OSDN Git Service

Version 0.6.190, fix X.UI.ScrollBox & X.UI.Gesture.
[pettanr/clientJs.git] / 0.6.x / js / 20_ui / 08_Box.js
index 0aa07e1..d0c7818 100644 (file)
@@ -24,7 +24,7 @@ var XUI_Layout_Canvas = X[ 'UI' ][ 'Layout' ][ 'Canvas' ] = XUI_createLayout( {
 \r
                data.preMesure( w, h );\r
                \r
-               console.log( w + ' > ' + data.boxWidth );\r
+               //console.log( w + ' > ' + data.boxWidth );\r
                \r
                //  data.boxWidth と data.boxHeight のどちらかでも Infinity\r
                if( isNeedsDetection && data.boxWidth + data.boxHeight === XUI_Attr_AUTO ) return false;\r
@@ -35,7 +35,7 @@ var XUI_Layout_Canvas = X[ 'UI' ][ 'Layout' ][ 'Canvas' ] = XUI_createLayout( {
                _h = data.contentHeight;\r
 \r
                if( ( uinodes = data.uinodes ) && ( l = uinodes.length ) ){\r
-                       console.log( _w + ' x ' + _h + ' l:' + l );\r
+                       //console.log( _w + ' x ' + _h + ' l:' + l );\r
                        for( i = 0; i < l; ++i ){\r
                                node = uinodes[ i ];\r
                                node.calculate( false, _x, _y, _w, _h );\r
@@ -176,7 +176,9 @@ var XUI_Box = XUI_AbstractUINode.inherits(
                \r
                capcher : function( x, y ){\r
                        var uinodes, child, _x, _y, hit, i;\r
+                       \r
                        if( this.pointerDisabled ) return false;\r
+\r
                        delete this.hitChildData;\r
                        x -= this.boxX;\r
                        y -= this.boxY;\r
@@ -198,7 +200,9 @@ var XUI_Box = XUI_AbstractUINode.inherits(
                        };\r
                        hit = 0 <= x && x < this.boxWidth && 0 <= y && y < this.boxHeight;\r
                        ( this.hitChildData || hit ) && !this.hovering && ( this.rootData.hoverList[ this.rootData.hoverList.length ] = this );\r
-                       if( hit && this.hitChildData === null ) this.rootData.targetNodeData = this;\r
+                       if( hit && this.hitChildData === null ){\r
+                               this.rootData.targetNodeData = this;\r
+                       };\r
                        return hit || !!this.hitChildData;\r
                },\r
                \r
@@ -342,7 +346,7 @@ X.UI.Box = X.UI.AbstractUINode.inherits(
                },\r
                \r
                clone : function( opt_cloneListener ){\r
-                       var clone   = XUI_AbstractUINode.prototype.clone.call( this,  opt_cloneListener ),\r
+                       var clone   = X.UI.AbstractUINode.prototype.clone.call( this,  opt_cloneListener ),\r
                                uinodes = X_Pair_get( this ).uinodes,\r
                                i       = 0,\r
                                l       = uinodes && uinodes.length,\r