int left = 0;
int bottom = groupList.size() > 1 ? 95 : 50;
for(int i = 0; i < groupList.size(); i++){
IVTabGroup group = groupList.get(i);
ScrolledComposite groupContainer = group.getComposite();
Control control = group.getPeer();
if(group.isSelected()){
control.setBounds(left, top, barSize.x, titleHeight);
top += titleHeight - 1;
int controlBottom = layoutBottomUp(groupList, i, left, barSize.x, barSize.y);
groupContainer.setVisible(true);
groupContainer.setBounds(left, top, barSize.x, controlBottom - top);
groupContainer.getContent().setBounds(left, 0, barSize.x - 4, group.getItemList().size()*(barSize.y- bottom));//95
return;
}
control.setBounds(0, top, barSize.x, titleHeight);
top += titleHeight;
groupContainer.setVisible(false);