Chromium Code Reviews| OLD | NEW |
|---|---|
| 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_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 61 int GetCommandIdForExtension(const extensions::Extension& extension); | 61 int GetCommandIdForExtension(const extensions::Extension& extension); |
| 62 | 62 |
| 63 // Gets the extension for a command ID, or NULL if there isn't one. | 63 // Gets the extension for a command ID, or NULL if there isn't one. |
| 64 const extensions::Extension* GetExtensionForCommandId(int command_id); | 64 const extensions::Extension* GetExtensionForCommandId(int command_id); |
| 65 | 65 |
| 66 // content::NotificationObserver implementation. | 66 // content::NotificationObserver implementation. |
| 67 virtual void Observe(int type, | 67 virtual void Observe(int type, |
| 68 const content::NotificationSource& source, | 68 const content::NotificationSource& source, |
| 69 const content::NotificationDetails& details) OVERRIDE; | 69 const content::NotificationDetails& details) OVERRIDE; |
| 70 | 70 |
| 71 // Handles "share with X" commands. | |
| 72 void TriggerExplicitShareIntent(const GURL& share_service_url); | |
| 73 | |
| 74 // Handles the "Find places to share" command. Navigates the browser to the | |
| 75 // web store to find extensions with share intents. | |
| 76 void NavigateToWebStoreShareIntentsList(); | |
| 77 | |
| 71 Browser* browser_; | 78 Browser* browser_; |
| 72 | 79 |
| 73 Delegate* delegate_; | 80 Delegate* delegate_; |
| 74 | 81 |
| 75 // The command ID to assign to the next extension that needs one. | 82 // The command ID to assign to the next extension that needs one. |
|
Peter Kasting
2012/10/15 19:33:09
Nit: Comment is wrong
skare_
2012/10/15 21:07:27
removed member
On 2012/10/15 19:33:09, Peter Kasti
| |
| 83 int next_share_intent_command_id_; | |
| 84 | |
| 85 // The share service strings that have commands associated with them. | |
| 86 typedef std::map<int, GURL> ShareIntentServiceCommandMap; | |
| 87 ShareIntentServiceCommandMap share_intent_service_ids_; | |
| 88 | |
| 89 // The command ID to assign to the next extension that needs one. | |
| 76 int next_extension_command_id_; | 90 int next_extension_command_id_; |
| 77 | 91 |
| 78 // The extension IDs that have commands associated with them. | 92 // The extension IDs that have commands associated with them. |
| 79 typedef std::map<std::string, int> ExtensionIdCommandMap; | 93 typedef std::map<std::string, int> ExtensionIdCommandMap; |
| 80 ExtensionIdCommandMap extension_command_ids_; | 94 ExtensionIdCommandMap extension_command_ids_; |
| 81 | 95 |
| 82 content::NotificationRegistrar registrar_; | 96 content::NotificationRegistrar registrar_; |
| 83 | 97 |
| 84 DISALLOW_COPY_AND_ASSIGN(ActionBoxButtonController); | 98 DISALLOW_COPY_AND_ASSIGN(ActionBoxButtonController); |
| 85 }; | 99 }; |
| 86 | 100 |
| 87 #endif // CHROME_BROWSER_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ | 101 #endif // CHROME_BROWSER_UI_TOOLBAR_ACTION_BOX_BUTTON_CONTROLLER_H_ |
| OLD | NEW |