inputMethod: Fix setting surrounding text
The underlying ibus method expects an object of type IBusText rather than a plain string. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/228
This commit is contained in:
parent
ed1a8c582d
commit
e55aacaa10
@ -176,8 +176,11 @@ var InputMethod = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
vfunc_set_surrounding(text, cursor, anchor) {
|
vfunc_set_surrounding(text, cursor, anchor) {
|
||||||
if (this._context && text)
|
if (!this._context || !text)
|
||||||
this._context.set_surrounding_text(text, cursor, anchor);
|
return;
|
||||||
|
|
||||||
|
let ibusText = IBus.Text.new_from_string(text);
|
||||||
|
this._context.set_surrounding_text(ibusText, cursor, anchor);
|
||||||
},
|
},
|
||||||
|
|
||||||
vfunc_update_content_hints(hints) {
|
vfunc_update_content_hints(hints) {
|
||||||
|
Loading…
Reference in New Issue
Block a user