Revision: 3810
          http://vexi.svn.sourceforge.net/vexi/?rev=3810&view=rev
Author:   clrg
Date:     2010-02-26 15:45:38 +0000 (Fri, 26 Feb 2010)

Log Message:
-----------
Fix tablist doubling up on list implementation + tidy up

Modified Paths:
--------------
    trunk/widgets/org.vexi.widgets/src/org/vexi/theme/classic/tablist.t

Modified: trunk/widgets/org.vexi.widgets/src/org/vexi/theme/classic/tablist.t
===================================================================
--- trunk/widgets/org.vexi.widgets/src/org/vexi/theme/classic/tablist.t 
2010-02-26 14:34:35 UTC (rev 3809)
+++ trunk/widgets/org.vexi.widgets/src/org/vexi/theme/classic/tablist.t 
2010-02-26 15:45:38 UTC (rev 3810)
@@ -9,18 +9,16 @@
     </meta:doc>
     
     <lib:option />
-    <lay:margin redirect=":$proxy" margin="3" maxlistheight="160" 
shrink="true">
+    <lay:margin redirect=":$content" margin="3" maxlistheight="160" 
shrink="true">
         <button id="button" width="18" minheight="18">
             <ui:box fill="#d4d0c8" layout="layer"> 
                 <ui:box id="arrow" fill=":.image.arrowdown" shrink="true" />
             </ui:box>
         </button>
-        <!-- always hidden -->
-        <ui:box id="proxy" display="false" />
-        <!-- moved elsewhere -->
+        <!-- our popox -->
         <lay:border id="popbox" border="black" depth="1">
             <scrollpane id="scroll" autohide="true" 
fill=":.settings..surfacefill" hshrink="true" scrollhorizontal="false">
-                <wi:list id="content" fill="white" shrink="true" />
+                <ui:box id="content" fill="white" shrink="true" />
             </scrollpane>
         </lay:border>
         
@@ -44,19 +42,16 @@
         /** grow content scrollpane */
         $content.height ++= function(v) {
             // FIXME: this is all a bit of a hack really - do it properly
-            if (!popped) { cascade = v; return true; }
+            if (!popped) {
+                cascade = v;
+                return;
+            }
             var surf = 
surface.frame.height-surface.frame.distanceto($popbox).y;
             surf = maxlistheight>surf ? surf : maxlistheight;
             $scroll.minheight = v>surf ? surf : v;
             cascade = v;
         }
         
-        /** move proxy children to $popbox children */
-        $proxy.Children ++= function(v) { $content[trapname] = v; return; }
-        $proxy.Children ++= function() { return $content[trapname]; }
-        $proxy.indexof ++= function() { return $content.indexof; }
-        $proxy.numchildren ++= function() { return $content.numchildren; }
-        
         thisbox.surfaceWidth = function(dx, sw) {
             v_popbox.surface_x = vexi.math.max(0, dx-v_popbox.width+width-3);
         }
@@ -68,8 +63,9 @@
         v_popbox.width ++= function(v) {
             cascade = v;
             var s = surface;
-            if (s==null) return;
-            surfaceWidth(s.frame.distanceto(thisbox).x, s.frame.width);
+            if (s!=null) {
+                surfaceWidth(s.frame.distanceto(thisbox).x, s.frame.width);
+            }
         }
         
     </lay:margin>


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Vexi-svn mailing list
Vexi-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vexi-svn

Reply via email to