[Pkg-xfce-commits] r2211 - in desktop/trunk: thunar/debian thunar/debian/patches xfdesktop4/debian xfdesktop4/debian/patches

corsac at alioth.debian.org corsac at alioth.debian.org
Wed Aug 13 21:00:55 UTC 2008


Author: corsac
Date: 2008-08-13 21:00:54 +0000 (Wed, 13 Aug 2008)
New Revision: 2211

Removed:
   desktop/trunk/thunar/debian/patches/06_support-encrypted-volumes.patch
   desktop/trunk/xfdesktop4/debian/patches/08_handle-crypto-fs.patch
Modified:
   desktop/trunk/thunar/debian/changelog
   desktop/trunk/xfdesktop4/debian/changelog
Log:
no need for thunar and xfdesktop patches anymore


Modified: desktop/trunk/thunar/debian/changelog
===================================================================
--- desktop/trunk/thunar/debian/changelog	2008-08-13 21:00:18 UTC (rev 2210)
+++ desktop/trunk/thunar/debian/changelog	2008-08-13 21:00:54 UTC (rev 2211)
@@ -1,18 +1,10 @@
 thunar (0.9.0-11) UNRELEASED; urgency=low
 
-  * debian/patches:
-    - 06_support-encrypted-volumes added, by Colin Leroy. Handle encrypted
-      volumes and enable mounting them from thunar.
   * debian/control:
     - updated standards version to 3.8.0. No change needed.
-    - update build-dep on exo with luks support.
 
