Created
May 22, 2025 17:50
-
-
Save PhrantiK/f62f5d3c52167d3bf9fd402a52a235af to your computer and use it in GitHub Desktop.
level.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/src/misc/extern.h b/src/misc/extern.h | |
| index f1a5cfa..eb96253 100644 | |
| --- a/src/misc/extern.h | |
| +++ b/src/misc/extern.h | |
| @@ -29,6 +29,7 @@ extern CGError SLSClearWindowTags(int cid, uint32_t wid, uint64_t* tags, int tag | |
| extern CGError SLSSetWindowShape(int cid, uint32_t wid, float x_offset, float y_offset, CFTypeRef shape); | |
| extern CGError SLSSetWindowResolution(int cid, uint32_t wid, double res); | |
| extern CGError SLSSetWindowOpacity(int cid, uint32_t wid, bool isOpaque); | |
| +extern CGError SLSSetWindowLevel(int cid, uint32_t wid, int level); | |
| extern CGError SLSSetWindowAlpha(int cid, uint32_t wid, float alpha); | |
| extern CGError SLSSetWindowBackgroundBlurRadius(int cid, uint32_t wid, uint32_t radius); | |
| extern CGError SLSSetWindowShadowParameters(int cid, uint32_t wid, float std, float density, int x_offset, int y_offset); | |
| diff --git a/src/misc/window.h b/src/misc/window.h | |
| index 959db0b..ddfd507 100644 | |
| --- a/src/misc/window.h | |
| +++ b/src/misc/window.h | |
| @@ -171,7 +171,7 @@ static inline int32_t window_sub_level(uint32_t wid) { | |
| msg.info.header.msgh_local_port, | |
| MACH_MSG_TIMEOUT_NONE, | |
| MACH_PORT_NULL ); | |
| - | |
| + | |
| if (error != KERN_SUCCESS) { | |
| printf("SubLevel: Error receiving message.\n"); | |
| mig_dealloc_special_reply_port(msg.info.header.msgh_local_port); | |
| @@ -261,6 +261,7 @@ static inline uint32_t window_create(int cid, CGRect frame, bool hidpi, bool unm | |
| SLSSetWindowTags(cid, wid, &set_tags, 64); | |
| SLSClearWindowTags(cid, wid, &clear_tags, 64); | |
| SLSSetWindowOpacity(cid, wid, 0); | |
| + SLSSetWindowLevel(cid, wid, kCGFloatingWindowLevel); | |
| CFIndex shadow_density = 0; | |
| CFNumberRef shadow_density_cf = CFNumberCreate(kCFAllocatorDefault, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment