DiffEditor: Modernize

* Use member init
* Use nullptr
* Use range-for
* omit QLatin1{String|Char} where possible

Change-Id: Ib231b747cdd9073b3d4fc6779b8e0afb2b404a31
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
This commit is contained in:
Andre Hartmann
2017-12-06 21:30:57 +01:00
committed by André Hartmann
parent 53a151074a
commit aae3056b33
21 changed files with 436 additions and 474 deletions

View File

@@ -93,14 +93,14 @@ private:
void setupView(IDiffView *view);
QSharedPointer<DiffEditorDocument> m_document;
DescriptionEditorWidget *m_descriptionWidget;
UnifiedView *m_unifiedView;
SideBySideView *m_sideBySideView;
QStackedWidget *m_stackedWidget;
DescriptionEditorWidget *m_descriptionWidget = nullptr;
UnifiedView *m_unifiedView = nullptr;
SideBySideView *m_sideBySideView = nullptr;
QStackedWidget *m_stackedWidget = nullptr;
QVector<IDiffView *> m_views;
QToolBar *m_toolBar;
QComboBox *m_entriesComboBox;
QSpinBox *m_contextSpinBox;
QToolBar *m_toolBar = nullptr;
QComboBox *m_entriesComboBox = nullptr;
QSpinBox *m_contextSpinBox = nullptr;
QAction *m_contextSpinBoxAction = nullptr;
QAction *m_toggleSyncAction;
QAction *m_whitespaceButtonAction;
@@ -109,11 +109,11 @@ private:
QAction *m_contextLabelAction = nullptr;
QAction *m_viewSwitcherAction;
QPair<QString, QString> m_currentFileChunk;
int m_currentViewIndex;
int m_currentDiffFileIndex;
int m_currentViewIndex = -1;
int m_currentDiffFileIndex = -1;
Utils::Guard m_ignoreChanges;
bool m_sync;
bool m_showDescription;
bool m_sync = false;
bool m_showDescription = true;
};
} // namespace Internal