mirror of
https://github.com/zen-browser/desktop.git
synced 2026-04-06 07:38:36 +00:00
gh-10687: Space switching should ignore system prefs (gh-13079)
This commit is contained in:
@@ -27,3 +27,7 @@
|
||||
- name: widget.macos.native-popovers
|
||||
value: true
|
||||
condition: "defined(XP_MACOSX)"
|
||||
|
||||
- name: zen.widget.macos.override-system-swipe-gestures
|
||||
value: true
|
||||
condition: "defined(XP_MACOSX)"
|
||||
|
||||
@@ -1,8 +1,19 @@
|
||||
diff --git a/browser/base/content/browser-gestureSupport.js b/browser/base/content/browser-gestureSupport.js
|
||||
index a28d54bf72c0e6495b9586f220d1859aac794936..66154668b9f85ffbaacea1e8351370659260227b 100644
|
||||
index a28d54bf72c0e6495b9586f220d1859aac794936..411d7255a68c48643617d77cc279a0a831fdf5c9 100644
|
||||
--- a/browser/base/content/browser-gestureSupport.js
|
||||
+++ b/browser/base/content/browser-gestureSupport.js
|
||||
@@ -832,7 +832,7 @@ var gHistorySwipeAnimation = {
|
||||
@@ -247,6 +247,10 @@ var gGestureSupport = {
|
||||
: aEvent.DIRECTION_LEFT;
|
||||
}
|
||||
|
||||
+ if (!gHistorySwipeAnimation._isSupported()) {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
return canGoBack || canGoForward;
|
||||
},
|
||||
|
||||
@@ -832,7 +836,7 @@ var gHistorySwipeAnimation = {
|
||||
* @return true if there is a previous page in history, false otherwise.
|
||||
*/
|
||||
canGoBack: function HSA_canGoBack() {
|
||||
|
||||
14
src/widget/cocoa/nsCocoaUtils-mm.patch
Normal file
14
src/widget/cocoa/nsCocoaUtils-mm.patch
Normal file
@@ -0,0 +1,14 @@
|
||||
diff --git a/widget/cocoa/nsCocoaUtils.mm b/widget/cocoa/nsCocoaUtils.mm
|
||||
index 540130c449b859f50847cad8177bd1065f67078a..83f96be9dc5aefe178e788472f220e9d560f5e2d 100644
|
||||
--- a/widget/cocoa/nsCocoaUtils.mm
|
||||
+++ b/widget/cocoa/nsCocoaUtils.mm
|
||||
@@ -1632,7 +1632,8 @@ bool static ShouldConsiderStartingSwipeFromEvent(NSEvent* anEvent) {
|
||||
return [anEvent type] == NSEventTypeScrollWheel &&
|
||||
eventPhase == NSEventPhaseBegan &&
|
||||
[anEvent hasPreciseScrollingDeltas] &&
|
||||
- [NSEvent isSwipeTrackingFromScrollEventsEnabled];
|
||||
+ ([NSEvent isSwipeTrackingFromScrollEventsEnabled] ||
|
||||
+ Preferences::GetBool("zen.widget.macos.override-system-swipe-gestures"));
|
||||
}
|
||||
|
||||
PanGestureInput nsCocoaUtils::CreatePanGestureEvent(
|
||||
Reference in New Issue
Block a user