Nspanel event (#689)
* upd: hmi2txt export * upd: sync latest dev * upd: currentpage * upd: lightsettings * upd: coversettings * upd: touchevent * Fix error preventing long click on button pages * upd: climate * upd: lastclick w.o. blueprint * Upd: Long_press - Lights * Update: Everything else (#688) Still a bug with confirmation message and long press button. * Fix: Notifications * Fix: Button long press * Fix: Climate page * Fix: Indoor temp when no sensor defined * fix: open climate from homepage triggers mulitple --------- Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
This commit is contained in:
418
nspanel_eu_code/settings.txt
Normal file
418
nspanel_eu_code/settings.txt
Normal file
@@ -0,0 +1,418 @@
|
||||
Page settings
|
||||
Attributes
|
||||
ID : 0
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
Width : 480
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Locked : no
|
||||
Swide up page ID : disabled
|
||||
Swide down page ID : disabled
|
||||
Swide left page ID : disabled
|
||||
Swide right page ID: disabled
|
||||
Fill : picture
|
||||
Back. Picture ID : 99
|
||||
|
||||
Events
|
||||
Preinitialize Event
|
||||
printh 92
|
||||
prints "nspanelevent",0
|
||||
printh 00
|
||||
prints "{\"page\": \"settings\", \"component\": \"currentpage\", \"value\": \"pagechange\"}",0
|
||||
printh 00
|
||||
printh FF FF FF
|
||||
|
||||
Touch Press Event
|
||||
printh 92
|
||||
prints "touchevent",0
|
||||
printh 00
|
||||
prints "{\"page\": \"settings\", \"component\": \"touchevent\", \"value\": \"press\"}",0
|
||||
printh 00
|
||||
printh FF FF FF
|
||||
|
||||
Touch Release Event
|
||||
printh 92
|
||||
prints "touchevent",0
|
||||
printh 00
|
||||
prints "{\"page\": \"settings\", \"component\": \"touchevent\", \"value\": \"release\"}",0
|
||||
printh 00
|
||||
printh FF FF FF
|
||||
|
||||
Text a03
|
||||
Attributes
|
||||
ID : 5
|
||||
Scope : global
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 328
|
||||
y coordinate : 46
|
||||
Width : 40
|
||||
Height : 20
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 3
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : right
|
||||
Vertical Alignment : bottom
|
||||
Input Type : character
|
||||
Text :
|
||||
Max. Text Size : 3
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Text a04
|
||||
Attributes
|
||||
ID : 6
|
||||
Scope : global
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 328
|
||||
y coordinate : 77
|
||||
Width : 40
|
||||
Height : 21
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 3
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : right
|
||||
Vertical Alignment : bottom
|
||||
Input Type : character
|
||||
Text :
|
||||
Max. Text Size : 3
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Text a06
|
||||
Attributes
|
||||
ID : 7
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 15
|
||||
y coordinate : 38
|
||||
Width : 120
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 3
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : left
|
||||
Vertical Alignment : center
|
||||
Input Type : character
|
||||
Text : Reboot
|
||||
Max. Text Size : 6
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Text a07
|
||||
Attributes
|
||||
ID : 8
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 15
|
||||
y coordinate : 84
|
||||
Width : 120
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 3
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : left
|
||||
Vertical Alignment : center
|
||||
Input Type : character
|
||||
Text : Sleep
|
||||
Max. Text Size : 5
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Text a08
|
||||
Attributes
|
||||
ID : 9
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 24
|
||||
y coordinate : 183
|
||||
Width : 85
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 1
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : left
|
||||
Vertical Alignment : center
|
||||
Input Type : character
|
||||
Text : Brightness
|
||||
Max. Text Size : 10
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Text a09
|
||||
Attributes
|
||||
ID : 10
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : disabled
|
||||
Opacity : 127
|
||||
x coordinate : 24
|
||||
y coordinate : 243
|
||||
Width : 85
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Associated Keyboard : none
|
||||
Font ID : 1
|
||||
Cropped Back. Picture ID: 99
|
||||
Horizontal Alignment : left
|
||||
Vertical Alignment : center
|
||||
Input Type : character
|
||||
Text : Dimming
|
||||
Max. Text Size : 7
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Picture settings_exit
|
||||
Attributes
|
||||
ID : 11
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID: disabled
|
||||
Opacity : 127
|
||||
x coordinate : 415
|
||||
y coordinate : 10
|
||||
Width : 25
|
||||
Height : 25
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Picture ID : 56
|
||||
|
||||
Slider brightslider
|
||||
Attributes
|
||||
ID : 3
|
||||
Scope : global
|
||||
Dragging : 0
|
||||
Send Component ID : on press and release
|
||||
Opacity : 127
|
||||
x coordinate : 140
|
||||
y coordinate : 183
|
||||
Width : 255
|
||||
Height : 41
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Direction : horizontal
|
||||
Fill : crop image
|
||||
Cursor width : auto
|
||||
Cursor height : 255
|
||||
Cropped Back. Picture ID : 99
|
||||
Cropped Slided Back. Picture ID: 100
|
||||
Position : 80
|
||||
Upper range limit : 100
|
||||
Lower range limit : 0
|
||||
|
||||
Events
|
||||
Touch Release Event
|
||||
printh 91
|
||||
prints "brightslider",0
|
||||
printh 00
|
||||
prints brightslider.val,0
|
||||
printh FF FF FF
|
||||
|
||||
Slider dimslider
|
||||
Attributes
|
||||
ID : 4
|
||||
Scope : global
|
||||
Dragging : 0
|
||||
Send Component ID : on press and release
|
||||
Opacity : 127
|
||||
x coordinate : 140
|
||||
y coordinate : 243
|
||||
Width : 255
|
||||
Height : 41
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Direction : horizontal
|
||||
Fill : crop image
|
||||
Cursor width : auto
|
||||
Cursor height : 255
|
||||
Cropped Back. Picture ID : 99
|
||||
Cropped Slided Back. Picture ID: 100
|
||||
Position : 20
|
||||
Upper range limit : 100
|
||||
Lower range limit : 0
|
||||
|
||||
Events
|
||||
Touch Release Event
|
||||
printh 91
|
||||
prints "dimslider",0
|
||||
printh 00
|
||||
prints dimslider.val,0
|
||||
printh FF FF FF
|
||||
|
||||
Dual-state Button bt0
|
||||
Attributes
|
||||
ID : 13
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID : on press and release
|
||||
Opacity : 127
|
||||
x coordinate : 136
|
||||
y coordinate : 36
|
||||
Width : 83
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Font ID : 1
|
||||
Cropped Back. Picture ID (Unpressed): 99
|
||||
Back. Picture ID (Pressed) : 65535
|
||||
Cropped Back. Picture ID (Pressed) : 100
|
||||
Horizontal Alignment : center
|
||||
Vertical Alignment : center
|
||||
State : unpressed
|
||||
Text :
|
||||
Max. Text Size : 0
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Dual-state Button bt1
|
||||
Attributes
|
||||
ID : 14
|
||||
Scope : global
|
||||
Dragging : 0
|
||||
Send Component ID : on press and release
|
||||
Opacity : 127
|
||||
x coordinate : 138
|
||||
y coordinate : 88
|
||||
Width : 83
|
||||
Height : 40
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
Fill : crop image
|
||||
Font ID : 1
|
||||
Cropped Back. Picture ID (Unpressed): 99
|
||||
Back. Picture ID (Pressed) : 65535
|
||||
Cropped Back. Picture ID (Pressed) : 100
|
||||
Horizontal Alignment : center
|
||||
Vertical Alignment : center
|
||||
State : unpressed
|
||||
Text :
|
||||
Max. Text Size : 0
|
||||
Word wrap : disabled
|
||||
Horizontal Spacing : 0
|
||||
Vertical Spacing : 0
|
||||
|
||||
Hotspot setings_back
|
||||
Attributes
|
||||
ID : 12
|
||||
Scope : local
|
||||
Dragging : 0
|
||||
Send Component ID: disabled
|
||||
Opacity : 127
|
||||
x coordinate : 387
|
||||
y coordinate : 0
|
||||
Width : 60
|
||||
Height : 60
|
||||
Effect : load
|
||||
Effect Priority : 0
|
||||
Effect Time : 300
|
||||
|
||||
Events
|
||||
Touch Press Event
|
||||
page home
|
||||
|
||||
Timer swipestore
|
||||
Attributes
|
||||
ID : 2
|
||||
Scope : local
|
||||
Period (ms): 50
|
||||
Enabled : no
|
||||
|
||||
Events
|
||||
Timer Event
|
||||
swipex=tch0
|
||||
swipey=tch1
|
||||
|
||||
TouchCap swipe
|
||||
Attributes
|
||||
ID : 1
|
||||
Scope: local
|
||||
Value: 0
|
||||
|
||||
Events
|
||||
Touch Press Event
|
||||
swipestore.en=1 // Start swipestore timer
|
||||
|
||||
Touch Release Event
|
||||
swipestore.en=0
|
||||
// Touch has ended, x
|
||||
if(tch0==0)
|
||||
{
|
||||
swipec=swipex-tch2
|
||||
// From Left to Right
|
||||
if(swipec>swipedx)
|
||||
{
|
||||
//page
|
||||
}
|
||||
// Right to Left
|
||||
swipec2=0-swipedx
|
||||
if(swipec<swipec2)
|
||||
{
|
||||
//page
|
||||
}
|
||||
}
|
||||
// Touch has ended, y
|
||||
if(tch1==0)
|
||||
{
|
||||
swipec=swipey-tch3
|
||||
// From Up to Down
|
||||
if(swipec>100)
|
||||
{
|
||||
//page
|
||||
}
|
||||
// Down to Up
|
||||
swipec2=0-swipedy
|
||||
if(swipec<-100)
|
||||
{
|
||||
//page
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user