Polyphase Game Engine
Loading...
Searching...
No Matches
GeneralModule.h
Go to the documentation of this file.
1#pragma once
2
3#if EDITOR
4
5#include "../PreferencesModule.h"
6
7class GeneralModule : public PreferencesModule
8{
9public:
10 DECLARE_PREFERENCES_MODULE(GeneralModule)
11
12 GeneralModule();
13 virtual ~GeneralModule();
14
15 virtual const char* GetName() const override { return GetStaticName(); }
16 virtual const char* GetParentPath() const override { return GetStaticParentPath(); }
17 virtual void Render() override;
18 virtual void LoadSettings(const rapidjson::Document& doc) override;
19 virtual void SaveSettings(rapidjson::Document& doc) override;
20
21 // Settings accessors
22 bool GetAutoSave() const { return mAutoSave; }
23 int GetRecentProjectsLimit() const { return mRecentProjectsLimit; }
24 bool GetShowWelcomeScreen() const { return mShowWelcomeScreen; }
25 bool GetShowDebugInEditor() const { return mShowDebugInEditor; }
26 bool GetShowDebugLogsInBuild() const { return mShowDebugLogsInBuild; }
27 bool GetCheckBuildDepsOnStartup() const { return mCheckBuildDepsOnStartup; }
28 void SetCheckBuildDepsOnStartup(bool value);
29
30private:
31 bool mAutoSave = true;
32 int mRecentProjectsLimit = 10;
33 bool mShowWelcomeScreen = true;
34 bool mShowDebugInEditor = true;
35 bool mShowDebugLogsInBuild = true;
36 bool mCheckBuildDepsOnStartup = true;
37};
38
39#endif
Definition JsonHelpers.h:15