You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
894 B
39 lines
894 B
#pragma once |
|
|
|
#include <QMainWindow> |
|
#include <QSystemTrayIcon> |
|
#include <QMenu> |
|
|
|
class ChannelList; |
|
class MessageList; |
|
class AccountList; |
|
class DbManager; |
|
class MsgClient; |
|
class ChatPropagator; |
|
|
|
class MainWindow : public QMainWindow { |
|
Q_OBJECT |
|
public: |
|
explicit MainWindow(QWidget *parent = nullptr, DbManager* db = nullptr); |
|
~MainWindow() override = default; |
|
|
|
protected: |
|
void closeEvent(QCloseEvent *event) override; |
|
|
|
private slots: |
|
void onTrayActivated(QSystemTrayIcon::ActivationReason reason); |
|
void showInviteDialog(const QString& channelId); |
|
|
|
private: |
|
void setupUi(); |
|
void setupTray(); |
|
|
|
ChannelList *m_channelList; |
|
MessageList *m_messageList; |
|
AccountList *m_accountList; |
|
QSystemTrayIcon *m_trayIcon; |
|
QMenu *m_trayMenu; |
|
DbManager *m_db; |
|
MsgClient *m_client; |
|
ChatPropagator *m_propagator; |
|
};
|
|
|