-WARNING: The patch introduces a soname bump, which mean package renaming and
-the like. No upload before we have an upstream comment on the bug
-(http://bugzilla.xfce.org/show_bug.cgi?id=3349).
+ -- Yves-Alexis Perez <corsac at debian.org>  Tue, 12 Aug 2008 22:02:38 +0200
 
- -- Yves-Alexis Perez <corsac at debian.org>  Mon, 09 Jun 2008 17:37:22 +0200
-
 thunar (0.9.0-10) unstable; urgency=low
 
   * -dev package doesn't need to depend on exo-utils, thunar does.

Deleted: desktop/trunk/thunar/debian/patches/06_support-encrypted-volumes.patch
===================================================================
--- desktop/trunk/thunar/debian/patches/06_support-encrypted-volumes.patch	2008-08-13 21:00:18 UTC (rev 2210)
+++ desktop/trunk/thunar/debian/patches/06_support-encrypted-volumes.patch	2008-08-13 21:00:54 UTC (rev 2211)
@@ -1,380 +0,0 @@
-Index: thunar/thunar-shortcuts-view.c
-===================================================================
---- thunar/thunar-shortcuts-view.c	(revision 27044)
-+++ thunar/thunar-shortcuts-view.c	(working copy)
-@@ -828,14 +828,19 @@
-   if (G_UNLIKELY (volume != NULL))
-     {
-       /* append the "Mount Volume" menu action */
--      item = gtk_image_menu_item_new_with_mnemonic (_("_Mount Volume"));
--      gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_mounted (volume));
-+      if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+        item = gtk_image_menu_item_new_with_mnemonic (_("_Setup crypto layer"));
-+        gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_crypto_setup (volume));
-+      } else {
-+        item = gtk_image_menu_item_new_with_mnemonic (_("_Mount Volume"));
-+        gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_mounted (volume));
-+      }
-       g_signal_connect_swapped (G_OBJECT (item), "activate", G_CALLBACK (thunar_shortcuts_view_mount), view);
-       gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-       gtk_widget_show (item);
- 
-       /* check if the volume is ejectable */
--      if (thunar_vfs_volume_is_ejectable (volume))
-+      if (thunar_vfs_volume_is_ejectable (volume) && !thunar_vfs_volume_is_crypto(volume))
-         {
-           /* append the "Eject Volume" menu action */
-           item = gtk_image_menu_item_new_with_mnemonic (_("E_ject Volume"));
-@@ -846,8 +851,13 @@
-       else
-         {
-           /* append the "Unmount Volume" menu item */
--          item = gtk_image_menu_item_new_with_mnemonic (_("_Unmount Volume"));
--          gtk_widget_set_sensitive (item, thunar_vfs_volume_is_mounted (volume));
-+	  if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+            item = gtk_image_menu_item_new_with_mnemonic (_("_Teardown crypto layer"));
-+            gtk_widget_set_sensitive (item, thunar_vfs_volume_is_crypto_setup (volume));
-+	  } else {
-+            item = gtk_image_menu_item_new_with_mnemonic (_("_Unmount Volume"));
-+            gtk_widget_set_sensitive (item, thunar_vfs_volume_is_mounted (volume));
-+	  }
-           g_signal_connect_swapped (G_OBJECT (item), "activate", G_CALLBACK (thunar_shortcuts_view_unmount), view);
-           gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-           gtk_widget_show (item);
-Index: thunar/thunar-tree-view.c
-===================================================================
---- thunar/thunar-tree-view.c	(revision 27044)
-+++ thunar/thunar-tree-view.c	(working copy)
-@@ -1035,14 +1035,19 @@
-   if (G_UNLIKELY (volume != NULL))
-     {
-       /* append the "Mount Volume" menu action */
--      item = gtk_image_menu_item_new_with_mnemonic (_("_Mount Volume"));
--      gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_mounted (volume));
-+      if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+        item = gtk_image_menu_item_new_with_mnemonic (_("_Setup crypto layer"));
-+        gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_crypto_setup (volume));
-+      } else {
-+        item = gtk_image_menu_item_new_with_mnemonic (_("_Mount Volume"));
-+        gtk_widget_set_sensitive (item, !thunar_vfs_volume_is_mounted (volume));
-+      }
-       g_signal_connect_swapped (G_OBJECT (item), "activate", G_CALLBACK (thunar_tree_view_action_mount), view);
-       gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-       gtk_widget_show (item);
- 
-       /* check if the volume is ejectable */
--      if (thunar_vfs_volume_is_ejectable (volume))
-+      if (thunar_vfs_volume_is_ejectable (volume) && !thunar_vfs_volume_is_crypto(volume))
-         {
-           /* append the "Eject Volume" menu action */
-           item = gtk_image_menu_item_new_with_mnemonic (_("E_ject Volume"));
-@@ -1053,8 +1058,13 @@
-       else
-         {
-           /* append the "Unmount Volume" menu item */
--          item = gtk_image_menu_item_new_with_mnemonic (_("_Unmount Volume"));
--          gtk_widget_set_sensitive (item, thunar_vfs_volume_is_mounted (volume));
-+	  if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+            item = gtk_image_menu_item_new_with_mnemonic (_("_Teardown crypto layer"));
-+            gtk_widget_set_sensitive (item, thunar_vfs_volume_is_crypto_setup (volume));
-+	  } else {
-+            item = gtk_image_menu_item_new_with_mnemonic (_("_Unmount Volume"));
-+            gtk_widget_set_sensitive (item, thunar_vfs_volume_is_mounted (volume));
-+	  }
-           g_signal_connect_swapped (G_OBJECT (item), "activate", G_CALLBACK (thunar_tree_view_action_unmount), view);
-           gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-           gtk_widget_show (item);
-Index: thunar-vfs/thunar-vfs-volume-hal.c
-===================================================================
---- thunar-vfs/thunar-vfs-volume-hal.c	(revision 27044)
-+++ thunar-vfs/thunar-vfs-volume-hal.c	(working copy)
-@@ -54,6 +54,8 @@
- static ThunarVfsVolumeStatus thunar_vfs_volume_hal_get_status               (ThunarVfsVolume          *volume);
- static ThunarVfsPath        *thunar_vfs_volume_hal_get_mount_point          (ThunarVfsVolume          *volume);
- static gboolean              thunar_vfs_volume_hal_is_ejectable             (ThunarVfsVolume          *volume);
-+static gboolean              thunar_vfs_volume_hal_is_crypto                (ThunarVfsVolume          *volume);
-+static gboolean              thunar_vfs_volume_hal_is_crypto_setup          (ThunarVfsVolume          *volume);
- static const gchar          *thunar_vfs_volume_hal_lookup_icon_name         (ThunarVfsVolume          *volume,
-                                                                              GtkIconTheme             *icon_theme);
- static gboolean              thunar_vfs_volume_hal_eject                    (ThunarVfsVolume          *volume,
-@@ -71,9 +73,9 @@
-                                                                              LibHalContext            *context,
-                                                                              LibHalVolume             *hv,
-                                                                              LibHalDrive              *hd);
-+static LibHalContext        *thunar_vfs_volume_manager_hal_get_hal_context  (ThunarVfsVolumeManagerHal *manager_hal);
- 
- 
--
- struct _ThunarVfsVolumeHalClass
- {
-   ThunarVfsVolumeClass __parent__;
-@@ -142,6 +144,8 @@
-   thunarvfs_volume_class->get_status = thunar_vfs_volume_hal_get_status;
-   thunarvfs_volume_class->get_mount_point = thunar_vfs_volume_hal_get_mount_point;
-   thunarvfs_volume_class->is_ejectable = thunar_vfs_volume_hal_is_ejectable;
-+  thunarvfs_volume_class->is_crypto = thunar_vfs_volume_hal_is_crypto;
-+  thunarvfs_volume_class->is_crypto_setup = thunar_vfs_volume_hal_is_crypto_setup;
-   thunarvfs_volume_class->lookup_icon_name = thunar_vfs_volume_hal_lookup_icon_name;
-   thunarvfs_volume_class->eject = thunar_vfs_volume_hal_eject;
-   thunarvfs_volume_class->mount = thunar_vfs_volume_hal_mount;
-@@ -216,7 +220,49 @@
- }
- 
- 
-+static gboolean
-+thunar_vfs_volume_hal_is_crypto (ThunarVfsVolume *volume)
-+{
-+  return THUNAR_VFS_VOLUME_HAL (volume)->kind == THUNAR_VFS_VOLUME_KIND_CRYPTO;
-+}
- 
-+static gboolean
-+thunar_vfs_volume_hal_is_crypto_setup (ThunarVfsVolume *volume)
-+{
-+  ThunarVfsVolumeManager *manager = NULL;
-+  LibHalContext *hal_context = NULL;
-+  LibHalVolume *hal_volume = NULL;
-+  gchar *plain_udi = NULL;
-+
-+  if (THUNAR_VFS_VOLUME_HAL (volume)->kind != THUNAR_VFS_VOLUME_KIND_CRYPTO)
-+    return FALSE;
-+
-+  manager = thunar_vfs_volume_manager_get_default();
-+  g_return_val_if_fail(manager != NULL, FALSE);
-+  
-+  if (!THUNAR_VFS_IS_VOLUME_MANAGER_HAL(manager))
-+    return FALSE;
-+
-+  hal_context = thunar_vfs_volume_manager_hal_get_hal_context(THUNAR_VFS_VOLUME_MANAGER_HAL(manager));
-+  g_return_val_if_fail(hal_context != NULL, FALSE);
-+  
-+  hal_volume = libhal_volume_from_udi(hal_context, THUNAR_VFS_VOLUME_HAL (volume)->udi);
-+  g_return_val_if_fail(hal_volume != NULL, FALSE);
-+
-+  plain_udi = libhal_volume_crypto_get_clear_volume_udi(hal_context, hal_volume);
-+
-+  libhal_volume_free(hal_volume);
-+  g_object_unref(manager);
-+  if (plain_udi) {
-+    g_free(plain_udi);
-+    return TRUE;
-+  }
-+  return FALSE;
-+}
-+
-+
-+
-+
- static const gchar*
- thunar_vfs_volume_hal_lookup_icon_name (ThunarVfsVolume *volume,
-                                         GtkIconTheme    *icon_theme)
-@@ -282,25 +328,28 @@
-   if (G_LIKELY (result))
-     {
-       /* try to figure out where the device was mounted */
--      path = thunar_vfs_volume_hal_find_active_mount_point (volume_hal);
--      if (G_LIKELY (path != NULL))
-+      if (volume_hal->kind != THUNAR_VFS_VOLUME_KIND_CRYPTO)
-         {
--          /* we must have been mounted successfully */
--          volume_hal->status |= THUNAR_VFS_VOLUME_STATUS_MOUNTED | THUNAR_VFS_VOLUME_STATUS_PRESENT;
-+	  path = thunar_vfs_volume_hal_find_active_mount_point (volume_hal);
-+	  if (G_LIKELY (path != NULL))
-+            {
-+              /* we must have been mounted successfully */
-+              volume_hal->status |= THUNAR_VFS_VOLUME_STATUS_MOUNTED | THUNAR_VFS_VOLUME_STATUS_PRESENT;
- 
--          /* replace the existing mount point */
--          thunar_vfs_path_unref (volume_hal->mount_point);
--          volume_hal->mount_point = path;
-+              /* replace the existing mount point */
-+              thunar_vfs_path_unref (volume_hal->mount_point);
-+              volume_hal->mount_point = path;
- 
--          /* tell everybody that we have a new state */
--          thunar_vfs_volume_changed (THUNAR_VFS_VOLUME (volume_hal));
--        }
--      else
--        {
--          /* something went wrong, for sure */
--          g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED, _("Failed to determine the mount point for %s"), volume_hal->device_file);
--          result = FALSE;
--        }
-+              /* tell everybody that we have a new state */
-+              thunar_vfs_volume_changed (THUNAR_VFS_VOLUME (volume_hal));
-+            }
-+	  else
-+            {
-+              /* something went wrong, for sure */
-+              g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED, _("Failed to determine the mount point for %s"), volume_hal->device_file);
-+              result = FALSE;
-+            }
-+	}
-     }
- 
-   return result;
-@@ -326,7 +375,7 @@
-   if (G_LIKELY (result))
-     {
-       /* reset the status */
--      volume_hal->status &= ~THUNAR_VFS_VOLUME_STATUS_MOUNTED;
-+      volume_hal->status &= ~(THUNAR_VFS_VOLUME_STATUS_MOUNTED);
- 
-       /* emit "changed" on the volume */
-       thunar_vfs_volume_changed (THUNAR_VFS_VOLUME (volume_hal));
-@@ -359,7 +408,6 @@
-       g_slist_foreach (mount_points, (GFunc) exo_mount_point_free, NULL);
-       g_slist_free (mount_points);
-     }
--
-   return mount_point;
- }
- 
-@@ -541,6 +589,10 @@
-   if(hv != NULL && libhal_volume_get_fsusage (hv) == LIBHAL_VOLUME_USAGE_MOUNTABLE_FILESYSTEM)
-     volume_hal->status |= THUNAR_VFS_VOLUME_STATUS_MOUNTABLE;
- 
-+  /* force the type to CRYPTO if necessary */
-+  if (libhal_volume_get_fsusage (hv) == LIBHAL_VOLUME_USAGE_CRYPTO)
-+    volume_hal->kind = THUNAR_VFS_VOLUME_KIND_CRYPTO;
-+
-   /* check if the drive requires eject */
-   volume_hal->requires_eject = libhal_drive_requires_eject (hd);
- 
-@@ -686,6 +738,12 @@
- }
- 
- 
-+static LibHalContext *
-+thunar_vfs_volume_manager_hal_get_hal_context (ThunarVfsVolumeManagerHal *manager)
-+{
-+  g_return_val_if_fail(manager != NULL, NULL);
-+  return manager->context;
-+}
- 
- static void
- thunar_vfs_volume_manager_hal_class_init (ThunarVfsVolumeManagerHalClass *klass)
-@@ -1019,7 +1077,8 @@
-   if (G_LIKELY (hv != NULL))
-     {
-       /* check if we have a mountable file system here */
--      if (libhal_volume_get_fsusage (hv) == LIBHAL_VOLUME_USAGE_MOUNTABLE_FILESYSTEM)
-+      if (libhal_volume_get_fsusage (hv) == LIBHAL_VOLUME_USAGE_MOUNTABLE_FILESYSTEM
-+       || libhal_volume_get_fsusage (hv) == LIBHAL_VOLUME_USAGE_CRYPTO)
-         {
-           /* determine the UDI of the drive to which this volume belongs */
-           drive_udi = libhal_volume_get_storage_device_udi (hv);
-Index: thunar-vfs/thunar-vfs-volume.c
-===================================================================
---- thunar-vfs/thunar-vfs-volume.c	(revision 27044)
-+++ thunar-vfs/thunar-vfs-volume.c	(working copy)
-@@ -318,8 +318,46 @@
- }
- 
- 
-+/**
-+ * thunar_vfs_volume_is_crypto:
-+ * @volume : a #ThunarVfsVolume instance.
-+ *
-+ * Determines whether @volume is a crypto container
-+ *
-+ * Return value: whether @volume can is a crypto container.
-+ **/
-+gboolean
-+thunar_vfs_volume_is_crypto (ThunarVfsVolume *volume)
-+{
-+  g_return_val_if_fail (THUNAR_VFS_IS_VOLUME (volume), FALSE);
-+  if (*THUNAR_VFS_VOLUME_GET_CLASS (volume)->is_crypto)
-+    return (*THUNAR_VFS_VOLUME_GET_CLASS (volume)->is_crypto) (volume);
-+  else
-+    return FALSE;
-+}
- 
-+
- /**
-+ * thunar_vfs_volume_is_crypto:
-+ * @volume : a #ThunarVfsVolume instance.
-+ *
-+ * Determines whether @volume is a crypto container
-+ *
-+ * Return value: whether @volume can is a crypto container.
-+ **/
-+gboolean
-+thunar_vfs_volume_is_crypto_setup (ThunarVfsVolume *volume)
-+{
-+  g_return_val_if_fail (THUNAR_VFS_IS_VOLUME (volume), FALSE);
-+  if (*THUNAR_VFS_VOLUME_GET_CLASS (volume)->is_crypto_setup)
-+    return (*THUNAR_VFS_VOLUME_GET_CLASS (volume)->is_crypto_setup) (volume);
-+  else
-+    return FALSE;
-+}
-+
-+
-+
-+/**
-  * thunar_vfs_volume_is_removable:
-  * @volume : a #ThunarVfsVolume instance.
-  *
-@@ -354,6 +392,7 @@
-     case THUNAR_VFS_VOLUME_KIND_AUDIO_CD:
-     case THUNAR_VFS_VOLUME_KIND_MEMORY_CARD:
-     case THUNAR_VFS_VOLUME_KIND_REMOVABLE_DISK:
-+    case THUNAR_VFS_VOLUME_KIND_CRYPTO:
-       return TRUE;
- 
-     default:
-Index: thunar-vfs/thunar-vfs-volume.h
-===================================================================
---- thunar-vfs/thunar-vfs-volume.h	(revision 27044)
-+++ thunar-vfs/thunar-vfs-volume.h	(working copy)
-@@ -56,6 +56,7 @@
-  * @THUNAR_VFS_VOLUME_KIND_AUDIO_CD       : Audio CDs.
-  * @THUNAR_VFS_VOLUME_KIND_MEMORY_CARD    : Memory cards.
-  * @THUNAR_VFS_VOLUME_KIND_REMOVABLE_DISK : Other removable disks.
-+ * @THUNAR_VFS_VOLUME_KIND_CRYPTO         : Crypto fs container.
-  *
-  * Describes the type of a VFS volume.
-  **/
-@@ -78,6 +79,7 @@
-   THUNAR_VFS_VOLUME_KIND_AUDIO_CD,
-   THUNAR_VFS_VOLUME_KIND_MEMORY_CARD,
-   THUNAR_VFS_VOLUME_KIND_REMOVABLE_DISK,
-+  THUNAR_VFS_VOLUME_KIND_CRYPTO,
- } ThunarVfsVolumeKind;
- 
- /**
-@@ -90,9 +92,9 @@
-  **/
- typedef enum /*< flags >*/
- {
--  THUNAR_VFS_VOLUME_STATUS_MOUNTED   = 1 << 0,
--  THUNAR_VFS_VOLUME_STATUS_PRESENT   = 1 << 1,
--  THUNAR_VFS_VOLUME_STATUS_MOUNTABLE = 1 << 2,
-+  THUNAR_VFS_VOLUME_STATUS_MOUNTED      = 1 << 0,
-+  THUNAR_VFS_VOLUME_STATUS_PRESENT      = 1 << 1,
-+  THUNAR_VFS_VOLUME_STATUS_MOUNTABLE    = 1 << 2,
- } ThunarVfsVolumeStatus;
- 
- GType                 thunar_vfs_volume_get_type          (void) G_GNUC_CONST;
-@@ -109,6 +111,9 @@
- gboolean              thunar_vfs_volume_is_ejectable      (ThunarVfsVolume   *volume);
- gboolean              thunar_vfs_volume_is_removable      (ThunarVfsVolume   *volume);
- 
-+gboolean              thunar_vfs_volume_is_crypto         (ThunarVfsVolume   *volume);
-+gboolean              thunar_vfs_volume_is_crypto_setup   (ThunarVfsVolume   *volume);
-+
- const gchar          *thunar_vfs_volume_lookup_icon_name  (ThunarVfsVolume   *volume,
-                                                            GtkIconTheme      *icon_theme);
- 
-Index: thunar-vfs/thunar-vfs-volume-private.h
-===================================================================
---- thunar-vfs/thunar-vfs-volume-private.h	(revision 27044)
-+++ thunar-vfs/thunar-vfs-volume-private.h	(working copy)
-@@ -56,6 +56,8 @@
-   void                  (*mounted)          (ThunarVfsVolume   *volume);
-   void                  (*pre_unmount)      (ThunarVfsVolume   *volume);
-   void                  (*unmounted)        (ThunarVfsVolume   *volume);
-+  gboolean              (*is_crypto)        (ThunarVfsVolume   *volume);
-+  gboolean              (*is_crypto_setup)  (ThunarVfsVolume   *volume);
- };
- 
- struct _ThunarVfsVolume

