diff pidgin/gtkrequest.c @ 21888:c88a3f2dbb52

Try to make a window transient for a suitable parent window. This currently happens only for the request and notify windows, and only when they are triggered by some GTK+ event. There are some issues when a request/notify window pops up from activating a popup menuitem. I found a fix for when the menuitem is activated by a keypress. I'll try to find a fix for a mouse-button later.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Wed, 28 Nov 2007 01:54:34 +0000
parents eb2d5ba2a50d
children 65e23b7a4398
line wrap: on
line diff
--- a/pidgin/gtkrequest.c	Wed Nov 28 00:17:27 2007 +0000
+++ b/pidgin/gtkrequest.c	Wed Nov 28 01:54:34 2007 +0000
@@ -439,6 +439,8 @@
 	pidgin_set_accessible_label (entry, label);
 	data->u.input.entry = entry;
 
+	pidgin_auto_parent_window(dialog);
+
 	/* Show everything. */
 	gtk_widget_show(dialog);
 
@@ -546,6 +548,8 @@
 	g_object_set_data(G_OBJECT(dialog), "radio", radio);
 
 	/* Show everything. */
+	pidgin_auto_parent_window(dialog);
+
 	gtk_widget_show_all(dialog);
 
 	return data;
@@ -661,6 +665,8 @@
 		gtk_dialog_set_default_response(GTK_DIALOG(dialog), default_action);
 
 	/* Show everything. */
+	pidgin_auto_parent_window(dialog);
+
 	gtk_widget_show_all(dialog);
 
 	return data;
@@ -1394,6 +1400,8 @@
 	if (!purple_request_fields_all_required_filled(fields))
 		gtk_widget_set_sensitive(button, FALSE);
 
+	pidgin_auto_parent_window(win);
+
 	gtk_widget_show(win);
 
 	return data;
@@ -1601,6 +1609,8 @@
 					 G_CALLBACK(file_ok_check_if_exists_cb), data);
 #endif /* FILECHOOSER */
 
+	pidgin_auto_parent_window(filesel);
+
 	data->dialog = filesel;
 	gtk_widget_show(filesel);
 
@@ -1652,6 +1662,8 @@
 #endif
 
 	data->dialog = dirsel;
+	pidgin_auto_parent_window(dirsel);
+
 	gtk_widget_show(dirsel);
 
 	return (void *)data;