QTfrontend/ui/widget/HistoryLineEdit.cpp
changeset 6205 7764cbe4ddd7
parent 6187 59ff93c0ae2d
child 6616 f77bb02b669f
--- a/QTfrontend/ui/widget/HistoryLineEdit.cpp	Tue Oct 25 13:30:02 2011 +0400
+++ b/QTfrontend/ui/widget/HistoryLineEdit.cpp	Tue Oct 25 19:46:59 2011 +0200
@@ -43,16 +43,6 @@
 
 void HistoryLineEdit::rememberCurrentText()
 {
-    m_historyMutex.lock();
-
-    rememberCurrentTextUnsynced();
-
-    m_historyMutex.unlock();
-}
-
-
-void HistoryLineEdit::rememberCurrentTextUnsynced()
-{
     QString newEntry = text();
 
     // don't store whitespace-only/empty text
@@ -73,36 +63,26 @@
 
 void HistoryLineEdit::clear()
 {
-    m_historyMutex.lock();
-
     QLineEdit::clear();
     m_curHistEntryIdx = m_history->size();
-
-    m_historyMutex.unlock();
 }
 
 
 void HistoryLineEdit::reset()
 {
     // forget history
-    m_historyMutex.lock();
-
     m_history->clear();
     m_curHistEntryIdx = 0;
-
-    m_historyMutex.unlock();
 }
 
 
 void HistoryLineEdit::navigateHistory(bool isGoingUp)
 {
-    m_historyMutex.lock();
-
     // save possible changes to new entry
     if ((m_curHistEntryIdx >= m_history->size() ||
         (text() != m_history->at(m_curHistEntryIdx))))
         {
-            rememberCurrentTextUnsynced();
+            rememberCurrentText();
         }
 
     if (isGoingUp)
@@ -125,8 +105,6 @@
     else
         m_curHistEntryIdx = 0;
 
-
-    m_historyMutex.unlock();
 }