summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libcaja-private/caja-file-operations.c2
-rw-r--r--libcaja-private/caja-global-preferences.h1
-rw-r--r--libcaja-private/org.mate.caja.gschema.xml5
3 files changed, 8 insertions, 0 deletions
diff --git a/libcaja-private/caja-file-operations.c b/libcaja-private/caja-file-operations.c
index a1172533..b76ef038 100644
--- a/libcaja-private/caja-file-operations.c
+++ b/libcaja-private/caja-file-operations.c
@@ -200,6 +200,8 @@ caja_application_notify_unmount_show (const gchar *message)
gchar **strings;
strings = g_strsplit (message, "\n", 0);
+ if (!g_settings_get_boolean (caja_preferences, CAJA_PREFERENCES_SHOW_NOTIFICATIONS)) return;
+
if (unmount_notify == NULL) {
unmount_notify =
notify_notification_new (strings[0], strings[1],
diff --git a/libcaja-private/caja-global-preferences.h b/libcaja-private/caja-global-preferences.h
index d97c7225..6fae1fc0 100644
--- a/libcaja-private/caja-global-preferences.h
+++ b/libcaja-private/caja-global-preferences.h
@@ -59,6 +59,7 @@ G_BEGIN_DECLS
/* Desktop options */
#define CAJA_PREFERENCES_DESKTOP_IS_HOME_DIR "desktop-is-home-dir"
+#define CAJA_PREFERENCES_SHOW_NOTIFICATIONS "show-notifications"
/* Display */
#define CAJA_PREFERENCES_SHOW_HIDDEN_FILES "show-hidden-files"
diff --git a/libcaja-private/org.mate.caja.gschema.xml b/libcaja-private/org.mate.caja.gschema.xml
index 0668d584..0f84f4ec 100644
--- a/libcaja-private/org.mate.caja.gschema.xml
+++ b/libcaja-private/org.mate.caja.gschema.xml
@@ -241,6 +241,11 @@
<summary>Whether to show file sizes with IEC units</summary>
<description>If set to true, file sizes are shown using IEC (base 1024) units with "KiB" style suffixes, instead of default with SI units.</description>
</key>
+ <key name="show-notifications" type="b">
+ <default>true</default>
+ <summary>Whether to show desktop notifications</summary>
+ <description>If set to true, caja will show desktop notifications for eject events</description>
+ </key>
</schema>
<schema id="org.mate.caja.icon-view" path="/org/mate/caja/icon-view/" gettext-domain="caja">