aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/TextButton.cc
diff options
context:
space:
mode:
authorsimonb <simonb>2006-06-24 14:05:19 (GMT)
committersimonb <simonb>2006-06-24 14:05:19 (GMT)
commit0b730c76b10babe20738067ae7aec5a102d451fe (patch)
tree727cc111eeffd9fe838a04d54da834b9d74b6905 /src/FbTk/TextButton.cc
parent1d0b23bd020c9185dc9cbf8952ab97a27f061be0 (diff)
downloadfluxbox-0b730c76b10babe20738067ae7aec5a102d451fe.zip
fluxbox-0b730c76b10babe20738067ae7aec5a102d451fe.tar.bz2
fix more x errors due to using an invalid background
Diffstat (limited to 'src/FbTk/TextButton.cc')
-rw-r--r--src/FbTk/TextButton.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/FbTk/TextButton.cc b/src/FbTk/TextButton.cc
index 0d9eef0..474c094 100644
--- a/src/FbTk/TextButton.cc
+++ b/src/FbTk/TextButton.cc
@@ -63,8 +63,10 @@ void TextButton::setJustify(FbTk::Justify just) {
63} 63}
64 64
65bool TextButton::setOrientation(FbTk::Orientation orient) { 65bool TextButton::setOrientation(FbTk::Orientation orient) {
66 if (!m_font->validOrientation(orient)) 66 if (orient == m_orientation
67 || !m_font->validOrientation(orient))
67 return false; 68 return false;
69 invalidateBackground();
68 70
69 if ((m_orientation == FbTk::ROT0 || m_orientation == FbTk::ROT180) && 71 if ((m_orientation == FbTk::ROT0 || m_orientation == FbTk::ROT180) &&
70 (orient == FbTk::ROT90 || orient == FbTk::ROT270) || 72 (orient == FbTk::ROT90 || orient == FbTk::ROT270) ||
@@ -76,8 +78,7 @@ bool TextButton::setOrientation(FbTk::Orientation orient) {
76 } else { 78 } else {
77 m_orientation = orient; 79 m_orientation = orient;
78 } 80 }
79 updateBackground(false); 81
80 clear();
81 return true; 82 return true;
82} 83}
83 84