![]() |
VR-Forces 4.6 Class Documentation
|
The logic for the HumbleDialogWidget. More...
Public Member Functions | |
| HumbleDialogLogic (HumbleDialogWidgetInterface &iFace) | |
| Initializing CTOR. | |
| virtual | ~HumbleDialogLogic () |
| Virtual DTOR. | |
| void | slot_processText (const std::string &text) |
| Called when the user presses Return or Enter in the widget. | |
Private Attributes | |
| HumbleDialogWidgetInterface & | myInterface |
| makVrv::DtSignalConnectionManager | myConnections |
The logic for the HumbleDialogWidget.
This class does not have knowledge about how the widget was implemented, but communicates with the widget through an interface. The interface allows the widget or logic to be independently re-factored without affecting the other.
| HumbleDialogLogic::HumbleDialogLogic | ( | HumbleDialogWidgetInterface & | iFace | ) |
Initializing CTOR.
At construction time, this logic is connected to the boost::signals of the widget-interface to receive updates when the widget changes. A reference to the widget-interface is saved to call back to the widget and disconnect during destruction.
|
virtual |
Virtual DTOR.
Disconnect from the boost::signals of the widget-interface.
| void HumbleDialogLogic::slot_processText | ( | const std::string & | text | ) |
Called when the user presses Return or Enter in the widget.
When signaled the given text is simply printed to the console, then this logic-object clears the text-box in the widget by calling setText on the widget-interface.
|
private |
|
private |