diff options
author | Christian Persch <chpe@cvs.gnome.org> | 2004-12-19 05:51:48 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2004-12-19 05:51:48 +0800 |
commit | fb964a82fd2244d91b6303853d3a49ec338b94cc (patch) | |
tree | 529320e1e933bc2a41945c51f6374818158a4898 /src | |
parent | 419bf3af0979b9d9c0bc04e0e8c02ad68bcd4dd6 (diff) | |
download | gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar.gz gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar.bz2 gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar.lz gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar.xz gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.tar.zst gsoc2013-epiphany-fb964a82fd2244d91b6303853d3a49ec338b94cc.zip |
Make sure we don't have any app-modal dialogues. Fixes bug #110479.
2004-12-18 Christian Persch <chpe@cvs.gnome.org>
* embed/mozilla/ContentHandler.cpp:
* embed/mozilla/FilePicker.cpp:
* embed/mozilla/GtkNSSClientAuthDialogs.cpp:
* embed/mozilla/GtkNSSDialogs.cpp:
* embed/mozilla/GtkNSSKeyPairDialogs.cpp:
* lib/ephy-file-chooser.c: (ephy_file_chooser_new):
* lib/ephy-gui.c: (ephy_gui_ensure_window_group),
(ephy_gui_confirm_overwrite_file):
* lib/ephy-gui.h:
* src/bookmarks/ephy-bookmarks-editor.c:
(delete_topic_dialog_construct), (ephy_bookmarks_editor_construct):
* src/ephy-window.c: (ephy_window_init):
* src/pdm-dialog.c: (show_cookies_properties):
Make sure we don't have any app-modal dialogues. Fixes bug #110479.
Diffstat (limited to 'src')
-rw-r--r-- | src/bookmarks/ephy-bookmarks-editor.c | 25 | ||||
-rw-r--r-- | src/ephy-window.c | 6 | ||||
-rwxr-xr-x | src/pdm-dialog.c | 9 |
3 files changed, 13 insertions, 27 deletions
diff --git a/src/bookmarks/ephy-bookmarks-editor.c b/src/bookmarks/ephy-bookmarks-editor.c index 556984c5a..514e51280 100644 --- a/src/bookmarks/ephy-bookmarks-editor.c +++ b/src/bookmarks/ephy-bookmarks-editor.c @@ -454,10 +454,10 @@ cmd_open_bookmarks_in_browser (GtkAction *action, } static GtkWidget* -delete_topic_dialog_construct (GtkWindow *parent, const char *topic) +delete_topic_dialog_construct (GtkWindow *parent, + const char *topic) { GtkWidget *dialog; - GtkWindowGroup *group; char *str; str = g_strdup_printf (_("Delete topic %s?"), topic); @@ -478,16 +478,7 @@ delete_topic_dialog_construct (GtkWindow *parent, const char *topic) gtk_dialog_add_button (GTK_DIALOG (dialog), _("_Delete Topic"), GTK_RESPONSE_ACCEPT); gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_CANCEL); - group = GTK_WINDOW (parent)->group; - - if (group == NULL) - { - group = gtk_window_group_new (); - gtk_window_group_add_window (group, GTK_WINDOW (parent)); - g_object_unref (group); - } - - gtk_window_group_add_window (group, GTK_WINDOW (dialog)); + gtk_window_group_add_window (GTK_WINDOW (parent)->group, GTK_WINDOW (dialog)); return dialog; } @@ -1542,17 +1533,9 @@ ephy_bookmarks_editor_construct (EphyBookmarksEditor *editor) EphyNode *node; GtkUIManager *ui_merge; GtkActionGroup *action_group; - GtkWindowGroup *group; int col_id, details_value; - /* ensure window group */ - group = GTK_WINDOW (editor)->group; - if (group == NULL) - { - group = gtk_window_group_new (); - gtk_window_group_add_window (group, GTK_WINDOW (editor)); - g_object_unref (group); - } + ephy_gui_ensure_window_group (GTK_WINDOW (editor)); gtk_window_set_title (GTK_WINDOW (editor), _("Bookmarks")); gtk_window_set_icon_name (GTK_WINDOW (editor), EPHY_STOCK_BOOKMARKS); diff --git a/src/ephy-window.c b/src/ephy-window.c index 72c3bfb20..ec33e5e48 100644 --- a/src/ephy-window.c +++ b/src/ephy-window.c @@ -2452,13 +2452,13 @@ ephy_window_init (EphyWindow *window) LOG ("EphyWindow initialising %p", window) + g_object_ref (ephy_shell); + window->priv = EPHY_WINDOW_GET_PRIVATE (window); window->priv->chrome = EPHY_EMBED_CHROME_ALL; - g_object_ref (ephy_shell); - - ensure_window_group (window); + ephy_gui_ensure_window_group (GTK_WINDOW (window)); /* Setup the UI manager and connect verbs */ setup_ui_manager (window); diff --git a/src/pdm-dialog.c b/src/pdm-dialog.c index a6dfa8c77..ec92f3b4d 100755 --- a/src/pdm-dialog.c +++ b/src/pdm-dialog.c @@ -900,8 +900,8 @@ show_cookies_properties (PdmDialog *dialog, gdialog = gtk_dialog_new_with_buttons (_("Cookie Properties"), - GTK_WINDOW(parent), - GTK_DIALOG_MODAL, + GTK_WINDOW (parent), + GTK_DIALOG_DESTROY_WITH_PARENT, GTK_STOCK_CLOSE, 0, NULL); ephy_state_add_window (GTK_WIDGET (gdialog), "cookie_properties", -1, -1, FALSE, @@ -993,7 +993,10 @@ show_cookies_properties (PdmDialog *dialog, table, FALSE, FALSE, 0); - gtk_dialog_run (GTK_DIALOG(gdialog)); + gtk_window_group_add_window (ephy_gui_ensure_window_group (GTK_WINDOW (parent)), + GTK_WINDOW (gdialog)); + + gtk_dialog_run (GTK_DIALOG (gdialog)); gtk_widget_destroy (gdialog); } |