-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathuploaddialog.h
93 lines (78 loc) · 2.39 KB
/
uploaddialog.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
/***************************************************************************
* Copyright 2007 Niko Sams <[email protected]> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef UPLOADDIALOG_H
#define UPLOADDIALOG_H
#include <QDialog>
#include <QModelIndex>
class QAbstractButton;
class QProgressDialog;
class QMenu;
class KJob;
namespace KDevelop {
class IProject;
class ProjectBaseItem;
}
class UploadProjectModel;
class UploadProfileModel;
class UploadProfileDlg;
class UploadPlugin;
namespace Ui {
class UploadDialog;
}
/**
* Dialog where the user can select the files to upload
*/
class UploadDialog : public QDialog
{
Q_OBJECT
public:
UploadDialog(KDevelop::IProject* project, UploadPlugin* plugin, QWidget *parent = nullptr);
~UploadDialog() override;
/**
* Set the root-item, only items below this are displayed
*/
void setRootItem(KDevelop::ProjectBaseItem* item);
/**
* Set the UploadProfileModel
*/
void setProfileModel(UploadProfileModel* model);
private Q_SLOTS:
/**
* Starts the upload
*/
void startUpload();
/**
* Current profile changed, sets the new profile to the model
*/
void profileChanged(int index);
/**
* Opens the UploadProfileDlg to edit the current profile
*/
void modifyProfile();
/**
* Called when the upload successfully finished, closes the UploadDialog
*/
void uploadFinished();
protected:
/**
* Event-filter for tree context-menu.
*/
bool eventFilter(QObject* obj, QEvent* event) override;
private:
Ui::UploadDialog* m_ui;
KDevelop::IProject* m_project;
UploadProjectModel* m_uploadProjectModel;
UploadProfileModel* m_profileModel;
UploadProfileDlg* m_editProfileDlg;
UploadPlugin* m_plugin;
QMenu* m_treeContextMenu;
};
#endif
// kate: space-indent on; indent-width 4; tab-width 4; replace-tabs on