Page weather04
    Attributes
        ID                 : 0
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Locked             : no
        Swide up page ID   : disabled
        Swide down page ID : disabled
        Swide left page ID : disabled
        Swide right page ID: disabled
    
    Events
        Preinitialize Event
            if(api==0)
            {
                page home
            }else
            {
                printh 92
                prints "nspanelevent",0
                printh 00
                prints "{\"page\": \"weather04\", \"component\": \"currentpage\", \"value\": \"pagechange\"}",0
                printh 00
                printh FF FF FF
            }
        
        Touch Press Event
            printh 91
            prints "touchevent",0
            printh 00
            prints rand,0
            printh FF FF FF
        
        Touch Release Event
            printh 91
            prints "touchevent",0
            printh 00
            prints rand,0
            printh FF FF FF
        
Text day
    Attributes
        ID                 : 4
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 20
    
Text loading
    Attributes
        ID                 : 5
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 1
    
Text date
    Attributes
        ID                 : 6
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 25
    
Text temperature
    Attributes
        ID                 : 7
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value01
    Attributes
        ID                 : 8
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value05
    Attributes
        ID                 : 9
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value04
    Attributes
        ID                 : 10
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value02
    Attributes
        ID                 : 11
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value03
    Attributes
        ID                 : 12
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 15
    
Text value01_icon
    Attributes
        ID                 : 13
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 10
    
Text value02_icon
    Attributes
        ID                 : 14
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 10
    
Text value03_icon
    Attributes
        ID                 : 15
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 10
    
Text value04_icon
    Attributes
        ID                 : 16
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 10
    
Text value05_icon
    Attributes
        ID                 : 17
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 10
    
Text page_index
    Attributes
        ID                 : 18
        Scope              : local
        Dragging           : 0
        Send Component ID  : disabled
        Associated Keyboard: none
        Text               : 
        Max. Text Size     : 20
    
Picture weather_icon
    Attributes
        ID               : 3
        Scope            : local
        Dragging         : 0
        Send Component ID: disabled
    
Button button_back
    Attributes
        ID               : 19
        Scope            : local
        Dragging         : 0
        Send Component ID: disabled
        State            : unpressed
        Text             : 
        Max. Text Size   : 3
    
    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
        
Timer wakeup_timer
    Attributes
        ID         : 20
        Scope      : local
        Period (ms): 100
        Enabled    : yes
    
    Events
        Timer Event
            if(dim<brightness)
            {
                dimdelta=brightness-dim
                dimdelta/=10
                if(dimdelta<1)
                {
                    dimdelta=1
                }
                dim+=dimdelta
            }else
            {
                wakeup_timer.en=0
            }
        
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 weather03
                }
                // Right to Left
                swipec2=0-swipedx
                if(swipec<swipec2)
                {
                    page weather05
                }
            }
            // 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
                }
            }
        
