Share Posted April 8, 2009 Hi there, The following problem comes to me and I can't create a simple test for reproduce the bug : The current DisplayObject : horizontalScrollPolicy="off" verticalScrollPolicy="off"> angle='45' blurX='4' blurY='4' distance='4' alpha='0.4' color='#000000' knockout='false' quality='1' strength='1' inner='false' hideObject='false'/> /* Here is my image, the canvas content auto ajust */ /* a replacement with an mx:Button don't change anything */ Thanks in advance Link to comment Share on other sites More sharing options...
Share Posted April 8, 2009 It'd be SUPER helpful if you'd zip up a simplified Flex project that clearly demonstrates the issue and send it directly to me via e-mail or private message. When I pasted your code into Flex, it kept complaining "Initializer for property 'states' is not allowed here". I've got a lot on my plate at the moment and don't have much time to try building something that reproduces the problem (TransformManager seems to work great for me and nobody else has complained about a similar issue), so your help would be greatly appreciated. Link to comment Share on other sites More sharing options...
Author Share Posted April 9, 2009 I have passed lot of time to isolate this problem. Finnaly I found this, It's because the root canvas has a yellow border. I have created a simple flex project example. I will send you email. Thanks Link to comment Share on other sites More sharing options...
Share Posted April 11, 2009 Yep, looks like yet another bug in the Flex framework. It doesn't accurately perform globalToLocal() on a canvas with a border (it offsets things by the thickness of the border). You can see proof with this simple MXML: <br> import mx.containers.Canvas;<br><br> public function doMain():void {<br><br> var redReg:Point = red.parent.globalToLocal(red.localToGlobal(new Point(0, 0))); //just translates the origin of the red box into the coordinate space of its parent where we'll position the green box.<br><br> //now position the green box directly over the red box (you'll see that it's actually offset by however thick the border of the parent is (which is a bug in Flex)<br> green.x = redReg.x;<br> green.y = redReg.y;<br><br> } <br> ]]><br> If you've got any ideas on how to elegantly work around the Flex bug, let me know. I'm not interested in littering my code with a bunch of conditional logic to accommodate a Canvas border, though, especially because it seems to be an obvious bug in the framework that Adobe will hopefully fix on the next rev of Flex. Link to comment Share on other sites More sharing options...
Share Posted September 2, 2009 If you've got any ideas on how to elegantly work around the Flex bug, let me know. I have a similar problem when I put a border on the FlexTransformManager. I too am looking for a work-around for this bug. Thanks Much, Mark Link to comment Share on other sites More sharing options...
Share Posted September 2, 2009 Again, this is a bug in Flex, not TransformManager. I'd recommend avoiding borders and instead, apply them manually with a Shape or something. You'd get the same effect visually, but without the bug. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now