summaryrefslogtreecommitdiffstats
path: root/gui
diff options
context:
space:
mode:
Diffstat (limited to 'gui')
-rw-r--r--gui/button.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/gui/button.cpp b/gui/button.cpp
index 601a51667..a4c1b52bd 100644
--- a/gui/button.cpp
+++ b/gui/button.cpp
@@ -104,10 +104,13 @@ GUIButton::GUIButton(xml_node<>* node)
mButtonLabel->SetRenderPos(mTextX, mTextY);
} else {
mTextX = mRenderW + mRenderX + 5;
- mRenderW += mTextW + 5;
mButtonLabel->GetCurrentBounds(mTextW, mTextH);
+ mRenderW += mTextW + 5;
mTextY = mRenderY + (mRenderH / 2) - (mTextH / 2);
mButtonLabel->SetRenderPos(mTextX, mTextY);
+ if (mAction)
+ mAction->SetActionPos(mRenderX, mRenderY, mRenderW, mRenderH);
+ SetActionPos(mRenderX, mRenderY, mRenderW, mRenderH);
}
}
}