Skip to content

Commit 9ca4093

Browse files
author
g_j_m
committed
Work around for ticket #405 (incorrect drawing of expanded file groups
in the legen). Not sure why it works... git-svn-id: http://svn.osgeo.org/qgis/trunk@6163 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent bc018dd commit 9ca4093

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/legend/qgslegend.cpp

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1662,11 +1662,17 @@ void QgsLegend::showLegendLayerFileGroups()
16621662

16631663
do
16641664
{
1665+
// This call seems to fix a bug in Qt4.2 (qgis trac #405) whereby the
1666+
// setHidden() call in the if statement below doesn't result in
1667+
// correct drawing of the visible file group part of the tree,
1668+
// but doing this setHidden() call does result in correct drawing.
1669+
theItem->setHidden(false);
1670+
16651671
theFileGroup = dynamic_cast<QgsLegendLayerFileGroup*>(theItem);
16661672
if(theFileGroup)
1667-
{
1668-
theFileGroup->setHidden(!mShowLegendLayerFiles);
1669-
}
1673+
{
1674+
theFileGroup->setHidden(!mShowLegendLayerFiles);
1675+
}
16701676
}
16711677
while(theItem = nextItem(theItem));
16721678
}

0 commit comments

Comments
 (0)