0 Replies Latest reply on Apr 6, 2012 3:30 AM by LeonardoAgosti

    Pan Zoom componente with start zoom

    LeonardoAgosti

      Hi!

       

      I use the adobe component com.adobe.wheelerstreet.fig.panzoom.

      How can'I set a default value of zoom?

      It's set to default to 1 and I don't found way to modify this value....

       

      This is the creator of component:

       

      public function ImageViewer():void

                          {

                                    viewRect = new Rectangle();

                                    _contentRectangle = new ContentRectangle(0,0,0,0,viewRect);

       

                                    addEventListener(ResizeEvent.RESIZE, handleResize);

       

                                    addEventListener(FlexEvent.CREATION_COMPLETE, handleCreationComplete);

       

       

       

                                    function handleCreationComplete(e:FlexEvent):void

                                    {

                                              _contentRectangle.zoom =1

                                              bitmapScaleFactor = _contentRectangle.zoom;

                                              invalidateDisplayList();

       

                                    }

                          }

       

       

      If I modify

      _contentRectangle.zoom =1

       

      to

       

      _contentRectangle.zoom =0.6

       

      don't refresh the component.

       

      Any ideas?