diff --git a/inc/wofi.h b/inc/wofi.h index 62ca8c1..63a0a8f 100644 --- a/inc/wofi.h +++ b/inc/wofi.h @@ -53,7 +53,7 @@ bool wofi_allow_images(); uint64_t wofi_get_image_size(); -bool wofi_run_in_term(); +bool wofi_mod_shift(); bool wofi_mod_control(); diff --git a/modes/run.c b/modes/run.c index a5ddb56..b2e9c76 100644 --- a/modes/run.c +++ b/modes/run.c @@ -79,7 +79,7 @@ void wofi_run_init() { } void wofi_run_exec(const gchar* cmd) { - if(wofi_run_in_term()) { + if(wofi_mod_shift()) { wofi_write_cache(MODE, cmd); wofi_term_run(cmd); } diff --git a/src/wofi.c b/src/wofi.c index fba2e39..eabafd5 100644 --- a/src/wofi.c +++ b/src/wofi.c @@ -31,7 +31,7 @@ static bool allow_images, allow_markup; static uint64_t image_size; static char* cache_file = NULL; static char* config_dir; -static bool run_in_term; +static bool mod_shift; static bool mod_ctrl; static char* terminal; static GtkOrientation outer_orientation; @@ -320,8 +320,8 @@ uint64_t wofi_get_image_size() { return image_size; } -bool wofi_run_in_term() { - return run_in_term; +bool wofi_mod_shift() { + return mod_shift; } bool wofi_mod_control() { @@ -417,9 +417,9 @@ static gboolean key_press(GtkWidget* widget, GdkEvent* event, gpointer data) { case GDK_KEY_Left: break; case GDK_KEY_Return: - run_in_term = (event->key.state & GDK_SHIFT_MASK) == GDK_SHIFT_MASK; + mod_shift = (event->key.state & GDK_SHIFT_MASK) == GDK_SHIFT_MASK; mod_ctrl = (event->key.state & GDK_CONTROL_MASK) == GDK_CONTROL_MASK; - if(run_in_term) { + if(mod_shift) { event->key.state &= ~GDK_SHIFT_MASK; } if(mod_ctrl) {