1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-01 14:20:04 -04:00

Simplify and unify queries about available space

This commit is contained in:
Emil Ernerfeldt
2020-05-12 18:21:09 +02:00
parent 6f7bc3cfac
commit 7a1c97ccfe
15 changed files with 91 additions and 108 deletions

View File

@@ -69,8 +69,8 @@ impl ScrollArea {
};
let outer_size = vec2(
outer_ui.available_width(),
outer_ui.available_height().min(self.max_height),
outer_ui.available().width(),
outer_ui.available().height().min(self.max_height),
);
let inner_size = outer_size - vec2(current_scroll_bar_width, 0.0);