eeschema: Allow labels to rotate on bus unfold
This commit is contained in:
parent
04edc6ceff
commit
1df7b718d9
|
@ -450,6 +450,10 @@ int SCH_LINE_WIRE_BUS_TOOL::doDrawSegments( const std::string& aTool, int aType,
|
||||||
|
|
||||||
Activate();
|
Activate();
|
||||||
|
|
||||||
|
// Add the new label to the selection so the rotate command operates on it
|
||||||
|
if( m_busUnfold.label )
|
||||||
|
m_selectionTool->AddItemToSel( m_busUnfold.label, true );
|
||||||
|
|
||||||
// Main loop: keep receiving events
|
// Main loop: keep receiving events
|
||||||
while( TOOL_EVENT* evt = Wait() )
|
while( TOOL_EVENT* evt = Wait() )
|
||||||
{
|
{
|
||||||
|
@ -471,6 +475,9 @@ int SCH_LINE_WIRE_BUS_TOOL::doDrawSegments( const std::string& aTool, int aType,
|
||||||
if( m_busUnfold.entry )
|
if( m_busUnfold.entry )
|
||||||
m_frame->RemoveFromScreen( m_busUnfold.entry );
|
m_frame->RemoveFromScreen( m_busUnfold.entry );
|
||||||
|
|
||||||
|
if( m_busUnfold.label && !m_busUnfold.label_placed )
|
||||||
|
m_selectionTool->RemoveItemFromSel( m_busUnfold.label, true );
|
||||||
|
|
||||||
if( m_busUnfold.label && m_busUnfold.label_placed )
|
if( m_busUnfold.label && m_busUnfold.label_placed )
|
||||||
m_frame->RemoveFromScreen( m_busUnfold.label );
|
m_frame->RemoveFromScreen( m_busUnfold.label );
|
||||||
|
|
||||||
|
@ -533,6 +540,7 @@ int SCH_LINE_WIRE_BUS_TOOL::doDrawSegments( const std::string& aTool, int aType,
|
||||||
wxASSERT( aType == LAYER_WIRE );
|
wxASSERT( aType == LAYER_WIRE );
|
||||||
|
|
||||||
m_frame->AddToScreen( m_busUnfold.label );
|
m_frame->AddToScreen( m_busUnfold.label );
|
||||||
|
m_selectionTool->RemoveItemFromSel( m_busUnfold.label, true );
|
||||||
m_busUnfold.label_placed = true;
|
m_busUnfold.label_placed = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue