File indexing completed on 2024-05-19 04:47:11
0001 #pragma once 0002 #include <QObject> 0003 0004 class BranchesManager : public QObject 0005 { 0006 Q_OBJECT 0007 Q_PROPERTY(QStringList allBranches READ allBranches NOTIFY repoChanged) 0008 Q_PROPERTY(QStringList localBranches READ localBranches NOTIFY repoChanged) 0009 Q_PROPERTY(QStringList remoteBranches READ remoteBranches NOTIFY repoChanged) 0010 0011 public: 0012 explicit BranchesManager(QObject *parent = nullptr); 0013 0014 QStringList allBranches(); 0015 0016 QStringList localBranches(); 0017 0018 QStringList remoteBranches(); 0019 0020 public Q_SLOTS: 0021 QString upstreamRemote(const QString &branchName); 0022 QString upstream(const QString &branchName); 0023 0024 private: 0025 // Git::Repository m_repo; 0026 0027 Q_SIGNALS: 0028 void repoChanged(); 0029 0030 }; 0031