Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main layout repaints each second #72

Closed
TatsuUkraine opened this issue Jun 9, 2021 · 7 comments
Closed

Main layout repaints each second #72

TatsuUkraine opened this issue Jun 9, 2021 · 7 comments
Labels
T: Fix Type: :bug: Bug Fixes

Comments

@TatsuUkraine
Copy link
Contributor

Describe the bug
When timetable widget is initialized it starts to repaint entire table each second

Screenshots
timetable-repaint

Environment:

  • Package version: 1.0.0-alpha.0
@TatsuUkraine TatsuUkraine added the T: Fix Type: :bug: Bug Fixes label Jun 9, 2021
@JonasWanke
Copy link
Owner

The repaint was indeed happening too often, but only affected the NowIndicator – I did not find any widget that was rebuilt every frame.

The NowIndicator requested a repaint every frame with a TODO to improve this – which I've now done as part of v1.0.0-alpha.1. Now, the NowIndicator is only repainted when it moves more than half a device pixel, which is considerably less often.

@TatsuUkraine
Copy link
Contributor Author

I think entire layout repaints because it wrapped in NowIndicator

@TatsuUkraine
Copy link
Contributor Author

Need to double check, but it seems paint method was invoked on all children custom painters

@TatsuUkraine
Copy link
Contributor Author

Just checked, not child painters, but HourDeviderPainter was invoked each second as well

@TatsuUkraine
Copy link
Contributor Author

@JonasWanke I updated the package version, but still see that widget starts to repaint each second after a few gestures back and forward

@TatsuUkraine
Copy link
Contributor Author

screen-20210610-150655.mp4

@TatsuUkraine
Copy link
Contributor Author

@JonasWanke is there any way to disable indicator update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T: Fix Type: :bug: Bug Fixes
Projects
None yet
Development

No branches or pull requests

2 participants