fixes m_cursor computing.
authorPeng Wu <alexepico@gmail.com>
Mon, 21 Jun 2010 07:17:48 +0000 (15:17 +0800)
committerPeng Wu <alexepico@gmail.com>
Mon, 21 Jun 2010 07:17:48 +0000 (15:17 +0800)
src/ExtEditor.cc

index c319802..a4b2104 100644 (file)
@@ -295,7 +295,7 @@ ExtEditor::removeCharBefore()
     }
 
     m_text.erase(m_cursor - 1, 1);
-    m_cursor = std::max(0, static_cast<int>(m_cursor - 1));
+    m_cursor = std::max(0, static_cast<int>(m_cursor) - 1);
     return TRUE;
 }