Exemple #1
0
  virtual void Pack()
  {
    int width  = size.x - run->GetSizeX() - 2*5 -2*5;
    int height = run->GetSizeY();

    size.y = height + 2*border_size;
    bench->SetSizeX(width/2);
    score->SetSizeX(width/2);
    //run->SetPositionX(position.x + width);

    // Call first HBox::Pack to set positions
    HBox::Pack();

    // Set proper height now
    for (wit it = widget_list.begin(); it != widget_list.end(); ++it)
      (*it)->SetSizeY(height);
  }