00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef GLUON_ENGINE_GAMEPROJECT_H
00022 #define GLUON_ENGINE_GAMEPROJECT_H
00023
00024 #include "gluon_engine_export.h"
00025 #include "scene.h"
00026
00027 #include <core/gluonobject.h>
00028
00029 #include <QtCore/QSharedData>
00030 #include <QtCore/QUrl>
00031
00032 namespace GluonEngine
00033 {
00034 class GameProjectPrivate;
00035
00049 class GLUON_ENGINE_EXPORT GameProject : public GluonCore::GluonObject
00050 {
00051 Q_OBJECT;
00052 GLUON_OBJECT( GluonCore::GameProject );
00053
00060 Q_PROPERTY( QString description READ description WRITE setDescription )
00066 Q_PROPERTY( QUrl homepage READ homepage WRITE setHomepage )
00071 Q_PROPERTY( QList<QUrl> mediaInfo READ mediaInfo WRITE setMediaInfo )
00072
00077 Q_PROPERTY( QUrl filename READ filename )
00078
00084 Q_PROPERTY( GluonEngine::Scene* entryPoint READ entryPoint WRITE setEntryPoint )
00085
00086 public:
00087 Q_INVOKABLE GameProject( QObject* parent = 0 );
00088 GameProject( const GameProject& other, QObject* parent = 0 );
00089 ~GameProject();
00090
00091 bool saveToFile() const;
00092 bool loadFromFile();
00093 bool loadFromFile( QUrl filename );
00094
00095
00096
00097
00098 QString description() const;
00099 void setDescription( QString newDescription );
00100
00101 QUrl homepage() const;
00102 void setHomepage( QUrl newHomepage );
00103
00104 QList<QUrl> mediaInfo() const;
00105 void setMediaInfo( QList<QUrl> newMediaInfo );
00106
00107 QUrl filename() const;
00108 void setFilename( QUrl newFilename );
00109
00110 Scene* entryPoint() const;
00111 void setEntryPoint( Scene* newEntryPoint );
00112
00113 private:
00114 QSharedDataPointer<GameProjectPrivate> d;
00115 };
00116 }
00117
00118 Q_DECLARE_METATYPE( GluonEngine::GameProject )
00119 Q_DECLARE_METATYPE( GluonEngine::GameProject* )
00120
00121 #endif // GLUON_ENGINE_GAMEPROJECT_H