DarkRadiant EventManager

From The DarkMod Wiki
Revision as of 11:15, 12 January 2007 by Greebo (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

The EventManager plugin provides methods to define events and connect them to (member) functions that are called upon connect. This document is WIP.

Connecting Widgets

The events can be connected to certain GtkWidgets (like GtkMenuItems, GtkCheckMenuItems and GtkToolButtons/GtkToggleToolButtons). The events recognise the supported widet types and connect the callbacks automatically. For example, a "Toggle" event can of course be connected to a GtkCheckMenuItem or a GtkToggleToolButton, whereas a "Command" event cannot (connect it to a GtkMenuItem instead).

Event Types

The interface of an event (IEvent) is defined in ieventmanager.h.

  • (Event) - this is the basic, empty implementation of an event.
  • Command
  • Toggle
  • KeyEvent

Accelerators