Sun, 19 Jan 2020 02:54:48 +0200
commit work on GL rendering
3 | 1 | #pragma once |
12 | 2 | #include "libraries.h" |
3 | 3 | #include "model.h" |
4 | ||
5 | 5 | class DocumentManager : public QObject |
3 | 6 | { |
5 | 7 | Q_OBJECT |
8
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
8 | using ModelPointer = std::unique_ptr<Model>; |
3 | 9 | public: |
21 | 10 | DocumentManager(QObject* parent = nullptr); |
8
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
11 | QString newModel(); |
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
12 | Model* findModelByName(const QString& name); |
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
13 | QString openModel(const QString& path, QTextStream& errorStream); |
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
14 | QString makeNewModelName(); |
12 | 15 | void loadDependenciesForModel(const QString& modelName, |
16 | const LibraryManager& libraries, | |
17 | QTextStream& errorStream); | |
3 | 18 | private: |
8
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
19 | int untitledNameCounter = 0; |
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
5
diff
changeset
|
20 | std::map<QString, ModelPointer> openModels; |
12 | 21 | void loadDependenciesForModel(const QString& modelName, |
22 | const LibraryManager& libraries, | |
23 | QStringList& missing, | |
24 | QStringList& processed, | |
25 | QTextStream& errorStream); | |
3 | 26 | }; |