Allow restart via plasmoid

This commit is contained in:
Martchus 2018-02-19 01:38:41 +01:00
parent e6ac3d8599
commit 6be44cc93f
5 changed files with 98 additions and 70 deletions

View File

@ -65,148 +65,148 @@
<translation>Fehler beim Anfordern Gerät zu Pausieren/Fortzusetzen</translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="852"/>
<location filename="../syncthingconnection.cpp" line="854"/>
<source>Unable to request QR-Code: </source>
<translation>Fehler beim Abfragen des QR-Codes: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="872"/>
<location filename="../syncthingconnection.cpp" line="874"/>
<source>Unable to parse Syncthing log: </source>
<translation>Fehler beim Auslesen des Syncthing-Logs: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="887"/>
<location filename="../syncthingconnection.cpp" line="889"/>
<source>Unable to request Syncthing log: </source>
<translation>Fehler beim Abfragen des Syncthing-Logs: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="921"/>
<location filename="../syncthingconnection.cpp" line="923"/>
<source>Unable to locate certificate used by Syncthing.</source>
<translation>Das SSL-Zertifikat von Syncthing kann nicht gefunden werden.</translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="927"/>
<location filename="../syncthingconnection.cpp" line="929"/>
<source>Unable to load certificate used by Syncthing.</source>
<translation>Das SSL-Zertifikat von Syncthing kann nicht ausgelesen werden.</translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1002"/>
<location filename="../syncthingconnection.cpp" line="1004"/>
<source>Unable to parse Syncthing config: </source>
<translation>Fehler beim Auslesen der Syncthing-Konfiguration: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1016"/>
<location filename="../syncthingconnection.cpp" line="1018"/>
<source>Unable to request Syncthing config: </source>
<translation>Fehler beim Abfragen der Syncthing-Konfiguration: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1117"/>
<location filename="../syncthingconnection.cpp" line="1119"/>
<source>Unable to parse Syncthing status: </source>
<translation>Fehler beim Auslesen des Syncthing-Status: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1131"/>
<location filename="../syncthingconnection.cpp" line="1133"/>
<source>Unable to request Syncthing status: </source>
<translation>Fehler beim Abfragen des Syncthing-Status: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1172"/>
<location filename="../syncthingconnection.cpp" line="1177"/>
<source>Unable to parse connections: </source>
<translation>Fehler beim Auslesen der Verbindungen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1243"/>
<location filename="../syncthingconnection.cpp" line="1248"/>
<source>Unable to request connections: </source>
<translation>Fehler beim Abfragen der Verbindungen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1261"/>
<location filename="../syncthingconnection.cpp" line="1266"/>
<source>Unable to parse directory statistics: </source>
<translation>Fehler beim Auslesen der Verzeichnisstatistiken: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1307"/>
<location filename="../syncthingconnection.cpp" line="1939"/>
<location filename="../syncthingconnection.cpp" line="1312"/>
<location filename="../syncthingconnection.cpp" line="1944"/>
<source>Unable to request directory statistics: </source>
<translation>Fehler beim Abfragen der Verzeichnisstatistiken: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1325"/>
<location filename="../syncthingconnection.cpp" line="1330"/>
<source>Unable to parse device statistics: </source>
<translation>Fehler beim Auslesen der Gerätestatistiken: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1352"/>
<location filename="../syncthingconnection.cpp" line="1357"/>
<source>Unable to request device statistics: </source>
<translation>Fehler beim Abfragen der Gerätestatistiken: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1378"/>
<location filename="../syncthingconnection.cpp" line="1383"/>
<source>Unable to parse errors: </source>
<translation>Fehler beim Auslesen der Syncthing-Fehlermeldungen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1405"/>
<location filename="../syncthingconnection.cpp" line="1410"/>
<source>Unable to request errors: </source>
<translation>Fehler beim Abfragen der Syncthing-Fehlermeldungen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1421"/>
<location filename="../syncthingconnection.cpp" line="1426"/>
<source>Unable to request clearing errors: </source>
<translation>Fehler beim Löschen der Fehlermeldungen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1442"/>
<location filename="../syncthingconnection.cpp" line="1447"/>
<source>Unable to parse Syncthing events: </source>
<translation>Fehler beim Auslesen der Syncthing-Ereignisse: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1497"/>
<location filename="../syncthingconnection.cpp" line="1502"/>
<source>Unable to request Syncthing events: </source>
<translation>Fehler beim Abfragen der Syncthing-Ereignisse: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1825"/>
<location filename="../syncthingconnection.cpp" line="1830"/>
<source>Unable to request rescan: </source>
<translation>Fehler beim Anfordern eines Verzeichnis-Rescans: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1849"/>
<location filename="../syncthingconnection.cpp" line="1854"/>
<source>Unable to request device pause/resume: </source>
<translation>Fehler beim Anfordern Gerät zu Pausieren/Fortzusetzen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1870"/>
<location filename="../syncthingconnection.cpp" line="1875"/>
<source>Unable to request directory pause/resume: </source>
<translation>Fehler beim Anfordern Verzeichnis zu Pausieren/Fortzusetzen: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1886"/>
<location filename="../syncthingconnection.cpp" line="1891"/>
<source>Unable to request restart: </source>
<translation>Fehler beim Anfordern eines Neustarts: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1902"/>
<location filename="../syncthingconnection.cpp" line="1907"/>
<source>Unable to request shutdown: </source>
<translation>Fehler beim Anfordern Syncthing zu beenden: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1929"/>
<location filename="../syncthingconnection.cpp" line="1934"/>
<source>Unable to parse status for directory %1: </source>
<translation>Fehler beim Auslesen des Status von Verzeichnis %1: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2015"/>
<location filename="../syncthingconnection.cpp" line="2020"/>
<source>Unable to parse completion for device/directory %1/%2: </source>
<translation>Fehler beim Auslesen des Fortschrittes von Verzeichnis %1/%2: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2032"/>
<location filename="../syncthingconnection.cpp" line="2037"/>
<source>Unable to request completion for device/directory %1/%2: </source>
<translation>Fehler beim Anfordern des Fortschrittes von Verzeichnis %1/%2: </translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2116"/>
<location filename="../syncthingconnection.cpp" line="2121"/>
<source>at offset %1</source>
<translation>bei Zeichen %1</translation>
</message>

