on xenial help sign in
fixed indent
10b9065Nick Dedekind
tests/qmltests/Panel/Indicators/tst_DefaultIndicatorPage.qml+70−70
@@ -25,7 +25,7 @@ Item {
25 width: units.gu(40)
25 width: units.gu(40)
26 height: units.gu(70)
26 height: units.gu(70)
27
27
28− DefaultIndicatorPage {
28+ DefaultIndicatorPage {
29 id: page
29 id: page
30 anchors.fill: parent
30 anchors.fill: parent
31
31
@@ -35,23 +35,36 @@ Item {
35 menuObjectPath: "/com/canonical/indicator/test"
35 menuObjectPath: "/com/canonical/indicator/test"
36 }
36 }
37
37
38− property var fullMenuData: [{
38+ property var fullMenuData: [{
39− "rowData": { // 1
39+ "rowData": { // 1
40− "label": "root",
40+ "label": "root",
41− "sensitive": true,
41+ "sensitive": true,
42− "isSeparator": false,
42+ "isSeparator": false,
43− "icon": "",
43+ "icon": "",
44− "type": "com.canonical.indicator.root",
44+ "type": "com.canonical.indicator.root",
45− "ext": {},
45+ "ext": {},
46− "action": "",
46+ "action": "",
47− "actionState": {},
47+ "actionState": {},
48− "isCheck": false,
48+ "isCheck": false,
49− "isRadio": false,
49+ "isRadio": false,
50− "isToggled": false,
50+ "isToggled": false,
51− },
51+ },
52− "submenu": [{
52+ "submenu": [{
53− "rowData": { // 1.1
53+ "rowData": { // 1.1
54− "label": "menu1",
54+ "label": "menu1",
55+ "sensitive": true,
56+ "isSeparator": false,
57+ "icon": "",
58+ "type": "",
59+ "ext": {},
60+ "action": "",
61+ "actionState": {},
62+ "isCheck": false,
63+ "isRadio": false,
64+ "isToggled": false,
65+ }}, {
66+ "rowData": { // 1.2
67+ "label": "menu2",
55 "sensitive": true,
68 "sensitive": true,
56 "isSeparator": false,
69 "isSeparator": false,
57 "icon": "",
70 "icon": "",
@@ -63,58 +76,45 @@ Item {
63 "isRadio": false,
76 "isRadio": false,
64 "isToggled": false,
77 "isToggled": false,
65 }}, {
78 }}, {
66− "rowData": { // 1.2
67− "label": "menu2",
68− "sensitive": true,
69− "isSeparator": false,
70− "icon": "",
71− "type": "",
72− "ext": {},
73− "action": "",
74− "actionState": {},
75− "isCheck": false,
76− "isRadio": false,
77− "isToggled": false,
78− }}, {
79− "rowData": { // row 1.2
79+ "rowData": { // row 1.2
80− "label": "menu3",
80+ "label": "menu3",
81− "sensitive": true,
81+ "sensitive": true,
82− "isSeparator": false,
82+ "isSeparator": false,
83− "icon": "",
83+ "icon": "",
84− "type": "",
84+ "type": "",
85− "ext": {},
85+ "ext": {},
86− "action": "",
86+ "action": "",
87− "actionState": {},
87+ "actionState": {},
88− "isCheck": false,
88+ "isCheck": false,
89− "isRadio": false,
89+ "isRadio": false,
90− "isToggled": false,
90+ "isToggled": false,
91− }}
91+ }}
92− ]
92+ ]
93− }]; // end row 1
93+ }]; // end row 1
94−
94+
95− property var emptySubMenuData: [{
95+ property var emptySubMenuData: [{
96− "rowData": { // 1
96+ "rowData": { // 1
97− "label": "root",
97+ "label": "root",
98− "sensitive": true,
98+ "sensitive": true,
99− "isSeparator": false,
99+ "isSeparator": false,
100− "icon": "",
100+ "icon": "",
101− "type": "com.canonical.indicator.root",
101+ "type": "com.canonical.indicator.root",
102− "ext": {},
102+ "ext": {},
103− "action": "",
103+ "action": "",
104− "actionState": {},
104+ "actionState": {},
105− "isCheck": false,
105+ "isCheck": false,
106− "isRadio": false,
106+ "isRadio": false,
107− "isToggled": false,
107+ "isToggled": false,
108− },
108+ },
109− "submenu": []
109+ "submenu": []
110− }]; // end row 1
110+ }]; // end row 1
111−
111+
112− function initializeMenuData(data) {
112+ function initializeMenuData(data) {
113− Indicators.UnityMenuModelCache.setCachedModelData("com.canonical.indicator.test",
113+ Indicators.UnityMenuModelCache.setCachedModelData("com.canonical.indicator.test",
114− "/com/canonical/indicator/test",
114+ "/com/canonical/indicator/test",
115− "/com/canonical/indicator/test",
115+ "/com/canonical/indicator/test",
116− data);
116+ data);
117− }
117+ }
118
118
119 UT.UnityTestCase {
119 UT.UnityTestCase {
120 name: "DefaultIndicatorPage"
120 name: "DefaultIndicatorPage"