Move sheet navigation commands below active tool commands.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16367
This commit is contained in:
Jeff Young 2023-12-17 22:06:28 +00:00
parent 16c8050f3d
commit a944310f7b
3 changed files with 7 additions and 7 deletions

View File

@ -274,10 +274,6 @@ bool EE_SELECTION_TOOL::Init()
menu.AddItem( EE_ACTIONS::clearHighlight, haveHighlight && EE_CONDITIONS::Idle, 1 );
menu.AddSeparator( haveHighlight && EE_CONDITIONS::Idle, 1 );
menu.AddItem( EE_ACTIONS::enterSheet, sheetSelection && EE_CONDITIONS::Idle, 2 );
menu.AddItem( EE_ACTIONS::selectOnPCB, crossProbingSelection && EE_CONDITIONS::Idle, 2 );
menu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 2 );
menu.AddSeparator( 100 );
menu.AddItem( EE_ACTIONS::drawWire, schEditCondition && EE_CONDITIONS::Empty, 100 );
menu.AddItem( EE_ACTIONS::drawBus, schEditCondition && EE_CONDITIONS::Empty, 100 );
@ -285,6 +281,10 @@ bool EE_SELECTION_TOOL::Init()
menu.AddSeparator( 100 );
menu.AddItem( ACTIONS::finishInteractive, SCH_LINE_WIRE_BUS_TOOL::IsDrawingLineWireOrBus, 100 );
menu.AddItem( EE_ACTIONS::enterSheet, sheetSelection && EE_CONDITIONS::Idle, 150 );
menu.AddItem( EE_ACTIONS::selectOnPCB, crossProbingSelection && EE_CONDITIONS::Idle, 150 );
menu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 150 );
menu.AddSeparator( 200 );
menu.AddItem( EE_ACTIONS::selectConnection, connectedSelection && EE_CONDITIONS::Idle, 250 );
menu.AddItem( EE_ACTIONS::placeJunction, wireOrBusSelection && EE_CONDITIONS::Idle, 250 );

View File

@ -99,7 +99,7 @@ bool SCH_DRAWING_TOOLS::Init()
};
CONDITIONAL_MENU& ctxMenu = m_menu.GetMenu();
ctxMenu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 2 );
ctxMenu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 150 );
return true;
}

View File

@ -212,8 +212,6 @@ bool SCH_LINE_WIRE_BUS_TOOL::Init()
ctxMenu.AddItem( EE_ACTIONS::clearHighlight, haveHighlight && EE_CONDITIONS::Idle, 1 );
ctxMenu.AddSeparator( haveHighlight && EE_CONDITIONS::Idle, 1 );
ctxMenu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 2 );
ctxMenu.AddSeparator( 10 );
ctxMenu.AddItem( EE_ACTIONS::drawWire, wireOrBusTool && EE_CONDITIONS::Idle, 10 );
ctxMenu.AddItem( EE_ACTIONS::drawBus, wireOrBusTool && EE_CONDITIONS::Idle, 10 );
@ -234,6 +232,8 @@ bool SCH_LINE_WIRE_BUS_TOOL::Init()
ctxMenu.AddItem( EE_ACTIONS::breakWire, wireOrBusTool && EE_CONDITIONS::Idle, 100 );
ctxMenu.AddItem( EE_ACTIONS::slice, ( wireOrBusTool || lineTool )
&& EE_CONDITIONS::Idle, 100 );
ctxMenu.AddItem( EE_ACTIONS::leaveSheet, belowRootSheetCondition, 150 );
ctxMenu.AddSeparator( 200 );
ctxMenu.AddItem( EE_ACTIONS::selectNode, wireOrBusTool && EE_CONDITIONS::Idle, 200 );
ctxMenu.AddItem( EE_ACTIONS::selectConnection, wireOrBusTool && EE_CONDITIONS::Idle, 200 );