View File

@ -65,148 +65,148 @@
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="852"/>
<location filename="../syncthingconnection.cpp" line="854"/>
<source>Unable to request QR-Code: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="872"/>
<location filename="../syncthingconnection.cpp" line="874"/>
<source>Unable to parse Syncthing log: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="887"/>
<location filename="../syncthingconnection.cpp" line="889"/>
<source>Unable to request Syncthing log: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="921"/>
<location filename="../syncthingconnection.cpp" line="923"/>
<source>Unable to locate certificate used by Syncthing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="927"/>
<location filename="../syncthingconnection.cpp" line="929"/>
<source>Unable to load certificate used by Syncthing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1002"/>
<location filename="../syncthingconnection.cpp" line="1004"/>
<source>Unable to parse Syncthing config: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1016"/>
<location filename="../syncthingconnection.cpp" line="1018"/>
<source>Unable to request Syncthing config: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1117"/>
<location filename="../syncthingconnection.cpp" line="1119"/>
<source>Unable to parse Syncthing status: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1131"/>
<location filename="../syncthingconnection.cpp" line="1133"/>
<source>Unable to request Syncthing status: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1172"/>
<location filename="../syncthingconnection.cpp" line="1177"/>
<source>Unable to parse connections: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1243"/>
<location filename="../syncthingconnection.cpp" line="1248"/>
<source>Unable to request connections: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1261"/>
<location filename="../syncthingconnection.cpp" line="1266"/>
<source>Unable to parse directory statistics: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1307"/>
<location filename="../syncthingconnection.cpp" line="1939"/>
<location filename="../syncthingconnection.cpp" line="1312"/>
<location filename="../syncthingconnection.cpp" line="1944"/>
<source>Unable to request directory statistics: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1325"/>
<location filename="../syncthingconnection.cpp" line="1330"/>
<source>Unable to parse device statistics: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1352"/>
<location filename="../syncthingconnection.cpp" line="1357"/>
<source>Unable to request device statistics: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1378"/>
<location filename="../syncthingconnection.cpp" line="1383"/>
<source>Unable to parse errors: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1405"/>
<location filename="../syncthingconnection.cpp" line="1410"/>
<source>Unable to request errors: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1421"/>
<location filename="../syncthingconnection.cpp" line="1426"/>
<source>Unable to request clearing errors: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1442"/>
<location filename="../syncthingconnection.cpp" line="1447"/>
<source>Unable to parse Syncthing events: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1497"/>
<location filename="../syncthingconnection.cpp" line="1502"/>
<source>Unable to request Syncthing events: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1825"/>
<location filename="../syncthingconnection.cpp" line="1830"/>
<source>Unable to request rescan: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1849"/>
<location filename="../syncthingconnection.cpp" line="1854"/>
<source>Unable to request device pause/resume: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1870"/>
<location filename="../syncthingconnection.cpp" line="1875"/>
<source>Unable to request directory pause/resume: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1886"/>
<location filename="../syncthingconnection.cpp" line="1891"/>
<source>Unable to request restart: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1902"/>
<location filename="../syncthingconnection.cpp" line="1907"/>
<source>Unable to request shutdown: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="1929"/>
<location filename="../syncthingconnection.cpp" line="1934"/>
<source>Unable to parse status for directory %1: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2015"/>
<location filename="../syncthingconnection.cpp" line="2020"/>
<source>Unable to parse completion for device/directory %1/%2: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2032"/>
<location filename="../syncthingconnection.cpp" line="2037"/>
<source>Unable to request completion for device/directory %1/%2: </source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../syncthingconnection.cpp" line="2116"/>
<location filename="../syncthingconnection.cpp" line="2121"/>
<source>at offset %1</source>
<translation type="unfinished"></translation>
</message>

