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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_window_tree_host.h

Issue 2173033002: Make various views SetShape() methods take an unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 4 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
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_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_ 5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_
6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_ 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "ui/aura/window_event_dispatcher.h" 10 #include "ui/aura/window_event_dispatcher.h"
11 #include "ui/base/ui_base_types.h" 11 #include "ui/base/ui_base_types.h"
12 #include "ui/views/views_export.h" 12 #include "ui/views/views_export.h"
13 #include "ui/views/widget/widget.h" 13 #include "ui/views/widget/widget.h"
14 14
15 namespace aura { 15 namespace aura {
16 class WindowTreeHost; 16 class WindowTreeHost;
17 class Window; 17 class Window;
18 18
19 namespace client { 19 namespace client {
20 class DragDropClient; 20 class DragDropClient;
21 } 21 }
22 } 22 } // namespace aura
23 23
24 namespace gfx { 24 namespace gfx {
25 class ImageSkia; 25 class ImageSkia;
26 class Rect; 26 class Rect;
27 } 27 }
28 28
29 namespace ui { 29 namespace ui {
30 class NativeTheme; 30 class NativeTheme;
31 } 31 }
32 32
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 virtual void GetWindowPlacement(gfx::Rect* bounds, 88 virtual void GetWindowPlacement(gfx::Rect* bounds,
89 ui::WindowShowState* show_state) const = 0; 89 ui::WindowShowState* show_state) const = 0;
90 virtual gfx::Rect GetWindowBoundsInScreen() const = 0; 90 virtual gfx::Rect GetWindowBoundsInScreen() const = 0;
91 virtual gfx::Rect GetClientAreaBoundsInScreen() const = 0; 91 virtual gfx::Rect GetClientAreaBoundsInScreen() const = 0;
92 virtual gfx::Rect GetRestoredBounds() const = 0; 92 virtual gfx::Rect GetRestoredBounds() const = 0;
93 virtual std::string GetWorkspace() const = 0; 93 virtual std::string GetWorkspace() const = 0;
94 94
95 virtual gfx::Rect GetWorkAreaBoundsInScreen() const = 0; 95 virtual gfx::Rect GetWorkAreaBoundsInScreen() const = 0;
96 96
97 // Sets the shape of the root window. If |native_region| is NULL then the 97 // Sets the shape of the root window. If |native_region| is NULL then the
98 // window reverts to rectangular. Takes ownership of |native_region|. 98 // window reverts to rectangular.
99 virtual void SetShape(SkRegion* native_region) = 0; 99 virtual void SetShape(std::unique_ptr<SkRegion> native_region) = 0;
100 100
101 virtual void Activate() = 0; 101 virtual void Activate() = 0;
102 virtual void Deactivate() = 0; 102 virtual void Deactivate() = 0;
103 virtual bool IsActive() const = 0; 103 virtual bool IsActive() const = 0;
104 virtual void Maximize() = 0; 104 virtual void Maximize() = 0;
105 virtual void Minimize() = 0; 105 virtual void Minimize() = 0;
106 virtual void Restore() = 0; 106 virtual void Restore() = 0;
107 virtual bool IsMaximized() const = 0; 107 virtual bool IsMaximized() const = 0;
108 virtual bool IsMinimized() const = 0; 108 virtual bool IsMinimized() const = 0;
109 109
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 // Returns true if the Widget supports translucency. 161 // Returns true if the Widget supports translucency.
162 virtual bool IsTranslucentWindowOpacitySupported() const = 0; 162 virtual bool IsTranslucentWindowOpacitySupported() const = 0;
163 163
164 // Called when the window's size constraints change. 164 // Called when the window's size constraints change.
165 virtual void SizeConstraintsChanged() = 0; 165 virtual void SizeConstraintsChanged() = 0;
166 }; 166 };
167 167
168 } // namespace views 168 } // namespace views
169 169
170 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_ 170 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698