Skip to content

Commit

Permalink
Modified request_redraw to use correct OS facilities on Mac OS
Browse files Browse the repository at this point in the history
  • Loading branch information
john01dav committed Feb 8, 2022
1 parent 0e52672 commit 532402a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/platform_impl/macos/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,12 @@ impl UnownedWindow {
}

pub fn request_redraw(&self) {
AppState::queue_redraw(RootWindowId(self.id()));
use objc::{msg_send, runtime::{Object, YES}};
println!("Modified redraw request");
let view = *self.ns_view as *mut _;
unsafe{
let _: () = objc::msg_send![view, setNeedsDisplay:YES];
}
}

pub fn outer_position(&self) -> Result<PhysicalPosition<i32>, NotSupportedError> {
Expand Down

0 comments on commit 532402a

Please sign in to comment.