Public Member Functions | |
bool | isDraggingEnabled (void) const |
Return whether this title bar will respond to dragging. | |
void | setDraggingEnabled (bool setting) |
Set whether this title bar widget will respond to dragging. | |
Titlebar (const String &type, const String &name) | |
Constructor for Titlebar base class. | |
virtual | ~Titlebar (void) |
Destructor for Titlebar base class. | |
Static Public Attributes | |
static const String | EventNamespace |
Namespace for global events. | |
static const String | WidgetTypeName |
Window factory name. | |
Protected Member Functions | |
virtual void | onMouseMove (MouseEventArgs &e) |
Handler called when the mouse cursor has been moved within this window's area. | |
virtual void | onMouseButtonDown (MouseEventArgs &e) |
Handler called when a mouse button has been depressed within this window's area. | |
virtual void | onMouseButtonUp (MouseEventArgs &e) |
Handler called when a mouse button has been released within this window's area. | |
virtual void | onMouseDoubleClicked (MouseEventArgs &e) |
Handler called when a mouse button has been double-clicked within this window's area. | |
virtual void | onCaptureLost (WindowEventArgs &e) |
Handler called when this window loses capture of mouse inputs. | |
virtual void | onFontChanged (WindowEventArgs &e) |
Handler called when the window's font is changed. | |
virtual void | onDraggingModeChanged (WindowEventArgs &e) |
Event handler called when the 'draggable' state for the title bar is changed. | |
virtual bool | testClassName_impl (const String &class_name) const |
Return whether this window was inherited from the given class name at some point in the inheritance hierarchy. | |
Protected Attributes | |
bool | d_dragging |
set to true when the window is being dragged. | |
Point | d_dragPoint |
Point at which we are being dragged. | |
bool | d_dragEnabled |
true when dragging for the widget is enabled. | |
Rect | d_oldCursorArea |
Used to backup cursor restraint area. |
bool CEGUI::Titlebar::isDraggingEnabled | ( | void | ) | const |
Return whether this title bar will respond to dragging.
References d_dragEnabled.
void CEGUI::Titlebar::onCaptureLost | ( | WindowEventArgs & | e | ) | [protected, virtual] |
Handler called when this window loses capture of mouse inputs.
e | WindowEventArgs object whose 'window' pointer field is set to the window that triggered the event. For this event the trigger window is always 'this'. |
Reimplemented from CEGUI::Window.
References d_dragging, d_oldCursorArea, CEGUI::MouseCursor::getSingleton(), and CEGUI::MouseCursor::setConstraintArea().
virtual void CEGUI::Titlebar::onDraggingModeChanged | ( | WindowEventArgs & | e | ) | [inline, protected, virtual] |
Event handler called when the 'draggable' state for the title bar is changed.
Note that this is for 'internal' use at the moment and as such does not add or fire a public Event that can be subscribed to.
Referenced by setDraggingEnabled().
void CEGUI::Titlebar::onFontChanged | ( | WindowEventArgs & | e | ) | [protected, virtual] |
Handler called when the window's font is changed.
e | WindowEventArgs object whose 'window' pointer field is set to the window that triggered the event. For this event the trigger window is always 'this'. |
Reimplemented from CEGUI::Window.
References CEGUI::Window::d_parent, and CEGUI::Window::performChildWindowLayout().
void CEGUI::Titlebar::onMouseButtonDown | ( | MouseEventArgs & | e | ) | [protected, virtual] |
Handler called when a mouse button has been depressed within this window's area.
e | MouseEventArgs object. All fields are valid. |
Reimplemented from CEGUI::Window.
References CEGUI::MouseEventArgs::button, CEGUI::Window::captureInput(), d_dragEnabled, d_dragging, d_dragPoint, d_oldCursorArea, CEGUI::Window::d_parent, CEGUI::MouseCursor::getConstraintArea(), CEGUI::Window::getInnerRect(), CEGUI::Rect::getIntersection(), CEGUI::Window::getParent(), CEGUI::Renderer::getRect(), CEGUI::System::getRenderer(), CEGUI::System::getSingleton(), CEGUI::MouseCursor::getSingleton(), CEGUI::EventArgs::handled, CEGUI::LeftButton, CEGUI::MouseEventArgs::position, CEGUI::CoordConverter::screenToWindow(), and CEGUI::MouseCursor::setConstraintArea().
void CEGUI::Titlebar::onMouseButtonUp | ( | MouseEventArgs & | e | ) | [protected, virtual] |
Handler called when a mouse button has been released within this window's area.
e | MouseEventArgs object. All fields are valid. |
Reimplemented from CEGUI::Window.
References CEGUI::MouseEventArgs::button, CEGUI::EventArgs::handled, CEGUI::LeftButton, and CEGUI::Window::releaseInput().
void CEGUI::Titlebar::onMouseDoubleClicked | ( | MouseEventArgs & | e | ) | [protected, virtual] |
Handler called when a mouse button has been double-clicked within this window's area.
e | MouseEventArgs object. All fields are valid. |
Reimplemented from CEGUI::Window.
References CEGUI::MouseEventArgs::button, CEGUI::Window::d_parent, CEGUI::EventArgs::handled, and CEGUI::LeftButton.
void CEGUI::Titlebar::onMouseMove | ( | MouseEventArgs & | e | ) | [protected, virtual] |
Handler called when the mouse cursor has been moved within this window's area.
e | MouseEventArgs object. All fields are valid. |
Reimplemented from CEGUI::Window.
References d_dragging, d_dragPoint, CEGUI::Window::d_parent, CEGUI::EventArgs::handled, CEGUI::MouseEventArgs::position, and CEGUI::CoordConverter::screenToWindow().
void CEGUI::Titlebar::setDraggingEnabled | ( | bool | setting | ) |
Set whether this title bar widget will respond to dragging.
setting | true if the title bar should respond to being dragged, false if it should not respond. |
References d_dragEnabled, d_dragging, onDraggingModeChanged(), and CEGUI::Window::releaseInput().
Referenced by CEGUI::FrameWindow::initialiseComponents(), and CEGUI::FrameWindow::setDragMovingEnabled().
virtual bool CEGUI::Titlebar::testClassName_impl | ( | const String & | class_name | ) | const [inline, protected, virtual] |
Return whether this window was inherited from the given class name at some point in the inheritance hierarchy.
class_name | The class name that is to be checked. |
Reimplemented from CEGUI::Window.
References CEGUI::Window::testClassName_impl().