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

Side by Side Diff: chrome/browser/extensions/tab_helper.h

Issue 11014009: Beginnings of the script bubble. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More minor cleanup Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_
6 #define CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_ 6 #define CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/observer_list.h" 10 #include "base/observer_list.h"
(...skipping 13 matching lines...) Expand all
24 struct WebApplicationInfo; 24 struct WebApplicationInfo;
25 25
26 namespace content { 26 namespace content {
27 struct LoadCommittedDetails; 27 struct LoadCommittedDetails;
28 } 28 }
29 29
30 namespace extensions { 30 namespace extensions {
31 class Extension; 31 class Extension;
32 class LocationBarController; 32 class LocationBarController;
33 class ScriptBadgeController; 33 class ScriptBadgeController;
34 class ScriptBubbleController;
34 35
35 // Per-tab extension helper. Also handles non-extension apps. 36 // Per-tab extension helper. Also handles non-extension apps.
36 class TabHelper : public content::WebContentsObserver, 37 class TabHelper : public content::WebContentsObserver,
37 public ExtensionFunctionDispatcher::Delegate, 38 public ExtensionFunctionDispatcher::Delegate,
38 public ImageLoadingTracker::Observer, 39 public ImageLoadingTracker::Observer,
39 public AppNotifyChannelSetup::Delegate, 40 public AppNotifyChannelSetup::Delegate,
40 public base::SupportsWeakPtr<TabHelper>, 41 public base::SupportsWeakPtr<TabHelper>,
41 public content::NotificationObserver, 42 public content::NotificationObserver,
42 public WebContentsUserData<TabHelper> { 43 public WebContentsUserData<TabHelper> {
43 public: 44 public:
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 } 133 }
133 134
134 LocationBarController* location_bar_controller() { 135 LocationBarController* location_bar_controller() {
135 return location_bar_controller_.get(); 136 return location_bar_controller_.get();
136 } 137 }
137 138
138 ActiveTabPermissionGranter* active_tab_permission_granter() { 139 ActiveTabPermissionGranter* active_tab_permission_granter() {
139 return active_tab_permission_granter_.get(); 140 return active_tab_permission_granter_.get();
140 } 141 }
141 142
143 ScriptBubbleController* script_bubble_controller() {
144 return script_bubble_controller_.get();
145 }
146
142 // Sets a non-extension app icon associated with WebContents and fires an 147 // Sets a non-extension app icon associated with WebContents and fires an
143 // INVALIDATE_TYPE_TITLE navigation state change to trigger repaint of title. 148 // INVALIDATE_TYPE_TITLE navigation state change to trigger repaint of title.
144 void SetAppIcon(const SkBitmap& app_icon); 149 void SetAppIcon(const SkBitmap& app_icon);
145 150
146 private: 151 private:
147 explicit TabHelper(content::WebContents* web_contents); 152 explicit TabHelper(content::WebContents* web_contents);
148 friend class WebContentsUserData<TabHelper>; 153 friend class WebContentsUserData<TabHelper>;
149 154
150 // content::WebContentsObserver overrides. 155 // content::WebContentsObserver overrides.
151 virtual void RenderViewCreated( 156 virtual void RenderViewCreated(
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
247 WebAppAction pending_web_app_action_; 252 WebAppAction pending_web_app_action_;
248 253
249 content::NotificationRegistrar registrar_; 254 content::NotificationRegistrar registrar_;
250 255
251 ScriptExecutor script_executor_; 256 ScriptExecutor script_executor_;
252 257
253 scoped_ptr<LocationBarController> location_bar_controller_; 258 scoped_ptr<LocationBarController> location_bar_controller_;
254 259
255 scoped_ptr<ActiveTabPermissionGranter> active_tab_permission_granter_; 260 scoped_ptr<ActiveTabPermissionGranter> active_tab_permission_granter_;
256 261
262 scoped_ptr<ScriptBubbleController> script_bubble_controller_;
263
257 DISALLOW_COPY_AND_ASSIGN(TabHelper); 264 DISALLOW_COPY_AND_ASSIGN(TabHelper);
258 }; 265 };
259 266
260 } // namespace extensions 267 } // namespace extensions
261 268
262 #endif // CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_ 269 #endif // CHROME_BROWSER_EXTENSIONS_TAB_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698