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

Unified Diff: ui/aura/window.h

Issue 10831361: Draggable region support for frameless app window on CrOS. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix build Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/aura/root_window.cc ('k') | ui/aura/window.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/window.h
diff --git a/ui/aura/window.h b/ui/aura/window.h
index 8d98ffa54f18ac4a39a60c308b3c2e1f09a63d41..3a385564730ab8a80b89f4518f73e6679ab23298 100644
--- a/ui/aura/window.h
+++ b/ui/aura/window.h
@@ -27,6 +27,7 @@
#include "ui/gfx/rect.h"
class SkCanvas;
+class SkRegion;
namespace gfx {
class Display;
@@ -264,6 +265,10 @@ class AURA_EXPORT Window : public ui::LayerDelegate,
return hit_test_bounds_override_inner_;
}
+ // The region specified can be used to drag the window.
+ // The window will take the ownership of the specified region.
+ void SetDraggableRegion(SkRegion* region);
Ben Goodger (Google) 2012/08/17 17:10:24 Aura is agnostic of things that relate specificall
+
// Returns true if the |point_in_root| in root window's coordinate falls
// within this window's bounds. Returns false if the window is detached
// from root window.
@@ -282,7 +287,8 @@ class AURA_EXPORT Window : public ui::LayerDelegate,
// Returns the Window that most closely encloses |local_point| for the
// purposes of event targeting.
- Window* GetEventHandlerForPoint(const gfx::Point& local_point);
+ Window* GetEventHandlerForPoint(const gfx::Point& local_point,
+ ui::EventType event_type);
// Returns the topmost Window with a delegate containing |local_point|.
Window* GetTopWindowContainingPoint(const gfx::Point& local_point);
@@ -381,11 +387,11 @@ class AURA_EXPORT Window : public ui::LayerDelegate,
// Gets a Window (either this one or a subwindow) containing |local_point|.
// If |return_tightest| is true, returns the tightest-containing (i.e.
// furthest down the hierarchy) Window containing the point; otherwise,
- // returns the loosest. If |for_event_handling| is true, then hit-test masks
- // are honored; otherwise, only bounds checks are performed.
+ // returns the loosest. If |event_type| is provided (!ET_UNKNOWN), then
+ // hit-test masks are honored; otherwise, only bounds checks are performed.
Window* GetWindowForPoint(const gfx::Point& local_point,
bool return_tightest,
- bool for_event_handling);
+ ui::EventType event_type);
// Implementation of RemoveChild(). If |child| is being removed as the result
// of an add, |new_parent| is the new parent |child| is going to be parented
@@ -481,6 +487,9 @@ class AURA_EXPORT Window : public ui::LayerDelegate,
gfx::Insets hit_test_bounds_override_outer_touch_;
gfx::Insets hit_test_bounds_override_inner_;
+ // Region that can be used to drag the window.
+ scoped_ptr<SkRegion> draggable_region_;
+
ObserverList<WindowObserver> observers_;
// Value struct to keep the name and deallocator for this property.
« no previous file with comments | « ui/aura/root_window.cc ('k') | ui/aura/window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698