diff options
author | Jason Barron <jbarron@trolltech.com> | 2009-08-25 09:59:38 (GMT) |
---|---|---|
committer | Jason Barron <jbarron@trolltech.com> | 2009-08-25 10:04:39 (GMT) |
commit | 59d974cfd899832dc88c0183582147162bf721be (patch) | |
tree | 272b634a6f8691b555b73ba0ccfe721a88d0035a /src/gui/widgets/qlineedit.cpp | |
parent | ba60e4bedde9c8ef002289ebe60d25ad95f20707 (diff) | |
download | Qt-59d974cfd899832dc88c0183582147162bf721be.zip Qt-59d974cfd899832dc88c0183582147162bf721be.tar.gz Qt-59d974cfd899832dc88c0183582147162bf721be.tar.bz2 |
Some cleanups after code review.
Some minor harmless fixes after feedback from code review.
Reviewed-by: Espen Riskedal
Diffstat (limited to 'src/gui/widgets/qlineedit.cpp')
-rw-r--r-- | src/gui/widgets/qlineedit.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/gui/widgets/qlineedit.cpp b/src/gui/widgets/qlineedit.cpp index 6b73e21..299ecfc 100644 --- a/src/gui/widgets/qlineedit.cpp +++ b/src/gui/widgets/qlineedit.cpp @@ -1395,8 +1395,7 @@ bool QLineEdit::event(QEvent * e) if (e->type() == QEvent::EnterEditFocus) { end(false); d->setCursorVisible(true); - int cft = QApplication::cursorFlashTime(); - d->control->setCursorBlinkPeriod(cft/2); + d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()/2); } else if (e->type() == QEvent::LeaveEditFocus) { d->setCursorVisible(false); d->control->setCursorBlinkPeriod(0); @@ -1691,8 +1690,7 @@ void QLineEdit::focusInEvent(QFocusEvent *e) #ifdef QT_KEYPAD_NAVIGATION if (!QApplication::keypadNavigationEnabled() || (hasEditFocus() && e->reason() == Qt::PopupFocusReason)){ #endif - int cft = QApplication::cursorFlashTime(); - d->control->setCursorBlinkPeriod(cft/2); + d->control->setCursorBlinkPeriod(QApplication::cursorFlashTime()/2); QStyleOptionFrameV2 opt; initStyleOption(&opt); if((!hasSelectedText() && d->control->preeditAreaText().isEmpty()) |