Fix run indicators jumping when buffer content changes. (#25507)
Co-authored-by: Anthony Eid <hello@anthonyeid.me> Release Notes: - Fix run indicators jumping when content changes --------- Co-authored-by: Anthony Eid <hello@anthonyeid.me>
This commit is contained in:
parent
63cfcc26fb
commit
7b277d2efd
3 changed files with 17 additions and 15 deletions
|
@ -524,7 +524,7 @@ impl ScrollbarMarkerState {
|
|||
#[derive(Clone, Debug)]
|
||||
struct RunnableTasks {
|
||||
templates: Vec<(TaskSourceKind, TaskTemplate)>,
|
||||
offset: MultiBufferOffset,
|
||||
offset: multi_buffer::Anchor,
|
||||
// We need the column at which the task context evaluation should take place (when we're spawning it via gutter).
|
||||
column: u32,
|
||||
// Values of all named captures, including those starting with '_'
|
||||
|
@ -551,8 +551,6 @@ struct ResolvedTasks {
|
|||
templates: SmallVec<[(TaskSourceKind, ResolvedTask); 1]>,
|
||||
position: Anchor,
|
||||
}
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
struct MultiBufferOffset(usize);
|
||||
#[derive(Copy, Clone, Debug, PartialEq, PartialOrd)]
|
||||
struct BufferOffset(usize);
|
||||
|
||||
|
@ -10848,7 +10846,9 @@ impl Editor {
|
|||
(runnable.buffer_id, row),
|
||||
RunnableTasks {
|
||||
templates: tasks,
|
||||
offset: MultiBufferOffset(runnable.run_range.start),
|
||||
offset: snapshot
|
||||
.buffer_snapshot
|
||||
.anchor_before(runnable.run_range.start),
|
||||
context_range,
|
||||
column: point.column,
|
||||
extra_variables: runnable.extra_captures,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue