Skip to content

Commit

Permalink
Merge pull request #147 from emfcamp/feature/reduce-draw-overlead
Browse files Browse the repository at this point in the history
Only draw the focused and always-on-top apps
  • Loading branch information
MatthewWilkes authored Jun 17, 2024
2 parents 8347024 + 0ece5e3 commit bcaa84c
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions modules/system/scheduler/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ async def _render_task(self):

with PerfTimer("render"):
ctx = display.get_ctx()
for app in self.foreground_stack:
for app in self.foreground_stack[-1:] + self.on_top_stack:
with PerfTimer(f"rendering {app}"):
ctx.save()
try:
Expand All @@ -227,11 +227,6 @@ async def _render_task(self):
)
)
ctx.restore()
for app in self.on_top_stack:
with PerfTimer(f"rendering {app}"):
ctx.save()
app.draw(ctx)
ctx.restore()
display.end_frame(ctx)
await asyncio.sleep(0)

Expand Down

0 comments on commit bcaa84c

Please sign in to comment.