Open kimmoli opened 10 years ago
Why would fingerterm need to distinguish between tohkbd and any other kind of physical keyboard such as, say, bluetooth?
There is no need to separate tohkbd and other keyboards, if there is other way to detect attachment/removeal of such and turning virtual keyboard off/on accordingly.
Sounds like support for physical keyboards is generally broken in Sailfish. Last time I checked (about a year ago) it definitely was. Perhaps it's time to take a look at it.
yes, there were some fixes on it during spring. uinput in general works, but seems it is not supporting compose etc. Tried also xkbcommon (seems it is rather old version too)
So, input devices tracking should be fixed if it is broken instead of inventing new ways to notify and modify everything to support it. There is "maemo.InternalKeyboard.Open" context property provided by generic keyboard statefs provider. It should work in generic case if input device providing [KEY_Q, KEY_P] is present (cor::udev library has routine to check it).
agree
For retractable keyboards we probably would want to have some event when keyboard is opened/closed. That could then be used (in mce) as input for display blank/unblank policy and forwarded to ui for hide/show virtual keyboard. If tohkbd is already using evdev, SW_KEYPAD_SLIDE is already kind of used for this at mce side.
@spiiroin In the maemo.InternalKeyboard there are Open
and Present
properties
Agree that the way to do it would be to listen to a contextkit/statefs property, here's the keyboard provider source:
Added an issue there: https://github.com/nemomobile/statefs-providers/issues/28
iirc @spiiroin is going to provide some signal to reflect "Opened" state to be used e.g. by statefs, isn't it?
@deztructor: yes, https://github.com/nemomobile/mce/pull/230 (in review) adds the following signals
/usr/lib/qt5/bin/qdbus --system com.nokia.mce /com/nokia/mce/signal|grep keyb signal void com.nokia.mce.signal.keyboard_available_state_ind(QString keyboard_state) signal void com.nokia.mce.signal.keyboard_slide_state_ind(QString slide_state)
The vkb related statefs could be derived from the "available" data.
nemomobile/statefs-providers#41 is required for correct operation, at least using 0.2.74 with this nemomobile-packages/maliit-framework#8 seems to work(ish)
preparations for tohkbd2.
tohkbd daemon will emit a dbus signal on
systembus
when it is connected or disconnect. For optimum user experience with fingerterm, the "ui/vkbShowMethod" should be set to "off" when tohkbd is connected, and to previous value when disconnected.path=/; interface=com.kimmoli.tohkbd2; member=keyboardConnectedChanged
boolean false
when disconnected andboolean true
when connected