generated from tipragot/rust
Add a responsive scaling for ui #73
|
@ -21,6 +21,7 @@ pub enum CurrentScene {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Calculates the ui_scale.0 depending on the size of the main node
|
/// Calculates the ui_scale.0 depending on the size of the main node
|
||||||
|
/// in order to make the screen responsive
|
||||||
pub fn change_scaling(mut ui_scale: ResMut<UiScale>, window: Query<&Window>) {
|
pub fn change_scaling(mut ui_scale: ResMut<UiScale>, window: Query<&Window>) {
|
||||||
let window = window.single();
|
let window = window.single();
|
||||||
let (a, b) = (
|
let (a, b) = (
|
||||||
|
|
Loading…
Reference in a new issue