Make /list open the Channel List dialog
authorJanne Koschinski <janne@kuschku.de>
Fri, 22 Dec 2017 01:39:43 +0000 (02:39 +0100)
committerManuel Nickschas <sputnick@quassel-irc.org>
Wed, 28 Mar 2018 21:13:39 +0000 (23:13 +0200)
src/client/client.h
src/client/clientuserinputhandler.cpp
src/client/clientuserinputhandler.h
src/qtui/mainwin.cpp

index 6732d59..a7e6c2c 100644 (file)
@@ -165,6 +165,7 @@ signals:
     void requestNetworkStates();
 
     void showConfigWizard(const QVariantMap &coredata);
     void requestNetworkStates();
 
     void showConfigWizard(const QVariantMap &coredata);
+    void showChannelList(NetworkId networkId);
     void showIgnoreList(QString ignoreRule);
 
     void connected();
     void showIgnoreList(QString ignoreRule);
 
     void connected();
index 8af827d..561eb3d 100644 (file)
@@ -140,6 +140,11 @@ void ClientUserInputHandler::handleIgnore(const BufferInfo &bufferInfo, const QS
     );
 }
 
     );
 }
 
+void ClientUserInputHandler::handleList(const BufferInfo &bufferInfo, const QString &text)
+{
+    emit Client::instance()->showChannelList(bufferInfo.networkId());
+}
+
 
 void ClientUserInputHandler::switchBuffer(const NetworkId &networkId, const QString &bufferName)
 {
 
 void ClientUserInputHandler::switchBuffer(const NetworkId &networkId, const QString &bufferName)
 {
index 391a94a..5f7721a 100644 (file)
@@ -46,6 +46,7 @@ private slots:
     void handleJoin(const BufferInfo &bufferInfo, const QString &text);
     void handleQuery(const BufferInfo &bufferInfo, const QString &text);
     void handleIgnore(const BufferInfo &bufferInfo, const QString &text);
     void handleJoin(const BufferInfo &bufferInfo, const QString &text);
     void handleQuery(const BufferInfo &bufferInfo, const QString &text);
     void handleIgnore(const BufferInfo &bufferInfo, const QString &text);
+    void handleList(const BufferInfo &bufferInfo, const QString &text);
     void defaultHandler(const QString &cmd, const BufferInfo &bufferInfo, const QString &text);
 
 private:
     void defaultHandler(const QString &cmd, const BufferInfo &bufferInfo, const QString &text);
 
 private:
index d41f087..7854d89 100644 (file)
@@ -203,6 +203,7 @@ void MainWin::init()
     connect(Client::messageModel(), SIGNAL(rowsInserted(const QModelIndex &, int, int)),
         SLOT(messagesInserted(const QModelIndex &, int, int)));
     connect(GraphicalUi::contextMenuActionProvider(), SIGNAL(showChannelList(NetworkId)), SLOT(showChannelList(NetworkId)));
     connect(Client::messageModel(), SIGNAL(rowsInserted(const QModelIndex &, int, int)),
         SLOT(messagesInserted(const QModelIndex &, int, int)));
     connect(GraphicalUi::contextMenuActionProvider(), SIGNAL(showChannelList(NetworkId)), SLOT(showChannelList(NetworkId)));
+    connect(Client::instance(), SIGNAL(showChannelList(NetworkId)), SLOT(showChannelList(NetworkId)));
     connect(GraphicalUi::contextMenuActionProvider(), SIGNAL(showIgnoreList(QString)), SLOT(showIgnoreList(QString)));
     connect(Client::instance(), SIGNAL(showIgnoreList(QString)), SLOT(showIgnoreList(QString)));
 
     connect(GraphicalUi::contextMenuActionProvider(), SIGNAL(showIgnoreList(QString)), SLOT(showIgnoreList(QString)));
     connect(Client::instance(), SIGNAL(showIgnoreList(QString)), SLOT(showIgnoreList(QString)));