example update

master
inpos 2018-08-08 12:53:54 +03:00
parent 2d545c0ccc
commit 5409901607
1 changed files with 3 additions and 1 deletions

View File

@ -16,10 +16,12 @@ class MyApplication(cp.ExtApplication):
wnd = Ext.create('widget.window', {'title': 'My Window', 'width': 300, 'height': 250, wnd = Ext.create('widget.window', {'title': 'My Window', 'width': 300, 'height': 250,
'items': [{'xtype': 'button', 'text': 'Click Here', 'handler': button_click}], 'items': [{'xtype': 'button', 'text': 'Click Here', 'handler': button_click}],
'buttons': [ 'buttons': [
{'text': 'OK', 'handler': ok_click}, {'text': 'OK', 'handler': js.FuncWithParams(ok_click, {'arg1': 1, 'arg2': 'val2'})},
{'text': 'Close', 'handler': js.function('this.up(\'window\').close()')}]}) {'text': 'Close', 'handler': js.function('this.up(\'window\').close()')}]})
wnd.show() wnd.show()
wnd.setHeight(200) wnd.setHeight(200)
cp.THEME = 'classic'
app = MyApplication('Orun (ExtJS Application)') app = MyApplication('Orun (ExtJS Application)')
app.run() app.run()