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

Unified Diff: ash/wm/window_resizer.h

Issue 9467021: Attempt 3: Makes managed mode constrain the height of windows so they don't (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Da fix Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/wm/toplevel_window_event_filter_unittest.cc ('k') | ash/wm/window_resizer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/window_resizer.h
diff --git a/ash/wm/window_resizer.h b/ash/wm/window_resizer.h
index f44081b07270d08c9a869942045cedd83de7f683..777eff3a897e7c2c0323bc9b1b68fde24d3a7dbf 100644
--- a/ash/wm/window_resizer.h
+++ b/ash/wm/window_resizer.h
@@ -38,7 +38,7 @@ class ASH_EXPORT WindowResizer {
const gfx::Point& location,
int window_component,
int grid_size);
- ~WindowResizer();
+ virtual ~WindowResizer();
// Returns a bitmask of the kBoundsChange_ values.
static int GetBoundsChangeForWindowComponent(int component);
@@ -64,12 +64,20 @@ class ASH_EXPORT WindowResizer {
}
int window_component() const { return window_component_; }
aura::Window* window() const { return window_; }
+ int grid_size() const { return grid_size_; }
+ bool did_move_or_resize() const { return did_move_or_resize_; }
+ int bounds_change() const { return bounds_change_; }
- private:
+ protected:
// Returns the bounds to give to the window once the mouse has moved to
// |location|.
- gfx::Rect GetBoundsForDrag(const gfx::Point& location);
+ virtual gfx::Rect GetBoundsForDrag(const gfx::Point& location);
+
+ // Returns the final bounds. This differs from current bounds if a grid_size
+ // was specified.
+ virtual gfx::Rect GetFinalBounds();
+ private:
// Returns the new origin of the window. The arguments are the difference
// between the current location and the initial location.
gfx::Point GetOriginForDrag(int delta_x, int delta_y) const;
« no previous file with comments | « ash/wm/toplevel_window_event_filter_unittest.cc ('k') | ash/wm/window_resizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698