00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #include <Bonobo_Unknown.idl>
00024 #include <Accessibility_Event.idl>
00025 #include <Accessibility_Application.idl>
00026 #include <Accessibility_Desktop.idl>
00027
00028 #ifndef _ACCESSIBILITY_REGISTRY_IDL_
00029 #define _ACCESSIBILITY_REGISTRY_IDL_
00030
00031 module Accessibility {
00032
00033 typedef sequence<Desktop> DesktopSeq;
00034
00035 interface DeviceEventController;
00036
00074 interface Registry : EventListener {
00075
00080 oneway void registerApplication (in Application application);
00081
00088 void deregisterApplication (in Application application);
00089
00097 void registerGlobalEventListener (in EventListener listener,
00098 in string eventName);
00099
00108 void deregisterGlobalEventListenerAll (in EventListener listener);
00109
00119 void deregisterGlobalEventListener (in EventListener listener,
00120 in string eventName);
00145 short getDesktopCount ();
00146
00155 Desktop getDesktop (in short n);
00156
00163 DesktopSeq getDesktopList ();
00164
00170 DeviceEventController getDeviceEventController ();
00171
00177 void unImplemented ();
00178 void unImplemented2 ();
00179 void unImplemented3 ();
00180 void unImplemented4 ();
00181 void unImplemented5 ();
00182 void unImplemented6 ();
00184 };
00185
00187 enum KeyEventType {
00188 KEY_PRESSED,
00189 KEY_RELEASED
00190 };
00191
00196 enum EventType {
00197 KEY_PRESSED_EVENT,
00198 KEY_RELEASED_EVENT,
00199 BUTTON_PRESSED_EVENT,
00201 BUTTON_RELEASED_EVENT
00203 };
00204
00206 enum KeySynthType {
00207 KEY_PRESS,
00208 KEY_RELEASE,
00209 KEY_PRESSRELEASE,
00210 KEY_SYM,
00221 KEY_STRING
00227 };
00228
00229 enum ModifierType {
00230 MODIFIER_SHIFT,
00231 MODIFIER_SHIFTLOCK,
00232 MODIFIER_CONTROL,
00233 MODIFIER_ALT,
00234 MODIFIER_META,
00242 MODIFIER_META2,
00243 MODIFIER_META3,
00244 MODIFIER_NUMLOCK
00247 };
00248
00253 struct EventListenerMode {
00254 boolean synchronous;
00263 boolean preemptive;
00270 boolean global;
00280 };
00281
00291 typedef unsigned long ControllerEventMask;
00292
00294 struct DeviceEvent {
00295 EventType type;
00296 long id;
00299 short hw_code;
00312 unsigned short modifiers;
00322 unsigned long timestamp;
00328 string event_string;
00334 boolean is_text;
00339 };
00340
00368 struct KeyDefinition {
00369 long keycode;
00370 long keysym;
00371 string keystring;
00372 long unused;
00373 };
00374
00375 typedef sequence< KeyDefinition > KeySet;
00376 typedef sequence< EventType > KeyEventTypeSeq;
00377 typedef sequence< EventType > EventTypeSeq;
00378
00383 interface DeviceEventListener : Bonobo::Unknown {
00389 boolean notifyEvent (in DeviceEvent event);
00391 void unImplemented__ ();
00392 void unImplemented_2_ ();
00393 void unImplemented_3_ ();
00394 void unImplemented_4_ ();
00395 void unImplemented_5_ ();
00396 void unImplemented_6_ ();
00398 };
00399
00404 interface DeviceEventController : Bonobo::Unknown {
00405
00430 boolean registerKeystrokeListener (in DeviceEventListener listener,
00431 in KeySet keys,
00432 in ControllerEventMask mask,
00433 in KeyEventTypeSeq type,
00434 in EventListenerMode mode);
00435
00443 void deregisterKeystrokeListener (in DeviceEventListener listener,
00444 in KeySet keys,
00445 in ControllerEventMask mask,
00446 in KeyEventTypeSeq type);
00447
00456 boolean registerDeviceEventListener (in DeviceEventListener listener,
00457 in EventTypeSeq typeseq);
00458
00465 void deregisterDeviceEventListener (in DeviceEventListener listener,
00466 in EventTypeSeq typeseq);
00467
00483 boolean notifyListenersSync (in DeviceEvent event);
00484
00496 oneway void notifyListenersAsync (in DeviceEvent event);
00497
00518 void generateKeyboardEvent (in long keycode,
00519 in string keystring,
00520 in KeySynthType type);
00521
00528 void generateMouseEvent (in long x, in long y, in string eventName);
00529
00535 void unImplemented ();
00536 void unImplemented2 ();
00537 void unImplemented3 ();
00538 void unImplemented4 ();
00540 };
00541 };
00542
00543 #endif