Commit 05a19783 authored by Nicolas Fella's avatar Nicolas Fella
Browse files

[app] Allow refreshing the device list

The Android app and the KCM allow forcing a refresh, which is useful sometimes. kdeconnect-app should have that too given we want to replace the KCM.
parent 56575471
Pipeline #29990 passed with stage
in 15 minutes and 34 seconds
...@@ -26,6 +26,8 @@ import org.kde.kdeconnect 1.0 ...@@ -26,6 +26,8 @@ import org.kde.kdeconnect 1.0
Kirigami.ScrollablePage Kirigami.ScrollablePage
{ {
id: root
Component { Component {
id: deviceComp id: deviceComp
DevicePage {} DevicePage {}
...@@ -33,6 +35,18 @@ Kirigami.ScrollablePage ...@@ -33,6 +35,18 @@ Kirigami.ScrollablePage
objectName: "FindDevices" objectName: "FindDevices"
title: i18nd("kdeconnect-app", "Pair") title: i18nd("kdeconnect-app", "Pair")
supportsRefreshing: true
onRefreshingChanged: {
DaemonDbusInterface.forceOnNetworkChange()
refreshResetTimer.start()
}
Timer {
id: refreshResetTimer
interval: 1000
onTriggered: root.refreshing = false
}
Kirigami.PlaceholderMessage { Kirigami.PlaceholderMessage {
text: i18nd("kdeconnect-app", "No devices found") text: i18nd("kdeconnect-app", "No devices found")
......
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