Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
energye
energy
提交
95823763
energy
项目概览
energye
/
energy
通知
13
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
energy
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
95823763
编写于
6月 05, 2023
作者:
yanghye
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
up: check update demo
上级
cfb24425
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
27 addition
and
14 deletion
+27
-14
example/browser-lib-checkupdate/demo_windows_386.syso
example/browser-lib-checkupdate/demo_windows_386.syso
+0
-0
example/browser-lib-checkupdate/demo_windows_amd64.syso
example/browser-lib-checkupdate/demo_windows_amd64.syso
+0
-0
example/browser-lib-checkupdate/main.go
example/browser-lib-checkupdate/main.go
+23
-14
example/browser-lib-checkupdate/resources/btn-cancel.png
example/browser-lib-checkupdate/resources/btn-cancel.png
+0
-0
example/browser-lib-checkupdate/resources/btn-update.png
example/browser-lib-checkupdate/resources/btn-update.png
+0
-0
example/browser-lib-checkupdate/resources/locale.en-US.json
example/browser-lib-checkupdate/resources/locale.en-US.json
+2
-0
example/browser-lib-checkupdate/resources/locale.zh-CN.json
example/browser-lib-checkupdate/resources/locale.zh-CN.json
+2
-0
未找到文件。
example/browser-lib-checkupdate/demo_windows_386.syso
0 → 100644
浏览文件 @
95823763
文件已添加
example/browser-lib-checkupdate/demo_windows_amd64.syso
0 → 100644
浏览文件 @
95823763
文件已添加
example/browser-lib-checkupdate/main.go
浏览文件 @
95823763
...
...
@@ -193,22 +193,31 @@ func main() {
updateContent
.
Lines
()
.
Add
(
downUrl
)
//
ok
:=
lcl
.
NewButton
(
m
.
UpdatePromptPanel
)
ok
.
SetParent
(
m
.
UpdatePromptPanel
)
ok
.
SetCaption
(
"提示"
)
ok
.
SetOnClick
(
func
(
sender
lcl
.
IObject
)
{
fmt
.
Println
(
"提示"
)
m
.
UpdatePromptPanel
.
SetVisible
(
false
)
m
.
UpdateProgressPanel
.
SetVisible
(
true
)
cancelBtn
:=
lcl
.
NewImageButton
(
m
)
cancelBtn
.
SetParent
(
m
)
cancelBtn
.
SetImageCount
(
3
)
cancelBtn
.
SetAutoSize
(
true
)
cancelBtn
.
SetCursor
(
types
.
CrHandPoint
)
cancelBtn
.
Picture
()
.
LoadFromFSFile
(
"resources/btn-cancel.png"
)
cancelBtn
.
SetLeft
(
300
)
cancelBtn
.
SetTop
(
290
)
cancelBtn
.
SetHint
(
i18n
.
Resource
(
"cancel"
))
cancelBtn
.
SetOnClick
(
func
(
lcl
.
IObject
)
{
fmt
.
Println
(
"cancel"
)
})
process
:=
lcl
.
NewButton
(
m
.
UpdateProgressPanel
)
process
.
SetParent
(
m
.
UpdateProgressPanel
)
process
.
SetCaption
(
"进度"
)
process
.
SetOnClick
(
func
(
sender
lcl
.
IObject
)
{
fmt
.
Println
(
"进度"
)
m
.
UpdatePromptPanel
.
SetVisible
(
true
)
m
.
UpdateProgressPanel
.
SetVisible
(
false
)
//
updateBtn
:=
lcl
.
NewImageButton
(
m
)
updateBtn
.
SetParent
(
m
)
updateBtn
.
SetImageCount
(
3
)
updateBtn
.
SetAutoSize
(
true
)
updateBtn
.
SetCursor
(
types
.
CrHandPoint
)
updateBtn
.
Picture
()
.
LoadFromFSFile
(
"resources/btn-update.png"
)
updateBtn
.
SetLeft
(
400
)
updateBtn
.
SetTop
(
290
)
updateBtn
.
SetHint
(
i18n
.
Resource
(
"update"
))
updateBtn
.
SetOnClick
(
func
(
lcl
.
IObject
)
{
fmt
.
Println
(
"update"
)
})
}
// run and create update form
...
...
example/browser-lib-checkupdate/resources/btn-cancel.png
0 → 100644
浏览文件 @
95823763
4.1 KB
example/browser-lib-checkupdate/resources/btn-update.png
0 → 100644
浏览文件 @
95823763
4.6 KB
example/browser-lib-checkupdate/resources/locale.en-US.json
浏览文件 @
95823763
{
"title"
:
"liblcl Update"
,
"close"
:
"close"
,
"cancel"
:
"cancel"
,
"update"
:
"update"
,
"updateContent"
:
"Update Content"
,
"downloadURL"
:
"Update URL"
}
\ No newline at end of file
example/browser-lib-checkupdate/resources/locale.zh-CN.json
浏览文件 @
95823763
{
"title"
:
"liblcl更新"
,
"close"
:
"关闭"
,
"cancel"
:
"取消"
,
"update"
:
"更新"
,
"updateContent"
:
"更新内容"
,
"downloadURL"
:
"更新地址"
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录