[gnome-shell/wip/carlosg/osk-updates: 48/49] keyboard: Shuffle text direction initialization
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/carlosg/osk-updates: 48/49] keyboard: Shuffle text direction initialization
- Date: Tue, 5 Jul 2022 10:56:30 +0000 (UTC)
commit 437062d169e40a3822fe931317a502e7f5818536
Author: Carlos Garnacho <carlosg gnome org>
Date: Thu Jun 30 11:41:12 2022 +0200
keyboard: Shuffle text direction initialization
We do set the full OSK as LTR since keymaps are defined in that
direction. Other actors inside the OSK might want differently so
move this piece of setup to init(), so child actors can set their
own without the OSK overwriting the value.
js/ui/keyboard.js | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
---
diff --git a/js/ui/keyboard.js b/js/ui/keyboard.js
index 536ee51bd4..afe8f4151b 100644
--- a/js/ui/keyboard.js
+++ b/js/ui/keyboard.js
@@ -1294,7 +1294,15 @@ var Keyboard = GObject.registerClass({
},
}, class Keyboard extends St.BoxLayout {
_init() {
- super._init({ name: 'keyboard', reactive: true, vertical: true });
+ super._init({
+ name: 'keyboard',
+ reactive: true,
+ // Keyboard models are defined in LTR, we must override
+ // the locale setting in order to avoid flipping the
+ // keyboard on RTL locales.
+ text_direction: Clutter.TextDirection.LTR,
+ vertical: true,
+ });
this._focusInExtendedKeys = false;
this._emojiActive = false;
@@ -1419,11 +1427,6 @@ var Keyboard = GObject.registerClass({
this._ensureKeysForGroup(this._keyboardController.getCurrentGroup());
this._setActiveLayer(0);
- // Keyboard models are defined in LTR, we must override
- // the locale setting in order to avoid flipping the
- // keyboard on RTL locales.
- this.text_direction = Clutter.TextDirection.LTR;
-
Main.inputMethod.connect(
'terminal-mode-changed', this._onTerminalModeChanged.bind(this));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]