Fix icon-scaling issue for ACTION_TOOLBAR.
Fixes: lp:1829291 * https://bugs.launchpad.net/kicad/+bug/1829291
This commit is contained in:
parent
fbb807f3bb
commit
b4d4525496
|
@ -41,10 +41,11 @@ ACTION_TOOLBAR::ACTION_TOOLBAR( EDA_DRAW_FRAME* parent, wxWindowID id, const wxP
|
|||
|
||||
void ACTION_TOOLBAR::Add( const TOOL_ACTION& aAction, bool aIsToggleEntry )
|
||||
{
|
||||
EDA_DRAW_FRAME* editFrame = m_toolManager->GetEditFrame();
|
||||
int toolId = aAction.GetId() + ACTION_ID;
|
||||
|
||||
AddTool( toolId, wxEmptyString, KiBitmap( aAction.GetIcon() ), aAction.GetDescription(),
|
||||
aIsToggleEntry ? wxITEM_CHECK : wxITEM_NORMAL );
|
||||
AddTool( toolId, wxEmptyString, KiScaledBitmap( aAction.GetIcon(), editFrame ),
|
||||
aAction.GetDescription(), aIsToggleEntry ? wxITEM_CHECK : wxITEM_NORMAL );
|
||||
|
||||
m_toolKinds[ toolId ] = aIsToggleEntry;
|
||||
m_toolActions[ toolId ] = &aAction;
|
||||
|
|
Loading…
Reference in New Issue