View File

@ -36,6 +36,10 @@ Item {
plasmoid.nativeInterface.connection.rescanAllDirs()
}
function action_restartSyncthing() {
plasmoid.nativeInterface.connection.restart()
}
function action_showLog() {
plasmoid.nativeInterface.showLog()
}
@ -55,6 +59,10 @@ Item {
plasmoid.setAction("showLog", qsTr("Log"), "text-x-generic")
plasmoid.setAction("showErrors", qsTr("Internal errors"),
"emblem-important")
plasmoid.setAction("rescanAllDirs", qsTr("Rescan all directories"),
"folder-sync")
plasmoid.setAction("restartSyncthing", qsTr("Restart Syncthing"),
"system-reboot")
plasmoid.setAction("showAboutDialog", qsTr("About"), "help-about")
}
}

View File

@ -225,27 +225,37 @@
<context>
<name>main</name>
<message>
<location filename="../package/contents/ui/main.qml" line="53"/>
<location filename="../package/contents/ui/main.qml" line="57"/>
<source>Web UI</source>
<translation>Weboberfläche</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="54"/>
<location filename="../package/contents/ui/main.qml" line="58"/>
<source>Settings</source>
<translation>Einstellungen</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="55"/>
<location filename="../package/contents/ui/main.qml" line="59"/>
<source>Log</source>
<translation>Log</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="56"/>
<location filename="../package/contents/ui/main.qml" line="60"/>
<source>Internal errors</source>
<translation>Interne Fehler</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="58"/>
<location filename="../package/contents/ui/main.qml" line="62"/>
<source>Rescan all directories</source>
<translation>Alle Verzeichnisse neu scannen</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="64"/>
<source>Restart Syncthing</source>
<translation>Syncthing neustarten</translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="66"/>
<source>About</source>
<translation>Über Syncthing Plasmoid</translation>
</message>

View File

@ -225,27 +225,37 @@
<context>
<name>main</name>
<message>
<location filename="../package/contents/ui/main.qml" line="53"/>
<location filename="../package/contents/ui/main.qml" line="57"/>
<source>Web UI</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="54"/>
<location filename="../package/contents/ui/main.qml" line="58"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="55"/>
<location filename="../package/contents/ui/main.qml" line="59"/>
<source>Log</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="56"/>
<location filename="../package/contents/ui/main.qml" line="60"/>
<source>Internal errors</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="58"/>
<location filename="../package/contents/ui/main.qml" line="62"/>
<source>Rescan all directories</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="64"/>
<source>Restart Syncthing</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../package/contents/ui/main.qml" line="66"/>
<source>About</source>
<translation type="unfinished"></translation>
</message>