r9213: some improvements to the registry editor code
authorAndrew Tridgell <tridge@samba.org>
Mon, 8 Aug 2005 05:26:15 +0000 (05:26 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:31:32 +0000 (13:31 -0500)
(This used to be commit 5cd33fa9f898f95a78397a387a42977a4839fb20)

swat/esptest/registry.esp

index 85843c41d9caddbaa1ca9bdda88b6daa9011b8e9..2b6a2144734f5fc76dc6d0ffb068696de814fbb2 100644 (file)
 function folder_list(t, list) {
        var i;
        t.populated = true;
 function folder_list(t, list) {
        var i;
        t.populated = true;
-       t.reg_list = new Object();
+       t.removeAll();
        for (i=0;i<list.length;i++) {
                var te;
        for (i=0;i<list.length;i++) {
                var te;
-               if (t.reg_list.working != undefined) {
-                       te = t.reg_list.working;
-                       t.reg_list = new Object();
-                       te.label = list[i];
-               } else {
-                       te = new QxTreeFolder(list[i]);
-                       t.add(te);
-               }
+               te = new QxTreeFolder(list[i]);
+               t.add(te);
                te.binding = t.binding;
                if (t.reg_path == '\\\\') {
                        te.reg_path = list[i];
                } else {
                        te.reg_path = t.reg_path + '\\\\' + list[i];
                }
                te.binding = t.binding;
                if (t.reg_path == '\\\\') {
                        te.reg_path = list[i];
                } else {
                        te.reg_path = t.reg_path + '\\\\' + list[i];
                }
-               te.reg_list = new Object();
-               te.reg_list.working = new QxTreeFolder('Working ...');
-               te.add(te.reg_list.working);
-               t.reg_list[list[i]] = te;
+               te.add(new QxTreeFolder('Working ...'));
                te.addEventListener("click", function() { 
                        var el = this; folder_click(el); 
                });
                te.addEventListener("click", function() { 
                        var el = this; folder_click(el); 
                });
-               te.setOverflow("auto");
                t.setOpen(1);
        }
 }
                t.setOpen(1);
        }
 }
@@ -54,16 +44,15 @@ function registry_tree(binding) {
       var t = new QxTree("registry: " + binding);
       t.binding = binding;
       t.reg_path = "\\\\";
       var t = new QxTree("registry: " + binding);
       t.binding = binding;
       t.reg_path = "\\\\";
-      t.reg_list = new Object();
       t.populated = false;
       with(t)
       {
         setBackgroundColor(255);
         setBorder(QxBorder.presets.inset);
       t.populated = false;
       with(t)
       {
         setBackgroundColor(255);
         setBorder(QxBorder.presets.inset);
-        setOverflow("auto");
+        setOverflow("scroll");
         setStyleProperty("padding", "2px");
         setStyleProperty("padding", "2px");
-        setWidth(200);
-        setHeight("100%");
+        setWidth(400);
+        setHeight(400);
         setTop(20);
        addEventListener("click", function() { folder_click(t); });
       }
         setTop(20);
        addEventListener("click", function() { folder_click(t); });
       }
@@ -74,7 +63,7 @@ function registry_tree(binding) {
   {
     var inlineWidget = new QxInline;
     var fieldSet = new QxFieldSet("Registry");
   {
     var inlineWidget = new QxInline;
     var fieldSet = new QxFieldSet("Registry");
-    var binding = "ncacn_np:win2003";
+    var binding = "ncalrpc:";
 
     with(fieldSet)
     {
 
     with(fieldSet)
     {