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

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

Issue 2675983003: views::Separator cleanup. (Closed)
Patch Set: revert test change 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
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/find_bar_view.h" 5 #include "chrome/browser/ui/views/find_bar_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/i18n/number_formatting.h" 9 #include "base/i18n/number_formatting.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 } // namespace 109 } // namespace
110 110
111 //////////////////////////////////////////////////////////////////////////////// 111 ////////////////////////////////////////////////////////////////////////////////
112 // FindBarView, public: 112 // FindBarView, public:
113 113
114 FindBarView::FindBarView(FindBarHost* host) 114 FindBarView::FindBarView(FindBarHost* host)
115 : find_bar_host_(host), 115 : find_bar_host_(host),
116 find_text_(new views::Textfield), 116 find_text_(new views::Textfield),
117 match_count_text_(new MatchCountLabel()), 117 match_count_text_(new MatchCountLabel()),
118 focus_forwarder_view_(new FocusForwarderView(find_text_)), 118 focus_forwarder_view_(new FocusForwarderView(find_text_)),
119 separator_(new views::Separator(views::Separator::VERTICAL)), 119 separator_(new views::Separator()),
120 find_previous_button_(new views::VectorIconButton(this)), 120 find_previous_button_(new views::VectorIconButton(this)),
121 find_next_button_(new views::VectorIconButton(this)), 121 find_next_button_(new views::VectorIconButton(this)),
122 close_button_(new views::VectorIconButton(this)) { 122 close_button_(new views::VectorIconButton(this)) {
123 find_text_->set_id(VIEW_ID_FIND_IN_PAGE_TEXT_FIELD); 123 find_text_->set_id(VIEW_ID_FIND_IN_PAGE_TEXT_FIELD);
124 find_text_->set_default_width_in_chars(kDefaultCharWidth); 124 find_text_->set_default_width_in_chars(kDefaultCharWidth);
125 find_text_->set_controller(this); 125 find_text_->set_controller(this);
126 find_text_->SetAccessibleName(l10n_util::GetStringUTF16(IDS_ACCNAME_FIND)); 126 find_text_->SetAccessibleName(l10n_util::GetStringUTF16(IDS_ACCNAME_FIND));
127 find_text_->SetTextInputFlags(ui::TEXT_INPUT_FLAG_AUTOCORRECT_OFF); 127 find_text_->SetTextInputFlags(ui::TEXT_INPUT_FLAG_AUTOCORRECT_OFF);
128 AddChildView(find_text_); 128 AddChildView(find_text_);
129 129
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 set_background(new views::BubbleBackground(border.get())); 417 set_background(new views::BubbleBackground(border.get()));
418 SetBorder(std::move(border)); 418 SetBorder(std::move(border));
419 419
420 match_count_text_->SetBackgroundColor(bg_color); 420 match_count_text_->SetBackgroundColor(bg_color);
421 SkColor text_color = 421 SkColor text_color =
422 theme->GetSystemColor(ui::NativeTheme::kColorId_TextfieldDefaultColor); 422 theme->GetSystemColor(ui::NativeTheme::kColorId_TextfieldDefaultColor);
423 match_count_text_->SetEnabledColor(SkColorSetA(text_color, 0x69)); 423 match_count_text_->SetEnabledColor(SkColorSetA(text_color, 0x69));
424 separator_->SetColor(SkColorSetA(text_color, 0x26)); 424 separator_->SetColor(SkColorSetA(text_color, 0x26));
425 } 425 }
426 426
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698