From a11617ff65f8570e7c33db420c207ef304529322 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Capelle?= Date: Sun, 26 May 2024 12:20:02 +0200 Subject: [PATCH] Use MO2 formatting action. (#2032) --- .github/workflows/linting.yml | 6 +++--- src/datatab.cpp | 14 +++++++------- src/glob_matching.h | 2 +- src/modlistview.cpp | 4 ++-- src/savestab.cpp | 5 ++--- 5 files changed, 15 insertions(+), 16 deletions(-) diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index 43cdeeaed..40b3f7fea 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -10,8 +10,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Run clang-format - uses: jidicula/clang-format-action@v4.11.0 + - name: Check format + uses: ModOrganizer2/check-formatting-action@master with: - clang-format-version: "15" check-path: "." + exclude-regex: "third-party" diff --git a/src/datatab.cpp b/src/datatab.cpp index 567fa99d7..e531c1e07 100644 --- a/src/datatab.cpp +++ b/src/datatab.cpp @@ -16,13 +16,13 @@ QString UnmanagedModName(); DataTab::DataTab(OrganizerCore& core, PluginContainer& pc, QWidget* parent, Ui::MainWindow* mwui) - : m_core(core), m_pluginContainer(pc), - m_parent(parent), ui{mwui->tabWidget, - mwui->dataTab, - mwui->dataTabRefresh, - mwui->dataTree, - mwui->dataTabShowOnlyConflicts, - mwui->dataTabShowFromArchives}, + : m_core(core), m_pluginContainer(pc), m_parent(parent), + ui{mwui->tabWidget, + mwui->dataTab, + mwui->dataTabRefresh, + mwui->dataTree, + mwui->dataTabShowOnlyConflicts, + mwui->dataTabShowFromArchives}, m_needUpdate(true) { m_filetree.reset(new FileTree(core, m_pluginContainer, ui.tree)); diff --git a/src/glob_matching.h b/src/glob_matching.h index b47d30aca..c0620aafd 100644 --- a/src/glob_matching.h +++ b/src/glob_matching.h @@ -178,7 +178,7 @@ GlobPattern(std::basic_string const&) template GlobPattern(CharT const*) -> GlobPattern; -GlobPattern(QString const&)->GlobPattern; +GlobPattern(QString const&) -> GlobPattern; } // namespace MOShared diff --git a/src/modlistview.cpp b/src/modlistview.cpp index 944825fac..81e87c5ee 100644 --- a/src/modlistview.cpp +++ b/src/modlistview.cpp @@ -137,8 +137,8 @@ class ModListViewMarkingScrollBar : public ViewMarkingScrollBar ModListView::ModListView(QWidget* parent) : QTreeView(parent), m_core(nullptr), m_sortProxy(nullptr), - m_byPriorityProxy(nullptr), m_byCategoryProxy(nullptr), - m_byNexusIdProxy(nullptr), m_markers{{}, {}, {}, {}, {}, {}}, + m_byPriorityProxy(nullptr), m_byCategoryProxy(nullptr), m_byNexusIdProxy(nullptr), + m_markers{{}, {}, {}, {}, {}, {}}, m_scrollbar(new ModListViewMarkingScrollBar(this)) { setVerticalScrollBar(m_scrollbar); diff --git a/src/savestab.cpp b/src/savestab.cpp index c6ab645f3..813fea052 100644 --- a/src/savestab.cpp +++ b/src/savestab.cpp @@ -8,9 +8,8 @@ using namespace MOBase; SavesTab::SavesTab(QWidget* window, OrganizerCore& core, Ui::MainWindow* mwui) - : m_window(window), m_core(core), - m_CurrentSaveView(nullptr), ui{mwui->tabWidget, mwui->savesTab, - mwui->savegameList} + : m_window(window), m_core(core), m_CurrentSaveView(nullptr), + ui{mwui->tabWidget, mwui->savesTab, mwui->savegameList} { m_SavesWatcherTimer.setSingleShot(true); m_SavesWatcherTimer.setInterval(500);