Add unit submenu to page layout editor view menu
This commit is contained in:
parent
27f3ac980f
commit
9d3aca56bb
|
@ -110,6 +110,16 @@ void PL_EDITOR_FRAME::ReCreateMenuBar()
|
|||
|
||||
viewMenu->AppendSeparator();
|
||||
viewMenu->Add( ACTIONS::toggleGrid, ACTION_MENU::CHECK );
|
||||
|
||||
// Units submenu
|
||||
ACTION_MENU* unitsSubMenu = new ACTION_MENU( false, selTool );
|
||||
unitsSubMenu->SetTitle( _( "&Units" ) );
|
||||
unitsSubMenu->SetIcon( unit_mm_xpm );
|
||||
unitsSubMenu->Add( ACTIONS::inchesUnits, ACTION_MENU::CHECK );
|
||||
unitsSubMenu->Add( ACTIONS::milsUnits, ACTION_MENU::CHECK );
|
||||
unitsSubMenu->Add( ACTIONS::millimetersUnits, ACTION_MENU::CHECK );
|
||||
viewMenu->Add( unitsSubMenu );
|
||||
|
||||
viewMenu->Add( ACTIONS::toggleCursorStyle, ACTION_MENU::CHECK );
|
||||
|
||||
viewMenu->AppendSeparator();
|
||||
|
|
|
@ -253,6 +253,9 @@ void PL_EDITOR_FRAME::setupUIConditions()
|
|||
|
||||
mgr->SetConditions( ACTIONS::toggleGrid, CHECK( cond.GridVisible() ) );
|
||||
mgr->SetConditions( ACTIONS::toggleCursorStyle, CHECK( cond.FullscreenCursor() ) );
|
||||
mgr->SetConditions( ACTIONS::millimetersUnits, CHECK( cond.Units( EDA_UNITS::MILLIMETRES ) ) );
|
||||
mgr->SetConditions( ACTIONS::inchesUnits, CHECK( cond.Units( EDA_UNITS::INCHES ) ) );
|
||||
mgr->SetConditions( ACTIONS::milsUnits, CHECK( cond.Units( EDA_UNITS::MILS ) ) );
|
||||
|
||||
mgr->SetConditions( ACTIONS::cut, ENABLE( SELECTION_CONDITIONS::NotEmpty ) );
|
||||
mgr->SetConditions( ACTIONS::copy, ENABLE( SELECTION_CONDITIONS::NotEmpty ) );
|
||||
|
|
Loading…
Reference in New Issue