summaryrefslogtreecommitdiffhomepage
path: root/Public/Developer/SystemLib
diff options
context:
space:
mode:
authorAmlal <amlalelmahrouss@icloud.com>2024-04-28 15:13:03 +0000
committerAmlal <amlalelmahrouss@icloud.com>2024-04-28 15:13:03 +0000
commit14f10cc0b35155ddb19ec9069ebb884246e61dcf (patch)
treea988617d1c511cf04eb2c2392829a37d82a59e2e /Public/Developer/SystemLib
parentdb0681412191dcceb5aa99cf31fb8339d6bc4adb (diff)
parent346558208d39a036effe3a4ec232fa5df5a3c8e7 (diff)
Merged in MHR-18 (pull request #8)
MHR-18: A lot of fixes and improvements, mostly related to disk I/O and kernel stability.
Diffstat (limited to 'Public/Developer/SystemLib')
-rw-r--r--Public/Developer/SystemLib/Headers/Defines.h28
-rw-r--r--Public/Developer/SystemLib/Headers/Wm.h9
-rw-r--r--Public/Developer/SystemLib/Sources/Wm.c19
3 files changed, 16 insertions, 40 deletions
diff --git a/Public/Developer/SystemLib/Headers/Defines.h b/Public/Developer/SystemLib/Headers/Defines.h
index 3be7552f..57bfffdf 100644
--- a/Public/Developer/SystemLib/Headers/Defines.h
+++ b/Public/Developer/SystemLib/Headers/Defines.h
@@ -52,8 +52,10 @@ typedef void* PtrVoidType;
typedef void VoidType;
#ifdef __SINGLE_PRECISION__
+typedef float FloatType;
typedef float PositionType;
#else
+typedef double FloatType;
typedef double PositionType;
#endif
@@ -84,23 +86,23 @@ typedef CharacterTypeUTF8 BooleanType;
# define CA_FAR
# define CA_NEAR
-#endif
+#endif
#ifdef __aarch64__
# define _M_AARCH64 3
-#endif
+#endif
#ifdef __powerpc64__
-# define _M_PPC64 4
-#endif
+# define _M_PPC64 4
+#endif
#ifdef __64x0__
-# define _M_64000 5
-#endif
+# define _M_64000 5
+#endif
#ifdef __riscv__
# define _M_RISCV 6
-#endif
+#endif
#define CA_STATIC static
#define CA_INLINE inline
@@ -191,18 +193,18 @@ using StrType = CharacterTypeUTF8[N];
#endif // ifdef C++
/// @brief Get app singleton.
-/// @param
-/// @return
+/// @param
+/// @return
CA_EXTERN_C ApplicationRef RtGetAppPointer(VoidType);
/// @brief Get argument count
-/// @param
-/// @return
+/// @param
+/// @return
CA_EXTERN_C SizeType RtGetAppArgumentsCount(VoidType);
/// @brief Get argument pointer.
-/// @param
-/// @return
+/// @param
+/// @return
CA_EXTERN_C CharacterTypeUTF8** RtGetAppArgumentsPtr(VoidType);
CA_EXTERN_C ApplicationRef kSharedApplication;
diff --git a/Public/Developer/SystemLib/Headers/Wm.h b/Public/Developer/SystemLib/Headers/Wm.h
index f6484c29..609e89ac 100644
--- a/Public/Developer/SystemLib/Headers/Wm.h
+++ b/Public/Developer/SystemLib/Headers/Wm.h
@@ -165,12 +165,3 @@ CA_EXTERN_C VoidType WmReleaseMenu(WindowPort* port);
/// @param where to move.
/// @return error code.
CA_EXTERN_C Int32Type WmMoveWindow(WindowPort* wndPort, WmPoint where);
-
-/// @brief Get the NewOS about window.
-/// @return The window port of it.
-/// @note The reason that this is not a window is for it to run without blocking the UI.
-CA_EXTERN_C WindowPort* WmGetOSDlg(void);
-
-/// @brief Draws a blur effect on the window.
-/// @param wndPort the window port.
-CA_EXTERN_C VoidType WmBlur(WindowPort* wndPort);
diff --git a/Public/Developer/SystemLib/Sources/Wm.c b/Public/Developer/SystemLib/Sources/Wm.c
index 79eda22a..a1f4d051 100644
--- a/Public/Developer/SystemLib/Sources/Wm.c
+++ b/Public/Developer/SystemLib/Sources/Wm.c
@@ -76,23 +76,6 @@ CA_EXTERN_C Int32Type WmMoveWindow(WindowPort* wndPort, WmPoint where) {
return 0;
}
-/// @brief Draws a blur effect on the window.
-/// @param wndPort the window port.
-CA_EXTERN_C VoidType WmBlur(WindowPort* wndPort) {
- if (wndPort != NullPtr) {
- WmGFXRef refGfx = wndPort->windowGfx;
-
- UInt32Type lookupTbl[4] = {0.21336, 0.41336, 0.61336, 0.81336};
-
- for (SizeType width = 0; width < refGfx->DataFrameWidth; ++width) {
- for (SizeType height = 0; height < refGfx->DataFrameHeight; ++height) {
- refGfx->DataFrame[width * height] =
- refGfx->DataFrame[width * height] * lookupTbl[MathRand() % 4];
- }
- }
- }
-}
-
/// @brief Causes the window to invalidate and redraw.
/// @param wndPort The Window port.
/// @return nothing.
@@ -100,4 +83,4 @@ CA_EXTERN_C VoidType WmInvalidateGfx(WindowPort* wndPort) {
if (wndPort) {
wndPort->windowInvalidate = Yes;
}
-} \ No newline at end of file
+}