Skip to content

Commit e08815c

Browse files
committed
Regenerate bindings
1 parent cd18546 commit e08815c

File tree

8 files changed

+71
-40
lines changed

8 files changed

+71
-40
lines changed

gen/gen_audio.jl

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
4-
const GRAPHICS_DIR = joinpath(SFML_INCLUDE, "SFML", "Audio")
5-
const GRAPHICS_HEADERS = [joinpath(GRAPHICS_DIR, header) for header in readdir(GRAPHICS_DIR) if endswith(header, ".h")]
6-
const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "Audio.h")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
6+
const AUDIO_DIR = joinpath(SFML_INCLUDE, "SFML", "Audio")
7+
const AUDIO_HEADERS = [joinpath(AUDIO_DIR, header) for header in readdir(AUDIO_DIR) if endswith(header, ".h")]
8+
const AUDIO_H = joinpath(SFML_INCLUDE, "SFML", "Audio.h")
79

810
# create a work context
911
ctx = DefaultContext()
1012

1113
# parse headers
12-
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...], includes=[SFML_INCLUDE, CLANG_INCLUDE])
14+
parse_headers!(ctx, [AUDIO_H, AUDIO_HEADERS...],
15+
args=[map(x->"-I"*x, find_std_headers())...],
16+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1317

1418
# settings
1519
ctx.libname = "libcsfml_audio"

gen/gen_config.jl

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,17 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
46
const CONFIG_H = joinpath(SFML_INCLUDE, "SFML", "Config.h")
57

68
# create a work context
79
ctx = DefaultContext()
810

911
# parse headers
10-
parse_headers!(ctx, [CONFIG_H], includes=[SFML_INCLUDE, CLANG_INCLUDE])
12+
parse_headers!(ctx, [CONFIG_H],
13+
args=[map(x->"-I"*x, find_std_headers())...],
14+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1115

1216
# settings
1317
ctx.options["is_struct_mutable"] = false # for nested struct

gen/gen_graphics.jl

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
46
const GRAPHICS_DIR = joinpath(SFML_INCLUDE, "SFML", "Graphics")
57
const GRAPHICS_HEADERS = [joinpath(GRAPHICS_DIR, header) for header in readdir(GRAPHICS_DIR) if endswith(header, ".h")]
68
const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "Graphics.h")
@@ -9,7 +11,9 @@ const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "Graphics.h")
911
ctx = DefaultContext()
1012

1113
# parse headers
12-
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...], includes=[SFML_INCLUDE, CLANG_INCLUDE])
14+
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...],
15+
args=[map(x->"-I"*x, find_std_headers())...],
16+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1317

1418
# settings
1519
ctx.libname = "libcsfml_graphics"

gen/gen_network.jl

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
4-
const GRAPHICS_DIR = joinpath(SFML_INCLUDE, "SFML", "Network")
5-
const GRAPHICS_HEADERS = [joinpath(GRAPHICS_DIR, header) for header in readdir(GRAPHICS_DIR) if endswith(header, ".h")]
6-
const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "Network.h")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
6+
const NETWORK_DIR = joinpath(SFML_INCLUDE, "SFML", "Network")
7+
const NETWORK_HEADERS = [joinpath(NETWORK_DIR, header) for header in readdir(NETWORK_DIR) if endswith(header, ".h")]
8+
const NETWORK_H = joinpath(SFML_INCLUDE, "SFML", "Network.h")
79

810
# create a work context
911
ctx = DefaultContext()
1012

