diff options
Diffstat (limited to 'src/core/keybindings.c')
-rw-r--r-- | src/core/keybindings.c | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/src/core/keybindings.c b/src/core/keybindings.c index 73966a80..068199b8 100644 --- a/src/core/keybindings.c +++ b/src/core/keybindings.c @@ -2288,6 +2288,14 @@ handle_switch_to_workspace (MetaDisplay *display, { gint which = binding->handler->data; MetaWorkspace *workspace; + + if (which == META_MOTION_PREV) + { + workspace = screen->prev_workspace; + if (workspace) + meta_workspace_activate (workspace, event->xkey.time); + return; + } if (which < 0) { @@ -3421,3 +3429,40 @@ meta_set_keybindings_disabled (gboolean setting) meta_topic (META_DEBUG_KEYBINDINGS, "Keybindings %s\n", all_bindings_disabled ? "disabled" : "enabled"); } + +static void +handle_run_terminal (MetaDisplay *display, + MetaScreen *screen, + MetaWindow *window, + XEvent *event, + MetaKeyBinding *binding) +{ + const char *command; + GError *err; + + command = meta_prefs_get_terminal_command (); + + if (command == NULL) + { + char *s; + + meta_topic (META_DEBUG_KEYBINDINGS, + "No terminal command to run in response to " + "keybinding press\n"); + + s = g_strdup_printf (_("No terminal command has been defined.\n")); + error_on_command (-1, NULL, s, screen->screen_name, event->xkey.time); + g_free (s); + + return; + } + + err = NULL; + if (!meta_spawn_command_line_async_on_screen (command, screen, &err)) + { + error_on_command (-1, command, err->message, screen->screen_name, + event->xkey.time); + + g_error_free (err); + } +} |