Gui: move to new style connect()

This commit is contained in:
wmayer
2023-02-01 11:58:00 +01:00
committed by wwmayer
parent 25a63f8750
commit 2e5cb03261
43 changed files with 237 additions and 246 deletions

View File

@@ -53,9 +53,9 @@ TextDocumentEditorView::TextDocumentEditorView(
// update editor actions on request
Gui::MainWindow* mw = Gui::getMainWindow();
connect(editor, SIGNAL(undoAvailable(bool)), mw, SLOT(updateEditorActions()));
connect(editor, SIGNAL(redoAvailable(bool)), mw, SLOT(updateEditorActions()));
connect(editor, SIGNAL(copyAvailable(bool)), mw, SLOT(updateEditorActions()));
connect(editor, &QPlainTextEdit::undoAvailable, mw, &MainWindow::updateEditorActions);
connect(editor, &QPlainTextEdit::redoAvailable, mw, &MainWindow::updateEditorActions);
connect(editor, &QPlainTextEdit::copyAvailable, mw, &MainWindow::updateEditorActions);
}
TextDocumentEditorView::~TextDocumentEditorView()
@@ -97,8 +97,8 @@ bool TextDocumentEditorView::event(QEvent *event)
void TextDocumentEditorView::setupEditor()
{
connect(getEditor()->document(), SIGNAL(modificationChanged(bool)),
this, SLOT(setWindowModified(bool)));
connect(getEditor()->document(), &QTextDocument::modificationChanged,
this, &TextDocumentEditorView::setWindowModified);
setWindowTitle(QString::fromUtf8(textDocument->Label.getValue())
+ QString::fromLatin1("[*]"));
getEditor()->setPlainText(