Skip to content

Commit

Permalink
Safety check if our object recovery manages to find the overlay widget.
Browse files Browse the repository at this point in the history
Otherwise we end up in an infinite loop as described in issue #109.
  • Loading branch information
vkrause committed Jun 16, 2015
1 parent a22ad19 commit 048b384
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions plugins/widgetinspector/widgetinspectorserver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ void WidgetInspectorServer::widgetSelected(const QItemSelection &selection)
m_overlayWidget->placeOn(0);
return;
}
if (m_selectedWidget == m_overlayWidget) {
// this should not happen, but apparently our object recovery is slightly too good sometimes ;)
return;
}

m_overlayWidget->placeOn(m_selectedWidget);

Expand Down

0 comments on commit 048b384

Please sign in to comment.