jesseduffield.lazygit/pkg/gui/types
Stefan Haller a67eda39a5 Rerender fewer views when their width changes
In d5b4f7bb3e and 58a83b0862 we introduced a combined mechanism for rerendering
views when either their width changes (needed for the branches view which
truncates long branch names), or the screen mode (needed for those views that
display more information in half or full screen mode, e.g. the commits view).

This was a bad idea, because it unnecessarily rerenders too many views when just
their width changes, which causes a noticable lag. This is a problem, for
example, when selecting a file in the files panel that has only unstaged
changes, and then going to one that has both staged and unstaged changes; this
splits the main view, causing the side panels to become a bit narrower, and
rerendering all those views took almost 500ms on my machine. Another similar
example is entering or leaving staging mode.

Fix this by being more specific about which views need rerendering under what
conditions; this improves the time it takes to rerender in the above scenarios
from 450-500s down to about 20ms.

This reintroduces the code that was removed in 58a83b0862, but in a slightly
different way.
2024-06-23 13:10:48 +02:00
..
common.go Support showing checkboxes or radio buttons in menus 2024-06-23 12:53:15 +02:00
common_commands.go start moving commit panel handlers into controller 2022-03-17 19:13:40 +11:00
context.go Rerender fewer views when their width changes 2024-06-23 13:10:48 +02:00
keybindings.go Show mode-specific keybinding suggestions 2024-01-28 08:33:13 +11:00
modes.go Add a "Mark commit as base commit for rebase" command 2023-07-31 08:41:41 +02:00
ref.go fix: fix ambiguous refname 2022-05-13 21:05:51 +09:00
refresh.go Return error from RefreshOptions.Then 2024-04-18 10:10:30 +02:00
rendering.go Visualize the "ignore whitespace" state in the subtitle of the diff view 2023-05-20 12:58:32 +10:00
search_state.go Add search history 2023-09-20 08:35:41 +03:00
suggestion.go Set groundwork for better disabled reasons with range select 2024-01-23 13:03:37 +11:00
version_number.go Show popup message with breaking changes on startup 2024-03-12 13:27:14 +01:00
version_number_test.go Show popup message with breaking changes on startup 2024-03-12 13:27:14 +01:00
views.go Layout the bottom line view using spacer views 2023-12-09 11:18:28 +01:00