A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/classCGUIEvent.html below:

NCBI C++ ToolKit: CGUIEvent Class Reference

CGUIEvent provides mapping of FLTK events to Semantic Events.

Goals: 1. To isolate programs from the complexities of platform-dependent bindings of mouse and keyboard events to Actions. 2. To simplify event handling in programs by mapping multiple FLTK events to a single Semantic Event (for instance 'Ctrl'+C and 'Ctrl'+'Ins' - > eCopy) 3. To provide uniform and consistent mapping of Events to Actions controlled in one place. 4. To provide workarounds for some deficiencies of FLTK event handling system.

CGUIEvent support two type of Semantic Events - mouse events and shortcuts. Both types of events may emit Signals depending on the current state of modifiers , however, there is a significant difference in a way mapping is declared.

States for mouse events are explicintly declared and registered in CGUIEvent using RegisterState() function. Then it is possible to bind a Signal to a particular mouse Event depending on the current State. States for mouse events represent different GUI modes, user enter a mode by pressing a combination of modifier keys and remains in this mode by holding the keys pressed.

Shortcuts also depend on pressed modifiers, but defining Shortcuts does not require registering special states. RegisterShortcut() function takes a combination of modifiers and an action key. If action key is pressed while specified combination of modifiers is being hold - CGUIEvent generates a Signal corresponding to shortcut. Handling shortcuts does not change current state and so do not interfere with handling of mouse events.

Definition at line 81 of file gui_event.hpp.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4