From c3a8485e91cc86e9e886712acb1b9a70d96382e9 Mon Sep 17 00:00:00 2001 From: Alan Alpert Date: Wed, 26 Aug 2009 14:32:25 +1000 Subject: Fix another minor copy'n'paste error from QLineControl refactoring Had left the cursor flash time as half the QApplication cursor flash time by mistake. The new function sets the whole period and not just the time between toggling cursor visibility. Reviewed-by: Trust Me --- src/gui/widgets/qlineedit.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/widgets/qlineedit.cpp b/src/gui/widgets/qlineedit.cpp index 299ecfc..f36a995 100644 --- a/src/gui/widgets/qlineedit.cpp +++ b/src/gui/widgets/qlineedit.cpp @@ -1395,7 +1395,7 @@ bool QLineEdit::event(QEvent * e) if (e->type() == QEvent::EnterEditFocus) { end(false); d->setCursorVisible(true); - d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()/2); + d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()); } else if (e->type() == QEvent::LeaveEditFocus) { d->setCursorVisible(false); d->control->setCursorBlinkPeriod(0); @@ -1690,7 +1690,7 @@ void QLineEdit::focusInEvent(QFocusEvent *e) #ifdef QT_KEYPAD_NAVIGATION if (!QApplication::keypadNavigationEnabled() || (hasEditFocus() && e->reason() == Qt::PopupFocusReason)){ #endif - d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()/2); + d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()); QStyleOptionFrameV2 opt; initStyleOption(&opt); if((!hasSelectedText() && d->control->preeditAreaText().isEmpty()) -- cgit v0.12