1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

refactor: Add copy and move assignment operator to toxid and toxpk

Add assignment operator to classes which has copy constructor
This commit is contained in:
Diadlo 2017-06-11 22:56:04 +03:00
parent 365d703e8a
commit 8e93af7fca
No known key found for this signature in database
GPG Key ID: 5AF9F2E29107C727
2 changed files with 4 additions and 0 deletions

View File

@ -35,6 +35,8 @@ public:
explicit ToxId(const QString& id);
explicit ToxId(const QByteArray& rawId);
explicit ToxId(const uint8_t* rawId, int len);
ToxId& operator=(const ToxId& other) = default;
ToxId& operator=(ToxId&& other) = default;
bool operator==(const ToxId& other) const;
bool operator!=(const ToxId& other) const;

View File

@ -12,6 +12,8 @@ public:
ToxPk(const ToxPk& other);
explicit ToxPk(const QByteArray& rawId);
explicit ToxPk(const uint8_t* rawId);
ToxPk& operator=(const ToxPk& other) = default;
ToxPk& operator=(ToxPk&& other) = default;
bool operator==(const ToxPk& other) const;
bool operator!=(const ToxPk& other) const;