Eeschema: never replace event position in wire drawing tool
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7745
This commit is contained in:
parent
f4cc9b86e3
commit
375cd12258
|
@ -519,8 +519,9 @@ int SCH_LINE_WIRE_BUS_TOOL::doDrawSegments( const std::string& aTool, int aType,
|
|||
grid.ClearMaskFlag( GRID_HELPER::HORIZONTAL );
|
||||
}
|
||||
|
||||
wxPoint cursorPos = evt->IsPrime() ? (wxPoint) evt->Position()
|
||||
: (wxPoint) controls->GetMousePosition();
|
||||
wxPoint cursorPos = static_cast<wxPoint>( evt->HasPosition() ?
|
||||
evt->Position() :
|
||||
controls->GetMousePosition() );
|
||||
|
||||
cursorPos = (wxPoint) grid.BestSnapAnchor( cursorPos, LAYER_CONNECTABLE, segment );
|
||||
controls->ForceCursorPosition( true, cursorPos );
|
||||
|
|
Loading…
Reference in New Issue