]> git.lyx.org Git - lyx.git/blobdiff - src/Text.cpp
Kornel's gcc compile fix.
[lyx.git] / src / Text.cpp
index cb9531d19dcd64e1c252cbf86c345c42a8eb3112..1bf7d61135fc4fb8a809671a935e632f3c262cbf 100644 (file)
@@ -927,12 +927,11 @@ void Text::charInserted(Cursor & cur)
 
        // Here we call finishUndo for every 20 characters inserted.
        // This is from my experience how emacs does it. (Lgb)
-       static unsigned int counter;
-       if (counter < 20) {
-               ++counter;
+       if (undo_counter_ < 20) {
+               ++undo_counter_;
        } else {
                cur.finishUndo();
-               counter = 0;
+               undo_counter_ = 0;
        }
 
        // register word if a non-letter was entered