DiffEditor: Minor cleanup

There is no need to enclose the argument with parentheses, and there is no
need to cast to QSharedPointer.

Change-Id: Ie8f6e4228e09203d1c42f614ee8a84de4a1e110b
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This commit is contained in:
Orgad Shaneh
2018-02-17 23:33:19 +02:00
committed by Orgad Shaneh
parent 436b8cdea1
commit b114b0c95e

View File

@@ -289,12 +289,12 @@ DiffEditor::DiffEditor()
connect(m_viewSwitcherAction, &QAction::triggered, this, [this]() { showDiffView(nextView()); });
}
void DiffEditor::setDocument(QSharedPointer<DiffEditorDocument>(doc))
void DiffEditor::setDocument(QSharedPointer<DiffEditorDocument> doc)
{
QTC_ASSERT(m_document.isNull(), return);
QTC_ASSERT(doc, return);
m_document = QSharedPointer<DiffEditorDocument>(doc);
m_document = doc;
connect(m_descriptionWidget, &DescriptionEditorWidget::requestBranchList,
m_document.data(), &DiffEditorDocument::requestMoreInformation);