summaryrefslogtreecommitdiffstats
path: root/external/physfs/src/physfs_platform_winrt.cpp
diff options
context:
space:
mode:
authoruntodesu <kirill@untode.su>2025-12-11 15:14:26 +0500
committeruntodesu <kirill@untode.su>2025-12-11 15:14:26 +0500
commitf40d09cb8f712e87691af4912f3630d92d692779 (patch)
tree7ac3a4168ff722689372fd489c6f94d0a2546e8f /external/physfs/src/physfs_platform_winrt.cpp
parent8bcbd2729388edc63c82d77d314b583af1447c49 (diff)
downloadvoxelius-f40d09cb8f712e87691af4912f3630d92d692779.tar.bz2
voxelius-f40d09cb8f712e87691af4912f3630d92d692779.zip
Shuffle stuff around
- Use the new and improved hierarchy I figured out when making Prospero chat - Re-add NSIS scripts, again from Prospero - Update most build and utility scripts with their most recent versions
Diffstat (limited to 'external/physfs/src/physfs_platform_winrt.cpp')
-rw-r--r--external/physfs/src/physfs_platform_winrt.cpp41
1 files changed, 41 insertions, 0 deletions
diff --git a/external/physfs/src/physfs_platform_winrt.cpp b/external/physfs/src/physfs_platform_winrt.cpp
new file mode 100644
index 0000000..f50fc9d
--- /dev/null
+++ b/external/physfs/src/physfs_platform_winrt.cpp
@@ -0,0 +1,41 @@
+/*
+ * Windows Runtime (WinRT) support routines for PhysicsFS.
+ *
+ * Please see the file LICENSE.txt in the source's root directory.
+ *
+ * This file originally written by Martin "T-Bone" Ahrnbom, but was mostly
+ * merged into physfs_platform_windows.c by Ryan C. Gordon (so please harass
+ * Ryan about bugs and not Martin).
+ */
+
+/* (There used to be instructions on how to make a WinRT project, but at
+ this point, either CMake will do it for you or you should just drop
+ PhysicsFS's sources into your existing project. --ryan.) */
+
+#define __PHYSICSFS_INTERNAL__
+#include "physfs_platforms.h"
+
+#ifdef PHYSFS_PLATFORM_WINRT
+
+#if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_WARNINGS)
+#define _CRT_SECURE_NO_WARNINGS 1
+#endif
+#include <windows.h>
+
+#include "physfs_internal.h"
+
+const void *__PHYSFS_winrtCalcBaseDir(void)
+{
+ return Windows::ApplicationModel::Package::Current->InstalledLocation->Path->Data();
+} /* __PHYSFS_winrtCalcBaseDir */
+
+const void *__PHYSFS_winrtCalcPrefDir(void)
+{
+ return Windows::Storage::ApplicationData::Current->LocalFolder->Path->Data();
+} /* __PHYSFS_winrtCalcBaseDir */
+
+
+#endif /* PHYSFS_PLATFORM_WINRT */
+
+/* end of physfs_platform_winrt.cpp ... */
+