Open sillysloft opened 19 years ago
Original comment by: lordbrain
Original comment by: akir
Logged In: YES user_id=1101187
mhh .. i personally expect from removewhitespace() that it removes whitespaces, no matter if the string becomes empty after it or not.
the "bug" itself is easily fixable by throwing out the aguments.empty() check.
Original comment by: akir
BUG: When there is trailing whitespace in your keys file after either a "PrevWorkspace" or "NextWorkspace" command, the key binding is disabled.
FIX: The attached patch will apply to the head in svn as well as 0.9.12, and probably earlier versions which have this bug. Apply it at toplevel, like so:
patch -p0 < StringUtil.removeFirstWhitespace.050222.patch
EXPLANATION: The patch modifies StringUtil::removeFirstWhitespace(sdt::string &str) so that if given purely whitespace it will return an empty string rather than leaving the string unmodified.
I think this behavior is more in line with what programmers expect, and besides it fixes the bug which results from the fact that in lines 302 & 304 of FbCommandFactory.cc we explicitely disable {Prev,Next}Workspace command if the arguments string is not empty.
Reported by: lordbrain