minor cosmetic to changes of LauncherDialog & ProgressDialog

This commit is contained in:
Thomas Jentzsch 2021-12-06 11:13:45 +01:00
parent 4462492be8
commit 66e2c857c2
3 changed files with 3 additions and 4 deletions

View File

@ -29,8 +29,7 @@
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ProgressDialog::ProgressDialog(GuiObject* boss, const GUI::Font& font,
const string& message)
: Dialog(boss->instance(), boss->parent()),
myFont{font}
: Dialog(boss->instance(), boss->parent(), font)
{
const int lineHeight = Dialog::lineHeight(),
fontHeight = Dialog::fontHeight(),
@ -72,7 +71,7 @@ void ProgressDialog::setMessage(const string& message)
{
const int buttonWidth = Dialog::buttonWidth("Cancel"),
HBORDER = Dialog::hBorder();
const int lwidth = myFont.getStringWidth(message);
const int lwidth = _font.getStringWidth(message);
// Recalculate real dimensions
_w = HBORDER * 2 + std::max(lwidth, buttonWidth);

View File

@ -41,7 +41,6 @@ class ProgressDialog : public Dialog
bool isCancelled() const { return myIsCancelled; }
private:
const GUI::Font& myFont;
StaticTextWidget* myMessage{nullptr};
SliderWidget* mySlider{nullptr};

View File

@ -244,6 +244,7 @@ void RomInfoWidget::drawWidget(bool hilite)
const int yoff = myAvail.h + _font.getFontHeight() / 2;
s.fillRect(_x+2, _y+2, _w-4, _h-4, _bgcolor);
s.frameRect(_x, _y, _w, myAvail.h, kColor);
s.frameRect(_x, _y+yoff, _w, _h-yoff, kColor);
if(!myHaveProperties)