mirror of
https://github.com/italicsjenga/rust_minifb.git
synced 2025-01-26 02:36:32 +11:00
fixed braces formatting + dropped err_code variable
This commit is contained in:
parent
de47861fe3
commit
bd5ac066a2
1 changed files with 1 additions and 4 deletions
|
@ -249,11 +249,8 @@ impl Window {
|
||||||
};
|
};
|
||||||
|
|
||||||
if user32::RegisterClassW(&class) == 0 {
|
if user32::RegisterClassW(&class) == 0 {
|
||||||
let err_code = kernel32::GetLastError() as u32;
|
|
||||||
|
|
||||||
// ignore the "Class already exists" error for multiple windows
|
// ignore the "Class already exists" error for multiple windows
|
||||||
if err_code != 1410
|
if kernel32::GetLastError() as u32 != 1410 {
|
||||||
{
|
|
||||||
println!("Unable to register class, error {}", kernel32::GetLastError() as u32);
|
println!("Unable to register class, error {}", kernel32::GetLastError() as u32);
|
||||||
return None;
|
return None;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue