Commit a3b53360 authored by 任建锋's avatar 任建锋

--

parent dd6e52a5
......@@ -169,8 +169,8 @@
y:parseInt(node.y),
anchorX:parseInt(node.anchorX),
anchorY:parseInt(node.anchorY),
scaleX:parseInt(node.anchorX),
scaleY:parseInt(node.anchorY),
scaleX:parseInt(node.scaleX),
scaleY:parseInt(node.scaleY),
// imageWidth:parseInt(node.imageWidth),
// imageHeight:parseInt(node.imageHeight),
width:parseInt(node._width),
......
......@@ -95,6 +95,7 @@
let view = this.getNode('', true);
return node.getIndexPath(view);
},
}
}
</script>
......
......@@ -311,10 +311,11 @@ export default {
this.styleCatch={
x:this.targetNode.x,
y:this.targetNode.y,
worldVisible:this.targetNode.worldVisible,
anchorX:this.targetNode.anchorX,
anchorY:this.targetNode.anchorY,
imageWidth:this.targetNode.imageWidth,
imageHeight:this.targetNode.imageHeight,
textureWidth:this.targetNode.textureWidth,
textureHeight:this.targetNode.textureHeight,
worldMatrix:this.targetNode.worldMatrix,
width:this.targetNode.width,
height:this.targetNode.height,
......@@ -356,15 +357,16 @@ export default {
}
let result={
width: `${ (this.styleCatch.imageWidth?this.styleCatch.imageWidth:(this.styleCatch.width?this.styleCatch.width:0))*scaleX/window.devicePixelRatio}px`,
height: `${ (this.styleCatch.imageHeight?this.styleCatch.imageHeight:(this.styleCatch.height?this.styleCatch.height:0))*scaleY/window.devicePixelRatio}px`,
width: `${ (this.styleCatch.textureWidth?this.styleCatch.textureWidth:(this.styleCatch._width?this.styleCatch._width:(this.styleCatch.width?this.styleCatch.width:0)))*scaleX/window.devicePixelRatio}px`,
height: `${ (this.styleCatch.textureHeight?this.styleCatch.textureHeight:(this.styleCatch._height?this.styleCatch._height:(this.styleCatch.height?this.styleCatch.height:0)))*scaleY/window.devicePixelRatio}px`,
marginTop:`${y/window.devicePixelRatio}px`,
marginLeft:`${x/window.devicePixelRatio}px`,
transform: `rotate(${rotation}deg)`,
// webkitTransformOriginY: `${ this.styleCatch.anchorY?this.styleCatch.anchorY:0}px`,
// webkitTransformOriginX: `${ this.styleCatch.anchorX?this.styleCatch.anchorX:0}px`,
webkitTransformOrigin:`0px 0px 0px`,
opacity:`${this.canFouce?"1":"0"}`
opacity:`${this.canFouce?"1":"0"}`,
display:`${this.styleCatch.worldVisible?"block":"none"}`
// transform: `matrix(${this.styleCatch.worldMatrix.a},${this.styleCatch.worldMatrix.b},${this.styleCatch.worldMatrix.c},${this.styleCatch.worldMatrix.d},${this.styleCatch.worldMatrix.tx},${this.styleCatch.worldMatrix.ty})`
}
......@@ -410,18 +412,21 @@ export default {
},
targetNode:function(){
console.log("targetNode变化",this.targetNode)
// console.log(this.targetNode.getLocalBounds())
if(!this.targetNode){
return
}
let {
x,
y,
worldVisible,
anchorX,
anchorY,
width,
height,
imageWidth,
imageHeight,
textureWidth,
textureHeight,
left,
top,
right,
......@@ -449,8 +454,8 @@ export default {
anchorY,
width,
height,
imageWidth,
imageHeight,
textureWidth,
textureHeight,
left,
top,
right,
......@@ -461,6 +466,7 @@ export default {
instanceType,
verticalCenter,
source,
worldVisible,
_width,
_height,
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment