Mercurial > hg > forks > geeqie
changeset 2606:1e344397544c
Remove some stuff that is throwing errors in gcc-7
New gcc warns (and errors with -Werror) if there are unused functions or
variables.
- Remove two leftover functions from ae34634113b2
- Remove definition made to much in 035c3253ded5
- Remove two variable definitions made in b0b11291d2c9
- Remove not really used function in 15917d4063ce
- Remove two variable definitions made in 5ed2574fb8cc
- Remove variable definition made in efe0e6a38273
- Remove variable definition made in c95bd6996583 and since then removed
usage
- Remove unused variable definition made in bc02fd0eb0d9
- Remove unused variable definition made in 324129463b17
- Remove two variables left over from fe69cac65ad4 (Pretty old code from
John Ellis)
- Remove some functions not used anymore with one obsolete variable
- Remove Variables introduced in 8746b22d3ed1 and 51a9455bd33f
- Fix missed change in definition in 6e3b2edff8cf
- Remove unused function from 63a96f8504a2
- Remove unused function from c6bdbaa559c7 (Pretty old code)
author | Klaus Ethgen <Klaus@Ethgen.de> |
---|---|
date | Sun, 17 Sep 2017 13:45:42 +0100 |
parents | 71e7f2a9b52c |
children | 4a7ef0180612 |
files | src/bar_exif.c src/collect-table.c src/dupe.c src/layout_image.c src/layout_util.c src/logwindow.c src/pixbuf-renderer.c src/preferences.c src/remote.c src/search.c src/view_file/view_file.c |
diffstat | 11 files changed, 4 insertions(+), 92 deletions(-) [+] |
line wrap: on
line diff
--- a/src/bar_exif.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/bar_exif.c Sun Sep 17 13:45:42 2017 +0100 @@ -97,7 +97,6 @@ static void bar_pane_exif_update(PaneExifData *ped); static gboolean bar_pane_exif_menu_cb(GtkWidget *widget, GdkEventButton *bevent, gpointer data); static void bar_pane_exif_notify_cb(FileData *fd, NotifyType type, gpointer data); -static gboolean bar_pane_exif_mouse_cb(GtkWidget *widget, GdkEventButton *bevent, gpointer data); static gboolean bar_pane_exif_copy_cb(GtkWidget *widget, GdkEventButton *bevent, gpointer data); static void bar_pane_exif_entry_changed(GtkEntry *text_entry, gpointer data)
--- a/src/collect-table.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/collect-table.c Sun Sep 17 13:45:42 2017 +0100 @@ -803,8 +803,6 @@ static void collection_table_popup_rectangular_selection_cb(GtkWidget *widget, gpointer data) { - CollectTable *ct = data; - options->collections.rectangular_selection = !(options->collections.rectangular_selection); }
--- a/src/dupe.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/dupe.c Sun Sep 17 13:45:42 2017 +0100 @@ -2211,13 +2211,6 @@ dupe_window_edit_selected(dw, key); } -static void dupe_menu_collection_cb(GtkWidget *widget, gpointer data) -{ - DupeWindow *dw = data; - - dupe_window_collection_from_selection(dw); -} - static void dupe_menu_print_cb(GtkWidget *widget, gpointer data) { DupeWindow *dw = data;
--- a/src/layout_image.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/layout_image.c Sun Sep 17 13:45:42 2017 +0100 @@ -52,7 +52,6 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw); static void layout_image_set_buttons(LayoutWindow *lw); -static void layout_image_animate_stop(LayoutWindow *lw); static gboolean layout_image_animate_new_file(LayoutWindow *lw); static void layout_image_animate_update_image(LayoutWindow *lw); @@ -355,17 +354,6 @@ return TRUE; } -static void layout_image_animate_stop(LayoutWindow *lw) -{ - if (!layout_valid(&lw)) return; - - if(lw->options.animate && lw->animation) - { - lw->animation->valid = FALSE; - lw->animation = NULL; - } -} - static void layout_image_animate_update_image(LayoutWindow *lw) { if (!layout_valid(&lw)) return;
--- a/src/layout_util.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/layout_util.c Sun Sep 17 13:45:42 2017 +0100 @@ -877,8 +877,6 @@ static void layout_menu_rectangular_selection_cb(GtkToggleAction *action, gpointer data) { - LayoutWindow *lw = data; - options->collections.rectangular_selection = gtk_toggle_action_get_active(action); } @@ -1020,8 +1018,6 @@ static void layout_menu_slideshow_slower_cb(GtkAction *action, gpointer data) { - LayoutWindow *lw = data; - options->slideshow.delay = options->slideshow.delay + 5; if (options->slideshow.delay > SLIDESHOW_MAX_SECONDS) options->slideshow.delay = SLIDESHOW_MAX_SECONDS; @@ -1029,8 +1025,6 @@ static void layout_menu_slideshow_faster_cb(GtkAction *action, gpointer data) { - LayoutWindow *lw = data; - options->slideshow.delay = options->slideshow.delay - 5; if (options->slideshow.delay < SLIDESHOW_MIN_SECONDS * 10) options->slideshow.delay = SLIDESHOW_MIN_SECONDS * 10; @@ -1167,7 +1161,6 @@ static void layout_menu_kbd_map_cb(GtkAction *action, gpointer data) { - LayoutWindow *lw = data; gint fd = -1; GPtrArray *array; char * tmp_file; @@ -2447,7 +2440,6 @@ void layout_actions_setup(LayoutWindow *lw) { GError *error; - gint i; DEBUG_1("%s layout_actions_setup: start", get_exec_time()); if (lw->ui_manager) return;
--- a/src/logwindow.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/logwindow.c Sun Sep 17 13:45:42 2017 +0100 @@ -108,8 +108,6 @@ static void log_window_timer_data_cb(GtkWidget *widget, gpointer data) { - LogWindow *logwin = data; - options->log_window.timer_data = !options->log_window.timer_data; } @@ -135,7 +133,6 @@ GtkWidget *text; GtkTextBuffer *buffer; GtkTextIter iter; - GtkWidget *button; GtkWidget *win_vbox; GtkWidget *textbox; GtkWidget *hbox;
--- a/src/pixbuf-renderer.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/pixbuf-renderer.c Sun Sep 17 13:45:42 2017 +0100 @@ -920,9 +920,6 @@ void pixbuf_renderer_set_color(PixbufRenderer *pr, GdkColor *color) { - GtkStyle *style; - GtkWidget *widget; - g_return_if_fail(IS_PIXBUF_RENDERER(pr)); if (color) @@ -2298,15 +2295,15 @@ guchar *spi, *dpi; gint i, j, k; double pr_dubois_matrix[3][6]; - const static double pr_dubois_matrix_RC[3][6] = { + static const double pr_dubois_matrix_RC[3][6] = { { 0.456, 0.500, 0.176, -0.043, -0.088, -0.002}, {-0.040, -0.038, -0.016, 0.378, 0.734, -0.018}, {-0.015, -0.021, -0.005, -0.072, -0.113, 1.226}}; - const static double pr_dubois_matrix_GM[3][6] = { + static const double pr_dubois_matrix_GM[3][6] = { {-0.062, -0.158, -0.039, 0.529, 0.705, 0.024}, { 0.284, 0.668, 0.143, -0.016, -0.015, -0.065}, {-0.015, -0.027, 0.021, 0.009, 0.075, 0.937}}; - const static double pr_dubois_matrix_YB[3][6] = { + static const double pr_dubois_matrix_YB[3][6] = { { 1.000, -0.193, 0.282, -0.015, -0.116, -0.016}, {-0.024, 0.855, 0.064, 0.006, 0.058, -0.016}, {-0.036, -0.163, 0.021, 0.089, 0.174, 0.858}};
--- a/src/preferences.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/preferences.c Sun Sep 17 13:45:42 2017 +0100 @@ -140,12 +140,6 @@ *----------------------------------------------------------------------------- */ -static void scroll_reset_cb(GtkWidget *widget, gpointer data) -{ - if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget))) - c_options->image.scroll_reset_method = GPOINTER_TO_INT(data); -} - static void zoom_increment_cb(GtkWidget *spin, gpointer data) { c_options->image.zoom_increment = (gint)(gtk_spin_button_get_value(GTK_SPIN_BUTTON(spin)) * 100.0 + 0.01); @@ -1546,9 +1540,7 @@ { GtkWidget *hbox; GtkWidget *vbox; - GtkWidget *vbox2; GtkWidget *group; - GtkWidget *button; GtkWidget *ct_button; GtkWidget *enlargement_button; GtkWidget *table; @@ -2540,29 +2532,6 @@ *----------------- */ -static GtkWidget *about = NULL; - -static gboolean about_delete_cb(GtkWidget *widget, GdkEventAny *event, gpointer data) -{ - gtk_widget_destroy(about); - about = NULL; - - return TRUE; -} - -static void about_window_close(GtkWidget *widget, gpointer data) -{ - if (!about) return; - - gtk_widget_destroy(about); - about = NULL; -} - -static void about_credits_cb(GtkWidget *widget, gpointer data) -{ - help_window_show("credits"); -} - void show_about_window(LayoutWindow *lw) { GdkPixbuf *pixbuf_logo;
--- a/src/remote.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/remote.c Sun Sep 17 13:45:42 2017 +0100 @@ -452,11 +452,6 @@ cache_maintain_home_remote(TRUE, FALSE); } -static void gr_cache_clear(const gchar *text, GIOChannel *channel, gpointer data) -{ - cache_maintain_home_remote(FALSE, TRUE); -} - static void gr_cache_render(const gchar *text, GIOChannel *channel, gpointer data) { cache_manager_render_remote(text, FALSE, FALSE); @@ -748,7 +743,7 @@ { "-crr:", "--cache-render-recurse:", gr_cache_render_recurse, TRUE, FALSE, N_("<folder> "), N_("render thumbnails recursively") }, { "-crs:", "--cache-render-shared:", gr_cache_render_standard, TRUE, FALSE, N_("<folder> "), N_(" render thumbnails (see Help)") }, { "-crsr:", "--cache-render-shared-recurse:", gr_cache_render_standard_recurse, TRUE, FALSE, N_("<folder>"), N_(" render thumbnails recursively (see Help)") }, - { NULL, NULL, NULL, FALSE, FALSE, NULL } + { NULL, NULL, NULL, FALSE, FALSE, NULL, NULL } }; static RemoteCommandEntry *remote_command_find(const gchar *text, const gchar **offset)
--- a/src/search.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/search.c Sun Sep 17 13:45:42 2017 +0100 @@ -959,13 +959,6 @@ search_result_edit_selected(sd, key); } -static void sr_menu_collection_cb(GtkWidget *widget, gpointer data) -{ - SearchData *sd = data; - - search_result_collection_from_selection(sd); -} - static void sr_menu_print_cb(GtkWidget *widget, gpointer data) { SearchData *sd = data;
--- a/src/view_file/view_file.c Sun Sep 17 13:37:10 2017 +0100 +++ b/src/view_file/view_file.c Sun Sep 17 13:45:42 2017 +0100 @@ -376,15 +376,6 @@ dupe_window_add_files(dw, vf_pop_menu_file_list(vf), FALSE); } -static void vf_pop_menu_add_collection_cb(GtkWidget *widget, gpointer data) -{ - ViewFile *vf = data; - CollectWindow *w; - - w = collection_window_new(NULL); - collection_table_add_filelist(w->table, vf_pop_menu_file_list(vf)); -} - static void vf_pop_menu_disable_grouping_cb(GtkWidget *widget, gpointer data) { ViewFile *vf = data;