mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 22:00:10 +00:00
LineEdit: fix placeholder text affected by secret
(cherry picked from commit e64c473bc9)
This commit is contained in:
parent
1ca67fd484
commit
e06fa5a089
1 changed files with 2 additions and 2 deletions
|
|
@ -639,8 +639,8 @@ void LineEdit::_notification(int p_what) {
|
||||||
if (char_ofs >= t.length())
|
if (char_ofs >= t.length())
|
||||||
break;
|
break;
|
||||||
|
|
||||||
CharType cchar = pass ? '*' : t[char_ofs];
|
CharType cchar = (pass && !text.empty()) ? '*' : t[char_ofs];
|
||||||
CharType next = pass ? '*' : t[char_ofs + 1];
|
CharType next = (pass && !text.empty()) ? '*' : t[char_ofs + 1];
|
||||||
int char_width = font->get_char_size(cchar, next).width;
|
int char_width = font->get_char_size(cchar, next).width;
|
||||||
|
|
||||||
// end of widget, break!
|
// end of widget, break!
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue