inputMethod: Avoid calling set_preedit_text() if unnecessary
This is easier down on clients.
This commit is contained in:
parent
118cab1766
commit
8c3811a866
@ -144,8 +144,11 @@ var InputMethod = new Lang.Class({
|
|||||||
this._updateCapabilities();
|
this._updateCapabilities();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this._preeditStr) {
|
||||||
// Unset any preedit text
|
// Unset any preedit text
|
||||||
this.set_preedit_text(null, 0);
|
this.set_preedit_text(null, 0);
|
||||||
|
this._preeditStr = null;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_reset() {
|
vfunc_reset() {
|
||||||
@ -154,8 +157,11 @@ var InputMethod = new Lang.Class({
|
|||||||
this._emitRequestSurrounding();
|
this._emitRequestSurrounding();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this._preeditStr) {
|
||||||
// Unset any preedit text
|
// Unset any preedit text
|
||||||
this.set_preedit_text(null, 0);
|
this.set_preedit_text(null, 0);
|
||||||
|
this._preeditStr = null;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_set_cursor_location(rect) {
|
vfunc_set_cursor_location(rect) {
|
||||||
|
Loading…
Reference in New Issue
Block a user