diff options
-rw-r--r-- | src/commands.c | 27 | ||||
-rw-r--r-- | src/commands.h | 7 | ||||
-rw-r--r-- | src/view.c | 1 |
3 files changed, 9 insertions, 26 deletions
diff --git a/src/commands.c b/src/commands.c index e4711f4f..5600a552 100644 --- a/src/commands.c +++ b/src/commands.c @@ -63,6 +63,7 @@ commands_simple_command(KeyMap *km) { dwb_set_error_message(dwb.state.fview, arg->e ? arg->e : km->map->error); break; case STATUS_END: + dwb_clean_key_buffer(); return; default: break; } @@ -72,9 +73,10 @@ commands_simple_command(KeyMap *km) { }/*}}}*/ /* commands_add_view(KeyMap *, Arg *) {{{*/ -void +DwbStatus commands_add_view(KeyMap *km, Arg *arg) { view_add(arg->p, false); + return STATUS_OK; }/*}}}*/ /* commands_set_setting {{{*/ @@ -309,30 +311,12 @@ commands_scroll(KeyMap *km, Arg *arg) { }/*}}}*/ /* commands_set_zoom_level(KeyMap *km, Arg *arg) {{{*/ -void +DwbStatus commands_set_zoom_level(KeyMap *km, Arg *arg) { GList *gl = arg->p ? arg->p : dwb.state.fview; webkit_web_view_set_zoom_level(WEBKIT_WEB_VIEW(((View*)gl->data)->web), arg->d); -}/*}}}*/ - -/* commands_set_orientation(KeyMap *km, Arg *arg) {{{*/ -#if 0 -DwbStatus -commands_set_orientation(KeyMap *km, Arg *arg) { - Layout l; - if (arg->n) { - l = arg->n; - } - else { - dwb.state.layout ^= BOTTOM_STACK; - l = dwb.state.layout; - } - gtk_orientable_set_orientation(GTK_ORIENTABLE(dwb.gui.paned), l & BOTTOM_STACK ); - gtk_orientable_set_orientation(GTK_ORIENTABLE(dwb.gui.right), (l & BOTTOM_STACK) ^ 1); - dwb_resize(dwb.state.size); return STATUS_OK; }/*}}}*/ -#endif /* History {{{*/ DwbStatus @@ -366,9 +350,10 @@ commands_open_startpage(KeyMap *km, Arg *arg) { } /*}}}*/ /* commands_remove_view(KeyMap *km, Arg *arg) {{{*/ -void +DwbStatus commands_remove_view(KeyMap *km, Arg *arg) { view_remove(NULL); + return STATUS_OK; }/*}}}*/ static gboolean diff --git a/src/commands.h b/src/commands.h index 9312ba05..e0bdea38 100644 --- a/src/commands.h +++ b/src/commands.h @@ -21,7 +21,7 @@ void commands_simple_command(KeyMap *km); -void commands_add_view(KeyMap *, Arg *); +DwbStatus commands_add_view(KeyMap *, Arg *); DwbStatus commands_add_search_field(KeyMap *, Arg *); DwbStatus commands_allow_cookie(KeyMap *, Arg *); DwbStatus commands_bookmark(KeyMap *, Arg *); @@ -69,9 +69,8 @@ DwbStatus commands_yank(KeyMap *, Arg *); DwbStatus commands_zoom_in(KeyMap *, Arg *); DwbStatus commands_zoom_out(KeyMap *, Arg *); DwbStatus dwb_create_hints(Arg *); -void commands_remove_view(KeyMap *, Arg *); -void commands_set_zoom_level(KeyMap *, Arg *); -void commands_toggle_maximized(KeyMap *, Arg *); +DwbStatus commands_remove_view(KeyMap *, Arg *); +DwbStatus commands_set_zoom_level(KeyMap *, Arg *); DwbStatus commands_toggle_hidden_files(KeyMap *, Arg *); DwbStatus commands_web_inspector(KeyMap *, Arg *); DwbStatus commands_quit(KeyMap *, Arg *); @@ -875,7 +875,6 @@ view_remove(GList *gl) { gtk_widget_show(CURRENT_VIEW()->scroll); dwb_update_layout(); - dwb_clean_key_buffer(); CLEAR_COMMAND_TEXT(); }/*}}}*/ |