summaryrefslogtreecommitdiffstats
path: root/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/doc/snippets/textdocument-selections/mainwindow.cpp')
-rw-r--r--src/gui/doc/snippets/textdocument-selections/mainwindow.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp b/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
index 8ac3913f3c..9253e87670 100644
--- a/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
+++ b/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
@@ -48,7 +48,7 @@
**
****************************************************************************/
-#include <QtGui>
+#include <QtWidgets>
#include "mainwindow.h"
@@ -90,7 +90,8 @@ MainWindow::MainWindow()
document = new QTextDocument(this);
editor->setDocument(document);
- connect(editor, SIGNAL(selectionChanged()), this, SLOT(updateMenus()));
+ connect(editor, &QTextEdit::selectionChanged,
+ this, &MainWindow::updateMenus);
setCentralWidget(editor);
setWindowTitle(tr("Text Document Writer"));