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

Side by Side Diff: ui/aura/window.h

Issue 173443002: aura: Take transformation into account when computing window bounds in root-window/screen. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 10 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_AURA_WINDOW_H_ 5 #ifndef UI_AURA_WINDOW_H_
6 #define UI_AURA_WINDOW_H_ 6 #define UI_AURA_WINDOW_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // Changes the visibility of the window. 140 // Changes the visibility of the window.
141 void Show(); 141 void Show();
142 void Hide(); 142 void Hide();
143 // Returns true if this window and all its ancestors are visible. 143 // Returns true if this window and all its ancestors are visible.
144 bool IsVisible() const; 144 bool IsVisible() const;
145 // Returns the visibility requested by this window. IsVisible() takes into 145 // Returns the visibility requested by this window. IsVisible() takes into
146 // account the visibility of the layer and ancestors, where as this tracks 146 // account the visibility of the layer and ancestors, where as this tracks
147 // whether Show() without a Hide() has been invoked. 147 // whether Show() without a Hide() has been invoked.
148 bool TargetVisibility() const { return visible_; } 148 bool TargetVisibility() const { return visible_; }
149 149
150 // Returns the window's bounds in root window's coordinates. 150 // Returns the window's bounds in root window's coordinates. Note that it
151 // takes transforms into account when computing the bounds.
151 gfx::Rect GetBoundsInRootWindow() const; 152 gfx::Rect GetBoundsInRootWindow() const;
152 153
153 // Returns the window's bounds in screen coordinates. 154 // Returns the window's bounds in screen coordinates. Note that it
155 // takes transforms into account when computing the bounds.
154 // How the root window's coordinates is mapped to screen's coordinates 156 // How the root window's coordinates is mapped to screen's coordinates
155 // is platform dependent and defined in the implementation of the 157 // is platform dependent and defined in the implementation of the
156 // |aura::client::ScreenPositionClient| interface. 158 // |aura::client::ScreenPositionClient| interface.
157 gfx::Rect GetBoundsInScreen() const; 159 gfx::Rect GetBoundsInScreen() const;
158 160
159 virtual void SetTransform(const gfx::Transform& transform); 161 virtual void SetTransform(const gfx::Transform& transform);
160 162
161 // Assigns a LayoutManager to size and place child windows. 163 // Assigns a LayoutManager to size and place child windows.
162 // The Window takes ownership of the LayoutManager. 164 // The Window takes ownership of the LayoutManager.
163 void SetLayoutManager(LayoutManager* layout_manager); 165 void SetLayoutManager(LayoutManager* layout_manager);
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 }; 550 };
549 551
550 std::map<const void*, Value> prop_map_; 552 std::map<const void*, Value> prop_map_;
551 553
552 DISALLOW_COPY_AND_ASSIGN(Window); 554 DISALLOW_COPY_AND_ASSIGN(Window);
553 }; 555 };
554 556
555 } // namespace aura 557 } // namespace aura
556 558
557 #endif // UI_AURA_WINDOW_H_ 559 #endif // UI_AURA_WINDOW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698