Updates following Button API changes
[platform/core/uifw/dali-demo.git] / resources / scripts / button.json
1 /*
2  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 {
18   "stage": [
19     // First Button
20     {
21       "type": "PushButton",
22       "parentOrigin": "TOP_CENTER",
23       "anchorPoint": "TOP_CENTER",
24       "position": [0, 0, 0],
25       "widthResizePolicy":"FILL_TO_PARENT",
26       "heightResizePolicy":"SIZE_RELATIVE_TO_PARENT",
27       "sizeModeFactor": [1,0.25,1],
28       "label": "Normal"
29     },
30
31     // Second Button
32     {
33       "type": "PushButton",
34       "parentOrigin": "CENTER",
35       "anchorPoint": "CENTER",
36       "position": [0, 0, 0],
37       "widthResizePolicy":"FILL_TO_PARENT",
38       "heightResizePolicy":"SIZE_RELATIVE_TO_PARENT",
39       "sizeModeFactor": [1,0.25,1],
40       "disabled": true,
41       "label": "Disabled"
42     },
43
44     // Third Button
45     {
46       "type": "PushButton",
47       "name": "toggleButton",
48       "parentOrigin": "BOTTOM_CENTER",
49       "anchorPoint": "BOTTOM_CENTER",
50       "position": [0, 0, 0],
51       "widthResizePolicy":"FILL_TO_PARENT",
52       "heightResizePolicy":"SIZE_RELATIVE_TO_PARENT",
53       "sizeModeFactor": [1,0.25,1],
54       "togglable": true,
55       "unselectedStateImage": "{DEMO_IMAGE_DIR}button-up-6.9.png",
56       "selectedStateImage": "{DEMO_IMAGE_DIR}button-up-8.9.png",
57       "label": "Toggle With Custom Images"
58     }
59   ]
60 }