Revision: 3936
          http://vexi.svn.sourceforge.net/vexi/?rev=3936&view=rev
Author:   clrg
Date:     2010-10-21 09:58:20 +0000 (Thu, 21 Oct 2010)

Log Message:
-----------
Additional clean up and block Move underneath popups

Modified Paths:
--------------
    trunk/widgets/org.vexi.widgets/src/org/vexi/lib/role/popupmanager.t

Modified: trunk/widgets/org.vexi.widgets/src/org/vexi/lib/role/popupmanager.t
===================================================================
--- trunk/widgets/org.vexi.widgets/src/org/vexi/lib/role/popupmanager.t 
2010-10-21 09:47:57 UTC (rev 3935)
+++ trunk/widgets/org.vexi.widgets/src/org/vexi/lib/role/popupmanager.t 
2010-10-21 09:58:20 UTC (rev 3936)
@@ -116,11 +116,13 @@
                 return;
             }
             var p = trapee;
+            // drop active popup traps
             p.surface_x --= syncXPos;
             p.surface_y --= syncYPos;
             p.width --= updateXPos;
             p.height --= updateYPos;
             p.visible --= callee;
+            // handle container display
             popcount--;
             $container.display = popcount>0;
             // use default group if none is specified
@@ -129,7 +131,6 @@
                 popforegs[g].display = false;
             }
             if (popbygroup[g]) {
-                vexi.trace("removing key: "+g);
                 (keysof(popbygroup)).remove(g);
             }
         }
@@ -144,9 +145,9 @@
             var fg = popforegs[g];
             // establish 'v' as active popup for group
             if (popbygroup[g]) {
+                // undisplay previous popup in group
                 popbygroup[g].display = false;
             }
-            vexi.trace("assigning key: "+g+" -> "+p);
             popbygroup[g] = p;
             // call surface update functions
             var s = surface;
@@ -166,18 +167,15 @@
             fg.x = p.surface_x;
             fg.y = p.surface_y;
             p.display = true;
+            // assign active popup traps
+            p.surface_x ++= syncXPos;
+            p.surface_y ++= syncYPos;
+            p.width ++= updateXPos;
+            p.height ++= updateYPos;
+            p.visible ++= popboxDisplay;
             // handle container display
-            if (p.display) {
-                popcount++;
-                $container.display = popcount>0;
-                if (p.visible) {
-                    p.surface_x ++= syncXPos;
-                    p.surface_y ++= syncYPos;
-                    p.width ++= updateXPos;
-                    p.height ++= updateYPos;
-                    p.visible ++= popboxDisplay;
-                }
-            }
+            popcount++;
+            $container.display = true;
         }
         
         /** private function to handle timed pop requests */
@@ -185,6 +183,7 @@
             if (time==0 or 2>=arguments.length) {
                 // no delay stated, perform immediate popup/popdown
                 if (requests[v]) {
+                    // drop existing request
                     (keysof(reqtimes)).remove(v);
                     (keysof(requests)).remove(v);
                 }
@@ -263,7 +262,9 @@
                 fg.display = false;
                 fg.shrink = true;
                 fg.zindex = z;
-                fg[fg.numchildren] = p;
+                fg.add(p);
+                // block Enter/Leave underneath popup
+                fg.Move ++= eventBlock;
                 popforegs[g] = fg;
                 var n = $container.numchildren;
                 for (var i=1; n>i; i++) {


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

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Vexi-svn mailing list
Vexi-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vexi-svn

Reply via email to