Cast the parent being checked rather than parentItem()
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=743922
This commit is contained in:
parent
220094f3a8
commit
89a387b76d
@ -298,7 +298,7 @@ Widget *Widget::parent() const
|
||||
QGraphicsItem *parent = parentItem();
|
||||
|
||||
while (parent) {
|
||||
Widget *parentWidget = dynamic_cast<Widget *>(parentItem());
|
||||
Widget *parentWidget = dynamic_cast<Widget *>(parent);
|
||||
|
||||
if (parentWidget) {
|
||||
return parentWidget;
|
||||
|
Loading…
Reference in New Issue
Block a user