5 Replies Latest reply on Jun 16, 2009 9:24 AM by acath

    Checkbox and Radio Button Use In Transitions

    monkamoo

      I am currently using checkboxes and radio buttons to filter particular ecommerce products.  Onclick, the buttons enable transition from one state to another, and it ends in "selected mode" after transition.  however, if I try to transition back to the initial state, I would like for the button to deselect itself.  This is not the case.  The buttons remain in selected mode when transitioning back to the initial state.  ie;

       

      button enables transition from state 1 to state 2  (button ends in state 2 in selected mode - as it should)

       

      state 2 to state 1 (button remains selected - I would like it to deselect) - note: to effect transition from state 2 to state 1, I developed a text pathway.  Another words, the button effects transition from state 1 to 2, but a separate text pathway effects transition from state 2 to 1.  Thanks in advance - file attached.  Don/monkamoo.com

        • 1. Re: Checkbox and Radio Button Use In Transitions
          acath Level 4

          I can't see your attachment. You may need to rename the FXP to something more innocuous-seeming, like TXT (stupid forum software, I know)...

           

          One thing you might try is to explicitly toggle on and off the "selected" property in state1. Let me know if this works and I'll send the long explanation of why it works...

           

          -Adam

          Catalyst Engineering

          • 2. Re: Checkbox and Radio Button Use In Transitions
            monkamoo Level 1

            Adam, that totally worked.  I tried for hours to get it working.  Thanks, Don/monkamoo.com

            • 3. Re: Checkbox and Radio Button Use In Transitions
              Peter Flynn (Adobe) Adobe Employee

              So, here's the medium-long explanation of why that works...

               

              When you're working with states, there's a difference between properties/settings you've never touched before vs. ones that you've done some editing on.  If you've never touched a property in a given state, it's essentially "open" or "free."  If the SWF's user takes actions (such as typing in a text box or clicking a toggle button) that change the component, switching states to another state where that property on the component is untouhed or "open" will leave it as-is -- that is, as the user left it.  This is useful behavior in many cases (e.g., "Search" text field in the Results state should still show the text the user entered in the StartSearch state).

               

              But once you've edited a property, even if you eventually edit it back to its original value, it's now "explicitly set."  This means that when you transition into the state where you did the editing, we blow away whatever value the setting had in the state you just left -- even if it got that way due to user input -- in order to make the setting match what you explicitly set it to.

               

              Hope that makes a little more sense.  We are definitely looking carefully at ways we can expose this distinction better within Catalyst.

               

              - Peter

              • 4. Re: Checkbox and Radio Button Use In Transitions
                acath Level 4

                Long explanation is on its way...give me a few days...

                • 5. Re: Checkbox and Radio Button Use In Transitions
                  acath Level 4

                  Beautiful. Thanks, Peter!