summaryrefslogtreecommitdiff
path: root/src/examples/button_example_00.js
blob: 64d7c8f6f5c9011db19a1b60cac02bbe7fd377c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21

efl = require('efl');
elm = require('elm');

win = new elm.Elm.WinStandard(null);
win.setTitle("Hello, World!");
win.setAutohide(true);

btn = new elm.Elm.Button(win);
btn.setText(null, "Good-Bye, World!");
btn.setSize(120, 30);
btn.setPosition(60, 15);
btn.setSizeHintWeight(1.0, 1.0);
btn.setSizeHintAlign(1.0, 1.0);
btn.setVisible(true);

btn.on('clicked', function () { console.log('clicked'); } );

win.setSize(240, 60);
win.setVisible(true);