mirror of
https://github.com/electron/electron.git
synced 2026-05-02 03:00:22 -04:00
Swipe back/forward should respect system preferences
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
#include "atom/common/color_util.h"
|
||||
#include "atom/common/draggable_region.h"
|
||||
#include "atom/common/options_switches.h"
|
||||
#include "atom/common/platform_util.h"
|
||||
#include "base/mac/mac_util.h"
|
||||
#include "base/mac/scoped_cftyperef.h"
|
||||
#include "base/strings/sys_string_conversions.h"
|
||||
@@ -577,6 +578,9 @@ NativeWindowMac::NativeWindowMac(
|
||||
if (!web_contents)
|
||||
return event;
|
||||
|
||||
if (!platform_util::IsSwipeTrackingFromScrollEventsEnabled())
|
||||
return event;
|
||||
|
||||
if (!began && (([event phase] == NSEventPhaseMayBegin) ||
|
||||
([event phase] == NSEventPhaseBegan))) {
|
||||
this->NotifyWindowScrollTouchBegin();
|
||||
|
||||
Reference in New Issue
Block a user