summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/widgets/button.h1
-rw-r--r--src/gui/widgets/pincode.cpp4
-rw-r--r--src/gui/windows/pincodedialog.cpp2
3 files changed, 5 insertions, 2 deletions
diff --git a/src/gui/widgets/button.h b/src/gui/widgets/button.h
index 447ef8192..a14a1a5a1 100644
--- a/src/gui/widgets/button.h
+++ b/src/gui/widgets/button.h
@@ -86,6 +86,7 @@ class Skin;
const std::string BUTTON_PLAY = "buttonplay.png";
const std::string BUTTON_SKIN = "button";
+const std::string BUTTON_PIN_SKIN = "buttonpin";
/**
* Button widget. Same as the Guichan button but with custom look.
diff --git a/src/gui/widgets/pincode.cpp b/src/gui/widgets/pincode.cpp
index e0f0ce3d8..6d826e3e2 100644
--- a/src/gui/widgets/pincode.cpp
+++ b/src/gui/widgets/pincode.cpp
@@ -97,7 +97,7 @@ void Pincode::addButtons()
mButtons[f] = new Button(this,
str,
str,
- BUTTON_SKIN,
+ BUTTON_PIN_SKIN,
this);
mButtons[f]->adjustSize();
const Rect &rect = mButtons[f]->getDimension();
@@ -126,7 +126,7 @@ void Pincode::addButtons()
// TRANSLATORS: clear pin code button
_("Clear"),
"clear",
- BUTTON_SKIN,
+ BUTTON_PIN_SKIN,
this);
mButtons[10]->adjustSize();
add(mButtons[10]);
diff --git a/src/gui/windows/pincodedialog.cpp b/src/gui/windows/pincodedialog.cpp
index 223ad69c0..0e79774ac 100644
--- a/src/gui/windows/pincodedialog.cpp
+++ b/src/gui/windows/pincodedialog.cpp
@@ -75,6 +75,8 @@ PincodeDialog::PincodeDialog(const std::string &restrict title,
int width = getFont()->getWidth(title);
if (width < textLabel->getWidth())
width = textLabel->getWidth();
+ if (width < mPincode->getWidth())
+ width = mPincode->getWidth();
reflowLayout(CAST_S32(width + 20), 0);
updateButtons();
}