From 9c208e88d6707fff008164fa9c335a93bd809a3f Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Tue, 24 Nov 2020 16:01:55 -0800 Subject: mobile/Android: register the Kirigami plugin According to the Kirigami documentation, this is only required on Android. Signed-off-by: Dirk Hohndel --- subsurface-helper.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'subsurface-helper.cpp') diff --git a/subsurface-helper.cpp b/subsurface-helper.cpp index befe89559..d2eb6e01e 100644 --- a/subsurface-helper.cpp +++ b/subsurface-helper.cpp @@ -66,6 +66,9 @@ void run_ui() { #ifdef SUBSURFACE_MOBILE #if defined(Q_OS_ANDROID) + // according to the documentation this is required on Android, but nowhere else + KirigamiPlugin::getInstance().registerTypes(); + // work around an odd interaction between the OnePlus flavor of Android and Qt font handling if (getAndroidHWInfo().contains("/OnePlus/")) { QFontDatabase db; int id = QFontDatabase::addApplicationFont(":/fonts/Roboto-Regular.ttf"); @@ -91,7 +94,6 @@ void run_ui() // Register qml interface classes QMLInterface::setup(ctxt); register_qml_types(&engine); - KirigamiPlugin::getInstance().registerTypes(); #if defined(__APPLE__) && !defined(Q_OS_IOS) // when running the QML UI on a Mac the deployment of the QML Components seems // to fail and the search path for the components is rather odd - simply the -- cgit v1.2.3-70-g09d2