QTfrontend/teamselect.h
author unc0rr
Sat, 08 Jul 2006 21:40:03 +0000
changeset 74 42257fee61ae
parent 63 27e2b5bb6d4b
child 117 d21a48200772
permissions -rw-r--r--
- Unicode support for team and hedgehogs names - Clouds move in vertical direction also - Many fixes to hedgehog physics - Support for different images in 16 and 32 bit screen resolution - Fixed bots behavior after attack - Fixed camera behavior right after the game start

#ifndef _TEAM_SELECT_INCLUDED
#define _TEAM_SELECT_INCLUDED

#include <QWidget>
#include <QVBoxLayout>
class QFrame;

#include <list>
#include <map>

class TeamSelWidget;
class FrameTeams;

using namespace std;

struct tmprop
{
  tmprop(QString nm) : teamName(nm) {};
  QString teamName;
  QString pixmapFileName;
  bool operator==(const tmprop& t1) const {
    return teamName==t1.teamName;
  };
  bool operator<(const tmprop& t1) const {
    return teamName<t1.teamName;
  };
};

class TeamSelWidget : public QWidget
{
  Q_OBJECT
 
 public:
  TeamSelWidget(QWidget* parent=0);
  void addTeam(tmprop team);
  void removeTeam(tmprop team);

private slots:
  void changeTeamStatus(tmprop team);

 private:
  void addScrArea(FrameTeams* pfteams, QColor color);
  FrameTeams* frameDontPlaying;
  FrameTeams* framePlaying;

  QVBoxLayout mainLayout;

  list<tmprop> curPlayingTeams;
  list<tmprop> curDontPlayingTeams;
};

#endif // _TEAM_SELECT_INCLUDED