Forum Discussion
Is it possible to create custom Hover, Selected, and Visited states in a tab interaction?
I know it's possible. The question, really, is can it be done and function the way I envision it?
In short, I'd like to have the tab interaction function so that each state works in harmony with the others.
Behavior
Click should change the state to SelectedState.
When the user clicks another button the previously selected button should change to VisitedState
When the user hovers, the button state should change to HoverState, if the button is in Normal or VisitedState.
On hover out, the button should return to the previous state. For example: If it was in SelectedState or VisitedState, it should return to those states.
I cannot get the HoverState to function as desired. But the other states are working.
This project is only for the purpose of refreshing my skills. It's been years since I've developed in Storyline—so bear with my development if you see anything inefficient. In fact, if you find yourself saying, "Why'd you do that?" Please don't hesitate to bring it up.
My storyline file is attached. Thanks in advance for any assistance you can provide.
- SandeepGadamCommunity Member
Hello there, I was able to replicate your problem and come up with a fix for it. It works good just by duplicating the current hover state and create a new hover state by selecting the desired choice from the selection. Please refer to the SL file that is provided.
- WaltHamiltonSuper Hero
FYI, and for anybody that finds this, every function you describe is built into the predefined states. That means if you use the names in the built-in drop-down list, you don’t need to create those actions. They come with the states, with two caveats.
1. To get the Selected state to turn off when another is clicked, they have to be part of a button set. In a set, only one can be selected at a time.
2. You wrote:
When the user hovers, the button state should change to HoverState, if the button is in Normal or VisitedState.
If you are willing to have the hover state show any time the cursor hovers over the object, that is built into the hover state. If you actually mean you want it to change only if it is in Normal or Visited, you have to create that action. WARNING: if you create your own triggers and actions, you MUST use a name for the state other than Hover. Writing your own triggers that duplicate the actions of the built-in actions can lead to strange, unpredictable, and seldom desirable results. If you have, indeed, created your own triggers, that may be the problem with the hover state. If not, follow Sandeep’s suggestion.