Multiple objects using Senocular TransformTool

Senocular TransformTool is one of the best and most used components around the net. It is really useful for those (include me) who don’t want to fight against Matrix, concatenation of Matrix and all those painful stuff…

The only ‘lack’ of that component is that it does not support multiple objects as target. If you want to transform n array of elements at the same time you should have all those elements in the same parent DisplayObjectContainer and then set that parent as target of TransformTool.

http://ins104.dijizeka.net/history-gcse-coursework-help/ But maybe sometimes this is not possible due to various reason and you want to use different items with different parents as dataprovider.

This is the solution I actually use for that particular situation (Remember that I’m using a modified version of the TransformTool)

source url This is the final result: ( Ctrl+click on the tree leaves to multiple selection )

Live Demo of the Trasform Tool using multiple objects

http://www.kstechnologybd.com/doctoral-dissertation-help-apa-reference/ ( Here you can download download the source files ).

source link In few words the solution I found is this:

see url Create a temporary layer which will be the TransformTool target.
For every item in the selection Array create a temporary shape with the size of the getBounds() of the real object. Store this shape into the temporary layer, assigning to it the concatenated matrix of the real object.

follow url Once there’s a transformation of the temporary layer get every shape transform matrix and assign back to the original object.

http://ef-luegde.de/research-paper-on-julius-caesar/ Probably there are many and better solutions to do the same, this is just the one I found, maybe someone has better approach to this problem (and he is welcome here!)

  • hbb

    the great solution!
    I think getBounds() is fit for muliple targets ,if only one target matrix is better.)