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

CalloutButton shows calloutContents on MouseOver, instead of MouseClick

Details

    Description

      I happened to migrate from 4.12 to 4.12.1. Wherever calloutbutton was used, the callout contents were shown only on click of calloutbutton. But now in 4.12.1, it shows the callout contents as soon as we hover the mouse cursor on top of calloutbutton. When I try to select callout content, it just closes the callout.
      Issue is CalloutButton shows calloutContents on MouseOver, instead of MouseClick and gets closed on MouseOut. And mouse click has no effect.

      This was using a mobile project, 4.12.1, on windows 7 simulator, using AIR 4, AIR13, AIR14.

      Sample code to try:

      <?xml version="1.0" encoding="utf-8"?>
      <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
      xmlns:s="library://ns.adobe.com/flex/spark" title="Home" xmlns:ns="http://flex.apache.org/experimental/ns">

      <s:layout>
      <s:VerticalLayout verticalAlign="top" horizontalAlign="left"/>
      </s:layout>
      <fx:Declarations>

      </fx:Declarations>

      <s:CalloutButton label="Click">
      <s:calloutContent>
      <s:List labelField="name">
      <s:dataProvider>
      <s:ArrayCollection>
      <fx:Object name="Name 1"/>
      <fx:Object name="Name 2"/>
      <fx:Object name="Name 3"/>
      <fx:Object name="Name 4"/>
      <fx:Object name="Name 5"/>
      </s:ArrayCollection>
      </s:dataProvider>
      </s:List>
      </s:calloutContent>
      </s:CalloutButton>

      </s:View>

      Attachments

        Activity

          set rollOverOpenDelay style to NaN

          mamsellem Maurice Amsellem added a comment - set rollOverOpenDelay style to NaN
          megharajdeepak Deepak MS added a comment -

          Thanks Maurice, that worked
          But it keeps giving this warning:
          The style 'rollOverOpenDelay' is only supported by type 'spark.components.CalloutButton' with the theme(s) 'spark'.
          Not a issue though.

          megharajdeepak Deepak MS added a comment - Thanks Maurice, that worked But it keeps giving this warning: The style 'rollOverOpenDelay' is only supported by type 'spark.components.CalloutButton' with the theme(s) 'spark'. Not a issue though.

          Yes, I know

          mamsellem Maurice Amsellem added a comment - Yes, I know
          agentphantom George added a comment -

          Hi there,

          Yesterday I did some tests with this bug, these are the results (Apache Flex 4.13.0 rc3 + AIR 14 latest beta):

          When creating a desktop AIR app this bug doesn't occur at all. The Callout opens on a click event, not rollover.
          On a mobile app it only occurs while running it on the AIR simulator. This bug doesn't occur on actual mobile devices.

          The style supplied a few comments above doesn't work on the mobile theme, it returns an Error and can't compile.

          As said before, it works perfectly fine in 4.12.0 and the bug started to occur in 4.12.1

          Regards

          George

          agentphantom George added a comment - Hi there, Yesterday I did some tests with this bug, these are the results (Apache Flex 4.13.0 rc3 + AIR 14 latest beta): When creating a desktop AIR app this bug doesn't occur at all. The Callout opens on a click event, not rollover. On a mobile app it only occurs while running it on the AIR simulator. This bug doesn't occur on actual mobile devices. The style supplied a few comments above doesn't work on the mobile theme, it returns an Error and can't compile. As said before, it works perfectly fine in 4.12.0 and the bug started to occur in 4.12.1 Regards George
          lkhlufo Omar LKHLUF added a comment -

          Hi,

          I fixed this on handling initialize event of the CallOutButton with :

          protected function callOutInitializeHandler(event:FlexEvent):void
          {
          (event.target as CalloutButton).setStyle("rollOverOpenDelay",Number.NaN);
          }

          lkhlufo Omar LKHLUF added a comment - Hi, I fixed this on handling initialize event of the CallOutButton with : protected function callOutInitializeHandler(event:FlexEvent):void { (event.target as CalloutButton).setStyle("rollOverOpenDelay",Number.NaN); }
          erik@ixsoftware.nl Erik de Bruin added a comment -

          Is this still an issue? And if so, does the solution in the previous comment fix it on all 'devices'? If it is a valid fix, can someone provide a patch or commit the solution? Thanks!

          erik@ixsoftware.nl Erik de Bruin added a comment - Is this still an issue? And if so, does the solution in the previous comment fix it on all 'devices'? If it is a valid fix, can someone provide a patch or commit the solution? Thanks!
          Arjan Arjan added a comment -

          Hi Omar,

          Could you please tell me how I can do this. I am not an advanced programmer. How do I handle the initialize even of a CallOutButton?

          Arjan Arjan added a comment - Hi Omar, Could you please tell me how I can do this. I am not an advanced programmer. How do I handle the initialize even of a CallOutButton?

          People

            mamsellem Maurice Amsellem
            megharajdeepak Deepak MS
            Votes:
            3 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated: