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

Side by Side Diff: ash/wm/workspace/workspace_window_resizer.h

Issue 15008002: Make touch-resizing windows to screen edge possible (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Cleanup Created 7 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
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 ASH_WM_WORKSPACE_WINDOW_RESIZER_H_ 5 #ifndef ASH_WM_WORKSPACE_WINDOW_RESIZER_H_
6 #define ASH_WM_WORKSPACE_WINDOW_RESIZER_H_ 6 #define ASH_WM_WORKSPACE_WINDOW_RESIZER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/wm/window_resizer.h" 10 #include "ash/wm/window_resizer.h"
(...skipping 19 matching lines...) Expand all
30 public: 30 public:
31 // When dragging an attached window this is the min size we'll make sure is 31 // When dragging an attached window this is the min size we'll make sure is
32 // visible. In the vertical direction we take the max of this and that from 32 // visible. In the vertical direction we take the max of this and that from
33 // the delegate. 33 // the delegate.
34 static const int kMinOnscreenSize; 34 static const int kMinOnscreenSize;
35 35
36 // Min height we'll force on screen when dragging the caption. 36 // Min height we'll force on screen when dragging the caption.
37 // TODO: this should come from a property on the window. 37 // TODO: this should come from a property on the window.
38 static const int kMinOnscreenHeight; 38 static const int kMinOnscreenHeight;
39 39
40 // Snap region when dragging close to the edges. That is, as the window gets 40 // Snap region when dragging close to the edges using mouse. That is, as the
41 // this close to an edge of the screen it snaps to the edge. 41 // window gets this close to an edge of the screen it snaps to the edge.
sadrul 2013/05/08 17:10:56 '... as the window gets close the an edge ...'
mohsen 2013/05/28 23:27:39 This is the original wording and I haven't changed
42 static const int kScreenEdgeInset; 42 static const int kScreenEdgeInset;
43 43
44 // Snap region when dragging close to the edges using touchscreen. That is, as
45 // the window gets this close to an edge of the screen it snaps to the edge.
sadrul 2013/05/08 17:10:56 This can just be a local const in workspace_window
mohsen 2013/05/28 23:27:39 Done.
46 static const int kScreenEdgeInsetForTouchResize;
47
44 virtual ~WorkspaceWindowResizer(); 48 virtual ~WorkspaceWindowResizer();
45 49
46 static WorkspaceWindowResizer* Create( 50 static WorkspaceWindowResizer* Create(
47 aura::Window* window, 51 aura::Window* window,
48 const gfx::Point& location_in_parent, 52 const gfx::Point& location_in_parent,
49 int window_component, 53 int window_component,
50 const std::vector<aura::Window*>& attached_windows); 54 const std::vector<aura::Window*>& attached_windows);
51 55
52 // Overridden from WindowResizer: 56 // Overridden from WindowResizer:
53 virtual void Drag(const gfx::Point& location_in_parent, 57 virtual void Drag(const gfx::Point& location_in_parent,
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 // should attach. 212 // should attach.
209 MatchedEdge magnetism_edge_; 213 MatchedEdge magnetism_edge_;
210 214
211 DISALLOW_COPY_AND_ASSIGN(WorkspaceWindowResizer); 215 DISALLOW_COPY_AND_ASSIGN(WorkspaceWindowResizer);
212 }; 216 };
213 217
214 } // namespace internal 218 } // namespace internal
215 } // namespace ash 219 } // namespace ash
216 220
217 #endif // ASH_WM_WORKSPACE_WINDOW_RESIZER_H_ 221 #endif // ASH_WM_WORKSPACE_WINDOW_RESIZER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698