home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Komputer 1997 May
/
Pcwk0597.iso
/
sybase
/
starbuck
/
hpp.z
/
MTOBJECT.HPP
< prev
next >
Wrap
C/C++ Source or Header
|
1996-12-03
|
3KB
|
90 lines
#ifndef _MTOBJECT_HPP
#define _MTOBJECT_HPP
#include "mtdef.hpp"
#include "mmcomp.hpp"
class WStringList;
class DTObject;
class MTPropertyDialog;
class MTHashTable;
enum MMBitmapSize {
MMBmpS_Small, // 16 x 16
MMBmpS_Medium, // 24 x 24
MMBmpS_Large, // 32 x 32
MMBmpS_NumSizes,
};
class METACLASSDEF MetaObject : public MMComponent {
public:
MetaObject( const MMComponentData * data );
MetaObject();
MetaObject( const MetaObject & o );
MetaObject & operator=( const MetaObject & o );
virtual ~MetaObject();
virtual WConstantString GetName() const;
virtual WBool GetDerivedFrom( const WString & ) const;
virtual const MMEventList & EventList() const;
virtual const MMStyleList & StyleList() const;
virtual const MMPropertyList & PropertyList() const;
virtual const MMMethodList & MethodList() const;
virtual const MMPropertySheetList & PropertySheetList() const;
virtual DTObject * Instantiate() const;
virtual WBool GetBitmap( WBitmap & bmp,
MMBitmapSize size ) const;
virtual WBool GetIcon( WIcon & bmp,
MMBitmapSize size ) const;
virtual MTPropertyDialog * CreatePropDialog() const;
virtual WBool CreateEventPopupMenu( DTObject *,
WPopupMenu * ) const;
virtual MetaObject * GetBaseObject() const;
virtual WStyle GetMappedMask() const;
virtual WStyle GetExMappedMask() const;
virtual const MMProperty * FindProperty( const char * ) const;
virtual const MMStyle * FindStyle( const char * ) const;
virtual WUInt GetNumMappedProperties() const;
virtual const MMProperty * GetMappedProperty( WUInt idx ) const;
private:
virtual WBool InitMetaObject();
void InitFindProps();
friend class MMComponentLib;
private:
MetaObject * _base;
WConstantString _name;
WBool _initialized;
WBool _eventListInit;
WBool _styleListInit;
WBool _propertyListInit;
WBool _methodListInit;
WBool _propertySheetListInit;
WBool _mappedPropertyListInit;
MMEventList _eventList;
MMStyleList _styleList;
MMPropertyList _propertyList;
MMMethodList _methodList;
MMPropertySheetList _propertySheetList;
MMPropertyList _mappedProperties;
MTHashTable * _findProperties;
MTHashTable * _findStyles;
};
typedef MetaObject MetaWObject;
#endif // _MTOBJECT_HPP