summaryrefslogtreecommitdiff
path: root/platform/ios
diff options
context:
space:
mode:
Diffstat (limited to 'platform/ios')
-rw-r--r--platform/ios/display_server_ios.h4
-rw-r--r--platform/ios/display_server_ios.mm1
-rw-r--r--platform/ios/vulkan_context_ios.h4
-rw-r--r--platform/ios/vulkan_context_ios.mm4
4 files changed, 11 insertions, 2 deletions
diff --git a/platform/ios/display_server_ios.h b/platform/ios/display_server_ios.h
index f3624f24ab..af78ba3f05 100644
--- a/platform/ios/display_server_ios.h
+++ b/platform/ios/display_server_ios.h
@@ -40,7 +40,6 @@
#include "vulkan_context_ios.h"
-#import <QuartzCore/CAMetalLayer.h>
#ifdef USE_VOLK
#include <volk.h>
#else
@@ -48,6 +47,9 @@
#endif
#endif
+#import <Foundation/Foundation.h>
+#import <QuartzCore/CAMetalLayer.h>
+
class DisplayServerIOS : public DisplayServer {
GDCLASS(DisplayServerIOS, DisplayServer)
diff --git a/platform/ios/display_server_ios.mm b/platform/ios/display_server_ios.mm
index cf0fae4997..33d101ec8a 100644
--- a/platform/ios/display_server_ios.mm
+++ b/platform/ios/display_server_ios.mm
@@ -41,7 +41,6 @@
#include "tts_ios.h"
#import "view_controller.h"
-#import <Foundation/Foundation.h>
#import <sys/utsname.h>
static const float kDisplayServerIOSAcceleration = 1.f;
diff --git a/platform/ios/vulkan_context_ios.h b/platform/ios/vulkan_context_ios.h
index e9c09e087a..3849c8ba8a 100644
--- a/platform/ios/vulkan_context_ios.h
+++ b/platform/ios/vulkan_context_ios.h
@@ -31,6 +31,8 @@
#ifndef VULKAN_CONTEXT_IOS_H
#define VULKAN_CONTEXT_IOS_H
+#ifdef VULKAN_ENABLED
+
#include "drivers/vulkan/vulkan_context.h"
#import <UIKit/UIKit.h>
@@ -45,4 +47,6 @@ public:
~VulkanContextIOS();
};
+#endif // VULKAN_ENABLED
+
#endif // VULKAN_CONTEXT_IOS_H
diff --git a/platform/ios/vulkan_context_ios.mm b/platform/ios/vulkan_context_ios.mm
index 09cd369aa5..81b021e758 100644
--- a/platform/ios/vulkan_context_ios.mm
+++ b/platform/ios/vulkan_context_ios.mm
@@ -28,6 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
+#ifdef VULKAN_ENABLED
+
#include "vulkan_context_ios.h"
#ifdef USE_VOLK
#include <volk.h>
@@ -57,3 +59,5 @@ Error VulkanContextIOS::window_create(DisplayServer::WindowID p_window_id, Displ
VulkanContextIOS::VulkanContextIOS() {}
VulkanContextIOS::~VulkanContextIOS() {}
+
+#endif // VULKAN_ENABLED