Skip to content

Commit

Permalink
Fix Windows build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
helgoboss committed Jul 4, 2023
1 parent 9d76465 commit 02e9e3a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 17 deletions.
12 changes: 6 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ members = [
# Will probably be excluded from the workspace in future
"main/lib/helgoboss-learn"
]
publish = false

[workspace.dependencies]
# Own
Expand Down
10 changes: 0 additions & 10 deletions swell-ui/src/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -545,16 +545,6 @@ impl Window {
text.into_string().map_err(|_| "non UTF-8")
}

pub fn class_name(self, max_size: u32) -> Result<String, &'static str> {
let (text, result) = with_string_buffer(max_size, |buffer, max_size| unsafe {
Swell::get().GetClassName(self.raw, buffer, max_size)
});
if result == 0 {
return Err("handle not found or doesn't support class name");
}
text.into_string().map_err(|_| "non UTF-8")
}

pub fn set_text<'a>(self, text: impl Into<SwellStringArg<'a>>) {
unsafe { Swell::get().SetWindowText(self.raw, text.into().as_ptr()) };
}
Expand Down

0 comments on commit 02e9e3a

Please sign in to comment.