summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorQuentin Glidic2017-03-13 13:35:49 +0100
committerQuentin Glidic2017-03-13 13:49:33 +0100
commitafdc82a7d0bc82d68ee9439fbe11cfe8c7682945 (patch)
tree7a65edb0280b0dcfb55e2a8ee6899a148059b863 /packages
parentc76005fd133c8b4d2afca375e7c01c384d563bc3 (diff)
downloadsardemff7-pending-afdc82a7d0bc82d68ee9439fbe11cfe8c7682945.tar.xz
mozilla-app: Update GTK+2-less patches
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
Diffstat (limited to 'packages')
-rw-r--r--packages/mail-client/daily/files/gtk2less.patch101
-rw-r--r--packages/net-www/nightly/files/gtk2less.patch101
2 files changed, 44 insertions, 158 deletions
diff --git a/packages/mail-client/daily/files/gtk2less.patch b/packages/mail-client/daily/files/gtk2less.patch
index 15b58a2..e3ef2dd 100644
--- a/packages/mail-client/daily/files/gtk2less.patch
+++ b/packages/mail-client/daily/files/gtk2less.patch
@@ -1,17 +1,17 @@
-From 1e37521bf1b7603bb0b03a1d8fc8e20a237e2417 Mon Sep 17 00:00:00 2001
+From d744f1f548f7e17f3562c96a6f33e778a3e73197 Mon Sep 17 00:00:00 2001
From: Quentin Glidic <sardemff7+git@sardemff7.net>
Date: Mon, 18 Jul 2016 13:32:15 +0200
Subject: [PATCH] Less GKT+2
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
---
- dom/plugins/ipc/PluginInstanceChild.cpp | 20 ++++++++++----------
+ dom/plugins/ipc/PluginInstanceChild.cpp | 6 +++---
dom/plugins/ipc/PluginInstanceChild.h | 4 ++--
dom/plugins/ipc/PluginModuleChild.cpp | 25 +++++++++++++++++++------
- 3 files changed, 31 insertions(+), 18 deletions(-)
+ 3 files changed, 24 insertions(+), 11 deletions(-)
diff --git a/dom/plugins/ipc/PluginInstanceChild.cpp b/dom/plugins/ipc/PluginInstanceChild.cpp
-index cacb087..bfe7a46 100644
+index ba75651b1e49..ab1a04b0b9ac 100644
--- a/mozilla/dom/plugins/ipc/PluginInstanceChild.cpp
+++ b/mozilla/dom/plugins/ipc/PluginInstanceChild.cpp
@@ -47,7 +47,7 @@ using namespace mozilla::gfx;
@@ -23,83 +23,26 @@ index cacb087..bfe7a46 100644
#include <gtk/gtk.h>
#include <gdk/gdkx.h>
-@@ -151,9 +151,9 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
- , mAsyncInvalidateTask(0)
- , mCachedWindowActor(nullptr)
- , mCachedElementActor(nullptr)
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- , mXEmbed(false)
--#endif // MOZ_WIDGET_GTK
-+#endif // MOZ_WIDGET_GTK2
- #if defined(OS_WIN)
- , mPluginWindowHWND(0)
- , mPluginWndProc(0)
-@@ -200,7 +200,7 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
+@@ -194,7 +194,7 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
#if defined(MOZ_X11) && defined(XP_UNIX) && !defined(XP_MACOSX)
mWindow.ws_info = &mWsInfo;
memset(&mWsInfo, 0, sizeof(mWsInfo));
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
mWsInfo.display = nullptr;
- mXtClient.top_widget = nullptr;
#else
-@@ -599,7 +599,7 @@ PluginInstanceChild::NPN_SetValue(NPPVariable aVar, void* aValue)
- return NPERR_GENERIC_ERROR;
-
- NPWindowType newWindowType = windowed ? NPWindowTypeWindow : NPWindowTypeDrawable;
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mWindow.type != newWindowType && mWsInfo.display) {
- // plugin type has been changed but we already have a valid display
- // so update it for the recent plugin mode
-@@ -1157,7 +1157,7 @@ bool PluginInstanceChild::CreateWindow(const NPRemoteWindow& aWindow)
- aWindow.x, aWindow.y,
- aWindow.width, aWindow.height));
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXEmbed) {
- mWindow.window = reinterpret_cast<void*>(aWindow.window);
- }
-@@ -1186,7 +1186,7 @@ void PluginInstanceChild::DeleteWindow()
- if (!mWindow.window)
- return;
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXtClient.top_widget) {
- xt_client_unrealize(&mXtClient);
- xt_client_destroy(&mXtClient);
-@@ -1268,7 +1268,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
- CreateWindow(aWindow);
- }
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXEmbed && gtk_check_version(2,18,7) != nullptr) { // older
- if (aWindow.type == NPWindowTypeWindow) {
- GdkWindow* socket_window = gdk_window_lookup(static_cast<GdkNativeWindow>(aWindow.window));
-@@ -1395,7 +1395,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
+ mWsInfo.display = DefaultXDisplay();
+@@ -1270,7 +1270,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
bool
PluginInstanceChild::Initialize()
{
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
- NPError rv;
-
if (mWsInfo.display) {
-@@ -4600,7 +4600,7 @@ PluginInstanceChild::Destroy()
-
- mPendingAsyncCalls.Clear();
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mWindow.type == NPWindowTypeWindow && !mXEmbed) {
- xt_client_xloop_destroy();
- }
+ // Already initialized
+ return true;
diff --git a/dom/plugins/ipc/PluginInstanceChild.h b/dom/plugins/ipc/PluginInstanceChild.h
-index cdeffc0..e82732d 100644
+index 1836cec193a8..19abeeb0e9bf 100644
--- a/mozilla/dom/plugins/ipc/PluginInstanceChild.h
+++ b/mozilla/dom/plugins/ipc/PluginInstanceChild.h
@@ -35,7 +35,7 @@
@@ -111,17 +54,17 @@ index cdeffc0..e82732d 100644
#include "gtk2xtbin.h"
#endif
-@@ -454,7 +454,7 @@ private:
+@@ -447,7 +447,7 @@ private:
#if defined(MOZ_X11) && defined(XP_UNIX) && !defined(XP_MACOSX)
NPSetWindowCallbackStruct mWsInfo;
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
- bool mXEmbed;
XtClient mXtClient;
#endif
+ #elif defined(OS_WIN)
diff --git a/dom/plugins/ipc/PluginModuleChild.cpp b/dom/plugins/ipc/PluginModuleChild.cpp
-index 27bbd60..83b0821 100644
+index f86149eac5d1..7068cd5bd138 100644
--- a/mozilla/dom/plugins/ipc/PluginModuleChild.cpp
+++ b/mozilla/dom/plugins/ipc/PluginModuleChild.cpp
@@ -11,7 +11,7 @@
@@ -133,7 +76,7 @@ index 27bbd60..83b0821 100644
#include <gtk/gtk.h>
#endif
-@@ -117,7 +117,7 @@ PluginModuleChild::PluginModuleChild(bool aIsChrome)
+@@ -127,7 +127,7 @@ PluginModuleChild::PluginModuleChild(bool aIsChrome)
, mInitializeFunc(0)
#if defined(OS_WIN) || defined(OS_MACOSX)
, mGetEntryPointsFunc(0)
@@ -142,7 +85,7 @@ index 27bbd60..83b0821 100644
, mNestedLoopTimerId(0)
#endif
#ifdef OS_WIN
-@@ -310,7 +310,20 @@ PluginModuleChild::InitForChrome(const std::string& aPluginFilename,
+@@ -316,7 +316,20 @@ PluginModuleChild::InitForChrome(const std::string& aPluginFilename,
return true;
}
@@ -164,7 +107,7 @@ index 27bbd60..83b0821 100644
typedef void (*GObjectDisposeFn)(GObject*);
typedef gboolean (*GtkWidgetScrollEventFn)(GtkWidget*, GdkEventScroll*);
-@@ -559,7 +572,7 @@ PluginModuleChild::ShouldContinueFromReplyTimeout()
+@@ -565,7 +578,7 @@ PluginModuleChild::ShouldContinueFromReplyTimeout()
bool
PluginModuleChild::InitGraphics()
{
@@ -173,7 +116,7 @@ index 27bbd60..83b0821 100644
// Work around plugins that don't interact well with GDK
// client-side windows.
PR_SetEnv("GDK_NATIVE_WINDOWS=1");
-@@ -1094,7 +1107,7 @@ _getvalue(NPP aNPP,
+@@ -1089,7 +1102,7 @@ _getvalue(NPP aNPP,
switch (aVariable) {
// Copied from nsNPAPIPlugin.cpp
case NPNVToolkit:
@@ -182,15 +125,15 @@ index 27bbd60..83b0821 100644
*static_cast<NPNToolkitType*>(aValue) = NPNVGtk2;
return NPERR_NO_ERROR;
#endif
-@@ -1115,7 +1128,7 @@ _getvalue(NPP aNPP,
+@@ -1113,7 +1126,7 @@ _getvalue(NPP aNPP,
case NPNVSupportsWindowless:
- *(NPBool*)aValue = PluginModuleChild::GetChrome()->Settings().supportsWindowless();
+ *(NPBool*)aValue = true;
return NPERR_NO_ERROR;
-#if defined(MOZ_WIDGET_GTK)
+#if (MOZ_WIDGET_GTK == 2)
case NPNVxDisplay: {
- if (aNPP) {
- return InstCast(aNPP)->NPN_GetValue(aVariable, aValue);
+ if (!aNPP) {
+ return NPERR_INVALID_INSTANCE_ERROR;
--
-2.9.0
+2.11.1
diff --git a/packages/net-www/nightly/files/gtk2less.patch b/packages/net-www/nightly/files/gtk2less.patch
index 3347b6a..daa3a6d 100644
--- a/packages/net-www/nightly/files/gtk2less.patch
+++ b/packages/net-www/nightly/files/gtk2less.patch
@@ -1,17 +1,17 @@
-From 1e37521bf1b7603bb0b03a1d8fc8e20a237e2417 Mon Sep 17 00:00:00 2001
+From d744f1f548f7e17f3562c96a6f33e778a3e73197 Mon Sep 17 00:00:00 2001
From: Quentin Glidic <sardemff7+git@sardemff7.net>
Date: Mon, 18 Jul 2016 13:32:15 +0200
Subject: [PATCH] Less GKT+2
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
---
- dom/plugins/ipc/PluginInstanceChild.cpp | 20 ++++++++++----------
+ dom/plugins/ipc/PluginInstanceChild.cpp | 6 +++---
dom/plugins/ipc/PluginInstanceChild.h | 4 ++--
dom/plugins/ipc/PluginModuleChild.cpp | 25 +++++++++++++++++++------
- 3 files changed, 31 insertions(+), 18 deletions(-)
+ 3 files changed, 24 insertions(+), 11 deletions(-)
diff --git a/dom/plugins/ipc/PluginInstanceChild.cpp b/dom/plugins/ipc/PluginInstanceChild.cpp
-index cacb087..bfe7a46 100644
+index ba75651b1e49..ab1a04b0b9ac 100644
--- a/dom/plugins/ipc/PluginInstanceChild.cpp
+++ b/dom/plugins/ipc/PluginInstanceChild.cpp
@@ -47,7 +47,7 @@ using namespace mozilla::gfx;
@@ -23,83 +23,26 @@ index cacb087..bfe7a46 100644
#include <gtk/gtk.h>
#include <gdk/gdkx.h>
-@@ -151,9 +151,9 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
- , mAsyncInvalidateTask(0)
- , mCachedWindowActor(nullptr)
- , mCachedElementActor(nullptr)
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- , mXEmbed(false)
--#endif // MOZ_WIDGET_GTK
-+#endif // MOZ_WIDGET_GTK2
- #if defined(OS_WIN)
- , mPluginWindowHWND(0)
- , mPluginWndProc(0)
-@@ -200,7 +200,7 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
+@@ -194,7 +194,7 @@ PluginInstanceChild::PluginInstanceChild(const NPPluginFuncs* aPluginIface,
#if defined(MOZ_X11) && defined(XP_UNIX) && !defined(XP_MACOSX)
mWindow.ws_info = &mWsInfo;
memset(&mWsInfo, 0, sizeof(mWsInfo));
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
mWsInfo.display = nullptr;
- mXtClient.top_widget = nullptr;
#else
-@@ -599,7 +599,7 @@ PluginInstanceChild::NPN_SetValue(NPPVariable aVar, void* aValue)
- return NPERR_GENERIC_ERROR;
-
- NPWindowType newWindowType = windowed ? NPWindowTypeWindow : NPWindowTypeDrawable;
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mWindow.type != newWindowType && mWsInfo.display) {
- // plugin type has been changed but we already have a valid display
- // so update it for the recent plugin mode
-@@ -1157,7 +1157,7 @@ bool PluginInstanceChild::CreateWindow(const NPRemoteWindow& aWindow)
- aWindow.x, aWindow.y,
- aWindow.width, aWindow.height));
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXEmbed) {
- mWindow.window = reinterpret_cast<void*>(aWindow.window);
- }
-@@ -1186,7 +1186,7 @@ void PluginInstanceChild::DeleteWindow()
- if (!mWindow.window)
- return;
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXtClient.top_widget) {
- xt_client_unrealize(&mXtClient);
- xt_client_destroy(&mXtClient);
-@@ -1268,7 +1268,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
- CreateWindow(aWindow);
- }
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mXEmbed && gtk_check_version(2,18,7) != nullptr) { // older
- if (aWindow.type == NPWindowTypeWindow) {
- GdkWindow* socket_window = gdk_window_lookup(static_cast<GdkNativeWindow>(aWindow.window));
-@@ -1395,7 +1395,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
+ mWsInfo.display = DefaultXDisplay();
+@@ -1270,7 +1270,7 @@ PluginInstanceChild::AnswerNPP_SetWindow(const NPRemoteWindow& aWindow)
bool
PluginInstanceChild::Initialize()
{
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
- NPError rv;
-
if (mWsInfo.display) {
-@@ -4600,7 +4600,7 @@ PluginInstanceChild::Destroy()
-
- mPendingAsyncCalls.Clear();
-
--#ifdef MOZ_WIDGET_GTK
-+#if (MOZ_WIDGET_GTK == 2)
- if (mWindow.type == NPWindowTypeWindow && !mXEmbed) {
- xt_client_xloop_destroy();
- }
+ // Already initialized
+ return true;
diff --git a/dom/plugins/ipc/PluginInstanceChild.h b/dom/plugins/ipc/PluginInstanceChild.h
-index cdeffc0..e82732d 100644
+index 1836cec193a8..19abeeb0e9bf 100644
--- a/dom/plugins/ipc/PluginInstanceChild.h
+++ b/dom/plugins/ipc/PluginInstanceChild.h
@@ -35,7 +35,7 @@
@@ -111,17 +54,17 @@ index cdeffc0..e82732d 100644
#include "gtk2xtbin.h"
#endif
-@@ -454,7 +454,7 @@ private:
+@@ -447,7 +447,7 @@ private:
#if defined(MOZ_X11) && defined(XP_UNIX) && !defined(XP_MACOSX)
NPSetWindowCallbackStruct mWsInfo;
-#ifdef MOZ_WIDGET_GTK
+#if (MOZ_WIDGET_GTK == 2)
- bool mXEmbed;
XtClient mXtClient;
#endif
+ #elif defined(OS_WIN)
diff --git a/dom/plugins/ipc/PluginModuleChild.cpp b/dom/plugins/ipc/PluginModuleChild.cpp
-index 27bbd60..83b0821 100644
+index f86149eac5d1..7068cd5bd138 100644
--- a/dom/plugins/ipc/PluginModuleChild.cpp
+++ b/dom/plugins/ipc/PluginModuleChild.cpp
@@ -11,7 +11,7 @@
@@ -133,7 +76,7 @@ index 27bbd60..83b0821 100644
#include <gtk/gtk.h>
#endif
-@@ -117,7 +117,7 @@ PluginModuleChild::PluginModuleChild(bool aIsChrome)
+@@ -127,7 +127,7 @@ PluginModuleChild::PluginModuleChild(bool aIsChrome)
, mInitializeFunc(0)
#if defined(OS_WIN) || defined(OS_MACOSX)
, mGetEntryPointsFunc(0)
@@ -142,7 +85,7 @@ index 27bbd60..83b0821 100644
, mNestedLoopTimerId(0)
#endif
#ifdef OS_WIN
-@@ -310,7 +310,20 @@ PluginModuleChild::InitForChrome(const std::string& aPluginFilename,
+@@ -316,7 +316,20 @@ PluginModuleChild::InitForChrome(const std::string& aPluginFilename,
return true;
}
@@ -164,7 +107,7 @@ index 27bbd60..83b0821 100644
typedef void (*GObjectDisposeFn)(GObject*);
typedef gboolean (*GtkWidgetScrollEventFn)(GtkWidget*, GdkEventScroll*);
-@@ -559,7 +572,7 @@ PluginModuleChild::ShouldContinueFromReplyTimeout()
+@@ -565,7 +578,7 @@ PluginModuleChild::ShouldContinueFromReplyTimeout()
bool
PluginModuleChild::InitGraphics()
{
@@ -173,7 +116,7 @@ index 27bbd60..83b0821 100644
// Work around plugins that don't interact well with GDK
// client-side windows.
PR_SetEnv("GDK_NATIVE_WINDOWS=1");
-@@ -1094,7 +1107,7 @@ _getvalue(NPP aNPP,
+@@ -1089,7 +1102,7 @@ _getvalue(NPP aNPP,
switch (aVariable) {
// Copied from nsNPAPIPlugin.cpp
case NPNVToolkit:
@@ -182,15 +125,15 @@ index 27bbd60..83b0821 100644
*static_cast<NPNToolkitType*>(aValue) = NPNVGtk2;
return NPERR_NO_ERROR;
#endif
-@@ -1115,7 +1128,7 @@ _getvalue(NPP aNPP,
+@@ -1113,7 +1126,7 @@ _getvalue(NPP aNPP,
case NPNVSupportsWindowless:
- *(NPBool*)aValue = PluginModuleChild::GetChrome()->Settings().supportsWindowless();
+ *(NPBool*)aValue = true;
return NPERR_NO_ERROR;
-#if defined(MOZ_WIDGET_GTK)
+#if (MOZ_WIDGET_GTK == 2)
case NPNVxDisplay: {
- if (aNPP) {
- return InstCast(aNPP)->NPN_GetValue(aVariable, aValue);
+ if (!aNPP) {
+ return NPERR_INVALID_INSTANCE_ERROR;
--
-2.9.0
+2.11.1