From f77887bd02df50d52a0755c386c3a4e65b035955 Mon Sep 17 00:00:00 2001 From: weike Date: Thu, 20 Jun 2024 18:48:54 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9=E6=9C=AA=E5=AE=89=E8=A3=85?= =?UTF-8?q?=E6=88=90=E5=8A=9F=E6=97=B6,=E5=AE=89=E8=A3=85=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E5=B7=A6=E4=BE=A7=E5=9B=BE=E6=A0=87=E9=97=AE=E9=A2=98?= =?UTF-8?q?=202.=E6=B7=BB=E5=8A=A0=E6=BB=9A=E5=8A=A8=E6=9D=A1hover?= =?UTF-8?q?=E6=95=88=E6=9E=9C=203.=E4=BF=AE=E6=94=B9=E8=99=9A=E6=8B=9F?= =?UTF-8?q?=E6=9C=BA=E4=B8=AD=E8=B6=85=E5=87=BA=E7=95=8C=E9=9D=A2=E9=97=AE?= =?UTF-8?q?=E9=A2=98=204.=E4=BF=AE=E6=94=B9=E7=9B=B8=E5=85=B3=E5=90=8D?= =?UTF-8?q?=E7=A7=B0=E4=B8=BA=E5=BC=80=E5=8F=91=E7=8E=AF=E5=A2=83=E5=BF=AB?= =?UTF-8?q?=E9=80=9F=E9=83=A8=E7=BD=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../deploy/deployWindow-dev.html | 4 +-- .../electron-sandbox/deploy/deployWindow.html | 4 +-- .../deploy/deployWindowMain.ts | 22 +++++++++--- .../electron-sandbox/deploy/media/deploy.css | 34 ++++++++++++++----- .../issue/electron-main/deployMainService.ts | 3 ++ .../electron-sandbox/deploy.contribution.ts | 6 ++-- 6 files changed, 54 insertions(+), 19 deletions(-) diff --git a/src/vs/code/electron-sandbox/deploy/deployWindow-dev.html b/src/vs/code/electron-sandbox/deploy/deployWindow-dev.html index cd122bf5..695c430c 100644 --- a/src/vs/code/electron-sandbox/deploy/deployWindow-dev.html +++ b/src/vs/code/electron-sandbox/deploy/deployWindow-dev.html @@ -38,7 +38,7 @@
-
安装向导
+
开发环境快速部署
@@ -130,7 +130,7 @@
-
+

 								
diff --git a/src/vs/code/electron-sandbox/deploy/deployWindow.html b/src/vs/code/electron-sandbox/deploy/deployWindow.html index 51f98544..c765bb41 100644 --- a/src/vs/code/electron-sandbox/deploy/deployWindow.html +++ b/src/vs/code/electron-sandbox/deploy/deployWindow.html @@ -39,7 +39,7 @@
-
安装向导
+
开发环境快速部署
@@ -131,7 +131,7 @@
-
+

 								
diff --git a/src/vs/code/electron-sandbox/deploy/deployWindowMain.ts b/src/vs/code/electron-sandbox/deploy/deployWindowMain.ts index 5fca1b59..cc4cabda 100644 --- a/src/vs/code/electron-sandbox/deploy/deployWindowMain.ts +++ b/src/vs/code/electron-sandbox/deploy/deployWindowMain.ts @@ -163,6 +163,19 @@ class deployWindow { this.progressNum++; this.extInstallState.set(msg.depName, 15); } + else if (msg.type === "cancelinstall") { + console.log("receive: kylinide.installWizard.msg:cancelinstall"); + for (const [key, value] of this.extInstallState) { + if (key === undefined) { + console.log("cancel install: key is undefined"); + continue; + } + console.log("cancel install:" + key + " 状态:" + value); + if (value === 0 || value === 1) { + this.extInstallState.set(key, 4); + } + } + } let dTpreElement = document.getElementById("detailInstallPre"); dTpreElement!.innerHTML = ''; let dTformattedDoc = ''; @@ -256,7 +269,7 @@ class deployWindow { if (writeKeyJson.length > 0) { ipcRenderer.send("kylinide.installWizard.init", { type: "writeKey", keys: writeKeyJson }); } - showContext += "点击结束按钮退出安装向导\n" + showContext += "点击结束按钮退出开发环境快速部署\n" this.goFinish(showContext, false, true); console.log("安装结束:成功"); @@ -279,7 +292,7 @@ class deployWindow { if (msg.type == "cancelinstall") { let showContext = ''; showContext += "取消安装\n"; - showContext += "点击结束按钮退出安装向导\n" + showContext += "点击结束按钮退出开发环境快速部署\n" this.goFinish(showContext, false, false); console.log("安装结束:取消"); } @@ -289,7 +302,7 @@ class deployWindow { if (msg.type == "pkgNotAuth") { let showContext = ''; showContext += "授权失败,结束安装\n"; - showContext += "点击结束按钮退出安装向导\n" + showContext += "点击结束按钮退出开发环境快速部署\n" this.goFinish(showContext, true, false); console.log("安装结束:授权失败") } @@ -866,8 +879,9 @@ class deployWindow { if (document.getElementById('jsonSelectKey') !== null) { return; } - const preE = document.createElement('pre'); + const preE = document.createElement('div'); preE.id = "jsonSelectKey"; + preE.classList.add('jsonSelectKey'); let constent = ""; let flag = 0; for (let i = 0; i < jsonSelectKey.length; i++) { diff --git a/src/vs/code/electron-sandbox/deploy/media/deploy.css b/src/vs/code/electron-sandbox/deploy/media/deploy.css index 4a50fe22..abcf1dc0 100644 --- a/src/vs/code/electron-sandbox/deploy/media/deploy.css +++ b/src/vs/code/electron-sandbox/deploy/media/deploy.css @@ -664,6 +664,10 @@ button#prevStep:disabled { border-radius: 4px; } +::-webkit-scrollbar-thumb:hover { + background: #888888; +} + .osInfoShow { display: flex; flex-direction: column; @@ -712,6 +716,7 @@ button#prevStep:disabled { margin-top: 0px; margin-right: 20px; margin-bottom: 20px; + /* width: calc(100% - 40px); */ /* background-color: orange; */ } @@ -735,10 +740,25 @@ button#prevStep:disabled { background: rgba(0,0,0,0.7); } -.sceneChooseOutput { - overflow: auto; - padding-right: 12px; +.depOutputTextbox { + overflow-x: hidden; + overflow-y: auto; + margin-left: 20px; height: 325px; + /* border: 1px solid red; */ +} + +.depOutputTextbox>.jsonSelectKey { + font-family: SourceHanSansCN, SourceHanSansCN; + font-weight: 400; + font-size: 13px; + color: rgba(255,255,255,0.9); + line-height: 22px; + text-align: left; + font-style: normal; + margin-top: 6px; + margin-right: 12px; + margin-bottom: 0px; } .depOutputTextbox input[type="text"], @@ -746,7 +766,8 @@ button#prevStep:disabled { /* height: 330px; */ /* width: 600px; */ margin-left: 0px; - margin-top: 20px; + margin-top: 22px; + margin-right: 12px; background-color: transparent; border-width: 1px solid black; } @@ -794,10 +815,7 @@ button#prevStep:disabled { text-align: left; font-style: normal; margin-top: 0px; -} - -.depOutputTextbox { - margin-left: 20px; + margin-right: 12px; } #checkboxForm { diff --git a/src/vs/platform/issue/electron-main/deployMainService.ts b/src/vs/platform/issue/electron-main/deployMainService.ts index 3f63a1ad..dc7e7530 100644 --- a/src/vs/platform/issue/electron-main/deployMainService.ts +++ b/src/vs/platform/issue/electron-main/deployMainService.ts @@ -370,6 +370,7 @@ export class DeployMainService implements IDeployMainService { //结束插件下载及安装 if (this.DeployWindow) { this.DeployWindow.webContents.send("kylinide.installWizard.cancelInstall", { type: "cancelinstall" }); + this.DeployWindow.webContents.send("kylinide.installWizard.msg", { type: "cancelinstall" }); } } this.println('kill Exit code:', code); @@ -388,6 +389,7 @@ export class DeployMainService implements IDeployMainService { //结束插件下载及安装 if (this.DeployWindow) { this.DeployWindow.webContents.send("kylinide.installWizard.cancelInstall", { type: 'cancelinstall' }); + this.DeployWindow.webContents.send("kylinide.installWizard.msg", { type: "cancelinstall" }); } } } @@ -1106,6 +1108,7 @@ export class DeployMainService implements IDeployMainService { //授权失败,结束安装。 if (this.DeployWindow) { this.DeployWindow.webContents.send("kylinide.installWizard.Auth", { type: "pkgNotAuth" }); + this.DeployWindow.webContents.send("kylinide.installWizard.msg", { type: "cancelinstall" }); } } }); diff --git a/src/vs/workbench/contrib/issue/electron-sandbox/deploy.contribution.ts b/src/vs/workbench/contrib/issue/electron-sandbox/deploy.contribution.ts index 027df01e..04e5a4f8 100644 --- a/src/vs/workbench/contrib/issue/electron-sandbox/deploy.contribution.ts +++ b/src/vs/workbench/contrib/issue/electron-sandbox/deploy.contribution.ts @@ -19,8 +19,8 @@ class deployWindow extends Action2 { super({ id: deployWindow.ID, title: { - value: localize('deployWindow', "deploy window"), - mnemonicTitle: localize({ key: 'mideployWindow', comment: ['&& denotes a mnemonic'] }, "deploy window"), + value: localize('deployWindow', "打开开发环境快速部署"), + mnemonicTitle: localize({ key: 'mideployWindow', comment: ['&& denotes a mnemonic'] }, "打开开发环境快速部署"), original: 'DeployWindow' }, category: Categories.Help, @@ -39,7 +39,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarHelpMenu, { group: '2_reference', command: { id: deployWindow.ID, - title: localize({ key: 'mideployWindow', comment: ['&& denotes a mnemonic'] }, "deploy Window") + title: localize({ key: 'mideployWindow', comment: ['&& denotes a mnemonic'] }, "打开开发环境快速部署") }, order: 6 });