Commit 01e20b9d authored by George Mocanu's avatar George Mocanu Committed by Carlos Soriano Sánchez

Replace eel_show_warning_dialog()

We need to move away from using eel and port most functionalities
inside nautilus.

Replaced the usage of eel_show_warning_dialog() with the show_dialog()
alternative.

#331
parent c1bb594d
......@@ -30,8 +30,8 @@
#include "nautilus-file-operations.h"
#include "nautilus-search-directory.h"
#include "nautilus-starred-directory.h"
#include "nautilus-ui-utilities.h"
#include <eel/eel-glib-extensions.h>
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
#include <eel/eel-debug.h>
#include <eel/eel-vfs-extensions.h>
......@@ -926,9 +926,10 @@ nautilus_restore_files_from_trash (GList *files,
message = g_strdup_printf (_("Could not determine original location of “%s” "), file_name);
g_free (file_name);
eel_show_warning_dialog (message,
_("The item cannot be restored from trash"),
parent_window);
show_dialog (message,
_("The item cannot be restored from trash"),
parent_window,
GTK_MESSAGE_WARNING);
g_free (message);
}
......
......@@ -30,7 +30,6 @@
#include "nautilus-files-view.h"
#include "nautilus-application.h"
#include <eel/eel-stock-dialogs.h>
#include <eel/eel-string.h>
#include <eel/eel-vfs-extensions.h>
......@@ -39,6 +38,7 @@
#include "nautilus-clipboard.h"
#include "nautilus-dnd.h"
#include "nautilus-global-preferences.h"
#include "nautilus-ui-utilities.h"
#define GET_ANCESTOR(obj) \
GTK_WINDOW (gtk_widget_get_ancestor (GTK_WIDGET (obj), GTK_TYPE_WINDOW))
......@@ -145,9 +145,10 @@ nautilus_files_view_handle_netscape_url_drop (NautilusFilesView *view,
if (!g_file_is_native (f))
{
eel_show_warning_dialog (_("Drag and drop is not supported."),
_("Drag and drop is only supported on local file systems."),
GET_ANCESTOR (view));
show_dialog (_("Drag and drop is not supported."),
_("Drag and drop is only supported on local file systems."),
GET_ANCESTOR (view),
GTK_MESSAGE_WARNING);
g_object_unref (f);
return;
}
......@@ -185,9 +186,10 @@ nautilus_files_view_handle_netscape_url_drop (NautilusFilesView *view,
(action != GDK_ACTION_MOVE) &&
(action != GDK_ACTION_LINK))
{
eel_show_warning_dialog (_("Drag and drop is not supported."),
_("An invalid drag type was used."),
GET_ANCESTOR (view));
show_dialog (_("Drag and drop is not supported."),
_("An invalid drag type was used."),
GET_ANCESTOR (view),
GTK_MESSAGE_WARNING);
return;
}
......@@ -277,9 +279,10 @@ nautilus_files_view_handle_uri_list_drop (NautilusFilesView *view,
(action != GDK_ACTION_MOVE) &&
(action != GDK_ACTION_LINK))
{
eel_show_warning_dialog (_("Drag and drop is not supported."),
_("An invalid drag type was used."),
GET_ANCESTOR (view));
show_dialog (_("Drag and drop is not supported."),
_("An invalid drag type was used."),
GET_ANCESTOR (view),
GTK_MESSAGE_WARNING);
g_free (container_uri);
return;
}
......
......@@ -27,7 +27,6 @@
#include "nautilus-icon-info.h"
#include "nautilus-recent.h"
#include "nautilus-ui-utilities.h"
#include <eel/eel-stock-dialogs.h>
#include <gtk/gtk.h>
#include <glib/gi18n.h>
#include <gio/gio.h>
......@@ -390,10 +389,11 @@ nautilus_launch_desktop_file (GdkScreen *screen,
else if (count != total)
{
/* some files are non-local */
eel_show_warning_dialog(_("This drop target only supports local files."),
_("To open non-local files copy them to a local folder and then"
" drop them again. The local files you dropped have already been opened."),
parent_window);
show_dialog (_("This drop target only supports local files."),
_("To open non-local files copy them to a local folder and then"
" drop them again. The local files you dropped have already been opened."),
parent_window,
GTK_MESSAGE_WARNING);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment