1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
|
#ifndef file_chatview
#define file_chatview
#include "view.h"
#include "chat.h"
class IRCConnection;
class ChatView : public View
{
//! Construction:
public:
ChatView(IRCConnection *connection, const std::string &filter, MainFrame *mainframe);
~ChatView();
//! Attributes:
public:
const std::string &get_filter() const { return chat->get_filter(); }
//! Operations:
public:
//! Implementation:
private:
void on_resize(int old_width, int old_height);
void on_paint();
void on_inputbox_return_pressed();
void on_inputbox_changed(const std::string &text);
void on_userlist_activated(int item_id);
void on_userlist_key_up(const CL_InputEvent &event);
void on_userlist_mouse_up(const CL_InputEvent &event);
void on_userlist_contextmenu();
void on_connection_numeric_reply(const std::string &prefix, int command, const std::vector<std::string> ¶ms);
void on_connection_nick(const std::string &_old_nick, const std::string &_new_nick);
void on_connection_join(const std::string &nick, const std::string &channel);
void on_connection_part(const std::string &nick, const std::string &channel, const std::string &reason);
Chat *chat;
CL_InputBox *inputbox;
CL_ListBox *userlist;
IRCConnection *connection;
CL_SlotContainer slots;
};
#endif
|