Flex:在 currentStateChange 处理程序中设置另一个状态?
我有一个 currentStateChange 处理程序。在那个处理程序中。我想根据变量设置另一个状态。 currentStateChange 处理程序会触发,但在处理程序函数中它不会将其更改为下一个状态。我知道当它到达处理程序点时状态已经改变。我希望这是我所缺少的东西,而不是 Flex 限制...
* state >状态2>我无法在状态更改处理程序中更改为状态 3 *
private function onStateChange(e:Event):void
{
//THIS FIRES
if(applicationViewModel.eremndr_mode == ApplicationViewModel.ERMNDR_MODE_LOGIN)
{
//it gets here but won't change to Signup state!
prescreenViewModel.prescreen_state ='Signup';
}
}
I have a currentStateChange handler. In that handler. I want to set another state based on a variable. The currentStateChange handler fires but in the handler function it won't change it to the next state. I know when it gets to the handler point the state has already changed. I'm hoping it something I'm missing and not a Flex limitation...
* state > state2 > I can't change to state 3 inside state change handler *
private function onStateChange(e:Event):void
{
//THIS FIRES
if(applicationViewModel.eremndr_mode == ApplicationViewModel.ERMNDR_MODE_LOGIN)
{
//it gets here but won't change to Signup state!
prescreenViewModel.prescreen_state ='Signup';
}
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我相信他的问题是附加到过渡的效果仍在播放,因此它忽略了我更改状态的请求
I believe he issue was an effect that was attached to the transition was still playing so it ignored my request to change the state