Changeset 10358
- Timestamp:
- Apr 12, 2015, 3:27:09 PM (10 years ago)
- Location:
- code/branches/core7/src/libraries/core
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core7/src/libraries/core/BaseObject.cc
r9667 r10358 86 86 { 87 87 this->file_ = 0; 88 this->namespace_ = 0;89 this->scene_ = 0;90 88 this->sceneID_ = OBJECTID_UNKNOWN; 91 this->gametype_ = 0;92 this->level_ = 0;93 89 } 94 90 } -
code/branches/core7/src/libraries/core/object/SmartPtr.h
r9571 r10358 142 142 } 143 143 144 /// Constructor: Used to explicitly initialize the smart pointer with a null pointer145 inline SmartPtr(int) : pointer_(0), base_(0)146 {147 }148 149 144 /// Constructor: Initializes the smart pointer with a pointer to an object. @param pointer The pointer @param bAddRef If true, the reference counter is increased. Don't set this to false unless you know exactly what you're doing! (for example to avoid circular references if the @c this pointer of the possessing object is stored) 150 145 inline SmartPtr(T* pointer, bool bAddRef = true) : pointer_(pointer), base_(pointer) … … 182 177 if (this->base_) 183 178 this->base_->decrementReferenceCount(); 184 }185 186 /// Used to assign a null pointer.187 inline SmartPtr& operator=(int)188 {189 SmartPtr(0).swap(*this);190 return *this;191 179 } 192 180 -
code/branches/core7/src/libraries/core/object/WeakPtr.h
r9571 r10358 104 104 } 105 105 106 /// Constructor: Used to explicitly initialize the weak pointer with a null pointer107 inline WeakPtr(int) : pointer_(0), base_(0), callback_(0)108 {109 }110 111 106 /// Constructor: Initializes the weak pointer with a pointer to an object. 112 107 inline WeakPtr(T* pointer) : pointer_(pointer), base_(pointer), callback_(0) … … 132 127 { 133 128 this->unregisterAsDestructionListener(this->base_); 134 }135 136 /// Used to assign a null pointer.137 inline WeakPtr& operator=(int)138 {139 WeakPtr(0).swap(*this);140 return *this;141 129 } 142 130
Note: See TracChangeset
for help on using the changeset viewer.