升级 mygo 到 v0.7.4,删除弹窗标记不可逆按钮
v0.7.2 → v0.7.4 两个补丁版本。逐文件 diff 后确认无影响本项目的破坏性变更: paintBlock 的签名改动只影响自定义 decor,本项目没有实现。 - fileops.go:删除弹窗用上新的 DestructiveButtons,把「永久删除」标出来 - view.go:补注释说明 NoScrollPastEnd 在 v0.7.4 下仍然必要 - 评估报告记录升级验证过程与滚动条行为变化 验证:build/vet/gofmt 全绿,lsp 与 app 包 -count=1 全绿(含真 gopls 与 右键菜单的 ui.Tester 用例);另编了 v0.7.2 二进制做像素级对照,差异仅在 滚动条滑块是否常驻。
This commit is contained in:
1 parent
6b07d16738
commit
88067cc15c
7 files changed
+32
-1
No files matched your search
@@ -197,6 +197,10 @@ func (a *App) deletePaths(paths []string) {
|
||||
Buttons: []string{"移到回收站", "永久删除", "取消"},
|
||||
DefaultButton: btnTrash,
|
||||
CancelButton: btnCancel,
|
||||
// 告诉系统哪个按钮是不可逆的:macOS 11+ 会把它单独摆放,
|
||||
// 并且不让回车键顺手激活它。Windows 的 task dialog 没有这个概念,
|
||||
// 传了也不生效——所以在 Windows 上「默认按钮是回收站」才是保险的那道。
|
||||
DestructiveButtons: []int{btnPermanent},
|
||||
})
|
||||
if err != nil || res.Button == btnCancel {
|
||||
return
|
||||
|
||||
Reference in new issue
Block a user