settings: Fall back to "us" layout when no file found
This commit is contained in:
@ -198,9 +198,15 @@ eekboard_context_service_real_create_keyboard (EekboardContextService *self,
|
||||
g_warning ("can't create keyboard %s: %s",
|
||||
keyboard_type, error->message);
|
||||
g_error_free (error);
|
||||
error = NULL;
|
||||
layout = eek_xml_layout_new ("us", &error);
|
||||
if (layout == NULL) {
|
||||
g_error ("failed to create fallback layout: %s", error->message);
|
||||
g_error_free (error);
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
keyboard = eek_keyboard_new (layout, CSW, CSH);
|
||||
g_object_unref (layout);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user