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

Side by Side Diff: chrome/browser/ui/cocoa/constrained_window/constrained_window_mac.h

Issue 1234073002: Allow cert-popup for WebView guests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add comment. Created 5 years, 5 months 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_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_ 5 #ifndef CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_
6 #define CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_ 6 #define CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 9
10 namespace content { 10 namespace content {
(...skipping 13 matching lines...) Expand all
24 // Constrained window implementation for Mac. 24 // Constrained window implementation for Mac.
25 // Normally an instance of this class is owned by the delegate. The delegate 25 // Normally an instance of this class is owned by the delegate. The delegate
26 // should delete the instance when the window is closed. 26 // should delete the instance when the window is closed.
27 class ConstrainedWindowMac { 27 class ConstrainedWindowMac {
28 public: 28 public:
29 ConstrainedWindowMac(ConstrainedWindowMacDelegate* delegate, 29 ConstrainedWindowMac(ConstrainedWindowMacDelegate* delegate,
30 content::WebContents* web_contents, 30 content::WebContents* web_contents,
31 id<ConstrainedWindowSheet> sheet); 31 id<ConstrainedWindowSheet> sheet);
32 ~ConstrainedWindowMac(); 32 ~ConstrainedWindowMac();
33 33
34 // Indicates if the dialog can be successfully shown.
35 // TODO(davidben): Remove this when the certificate selector prompt is moved
36 // to the WebContentsDelegate. https://crbug.com/456255.
37 static bool HasTopLevelDialogManager(content::WebContents* web_contents);
38
34 // Closes the constrained window. 39 // Closes the constrained window.
35 void CloseWebContentsModalDialog(); 40 void CloseWebContentsModalDialog();
36 41
37 SingleWebContentsDialogManagerCocoa* manager() const { return manager_; } 42 SingleWebContentsDialogManagerCocoa* manager() const { return manager_; }
38 void set_manager(SingleWebContentsDialogManagerCocoa* manager) { 43 void set_manager(SingleWebContentsDialogManagerCocoa* manager) {
39 manager_ = manager; 44 manager_ = manager;
40 } 45 }
41 46
42 // Called by |manager_| when the dialog is closing. 47 // Called by |manager_| when the dialog is closing.
43 void OnDialogClosing(); 48 void OnDialogClosing();
44 49
45 private: 50 private:
46 ConstrainedWindowMacDelegate* delegate_; // weak, owns us. 51 ConstrainedWindowMacDelegate* delegate_; // weak, owns us.
47 SingleWebContentsDialogManagerCocoa* manager_; // weak, owned by WCMDM. 52 SingleWebContentsDialogManagerCocoa* manager_; // weak, owned by WCMDM.
48 }; 53 };
49 54
50 #endif // CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_ 55 #endif // CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_MAC_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698