Added TOOL_MANAGER::RunAction() function.

This commit is contained in:
Maciej Suminski 2013-12-03 15:41:41 +01:00
parent bec2e9b178
commit ad3cb1f36a
2 changed files with 15 additions and 0 deletions

View File

@ -194,6 +194,12 @@ void TOOL_MANAGER::UnregisterAction( TOOL_ACTION* aAction )
}
bool TOOL_MANAGER::RunAction( const std::string& aActionName )
{
return m_actionMgr->RunAction( aActionName );
}
bool TOOL_MANAGER::invokeTool( TOOL_BASE* aTool )
{
wxASSERT( aTool != NULL );

View File

@ -99,6 +99,15 @@ public:
*/
void UnregisterAction( TOOL_ACTION* aAction );
/**
* Function RunAction()
* Runs the specified action. The common format is "application.ToolName.Action".
*
* @param aActionName is the name of action to be invoked.
* @return True if the action finished successfully, false otherwise.
*/
bool RunAction( const std::string& aActionName );
/**
* Function FindTool()
* Searches for a tool with given ID.