flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deepak MS <megharajdee...@gmail.com>
Subject Re: Callout contents issue
Date Tue, 23 Sep 2014 09:56:19 GMT
Here's the screenshot of the issue I'm facing.


I have also tried to come up with sample example:

<?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"
currentState="loggedOut" >

        <s:VerticalLayout />


            private var USER_IDLE_TIME:int = 5;//seconds
            private var timer:Timer;
            protected function button1_clickHandler(event:MouseEvent):void
                currentState = 'loggedIn';
                timer = new Timer(1000);
                timer.addEventListener(TimerEvent.TIMER, logoutUser);

            private var count:int = 0;
            private function logoutUser(event:TimerEvent):void

                if(count == USER_IDLE_TIME)
                    count = 0;
                    timer.removeEventListener(TimerEvent.TIMER, logoutUser);
                    timer = null;

                    currentState = 'loggedOut'; //if call out contents are
open, it will keep floating the callout contents on the screen even if we
change the state.

        <s:State name="loggedOut"/>
        <s:State name="loggedIn"/>

    <s:Button label="Login" click="button1_clickHandler(event)"
              visible.loggedOut="true" includeInLayout.loggedOut="true"
              visible.loggedIn="false" includeInLayout.loggedIn="false"/>

    <s:CalloutButton label="Dropdown"

            <s:List labelField="name">
                        <fx:Object name="someValue1"/>
                        <fx:Object name="someValue2"/>
                        <fx:Object name="someValue3"/>
                        <fx:Object name="someValue4"/>
                        <fx:Object name="someValue5"/>

On Wed, Sep 17, 2014 at 2:02 PM, Deepak MS <megharajdeepak@gmail.com> wrote:

> Hello,
> I have ran into this issue when we change the states.
> I have defined 2 states. One of the state has a calloutbutton and when
> calloutbutton's callout contents are still active(open) and if we change
> the app's currentstate(user idle time out), the calloutbutton's contents
> are still shown on the screen.
> Is that an expected behaviour?
> How can we remove the calloutcontent when we change the state?

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message