comparison src/image-overlay.c @ 1433:b4ad1d201279

Use gboolean where applicable, minor cleanup and indentations fixes.
author zas_
date Sat, 14 Mar 2009 19:25:21 +0000
parents fe4da037be21
children 2441a90c4bcf
comparison
equal deleted inserted replaced
1432:cf4029d10d38 1433:b4ad1d201279
56 }; 56 };
57 57
58 58
59 typedef struct _OSDIcon OSDIcon; 59 typedef struct _OSDIcon OSDIcon;
60 struct _OSDIcon { 60 struct _OSDIcon {
61 gint reset; /* reset on new image */ 61 gboolean reset; /* reset on new image */
62 gint x; /* x, y offset */ 62 gint x; /* x, y offset */
63 gint y; 63 gint y;
64 gchar *key; /* inline pixbuf */ 64 gchar *key; /* inline pixbuf */
65 }; 65 };
66 66
816 816
817 image_overlay_remove(osd->imd, osd->ovl_info); 817 image_overlay_remove(osd->imd, osd->ovl_info);
818 osd->ovl_info = 0; 818 osd->ovl_info = 0;
819 } 819 }
820 820
821 static gint image_osd_update_cb(gpointer data) 821 static gboolean image_osd_update_cb(gpointer data)
822 { 822 {
823 OverlayStateData *osd = data; 823 OverlayStateData *osd = data;
824 824
825 osd->imd->overlay_show_zoom = FALSE; 825 osd->imd->overlay_show_zoom = FALSE;
826 826
886 osd->changed_states = IMAGE_STATE_NONE; 886 osd->changed_states = IMAGE_STATE_NONE;
887 osd->idle_id = -1; 887 osd->idle_id = -1;
888 return FALSE; 888 return FALSE;
889 } 889 }
890 890
891 static void image_osd_update_schedule(OverlayStateData *osd, gint force) 891 static void image_osd_update_schedule(OverlayStateData *osd, gboolean force)
892 { 892 {
893 if (force) osd->changed_states |= IMAGE_STATE_IMAGE; 893 if (force) osd->changed_states |= IMAGE_STATE_IMAGE;
894 894
895 if (osd->idle_id == -1) 895 if (osd->idle_id == -1)
896 { 896 {
905 if (!osd) return; 905 if (!osd) return;
906 906
907 image_osd_update_schedule(osd, TRUE); 907 image_osd_update_schedule(osd, TRUE);
908 } 908 }
909 909
910 static gint image_osd_timer_cb(gpointer data) 910 static gboolean image_osd_timer_cb(gpointer data)
911 { 911 {
912 OverlayStateData *osd = data; 912 OverlayStateData *osd = data;
913 gint done = TRUE; 913 gboolean done = TRUE;
914 gint changed = FALSE; 914 gboolean changed = FALSE;
915 gint i; 915 gint i;
916 916
917 for (i = 0; i < IMAGE_OSD_COUNT; i++) 917 for (i = 0; i < IMAGE_OSD_COUNT; i++)
918 { 918 {
919 if (osd->icon_time[i] > 1) 919 if (osd->icon_time[i] > 1)