Mottie / Keyboard

Virtual Keyboard using jQuery ~
http://mottie.github.io/Keyboard/
Other
1.78k stars 723 forks source link

How to check if altKeyPopup added #714

Closed Chokomoko closed 5 years ago

Chokomoko commented 5 years ago

Dear @Mottie. Is there any way to check if altpopup is already added for given input with keyboard? Because when I try to call addAltKeyPopup twice for the same element it throws me error, so id like to avoid it

Mottie commented 5 years ago

Hi @Chokomoko!

You can check to see if the altkeypopup_namespace is defined:

var altKeyPopupActive = $("#keyboard").getkeyboard().altkeypopup_namespace
  ? true
  : false;
Chokomoko commented 5 years ago

Thanks a lot!