mirror of
https://github.com/lisk77/comet.git
synced 2025-12-12 09:08:49 +00:00
feat(renderer): added scale_factor to the trait to allow checking for scale factors in the event loop
This commit is contained in:
parent
dd89d71565
commit
87f0233066
3 changed files with 32 additions and 7 deletions
|
|
@ -381,6 +381,9 @@ impl App {
|
|||
WindowEvent::Resized(physical_size) => {
|
||||
renderer.resize(*physical_size);
|
||||
}
|
||||
WindowEvent::ScaleFactorChanged { scale_factor, .. } => {
|
||||
renderer.set_scale_factor(*scale_factor);
|
||||
}
|
||||
WindowEvent::RedrawRequested => {
|
||||
window.request_redraw();
|
||||
match renderer.render() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue