all repos — fluxbox @ e4157821fc159371ff7bd8b6b1b0a889c81e72a2

custom fork of the fluxbox windowmanager

Add a reset() function to FbTk::RefCount

to make it's interface more compatible with other smart pointers.
Pavel Labath pavelo@centrum.sk
commit

e4157821fc159371ff7bd8b6b1b0a889c81e72a2

parent

0f85ade9bee91701533137deaea291ad023fd824

1 files changed, 1 insertions(+), 0 deletions(-)

jump to
M src/FbTk/RefCount.hhsrc/FbTk/RefCount.hh

@@ -41,6 +41,7 @@ RefCount<Pointer> &operator = (Pointer *p);

Pointer &operator * () const { return *get(); } Pointer *operator -> () const { return get(); } Pointer *get() const { return m_data; } + void reset(Pointer *p) { *this = p; } /// conversion to "bool" operator bool_type() const { return m_data ? &RefCount::m_data : 0; }