VR-Forces 4.2 Class Documentation
newSimulationModelSetWizard.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2013 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 
8 #pragma once
9 
11 #include <vrvUtil/DtVirtualBaseClass.h>
12 
13 #include <QtGui/QDialog>
14 #include <QtCore/QList>
15 
16 class QPushButton;
17 class QRadioButton;
18 class QFileDialog;
19 class QLineEdit;
21 class DtFilename;
22 class QProgressDialog;
23 
25 {
26  Q_OBJECT
27 
28 public:
29  DtWizardPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
30  virtual ~DtWizardPage();
31 
32  virtual DtWizardPage* nextPage(QWidget* p) { return NULL; };
33 
34  virtual bool isLastPage() const;
35  virtual bool pageComplete() const;
36  virtual bool nextPageComplete() const { return false; };
37 
38  virtual void execute() {};
39 
40  virtual void keyPressEvent(QKeyEvent*);
41 
42 signals:
43  void pageCompleted(bool);
44  void returnPressed();
45  void backPage();
46  void rejected();
47 
48 protected:
50  makVrv::DtDe& myDe;
51 };
52 
54 {
55  Q_OBJECT
56 
57 public:
58  DtNewModelSetPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
59  virtual ~DtNewModelSetPage();
60 
61  void setSimulationModelSet(const DtSimulationModelSet* s) { mySet = s; };
62 
63  virtual void accept();
64  virtual void reject();
65 
66 protected:
67  virtual bool isLastPage() const;
68  virtual bool hideButtons(QWidget*);
69  virtual bool pageComplete() const;
70  virtual bool nextPageComplete() const { return false; };
71  virtual QLineEdit* lineEdit(QWidget*);
72  virtual void execute();
73  virtual void createFromSet(const DtSimulationModelSet& set, const QStringList& ignoreFiles = QStringList());
74 
77  virtual int fileCount(const DtFilename&, const QStringList& ignore) const;
78  virtual bool duplicateDirectory(const DtFilename& sourceDir, const DtFilename& destDir,
79  const QStringList& ignore, QProgressDialog*, int& onFile);
80 
81 protected slots:
82  virtual void directoryChanged();
83 
84 protected:
87 };
88 
90 {
91  Q_OBJECT
92 
93 public:
94  DtExistingModelSetPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
95  virtual ~DtExistingModelSetPage();
96 
97 protected:
98  virtual bool isLastPage() const { return false; };
99  virtual bool pageComplete() const;
100  virtual bool nextPageComplete() const { return pageComplete(); };
101  virtual DtWizardPage* nextPage(QWidget* p);
102  virtual void execute();
103 
104 protected:
106 };
107 
109 {
110  Q_OBJECT
111 
112 public:
113  DtChoicePage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
114  virtual ~DtChoicePage();
115 
116 protected:
117  virtual DtWizardPage* nextPage(QWidget* p);
118  virtual bool pageComplete() const { return true; };
119  virtual bool nextPageComplete() const { return true; };
120  virtual void execute();
121  virtual DtNewModelSetPage* createNewModelSetPage(QWidget* p);
122  virtual DtExistingModelSetPage* createExistingModelSetPage(QWidget* p);
123 
124 protected:
125  QRadioButton* myCreateNew;
126  QRadioButton* myCreateFromExisting;
127 
130 };
131 
133 {
134  Q_OBJECT
135 
136 public:
137  DtNewSimulationModelSetWizard(makVrv::DtDe&, QWidget* p, const Qt::WindowFlags& f = 0);
139 
140  virtual void createNewModelSet();
141 
142 protected:
143  virtual void keyPressEvent(QKeyEvent*);
144  virtual DtChoicePage* createChoicePage(QWidget*);
145 
146 protected slots:
147  virtual void backButtonClicked();
148  virtual void nextButtonClicked();
149  virtual void enableNextButton(bool);
150  virtual void returnKeyPressed();
151 
152 protected:
158 
159 protected:
161  makVrv::DtDe& myDe;
162 };
163 
165 class DT_DLL_entityeditorimpl DtNewSimulationModelSetWizardCreator : public makVrv::DtVirtualBaseClass
166 {
167 public:
170 
173 
175  static DtNewSimulationModelSetWizardCreator& instance(makVrv::DtDe&);
176 
178  static void registerInstance(makVrv::DtDe&, DtNewSimulationModelSetWizardCreator*);
179 
181  virtual DtNewSimulationModelSetWizard* create(QWidget* parent);
182 
183 protected:
184  makVrv::DtDe& myDe;
185 };

Document ID: Generated on Sun Nov 24 19:49:21 EST 2013 from SVN revision 133924
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)