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

Side by Side Diff: chrome/views/view.h

Issue 100221: Adds a GetWindow method to View. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 7 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 | « chrome/browser/views/frame/browser_view.cc ('k') | chrome/views/view.cc » ('j') | 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #ifndef CHROME_VIEWS_VIEW_H_ 5 #ifndef CHROME_VIEWS_VIEW_H_
6 #define CHROME_VIEWS_VIEW_H_ 6 #define CHROME_VIEWS_VIEW_H_
7 7
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #if defined(OS_WIN) 10 #if defined(OS_WIN)
(...skipping 27 matching lines...) Expand all
38 38
39 class Background; 39 class Background;
40 class Border; 40 class Border;
41 class FocusManager; 41 class FocusManager;
42 class FocusTraversable; 42 class FocusTraversable;
43 class LayoutManager; 43 class LayoutManager;
44 class RestoreFocusTask; 44 class RestoreFocusTask;
45 class RootView; 45 class RootView;
46 class ScrollView; 46 class ScrollView;
47 class Widget; 47 class Widget;
48 class Window;
48 49
49 // ContextMenuController is responsible for showing the context menu for a 50 // ContextMenuController is responsible for showing the context menu for a
50 // View. To use a ContextMenuController invoke SetContextMenuController on a 51 // View. To use a ContextMenuController invoke SetContextMenuController on a
51 // View. When the appropriate user gesture occurs ShowContextMenu is invoked 52 // View. When the appropriate user gesture occurs ShowContextMenu is invoked
52 // on the ContextMenuController. 53 // on the ContextMenuController.
53 // 54 //
54 // Setting a ContextMenuController on a view makes the view process mouse 55 // Setting a ContextMenuController on a view makes the view process mouse
55 // events. 56 // events.
56 // 57 //
57 // It is up to subclasses that do their own mouse processing to invoke 58 // It is up to subclasses that do their own mouse processing to invoke
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after
426 427
427 // Get the number of child Views. 428 // Get the number of child Views.
428 int GetChildViewCount() const; 429 int GetChildViewCount() const;
429 430
430 // Get the child View at the specified point. 431 // Get the child View at the specified point.
431 virtual View* GetViewForPoint(const gfx::Point& point); 432 virtual View* GetViewForPoint(const gfx::Point& point);
432 433
433 // Get the Widget that hosts this View, if any. 434 // Get the Widget that hosts this View, if any.
434 virtual Widget* GetWidget() const; 435 virtual Widget* GetWidget() const;
435 436
437 // Gets the Widget that most closely contains this View, if any.
438 virtual Window* GetWindow() const;
439
436 // Get the containing RootView 440 // Get the containing RootView
437 virtual RootView* GetRootView(); 441 virtual RootView* GetRootView();
438 442
439 // Get the parent View 443 // Get the parent View
440 View* GetParent() const { return parent_; } 444 View* GetParent() const { return parent_; }
441 445
442 // Returns the index of the specified |view| in this view's children, or -1 446 // Returns the index of the specified |view| in this view's children, or -1
443 // if the specified view is not a child of this view. 447 // if the specified view is not a child of this view.
444 int GetChildIndex(View* v) const; 448 int GetChildIndex(View* v) const;
445 449
(...skipping 892 matching lines...) Expand 10 before | Expand all | Expand 10 after
1338 // is going to be flipped horizontally (using the appropriate transform) on 1342 // is going to be flipped horizontally (using the appropriate transform) on
1339 // right-to-left locales for this View. 1343 // right-to-left locales for this View.
1340 bool flip_canvas_on_paint_for_rtl_ui_; 1344 bool flip_canvas_on_paint_for_rtl_ui_;
1341 1345
1342 DISALLOW_COPY_AND_ASSIGN(View); 1346 DISALLOW_COPY_AND_ASSIGN(View);
1343 }; 1347 };
1344 1348
1345 } // namespace views 1349 } // namespace views
1346 1350
1347 #endif // CHROME_VIEWS_VIEW_H_ 1351 #endif // CHROME_VIEWS_VIEW_H_
OLDNEW
« no previous file with comments | « chrome/browser/views/frame/browser_view.cc ('k') | chrome/views/view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698