File tree Expand file tree Collapse file tree 1 file changed +9
-10
lines changed
packages/app-frontend/src/features/timeline Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -55,7 +55,6 @@ const propConfig = {
55
55
// Micro tasks (higher = later)
56
56
const taskPriority = {
57
57
normal: 0 ,
58
- resize: 1 ,
59
58
addEventUpdate: 2 ,
60
59
updateEvents: 3 ,
61
60
runPositionUpdate: 4 ,
@@ -152,8 +151,9 @@ export default defineComponent({
152
151
wrapper .value .appendChild (app .view )
153
152
154
153
// Prevent flash of white in dark mode
154
+ // Init & on resize
155
155
app .view .style .opacity = ' 0'
156
- app .renderer .once (' postrender' , () => {
156
+ app .renderer .on (' postrender' , () => {
157
157
app .view .style .opacity = ' 1'
158
158
})
159
159
@@ -1313,17 +1313,16 @@ export default defineComponent({
1313
1313
// Resize
1314
1314
1315
1315
function onResize () {
1316
+ // Prevent flashing (will be set back to 1 in postrender event listener)
1316
1317
app .view .style .opacity = ' 0'
1317
1318
// @ts-expect-error PIXI type is missing queueResize
1318
1319
app .queueResize ()
1319
- nextTick (() => {
1320
- mainRenderTexture ?.resize (app .view .width , app .view .height )
1321
- queueEventsUpdate ()
1322
- drawLayerBackgroundEffects ()
1323
- drawTimeCursor ()
1324
- drawTimeGrid ()
1325
- draw ()
1326
- }, taskPriority .resize )
1320
+ mainRenderTexture ?.resize (app .view .width , app .view .height )
1321
+ queueEventsUpdate ()
1322
+ drawLayerBackgroundEffects ()
1323
+ drawTimeCursor ()
1324
+ drawTimeGrid ()
1325
+ draw ()
1327
1326
}
1328
1327
1329
1328
// Events
You can’t perform that action at this time.
0 commit comments