summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eblomfel@trolltech.com>2009-08-06 13:05:32 (GMT)
committerEskil Abrahamsen Blomfeldt <eblomfel@trolltech.com>2009-08-06 13:08:10 (GMT)
commitd738bfe0f06448d9a6bc2ee1a32225c076c67334 (patch)
tree0d288a2eaf10a3883bcb8991833b2e041edb35a8 /src/gui
parentef07fa46ed352176eba3c58268fd6bb1512cd70f (diff)
downloadQt-d738bfe0f06448d9a6bc2ee1a32225c076c67334.zip
Qt-d738bfe0f06448d9a6bc2ee1a32225c076c67334.tar.gz
Qt-d738bfe0f06448d9a6bc2ee1a32225c076c67334.tar.bz2
Make sure cursorPositionChanged is emitted when cursor position changes
When selecting the text and setting the cursor position, we need to emit the cursorPositionChanged signal. This seems to be a copy-paste error from refactoring QLineEdit, as the function call is there in the original version of setSelection(). The effect was two test breakages in tst_QDateTimeEdit, because the section and cursor position of the QDateTimeEdit would be out of sync. Reviewed-by: Gunnar
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/widgets/qlinecontrol.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gui/widgets/qlinecontrol.cpp b/src/gui/widgets/qlinecontrol.cpp
index d90d53b..f4a2348 100644
--- a/src/gui/widgets/qlinecontrol.cpp
+++ b/src/gui/widgets/qlinecontrol.cpp
@@ -257,6 +257,7 @@ void QLineControl::setSelection(int start, int length)
m_cursor = m_selstart;
}
emit selectionChanged();
+ emitCursorPositionChanged();
}
void QLineControl::_q_clipboardChanged()