This commit is contained in:
mr. m
2025-09-13 21:20:10 +02:00
9 changed files with 39 additions and 70 deletions

View File

@@ -57,8 +57,6 @@ zen-tabs-unloader-enabled =
zen-look-and-feel-compact-toolbar-themed =
.label = Use themed background for compact toolbar
zen-look-and-feel-compact-sidebar-themed =
.label = Use themed background for compact sidebar
zen-workspace-continue-where-left-off =
.label = Continue where you left off

View File

@@ -20,9 +20,6 @@
- name: zen.view.compact.color-toolbar
value: true
- name: zen.view.compact.color-sidebar
value: true
- name: zen.view.compact.animate-sidebar
value: true

View File

@@ -1135,11 +1135,6 @@ Preferences.addAll([
type: 'string',
default: 'float',
},
{
id: 'zen.view.compact.color-sidebar',
type: 'bool',
default: true,
},
{
id: 'zen.workspaces.separate-essentials',
type: 'bool',

View File

@@ -100,9 +100,6 @@
<checkbox id="zenLooksAndFeelEnableThemedToolbarCompactMode"
data-l10n-id="zen-look-and-feel-compact-toolbar-themed"
preference="zen.view.compact.color-toolbar"/>
<checkbox id="zenLooksAndFeelEnableThemedSidebarCompactMode"
data-l10n-id="zen-look-and-feel-compact-sidebar-themed"
preference="zen.view.compact.color-sidebar"/>
</vbox>
</groupbox>

View File

@@ -1,5 +1,5 @@
diff --git a/browser/themes/linux/browser.css b/browser/themes/linux/browser.css
index 9723a8199cc5b8d25bb92c46992792b8c94a3565..3496c3ae4bacf39b788f1b0f740e89cdd9d7de5b 100644
index 9723a8199cc5b8d25bb92c46992792b8c94a3565..302f5b675abd1970e64f56a5a4592bb174f9a72a 100644
--- a/browser/themes/linux/browser.css
+++ b/browser/themes/linux/browser.css
@@ -43,7 +43,8 @@
@@ -12,7 +12,7 @@ index 9723a8199cc5b8d25bb92c46992792b8c94a3565..3496c3ae4bacf39b788f1b0f740e89cd
dialog::backdrop {
border-top-left-radius: env(-moz-gtk-csd-titlebar-radius);
border-top-right-radius: env(-moz-gtk-csd-titlebar-radius);
@@ -51,13 +52,10 @@
@@ -51,13 +52,11 @@
/* stylelint-disable-next-line media-query-no-invalid */
@media -moz-pref("widget.gtk.rounded-bottom-corners.enabled") {
@@ -24,6 +24,7 @@ index 9723a8199cc5b8d25bb92c46992792b8c94a3565..3496c3ae4bacf39b788f1b0f740e89cd
body,
- dialog::backdrop {
+ dialog::backdrop,
+ #zen-main-app-wrapper,
+ #zen-browser-background {
/* Use an uniform clip to allow WebRender to optimize it better */
border-radius: env(-moz-gtk-csd-titlebar-radius);

View File

@@ -47,7 +47,6 @@
overflow: clip;
isolation: isolate;
background: var(--zen-themed-toolbar-bg-transparent);
&::after,
&::before {
@@ -71,12 +70,6 @@
}
}
@media (-moz-pref('zen.view.grey-out-inactive-windows')) {
&:-moz-window-inactive {
background: InactiveCaption;
}
}
&::before {
background: var(--zen-main-browser-background-old);
opacity: calc(1 - var(--zen-background-opacity));
@@ -140,10 +133,16 @@
}
#zen-main-app-wrapper {
background: transparent;
background: var(--zen-themed-toolbar-bg-transparent);
/* See bug #8814, don't an overflow here as it causes issues
* with firefox's rendering of the tab bar */
@media (-moz-pref('zen.view.grey-out-inactive-windows')) {
&:-moz-window-inactive {
background: InactiveCaption;
}
}
& > * {
z-index: 1;
}

View File

@@ -206,7 +206,7 @@
--tab-close-button-padding: 5px !important;
--input-border-color: var(--zen-input-border-color) !important;
--zen-themed-toolbar-bg-transparent: transparent;
--zen-themed-toolbar-bg-transparent: light-dark(var(--zen-branding-bg), #171717);
--zen-workspace-indicator-height: 46px;
@@ -265,9 +265,14 @@
#main-window:not([chromehidden~='toolbar']) {
min-height: 495px !important;
background: transparent;
@media (-moz-windows-mica) and (not (-moz-pref('widget.windows.mica.toplevel-backdrop', 1))) and (not (-moz-pref('widget.windows.mica.toplevel-backdrop', 2))) {
--zen-themed-toolbar-bg-transparent: rgba(255, 255, 255, 0.2);
@media (-moz-windows-mica) or (-moz-platform: macos) or ((-moz-platform: linux) and
-moz-pref('zen.widget.linux.transparency')) {
background: transparent;
--zen-themed-toolbar-bg-transparent: transparent;
@media (-moz-windows-mica) and (not (-moz-pref('widget.windows.mica.toplevel-backdrop', 1))) and (not (-moz-pref('widget.windows.mica.toplevel-backdrop', 2))) {
--zen-themed-toolbar-bg-transparent: rgba(255, 255, 255, 0.2);
}
}
&,

View File

@@ -154,11 +154,15 @@
@media -moz-pref('zen.theme.acrylic-elements') {
backdrop-filter: blur(42px) saturate(110%) brightness(0.25) contrast(100%) !important;
}
&::before,
&::after {
outline: 1px solid rgba(255, 255, 255, .15);
outline-offset: -1px;
background-attachment: fixed !important;
background-size: 2000px !important;
}
&,
&::before,
&::after {

View File

@@ -596,66 +596,39 @@ var gZenWorkspaces = new (class extends nsZenMultiWindowFeature {
const scrollCooldown = 200; // Milliseconds to wait before allowing another scroll
const scrollThreshold = 2; // Minimum scroll delta to trigger workspace change
const scrollDeltaMode0Cooldown = 200; // Cooldown for consecutive DOM_DELTA_PIXEL events
toolbox.addEventListener(
'wheel',
async (event) => {
if (this.privateWindowOrDisabled) return;
// Allow DOM_DELTA_LINE (1) and DOM_DELTA_PIXEL (0) events
if (event.deltaMode > 1) return;
// Only process non-gesture scrolls
if (event.deltaMode !== 1) return;
// Add cooling to consecutive DOM_DELTA_PIXEL events, which are usually from touchpads
if (event.deltaMode === 0) {
const now = Date.now();
const timeSinceLastDeltaMode0 = now - (this._lastDeltaMode0Time || 0);
this._lastDeltaMode0Time = now;
const isVerticalScroll = event.deltaY && !event.deltaX;
//if the scroll is vertical this checks that a modifier key is used before proceeding
if (isVerticalScroll) {
const activationKeyMap = {
ctrl: event.ctrlKey,
alt: event.altKey,
shift: event.shiftKey,
meta: event.metaKey,
};
if (
Math.abs(event.deltaY || 0) === 0 &&
timeSinceLastDeltaMode0 < scrollDeltaMode0Cooldown
this.activationMethod in activationKeyMap &&
!activationKeyMap[this.activationMethod]
) {
return;
}
}
const absX = Math.abs(event.deltaX || 0);
const absY = Math.abs(event.deltaY || 0);
const isVerticalScroll = absY > absX * 2;
const isHorizontalScroll = absX > absY * 2;
const activationKeyMap = {
ctrl: event.ctrlKey,
alt: event.altKey,
shift: event.shiftKey,
meta: event.metaKey,
};
const modifierActive =
this.activationMethod in activationKeyMap && activationKeyMap[this.activationMethod];
let delta;
let shouldProceed = false;
if (isVerticalScroll && modifierActive) {
// scroll is vertical + modifier key
delta = event.deltaY;
shouldProceed = true;
} else if (isHorizontalScroll) {
// clear horizontal scrolling
delta = event.deltaX;
shouldProceed = true;
} else {
// diagonal scrolling or unclear direction, ignore
return;
}
if (!shouldProceed) return;
const currentTime = Date.now();
if (currentTime - this._lastScrollTime < scrollCooldown) return;
//this decides which delta to use
const delta = isVerticalScroll ? event.deltaY : event.deltaX;
if (Math.abs(delta) < scrollThreshold) return;
// Determine scroll direction