diff --git a/src/gui/CommandDialog.cxx b/src/gui/CommandDialog.cxx index 72586bfea..a2257117c 100644 --- a/src/gui/CommandDialog.cxx +++ b/src/gui/CommandDialog.cxx @@ -37,20 +37,20 @@ CommandDialog::CommandDialog(OSystem& osystem, DialogContainer& parent) const int buttonWidth = _font.getStringWidth("Stella Palette") + 16, buttonHeight = _font.getLineHeight() + 6, rowHeight = buttonHeight + VGAP; - + // Set real dimensions _w = 3 * (buttonWidth + 5) + HBORDER * 2; _h = 6 * rowHeight - VGAP + VBORDER * 2 + _th; - ButtonWidget* bw; + ButtonWidget* bw = nullptr; WidgetArray wid; int xoffset = HBORDER, yoffset = VBORDER + _th; auto ADD_CD_BUTTON = [&](const string& label, int cmd) { - ButtonWidget* bw = new ButtonWidget(this, _font, xoffset, yoffset, + ButtonWidget* b = new ButtonWidget(this, _font, xoffset, yoffset, buttonWidth, buttonHeight, label, cmd); yoffset += buttonHeight + VGAP; - return bw; + return b; }; // Column 1 diff --git a/src/gui/UIDialog.cxx b/src/gui/UIDialog.cxx index 3ac4bbb8c..52c213114 100644 --- a/src/gui/UIDialog.cxx +++ b/src/gui/UIDialog.cxx @@ -196,6 +196,11 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent, addBGroupToFocusList(wid); } +// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +UIDialog::~UIDialog() +{ +} + // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - void UIDialog::loadConfig() { diff --git a/src/gui/UIDialog.hxx b/src/gui/UIDialog.hxx index 676ee8ff0..da0515867 100644 --- a/src/gui/UIDialog.hxx +++ b/src/gui/UIDialog.hxx @@ -35,7 +35,7 @@ class UIDialog : public Dialog { public: UIDialog(OSystem& osystem, DialogContainer& parent, const GUI::Font& font); - virtual ~UIDialog() = default; + virtual ~UIDialog(); private: void loadConfig() override;