forked from qt-creator/qt-creator
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:
committed by
Orgad Shaneh
parent
436b8cdea1
commit
b114b0c95e
@@ -289,12 +289,12 @@ DiffEditor::DiffEditor()
|
|||||||
connect(m_viewSwitcherAction, &QAction::triggered, this, [this]() { showDiffView(nextView()); });
|
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(m_document.isNull(), return);
|
||||||
QTC_ASSERT(doc, return);
|
QTC_ASSERT(doc, return);
|
||||||
|
|
||||||
m_document = QSharedPointer<DiffEditorDocument>(doc);
|
m_document = doc;
|
||||||
|
|
||||||
connect(m_descriptionWidget, &DescriptionEditorWidget::requestBranchList,
|
connect(m_descriptionWidget, &DescriptionEditorWidget::requestBranchList,
|
||||||
m_document.data(), &DiffEditorDocument::requestMoreInformation);
|
m_document.data(), &DiffEditorDocument::requestMoreInformation);
|
||||||
|
|||||||
Reference in New Issue
Block a user