mirror of https://github.com/buggins/dlangui.git
fix crash on removing editor mark
This commit is contained in:
parent
51c5952dc8
commit
c9c9837da5
|
@ -1518,6 +1518,7 @@ struct LineIcons {
|
||||||
LineIcon res = _items[index];
|
LineIcon res = _items[index];
|
||||||
for (int i = index; i < _len - 1; i++)
|
for (int i = index; i < _len - 1; i++)
|
||||||
_items[i] = _items[i + 1];
|
_items[i] = _items[i + 1];
|
||||||
|
_items[_len] = null;
|
||||||
_len--;
|
_len--;
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
@ -1587,7 +1588,7 @@ struct LineIcons {
|
||||||
if (deltaLines < 0 && rangeBefore.end.line >= item.line && rangeAfter.end.line < item.line) {
|
if (deltaLines < 0 && rangeBefore.end.line >= item.line && rangeAfter.end.line < item.line) {
|
||||||
// remove
|
// remove
|
||||||
removed ~= item;
|
removed ~= item;
|
||||||
_items.remove(i);
|
remove(i);
|
||||||
res = true;
|
res = true;
|
||||||
} else {
|
} else {
|
||||||
// move
|
// move
|
||||||
|
|
Loading…
Reference in New Issue