summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/browser.scons1
-rw-r--r--chrome/browser/renderer_host/render_view_host.cc26
-rw-r--r--chrome/browser/renderer_host/render_view_host.h8
-rw-r--r--chrome/browser/renderer_host/render_view_host_delegate.h5
-rw-r--r--chrome/browser/renderer_host/render_widget_helper.cc3
-rw-r--r--chrome/browser/renderer_host/render_widget_host.h15
-rw-r--r--chrome/chrome.xcodeproj/project.pbxproj16
-rw-r--r--chrome/common/render_messages.h31
-rw-r--r--chrome/common/render_messages_internal.h26
9 files changed, 89 insertions, 42 deletions
diff --git a/chrome/browser/browser.scons b/chrome/browser/browser.scons
index 225d6fa..cde1556 100644
--- a/chrome/browser/browser.scons
+++ b/chrome/browser/browser.scons
@@ -769,7 +769,6 @@ if not env.Bit('windows'):
'printing/win_printing_context.cc',
'profile.cc',
'profile_manager.cc',
- 'renderer_host/render_view_host.cc',
'renderer_host/render_widget_helper.cc',
'renderer_host/render_widget_host.cc',
'renderer_host/cross_site_resource_handler.cc',
diff --git a/chrome/browser/renderer_host/render_view_host.cc b/chrome/browser/renderer_host/render_view_host.cc
index adfebaa..1c724e2 100644
--- a/chrome/browser/renderer_host/render_view_host.cc
+++ b/chrome/browser/renderer_host/render_view_host.cc
@@ -22,7 +22,6 @@
#include "chrome/browser/renderer_host/renderer_security_policy.h"
#include "chrome/browser/tab_contents/navigation_entry.h"
#include "chrome/browser/tab_contents/site_instance.h"
-#include "chrome/browser/tab_contents/web_contents.h"
#include "chrome/common/resource_bundle.h"
#include "chrome/common/thumbnail_score.h"
#include "net/base/net_util.h"
@@ -78,12 +77,13 @@ RenderViewHost::RenderViewHost(SiteInstance* instance,
base::WaitableEvent* modal_dialog_event)
: RenderWidgetHost(instance->GetProcess(), routing_id),
instance_(instance),
- enable_dom_ui_bindings_(false),
- enable_external_host_bindings_(false),
delegate_(delegate),
renderer_initialized_(false),
waiting_for_drag_context_response_(false),
debugger_attached_(false),
+ enable_dom_ui_bindings_(false),
+ pending_request_id_(-1),
+ enable_external_host_bindings_(false),
modal_dialog_count_(0),
navigations_suspended_(false),
suspended_nav_message_(NULL),
@@ -129,6 +129,7 @@ bool RenderViewHost::CreateRenderView() {
renderer_initialized_ = true;
+#if defined(OS_WIN)
HANDLE modal_dialog_event;
HANDLE renderer_process_handle = process()->process().handle();
if (renderer_process_handle == NULL)
@@ -148,6 +149,9 @@ bool RenderViewHost::CreateRenderView() {
modal_dialog_event,
delegate_->GetWebkitPrefs(),
routing_id()));
+#elif defined(OS_POSIX)
+ Send(new ViewMsg_New(delegate_->GetWebkitPrefs(), routing_id()));
+#endif
// Set the alternate error page, which is profile specific, in the renderer.
GURL url = delegate_->GetAlternateErrorPageURL();
@@ -750,12 +754,21 @@ void RenderViewHost::Shutdown() {
RenderWidgetHost::Shutdown();
}
-void RenderViewHost::OnMsgCreateWindow(int route_id,
- HANDLE modal_dialog_event) {
+void RenderViewHost::OnMsgCreateWindow(
+ int route_id,
+ ModalDialogEvent modal_dialog_event) {
RenderViewHostDelegate::View* view = delegate_->GetViewDelegate();
- if (view)
+ if (view) {
+#if defined(OS_WIN)
view->CreateNewWindow(route_id,
new base::WaitableEvent(modal_dialog_event));
+#else
+ // TODO(port) this isn't correct, since we just make up an event won't ever
+ // be set by the renderer.
+ view->CreateNewWindow(route_id,
+ new base::WaitableEvent(true, false));
+ }
+#endif
}
void RenderViewHost::OnMsgCreateWidget(int route_id, bool activatable) {
@@ -1070,7 +1083,6 @@ void RenderViewHost::OnMsgRunJavaScriptMessage(
StopHangMonitorTimeout();
if (modal_dialog_count_++ == 0)
modal_dialog_event_->Signal();
- bool did_suppress_message = false;
delegate_->RunJavaScriptMessage(message, default_prompt, flags, reply_msg,
&are_javascript_messages_suppressed_);
}
diff --git a/chrome/browser/renderer_host/render_view_host.h b/chrome/browser/renderer_host/render_view_host.h
index f4c40ed..36ec1d1 100644
--- a/chrome/browser/renderer_host/render_view_host.h
+++ b/chrome/browser/renderer_host/render_view_host.h
@@ -12,9 +12,11 @@
#include "chrome/browser/renderer_host/render_view_host_delegate.h"
#include "chrome/browser/renderer_host/render_widget_host.h"
#include "chrome/common/page_zoom.h"
+#include "chrome/common/render_messages.h"
#ifdef CHROME_PERSONALIZATION
#include "chrome/personalization/personalization.h"
#endif
+#include "net/base/load_states.h"
#include "webkit/glue/password_form_dom_manager.h"
#include "webkit/glue/autofill_form.h"
@@ -41,10 +43,6 @@ namespace gfx {
class Point;
}
-namespace net {
-enum LoadState;
-}
-
namespace webkit_glue {
struct WebApplicationInfo;
}
@@ -416,7 +414,7 @@ class RenderViewHost : public RenderWidgetHost {
virtual void NotifyRendererResponsive();
// IPC message handlers.
- void OnMsgCreateWindow(int route_id, HANDLE modal_dialog_event);
+ void OnMsgCreateWindow(int route_id, ModalDialogEvent modal_dialog_event);
void OnMsgCreateWidget(int route_id, bool activatable);
void OnMsgShowView(int route_id,
WindowOpenDisposition disposition,
diff --git a/chrome/browser/renderer_host/render_view_host_delegate.h b/chrome/browser/renderer_host/render_view_host_delegate.h
index 764e8ca..5a39b91 100644
--- a/chrome/browser/renderer_host/render_view_host_delegate.h
+++ b/chrome/browser/renderer_host/render_view_host_delegate.h
@@ -11,6 +11,7 @@
#include "base/basictypes.h"
#include "chrome/browser/autofill_manager.h"
#include "chrome/common/render_messages.h"
+#include "net/base/load_states.h"
#include "webkit/glue/webpreferences.h"
class NavigationEntry;
@@ -34,10 +35,6 @@ namespace gfx {
class Rect;
}
-namespace net {
-enum LoadState;
-}
-
//
// RenderViewHostDelegate
//
diff --git a/chrome/browser/renderer_host/render_widget_helper.cc b/chrome/browser/renderer_host/render_widget_helper.cc
index d92ff301..274d25f 100644
--- a/chrome/browser/renderer_host/render_widget_helper.cc
+++ b/chrome/browser/renderer_host/render_widget_helper.cc
@@ -204,7 +204,8 @@ void RenderWidgetHelper::CreateNewWindow(int opener_id,
*route_id = GetNextRoutingID();
#if defined(OS_WIN)
- HANDLE event = CreateEvent(NULL, TRUE, FALSE, NULL);
+ ModalDialogEvent event;
+ event.event = CreateEvent(NULL, TRUE, FALSE, NULL);
BOOL result = DuplicateHandle(GetCurrentProcess(),
event,
render_process,
diff --git a/chrome/browser/renderer_host/render_widget_host.h b/chrome/browser/renderer_host/render_widget_host.h
index 70d6cf5..2e769ec 100644
--- a/chrome/browser/renderer_host/render_widget_host.h
+++ b/chrome/browser/renderer_host/render_widget_host.h
@@ -5,14 +5,19 @@
#ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_H_
#define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_H_
-#include <windows.h>
-
#include <vector>
#include "base/gfx/size.h"
#include "base/timer.h"
+#include "build/build_config.h"
#include "chrome/common/ipc_channel.h"
+#if defined(OS_WIN)
+// TODO(port) when the bitmaps below use a cross-platform representation this
+// can be removed.
+#include <windows.h>
+#endif
+
namespace gfx {
class Rect;
}
@@ -255,6 +260,9 @@ class RenderWidgetHost : public IPC::Channel::Listener {
void OnMsgImeUpdateStatus(ViewHostMsg_ImeControl control,
const gfx::Rect& caret_rect);
+#if defined(OS_WIN)
+ // TODO(port) use a cross-platform representation of the bitmap.
+
// Paints the given bitmap to the current backing store at the given location.
void PaintBackingStoreRect(HANDLE bitmap,
const gfx::Rect& bitmap_rect,
@@ -268,7 +276,8 @@ class RenderWidgetHost : public IPC::Channel::Listener {
int dx, int dy,
const gfx::Rect& clip_rect,
const gfx::Size& view_size);
-
+#endif
+
// The View associated with the RenderViewHost. The lifetime of this object
// is associated with the lifetime of the Render process. If the Renderer
// crashes, its View is destroyed and this pointer becomes NULL, even though
diff --git a/chrome/chrome.xcodeproj/project.pbxproj b/chrome/chrome.xcodeproj/project.pbxproj
index 499b205..f86ada6 100644
--- a/chrome/chrome.xcodeproj/project.pbxproj
+++ b/chrome/chrome.xcodeproj/project.pbxproj
@@ -198,6 +198,8 @@
A54612DC0EE9958600A8EE5D /* extensions_service_unittest.cc in Sources */ = {isa = PBXBuildFile; fileRef = A54612DB0EE9958600A8EE5D /* extensions_service_unittest.cc */; };
A54612E20EE995F600A8EE5D /* extensions_service.cc in Sources */ = {isa = PBXBuildFile; fileRef = A54612D90EE9957000A8EE5D /* extensions_service.cc */; };
A76E43A40F29039C009A7E88 /* browser_render_process_host.cc in Sources */ = {isa = PBXBuildFile; fileRef = A76E43A30F29039C009A7E88 /* browser_render_process_host.cc */; };
+ A76E43CC0F29115A009A7E88 /* render_view_host.cc in Sources */ = {isa = PBXBuildFile; fileRef = A76E429D0F28ED73009A7E88 /* render_view_host.cc */; };
+ A7AD09FB0F2E193E004A02B8 /* render_process_host.cc in Sources */ = {isa = PBXBuildFile; fileRef = B5D16EC10F2144D500861FAC /* render_process_host.cc */; };
B502DA280F098056005BE90C /* visit_database_unittest.cc in Sources */ = {isa = PBXBuildFile; fileRef = 4D7BFA180E9D48F7009A6919 /* visit_database_unittest.cc */; };
B502DA520F098888005BE90C /* l10n_util.cc in Sources */ = {isa = PBXBuildFile; fileRef = 4D7BFBC90E9D4C9F009A6919 /* l10n_util.cc */; };
B503E0F00F0175FD00547DC6 /* user_script_slave.cc in Sources */ = {isa = PBXBuildFile; fileRef = 4D640CC90EAE868600EBCFC0 /* user_script_slave.cc */; };
@@ -1289,7 +1291,6 @@
4D7BF9070E9D4839009A6919 /* sandbox_policy.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sandbox_policy.cc; sourceTree = "<group>"; };
4D7BF9080E9D4839009A6919 /* sandbox_policy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sandbox_policy.h; sourceTree = "<group>"; };
4D7BF9090E9D4839009A6919 /* sanity_uitest.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sanity_uitest.cc; sourceTree = "<group>"; };
- 4D7BF90A0E9D4839009A6919 /* security_style.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = security_style.h; sourceTree = "<group>"; };
4D7BF9100E9D4839009A6919 /* session_history_uitest.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = session_history_uitest.cc; sourceTree = "<group>"; };
4D7BF91A0E9D4839009A6919 /* session_startup_pref.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = session_startup_pref.cc; sourceTree = "<group>"; };
4D7BF91B0E9D4839009A6919 /* session_startup_pref.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = session_startup_pref.h; sourceTree = "<group>"; };
@@ -1688,6 +1689,9 @@
A76E42AE0F28EDB5009A7E88 /* render_view_host_manager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = render_view_host_manager.h; path = tab_contents/render_view_host_manager.h; sourceTree = "<group>"; };
A76E43970F29022A009A7E88 /* browser_render_process_host.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = browser_render_process_host.h; path = renderer_host/browser_render_process_host.h; sourceTree = "<group>"; };
A76E43A30F29039C009A7E88 /* browser_render_process_host.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = browser_render_process_host.cc; path = renderer_host/browser_render_process_host.cc; sourceTree = "<group>"; };
+ A7AD096F0F2E1825004A02B8 /* backing_store.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = backing_store.cc; path = renderer_host/backing_store.cc; sourceTree = "<group>"; };
+ A7AD09700F2E1825004A02B8 /* backing_store.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = backing_store.h; path = renderer_host/backing_store.h; sourceTree = "<group>"; };
+ A7AD0BD10F2E2E11004A02B8 /* security_style.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = security_style.h; path = tab_contents/security_style.h; sourceTree = "<group>"; };
B503E0FB0F01764800547DC6 /* user_script_slave_unittest.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = user_script_slave_unittest.cc; sourceTree = "<group>"; };
B54BD8FA0ED622C00093FD54 /* mach_message_source_mac.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = mach_message_source_mac.cc; sourceTree = "<group>"; };
B54BD8FB0ED622C00093FD54 /* mach_message_source_mac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mach_message_source_mac.h; sourceTree = "<group>"; };
@@ -1758,8 +1762,6 @@
B6CCB9D80F1EC32700106F0D /* navigation_controller.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = navigation_controller.h; path = tab_contents/navigation_controller.h; sourceTree = "<group>"; };
B6CCB9D90F1EC32700106F0D /* navigation_entry.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = navigation_entry.cc; path = tab_contents/navigation_entry.cc; sourceTree = "<group>"; };
B6CCB9DA0F1EC32700106F0D /* navigation_entry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = navigation_entry.h; path = tab_contents/navigation_entry.h; sourceTree = "<group>"; };
- B6CCB9DB0F1EC32700106F0D /* network_status_view.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = network_status_view.cc; path = tab_contents/network_status_view.cc; sourceTree = "<group>"; };
- B6CCB9DC0F1EC32700106F0D /* network_status_view.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = network_status_view.h; path = tab_contents/network_status_view.h; sourceTree = "<group>"; };
B6CCB9DD0F1EC32700106F0D /* page_navigator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = page_navigator.h; path = tab_contents/page_navigator.h; sourceTree = "<group>"; };
B6CCB9DE0F1EC32700106F0D /* provisional_load_details.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = provisional_load_details.cc; path = tab_contents/provisional_load_details.cc; sourceTree = "<group>"; };
B6CCB9DF0F1EC32700106F0D /* provisional_load_details.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = provisional_load_details.h; path = tab_contents/provisional_load_details.h; sourceTree = "<group>"; };
@@ -2428,7 +2430,6 @@
4D7BF9070E9D4839009A6919 /* sandbox_policy.cc */,
4D7BF9080E9D4839009A6919 /* sandbox_policy.h */,
4D7BF9090E9D4839009A6919 /* sanity_uitest.cc */,
- 4D7BF90A0E9D4839009A6919 /* security_style.h */,
4D7BF9100E9D4839009A6919 /* session_history_uitest.cc */,
4D7BF91A0E9D4839009A6919 /* session_startup_pref.cc */,
4D7BF91B0E9D4839009A6919 /* session_startup_pref.h */,
@@ -3101,8 +3102,6 @@
B6CCB9D80F1EC32700106F0D /* navigation_controller.h */,
B6CCB9D90F1EC32700106F0D /* navigation_entry.cc */,
B6CCB9DA0F1EC32700106F0D /* navigation_entry.h */,
- B6CCB9DB0F1EC32700106F0D /* network_status_view.cc */,
- B6CCB9DC0F1EC32700106F0D /* network_status_view.h */,
B6CCB9DD0F1EC32700106F0D /* page_navigator.h */,
B6CCB9DE0F1EC32700106F0D /* provisional_load_details.cc */,
B6CCB9DF0F1EC32700106F0D /* provisional_load_details.h */,
@@ -3112,6 +3111,7 @@
A76E42AC0F28EDB5009A7E88 /* render_view_context_menu_controller.h */,
A76E42AD0F28EDB5009A7E88 /* render_view_host_manager.cc */,
A76E42AE0F28EDB5009A7E88 /* render_view_host_manager.h */,
+ A7AD0BD10F2E2E11004A02B8 /* security_style.h */,
B6CCB9E00F1EC32700106F0D /* site_instance.cc */,
B6CCB9E10F1EC32700106F0D /* site_instance.h */,
B6CCB9E20F1EC32700106F0D /* status_view.cc */,
@@ -3271,6 +3271,8 @@
children = (
E45075DA0F150A53003BE099 /* async_resource_handler.cc */,
E45075DB0F150A53003BE099 /* async_resource_handler.h */,
+ A7AD096F0F2E1825004A02B8 /* backing_store.cc */,
+ A7AD09700F2E1825004A02B8 /* backing_store.h */,
A76E43A30F29039C009A7E88 /* browser_render_process_host.cc */,
A76E43970F29022A009A7E88 /* browser_render_process_host.h */,
E45075DE0F150A6F003BE099 /* buffered_resource_handler.h */,
@@ -4143,6 +4145,7 @@
B6CCB9FA0F1EC33100106F0D /* provisional_load_details.cc in Sources */,
E4F324500EE5CF7C002533CE /* query_parser.cc in Sources */,
E4F3247A0EE5D17E002533CE /* referrer.cc in Sources */,
+ A76E43CC0F29115A009A7E88 /* render_view_host.cc in Sources */,
4D7BFAF30E9D49EF009A6919 /* safe_browsing_database.cc in Sources */,
E48FB9590EC4E9C10052B72B /* safe_browsing_database_bloom.cc in Sources */,
E48FB95C0EC4E9DD0052B72B /* safe_browsing_database_impl.cc in Sources */,
@@ -4181,6 +4184,7 @@
4D7BFA480E9D4922009A6919 /* visitsegment_database.cc in Sources */,
E48B6C3C0F27844F002E47EC /* web_data_service.cc in Sources */,
E45076200F150E0C003BE099 /* web_database.cc in Sources */,
+ A7AD09FB0F2E193E004A02B8 /* render_process_host.cc in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
diff --git a/chrome/common/render_messages.h b/chrome/common/render_messages.h
index b0338b7..e279270ec 100644
--- a/chrome/common/render_messages.h
+++ b/chrome/common/render_messages.h
@@ -445,6 +445,18 @@ enum ViewHostMsg_ImeControl {
IME_COMPLETE_COMPOSITION,
};
+// This structure is passed around where we need a modal dialog event, which
+// is currently not plumbed on Mac & Linux.
+//
+// TODO(port) Fix this. This structure should probably go away and we should
+// do the modal dialog event in some portable way. If you remove this, be
+// sure to also remove the ParamTraits for it below.
+struct ModalDialogEvent {
+#if defined(OS_WIN)
+ HANDLE event;
+#endif
+};
+
// Multi-pass include of render_messages_internal. Preprocessor magic allows
// us to use 1 header to define the enums and classes for our render messages.
#define IPC_MESSAGE_MACROS_ENUMS
@@ -1723,6 +1735,25 @@ struct ParamTraits<webkit_glue::ScreenInfo> {
}
};
+template<>
+struct ParamTraits<ModalDialogEvent> {
+ typedef ModalDialogEvent param_type;
+#if defined(OS_WIN)
+ static void Write(Message* m, const param_type& p) {
+ WriteParam(m, p.event);
+ }
+ static bool Read(const Message* m, void** iter, param_type* p) {
+ return ReadParam(m, iter, &p->event);
+ }
+#else
+ static void Write(Message* m, const param_type& p) {
+ }
+ static bool Read(const Message* m, void** iter, param_type* p) {
+ return true;
+ }
+#endif
+};
+
} // namespace IPC
#endif // CHROME_COMMON_RENDER_MESSAGES_H_
diff --git a/chrome/common/render_messages_internal.h b/chrome/common/render_messages_internal.h
index 1081e54..ec0edd2 100644
--- a/chrome/common/render_messages_internal.h
+++ b/chrome/common/render_messages_internal.h
@@ -43,7 +43,15 @@ IPC_BEGIN_MESSAGES(View, 1)
// Tells the renderer to create a new view.
// This message is slightly different, the view it takes is the view to
// create, the message itself is sent as a non-view control message.
- IPC_MESSAGE_CONTROL4(ViewMsg_New, HWND, HANDLE, WebPreferences, int32)
+ IPC_MESSAGE_CONTROL4(ViewMsg_New,
+ HWND /* plugin_hwnd */,
+ HANDLE /* modal_dialog_event */,
+ WebPreferences /* preferences */,
+ int32 /* routing_id */)
+#elif defined(OS_POSIX)
+ IPC_MESSAGE_CONTROL2(ViewMsg_New,
+ WebPreferences, /* preferences */
+ int32 /* routing_id */)
#endif // defined(OS_WIN)
// Tells the renderer to set its maximum cache size to the supplied value
@@ -495,7 +503,6 @@ IPC_END_MESSAGES(View)
// These are messages sent from the renderer to the browser process.
IPC_BEGIN_MESSAGES(ViewHost, 2)
-#if defined(OS_WIN)
// Sent by the renderer when it is creating a new window. The browser creates
// a tab for it and responds with a ViewMsg_CreatingNew_ACK. If route_id is
// MSG_ROUTING_NONE, the view couldn't be created. modal_dialog_event is set
@@ -504,16 +511,7 @@ IPC_BEGIN_MESSAGES(ViewHost, 2)
int /* opener_id */,
bool /* user_gesture */,
int /* route_id */,
- HANDLE /* modal_dialog_event */)
-#else // defined(OS_WIN)
- // On POSIX, we don't use the cross process events for modal dialogs. At some
- // point, we won't use them on any platform, but for now we just define a
- // message without the last parameter.
- IPC_SYNC_MESSAGE_CONTROL2_1(ViewHostMsg_CreateWindow,
- int /* opener_id */,
- bool /* user_gesture */,
- int /* route_id */)
-#endif
+ ModalDialogEvent /* modal_dialog_event */)
// Similar to ViewHostMsg_CreateView, except used for sub-widgets, like
// <select> dropdowns. This message is sent to the WebContents that
@@ -523,13 +521,11 @@ IPC_BEGIN_MESSAGES(ViewHost, 2)
bool /* focus on show */,
int /* route_id */)
-#if defined(OS_WIN)
// These two messages are sent as a result of the above two, in the browser
// process, from RenderWidgetHelper to RenderViewHost.
IPC_MESSAGE_ROUTED2(ViewHostMsg_CreateWindowWithRoute,
int /* route_id */,
- HANDLE /* modal_dialog_event */)
-#endif // defined(OS_WIN)
+ ModalDialogEvent /* modal_dialog_event */)
IPC_MESSAGE_ROUTED2(ViewHostMsg_CreateWidgetWithRoute,
int /* route_id */,