mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-06 18:25:37 +08:00
Fixed clazy warnings: new-style signal/slot connect syntax.
This commit is contained in:
@@ -42,7 +42,7 @@ namespace BlackGui
|
||||
void CConsoleTextEdit::customMenuRequested(const QPoint &pos)
|
||||
{
|
||||
QMenu *menu = QPlainTextEdit::createStandardContextMenu();
|
||||
menu->addAction(CIcons::delete16(), "Clear console", this, SLOT(clear()));
|
||||
menu->addAction(CIcons::delete16(), "Clear console", this, &QPlainTextEdit::clear);
|
||||
menu->exec(this->mapToGlobal(pos));
|
||||
}
|
||||
|
||||
|
||||
@@ -349,7 +349,7 @@ namespace BlackGui
|
||||
a = contextMenu->addAction(CIcons::resize16(), "2 columns", this, &CNavigatorDialog::changeLayout);
|
||||
a->setData("2c");
|
||||
const QString frameLessActionText = this->isFrameless() ? "Normal window" : "Frameless";
|
||||
contextMenu->addAction(CIcons::tableSheet16(), frameLessActionText, this, SLOT(toggleFrameless()));
|
||||
contextMenu->addAction(CIcons::tableSheet16(), frameLessActionText, this, &CNavigatorDialog::toggleFrameless);
|
||||
contextMenu->addAction("Adjust margins", this, &CNavigatorDialog::dummyFunction);
|
||||
contextMenu->addAction(m_marginMenuAction);
|
||||
contextMenu->addSeparator();
|
||||
|
||||
@@ -124,7 +124,7 @@ namespace BlackGui
|
||||
toggleFloatingMenuAction->setCheckable(true);
|
||||
toggleFloatingMenuAction->setChecked(!dw->isFloating());
|
||||
subMenuToggleFloat->addAction(toggleFloatingMenuAction);
|
||||
c = connect(toggleFloatingMenuAction, SIGNAL(toggled(bool)), signalMapperToggleFloating, SLOT(map()));
|
||||
c = connect(toggleFloatingMenuAction, &QAction::toggled, signalMapperToggleFloating, qOverload<>(&QSignalMapper::map));
|
||||
BLACK_VERIFY_X(c, Q_FUNC_INFO, "Cannot map floating action"); // do not make that shutdown reason in a release build
|
||||
signalMapperToggleFloating->setMapping(toggleFloatingMenuAction, i);
|
||||
}
|
||||
@@ -160,7 +160,7 @@ namespace BlackGui
|
||||
connect(showTabbar, &QAction::toggled, this, &CInfoArea::showTabBar);
|
||||
|
||||
// tab bar position
|
||||
menu->addAction(CIcons::dockBottom16(), "Toogle tabbar position", this, SLOT(toggleTabBarPosition()));
|
||||
menu->addAction(CIcons::dockBottom16(), "Toogle tabbar position", this, &CInfoArea::toggleTabBarPosition);
|
||||
Q_UNUSED(c);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user