Compare commits

...

46 Commits

Author SHA1 Message Date
mr. m
1473675094 fix: improve workspace session restoration and scrolling behavior 2025-03-25 19:51:03 +01:00
mr. m
a6e03680eb Merge pull request #6818 from Slowlife01/playback.1
refactor(MediaController): remove redundant code
2025-03-25 16:07:26 +01:00
Slowlife01
c99d3d37db refactor(MediaController): remove redundant code 2025-03-25 20:45:41 +07:00
Slowlife01
b2fa05fa22 fix(MediaController): pass in playbackRate in more place 2025-03-25 20:34:07 +07:00
mr. m
77070be769 Merge pull request #6814 from Slowlife01/playback
fix(MediaController): pass in playbackRate when switching controller
2025-03-25 14:12:33 +01:00
Slowlife01
3467e5070f fix(MediaController): pass in playbackRate when switching 2025-03-25 20:09:25 +07:00
mr. m
5fb8fe86de Merge pull request #6793 from zen-browser/split-views-session-restore
Added support for split views persisting between sessions
2025-03-25 00:06:26 +01:00
mr. m
afea93d327 Merge branch 'dev' into split-views-session-restore 2025-03-25 00:06:11 +01:00
mr. M
53ec2f15b6 Fixed pinning tabs rendering the browser useles (closes https://github.com/zen-browser/desktop/issues/4583) 2025-03-25 00:04:04 +01:00
mr. M
342186584e Added support for split views persisting between sessions 2025-03-24 23:58:06 +01:00
mr. M
bd5d3c00f1 Formatted the project 2025-03-24 22:19:49 +01:00
mr. m
53eeb4e921 Merge pull request #6740 from Jarm7/patch-1
Update update_newtab.py
2025-03-24 22:19:08 +01:00
mr. m
f2909fb3bd Merge pull request #6788 from k00lagin/fix-typo
Fix: small typo
2025-03-24 22:15:08 +01:00
k00lagin
1039f1db38 Update ZenThemeMarketplaceChild.sys.mjs
Fix typo intall -> inStall

Signed-off-by: k00lagin <k00lagin@gmail.com>
2025-03-25 02:06:26 +05:00
mr. M
741ae9eb1e fix(firefox): update candidate version to 136.0.3 and update last commit hash 2025-03-24 22:02:04 +01:00
mr. M
76ff984b9c Merge branch 'dev' of https://github.com/zen-browser/desktop into dev 2025-03-24 18:36:23 +01:00
mr. M
f89478bf67 fix(styles): adjust zen-toast-container positioning for right-side alignment 2025-03-24 11:11:05 +01:00
mr. m
f530c389a4 Merge pull request #6777 from kritishd8/dev
Removed weird movement when hovering media player
2025-03-24 10:19:34 +01:00
Obscure.
a1ab0512b7 Removed weird movement when hovering media player
Signed-off-by: Obscure. <69711181+kritishd8@users.noreply.github.com>
2025-03-24 15:02:34 +05:45
mr. m
3dad9896eb Merge pull request #6775 from Slowlife01/position
MediaController: update position more frequently
2025-03-24 07:39:19 +01:00
mr. m
ff9b0c79c0 Merge pull request #6774 from Slowlife01/pref
fix: media controls config typo
2025-03-24 07:36:27 +01:00
Slowlife01
19ed3fb303 MediaController: update position more frequently 2025-03-24 10:40:48 +07:00
Slowlife
09dd3c94c1 fix: media controls config typo
Signed-off-by: Slowlife <slowlife1165@gmail.com>
2025-03-24 10:21:51 +07:00
mr. M
e79afc87ca refactor(ZenCompactMode): comment out relatedTarget check for hover state experimentation 2025-03-23 23:54:07 +01:00
mr. M
f3ff74b0df Merge branch 'dev' of https://github.com/zen-browser/desktop into dev 2025-03-23 11:31:26 +01:00
mr. M
569ee488f5 fix(build): remove duplicate echo statement for GITHUB_REPOSITORY_OWNER in workflow 2025-03-23 11:31:21 +01:00
mr. m
68ebe2d503 Merge pull request #6745 from zen-browser/revert-5842-glance-buttons-overflow
Revert "Fix: fixed overflowing glance buttons when sidebar is opened"
2025-03-23 10:41:38 +01:00
mr. m
8939e889f0 Revert "Fix: fixed overflowing glance buttons when sidebar is opened" 2025-03-23 10:41:26 +01:00
Jarm7
796a52625e Update update_newtab.py
feat: Enhance error handling and logging in newtab update script

Add directory existence validation for NEW_TAB_DIR and ENGINE_DIR
Implement detailed subprocess output capturing with error logging
Introduce comprehensive exception handling with specific error types

Signed-off-by: Jarm7 <kotek.moorkotek@gmail.com>
2025-03-23 00:22:08 +01:00
mr. m
0fbc5178f6 Merge pull request #6738 from nocanoa/dev
Update README.md to set user expectations
2025-03-22 23:31:50 +01:00
NOCanoa
d1505287b2 Forgot ! xP
Signed-off-by: NOCanoa <158103554+nocanoa@users.noreply.github.com>
2025-03-22 22:30:56 +00:00
NOCanoa
8959adf9e0 Update README.md to set user expectations
Signed-off-by: NOCanoa <158103554+nocanoa@users.noreply.github.com>
2025-03-22 22:30:19 +00:00
mr. m
5961462cd7 Merge pull request #5842 from Raiden0456/glance-buttons-overflow
Fix: fixed overflowing glance buttons when sidebar is opened
2025-03-22 18:40:13 +01:00
Vrezh Fedora
af0eeb710e Merge branch 'dev' into glance-buttons-overflow 2025-03-22 16:24:01 +01:00
mr. m
75a75d78ec Merge pull request #6706 from Slowlife01/string
fix: import string to pip window
2025-03-22 11:00:13 +01:00
mr. m
ddd8eb6da4 Merge pull request #6710 from Slowlife01/overflow
fix(MediaController): recheck overflow on metadata change
2025-03-22 10:59:49 +01:00
Slowlife01
d9d8437b6d fix(MediaController): recheck overflow on metadata change 2025-03-22 09:46:20 +07:00
Slowlife01
c2f2a589ed shorter export 2025-03-22 08:52:39 +07:00
Slowlife01
c3d09c486c fix: import string to pip window 2025-03-22 08:46:40 +07:00
Vrezh Fedora
d808e72d2a Merge branch 'dev' into glance-buttons-overflow 2025-03-14 22:22:20 +09:00
Vrezh Fedora
02a860ba19 Remove inline styles from glance-wrapper element 2025-03-14 22:16:55 +09:00
mr. m
8902f3202e Merge branch 'dev' into glance-buttons-overflow 2025-03-02 15:45:11 +01:00
Vrezh Fedora
c17779b6d4 revert(var): bring back quikcCloseZen 2025-03-01 22:26:46 +01:00
Vrezh Fedora
7f6c5f7211 revert some changes 2025-03-01 22:23:49 +01:00
Vrezh Fedora
45f49738f3 Merge branch 'dev' into glance-buttons-overflow 2025-03-01 20:47:06 +01:00
Vrezh Fedora
cf0662d0a4 feat(glance): glance buttons fix overflow 2025-02-27 12:09:05 +01:00
23 changed files with 309 additions and 96 deletions

View File

@@ -51,7 +51,6 @@ jobs:
echo "update_branch: ${{ inputs.update_branch }}"
echo "GITHUB_REPOSITORY: ${{ github.repository }}"
echo "GITHUB_REPOSITORY_OWNER: ${{ github.repository_owner }}"
echo "GITHUB_REPOSITORY_OWNER: ${{ github.repository_owner }}"
echo "GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}"
buildid:

View File

@@ -6,7 +6,7 @@
[![Crowdin](https://badges.crowdin.net/zen-browser/localized.svg)](https://crowdin.com/project/zen-browser)
[![Zen Release builds](https://github.com/zen-browser/desktop/actions/workflows/build.yml/badge.svg?branch=stable)](https://github.com/zen-browser/desktop/actions/workflows/build.yml)
✨ Experience tranquillity while browsing the web without people tracking you! Zen is a privacy-focused browser that blocks trackers, ads, and other unwanted content while offering the best browsing experience!
✨ Experience tranquillity while browsing the internet with Zen! Our mission is to give you a balance between speed, privacy and productivity!
<div flex="true">
<a href="https://zen-browser.app/download">

View File

@@ -1 +1 @@
6013afe489c3d5e19c5f0d0f6c3f94b91f5bd7d1
e234130176d2813fec2397bbf3a313909565006e

View File

@@ -2,10 +2,11 @@ import os
import subprocess
import logging
# Set up logging
logging.basicConfig(level=logging.INFO)
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s - %(levelname)s - %(message)s'
)
# Constants for paths
NEW_TAB_DIR = "./engine/browser/components/newtab"
ENGINE_DIR = "./engine"
NPM_INSTALL_COMMANDS = ["npm install", "npm install meow@9.0.0"]
@@ -13,27 +14,62 @@ BUNDLE_COMMAND = "npm run bundle --prefix=browser/components/newtab"
def install_dependencies():
"""Install necessary npm packages for the newtab component."""
if not os.path.isdir(NEW_TAB_DIR):
logging.error(f"Directory not found: {NEW_TAB_DIR}")
raise FileNotFoundError(f"New tab directory {NEW_TAB_DIR} does not exist")
for command in NPM_INSTALL_COMMANDS:
logging.info(f"Running command: {command} in {NEW_TAB_DIR}")
subprocess.run(command.split(), cwd=NEW_TAB_DIR, check=True)
try:
logging.info(f"Running command: {command} in {NEW_TAB_DIR}")
subprocess.run(
command.split(),
cwd=NEW_TAB_DIR,
check=True,
capture_output=True,
text=True
)
logging.info(f"Successfully executed: {command}")
except subprocess.CalledProcessError as e:
logging.error(f"Command failed: {command} - {e.stderr}")
raise
def bundle_newtab_components():
"""Bundle the newtab components."""
logging.info(f"Bundling newtab components in {ENGINE_DIR}")
subprocess.run(BUNDLE_COMMAND.split(), cwd=ENGINE_DIR, check=True)
if not os.path.isdir(ENGINE_DIR):
logging.error(f"Directory not found: {ENGINE_DIR}")
raise FileNotFoundError(f"Engine directory {ENGINE_DIR} does not exist")
try:
logging.info(f"Bundling newtab components in {ENGINE_DIR}")
result = subprocess.run(
BUNDLE_COMMAND.split(),
cwd=ENGINE_DIR,
check=True,
capture_output=True,
text=True
)
logging.info(f"Bundle completed successfully: {result.stdout}")
except subprocess.CalledProcessError as e:
logging.error(f"Bundle failed: {e.stderr}")
raise
def update_newtab(init: bool = True):
"""Update the newtab components, optionally initializing dependencies."""
try:
if init:
logging.info("Starting dependency installation")
install_dependencies()
logging.info("Dependencies installed successfully")
logging.info("Starting bundle process")
bundle_newtab_components()
except subprocess.CalledProcessError as e:
logging.error(f"An error occurred: {e}")
logging.info("Newtab update completed successfully")
except (subprocess.CalledProcessError, FileNotFoundError) as e:
logging.error(f"Update process failed: {str(e)}")
raise
except Exception as e:
logging.error(f"Unexpected error: {str(e)}")
raise

View File

@@ -90,7 +90,7 @@ pref('zen.tabs.show-newtab-vertical', true);
pref('zen.view.show-newtab-button-border-top', false);
pref('zen.view.show-newtab-button-top', true);
perf('zen.mediacontrols.enabled', true);
pref('zen.mediacontrols.enabled', true);
#ifdef MOZILLA_OFFICIAL
pref('zen.rice.api.url', 'https://share.zen-browser.app', locked);
@@ -256,7 +256,7 @@ pref('browser.migrate.opera.enabled', true);
// pref('network.trr.mode', 5);
// security: They must enable this themselves, to avoid people downloading malware
pref('xpinstall.signatures.required', false);
pref('xpinstall.signatures.required', true);
// Experimental Zen Features
// Strategy to use for bytecode cache (Thanks https://github.com/gunir)

View File

@@ -58,6 +58,11 @@ tab-group[split-view-group] {
right: 50%;
transform: translateX(50%);
}
& .tab-content {
min-width: 0;
justify-content: unset !important;
}
}
&:has(> tab:is([visuallyselected], [multiselected])) {

View File

@@ -141,7 +141,6 @@
background-color: var(--zen-media-control-bg);
backdrop-filter: saturate(3) contrast(2) blur(10px);
width: 100%;
will-change: transform;
}
.show-on-hover {

View File

@@ -351,14 +351,21 @@ menuitem {
#zen-toast-container {
position: fixed;
top: calc(var(--zen-element-separation) * 2);
right: calc(var(--zen-element-separation) * 2);
z-index: 1000;
gap: 1rem;
display: flex;
align-items: end;
:root:not([zen-right-side='true']) & {
right: calc(var(--zen-element-separation) * 2);
}
:root[zen-right-side='true'] & {
left: calc(var(--zen-element-separation) * 2);
}
& .zen-toast {
padding: 0.9rem 0.8rem;
padding: 0.5rem 0.6rem;
border-radius: 12px;
background: linear-gradient(
170deg,

View File

@@ -130,6 +130,9 @@
overflow: hidden;
display: flex;
gap: 0.5ch;
overflow-x: auto;
scrollbar-width: none;
scroll-behavior: smooth;
}
}

View File

@@ -394,9 +394,10 @@ var gZenCompactModeManager = {
// When moving the cursor between the url bar and bookmarks, or in-between bookmarks in the bookmark bar, the
// mouseLeave event is triggered without a relatedTarget.
if (event.relatedTarget == null) {
return;
}
// TODO: Experiment with this for some time, see if people still have issues with the hover state
//if (event.relatedTarget == null) {
// return;
//}
// If it's a child element but not the target, ignore the event
if (target.contains(event.explicitOriginalTarget) && event.explicitOriginalTarget !== target) {

View File

@@ -192,15 +192,6 @@ class ZenMediaController {
this._currentBrowser = browser;
this.updatePipButton();
const positionState = mediaController.getPositionState();
this.mediaControllersMap.set(mediaController.id, {
controller: mediaController,
browser,
position: positionState.position,
duration: positionState.duration,
lastUpdated: Date.now(),
});
}
setupMediaControlUI(metadata, positionState) {
@@ -244,6 +235,7 @@ class ZenMediaController {
browser,
position: positionState.position,
duration: positionState.duration,
playbackRate: positionState.playbackRate,
lastUpdated: Date.now(),
});
@@ -292,6 +284,7 @@ class ZenMediaController {
...mediaController,
position: event.position,
duration: event.duration,
playbackRate: event.playbackRate,
lastUpdated: Date.now(),
});
@@ -333,6 +326,7 @@ class ZenMediaController {
this.setupMediaControlUI(nextController.controller.getMetadata(), {
position: nextController.position + (nextController.controller.isPlaying ? elapsedTime : 0),
duration: nextController.duration,
playbackRate: nextController.playbackRate,
});
this.showMediaControls();
@@ -396,6 +390,13 @@ class ZenMediaController {
const metadata = event.target.getMetadata();
this.mediaTitle.textContent = metadata.title || '';
this.mediaArtist.textContent = metadata.artist || '';
const mediaInfoElements = [this.mediaTitle, this.mediaArtist];
for (const element of mediaInfoElements) {
element.removeAttribute('overflow');
}
this.addLabelOverflows(mediaInfoElements);
}
_onPictureInPictureModeChange(event) {

View File

@@ -981,7 +981,9 @@ class ZenViewSplitter extends ZenDOMOperatedFeature {
layoutTree: this.calculateLayoutTree(tabs, gridType),
};
this._data.push(splitData);
window.gBrowser.selectedTab = tabs[0];
if (!this._sessionRestoring) {
window.gBrowser.selectedTab = tabs[0];
}
// Add tabs to the split view group
let splitGroup = this._getSplitViewGroup(tabs);
@@ -1722,6 +1724,43 @@ class ZenViewSplitter extends ZenDOMOperatedFeature {
return null;
}
storeDataForSessionStore() {
// We cant store any tab or browser elements in the session store
// so we need to store the tab indexes and group indexes
const data = this._data.map((group) => {
return {
groupId: group.tabs[0].group?.id,
gridType: group.gridType,
};
});
return data;
}
restoreDataFromSessionStore(data) {
if (!data) {
return;
}
this._sessionRestoring = true;
// We can just get the tab group with document.getElementById(group.groupId)
// and add the tabs to it
for (const group of data) {
const groupElement = document.getElementById(group.groupId);
if (groupElement) {
const tabs = groupElement.querySelectorAll('tab');
this.splitTabs([...tabs], group.gridType);
}
}
delete this._sessionRestoring;
}
onAfterWorkspaceSessionRestore() {
if (this.currentView >= 0) {
// Activate all browsers in the split view
this.currentView = -1;
this.onLocationChange(gBrowser.selectedTab.linkedBrowser);
}
}
}
window.gZenViewSplitter = new ZenViewSplitter();

View File

@@ -263,12 +263,13 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
_organizeTabsToWorkspaceSections(workspace, section, pinnedSection, tabs) {
const workspaceTabs = Array.from(tabs).filter((tab) => tab.getAttribute('zen-workspace-id') === workspace.uuid);
let firstNormalTab = null;
for (const tab of workspaceTabs) {
for (let tab of workspaceTabs) {
if (tab.hasAttribute('zen-essential')) {
continue; // Ignore essentials as they need to be in their own section
}
// remove tab from list
tabs.splice(tabs.indexOf(tab), 1);
tab = tab.group ?? tab;
if (tab.pinned) {
pinnedSection.insertBefore(tab, pinnedSection.nextSibling);
} else {
@@ -404,6 +405,7 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
_handleSwipeMayStart(event) {
if (!this.workspaceEnabled) return;
if (event.target.closest('#zen-sidebar-bottom-buttons')) return;
// Only handle horizontal swipes
if (event.direction === event.DIRECTION_LEFT || event.direction === event.DIRECTION_RIGHT) {
@@ -647,6 +649,7 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
if (gZenVerticalTabsManager._canReplaceNewTab && showed) {
BrowserCommands.openTab();
}
gZenViewSplitter.onAfterWorkspaceSessionRestore();
}
handleInitialTab(tab, isEmpty) {
@@ -2291,7 +2294,11 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
if (!this._hasInitializedTabsStrip) {
const children = this.tabboxChildren;
children.pop(); // Remove the last child which is the new tab button
return children;
return [
...document.querySelectorAll('#zen-essentials-container tab'),
...document.querySelectorAll('#vertical-pinned-tabs-container tab'),
...children,
];
}
if (this._allStoredTabs) {
@@ -2323,6 +2330,23 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
return this._allStoredTabs;
}
get allTabGroups() {
if (!this._hasInitializedTabsStrip) {
let children = this.tabboxChildren;
return children.filter((node) => node.tagName == 'tab-group');
}
const pinnedContainers = document.querySelectorAll('#vertical-pinned-tabs-container .zen-workspace-tabs-section');
const normalContainers = document.querySelectorAll('#tabbrowser-arrowscrollbox .zen-workspace-tabs-section');
const containers = [...pinnedContainers, ...normalContainers];
const tabGroups = [];
for (const container of containers) {
for (const tabGroup of container.querySelectorAll('tab-group')) {
tabGroups.push(tabGroup);
}
}
return tabGroups;
}
get allUsedBrowsers() {
if (!this._hasInitializedTabsStrip) {
return gBrowser.browsers;
@@ -2393,6 +2417,17 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
const maxWidth = 100 / numButtons;
parent.style.setProperty('--zen-overflowed-workspace-button-width', `${maxWidth}%`);
this._processingResize = false;
// Scroll to the active workspace button if it's not visible
const activeButton = parent.querySelector('.zen-workspace-button.active');
if (!activeButton) {
return;
}
const parentRect = parent.getBoundingClientRect();
const activeRect = activeButton.getBoundingClientRect();
if (activeRect.left < parentRect.left || activeRect.right > parentRect.right) {
parent.scrollLeft = activeButton.offsetLeft;
}
});
}
})();

View File

@@ -50,7 +50,7 @@ export class ZenThemeMarketplaceChild extends JSWindowActorChild {
initiateThemeMarketplace() {
this.contentWindow.setTimeout(() => {
this.addIntallButtons();
this.addInstallButtons();
this.injectMarkplaceAPI();
}, 0);
}
@@ -111,7 +111,7 @@ export class ZenThemeMarketplaceChild extends JSWindowActorChild {
});
}
async addIntallButtons() {
async addInstallButtons() {
const actionButton = this.actionButton;
const actionButtonUnnstall = this.actionButtonUninstall;
const errorMessage = this.contentWindow.document.getElementById('install-theme-error');

View File

@@ -1,5 +1,5 @@
diff --git a/browser/components/sessionstore/SessionStore.sys.mjs b/browser/components/sessionstore/SessionStore.sys.mjs
index f814772114948f87cbb3c3a7231c95ea1f68d776..ae35daa518ca25f4fc95ef983519c390bf088a68 100644
index f814772114948f87cbb3c3a7231c95ea1f68d776..38913eb9dee97b42697440560f7a1bab1ffe9f15 100644
--- a/browser/components/sessionstore/SessionStore.sys.mjs
+++ b/browser/components/sessionstore/SessionStore.sys.mjs
@@ -3171,7 +3171,7 @@ var SessionStoreInternal = {
@@ -19,7 +19,7 @@ index f814772114948f87cbb3c3a7231c95ea1f68d776..ae35daa518ca25f4fc95ef983519c390
if (inBackground === false) {
aWindow.gBrowser.selectedTab = newTab;
@@ -5355,14 +5356,14 @@ var SessionStoreInternal = {
@@ -5355,14 +5356,15 @@ var SessionStoreInternal = {
}
let tabbrowser = aWindow.gBrowser;
@@ -29,6 +29,7 @@ index f814772114948f87cbb3c3a7231c95ea1f68d776..ae35daa518ca25f4fc95ef983519c390
let winData = this._windows[aWindow.__SSi];
let tabsData = (winData.tabs = []);
+ winData.splitViewData = aWindow.gZenViewSplitter?.storeDataForSessionStore();
// update the internal state data for this window
for (let tab of tabs) {
- if (tab == aWindow.FirefoxViewHandler.tab) {
@@ -36,7 +37,7 @@ index f814772114948f87cbb3c3a7231c95ea1f68d776..ae35daa518ca25f4fc95ef983519c390
continue;
}
let tabData = lazy.TabState.collect(tab, TAB_CUSTOM_VALUES.get(tab));
@@ -5381,7 +5382,7 @@ var SessionStoreInternal = {
@@ -5381,7 +5383,7 @@ var SessionStoreInternal = {
// We don't store the Firefox View tab in Session Store, so if it was the last selected "tab" when
// a window is closed, point to the first item in the tab strip instead (it will never be the Firefox View tab,
// since it's only inserted into the tab strip after it's selected).
@@ -45,7 +46,15 @@ index f814772114948f87cbb3c3a7231c95ea1f68d776..ae35daa518ca25f4fc95ef983519c390
selectedIndex = 1;
winData.title = tabbrowser.tabs[0].label;
}
@@ -6086,8 +6087,23 @@ var SessionStoreInternal = {
@@ -5538,6 +5540,7 @@ var SessionStoreInternal = {
winData.tabs,
winData.groups ?? []
);
+ aWindow.gZenViewSplitter?.restoreDataFromSessionStore(winData.splitViewData);
this._log.debug(
`restoreWindow, createTabsForSessionRestore returned ${tabs.length} tabs`
);
@@ -6086,8 +6089,23 @@ var SessionStoreInternal = {
// Most of tabData has been restored, now continue with restoring
// attributes that may trigger external events.

View File

@@ -0,0 +1,14 @@
diff --git a/browser/components/sessionstore/TabGroupState.sys.mjs b/browser/components/sessionstore/TabGroupState.sys.mjs
index 2406837c67d8ff590aa0db6c75ede81e53097506..b69fb7862cd76c891ef61e29aca8c10bab2f5d7e 100644
--- a/browser/components/sessionstore/TabGroupState.sys.mjs
+++ b/browser/components/sessionstore/TabGroupState.sys.mjs
@@ -66,6 +66,9 @@ class _TabGroupState {
name: tabGroup.label,
color: tabGroup.color,
collapsed: tabGroup.collapsed,
+ pinned: tabGroup.pinned,
+ essential: tabGroup.essential,
+ splitView: tabGroup.hasAttribute("split-view-group"),
};
}

View File

@@ -1,13 +1,8 @@
diff --git a/browser/components/sessionstore/TabState.sys.mjs b/browser/components/sessionstore/TabState.sys.mjs
index 8f7ed557e6aa61e7e16ed4a8d785ad5fe651b3d8..aff63696d198055886960072a6130318e099ae42 100644
index 8f7ed557e6aa61e7e16ed4a8d785ad5fe651b3d8..254849e13f7566029dc780c45e376e0f0d427cb5 100644
--- a/browser/components/sessionstore/TabState.sys.mjs
+++ b/browser/components/sessionstore/TabState.sys.mjs
@@ -80,10 +80,20 @@ class _TabState {
tabData.muteReason = tab.muteReason;
}
- if (tab.group) {
+ if (tab.group && !tab.group.hasAttribute("split-view-group")) {
@@ -84,6 +84,16 @@ class _TabState {
tabData.groupId = tab.group.id;
}

View File

@@ -1,5 +1,5 @@
diff --git a/browser/components/tabbrowser/content/tabbrowser.js b/browser/components/tabbrowser/content/tabbrowser.js
index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63af1fa8a3 100644
index 628aa6596627c85efe361fc1ece8fd58f7ee653e..2a9ac30c7e270586ff4502046e5b1ae7409d0582 100644
--- a/browser/components/tabbrowser/content/tabbrowser.js
+++ b/browser/components/tabbrowser/content/tabbrowser.js
@@ -412,11 +412,50 @@
@@ -246,7 +246,24 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
// Additionally send pinned tab events
if (pinned) {
this._notifyPinnedStatus(t);
@@ -2904,6 +2977,7 @@
@@ -2865,12 +2938,15 @@
* @param {string} [label=]
* @returns {MozTabbrowserTabGroup}
*/
- _createTabGroup(id, color, collapsed, label = "") {
+ _createTabGroup(id, color, collapsed, label = "", pinned = false, essential = false, splitViewGroup = false) {
let group = document.createXULElement("tab-group", { is: "tab-group" });
group.id = id;
group.collapsed = collapsed;
group.color = color;
group.label = label;
+ group.pinned = pinned;
+ group.essential = essential;
+ if (splitViewGroup) group.setAttribute('split-view-group', true);
return group;
}
@@ -2904,6 +2980,7 @@
label = "",
insertBefore = null,
showCreateUI = false,
@@ -254,7 +271,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
} = {}
) {
if (!tabs?.length) {
@@ -2918,7 +2992,12 @@
@@ -2918,7 +2995,12 @@
id = `${Date.now()}-${Math.round(Math.random() * 100)}`;
}
let group = this._createTabGroup(id, color, false, label);
@@ -264,11 +281,11 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
+ }
+ group.essential = tabs.some(tab => tab.hasAttribute("essential"));
+ group.pinned = group.essential || tabs.some(tab => tab.pinned);
+ (group.essential ? document.getElementById("zen-essentials-container") : (group.pinned ? this.verticalPinnedTabsContainer : this.tabContainer)).insertBefore(
+ ((insertBefore?.group ?? insertBefore).parentNode).insertBefore(
group,
insertBefore?.group ?? insertBefore
);
@@ -3126,6 +3205,7 @@
@@ -3126,6 +3208,7 @@
initialBrowsingContextGroupId,
openWindowInfo,
skipLoad,
@@ -276,7 +293,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
}
) {
// If we don't have a preferred remote type, and we have a remote
@@ -3189,6 +3269,7 @@
@@ -3189,6 +3272,7 @@
openWindowInfo,
name,
skipLoad,
@@ -284,7 +301,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
});
}
@@ -3367,6 +3448,27 @@
@@ -3367,6 +3451,27 @@
) {
tabWasReused = true;
tab = this.selectedTab;
@@ -312,7 +329,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (!tabData.pinned) {
this.unpinTab(tab);
} else {
@@ -3380,6 +3482,7 @@
@@ -3380,6 +3485,7 @@
restoreTabsLazily && !select && !tabData.pinned;
let url = "about:blank";
@@ -320,7 +337,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (tabData.entries?.length) {
let activeIndex = (tabData.index || tabData.entries.length) - 1;
// Ensure the index is in bounds.
@@ -3415,7 +3518,27 @@
@@ -3415,7 +3521,27 @@
skipLoad: true,
preferredRemoteType,
});
@@ -349,7 +366,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (select) {
tabToSelect = tab;
}
@@ -3428,8 +3551,8 @@
@@ -3428,8 +3554,8 @@
// inserted in the DOM. If the tab is not yet in the DOM,
// just insert it in the right place from the start.
if (!tab.parentNode) {
@@ -360,7 +377,29 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
tab.toggleAttribute("pinned", true);
this.tabContainer._invalidateCachedTabs();
// Then ensure all the tab open/pinning information is sent.
@@ -3504,6 +3627,9 @@
@@ -3439,7 +3565,8 @@
// needs calling:
shouldUpdateForPinnedTabs = true;
}
- } else if (tabData.groupId) {
+ }
+ if (tabData.groupId) {
let { groupId } = tabData;
const tabGroup = tabGroupWorkingData.get(groupId);
// if a tab refers to a tab group we don't know, skip any group
@@ -3453,7 +3580,10 @@
tabGroup.stateData.id,
tabGroup.stateData.color,
tabGroup.stateData.collapsed,
- tabGroup.stateData.name
+ tabGroup.stateData.name,
+ tabGroup.stateData.pinned,
+ tabGroup.stateData.essential,
+ tabGroup.stateData.splitView,
);
tabsFragment.appendChild(tabGroup.node);
}
@@ -3504,6 +3634,9 @@
this.selectedTab = tabToSelect;
this.removeTab(leftoverTab);
}
@@ -370,7 +409,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (tabs.length > 1 || !tabs[0].selected) {
this._updateTabsAfterInsert();
@@ -3693,7 +3819,7 @@
@@ -3693,7 +3826,7 @@
// Ensure we have an index if one was not provided.
if (typeof index != "number") {
// Move the new tab after another tab if needed, to the end otherwise.
@@ -379,7 +418,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (
!bulkOrderedOpen &&
((openerTab &&
@@ -3736,18 +3862,18 @@
@@ -3736,18 +3869,18 @@
// Ensure index is within bounds.
if (tab.pinned) {
@@ -402,7 +441,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (tabAfter && tabAfter.group == tabGroup) {
// Place at the front of, or between tabs in, the same tab group
this.tabContainer.insertBefore(tab, tabAfter);
@@ -4059,6 +4185,9 @@
@@ -4059,6 +4192,9 @@
return;
}
@@ -412,7 +451,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
this.removeTabs(selectedTabs);
}
@@ -4391,6 +4520,7 @@
@@ -4391,6 +4527,7 @@
skipSessionStore,
} = {}
) {
@@ -420,7 +459,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (UserInteraction.running("browser.tabs.opening", window)) {
UserInteraction.finish("browser.tabs.opening", window);
}
@@ -4407,6 +4537,12 @@
@@ -4407,6 +4544,12 @@
TelemetryStopwatch.start("FX_TAB_CLOSE_TIME_NO_ANIM_MS", aTab);
}
@@ -433,7 +472,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
// Handle requests for synchronously removing an already
// asynchronously closing tab.
if (!animate && aTab.closing) {
@@ -4421,7 +4557,9 @@
@@ -4421,7 +4564,9 @@
// frame created for it (for example, by updating the visually selected
// state).
let tabWidth = window.windowUtils.getBoundsWithoutFlushing(aTab).width;
@@ -444,7 +483,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (
!this._beginRemoveTab(aTab, {
closeWindowFastpath: true,
@@ -4435,7 +4573,6 @@
@@ -4435,7 +4580,6 @@
TelemetryStopwatch.cancel("FX_TAB_CLOSE_TIME_NO_ANIM_MS", aTab);
return;
}
@@ -452,7 +491,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
let lockTabSizing =
!this.tabContainer.verticalMode &&
!aTab.pinned &&
@@ -4574,14 +4711,14 @@
@@ -4574,14 +4718,14 @@
!!this.tabsInCollapsedTabGroups.length;
if (
aTab.visible &&
@@ -469,7 +508,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (closeWindow) {
// We've already called beforeunload on all the relevant tabs if we get here,
@@ -4605,6 +4742,7 @@
@@ -4605,6 +4749,7 @@
newTab = true;
}
@@ -477,7 +516,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
aTab._endRemoveArgs = [closeWindow, newTab];
// swapBrowsersAndCloseOther will take care of closing the window without animation.
@@ -4645,9 +4783,7 @@
@@ -4645,9 +4790,7 @@
aTab._mouseleave();
if (newTab) {
@@ -488,7 +527,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
} else {
TabBarVisibility.update();
}
@@ -4776,6 +4912,8 @@
@@ -4776,6 +4919,8 @@
this.tabs[i]._tPos = i;
}
@@ -497,7 +536,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (!this._windowIsClosing) {
if (wasPinned) {
this.tabContainer._positionPinnedTabs();
@@ -4994,7 +5132,7 @@
@@ -4994,7 +5139,7 @@
!excludeTabs.has(aTab.owner) &&
Services.prefs.getBoolPref("browser.tabs.selectOwnerOnClose")
) {
@@ -506,7 +545,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
}
// Try to find a remaining tab that comes after the given tab
@@ -5016,7 +5154,7 @@
@@ -5016,7 +5161,7 @@
}
if (tab) {
@@ -515,7 +554,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
}
// If no qualifying visible tab was found, see if there is a tab in
@@ -5434,10 +5572,10 @@
@@ -5434,10 +5579,10 @@
SessionStore.deleteCustomTabValue(aTab, "hiddenBy");
}
@@ -528,7 +567,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
aTab.selected ||
aTab.closing ||
// Tabs that are sharing the screen, microphone or camera cannot be hidden.
@@ -5675,7 +5813,7 @@
@@ -5675,7 +5820,7 @@
// Don't allow mixing pinned and unpinned tabs.
if (aTab.pinned) {
@@ -537,7 +576,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
} else {
aIndex = Math.max(aIndex, this.pinnedTabCount);
}
@@ -5685,10 +5823,17 @@
@@ -5685,10 +5830,17 @@
this._handleTabMove(aTab, () => {
let neighbor = this.tabs[aIndex];
@@ -557,7 +596,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
neighbor.after(aTab);
} else {
this.tabContainer.insertBefore(aTab, neighbor);
@@ -5697,7 +5842,7 @@
@@ -5697,7 +5849,7 @@
}
moveTabToGroup(aTab, aGroup) {
@@ -566,7 +605,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
return;
}
if (aTab.group && aTab.group.id === aGroup.id) {
@@ -5721,6 +5866,10 @@
@@ -5721,6 +5873,10 @@
moveActionCallback();
@@ -577,7 +616,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
// Clear tabs cache after moving nodes because the order of tabs may have
// changed.
this.tabContainer._invalidateCachedTabs();
@@ -5771,7 +5920,7 @@
@@ -5771,7 +5927,7 @@
createLazyBrowser,
};
@@ -586,7 +625,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
if (aIndex < numPinned || (aTab.pinned && aIndex == numPinned)) {
params.pinned = true;
}
@@ -6513,7 +6662,7 @@
@@ -6513,7 +6669,7 @@
// preventDefault(). It will still raise the window if appropriate.
break;
}
@@ -595,7 +634,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
window.focus();
aEvent.preventDefault();
break;
@@ -7415,6 +7564,7 @@
@@ -7415,6 +7571,7 @@
aWebProgress.isTopLevel
) {
this.mTab.setAttribute("busy", "true");
@@ -603,7 +642,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
gBrowser._tabAttrModified(this.mTab, ["busy"]);
this.mTab._notselectedsinceload = !this.mTab.selected;
}
@@ -8381,7 +8531,7 @@ var TabContextMenu = {
@@ -8381,7 +8538,7 @@ var TabContextMenu = {
);
contextUnpinSelectedTabs.hidden =
!this.contextTab.pinned || !multiselectionContext;
@@ -612,7 +651,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
// Move Tab items
let contextMoveTabOptions = document.getElementById(
"context_moveTabOptions"
@@ -8414,7 +8564,7 @@ var TabContextMenu = {
@@ -8414,7 +8571,7 @@ var TabContextMenu = {
let contextMoveTabToStart = document.getElementById("context_moveToStart");
let isFirstTab =
tabsToMove[0] == visibleTabs[0] ||
@@ -621,7 +660,7 @@ index 628aa6596627c85efe361fc1ece8fd58f7ee653e..06a4aae50ebe8a42d08d4689d8e80a63
contextMoveTabToStart.disabled = isFirstTab && allSelectedTabsAdjacent;
document.getElementById("context_openTabInWindow").disabled =
@@ -8647,6 +8797,7 @@ var TabContextMenu = {
@@ -8647,6 +8804,7 @@ var TabContextMenu = {
if (this.contextTab.multiselected) {
gBrowser.removeMultiSelectedTabs();
} else {

View File

@@ -1,5 +1,5 @@
diff --git a/browser/components/tabbrowser/content/tabs.js b/browser/components/tabbrowser/content/tabs.js
index fa96568d366fd3608f9bd583fa793150bd815c8b..1c940a3b162919256ca73fa867c5c261a3395e25 100644
index fa96568d366fd3608f9bd583fa793150bd815c8b..13a870629a98304cb18dc09b5ae075d734668f2a 100644
--- a/browser/components/tabbrowser/content/tabs.js
+++ b/browser/components/tabbrowser/content/tabs.js
@@ -94,7 +94,7 @@
@@ -145,7 +145,7 @@ index fa96568d366fd3608f9bd583fa793150bd815c8b..1c940a3b162919256ca73fa867c5c261
}
get verticalMode() {
@@ -1537,28 +1565,40 @@
@@ -1537,29 +1565,41 @@
if (this.#allTabs) {
return this.#allTabs;
}
@@ -189,11 +189,12 @@ index fa96568d366fd3608f9bd583fa793150bd815c8b..1c940a3b162919256ca73fa867c5c261
}
get allGroups() {
- let children = Array.from(this.arrowScrollbox.children);
+ let children = ZenWorkspaces.tabboxChildren;
return children.filter(node => node.tagName == "tab-group");
let children = Array.from(this.arrowScrollbox.children);
- return children.filter(node => node.tagName == "tab-group");
+ return ZenWorkspaces.allTabGroups;
}
/**
@@ -1579,7 +1619,7 @@
*/
get visibleTabs() {

View File

@@ -1,5 +1,5 @@
diff --git a/dom/html/HTMLMediaElement.cpp b/dom/html/HTMLMediaElement.cpp
index 0b8dee1ca22b1f0ddcf7e6a976f606990104b56e..a3a5a7cfcaa8a4719e56988bc917183fa3cc9d10 100644
index 0b8dee1ca22b1f0ddcf7e6a976f606990104b56e..db31132b67a041abf6bf3e5ed68ab20380fdc293 100644
--- a/dom/html/HTMLMediaElement.cpp
+++ b/dom/html/HTMLMediaElement.cpp
@@ -455,6 +455,7 @@ class HTMLMediaElement::MediaControlKeyListener final
@@ -10,3 +10,13 @@ index 0b8dee1ca22b1f0ddcf7e6a976f606990104b56e..a3a5a7cfcaa8a4719e56988bc917183f
NotifyAudibleStateChanged(mIsOwnerAudible
? MediaAudibleState::eAudible
: MediaAudibleState::eInaudible);
@@ -6952,6 +6953,9 @@ void HTMLMediaElement::FireTimeUpdate(TimeupdateType aType) {
DispatchAsyncEvent(std::move(runner));
mQueueTimeUpdateRunnerTime = TimeStamp::Now();
mLastCurrentTime = CurrentTime();
+ if (aType == TimeupdateType::eMandatory) {
+ mMediaControlKeyListener->NotifyMediaPositionState();
+ }
}
if (mFragmentEnd >= 0.0 && CurrentTime() >= mFragmentEnd) {
Pause();

View File

@@ -1,8 +1,16 @@
diff --git a/toolkit/components/pictureinpicture/content/player.xhtml b/toolkit/components/pictureinpicture/content/player.xhtml
index 440ce51e8e67e4d3a7bdcb78f38f2fb6684c9848..6b48a3178f9de460dd3b08728f5638ef2751de21 100644
index 440ce51e8e67e4d3a7bdcb78f38f2fb6684c9848..38912579310314a13d516328ec770db6b589d243 100644
--- a/toolkit/components/pictureinpicture/content/player.xhtml
+++ b/toolkit/components/pictureinpicture/content/player.xhtml
@@ -52,13 +52,22 @@
@@ -17,6 +17,7 @@
<link rel="localization" href="browser/browserSets.ftl"/>
<script src="chrome://global/content/pictureinpicture/player.js"></script>
<title data-l10n-id="pictureinpicture-player-title"></title>
+ <link rel="localization" href="browser/zen-general.ftl"/>
</head>
<body>
@@ -52,13 +53,22 @@
tabindex="10"
#endif
/>

View File

@@ -0,0 +1,12 @@
diff --git a/toolkit/content/widgets/findbar.js b/toolkit/content/widgets/findbar.js
index 8ca512e0b212bb6e25ed37e7edb4f8e2587d5bb0..5abfff92b3a8df5d138082af96419668a2c8a9bb 100644
--- a/toolkit/content/widgets/findbar.js
+++ b/toolkit/content/widgets/findbar.js
@@ -1188,6 +1188,7 @@
* e.g. <command name="cmd_find" oncommand="gFindBar.onFindCommand();"/>
*/
onFindCommand() {
+ if (gBrowser?.selectedTab?.hasAttribute("zen-empty-tab")) return;
return this.startFind(this.FIND_NORMAL);
}

View File

@@ -5,8 +5,8 @@
"binaryName": "zen",
"version": {
"product": "firefox",
"version": "136.0.2",
"candidate": "136.0.2"
"version": "136.0.3",
"candidate": "136.0.3"
},
"buildOptions": {
"generateBranding": true
@@ -19,7 +19,7 @@
"brandShortName": "Zen",
"brandFullName": "Zen Browser",
"release": {
"displayVersion": "1.10.1b",
"displayVersion": "1.10.2b",
"github": {
"repo": "zen-browser/desktop"
},
@@ -39,7 +39,7 @@
"brandShortName": "Twilight",
"brandFullName": "Zen Twilight",
"release": {
"displayVersion": "1.10.1t",
"displayVersion": "1.10.2t",
"github": {
"repo": "zen-browser/desktop"
}
@@ -53,4 +53,4 @@
"licenseType": "MPL-2.0"
},
"updateHostname": "updates.zen-browser.app"
}
}