1113
# parse headers
12-
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...], includes=[SFML_INCLUDE, CLANG_INCLUDE])
14+
parse_headers!(ctx, [NETWORK_H, NETWORK_HEADERS...],
15+
args=[map(x->"-I"*x, find_std_headers())...],
16+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1317

1418
# settings
1519
ctx.libname = "libcsfml_network"

gen/gen_system.jl

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
4-
const GRAPHICS_DIR = joinpath(SFML_INCLUDE, "SFML", "System")
5-
const GRAPHICS_HEADERS = [joinpath(GRAPHICS_DIR, header) for header in readdir(GRAPHICS_DIR) if endswith(header, ".h")]
6-
const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "System.h")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
6+
const SYSTEM_DIR = joinpath(SFML_INCLUDE, "SFML", "System")
7+
const SYSTEM_HEADERS = [joinpath(SYSTEM_DIR, header) for header in readdir(SYSTEM_DIR) if endswith(header, ".h")]
8+
const SYSTEM_H = joinpath(SFML_INCLUDE, "SFML", "System.h")
79

810
# create a work context
911
ctx = DefaultContext()
1012

1113
# parse headers
12-
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...], includes=[SFML_INCLUDE, CLANG_INCLUDE])
14+
parse_headers!(ctx, [SYSTEM_H, SYSTEM_HEADERS...],
15+
args=[map(x->"-I"*x, find_std_headers())...],
16+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1317

1418
# settings
1519
ctx.libname = "libcsfml_system"

gen/gen_window.jl

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
using Clang
2+
using CSFML
3+
using CSFML.LibCSFML.CSFML_jll
24

3-
const SFML_INCLUDE = joinpath(@__DIR__, "..", "deps", "usr", "include")
4-
const GRAPHICS_DIR = joinpath(SFML_INCLUDE, "SFML", "Window")
5-
const GRAPHICS_HEADERS = [joinpath(GRAPHICS_DIR, header) for header in readdir(GRAPHICS_DIR) if endswith(header, ".h")]
6-
const GRAPHICS_H = joinpath(SFML_INCLUDE, "SFML", "Window.h")
5+
const SFML_INCLUDE = joinpath(dirname(CSFML_jll.libcsfml_window_path), "..", "include") |> normpath
6+
const WINDOW_DIR = joinpath(SFML_INCLUDE, "SFML", "Window")
7+
const WINDOW_HEADERS = [joinpath(WINDOW_DIR, header) for header in readdir(WINDOW_DIR) if endswith(header, ".h")]
8+
const WINDOW_H = joinpath(SFML_INCLUDE, "SFML", "Window.h")
79

810
# create a work context
911
ctx = DefaultContext()
1012

1113
# parse headers
12-
parse_headers!(ctx, [GRAPHICS_H, GRAPHICS_HEADERS...], includes=[SFML_INCLUDE, CLANG_INCLUDE])
14+
parse_headers!(ctx, [WINDOW_H, WINDOW_HEADERS...],
15+
args=[map(x->"-I"*x, find_std_headers())...],
16+
includes=[SFML_INCLUDE, CLANG_INCLUDE])
1317

1418
# settings
1519
ctx.libname = "libcsfml_window"

src/Window/window_api.jl

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window.h
1+
# Julia wrapper for header: Window.h
22
# Automatically generated using Clang.jl
33

4-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Clipboard.h
4+
# Julia wrapper for header: Clipboard.h
55
# Automatically generated using Clang.jl
66

77

@@ -20,7 +20,7 @@ end
2020
function sfClipboard_setUnicodeString(text)
2121
ccall((:sfClipboard_setUnicodeString, libcsfml_window), Cvoid, (Ptr{sfUint32},), text)
2222
end
23-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Context.h
23+
# Julia wrapper for header: Context.h
2424
# Automatically generated using Clang.jl
2525

2626

@@ -43,7 +43,7 @@ end
4343
function sfContext_getActiveContextId()
4444
ccall((:sfContext_getActiveContextId, libcsfml_window), sfUint64, ())
4545
end
46-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Cursor.h
46+
# Julia wrapper for header: Cursor.h
4747
# Automatically generated using Clang.jl
4848

4949

@@ -58,13 +58,13 @@ end
5858
function sfCursor_destroy(cursor)
5959
ccall((:sfCursor_destroy, libcsfml_window), Cvoid, (Ptr{sfCursor},), cursor)
6060
end
61-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Event.h
61+
# Julia wrapper for header: Event.h
6262
# Automatically generated using Clang.jl
6363

64-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Export.h
64+
# Julia wrapper for header: Export.h
6565
# Automatically generated using Clang.jl
6666

67-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Joystick.h
67+
# Julia wrapper for header: Joystick.h
6868
# Automatically generated using Clang.jl
6969

7070

@@ -95,10 +95,10 @@ end
9595
function sfJoystick_update()
9696
ccall((:sfJoystick_update, libcsfml_window), Cvoid, ())
9797
end
98-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/JoystickIdentification.h
98+
# Julia wrapper for header: JoystickIdentification.h
9999
# Automatically generated using Clang.jl
100100

101-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Keyboard.h
101+
# Julia wrapper for header: Keyboard.h
102102
# Automatically generated using Clang.jl
103103

104104

@@ -109,7 +109,7 @@ end
109109
function sfKeyboard_setVirtualKeyboardVisible(visible)
110110
ccall((:sfKeyboard_setVirtualKeyboardVisible, libcsfml_window), Cvoid, (sfBool,), visible)
111111
end
112-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Mouse.h
112+
# Julia wrapper for header: Mouse.h
113113
# Automatically generated using Clang.jl
114114

115115

@@ -124,7 +124,7 @@ end
124124
function sfMouse_setPosition(position, relativeTo)
125125
ccall((:sfMouse_setPosition, libcsfml_window), Cvoid, (sfVector2i, Ptr{sfWindow}), position, relativeTo)
126126
end
127-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Sensor.h
127+
# Julia wrapper for header: Sensor.h
128128
# Automatically generated using Clang.jl
129129

130130

@@ -139,7 +139,7 @@ end
139139
function sfSensor_getValue(sensor)
140140
ccall((:sfSensor_getValue, libcsfml_window), sfVector3f, (sfSensorType,), sensor)
141141
end
142-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Touch.h
142+
# Julia wrapper for header: Touch.h
143143
# Automatically generated using Clang.jl
144144

145145

@@ -150,10 +150,10 @@ end
150150
function sfTouch_getPosition(finger, relativeTo)
151151
ccall((:sfTouch_getPosition, libcsfml_window), sfVector2i, (UInt32, Ptr{sfWindow}), finger, relativeTo)
152152
end
153-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Types.h
153+
# Julia wrapper for header: Types.h
154154
# Automatically generated using Clang.jl
155155

156-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/VideoMode.h
156+
# Julia wrapper for header: VideoMode.h
157157
# Automatically generated using Clang.jl
158158

159159

@@ -168,7 +168,7 @@ end
168168
function sfVideoMode_isValid(mode)
169169
ccall((:sfVideoMode_isValid, libcsfml_window), sfBool, (sfVideoMode,), mode)
170170
end
171-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/Window.h
171+
# Julia wrapper for header: Window.h
172172
# Automatically generated using Clang.jl
173173

174174

@@ -287,6 +287,6 @@ end
287287
function sfWindow_getSystemHandle(window)
288288
ccall((:sfWindow_getSystemHandle, libcsfml_window), sfWindowHandle, (Ptr{sfWindow},), window)
289289
end
290-
# Julia wrapper for header: /Users/gnimuc/.julia/dev/LibCSFML/gen/../deps/usr/include/SFML/Window/WindowHandle.h
290+
# Julia wrapper for header: WindowHandle.h
291291
# Automatically generated using Clang.jl
292292

src/Window/window_common.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,13 @@ struct sfMouseButtonEvent
193193
y::Cint
194194
end
195195

196+
struct sfMouseWheelEvent
197+
type::sfEventType
198+
delta::Cint
199+
x::Cint
200+
y::Cint
201+
end
202+
196203
@cenum sfMouseWheel::UInt32 begin
197204
sfMouseVerticalWheel = 0
198205
sfMouseHorizontalWheel = 1

0 commit comments

Comments
 (0)