mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 07:08:48 +00:00
Merge remote-tracking branch 'offical/master'
This commit is contained in:
Vendored
+3
-3
@@ -622,7 +622,7 @@ push_command :: proc(ctx: ^Context, $Type: typeid, extra_size := 0) -> ^Type {
|
||||
return cmd
|
||||
}
|
||||
|
||||
next_command :: proc(ctx: ^Context, pcmd: ^^Command) -> bool {
|
||||
next_command :: proc "contextless" (ctx: ^Context, pcmd: ^^Command) -> bool {
|
||||
cmd := pcmd^
|
||||
defer pcmd^ = cmd
|
||||
if cmd != nil {
|
||||
@@ -630,7 +630,7 @@ next_command :: proc(ctx: ^Context, pcmd: ^^Command) -> bool {
|
||||
} else {
|
||||
cmd = (^Command)(&ctx.command_list.items[0])
|
||||
}
|
||||
invalid_command :: #force_inline proc(ctx: ^Context) -> ^Command {
|
||||
invalid_command :: #force_inline proc "contextless" (ctx: ^Context) -> ^Command {
|
||||
return (^Command)(&ctx.command_list.items[ctx.command_list.idx])
|
||||
}
|
||||
for cmd != invalid_command(ctx) {
|
||||
@@ -643,7 +643,7 @@ next_command :: proc(ctx: ^Context, pcmd: ^^Command) -> bool {
|
||||
return false
|
||||
}
|
||||
|
||||
next_command_iterator :: proc(ctx: ^Context, pcm: ^^Command) -> (Command_Variant, bool) {
|
||||
next_command_iterator :: proc "contextless" (ctx: ^Context, pcm: ^^Command) -> (Command_Variant, bool) {
|
||||
if next_command(ctx, pcm) {
|
||||
return pcm^.variant, true
|
||||
}
|
||||
|
||||
Vendored
+2
-2
@@ -118,8 +118,8 @@ when ODIN_OS == .Windows {
|
||||
} else when ODIN_OS == .Darwin {
|
||||
foreign import lib {
|
||||
"macos" +
|
||||
"-arm64" when ODIN_ARCH == .arm64 else "" +
|
||||
"/libraylib" + ".500.dylib" when RAYLIB_SHARED else ".a",
|
||||
("-arm64" when ODIN_ARCH == .arm64 else "") +
|
||||
"/libraylib" + (".500.dylib" when RAYLIB_SHARED else ".a"),
|
||||
"system:Cocoa.framework",
|
||||
"system:OpenGL.framework",
|
||||
"system:IOKit.framework",
|
||||
|
||||
Vendored
+1
-1
@@ -76,7 +76,7 @@ foreign lib {
|
||||
GetRenderer :: proc(window: ^Window) -> ^Renderer ---
|
||||
GetRendererInfo :: proc(renderer: ^Renderer, info: ^RendererInfo) -> c.int ---
|
||||
GetRendererOutputSize :: proc(renderer: ^Renderer, w, h: ^c.int) -> c.int ---
|
||||
CreateTexture :: proc(renderer: ^Renderer, format: u32, access: TextureAccess, w, h: c.int) -> ^Texture ---
|
||||
CreateTexture :: proc(renderer: ^Renderer, format: PixelFormatEnum, access: TextureAccess, w, h: c.int) -> ^Texture ---
|
||||
CreateTextureFromSurface :: proc(renderer: ^Renderer, surface: ^Surface) -> ^Texture ---
|
||||
QueryTexture :: proc(texture: ^Texture, format: ^u32, access, w, h: ^c.int) -> c.int ---
|
||||
SetTextureColorMod :: proc(texture: ^Texture, r, g, b: u8) -> c.int ---
|
||||
|
||||
Vendored
+5
@@ -17,6 +17,11 @@ AllTemporary :: 0
|
||||
CurrentTime :: 0
|
||||
NoSymbol :: 0
|
||||
|
||||
PropModeReplace :: 0
|
||||
PropModePrepend :: 1
|
||||
PropModeAppend :: 2
|
||||
|
||||
XA_ATOM :: Atom(4)
|
||||
XA_WM_CLASS :: Atom(67)
|
||||
XA_WM_CLIENT_MACHINE :: Atom(36)
|
||||
XA_WM_COMMAND :: Atom(34)
|
||||
|
||||
Vendored
+24
-6
@@ -6,6 +6,16 @@ foreign xlib {
|
||||
@(link_name="_Xdebug") _Xdebug: i32
|
||||
}
|
||||
|
||||
foreign import xcursor "system:Xcursor"
|
||||
@(default_calling_convention="c", link_prefix="X")
|
||||
foreign xcursor {
|
||||
cursorGetTheme :: proc(display: ^Display) -> cstring ---
|
||||
cursorGetDefaultSize :: proc(display: ^Display) -> i32 ---
|
||||
cursorLibraryLoadImage :: proc(name: cstring, theme: cstring, size: i32) -> rawptr ---
|
||||
cursorImageLoadCursor :: proc(display: ^Display, img: rawptr) -> Cursor ---
|
||||
cursorImageDestroy :: proc(img: rawptr) ---
|
||||
}
|
||||
|
||||
/* ---- X11/Xlib.h ---------------------------------------------------------*/
|
||||
|
||||
@(default_calling_convention="c", link_prefix="X")
|
||||
@@ -20,11 +30,9 @@ foreign xlib {
|
||||
NoOp :: proc(display: ^Display) ---
|
||||
// Display macros (connection)
|
||||
ConnectionNumber :: proc(display: ^Display) -> i32 ---
|
||||
ExtendedMaxRequestSize ::
|
||||
proc(display: ^Display) -> int ---
|
||||
ExtendedMaxRequestSize :: proc(display: ^Display) -> int ---
|
||||
MaxRequestSize :: proc(display: ^Display) -> int ---
|
||||
LastKnownRequestProcessed ::
|
||||
proc(display: ^Display) -> uint ---
|
||||
LastKnownRequestProcessed :: proc(display: ^Display) -> uint ---
|
||||
NextRequest :: proc(display: ^Display) -> uint ---
|
||||
ProtocolVersion :: proc(display: ^Display) -> i32 ---
|
||||
ProtocolRevision :: proc(display: ^Display) -> i32 ---
|
||||
@@ -46,8 +54,7 @@ foreign xlib {
|
||||
DefaultRootWindow :: proc(display: ^Display) -> Window ---
|
||||
DefaultScreen :: proc(display: ^Display) -> i32 ---
|
||||
DefaultVisual :: proc(display: ^Display, screen_no: i32) -> ^Visual ---
|
||||
DefaultScreenOfDisplay ::
|
||||
proc(display: ^Display) -> ^Screen ---
|
||||
DefaultScreenOfDisplay :: proc(display: ^Display) -> ^Screen ---
|
||||
// Display macros (other)
|
||||
RootWindow :: proc(display: ^Display, screen_no: i32) -> Window ---
|
||||
ScreenCount :: proc(display: ^Display) -> i32 ---
|
||||
@@ -1619,6 +1626,17 @@ foreign xlib {
|
||||
) -> b32 ---
|
||||
DestroyImage :: proc(image: ^XImage) ---
|
||||
ResourceManagerString :: proc(display: ^Display) -> cstring ---
|
||||
utf8SetWMProperties :: proc(
|
||||
display: ^Display,
|
||||
window: Window,
|
||||
window_name: cstring,
|
||||
icon_name: cstring,
|
||||
argv: ^cstring,
|
||||
argc: i32,
|
||||
normal_hints: ^XSizeHints,
|
||||
wm_hints: ^XWMHints,
|
||||
class_hints: ^XClassHint,
|
||||
) ---
|
||||
}
|
||||
|
||||
@(default_calling_convention="c")
|
||||
|
||||
Reference in New Issue
Block a user