File indexing completed on 2025-01-05 05:14:40
0001 /* 0002 SPDX-FileCopyrightText: 2021 Hamed Masafi <hamed.masfi@gmail.com> 0003 0004 SPDX-License-Identifier: GPL-3.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include "ui_submoduleswidget.h" 0010 #include "widgetbase.h" 0011 0012 class SubmoduleActions; 0013 0014 namespace Git 0015 { 0016 class SubmodulesModel; 0017 } 0018 0019 class SubmodulesWidget : public WidgetBase, private Ui::SubmodulesWidget 0020 { 0021 Q_OBJECT 0022 0023 public: 0024 explicit SubmodulesWidget(Git::Manager *git, AppWindow *parent = nullptr); 0025 0026 void saveState(QSettings &settings) const override; 0027 void restoreState(QSettings &settings) override; 0028 0029 private Q_SLOTS: 0030 void slotTreeViewCustomContextMenuRequested(const QPoint &pos); 0031 void slotTreeViewActivated(const QModelIndex &index); 0032 0033 private: 0034 SubmoduleActions *const mActions; 0035 Git::SubmodulesModel *mModel = nullptr; 0036 };