Commit c3596ce8 authored by Guido Gunther's avatar Guido Gunther
Browse files

Wait for DBus to show up before showing keyboard

This makes sure we don't try to set the shown DBus property before the
DBus interface is ready.

Closes: phosh#87
parent 5bdeda72
......@@ -1167,6 +1167,18 @@ make_visible(struct virtual_keyboard *keyboard) {
notify_visible(true);
}
static gboolean
make_visible_in_idle(struct virtual_keyboard *keyboard)
{
if (!dbus_interface)
return TRUE;
make_visible(keyboard);
return FALSE;
}
static void
make_hidden(struct virtual_keyboard *keyboard) {
if (!keyboard->layer_surface) {
......@@ -1571,7 +1583,7 @@ main(int argc, char *argv[])
session_register();
if (virtual_keyboard.input_method_manager == NULL) {
make_visible(&virtual_keyboard);
g_idle_add ((GSourceFunc) make_visible_in_idle, &virtual_keyboard);
}
display_run(virtual_keyboard.display);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment