mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 02:49:46 +00:00
Fix crash related to undo and continuous spell checking
The cursor member new_word_ should not be saved in undo. Move it from CursorData to Cursor.
This commit is contained in:
parent
945c0e4127
commit
146b754f1d
@ -286,6 +286,8 @@ void Cursor::reset()
|
|||||||
push_back(CursorSlice(buffer()->inset()));
|
push_back(CursorSlice(buffer()->inset()));
|
||||||
anchor_ = doc_iterator_begin(buffer());
|
anchor_ = doc_iterator_begin(buffer());
|
||||||
anchor_.clear();
|
anchor_.clear();
|
||||||
|
new_word_ = doc_iterator_begin(buffer());
|
||||||
|
new_word_.clear();
|
||||||
clearTargetX();
|
clearTargetX();
|
||||||
selection_ = false;
|
selection_ = false;
|
||||||
mark_ = false;
|
mark_ = false;
|
||||||
|
@ -52,8 +52,6 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
/// the anchor position
|
/// the anchor position
|
||||||
DocIterator anchor_;
|
DocIterator anchor_;
|
||||||
/// the start of the new born word
|
|
||||||
DocIterator new_word_;
|
|
||||||
///
|
///
|
||||||
mutable DispatchResult disp_;
|
mutable DispatchResult disp_;
|
||||||
/// do we have a selection?
|
/// do we have a selection?
|
||||||
@ -394,6 +392,8 @@ private:
|
|||||||
int x_target_;
|
int x_target_;
|
||||||
/// if a x_target cannot be hit exactly in a text, put the difference here
|
/// if a x_target cannot be hit exactly in a text, put the difference here
|
||||||
int textTargetOffset_;
|
int textTargetOffset_;
|
||||||
|
/// the start of the new born word
|
||||||
|
DocIterator new_word_;
|
||||||
/// position before dispatch started
|
/// position before dispatch started
|
||||||
DocIterator beforeDispatchCursor_;
|
DocIterator beforeDispatchCursor_;
|
||||||
/// cursor screen coordinates before dispatch started
|
/// cursor screen coordinates before dispatch started
|
||||||
|
Loading…
Reference in New Issue
Block a user