Skip to content

Commit

Permalink
If nwipe used within ShredOS, the d key will toggle the font size, ha…
Browse files Browse the repository at this point in the history
…s no action for other distributions
  • Loading branch information
PartialVolume committed Aug 21, 2024
1 parent ef312ff commit c024add
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/gui.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@
#include "hpa_dco.h"
#include "customers.h"
#include "conf.h"
#include "unistd.h"

#define NWIPE_GUI_PANE 8

Expand Down Expand Up @@ -1349,6 +1350,19 @@ void nwipe_gui_select( int count, nwipe_context_t** c )

break;

case 'd':

/* The d key is only meaningful for ShredOS, it toggles the fontsize */
if( access( "/usr/bin/shredos_toggle_font_size.sh", F_OK ) == 0 )
{
if( system( "/usr/bin/shredos_toggle_font_size.sh > /dev/null 2>&1" ) == 0 )
{
nwipe_log( NWIPE_LOG_INFO, "Toggle font size" );
}
}

break;

} /* keystroke switch */

/* Check the terminal size, if the user has changed it the while loop checks for
Expand Down

0 comments on commit c024add

Please sign in to comment.