[gtk+/xi2] GdkDevice: Don't allow master devices to be disabled.
- From: Carlos Garnacho <carlosg src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gtk+/xi2] GdkDevice: Don't allow master devices to be disabled.
- Date: Sun, 11 Oct 2009 01:13:55 +0000 (UTC)
commit d25b0b0db2e60673d97790f792889ba8cfe66d68
Author: Carlos Garnacho <carlos gnome org>
Date: Sun Oct 11 01:48:52 2009 +0200
GdkDevice: Don't allow master devices to be disabled.
gdk/gdkdevice.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/gdk/gdkdevice.c b/gdk/gdkdevice.c
index 6e54f32..4c1413b 100644
--- a/gdk/gdkdevice.c
+++ b/gdk/gdkdevice.c
@@ -366,6 +366,10 @@ gdk_device_set_mode (GdkDevice *device,
if (device->mode == mode)
return TRUE;
+ if (mode == GDK_MODE_DISABLED &&
+ gdk_device_get_device_type (device) == GDK_DEVICE_TYPE_MASTER)
+ return FALSE;
+
/* FIXME: setting has_cursor when mode is window? */
device->mode = mode;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]