Commit 26323007 authored by Maciej Suminski's avatar Maciej Suminski

Added a handler for not implemented toolbar buttons functionality in GAL.

parent 94cc845b
...@@ -261,6 +261,10 @@ TOOL_ACTION COMMON_ACTIONS::showHelp( "pcbnew.Control.showHelp", ...@@ -261,6 +261,10 @@ TOOL_ACTION COMMON_ACTIONS::showHelp( "pcbnew.Control.showHelp",
AS_GLOBAL, '?', AS_GLOBAL, '?',
"", "" ); "", "" );
TOOL_ACTION COMMON_ACTIONS::toBeDone( "pcbnew.Control.toBeDone",
AS_GLOBAL, 0, // dialog saying it is not implemented yet
"", "" ); // so users are aware of that
TOOL_ACTION COMMON_ACTIONS::routerActivate( "pcbnew.InteractiveRouter", TOOL_ACTION COMMON_ACTIONS::routerActivate( "pcbnew.InteractiveRouter",
AS_GLOBAL, 'X', AS_GLOBAL, 'X',
"Run push & shove router", "Run push & shove router", AF_ACTIVATE ); "Run push & shove router", "Run push & shove router", AF_ACTIVATE );
...@@ -317,6 +321,17 @@ boost::optional<TOOL_EVENT> COMMON_ACTIONS::TranslateLegacyId( int aId ) ...@@ -317,6 +321,17 @@ boost::optional<TOOL_EVENT> COMMON_ACTIONS::TranslateLegacyId( int aId )
case ID_ZOOM_PAGE: // toolbar button "Fit on Screen" case ID_ZOOM_PAGE: // toolbar button "Fit on Screen"
return COMMON_ACTIONS::zoomFitScreen.MakeEvent(); return COMMON_ACTIONS::zoomFitScreen.MakeEvent();
case ID_PCB_DELETE_ITEM_BUTT:
case ID_PCB_HIGHLIGHT_BUTT:
case ID_PCB_SHOW_1_RATSNEST_BUTT:
case ID_PCB_PLACE_OFFSET_COORD_BUTT:
case ID_TB_OPTIONS_SHOW_MODULE_RATSNEST:
case ID_TB_OPTIONS_SELECT_CURSOR:
case ID_TB_OPTIONS_SHOW_EXTRA_VERTICAL_TOOLBAR_MICROWAVE:
case ID_MENU_PCB_SHOW_HIDE_MUWAVE_TOOLBAR:
case ID_MICROWAVE_V_TOOLBAR:
return COMMON_ACTIONS::toBeDone.MakeEvent();
} }
return boost::optional<TOOL_EVENT>(); return boost::optional<TOOL_EVENT>();
......
...@@ -148,6 +148,7 @@ public: ...@@ -148,6 +148,7 @@ public:
static TOOL_ACTION resetCoords; static TOOL_ACTION resetCoords;
static TOOL_ACTION switchUnits; static TOOL_ACTION switchUnits;
static TOOL_ACTION showHelp; static TOOL_ACTION showHelp;
static TOOL_ACTION toBeDone;
/** /**
* Function TranslateLegacyId() * Function TranslateLegacyId()
......
...@@ -506,6 +506,15 @@ int PCBNEW_CONTROL::ShowHelp( TOOL_EVENT& aEvent ) ...@@ -506,6 +506,15 @@ int PCBNEW_CONTROL::ShowHelp( TOOL_EVENT& aEvent )
} }
int PCBNEW_CONTROL::ToBeDone( TOOL_EVENT& aEvent )
{
DisplayInfoMessage( m_frame, _( "Not implemented yet." ) );
setTransitions();
return 0;
}
void PCBNEW_CONTROL::setTransitions() void PCBNEW_CONTROL::setTransitions()
{ {
// View controls // View controls
...@@ -549,4 +558,5 @@ void PCBNEW_CONTROL::setTransitions() ...@@ -549,4 +558,5 @@ void PCBNEW_CONTROL::setTransitions()
Go( &PCBNEW_CONTROL::ResetCoords, COMMON_ACTIONS::resetCoords.MakeEvent() ); Go( &PCBNEW_CONTROL::ResetCoords, COMMON_ACTIONS::resetCoords.MakeEvent() );
Go( &PCBNEW_CONTROL::SwitchUnits, COMMON_ACTIONS::switchUnits.MakeEvent() ); Go( &PCBNEW_CONTROL::SwitchUnits, COMMON_ACTIONS::switchUnits.MakeEvent() );
Go( &PCBNEW_CONTROL::ShowHelp, COMMON_ACTIONS::showHelp.MakeEvent() ); Go( &PCBNEW_CONTROL::ShowHelp, COMMON_ACTIONS::showHelp.MakeEvent() );
Go( &PCBNEW_CONTROL::ToBeDone, COMMON_ACTIONS::toBeDone.MakeEvent() );
} }
...@@ -91,6 +91,7 @@ public: ...@@ -91,6 +91,7 @@ public:
int ResetCoords( TOOL_EVENT& aEvent ); int ResetCoords( TOOL_EVENT& aEvent );
int SwitchUnits( TOOL_EVENT& aEvent ); int SwitchUnits( TOOL_EVENT& aEvent );
int ShowHelp( TOOL_EVENT& aEvent ); int ShowHelp( TOOL_EVENT& aEvent );
int ToBeDone( TOOL_EVENT& aEvent );
private: private:
///> Sets up handlers for various events. ///> Sets up handlers for various events.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment