feat(ohos): window-ignore-cursor-events + adapter tests + print/https-scheme fixes - #71
feat(ohos): window-ignore-cursor-events + adapter tests + print/https-scheme fixes#71ljy9812 wants to merge 1 commit into
Conversation
Package Changes Through e4ddd4eThere are 11 changes which include tauri with minor, @tauri-apps/api with minor, tauri-build with minor, tauri-macos-sign with patch, tauri-bundler with minor, @tauri-apps/cli with minor, tauri-cli with minor, tauri-runtime with minor, tauri-runtime-wry with minor, tauri-utils with minor, tauri-plugin with minor Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
Code Review (babysit)✅ Clean — 0 Blocker, 0 Major
2 Minor noted (non-blocking): tungstenite dep, drag_drop_overlay field on cross-platform struct (default false, harmless). |
ljy9812
left a comment
There was a problem hiding this comment.
OHOS Code Review — tauri#71 (ohos-webview-drag-drop)
自审巡检(pr-babysit)。共 4 findings,0 🔴 Blocker,故为 COMMENT。
| 🔴 | 🟡 | 🔵 | ℹ️ |
|---|---|---|---|
| 0 | 1 | 2 | 1 |
- 🟡 F1
openspec/specs/ohos-webview-drag-drop/spec.md:49wire format 矛盾(见 inline)— 真实 bug,建议修 - 🔵 F2
changes/下 dialog-error 相关 change 未归档(proposal/tasks 缺失) - 🔵 F3 统计表标题与覆盖内容不一致
- ℹ️ F4 proposal 归档标注不完整(部分 task 状态未同步)
F1 经对抗性验证确认(line 49 说用 , 连接 paths_nul,与 line 26 定义 + line 32 示例的 \0 矛盾;含逗号路径会被 wry 侧 split('\0') 破坏——恰是 line 26 设计要避免的故障)。其余为文档卫生问题。
ljy9812
left a comment
There was a problem hiding this comment.
检视意见回复
已确认所有 4 个 findings 均已修复(commit a0bb8a6):
- F1: wire format 矛盾 - spec.md:49 已修正为 \0,与 line 26 定义 + line 32 示例一致
- F2: dialog-error 未归档 - ohos-dialog-error change 已归档至 openspec/changes/archive/2026-08-06-/
- F3: 统计表标题不一致 - manual_tests.md 统计表已给予独立 section 标题
- F4: proposal 归档标注不完整 - proposal.md 已添加状态+遗留项;tasks.md task 11 已标记 Deferred
无遗留问题,可以合并。
3-way merge of base (bd3b803) + PR head + upstream (c30d28b): - build.rs: keep both create_ohos_test_webview (PR) and create_ui_ability_window* (upstream) - run-app.json: keep both allow-create-ohos-test-webview and allow-create-ui-ability-window* permissions - TestRunner.svelte: keep both ohosAdapterTests (PR) and windowOpsTests/manualCreateUIAbilityWindow (upstream) - cmd.rs, lib.rs, core.ts, lib.rs(wry), webview_window.rs, module.json5, ohos-constraints.md: auto-merged Co-Authored-By: Claude <noreply@anthropic.com>
e59b60d to
130b85d
Compare
…-scheme fixes - window-ignore-cursor-events: tao set_ignore_cursor_events → openharmony_ability set_window_touchable bridge - ohos-adapter tests: drag-drop overlay, webview file drag-drop, print fix, https-scheme fix - create_ohos_test_webview command + manual test UI - tungstenite moved to main deps (cfg(desktop) custom cfg unresolvable by Cargo) - openspec change archives + specs Co-Authored-By: Claude <noreply@anthropic.com>
Summary
window-ignore-cursor-events (verified, archived)
set_ignore_cursor_events→set_window_touchable(!ignore)via TSFNACL fix
create_ohos_test_webviewwas rejected by ACL — added to app_manifest + run-app.jsonPrint fix (ohos-webview-print)
ohos.permission.PRINTin module.json5 templatesmanualOhosPrintcallswindow.print()(shim) notgetCurrentWebview().print()HTTPS scheme fix (ohos-webview-https-scheme)
with_https_scheme(was missing)isSecureContext+crypto.subtledrag_drop_overlay API (3-layer, cfg-gated)
drag_drop_overlayfield + builder + OHOS passthrough#[cfg(target_env = "ohos")]gates the API surface so non-OHOS platforms have no such field (6 sites)create_ohos_test_webviewcall site wrapped in cfg +let _ =suppressor on other platformswebview file drag-drop — COMPLETE (device-verified 2026-08-07) [NEW COMMIT]
file://<dropped file>→ ERR_ACCESS_DENIED → white screen (a kernel behavior desktop Tauri webviews do not have). The Web-level.onDropfires unreliably (ArkWeb preempts it) andsetResult(DRAG_SUCCESSFUL)is ineffective on the Web component. Resolution: afile://branch inonLoadInterceptreturns true to cancel the navigation (no white screen) and forwards the path via the drag-drop pipedrop|<path>|0,0. Whole webview becomes a drop zone, touch not blocked. Safe: Tauri OHOS loads via custom protocol (tauri:///https://<proto>.localhost) or inline html, neverfile://.paths_csv(comma) →paths_nul(\0-separated) so paths containing commas survive; both specs + plans updated with the device-verified result.openspec/changes/archive/2026-08-07-ohos-webview-drag-drop/.openspec
Real-device verification (API 23 desktop)
Test plan
🤖 Generated with Claude Code