Resize effect bug?

In the mxml file below, if you click 'Expand' the red box on
the right uses a Resize effect to grow, but it ends up expanding
way off the screen (producing a scrollbar in the application window
briefly). Since I have specified 'absolute' layout, shouldn't the
Resize effect respect the 'right="0"' constraint and expand the red
box to the left instead of to the right?
Is there another way of doing this?
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
xmlns="*"
layout="absolute"
width="100%" height="400" backgroundColor="yellow" >
<mx:Script><![CDATA[
import mx.effects.Resize;
private var resize:Resize = new Resize();
private function expand():void
resize.target = right_box;
resize.heightBy = 0;
resize.widthTo = this.width;
resize.duration = 1000;
resize.play();
]]></mx:Script>
<mx:HBox id='left_box' width="200" height="100%" left="0"
backgroundColor="blue" />
<mx:HBox id='right_box' width="200" height="100%"
right="0" backgroundColor="red" >
<mx:Button label="Expand" click="expand()" />
<mx:Button label="Contract" click="right_box.width=200;"
/>
</mx:HBox>
</mx:Application>

Well, I suppose we could add support to resize to tell it to
move as well as resize, but we're not setup that way. You can add a
move effect that will do what you want.
Objects that are affected by effects don't listen to
constraints and such because otherwise those things could block the
effect.

