Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-21222

Rotate effect sometimes causes objects to snap when complete

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • Adobe Flex SDK Previous
    • Adobe Flex SDK Previous
    • Spark: Effects
    • None
    • Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      1. Run the code below
      2. Click the button
      3. Watch the animation

      Actual Results:
      When the animation finishes, you'll see a 'snap' as the object positions itself in the correct end location (the blue/green dots mark where the corners should be)

      Expected Results:
      The object should animate to the end position and there should be no snap when it is complete.

      <?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:d="http://ns.adobe.com/fxg/2008/dt" xmlns:fc="http://ns.adobe.com/flashcatalyst/2009" backgroundColor="#ffffff" height="600" preloaderBaseColor="#ffffff" width="800">
      <s:states>
      <s:State name="Page1"/>
      <s:State name="Page2"/>
      </s:states>
      <fx:DesignLayer d:userLabel="Layer 1">
      <s:ToggleButton label="Change State" selected="true" id="tb" change="currentState=tb.selected ? 'Page1' : 'Page2'"/>
      <s:Group rotation.Page2="90" x="50" x.Page2="100" y="60" id="group1">
      <s:Rect id="rect1" width="50" height="50">
      <s:fill>
      <s:SolidColor color="red"/>
      </s:fill>
      </s:Rect>
      </s:Group>
      <s:Rect x="50" y="60" width="1" height="1">
      <s:fill>
      <s:SolidColor color="blue"/>
      </s:fill>
      </s:Rect>
      <s:Rect x="100" y="60" width="1" height="1">
      <s:fill>
      <s:SolidColor color="green"/>
      </s:fill>
      </s:Rect>
      </fx:DesignLayer>
      <s:transitions>
      <s:Transition autoReverse="true" fromState="Page1" toState="Page2">
      <s:Parallel>
      <s:Parallel targets="

      {[group1]}

      ">
      <s:Rotate autoCenterTransform="true" duration="2000"/>
      </s:Parallel>
      </s:Parallel>
      </s:Transition>
      <s:Transition autoReverse="true" fromState="Page2" toState="Page1">
      <s:Parallel>
      <s:Parallel target="

      {group1}

      ">
      <s:Rotate autoCenterTransform="true" duration="2000"/>
      </s:Parallel>
      </s:Parallel>
      </s:Transition>
      </s:transitions>
      </s:Application>

      Attachments

        Activity

          People

            adobejira Adobe JIRA
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: