summaryrefslogtreecommitdiffstats
path: root/chrome_frame
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-28 23:47:59 +0000
committerpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-28 23:47:59 +0000
commit074283adf1264cebfd1272afae558d2d7366a988 (patch)
tree8271a7e86446529c9f0927b5cb171690861c8f26 /chrome_frame
parentf22a79585707eef6ef87672e8b89845122108052 (diff)
downloadchromium_src-074283adf1264cebfd1272afae558d2d7366a988.zip
chromium_src-074283adf1264cebfd1272afae558d2d7366a988.tar.gz
chromium_src-074283adf1264cebfd1272afae558d2d7366a988.tar.bz2
Simplify Chrome Frame usage of Chrome identifiers by simply using the Chrome identifiers directly. This required renaming a few identifiers to avoid macro renaming conflicts when including the Chrome headers.
BUG=none TEST=none Review URL: http://codereview.chromium.org/2359002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48543 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame')
-rw-r--r--chrome_frame/chrome_active_document.cc11
-rw-r--r--chrome_frame/chrome_active_document.h6
-rw-r--r--chrome_frame/chrome_frame.gyp2
-rw-r--r--chrome_frame/chrome_frame_activex.h4
-rw-r--r--chrome_frame/chrome_imported_resources.cc13
-rw-r--r--chrome_frame/chrome_imported_resources.h10
-rw-r--r--chrome_frame/resources/chrome_frame_resources.grd4
-rw-r--r--chrome_frame/resources/structured_resources.rc10
8 files changed, 17 insertions, 43 deletions
diff --git a/chrome_frame/chrome_active_document.cc b/chrome_frame/chrome_active_document.cc
index 894564a..d850240 100644
--- a/chrome_frame/chrome_active_document.cc
+++ b/chrome_frame/chrome_active_document.cc
@@ -30,6 +30,7 @@
#include "base/trace_event.h"
#include "grit/generated_resources.h"
+#include "chrome/app/chrome_dll_resource.h"
#include "chrome/browser/tab_contents/tab_contents.h"
#include "chrome/common/chrome_constants.h"
#include "chrome/common/navigation_types.h"
@@ -37,7 +38,6 @@
#include "chrome/test/automation/tab_proxy.h"
#include "chrome_frame/bho.h"
#include "chrome_frame/bind_context_info.h"
-#include "chrome_frame/chrome_imported_resources.h"
#include "chrome_frame/utils.h"
const wchar_t kChromeAttachExternalTabPrefix[] = L"attach_external_tab";
@@ -873,15 +873,14 @@ bool ChromeActiveDocument::HandleContextMenuCommand(UINT cmd,
ScopedComPtr<IWebBrowser2> web_browser2;
DoQueryService(SID_SWebBrowserApp, m_spClientSite, web_browser2.Receive());
- if (cmd == static_cast<UINT>(context_menu_IDC_BACK)) {
+ if (cmd == IDC_BACK)
web_browser2->GoBack();
- } else if (cmd == static_cast<UINT>(context_menu_IDC_FORWARD)) {
+ else if (cmd == IDC_FORWARD)
web_browser2->GoForward();
- } else if (cmd == static_cast<UINT>(context_menu_IDC_RELOAD)) {
+ else if (cmd == IDC_RELOAD)
web_browser2->Refresh();
- } else {
+ else
return BaseActiveX::HandleContextMenuCommand(cmd, params);
- }
return true;
}
diff --git a/chrome_frame/chrome_active_document.h b/chrome_frame/chrome_active_document.h
index 575c06a..bd1474f 100644
--- a/chrome_frame/chrome_active_document.h
+++ b/chrome_frame/chrome_active_document.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -232,8 +232,8 @@ END_COM_MAP()
BEGIN_MSG_MAP(ChromeActiveDocument)
MESSAGE_HANDLER(WM_FIRE_PRIVACY_CHANGE_NOTIFICATION, OnFirePrivacyChange)
- COMMAND_ID_HANDLER(IDC_FORWARD, OnForward)
- COMMAND_ID_HANDLER(IDC_BACK, OnBack)
+ COMMAND_ID_HANDLER(IDC_CHROMEFRAME_FORWARD, OnForward)
+ COMMAND_ID_HANDLER(IDC_CHROMEFRAME_BACK, OnBack)
CHAIN_MSG_MAP(BaseActiveX)
END_MSG_MAP()
diff --git a/chrome_frame/chrome_frame.gyp b/chrome_frame/chrome_frame.gyp
index 141a88e..a457583 100644
--- a/chrome_frame/chrome_frame.gyp
+++ b/chrome_frame/chrome_frame.gyp
@@ -608,8 +608,6 @@
'chrome_frame_histograms.h',
'chrome_frame_reporting.cc',
'chrome_frame_reporting.h',
- 'chrome_imported_resources.cc',
- 'chrome_imported_resources.h',
'chrome_launcher_utils.cc',
'chrome_launcher_utils.h',
'chrome_protocol.cc',
diff --git a/chrome_frame/chrome_frame_activex.h b/chrome_frame/chrome_frame_activex.h
index ffe7880..e55e25e 100644
--- a/chrome_frame/chrome_frame_activex.h
+++ b/chrome_frame/chrome_frame_activex.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -41,7 +41,7 @@ class ATL_NO_VTABLE ChromeFrameActivex
ChromeFrameActivex();
~ChromeFrameActivex();
-DECLARE_REGISTRY_RESOURCEID(IDR_CHROMEFRAME)
+DECLARE_REGISTRY_RESOURCEID(IDR_CHROMEFRAME_ACTIVEX)
BEGIN_COM_MAP(ChromeFrameActivex)
COM_INTERFACE_ENTRY(IObjectWithSite)
diff --git a/chrome_frame/chrome_imported_resources.cc b/chrome_frame/chrome_imported_resources.cc
deleted file mode 100644
index 966fadf..0000000
--- a/chrome_frame/chrome_imported_resources.cc
+++ /dev/null
@@ -1,13 +0,0 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-// Defines resource ids included from Chrome. This is done to prevent resource
-// id conflicts.
-#pragma once
-
-#include "chrome/app/chrome_dll_resource.h"
-
-int context_menu_IDC_FORWARD = IDC_FORWARD;
-int context_menu_IDC_RELOAD = IDC_RELOAD;
-int context_menu_IDC_BACK = IDC_BACK;
-
diff --git a/chrome_frame/chrome_imported_resources.h b/chrome_frame/chrome_imported_resources.h
deleted file mode 100644
index 6b950ea..0000000
--- a/chrome_frame/chrome_imported_resources.h
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-// Defines resource ids included from Chrome. This is done to prevent resource
-// id conflicts.
-
-extern int context_menu_IDC_FORWARD;
-extern int context_menu_IDC_RELOAD;
-extern int context_menu_IDC_BACK;
-
diff --git a/chrome_frame/resources/chrome_frame_resources.grd b/chrome_frame/resources/chrome_frame_resources.grd
index a8107fd..f9d9a7f 100644
--- a/chrome_frame/resources/chrome_frame_resources.grd
+++ b/chrome_frame/resources/chrome_frame_resources.grd
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this
+Copyright (c) 2010 The Chromium Authors. All rights reserved. Use of this
source code is governed by a BSD-style license that can be found in the LICENSE
file.
-->
@@ -30,7 +30,7 @@ for localizable strings
<include name="IDR_CHROMEPROTOCOL" file="../chrome_protocol.rgs" type="REGISTRY" />
<include name="IDR_CHROMEACTIVEDOCUMENT" file="../chrome_active_document.rgs"
type="REGISTRY" />
- <include name="IDR_CHROMEFRAME" file="../chrome_frame_activex.rgs" type="REGISTRY" />
+ <include name="IDR_CHROMEFRAME_ACTIVEX" file="../chrome_frame_activex.rgs" type="REGISTRY" />
<include name="IDR_CHROMEFRAME_NPAPI" file="../chrome_frame_npapi.rgs" type="REGISTRY" />
</includes>
</release>
diff --git a/chrome_frame/resources/structured_resources.rc b/chrome_frame/resources/structured_resources.rc
index 1d07e05..28bcf9b 100644
--- a/chrome_frame/resources/structured_resources.rc
+++ b/chrome_frame/resources/structured_resources.rc
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -9,8 +9,8 @@
IDR_CHROME_FRAME_IE_FULL_TAB ACCELERATORS
BEGIN
- VK_LEFT, IDC_BACK, VIRTKEY, ALT
- VK_BACK, IDC_BACK, VIRTKEY
- VK_BACK, IDC_FORWARD, VIRTKEY, SHIFT
- VK_RIGHT, IDC_FORWARD, VIRTKEY, ALT
+ VK_LEFT, IDC_CHROMEFRAME_BACK, VIRTKEY, ALT
+ VK_BACK, IDC_CHROMEFRAME_BACK, VIRTKEY
+ VK_BACK, IDC_CHROMEFRAME_FORWARD, VIRTKEY, SHIFT
+ VK_RIGHT, IDC_CHROMEFRAME_FORWARD, VIRTKEY, ALT
END