Skip to content

Avoid javascript errors when caret extension used without a preview window#376

Merged
Mottie merged 1 commit intoMottie:masterfrom
insightfuls:master
Aug 5, 2015
Merged

Avoid javascript errors when caret extension used without a preview window#376
Mottie merged 1 commit intoMottie:masterfrom
insightfuls:master

Conversation

@insightfuls
Copy link
Contributor

Without a preview window, I was noticing a lot of "base.caret_$div is null" errors on the console. The problem was that events weren't being unbound when the caret was disabled, and since $preview is $el when there is no separate preview window, the events still fired as $el remains visible, and tried to access the nulled out property. This change simply unbinds the same events when removing the caret as are bound when adding it.

@Mottie
Copy link
Owner

Mottie commented Aug 5, 2015

Hi @isfs!

Thanks for your work on this! I'll take a closer look at this some time tomorrow.

Mottie added a commit that referenced this pull request Aug 5, 2015
Avoid javascript errors when caret extension used without a preview window
@Mottie Mottie merged commit ea741cd into Mottie:master Aug 5, 2015
Mottie added a commit that referenced this pull request Aug 5, 2015
@insightfuls
Copy link
Contributor Author

Thanks, Rob. Thanks also for adding the code that removes the caret. I have a
workaround in place for that currently which I hadn't integrated into the keyboard
as a patch; I will remove my workaround and check your fix suffices.

On 5/08/15 10:59 PM, Rob G wrote:

Merged #376 #376.


Reply to this email directly or view it on GitHub
#376 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants