NarraLeaf

Switch

Switch 控件的选中状态,以及每个控件都有的启用与可见两个开关

九个节点,对应一个 nl.switch 元素:界面需要的各种形态的选中状态,加上启用与可见这一对。

约定

  • 只能用于控件蓝图,且只在 Switch 上。 它们的 scope 就是 nl.switch,所以只在那个控件自己的蓝图里出现,别处没有。要从别的图里够到一个 Switch,用 Element 分类下的对应版本
  • 三个读取节点是 pure。 Blueprint Value 的宿主是 widgetValue,不提供这些节点;要在 Blueprint Value 中读取 Switch,请配合 Element 字面量使用 Element 版本。六个写入节点是 latent
  • 可见与启用节点各合为一组。 浏览创建浮窗时,Get Visible 与 Get Enabled 合为一行获取可见性或启用状态,Set Visible 与 Set Enabled 合为一行设置可见性或启用状态。搜索时每个节点按自己的名称列出;已放置的卡片可用标题旁的 ▾ 在两者之间切换。见同类节点

Get Checked

blueprint.switch.getChecked · Pure

引脚方向类型说明
checkedout · databoolean

Set Checked

blueprint.switch.setChecked · Latent

引脚方向类型说明
inin · exec—
nextout · exec—
checkedin · databoolean字面量

Turn On

blueprint.switch.turnOn · Latent

就是传 true 的 Set Checked,单独做成一张卡,好让最常见的那件事读起来只有一个词。

引脚方向类型说明
inin · exec—
nextout · exec—

Turn Off

blueprint.switch.turnOff · Latent

引脚方向类型说明
inin · exec—
nextout · exec—

Toggle

blueprint.switch.toggle · Latent

引脚方向类型说明
inin · exec—
nextout · exec—
checkedout · databoolean翻完之后停在哪一边

Get Enabled

blueprint.switch.getEnabled · Pure

引脚方向类型说明
enabledout · databoolean

Set Enabled

blueprint.switch.setEnabled · Latent

引脚方向类型说明
inin · exec—
nextout · exec—
enabledin · databoolean

Get Visible

blueprint.switch.getVisible · Pure

引脚方向类型说明
visibleout · databoolean

Set Visible

blueprint.switch.setVisible · Latent

引脚方向类型说明
inin · exec—
nextout · exec—
visiblein · databoolean

本页目录