summaryrefslogtreecommitdiff
path: root/platform/osx/export
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2017-07-19 17:00:46 -0300
committerJuan Linietsky <reduzio@gmail.com>2017-07-19 17:06:03 -0300
commit25678b1876816b9ccb14b2c92aef62f3b009f88f (patch)
tree189f082d788f78e16f620b056d21249118883fc5 /platform/osx/export
parent89588d43349e496a9e05756d42ae87323d31269e (diff)
-Renamed GlobalConfig to ProjectSettings, makes more sense.
-Added system for feature overrides, it's pretty cool :)
Diffstat (limited to 'platform/osx/export')
-rw-r--r--platform/osx/export/export.cpp22
1 files changed, 15 insertions, 7 deletions
diff --git a/platform/osx/export/export.cpp b/platform/osx/export/export.cpp
index f0a7e3772e..03f424de8d 100644
--- a/platform/osx/export/export.cpp
+++ b/platform/osx/export/export.cpp
@@ -32,13 +32,13 @@
#include "editor/editor_export.h"
#include "editor/editor_node.h"
#include "editor/editor_settings.h"
-#include "global_config.h"
#include "io/marshalls.h"
#include "io/resource_saver.h"
#include "io/zip_io.h"
#include "os/file_access.h"
#include "os/os.h"
#include "platform/osx/logo.gen.h"
+#include "project_settings.h"
#include "string.h"
#include "version.h"
#include <sys/stat.h>
@@ -64,6 +64,7 @@ protected:
public:
virtual String get_name() const { return "Mac OSX"; }
+ virtual String get_os_name() const { return "OSX"; }
virtual Ref<Texture> get_logo() const { return logo; }
#ifdef OSX_ENABLED
@@ -75,6 +76,13 @@ public:
virtual bool can_export(const Ref<EditorExportPreset> &p_preset, String &r_error, bool &r_missing_templates) const;
+ virtual void get_platform_features(List<String> *r_features) {
+
+ r_features->push_back("pc");
+ r_features->push_back("s3tc");
+ r_features->push_back("OSX");
+ }
+
EditorExportPlatformOSX();
~EditorExportPlatformOSX();
};
@@ -275,8 +283,8 @@ Error EditorExportPlatformOSX::export_project(const Ref<EditorExportPreset> &p_p
String pkg_name;
if (p_preset->get("application/name") != "")
pkg_name = p_preset->get("application/name"); // app_name
- else if (String(GlobalConfig::get_singleton()->get("application/config/name")) != "")
- pkg_name = String(GlobalConfig::get_singleton()->get("application/config/name"));
+ else if (String(ProjectSettings::get_singleton()->get("application/config/name")) != "")
+ pkg_name = String(ProjectSettings::get_singleton()->get("application/config/name"));
else
pkg_name = "Unnamed";
@@ -345,7 +353,7 @@ Error EditorExportPlatformOSX::export_project(const Ref<EditorExportPreset> &p_p
if (p_preset->get("application/icon") != "")
iconpath = p_preset->get("application/icon");
else
- iconpath = GlobalConfig::get_singleton()->get("application/config/icon");
+ iconpath = ProjectSettings::get_singleton()->get("application/config/icon");
print_line("icon? " + iconpath);
if (iconpath != "") {
Ref<Image> icon;
@@ -484,8 +492,8 @@ Error EditorExportPlatformOSX::export_project(const Ref<EditorExportPreset> &p_p
String pkg_name;
if (p_preset->get("application/name") != "")
pkg_name = p_preset->get("application/name"); // app_name
- else if (String(GlobalConfig::get_singleton()->get("application/config/name")) != "")
- pkg_name = String(GlobalConfig::get_singleton()->get("application/config/name"));
+ else if (String(ProjectSettings::get_singleton()->get("application/config/name")) != "")
+ pkg_name = String(ProjectSettings::get_singleton()->get("application/config/name"));
else
pkg_name = "Unnamed";
@@ -539,7 +547,7 @@ Error EditorExportPlatformOSX::export_project(const Ref<EditorExportPreset> &p_p
if (p_preset->get("application/icon") != "")
iconpath = p_preset->get("application/icon");
else
- iconpath = GlobalConfig::get_singleton()->get("application/config/icon");
+ iconpath = ProjectSettings::get_singleton()->get("application/config/icon");
print_line("icon? " + iconpath);
if (iconpath != "") {
Ref<Image> icon;