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

Side by Side Diff: chrome/browser/ui/browser_dialogs.h

Issue 2524213002: MacViews: Consolidate flags. Just use --secondary-ui-md to enable MacViews. (Closed)
Patch Set: remove obsolete comment from r409593 Created 4 years 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
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_UI_BROWSER_DIALOGS_H_ 5 #ifndef CHROME_BROWSER_UI_BROWSER_DIALOGS_H_
6 #define CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ 6 #define CHROME_BROWSER_UI_BROWSER_DIALOGS_H_
7 7
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "build/build_config.h" 13 #include "build/build_config.h"
14 #include "chrome/browser/ui/bookmarks/bookmark_editor.h" 14 #include "chrome/browser/ui/bookmarks/bookmark_editor.h"
15 #include "third_party/skia/include/core/SkColor.h" 15 #include "third_party/skia/include/core/SkColor.h"
16 #include "ui/gfx/native_widget_types.h" 16 #include "ui/gfx/native_widget_types.h"
17 17
18 #if defined(OS_CHROMEOS) 18 #if defined(OS_CHROMEOS)
19 #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" 19 #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h"
20 #endif // OS_CHROMEOS 20 #endif // OS_CHROMEOS
21 21
22 class Browser; 22 class Browser;
23 class ContentSettingBubbleModel; 23 class ContentSettingBubbleModel;
24 class GURL; 24 class GURL;
25 class LoginHandler; 25 class LoginHandler;
26 class Profile; 26 class Profile;
27 27
28 namespace base {
29 struct Feature;
30 }
31
32 namespace bookmarks { 28 namespace bookmarks {
33 class BookmarkBubbleObserver; 29 class BookmarkBubbleObserver;
34 } 30 }
35 31
36 namespace content { 32 namespace content {
37 class BrowserContext; 33 class BrowserContext;
38 class ColorChooser; 34 class ColorChooser;
39 class WebContents; 35 class WebContents;
40 } 36 }
41 37
(...skipping 18 matching lines...) Expand all
60 namespace task_manager { 56 namespace task_manager {
61 class TaskManagerTableModel; 57 class TaskManagerTableModel;
62 } 58 }
63 59
64 namespace ui { 60 namespace ui {
65 class WebDialogDelegate; 61 class WebDialogDelegate;
66 } 62 }
67 63
68 namespace chrome { 64 namespace chrome {
69 65
70 #if defined(OS_MACOSX)
71 // Makes ToolkitViewsDialogsEnabled() available to chrome://flags.
72 extern const base::Feature kMacViewsNativeDialogs;
73
74 // Makes ToolkitViewsWebUIDialogsEnabled() available to chrome://flags.
75 extern const base::Feature kMacViewsWebUIDialogs;
76 #endif // OS_MACOSX
77
78 // Shows or hides the Task Manager. |browser| can be NULL when called from Ash. 66 // Shows or hides the Task Manager. |browser| can be NULL when called from Ash.
79 // Returns a pointer to the underlying TableModel, which can be ignored, or used 67 // Returns a pointer to the underlying TableModel, which can be ignored, or used
80 // for testing. 68 // for testing.
81 task_manager::TaskManagerTableModel* ShowTaskManager(Browser* browser); 69 task_manager::TaskManagerTableModel* ShowTaskManager(Browser* browser);
82 void HideTaskManager(); 70 void HideTaskManager();
83 71
84 #if !defined(OS_MACOSX) 72 #if !defined(OS_MACOSX)
85 // Creates and shows an HTML dialog with the given delegate and context. 73 // Creates and shows an HTML dialog with the given delegate and context.
86 // The window is automatically destroyed when it is closed. 74 // The window is automatically destroyed when it is closed.
87 // Returns the created window. 75 // Returns the created window.
(...skipping 28 matching lines...) Expand all
116 Profile* profile, 104 Profile* profile,
117 const extensions::Extension* app, 105 const extensions::Extension* app,
118 const base::Callback<void(bool /* created */)>& close_callback); 106 const base::Callback<void(bool /* created */)>& close_callback);
119 107
120 // Shows a color chooser that reports to the given WebContents. 108 // Shows a color chooser that reports to the given WebContents.
121 content::ColorChooser* ShowColorChooser(content::WebContents* web_contents, 109 content::ColorChooser* ShowColorChooser(content::WebContents* web_contents,
122 SkColor initial_color); 110 SkColor initial_color);
123 111
124 #if defined(OS_MACOSX) 112 #if defined(OS_MACOSX)
125 113
126 // For Mac, returns true if Chrome should show an equivalent toolkit-views based
127 // dialog instead of a native-looking Cocoa dialog.
128 bool ToolkitViewsDialogsEnabled();
129
130 // For Mac, returns true if Chrome should show an equivalent toolkit-views based
131 // dialog instead of a WebUI-styled Cocoa dialog.
132 bool ToolkitViewsWebUIDialogsEnabled();
133
134 // Shows a Views website settings bubble at the given anchor point. 114 // Shows a Views website settings bubble at the given anchor point.
135 void ShowWebsiteSettingsBubbleViewsAtPoint( 115 void ShowWebsiteSettingsBubbleViewsAtPoint(
136 const gfx::Point& anchor_point, 116 const gfx::Point& anchor_point,
137 Profile* profile, 117 Profile* profile,
138 content::WebContents* web_contents, 118 content::WebContents* web_contents,
139 const GURL& virtual_url, 119 const GURL& virtual_url,
140 const security_state::SecurityInfo& security_info); 120 const security_state::SecurityInfo& security_info);
141 121
142 // Show a Views bookmark bubble at the given point. This occurs when the 122 // Show a Views bookmark bubble at the given point. This occurs when the
143 // bookmark star is clicked or "Bookmark This Page..." is selected from a menu 123 // bookmark star is clicked or "Bookmark This Page..." is selected from a menu
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 using BubbleShowPtr = 182 using BubbleShowPtr =
203 void (*)(content::WebContents*, 183 void (*)(content::WebContents*,
204 const std::vector<arc::ArcNavigationThrottle::AppInfo>&, 184 const std::vector<arc::ArcNavigationThrottle::AppInfo>&,
205 const IntentPickerResponse&); 185 const IntentPickerResponse&);
206 186
207 BubbleShowPtr ShowIntentPickerBubble(); 187 BubbleShowPtr ShowIntentPickerBubble();
208 188
209 #endif // OS_CHROMEOS 189 #endif // OS_CHROMEOS
210 190
211 #endif // CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ 191 #endif // CHROME_BROWSER_UI_BROWSER_DIALOGS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698