Load jquery.ime only when user focus on editable fields

To reduce javascript size for page load.

Change-Id: Ibf2ccd5b5501720837051d6e268b122e8a9f8590
This commit is contained in:
Santhosh Thottingal
2013-07-25 17:33:54 +05:30
committed by Amir E. Aharoni
parent 39f4714043
commit 82fbfe62e7
3 changed files with 45 additions and 28 deletions

View File

@@ -94,7 +94,8 @@
this.$parent.$settingsPanel.append( this.$template );
$enabledOnly = this.$template.find( '.enabled-only' );
// ime system is lazy loaded, make sure it is initialized
mw.ime.init();
if ( $.ime.preferences.isEnabled() ) {
$enabledOnly.removeClass( 'hide' );
} else {