micro/internal
Dmytro Maluka 93efc9eabe buffer/settings: Don't use Modified() before we updated origHash
When we have already enabled `fastdirty` but have not updated origHash
yet, we shouldn't use Modified() since it depends on origHash which is
still outdated, and thus returns wrong values.

This fixes the following issue: enable `fastdirty`, modify the buffer,
save the buffer and disable `fastdirty` -> micro wrongly reports the
buffer as modified (whereas it has just been saved).

Note that this fix, though, also causes a regression: e.g. if we run
`set fastdirty false` while fastdirty is already disabled, micro may
unexpectedly report a non-modified buffer as modified (in the case if
isModified is true but the buffer it actually not modified, since its
md5 sum matches and fastdirty is disabled), since this fix assumes that
since we are disabling fastdirty, it has been enabled. This shall be
fixed by PR #3343 which makes `set` do nothing if the option value
doesn't change.
2024-08-18 15:39:47 +02:00
..
action Adding missing deselect when calling RemoveAllMultiCursors (#3428) 2024-08-15 16:06:32 +02:00
buffer buffer/settings: Don't use Modified() before we updated origHash 2024-08-18 15:39:47 +02:00
clipboard Use zyedidia/clipper for external clipboard 2022-06-14 08:40:57 -04:00
config Temporarily don't initialize runtime files in buffer test 2024-04-03 04:37:44 +02:00
display Rework FindMatchingBrace() interface and implementation (#3319) 2024-06-05 00:56:19 +02:00
info Reordered prompt done callback to avoid accessing out of bound history (#3318) 2024-06-02 20:00:13 +02:00
lua Revert "Don't expose Go timers directly to lua" (#3211) 2024-03-25 17:11:12 +01:00
screen Reset mouse release state after restarting the screen 2023-01-29 18:26:55 +01:00
shell Return error with start in RunInteractiveShell 2024-06-22 21:21:13 +08:00
util Move sigterm channel to internal/util 2024-06-17 18:08:18 +08:00
views chore: fix some typos (#3239) 2024-04-08 12:04:38 +02:00