From c90c389a8a8d9d8661e9772ec4144c5cf2039f23 Mon Sep 17 00:00:00 2001 From: toma Date: Wed, 25 Nov 2009 17:56:58 +0000 Subject: Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- konquest/planet_info.h | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 konquest/planet_info.h (limited to 'konquest/planet_info.h') diff --git a/konquest/planet_info.h b/konquest/planet_info.h new file mode 100644 index 00000000..4080f6b9 --- /dev/null +++ b/konquest/planet_info.h @@ -0,0 +1,53 @@ +#ifndef _PLANET_INFO_H_ +#define _PLANET_INFO_H_ + +#include +#include +#include +#include + +#include "gamecore.h" + +class QLabel; + +struct planet_info_buffer { + Planet *planet; + int production; + int ships; + float killRate; +}; + +typedef QPtrList PlanetInfoList; +typedef QPtrListIterator PlanetInfoListIterator; + +class PlanetInfo : public QFrame +{ + Q_OBJECT + +public: + PlanetInfo( QWidget *parent, QPalette palette ); + virtual ~PlanetInfo(); + + void setPlanetList( PlanetList &newPlanets ); + void rescanPlanets(); + QSize sizeHint() const; + +public slots: + void showPlanet( Planet * ); + +private: + void emptyPlanetInfoList(); + void clearDisplay(); + + PlanetList *planets; + PlanetInfoList planet_stats; + + QLabel *name; + QLabel *owner; + QLabel *ships; + QLabel *production; + QLabel *kill_percent; +}; + +#endif // _PLANET_INFO_H_ + -- cgit v1.2.1