Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

GraphicsEnumerator.h

Go to the documentation of this file.
00001 #ifndef GraphicsEnumeratorH
00002 #define GraphicsEnumeratorH
00003 
00004 /*******************************************************************************
00005 Copyright 2001,2002 Petr Kulhanek
00006 
00007     This file is part of Core plugin.
00008 
00009     Core plugin is free software; you can redistribute it and/or modify
00010     it under the terms of the GNU General Public License as published by
00011     the Free Software Foundation; either version 2 of the License, or
00012     (at your option) any later version.
00013 
00014     Core plugin is distributed in the hope that it will be useful,
00015     but WITHOUT ANY WARRANTY; without even the implied warranty of
00016     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00017     GNU General Public License for more details.
00018 
00019     You should have received a copy of the GNU General Public License
00020     along with Core plugin; if not, write to the Free Software
00021     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00022 *******************************************************************************/
00023 /*******************************************************************************
00024 ** PROJECT:             Project NEMESIS
00025 ** FILE:                GraphicsEnumerator
00026 ** FUNCTION:            enumerator for all graphics class
00027 ** VERSION:             1.0
00028 ** LANGUAGE:            CBuilder C++
00029 ** TARGET COMPUTER:     IBM PC
00030 ** PROGRAMMER:          Petr Kulhánek
00031 ** HISTORY:
00032 VERSION DATE        NOTE
00033 *******************************************************************************/
00034 
00038 /* HEADER FILES ***************************************************************/
00039 
00040 #include "CoreMainHeader.h"
00041 #include "ContainerEnumerator.h"
00042 #include "SimpleList.h"
00043 #include "SmallString.h"
00044 
00045 /* HEADER FILES END ***********************************************************/
00046 
00047 
00048 class CPluginObjectInfo;
00049 class CExtUUID;
00050 class CComObject;
00051 class CGraphicsObjectsList;
00052 class CGraphicsObject;
00053 class CGraphicsProfile;
00054 
00055 // ----------------------------------------------------------------------------
00056 // ############################################################################
00057 // ----------------------------------------------------------------------------
00058 
00059 extern CPluginObjectInfo DisplayEnumObjectInfo;
00060 extern CExtUUID          ID_DisplayEnum;
00061 
00062 // ----------------------------------------------------------------------------
00063 
00065 
00068 class NEMESIS_CORE_PACKAGE CDisplayEnumerator : public CContainerEnumerator {
00069     public:
00070         __fastcall CDisplayEnumerator(CComObject* owner,CGraphicsObjectsList* p_gbl);
00071 
00072     virtual CContainerEnumerator* __fastcall GetFirstSubContainer(void);
00073     virtual CContainerEnumerator* __fastcall GetNextSubContainer(void);
00074 
00075     virtual bool __fastcall ContainSubContainers(void);
00076 
00077     virtual int         __fastcall NumOfObjects(void);
00078     virtual bool        __fastcall PrepareObjects(int startpos,int size,int rstart,int rend);
00079     virtual CExtObject* __fastcall GetObject(int pos);
00080 
00081     virtual int __fastcall NumOfColumns(void);  // počet sloupců popisujících objekt
00082     virtual const CSmallString __fastcall GetColumnCaption(int index); // popis sloupce
00083     virtual const CSmallString __fastcall GetObjectProperty(int index); // vlastnost objektu
00084     virtual int __fastcall GetObjectImageIndex(void);
00085     virtual CExtObject* __fastcall GetCurrentObject(void);
00086     virtual bool __fastcall SetCurrentObject(CExtObject* p_object);
00087     
00088     private:
00089     CSimpleList<CContainerEnumerator>       SubContainers;
00090     CSimpleIterator<CContainerEnumerator>   Pointer;
00091     CGraphicsObjectsList*                   GraphicsObjectList;
00092     CContainerEnumerator*                   CurrentObject;
00093 
00094     bool __fastcall PrepareSubContainers(void);
00095     };
00096 
00097 // ----------------------------------------------------------------------------
00098 // ############################################################################
00099 // ----------------------------------------------------------------------------
00100 
00101 extern CPluginObjectInfo GraphicsObjectEnumObjectInfo;
00102 extern CExtUUID          ID_GraphicsObjectEnum;
00103 
00104 //------------------------------------------------------------------------------
00105 
00107 
00110 class NEMESIS_CORE_PACKAGE CGraphicsObjectEnumerator : public CContainerEnumerator {
00111     public:
00112         __fastcall CGraphicsObjectEnumerator(CComObject* owner,CGraphicsObjectsList* p_gbl);
00113 
00114     virtual int __fastcall NumOfCommands(void);
00115     virtual CSmallString __fastcall GetCommand(int i,bool& enabled);
00116     virtual bool __fastcall DoCommand(int i);
00117 
00118     virtual int         __fastcall NumOfObjects(void);
00119     virtual bool        __fastcall PrepareObjects(int startpos,int size,int rstart,int rend);
00120     virtual CExtObject* __fastcall GetObject(int pos);
00121 
00122  // funkce pro rozšířený popis objektů a kontejnerů ----------------------------
00123     virtual int __fastcall NumOfColumns(void);  // počet sloupců popisujících objekt
00124     virtual const CSmallString __fastcall GetColumnCaption(int index); // popis sloupce
00125     virtual const CSmallString __fastcall GetObjectProperty(int index); // vlastnost objektu
00126     virtual int __fastcall GetObjectImageIndex(void);
00127     virtual CExtObject* __fastcall GetCurrentObject(void);
00128     virtual bool __fastcall SetCurrentObject(CExtObject* p_object);
00129     
00130     private:
00131     CGraphicsObjectsList*               GraphicsObjectList;
00132     CTemplIterator<CGraphicsObject>     Pointer;
00133     CGraphicsObject*                    CurrentObject;
00134     int                                 StartPos;
00135     int                                 EndPos;
00136     bool                                Changed;
00137     CSimpleList<CGraphicsObject>        CurrentView;
00138 
00139     void __fastcall ProcessEvent(const CEventIdentifier& event,CExtObject* Sender,void* p_data);
00140 
00141     void __fastcall PrepareImageIndex(void);
00142     };
00143 
00144 // ----------------------------------------------------------------------------
00145 // ############################################################################
00146 // ----------------------------------------------------------------------------
00147 
00148 extern CPluginObjectInfo GraphicsProfileEnumObjectInfo;
00149 extern CExtUUID          ID_GraphicsProfileEnum;
00150 
00151 class CGraphicsProfileObjectEnumerator;
00152 
00153 // ----------------------------------------------------------------------------
00154 
00156 
00159 class NEMESIS_CORE_PACKAGE CGraphicsProfileEnumerator : public CContainerEnumerator {
00160     public:
00161         __fastcall CGraphicsProfileEnumerator(CComObject* owner,CGraphicsObjectsList* p_gbl);
00162 
00163     virtual int __fastcall NumOfCommands(void);
00164     virtual CSmallString __fastcall GetCommand(int i,bool& enabled);
00165     virtual bool __fastcall DoCommand(int i);
00166 
00167     virtual CContainerEnumerator* __fastcall GetFirstSubContainer(void);
00168     virtual CContainerEnumerator* __fastcall GetNextSubContainer(void);
00169 
00170     virtual bool __fastcall ContainSubContainers(void);
00171 
00172     virtual int         __fastcall NumOfObjects(void);
00173     virtual bool        __fastcall PrepareObjects(int startpos,int size,int rstart,int rend);
00174     virtual CExtObject* __fastcall GetObject(int pos);
00175 
00176     virtual int __fastcall NumOfColumns(void);  // počet sloupců popisujících objekt
00177     virtual const CSmallString __fastcall GetColumnCaption(int index); // popis sloupce
00178     virtual const CSmallString __fastcall GetObjectProperty(int index); // vlastnost objektu
00179     virtual int __fastcall GetObjectImageIndex(void);
00180     virtual CExtObject* __fastcall GetCurrentObject(void);
00181     virtual bool __fastcall SetCurrentObject(CExtObject* p_object);
00182     
00183     private:
00184     CSimpleList<CGraphicsProfileObjectEnumerator>       SubContainers;
00185     CSimpleIterator<CGraphicsProfileObjectEnumerator>   Pointer;
00186     CGraphicsObjectsList*                               GraphicsObjectList;
00187     CGraphicsProfileObjectEnumerator*                   CurrentObject;
00188     bool                                                Changed;
00189 
00190     void __fastcall PrepareImageIndex(void);
00191     bool __fastcall PrepareSubContainers(void);
00192     void __fastcall ProcessEvent(const CEventIdentifier& event,CExtObject* Sender,void* p_data);
00193     };
00194 
00195 // ----------------------------------------------------------------------------
00196 // ############################################################################
00197 // ----------------------------------------------------------------------------
00198 
00199 extern CPluginObjectInfo GraphicsProfileObjectEnumObjectInfo;
00200 extern CExtUUID          ID_GraphicsProfileObjectEnum;
00201 
00202 //------------------------------------------------------------------------------
00203 
00205 
00208 class NEMESIS_CORE_PACKAGE CGraphicsProfileObjectEnumerator : public CContainerEnumerator {
00209     public:
00210         __fastcall CGraphicsProfileObjectEnumerator(CComObject* owner,CGraphicsProfile* p_gp);
00211 
00212     virtual int __fastcall NumOfCommands(void);
00213     virtual CSmallString __fastcall GetCommand(int i,bool& enabled);
00214     virtual bool __fastcall DoCommand(int i);
00215 
00216     virtual int         __fastcall NumOfObjects(void);
00217     virtual bool        __fastcall PrepareObjects(int startpos,int size,int rstart,int rend);
00218     virtual CExtObject* __fastcall GetObject(int pos);
00219 
00220  // funkce pro rozšířený popis objektů a kontejnerů ----------------------------
00221     virtual int __fastcall NumOfColumns(void);  // počet sloupců popisujících objekt
00222     virtual const CSmallString __fastcall GetColumnCaption(int index); // popis sloupce
00223     virtual const CSmallString __fastcall GetObjectProperty(int index); // vlastnost objektu
00224     virtual int __fastcall GetObjectImageIndex(void);
00225     virtual CExtObject* __fastcall GetCurrentObject(void);
00226     virtual bool __fastcall SetCurrentObject(CExtObject* p_object);
00227 
00228     CGraphicsProfile*                GraphicsProfile;
00229 
00230     private:
00231     CSimpleIterator<CGraphicsObject> Pointer;
00232     CGraphicsObject*                 CurrentObject;
00233     int                              StartPos;
00234     int                              EndPos;
00235     bool                             Changed;
00236     CSimpleList<CGraphicsObject>     CurrentView;
00237 
00238     void __fastcall ProcessEvent(const CEventIdentifier& event,CExtObject* Sender,void* p_data);
00239     };
00240 
00241 // ----------------------------------------------------------------------------
00242 // ############################################################################
00243 // ----------------------------------------------------------------------------
00244 
00245 
00246 #endif

Generated on Sun Feb 9 12:53:50 2003 for NemesisCore by doxygen1.3-rc2