途中でプルリクを処理するためコミット
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
//バージョンチェッカー
|
||||
function verck(ver,winstore) {
|
||||
function verck(ver) {
|
||||
console.log("Welcome")
|
||||
if(localStorage.getItem("ver")!=ver){
|
||||
localStorage.setItem("ver", ver);
|
||||
console.log("Thank you for your update");
|
||||
@@ -27,7 +28,6 @@ function verck(ver,winstore) {
|
||||
message: lang.lang_version_platform,
|
||||
buttons: [lang.lang_no,lang.lang_yesno]
|
||||
}
|
||||
console.log(localStorage.getItem("winstore"))
|
||||
if(!localStorage.getItem("winstore")){
|
||||
|
||||
dialog.showMessageBox(options, function(arg) {
|
||||
@@ -42,7 +42,6 @@ function verck(ver,winstore) {
|
||||
if(localStorage.getItem("winstore")=="unix"){
|
||||
localStorage.removeItem("winstore")
|
||||
}
|
||||
console.log(localStorage.getItem("winstore"))
|
||||
if(!localStorage.getItem("winstore")){
|
||||
const options = {
|
||||
type: 'info',
|
||||
@@ -61,6 +60,11 @@ function verck(ver,winstore) {
|
||||
}else{
|
||||
localStorage.setItem("winstore","unix")
|
||||
}
|
||||
if(localStorage.getItem("winstore")=="snapcraft" || localStorage.getItem("winstore")=="winstore"){
|
||||
var winstore=true;
|
||||
}else{
|
||||
var winstore=false;
|
||||
}
|
||||
var l = 5;
|
||||
// 生成する文字列に含める文字セット
|
||||
var c = "abcdefghijklmnopqrstuvwxyz0123456789";
|
||||
@@ -90,7 +94,7 @@ function verck(ver,winstore) {
|
||||
}
|
||||
if (newest == ver) {
|
||||
todo(lang.lang_version_usever.replace("{{ver}}" ,mess.desk));
|
||||
//betaかWInstoreならアプデチェックしない
|
||||
//betaかWinstoreならアプデチェックしない
|
||||
} else if (ver.indexOf("beta")!=-1 || winstore) {
|
||||
|
||||
}else{
|
||||
@@ -100,6 +104,7 @@ function verck(ver,winstore) {
|
||||
var ipc = electron.ipcRenderer;
|
||||
ipc.send('update', "true");
|
||||
}else{
|
||||
console.log(lang.lang_version_skipver);
|
||||
todo(lang.lang_version_skipver);
|
||||
}
|
||||
}else{
|
||||
|
@@ -10,6 +10,7 @@ function imgv(id, key, acct_id) {
|
||||
$("#imagemodal").attr("data-acct",acct_id);
|
||||
$(document).ready(function() {
|
||||
if (type == "image") {
|
||||
$('#imagemodal').modal('open');
|
||||
xhr = new XMLHttpRequest;
|
||||
xhr.open('GET', murl, true);
|
||||
xhr.addEventListener('progress', function (event) {
|
||||
@@ -29,7 +30,6 @@ function imgv(id, key, acct_id) {
|
||||
xhr.send();
|
||||
$('#imgmodal').attr('src', murl);
|
||||
$('#imagewrap').dragScroll(); // ドラッグスクロール設定
|
||||
$('#imagemodal').modal('open');
|
||||
$('#imgmodal').show();
|
||||
$('#imagemodal').attr('data-key', key);
|
||||
$('#imagemodal').attr('data-id', id);
|
||||
@@ -45,61 +45,31 @@ function imgv(id, key, acct_id) {
|
||||
var height = element.naturalHeight;
|
||||
var windowH = $(window).height();
|
||||
var windowW = $(window).width();
|
||||
//小さい画像
|
||||
if(width<(windowW - 50) && height<(windowH-1000)){
|
||||
$("#imgmodal").css('height',height+"px");
|
||||
$("#imgmodal").css('width',width+"px");
|
||||
$("#imagewrap").css('height',height+"px");
|
||||
$("#imagemodal").css('height',height+100+"px");
|
||||
$("#imagewrap").css('width',width+"px");
|
||||
$("#imagemodal").css('width',width+"px");
|
||||
$("#imagemodal").css('margin-top',(windowH /2) - (height / 2) +"px");
|
||||
}else{
|
||||
$("#imagemodal").css('margin-top',0);
|
||||
var aspect = width/height;
|
||||
if (aspect < 2.8 && aspect > 0.3){
|
||||
//moderate
|
||||
if(windowW > windowH){
|
||||
//画面が横長(縦幅基準)
|
||||
$("#imgmodal").css('height',windowH/1.2-70+"px");
|
||||
var imgW = (windowH/1.2-70)/height*width;
|
||||
$("#imgmodal").css('width',imgW+"px");
|
||||
$("#imagewrap").css('height',windowH/1.2-60+"px");
|
||||
$("#imagemodal").css('height',windowH/1.2+"px");
|
||||
$("#imagewrap").css('width',imgW+50+"px");
|
||||
$("#imagemodal").css('width',imgW+50+"px");
|
||||
}else{
|
||||
//画面が縦長・正方形(横幅基準)
|
||||
$("#imgmodal").css('width',windowW/1.2-30+"px");
|
||||
var imgH = (windowW/1.2-30)/width*height;
|
||||
$("#imgmodal").css('height',imgH+"px");
|
||||
$("#imagewrap").css('width',windowW/1.2+"px");
|
||||
$("#imagemodal").css('width',windowW/1.2+"px");
|
||||
$("#imagewrap").css('height',imgH+60+"px");
|
||||
$("#imagemodal").css('height',imgH+120+"px");
|
||||
}
|
||||
$("#imagemodal").css("bottom","0")
|
||||
$("#imagemodal img").css("width","auto")
|
||||
if(height<windowH){
|
||||
$("#imagemodal").css("height",height+60+"px")
|
||||
$("#imagemodal img").css("height","100%")
|
||||
if(width>windowW*0.8){
|
||||
$("#imagemodal").css("width","80vw")
|
||||
$("#imagemodal img").css("width","100%")
|
||||
var heightS=windowW*0.8/width*height;
|
||||
$("#imagemodal").css("height",heightS+60+"px")
|
||||
}else{
|
||||
//極端な画像
|
||||
if(height > width){
|
||||
//縦長
|
||||
$("#imgmodal").css('height',windowH-60+"px");
|
||||
var imgW = (windowH-50)/height*width;
|
||||
$("#imgmodal").css('width',imgW+"px");
|
||||
$("#imagewrap").css('height',windowH-50+"px");
|
||||
$("#imagemodal").css('height',windowH+"px");
|
||||
$("#imagewrap").css('width',imgW+50+"px");
|
||||
$("#imagemodal").css('width',imgW+50+"px");
|
||||
}else{
|
||||
//横長・正方形
|
||||
$("#imgmodal").css('width',windowW-30+"px");
|
||||
var imgH = (windowW-50)/width*height;
|
||||
$("#imgmodal").css('height',imgH+"px");
|
||||
$("#imagewrap").css('width',windowW+"px");
|
||||
$("#imagemodal").css('width',windowW+"px");
|
||||
$("#imagewrap").css('height',imgH+60+"px");
|
||||
$("#imagemodal").css('height',imgH+120+"px");
|
||||
}
|
||||
$("#imagemodal").css("width",width+"px")
|
||||
}
|
||||
}else{
|
||||
console.log("long")
|
||||
$("#imagemodal img").css("width","auto")
|
||||
var widthS=windowH/height*width;
|
||||
if(widthS<windowW){
|
||||
$("#imagemodal").css("width",widthS+"px")
|
||||
}else{
|
||||
$("#imagemodal").css("width","100vw")
|
||||
}
|
||||
|
||||
$("#imagemodal").css("height","100vh")
|
||||
$("#imagemodal img").css("height","calc(100vh - 60px)")
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -14,6 +14,13 @@ function addColumnMenu() {
|
||||
$("#add-box").removeClass("hide");
|
||||
addselCk()
|
||||
}
|
||||
$('.type').click(function() {
|
||||
if(this.hasClass("active")){
|
||||
|
||||
}else{
|
||||
|
||||
}
|
||||
})
|
||||
//最初、カラム変更時に発火
|
||||
function parseColumn() {
|
||||
console.log("parse");
|
||||
|
Reference in New Issue
Block a user