summaryrefslogtreecommitdiffstats
path: root/chrome_frame/chrome_frame_activex_base.h
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-23 22:15:34 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-23 22:15:34 +0000
commitf5494d49ab74e3d116540b14db3457558f54c88e (patch)
treebeb367c01c187652d02091a5067a69d5bc0fa064 /chrome_frame/chrome_frame_activex_base.h
parenta9f39a313b7ecc11d98727d869e15094481f3a65 (diff)
downloadchromium_src-f5494d49ab74e3d116540b14db3457558f54c88e.zip
chromium_src-f5494d49ab74e3d116540b14db3457558f54c88e.tar.gz
chromium_src-f5494d49ab74e3d116540b14db3457558f54c88e.tar.bz2
Clean up Automation and Chrome Frame IPC code.-only use routed messages when needed-use routing IDs to avoid manually unpacking messages-remove data structures from IPC namespace (that should only be used for IPC code, and param traits)Note that I temporarily commented out part of a test in external_tab_test.cc because I couldn't figure out how to get the updated gmock macros to compile.
Review URL: http://codereview.chromium.org/5998006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70105 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/chrome_frame_activex_base.h')
-rw-r--r--chrome_frame/chrome_frame_activex_base.h25
1 files changed, 11 insertions, 14 deletions
diff --git a/chrome_frame/chrome_frame_activex_base.h b/chrome_frame/chrome_frame_activex_base.h
index dfc3da0..cedd526 100644
--- a/chrome_frame/chrome_frame_activex_base.h
+++ b/chrome_frame/chrome_frame_activex_base.h
@@ -349,8 +349,7 @@ END_MSG_MAP()
return CComControlBase::IOleObject_SetClientSite(client_site);
}
- bool HandleContextMenuCommand(UINT cmd,
- const IPC::MiniContextMenuParams& params) {
+ bool HandleContextMenuCommand(UINT cmd, const MiniContextMenuParams& params) {
if (cmd == IDC_ABOUT_CHROME_FRAME) {
int tab_handle = automation_client_->tab()->handle();
HostNavigate(GURL("about:version"), GURL(), NEW_WINDOW);
@@ -415,7 +414,7 @@ END_MSG_MAP()
DVLOG(1) << __FUNCTION__ << ": " << profile_path->value();
}
- void OnLoad(int tab_handle, const GURL& url) {
+ void OnLoad(const GURL& url) {
if (ready_state_ < READYSTATE_COMPLETE) {
ready_state_ = READYSTATE_COMPLETE;
FireOnChanged(DISPID_READYSTATE);
@@ -428,7 +427,7 @@ END_MSG_MAP()
HRESULT hr = InvokeScriptFunction(onerror_handler_, url);
}
- void OnMessageFromChromeFrame(int tab_handle, const std::string& message,
+ void OnMessageFromChromeFrame(const std::string& message,
const std::string& origin,
const std::string& target) {
base::win::ScopedComPtr<IDispatch> message_event;
@@ -440,7 +439,7 @@ END_MSG_MAP()
}
}
- virtual void OnTabbedOut(int tab_handle, bool reverse) {
+ virtual void OnTabbedOut(bool reverse) {
DCHECK(m_bInPlaceActive);
HWND parent = ::GetParent(m_hWnd);
@@ -451,7 +450,7 @@ END_MSG_MAP()
control_site->OnFocus(FALSE);
}
- virtual void OnOpenURL(int tab_handle, const GURL& url_to_open,
+ virtual void OnOpenURL(const GURL& url_to_open,
const GURL& referrer, int open_disposition) {
HostNavigate(url_to_open, referrer, open_disposition);
}
@@ -480,8 +479,7 @@ END_MSG_MAP()
return TRUE;
}
- virtual void OnAttachExternalTab(int tab_handle,
- const IPC::AttachExternalTabParams& params) {
+ virtual void OnAttachExternalTab(const AttachExternalTabParams& params) {
std::wstring wide_url = url_;
GURL parsed_url(WideToUTF8(wide_url));
@@ -515,12 +513,11 @@ END_MSG_MAP()
HostNavigate(GURL(url), GURL(), params.disposition);
}
- virtual void OnHandleContextMenu(int tab_handle, HANDLE menu_handle,
+ virtual void OnHandleContextMenu(HANDLE menu_handle,
int align_flags,
- const IPC::MiniContextMenuParams& params) {
+ const MiniContextMenuParams& params) {
scoped_refptr<BasePlugin> ref(this);
- ChromeFramePlugin<T>::OnHandleContextMenu(tab_handle, menu_handle,
- align_flags, params);
+ ChromeFramePlugin<T>::OnHandleContextMenu(menu_handle, align_flags, params);
}
LRESULT OnCreate(UINT message, WPARAM wparam, LPARAM lparam,
@@ -567,7 +564,7 @@ END_MSG_MAP()
FireOnChanged(DISPID_READYSTATE);
}
- virtual void OnCloseTab(int tab_handle) {
+ virtual void OnCloseTab() {
Fire_onclose();
}
@@ -1093,7 +1090,7 @@ END_MSG_MAP()
return hr;
}
- virtual void OnAcceleratorPressed(int tab_handle, const MSG& accel_message) {
+ virtual void OnAcceleratorPressed(const MSG& accel_message) {
DCHECK(m_spInPlaceSite != NULL);
// Allow our host a chance to handle the accelerator.
// This catches things like Ctrl+F, Ctrl+O etc, but not browser