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

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

Issue 1540753002: Switch to standard integer types in ash/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: arraysize Created 5 years 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 ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_ 5 #ifndef ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_
6 #define ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_ 6 #define ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_
7 7
8 #include <stdint.h>
9
8 #include <vector> 10 #include <vector>
9 11
10 #include "ash/wm/window_resizer.h" 12 #include "ash/wm/window_resizer.h"
11 #include "ash/wm/workspace/magnetism_matcher.h" 13 #include "ash/wm/workspace/magnetism_matcher.h"
12 #include "base/compiler_specific.h" 14 #include "base/compiler_specific.h"
15 #include "base/macros.h"
13 #include "base/memory/scoped_ptr.h" 16 #include "base/memory/scoped_ptr.h"
14 #include "base/memory/weak_ptr.h" 17 #include "base/memory/weak_ptr.h"
15 #include "ui/aura/window_tracker.h" 18 #include "ui/aura/window_tracker.h"
16 19
17 namespace ash { 20 namespace ash {
18 class DockedWindowLayoutManager; 21 class DockedWindowLayoutManager;
19 class PhantomWindowController; 22 class PhantomWindowController;
20 class TwoStepEdgeCycler; 23 class TwoStepEdgeCycler;
21 class WindowSize; 24 class WindowSize;
22 25
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 void MagneticallySnapToOtherWindows(gfx::Rect* bounds); 108 void MagneticallySnapToOtherWindows(gfx::Rect* bounds);
106 109
107 // If possible snaps the resize to a neary window. Updates |bounds| if there 110 // If possible snaps the resize to a neary window. Updates |bounds| if there
108 // was a close enough window. 111 // was a close enough window.
109 void MagneticallySnapResizeToOtherWindows(gfx::Rect* bounds); 112 void MagneticallySnapResizeToOtherWindows(gfx::Rect* bounds);
110 113
111 // Finds the neareset window to magentically snap to. Updates 114 // Finds the neareset window to magentically snap to. Updates
112 // |magnetism_window_| and |magnetism_edge_| appropriately. |edges| is a 115 // |magnetism_window_| and |magnetism_edge_| appropriately. |edges| is a
113 // bitmask of the MagnetismEdges to match again. Returns true if a match is 116 // bitmask of the MagnetismEdges to match again. Returns true if a match is
114 // found. 117 // found.
115 bool UpdateMagnetismWindow(const gfx::Rect& bounds, uint32 edges); 118 bool UpdateMagnetismWindow(const gfx::Rect& bounds, uint32_t edges);
116 119
117 // Adjusts the bounds of the window: magnetically snapping, ensuring the 120 // Adjusts the bounds of the window: magnetically snapping, ensuring the
118 // window has enough on screen... |snap_size| is the distance from an edge of 121 // window has enough on screen... |snap_size| is the distance from an edge of
119 // the work area before the window is snapped. A value of 0 results in no 122 // the work area before the window is snapped. A value of 0 results in no
120 // snapping. 123 // snapping.
121 void AdjustBoundsForMainWindow(int snap_size, gfx::Rect* bounds); 124 void AdjustBoundsForMainWindow(int snap_size, gfx::Rect* bounds);
122 125
123 // Stick the window bounds to the work area during a move. 126 // Stick the window bounds to the work area during a move.
124 bool StickToWorkAreaOnMove(const gfx::Rect& work_area, 127 bool StickToWorkAreaOnMove(const gfx::Rect& work_area,
125 int sticky_size, 128 int sticky_size,
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 // Used to determine if this has been deleted during a drag such as when a tab 219 // Used to determine if this has been deleted during a drag such as when a tab
217 // gets dragged into another browser window. 220 // gets dragged into another browser window.
218 base::WeakPtrFactory<WorkspaceWindowResizer> weak_ptr_factory_; 221 base::WeakPtrFactory<WorkspaceWindowResizer> weak_ptr_factory_;
219 222
220 DISALLOW_COPY_AND_ASSIGN(WorkspaceWindowResizer); 223 DISALLOW_COPY_AND_ASSIGN(WorkspaceWindowResizer);
221 }; 224 };
222 225
223 } // namespace ash 226 } // namespace ash
224 227
225 #endif // ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_ 228 #endif // ASH_WM_WORKSPACE_WORKSPACE_WINDOW_RESIZER_H_
OLDNEW
« no previous file with comments | « ash/wm/workspace/workspace_layout_manager_unittest.cc ('k') | ash/wm/workspace/workspace_window_resizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698