Permalink
Browse files

Added std::set semantics to the AddonClass::Ref.

  • Loading branch information...
1 parent b3c5667 commit 8a0aa42b9aa33c91feb89dc061b6d5b35194d74e Jim Carroll committed Dec 16, 2012
Showing with 2 additions and 0 deletions.
  1. +2 −0 xbmc/interfaces/legacy/AddonClass.h
@@ -199,6 +199,8 @@ namespace XBMCAddon
inline bool isNotNull() const { refcheck; return ac != NULL; }
inline bool isSet() const { refcheck; return ac != NULL; }
inline bool operator!() const { refcheck; return ac == NULL; }
+ inline bool operator==(const AddonClass::Ref<T>& oref) const { refcheck; return ac == oref.ac; }
+ inline bool operator<(const AddonClass::Ref<T>& oref) const { refcheck; return ac < oref.ac; } // std::set semantics
// This is there only for boost compatibility
template<class O> inline void reset(Ref<O> const & oref) { refcheck; (*this) = static_cast<T*>(oref.get()); refcheck; }

0 comments on commit 8a0aa42

Please sign in to comment.