[gnome-panel] fish: remove redundant variable declaration



commit 03e31ea8a025709601bb4ae05226d0d8eefb382e
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Mon Oct 17 20:53:16 2016 +0300

    fish: remove redundant variable declaration

 applets/fish/fish-applet.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/applets/fish/fish-applet.c b/applets/fish/fish-applet.c
index ccb963e..85b663b 100644
--- a/applets/fish/fish-applet.c
+++ b/applets/fish/fish-applet.c
@@ -617,10 +617,11 @@ display_fortune_dialog (FishApplet *fish)
        if (!argv)
                return;
 
+       screen = gtk_widget_get_screen (GTK_WIDGET (fish));
+
        if (!fish->fortune_dialog) {
                GtkWidget *scrolled;
                GtkWidget *vbox;
-               GdkScreen *screen;
                int        screen_width;
                int        screen_height;
 
@@ -644,8 +645,6 @@ display_fortune_dialog (FishApplet *fish)
 
                gtk_window_set_wmclass (GTK_WINDOW (fish->fortune_dialog), "fish", "Fish");
 
-               screen = gtk_widget_get_screen (GTK_WIDGET (fish));
-
                screen_width  = gdk_screen_get_width (screen);
                screen_height = gdk_screen_get_height (screen);
 
@@ -722,7 +721,6 @@ display_fortune_dialog (FishApplet *fish)
 
        clear_fortune_text (fish);
 
-       screen = gtk_widget_get_screen (GTK_WIDGET (fish));
        display = gdk_screen_make_display_name (screen);
 
        g_spawn_async_with_pipes (NULL, /* working directory */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]