Fixed havhing monochrome titlebar buttons not being disabled

This commit is contained in:
mr. m
2025-02-15 18:48:31 +01:00
committed by mr. m
parent 3da54549ea
commit 6ffe5fd249
2 changed files with 13 additions and 3 deletions

View File

@@ -152,7 +152,7 @@
gap: var(--zen-element-separation);
}
@media not (-moz-platform: macos) {
@media not (-moz-platform: macos) {
.titlebar-buttonbox-container {
height: 100%;
}
@@ -161,6 +161,7 @@
@media (-moz-platform: macos) {
.titlebar-buttonbox-container {
margin-inline-end: 8px;
padding: 3px 0;
& > .titlebar-buttonbox {
margin-inline-start: var(--zen-toolbox-padding);

View File

@@ -294,7 +294,7 @@ var gZenCompactModeManager = {
},
{
element: gZenVerticalTabsManager.actualWindowButtons,
}
},
];
},
@@ -343,7 +343,16 @@ var gZenCompactModeManager = {
const MAC_WINDOW_BUTTONS_X_BORDER = buttonRect.width + buttonRect.x;
const MAC_WINDOW_BUTTONS_Y_BORDER = buttonRect.height + buttonRect.y;
if (event.clientX < MAC_WINDOW_BUTTONS_X_BORDER && event.clientY < MAC_WINDOW_BUTTONS_Y_BORDER) {
return;
// Also check if it has gone from the top or left if we are exiting the titlebar
// button area
if (
!(
target.classList.contains('titlebar-buttonbox-container') &&
(event.clientX < buttonRect.x || event.clientY < buttonRect.y)
)
) {
return;
}
}
}