diff options
author | markt <markt> | 2007-10-21 21:37:48 (GMT) |
---|---|---|
committer | markt <markt> | 2007-10-21 21:37:48 (GMT) |
commit | f72633a0e0df146c4860b5b3940e9c3a2f7260b1 (patch) | |
tree | ccbb237adaa4df190cf5992ad9ead51d365d7d66 /src | |
parent | 72299cca4829046d51bbbb8c74d506f7289dd879 (diff) | |
download | fluxbox-f72633a0e0df146c4860b5b3940e9c3a2f7260b1.zip fluxbox-f72633a0e0df146c4860b5b3940e9c3a2f7260b1.tar.bz2 |
allow decorations bitmask to be specified with 0x
Diffstat (limited to 'src')
-rw-r--r-- | src/Window.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/Window.cc b/src/Window.cc index 5e9aec5..9a3d367 100644 --- a/src/Window.cc +++ b/src/Window.cc | |||
@@ -4086,8 +4086,9 @@ int FluxboxWindow::getDecoMaskFromString(const string &str_label) { | |||
4086 | return DECOR_BORDER; | 4086 | return DECOR_BORDER; |
4087 | if (strcasecmp(str_label.c_str(), "TAB") == 0) | 4087 | if (strcasecmp(str_label.c_str(), "TAB") == 0) |
4088 | return DECOR_TAB; | 4088 | return DECOR_TAB; |
4089 | unsigned int mask = atoi(str_label.c_str()); | 4089 | int mask = -1; |
4090 | if (mask) | 4090 | if (str_label.size() > 1 && str_label[0] == '0' && str_label[1] == 'x' || |
4091 | return mask; | 4091 | str_label.size() > 0 && isdigit(str_label[0])) |
4092 | return -1; | 4092 | mask = strtol(str_label.c_str(), NULL, 0); |
4093 | return mask; | ||
4093 | } | 4094 | } |