Commit c094592f authored by hjk's avatar hjk

BaseTextEditor: Un-slot most widget actions

Change-Id: Id642fc518d03dad5202e0d7bbb6b8b6325abbbab
Reviewed-by: default avatarChristian Stenger <christian.stenger@digia.com>
parent 0e81b718
......@@ -626,7 +626,7 @@ void BaseTextEditorWidgetPrivate::ctor(const QSharedPointer<BaseTextDocument> &d
QObject::connect(q, &QPlainTextEdit::blockCountChanged,
this, &BaseTextEditorWidgetPrivate::slotUpdateExtraAreaWidth);
QObject::connect(q, &BaseTextEditorWidget::modificationChanged, m_extraArea,
QObject::connect(q, &QPlainTextEdit::modificationChanged, m_extraArea,
static_cast<void (QWidget::*)()>(&QWidget::update));
QObject::connect(q, &QPlainTextEdit::cursorPositionChanged,
......@@ -981,10 +981,10 @@ bool BaseTextEditorWidget::open(QString *errorString, const QString &fileName, c
moveCursor(QTextCursor::Start);
d->updateCannotDecodeInfo();
if (d->m_fileEncodingLabel) {
connect(d->m_fileEncodingLabel, SIGNAL(clicked()), this,
SLOT(selectEncoding()), Qt::UniqueConnection);
connect(d->m_document->document(), SIGNAL(modificationChanged(bool)), this,
SLOT(updateTextCodecLabel()), Qt::UniqueConnection);
connect(d->m_fileEncodingLabel, &LineColumnLabel::clicked,
this, &BaseTextEditorWidget::selectEncoding, Qt::UniqueConnection);
connect(d->m_document->document(), &QTextDocument::modificationChanged,
this, &BaseTextEditorWidget::updateTextCodecLabel, Qt::UniqueConnection);
updateTextCodecLabel();
}
return true;
......
......@@ -392,7 +392,6 @@ public:
enum Side { Left, Right };
void insertExtraToolBarWidget(Side side, QWidget *widget);
public slots:
virtual void copy();
virtual void paste();
virtual void cut();
......@@ -495,7 +494,8 @@ public slots:
void configureMimeType(const QString &mimeType);
void configureMimeType(const Core::MimeType &mimeType);
void inSnippetMode(bool *active);
Q_INVOKABLE void inSnippetMode(bool *active); // Used by FakeVim.
signals:
void assistFinished();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment