- Update to 1.6.9

- Add patches, which fixes trash at startup [1]

Obtained from:	https://bugzilla.xfce.org/show_bug.cgi?id=11913 [1]
This commit is contained in:
Olivier Duchateau 2015-05-22 04:29:41 +00:00
parent 454e14df24
commit ab78f3c806
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=386982
7 changed files with 195 additions and 17 deletions

View File

@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= Thunar
PORTVERSION= 1.6.8
PORTREVISION= 1
PORTVERSION= 1.6.9
CATEGORIES= x11-fm xfce
MASTER_SITES= XFCE/src/xfce/${PORTNAME:tl}/${PORTVERSION:R}
DIST_SUBDIR= xfce4
@ -58,8 +57,7 @@ OPTIONS_SUB= yes
CONFIGURE_ARGS+=--enable-gio-unix \
--disable-gudev \
--enable-dbus \
--without-html-dir
--enable-dbus
post-patch:
${REINPLACE_CMD} -e 's|internet-mail|mail-send|' \

View File

@ -1,2 +1,2 @@
SHA256 (xfce4/Thunar-1.6.8.tar.bz2) = 4079ccffe990cdccee48a0ae200d8a5bc9335c34721d7923b375795940cf79bb
SIZE (xfce4/Thunar-1.6.8.tar.bz2) = 2169171
SHA256 (xfce4/Thunar-1.6.9.tar.bz2) = 75f3622cbe6ab6837f38d856faeac75a1191be8a08dc4c98ba35b61e312b94e5
SIZE (xfce4/Thunar-1.6.9.tar.bz2) = 1947746

View File

