mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-03 18:29:09 +00:00
added requestRedraw to node window (#3940)
This commit is contained in:
parent
aeace4c4ed
commit
80bcdee646
2 changed files with 9 additions and 0 deletions
|
@ -71,6 +71,9 @@ export interface Window {
|
|||
|
||||
/** Hides the window, so that it is not visible anymore. */
|
||||
hide(): void;
|
||||
|
||||
/** Issues a request to the windowing system to re-render the contents of the window. */
|
||||
requestRedraw(): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -117,4 +117,10 @@ impl JsWindow {
|
|||
height: size.height.floor() as u32,
|
||||
});
|
||||
}
|
||||
|
||||
/// Issues a request to the windowing system to re-render the contents of the window.
|
||||
#[napi(js_name = "requestRedraw")]
|
||||
pub fn request_redraw(&self) {
|
||||
self.inner.request_redraw();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue