Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5885 in orxonox.OLD for trunk/src/lib


Ignore:
Timestamp:
Dec 3, 2005, 1:29:42 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: classList: returns const lists

Location:
trunk/src/lib
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/graphics/importer/texture_sequence.cc

    r5865 r5885  
    155155
    156156/**
    157  * moves to the n'th texture which can then be retrieved via the Texture function: this->getTexture()
     157 * @brief moves to the n'th texture which can then be retrieved via the Texture function: this->getTexture()
    158158 * @param frameNumber the n-th frame
    159159 */
  • trunk/src/lib/graphics/text_engine/text_engine.cc

    r5780 r5885  
    6464{
    6565  // first remove all the remaining Texts (if any).
    66   std::list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
     66  const std::list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
    6767  if (textList != NULL)
    6868  {
     
    7171  }
    7272  // delete all remaining fonts (There should not be Anything to do here)
    73   std::list<BaseObject*>* fontList = ClassList::getList(CL_FONT);
     73  const std::list<BaseObject*>* fontList = ClassList::getList(CL_FONT);
    7474  if (fontList != NULL)
    7575  {
     
    124124void TextEngine::debug() const
    125125{
    126   list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
     126  const list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
    127127  if (textList != NULL)
    128128  {
     
    132132    PRINT(0)("Reference: %p; Text Counts: %d\n", this, textList->size());
    133133
    134     list<BaseObject*>::iterator text;
     134    list<BaseObject*>::const_iterator text;
    135135    for ( text = textList->begin(); text != textList->end(); text++)
    136136      dynamic_cast<Text*>(*text)->debug();
  • trunk/src/lib/lang/class_list.cc

    r5822 r5885  
    133133 * @return the List accessed by classID, or NULL if not found
    134134 */
    135 std::list<BaseObject*>* ClassList::getList(ClassID classID)
     135const std::list<BaseObject*>* ClassList::getList(ClassID classID)
    136136{
    137137  ClassList* fl;
     
    156156 * @return the List accessed by classID, or NULL if not found
    157157 */
    158 std::list<BaseObject*>* ClassList::getList(const char* className)
     158const std::list<BaseObject*>* ClassList::getList(const char* className)
    159159{
    160160  ClassList* fl;
  • trunk/src/lib/lang/class_list.h

    r5821 r5885  
    4040    static void                           removeFromClassList(BaseObject* objectPointer);
    4141
    42     static std::list<BaseObject*>*        getList(ClassID classID = CL_NULL);// { return (ClassList* fl = ClassList::getClassList(classID) != NULL)? &(fl->objectList) : NULL; };
    43     static std::list<BaseObject*>*        getList(const char* className); // { return (ClassList* fl = ClassList::getClassList(className) != NULL)? &(fl->objectList) : NULL;  };
     42    static const std::list<BaseObject*>*  getList(ClassID classID = CL_NULL);// { return (ClassList* fl = ClassList::getClassList(classID) != NULL)? &(fl->objectList) : NULL; };
     43    static const std::list<BaseObject*>*  getList(const char* className); // { return (ClassList* fl = ClassList::getClassList(className) != NULL)? &(fl->objectList) : NULL;  };
    4444    static const std::list<const char*>*  getClassNames();
    4545    static BaseObject*                    getObject(const char* name, ClassID classID = CL_NULL);
  • trunk/src/lib/network/network_manager.cc

    r5822 r5885  
    161161  if (this->netStreamList != NULL || (this->netStreamList = ClassList::getList(CL_NETWORK_STREAM)) != NULL)
    162162  {
    163     std::list<BaseObject*>::iterator stream;
     163    std::list<BaseObject*>::const_iterator stream;
    164164    for (stream = this->netStreamList->begin(); stream != this->netStreamList->end(); ++stream)
    165165      static_cast<NetworkStream*>(*stream)->processData();
  • trunk/src/lib/network/network_manager.h

    r5822 r5885  
    4141
    4242private:
    43   std::list<BaseObject*>*    netStreamList;            // list with refs to all network streams
    44   std::list<BaseObject*>*    syncList;                 // list of synchronizeables
     43  const std::list<BaseObject*>*    netStreamList;            // list with refs to all network streams
     44  const std::list<BaseObject*>*    syncList;                 // list of synchronizeables
    4545
    4646};
  • trunk/src/lib/shell/shell_command.cc

    r5791 r5885  
    159159  long classID = CL_NULL;                      //< the classID retrieved from the Class.
    160160  ShellCommandClass* commandClass = NULL;      //< the command class this command applies to.
    161   std::list<BaseObject*>* objectList = NULL;   //< the list of Objects stored in classID
     161  const std::list<BaseObject*>* objectList = NULL;   //< the list of Objects stored in classID
    162162  BaseObject* objectPointer = NULL;            //< a pointer to th Object to Execute the command on
    163163  bool emptyComplete = false;                  //< if the completion input is empty string. e.g ""
  • trunk/src/lib/shell/shell_completion.cc

    r5791 r5885  
    5858
    5959  long classID;                         //< the classID retrieved from the Class.
    60   std::list<BaseObject*>* objectList;   //< the list of Objects stored in classID
     60  const std::list<BaseObject*>* objectList;   //< the list of Objects stored in classID
    6161  bool emptyComplete = false;           //< if the completion input is empty string. e.g ""
    6262  long completeType = SHELLC_NONE;      //< the Type we'd like to complete.
  • trunk/src/lib/sound/sound_engine.cc

    r5856 r5885  
    137137  if (this->sourceList != NULL)
    138138  {
    139     list<BaseObject*>::iterator source;
     139    list<BaseObject*>::const_iterator source;
    140140    for (source = this->sourceList->begin(); source != this->sourceList->end(); source++)
    141141    {
     
    182182  if (likely(this->sourceList != NULL))
    183183  {
    184     list<BaseObject*>::iterator sourceIT;
     184    list<BaseObject*>::const_iterator sourceIT;
    185185    SoundSource* source;
    186186    for (sourceIT = this->sourceList->begin(); sourceIT != this->sourceList->end(); sourceIT++)
  • trunk/src/lib/sound/sound_engine.h

    r5819 r5885  
    6666
    6767  private:
    68     static SoundEngine*      singletonRef;             //!< Reference to this class
     68    static SoundEngine*            singletonRef;             //!< Reference to this class
    6969
    70     ALCdevice*               device;                   //!< the used audio-device.
    71     ALCcontext*              context;                  //!< the context, currently in use.
     70    ALCdevice*                     device;                   //!< the used audio-device.
     71    ALCcontext*                    context;                  //!< the context, currently in use.
    7272
    73     float                    musicVolume;              //!< the maximum volume of the music in % (0f,1f]
    74     float                    effectsVolume;            //!< the maximum volume of sound-effects in % (0f,1f]
    75     PNode*                   listener;                 //!< The listener of the Scene
     73    float                          musicVolume;              //!< the maximum volume of the music in % (0f,1f]
     74    float                          effectsVolume;            //!< the maximum volume of sound-effects in % (0f,1f]
     75    PNode*                         listener;                 //!< The listener of the Scene
    7676
    77     std::list<BaseObject*>*  bufferList;               //!< A list of buffers
    78     std::list<BaseObject*>*  sourceList;               //!< A list for all the sources in the scene.
     77    const std::list<BaseObject*>*  bufferList;               //!< A list of buffers
     78    const std::list<BaseObject*>*  sourceList;               //!< A list for all the sources in the scene.
    7979
    8080
Note: See TracChangeset for help on using the changeset viewer.