emailuis/uicomponents/src/fstreevisualizerbase.cpp
branchRCL_3
changeset 16 b5fbb9b25d57
parent 12 4ce476e64c59
child 17 67369d1b217f
--- a/emailuis/uicomponents/src/fstreevisualizerbase.cpp	Tue Apr 27 16:20:14 2010 +0300
+++ b/emailuis/uicomponents/src/fstreevisualizerbase.cpp	Tue May 11 15:57:15 2010 +0300
@@ -2535,7 +2535,11 @@
 void CFsTreeVisualizerBase::SetItemsAlwaysExtendedL(TBool aAlwaysExtended)
     {
     FUNC_LOG;
-    if (iFlags.IsSet(EItemsAlwaysExtended) != aAlwaysExtended )
+    // Do not change this to: IsItemsAlwaysExtended() != aAlwaysExtended, because
+    // it will not work. TBool is defined as TInt and thus this comparison
+    // comes out as TInt != TInt, which always evaluates true in this case.
+    if ( ( IsItemsAlwaysExtended() && !aAlwaysExtended ) || 
+         ( !IsItemsAlwaysExtended() && aAlwaysExtended ) )
         {
         iFlags.Assign(EItemsAlwaysExtended, aAlwaysExtended);
         TFsTreeIterator treeIter(