TwiceAsNice  2019-02-18
Public Slots | Public Member Functions | Public Attributes | Static Public Attributes | Private Slots | Private Member Functions | Private Attributes | List of all members
ActionEditorImpl Class Reference

#include <ActionEditorImpl.h>

Inheritance diagram for ActionEditorImpl:
Inheritance graph
Collaboration diagram for ActionEditorImpl:
Collaboration graph

Public Slots

void set ()
 Slot is called when the date of the widget is changed. More...
 

Public Member Functions

 ActionEditorImpl (QWidget *parent=0, bool _connect=false)
 Constructor. More...
 
virtual ~ActionEditorImpl ()
 
virtual void updateGUI (const Nice::Any &_val)
 Update the gui with new value. More...
 
void getSessionData (Nice::JointPtr _j)
 
void setSessionData (Nice::JointPtr _j)
 Set the internal session data from thge passed Joint. More...
 
QString command ()
 
- Public Member Functions inherited from Nice::BridgeItem
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 

Public Attributes

Ui::ActionEditorm_editor
 
bool m_play
 
ReadStdOutm_stdout
 
- Public Attributes inherited from Nice::BridgeItem
QGroupBox * m_container
 
bool m_locked
 

Static Public Attributes

static const char * s_logTypeStr []
 
- Static Public Attributes inherited from Nice::BridgeItem
static std::map< CompletionState, QString > * s_palette = 0
 

Private Slots

void slot_load ()
 
bool slot_save ()
 
bool slot_saveas ()
 
void slot_record (bool _rec)
 
void slot_pause (bool _pause)
 
void slot_step ()
 
void slot_play (bool _play)
 
void slot_modified ()
 
void slot_msgChanged (QString)
 
void slot_stop ()
 

Private Member Functions

void createStatusBar ()
 
bool maybeSave ()
 
void loadFile (const QString &fileName)
 
bool saveFile (const QString &fileName)
 
bool saveAs ()
 
void setCurrentFile (const QString &fileName)
 
void parsePythonString ()
 

Private Attributes

PlayThreadm_playthread
 
QString m_file
 
bool m_modified
 
QString m_command
 

Additional Inherited Members

- Protected Member Functions inherited from Nice::BridgeItem
virtual void initSlots ()
 
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
virtual void initSlots ()
 
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
virtual void initSlots ()
 
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
- Protected Attributes inherited from Nice::BridgeItem
bool m_inited
 
CompletionState m_state
 
bool m_autoSynch
 
bool m_isUserConfirmationNeeded
 
Nice::Jointm_root
 
Nice::Propertym_prop
 
WaveBreakerPtr m_breaker
 
bool m_showLabels
 
Nice::I64 m_id
 
QString m_nodeName
 
std::vector< Nice::PropertyPtrm_connectedProps
 

Constructor & Destructor Documentation

◆ ActionEditorImpl()

ActionEditorImpl::ActionEditorImpl ( QWidget *  parent = 0,
bool  _connect = false 
)

Constructor.

Parameters
parentParent widget.
_connectAutosync activation.

◆ ~ActionEditorImpl()

ActionEditorImpl::~ActionEditorImpl ( )
virtual

Member Function Documentation

◆ command()

QString ActionEditorImpl::command ( )
inline

◆ createStatusBar()

void ActionEditorImpl::createStatusBar ( )
private

◆ getSessionData()

void ActionEditorImpl::getSessionData ( Nice::JointPtr  _j)

◆ loadFile()

void ActionEditorImpl::loadFile ( const QString &  fileName)
private

◆ maybeSave()

bool ActionEditorImpl::maybeSave ( )
private

◆ parsePythonString()

void ActionEditorImpl::parsePythonString ( )
private

◆ saveAs()

bool ActionEditorImpl::saveAs ( )
private

◆ saveFile()

bool ActionEditorImpl::saveFile ( const QString &  fileName)
private

◆ set

void ActionEditorImpl::set ( )
slot

Slot is called when the date of the widget is changed.

◆ setCurrentFile()

void ActionEditorImpl::setCurrentFile ( const QString &  fileName)
private

◆ setSessionData()

void ActionEditorImpl::setSessionData ( Nice::JointPtr  )
virtual

Set the internal session data from thge passed Joint.

The function can be implemented in the derived widgets.

Parameters
_dataData node to read the session data from.

Reimplemented from Nice::BridgeItem.

◆ slot_load

void ActionEditorImpl::slot_load ( )
privateslot

◆ slot_modified

void ActionEditorImpl::slot_modified ( )
privateslot

◆ slot_msgChanged

void ActionEditorImpl::slot_msgChanged ( QString  message)
privateslot

◆ slot_pause

void ActionEditorImpl::slot_pause ( bool  _pause)
privateslot

◆ slot_play

void ActionEditorImpl::slot_play ( bool  _play)
privateslot

◆ slot_record

void ActionEditorImpl::slot_record ( bool  _rec)
privateslot

◆ slot_save

bool ActionEditorImpl::slot_save ( )
privateslot

◆ slot_saveas

bool ActionEditorImpl::slot_saveas ( )
privateslot

◆ slot_step

void ActionEditorImpl::slot_step ( )
privateslot

◆ slot_stop

void ActionEditorImpl::slot_stop ( )
privateslot

◆ updateGUI()

void ActionEditorImpl::updateGUI ( const Nice::Any _val)
virtual

Update the gui with new value.

Parameters
_valNew vlaue.

Member Data Documentation

◆ m_command

QString ActionEditorImpl::m_command
private

◆ m_editor

Ui::ActionEditor* ActionEditorImpl::m_editor

◆ m_file

QString ActionEditorImpl::m_file
private

◆ m_modified

bool ActionEditorImpl::m_modified
private

◆ m_play

bool ActionEditorImpl::m_play

◆ m_playthread

PlayThread* ActionEditorImpl::m_playthread
private

◆ m_stdout

ReadStdOut* ActionEditorImpl::m_stdout

◆ s_logTypeStr

const char * ActionEditorImpl::s_logTypeStr
static
Initial value:
= {
"<b><font color=red >" "FATAL" "</font></b>",
"<font color=red>" "ALERT" "</font>",
"<font color=red>" "CRITICAL" "</font>",
"<font color=red>" "ERROR" "</font>",
"<font color=yellow>" "WARNING" "</font>",
"<font color=cyan>" "NOTICE" "</font>",
"<font color=green>" "INFO" "</font>",
"<font color=olive>" "USER1" "</font>",
"<font color=magenta>" "USER2" "</font>",
"<font color=magenta>" "USER3" "</font>",
"<font color=magenta>" "USER4" "</font>",
"<font color=magenta>" "USER5" "</font>",
"<font color=magenta>" "USER6" "</font>",
"<font color=magenta>" "USER7" "</font>",
"<font color=magenta>" "USER8" "</font>",
"<font color=magenta>" "USER9" "</font>",
"<font color=blue>" "DEBUG" "</font>",
"<font color=maroon>" "TRACE" "</font>"
}

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