summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-gfx/geeqie/files')
-rw-r--r--media-gfx/geeqie/files/geeqie-1.0-copy_chown.patch49
-rw-r--r--media-gfx/geeqie/files/geeqie-1.0-filedata_compare.patch53
-rw-r--r--media-gfx/geeqie/files/geeqie-1.0-fix_fullscreen.patch143
-rw-r--r--media-gfx/geeqie/files/geeqie-1.0-ui_pathsel.patch44
-rw-r--r--media-gfx/geeqie/files/geeqie-1.0-vflist-refresh.patch72
5 files changed, 361 insertions, 0 deletions
diff --git a/media-gfx/geeqie/files/geeqie-1.0-copy_chown.patch b/media-gfx/geeqie/files/geeqie-1.0-copy_chown.patch
new file mode 100644
index 000000000000..9aef27d69fed
--- /dev/null
+++ b/media-gfx/geeqie/files/geeqie-1.0-copy_chown.patch
@@ -0,0 +1,49 @@
+From dc8933e3c0ae3e0021d13beb666d6729267c7624 Mon Sep 17 00:00:00 2001
+From: Vladislav Naumov <vnaum@vnaum.com>
+Date: Thu, 16 Dec 2010 21:55:03 +0100
+Subject: [PATCH] Fix bug 2999830: do not report failed chown() on copy.
+
+Debian bug 574853 reported by Ian Zimmerman <itz@buug.org>
+
+I was trying to copy images from my camera which is mounted as a USB
+mass storage device. The files on the mount are owned by root, and
+geeqie tries to chown (and chgrp) the copy, fails, and displays an
+error message. This is only mildly annoying when copying a single
+file, but when I want to copy multiple files the failure stops the
+operation after the first file.
+
+Patch by Vladislav Naumov <vnaum@vnaum.com>
+
+This patch ignores chown errors, while still doing chown
+(so root still can copy files preserving ownership).
+
+http://sourceforge.net/tracker/?func=detail&aid=2999830&group_id=222125&atid=1054680
+http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=574853 (original report)
+---
+ src/ui_fileops.c | 10 ++++++++--
+ 1 files changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/src/ui_fileops.c b/src/ui_fileops.c
+index aa3cc8d..33c6560 100644
+--- a/src/ui_fileops.c
++++ b/src/ui_fileops.c
+@@ -490,8 +490,14 @@ gboolean copy_file_attributes(const gchar *s, const gchar *t, gint perms, gint m
+
+ /* set the dest file attributes to that of source (ignoring errors) */
+
+- if (perms && chown(tl, st.st_uid, st.st_gid) < 0) ret = FALSE;
+- if (perms && chmod(tl, st.st_mode) < 0) ret = FALSE;
++ if (perms)
++ {
++ ret = chown(tl, st.st_uid, st.st_gid);
++ /* Ignores chown errors, while still doing chown
++ (so root still can copy files preserving ownership) */
++ ret = TRUE;
++ if (chmod(tl, st.st_mode) < 0) ret = FALSE;
++ }
+
+ tb.actime = st.st_atime;
+ tb.modtime = st.st_mtime;
+--
+1.6.1
+
diff --git a/media-gfx/geeqie/files/geeqie-1.0-filedata_compare.patch b/media-gfx/geeqie/files/geeqie-1.0-filedata_compare.patch
new file mode 100644
index 000000000000..50a1c0f8ac88
--- /dev/null
+++ b/media-gfx/geeqie/files/geeqie-1.0-filedata_compare.patch
@@ -0,0 +1,53 @@
+From 18d80ca385e38b3bf9bc4ef36264bb4d430aa1f6 Mon Sep 17 00:00:00 2001
+From: Vladimir Nadvornik <nadvornik@suse.cz>
+Date: Fri, 30 Sep 2011 23:57:31 +0200
+Subject: [PATCH] fixed filelist_sort_compare_filedata to not return 0 no different files
+
+---
+ src/filedata.c | 15 ++++++++++++---
+ 1 files changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/filedata.c b/src/filedata.c
+index f6e3896..78fd74e 100644
+--- a/src/filedata.c
++++ b/src/filedata.c
+@@ -852,6 +852,7 @@ static gboolean filelist_sort_ascend = TRUE;
+
+ gint filelist_sort_compare_filedata(FileData *fa, FileData *fb)
+ {
++ gint ret;
+ if (!filelist_sort_ascend)
+ {
+ FileData *tmp = fa;
+@@ -875,7 +876,8 @@ gint filelist_sort_compare_filedata(FileData *fa, FileData *fb)
+ break;
+ #ifdef HAVE_STRVERSCMP
+ case SORT_NUMBER:
+- return strverscmp(fa->name, fb->name);
++ ret = strverscmp(fa->name, fb->name);
++ if (ret != 0) return ret;
+ break;
+ #endif
+ default:
+@@ -883,9 +885,16 @@ gint filelist_sort_compare_filedata(FileData *fa, FileData *fb)
+ }
+
+ if (options->file_sort.case_sensitive)
+- return strcmp(fa->collate_key_name, fb->collate_key_name);
++ ret = strcmp(fa->collate_key_name, fb->collate_key_name);
+ else
+- return strcmp(fa->collate_key_name_nocase, fb->collate_key_name_nocase);
++ ret = strcmp(fa->collate_key_name_nocase, fb->collate_key_name_nocase);
++
++ if (ret != 0) return ret;
++
++ /* do not return 0 unless the files are really the same
++ file_data_pool ensures that original_path is unique
++ */
++ return strcmp(fa->original_path, fb->original_path);
+ }
+
+ gint filelist_sort_compare_filedata_full(FileData *fa, FileData *fb, SortType method, gboolean ascend)
+--
+1.6.1
+
diff --git a/media-gfx/geeqie/files/geeqie-1.0-fix_fullscreen.patch b/media-gfx/geeqie/files/geeqie-1.0-fix_fullscreen.patch
new file mode 100644
index 000000000000..0547395a3b2b
--- /dev/null
+++ b/media-gfx/geeqie/files/geeqie-1.0-fix_fullscreen.patch
@@ -0,0 +1,143 @@
+Description: Make fullscreen modes actually use the full screen.
+ The default fullscreen mode now leaves everything up to the window manager,
+ which usually produces the best result. Custom fullscreen modes now use
+ override-redirect to ensure docks and panels never obscure the image.
+Author: Daniel van Vugt <vanvugt@gmail.com>
+Bug: http://sourceforge.net/support/tracker.php?aid=2925034
+Bug-Ubuntu: https://launchpad.net/bugs/788321
+Forwarded: yes
+
+=== modified file 'src/fullscreen.c'
+--- old/src/fullscreen.c 2010-02-26 10:41:38 +0000
++++ new/src/fullscreen.c 2011-08-16 03:55:04 +0000
+@@ -218,75 +218,65 @@
+ void (*stop_func)(FullScreenData *, gpointer), gpointer stop_data)
+ {
+ FullScreenData *fs;
+- GdkScreen *screen;
+- gboolean same;
+- gint x, y;
+- gint w, h;
+- GdkGeometry geometry;
+
+ if (!window || !imd) return NULL;
+
++ DEBUG_1("full screen requests screen %d", options->fullscreen.screen);
++
+ fs = g_new0(FullScreenData, 1);
+-
+ fs->cursor_state = FULLSCREEN_CURSOR_HIDDEN;
+-
+ fs->normal_window = window;
+ fs->normal_imd = imd;
+-
+ fs->stop_func = stop_func;
+ fs->stop_data = stop_data;
+-
+- DEBUG_1("full screen requests screen %d", options->fullscreen.screen);
+- fullscreen_prefs_get_geometry(options->fullscreen.screen, window, &x, &y, &w, &h,
+- &screen, &same);
+-
+- fs->window = window_new(GTK_WINDOW_TOPLEVEL, "fullscreen", NULL, NULL, _("Full screen"));
+-
+- /* this requests no decorations, if you still have them complain to the window manager author(s) */
+- gtk_window_set_decorated(GTK_WINDOW(fs->window), FALSE);
++ fs->window = window_new(GTK_WINDOW_TOPLEVEL, "fullscreen", NULL, NULL,
++ _("Full screen"));
+
+ if (options->fullscreen.screen < 0)
+- {
+- /* If we want control of the window size and position this is not what we want.
+- * Geeqie needs control of which monitor(s) to use for full screen.
+- */
++ { /* Fullscreen as determined by the window manager... */
+ gtk_window_fullscreen(GTK_WINDOW(fs->window));
+ }
+- else if (options->fullscreen.above)
+- {
+- /* request to be above other windows */
+- gtk_window_set_keep_above(GTK_WINDOW(fs->window), TRUE);
++ else
++ { /* Custom fullscreen modes. Done by hand, the hard way... */
++ GdkScreen *screen;
++ gint x, y, w, h;
++ GdkGeometry geometry;
++ GtkWindow *gtkwin = GTK_WINDOW(fs->window);
++ GdkWindow *gdkwin;
++
++ fullscreen_prefs_get_geometry(options->fullscreen.screen,
++ window, &x, &y, &w, &h, &screen, NULL);
++
++ if (options->fullscreen.above)
++ gtk_window_set_keep_above(gtkwin, TRUE);
++
++ gtk_window_set_screen(gtkwin, screen);
++ gtk_window_set_decorated(gtkwin, FALSE);
++ gtk_window_set_resizable(gtkwin, FALSE);
++ gtk_container_set_border_width(GTK_CONTAINER(fs->window), 0);
++
++ geometry.min_width = w;
++ geometry.min_height = h;
++ geometry.max_width = w;
++ geometry.max_height = h;
++ geometry.base_width = w;
++ geometry.base_height = h;
++ gtk_window_set_geometry_hints(gtkwin, fs->window, &geometry,
++ GDK_HINT_MIN_SIZE | GDK_HINT_MAX_SIZE |
++ GDK_HINT_BASE_SIZE);
++
++ gtk_window_set_default_size(gtkwin, w, h);
++ gtk_window_move(gtkwin, x, y);
++
++ gtk_widget_realize(fs->window);
++ gdkwin = gtk_widget_get_window(fs->window);
++ if (gdkwin != NULL)
++ gdk_window_set_override_redirect(gdkwin, TRUE);
+ }
+
+- gtk_window_set_resizable(GTK_WINDOW(fs->window), FALSE);
+-
+- gtk_window_set_screen(GTK_WINDOW(fs->window), screen);
+- gtk_container_set_border_width(GTK_CONTAINER(fs->window), 0);
+ g_signal_connect(G_OBJECT(fs->window), "delete_event",
+ G_CALLBACK(fullscreen_delete_cb), fs);
+
+- geometry.min_width = w;
+- geometry.min_height = h;
+- geometry.max_width = w;
+- geometry.max_height = h;
+- geometry.base_width = w;
+- geometry.base_height = h;
+- geometry.win_gravity = GDK_GRAVITY_STATIC;
+- /* By setting USER_POS and USER_SIZE, most window managers will
+- * not request positioning of the full screen window (for example twm).
+- *
+- * In addition, setting gravity to STATIC will result in the
+- * decorations of twm to not effect the requested window position,
+- * the decorations will simply be off screen, except in multi monitor setups :-/
+- */
+- gtk_window_set_geometry_hints(GTK_WINDOW(fs->window), fs->window, &geometry,
+- GDK_HINT_MIN_SIZE | GDK_HINT_MAX_SIZE | GDK_HINT_BASE_SIZE |
+- GDK_HINT_WIN_GRAVITY |
+- GDK_HINT_USER_POS);
+-
+- gtk_window_set_default_size(GTK_WINDOW(fs->window), w, h);
+- gtk_window_move(GTK_WINDOW(fs->window), x, y);
+-
+ fs->imd = image_new(FALSE);
+
+ gtk_container_add(GTK_CONTAINER(fs->window), fs->imd->widget);
+@@ -393,7 +383,11 @@
+ else
+ {
+ gdk_screen_get_monitor_geometry(screen, j, &rect);
+- subname = g_strdup_printf("%s %d", _("Monitor"), j + 1);
++ subname = gdk_screen_get_monitor_plug_name(screen, j);
++ if (subname == NULL)
++ {
++ subname = g_strdup_printf("%s %d", _("Monitor"), j + 1);
++ }
+ }
+
+ sd = g_new0(ScreenData, 1);
+
diff --git a/media-gfx/geeqie/files/geeqie-1.0-ui_pathsel.patch b/media-gfx/geeqie/files/geeqie-1.0-ui_pathsel.patch
new file mode 100644
index 000000000000..019ce413ebb0
--- /dev/null
+++ b/media-gfx/geeqie/files/geeqie-1.0-ui_pathsel.patch
@@ -0,0 +1,44 @@
+From 738ed337ffaa80276901451847fa83f865b1c439 Mon Sep 17 00:00:00 2001
+From: Klaus Ethgen <Klaus@Ethgen.de>
+Date: Sat, 9 Apr 2011 19:47:30 +0100
+Subject: [PATCH] Do not delete path settings when adding new directory
+
+This patch will change the way, geeqie is mangling the path name in the
+rename (copy) dialog when creating new directory. Will fix the bugs
+Debian:529531 and SF:2795791.
+---
+ src/ui_pathsel.c | 11 +++++++++--
+ 1 files changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/src/ui_pathsel.c b/src/ui_pathsel.c
+index 6b69c05..d58c5ac 100644
+--- a/src/ui_pathsel.c
++++ b/src/ui_pathsel.c
+@@ -740,7 +740,10 @@ static void dest_new_dir_cb(GtkWidget *widget, gpointer data)
+ tmp = gtk_entry_get_text(GTK_ENTRY(dd->entry));
+ if (!isname(tmp))
+ {
+- path = g_strdup(tmp);
++ buf = remove_trailing_slash(tmp);
++ path = g_strdup(buf);
++ g_free(buf);
++ buf = remove_level_from_path(path);
+ from_text = TRUE;
+ }
+ else
+@@ -765,7 +768,11 @@ static void dest_new_dir_cb(GtkWidget *widget, gpointer data)
+ GtkListStore *store;
+ const gchar *text;
+
+- if (from_text) gtk_entry_set_text(GTK_ENTRY(dd->entry), dd->path);
++ if (from_text)
++ {
++ dest_populate(dd, buf);
++ g_free(buf);
++ }
+
+ store = GTK_LIST_STORE(gtk_tree_view_get_model(GTK_TREE_VIEW(dd->d_view)));
+
+--
+1.6.1
+
diff --git a/media-gfx/geeqie/files/geeqie-1.0-vflist-refresh.patch b/media-gfx/geeqie/files/geeqie-1.0-vflist-refresh.patch
new file mode 100644
index 000000000000..a5e0aa32c218
--- /dev/null
+++ b/media-gfx/geeqie/files/geeqie-1.0-vflist-refresh.patch
@@ -0,0 +1,72 @@
+diff -Nur geeqie-1.0-orig/src/view_file_list.c geeqie-1.0/src/view_file_list.c
+--- geeqie-1.0-orig/src/view_file_list.c 2010-02-17 22:21:19.000000000 +0100
++++ geeqie-1.0/src/view_file_list.c 2011-04-15 13:47:10.727936556 +0200
+@@ -943,8 +943,6 @@
+ GList *work;
+ GtkTreeIter iter;
+ gboolean valid;
+- gint num_ordered = 0;
+- gint num_prepended = 0;
+
+ valid = gtk_tree_model_iter_children(GTK_TREE_MODEL(store), &iter, parent_iter);
+
+@@ -993,17 +991,11 @@
+
+ if (valid)
+ {
+- num_ordered++;
+ gtk_tree_store_insert_before(store, &new, parent_iter, &iter);
+ }
+ else
+ {
+- /*
+- here should be used gtk_tree_store_append, but this function seems to be O(n)
+- and it seems to be much faster to add new entries to the beginning and reorder later
+- */
+- num_prepended++;
+- gtk_tree_store_prepend(store, &new, parent_iter);
++ gtk_tree_store_append(store, &new, parent_iter);
+ }
+
+ vflist_setup_iter(vf, store, &new, file_data_ref(fd));
+@@ -1026,7 +1018,6 @@
+ }
+ else
+ {
+- num_ordered++;
+ if (fd->version != old_version || force)
+ {
+ vflist_setup_iter(vf, store, &iter, fd);
+@@ -1043,31 +1034,12 @@
+
+ while (valid)
+ {
+- FileData *old_fd;
++ FileData *old_fd = NULL;
+ gtk_tree_model_get(GTK_TREE_MODEL(store), &iter, FILE_COLUMN_POINTER, &old_fd, -1);
+ file_data_unref(old_fd);
+
+ valid = gtk_tree_store_remove(store, &iter);
+ }
+-
+- /* move the prepended entries to the correct position */
+- if (num_prepended)
+- {
+- gint i;
+- gint num_total = num_prepended + num_ordered;
+- gint *new_order = g_malloc(num_total * sizeof(gint));
+-
+- for (i = 0; i < num_total; i++)
+- {
+- if (i < num_ordered)
+- new_order[i] = num_prepended + i;
+- else
+- new_order[i] = num_total - 1 - i;
+- }
+- gtk_tree_store_reorder(store, parent_iter, new_order);
+-
+- g_free(new_order);
+- }
+ }
+
+ void vflist_sort_set(ViewFile *vf, SortType type, gboolean ascend)