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

Unified Diff: ui/views/bubble/bubble_delegate.cc

Issue 8833004: Remove BubbleDelegateView ctor color arg, add simple setter/getter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pass set_color SkColor arg by value. Created 9 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/bubble/bubble_delegate_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/bubble/bubble_delegate.cc
diff --git a/ui/views/bubble/bubble_delegate.cc b/ui/views/bubble/bubble_delegate.cc
index f262a3346a049ffe29c8a7c29042dc91509c62d0..72f20b87af519a9cfe43fba2c3a0dd8fb8eaffc7 100644
--- a/ui/views/bubble/bubble_delegate.cc
+++ b/ui/views/bubble/bubble_delegate.cc
@@ -80,7 +80,8 @@ BubbleDelegateView::BubbleDelegateView()
allow_bubble_offscreen_(false),
anchor_view_(NULL),
arrow_location_(BubbleBorder::TOP_LEFT),
- color_(SK_ColorWHITE),
+ color_(kBackgroundColor),
+ original_opacity_(255),
border_widget_(NULL),
use_focusless_(false) {
set_background(views::Background::CreateSolidBackground(color_));
@@ -89,14 +90,13 @@ BubbleDelegateView::BubbleDelegateView()
BubbleDelegateView::BubbleDelegateView(
View* anchor_view,
- BubbleBorder::ArrowLocation arrow_location,
- const SkColor& color)
+ BubbleBorder::ArrowLocation arrow_location)
: close_on_esc_(true),
close_on_deactivate_(true),
allow_bubble_offscreen_(false),
anchor_view_(anchor_view),
arrow_location_(arrow_location),
- color_(color),
+ color_(kBackgroundColor),
original_opacity_(255),
border_widget_(NULL),
use_focusless_(false) {
@@ -142,8 +142,8 @@ View* BubbleDelegateView::GetContentsView() {
NonClientFrameView* BubbleDelegateView::CreateNonClientFrameView() {
return new BubbleFrameView(GetArrowLocation(),
GetPreferredSize(),
- GetColor(),
- allow_bubble_offscreen_);
+ color(),
+ allow_bubble_offscreen());
}
void BubbleDelegateView::OnWidgetActivationChanged(Widget* widget,
@@ -177,10 +177,6 @@ BubbleBorder::ArrowLocation BubbleDelegateView::GetArrowLocation() const {
return arrow_location_;
}
-SkColor BubbleDelegateView::GetColor() const {
- return color_;
-}
-
void BubbleDelegateView::Show() {
if (border_widget_)
border_widget_->Show();
« no previous file with comments | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/bubble/bubble_delegate_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698