mirror of
https://github.com/neovim/neovim.git
synced 2025-09-29 06:28:35 +00:00
The grand renaming
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
#include "nvim/ex_docmd.h"
|
||||
#include "nvim/func_attr.h"
|
||||
#include "nvim/indent.h"
|
||||
#include "nvim/liveupdate.h"
|
||||
#include "nvim/buffer_updates.h"
|
||||
#include "nvim/mark.h"
|
||||
#include "nvim/memline.h"
|
||||
#include "nvim/memory.h"
|
||||
@@ -746,14 +746,14 @@ deleteFold (
|
||||
if (last_lnum > 0) {
|
||||
changed_lines(first_lnum, (colnr_T)0, last_lnum, 0L, false);
|
||||
|
||||
// send one LiveUpdate at the end
|
||||
if (kv_size(curbuf->liveupdate_channels)) {
|
||||
// send one nvim_buf_update at the end
|
||||
if (kv_size(curbuf->update_channels)) {
|
||||
// last_lnum is the line *after* the last line of the outermost fold
|
||||
// that was modified. Note also that deleting a fold might only require
|
||||
// the modification of the *first* line of the fold, but we send through a
|
||||
// notification that includes every line that was part of the fold
|
||||
int64_t num_changed = last_lnum - first_lnum;
|
||||
liveupdate_send_changes(curbuf, first_lnum, num_changed,
|
||||
buffer_updates_send_changes(curbuf, first_lnum, num_changed,
|
||||
num_changed, true);
|
||||
}
|
||||
}
|
||||
@@ -1605,12 +1605,12 @@ static void foldCreateMarkers(linenr_T start, linenr_T end)
|
||||
* changed when the start marker is inserted and the end isn't. */
|
||||
changed_lines(start, (colnr_T)0, end, 0L, false);
|
||||
|
||||
if (kv_size(curbuf->liveupdate_channels)) {
|
||||
if (kv_size(curbuf->update_channels)) {
|
||||
// Note: foldAddMarker() may not actually change start and/or end if
|
||||
// u_save() is unable to save the buffer line, but we send the LiveUpdate
|
||||
// u_save() is unable to save the buffer line, but we send the nvim_buf_update
|
||||
// anyway since it won't do any harm.
|
||||
int64_t num_changed = 1 + end - start;
|
||||
liveupdate_send_changes(curbuf, start, num_changed, num_changed, true);
|
||||
buffer_updates_send_changes(curbuf, start, num_changed, num_changed, true);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user