diff --git a/components/waydroidintegrationplugin/waydroiddbusobject.cpp b/components/waydroidintegrationplugin/waydroiddbusobject.cpp index 5c41216e..bd26e233 100644 --- a/components/waydroidintegrationplugin/waydroiddbusobject.cpp +++ b/components/waydroidintegrationplugin/waydroiddbusobject.cpp @@ -453,6 +453,10 @@ void WaydroidDBusObject::refreshAndroidId() KAuth::ExecuteJob *executeJob = dynamic_cast(job); if (executeJob->error() == 0) { m_androidId = executeJob->data()["android_id"].toString(); + + if (m_androidId.isEmpty()) { + Q_EMIT actionFailed(i18n("Android ID not found")); + } } else { m_androidId = ""; qCWarning(WAYDROIDINTEGRATIONPLUGIN) << "KAuth returned an error code:" << executeJob->error(); diff --git a/kcms/waydroidintegration/ui/WaydroidGooglePlayProtectConfigurationPage.qml b/kcms/waydroidintegration/ui/WaydroidGooglePlayProtectConfigurationPage.qml index 8372ae8a..5aba9461 100644 --- a/kcms/waydroidintegration/ui/WaydroidGooglePlayProtectConfigurationPage.qml +++ b/kcms/waydroidintegration/ui/WaydroidGooglePlayProtectConfigurationPage.qml @@ -33,6 +33,25 @@ KCM.SimpleKCM { text: i18n("We fetching your Android ID.\nIt can take a few seconds.") } + Connections { + target: AIP.WaydroidDBusClient + + function onActionFailed(error: string): void { + inlineMessage.text = error + inlineMessage.visible = true + inlineMessage.type = Kirigami.MessageType.Error + } + } + + Kirigami.InlineMessage { + id: inlineMessage + + Layout.fillWidth: true + + visible: false + showCloseButton: true + } + ColumnLayout { visible: AIP.WaydroidDBusClient.androidId !== "" anchors.verticalCenter: parent.verticalCenter