mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 04:15:52 +08:00
SPE-2199 - Add .jpg in ScalableBitmap
+ TopBar: Set correct size for "user" icon
This commit is contained in:
parent
cd76008e81
commit
b4c6ec1068
@ -301,10 +301,10 @@ void TopBarItemsCtrl::UpdateAccountMenu(bool avatar/* = false*/)
|
|||||||
if (new_logo.IsOk())
|
if (new_logo.IsOk())
|
||||||
m_account_btn->SetBitmapBundle(new_logo.bmp());
|
m_account_btn->SetBitmapBundle(new_logo.bmp());
|
||||||
else
|
else
|
||||||
m_account_btn->SetBitmapBundle(*get_bmp_bundle("user"));
|
m_account_btn->SetBitmapBundle(*get_bmp_bundle("user", 24));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
m_account_btn->SetBitmapBundle(*get_bmp_bundle("user"));
|
m_account_btn->SetBitmapBundle(*get_bmp_bundle("user", 24));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -860,6 +860,11 @@ ScalableBitmap::ScalableBitmap(wxWindow* parent, boost::filesystem::path& icon_p
|
|||||||
wxBitmap::Rescale(bitmap, icon_size);
|
wxBitmap::Rescale(bitmap, icon_size);
|
||||||
m_bmp = wxBitmapBundle(bitmap);
|
m_bmp = wxBitmapBundle(bitmap);
|
||||||
}
|
}
|
||||||
|
else if (ext == ".jpg") {
|
||||||
|
bitmap.LoadFile(path, wxBITMAP_TYPE_JPEG);
|
||||||
|
wxBitmap::Rescale(bitmap, icon_size);
|
||||||
|
m_bmp = wxBitmapBundle(bitmap);
|
||||||
|
}
|
||||||
else if (ext == ".svg") {
|
else if (ext == ".svg") {
|
||||||
m_bmp = wxBitmapBundle::FromSVGFile(path, icon_size);
|
m_bmp = wxBitmapBundle::FromSVGFile(path, icon_size);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user