summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
Diffstat (limited to 'webkit')
-rw-r--r--webkit/glue/chrome_client_impl.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/webkit/glue/chrome_client_impl.cc b/webkit/glue/chrome_client_impl.cc
index 18269e1..f23cf43 100644
--- a/webkit/glue/chrome_client_impl.cc
+++ b/webkit/glue/chrome_client_impl.cc
@@ -17,6 +17,9 @@ MSVC_PUSH_WARNING_LEVEL(0);
#include "Page.h"
#include "ScriptController.h"
#include "WindowFeatures.h"
+#if USE(V8)
+#include "v8_proxy.h"
+#endif
MSVC_POP_WARNING();
#undef LOG
@@ -311,6 +314,12 @@ void ChromeClientImpl::runJavaScriptAlert(WebCore::Frame* frame,
// Pass the request on to the WebView delegate, for more control.
WebViewDelegate* d = webview_->delegate();
if (d) {
+#if USE(V8)
+ // Before showing the JavaScript dialog, we give the proxy implementation
+ // a chance to process any pending console messages.
+ WebCore::V8Proxy::ProcessConsoleMessages();
+#endif
+
std::wstring wstr = webkit_glue::StringToStdWString(message);
d->RunJavaScriptAlert(webview_, wstr);
}