summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArvind Samptur <arvind.samptur@wipro.com>2003-02-17 09:20:56 +0000
committerArvind Samptur <arvind@src.gnome.org>2003-02-17 09:20:56 +0000
commit14e2c3764f7968dfc28abe0c8118bded4e70413f (patch)
treece32dee0631f174a7a022ef5b2fcccfe004437a1
parent9afb72f2bb881a630fb388635c9d7d922f503e56 (diff)
downloadnautilus-14e2c3764f7968dfc28abe0c8118bded4e70413f.tar.gz
Multi-head stuff done for the preferences dialog.
2003-02-17 Arvind Samptur <arvind.samptur@wipro.com> * src/nautilus-file-management-properties.[ch]: (nautilus_file_management_properties_dialog_setup): (nautilus_file_management_properties_dialog_show): * src/nautilus-window-menus.c: (preferences_callback): * src/nautilus-file-management-properties-main.c: (main): Multi-head stuff done for the preferences dialog. * libnautilus-private/nautilus-icon-dnd.c: (confirm_switch_to_manual_layout) Get the transient parent for the "Switch to Manual Layout ?" right. Patches approved by Dave Camp. #100343 and #106086.
-rw-r--r--ChangeLog16
-rw-r--r--libnautilus-private/nautilus-icon-dnd.c5
-rw-r--r--src/nautilus-file-management-properties-main.c2
-rw-r--r--src/nautilus-file-management-properties.c13
-rw-r--r--src/nautilus-file-management-properties.h3
-rw-r--r--src/nautilus-navigation-window-menus.c2
-rw-r--r--src/nautilus-window-menus.c2
7 files changed, 32 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index 9c5e8086a..1fe2790c8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+2003-02-17 Arvind Samptur <arvind.samptur@wipro.com>
+ * src/nautilus-file-management-properties.[ch]:
+ (nautilus_file_management_properties_dialog_setup):
+ (nautilus_file_management_properties_dialog_show):
+ * src/nautilus-window-menus.c:
+ (preferences_callback):
+ * src/nautilus-file-management-properties-main.c:
+ (main):
+
+ Multi-head stuff done for the preferences dialog.
+
+ * libnautilus-private/nautilus-icon-dnd.c: (confirm_switch_to_manual_layout)
+ Get the transient parent for the "Switch to Manual Layout ?" right.
+
+ Patches approved by Dave Camp. #100343 and #106086.
+
2003-02-13 Alexander Larsson <alexl@redhat.com>
* libnautilus-private/nautilus-thumbnails.c (thumbnail_thread_start):
diff --git a/libnautilus-private/nautilus-icon-dnd.c b/libnautilus-private/nautilus-icon-dnd.c
index d384ae063..9272748a3 100644
--- a/libnautilus-private/nautilus-icon-dnd.c
+++ b/libnautilus-private/nautilus-icon-dnd.c
@@ -744,9 +744,8 @@ confirm_switch_to_manual_layout (NautilusIconContainer *container)
dialog = eel_show_yes_no_dialog (message, _("Switch to Manual Layout?"),
_("Switch"), GTK_STOCK_CANCEL,
- GTK_WINDOW (gtk_widget_get_ancestor
- (GTK_WIDGET (container), GTK_TYPE_WINDOW)));
-
+ GTK_WINDOW (gtk_widget_get_toplevel(GTK_WIDGET(container))));
+
response = gtk_dialog_run (dialog);
gtk_object_destroy (GTK_OBJECT (dialog));
diff --git a/src/nautilus-file-management-properties-main.c b/src/nautilus-file-management-properties-main.c
index c79c4650f..607c24818 100644
--- a/src/nautilus-file-management-properties-main.c
+++ b/src/nautilus-file-management-properties-main.c
@@ -58,7 +58,7 @@ main (int argc, char *argv[])
eel_preferences_init ("/apps/nautilus");
- nautilus_file_management_properties_dialog_show (G_CALLBACK (nautilus_file_management_properties_main_close_callback));
+ nautilus_file_management_properties_dialog_show (G_CALLBACK (nautilus_file_management_properties_main_close_callback), NULL);
gtk_main ();
diff --git a/src/nautilus-file-management-properties.c b/src/nautilus-file-management-properties.c
index 769d351ac..017347596 100644
--- a/src/nautilus-file-management-properties.c
+++ b/src/nautilus-file-management-properties.c
@@ -282,8 +282,8 @@ nautilus_file_management_properties_dialog_response_cb (GtkDialog *parent,
}
}
-static void
-nautilus_file_management_properties_dialog_setup (GladeXML *xml_dialog)
+static void
+nautilus_file_management_properties_dialog_setup (GladeXML *xml_dialog, GtkWindow *window)
{
GtkWidget *dialog;
@@ -407,11 +407,16 @@ nautilus_file_management_properties_dialog_setup (GladeXML *xml_dialog)
xml_dialog);
nautilus_file_management_properties_dialog_set_icons (GTK_WINDOW (dialog));
+
+ if (window) {
+ gtk_window_set_screen (GTK_WINDOW (dialog), gtk_window_get_screen(window));
+ }
+
gtk_widget_show (dialog);
}
void
-nautilus_file_management_properties_dialog_show (GCallback close_callback)
+nautilus_file_management_properties_dialog_show (GCallback close_callback, GtkWindow *window)
{
GladeXML *xml_dialog;
@@ -420,5 +425,5 @@ nautilus_file_management_properties_dialog_show (GCallback close_callback)
g_signal_connect (G_OBJECT (glade_xml_get_widget (xml_dialog, "file_management_dialog")),
"response", close_callback, NULL);
- nautilus_file_management_properties_dialog_setup (xml_dialog);
+ nautilus_file_management_properties_dialog_setup (xml_dialog, window);
}
diff --git a/src/nautilus-file-management-properties.h b/src/nautilus-file-management-properties.h
index 556fdbf99..7baff45dc 100644
--- a/src/nautilus-file-management-properties.h
+++ b/src/nautilus-file-management-properties.h
@@ -26,10 +26,11 @@
#define NAUTILUS_FILE_MANAGEMENT_PROPERTIES_H
#include <glib-object.h>
+#include <gtk/gtkwindow.h>
G_BEGIN_DECLS
-void nautilus_file_management_properties_dialog_show (GCallback close_callback);
+void nautilus_file_management_properties_dialog_show (GCallback close_callback, GtkWindow *window);
G_END_DECLS
diff --git a/src/nautilus-navigation-window-menus.c b/src/nautilus-navigation-window-menus.c
index f125da5af..0df5b9ed5 100644
--- a/src/nautilus-navigation-window-menus.c
+++ b/src/nautilus-navigation-window-menus.c
@@ -583,7 +583,7 @@ preferences_callback (BonoboUIComponent *component,
window = GTK_WINDOW (user_data);
- nautilus_file_management_properties_dialog_show (G_CALLBACK (preferences_respond_callback));
+ nautilus_file_management_properties_dialog_show (G_CALLBACK (preferences_respond_callback), window);
}
static void
diff --git a/src/nautilus-window-menus.c b/src/nautilus-window-menus.c
index f125da5af..0df5b9ed5 100644
--- a/src/nautilus-window-menus.c
+++ b/src/nautilus-window-menus.c
@@ -583,7 +583,7 @@ preferences_callback (BonoboUIComponent *component,
window = GTK_WINDOW (user_data);
- nautilus_file_management_properties_dialog_show (G_CALLBACK (preferences_respond_callback));
+ nautilus_file_management_properties_dialog_show (G_CALLBACK (preferences_respond_callback), window);
}
static void