equal
deleted
inserted
replaced
1 // widget_jump.ysl2 |
1 // widget_jump.ysl2 |
2 |
2 |
3 template "widget[@type='Jump']", mode="widget_class"{ |
3 widget_class("Jump") { |
4 || |
4 || |
5 class JumpWidget extends Widget{ |
|
6 |
|
7 activable = false; |
5 activable = false; |
8 active = false; |
6 active = false; |
9 disabled = false; |
7 disabled = false; |
10 frequency = 2; |
8 frequency = 2; |
11 |
9 |
56 /* hide disabled */ |
54 /* hide disabled */ |
57 this.disabled_elt.setAttribute("style", "display:none"); |
55 this.disabled_elt.setAttribute("style", "display:none"); |
58 this.update_activity(); |
56 this.update_activity(); |
59 } |
57 } |
60 } |
58 } |
61 } |
|
62 || |
59 || |
63 } |
60 } |
64 |
61 |
65 template "widget[@type='Jump']", mode="widget_defs" { |
62 widget_defs("Jump") { |
66 param "hmi_element"; |
63 param "hmi_element"; |
67 const "activity" optional_labels("active inactive"); |
64 const "activity" optional_labels("active inactive"); |
68 const "have_activity","string-length($activity)>0"; |
65 const "have_activity","string-length($activity)>0"; |
69 value "$activity"; |
66 value "$activity"; |
70 |
67 |
88 } |
85 } |
89 } |
86 } |
90 | }, |
87 | }, |
91 } |
88 } |
92 |
89 |
93 template "widget[@type='Jump']", mode="per_page_widget_template"{ |
90 widget_page("Jump"){ |
94 param "page_desc"; |
91 param "page_desc"; |
95 /* check that given path is compatible with page's reference path */ |
92 /* check that given path is compatible with page's reference path */ |
96 if "path" { |
93 if "path" { |
97 /* TODO: suport local variable containing an HMI_TREE index to jump to a relative page */ |
94 /* TODO: suport local variable containing an HMI_TREE index to jump to a relative page */ |
98 /* when no page name provided, check for same page */ |
95 /* when no page name provided, check for same page */ |