summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormonsta <[email protected]>2016-03-30 14:32:18 +0300
committermonsta <[email protected]>2016-03-30 14:32:18 +0300
commit5001668d783804f291624b7b0430da4b5a3432fd (patch)
treec82401b4e7a4b9597c135c92c57cd7830d256d65 /src
parent72eef06b2329b178a4f8476c29f79d577807a133 (diff)
downloadeom-5001668d783804f291624b7b0430da4b5a3432fd.tar.bz2
eom-5001668d783804f291624b7b0430da4b5a3432fd.tar.xz
auto-reload unmodified images when their file is changed
from https://git.gnome.org/browse/eog/commit/?id=3764db24f7d5e570b39894a05ba71a09012eea24 fixes https://github.com/mate-desktop/eom/issues/69
Diffstat (limited to 'src')
-rw-r--r--src/eom-window.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/eom-window.c b/src/eom-window.c
index 2981f0f..ff4f712 100644
--- a/src/eom-window.c
+++ b/src/eom-window.c
@@ -806,6 +806,12 @@ image_file_changed_cb (EomImage *img, EomWindow *window)
if (window->priv->needs_reload_confirmation == FALSE)
return;
+ if (!eom_image_is_modified (img)) {
+ /* Auto-reload when image is unmodified */
+ eom_window_reload_image (window);
+ return;
+ }
+
window->priv->needs_reload_confirmation = FALSE;
info_bar = gtk_info_bar_new_with_buttons (_("_Reload"),