From 8be5ffbb2c9085c785e4594a8eb286d6e48e3d2d Mon Sep 17 00:00:00 2001 From: rolux Date: Fri, 22 Jun 2012 09:54:38 +0200 Subject: [PATCH] update example --- examples/forms/file_selection/js/example.js | 25 ++++++++++----------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/examples/forms/file_selection/js/example.js b/examples/forms/file_selection/js/example.js index 97c0ebc9..8661b62f 100644 --- a/examples/forms/file_selection/js/example.js +++ b/examples/forms/file_selection/js/example.js @@ -65,7 +65,7 @@ Ox.load('UI', function() { $innerPanel = Ox.SplitPanel({ elements: [ {element: $main}, - {element: $list, size: 256} + {element: $list, resizable: true, resize: [256], size: 256} ], orientation: 'horizontal' }), @@ -79,7 +79,16 @@ Ox.load('UI', function() { .appendTo(Ox.$body); function openDialog(data) { - var $content = Ox.Element() + var $button = Ox.Button({ + id: 'close', + title: 'Close' + }) + .bindEvent({ + click: function() { + $dialog.close(); + } + }), + $content = Ox.Element() .css(getContentCSS(data)) .append( Ox.FileInput({ @@ -101,17 +110,7 @@ Ox.load('UI', function() { }) ), $dialog = Ox.Dialog({ - buttons: [ - Ox.Button({ - id: 'close', - title: 'Close' - }) - .bindEvent({ - click: function() { - $dialog.close(); - } - }) - ], + buttons: [$button], content: $content, height: 129, keys: {escape: 'close'},