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

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

Issue 145033006: views: Make View::set_border() take a scoped_ptr<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to ToT Created 6 years, 11 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 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/autofill/autofill_popup_base_view.h" 5 #include "chrome/browser/ui/views/autofill/autofill_popup_base_view.h"
6 6
7 #include "chrome/browser/ui/autofill/popup_constants.h" 7 #include "chrome/browser/ui/autofill/popup_constants.h"
8 #include "ui/gfx/point.h" 8 #include "ui/gfx/point.h"
9 #include "ui/gfx/screen.h" 9 #include "ui/gfx/screen.h"
10 #include "ui/views/border.h" 10 #include "ui/views/border.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 params.parent = container_view(); 56 params.parent = container_view();
57 widget->Init(params); 57 widget->Init(params);
58 widget->SetContentsView(this); 58 widget->SetContentsView(this);
59 #if defined(USE_AURA) 59 #if defined(USE_AURA)
60 // No animation for popup appearance (too distracting). 60 // No animation for popup appearance (too distracting).
61 views::corewm::SetWindowVisibilityAnimationTransition( 61 views::corewm::SetWindowVisibilityAnimationTransition(
62 widget->GetNativeView(), views::corewm::ANIMATE_HIDE); 62 widget->GetNativeView(), views::corewm::ANIMATE_HIDE);
63 #endif 63 #endif
64 } 64 }
65 65
66 set_border(views::Border::CreateSolidBorder(kPopupBorderThickness, 66 SetBorder(views::Border::CreateSolidBorder(kPopupBorderThickness,
67 kBorderColor)); 67 kBorderColor));
68 68
69 DoUpdateBoundsAndRedrawPopup(); 69 DoUpdateBoundsAndRedrawPopup();
70 GetWidget()->Show(); 70 GetWidget()->Show();
71 71
72 if (ShouldHideOnOutsideClick()) 72 if (ShouldHideOnOutsideClick())
73 GetWidget()->SetCapture(this); 73 GetWidget()->SetCapture(this);
74 } 74 }
75 75
76 void AutofillPopupBaseView::DoHide() { 76 void AutofillPopupBaseView::DoHide() {
77 // The controller is no longer valid after it hides us. 77 // The controller is no longer valid after it hides us.
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 bool AutofillPopupBaseView::ShouldRepostEvent(const ui::MouseEvent& event) { 232 bool AutofillPopupBaseView::ShouldRepostEvent(const ui::MouseEvent& event) {
233 return delegate_->ShouldRepostEvent(event); 233 return delegate_->ShouldRepostEvent(event);
234 } 234 }
235 235
236 gfx::NativeView AutofillPopupBaseView::container_view() { 236 gfx::NativeView AutofillPopupBaseView::container_view() {
237 return delegate_->container_view(); 237 return delegate_->container_view();
238 } 238 }
239 239
240 240
241 } // namespace autofill 241 } // namespace autofill
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/autofill/autofill_dialog_views.cc ('k') | chrome/browser/ui/views/autofill/decorated_textfield.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698