diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-01-04 18:49:26 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-01-04 18:49:26 +0000 |
| commit | 99f471d738e0c2a0dcb61a559be3be512659d113 (patch) | |
| tree | 4a36dadf274d9c438e5b42ed907ce0bf7ea3976b /scripts | |
| parent | fdm: add support for hooks (diff) | |
render: trigger terminal refreshes in an FDM hook
In some cases, we end up calling render_refresh() multiple times in
the same FDM iteration. This means will render the first update
immediately, and then set the 'pending' flag, causing the updated
content to be rendered in the next frame.
This can cause flicker, or flashes, since we're presenting one or more
intermediate frames until the final content is shown.
Not to mention that it is inefficient to render multiple frames like
this.
Fix by:
* render_refresh() only sets a flag in the terminal
* install an FDM hook; this hook loops all terminals and executes what
render_refresh() _used_ to do (that is, render immediately if we're
not waiting for a frame callback, otherwise set 'pending' flag). for
all terminals that have the 'refresh_needed' flag set.
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
