Bring PS5 GTA6 to 120FPS with DLSS 5. An advanced Windows video player and capture enhancement tool featuring real-time preview for videos, images, and capture card sources. Combine AI-powered Super Resolution, DLSS5 image enhancement, and Frame Generation to deliver a next-generation visual experience.
C++
feat(ui-mig): G2.1 dock hot zone works over the playing picture
Veyra Goal Agent3d910c44d27c
diff --git a/apps/veyra-qml/main.cpp b/apps/veyra-qml/main.cppindex 1b203fb2..346b7285 100644--- a/apps/veyra-qml/main.cpp+++ b/apps/veyra-qml/main.cpp@@ -43,6 +43,9 @@ LRESULT CALLBACK videoProc(HWND h, UINT m, WPARAM w, LPARAM l) {// swapchains fight and we lose the whole point of the native path.if (m == WM_ERASEBKGND) return 1;if (m == WM_PAINT) { ValidateRect(h, nullptr); return 0; }+ // The pointer belongs to the QML layer under the picture (the dock's hot zone+ // at the top edge, the cinema controls): pass hit testing through to it.+ if (m == WM_NCHITTEST) return HTTRANSPARENT;return DefWindowProcW(h, m, w, l);}diff --git a/docs/UI_FULL_GOAL_PLAN_2026-09-26.md b/docs/UI_FULL_GOAL_PLAN_2026-09-26.mdindex b0049639..26950d67 100644--- a/docs/UI_FULL_GOAL_PLAN_2026-09-26.md+++ b/docs/UI_FULL_GOAL_PLAN_2026-09-26.md@@ -11,7 +11,7 @@|---|---|---|---|| G0 工具与基线 | 完成 | checkpoint/ui-mig-g0.7 | 设计参考 `design-ref/`、对比 `compare/`、动效曲线 `goal/g0.5/`、缓动测试 `veyra_qml_easing_tests`(构建目录 `build/qt-probe-20260926`)、门槛基线 `goal/g0.7/`(B 阶段性能对比用 `goal/g0.7/perf`) || G1 基础(缓动/背景/字体/图标/组件动效) | 完成 | checkpoint/ui-mig-g1.6 | G1.1–G1.6 完成(Qt 6.8.3:BezierSpline ≤10 段;CurveRenderer 不能用 fillItem;可变字体 600 须设 wght 轴;Popup 无 transform;视频子窗用 videoCover 挖区);动效探针 dock/page/switch/seg/menu/dialog;Quick Test 8/8;M28/M29 曲线未执行;下一步 G2 |-| G2 外壳 | 未开始 | | |+| G2 外壳 | 进行中 | checkpoint/ui-mig-g2.1 | G2.1 dock 热区(视频子窗 HTTRANSPARENT、dock 挖区、450ms 收起,hover-shot.ps1 真实光标证据);下一步 G2.2 页面切换 || G3 四主屏 | 未开始 | | || B1 小项 + 桥接补齐 | 未开始 | | || B2 导出补齐(S2.5) | 未开始 | | |diff --git a/docs/WORKLOG.md b/docs/WORKLOG.mdindex 95731909..2ce5d213 100644--- a/docs/WORKLOG.md+++ b/docs/WORKLOG.md@@ -6641,3 +6641,10 @@ release. 5090 live acceptance, 15-second hitch and user flicker remain unresolve- 命令:`powershell -NoProfile -File tools/qt_probe/run-quick-tests.ps1 -Out E:\项目\Veyra\logs\ui-qml-migration-20260925\goal\g1.6-quick-tests.txt`。- 结果:8 passed, 0 failed(含 init/cleanup)。首次运行 test_slider_tap 计数为 2,原因是前一个拖动用例也发 moved,已在各用例开头 clear。- 脚本内 QtTest 控制台输出经管道丢失,改为 `-o <file>,txt` 再读文件。+- G2.1 顶部 dock 热区(`checkpoint/ui-mig-g2.1`,证据 `goal/g2.1/`):+ - 原问题:播放时原生视频子窗压在 QML 之上并吃掉鼠标,顶部 12px 热区在画面上无效。+ - 修正:视频子窗 `WM_NCHITTEST` 返回 `HTTRANSPARENT`,指针交给下面的 QML;dock 本体设为 videoCover(圆角 = 高/2),画面上方可见。+ - 收起逻辑对齐 core.js:离开热区且不在 dock 上 → 450ms 收起;进入热区/手柄/dock 取消计时。+ - 新脚本 `tools/qt_probe/hover-shot.ps1`:带片源启动、置顶、真实移动光标、逐步 PrintWindow。+ - 实测(visible-scene.mp4,极简页):中部无 dock → 顶边 4px 弹出 → 悬停专业模式出提示 → 移开 200ms 仍在 → 900ms 已收起(strip.png)。+ - 未执行:固定模式在播放中的截图(x-tip 已覆盖无片源情形)。diff --git a/qml/Veyra/TopDock.qml b/qml/Veyra/TopDock.qmlindex 68edabb9..b9dab5a1 100644--- a/qml/Veyra/TopDock.qml+++ b/qml/Veyra/TopDock.qml@@ -44,7 +44,8 @@ Item {anchors.left: parent.leftanchors.right: parent.rightheight: 12- HoverHandler { onHoveredChanged: if (hovered) dockRoot.opened = true }+ // Leaving the zone for anywhere but the dock retracts it (closeDock).+ HoverHandler { onHoveredChanged: if (hovered) dockRoot.open(); else if (!barHover.hovered) retract.restart() }}Rectangle {id: handle@@ -58,16 +59,16 @@ Item {opacity: dockRoot.opened ? 0 : 1Behavior on width { NumberAnimation { duration: Theme.d(400); easing.bezierCurve: Theme.spring } }Behavior on opacity { NumberAnimation { duration: Theme.d(200) } }- HoverHandler { onHoveredChanged: if (hovered) dockRoot.opened = true }+ HoverHandler { onHoveredChanged: if (hovered) dockRoot.open() }}+ function open() { retract.stop(); opened = true }// Retract 450ms after the pointer leaves, exactly like closeDock().Timer {id: retractinterval: 450onTriggered: if (!dockRoot.pinned) dockRoot.opened = false}- onOpenedChanged: if (!opened) ; else retract.stop()// .dock: black pill, radius 999, 1px hairline, heavy drop shadow.Rectangle {@@ -81,16 +82,17 @@ Item {color: "#000000"border.width: 1border.color: Qt.rgba(1, 1, 1, 0.1)+ // Over the picture on the cinema page: cut out of the video window.+ objectName: "videoCover"+ property real coverRadius: height / 2// .dock { transform: translate(-50%,-120%); transition: transform .55s spring }Behavior on anchors.topMargin {NumberAnimation { duration: Theme.d(550); easing.bezierCurve: Theme.spring }}HoverHandler {- onHoveredChanged: {- if (hovered) { dockRoot.opened = true; retract.stop() }- else retract.restart()- }+ id: barHover+ onHoveredChanged: if (hovered) dockRoot.open(); else retract.restart()}RowLayout {diff --git a/tools/qt_probe/hover-shot.ps1 b/tools/qt_probe/hover-shot.ps1new file mode 100644index 00000000..68534414--- /dev/null+++ b/tools/qt_probe/hover-shot.ps1@@ -0,0 +1,72 @@+# Pointer-driven review shot: launches the app (optionally with a clip), brings it to+# the front, walks the cursor through the given window-relative points and captures+# after each step. Hover state needs a real pointer, which the other shot scripts do+# not have; this is what exercises the dock's hot zone over a playing picture.+param(+ [string]$App = 'E:\项目\Veyra\tests\ui-qml-migration-20260925\qml-app',+ [string]$Page = 'min',+ [string]$Clip = '',+ [string]$Out = 'E:\项目\Veyra\logs\ui-qml-migration-20260925\hover',+ [string]$Extra = '',+ # "x,y,name[,waitMs]" per step, steps separated by ';', window-relative pixels. One+ # string: powershell -File does not split an array argument.+ [string]$Steps = '640,4,top',+ [int]$WaitSeconds = 8+)+Add-Type -AssemblyName System.Drawing+Add-Type @"+using System;using System.Runtime.InteropServices;+public class HW {+ [DllImport("user32.dll")] static extern bool EnumWindows(EnumProc f, IntPtr p);+ [DllImport("user32.dll")] static extern uint GetWindowThreadProcessId(IntPtr h, out uint pid);+ [DllImport("user32.dll")] public static extern bool IsWindowVisible(IntPtr h);+ [DllImport("user32.dll")] public static extern bool GetWindowRect(IntPtr h, out RECT r);+ [DllImport("user32.dll")] public static extern bool PrintWindow(IntPtr h, IntPtr dc, uint flags);+ [DllImport("user32.dll")] public static extern bool SetCursorPos(int x, int y);+ [DllImport("user32.dll")] public static extern bool SetWindowPos(IntPtr h, IntPtr after, int x, int y, int cx, int cy, uint f);+ [DllImport("user32.dll")] public static extern bool SetForegroundWindow(IntPtr h);+ delegate bool EnumProc(IntPtr h, IntPtr p);+ [StructLayout(LayoutKind.Sequential)] public struct RECT { public int Left, Top, Right, Bottom; }+ public static IntPtr Largest(uint want) {+ IntPtr best = IntPtr.Zero; long area = 0;+ EnumWindows((h, p) => {+ uint pid; GetWindowThreadProcessId(h, out pid);+ if (pid != want || !IsWindowVisible(h)) return true;+ RECT r; if (!GetWindowRect(h, out r)) return true;+ long a = (long)(r.Right - r.Left) * (r.Bottom - r.Top);+ if (a > area) { area = a; best = h; }+ return true;+ }, IntPtr.Zero);+ return best;+ }+}+"@+New-Item -ItemType Directory -Force $Out | Out-Null+$launch = @('--page', $Page)+if ($Extra -ne '') { $launch += ($Extra -split '\s+' | Where-Object { $_ -ne '' }) }+if ($Clip -ne '') { $launch += ('"' + $Clip + '"') }+$p = Start-Process -FilePath (Join-Path $App 'veyra_qml_ui.exe') -ArgumentList $launch -PassThru+Start-Sleep -Seconds $WaitSeconds+if ($p.HasExited) { "the app exited early"; exit 1 }+$h = [HW]::Largest([uint32]$p.Id)+if ($h -eq [IntPtr]::Zero) { "no window"; Stop-Process -Id $p.Id -Force; exit 1 }+# Topmost for the duration, so the terminal cannot sit over the hot zone.+[HW]::SetWindowPos($h, [IntPtr](-1), 0, 0, 0, 0, 0x0003) | Out-Null+[HW]::SetForegroundWindow($h) | Out-Null+$r = New-Object HW+RECT+foreach ($s in ($Steps -split ';')) {+ $x, $y, $name, $ms = $s -split ','+ if (-not $ms) { $ms = 900 }+ [HW]::GetWindowRect($h, [ref]$r) | Out-Null+ [HW]::SetCursorPos($r.Left + [int]$x, $r.Top + [int]$y) | Out-Null+ Start-Sleep -Milliseconds ([int]$ms)+ [HW]::GetWindowRect($h, [ref]$r) | Out-Null+ $w = $r.Right - $r.Left; $ht = $r.Bottom - $r.Top+ $bmp = New-Object System.Drawing.Bitmap $w, $ht+ $g = [System.Drawing.Graphics]::FromImage($bmp)+ $dc = $g.GetHdc(); [HW]::PrintWindow($h, $dc, 2) | Out-Null; $g.ReleaseHdc($dc)+ $file = Join-Path $Out ("hover-$name.png")+ $bmp.Save($file, [System.Drawing.Imaging.ImageFormat]::Png); $g.Dispose(); $bmp.Dispose()+ "saved $file (${w}x${ht})"+}+Stop-Process -Id $p.Id -Force -ErrorAction SilentlyContinue