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

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

Issue 10834079: views: Extract Widget observer into its own header file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/view.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 446b7b2de96529417a23c4e1c73570ba8ed29443..e0449bf0c2a18dc93427649379eaa34ec0d4c718 100644
--- a/ui/views/bubble/bubble_delegate.cc
+++ b/ui/views/bubble/bubble_delegate.cc
@@ -8,6 +8,7 @@
#include "ui/gfx/color_utils.h"
#include "ui/views/bubble/bubble_frame_view.h"
#include "ui/views/widget/widget.h"
+#include "ui/views/widget/widget_observer.h"
// The duration of the fade animation in milliseconds.
static const int kHideFadeDurationMS = 200;
@@ -44,7 +45,7 @@ Widget* CreateBubbleWidget(BubbleDelegateView* bubble) {
// transparent native controls and use per-pixel HWND alpha on the border.
// TODO(msw): Clean these up when Windows native controls are no longer needed.
class BubbleBorderDelegate : public WidgetDelegate,
- public Widget::Observer {
+ public WidgetObserver {
public:
BubbleBorderDelegate(BubbleDelegateView* bubble, Widget* widget)
: bubble_(bubble),
@@ -63,11 +64,11 @@ class BubbleBorderDelegate : public WidgetDelegate,
virtual Widget* GetWidget() OVERRIDE { return widget_; }
virtual const Widget* GetWidget() const OVERRIDE { return widget_; }
virtual NonClientFrameView* CreateNonClientFrameView(
- views::Widget* widget) OVERRIDE {
+ Widget* widget) OVERRIDE {
return bubble_->CreateNonClientFrameView(widget);
}
- // Widget::Observer overrides:
+ // WidgetObserver overrides:
virtual void OnWidgetClosing(Widget* widget) OVERRIDE {
bubble_ = NULL;
widget_->Close();
@@ -115,7 +116,7 @@ BubbleDelegateView::BubbleDelegateView()
border_widget_(NULL),
use_focusless_(false),
parent_window_(NULL) {
- set_background(views::Background::CreateSolidBackground(color_));
+ set_background(Background::CreateSolidBackground(color_));
AddAccelerator(ui::Accelerator(ui::VKEY_ESCAPE, ui::EF_NONE));
}
@@ -134,7 +135,7 @@ BubbleDelegateView::BubbleDelegateView(
border_widget_(NULL),
use_focusless_(false),
parent_window_(NULL) {
- set_background(views::Background::CreateSolidBackground(color_));
+ set_background(Background::CreateSolidBackground(color_));
AddAccelerator(ui::Accelerator(ui::VKEY_ESCAPE, ui::EF_NONE));
}
« no previous file with comments | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698