TheDesk Akane (16.0.10)
This commit is contained in:
parent
8ed7796556
commit
8439aa3e05
|
@ -26,7 +26,7 @@
|
|||
<script type="text/javascript" src="./js/common/modal.js"></script>
|
||||
<script type="text/javascript" src="./js/ui/jquery-ui.min.js"></script>
|
||||
<script>
|
||||
var ver="Akane (16.0.9)";
|
||||
var ver="Akane (16.0.10)";
|
||||
//betaを入れるとバージョンチェックしない
|
||||
//GitHubに上げるときはindex.htmlをちゃんとする。(index.start.html)
|
||||
//var ver="beta";
|
||||
|
@ -522,21 +522,16 @@ var lang="{{lang}}";
|
|||
<a href="https://thedesk.top" target="_blank">HP</a><br>
|
||||
<a href="https://github.com/cutls/TheDesk" target="_blank">GitHub</a><br>
|
||||
<br>
|
||||
<div id="release-Akane_16-0-9" style="display:none">
|
||||
<div id="release-Akane_16-0-10" style="display:none">
|
||||
<a href="https://code.cutls.com/thedesk-log/" target="_blank">開発の経緯</a><br>
|
||||
<a href="https://ja.mstdn.wiki/TheDesk" target="_blank">機能一覧</a><br>
|
||||
Entyでは支援者様限定で様々なTheDeskに関する記事をご覧いただけます。
|
||||
<h5>Release Note Akane (16.0.9)</h5>
|
||||
<h5>Release Note Akane (16.0.10)</h5>
|
||||
16.0.9<br>
|
||||
<ul>
|
||||
<li>ログインできない問題を修正</li>
|
||||
<li>ストリーミングが切れることがある不具合を修正</li>
|
||||
<li>長文投稿時にCWが簡単に付く機能</li>
|
||||
<li>誰が通知アクションをしたかのミニアイコンを表示</li>
|
||||
<li>クリップボードへ複数枚の貼り付けに対応</li>
|
||||
<li>全てのMisskeyに全てのOSからログイン可能に</li>
|
||||
<li>friends.nicoのユーザー絵文字に対応</li>
|
||||
<li>バグ修正</li>
|
||||
<li>自動CWに関する不具合</li>
|
||||
<li>アップデートに関する不具合</li>
|
||||
<li>MisskeyのURLコピーに関する不具合</li>
|
||||
</ul>
|
||||
</div>
|
||||
<br><br>
|
||||
|
|
|
@ -65,4 +65,117 @@ function verck(ver) {
|
|||
}
|
||||
}
|
||||
});
|
||||
if(!localStorage.getItem("last-notice-id")){
|
||||
localStorage.setItem("last-notice-id",0)
|
||||
}
|
||||
console.log(localStorage.getItem("last-notice-id"))
|
||||
var start = "https://thedesk.top/notice?since_id="+localStorage.getItem("last-notice-id");
|
||||
console.log(start);
|
||||
fetch(start, {
|
||||
method: 'GET'
|
||||
}).then(function(response) {
|
||||
return response.json();
|
||||
}).catch(function(error) {
|
||||
todo(error);
|
||||
console.error(error);
|
||||
}).then(function(mess) {
|
||||
console.log(mess.length);
|
||||
if(mess.length<1){
|
||||
return false;
|
||||
}else{
|
||||
var last=localStorage.getItem("last-notice-id")
|
||||
localStorage.setItem("last-notice-id",mess[0].ID)
|
||||
for(i=0;i<mess.length;i++){
|
||||
var obj=mess[i];
|
||||
if(obj.ID*1<=last){
|
||||
break;
|
||||
}else{
|
||||
var show=true;
|
||||
if(obj.Toot!=""){
|
||||
var toot='<button class="btn-flat toast-action" onclick="detEx(\''+obj.Toot+'\',\'main\')">Show</button>';
|
||||
}else{
|
||||
var toot="";
|
||||
}
|
||||
if(obj.Ver!=""){
|
||||
if(obj.Ver==ver){
|
||||
show=true;
|
||||
}else{
|
||||
show=false;
|
||||
}
|
||||
}
|
||||
if(obj.Domain!=""){
|
||||
var multi = localStorage.getItem("multi");
|
||||
if (multi) {
|
||||
show=false;
|
||||
var accts = JSON.parse(multi);
|
||||
Object.keys(accts).forEach(function(key) {
|
||||
var acct = accts[key];
|
||||
if(acct.domain==obj.Domain){
|
||||
show=true;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
if(show){
|
||||
Materialize.toast(obj.Text+toot+'<span class="sml grey-text">(スライドして消去)</span>', 86400);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
infows = new WebSocket("wss://thedesk.top/ws/");
|
||||
infows.onopen = function(mess) {
|
||||
console.log(tlid + ":Connect Streaming Info:");
|
||||
console.log(mess);
|
||||
}
|
||||
infows.onmessage = function(mess) {
|
||||
console.log(":Receive Streaming:");
|
||||
console.log(JSON.parse(mess.data));
|
||||
var obj=JSON.parse(mess.data);
|
||||
if(obj.type!="counter"){
|
||||
if(obj.id*1<=localStorage.getItem("last-notice-id")){
|
||||
|
||||
}else{
|
||||
localStorage.setItem("last-notice-id",obj.id)
|
||||
var show=true;
|
||||
if(obj.toot!=""){
|
||||
var toot='<button class="btn-flat toast-action" onclick="detEx(\''+obj.toot+'\',\'main\')">Show</button>';
|
||||
}else{
|
||||
var toot="";
|
||||
}
|
||||
if(obj.ver!=""){
|
||||
if(obj.ver==ver){
|
||||
show=true;
|
||||
}else{
|
||||
show=false;
|
||||
}
|
||||
}
|
||||
if(obj.domain!=""){
|
||||
var multi = localStorage.getItem("multi");
|
||||
if (multi) {
|
||||
show=false;
|
||||
var accts = JSON.parse(multi);
|
||||
Object.keys(accts).forEach(function(key) {
|
||||
var acct = accts[key];
|
||||
if(acct.domain==obj.domain){
|
||||
show=true;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
if(show){
|
||||
Materialize.toast(obj.text+toot+'<span class="sml grey-text">(スライドして消去)</span>', 86400);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
infows.onerror = function(error) {
|
||||
console.error("Error closing:info");
|
||||
console.error(error);
|
||||
return false;
|
||||
};
|
||||
infows.onclose = function() {
|
||||
console.error("Closing:info");
|
||||
};
|
||||
}
|
|
@ -5,6 +5,7 @@
|
|||
localStorage.removeItem("kirishima")
|
||||
localStorage.removeItem("imas")
|
||||
localStorage.removeItem("image");
|
||||
localStorage.setItem("mode_misskey.xyz","misskey")
|
||||
function ck() {
|
||||
var main = localStorage.getItem("main");
|
||||
if(!main){
|
||||
|
|
|
@ -132,6 +132,7 @@ function icon(type) {
|
|||
}
|
||||
function todo(){}
|
||||
function todc(){}
|
||||
function hide(){}
|
||||
$(function($) {
|
||||
//キーボードショートカット
|
||||
$(window).keydown(function(e) {
|
||||
|
|
|
@ -26,7 +26,17 @@ function post(mode) {
|
|||
}
|
||||
}
|
||||
}
|
||||
if(mode!="pass" && !$("#cw").hasClass("cw-avail") && (str.length>localStorage.getItem("cw_sentence") || (str.split("\n").length - 1)>localStorage.getItem("cw_letters"))){
|
||||
if(!localStorage.getItem("cw_sentence")){
|
||||
var cw_sent=500;
|
||||
}else{
|
||||
var cw_sent=localStorage.getItem("cw_sentence");
|
||||
}
|
||||
if(!localStorage.getItem("cw_letters")){
|
||||
var cw_ltres=500;
|
||||
}else{
|
||||
var cw_ltres=localStorage.getItem("cw_letters");
|
||||
}
|
||||
if(mode!="pass" && !$("#cw").hasClass("cw-avail") && (str.length>cw_sent || (str.split("\n").length - 1)>cw_ltres)){
|
||||
var electron = require("electron");
|
||||
var remote=electron.remote;
|
||||
var dialog=remote.dialog;
|
||||
|
|
|
@ -640,8 +640,8 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) {
|
|||
dis_name +
|
||||
'</span><span class="sml gray" style="overflow: hidden;white-space: nowrap;text-overflow: ellipsis; cursor:text;"> @' +
|
||||
toot.user.username + '</span></div>' +
|
||||
'<div class="flex-time"><span class="cbadge cbadge-hover pointer waves-effect" onclick="tootUriCopy(\'' +
|
||||
toot.url + '\');" title="' + date(toot.createdAt, 'absolute') +
|
||||
'<div class="flex-time"><span class="cbadge cbadge-hover pointer waves-effect" onclick="tootUriCopy(\'https://' +domain+"/notes/"+
|
||||
toot.id + '\');" title="' + date(toot.createdAt, 'absolute') +
|
||||
'('+lang_parse_clickcopyurl[lang]+')"><i class="fa fa-clock-o"></i>' +
|
||||
date(toot.createdAt, datetype) + '</span>' +
|
||||
'</div></div>' +
|
||||
|
|
|
@ -31,9 +31,6 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
|||
var type = "local";
|
||||
}
|
||||
}
|
||||
/*
|
||||
|
||||
*/
|
||||
if (type == "mix" && localStorage.getItem("mode_" + domain)!="misskey") {
|
||||
//Integratedなら飛ばす
|
||||
$("#notice_" + tlid).text("Integrated TL(" + localStorage.getItem(
|
||||
|
|
|
@ -1,17 +1,15 @@
|
|||
{
|
||||
"updatehere":"Latest TheDesk",
|
||||
"nowver":"Current version",
|
||||
"afterdl":"TheDesk will be quit TheDesk after downloading.",
|
||||
"download":"Download",
|
||||
"winzip":"On Windows, TheDesk will self-unzip and launch the latest file. Durling unzippng, TheDesk may freeze. It takes several seconds.",
|
||||
"releasenote1":"Visit a releasenote of ",
|
||||
"releasenote2":"",
|
||||
"skipupd":"Skip this uodate",
|
||||
"nexttl":"until next TL loading",
|
||||
"nextver":"until next version",
|
||||
"endthedesk":"Quit",
|
||||
"about":"About TheDesk",
|
||||
"problem1":"Some problems? Please download on ",
|
||||
"problem2":"",
|
||||
"dlnow":"Downloading"
|
||||
"updatehere":"Get latest TheDesk",
|
||||
"download":"Start",
|
||||
"plusunzip":"Unzip(for Win)",
|
||||
"winzip":"Durling unzippng, TheDesk may freeze. It takes several seconds.",
|
||||
"unrewrite":"Not rewrite",
|
||||
"sureupd":"You may lose a cool experience!",
|
||||
"skipupd":"Skip this update",
|
||||
"nexttl":"Until next TL loading",
|
||||
"nextver":"Until next version",
|
||||
"problem1":"Some problems?",
|
||||
"problem2":"Please download on <a href=\"https://thedesk.top\">Oficial HP</a>.",
|
||||
"continue":"Continue updating",
|
||||
"dlnow":"Downloading..."
|
||||
}
|
|
@ -1,17 +1,15 @@
|
|||
{
|
||||
"updatehere":"アップデートがあります",
|
||||
"nowver":"現在のバージョン",
|
||||
"afterdl":"ダウンロード後は選択したフォルダが開きソフトは閉じられます。",
|
||||
"download":"ダウンロード",
|
||||
"winzip":"Windows環境の場合、自動で展開され起動します。展開時にTheDeskが固まることがありますが、しばらくお待ち下さい。",
|
||||
"releasenote1":"アップデート内容の詳細は",
|
||||
"releasenote2":"をご覧ください。",
|
||||
"skipupd":"このアップデートを飛ばす",
|
||||
"download":"開始",
|
||||
"plusunzip":"解凍も行う",
|
||||
"winzip":"zip展開時にTheDeskが固まることがありますが、しばらくお待ち下さい。",
|
||||
"unrewrite":"上書きしない",
|
||||
"sureupd":"アップデートは必ず行ってください",
|
||||
"skipupd":"アップデートをスキップする",
|
||||
"nexttl":"次回TL表示時まで",
|
||||
"nextver":"次のバージョンが出るまで",
|
||||
"endthedesk":"このソフトを終了",
|
||||
"about":"このソフトについて",
|
||||
"problem1":"アップデートに問題が生じる場合は",
|
||||
"problem2":"からのダウンロードをおためしください。",
|
||||
"problem1":"問題が発生しますか?",
|
||||
"problem2":"<a href=\"https://thedesk.top\">公式HP</a>からダウンロードをお試しください。",
|
||||
"continue":"アップデートを続行",
|
||||
"dlnow":"ダウンロード中"
|
||||
}
|
16
app/main.js
16
app/main.js
|
@ -296,6 +296,7 @@ ipc.on('shot-img-dl', (e, args) => {
|
|||
ipc.on('download-btn', (e, args) => {
|
||||
var platform=process.platform;
|
||||
var bit=process.arch;
|
||||
var versioning=args[3];
|
||||
if(platform=="win32" || platform=="linux" || platform=="darwin" ){
|
||||
if(platform=="win32" && bit=="x64"){
|
||||
var zip="TheDesk-win32-x64.zip";
|
||||
|
@ -308,7 +309,10 @@ ipc.on('download-btn', (e, args) => {
|
|||
}else if(platform=="darwin"){
|
||||
var zip="TheDesk-darwin-x64.zip";
|
||||
}else{
|
||||
retrun;
|
||||
return;
|
||||
}
|
||||
if(versioning){
|
||||
zip=zip.replace(".zip","."+args[1]+".zip");
|
||||
}
|
||||
}else{
|
||||
const options = {
|
||||
|
@ -328,6 +332,8 @@ ipc.on('download-btn', (e, args) => {
|
|||
}
|
||||
}
|
||||
var ver=args[1];
|
||||
var unzipper=args[2];
|
||||
|
||||
console.log(zip);
|
||||
if(args[0]=="true"){
|
||||
dialog.showSaveDialog(null, {
|
||||
|
@ -350,10 +356,10 @@ ipc.on('download-btn', (e, args) => {
|
|||
fs.unlink(savedFiles);
|
||||
}
|
||||
console.log(m[1]+":"+savedFiles)
|
||||
dl(ver,m[1],savedFiles);
|
||||
dl(unzipper,ver,m[1],savedFiles);
|
||||
});
|
||||
}else{
|
||||
dl(ver);
|
||||
dl(unzipper,ver);
|
||||
}
|
||||
|
||||
});
|
||||
|
@ -365,7 +371,7 @@ function isExistFile(file) {
|
|||
if(err.code === 'ENOENT') return false
|
||||
}
|
||||
}
|
||||
function dl(ver,files,fullname){
|
||||
function dl(unzipper,ver,files,fullname){
|
||||
console.log(files);
|
||||
var platform=process.platform;
|
||||
var bit=process.arch;
|
||||
|
@ -409,7 +415,7 @@ function dl(ver,files,fullname){
|
|||
'https://dl.thedesk.top/'+zip, opts)
|
||||
.then(dl => {
|
||||
updatewin.webContents.send('mess', "ダウンロードが完了しました。");
|
||||
if(platform=="win32"){
|
||||
if(unzipper && platform=="win32"){
|
||||
mainWindow.webContents.send('mess', "unzip");
|
||||
console.log(files+"/"+zip);
|
||||
fs.rename(files+"/"+zip, app.getPath("userData")+"/TheDesk-temp.zip", function (err) {
|
||||
|
|
|
@ -85,9 +85,18 @@ textarea {
|
|||
<input type="hidden" id="reply">
|
||||
<input type="hidden" id="media">
|
||||
<button class="btn" onclick="post()">Post</button>
|
||||
<script>
|
||||
if(localStorage.getItem("lang")){
|
||||
var lang=localStorage.getItem("lang");
|
||||
}else{
|
||||
var lang="ja";
|
||||
}
|
||||
</script>
|
||||
<script type="text/javascript" src="./js/lang/lang.js"></script>
|
||||
<script type="text/javascript" src="./js/lang/parse.lang.js"></script>
|
||||
<script src="https://twemoji.maxcdn.com/2/twemoji.min.js?2.7"></script>
|
||||
<script type="text/javascript" src="./js/post/post.js"></script>
|
||||
<script type="text/javascript" src="./js/post/reply.js"></script>
|
||||
<script type="text/javascript" src="./js/post/use-txtbox.js"></script>
|
||||
<script type="text/javascript" src="./js/tl/parse.js"></script>
|
||||
<script type="text/javascript" src="./js/ui/theme.js"></script>
|
||||
<script type="text/javascript" src="./js/tl/date.js"></script>
|
||||
|
@ -124,4 +133,10 @@ var multi = localStorage.getItem("multi");
|
|||
'</option>';
|
||||
$("#post-acct-sel").append(templete);
|
||||
});
|
||||
function mov(){
|
||||
return false;
|
||||
}
|
||||
function resetmv(){
|
||||
return false;
|
||||
}
|
||||
</script>
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "thedesk",
|
||||
"version": "16.0.9",
|
||||
"version": "16.0.10",
|
||||
"description": "TheDesk is a Mastodon client for PC.",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
|
|
145
app/update.html
145
app/update.html
|
@ -1,5 +1,5 @@
|
|||
<!doctype html>
|
||||
<html lang="ja">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Update - TheDesk</title>
|
||||
<link href="./css/materialize.css" type="text/css" rel="stylesheet">
|
||||
|
@ -8,57 +8,144 @@
|
|||
<meta charset="utf-8">
|
||||
</head>
|
||||
<body>
|
||||
<style>
|
||||
body{
|
||||
<style>
|
||||
body{
|
||||
font-family:'Open Sans';
|
||||
-webkit-app-region: drag;
|
||||
cursor: move;
|
||||
padding:10px;
|
||||
text-align:right;
|
||||
}
|
||||
a,button{
|
||||
#start{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width:100vw;
|
||||
height: calc(100vh - 2.5rem);
|
||||
text-align:center;
|
||||
}
|
||||
#checkbox{
|
||||
text-align:left;
|
||||
}
|
||||
a,button,input,label,i{
|
||||
-webkit-app-region: no-drag;
|
||||
}</style>
|
||||
}
|
||||
#updskip{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.skipbtn{
|
||||
display:block;
|
||||
float:left;
|
||||
width:200px;
|
||||
height:200px;
|
||||
border:1px solid;
|
||||
margin-left:5px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
border: 1px solid;
|
||||
overflow: hidden;
|
||||
}
|
||||
.skipbtn:hover{
|
||||
background-color: #b3e5fc;
|
||||
transition: all 0.3s ease-in-out;
|
||||
}
|
||||
#prog{
|
||||
font-size:200%;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript" src="./js/common/jquery.js"></script>
|
||||
<script type="text/javascript" src="./js/platform/first.js"></script>
|
||||
<script type="text/javascript" src="./js/common/materialize.js"></script>
|
||||
<h5>アップデートがあります[TheDesk <span id="ver"></span>]</h5>
|
||||
<span id="det"></span><br>
|
||||
現在のバージョン<span id="now"></span><br>
|
||||
ダウンロード後は選択したフォルダが開きソフトは閉じられます。<br>
|
||||
<button id="update" class="waves-effect btn" onclick="update('true')">ダウンロード</button>
|
||||
<p id="prog"></p>
|
||||
<div class="progress">
|
||||
<div class="determinate" style="width: 0%"></div>
|
||||
</div><br>
|
||||
<b>Windows環境の場合、自動で展開され起動します。展開時にTheDeskが固まることがありますが、しばらくお待ち下さい。</b><br>
|
||||
アップデート内容の詳細は<a href="https://github.com/cutls/TheDesk/blob/master/LATEST.md">GitHub</a>をご覧ください。<br><br>
|
||||
このアップデートを飛ばす(<a onclick="window.close();" class="pointer">次回TL表示時まで</a>/<a onclick="nextv();" class="pointer">次のバージョンが出るまで</a>)<br>
|
||||
<a onclick="quit()" class="pointer">このソフトを終了</a><br>
|
||||
<a onclick="about()" class="pointer">このソフトについて</a><br>
|
||||
アップデートに問題が生じる場合は<a href="https://thedesk.top">TheDesk HP</a>からのダウンロードをおためしください。
|
||||
<script type="text/javascript" src="./js/common/about.js"></script>
|
||||
<i class="material-icons pointer waves-effect" onclick="about();">info</i>
|
||||
<i class="material-icons pointer waves-effect" onclick="skipper();">clear</i>
|
||||
<!--a href="update.html">Reload</a-->
|
||||
<div id="start">
|
||||
<div id="box" class="show">
|
||||
<h2>TheDesk</h2>
|
||||
<p>アップデートがあります</p>
|
||||
<span id="now"></span>→<b id="ver"></b><br>
|
||||
<span id="det"></span><br>
|
||||
<button id="update" class="waves-effect btn" onclick="update('true')" style="margin-left:15px;">開始</button>
|
||||
<div id="checkbox">
|
||||
Options:<br>
|
||||
<input type="checkbox" class="filled-in" id="updator" value="true" onchange="alert('zip展開時にTheDeskが固まることがありますが、しばらくお待ち下さい。')" />
|
||||
<label for="updator">解凍も行う</label><br>
|
||||
<input type="checkbox" class="filled-in" id="rewrite" value="true" />
|
||||
<label for="rewrite">上書きしない</label><br>
|
||||
</div>
|
||||
問題が発生しますか?<br><a href="https://thedesk.top">公式HP</a>からダウンロードをお試しください。
|
||||
</div>
|
||||
<div id="skipper" class="hide">
|
||||
<h4>アップデートは必ず行ってください</h4>
|
||||
アップデートをスキップする<br>
|
||||
<div id="updskip">
|
||||
<a onclick="window.close();" class="pointer skipbtn waves-effect waves-light"><div>次回TL表示時まで</div></a>
|
||||
<a onclick="nextv();" class="pointer skipbtn waves-effect waves-light"><div>次のバージョンが出るまで</div></a>
|
||||
</div>
|
||||
<a class="pointer waves-effect" onclick="skipper();" style="margin-top:5px">アップデートを続行</a>
|
||||
</div>
|
||||
<div id="dlnow" class="hide">
|
||||
<h4>ダウンロード中</h4>
|
||||
<h4 id="prog"></h4>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" src="./js/common/about.js"></script>
|
||||
<script type="text/javascript" src="./js/platform/end.js"></script>
|
||||
<script>
|
||||
function skipper(){
|
||||
$("#dlnow").addClass("hide");
|
||||
$("#box").toggleClass("show");
|
||||
if($("#box").hasClass("hide") && $("#skipper").hasClass("hide")){
|
||||
$("#skipper").removeClass("hide");
|
||||
$("#skipper").addClass("show");
|
||||
}else{
|
||||
$("#box").toggleClass("hide");
|
||||
$("#skipper").toggleClass("hide");
|
||||
$("#skipper").toggleClass("show");
|
||||
}
|
||||
}
|
||||
var electron = require("electron");
|
||||
var ipc = electron.ipcRenderer;
|
||||
verck();
|
||||
function update(sel){
|
||||
$("#prog").text("");
|
||||
ipc.send('download-btn', [sel,enc(localStorage.getItem("next-ver"))]);
|
||||
function update(sel){
|
||||
$("#box").toggleClass("show");
|
||||
$("#box").toggleClass("hide");
|
||||
$("#dlnow").toggleClass("hide");
|
||||
$("#dlnow").toggleClass("show");
|
||||
$("#prog").text("");
|
||||
if($('#rewrite:checked').val()=="true"){
|
||||
var versioning=true;
|
||||
}else{
|
||||
var versioning=false;
|
||||
}
|
||||
if($('#updator:checked').val()=="true"){
|
||||
var zip=true;
|
||||
}else{
|
||||
var zip=false;
|
||||
}
|
||||
ipc.send('download-btn', [sel,enc(localStorage.getItem("next-ver")),zip,versioning]);
|
||||
}
|
||||
function quit(){
|
||||
ipc.send('quit', 'go');
|
||||
}
|
||||
ipc.on('prog', function (event, arg) {
|
||||
console.log(arg);
|
||||
$(".determinate").css('width',arg*100+"%");
|
||||
$("#prog").text("ダウンロード中:"+Math.floor(arg*100)+"%");
|
||||
console.log(arg);
|
||||
$("body").css('background','linear-gradient(#fff 0%,#fff '+(1-arg)*100+'%, #d7ccc8 '+(1-arg)*100+'%, #d7ccc8 100%)');
|
||||
$("#prog").text(Math.floor(arg*100)+"%");
|
||||
})
|
||||
ipc.on('mess', function (event, arg) {
|
||||
console.log(arg);
|
||||
$("#prog").text(arg);
|
||||
})
|
||||
function verck(){
|
||||
var remote=electron.remote;
|
||||
var platform=remote.process.platform;
|
||||
if(platform!="win32"){
|
||||
$('#updator').prop("disabled",true)
|
||||
}
|
||||
var start="https://thedesk.top/ver.json";
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
|
@ -69,10 +156,10 @@ function verck(){
|
|||
todo(error);
|
||||
console.error(error);
|
||||
}).then(function(json) {
|
||||
console.log(json);
|
||||
console.log(json);
|
||||
$("#ver").text(json.desk);
|
||||
localStorage.setItem("next-ver",json.desk);
|
||||
$("#det").text(json.detail);
|
||||
$("#det").html(json.detail);
|
||||
$("#now").text(localStorage.getItem("ver"));
|
||||
});
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<!doctype html>
|
||||
<html lang="{{lang}}">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Update - TheDesk</title>
|
||||
<link href="./css/materialize.css" type="text/css" rel="stylesheet">
|
||||
|
@ -8,57 +8,144 @@
|
|||
<meta charset="utf-8">
|
||||
</head>
|
||||
<body>
|
||||
<style>
|
||||
body{
|
||||
<style>
|
||||
body{
|
||||
font-family:'Open Sans';
|
||||
-webkit-app-region: drag;
|
||||
cursor: move;
|
||||
padding:10px;
|
||||
text-align:right;
|
||||
}
|
||||
a,button{
|
||||
#start{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width:100vw;
|
||||
height: calc(100vh - 2.5rem);
|
||||
text-align:center;
|
||||
}
|
||||
#checkbox{
|
||||
text-align:left;
|
||||
}
|
||||
a,button,input,label,i{
|
||||
-webkit-app-region: no-drag;
|
||||
}</style>
|
||||
}
|
||||
#updskip{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.skipbtn{
|
||||
display:block;
|
||||
float:left;
|
||||
width:200px;
|
||||
height:200px;
|
||||
border:1px solid;
|
||||
margin-left:5px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
border: 1px solid;
|
||||
overflow: hidden;
|
||||
}
|
||||
.skipbtn:hover{
|
||||
background-color: #b3e5fc;
|
||||
transition: all 0.3s ease-in-out;
|
||||
}
|
||||
#prog{
|
||||
font-size:200%;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript" src="./js/common/jquery.js"></script>
|
||||
<script type="text/javascript" src="./js/platform/first.js"></script>
|
||||
<script type="text/javascript" src="./js/common/materialize.js"></script>
|
||||
<h5>{{updatehere}}[TheDesk <span id="ver"></span>]</h5>
|
||||
<span id="det"></span><br>
|
||||
{{nowver}}<span id="now"></span><br>
|
||||
{{afterdl}}<br>
|
||||
<button id="update" class="waves-effect btn" onclick="update('true')">{{download}}</button>
|
||||
<p id="prog"></p>
|
||||
<div class="progress">
|
||||
<div class="determinate" style="width: 0%"></div>
|
||||
</div><br>
|
||||
<b>{{winzip}}</b><br>
|
||||
{{releasenote1}}<a href="https://github.com/cutls/TheDesk/blob/master/LATEST.md">GitHub</a>{{releasenote2}}<br><br>
|
||||
{{skipupd}}(<a onclick="window.close();" class="pointer">{{nexttl}}</a>/<a onclick="nextv();" class="pointer">{{nextver}}</a>)<br>
|
||||
<a onclick="quit()" class="pointer">{{endthedesk}}</a><br>
|
||||
<a onclick="about()" class="pointer">{{about}}</a><br>
|
||||
{{problem1}}<a href="https://thedesk.top">TheDesk HP</a>{{problem2}}
|
||||
<script type="text/javascript" src="./js/common/about.js"></script>
|
||||
<i class="material-icons pointer waves-effect" onclick="about();">info</i>
|
||||
<i class="material-icons pointer waves-effect" onclick="skipper();">clear</i>
|
||||
<!--a href="update.html">Reload</a-->
|
||||
<div id="start">
|
||||
<div id="box" class="show">
|
||||
<h2>TheDesk</h2>
|
||||
<p>{{updatehere}}</p>
|
||||
<span id="now"></span>→<b id="ver"></b><br>
|
||||
<span id="det"></span><br>
|
||||
<button id="update" class="waves-effect btn" onclick="update('true')" style="margin-left:15px;">{{download}}</button>
|
||||
<div id="checkbox">
|
||||
Options:<br>
|
||||
<input type="checkbox" class="filled-in" id="updator" value="true" onchange="alert('{{winzip}}')" />
|
||||
<label for="updator">{{plusunzip}}</label><br>
|
||||
<input type="checkbox" class="filled-in" id="rewrite" value="true" />
|
||||
<label for="rewrite">{{unrewrite}}</label><br>
|
||||
</div>
|
||||
{{problem1}}<br>{{problem2}}
|
||||
</div>
|
||||
<div id="skipper" class="hide">
|
||||
<h4>{{sureupd}}</h4>
|
||||
{{skipupd}}<br>
|
||||
<div id="updskip">
|
||||
<a onclick="window.close();" class="pointer skipbtn waves-effect waves-light"><div>{{nexttl}}</div></a>
|
||||
<a onclick="nextv();" class="pointer skipbtn waves-effect waves-light"><div>{{nextver}}</div></a>
|
||||
</div>
|
||||
<a class="pointer waves-effect" onclick="skipper();" style="margin-top:5px">{{continue}}</a>
|
||||
</div>
|
||||
<div id="dlnow" class="hide">
|
||||
<h4>{{dlnow}}</h4>
|
||||
<h4 id="prog"></h4>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" src="./js/common/about.js"></script>
|
||||
<script type="text/javascript" src="./js/platform/end.js"></script>
|
||||
<script>
|
||||
function skipper(){
|
||||
$("#dlnow").addClass("hide");
|
||||
$("#box").toggleClass("show");
|
||||
if($("#box").hasClass("hide") && $("#skipper").hasClass("hide")){
|
||||
$("#skipper").removeClass("hide");
|
||||
$("#skipper").addClass("show");
|
||||
}else{
|
||||
$("#box").toggleClass("hide");
|
||||
$("#skipper").toggleClass("hide");
|
||||
$("#skipper").toggleClass("show");
|
||||
}
|
||||
}
|
||||
var electron = require("electron");
|
||||
var ipc = electron.ipcRenderer;
|
||||
verck();
|
||||
function update(sel){
|
||||
$("#prog").text("");
|
||||
ipc.send('download-btn', [sel,enc(localStorage.getItem("next-ver"))]);
|
||||
function update(sel){
|
||||
$("#box").toggleClass("show");
|
||||
$("#box").toggleClass("hide");
|
||||
$("#dlnow").toggleClass("hide");
|
||||
$("#dlnow").toggleClass("show");
|
||||
$("#prog").text("");
|
||||
if($('#rewrite:checked').val()=="true"){
|
||||
var versioning=true;
|
||||
}else{
|
||||
var versioning=false;
|
||||
}
|
||||
if($('#updator:checked').val()=="true"){
|
||||
var zip=true;
|
||||
}else{
|
||||
var zip=false;
|
||||
}
|
||||
ipc.send('download-btn', [sel,enc(localStorage.getItem("next-ver")),zip,versioning]);
|
||||
}
|
||||
function quit(){
|
||||
ipc.send('quit', 'go');
|
||||
}
|
||||
ipc.on('prog', function (event, arg) {
|
||||
console.log(arg);
|
||||
$(".determinate").css('width',arg*100+"%");
|
||||
$("#prog").text("{{dlnow}}:"+Math.floor(arg*100)+"%");
|
||||
console.log(arg);
|
||||
$("body").css('background','linear-gradient(#fff 0%,#fff '+(1-arg)*100+'%, #d7ccc8 '+(1-arg)*100+'%, #d7ccc8 100%)');
|
||||
$("#prog").text(Math.floor(arg*100)+"%");
|
||||
})
|
||||
ipc.on('mess', function (event, arg) {
|
||||
console.log(arg);
|
||||
$("#prog").text(arg);
|
||||
})
|
||||
function verck(){
|
||||
var remote=electron.remote;
|
||||
var platform=remote.process.platform;
|
||||
if(platform!="win32"){
|
||||
$('#updator').prop("disabled",true)
|
||||
}
|
||||
var start="https://thedesk.top/ver.json";
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
|
|
2
ver.json
2
ver.json
|
@ -1 +1 @@
|
|||
{"warn":"これはGCPにアップして下さい!!","warn2":"これはGCPにアップして下さい!!","warn3":"これはGCPにアップして下さい!!","desk":"Mio (15.9.1)","desk_mac":"Mio (15.9.1)","date":"2018-06-17","detail":"複数アカウント、フォントなど。バグ修正多数。アプデ後のアプリ内リリースノートなどで。"}
|
||||
{"warn":"これはGCPにアップして下さい!!","warn2":"これはGCPにアップして下さい!!","warn3":"これはGCPにアップして下さい!!","desk":"Akane (16.0.9)","desk_mac":"Akane (16.0.8)","date":"2018-08-17","detail":"ストリーミング接続改善、Auto CW他不具合修正"}
|
Loading…
Reference in New Issue
Block a user