Adwaita: control surface for resize tiled windows

- window resizing control area is implemented as where the shadows are drawn
    - create a 'fake' shadow for the tiled case to allow easier resizing of
      the tiled window ratio even if it's offset to the side of the border

Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3670
This commit is contained in:
Jakub Steiner 2021-02-16 14:23:12 +01:00
parent 03b97b0a8b
commit 56f6ac5fcc
5 changed files with 13 additions and 10 deletions

View File

@ -4587,9 +4587,12 @@ decoration {
.tiled-bottom &,
.tiled-left & {
border-radius: 0;
box-shadow: 0 0 0 1px $_wm_border_backdrop;
box-shadow: 0 0 0 1px $_wm_border_backdrop,
0 0 0 20px transparent; //transparent control workaround -- #3670
&:backdrop { box-shadow: 0 0 0 1px $_wm_border_backdrop; }
&:backdrop { box-shadow: 0 0 0 1px $_wm_border_backdrop,
0 0 0 20px transparent; // #3670
}
}
.popup & { box-shadow: none; }

View File

@ -1840,9 +1840,9 @@ decoration:backdrop { box-shadow: 0 3px 9px 1px transparent, 0 2px 6px 2px rgba(
.maximized decoration, .fullscreen decoration { border-radius: 0; box-shadow: none; }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(27, 27, 27, 0.9); }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(27, 27, 27, 0.9), 0 0 0 20px transparent; }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(27, 27, 27, 0.9); }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(27, 27, 27, 0.9), 0 0 0 20px transparent; }
.popup decoration { box-shadow: none; }

View File

@ -1856,9 +1856,9 @@ decoration:backdrop { box-shadow: 0 3px 9px 1px transparent, 0 2px 6px 2px rgba(
.maximized decoration, .fullscreen decoration { border-radius: 0; box-shadow: none; }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18); }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18), 0 0 0 20px transparent; }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18); }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18), 0 0 0 20px transparent; }
.popup decoration { box-shadow: none; }

View File

@ -1920,9 +1920,9 @@ decoration:backdrop { box-shadow: 0 3px 9px 1px transparent, 0 2px 6px 2px rgba(
.maximized decoration, .fullscreen decoration { border-radius: 0; box-shadow: none; }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(104, 104, 104, 0.9); }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(104, 104, 104, 0.9), 0 0 0 20px transparent; }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(104, 104, 104, 0.9); }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(104, 104, 104, 0.9), 0 0 0 20px transparent; }
.popup decoration { box-shadow: none; }

View File

@ -1936,9 +1936,9 @@ decoration:backdrop { box-shadow: 0 3px 9px 1px transparent, 0 2px 6px 2px rgba(
.maximized decoration, .fullscreen decoration { border-radius: 0; box-shadow: none; }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18); }
.tiled decoration, .tiled-top decoration, .tiled-right decoration, .tiled-bottom decoration, .tiled-left decoration { border-radius: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18), 0 0 0 20px transparent; }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18); }
.tiled decoration:backdrop, .tiled-top decoration:backdrop, .tiled-right decoration:backdrop, .tiled-bottom decoration:backdrop, .tiled-left decoration:backdrop { box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18), 0 0 0 20px transparent; }
.popup decoration { box-shadow: none; }