VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
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 
12 #include <vlutil/vlString.h>
13 
14 #include <QtWidgets/QDialog>
15 #include <QtCore/QList>
16 
17 class QPushButton;
18 class QRadioButton;
19 class QFileDialog;
20 class QLineEdit;
22 class DtFilename;
23 class QProgressDialog;
25 class QLabel;
26 class QVBoxLayout;
27 
29 {
30  Q_OBJECT
31 
32 public:
33  DtWizardPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
34  virtual ~DtWizardPage();
35 
36  virtual DtWizardPage* nextPage(QWidget* p) { return NULL; };
37 
38  virtual bool isLastPage() const;
39  virtual bool showFinishButton() const;
40  virtual bool pageComplete() const;
41  virtual bool nextPageComplete() const { return false; };
42 
43  virtual void execute() {};
44 
45  virtual void cancel() {};
46 
47  virtual void keyPressEvent(QKeyEvent*);
48 
49  virtual void setTitle(const QString&);
50  virtual void setDescription(const QString&);
51 
52  virtual void showTitle(bool);
53  virtual void showDescription(bool);
54 
55 signals:
56  void pageCompleted(bool);
57  void returnPressed();
58  void backPage();
59  void rejected();
60 
61 protected:
64 
65 public:
67  QWidget* myContents;
68  QVBoxLayout* myContentsLayout;
69  QVBoxLayout* myMainLayout;
71 };
72 
74 {
75  Q_OBJECT
76 
77 public:
78  DtNewModelSetPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0, bool shallowCopyOnly = false);
79  virtual ~DtNewModelSetPage();
80 
81  void setSimulationModelSet(const DtSimulationModelSet* s) { mySet = s; };
82 
83  virtual void accept();
84  virtual void reject();
85 
86  virtual void setIncludeSMSFiles(const std::vector<DtString>&);
87  virtual void setIncludeSMSFiles(const QString&);
88 
89 protected:
90  virtual bool isLastPage() const;
91  virtual bool showFinishButton() const { return true; };
92  virtual bool hideButtons(QWidget*);
93  virtual bool pageComplete() const;
94  virtual bool nextPageComplete() const { return false; };
95  virtual QLineEdit* lineEdit(QWidget*);
96  virtual void execute();
97  virtual void createFromSet(const DtSimulationModelSet& set, const QStringList& ignoreFiles = QStringList(),
98  const QStringList& overrideIgnoreFiles = QStringList());
99 
102  virtual int fileCount(const DtFilename&, const QStringList& ignore) const;
103  virtual bool duplicateDirectory(const DtFilename& sourceDir, const DtFilename& destDir,
104  const QStringList& ignore, const QStringList& overrideIgnore, QProgressDialog*, int& onFile);
105 
106 protected slots:
107  virtual void directoryChanged();
108 
109 public:
111 
112 protected:
114  std::vector<DtString> myIncludeSMSFiles;
116 };
117 
119 {
120  Q_OBJECT
121 
122 public:
123  DtExistingModelSetPage(makVrv::DtDe&, QWidget*, const QString& title, const Qt::WindowFlags& f = 0, DtNewModelSetPage* nextPage = 0, bool shallowCopyOnly = false);
124  virtual ~DtExistingModelSetPage();
125 
126 protected:
127  virtual bool isLastPage() const { return false; };
128  virtual bool showFinishButton() const { return false; };
129  virtual bool pageComplete() const;
130  virtual bool nextPageComplete() const { return pageComplete(); };
131  virtual DtWizardPage* nextPage(QWidget* p);
132  virtual void execute();
133 
134 protected:
138 };
139 
141 {
142  Q_OBJECT
143 
144 public:
145  DtIncludeSimulationModelSetsPage(makVrv::DtDe&, QWidget*, DtWizardPage* nextPage, DtWizardPage* parentPage = 0, const Qt::WindowFlags& f = 0);
147 
148  virtual void setSimulationModelSet(const QString&);
149 
150 protected:
151  virtual bool isLastPage() const;
152  virtual bool pageComplete() const;
153  virtual bool nextPageComplete() const { return pageComplete(); };
154  virtual DtWizardPage* nextPage(QWidget* p);
155  virtual void execute();
156  virtual void copyIncludeFiles();
157  virtual void copyIncludeFiles(DtWizardPage*);
158 
159 protected:
164 };
165 
167 {
168  Q_OBJECT
169 
170 public:
171  DtSimulationModelSetSelectionPage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
173 
174 protected:
175  virtual DtWizardPage* nextPage(QWidget* p);
176  virtual bool pageComplete() const { return true; };
177  virtual bool nextPageComplete() const { return true; };
178  virtual void execute();
179  virtual DtNewModelSetPage* createNewModelSetPage(QWidget* p, bool shallowCopyOnly);
180  virtual DtExistingModelSetPage* createExistingModelSetPage(QWidget* p, DtNewModelSetPage* nextPage,
181  const QString& title, bool shallowCopyOnly = false);
182 
183 public:
184  QWidget* myChoiceWidget;
185  QRadioButton* myMinimalModelSet;
186  QRadioButton* myExtendExisting;
188 
189 protected:
191 };
192 
194 {
195  Q_OBJECT
196 
197 public:
198  DtChoicePage(makVrv::DtDe&, QWidget*, const Qt::WindowFlags& f = 0);
199  virtual ~DtChoicePage();
200 
201 protected:
202  virtual DtWizardPage* nextPage(QWidget* p);
203  virtual bool pageComplete() const { return true; };
204  virtual bool nextPageComplete() const { return true; };
205  virtual void execute();
206  virtual DtSimulationModelSetSelectionPage* createSimulationModelSetSelectionPage(QWidget* p);
207  virtual DtExistingModelSetPage* createExistingModelSetPage(QWidget* p, DtNewModelSetPage* nextPage, const QString& title, bool shallowCopyOnly = false);
208 
209 public:
210  QWidget* myChoiceWidget;
211  QRadioButton* myCreateNew;
212  QRadioButton* myCreateFromExisting;
214 
215 protected:
217 };
218 
220 {
221  Q_OBJECT
222 
223 public:
224  DtNewSimulationModelSetWizard(makVrv::DtDe&, QWidget* p, const Qt::WindowFlags& f = 0, DtWizardPage* statePage = 0);
226 
227  virtual void createNewModelSet();
228 
229 protected:
230  virtual void keyPressEvent(QKeyEvent*);
231  virtual DtChoicePage* createChoicePage(QWidget*);
232 
233 protected slots:
234  virtual void backButtonClicked();
235  virtual void nextButtonClicked();
236  virtual void enableNextButton(bool);
237  virtual void returnKeyPressed();
238 
239 protected:
245 
246 protected:
247  QWidget* myChoicePage;
250 };
251 
254 {
255 public:
258 
261 
264 
266  static void registerInstance(makVrv::DtDe&, DtNewSimulationModelSetWizardCreator*);
267 
269  virtual DtNewSimulationModelSetWizard* create(QWidget* parent, DtWizardPage* startPage = 0);
270 
271 protected:
273 };
virtual DtWizardPage * nextPage(QWidget *p)
Definition: newSimulationModelSetWizard.h:36
QWidget * myChoicePage
Definition: newSimulationModelSetWizard.h:247
Virtual base class. Allows for RTTI and proper virtual destruction. Used by Creators, Factories, Providers, Assemblers and User Interfaces.
Definition: DtVirtualBaseClass.h:19
virtual bool pageComplete() const
DtWizardPage * myNextPage
Definition: newSimulationModelSetWizard.h:213
DtIncludeFilesWidget * myIncludeFilesWidget
Definition: newSimulationModelSetWizard.h:161
makVrv::DtDe & myDe
Definition: newSimulationModelSetWizard.h:248
DtWizardPage * myParentPage
Definition: newSimulationModelSetWizard.h:163
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:153
QLabel * myLabel
Definition: newSimulationModelSetWizard.h:160
DtWizardPage * myNextPage
Definition: newSimulationModelSetWizard.h:136
Definition: newSimulationModelSetWizard.h:166
virtual bool showFinishButton() const
Definition: newSimulationModelSetWizard.h:91
bool myCreateNewWasChecked
Definition: newSimulationModelSetWizard.h:216
QPushButton * myCancelButton
Definition: newSimulationModelSetWizard.h:242
DtWizardPage * myNextPage
Definition: newSimulationModelSetWizard.h:187
QPushButton * myBackButton
Definition: newSimulationModelSetWizard.h:241
QLabel * myTitle
Definition: newSimulationModelSetWizard.h:66
QRadioButton * myCreateNew
Definition: newSimulationModelSetWizard.h:211
std::vector< DtString > myIncludeSMSFiles
Definition: newSimulationModelSetWizard.h:114
QPushButton * myFinishButton
Definition: newSimulationModelSetWizard.h:243
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:130
virtual void execute()
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:177
QFileDialog * myDirectory
Definition: newSimulationModelSetWizard.h:110
DtWizardPage * myStartPage
Definition: newSimulationModelSetWizard.h:249
virtual bool pageComplete() const
const DtSimulationModelSet * mySet
Definition: newSimulationModelSetWizard.h:113
QRadioButton * myExtendExisting
Definition: newSimulationModelSetWizard.h:186
bool myShallowCopyOnly
Definition: newSimulationModelSetWizard.h:137
DtWizardPage * myNewModelSetPage
Definition: newSimulationModelSetWizard.h:135
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:41
Contains makVrv::DtVirtualBaseClass class.
Definition: newSimulationModelSetWizard.h:73
bool myMinimalWasChecked
Definition: newSimulationModelSetWizard.h:190
QPushButton * myNextButton
Definition: newSimulationModelSetWizard.h:240
QWidget * myChoiceWidget
Definition: newSimulationModelSetWizard.h:184
QVBoxLayout * myMainLayout
Definition: newSimulationModelSetWizard.h:69
virtual bool pageComplete() const
Definition: newSimulationModelSetWizard.h:176
Definition: newSimulationModelSetWizard.h:118
Definition: newSimulationModelSetWizard.h:219
Definition: newSimulationModelSetWizard.h:193
Definition: newSimulationModelSetWizard.h:140
bool myShallowCopyOnly
Definition: newSimulationModelSetWizard.h:115
makVrv::DtDe & myDe
Definition: newSimulationModelSetWizard.h:272
QWidget * myChoiceWidget
Definition: newSimulationModelSetWizard.h:210
virtual void cancel()
Definition: newSimulationModelSetWizard.h:45
QLabel * myDescription
Definition: newSimulationModelSetWizard.h:70
QRadioButton * myMinimalModelSet
Definition: newSimulationModelSetWizard.h:185
Definition: newSimulationModelSetWizard.h:28
A simulation model set contains all the information that can be used to support a scenario either for...
Definition: simulationModelSet.h:31
Creator for the dialog.
Definition: newSimulationModelSetWizard.h:253
DtWizardPage * myNextPage
Definition: newSimulationModelSetWizard.h:162
QList< DtWizardPage * > myPages
Definition: newSimulationModelSetWizard.h:244
QWidget * myContents
Definition: newSimulationModelSetWizard.h:67
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:94
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:70
virtual bool showFinishButton() const
Definition: newSimulationModelSetWizard.h:128
virtual bool pageComplete() const
Definition: newSimulationModelSetWizard.h:203
QVBoxLayout * myContentsLayout
Definition: newSimulationModelSetWizard.h:68
Definition: includeFilesEditor.h:38
makVrv::DtDe & myDe
Definition: newSimulationModelSetWizard.h:63
virtual void execute()
Definition: newSimulationModelSetWizard.h:43
DtWizardPage * myNextPage
Definition: newSimulationModelSetWizard.h:62
virtual bool isLastPage() const
virtual bool isLastPage() const
Definition: newSimulationModelSetWizard.h:127
QRadioButton * myCreateFromExisting
Definition: newSimulationModelSetWizard.h:212
virtual bool nextPageComplete() const
Definition: newSimulationModelSetWizard.h:204
#define DT_DLL_simulationObjectEditorimpl
This file is used to determine how to build.
Definition: simulationObjectEditorImplDefines.h:33
void setSimulationModelSet(const DtSimulationModelSet *s)
Definition: newSimulationModelSetWizard.h:81

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)