Added method to read messages.
[situare] / src / ui / meetpeoplepanel.h
1 #ifndef MEETPEOPLEPANEL_H
2 #define MEETPEOPLEPANEL_H
3
4 #include <QList>
5
6 #include "situareservice/message.h"
7
8 #include "panelbase.h"
9
10 class FriendListView;
11 class ImageButton;
12 class MessageListView;
13 class User;
14
15 class MeetPeoplePanel : public PanelBase
16 {
17     Q_OBJECT
18
19 public:
20     /**
21      * @brief Default constructor
22      *
23      * @param parent
24      */
25     MeetPeoplePanel(QWidget *parent = 0);
26
27 private slots:
28     /**
29      * @brief Slot to update friend item's image
30      *
31      * @param user Friend
32      */
33     void friendImageReady(User *user);
34
35     /**
36     * @brief Populates interesting people list view.
37     *
38     * @param interestingPeople list of interesting people
39     */
40     void populateInterestingPeopleListView(QList<User *> &interestingPeople);
41
42     /**
43     * @brief Populates message list view.
44     *
45     * @param messages list of user messages
46     */
47     void populateMessageListView(QList<Message> &messages);
48
49
50     /**
51     * @brief Sets chat button disabled.
52     *
53     * Disabled if there isn't any list item selected.
54     */
55     void setChatButtonDisabled();
56
57 signals:
58     /**
59     * @brief Requests interesting people from current map viewport.
60     *
61     * Interesting people is defined by people with same tags as user has.
62     */
63     void requestInterestingPeople();
64
65 private:
66     FriendListView *m_interestingPeopleListView;///< Interesting people list view
67     MessageListView *m_messageListView;         ///< Message list view
68     ImageButton *m_chatButton;                  ///< Chat button
69 };
70
71 #endif // MEETPEOPLEPANEL_H