comarebranchesview.h 966 Bytes
Newer Older
Waqar Ahmed's avatar
Waqar Ahmed committed
1
2
3
4
5
/*
    SPDX-FileCopyrightText: 2021 Waqar Ahmed <waqar.17a@gmail.com>

    SPDX-License-Identifier: LGPL-2.0-or-later
*/
6
7
8
9
10
11
12
13
#ifndef COMAREBRANCHESVIEW_H
#define COMAREBRANCHESVIEW_H

#include <QPushButton>
#include <QStandardItemModel>
#include <QTreeView>
#include <QWidget>

Waqar Ahmed's avatar
Waqar Ahmed committed
14
#include "git/gitstatus.h"
15
16
17
18
19
20

class KateProjectPluginView;
class CompareBranchesView : public QWidget
{
    Q_OBJECT
public:
Waqar Ahmed's avatar
Waqar Ahmed committed
21
    explicit CompareBranchesView(QWidget *parent, const QString &gitPath, const QString fromB, const QString &toBr, QVector<GitUtils::StatusItem> items);
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
    void setPluginView(KateProjectPluginView *pv)
    {
        m_pluginView = pv;
    }

    Q_SIGNAL void backClicked();

private Q_SLOTS:
    void showDiff(const QModelIndex &idx);

private:
    QPushButton m_backBtn;
    QTreeView m_tree;
    QStandardItemModel m_model;
    QString m_gitDir;
    QString m_fromBr;
    QString m_toBr;
    KateProjectPluginView *m_pluginView;
};

#endif // COMAREBRANCHESVIEW_H