mirror of
https://github.com/rust-windowing/winit.git
synced 2026-09-02 06:40:06 -04:00
Add null terminator to custom events
This commit is contained in:
@@ -271,7 +271,7 @@ lazy_static! {
|
|||||||
// WPARAM and LPARAM are unused.
|
// WPARAM and LPARAM are unused.
|
||||||
static ref WAKEUP_MSG_ID: u32 = {
|
static ref WAKEUP_MSG_ID: u32 = {
|
||||||
unsafe {
|
unsafe {
|
||||||
user32::RegisterWindowMessageA("Winit::WakeupMsg".as_ptr() as *const i8)
|
user32::RegisterWindowMessageA("Winit::WakeupMsg\0".as_ptr() as *const i8)
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
// Message sent when we want to execute a closure in the thread.
|
// Message sent when we want to execute a closure in the thread.
|
||||||
@@ -279,7 +279,7 @@ lazy_static! {
|
|||||||
// and LPARAM is unused.
|
// and LPARAM is unused.
|
||||||
static ref EXEC_MSG_ID: u32 = {
|
static ref EXEC_MSG_ID: u32 = {
|
||||||
unsafe {
|
unsafe {
|
||||||
user32::RegisterWindowMessageA("Winit::ExecMsg".as_ptr() as *const i8)
|
user32::RegisterWindowMessageA("Winit::ExecMsg\0".as_ptr() as *const i8)
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
// Message sent when the parent thread receives a resize event and wants this thread to use any
|
// Message sent when the parent thread receives a resize event and wants this thread to use any
|
||||||
|
|||||||
Reference in New Issue
Block a user