From fef8f4d29cc65ef96050ddb668dbb1bf601d7ee7 Mon Sep 17 00:00:00 2001 From: daboe01 Date: Tue, 23 Jun 2015 20:36:57 +0200 Subject: [PATCH] safari backspace fix --- AppKit/CPTextView/CPTextView.j | 3 +++ 1 file changed, 3 insertions(+) diff --git a/AppKit/CPTextView/CPTextView.j b/AppKit/CPTextView/CPTextView.j index cc487244b..7d57ea99b 100644 --- a/AppKit/CPTextView/CPTextView.j +++ b/AppKit/CPTextView/CPTextView.j @@ -2150,6 +2150,9 @@ var _CPCopyPlaceholder = '-'; if (e.which != 8 && e.which != 13 && e.which < 27 || e.which == 91 || e.which == 93) // include apple command keys return; + if (e.which == 8) // safari backspace fix + _CPNativeInputFieldKeyPressedCalled = YES; + if(_CPNativeInputFieldActive && _CPNativeInputField.innerHTML.slice(-1) == ">") // exit when safari starts inserting tags { _CPNativeInputField.innerHTML=''