Changeset - r20122:31286a037f6a
[Not reviewed]
master
0 1 0
frosch - 11 years ago 2013-03-17 13:04:48
frosch@openttd.org
(svn r25090) -Fix: Make editbox character filters also apply to pasted content from clipboard.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/textbuf.cpp
Show inline comments
 
@@ -190,7 +190,7 @@ bool Textbuf::InsertClipboard()
 
	uint16 pixels = 0, bytes = 0, chars = 0;
 
	WChar c;
 
	for (const char *ptr = utf8_buf; (c = Utf8Consume(&ptr)) != '\0';) {
 
		if (!IsPrintable(c)) break;
 
		if (!IsValidChar(c, this->afilter)) break;
 

	
 
		byte len = Utf8CharLen(c);
 
		if (this->bytes + bytes + len > this->max_bytes) break;
0 comments (0 inline, 0 general)