fix: 屏幕方向和屏幕超时设置切换后不立即生效

MoreConfigSheet 中屏幕方向和屏幕超时的变更只写入 DataStore,需经过
6 步异步传播(DataStore → Flow → ViewModel → Effect → Controller)
才能生效,导致:
- 切换横屏后文字显示不全,仍保持竖屏布局
- 目录不跟随横屏显示
- 屏幕超时设置延迟生效

修复:
- 新增 ReadBookIntent.SetOrientation 意图,直接写入 ReadConfig 并发射 Effect
- 将 ReadBookIntent.KeepLightChanged 改为带值的 data class,同理直接生效
- MoreConfigSheet 在写 DataStore 的同时同步调用 onIntent,立即应用变更
- 新增反向横屏(REVERSE_LANDSCAPE)选项
This commit is contained in:
HapeLee committed 2026-06-11 01:36:06 +08:00
1 parent 7d333f8b6c
commit aa16376dae
8 files changed
+19 -2

No files matched your search

@@ -1193,6 +1193,7 @@
<string name="keep_enable">保留启用状态</string>
<string name="preview_image_by_click">点击预览图片</string>
<string name="screen_portrait_reversed">反向竖屏</string>
<string name="screen_landscape_reversed">反向橫屏</string>
<string name="del_ruby_tag">删除ruby标签</string>
<string name="del_h_tag">删除h标签</string>
<string name="adjust_chapter_page">调整本章页数</string>