Similar Messages

  • [svn:fx-gumbo_beta2] 10484: Fix for autoCenter problem when Move/ Resize effects are used.

    Revision: 10484
    Author:   [email protected]
    Date:     2009-09-21 19:38:14 -0700 (Mon, 21 Sep 2009)
    Log Message:
    Fix for autoCenter problem when Move/Resize effects are used. autoCenterTransform calculates the center dynamically, using the current width/height of the target. This calculation can be one frame off if a Resize effect is running in parallel with the transform effect. Also, containers do their validation lazily, so they need to be forced to validate in order to have an up-to-date width/height. This fix addresses these problems by reordering the effects in a Parallel hierarchy to put the Resize effects (and composite effects containing Resize) at the front of the set of effects and by calling validateNow() on the target of a transform effect prior to calculating the transform center (if appropriate).
    QE notes: None
    Doc notes: None
    Bugs: SDK-23306
    Reviewer: Jason
    Tests run: checkintests, Mustella spark/effects mx/effects, manual tests
    Is noteworthy for integration: Yes
    Ticket Links:
        http://bugs.adobe.com/jira/browse/SDK-23306
    Modified Paths:
        flex/sdk/branches/gumbo_beta2/frameworks/projects/framework/src/mx/effects/effectClasses/ CompositeEffectInstance.as
        flex/sdk/branches/gumbo_beta2/frameworks/projects/framework/src/mx/effects/effectClasses/ ParallelInstance.as
        flex/sdk/branches/gumbo_beta2/frameworks/projects/spark/src/spark/effects/supportClasses/ AnimateTransformInstance.as

    Dear Pallavi,
    Very useful post!
    I am looking for similar accelerators for
    Software Inventory Accelerator
    Hardware Inventory Accelerator
    Interfaces Inventory
    Customization Assessment Accelerator
    Sizing Tool
    Which helps us to come up with the relevant Bill of Matetials for every area mentioned above, and the ones which I dont know...
    Request help on such accelerators... Any clues?
    Any reply, help is highly appreciated.
    Regards
    Manish Madhav

  • How do I disable the Image Resize Effect?

    The Image class does a zoom resize effect when you change
    it's width and height. How do I disable that? it's .transitions
    array is already empty.

    Thanks Ralph, that fixed it, I did uncheck that box earlier however I had not restarted the computer. Thanks again.

  • Using Resize effect to resize the component to 100percent

    Hi all,
    I am using resize component to show the opening of a datagrid which contains itemrenderers.The number of itemrenderers is not fixed hence i want to use the resize effect to resize the grid from height=0 to height=100%. I m not getting any clue as to how to do percent resize with effects.
    Please share ur ideas.

    Thanks for your answer!
    I tried setting the font size to Auto, but the problem is that the text starts off really small, at about 12pt font. I really need it to start with large text, eg to start off as one word at say 60pt size, and be able to go down to two words on the top line and two words on the bottom line, at around 20 pt size. So it starts large, but goes down in size with the more text that is put in.
    I am making editable Avery Labels for teachers - 10 to a page - to put kids names in, or subjects and names.
    Also... is it possible to cenre the text vertically with in the text box?
    Thanks very much for your advice!

  • How to set resize effect for border container using flex 4 or 4.5

    Hi friends,
    resize effect works fine for one control (image). if want to same for custom comp, then is not working.
    below is the code is in custom comp,
    <?xml version="1.0" encoding="utf-8"?>
    <s:VGroup xmlns:fx="http://ns.adobe.com/mxml/2009" width="200"
             xmlns:s="library://ns.adobe.com/flex/spark" horizontalAlign="left" verticalAlign="bottom"
             xmlns:mx="library://ns.adobe.com/flex/mx"  xmlns:parsley="http://www.spicefactory.org/parsley"
             xmlns:general="com.presentation.components.general.*">
        <fx:Declarations>
            <parsley:Configure/>
        </fx:Declarations>
        <s:BorderContainer id="bcMain" backgroundColor="#f4f4f4" borderColor="#CDC7C7" borderStyle="solid" borderVisible="true" width="100%">
            <s:layout>
                <s:VerticalLayout horizontalAlign="left" verticalAlign="middle" paddingTop="5" paddingLeft="5" paddingRight="5" paddingBottom="5"/>
            </s:layout>
            <s:HGroup id="hg1" horizontalAlign="left" verticalAlign="middle" width="100%" gap="5"
                      buttonMode="true" useHandCursor="true" >
                <s:Image id="img1" source="@Embed(source='assets/flex.png" width="15" height="17" cachePolicy="on" cacheAsBitmap="true"/>
                <s:Label text="label 1" textAlign="center"/>
            </s:HGroup>
            <mx:HRule width="100%"/>
            <s:HGroup horizontalAlign="left" verticalAlign="middle" width="100%" gap="10">
                <s:BorderContainer id="bc1" width="35" useHandCursor="true" buttonMode="true"
                          backgroundColor="#f4f4f4" height="40">
                    <s:layout>
                        <s:VerticalLayout horizontalAlign="center" verticalAlign="middle"/>
                    </s:layout>
                    <s:Image id="img2" source="@Embed(source='assets/flex.png" cachePolicy="on" cacheAsBitmap="true"/>
                    <s:Label text="label 2" textAlign="center"/>
                </s:BorderContainer>
                <s:BorderContainer id="bc2" width="35" useHandCursor="true" buttonMode="true"
                          backgroundColor="#f4f4f4" height="40">
                    <s:layout>
                        <s:VerticalLayout horizontalAlign="center" verticalAlign="middle"/>
                    </s:layout>
                    <s:Image id="img3" source="@Embed(source='assets/flex.png" cachePolicy="on" cacheAsBitmap="true"/>
                    <s:Label text="label 3" textAlign="center"/>
                </s:BorderContainer>
                <s:BorderContainer id="bc3" width="35" useHandCursor="true" buttonMode="true"
                          backgroundColor="#f4f4f4" height="40">
                    <s:layout>
                        <s:VerticalLayout horizontalAlign="center" verticalAlign="middle"/>
                    </s:layout>
                    <s:Image id="img4" source="@Embed(source='assets/flex.png" cachePolicy="on" cacheAsBitmap="true"/>
                    <s:Label text="label 4" textAlign="center"/>
                </s:BorderContainer>
            </s:HGroup>
        </s:BorderContainer>
    </s:VGroup>
    I followed how resize effects works for image control,
    <mx:Resize id="expand" target="{img}" widthTo="100" heightTo="200"  duration="2000"/>
            <mx:Resize id="contract" target="{img}" widthTo="30" heightTo="60"  duration="2000"/>
    <s:Panel title="Resize Effect Example" width="100%" height="100%">
            <s:VGroup width="100%" height="200" horizontalAlign="left" verticalAlign="bottom">           
                <mx:Image id="img" source="@Embed(source='assets/05_ipad.png')" width="10" height="10"/>
                <mx:Button label="Expand" click="expand.end(); expand.play();"/>
                <mx:Button label="Contract" click="contract.end(); contract.play();"/>
            </s:VGroup>
        </s:Panel>
    Please help me.

    BorderContainer wont resize if the fixed width is specified, if u want to give some minimum width you can use minWidth . Give  Width = "100%", now it will get Resizing capabilities

  • [svn:fx-trunk] 10131: Fixes to several effects bugs and one styles-related bug.

    Revision: 10131
    Author:   [email protected]
    Date:     2009-09-10 14:25:42 -0700 (Thu, 10 Sep 2009)
    Log Message:
    Fixes to several effects bugs and one styles-related bug.
    QE notes: Fixes to all filed auto-center feature bugs.
    Doc notes: None
    Bugs: sdk-22994, sdk-22992, sdk-22990, sdk-21850, sdk-22973
    Reviewer: Jason (+Glenn for RadioButton/CheckBox changes, 21850)
    Tests run: checkintests, Mustella (transform effects, Slider, DataGrid - all passed last week, prior to skin/test changes)
    Is noteworthy for integration: No
    Ticket Links:
        http://bugs.adobe.com/jira/browse/sdk-22994
        http://bugs.adobe.com/jira/browse/sdk-22992
        http://bugs.adobe.com/jira/browse/sdk-22990
        http://bugs.adobe.com/jira/browse/sdk-21850
        http://bugs.adobe.com/jira/browse/sdk-22973
    Modified Paths:
        flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/CheckBox.as
        flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButton.as
        flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as
        flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/SoundEffectInst ance.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransform.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move3D.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate3D.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale3D.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateTransfor mInstance.as
        flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicEleme nt.as
        flex/sdk/trunk/tools/dependencychecker/frameworkSwcExceptionsList.txt

  • Fixed lots of Effect Bugs

    Hey,
    I have done a lot in my sandbox to fix Effect bugs, and add things that weren't in general working properly.  These include:
    1) Added/removed Effects.
    - Now all components, spark and halo, can have added/removed effects.
    2) Popup Effects.
    - Added/removed effects did not work correctly with popups, even in the old implementation.  Now, even with PopUpAnchor, you can run added/removed effects on the popup.  Move effects work correctly too, taking into consideration the popup position before animating.
    3) EffectManager was modified for handling these changes, as was PopUpAnchor, PopUpManager, SystemManager, and ChildManager.  Nothing that would break anything, as I have run the tests and everything works fine.
    Please pull my sandbox changes when you get a chance.  Thanks!

    Thanks a lot Matt.
    My goal in creating my own sandbox was to fix all the little things I find as I go, optimize things here and there, and refactor the code if I need to (without modifying the API) to make it easier to do things.
    These Effect fixes just made it so you could do what you expect, b/c it was doing strange things before .
    It would be very helpful if there was a workflow for merging these sandboxes changes into the main branch so I could use the Framework "swz", unless there is a way, or you're planning on creating a way, to create my own.
    Thanks,
    Lance

  • Resize effect in the repeater control

    Hi All,
    I developed an application using repeater control.Using repeater control i created 3 buttons.Is it possible to set the resize effect for the buttons in repeater control.I mean if i click on first button,only the first button need to be resized.If i click on secodn button,then only the second button need to be resized.Plz sugest the solution.

    I don't understand completely.But below is a piece of code I wrote render a image as a zoom popup and then when i cliked on the pop up it resized to its original size. May be it can help you
    use :-
    img.addEventListener(MouseEvent.CLICK, image_click);
    img.addEventListener(ResizeEvent.RESIZE, image_resize);
    PopUpManager.addPopUp(img, this, true);
    and
    private function image_click(evt:MouseEvent):void {
                        PopUpManager.removePopUp(evt.currentTarget as Image);
    private function image_resize(evt:ResizeEvent):void {
                       PopUpManager.centerPopUp(evt.currentTarget as Image);
    If you are using image.

  • Resize effect maintaining the window centered

    I have a TitleWindow that I open using the PopUpManager.
    PopUpManager.centerPopUp(paymentWindow);       
    I would like to apply a resize effect when I show the window.
    <mx:Resize id="expand"  widthTo="640" heightTo="480"/>
    The problem is that the TitleWindow is resized from the upper left corner to the bottom right corner. So the popup is no more centered. How can I apply the same effect but maintaining the window centered in the screen while it is resized?

    I don't understand completely.But below is a piece of code I wrote render a image as a zoom popup and then when i cliked on the pop up it resized to its original size. May be it can help you
    use :-
    img.addEventListener(MouseEvent.CLICK, image_click);
    img.addEventListener(ResizeEvent.RESIZE, image_resize);
    PopUpManager.addPopUp(img, this, true);
    and
    private function image_click(evt:MouseEvent):void {
                        PopUpManager.removePopUp(evt.currentTarget as Image);
    private function image_resize(evt:ResizeEvent):void {
                       PopUpManager.centerPopUp(evt.currentTarget as Image);
    If you are using image.

  • Problem with spark:resize effect and constraint-layout

    Hi,
    maybe its just a missuderstanding, but how i an get this to work.
    Also move effects doesnt seem to work.
    Does somebody have a Link, where I can get deeeper in constraints and spark.effects?
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                    xmlns:s="library://ns.adobe.com/flex/spark"
                    xmlns:mx="library://ns.adobe.com/flex/mx"
                    minWidth="955" minHeight="600"
                    width="100%" height="100%"
                    currentState="State1"
                    initialize="init()">
         <s:layout>
             <s:BasicLayout/>
         </s:layout>
        <fx:Script>
             <![CDATA[
                 import flash.utils.Timer;
                 import flash.events.TimerEvent;
                 import flash.events.Event;
                private var timer:Timer;
                 private function init():void {
                     timer = new Timer(5000);
                     timer.addEventListener(TimerEvent.TIMER, switcher);
                     timer.start();
                 public function switcher(event:TimerEvent):void {
                     if (currentState =="State1") {
                         currentState = "State2";
                     } else  {
                         currentState = "State1";
             ]]>
         </fx:Script>
         <s:states>
             <s:State name="State1"/>
             <s:State name="State2"/>
         </s:states>
         <s:transitions>
             <s:Transition fromState="State1" toState="State2">
                 <s:Resize target="{mainPanel}" />
             </s:Transition>
             <s:Transition fromState="State2" toState="State1">
                 <s:Resize target="{mainPanel}" />
             </s:Transition>
         </s:transitions>
        <s:Panel id="mainPanel"
                 horizontalCenter="0" verticalCenter="0"
                  width.State1="250"  height.State1="200"
                  horizontalCenter.State2="0" verticalCenter.State2="0"
                  left.State2="20" right.State2="20" top.State2="10" bottom.State2="50">
         </s:Panel>
    </s:Application>

    I think there are bugs in this area for transitioning an objects size between states where two different sizing mechanisms are in play.
    If you transition from constraints to constraints or from width/height to width/height it should work better:
        <s:Panel id="mainPanel"
                 horizontalCenter="0" verticalCenter="0"
                 left.State1="200" right.State1="200" top.State1="100" bottom.State1="500"
                 left.State2="20" right.State2="20" top.State2="10" bottom.State2="50">

  • Bevel effect bug.

    To some you, this is going to look like a trivial matter. For those of us designing detailed multi-buttoned GUI's, it isn't. Yes, there are time consuming work-arounds. But why?...when it could be fixed by Adobe?
    This first pic shows the starting point. It is a two layer image, the blue rectangles being uppermost.
    This second pic shows the default settings used to add an emboss effect to the rectangles and the result.
    It takes a sharp eye to see what's wrong. This third pic zooms in to show the problem.
    If you apply a outer or embossed bevel effect to a number of objects on a single layer, the topmost and leftmost edges will be missing a pixels worth of feathering. This error popped up in PS CS2. It almost seems like there is this mystery 1 pixel offset error worming it way around various parts of the program. I'd really LOVE to hear Chris Cox's take on this one, too.

    it's not a bug
    I would beg to differ.

  • Resizing effects: Bevel & Emboss

    Hi All,
    I've created a logo in IDCS3 using Bevel and Emboss. It's a monogram with a diamond background, two elements one each on separate layers.
    When I reduce this combo, the effect is remaining the same size. In other words when I reduce it to 60%, my 1/8" bevel is still 1/8". Obviously this will not work, I need the effect to reduce proportionally.
    How can I resize the image AND the effect?
    (Perhaps it was stupid to design a logo in IDCS3? I thought I'd give it a try since I know InDesign better than AI or PS. I can always export it as an EPS file, right?)

    > I don't see any advantage in pre-flattening a logo.
    Steve, I don't see any advantage either. BB is expressing concern over the bevel effect being rasterized. The PDF route will certainly work, my post #8 was intended as a warning that a flattened PDF will rasterize effect.
    The advice should have been written as such... If you choose the PDF route for this particular quandary, use an unflattened PDF to avoid pre-rasterization of the effect.

  • Effects Bug

    Hi Spry-Team,
    Just a little bug I would like to report, that I just
    noticed. In of my designs I had a DIV with a CSS style shadow, like
    this:
    filter:progid:DXImageTransform.Microsoft.Shadow(color='#CCCCCC',
    Direction=135, Strength=4)
    When I apply an effect (AppearFade & Blind) the shadow
    immediately disappears and doesn't reappear after toggle.
    Low priority bug, but maybe you can look into it...
    Regards,
    Leon

    Hi Leon,
    Thanks for reporting this. I'll file a bug about this. It
    happens because the Fade effect sets the filter CSS property on IE
    to alpha() to accomplish the fading. This overwrites your setting
    while the effect is going animating.
    --== Kin ==--

  • Flash Symbol w/ filters + spark parents + Fade effect bug

    I've come across an interesting bug which I've narrowed down to a combination of:
    • Flash symbols containing 1 or more Filters (defined in the Flash IDE)...
    • Parented within certain Spark components (ex. symbol in Group that's in another Group)...
    • Modified by an effect like spark.effects.Fade
    What you see when you combine those elements above is a 1-frame, fully-opaque flicker after the Fade has completed (if fading out) or before it begins (if fading in). This flicker is noticeable and obviously not an intended part of the animation.
    Here's a small test project that reproduces what I'm talking about. If you change the VGroup component to a VBox the flicker stops happening (at least for me). The same is true if you remove the middle DataGroup component. (The bug may not stop altogether but it does occur less frequently in that case.)
    Application.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx"
                   xmlns:local="*">
         <fx:Script>
              <![CDATA[
                   import mx.collections.ArrayCollection;
              ]]>
         </fx:Script>
         <fx:Declarations>
              <s:Sequence id="sequence">
                   <s:Fade target="{ vbox }" alphaTo="0" />
                   <s:Fade target="{ canvas }" alphaTo="1" />
                   <s:Fade target="{ canvas }" alphaTo="0" />
                   <s:Fade target="{ vbox }" alphaTo="1" />
              </s:Sequence>
         </fx:Declarations>
         <!-- If you replace the VGroup with a VBox, this bug does not show itself. -->
         <s:VGroup id="vbox" horizontalAlign="center" horizontalCenter="0" verticalCenter="0">
         <!--<mx:VBox id="vbox" horizontalAlign="center" horizontalCenter="0" verticalCenter="0">-->
              <!-- Changing this DataGroup to a regular Group lowers the frequency of the bug, but it still occurs. -->
              <s:DataGroup id="dataGroup" dataProvider="{ new ArrayCollection( [ BasicSymbol, SymbolWithGlow, SymbolWithBevel ] ) }">
                   <s:layout>
                        <s:HorizontalLayout verticalAlign="middle" />
                   </s:layout>
                   <s:itemRenderer>
                        <fx:Component>
                             <local:DataGroupItemRenderer />
                        </fx:Component>
                   </s:itemRenderer>
              </s:DataGroup>
              <s:Button label="Play" click="sequence.play()" />
         <!--</mx:VBox>-->
         </s:VGroup>
         <mx:Canvas id="canvas" width="200" height="200" horizontalCenter="0" verticalCenter="0" backgroundColor="0xCC6600" mouseEnabled="false" alpha="0" />
    </s:Application>
    DataGroupItemRenderer MXML
    <?xml version="1.0" encoding="utf-8"?>
    <s:ItemRenderer autoDrawBackground="false" width="70" height="70"
                    xmlns:fx="http://ns.adobe.com/mxml/2009"
                    xmlns:s="library://ns.adobe.com/flex/spark"
                    xmlns:mx="library://ns.adobe.com/flex/mx">
         <fx:Script>
              <![CDATA[
                   override public function set data( value:Object ):void {
                        super.data = value;
              ]]>
         </fx:Script>
         <mx:Image source="{ data }" />
    </s:ItemRenderer>
    In addition to the below MXML, I am also happy to provide the FLA that I've created the symbols in as well as a video demonstrating the glitch. (I will try to attach the video as a follow-up comment.)

    Suppose not.
    Defect created: https://bugs.adobe.com/jira/browse/SDK-30475

  • AE Median Effects BUG ???

    Hi There,
    I have come across this weird problem with the median effect.
    I apply it to a FullHD clip set to Full Quality.
    I up the Radius to 6 and then the preview bar starts advancing. It does so for at least 60 Seconds.
    Then it becomes an Indeterminate progress bar and that will spin for another 200 seconds at least.
    Then I open Boris' Median which is just as good in quality an apply that to the same clip.
    That takes 1 second or less to establish a preview.
    This is AE 5.5
    I dont know whether this is a BUG or a behavior.
    So if anyone can confirm this, it would be nice.
    As of now, I have to stop using AE's Median and use that from Boris.
    Thanks

    Hi Todd,
    thanks for testing this...
    Think I may have found a clue.
    My Fast Preview Setting was - Open GL Interactive
    Setting it to Open GL - Always - renders even a 16bit Tiff, instantaneously
    Toggling back to Interactive revealed the problem.
    Setting fast previews to OFF also works but takes a lot longer.
    Thanks for testing again !!!

Maybe you are looking for

  • How do I back up phone numbers from Nokia 6350 bef...

    I got so tired of my buggy Nokia 6350 that I went to my service provider's website (AT&T) and bought an iPhone 3GS. When it arrived I read the instructions, found some confusing directions there and am in the process of asking for clarifications in t

  • Here's How to change the image on the TOC to be different for each chapter.

    Suppose you don't follow the Very Strict default Rule that you use the exact same image parameters (shape, pixels, size, etc.) for your Table of Contents image entry as you use for its associated Chapter, a requirement built in to iBooks Author that

  • Getting null in document object Help me

    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();                DocumentBuilder builder = factory.newDocumentBuilder();                InputSource inputSource = new InputSource();                inputSource.setCharacterStream(ne

  • How to include Java embedding in BPEL to connect with Siebel On Demand

    Hi, I am trying to integrate Siebel on Demand with BPEL using the instructions given in the Best practices page http://www.oracle.com/technology/tech/fmw4apps/siebel/ofm-siebel-blog-postings.html. The code used in the Java embedding does not send a r

  • 5700 Express Music Huge Problem

    So I've had my phone for liek half a year now and other than the fact that I couldn't view my pictures or movies that I took with the phone (although they were there as I could download them to my PC), as if they were hidden or sth it was working OK.