mirror of
https://github.com/zen-browser/desktop.git
synced 2025-11-18 08:11:06 +00:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
08996215b2 | ||
|
|
dfe932a4c5 | ||
|
|
a61b077d3f | ||
|
|
f36b84de3c | ||
|
|
01f10cfc09 | ||
|
|
9a9c1c312c |
@@ -42,7 +42,7 @@ let JSWINDOWACTORS = {
|
|||||||
esModuleURI: 'resource:///actors/ZenGlanceChild.sys.mjs',
|
esModuleURI: 'resource:///actors/ZenGlanceChild.sys.mjs',
|
||||||
events: {
|
events: {
|
||||||
DOMContentLoaded: {},
|
DOMContentLoaded: {},
|
||||||
click: {
|
mousedown: {
|
||||||
capture: true,
|
capture: true,
|
||||||
},
|
},
|
||||||
keydown: {
|
keydown: {
|
||||||
|
|||||||
@@ -1156,7 +1156,7 @@
|
|||||||
let dragDownThreshold =
|
let dragDownThreshold =
|
||||||
Services.prefs.getIntPref('zen.view.drag-and-drop.drop-inside-lower-threshold') / 100;
|
Services.prefs.getIntPref('zen.view.drag-and-drop.drop-inside-lower-threshold') / 100;
|
||||||
|
|
||||||
const dropElementGroup = dropElement;
|
const dropElementGroup = dropElement?.isZenFolder ? dropElement : dropElement?.group;
|
||||||
const isSplitGroup = dropElement?.group?.hasAttribute('split-view-group');
|
const isSplitGroup = dropElement?.group?.hasAttribute('split-view-group');
|
||||||
let firstGroupElem =
|
let firstGroupElem =
|
||||||
dropElementGroup.querySelector('.zen-tab-group-start').nextElementSibling;
|
dropElementGroup.querySelector('.zen-tab-group-start').nextElementSibling;
|
||||||
|
|||||||
@@ -1415,8 +1415,9 @@
|
|||||||
this.overlay.classList.remove('zen-glance-overlay');
|
this.overlay.classList.remove('zen-glance-overlay');
|
||||||
this.#clearContainerStyles(this.browserWrapper);
|
this.#clearContainerStyles(this.browserWrapper);
|
||||||
this.animatingFullOpen = false;
|
this.animatingFullOpen = false;
|
||||||
|
const glanceID = this.#currentGlanceID;
|
||||||
this.closeGlance({ noAnimation: true, skipPermitUnload: true });
|
this.closeGlance({ noAnimation: true, skipPermitUnload: true });
|
||||||
this.#glances.delete(this.#currentGlanceID);
|
this.#glances.delete(glanceID);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -35,9 +35,12 @@ export class ZenGlanceChild extends JSWindowActorChild {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#sendClickDataToParent(target, element) {
|
#sendClickDataToParent(target, element) {
|
||||||
if (!element || !target) {
|
if (!element && !target) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (!target) {
|
||||||
|
target = element;
|
||||||
|
}
|
||||||
// Get the largest element we can get. If the `A` element
|
// Get the largest element we can get. If the `A` element
|
||||||
// is a parent of the original target, use the anchor element,
|
// is a parent of the original target, use the anchor element,
|
||||||
// otherwise use the original target.
|
// otherwise use the original target.
|
||||||
@@ -54,7 +57,7 @@ export class ZenGlanceChild extends JSWindowActorChild {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
on_click(event) {
|
on_mousedown(event) {
|
||||||
// get closest A element
|
// get closest A element
|
||||||
const target = event.target.closest('A');
|
const target = event.target.closest('A');
|
||||||
const elementToRecord = event.originalTarget || event.target;
|
const elementToRecord = event.originalTarget || event.target;
|
||||||
|
|||||||
@@ -329,6 +329,13 @@
|
|||||||
scale: 0.92;
|
scale: 0.92;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&:not(:hover) {
|
||||||
|
.tab-close-button,
|
||||||
|
.tab-reset-button {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
& .tab-icon-image {
|
& .tab-icon-image {
|
||||||
&:not([src]),
|
&:not([src]),
|
||||||
&:-moz-broken {
|
&:-moz-broken {
|
||||||
|
|||||||
@@ -24,9 +24,6 @@ nsresult ZenCommonUtils::PlayHapticFeedbackInternal() {
|
|||||||
id<NSHapticFeedbackPerformer> performer = [NSHapticFeedbackManager defaultPerformer];
|
id<NSHapticFeedbackPerformer> performer = [NSHapticFeedbackManager defaultPerformer];
|
||||||
[performer performFeedbackPattern:NSHapticFeedbackPatternAlignment
|
[performer performFeedbackPattern:NSHapticFeedbackPatternAlignment
|
||||||
performanceTime:NSHapticFeedbackPerformanceTimeDefault];
|
performanceTime:NSHapticFeedbackPerformanceTimeDefault];
|
||||||
} else {
|
|
||||||
// Fallback on earlier versions
|
|
||||||
// Note: This is a no-op on older versions of iOS/macOS
|
|
||||||
}
|
}
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
NS_OBJC_END_TRY_BLOCK_RETURN(NS_OK);
|
NS_OBJC_END_TRY_BLOCK_RETURN(NS_OK);
|
||||||
|
|||||||
@@ -2555,6 +2555,7 @@ var gZenWorkspaces = new (class extends nsZenMultiWindowFeature {
|
|||||||
|
|
||||||
async onPinnedTabsResize(entries, forAnimation = false, animateContainer = false) {
|
async onPinnedTabsResize(entries, forAnimation = false, animateContainer = false) {
|
||||||
if (
|
if (
|
||||||
|
document.documentElement.hasAttribute('inDOMFullscreen') ||
|
||||||
!this._hasInitializedTabsStrip ||
|
!this._hasInitializedTabsStrip ||
|
||||||
(this._organizingWorkspaceStrip && !forAnimation) ||
|
(this._organizingWorkspaceStrip && !forAnimation) ||
|
||||||
document.documentElement.hasAttribute('zen-creating-workspace') ||
|
document.documentElement.hasAttribute('zen-creating-workspace') ||
|
||||||
|
|||||||
Reference in New Issue
Block a user