This commit is contained in:
QIDI TECH
2024-09-03 09:34:33 +08:00
parent 27f34aa3e8
commit 585146181b
5147 changed files with 1734881 additions and 0 deletions

137
resources/web/guide/6/6.css Normal file
View File

@@ -0,0 +1,137 @@
*
{
padding: 0;
border: 0;
margin: 0;
font-family: "system-ui", "Segoe UI", Roboto, Oxygen, Ubuntu, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-sans;
}
html,body
{
font-size: 14px;
height:100%;
}
.LinkBtn
{
color: #1200FF;
cursor: pointer;
}
.LinkBtn:hover
{
text-decoration:underline;
}
.Btn_Green
{
padding: 1.5mm 6mm;
font-size: 14px;
text-align: center;
background-color: #4479FB; /* y96 */
border-radius: 6px;
color: #fff;
cursor: pointer;
display: inline-block;
border: 1px solid #4479FB; /* y96 */
}
.Btn_Green:hover
{
background-color: #4479FB; /* y96 */
}
#DownBlock
{
height: 60%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
#DownArea
{
width:80%;
height: 50%;
line-height: 50px;
display: inline;
}
#DownText
{
display: flex;
align-items: center;
}
#RetryBtn
{
background-image:url("restart.png");
background-size: 100% 100%;
width: 20px;
height: 20px;
margin-left: 20px;
display: none;
}
#DownPercent
{
height:20px;
}
#PercentBkg
{
height:20px;
background-color:#CFCFCF;
border-radius: 20px;
}
#PercentTip
{
float: left;
height:20px;
width: 0%;
background-color:#4479FB;
border-radius: 20px;
}
#DownSuccessTip
{
width:80%;
display: none;
text-align: center;
}
#InstallFailedTip
{
display:none;
height: auto;
}
/*------Btn Area------*/
#BtnBlock
{
height:40%;
display: flex;
justify-content: center;
align-items: center;
}
#CancelBtn
{
display: inline;
}
#RestartBtn
{
display: none;
}
#CloseBtn
{
display: none;
}

167
resources/web/guide/6/6.js Normal file
View File

@@ -0,0 +1,167 @@
function OnInit()
{
//let strInput=JSON.stringify(cData);
//HandleStudio(strInput);
// let tVal={};
// tVal['status']=3;
// tVal['percent']=30;
//
// HandStatusPercent(tVal);
TranslatePage();
SendDownloadCmd();
}
function SendDownloadCmd()
{
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="Begin_Download_network_plugin";
SendWXMessage( JSON.stringify(tSend) );
}
function HandleStudio( pVal )
{
let strCmd=pVal['command'];
//alert(strCmd);
if(strCmd=='ShowStatusPercent')
{
HandStatusPercent(pVal['data']);
}
}
function HandStatusPercent( pVal )
{
let nStatus=pVal['status']*1;
let nPercent=pVal['percent'];
if(nStatus==0)
{
//正常下载
$('#DownStepText').attr("tid","t71");
$('#RetryBtn').hide();
$('#PercentTip').css("width",nPercent+'%');
}
else if(nStatus==1)
{
//下载失败 或 解压缩补丁包失败
$('#DownStepText').attr("tid","t72");
$('#PercentTip').css("width",0+'%');
$('#RetryBtn').show();
}
else if(nStatus==2)
{
//下载完成
$('#PercentTip').css("width",100+'%');
setTimeout("SendInstallPluginCmd()",100);
}
else if(nStatus==3)
{
//解压缩补丁包失败
$('#DownArea').hide();
$("#InstallFailedTip").show();
$('#CancelBtn').hide();
$('#RestartBtn').hide();
$('#CloseBtn').show();
}
else if(nStatus==4)
{
//安装补丁包完成
$('#DownArea').hide();
$('#DownSuccessTip').show();
$('#CancelBtn').hide();
$('#CloseBtn').hide();
$('#RestartBtn').show();
//pTimer=setInterval("RunInverse()",1000);
}
TranslatePage();
}
var nCount=3;
var pTimer=null;
function RunInverse()
{
$('#CountNumber').text(nCount+'');
nCount--;
if(nCount==-1)
{
RestartQIDIStudio();
}
}
function RetryDownload()
{
$('#DownStepText').attr("tid","t71");
$('#PercentTip').css("width",0+'%');
SendDownloadCmd();
}
function CancelDownload()
{
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="netplugin_download_cancel";
SendWXMessage( JSON.stringify(tSend) );
}
function SendInstallPluginCmd()
{
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="begin_install_plugin";
SendWXMessage( JSON.stringify(tSend) );
}
function RestartQIDIStudio()
{
if( pTimer!=null )
{
clearInterval(pTimer);
pTimer=null;
}
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="restart_studio";
SendWXMessage( JSON.stringify(tSend) );
}
function CloseDownDialog()
{
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="close_download_dialog";
SendWXMessage( JSON.stringify(tSend) );
}
function OpenPluginFolder()
{
var tSend={};
tSend['sequence_id']=Math.round(new Date() / 1000);
tSend['command']="open_plugin_folder";
SendWXMessage( JSON.stringify(tSend) );
}

View File

@@ -0,0 +1,48 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="Cache-Control" content="max-age=7200" />
<title>引导_P1</title>
<link rel="stylesheet" type="text/css" href="6.css" />
<script type="text/javascript" src="../js/jquery-2.1.1.min.js"></script>
<script type="text/javascript" src="../js/json2.js"></script>
<script type="text/javascript" src="../../data/text.js"></script>
<script type="text/javascript" src="../js/globalapi.js"></script>
<script type="text/javascript" src="../js/common.js"></script>
<script type="text/javascript" src="6.js"></script>
</head>
<body onLoad="OnInit()">
<div id="DownBlock">
<div id="DownArea">
<div id="DownText">
<div id="DownStepText" class="trans" tid="t71">Downloading</div>
<div id="RetryBtn" onClick="RetryDownload()"></div>
</div>
<div>
<div id="PercentTip"></div>
<div id="PercentBkg"></div>
</div>
</div>
<div id="DownSuccessTip" class="trans" tid="t73">Installation successful.</div>
<div id="InstallFailedTip">
<div><a class="trans" tid="t79">Failed to install plug-in. </a><a class="trans" tid="t80">Try the following steps:</a></div>
<div><a class="trans" tid="t81">1, Click </a><a class="trans LinkBtn" tid="t77" onClick="OpenPluginFolder()">here</a><a class="trans" tid="t82"> to open the plug-in directory</a> </div>
<div class="trans" tid="t83">2, Close all open QIDI Studio</div>
<div class="trans" tid="t84">3, Delete all files under the plug-in directory</div>
<div class="trans" tid="t85">4, Reopen QIDI studio and install the plug-in again</div>
</div>
</div>
<div id="BtnBlock">
<div id="CancelBtn" class="trans Btn_Green" tid="t38" onClick="CancelDownload()">Cancel</div>
<div id="RestartBtn" class="Btn_Green" onClick="RestartQIDIStudio()"><a class="trans" tid="t25">Finish</a></div>
<div id="CloseBtn" class="Btn_Green" onClick="CloseDownDialog()"><a class="trans" tid="t86">Close</a></div>
</div>
</body>
</html>

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB