| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | #ifndef DIVELOGIMPORTDIALOG_H
 | 
					
						
							|  |  |  | #define DIVELOGIMPORTDIALOG_H
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include <QDialog>
 | 
					
						
							| 
									
										
										
										
											2014-06-26 14:01:31 -03:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | #include "../dive.h"
 | 
					
						
							|  |  |  | #include "../divelist.h"
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-05-22 11:40:22 -07:00
										 |  |  | namespace Ui { | 
					
						
							| 
									
										
										
										
											2014-02-27 20:09:57 -08:00
										 |  |  | 	class DiveLogImportDialog; | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-02-27 20:09:57 -08:00
										 |  |  | class DiveLogImportDialog : public QDialog { | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	Q_OBJECT | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | public: | 
					
						
							| 
									
										
										
										
											2014-01-07 22:01:28 +02:00
										 |  |  | 	explicit DiveLogImportDialog(QStringList *fn, QWidget *parent = 0); | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	~DiveLogImportDialog(); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-02-27 20:09:57 -08:00
										 |  |  | private | 
					
						
							|  |  |  | slots: | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	void on_buttonBox_accepted(); | 
					
						
							|  |  |  | 	void on_knownImports_currentIndexChanged(int index); | 
					
						
							|  |  |  | 	void unknownImports(); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-01-14 15:58:20 -02:00
										 |  |  | private: | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	bool selector; | 
					
						
							| 
									
										
										
										
											2014-01-07 22:01:28 +02:00
										 |  |  | 	QStringList fileNames; | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	Ui::DiveLogImportDialog *ui; | 
					
						
							| 
									
										
										
										
											2014-01-16 22:50:16 +02:00
										 |  |  | 	QList<int> specialCSV; | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  | 	struct CSVAppConfig { | 
					
						
							|  |  |  | 		QString name; | 
					
						
							|  |  |  | 		int time; | 
					
						
							|  |  |  | 		int depth; | 
					
						
							|  |  |  | 		int temperature; | 
					
						
							|  |  |  | 		int po2; | 
					
						
							|  |  |  | 		int cns; | 
					
						
							| 
									
										
										
										
											2014-07-09 22:13:37 +02:00
										 |  |  | 		int ndl; | 
					
						
							| 
									
										
										
										
											2014-07-09 22:13:38 +02:00
										 |  |  | 		int tts; | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 		int stopdepth; | 
					
						
							| 
									
										
										
										
											2014-07-10 20:54:18 +02:00
										 |  |  | 		int pressure; | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 		QString separator; | 
					
						
							|  |  |  | 	}; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-07-09 21:07:45 +02:00
										 |  |  | #define CSVAPPS 6
 | 
					
						
							| 
									
										
										
										
											2013-12-29 18:11:20 +02:00
										 |  |  | 	static const CSVAppConfig CSVApps[CSVAPPS]; | 
					
						
							|  |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #endif // DIVELOGIMPORTDIALOG_H
 |