| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_VIEWS_BROWSER_ACTIONS_PANEL_H_ | 5 #ifndef CHROME_BROWSER_VIEWS_BROWSER_ACTIONS_PANEL_H_ |
| 6 #define CHROME_BROWSER_VIEWS_BROWSER_ACTIONS_PANEL_H_ | 6 #define CHROME_BROWSER_VIEWS_BROWSER_ACTIONS_PANEL_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/task.h" | 10 #include "base/task.h" |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 int num_browser_actions() { return browser_action_views_.size(); } | 145 int num_browser_actions() { return browser_action_views_.size(); } |
| 146 | 146 |
| 147 // Returns the current tab's ID, or -1 if there is no current tab. | 147 // Returns the current tab's ID, or -1 if there is no current tab. |
| 148 int GetCurrentTabId(); | 148 int GetCurrentTabId(); |
| 149 | 149 |
| 150 // Get a particular browser action view. | 150 // Get a particular browser action view. |
| 151 BrowserActionView* GetBrowserActionViewAt(int index) { | 151 BrowserActionView* GetBrowserActionViewAt(int index) { |
| 152 return browser_action_views_[index]; | 152 return browser_action_views_[index]; |
| 153 } | 153 } |
| 154 | 154 |
| 155 // Retrieve the BrowserActionView for |extension|. |
| 156 BrowserActionView* GetBrowserActionView(Extension* extension); |
| 157 |
| 155 // Update the views to reflect the state of the browser action icons. | 158 // Update the views to reflect the state of the browser action icons. |
| 156 void RefreshBrowserActionViews(); | 159 void RefreshBrowserActionViews(); |
| 157 | 160 |
| 158 // Delete all browser action views. | 161 // Delete all browser action views. |
| 159 void DeleteBrowserActionViews(); | 162 void DeleteBrowserActionViews(); |
| 160 | 163 |
| 161 // Called when a browser action becomes visible/hidden. | 164 // Called when a browser action becomes visible/hidden. |
| 162 void OnBrowserActionVisibilityChanged(); | 165 void OnBrowserActionVisibilityChanged(); |
| 163 | 166 |
| 164 // Called when the user clicks on the browser action icon. | 167 // Called when the user clicks on the browser action icon. |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 220 // The button that triggered the current popup (just a reference to a button | 223 // The button that triggered the current popup (just a reference to a button |
| 221 // from browser_action_views_). | 224 // from browser_action_views_). |
| 222 BrowserActionButton* popup_button_; | 225 BrowserActionButton* popup_button_; |
| 223 | 226 |
| 224 ScopedRunnableMethodFactory<BrowserActionsContainer> task_factory_; | 227 ScopedRunnableMethodFactory<BrowserActionsContainer> task_factory_; |
| 225 | 228 |
| 226 DISALLOW_COPY_AND_ASSIGN(BrowserActionsContainer); | 229 DISALLOW_COPY_AND_ASSIGN(BrowserActionsContainer); |
| 227 }; | 230 }; |
| 228 | 231 |
| 229 #endif // CHROME_BROWSER_VIEWS_BROWSER_ACTIONS_PANEL_H_ | 232 #endif // CHROME_BROWSER_VIEWS_BROWSER_ACTIONS_PANEL_H_ |
| OLD | NEW |