Browse Source

修改类型(新功能),影响的范围(代码逻辑),[优化体验]

master
郑荣升 5 years ago
committed by wailovet
parent
commit
6518c9785e
  1. 1
      CHANGELOG.md
  2. 26
      index.html
  3. 10
      index.js

1
CHANGELOG.md

@ -5,6 +5,7 @@
### 2019-11-15
#### 新功能
+ 3136352472 [15:03:04] :优化体验;影响的范围(代码逻辑)
+ 3136352472 [09:29:53] :利用随机数清除缓存;影响的范围(代码逻辑)
------

26
index.html

@ -4,29 +4,41 @@
<meta charset="UTF-8">
<script src="jquery-3.1.1.min.js"></script>
<style>
html {
html, body {
text-align: center;
background: #50bfff;
/*background: linear-gradient(135deg, #3023ae 0%, #c86dd7 100%);*/
cursor: none;
padding: 0;
margin: 0;
}
.loading {
background: #50bfff;
width: 100%;
height: 100%;
z-index: 9999;
}
</style>
</head>
<body>
<div style="text-align:center;width:120px;height:120px;position:fixed;top:50%;left:50%;margin-left:-60px;margin-top:-60px;background: #50bfff;display: none"
<iframe src="" frameborder="0" id="content"
style="width: 100%;height: 100%;position: fixed;left: 0px;display: none;"></iframe>
<div class="loading" style="position: fixed;">
<div style="text-align:center;width:120px;height:120px;position:fixed;top:50%;left:50%;margin-left:-60px;margin-top:-60px;background: #50bfff;display: none"
id="loading_img">
<img src="oval.svg" style="width:100%;height:100%;">
</div>
</div>
</body>
<script>
function check() {
$.ajax({
url: "http://localhost",
url: "http://localhost/",
success: function () {
setTimeout(function () {
$("#loading_img").fadeOut(2000, function () {
location.href = "http://localhost/?t=" + Math.random()
})
document.getElementById("content").src = "http://localhost/?t=" + Math.random();
$("#content").show();
$(".loading").fadeOut(2000)
}, 3000)
},
error: function (err) {

10
index.js

@ -1,17 +1,17 @@
const {app, BrowserWindow} = require('electron')
const { app, BrowserWindow } = require('electron')
function createWindow () {
function createWindow() {
// 创建浏览器窗口
let win = new BrowserWindow({
width: 1024,
height: 600,
kiosk:true,
kiosk: true,
frame: false
})
// 加载index.html文件
win.loadFile('index.html')
// win.webContents.openDevTools()
}
app.on('ready', createWindow)
app.on('ready', createWindow);
Loading…
Cancel
Save