【问题标题】:Flex mobile TextInput eventsFlex 移动 TextInput 事件
【发布时间】:2012-05-27 17:34:25
【问题描述】:

我似乎无法从 Flex 移动应用中的 TextInput 控件触发任何事件。

<s:TextInput id="testInput" valueCommit="textInputHandler(event)" 
             touchEnd="textInputHandler(event)" 
             touchBegin="textInputHandler(event)"
             touchOut="textInputHandler(event)" 
             click="textInputHandler(event)"
             />

我最初只需要 ValueCommit 事件,但我无法触发上面示例中列出的任何事件。

我在 Flash Builder 设备模拟器和实际的 Android 和 iPad 设备上进行了尝试,但没有成功。

【问题讨论】:

    标签: apache-flex


    【解决方案1】:

    所以 TextInput.textDisplay 是用于移动设备的 StyleableStageText(与 RichEditableText 不同)。 StyleableStageText 不会调度 ValueCommit 事件。我想您可以使用 RichEditableText 对其进行皮肤处理,但您会失去移动优化。

    我最终使用了 FocusOut 事件来满足我的需要。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-02-13
      • 1970-01-01
      • 2012-06-13
      • 1970-01-01
      • 2012-01-20
      • 2012-03-09
      • 2010-09-21
      • 1970-01-01
      相关资源
      最近更新 更多