OpenWalnut  1.5.0dev
Public Slots | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
WQtPropertyBoolAction Class Reference

Implements a property action for WPropBool. More...

#include <WQtPropertyBoolAction.h>

+ Inheritance diagram for WQtPropertyBoolAction:
+ Collaboration diagram for WQtPropertyBoolAction:

Public Slots

void changed ()
 called whenever the user modifies the action More...
 

Public Member Functions

 WQtPropertyBoolAction (WPropBool property, QWidget *parent=0)
 Constructor. More...
 
virtual ~WQtPropertyBoolAction ()
 Destructor. More...
 

Protected Member Functions

virtual void update ()
 Called whenever the widget should update. More...
 
virtual void propertyChangeNotifier ()
 Callback for WPropertyBase::getChangeCondition. More...
 
virtual bool event (QEvent *event)
 Custom event dispatcher. More...
 

Protected Attributes

WPropBool m_boolProperty
 The boolean property represented by this widget. More...
 
boost::signals2::connection m_connection
 The connection for propertyChangeNotifier(). More...
 

Detailed Description

Implements a property action for WPropBool.

Definition at line 35 of file WQtPropertyBoolAction.h.

Constructor & Destructor Documentation

◆ WQtPropertyBoolAction()

WQtPropertyBoolAction::WQtPropertyBoolAction ( WPropBool  property,
QWidget *  parent = 0 
)

Constructor.

Creates a new action appropriate for the specified property.

Parameters
propertythe property to handle
parentthe parent widget.

Definition at line 34 of file WQtPropertyBoolAction.cpp.

References changed(), m_connection, propertyChangeNotifier(), and update().

+ Here is the call graph for this function:

◆ ~WQtPropertyBoolAction()

WQtPropertyBoolAction::~WQtPropertyBoolAction ( )
virtual

Destructor.

Definition at line 52 of file WQtPropertyBoolAction.cpp.

Member Function Documentation

◆ changed

void WQtPropertyBoolAction::changed ( )
slot

called whenever the user modifies the action

Definition at line 63 of file WQtPropertyBoolAction.cpp.

References m_boolProperty.

Referenced by WQtPropertyBoolAction().

+ Here is the caller graph for this function:

◆ event()

bool WQtPropertyBoolAction::event ( QEvent event)
protectedvirtual

Custom event dispatcher.

Gets called by QT's Event system every time an event got sent to this widget. This event handler processes property change events.

Note
QT Doc says: use event() for custom events.
Parameters
eventthe event that got transmitted.
Returns
true if the event got handled properly.

Definition at line 74 of file WQtPropertyBoolAction.cpp.

References update().

+ Here is the call graph for this function:

◆ propertyChangeNotifier()

void WQtPropertyBoolAction::propertyChangeNotifier ( )
protectedvirtual

Callback for WPropertyBase::getChangeCondition.

It emits an event to ensure all updates are done in gui thread.

Definition at line 69 of file WQtPropertyBoolAction.cpp.

Referenced by WQtPropertyBoolAction().

+ Here is the caller graph for this function:

◆ update()

void WQtPropertyBoolAction::update ( )
protectedvirtual

Called whenever the widget should update.

Definition at line 57 of file WQtPropertyBoolAction.cpp.

References m_boolProperty.

Referenced by event(), and WQtPropertyBoolAction().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_boolProperty

WPropBool WQtPropertyBoolAction::m_boolProperty
protected

The boolean property represented by this widget.

Definition at line 61 of file WQtPropertyBoolAction.h.

Referenced by changed(), and update().

◆ m_connection

boost::signals2::connection WQtPropertyBoolAction::m_connection
protected

The connection for propertyChangeNotifier().

Definition at line 83 of file WQtPropertyBoolAction.h.

Referenced by WQtPropertyBoolAction().


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