Om  1.0.0
A universal framework for multimedia simulation
Public Attributes | List of all members
om::graphics::devices::GraphicsContextWindow::Delegate Class Reference

A class that contains function objects that recieve context window events. More...

#include <omGraphicsContextWindow.h>

Public Attributes

Function< void(GraphicsContextWindow &, const Time &)> update
 A function object that is called whenever the state of a context window should be updated for a time interval. More...
 
Function< void(GraphicsContextWindow &, GraphicsContext &)> startDrawing
 A function object that is called whenever an attached context window is starting to be drawn. More...
 
Function< void(GraphicsContextWindow &, GraphicsContext &)> stopDrawing
 A function object that is called whenever an attached context window should stop drawing. More...
 
Function< void(GraphicsContextWindow &, GraphicsContext &)> draw
 A function object that is called whenever an attached context window should be drawn. More...
 
Function< Bool(GraphicsContextWindow &)> open
 A function object that is called whenever an attached window is made visible programmatically. More...
 
Function< Bool(GraphicsContextWindow &)> close
 A function object that is called whenever an attached window attempts to be closed. More...
 
Function< void(GraphicsContextWindow &, Bool)> setFocus
 A function object that is called whenever an attached window gains or loses focus. More...
 
Function< Bool(GraphicsContextWindow &, const Size2D &)> resize
 A function object that is called whenever an attached context window is resized. More...
 
Function< void(GraphicsContextWindow &, const Size2D &)> resized
 A function object that is called whenever an attached context window has been resized. More...
 
Function< Bool(GraphicsContextWindow &, const Vector2i &)> move
 A function object that is called whenever an attached context window is moved. More...
 
Function< void(GraphicsContextWindow &, const gui::input::TextEvent &)> textEvent
 A function object called whenever the user enters text in the context window (usually via keyboard). More...
 
Function< void(GraphicsContextWindow &, const gui::input::KeyEvent &)> keyEvent
 A function object called whenever an attached context window receives a keyboard event. More...
 
Function< void(GraphicsContextWindow &, const gui::input::MouseMotionEvent &)> mouseMotionEvent
 A function object called whenever an attached context window receives a mouse-motion event. More...
 
Function< void(GraphicsContextWindow &, const gui::input::MouseButtonEvent &)> mouseButtonEvent
 A function object called whenever an attached context window receives a mouse-button event. More...
 
Function< void(GraphicsContextWindow &, const gui::input::MouseWheelEvent &)> mouseWheelEvent
 A function object called whenever an attached context window receives a mouse-wheel event. More...
 

Detailed Description

A class that contains function objects that recieve context window events.

Any context-window-related event that might be processed has an appropriate callback function object. Each callback function is called by the GUI event thread whenever such an event is received. If a callback function in the delegate is not initialized, the RenderView simply ignores it and doesn't call the function.

It must be noted that the callback functions are asynchronous and not thread-safe. Thus, it is necessary to perform any additional synchronization externally.

Member Data Documentation

Function<void ( GraphicsContextWindow&, const Time& )> om::graphics::devices::GraphicsContextWindow::Delegate::update

A function object that is called whenever the state of a context window should be updated for a time interval.

Function<void ( GraphicsContextWindow&, GraphicsContext& )> om::graphics::devices::GraphicsContextWindow::Delegate::startDrawing

A function object that is called whenever an attached context window is starting to be drawn.

The delegate should do initialization of graphics data in this function.

Function<void ( GraphicsContextWindow&, GraphicsContext& )> om::graphics::devices::GraphicsContextWindow::Delegate::stopDrawing

A function object that is called whenever an attached context window should stop drawing.

The delegate should do cleanup of graphics data in this function.

Function<void ( GraphicsContextWindow&, GraphicsContext& )> om::graphics::devices::GraphicsContextWindow::Delegate::draw

A function object that is called whenever an attached context window should be drawn.

Function<Bool ( GraphicsContextWindow& )> om::graphics::devices::GraphicsContextWindow::Delegate::open

A function object that is called whenever an attached window is made visible programmatically.

The delegate function may choose to return either a value of TRUE, indicating that the open operation is allowed, or a value of FALSE, indicating that the open operation should be ignored.

Function<Bool ( GraphicsContextWindow& )> om::graphics::devices::GraphicsContextWindow::Delegate::close

A function object that is called whenever an attached window attempts to be closed.

The delegate function may choose to return either a value of TRUE, indicating that the close operation is allowed, or a value of FALSE, indicating that the close operation should be ignored.

Function<void ( GraphicsContextWindow&, Bool )> om::graphics::devices::GraphicsContextWindow::Delegate::setFocus

A function object that is called whenever an attached window gains or loses focus.

The boolean parameter indicates whether or not the window now has focus. A value of TRUE indicates that the window just gained focus. A value of FALSE indicates that the window just lost focus.

Function<Bool ( GraphicsContextWindow&, const Size2D& )> om::graphics::devices::GraphicsContextWindow::Delegate::resize

A function object that is called whenever an attached context window is resized.

The delegate function may choose to return either a value of TRUE, indicating that the change in size is allowed, or a value of FALSE, indicating that the change in size should be ignored.

The context window provides the desired new size of the window as a (width, height) pair.

Function<void ( GraphicsContextWindow&, const Size2D& )> om::graphics::devices::GraphicsContextWindow::Delegate::resized

A function object that is called whenever an attached context window has been resized.

The window provides the desired new size of the window's content area.

Function<Bool ( GraphicsContextWindow&, const Vector2i& )> om::graphics::devices::GraphicsContextWindow::Delegate::move

A function object that is called whenever an attached context window is moved.

The delegate function may choose to return either a value of TRUE, indicating that the change in position is allowed, or a value of FALSE, indicating that the change in position should be ignored.

The context window provides the desired new position of the window as a 2D vector.

Function<void ( GraphicsContextWindow&, const gui::input::TextEvent& )> om::graphics::devices::GraphicsContextWindow::Delegate::textEvent

A function object called whenever the user enters text in the context window (usually via keyboard).

Function<void ( GraphicsContextWindow&, const gui::input::KeyEvent& )> om::graphics::devices::GraphicsContextWindow::Delegate::keyEvent

A function object called whenever an attached context window receives a keyboard event.

Function<void ( GraphicsContextWindow&, const gui::input::MouseMotionEvent& )> om::graphics::devices::GraphicsContextWindow::Delegate::mouseMotionEvent

A function object called whenever an attached context window receives a mouse-motion event.

Function<void ( GraphicsContextWindow&, const gui::input::MouseButtonEvent& )> om::graphics::devices::GraphicsContextWindow::Delegate::mouseButtonEvent

A function object called whenever an attached context window receives a mouse-button event.

Function<void ( GraphicsContextWindow&, const gui::input::MouseWheelEvent& )> om::graphics::devices::GraphicsContextWindow::Delegate::mouseWheelEvent

A function object called whenever an attached context window receives a mouse-wheel event.


The documentation for this class was generated from the following file: