Fix shades field preferred size when UI scaling > 100%

This commit is contained in:
David Capello 2015-11-23 15:05:35 -03:00
parent c34f0e4eb7
commit 25a331c43a

View File

@ -506,9 +506,8 @@ private:
void onPreferredSize(PreferredSizeEvent& ev) override {
int size = getColors().size();
if (size < 2)
ev.setPreferredSize(Size(16+getTextWidth(), 18)*guiscale());
ev.setPreferredSize(Size(16*guiscale()+getTextWidth(), 18*guiscale()));
else
ev.setPreferredSize(Size(6+12*size, 18)*guiscale());
}