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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_CHROME_PAGES_H_
6 #define CHROME_BROWSER_UI_CHROME_PAGES_H_
10 #include "chrome/browser/signin/signin_promo.h"
11 #include "chrome/browser/ui/host_desktop.h"
12 #include "components/content_settings/core/common/content_settings_types.h"
23 // Sources of requests to show the help tab.
25 // Keyboard accelerators.
28 // Menus (e.g. wrench menu or Chrome OS system menu).
31 // WebUI (the "About" page).
36 void ShowBookmarkManager(Browser
* browser
);
37 void ShowBookmarkManagerForNode(Browser
* browser
, int64 node_id
);
38 void ShowHistory(Browser
* browser
);
39 void ShowDownloads(Browser
* browser
);
40 void ShowExtensions(Browser
* browser
,
41 const std::string
& extension_to_highlight
);
42 void ShowConflicts(Browser
* browser
);
44 // ShowFeedbackPage() uses |browser| to determine the URL of the current tab.
45 // |browser| should be NULL if there are no currently open browser windows.
46 void ShowFeedbackPage(Browser
* browser
,
47 const std::string
& description_template
,
48 const std::string
& category_tag
);
50 void ShowHelp(Browser
* browser
, HelpSource source
);
51 void ShowHelpForProfile(Profile
* profile
,
52 HostDesktopType host_desktop_type
,
54 void ShowPolicy(Browser
* browser
);
55 void ShowSlow(Browser
* browser
);
57 // Constructs a settings GURL for the specified |sub_page|.
58 GURL
GetSettingsUrl(const std::string
& sub_page
);
60 // Returns true if |browser| is a trusted popup window containing a page with
61 // matching |scheme| (or any trusted popup if |scheme| is empty).
62 bool IsTrustedPopupWindowWithScheme(const Browser
* browser
,
63 const std::string
& scheme
);
65 // Various things that open in a settings UI.
66 void ShowSettings(Browser
* browser
);
67 void ShowSettingsSubPage(Browser
* browser
, const std::string
& sub_page
);
68 void ShowSettingsSubPageForProfile(Profile
* profile
,
69 const std::string
& sub_page
);
70 void ShowContentSettings(Browser
* browser
,
71 ContentSettingsType content_settings_type
);
72 void ShowSettingsSubPageInTabbedBrowser(Browser
* browser
,
73 const std::string
& sub_page
);
74 void ShowClearBrowsingDataDialog(Browser
* browser
);
75 void ShowPasswordManager(Browser
* browser
);
76 void ShowImportDialog(Browser
* browser
);
77 void ShowAboutChrome(Browser
* browser
);
78 void ShowSearchEngineSettings(Browser
* browser
);
79 // If the user is already signed in, shows the "Signin" portion of Settings,
80 // otherwise initiates signin.
81 void ShowBrowserSignin(Browser
* browser
, signin::Source source
);
85 #endif // CHROME_BROWSER_UI_CHROME_PAGES_H_