Verified Commit 787c2289 authored by Jonah Brüchert's avatar Jonah Brüchert 🌳

ErrorHandler: Add retry button

parent 7255fd14
......@@ -70,6 +70,7 @@ Kirigami.ApplicationWindow {
anchors.fill: parent
visible: webView.errorCode !== ""
onRefreshRequested: webView.reload()
}
Loader {
......
......@@ -29,6 +29,8 @@ import org.kde.kirigami 2.0 as Kirigami
Item {
id: errorHandler
signal refreshRequested
property string errorCode: ""
property alias errorString: errorDescription.text
......@@ -58,5 +60,11 @@ Item {
Item {
Layout.fillHeight: true
}
Controls.ToolButton {
Layout.alignment: Qt.AlignHCenter
text: i18n("Retry")
icon.name: "view-refresh"
onClicked: errorHandler.refreshRequested()
}
}
}
......@@ -175,6 +175,8 @@ Kirigami.ApplicationWindow {
bottom: navigation.top
}
visible: currentWebView.errorCode !== ""
onRefreshRequested: currentWebView.reload()
}
Loader {
......
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