+ scene()->setSenderCutoffMode(ChatScene::CutoffLeft);
+ // The normal message prefixes get replaced by the network and buffer name. Re-add brackets for
+ // all message types.
+ scene()->setAlwaysBracketSender(true);
+ connect(Client::instance(), &Client::coreConnectionStateChanged, this, &ChatMonitorView::coreConnectionStateChanged);
+}
+
+
+void ChatMonitorView::addActionsToMenu(QMenu *menu, const QPointF &pos)
+{
+ ChatView::addActionsToMenu(menu, pos);
+ menu->addSeparator();
+ QAction *showOwnNicksAction = menu->addAction(tr("Show Own Messages"), _filter, SLOT(setShowOwnMessages(bool)));
+ showOwnNicksAction->setCheckable(true);
+ showOwnNicksAction->setChecked(_filter->showOwnMessages());
+
+ if (scene()->columnByScenePos(pos) == ChatLineModel::SenderColumn) {
+ menu->addSeparator();
+
+ QAction *showNetworkAction = menu->addAction(tr("Show Network Name"), this, SLOT(showFieldsChanged(bool)));
+ showNetworkAction->setCheckable(true);
+ showNetworkAction->setChecked(_filter->showFields() & ChatMonitorFilter::NetworkField);
+ showNetworkAction->setData(ChatMonitorFilter::NetworkField);
+
+ QAction *showBufferAction = menu->addAction(tr("Show Buffer Name"), this, SLOT(showFieldsChanged(bool)));
+ showBufferAction->setCheckable(true);
+ showBufferAction->setChecked(_filter->showFields() & ChatMonitorFilter::BufferField);
+ showBufferAction->setData(ChatMonitorFilter::BufferField);
+ }
+
+ menu->addSeparator();
+ menu->addAction(icon::get("configure"), tr("Configure..."), this, SLOT(showSettingsPage()));