branchitem.cpp
changeset 763 8c028a5d9083
parent 762 ffb95cd03156
child 767 6d2b32f305f9
     1.1 --- a/branchitem.cpp	Thu Apr 30 11:52:49 2009 +0000
     1.2 +++ b/branchitem.cpp	Fri May 01 10:30:29 2009 +0000
     1.3 @@ -204,29 +204,36 @@
     1.4  
     1.5  void BranchItem::toggleScroll()
     1.6  {
     1.7 +	BranchItem *bi=getFirstBranch();
     1.8 +
     1.9 +	BranchObj *bo=NULL;
    1.10  	if (scrolled)
    1.11  	{
    1.12  		scrolled=false;
    1.13  		//FIXME-1 systemFlags->deactivate("scrolledright");
    1.14 -		/*
    1.15 -		for (int i=0; i<branch.size(); ++i)
    1.16 -			branch.at(i)->setVisibility(true);
    1.17 -		*/	
    1.18 +		while (bi)
    1.19 +		{
    1.20 +			bo=(BranchObj*)(bi->getLMO());
    1.21 +			if (bo) bo->setVisibility(true);
    1.22 +			bi=getNextBranch(bi);
    1.23 +		}
    1.24  	} else
    1.25  	{
    1.26  		scrolled=true;
    1.27 -		/*
    1.28  		//FIXME-1 systemFlags->activate("scrolledright");
    1.29 -		for (int i=0; i<branch.size(); ++i)
    1.30 -			branch.at(i)->setVisibility(false);
    1.31 -		*/	
    1.32 +		while (bi)
    1.33 +		{
    1.34 +			bo=(BranchObj*)(bi->getLMO());
    1.35 +			if (bo) bo->setVisibility(false);
    1.36 +			bi=getNextBranch(bi);
    1.37 +		}
    1.38  	}
    1.39 -	/*	
    1.40 -	calcBBoxSize();
    1.41 -	positionBBox();	
    1.42 -	move (absPos.x(), absPos.y() );
    1.43 -	forceReposition();
    1.44 -	*/
    1.45 +	if (bo)
    1.46 +	{
    1.47 +		bo->calcBBoxSize();
    1.48 +		bo->positionBBox();	
    1.49 +		bo->forceReposition();
    1.50 +	}
    1.51  }
    1.52  
    1.53  bool BranchItem::isScrolled()