mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-06 17:12:50 +00:00
Fixed: clicking tokens in a token field could disable its keyboard handling due to the input field losing focus.
This commit is contained in:
1 parent
90d12ef77e
commit
9e235f7236
1 file changed
+4
-1
@@ -992,8 +992,11 @@ var CPThemeStateAutoCompleting = @"CPThemeStateAutoCompleting",
|
||||
|
||||
// Hide the editor if there are selected tokens, but still keep it active
|
||||
// so we can continue using our standard keyboard handling events.
|
||||
if (_selectedRange.length)
|
||||
if (isEditing && _selectedRange.length)
|
||||
{
|
||||
[self _inputElement].style.left = "-10000px";
|
||||
[self _inputElement].focus();
|
||||
}
|
||||
|
||||
// Trim off any excess height downwards.
|
||||
if (CGRectGetHeight([contentView bounds]) > offset.y + tokenHeight)
|
||||
|
||||
Reference in new issue
Block a user