summaryrefslogtreecommitdiff
path: root/libcaja-private
diff options
context:
space:
mode:
authorlukefromdc <[email protected]>2016-10-23 20:24:17 -0400
committerlukefromdc <[email protected]>2016-10-23 20:24:17 -0400
commit6404fa33afc5b4961fea47f8eefd07f5b4ff913a (patch)
tree4118dfcf3bf3e69d12e49b2fb360178e00ef802e /libcaja-private
parent30b7ce2e63080fca1db9bdf2dd82955ce7ad2cc7 (diff)
downloadcaja-6404fa33afc5b4961fea47f8eefd07f5b4ff913a.tar.bz2
caja-6404fa33afc5b4961fea47f8eefd07f5b4ff913a.tar.xz
libunique builds: enable eject notifications
We no longer need to use any GtkApplication features for this so enable it in libunique builds too. Tested with and without libunique in GTK 3.22
Diffstat (limited to 'libcaja-private')
-rw-r--r--libcaja-private/caja-file-operations.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/libcaja-private/caja-file-operations.c b/libcaja-private/caja-file-operations.c
index 705a25b9..a1172533 100644
--- a/libcaja-private/caja-file-operations.c
+++ b/libcaja-private/caja-file-operations.c
@@ -55,9 +55,7 @@
#include <gtk/gtk.h>
#include <gio/gio.h>
#include <glib.h>
-#if ENABLE_LIBUNIQUE == (FALSE)
#include <libnotify/notify.h>
-#endif
#include "caja-file-changes-queue.h"
#include "caja-file-private.h"
#include "caja-desktop-icon-file.h"
@@ -195,7 +193,7 @@ typedef struct {
#define COPY_FORCE _("Copy _Anyway")
NotifyNotification *unmount_notify;
-#if ENABLE_LIBUNIQUE == (FALSE)
+
void
caja_application_notify_unmount_show (const gchar *message)
{
@@ -220,7 +218,7 @@ caja_application_notify_unmount_show (const gchar *message)
notify_notification_show (unmount_notify, NULL);
g_strfreev (strings);
}
-#endif
+
static void
mark_desktop_file_trusted (CommonJob *common,
GCancellable *cancellable,
@@ -2099,9 +2097,9 @@ unmount_mount_callback (GObject *source_object,
if (error != NULL) {
g_error_free (error);
}
-#if ENABLE_LIBUNIQUE == (FALSE)
+
caja_application_notify_unmount_show ("It is now safe to remove the drive");
-#endif
+
eel_remove_weak_pointer (&data->parent_window);
g_object_unref (data->mount);
g_free (data);
@@ -2120,9 +2118,9 @@ do_unmount (UnmountData *data)
NULL,
unmount_mount_callback,
data);
-#if ENABLE_LIBUNIQUE == (FALSE)
+
caja_application_notify_unmount_show ("writing data to the drive-do not unplug");
-#endif
+
} else {
g_mount_unmount_with_operation (data->mount,
0,