切换导航条
切换导航条
当前项目
正在载入...
登录
术习电报
/
electron-vue-template
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
构建
提交
问题看板
文件
提交
网络
比较
分支
标签
作者
张恒
2020-01-13 16:33:05 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
提交
71e1cb963c5e5a55a75e1ac4d20de8aa4d7891c7
71e1cb96
1 个父辈
051d300a
修正错误字以及更新依赖
显示空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
33 行增加
和
33 行删除
package-lock.json
package.json
src/main/services/checkupdate.js
src/main/services/downloadFile.js
src/main/services/windowManager.js
src/renderer/components/LandingPage.vue
package-lock.json
查看文件 @
71e1cb9
此文件的差异太大,无法显示。
package.json
查看文件 @
71e1cb9
...
...
@@ -84,28 +84,28 @@
"vuex-electron"
:
"^1.0.3"
},
"devDependencies"
:
{
"@babel/core"
:
"^7.
7.5
"
,
"@babel/plugin-proposal-class-properties"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-decorators"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-do-expressions"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-export-default-from"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-export-namespace-from"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-function-bind"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-function-sent"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-json-strings"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-logical-assignment-operators"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-nullish-coalescing-operator"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-numeric-separator"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-optional-chaining"
:
"^7.
7.5
"
,
"@babel/plugin-proposal-pipeline-operator"
:
"^7.
7.4
"
,
"@babel/plugin-proposal-throw-expressions"
:
"^7.
7.4
"
,
"@babel/plugin-syntax-dynamic-import"
:
"^7.
7.4
"
,
"@babel/plugin-syntax-import-meta"
:
"^7.
7.4
"
,
"@babel/plugin-transform-runtime"
:
"^7.
7.6
"
,
"@babel/polyfill"
:
"^7.
7
.0"
,
"@babel/preset-env"
:
"^7.
7.6
"
,
"@babel/register"
:
"^7.
7.4
"
,
"@babel/runtime"
:
"^7.
7.6
"
,
"@babel/core"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-class-properties"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-decorators"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-do-expressions"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-export-default-from"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-export-namespace-from"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-function-bind"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-function-sent"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-json-strings"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-logical-assignment-operators"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-nullish-coalescing-operator"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-numeric-separator"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-optional-chaining"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-pipeline-operator"
:
"^7.
8.0
"
,
"@babel/plugin-proposal-throw-expressions"
:
"^7.
8.0
"
,
"@babel/plugin-syntax-dynamic-import"
:
"^7.
8.0
"
,
"@babel/plugin-syntax-import-meta"
:
"^7.
8.0
"
,
"@babel/plugin-transform-runtime"
:
"^7.
8.0
"
,
"@babel/polyfill"
:
"^7.
8
.0"
,
"@babel/preset-env"
:
"^7.
8.2
"
,
"@babel/register"
:
"^7.
8.0
"
,
"@babel/runtime"
:
"^7.
8.0
"
,
"ajv"
:
"^6.10.2"
,
"babel-eslint"
:
"^9.0.0"
,
"babel-loader"
:
"^8.0.6"
,
...
...
@@ -115,7 +115,7 @@
"clean-webpack-plugin"
:
"^3.0.0"
,
"copy-webpack-plugin"
:
"^5.1.1"
,
"cross-env"
:
"^6.0.3"
,
"css-loader"
:
"^3.4.
1
"
,
"css-loader"
:
"^3.4.
2
"
,
"del"
:
"^5.1.0"
,
"electron"
:
"^7.1.8"
,
"electron-builder"
:
"^21.2.0"
,
...
...
@@ -125,7 +125,7 @@
"eslint-friendly-formatter"
:
"^4.0.1"
,
"eslint-loader"
:
"^3.0.3"
,
"eslint-plugin-html"
:
"^6.0.0"
,
"eslint-plugin-import"
:
"^2.
19.1
"
,
"eslint-plugin-import"
:
"^2.
20.0
"
,
"eslint-plugin-node"
:
"^9.2.0"
,
"eslint-plugin-promise"
:
"^4.2.1"
,
"eslint-plugin-standard"
:
"^4.0.0"
,
...
...
@@ -137,11 +137,11 @@
"node-loader"
:
"^0.6.0"
,
"node-sass"
:
"^4.13.0"
,
"portfinder"
:
"^1.0.25"
,
"sass-loader"
:
"^8.0.
0
"
,
"sass-loader"
:
"^8.0.
1
"
,
"split2"
:
"^3.1.1"
,
"style-loader"
:
"^1.1.2"
,
"svg-sprite-loader"
:
"^4.1.6"
,
"terser-webpack-plugin"
:
"^2.3.
1
"
,
"terser-webpack-plugin"
:
"^2.3.
2
"
,
"through2-filter"
:
"^3.0.0"
,
"url-loader"
:
"^3.0.0"
,
"vue-html-loader"
:
"^1.2.4"
,
...
...
src/main/services/checkupdate.js
查看文件 @
71e1cb9
import
{
autoUpdater
}
from
'electron-updater'
import
{
ipcMain
}
from
'electron'
/**
* -1 检查更新失败 0 正在检查更新 1 检测到新版本,准备下载 2 未检测到新版本 3 下载中 4 下载
暂停 5 下载暂停恢复 6 下载完成 7 下载失败 8 取消下载
*
*/
* -1 检查更新失败 0 正在检查更新 1 检测到新版本,准备下载 2 未检测到新版本 3 下载中 4 下载
完成
**/
function
Message
(
mainWindow
,
type
,
data
)
{
const
senddata
=
{
state
:
type
,
...
...
src/main/services/downloadFile.js
查看文件 @
71e1cb9
...
...
@@ -21,7 +21,7 @@ if (os.platform().includes('win32')) {
}
export
default
{
download
(
mainWindow
)
{
ipcMain
.
on
(
's
at
rt-download'
,
(
event
,
msg
)
=>
{
ipcMain
.
on
(
's
ta
rt-download'
,
(
event
,
msg
)
=>
{
mainWindow
.
webContents
.
downloadURL
(
msg
.
downloadUrL
||
defaultDownloadUrL
)
event
.
reply
(
'confirm-download'
,
true
)
mainWindow
.
webContents
.
session
.
on
(
'will-download'
,
(
event
,
item
,
webContents
)
=>
{
...
...
src/main/services/windowManager.js
查看文件 @
71e1cb9
...
...
@@ -21,7 +21,7 @@ const loadingURL = process.env.NODE_ENV === 'development' ? `http://localhost:${
var
loadWindow
=
null
var
mainWindow
=
null
function
createMainWindow
()
{
function
createMainWindow
()
{
/**
* Initial window options
*/
...
...
@@ -83,7 +83,7 @@ function createMainWindow() {
})
}
function
loadindWindow
()
{
function
loadindWindow
()
{
loadWindow
=
new
BrowserWindow
({
width
:
400
,
height
:
600
,
...
...
@@ -106,7 +106,7 @@ function loadindWindow() {
})
}
function
initWindow
()
{
function
initWindow
()
{
if
(
config
.
UseStartupChart
)
{
return
loadindWindow
()
}
else
{
...
...
src/renderer/components/LandingPage.vue
查看文件 @
71e1cb9
...
...
@@ -179,7 +179,7 @@ export default {
break;
case "two":
console.log(111);
ipcApi.send("s
at
rt-download");
ipcApi.send("s
ta
rt-download");
ipcApi.on("confirm-download", (event, arg) => {
if (arg) {
this.dialogVisible = true;
...
...
请
注册
或
登录
后发表评论