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

Side by Side Diff: ui/views/widget/root_view.cc

Issue 7104042: ui/views: Fix the signature of View::OnViewAdded/Removed overridden methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sky,peter review Created 9 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « ui/views/widget/root_view.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "ui/views/widget/root_view.h" 5 #include "ui/views/widget/root_view.h"
6 6
7 #include "ui/views/focus/focus_manager.h" 7 #include "ui/views/focus/focus_manager.h"
8 #include "ui/views/layout/fill_layout.h" 8 #include "ui/views/layout/fill_layout.h"
9 #include "ui/views/widget/widget.h" 9 #include "ui/views/widget/widget.h"
10 10
(...skipping 13 matching lines...) Expand all
24 SetLayoutManager(new FillLayout); 24 SetLayoutManager(new FillLayout);
25 AddChildView(contents_view); 25 AddChildView(contents_view);
26 } 26 }
27 27
28 RootView::~RootView() { 28 RootView::~RootView() {
29 } 29 }
30 30
31 //////////////////////////////////////////////////////////////////////////////// 31 ////////////////////////////////////////////////////////////////////////////////
32 // RootView, View overrides: 32 // RootView, View overrides:
33 33
34 void RootView::OnViewRemoved(View* parent, View* child) { 34 void RootView::OnViewRemoved(const View& parent, const View& child) {
35 if (child == mouse_pressed_handler_) 35 if (&child == mouse_pressed_handler_)
36 mouse_pressed_handler_ = NULL; 36 mouse_pressed_handler_ = NULL;
37 37
38 GetFocusManager()->RemoveView(child); 38 GetFocusManager()->RemoveView(&child);
39 } 39 }
40 40
41 bool RootView::OnKeyPressed(const KeyEvent& event) { 41 bool RootView::OnKeyPressed(const KeyEvent& event) {
42 return true; 42 return true;
43 } 43 }
44 44
45 bool RootView::OnKeyReleased(const KeyEvent& event) { 45 bool RootView::OnKeyReleased(const KeyEvent& event) {
46 return true; 46 return true;
47 } 47 }
48 48
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 View* RootView::GetFocusTraversableParentView() const { 158 View* RootView::GetFocusTraversableParentView() const {
159 return focus_traversable_parent_view_; 159 return focus_traversable_parent_view_;
160 } 160 }
161 161
162 162
163 //////////////////////////////////////////////////////////////////////////////// 163 ////////////////////////////////////////////////////////////////////////////////
164 // RootView, private: 164 // RootView, private:
165 165
166 } // namespace internal 166 } // namespace internal
167 } // namespace ui 167 } // namespace ui
OLDNEW
« no previous file with comments | « ui/views/widget/root_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698