Version 2.6
[qgit4/redivivus.git] / src / patchview.h
bloba25d84db91e8214f5080ed8a61086175fe3dd5ad
1 /*
2 Author: Marco Costalba (C) 2005-2007
4 Copyright: See COPYING file that comes with this distribution
6 */
7 #ifndef PATCHVIEW_H
8 #define PATCHVIEW_H
10 #include "ui_patchview.h"
11 #include "domain.h"
13 class Git;
15 class PatchView :public Domain {
16 Q_OBJECT
17 public:
18 PatchView() {}
19 PatchView(MainImpl* mi, Git* g);
20 ~PatchView();
21 void clear(bool complete = true);
22 Ui_TabPatch* tab() { return patchTab; }
24 signals:
25 void diffTo(const QString&);
26 void diffViewerDocked();
28 public slots:
29 void on_updateRevDesc();
30 void lineEditDiff_returnPressed();
31 void button_clicked(int);
32 void buttonFilterPatch_clicked();
34 protected slots:
35 virtual void on_contextMenu(const QString&, int);
37 protected:
38 virtual bool doUpdate(bool force);
40 private:
41 void updatePatch();
42 void saveRestoreSizes(bool startup = false);
44 Ui_TabPatch* patchTab;
45 QString normalizedSha;
47 enum ButtonId {
48 DIFF_TO_PARENT = 0,
49 DIFF_TO_HEAD = 1,
50 DIFF_TO_SHA = 2
54 #endif