forked from pool/MozillaFirefox
Accepting request 542056 from home:cgiboudeaux:branches:mozilla:Factory
- Add show-context-menu-on-mouse-release.patch. Starting with Firefox 57, the context menu appears on key press. This patch creates a config entry to restore the old behaviour. Without the patch, the mouse gesture extensions require 2 clicks to work (bmo#1360278). The config entry is named "input.contextMenu.onRelease" (default: false). OBS-URL: https://build.opensuse.org/request/show/542056 OBS-URL: https://build.opensuse.org/package/show/mozilla:Factory/MozillaFirefox?expand=0&rev=613
This commit is contained in:
parent
1975148d10
commit
fe9ab0007d
@ -1,3 +1,13 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 15 11:21:16 UTC 2017 - christophe@krop.fr
|
||||
|
||||
- Add show-context-menu-on-mouse-release.patch.
|
||||
Starting with Firefox 57, the context menu appears on key press.
|
||||
This patch creates a config entry to restore the
|
||||
old behaviour. Without the patch, the mouse gesture extensions
|
||||
require 2 clicks to work (bmo#1360278). The config entry is named
|
||||
"input.contextMenu.onRelease" (default: false).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 15 06:46:06 UTC 2017 - wr@rosenauer.org
|
||||
|
||||
|
@ -157,6 +157,7 @@ Patch8: mozilla-bindgen-systemlibs.patch
|
||||
Patch101: firefox-kde.patch
|
||||
Patch102: firefox-no-default-ualocale.patch
|
||||
Patch103: firefox-branded-icons.patch
|
||||
Patch104: show-context-menu-on-mouse-release.patch
|
||||
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Requires(post): coreutils shared-mime-info desktop-file-utils
|
||||
@ -268,6 +269,7 @@ cd $RPM_BUILD_DIR/mozilla
|
||||
%patch101 -p1
|
||||
%patch102 -p1
|
||||
%patch103 -p1
|
||||
%patch104 -p1
|
||||
|
||||
%build
|
||||
# no need to add build time to binaries
|
||||
|
61
show-context-menu-on-mouse-release.patch
Normal file
61
show-context-menu-on-mouse-release.patch
Normal file
@ -0,0 +1,61 @@
|
||||
# HG changeset patch
|
||||
# User Dimi Meim <dimimeim@gmail.com>
|
||||
# Date 1508186130 -10800
|
||||
# Mon Oct 16 23:35:30 2017 +0300
|
||||
# Node ID 7251515cd508453edff10be2e1294261ef1dc4b5
|
||||
# Parent c241c2b44a75f4bad80e12c3a1a7cb5aaf37a3f7
|
||||
Bug-1360278-fix
|
||||
|
||||
diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js
|
||||
--- a/modules/libpref/init/all.js
|
||||
+++ b/modules/libpref/init/all.js
|
||||
@@ -5913,3 +5913,6 @@ pref("dom.noopener.newprocess.enabled",
|
||||
|
||||
pref("layers.omtp.enabled", false);
|
||||
pref("layers.omtp.force-sync", false);
|
||||
+
|
||||
+//Pop up context menu on mouse button release
|
||||
+pref("input.contextMenu.onRelease", false);
|
||||
diff --git a/widget/gtk/nsWindow.cpp b/widget/gtk/nsWindow.cpp
|
||||
--- a/widget/gtk/nsWindow.cpp
|
||||
+++ b/widget/gtk/nsWindow.cpp
|
||||
@@ -362,6 +362,7 @@ static bool gBlockActivateE
|
||||
static bool gGlobalsInitialized = false;
|
||||
static bool gRaiseWindows = true;
|
||||
|
||||
+static bool menuContextOnClickRelease = false;
|
||||
#if GTK_CHECK_VERSION(3,4,0)
|
||||
static uint32_t gLastTouchID = 0;
|
||||
#endif
|
||||
@@ -2795,9 +2796,11 @@ nsWindow::OnButtonPressEvent(GdkEventBut
|
||||
|
||||
DispatchInputEvent(&event);
|
||||
|
||||
+ Preferences::AddBoolVarCache(&menuContextOnClickRelease, "input.contextMenu.onRelease", false);
|
||||
+
|
||||
// right menu click on linux should also pop up a context menu
|
||||
if (domButton == WidgetMouseEvent::eRightButton &&
|
||||
- MOZ_LIKELY(!mIsDestroyed)) {
|
||||
+ MOZ_LIKELY(!mIsDestroyed) && !menuContextOnClickRelease) {
|
||||
WidgetMouseEvent contextMenuEvent(true, eContextMenu, this,
|
||||
WidgetMouseEvent::eReal);
|
||||
InitButtonEvent(contextMenuEvent, aEvent);
|
||||
@@ -2838,6 +2841,18 @@ nsWindow::OnButtonReleaseEvent(GdkEventB
|
||||
|
||||
DispatchInputEvent(&event);
|
||||
mLastMotionPressure = pressure;
|
||||
+
|
||||
+ Preferences::AddBoolVarCache(&menuContextOnClickRelease, "input.contextMenu.onRelease", false);
|
||||
+
|
||||
+ // right menu click on linux should also pop up a context menu
|
||||
+ if (domButton == WidgetMouseEvent::eRightButton &&
|
||||
+ MOZ_LIKELY(!mIsDestroyed) && menuContextOnClickRelease) {
|
||||
+ WidgetMouseEvent contextMenuEvent(true, eContextMenu, this,
|
||||
+ WidgetMouseEvent::eReal);
|
||||
+ InitButtonEvent(contextMenuEvent, aEvent);
|
||||
+ contextMenuEvent.pressure = mLastMotionPressure;
|
||||
+ DispatchInputEvent(&contextMenuEvent);
|
||||
+ }
|
||||
}
|
||||
|
||||
void
|
Loading…
Reference in New Issue
Block a user