1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-02 06:40:06 -04:00

Use new type Pos2 for positions (points) instead of Vec2

This commit is contained in:
Emil Ernerfeldt
2020-04-19 01:05:49 +02:00
parent 6eb1053c35
commit 2170081221
11 changed files with 157 additions and 81 deletions

View File

@@ -33,7 +33,7 @@ impl Memory {
self.windows.insert(id, state);
}
pub fn layer_at(&self, pos: Vec2) -> Layer {
pub fn layer_at(&self, pos: Pos2) -> Layer {
for window_id in self.window_order.iter().rev() {
if let Some(state) = self.windows.get(window_id) {
if state.rect.contains(pos) {