-
Notifications
You must be signed in to change notification settings - Fork 1
/
flex3.js
27 lines (26 loc) · 951 Bytes
/
flex3.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// Flex 3 page
//
exports.View =
{
title: "Flex 3",
elements:
[
{ control: "stackpanel", orientation: "Vertical", height: "*", width: "*", contents: [
{ control: "wrappanel", orientation: "Horizontal", width: "*", contents: [
{ control: "toggle", binding: "showRed", caption: "Show Red", onLabel: "Showing", offLabel: "Hiding", fontsize: 12 },
{ control: "toggle", binding: "showBlue", caption: "Show Blue", onLabel: "Showing", offLabel: "Hiding", fontsize: 12 },
] },
{ control: "rectangle", height: "*", width: "*", color: "Red", margin: 0, visibility: "{showRed}" },
{ control: "rectangle", height: "*", width: "*", color: "Blue", margin: 0, visibility: "{showBlue}" },
] }
]
}
exports.InitializeViewModel = function (context, session)
{
var viewModel =
{
showRed: true,
showBlue: true
}
return viewModel;
}