From 5d13d53762933c306e595079efd1f69b1807fb1a Mon Sep 17 00:00:00 2001 From: Tobi Oetiker Date: Fri, 16 Nov 2007 20:05:00 +0000 Subject: working version --- qooxdoo/source/class/Smokeping/ui/Graphs.js | 75 ++++++++++--------------- qooxdoo/source/class/Smokeping/ui/TargetTree.js | 15 ++++- 2 files changed, 41 insertions(+), 49 deletions(-) (limited to 'qooxdoo/source/class/Smokeping/ui') diff --git a/qooxdoo/source/class/Smokeping/ui/Graphs.js b/qooxdoo/source/class/Smokeping/ui/Graphs.js index 9508eee..7a9fb83 100644 --- a/qooxdoo/source/class/Smokeping/ui/Graphs.js +++ b/qooxdoo/source/class/Smokeping/ui/Graphs.js @@ -32,56 +32,39 @@ qx.Class.define('Smokeping.ui.Graphs', setHeight('100%'); setVerticalSpacing(10); setHorizontalSpacing(10); + setPadding(10); }; - for(var i=0;i<2000;i++){ - var button = new qx.ui.basic.Atom(i.toString()); - this.add(button); - } - }, - - /* - ***************************************************************************** - Statics - ***************************************************************************** - */ - - statics : - { - - /* - --------------------------------------------------------------------------- - CORE METHODS - --------------------------------------------------------------------------- - */ - - /** - * Create the tree based on input from the Server - * - * @type member - * - * @param {void} - * - * @return BaseUrl {Strings} - */ + var load_graphs = function(m){ + var files = m.getData() + this.removeAll(); + for(var i=0;i 0) { + if ( e.getData()[0].basename == 'TreeFolder' ){ + qx.event.message.Bus.dispatch('sp.menu.folder',e.getData()[0].getUserData('ids')); + } + } + },this); + rpc.callAsync(fill_tree,'get_tree'); }, @@ -82,8 +90,8 @@ qx.Class.define('Smokeping.ui.TargetTree', __fill_folder: function(node,data){ // in data[0] we have the id of the folder var folder = new qx.ui.tree.TreeFolder(data[1]); - folder.setUserData('id',data[0]); node.add(folder); + var files = new Array(); var length = data.length; for (var i=2;i