We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
imswitcher.js
switchInputMethod(prevMode, newMode) { return __awaiter(this, void 0, void 0, function* () { if (configuration_1.configuration.autoSwitchInputMethod.enable !== true) { return; } // when you exit from insert-like mode, save origin input method and set it to default let isPrevModeInsertLike = this.isInsertLikeMode(prevMode); let isNewModeInsertLike = this.isInsertLikeMode(newMode); if (isPrevModeInsertLike !== isNewModeInsertLike) { if (isNewModeInsertLike) { yield this.resumeIM(); } else { yield this.switchToDefaultIM(); //**dont switch, if not insertMode; or switch but no save** } } }); } // save origin input method and set input method to default switchToDefaultIM() { return __awaiter(this, void 0, void 0, function* () { const obtainIMCmd = configuration_1.configuration.autoSwitchInputMethod.obtainIMCmd; try { const insertIMKey = yield this.execute(obtainIMCmd); if (insertIMKey !== undefined) { this.savedIMKey = insertIMKey.trim(); } } catch (e) { this.logger.error(`Error switching to default IM. err=${e}`); } const defaultIMKey = configuration_1.configuration.autoSwitchInputMethod.defaultIM; if (defaultIMKey !== this.savedIMKey) { yield this.switchToIM(defaultIMKey); } }); }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
imswitcher.js
The text was updated successfully, but these errors were encountered: