Added Unlock() (an nicer sounding alias for Unset()) and Detach() (the lock is kept when the object is destroyed) to AutoLocker.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@9547 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -174,6 +174,17 @@ public:
|
|||||||
_Unlock();
|
_Unlock();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline void Unlock()
|
||||||
|
{
|
||||||
|
_Unlock();
|
||||||
|
}
|
||||||
|
|
||||||
|
inline void Detach()
|
||||||
|
{
|
||||||
|
fLockable = NULL;
|
||||||
|
fLocked = false;
|
||||||
|
}
|
||||||
|
|
||||||
inline AutoLocker<Lockable, Locking> &operator=(Lockable *lockable)
|
inline AutoLocker<Lockable, Locking> &operator=(Lockable *lockable)
|
||||||
{
|
{
|
||||||
SetTo(lockable);
|
SetTo(lockable);
|
||||||
|
|||||||
Reference in New Issue
Block a user