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

refactor: Improve interface

This commit is contained in:
Diadlo 2017-09-26 23:38:54 +03:00
parent ff2fc18be1
commit 87baf0e690
No known key found for this signature in database
GPG Key ID: 5AF9F2E29107C727
2 changed files with 4 additions and 1 deletions

View File

@ -47,7 +47,7 @@ public:
DECLARE_SIGNAL(noteChanged, const QString&);
DECLARE_SIGNAL(autoAcceptDirChanged, const QString&);
DECLARE_SIGNAL(autoAcceptCallChanged, AutoAcceptCallFlags);
DECLARE_SIGNAL(autoAcceptCallChanged, IFriendSettings::AutoAcceptCallFlags);
DECLARE_SIGNAL(autoGroupInviteChanged, bool);
};

View File

@ -27,6 +27,9 @@
* SIGNAL_IMPL(Example, valueChanged, int value);
* };
*/
#define DECLARE_SIGNAL(name, ...) \
using Slot_##name = std::function<void (__VA_ARGS__)>; \
virtual void connectTo_##name(Slot_##name slot) const = 0
/**
* @def DECLARE_SIGNAL