diff --git a/docs/changes.txt b/docs/changes.txt index 80dd4c7cfd..f11b13b57b 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -135,6 +135,7 @@ wxMSW: - Fix quoting of arguments passed to wxExecute(char **) (Brian Ravnsgaard Riis). - Support disabling items before adding them to the menu (Christian Walther). - Allow to call SetFont(wxNullFont) to reset the font to default. +- Implement UUID::operator==() and !=() (SQLAware). wxGTK: diff --git a/include/wx/msw/ole/uuid.h b/include/wx/msw/ole/uuid.h index 1bda2dc680..de53dd43ef 100644 --- a/include/wx/msw/ole/uuid.h +++ b/include/wx/msw/ole/uuid.h @@ -74,6 +74,12 @@ public: bool Set(const wxChar *pc); // from a string, returns true if ok void Set(const UUID& uuid); // from another UUID (never fails) +#if wxABI_VERSION >= 20809 + // comparison operators + bool operator==(const Uuid& uuid) const; + bool operator!=(const Uuid& uuid) const; +#endif // wxABI_VERSION >= 2.8.9 + // accessors operator const UUID*() const { return &m_uuid; } operator const wxChar*() const { return (wxChar *)(m_pszUuid); } diff --git a/src/msw/ole/uuid.cpp b/src/msw/ole/uuid.cpp index 0b1020d849..c21369b4ef 100644 --- a/src/msw/ole/uuid.cpp +++ b/src/msw/ole/uuid.cpp @@ -82,6 +82,16 @@ Uuid& Uuid::operator=(const Uuid& uuid) return *this; } +bool Uuid::operator==(const Uuid& uuid) const +{ + return m_uuid == uuid.m_uuid; +} + +bool Uuid::operator!=(const Uuid& uuid) const +{ + return m_uuid != uuid.m_uuid; +} + // dtor Uuid::~Uuid() {