diff options
author | Přemysl Eric Janouch <p@janouch.name> | 2021-10-20 09:17:53 +0200 |
---|---|---|
committer | Přemysl Eric Janouch <p@janouch.name> | 2021-10-20 09:17:53 +0200 |
commit | aa3ad12d44274cf665b53be11f3de2c9fc393664 (patch) | |
tree | c542c918db72d132b5a1b4b76b3d37b84719fa5e /src/sdgui.c | |
parent | 82accaf200ab3a2cbf5a9112628a8f6eac27b1c8 (diff) | |
download | tdv-aa3ad12d44274cf665b53be11f3de2c9fc393664.tar.gz tdv-aa3ad12d44274cf665b53be11f3de2c9fc393664.tar.xz tdv-aa3ad12d44274cf665b53be11f3de2c9fc393664.zip |
sdgui: decrease source code line count
Diffstat (limited to 'src/sdgui.c')
-rw-r--r-- | src/sdgui.c | 20 |
1 files changed, 4 insertions, 16 deletions
diff --git a/src/sdgui.c b/src/sdgui.c index d126d20..0cbee8f 100644 --- a/src/sdgui.c +++ b/src/sdgui.c @@ -195,15 +195,9 @@ on_key_press (G_GNUC_UNUSED GtkWidget *widget, GdkEvent *event, // Can't use gtk_widget_add_accelerator() to change-current-page(-1/+1) // because that signal has arguments, which cannot be passed. if (event->key.keyval == GDK_KEY_Page_Up) - { - gtk_notebook_prev_page (GTK_NOTEBOOK (g.notebook)); - return TRUE; - } + return gtk_notebook_prev_page (GTK_NOTEBOOK (g.notebook)), TRUE; if (event->key.keyval == GDK_KEY_Page_Down) - { - gtk_notebook_next_page (GTK_NOTEBOOK (g.notebook)); - return TRUE; - } + return gtk_notebook_next_page (GTK_NOTEBOOK (g.notebook)), TRUE; } if (mods == GDK_MOD1_MASK) { @@ -220,15 +214,9 @@ on_key_press (G_GNUC_UNUSED GtkWidget *widget, GdkEvent *event, { StardictView *view = STARDICT_VIEW (g.view); if (event->key.keyval == GDK_KEY_Page_Up) - { - stardict_view_scroll (view, GTK_SCROLL_PAGES, -0.5); - return TRUE; - } + return stardict_view_scroll (view, GTK_SCROLL_PAGES, -0.5), TRUE; if (event->key.keyval == GDK_KEY_Page_Down) - { - stardict_view_scroll (view, GTK_SCROLL_PAGES, +0.5); - return TRUE; - } + return stardict_view_scroll (view, GTK_SCROLL_PAGES, +0.5), TRUE; } return FALSE; } |