1
0
Fork 0

- move the ID stuff to dialog.hxx

- add an identifier to fgPropertyList(), which is also PUCLASS_LIST based
This commit is contained in:
mfranz 2006-05-22 16:14:50 +00:00
parent 9ff339332c
commit e2c195f3a6
5 changed files with 14 additions and 11 deletions

View file

@ -7,16 +7,9 @@
#include STL_STRING
#include <plib/pu.h>
#include "dialog.hxx"
// ugly temproary workaround for plib's lack of user defined class ids FIXME
#define FGCLASS_LIST 0x00000001
#define FGCLASS_AIRPORTLIST 0x00000002
class GUI_ID { public: GUI_ID(int id) : id(id) {} int id; };
#include "puList.hxx"
SG_USING_STD(string);
class FGAirportList;

View file

@ -16,6 +16,9 @@
#include "property_list.hxx"
#include "layout.hxx"
////////////////////////////////////////////////////////////////////////
// Implementation of GUIInfo.
////////////////////////////////////////////////////////////////////////

View file

@ -20,7 +20,13 @@
#include <vector>
SG_USING_STD(vector);
#include "AirportList.hxx"
// ugly temproary workaround for plib's lack of user defined class ids FIXME
#define FGCLASS_LIST 0x00000001
#define FGCLASS_AIRPORTLIST 0x00000002
#define FGCLASS_PROPERTYLIST 0x00000004
class GUI_ID { public: GUI_ID(int id) : id(id) {} int id; };
class FGDialog;

View file

@ -80,6 +80,7 @@ static string getValueTypeString(const SGPropertyNode *node)
PropertyList::PropertyList(int minx, int miny, int maxx, int maxy, SGPropertyNode *start) :
puList(minx, miny, maxx, maxy, short(0), 20),
GUI_ID(FGCLASS_PROPERTYLIST),
_curr(start),
_flags(fgGetNode("/sim/gui/dialogs/property-browser/show-flags", true)),
_return(0),

View file

@ -26,11 +26,11 @@
#include <plib/pu.h>
#include <simgear/props/props.hxx>
#include "dialog.hxx"
#include "puList.hxx"
class PropertyList : public puList, public SGPropertyChangeListener {
class PropertyList : public puList, public SGPropertyChangeListener, public GUI_ID {
public:
PropertyList(int minx, int miny, int maxx, int maxy, SGPropertyNode *);
~PropertyList();