ZIMA CAD Parts
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
addeditdatasource.h
Go to the documentation of this file.
1 /*
2  ZIMA-CAD-Parts
3  http://www.zima-construction.cz/software/ZIMA-Parts
4 
5  Copyright (C) 2011-2012 Jakub Skokan <aither@havefun.cz>
6 
7  This program is free software: you can redistribute it and/or modify
8  it under the terms of the GNU General Public License as published by
9  the Free Software Foundation, either version 3 of the License, or
10  (at your option) any later version.
11 
12  This program is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  GNU General Public License for more details.
16 
17  You should have received a copy of the GNU General Public License
18  along with this program. If not, see <http://www.gnu.org/licenses/>.
19 */
20 
21 #ifndef ADDEDITDATASOURCE_H
22 #define ADDEDITDATASOURCE_H
23 
24 #include <QDialog>
25 #include <QList>
26 #include "basedatasource.h"
27 #include "ftpdatasource.h"
28 #include "localdatasource.h"
29 
30 namespace Ui {
31 class AddEditDataSource;
32 }
33 
34 class AddEditDataSource : public QDialog
35 {
36  Q_OBJECT
37 
38 public:
39  enum Actions {
40  ADD=0,
42  };
43 
44  explicit AddEditDataSource(BaseDataSource *dataSource, Actions action, QWidget *parent = 0);
46 
48 
49 private:
50  void refill();
51 
52  Ui::AddEditDataSource *ui;
53  DataSourceList dataSources;
54  BaseDataSource *lastDataSource;
55 private slots:
56  void openFileDialog();
57  void dataSourceTypeChanged(int index);
58  void labelChangedByUser();
59 };
60 
61 #endif // ADDEDITDATASOURCE_H
Definition: addeditdatasource.h:34
BaseDataSource * dataSource()
Definition: addeditdatasource.cpp:60
Definition: basedatasource.h:50
AddEditDataSource(BaseDataSource *dataSource, Actions action, QWidget *parent=0)
Definition: addeditdatasource.cpp:28
Actions
Definition: addeditdatasource.h:39
~AddEditDataSource()
Definition: addeditdatasource.cpp:51
Definition: addeditdatasource.h:40
QList< BaseDataSource * > DataSourceList
Definition: basedatasource.h:127
Definition: addeditdatasource.h:41