| 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_BROWSER_COMMANDS_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_COMMANDS_H_ |
| 6 #define CHROME_BROWSER_UI_BROWSER_COMMANDS_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_COMMANDS_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "build/build_config.h" | 10 #include "build/build_config.h" |
| 11 #include "chrome/browser/devtools/devtools_toggle_action.h" | 11 #include "chrome/browser/devtools/devtools_toggle_action.h" |
| 12 #include "chrome/browser/ui/tabs/tab_strip_model_delegate.h" | 12 #include "chrome/browser/ui/tabs/tab_strip_model_delegate.h" |
| 13 #include "content/public/common/page_zoom.h" | 13 #include "content/public/common/page_zoom.h" |
| 14 #include "printing/features/features.h" | 14 #include "printing/features/features.h" |
| 15 #include "ui/base/window_open_disposition.h" | 15 #include "ui/base/window_open_disposition.h" |
| 16 | 16 |
| 17 class Browser; | 17 class Browser; |
| 18 class CommandObserver; | 18 class CommandObserver; |
| 19 class GURL; | 19 class GURL; |
| 20 class Profile; | 20 class Profile; |
| 21 | 21 |
| 22 namespace content { | 22 namespace content { |
| 23 class PageState; | 23 class PageState; |
| 24 class WebContents; | 24 class WebContents; |
| 25 } | 25 } |
| 26 | 26 |
| 27 namespace security_state { | |
| 28 struct SecurityInfo; | |
| 29 } // namespace security_state | |
| 30 | |
| 31 namespace chrome { | 27 namespace chrome { |
| 32 | 28 |
| 33 // For all commands, where a tab is not specified, the active tab is assumed. | 29 // For all commands, where a tab is not specified, the active tab is assumed. |
| 34 | 30 |
| 35 bool IsCommandEnabled(Browser* browser, int command); | 31 bool IsCommandEnabled(Browser* browser, int command); |
| 36 bool SupportsCommand(Browser* browser, int command); | 32 bool SupportsCommand(Browser* browser, int command); |
| 37 bool ExecuteCommand(Browser* browser, int command); | 33 bool ExecuteCommand(Browser* browser, int command); |
| 38 bool ExecuteCommandWithDisposition(Browser* browser, | 34 bool ExecuteCommandWithDisposition(Browser* browser, |
| 39 int command, | 35 int command, |
| 40 WindowOpenDisposition disposition); | 36 WindowOpenDisposition disposition); |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 void BookmarkCurrentPageAllowingExtensionOverrides(Browser* browser); | 95 void BookmarkCurrentPageAllowingExtensionOverrides(Browser* browser); |
| 100 bool CanBookmarkCurrentPage(const Browser* browser); | 96 bool CanBookmarkCurrentPage(const Browser* browser); |
| 101 void BookmarkAllTabs(Browser* browser); | 97 void BookmarkAllTabs(Browser* browser); |
| 102 bool CanBookmarkAllTabs(const Browser* browser); | 98 bool CanBookmarkAllTabs(const Browser* browser); |
| 103 void SaveCreditCard(Browser* browser); | 99 void SaveCreditCard(Browser* browser); |
| 104 void Translate(Browser* browser); | 100 void Translate(Browser* browser); |
| 105 void ManagePasswordsForPage(Browser* browser); | 101 void ManagePasswordsForPage(Browser* browser); |
| 106 void SavePage(Browser* browser); | 102 void SavePage(Browser* browser); |
| 107 bool CanSavePage(const Browser* browser); | 103 bool CanSavePage(const Browser* browser); |
| 108 void ShowFindBar(Browser* browser); | 104 void ShowFindBar(Browser* browser); |
| 109 void ShowWebsiteSettings(Browser* browser, | 105 bool ShowWebsiteSettings(Browser* browser, content::WebContents* web_contents); |
| 110 content::WebContents* web_contents, | |
| 111 const GURL& url, | |
| 112 const security_state::SecurityInfo& security_info); | |
| 113 void Print(Browser* browser); | 106 void Print(Browser* browser); |
| 114 bool CanPrint(Browser* browser); | 107 bool CanPrint(Browser* browser); |
| 115 #if BUILDFLAG(ENABLE_BASIC_PRINTING) | 108 #if BUILDFLAG(ENABLE_BASIC_PRINTING) |
| 116 void BasicPrint(Browser* browser); | 109 void BasicPrint(Browser* browser); |
| 117 bool CanBasicPrint(Browser* browser); | 110 bool CanBasicPrint(Browser* browser); |
| 118 #endif // ENABLE_BASIC_PRINTING | 111 #endif // ENABLE_BASIC_PRINTING |
| 119 bool CanRouteMedia(Browser* browser); | 112 bool CanRouteMedia(Browser* browser); |
| 120 void RouteMedia(Browser* browser); | 113 void RouteMedia(Browser* browser); |
| 121 void EmailPageLocation(Browser* browser); | 114 void EmailPageLocation(Browser* browser); |
| 122 bool CanEmailPageLocation(const Browser* browser); | 115 bool CanEmailPageLocation(const Browser* browser); |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 void CreateApplicationShortcuts(Browser* browser); | 159 void CreateApplicationShortcuts(Browser* browser); |
| 167 void CreateBookmarkAppFromCurrentWebContents(Browser* browser); | 160 void CreateBookmarkAppFromCurrentWebContents(Browser* browser); |
| 168 bool CanCreateApplicationShortcuts(const Browser* browser); | 161 bool CanCreateApplicationShortcuts(const Browser* browser); |
| 169 bool CanCreateBookmarkApp(const Browser* browser); | 162 bool CanCreateBookmarkApp(const Browser* browser); |
| 170 | 163 |
| 171 void ConvertTabToAppWindow(Browser* browser, content::WebContents* contents); | 164 void ConvertTabToAppWindow(Browser* browser, content::WebContents* contents); |
| 172 | 165 |
| 173 } // namespace chrome | 166 } // namespace chrome |
| 174 | 167 |
| 175 #endif // CHROME_BROWSER_UI_BROWSER_COMMANDS_H_ | 168 #endif // CHROME_BROWSER_UI_BROWSER_COMMANDS_H_ |
| OLD | NEW |