mirror of
https://github.com/Elvanos/fantasia-archive.git
synced 2024-05-22 05:03:13 +12:00
small fix to flickering window buttons on routing
This commit is contained in:
parent
cc85318d02
commit
d8a3585854
|
@ -42,7 +42,9 @@
|
||||||
</q-tooltip>
|
</q-tooltip>
|
||||||
<q-icon
|
<q-icon
|
||||||
size="16px"
|
size="16px"
|
||||||
:name="(isMaximized)? 'mdi-window-restore' : 'mdi-window-maximize'"
|
:name="(isMaximized)
|
||||||
|
? 'mdi-window-restore'
|
||||||
|
: 'mdi-window-maximize'"
|
||||||
/>
|
/>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
|
|
||||||
|
@ -120,7 +122,7 @@ const checkIfWindowMaximized = () => {
|
||||||
/**
|
/**
|
||||||
* Determines if the window is currently maximized or not
|
* Determines if the window is currently maximized or not
|
||||||
*/
|
*/
|
||||||
const isMaximized: Ref<boolean> = ref(false)
|
const isMaximized: Ref<boolean> = ref(true)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Window interval checker variable
|
* Window interval checker variable
|
||||||
|
@ -129,13 +131,17 @@ let checkerInterval: number
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Hook up a interval timer on mount for continuous checking
|
* Hook up a interval timer on mount for continuous checking
|
||||||
* This done due to the fact that dragging via the top header bar doesn't properly fire "drag" event
|
* This is done due to the fact that dragging via the top header bar doesn't properly fire "drag" event
|
||||||
* Async due to UI render blocking
|
* Async due to UI render blocking
|
||||||
*/
|
*/
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
|
window.clearInterval(checkerInterval)
|
||||||
|
|
||||||
|
checkIfWindowMaximized()
|
||||||
|
|
||||||
checkerInterval = window.setInterval(() => {
|
checkerInterval = window.setInterval(() => {
|
||||||
checkIfWindowMaximized()
|
checkIfWindowMaximized()
|
||||||
}, 300)
|
}, 100)
|
||||||
})
|
})
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -13,6 +13,7 @@ const routes: RouteRecordRaw[] = [
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Component testing pathing
|
* Component testing pathing
|
||||||
|
* ONLY for singular component testing purposes
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
path: '/componentTesting/:componentName',
|
path: '/componentTesting/:componentName',
|
||||||
|
@ -23,6 +24,7 @@ const routes: RouteRecordRaw[] = [
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* Error page - 404
|
||||||
* Always leave this as last one, but you can also remove it
|
* Always leave this as last one, but you can also remove it
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue