Robert Osfield
cc471b1103
From Magnus Kessler, "Attached are a number of files where I have tried to fix up some of the
...
documentation. I have accumulated them over some time, but rebased onto the
subversion trunk."
2010-09-15 12:00:12 +00:00
Robert Osfield
534af3aeaf
Removed the erroneous subclassing from osg::Observer
2010-08-08 15:44:03 +00:00
Robert Osfield
d26a8474e7
Changed the ref_ptr<T> observer_ptr<>::lock() method to be
...
bool observer_ptr<>::lock(ref_ptr<T>&) to avoid the temporary ref_ptr<>'s
being created and destroyed on the stack along with the associated ref/unref() operations
2010-05-28 08:57:48 +00:00
Robert Osfield
9cf330d7ff
Introduced a alternative implementation of observer_ptr<> that uses ObserverSet rather than an local WeakReference object.
2010-05-20 13:38:28 +00:00
Robert Osfield
b979b585f2
From Tim Moore, fix for deadlock
2010-05-19 13:14:57 +00:00
Robert Osfield
62d69c686f
Fixed warning
2010-05-19 08:22:10 +00:00
Robert Osfield
b3ac6484c1
From Martin Naylor, "Please find attached the modified observer_ptr include for fixing a compiler
...
issue for Windows and VS2008."
2010-05-19 08:08:49 +00:00
Robert Osfield
7ed822fd79
From Tim Moore, typo fix.
2010-05-18 18:01:02 +00:00
Robert Osfield
61121daaab
Updated wrappers
2010-05-17 18:37:32 +00:00
Robert Osfield
65c09c8e0d
From Tim Moore, improved doxygen comments
2010-05-17 14:43:41 +00:00
Robert Osfield
ccd9f31309
Removed signalUnreffed interface
2010-05-17 14:21:53 +00:00
Robert Osfield
f832198128
From Tim Moore, refactore WeakReference/Referenced to avoid signalling the observers when do a unref_nodelete.
2010-05-17 09:03:44 +00:00
Robert Osfield
2b2ea4487a
From Tim Moore, new more robust observer_ptr<> implementation
2010-05-14 12:14:14 +00:00
Robert Osfield
51924431cd
Fixed warnings
2010-04-13 09:42:53 +00:00
Robert Osfield
bb21136d92
Added missing _ptr = rp._ptr to constructor.
2010-02-22 08:39:33 +00:00
Robert Osfield
eca4361c4a
Clean up observer_ptr<> and removed the eronous casting of ptr in objectDeleted.
2010-02-19 19:50:55 +00:00
Robert Osfield
b807fc83fe
Added mutex lock to destructor.
2010-02-19 16:04:33 +00:00
Robert Osfield
8f11af8d3e
Replaced local mutex with getObserverMutex().
2010-02-19 15:41:42 +00:00
Robert Osfield
26a9e499a4
Fixed crash
2010-02-16 14:05:49 +00:00
Robert Osfield
a8e26f3a0c
Threads safety fixes based on suggestions from Tim Moore.
2010-02-16 11:10:49 +00:00
Robert Osfield
644b2e15d1
Refactored the osg::Observer to introduce a new bool Observer::objectUnreferenced(void*) method that adds
...
the extra capability of making it possible for Observers to assume ownership of a object that would otherwsie be deleted.
Added a thread safe ref_ptr<T> observer_ptr<T>::lock() method for robust access to an observed object. This
makes observer_ptr<> more equivilant to boosts weak_ptr.
2010-02-15 20:12:53 +00:00
Robert Osfield
1be388c705
Changed the const get(), operator*() and operator->() methods to return non const T versions
2008-03-14 11:06:35 +00:00
Robert Osfield
4ab9c6f5f4
Removed check from objectDeleted(void*) method as this was not catching cases
...
where the registered ptr was different from the deleted ptr - something that
can happen with multiple inheritance.
2006-11-26 22:27:09 +00:00
Robert Osfield
f1c2694c17
Updated copyright years.
2006-07-18 15:21:48 +00:00
Robert Osfield
8f2ffb7c2d
Added new observer_ptr templated smart pointer to allow one to retain pointers
...
to objects but have the pointer reset to null if that object is deleted.
2006-02-27 19:44:33 +00:00