|
@@ -5,10 +5,10 @@
|
|
<div
|
|
<div
|
|
:style="{
|
|
:style="{
|
|
position: 'relative',
|
|
position: 'relative',
|
|
- left:windowJson[0].Left+'px',
|
|
|
|
- top:windowJson[0].Top+'px',
|
|
|
|
- width:windowJson[0].Width + 'px',
|
|
|
|
- height:windowJson[0].Height + 'px',
|
|
|
|
|
|
+ left:windowJson[0].Left*Scale+'px',
|
|
|
|
+ top:windowJson[0].Top*Scale+'px',
|
|
|
|
+ width:windowJson[0].Width*Scale + 'px',
|
|
|
|
+ height:windowJson[0].Height*Scale + 'px',
|
|
zIndex:windowJson[0].ZIndex,
|
|
zIndex:windowJson[0].ZIndex,
|
|
display:windowJson[0].IsVisibility ? 'block' : 'none',
|
|
display:windowJson[0].IsVisibility ? 'block' : 'none',
|
|
backgroundImage:windowJson[0].BackIcon ? 'url('+require(`../../../static/images/${windowJson[0].BackIcon}`)+')' : null,
|
|
backgroundImage:windowJson[0].BackIcon ? 'url('+require(`../../../static/images/${windowJson[0].BackIcon}`)+')' : null,
|
|
@@ -56,12 +56,15 @@
|
|
|
|
|
|
<button class="logoutBtn" @click="logout">退出</button>
|
|
<button class="logoutBtn" @click="logout">退出</button>
|
|
</div>
|
|
</div>
|
|
|
|
+ <!--最小化和关闭按钮-->
|
|
|
|
+ <div class="mini" @click="miniWindow">-</div>
|
|
|
|
+ <div class="close" @click="closeWindow">×</div>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
- import {mapState} from 'vuex'
|
|
|
|
import '../assets/less/mainpage.less'
|
|
import '../assets/less/mainpage.less'
|
|
|
|
+ import {mapState} from 'vuex'
|
|
import storageUtils from "../../utils/storageUtils"
|
|
import storageUtils from "../../utils/storageUtils"
|
|
|
|
|
|
import ButtonComponent from './Button'
|
|
import ButtonComponent from './Button'
|
|
@@ -82,7 +85,7 @@
|
|
SliderComponent
|
|
SliderComponent
|
|
},
|
|
},
|
|
|
|
|
|
- mounted(){
|
|
|
|
|
|
+ mounted() {
|
|
this.fullScreen()
|
|
this.fullScreen()
|
|
},
|
|
},
|
|
|
|
|
|
@@ -112,11 +115,21 @@
|
|
} else if (de.webkitRequestFullScreen) {
|
|
} else if (de.webkitRequestFullScreen) {
|
|
de.webkitRequestFullScreen()
|
|
de.webkitRequestFullScreen()
|
|
}
|
|
}
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 最小化窗口
|
|
|
|
+ miniWindow() {
|
|
|
|
+ require('electron').ipcRenderer.send('window-min')
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 关闭窗口
|
|
|
|
+ closeWindow() {
|
|
|
|
+ require('electron').ipcRenderer.send('window-close')
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
|
|
computed: {
|
|
computed: {
|
|
- ...mapState(['windowJson'])
|
|
|
|
|
|
+ ...mapState(['windowJson','Scale'])
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|