Mercurial > geeqie
comparison src/layout_util.c @ 1739:8436cdbc315c
Remove an unused variable and minor code cleanup.
author | zas_ |
---|---|
date | Mon, 07 Sep 2009 08:18:18 +0000 |
parents | 869ef66693f3 |
children | 7a6f3ffa036a |
comparison
equal
deleted
inserted
replaced
1738:869ef66693f3 | 1739:8436cdbc315c |
---|---|
659 | 659 |
660 | 660 |
661 static void layout_menu_overlay_cb(GtkToggleAction *action, gpointer data) | 661 static void layout_menu_overlay_cb(GtkToggleAction *action, gpointer data) |
662 { | 662 { |
663 LayoutWindow *lw = data; | 663 LayoutWindow *lw = data; |
664 GtkToggleAction *histogram_action = GTK_TOGGLE_ACTION(gtk_action_group_get_action(lw->action_group, "ImageHistogram")); | 664 |
665 | |
666 if (gtk_toggle_action_get_active(action)) | 665 if (gtk_toggle_action_get_active(action)) |
667 { | 666 { |
668 OsdShowFlags flags = image_osd_get(lw->image); | 667 OsdShowFlags flags = image_osd_get(lw->image); |
669 | 668 |
670 if ((flags | OSD_SHOW_INFO | OSD_SHOW_STATUS) != flags) | 669 if ((flags | OSD_SHOW_INFO | OSD_SHOW_STATUS) != flags) |
671 image_osd_set(lw->image, flags | OSD_SHOW_INFO | OSD_SHOW_STATUS); | 670 image_osd_set(lw->image, flags | OSD_SHOW_INFO | OSD_SHOW_STATUS); |
672 } | 671 } |
673 else | 672 else |
674 { | 673 { |
674 GtkToggleAction *histogram_action = GTK_TOGGLE_ACTION(gtk_action_group_get_action(lw->action_group, "ImageHistogram")); | |
675 | |
675 image_osd_set(lw->image, OSD_SHOW_NOTHING); | 676 image_osd_set(lw->image, OSD_SHOW_NOTHING); |
676 gtk_toggle_action_set_active(histogram_action, FALSE); /* this calls layout_menu_histogram_cb */ | 677 gtk_toggle_action_set_active(histogram_action, FALSE); /* this calls layout_menu_histogram_cb */ |
677 } | 678 } |
678 } | 679 } |
679 | 680 |
680 static void layout_menu_histogram_cb(GtkToggleAction *action, gpointer data) | 681 static void layout_menu_histogram_cb(GtkToggleAction *action, gpointer data) |
681 { | 682 { |
682 LayoutWindow *lw = data; | 683 LayoutWindow *lw = data; |
683 GtkToggleAction *overlay_action = GTK_TOGGLE_ACTION(gtk_action_group_get_action(lw->action_group, "ImageOverlay")); | |
684 | 684 |
685 if (gtk_toggle_action_get_active(action)) | 685 if (gtk_toggle_action_get_active(action)) |
686 { | 686 { |
687 image_osd_set(lw->image, OSD_SHOW_INFO | OSD_SHOW_STATUS | OSD_SHOW_HISTOGRAM); | 687 image_osd_set(lw->image, OSD_SHOW_INFO | OSD_SHOW_STATUS | OSD_SHOW_HISTOGRAM); |
688 layout_util_sync_views(lw); /* show the overlay state, default channel and mode in the menu */ | 688 layout_util_sync_views(lw); /* show the overlay state, default channel and mode in the menu */ |