Modified: desktop/trunk/xfdesktop4/debian/changelog
===================================================================
--- desktop/trunk/xfdesktop4/debian/changelog	2008-08-13 21:00:18 UTC (rev 2210)
+++ desktop/trunk/xfdesktop4/debian/changelog	2008-08-13 21:00:54 UTC (rev 2211)
@@ -2,15 +2,11 @@
 
   * debian/patches:
     - 07_fix-italian-typos added, thanks David Paleino.         closes: #483709
-    - 08_handle-crypto-fs added, manage luks encrypted filesystems.
   * debian/control:
     - updated standards version to 3.8.0. No change needed.
-    - updated build deps on a luks-enabled exo.
 
-WARNING: this version depends on a luks-enabled exo, no yet uploaded.
+ -- Yves-Alexis Perez <corsac at debian.org>  Tue, 12 Aug 2008 22:03:52 +0200
 
- -- Yves-Alexis Perez <corsac at debian.org>  Mon, 09 Jun 2008 17:44:21 +0200
-
 xfdesktop4 (4.4.2-7) unstable; urgency=low
 
   * switch to triggers:

Deleted: desktop/trunk/xfdesktop4/debian/patches/08_handle-crypto-fs.patch
===================================================================
--- desktop/trunk/xfdesktop4/debian/patches/08_handle-crypto-fs.patch	2008-08-13 21:00:18 UTC (rev 2210)
+++ desktop/trunk/xfdesktop4/debian/patches/08_handle-crypto-fs.patch	2008-08-13 21:00:54 UTC (rev 2211)
@@ -1,52 +0,0 @@
-Index: src/xfdesktop-volume-icon.c
-===================================================================
---- src/xfdesktop-volume-icon.c	(revision 27044)
-+++ src/xfdesktop-volume-icon.c	(working copy)
-@@ -568,27 +568,31 @@
-     gtk_widget_show(mi);
-     gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
-     
--    mi = gtk_image_menu_item_new_with_mnemonic(_("_Mount Volume"));
-+    if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+      mi = gtk_image_menu_item_new_with_mnemonic(_("_Setup crypto layer"));
-+      gtk_widget_set_sensitive(mi, !thunar_vfs_volume_is_crypto_setup(volume));
-+    } else {
-+      mi = gtk_image_menu_item_new_with_mnemonic(_("_Mount Volume"));
-+      gtk_widget_set_sensitive(mi, !thunar_vfs_volume_is_mounted(volume));
-+    }
-     gtk_widget_show(mi);
-     gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
--    if(thunar_vfs_volume_is_mounted(volume))
--        gtk_widget_set_sensitive(mi, FALSE);
--    else {
--        g_signal_connect(G_OBJECT(mi), "activate",
--                         G_CALLBACK(xfdesktop_volume_icon_menu_toggle_mount),
--                         icon);
-+    g_signal_connect(G_OBJECT(mi), "activate",
-+                     G_CALLBACK(xfdesktop_volume_icon_menu_toggle_mount),
-+                     icon);
-+    
-+    if (G_UNLIKELY(thunar_vfs_volume_is_crypto(volume))) {
-+      mi = gtk_image_menu_item_new_with_mnemonic(_("_Teardown crypto layer"));
-+      gtk_widget_set_sensitive(mi, thunar_vfs_volume_is_crypto_setup(volume));
-+    } else {
-+      mi = gtk_image_menu_item_new_with_mnemonic(_("_Unmount Volume"));
-+      gtk_widget_set_sensitive(mi, thunar_vfs_volume_is_mounted(volume));
-     }
--    
--    mi = gtk_image_menu_item_new_with_mnemonic(_("_Unmount Volume"));
-     gtk_widget_show(mi);
-     gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
--    if(!thunar_vfs_volume_is_mounted(volume))
--        gtk_widget_set_sensitive(mi, FALSE);
--    else {
--        g_signal_connect(G_OBJECT(mi), "activate",
--                         G_CALLBACK(xfdesktop_volume_icon_menu_toggle_mount),
--                         icon);
--    }
-+    g_signal_connect(G_OBJECT(mi), "activate",
-+                     G_CALLBACK(xfdesktop_volume_icon_menu_toggle_mount),
-+                     icon);
-     
-     if(thunar_vfs_volume_is_disc(volume)
-        && thunar_vfs_volume_is_ejectable(volume))




More information about the Pkg-xfce-commits mailing list