Commit 812adaa2 authored by Albert Astals Cid's avatar Albert Astals Cid
Browse files

FormLineEdit: Move editing=false up in the focus out event

The fact that we don't want to process the focusout/formatfield actions
doesn't mean we are still editing the field
parent 10304223
......@@ -487,11 +487,12 @@ bool FormLineEdit::event(QEvent *e)
emit m_controller->focusAction(action, fft);
} else if (e->type() == QEvent::FocusOut) {
m_editing = false;
// Don't worry about focus events from other sources than the user FocusEvent to edit the field
QFocusEvent *focusEvent = static_cast<QFocusEvent *>(e);
if (focusEvent->reason() == Qt::OtherFocusReason)
return true;
m_editing = false;
if (const Okular::Action *action = m_ff->additionalAction(Okular::Annotation::FocusOut)) {
bool ok = false;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment