SettingItemBuilder class

设置项构建器

将设置项构建逻辑从 AliPlayerWidget 中剥离,直接使用 AliPlayerWidgetController 的 notifier,确保横竖屏数据一致性。

对于 int 类型的状态(镜像、旋转、渲染),自动转换为 String 用于 UI 显示。

重要: 使用完毕后必须调用 dispose 释放资源,移除注册的 listener。

Constructors

SettingItemBuilder({required AliPlayerWidgetController controller, required SceneType sceneType, required Set<String>? hiddenElements, required SafeValueNotifier<bool> isShowExternalSubtitle})

Properties

controller AliPlayerWidgetController
final
hashCode int
The hash code for this object.
no setterinherited
hiddenElements Set<String>?
final
isShowExternalSubtitle SafeValueNotifier<bool>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sceneType SceneType
final

Methods

buildLoopItem() SettingItem
构建循环播放设置项
buildMirrorItem() SettingItem
构建镜像模式设置项
buildMuteItem() SettingItem
构建静音设置项
buildQualityItem(List<String> displayQualities, List<AVPTrackInfo>? trackInfoList) SettingItem<String>
构建清晰度设置项
buildRenderItem() SettingItem
构建渲染模式设置项
buildRotateItem() SettingItem
构建旋转角度设置项
buildSpeedItem() SettingItem<double>
构建倍速设置项
buildSubtitleItem() SettingItem
构建字幕设置项
dispose() → void
释放包装 Notifier 和移除 listener
filterVisibleSettingItems(List<SettingItem> items) List<SettingItem>
过滤可见的设置项
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited