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

Side by Side Diff: chrome/browser/ui/views/autofill/autofill_dialog_views.cc

Issue 231173004: [WebModal] Rename NativeWebContentsModalDialogManager to SingleWebContentsDialogManager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 | Annotate | Revision Log
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 #include "chrome/browser/ui/views/autofill/autofill_dialog_views.h" 5 #include "chrome/browser/ui/views/autofill/autofill_dialog_views.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 1205 matching lines...) Expand 10 before | Expand all | Expand 10 after
1216 // Ownership of |contents_| is handed off by this call. The widget will take 1216 // Ownership of |contents_| is handed off by this call. The widget will take
1217 // care of deleting itself after calling DeleteDelegate(). 1217 // care of deleting itself after calling DeleteDelegate().
1218 WebContentsModalDialogManager* web_contents_modal_dialog_manager = 1218 WebContentsModalDialogManager* web_contents_modal_dialog_manager =
1219 WebContentsModalDialogManager::FromWebContents( 1219 WebContentsModalDialogManager::FromWebContents(
1220 delegate_->GetWebContents()); 1220 delegate_->GetWebContents());
1221 WebContentsModalDialogManagerDelegate* modal_delegate = 1221 WebContentsModalDialogManagerDelegate* modal_delegate =
1222 web_contents_modal_dialog_manager->delegate(); 1222 web_contents_modal_dialog_manager->delegate();
1223 DCHECK(modal_delegate); 1223 DCHECK(modal_delegate);
1224 window_ = views::Widget::CreateWindowAsFramelessChild( 1224 window_ = views::Widget::CreateWindowAsFramelessChild(
1225 this, modal_delegate->GetWebContentsModalDialogHost()->GetHostView()); 1225 this, modal_delegate->GetWebContentsModalDialogHost()->GetHostView());
1226 web_contents_modal_dialog_manager->ShowDialog(window_->GetNativeView()); 1226 web_contents_modal_dialog_manager->ShowWebModalDialog(
1227 window_->GetNativeView());
1227 focus_manager_ = window_->GetFocusManager(); 1228 focus_manager_ = window_->GetFocusManager();
1228 focus_manager_->AddFocusChangeListener(this); 1229 focus_manager_->AddFocusChangeListener(this);
1229 1230
1230 ShowDialogInMode(DETAIL_INPUT); 1231 ShowDialogInMode(DETAIL_INPUT);
1231 1232
1232 // Listen for size changes on the browser. 1233 // Listen for size changes on the browser.
1233 views::Widget* browser_widget = 1234 views::Widget* browser_widget =
1234 views::Widget::GetTopLevelWidgetForNativeView( 1235 views::Widget::GetTopLevelWidgetForNativeView(
1235 delegate_->GetWebContents()->GetView()->GetNativeView()); 1236 delegate_->GetWebContents()->GetView()->GetNativeView());
1236 observer_.Add(browser_widget); 1237 observer_.Add(browser_widget);
(...skipping 1253 matching lines...) Expand 10 before | Expand all | Expand 10 after
2490 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section) 2491 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section)
2491 : section(section), 2492 : section(section),
2492 container(NULL), 2493 container(NULL),
2493 manual_input(NULL), 2494 manual_input(NULL),
2494 suggested_info(NULL), 2495 suggested_info(NULL),
2495 suggested_button(NULL) {} 2496 suggested_button(NULL) {}
2496 2497
2497 AutofillDialogViews::DetailsGroup::~DetailsGroup() {} 2498 AutofillDialogViews::DetailsGroup::~DetailsGroup() {}
2498 2499
2499 } // namespace autofill 2500 } // namespace autofill
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698