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

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

Issue 2718533004: Add SolidSidedWidgetBorder
Patch Set: Created 3 years, 10 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 | « no previous file | ui/views/border.h » ('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/autofill/autofill_popup_base_view.h" 5 #include "chrome/browser/ui/views/autofill/autofill_popup_base_view.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/single_thread_task_runner.h" 9 #include "base/single_thread_task_runner.h"
10 #include "base/threading/thread_task_runner_handle.h" 10 #include "base/threading/thread_task_runner_handle.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 params.parent = parent_widget_->GetNativeView(); 55 params.parent = parent_widget_->GetNativeView();
56 widget->Init(params); 56 widget->Init(params);
57 57
58 // No animation for popup appearance (too distracting). 58 // No animation for popup appearance (too distracting).
59 widget->SetVisibilityAnimationTransition(views::Widget::ANIMATE_HIDE); 59 widget->SetVisibilityAnimationTransition(views::Widget::ANIMATE_HIDE);
60 60
61 show_time_ = base::Time::Now(); 61 show_time_ = base::Time::Now();
62 } 62 }
63 63
64 // TODO(crbug.com/676164): Show different border color when focused/unfocused 64 // TODO(crbug.com/676164): Show different border color when focused/unfocused
65 SetBorder(views::CreateSolidBorder( 65 SetBorder(views::CreateSolidWidgetBorder(
66 kPopupBorderThickness, 66 kPopupBorderThickness,
67 GetNativeTheme()->GetSystemColor( 67 GetNativeTheme()->GetSystemColor(
68 ui::NativeTheme::kColorId_UnfocusedBorderColor))); 68 ui::NativeTheme::kColorId_UnfocusedBorderColor)));
69 69
70 DoUpdateBoundsAndRedrawPopup(); 70 DoUpdateBoundsAndRedrawPopup();
71 GetWidget()->Show(); 71 GetWidget()->Show();
72 72
73 // Showing the widget can change native focus (which would result in an 73 // Showing the widget can change native focus (which would result in an
74 // immediate hiding of the popup). Only start observing after shown. 74 // immediate hiding of the popup). Only start observing after shown.
75 if (initialize_widget) 75 if (initialize_widget)
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 void AutofillPopupBaseView::HideController() { 235 void AutofillPopupBaseView::HideController() {
236 if (delegate_) 236 if (delegate_)
237 delegate_->Hide(); 237 delegate_->Hide();
238 } 238 }
239 239
240 gfx::NativeView AutofillPopupBaseView::container_view() { 240 gfx::NativeView AutofillPopupBaseView::container_view() {
241 return delegate_->container_view(); 241 return delegate_->container_view();
242 } 242 }
243 243
244 } // namespace autofill 244 } // namespace autofill
OLDNEW
« no previous file with comments | « no previous file | ui/views/border.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698