Show
Ignore:
Timestamp:
03/21/12 18:36:20 (2 years ago)
Author:
robert
Message:

Ran script to remove trailing spaces and tabs

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/include/osg/Referenced

    r12897 r13041  
    1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield  
     1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield 
    22 * 
    3  * This library is open source and may be redistributed and/or modified under   
    4  * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or  
     3 * This library is open source and may be redistributed and/or modified under 
     4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or 
    55 * (at your option) any later version.  The full license is in LICENSE file 
    66 * included with this distribution, and on the openscenegraph.org website. 
    7  *  
     7 * 
    88 * This library is distributed in the hope that it will be useful, 
    99 * but WITHOUT ANY WARRANTY; without even the implied warranty of 
    10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the  
     10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
    1111 * OpenSceneGraph Public License for more details. 
    1212*/ 
     
    4646 
    4747 
    48         Referenced();  
    49          
    50         explicit Referenced(bool threadSafeRefUnref);  
     48        Referenced(); 
     49 
     50        explicit Referenced(bool threadSafeRefUnref); 
    5151 
    5252        Referenced(const Referenced&); 
     
    7575        static OpenThreads::Mutex* getGlobalReferencedMutex(); 
    7676 
    77         /** Increment the reference count by one, indicating that  
     77        /** Increment the reference count by one, indicating that 
    7878            this object has another pointer which is referencing it.*/ 
    7979        inline int ref() const; 
    80          
    81         /** Decrement the reference count by one, indicating that  
     80 
     81        /** Decrement the reference count by one, indicating that 
    8282            a pointer to this object is no longer referencing it.  If the 
    8383            reference count goes to zero, it is assumed that this object 
    8484            is no longer referenced and is automatically deleted.*/ 
    8585        inline int unref() const; 
    86          
    87         /** Decrement the reference count by one, indicating that  
     86 
     87        /** Decrement the reference count by one, indicating that 
    8888            a pointer to this object is no longer referencing it.  However, do 
    89             not delete it, even if ref count goes to 0.  Warning, unref_nodelete()  
     89            not delete it, even if ref count goes to 0.  Warning, unref_nodelete() 
    9090            should only be called if the user knows exactly who will 
    91             be responsible for, one should prefer unref() over unref_nodelete()  
     91            be responsible for, one should prefer unref() over unref_nodelete() 
    9292            as the latter can lead to memory leaks.*/ 
    9393        int unref_nodelete() const; 
    94          
     94 
    9595        /** Return the number of pointers currently referencing this object. */ 
    9696        inline int referenceCount() const { return _refCount; } 
     
    120120        /** Set whether reference counting should use a mutex for thread safe reference counting.*/ 
    121121        static void setThreadSafeReferenceCounting(bool enableThreadSafeReferenceCounting); 
    122          
     122 
    123123        /** Get whether reference counting is active.*/ 
    124124        static bool getThreadSafeReferenceCounting(); 
     
    133133        static DeleteHandler* getDeleteHandler(); 
    134134 
    135         
     135 
    136136    protected: 
    137      
     137 
    138138        virtual ~Referenced(); 
    139139 
     
    147147        mutable OpenThreads::Atomic     _refCount; 
    148148#else 
    149          
     149 
    150150        mutable OpenThreads::Mutex*     _refMutex; 
    151151 
    152152        mutable int                     _refCount; 
    153          
     153 
    154154        mutable void*                   _observerSet; 
    155155#endif 
     
    163163    if (_refMutex) 
    164164    { 
    165         OpenThreads::ScopedLock<OpenThreads::Mutex> lock(*_refMutex);  
     165        OpenThreads::ScopedLock<OpenThreads::Mutex> lock(*_refMutex); 
    166166        return ++_refCount; 
    167167    } 
     
    183183    if (_refMutex) 
    184184    { 
    185         OpenThreads::ScopedLock<OpenThreads::Mutex> lock(*_refMutex);  
     185        OpenThreads::ScopedLock<OpenThreads::Mutex> lock(*_refMutex); 
    186186        newRef = --_refCount; 
    187187        needDelete = newRef==0;