update(SystemControl): use app base dialog instead of global dialog
All checks were successful
gitea-sync/antosdk-apps/pipeline/head This commit looks good

This commit is contained in:
Dany LE
2023-06-07 09:54:35 +02:00
parent 8153ca6f9d
commit d70391c7ba
55 changed files with 27 additions and 26 deletions

View File

@ -7,3 +7,6 @@ via the Antunnel service
![https://raw.githubusercontent.com/lxsang/antosdk-apps/master/SystemControl/screenshot.png](https://raw.githubusercontent.com/lxsang/antosdk-apps/master/SystemControl/screenshot.png)
## changelogs
- 0.1.12-a: use application based dialog instead of global dialog

View File

@ -7,3 +7,6 @@ via the Antunnel service
![https://raw.githubusercontent.com/lxsang/antosdk-apps/master/SystemControl/screenshot.png](https://raw.githubusercontent.com/lxsang/antosdk-apps/master/SystemControl/screenshot.png)
## changelogs
- 0.1.12-a: use application based dialog instead of global dialog

File diff suppressed because one or more lines are too long

View File

@ -13,7 +13,7 @@
"dependencies": [
"Antunnel@0.2.1-b"
],
"version":"0.1.11-a",
"version":"0.1.12-a",
"category":"System",
"iconclass":"fa fa-tachometer",
"mimes":["none"],

View File

@ -3,7 +3,7 @@ class SysmondService extends OS.application.BaseService
super "SysmondService", args
@text = __("{0}%", 0.toString())
@iconclass = "fa fa-android"
@app = undefined
@app = args[0].app
#@nodes = [
# {text: __("Status"), id: 1},
# {text: __("Shutdown"), id: 3},
@ -50,7 +50,7 @@ class SysmondService extends OS.application.BaseService
if not @setting().topic
console.log "Open dialog"
@_gui.openDialog("PromptDialog", {
@app.openDialog("PromptDialog", {
title: __("Enter topic name"),
label: __("Please enter topic name")
})

View File

@ -47,7 +47,11 @@ class SystemControl extends this.OS.application.BaseApplication
@battery.option("height", $(el).height())
$(el).children().show()
@_gui.pushService("SystemControl/SysmondService", [])
@_gui.pushService("SystemControl/SysmondService", [{
path: @meta().path,
type: "app",
app: @
}])
.then (p) =>
@service = p
p.app = @

View File

@ -13,7 +13,7 @@
"dependencies": [
"Antunnel@0.2.1-b"
],
"version":"0.1.11-a",
"version":"0.1.12-a",
"category":"System",
"iconclass":"fa fa-tachometer",
"mimes":["none"],