Skip to content

Commit

Permalink
Merge pull request #42 from llewelld/jb57688
Browse files Browse the repository at this point in the history
[qtmozembed] Avoid sending orientation signal on scene changes. Fixes JB#57688
  • Loading branch information
llewelld authored Mar 7, 2022
2 parents d536219 + eed2b5c commit 5c671a5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/quickmozview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,12 @@ void QuickMozView::itemChange(ItemChange change, const ItemChangeData &data)
if (data.window) {
connect(data.window, &QQuickWindow::contentOrientationChanged, this, &QuickMozView::updateOrientation);

// Update the orientation, but without emitting an orientationChanged signal
// Emitting the signal at this point will cause a SIGSEGV because
// the QML item isn't ready to be activated just yet, see JB#57688
blockSignals(true);
updateOrientation(data.window->contentOrientation());
blockSignals(false);
}
}
QQuickItem::itemChange(change, data);
Expand Down

0 comments on commit 5c671a5

Please sign in to comment.