diff options
-rw-r--r-- | src/FbTk/ResTraits.hh | 4 | ||||
-rw-r--r-- | src/Window.cc | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/FbTk/ResTraits.hh b/src/FbTk/ResTraits.hh index 3ee4464..3284801 100644 --- a/src/FbTk/ResTraits.hh +++ b/src/FbTk/ResTraits.hh | |||
@@ -160,7 +160,7 @@ struct EnumTraits { | |||
160 | } | 160 | } |
161 | }; | 161 | }; |
162 | 162 | ||
163 | template<typename Traits> | 163 | template<typename Traits, const char *delim> |
164 | struct VectorTraits { | 164 | struct VectorTraits { |
165 | typedef std::vector<typename Traits::Type> Type; | 165 | typedef std::vector<typename Traits::Type> Type; |
166 | static std::string toString(const Type &x) { | 166 | static std::string toString(const Type &x) { |
@@ -186,7 +186,7 @@ struct VectorTraits { | |||
186 | 186 | ||
187 | static Type fromString(const std::string &x) { | 187 | static Type fromString(const std::string &x) { |
188 | std::vector<std::string> val; | 188 | std::vector<std::string> val; |
189 | StringUtil::stringtok(val, x); | 189 | StringUtil::stringtok(val, x, delim); |
190 | Type retval; | 190 | Type retval; |
191 | 191 | ||
192 | for(size_t i = 0; i < val.size(); i++) { | 192 | for(size_t i = 0; i < val.size(); i++) { |
diff --git a/src/Window.cc b/src/Window.cc index 0296e13..e55a258 100644 --- a/src/Window.cc +++ b/src/Window.cc | |||
@@ -263,9 +263,10 @@ struct TestCornerHelper { | |||
263 | } | 263 | } |
264 | }; | 264 | }; |
265 | 265 | ||
266 | extern const char win_buttons_delim[] = " \t\n"; | ||
266 | typedef FbTk::Resource< | 267 | typedef FbTk::Resource< |
267 | vector<WinButton::Type>, | 268 | vector<WinButton::Type>, |
268 | FbTk::VectorTraits<FbTk::EnumTraits<WinButton::Type> > | 269 | FbTk::VectorTraits<FbTk::EnumTraits<WinButton::Type>, win_buttons_delim> |
269 | > WinButtonsResource; | 270 | > WinButtonsResource; |
270 | 271 | ||
271 | } | 272 | } |