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

Side by Side Diff: chrome/browser/ui/views/tab_dialogs_views.cc

Issue 1053463002: MacViews: Use native certificate viewer in MacViews browser. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@translate
Patch Set: Fix for tapted and rebase Created 5 years, 8 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
« no previous file with comments | « chrome/browser/ui/views/tab_dialogs_views.h ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "chrome/browser/ui/views/tab_dialogs_views.h" 5 #include "chrome/browser/ui/views/tab_dialogs_views.h"
6 6
7 #include "chrome/browser/ui/views/collected_cookies_views.h" 7 #include "chrome/browser/ui/views/collected_cookies_views.h"
8 #include "chrome/browser/ui/views/hung_renderer_view.h" 8 #include "chrome/browser/ui/views/hung_renderer_view.h"
9 #include "chrome/browser/ui/views/passwords/manage_passwords_bubble_view.h" 9 #include "chrome/browser/ui/views/passwords/manage_passwords_bubble_view.h"
10 #include "chrome/browser/ui/views/sync/profile_signin_confirmation_dialog_views. h" 10 #include "chrome/browser/ui/views/sync/profile_signin_confirmation_dialog_views. h"
11 #include "chrome/browser/ui/views/validation_message_bubble_view.h" 11 #include "chrome/browser/ui/views/validation_message_bubble_view.h"
12 #include "content/public/browser/web_contents.h" 12 #include "content/public/browser/web_contents.h"
13 13
14 // static 14 // static
15 void TabDialogs::CreateForWebContents(content::WebContents* contents) { 15 void TabDialogs::CreateForWebContents(content::WebContents* contents) {
16 DCHECK(contents); 16 DCHECK(contents);
17 if (!FromWebContents(contents)) 17 if (!FromWebContents(contents))
18 contents->SetUserData(UserDataKey(), new TabDialogsViews(contents)); 18 contents->SetUserData(UserDataKey(), new TabDialogsViews(contents));
19 } 19 }
20 20
21 TabDialogsViews::TabDialogsViews(content::WebContents* contents) 21 TabDialogsViews::TabDialogsViews(content::WebContents* contents)
22 : web_contents_(contents) { 22 : web_contents_(contents) {
23 DCHECK(contents); 23 DCHECK(contents);
24 } 24 }
25 25
26 TabDialogsViews::~TabDialogsViews() { 26 TabDialogsViews::~TabDialogsViews() {
27 } 27 }
28 28
29 gfx::NativeView TabDialogsViews::GetDialogParentView() const {
30 return web_contents_->GetNativeView();
31 }
32
29 void TabDialogsViews::ShowCollectedCookies() { 33 void TabDialogsViews::ShowCollectedCookies() {
30 // Deletes itself on close. 34 // Deletes itself on close.
31 new CollectedCookiesViews(web_contents_); 35 new CollectedCookiesViews(web_contents_);
32 } 36 }
33 37
34 void TabDialogsViews::ShowHungRendererDialog() { 38 void TabDialogsViews::ShowHungRendererDialog() {
35 HungRendererDialogView::Show(web_contents_); 39 HungRendererDialogView::Show(web_contents_);
36 } 40 }
37 41
38 void TabDialogsViews::HideHungRendererDialog() { 42 void TabDialogsViews::HideHungRendererDialog() {
(...skipping 29 matching lines...) Expand all
68 ManagePasswordsBubbleView::CloseBubble(); 72 ManagePasswordsBubbleView::CloseBubble();
69 } 73 }
70 74
71 scoped_ptr<ValidationMessageBubble> TabDialogsViews::ShowValidationMessage( 75 scoped_ptr<ValidationMessageBubble> TabDialogsViews::ShowValidationMessage(
72 const gfx::Rect& anchor_in_root_view, 76 const gfx::Rect& anchor_in_root_view,
73 const base::string16& main_text, 77 const base::string16& main_text,
74 const base::string16& sub_text) { 78 const base::string16& sub_text) {
75 return make_scoped_ptr(new ValidationMessageBubbleView( 79 return make_scoped_ptr(new ValidationMessageBubbleView(
76 web_contents_, anchor_in_root_view, main_text, sub_text)); 80 web_contents_, anchor_in_root_view, main_text, sub_text));
77 } 81 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/tab_dialogs_views.h ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698