Commit 945f9183 authored by Jocelyn Turcotte's avatar Jocelyn Turcotte
Browse files

Don't use the private QQuickItemPrivate::focusNextPrev


Do what focusNextPrev does internally. Also fix the tab-focus
by getting the next item relatively to the delegate (the
scopedFocusItem()) instead of the view itself.

Change-Id: I0d35a12bd5ef54d69df35b29ccdd55ac2301eec8
Reviewed-by: default avatarMichael Bruning <michael.bruning@digia.com>
Reviewed-by: default avatarZeno Albisser <zeno.albisser@digia.com>
Showing with 3 additions and 1 deletion
......@@ -209,7 +209,9 @@ void QQuickWebEngineViewPrivate::runFileChooser(FileChooserMode mode, const QStr
void QQuickWebEngineViewPrivate::passOnFocus(bool reverse)
{
Q_Q(QQuickWebEngineView);
focusNextPrev(q, !reverse);
// The child delegate currently has focus, find the next one from there and give it focus.
QQuickItem *next = q->scopedFocusItem()->nextItemInFocusChain(!reverse);
next->forceActiveFocus(reverse ? Qt::BacktabFocusReason : Qt::TabFocusReason);
}
void QQuickWebEngineViewPrivate::titleChanged(const QString &title)
......
Supports Markdown
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