Добавлена опция "Не включать строку статуса в обои"

This commit is contained in:
Book Pauk
2021-02-10 03:18:47 +07:00
parent ed901fc181
commit f142e5812d
3 changed files with 21 additions and 2 deletions

View File

@@ -84,4 +84,12 @@
</div>
</div>
<div class="q-mt-sm"/>
<div class="item row">
<div class="label-2"></div>
<div class="col row items-center">
<q-checkbox v-model="wallpaperIgnoreStatusBar" size="xs" label="Не включать строку статуса в обои" />
</div>
</div>
<input type="file" ref="file" @change="loadWallpaperFile" style='display: none;'/>

View File

@@ -495,8 +495,18 @@ class TextPage extends Vue {
}
setBackground() {
this.background = `<div class="layout ${this.wallpaper}" style="width: ${this.realWidth}px; height: ${this.realHeight}px;` +
` background-color: ${this.backgroundColor}"></div>`;
if (this.wallpaperIgnoreStatusBar) {
this.background = `<div class="layout" style="width: ${this.realWidth}px; height: ${this.realHeight}px;` +
` background-color: ${this.backgroundColor}">` +
`<div class="layout ${this.wallpaper}" style="width: ${this.realWidth}px; height: ${this.scrollHeight}px; ` +
`top: ${(this.showStatusBar && this.statusBarTop ? this.statusBarHeight + 1 : 0)}px; position: relative;">` +
`</div>` +
`</div>`;
} else {
this.background = `<div class="layout ${this.wallpaper}" style="width: ${this.realWidth}px; height: ${this.realHeight}px;` +
` background-color: ${this.backgroundColor}"></div>`;
}
}
async onResize() {