summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/FbTk/MenuTheme.cc14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/FbTk/MenuTheme.cc b/src/FbTk/MenuTheme.cc
index fa654f7..b130829 100644
--- a/src/FbTk/MenuTheme.cc
+++ b/src/FbTk/MenuTheme.cc
@@ -19,7 +19,7 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id: MenuTheme.cc,v 1.4 2003/02/15 01:49:43 fluxgen Exp $ 22// $Id: MenuTheme.cc,v 1.5 2003/02/22 19:08:28 fluxgen Exp $
23 23
24#include "MenuTheme.hh" 24#include "MenuTheme.hh"
25 25
@@ -29,7 +29,6 @@
29#include "App.hh" 29#include "App.hh"
30//TODO change this 30//TODO change this
31#include "../StringUtil.hh" 31#include "../StringUtil.hh"
32
33#include <cstdio> 32#include <cstdio>
34 33
35namespace FbTk { 34namespace FbTk {
@@ -88,7 +87,7 @@ void MenuTheme::reconfigTheme() {
88 87
89 XGCValues gcv; 88 XGCValues gcv;
90 unsigned long gc_value_mask = GCForeground; 89 unsigned long gc_value_mask = GCForeground;
91 90
92 gcv.foreground = t_text->pixel(); 91 gcv.foreground = t_text->pixel();
93 92
94 XChangeGC(m_display, t_text_gc, 93 XChangeGC(m_display, t_text_gc,
@@ -123,13 +122,16 @@ void ThemeItem<MenuTheme::BulletType>::setDefaultValue() {
123 122
124template <> 123template <>
125void ThemeItem<MenuTheme::BulletType>::setFromString(const char *str) { 124void ThemeItem<MenuTheme::BulletType>::setFromString(const char *str) {
125
126 // do nothing 126 // do nothing
127 if (StringUtil::strcasestr(str, "EMPTY") == 0) 127 if (StringUtil::strcasestr(str, "empty") != 0)
128 m_value = MenuTheme::EMPTY; 128 m_value = MenuTheme::EMPTY;
129 else if (StringUtil::strcasestr(str, "SQUARE") == 0) 129 else if (StringUtil::strcasestr(str, "square") != 0)
130 m_value = MenuTheme::SQUARE; 130 m_value = MenuTheme::SQUARE;
131 else if (StringUtil::strcasestr(str, "TRIANGLE") == 0) 131 else if (StringUtil::strcasestr(str, "triangle") != 0)
132 m_value = MenuTheme::TRIANGLE; 132 m_value = MenuTheme::TRIANGLE;
133 else if (StringUtil::strcasestr(str, "diamond") != 0)
134 m_value = MenuTheme::DIAMOND;
133 else 135 else
134 setDefaultValue(); 136 setDefaultValue();
135} 137}