aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/EphyPromptService.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@src.gnome.org>2008-02-18 21:40:59 +0800
committerChristian Persch <chpe@src.gnome.org>2008-02-18 21:40:59 +0800
commitb3924f2a5509596645492d232c9b3dcf1ad35965 (patch)
treec05f7f1fea2ddbf17d10a9e2edc05b043e537104 /embed/mozilla/EphyPromptService.cpp
parent72305c8033e66e792bde1060b7d7377935cedfb4 (diff)
downloadgsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar.gz
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar.bz2
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar.lz
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar.xz
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.tar.zst
gsoc2013-epiphany-b3924f2a5509596645492d232c9b3dcf1ad35965.zip
Fix prompt service for xr 1.9 wrt. DOM notifications. Bug #504445.
svn path=/trunk/; revision=7967
Diffstat (limited to 'embed/mozilla/EphyPromptService.cpp')
-rw-r--r--embed/mozilla/EphyPromptService.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/embed/mozilla/EphyPromptService.cpp b/embed/mozilla/EphyPromptService.cpp
index 29813f300..915649aea 100644
--- a/embed/mozilla/EphyPromptService.cpp
+++ b/embed/mozilla/EphyPromptService.cpp
@@ -36,8 +36,7 @@
#include "ephy-gui.h"
#include "ephy-debug.h"
-#include "AutoJSContextStack.h"
-#include "AutoWindowModalState.h"
+#include "AutoModalDialog.h"
#include "EphyUtils.h"
#include "EphyPromptService.h"
@@ -470,12 +469,9 @@ Prompter::Run (PRBool *aSuccess)
}
#endif
- nsresult rv;
- AutoJSContextStack stack;
- rv = stack.Init ();
- if (NS_FAILED (rv)) return rv;
-
- AutoWindowModalState modalState (mWindow);
+ AutoModalDialog modalDialog (mWindow, PR_TRUE);
+ if (!modalDialog.ShouldShow ())
+ return GTK_RESPONSE_CANCEL;
if (mDelay)
{
@@ -491,7 +487,7 @@ Prompter::Run (PRBool *aSuccess)
GtkWidget *widget = GTK_WIDGET (mDialog);
gtk_widget_show (widget);
- mResponse = gtk_dialog_run (mDialog);
+ mResponse = modalDialog.Run (mDialog);
gtk_widget_hide (widget);
g_object_set_data (G_OBJECT (mDialog), TIMEOUT_DATA_KEY, NULL);