summaryrefslogtreecommitdiff
path: root/platform/iphone
diff options
context:
space:
mode:
authorMarcel Admiraal <madmiraal@users.noreply.github.com>2020-12-15 12:04:21 +0000
committerMarcel Admiraal <madmiraal@users.noreply.github.com>2020-12-28 10:39:56 +0000
commit5b937d493f0046543a77a0be7920ad39f1e5fc3c (patch)
tree975e0a7384bc6fc7cf5b73b9ddc1e8eef13579d8 /platform/iphone
parent886571e0fc54914f161ab3f1ccf9bfe40411bc20 (diff)
Rename empty() to is_empty()
Diffstat (limited to 'platform/iphone')
-rw-r--r--platform/iphone/export/export.cpp12
-rw-r--r--platform/iphone/plugin/godot_plugin_config.h18
2 files changed, 15 insertions, 15 deletions
diff --git a/platform/iphone/export/export.cpp b/platform/iphone/export/export.cpp
index 3406c75c35..7cd67bc0ad 100644
--- a/platform/iphone/export/export.cpp
+++ b/platform/iphone/export/export.cpp
@@ -218,7 +218,7 @@ public:
da->list_dir_begin();
while (true) {
String file = da->get_next();
- if (file.empty()) {
+ if (file.is_empty()) {
break;
}
@@ -259,7 +259,7 @@ public:
if (DirAccess::exists(plugins_dir)) {
Vector<String> plugins_filenames = list_plugin_config_files(plugins_dir, true);
- if (!plugins_filenames.empty()) {
+ if (!plugins_filenames.is_empty()) {
Ref<ConfigFile> config_file = memnew(ConfigFile);
for (int i = 0; i < plugins_filenames.size(); i++) {
PluginConfig config = load_plugin_config(config_file, plugins_dir.plus_file(plugins_filenames[i]));
@@ -815,7 +815,7 @@ Error EditorExportPlatformIOS::_export_loading_screen_file(const Ref<EditorExpor
const String splash_path = ProjectSettings::get_singleton()->get("application/boot_splash/image");
- if (!splash_path.empty()) {
+ if (!splash_path.is_empty()) {
splash.instance();
const Error err = splash->load(splash_path);
if (err) {
@@ -1430,7 +1430,7 @@ Error EditorExportPlatformIOS::_export_ios_plugins(const Ref<EditorExportPreset>
String key = *K;
String value = plugin.plist[key];
- if (key.empty() || value.empty()) {
+ if (key.is_empty() || value.is_empty()) {
continue;
}
@@ -1457,7 +1457,7 @@ Error EditorExportPlatformIOS::_export_ios_plugins(const Ref<EditorExportPreset>
String key = *K;
String value = plist_values[key];
- if (key.empty() || value.empty()) {
+ if (key.is_empty() || value.is_empty()) {
continue;
}
@@ -1930,7 +1930,7 @@ bool EditorExportPlatformIOS::can_export(const Ref<EditorExportPreset> &p_preset
err += etc_error;
}
- if (!err.empty()) {
+ if (!err.is_empty()) {
r_error = err;
}
diff --git a/platform/iphone/plugin/godot_plugin_config.h b/platform/iphone/plugin/godot_plugin_config.h
index 5323f94989..e536616994 100644
--- a/platform/iphone/plugin/godot_plugin_config.h
+++ b/platform/iphone/plugin/godot_plugin_config.h
@@ -97,7 +97,7 @@ struct PluginConfig {
static inline String resolve_local_dependency_path(String plugin_config_dir, String dependency_path) {
String absolute_path;
- if (dependency_path.empty()) {
+ if (dependency_path.is_empty()) {
return absolute_path;
}
@@ -114,7 +114,7 @@ static inline String resolve_local_dependency_path(String plugin_config_dir, Str
static inline String resolve_system_dependency_path(String dependency_path) {
String absolute_path;
- if (dependency_path.empty()) {
+ if (dependency_path.is_empty()) {
return absolute_path;
}
@@ -133,7 +133,7 @@ static inline Vector<String> resolve_local_dependencies(String plugin_config_dir
for (int i = 0; i < p_paths.size(); i++) {
String path = resolve_local_dependency_path(plugin_config_dir, p_paths[i]);
- if (path.empty()) {
+ if (path.is_empty()) {
continue;
}
@@ -149,7 +149,7 @@ static inline Vector<String> resolve_system_dependencies(Vector<String> p_paths)
for (int i = 0; i < p_paths.size(); i++) {
String path = resolve_system_dependency_path(p_paths[i]);
- if (path.empty()) {
+ if (path.is_empty()) {
continue;
}
@@ -160,10 +160,10 @@ static inline Vector<String> resolve_system_dependencies(Vector<String> p_paths)
}
static inline bool validate_plugin(PluginConfig &plugin_config) {
- bool valid_name = !plugin_config.name.empty();
- bool valid_binary_name = !plugin_config.binary.empty();
- bool valid_initialize = !plugin_config.initialization_method.empty();
- bool valid_deinitialize = !plugin_config.deinitialization_method.empty();
+ bool valid_name = !plugin_config.name.is_empty();
+ bool valid_binary_name = !plugin_config.binary.is_empty();
+ bool valid_initialize = !plugin_config.initialization_method.is_empty();
+ bool valid_deinitialize = !plugin_config.deinitialization_method.is_empty();
bool fields_value = valid_name && valid_binary_name && valid_initialize && valid_deinitialize;
@@ -247,7 +247,7 @@ static inline PluginConfig load_plugin_config(Ref<ConfigFile> config_file, const
for (int i = 0; i < keys.size(); i++) {
String value = config_file->get_value(PLIST_SECTION, keys[i], String());
- if (value.empty()) {
+ if (value.is_empty()) {
continue;
}