diff options
| author | Ivan Molodetskikh <yalterz@gmail.com> | 2024-10-19 12:26:02 +0300 |
|---|---|---|
| committer | Ivan Molodetskikh <yalterz@gmail.com> | 2024-10-19 12:33:44 +0300 |
| commit | 10f04fd19de3bc2951d42411c237c8b963e6c816 (patch) | |
| tree | c68f4ac897baf73b77459ac88dbad92c16c9a7c4 | |
| parent | 79fd309d6cf84163ff1c5c44f222e6a58dfa2872 (diff) | |
| download | niri-10f04fd19de3bc2951d42411c237c8b963e6c816.tar.gz niri-10f04fd19de3bc2951d42411c237c8b963e6c816.tar.bz2 niri-10f04fd19de3bc2951d42411c237c8b963e6c816.zip | |
layout: Update tile config in Column::add_tile_at()
| -rw-r--r-- | src/layout/workspace.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/layout/workspace.rs b/src/layout/workspace.rs index f6c3f7df..2fd70978 100644 --- a/src/layout/workspace.rs +++ b/src/layout/workspace.rs @@ -3085,7 +3085,9 @@ impl<W: LayoutElement> Column<W> { self.active_tile_idx = idx; } - fn add_tile_at(&mut self, idx: usize, tile: Tile<W>, animate: bool) { + fn add_tile_at(&mut self, idx: usize, mut tile: Tile<W>, animate: bool) { + tile.update_config(self.scale, self.options.clone()); + // Inserting a tile pushes down all tiles below it, but also in always-centering mode it // will affect the X position of all tiles in the column. let mut prev_offsets = Vec::with_capacity(self.tiles.len() + 1); |