@ -0,0 +1,95 @@
Revert fix for bug #9513
--- thunar/main.c.orig 2015-05-15 16:38:08 UTC
+++ thunar/main.c
@@ -53,7 +53,7 @@ static gboolean opt_daemon = FALSE;
static gchar *opt_sm_client_id = NULL;
static gboolean opt_quit = FALSE;
static gboolean opt_version = FALSE;
-static ThunarFile *thunar_trash_file = NULL;
+
/* --- command line options --- */
@@ -97,13 +97,6 @@ thunar_delayed_exit_check (gpointer user
}
else
{
- /* unref the trash bin */
- if (thunar_trash_file != NULL)
- {
- g_object_unref (thunar_trash_file);
- thunar_trash_file = NULL;
- }
-
/* no command line arguments opened in Thunar, exit now */
gtk_main_quit ();
@@ -115,38 +108,6 @@ thunar_delayed_exit_check (gpointer user
-static void
-thunar_force_spawn_trash (void)
-{
- GFile *trash;
-
- /* check that this has not happened yet */
- if (thunar_trash_file != NULL)
- return;
-
- /* gvfs has no trash support */
- if (!thunar_g_vfs_is_uri_scheme_supported ("trash"))
- return;
-
- trash = thunar_g_file_new_for_trash ();
- thunar_trash_file = thunar_file_cache_lookup (trash);
- if (thunar_trash_file == NULL)
- {
- thunar_trash_file = thunar_file_get (trash, NULL);
- if (thunar_trash_file)
- {
- /* schedule a few reloads */
- thunar_file_reload_idle (thunar_trash_file);
- thunar_file_reload_idle_timeout (thunar_trash_file, 2000);
- thunar_file_reload_idle_timeout (thunar_trash_file, 3000);
- thunar_file_reload_idle_timeout (thunar_trash_file, 5000);
- }
- }
- g_object_unref (trash);
-}
-
-
-
int
main (int argc, char **argv)
{
@@ -290,14 +251,6 @@ main (int argc, char **argv)
/* initialize the thunar stock items/icons */
thunar_stock_init ();
- /* For the trash state to be correct, gvfsd-trash needs to have been
- * spawned. If the trash file is not in cache, this means we could
- * access it the first time and the daemon might not have been
- * spawned yet. So let's reload the trash later in idle, so that
- * the state gets updated correctly (bug #9513).
- */
- thunar_force_spawn_trash ();
-
/* acquire a reference on the global application */
application = thunar_application_get ();
@@ -363,13 +316,6 @@ error0:
g_object_unref (G_OBJECT (dbus_service));
#endif
- /* unreference the trash file */
- if (thunar_trash_file != NULL)
- {
- g_object_unref (thunar_trash_file);
- thunar_trash_file = NULL;
- }
-
/* disconnect from the session manager */
g_object_unref (G_OBJECT (session_client));

View File

@ -0,0 +1,10 @@
--- thunar/thunar-dbus-service.c.orig 2015-05-14 17:33:17 UTC
+++ thunar/thunar-dbus-service.c
@@ -357,6 +357,7 @@ thunar_dbus_service_connect_trash_bin (T
g_signal_connect_swapped (G_OBJECT (dbus_service->trash_bin), "changed",
G_CALLBACK (thunar_dbus_service_trash_bin_changed),
dbus_service);
+ thunar_file_reload_idle (dbus_service->trash_bin);
}
g_object_unref (trash_bin_path);
}

View File

@ -1,12 +1,60 @@
Fix Trash panel plugin (PLUG_TPA), now receives right signal (bug #11896)
--- thunar/thunar-file.c.orig 2015-05-05 17:25:29 UTC
--- thunar/thunar-file.c.orig 2015-05-16 14:25:55 UTC
+++ thunar/thunar-file.c
@@ -661,6 +661,7 @@ thunar_file_monitor_update (GFile
switch (event_type)
{
case G_FILE_MONITOR_EVENT_CREATED:
+ case G_FILE_MONITOR_EVENT_ATTRIBUTE_CHANGED:
case G_FILE_MONITOR_EVENT_CHANGES_DONE_HINT:
case G_FILE_MONITOR_EVENT_PRE_UNMOUNT:
case G_FILE_MONITOR_EVENT_DELETED:
@@ -3910,8 +3910,12 @@ thunar_file_unwatch (ThunarFile *file)
*
* You must be able to handle the case that @file is
* destroyed during the reload call.
+ *
+ * Return value: FALSE because if used as a callback function for
+ * thunar_file_reload_idle it should be automatically removed from
+ * the list of event sources so it is not called again.
**/
-void
+gboolean
thunar_file_reload (ThunarFile *file)
{
_thunar_return_if_fail (THUNAR_IS_FILE (file));
@@ -3923,12 +3927,13 @@ thunar_file_reload (ThunarFile *file)
{
/* destroy the file if we cannot query any file information */
thunar_file_destroy (file);
- return;
+ return FALSE;
}
/* ... and tell others */
thunar_file_changed (file);
-
+
+ return FALSE;
}
@@ -3952,27 +3957,6 @@ thunar_file_reload_idle (ThunarFile *fil
/**
- * thunar_file_reload_idle_timeout:
- * @file : a #ThunarFile instance.
- * @timeout : the timeout in ms after which the reload should happen
- *
- * Schedules a reload of the @file by calling thunar_file_reload in
- * idle after @timeout milliseconds have passed.
- *
- **/
-void
-thunar_file_reload_idle_timeout (ThunarFile *file,
- guint timeout)
-{
- _thunar_return_if_fail (THUNAR_IS_FILE (file));
-
- g_timeout_add_full (G_PRIORITY_DEFAULT_IDLE, timeout,
- (GSourceFunc) thunar_file_reload, file, NULL);
-}
-
-
-
-/**
* thunar_file_destroy:
* @file : a #ThunarFile instance.
*

View File

@ -0,0 +1,15 @@
--- thunar/thunar-file.h.orig 2015-05-15 16:38:08 UTC
+++ thunar/thunar-file.h
@@ -238,11 +238,8 @@ const gchar *thunar_file_get_icon_n
void thunar_file_watch (ThunarFile *file);
void thunar_file_unwatch (ThunarFile *file);
-
-void thunar_file_reload (ThunarFile *file);
+gboolean thunar_file_reload (ThunarFile *file);
void thunar_file_reload_idle (ThunarFile *file);
-void thunar_file_reload_idle_timeout (ThunarFile *file,
- guint timeout);
void thunar_file_reload_parent (ThunarFile *file);
void thunar_file_destroy (ThunarFile *file);

View File

@ -0,0 +1,12 @@
--- thunar/thunar-trash-action.c.orig 2015-05-15 08:57:43 UTC
+++ thunar/thunar-trash-action.c
@@ -88,6 +88,9 @@ thunar_trash_action_init (ThunarTrashAct
/* initially update the stock icon */
thunar_trash_action_changed (trash_action, trash_action->trash_bin);
+
+ /* schedule a reload in idle (fix for bug #9513) */
+ thunar_file_reload_idle (trash_action->trash_bin);
}
}