1 | /* |
---|
2 | * eventinterfaces.h |
---|
3 | * |
---|
4 | * Created on: Jan 16, 2010 |
---|
5 | * Author: saemy |
---|
6 | */ |
---|
7 | |
---|
8 | #ifndef EVENTINTERFACES_H_ |
---|
9 | #define EVENTINTERFACES_H_ |
---|
10 | |
---|
11 | #include <iinterface.h> |
---|
12 | |
---|
13 | class IContact; |
---|
14 | |
---|
15 | class IIdDataEvents: public IInterface { |
---|
16 | Q_INTERFACES(IInterface) |
---|
17 | |
---|
18 | public: |
---|
19 | virtual void idChanged(int oldId, int newId) =0; |
---|
20 | virtual void dataChanged() =0; |
---|
21 | }; |
---|
22 | Q_DECLARE_INTERFACE(IIdDataEvents, |
---|
23 | "ch.gorrion.smssender.IIdDataEvents/1.0") |
---|
24 | |
---|
25 | |
---|
26 | /* Account */ |
---|
27 | |
---|
28 | class IAccountEvents: public IIdDataEvents { |
---|
29 | Q_INTERFACES(IIdDataEvents) |
---|
30 | |
---|
31 | public: |
---|
32 | virtual void statusChanged(const QString& status) =0; |
---|
33 | virtual void progressChanged(int progress) =0; |
---|
34 | }; |
---|
35 | Q_DECLARE_INTERFACE(IAccountEvents, |
---|
36 | "ch.gorrion.smssender.IAccountEvents/1.0") |
---|
37 | |
---|
38 | |
---|
39 | class ILoginAccountEvents: virtual public IAccountEvents { |
---|
40 | Q_INTERFACES(IAccountEvents) |
---|
41 | |
---|
42 | public: |
---|
43 | virtual void loggedIn() =0; |
---|
44 | virtual void loggedOut() =0; |
---|
45 | }; |
---|
46 | Q_DECLARE_INTERFACE(ILoginAccountEvents, |
---|
47 | "ch.gorrion.smssender.ILoginAccountEvents/1.0") |
---|
48 | |
---|
49 | |
---|
50 | /* Contact */ |
---|
51 | |
---|
52 | class IContactEvents: public IIdDataEvents { |
---|
53 | Q_INTERFACES(IIdDataEvents) |
---|
54 | }; |
---|
55 | Q_DECLARE_INTERFACE(IContactEvents, |
---|
56 | "ch.gorrion.smssender.IContactEvents/1.0") |
---|
57 | |
---|
58 | |
---|
59 | /* Group */ |
---|
60 | |
---|
61 | class IGroupEvents: public IIdDataEvents { |
---|
62 | Q_INTERFACES(IIdDataEvents) |
---|
63 | |
---|
64 | public: |
---|
65 | virtual void contactAdded(IContact* contact) =0; |
---|
66 | virtual void contactRemoved(IContact* contact) =0; |
---|
67 | }; |
---|
68 | Q_DECLARE_INTERFACE(IGroupEvents, |
---|
69 | "ch.gorrion.smssender.IGroupEvents/1.0") |
---|
70 | |
---|
71 | |
---|
72 | #include <icontact.h> |
---|
73 | |
---|
74 | #endif /* EVENTINTERFACES_H_ */ |
---|