diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-21 16:12:34 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-21 16:12:34 +0000 |
commit | 3aa90ad5278b3e021dd4477bd0199dce6b2272ea (patch) | |
tree | b4f5f778cb60fe18f88e0491e988a2c1ec6d08ad /views/test | |
parent | b0ea7a8229abf2401cdfd75024ceeed829038883 (diff) | |
download | chromium_src-3aa90ad5278b3e021dd4477bd0199dce6b2272ea.zip chromium_src-3aa90ad5278b3e021dd4477bd0199dce6b2272ea.tar.gz chromium_src-3aa90ad5278b3e021dd4477bd0199dce6b2272ea.tar.bz2 |
Change NativeWidgetViews' constructor to not take a parent View. The embedding environment provides this instead via a new ViewsDelegate method: GetDefaultParentView().
This makes the constructors of NativeWidgetViews compatible with the other platforms and allows all of the existing construction patterns to be preserved (there is not a clear way to wire a desktop view through to all of them).
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/7204041
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89832 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/test')
-rw-r--r-- | views/test/test_views_delegate.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/views/test/test_views_delegate.h b/views/test/test_views_delegate.h index 45a2341..7f54967 100644 --- a/views/test/test_views_delegate.h +++ b/views/test/test_views_delegate.h @@ -10,7 +10,9 @@ #include "ui/base/clipboard/clipboard.h" #include "views/views_delegate.h" +// TODO(beng): this whole file should be in the views namespace. namespace views { +class View; class Widget; } @@ -20,18 +22,19 @@ class TestViewsDelegate : public views::ViewsDelegate { virtual ~TestViewsDelegate(); // Overridden from views::ViewsDelegate: - virtual ui::Clipboard* GetClipboard() const; + virtual ui::Clipboard* GetClipboard() const OVERRIDE; + virtual views::View* GetDefaultParentView() OVERRIDE { return NULL; } virtual void SaveWindowPlacement(const views::Widget* window, const std::wstring& window_name, const gfx::Rect& bounds, bool maximized) OVERRIDE { } virtual bool GetSavedWindowBounds(const views::Widget* window, const std::wstring& window_name, - gfx::Rect* bounds) const; + gfx::Rect* bounds) const OVERRIDE; virtual bool GetSavedMaximizedState(const views::Widget* window, const std::wstring& window_name, - bool* maximized) const; + bool* maximized) const OVERRIDE; virtual void NotifyAccessibilityEvent( views::View* view, ui::AccessibilityTypes::Event event_type) OVERRIDE {} @@ -41,7 +44,7 @@ class TestViewsDelegate : public views::ViewsDelegate { const std::wstring& menu_item_name, int item_index, int item_count, - bool has_submenu) {} + bool has_submenu) OVERRIDE {} #if defined(OS_WIN) virtual HICON GetDefaultWindowIcon() const OVERRIDE { return NULL; |