Prevent ghost image after canceling bitmap placement.
This commit is contained in:
parent
8b1318c92f
commit
ecb28ddf1c
|
@ -501,6 +501,7 @@ int SCH_DRAWING_TOOLS::PlaceImage( const TOOL_EVENT& aEvent )
|
||||||
{
|
{
|
||||||
m_toolMgr->RunAction( EE_ACTIONS::clearSelection, true );
|
m_toolMgr->RunAction( EE_ACTIONS::clearSelection, true );
|
||||||
m_view->ClearPreview();
|
m_view->ClearPreview();
|
||||||
|
m_view->RecacheAllItems();
|
||||||
delete image;
|
delete image;
|
||||||
image = nullptr;
|
image = nullptr;
|
||||||
};
|
};
|
||||||
|
|
|
@ -572,6 +572,7 @@ int DRAWING_TOOL::PlaceImage( const TOOL_EVENT& aEvent )
|
||||||
{
|
{
|
||||||
m_toolMgr->RunAction( PCB_ACTIONS::selectionClear, true );
|
m_toolMgr->RunAction( PCB_ACTIONS::selectionClear, true );
|
||||||
m_view->ClearPreview();
|
m_view->ClearPreview();
|
||||||
|
m_view->RecacheAllItems();
|
||||||
delete image;
|
delete image;
|
||||||
image = nullptr;
|
image = nullptr;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue