2 Replies Latest reply on Feb 15, 2007 8:18 AM by Killogram

    "Hover" like functionality

    Killogram
      Has anyone had any success in trying to replicate CSS's "hover" type functionality to repeatedly call a function using Flex?

      I have an application that I'm attempting to modify so that when a user hovers the mouse over an image, a function is repeatedly called until the user moves the mouse off the image. The rollover & mouseover functions both fall short as they only call the defined function once.

      E.g. I have a couple arrows images that when clicked will scroll a list up or down. However, I want the same "scroll up" or "scroll down" functions to be executed when the user also hovers over the arrow images and the execution to cease on "mouseout".

      I'm relatively new to flex, so any help or pointers in the right direction would be appreciated.

      Thanks!
        • 1. "Hover" like functionality
          Dzihan
          I never tried something like that but i bet the cursorManager in AS3 has information about what object the mouse hovers. Just get this information inside the mouseover function and let it call itself again and again if mouseHoverObj == event.target.

          I don't know if this would do but would try something like that first.
          • 2. Re: "Hover" like functionality
            Killogram Level 1
            Thanks for the response.

            However, I don't see a way to leverage the CursorManager and retrieve any relevant info about the object a users mouse is currently hovering over. I'll continue to research it, but it appears as if the cursor manager primarily just functions to manage cursor behaviors.

            If anyone can show me an example of using the cursor manager in a different capacity, I'd love to see it.

            I wish I knew Flex a bit better as it appears the MouseEvent has a "relatedObject" property that I might be able to use...