summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2022-10-11 12:34:10 +0200
committerRémi Verschelde <rverschelde@gmail.com>2022-10-11 12:34:10 +0200
commit6ad1a635ee19c6d263061cc661476cd94022de5b (patch)
tree3bc54c350635c05c4621e028beda4b60f7a8d83e /platform
parent3a2e749a10da4f4b2a78ef437d3c2682967e51ee (diff)
parenta92c564a026b4e2beda1b41124f05b55dc0b48ee (diff)
Merge pull request #67242 from akien-mga/cleanup-unused-defines
Cleanup unused defines in platform code
Diffstat (limited to 'platform')
-rw-r--r--platform/macos/joypad_macos.h6
-rw-r--r--platform/uwp/os_uwp.cpp7
-rw-r--r--platform/windows/os_windows.cpp11
-rw-r--r--platform/windows/os_windows.h11
4 files changed, 5 insertions, 30 deletions
diff --git a/platform/macos/joypad_macos.h b/platform/macos/joypad_macos.h
index 4b14fed6d5..8743fc91a9 100644
--- a/platform/macos/joypad_macos.h
+++ b/platform/macos/joypad_macos.h
@@ -31,14 +31,10 @@
#ifndef JOYPAD_MACOS_H
#define JOYPAD_MACOS_H
-#ifdef MACOS_10_0_4
-#import <IOKit/hidsystem/IOHIDUsageTables.h>
-#else
-#import <Kernel/IOKit/hidsystem/IOHIDUsageTables.h>
-#endif
#import <ForceFeedback/ForceFeedback.h>
#import <ForceFeedback/ForceFeedbackConstants.h>
#import <IOKit/hid/IOHIDLib.h>
+#import <Kernel/IOKit/hidsystem/IOHIDUsageTables.h>
#include "core/input/input.h"
diff --git a/platform/uwp/os_uwp.cpp b/platform/uwp/os_uwp.cpp
index 8050d299f0..c93c3896ab 100644
--- a/platform/uwp/os_uwp.cpp
+++ b/platform/uwp/os_uwp.cpp
@@ -826,10 +826,6 @@ OS_UWP::OS_UWP() {
pressrc = 0;
old_invalid = true;
mouse_mode = MOUSE_MODE_VISIBLE;
-#ifdef STDOUT_FILE
- stdo = fopen("stdout.txt", "wb");
-#endif
-
gl_context = nullptr;
display_request = ref new Windows::System::Display::DisplayRequest();
@@ -847,7 +843,4 @@ OS_UWP::OS_UWP() {
}
OS_UWP::~OS_UWP() {
-#ifdef STDOUT_FILE
- fclose(stdo);
-#endif
}
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index cbec31249e..2f69a3b07e 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -1123,15 +1123,7 @@ Error OS_Windows::move_to_trash(const String &p_path) {
}
OS_Windows::OS_Windows(HINSTANCE _hInstance) {
- ticks_per_second = 0;
- ticks_start = 0;
- main_loop = nullptr;
- process_map = nullptr;
-
hInstance = _hInstance;
-#ifdef STDOUT_FILE
- stdo = fopen("stdout.txt", "wb");
-#endif
#ifdef WASAPI_ENABLED
AudioDriverManager::add_driver(&driver_wasapi);
@@ -1160,7 +1152,4 @@ OS_Windows::OS_Windows(HINSTANCE _hInstance) {
}
OS_Windows::~OS_Windows() {
-#ifdef STDOUT_FILE
- fclose(stdo);
-#endif
}
diff --git a/platform/windows/os_windows.h b/platform/windows/os_windows.h
index b792f6fa44..177b69eaac 100644
--- a/platform/windows/os_windows.h
+++ b/platform/windows/os_windows.h
@@ -84,13 +84,10 @@ public:
};
class JoypadWindows;
-class OS_Windows : public OS {
-#ifdef STDOUT_FILE
- FILE *stdo = nullptr;
-#endif
- uint64_t ticks_start;
- uint64_t ticks_per_second;
+class OS_Windows : public OS {
+ uint64_t ticks_start = 0;
+ uint64_t ticks_per_second = 0;
HINSTANCE hInstance;
MainLoop *main_loop = nullptr;
@@ -130,7 +127,7 @@ protected:
STARTUPINFO si;
PROCESS_INFORMATION pi;
};
- HashMap<ProcessID, ProcessInfo> *process_map;
+ HashMap<ProcessID, ProcessInfo> *process_map = nullptr;
public:
virtual void alert(const String &p_alert, const String &p_title = "ALERT!") override;