diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 16:55:57 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 16:55:57 +0000 |
commit | 79a90d230d67c14292d1807dca6938c11de9275d (patch) | |
tree | 4efb3581363384b48b4c824bea5396c220b2366e /views/widget/widget_gtk.h | |
parent | 55c623ed0596e614e1340f36a7456e402a5ebbd4 (diff) | |
download | chromium_src-79a90d230d67c14292d1807dca6938c11de9275d.zip chromium_src-79a90d230d67c14292d1807dca6938c11de9275d.tar.gz chromium_src-79a90d230d67c14292d1807dca6938c11de9275d.tar.bz2 |
Add native capture API to Widget, and fix a bug in Window where we wouldn't let the window be closed from the X.
BUG=72040
TEST=none
TBR=sky
Review URL: http://codereview.chromium.org/6697016
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78222 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/widget/widget_gtk.h')
-rw-r--r-- | views/widget/widget_gtk.h | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/views/widget/widget_gtk.h b/views/widget/widget_gtk.h index 370e9cf..584be82 100644 --- a/views/widget/widget_gtk.h +++ b/views/widget/widget_gtk.h @@ -182,6 +182,9 @@ class WidgetGtk : public Widget, virtual void* GetNativeWindowProperty(const char* name) OVERRIDE; virtual TooltipManager* GetTooltipManager() const OVERRIDE; virtual bool IsScreenReaderActive() const OVERRIDE; + virtual void SetNativeCapture() OVERRIDE; + virtual void ReleaseNativeCapture() OVERRIDE; + virtual bool HasNativeCapture() const OVERRIDE; virtual gfx::Rect GetWindowScreenBounds() const OVERRIDE; virtual gfx::Rect GetClientAreaScreenBounds() const OVERRIDE; virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; @@ -263,19 +266,10 @@ class WidgetGtk : public Widget, void set_mouse_down(bool mouse_down) { is_mouse_down_ = mouse_down; } - // Do we own the mouse grab? - bool has_capture() const { return has_capture_; } - // Returns whether capture should be released on mouse release. The default // is true. virtual bool ReleaseCaptureOnMouseReleased(); - // Does a mouse grab on this widget. - virtual void DoGrab(); - - // Releases a grab done by this widget. - virtual void ReleaseGrab(); - // Invoked when input grab is stolen by other GtkWidget in the same // application. virtual void HandleGrabBroke(); @@ -347,9 +341,6 @@ class WidgetGtk : public Widget, // If true, the mouse is currently down. bool is_mouse_down_; - // Have we done a mouse grab? - bool has_capture_; - // The following are used to detect duplicate mouse move events and not // deliver them. Displaying a window may result in the system generating // duplicate move events even though the mouse hasn't moved. |