You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by Mark Fuqua <ma...@availdata.com> on 2013/12/18 02:15:40 UTC
interacting with navigator from outside view stack
I have an actionscript class that runs a function on a timed interval.
There is no way to tell what view the user will be on when the function is
run.
I would like to push the user to a view from within this function when
certain conditions are met. I have tried this, but it won't compile.
FlexGlobals.topLevelApplication.navigator.pushView(TaskFeed);
Is there a way to do this? Is there a way to interact with views from
outside the views package?
Thanks,
Mark Fuqua
mark@availdata.com
2301 Mount Carmel Road
Parkton, MD 21120
(410) 215-7356
www.availdata.com
Re: interacting with navigator from outside view stack
Posted by Alex Harui <ah...@adobe.com>.
What error are you getting? Is navigator a ViewStack? I don't think it
has pushView. There is addChild and selectedIndex.
Is this a mobile app? IIRC, timers can drain battery. If not, consider
using a data model to represent the UI state. Then the timer changes the
model and the view reacts accordingly.
On 12/17/13 5:15 PM, "Mark Fuqua" <ma...@availdata.com> wrote:
>I have an actionscript class that runs a function on a timed interval.
>There is no way to tell what view the user will be on when the function is
>run.
>
>
>
>I would like to push the user to a view from within this function when
>certain conditions are met. I have tried this, but it won't compile.
>
>
>
>FlexGlobals.topLevelApplication.navigator.pushView(TaskFeed);
>
>
>
>Is there a way to do this? Is there a way to interact with views from
>outside the views package?
>
>
>
>Thanks,
>
>
>
>Mark Fuqua
>
>
>
>mark@availdata.com
>
>
>
>2301 Mount Carmel Road
>
>Parkton, MD 21120
>
>(410) 215-7356
>
>
>
>www.availdata.com
>
>
>