Automatically hide the SIP

Change-Id: I4d63a883941842aed9a9c3806479d7aeeebb9f56
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
This commit is contained in:
BogDan Vatra 2013-02-08 10:04:30 +02:00 committed by The Qt Project
parent c080f1f98a
commit c4b88b0540
2 changed files with 5 additions and 1 deletions

View File

@ -8567,6 +8567,10 @@ void QWidget::focusOutEvent(QFocusEvent *)
{ {
if (focusPolicy() != Qt::NoFocus || !isWindow()) if (focusPolicy() != Qt::NoFocus || !isWindow())
update(); update();
// automatically hide the SIP
if (qApp->autoSipEnabled() && testAttribute(Qt::WA_InputMethodEnabled))
qApp->inputMethod()->hide();
} }
/*! /*!

View File

@ -1758,7 +1758,7 @@ void QLineEdit::focusOutEvent(QFocusEvent *e)
QObject::disconnect(d->control->completer(), 0, this, 0); QObject::disconnect(d->control->completer(), 0, this, 0);
} }
#endif #endif
update(); QWidget::focusOutEvent(e);
} }
/*!\reimp /*!\reimp