From 9aaf5514ce18273ff3525a56de670a919c4e8444 Mon Sep 17 00:00:00 2001 From: Quentin Quadrat Date: Tue, 11 Jun 2024 00:44:16 +0200 Subject: [PATCH] Use macros syntax: upper case instead of lower case --- addons/gdcef/gdcef/src/gdcef.cpp | 6 +++--- addons/gdcef/gdcef/src/helper_config.hpp | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/gdcef/gdcef/src/gdcef.cpp b/addons/gdcef/gdcef/src/gdcef.cpp index 7bc0dfa..1099273 100644 --- a/addons/gdcef/gdcef/src/gdcef.cpp +++ b/addons/gdcef/gdcef/src/gdcef.cpp @@ -121,7 +121,7 @@ bool GDCef::initialize(godot::Dictionary config) // Check if this process is executing from the Godot editor or from the // your standalone application. - if (isStartedFromGodotEditor()) + if (IS_STARTED_FROM_GODOT_EDITOR()) { std::string cef_folder_path = getConfig(config, "artifacts", std::string(CEF_ARTIFACTS_FOLDER)); @@ -130,7 +130,7 @@ bool GDCef::initialize(godot::Dictionary config) // Note: exported projects don't support globalize_path, see: // https://docs.godotengine.org/en/3.5/classes/class_projectsettings.html // Section: class-projectsettings-method-globalize-path - folder = globalize_path(cef_folder_path); + folder = GLOBALIZE_PATH(cef_folder_path); } else { @@ -167,7 +167,7 @@ bool GDCef::initialize(godot::Dictionary config) // Note: passed m_impl as 3th argument (as CefApp) because this is needed // to call OnBeforeCommandLineProcessing(). CefMainArgs args; - GDCEF_DEBUG_VAL("[GDCEF][GDCef::_init] CefInitialize"); + GDCEF_DEBUG_VAL("CefInitialize"); if (!CefInitialize(args, m_cef_settings, m_impl, nullptr)) { GDCEF_ERROR("CefInitialize failed"); diff --git a/addons/gdcef/gdcef/src/helper_config.hpp b/addons/gdcef/gdcef/src/helper_config.hpp index 277dffe..75a58ab 100644 --- a/addons/gdcef/gdcef/src/helper_config.hpp +++ b/addons/gdcef/gdcef/src/helper_config.hpp @@ -32,10 +32,10 @@ //! \brief CEF can be run either from the binary (standalone application) or //! from the Godot editor. We have to distinguish the both case. // **************************************************************************** -#define isStartedFromGodotEditor() \ +#define IS_STARTED_FROM_GODOT_EDITOR() \ godot::OS::get_singleton()->has_feature("editor") -#define globalize_path(path) \ +#define GLOBALIZE_PATH(path) \ godot::ProjectSettings::get_singleton()->globalize_path(path.c_str()).utf8().get_data() // ****************************************************************************