| 436 | } |
| 437 | |
| 438 | void FlowPacker::GetNextPosition( int xSize, int ySize ) |
| 439 | { |
| 440 | xSize += 2*mBorderWidth; |
| 441 | ySize += 2*mBorderWidth; |
| 442 | // if the height has increased, then we are on a NEW group. |
| 443 | if(( ySize > myHeight )||(((mFlags ^ mOldFlags )& ~resFlagSkip)!=0)) |
| 444 | { |
| 445 | SetNewGroup( ((mFlags & resFlagPaired)!=0) ? 2 : 1 ); |
| 446 | myHeight = ySize; |
| 447 | // mFlags &= ~resFlagNewLine; |
| 448 | // mOldFlags = mFlags; |
| 449 | } |
| 450 | |
| 451 | iImageGroupIndex++; |
| 452 | if( iImageGroupIndex == iImageGroupSize ) |
| 453 | { |
| 454 | iImageGroupIndex = 0; |
| 455 | mxPos += mComponentWidth; |
| 456 | } |
| 457 | |
| 458 | if(mxPos > (mxCacheWidth - xSize )) |
| 459 | { |
| 460 | SetNewGroup(iImageGroupSize); |
| 461 | iImageGroupIndex++; |
| 462 | myHeight = ySize; |
| 463 | } |
| 464 | myPos = myPosBase + iImageGroupIndex * myHeight; |
| 465 | |
| 466 | mComponentWidth = xSize; |
| 467 | mComponentHeight = ySize; |
| 468 | } |
| 469 | |
| 470 | wxRect FlowPacker::Rect() |
| 471 | { |
no outgoing calls
no test coverage detected