Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5131)

Unified Diff: chrome/renderer/extensions/extension_helper.cc

Issue 10443105: Take 2 at implementing activeTab. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: empty -> is_empty Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/extensions/extension_helper.h ('k') | chrome/renderer/extensions/tab_finder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/extensions/extension_helper.cc
diff --git a/chrome/renderer/extensions/extension_helper.cc b/chrome/renderer/extensions/extension_helper.cc
index cafb63d8c31a0993a155e7145de695906f243e90..a3460bf50eff415c9110e0ff1ae7e3218f7207db 100644
--- a/chrome/renderer/extensions/extension_helper.cc
+++ b/chrome/renderer/extensions/extension_helper.cc
@@ -144,6 +144,7 @@ ExtensionHelper::ExtensionHelper(content::RenderView* render_view,
extension_dispatcher_(extension_dispatcher),
pending_app_icon_requests_(0),
view_type_(chrome::VIEW_TYPE_INVALID),
+ tab_id_(-1),
browser_window_id_(-1) {
}
@@ -209,6 +210,7 @@ bool ExtensionHelper::OnMessageReceived(const IPC::Message& message) {
OnExtensionDispatchOnDisconnect)
IPC_MESSAGE_HANDLER(ExtensionMsg_ExecuteCode, OnExecuteCode)
IPC_MESSAGE_HANDLER(ExtensionMsg_GetApplicationInfo, OnGetApplicationInfo)
+ IPC_MESSAGE_HANDLER(ExtensionMsg_SetTabId, OnSetTabId)
IPC_MESSAGE_HANDLER(ExtensionMsg_UpdateBrowserWindowId,
OnUpdateBrowserWindowId)
IPC_MESSAGE_HANDLER(ExtensionMsg_NotifyRenderViewType,
@@ -373,6 +375,12 @@ void ExtensionHelper::OnNotifyRendererViewType(chrome::ViewType type) {
view_type_ = type;
}
+void ExtensionHelper::OnSetTabId(int init_tab_id) {
+ CHECK_EQ(tab_id_, -1);
+ CHECK_GE(init_tab_id, 0);
+ tab_id_ = init_tab_id;
+}
+
void ExtensionHelper::OnUpdateBrowserWindowId(int window_id) {
browser_window_id_ = window_id;
}
« no previous file with comments | « chrome/renderer/extensions/extension_helper.h ('k') | chrome/renderer/extensions/tab_finder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698