1 // -*- c++ -*- 2 // Generated by gmmproc 2.40.0 -- DO NOT MODIFY! 3 #ifndef _CLUTTERMM_INPUT_DEVICE_H 4 #define _CLUTTERMM_INPUT_DEVICE_H 5 6 7 #include <glibmm/ustring.h> 8 #include <sigc++/sigc++.h> 9 10 /* Copyright (C) 2011 The cluttermm Development Team 11 * 12 * This library is free software; you can redistribute it and/or 13 * modify it under the terms of the GNU Lesser General Public 14 * License as published by the Free Software Foundation; either 15 * version 2.1 of the License, or (at your option) any later version. 16 * 17 * This library is distributed in the hope that it will be useful, 18 * but WITHOUT ANY WARRANTY; without even the implied warranty of 19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 20 * Lesser General Public License for more details. 21 * 22 * You should have received a copy of the GNU Lesser General Public 23 * License along with this library; if not, write to the Free 24 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 25 */ 26 27 #include <glibmm/object.h> 28 #include <cluttermm/types.h> 29 30 31 //TODO: Wrap this? 32 typedef struct _ClutterEventSequence ClutterEventSequence; 33 34 #ifndef DOXYGEN_SHOULD_SKIP_THIS 35 typedef struct _ClutterInputDevice ClutterInputDevice; 36 typedef struct _ClutterInputDeviceClass ClutterInputDeviceClass; 37 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 38 39 40 namespace Clutter 41 { class InputDevice_Class; } // namespace Clutter 42 namespace Clutter 43 { 44 45 /** @addtogroup cluttermmEnums cluttermm Enums and Flags */ 46 47 /** 48 * @var InputAxis INPUT_AXIS_IGNORE 49 * Unused axis. 50 * 51 * @var InputAxis INPUT_AXIS_X 52 * The position on the X axis. 53 * 54 * @var InputAxis INPUT_AXIS_Y 55 * The position of the Y axis. 56 * 57 * @var InputAxis INPUT_AXIS_PRESSURE 58 * The pressure information. 59 * 60 * @var InputAxis INPUT_AXIS_XTILT 61 * The tilt on the X axis. 62 * 63 * @var InputAxis INPUT_AXIS_YTILT 64 * The tile on the Y axis. 65 * 66 * @var InputAxis INPUT_AXIS_WHEEL 67 * A wheel. 68 * 69 * @var InputAxis INPUT_AXIS_DISTANCE 70 * Distance (Since 1.12). 71 * 72 * @var InputAxis INPUT_AXIS_LAST 73 * Last value of the enumeration; this value is useful when iterating over the enumeration values (Since 1.12). 74 * 75 * @enum InputAxis 76 * 77 * The type of axes Clutter recognizes on a Clutter::InputDevice 78 * 79 * @newin{1,6} 80 * @ingroup cluttermmEnums 81 */ 82 enum InputAxis 83 { 84 INPUT_AXIS_IGNORE, 85 INPUT_AXIS_X, 86 INPUT_AXIS_Y, 87 INPUT_AXIS_PRESSURE, 88 INPUT_AXIS_XTILT, 89 INPUT_AXIS_YTILT, 90 INPUT_AXIS_WHEEL, 91 INPUT_AXIS_DISTANCE, 92 INPUT_AXIS_LAST 93 }; 94 95 } // namespace Clutter 96 97 98 #ifndef DOXYGEN_SHOULD_SKIP_THIS 99 namespace Glib 100 { 101 102 template <> 103 class Value<Clutter::InputAxis> : public Glib::Value_Enum<Clutter::InputAxis> 104 { 105 public: 106 static GType value_type() G_GNUC_CONST; 107 }; 108 109 } // namespace Glib 110 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 111 112 113 namespace Clutter 114 { 115 116 /** 117 * @var InputMode INPUT_MODE_MASTER 118 * A master, virtual device. 119 * 120 * @var InputMode INPUT_MODE_SLAVE 121 * A slave, physical device, attached to a master device. 122 * 123 * @var InputMode INPUT_MODE_FLOATING 124 * A slave, physical device, not attached to a master device. 125 * 126 * @enum InputMode 127 * 128 * The mode for input devices available. 129 * 130 * @newin{1,6} 131 * @ingroup cluttermmEnums 132 */ 133 enum InputMode 134 { 135 INPUT_MODE_MASTER, 136 INPUT_MODE_SLAVE, 137 INPUT_MODE_FLOATING 138 }; 139 140 } // namespace Clutter 141 142 143 #ifndef DOXYGEN_SHOULD_SKIP_THIS 144 namespace Glib 145 { 146 147 template <> 148 class Value<Clutter::InputMode> : public Glib::Value_Enum<Clutter::InputMode> 149 { 150 public: 151 static GType value_type() G_GNUC_CONST; 152 }; 153 154 } // namespace Glib 155 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 156 157 158 namespace Clutter 159 { 160 161 /** 162 * @var InputDeviceType POINTER_DEVICE 163 * A pointer device. 164 * 165 * @var InputDeviceType KEYBOARD_DEVICE 166 * A keyboard device. 167 * 168 * @var InputDeviceType EXTENSION_DEVICE 169 * A generic extension device. 170 * 171 * @var InputDeviceType JOYSTICK_DEVICE 172 * A joystick device. 173 * 174 * @var InputDeviceType TABLET_DEVICE 175 * A tablet device. 176 * 177 * @var InputDeviceType TOUCHPAD_DEVICE 178 * A touchpad device. 179 * 180 * @var InputDeviceType TOUCHSCREEN_DEVICE 181 * A touch screen device. 182 * 183 * @var InputDeviceType PEN_DEVICE 184 * A pen device. 185 * 186 * @var InputDeviceType ERASER_DEVICE 187 * An eraser device. 188 * 189 * @var InputDeviceType CURSOR_DEVICE 190 * A cursor device. 191 * 192 * @var InputDeviceType N_DEVICE_TYPES 193 * The number of device types. 194 * 195 * @enum InputDeviceType 196 * 197 * The types of input devices available. 198 * 199 * The Clutter::InputDeviceType enumeration can be extended at later 200 * date; not every platform supports every input device type. 201 * 202 * @newin{1,0} 203 * @ingroup cluttermmEnums 204 */ 205 enum InputDeviceType 206 { 207 POINTER_DEVICE, 208 KEYBOARD_DEVICE, 209 EXTENSION_DEVICE, 210 JOYSTICK_DEVICE, 211 TABLET_DEVICE, 212 TOUCHPAD_DEVICE, 213 TOUCHSCREEN_DEVICE, 214 PEN_DEVICE, 215 ERASER_DEVICE, 216 CURSOR_DEVICE, 217 N_DEVICE_TYPES 218 }; 219 220 } // namespace Clutter 221 222 223 #ifndef DOXYGEN_SHOULD_SKIP_THIS 224 namespace Glib 225 { 226 227 template <> 228 class Value<Clutter::InputDeviceType> : public Glib::Value_Enum<Clutter::InputDeviceType> 229 { 230 public: 231 static GType value_type() G_GNUC_CONST; 232 }; 233 234 } // namespace Glib 235 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 236 237 238 namespace Clutter 239 { 240 241 /** 242 * @var ModifierType SHIFT_MASK 243 * Mask applied by the Shift key. 244 * 245 * @var ModifierType LOCK_MASK 246 * Mask applied by the Caps Lock key. 247 * 248 * @var ModifierType CONTROL_MASK 249 * Mask applied by the Control key. 250 * 251 * @var ModifierType MOD1_MASK 252 * Mask applied by the first Mod key. 253 * 254 * @var ModifierType MOD2_MASK 255 * Mask applied by the second Mod key. 256 * 257 * @var ModifierType MOD3_MASK 258 * Mask applied by the third Mod key. 259 * 260 * @var ModifierType MOD4_MASK 261 * Mask applied by the fourth Mod key. 262 * 263 * @var ModifierType MOD5_MASK 264 * Mask applied by the fifth Mod key. 265 * 266 * @var ModifierType BUTTON1_MASK 267 * Mask applied by the first pointer button. 268 * 269 * @var ModifierType BUTTON2_MASK 270 * Mask applied by the second pointer button. 271 * 272 * @var ModifierType BUTTON3_MASK 273 * Mask applied by the third pointer button. 274 * 275 * @var ModifierType BUTTON4_MASK 276 * Mask applied by the fourth pointer button. 277 * 278 * @var ModifierType BUTTON5_MASK 279 * Mask applied by the fifth pointer button. 280 * 281 * @var ModifierType SUPER_MASK 282 * Mask applied by the Super key. 283 * 284 * @var ModifierType HYPER_MASK 285 * Mask applied by the Hyper key. 286 * 287 * @var ModifierType META_MASK 288 * Mask applied by the Meta key. 289 * 290 * @var ModifierType RELEASE_MASK 291 * Mask applied during release. 292 * 293 * @var ModifierType MODIFIER_MASK 294 * A mask covering all modifier types. 295 * 296 * @enum ModifierType 297 * 298 * Masks applied to a Clutter::Event by modifiers. 299 * 300 * Note that Clutter may add internal values to events which include 301 * reserved values such as Clutter::MODIFIER_RESERVED_13_MASK. Your code 302 * should preserve and ignore them. You can use Clutter::MODIFIER_MASK to 303 * remove all reserved values. 304 * 305 * @newin{0,4} 306 * @ingroup cluttermmEnums 307 * @par Bitwise operators: 308 * <tt>%ModifierType operator|(ModifierType, ModifierType)</tt><br> 309 * <tt>%ModifierType operator&(ModifierType, ModifierType)</tt><br> 310 * <tt>%ModifierType operator^(ModifierType, ModifierType)</tt><br> 311 * <tt>%ModifierType operator~(ModifierType)</tt><br> 312 * <tt>%ModifierType& operator|=(ModifierType&, ModifierType)</tt><br> 313 * <tt>%ModifierType& operator&=(ModifierType&, ModifierType)</tt><br> 314 * <tt>%ModifierType& operator^=(ModifierType&, ModifierType)</tt><br> 315 */ 316 enum ModifierType 317 { 318 SHIFT_MASK = 1 << 0, 319 LOCK_MASK = 1 << 1, 320 CONTROL_MASK = 1 << 2, 321 MOD1_MASK = 1 << 3, 322 MOD2_MASK = 1 << 4, 323 MOD3_MASK = 1 << 5, 324 MOD4_MASK = 1 << 6, 325 MOD5_MASK = 1 << 7, 326 BUTTON1_MASK = 1 << 8, 327 BUTTON2_MASK = 1 << 9, 328 BUTTON3_MASK = 1 << 10, 329 BUTTON4_MASK = 1 << 11, 330 BUTTON5_MASK = 1 << 12, 331 MODIFIER_RESERVED_13_MASK = 1 << 13, 332 MODIFIER_RESERVED_14_MASK = 1 << 14, 333 MODIFIER_RESERVED_15_MASK = 1 << 15, 334 MODIFIER_RESERVED_16_MASK = 1 << 16, 335 MODIFIER_RESERVED_17_MASK = 1 << 17, 336 MODIFIER_RESERVED_18_MASK = 1 << 18, 337 MODIFIER_RESERVED_19_MASK = 1 << 19, 338 MODIFIER_RESERVED_20_MASK = 1 << 20, 339 MODIFIER_RESERVED_21_MASK = 1 << 21, 340 MODIFIER_RESERVED_22_MASK = 1 << 22, 341 MODIFIER_RESERVED_23_MASK = 1 << 23, 342 MODIFIER_RESERVED_24_MASK = 1 << 24, 343 MODIFIER_RESERVED_25_MASK = 1 << 25, 344 SUPER_MASK = 1 << 26, 345 HYPER_MASK = 1 << 27, 346 META_MASK = 1 << 28, 347 MODIFIER_RESERVED_29_MASK = 1 << 29, 348 RELEASE_MASK = 1 << 30, 349 MODIFIER_MASK = 0x5c001fff 350 }; 351 352 /** @ingroup cluttermmEnums */ 353 inline ModifierType operator|(ModifierType lhs, ModifierType rhs) 354 { return static_cast<ModifierType>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs)); } 355 356 /** @ingroup cluttermmEnums */ 357 inline ModifierType operator&(ModifierType lhs, ModifierType rhs) 358 { return static_cast<ModifierType>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs)); } 359 360 /** @ingroup cluttermmEnums */ 361 inline ModifierType operator^(ModifierType lhs, ModifierType rhs) 362 { return static_cast<ModifierType>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs)); } 363 364 /** @ingroup cluttermmEnums */ 365 inline ModifierType operator~(ModifierType flags) 366 { return static_cast<ModifierType>(~static_cast<unsigned>(flags)); } 367 368 /** @ingroup cluttermmEnums */ 369 inline ModifierType& operator|=(ModifierType& lhs, ModifierType rhs) 370 { return (lhs = static_cast<ModifierType>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs))); } 371 372 /** @ingroup cluttermmEnums */ 373 inline ModifierType& operator&=(ModifierType& lhs, ModifierType rhs) 374 { return (lhs = static_cast<ModifierType>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs))); } 375 376 /** @ingroup cluttermmEnums */ 377 inline ModifierType& operator^=(ModifierType& lhs, ModifierType rhs) 378 { return (lhs = static_cast<ModifierType>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs))); } 379 380 } // namespace Clutter 381 382 383 #ifndef DOXYGEN_SHOULD_SKIP_THIS 384 namespace Glib 385 { 386 387 template <> 388 class Value<Clutter::ModifierType> : public Glib::Value_Flags<Clutter::ModifierType> 389 { 390 public: 391 static GType value_type() G_GNUC_CONST; 392 }; 393 394 } // namespace Glib 395 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 396 397 398 namespace Clutter 399 { 400 401 402 class Actor; 403 class Backend; 404 class Stage; 405 class DeviceManager; 406 407 408 class InputDevice : public Glib::Object 409 { 410 411 #ifndef DOXYGEN_SHOULD_SKIP_THIS 412 413 public: 414 typedef InputDevice CppObjectType; 415 typedef InputDevice_Class CppClassType; 416 typedef ClutterInputDevice BaseObjectType; 417 typedef ClutterInputDeviceClass BaseClassType; 418 419 private: friend class InputDevice_Class; 420 static CppClassType inputdevice_class_; 421 422 private: 423 // noncopyable 424 InputDevice(const InputDevice&); 425 InputDevice& operator=(const InputDevice&); 426 427 protected: 428 explicit InputDevice(const Glib::ConstructParams& construct_params); 429 explicit InputDevice(ClutterInputDevice* castitem); 430 431 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 432 433 public: 434 virtual ~InputDevice(); 435 436 /** Get the GType for this class, for use with the underlying GObject type system. 437 */ 438 static GType get_type() G_GNUC_CONST; 439 440 #ifndef DOXYGEN_SHOULD_SKIP_THIS 441 442 443 static GType get_base_type() G_GNUC_CONST; 444 #endif 445 446 ///Provides access to the underlying C GObject. gobj()447 ClutterInputDevice* gobj() { return reinterpret_cast<ClutterInputDevice*>(gobject_); } 448 449 ///Provides access to the underlying C GObject. gobj()450 const ClutterInputDevice* gobj() const { return reinterpret_cast<ClutterInputDevice*>(gobject_); } 451 452 ///Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. 453 ClutterInputDevice* gobj_copy(); 454 455 private: 456 457 458 protected: 459 InputDevice(); 460 461 public: 462 463 464 /** Retrieves the unique identifier of @a device 465 * 466 * @newin{1,0} 467 * @return The identifier of the device. 468 */ 469 int get_device_id() const; 470 471 //TODO: Wrap ClutterEventSequence? Where would the caller get it from? 472 //Make the sequence const? 473 474 475 /** Retrieves the latest coordinates of a pointer or touch point of 476 * @a device. 477 * 478 * @newin{1,12} 479 * @param sequence A Clutter::EventSequence, or <tt>0</tt> if 480 * the device is not touch-based. 481 * @param point Return location for the pointer 482 * or touch point. 483 * @return <tt>false</tt> if the device's sequence hasn't been found, 484 * and <tt>true</tt> otherwise. 485 */ 486 bool get_coords(ClutterEventSequence * sequence, Point& point) const; 487 488 /// A get_coords() convenience overload. 489 bool get_coords(Point& point) const; 490 491 492 /** Retrieves the current modifiers state of the device, as seen 493 * by the last event Clutter processed. 494 * 495 * @newin{1,16} 496 * @return The last known modifier state. 497 */ 498 ModifierType get_modifier_state() const; 499 500 /** Retrieves the type of @a device 501 * 502 * @newin{1,0} 503 * @return The type of the device. 504 */ 505 InputDeviceType get_device_type() const; 506 507 /** Retrieves the name of the @a device 508 * 509 * @newin{1,2} 510 * @return The name of the device, or <tt>0</tt>. The returned string 511 * is owned by the Clutter::InputDevice and should never be modified 512 * or freed. 513 */ 514 Glib::ustring get_device_name() const; 515 516 #ifndef CLUTTERMM_DISABLE_DEPRECATED 517 518 /** Retrieves the latest coordinates of the pointer of @a device 519 * 520 * @newin{1,2} 521 * 522 * Deprecated: 1.12: Use get_coords() instead. 523 * @deprecated Use get_coords() instead. 524 * @param x Return location for the X coordinate. 525 * @param y Return location for the Y coordinate. 526 */ 527 void get_device_coords(int & x, int & y) const; 528 #endif // CLUTTERMM_DISABLE_DEPRECATED 529 530 531 /** Retrieves the Clutter::InputMode of @a device. 532 * 533 * @newin{1,6} 534 * @return The device mode. 535 */ 536 InputMode get_device_mode() const; 537 538 /** Retrieves whether @a device has a pointer that follows the 539 * device motion. 540 * 541 * @newin{1,6} 542 * @return <tt>true</tt> if the device has a cursor. 543 */ 544 bool get_has_cursor() const; 545 546 /** Enables or disables a Clutter::InputDevice. 547 * 548 * Only devices with a Clutter::InputDevice::property_device_mode() property set 549 * to Clutter::INPUT_MODE_SLAVE or Clutter::INPUT_MODE_FLOATING can 550 * be disabled. 551 * 552 * @newin{1,6} 553 * @param enabled <tt>true</tt> to enable the @a device. 554 */ 555 void set_enabled(bool enabled = true); 556 557 /** Retrieves whether @a device is enabled. 558 * 559 * @newin{1,6} 560 * @return <tt>true</tt> if the device is enabled. 561 */ 562 bool get_enabled() const; 563 564 565 /** Retrieves a pointer to the Clutter::InputDevice that has been 566 * associated to @a device. 567 * 568 * If the Clutter::InputDevice::property_device_mode() property of @a device is 569 * set to Clutter::INPUT_MODE_MASTER, this function will return 570 * <tt>0</tt>. 571 * 572 * @newin{1,6} 573 * @return A Clutter::InputDevice, or <tt>0</tt>. 574 */ 575 Glib::RefPtr<InputDevice> get_associated_device(); 576 577 /** Retrieves a pointer to the Clutter::InputDevice that has been 578 * associated to @a device. 579 * 580 * If the Clutter::InputDevice::property_device_mode() property of @a device is 581 * set to Clutter::INPUT_MODE_MASTER, this function will return 582 * <tt>0</tt>. 583 * 584 * @newin{1,6} 585 * @return A Clutter::InputDevice, or <tt>0</tt>. 586 */ 587 Glib::RefPtr<const InputDevice> get_associated_device() const; 588 589 590 /** Translates a hardware keycode from a Clutter::KeyEvent to the 591 * equivalent evdev keycode. Note that depending on the input backend 592 * used by Clutter this function can fail if there is no obvious 593 * mapping between the key codes. The hardware keycode can be taken 594 * from the Clutter::KeyEvent.hardware_keycode member of Clutter::KeyEvent. 595 * 596 * @newin{1,10} 597 * @param hardware_keycode The hardware keycode from a Clutter::KeyEvent. 598 * @param evdev_keycode The return location for the evdev keycode. 599 * @return <tt>true</tt> if the conversion succeeded, <tt>false</tt> otherwise. 600 */ 601 bool keycode_to_evdev(guint hardware_keycode, guint& evdev_keycode) const; 602 603 /** Retrieves the number of keys registered for @a device. 604 * 605 * @newin{1,6} 606 * @return The number of registered keys. 607 */ 608 bool get_n_keys() const; 609 610 /** Sets the keyval and modifiers at the given @a index for @a device. 611 * 612 * Clutter will use the keyval and modifiers set when filling out 613 * an event coming from the same input device. 614 * 615 * @newin{1,6} 616 * @param index The index of the key. 617 * @param keyval The keyval. 618 * @param modifiers A bitmask of modifiers. 619 */ 620 void set_key(guint index, guint keyval, ModifierType modifiers); 621 622 623 /** Retrieves the key set using set_key() 624 * 625 * @newin{1,6} 626 * @param index The index of the key. 627 * @param keyval Return location for the keyval at @a index. 628 * @param modifiers Return location for the modifiers at @a index. 629 * @return <tt>true</tt> if a key was set at the given index. 630 */ 631 bool get_key(guint index, guint& keyval, ModifierType& modifiers) const; 632 633 634 /** Retrieves the number of axes available on @a device. 635 * 636 * @newin{1,6} 637 * @return The number of axes on the device. 638 */ 639 guint get_n_axes(); 640 641 /** Retrieves the type of axis on @a device at the given index. 642 * 643 * @newin{1,6} 644 * @param index The index of the axis. 645 * @return The axis type. 646 */ 647 InputAxis get_axis(guint index_); 648 649 650 /** Retrieves the Clutter::Actor underneath the pointer of @a device 651 * 652 * @newin{1,2} 653 * @return A pointer to the Clutter::Actor or <tt>0</tt>. 654 */ 655 Glib::RefPtr<Actor> get_pointer_actor(); 656 657 /** Retrieves the Clutter::Actor underneath the pointer of @a device 658 * 659 * @newin{1,2} 660 * @return A pointer to the Clutter::Actor or <tt>0</tt>. 661 */ 662 Glib::RefPtr<const Actor> get_pointer_actor() const; 663 664 /** Retrieves the Clutter::Stage underneath the pointer of @a device 665 * 666 * @newin{1,2} 667 * @return A pointer to the Clutter::Stage or <tt>0</tt>. 668 */ 669 Glib::RefPtr<Stage> get_pointer_stage(); 670 671 /** Retrieves the Clutter::Stage underneath the pointer of @a device 672 * 673 * @newin{1,2} 674 * @return A pointer to the Clutter::Stage or <tt>0</tt>. 675 */ 676 Glib::RefPtr<const Stage> get_pointer_stage() const; 677 678 679 /** Acquires a grab on @a actor for the given @a device. 680 * 681 * Any event coming from @a device will be delivered to @a actor, bypassing 682 * the usual event delivery mechanism, until the grab is released by 683 * calling ungrab(). 684 * 685 * The grab is client-side: even if the windowing system used by the Clutter 686 * backend has the concept of "device grabs", Clutter will not use them. 687 * 688 * Only Clutter::InputDevice of types Clutter::POINTER_DEVICE and 689 * Clutter::KEYBOARD_DEVICE can hold a grab. 690 * 691 * @newin{1,10} 692 * @param actor A Clutter::Actor. 693 */ 694 void grab(const Glib::RefPtr<const Actor>& actor); 695 696 /** Releases the grab on the @a device, if one is in place. 697 * 698 * @newin{1,10} 699 */ 700 void ungrab(); 701 702 //TODO: _WRAP_METHOD(void update_from_event(const Glib::RefPtr<Event>& event, bool update_stage), clutter_input_device_update_from_event) 703 704 #ifdef GLIBMM_PROPERTIES_ENABLED 705 /** The backend instance. 706 * 707 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 708 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 709 * or receive notification when the value of the property changes. 710 */ 711 Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Backend> > property_backend() const; 712 #endif //#GLIBMM_PROPERTIES_ENABLED 713 714 715 #ifdef GLIBMM_PROPERTIES_ENABLED 716 /** The device manager instance. 717 * 718 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 719 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 720 * or receive notification when the value of the property changes. 721 */ 722 Glib::PropertyProxy_ReadOnly< Glib::RefPtr<DeviceManager> > property_device_manager() const; 723 #endif //#GLIBMM_PROPERTIES_ENABLED 724 725 726 #ifdef GLIBMM_PROPERTIES_ENABLED 727 /** The mode of the device. 728 * 729 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 730 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 731 * or receive notification when the value of the property changes. 732 */ 733 Glib::PropertyProxy_ReadOnly< InputMode > property_device_mode() const; 734 #endif //#GLIBMM_PROPERTIES_ENABLED 735 736 737 #ifdef GLIBMM_PROPERTIES_ENABLED 738 /** The type of the device. 739 * 740 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 741 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 742 * or receive notification when the value of the property changes. 743 */ 744 Glib::PropertyProxy_ReadOnly< InputDeviceType > property_device_type() const; 745 #endif //#GLIBMM_PROPERTIES_ENABLED 746 747 748 #ifdef GLIBMM_PROPERTIES_ENABLED 749 /** Whether the device is enabled. 750 * 751 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 752 * @return A PropertyProxy that allows you to get or set the value of the property, 753 * or receive notification when the value of the property changes. 754 */ 755 Glib::PropertyProxy< bool > property_enabled() ; 756 #endif //#GLIBMM_PROPERTIES_ENABLED 757 758 #ifdef GLIBMM_PROPERTIES_ENABLED 759 /** Whether the device is enabled. 760 * 761 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 762 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 763 * or receive notification when the value of the property changes. 764 */ 765 Glib::PropertyProxy_ReadOnly< bool > property_enabled() const; 766 #endif //#GLIBMM_PROPERTIES_ENABLED 767 768 #ifdef GLIBMM_PROPERTIES_ENABLED 769 /** Whether the device has a cursor. 770 * 771 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 772 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 773 * or receive notification when the value of the property changes. 774 */ 775 Glib::PropertyProxy_ReadOnly< bool > property_has_cursor() const; 776 #endif //#GLIBMM_PROPERTIES_ENABLED 777 778 779 #ifdef GLIBMM_PROPERTIES_ENABLED 780 /** Unique identifier of the device. 781 * 782 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 783 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 784 * or receive notification when the value of the property changes. 785 */ 786 Glib::PropertyProxy_ReadOnly< int > property_id() const; 787 #endif //#GLIBMM_PROPERTIES_ENABLED 788 789 790 #ifdef GLIBMM_PROPERTIES_ENABLED 791 /** The number of axes on the device. 792 * 793 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 794 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 795 * or receive notification when the value of the property changes. 796 */ 797 Glib::PropertyProxy_ReadOnly< int > property_n_axes() const; 798 #endif //#GLIBMM_PROPERTIES_ENABLED 799 800 801 #ifdef GLIBMM_PROPERTIES_ENABLED 802 /** The name of the device. 803 * 804 * You rarely need to use properties because there are get_ and set_ methods for almost all of them. 805 * @return A PropertyProxy_ReadOnly that allows you to get the value of the property, 806 * or receive notification when the value of the property changes. 807 */ 808 Glib::PropertyProxy_ReadOnly< Glib::ustring > property_name() const; 809 #endif //#GLIBMM_PROPERTIES_ENABLED 810 811 812 public: 813 814 public: 815 //C++ methods used to invoke GTK+ virtual functions: 816 817 protected: 818 //GTK+ Virtual Functions (override these to change behaviour): 819 820 //Default Signal Handlers:: 821 822 823 }; 824 825 } // namespace Clutter 826 827 828 namespace Glib 829 { 830 /** A Glib::wrap() method for this object. 831 * 832 * @param object The C instance. 833 * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref. 834 * @result A C++ instance that wraps this C instance. 835 * 836 * @relates Clutter::InputDevice 837 */ 838 Glib::RefPtr<Clutter::InputDevice> wrap(ClutterInputDevice* object, bool take_copy = false); 839 } 840 841 842 #endif /* _CLUTTERMM_INPUT_DEVICE_H */ 843 844