Imported Upstream version 6.10.0.105

Former-commit-id: 2375b35bddf605a9d7f03e5431f8f15f890c1dd2
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2020-05-16 08:40:36 +00:00
parent d9bb6a9e48
commit 92747312ea
52 changed files with 450 additions and 393 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -10,7 +10,7 @@ generated by GNU Autoconf 2.69. Invocation command line was
## Platform. ##
## --------- ##
hostname = az-ubuntu-general1a4400
hostname = az-ubuntu-generala37872
uname -m = x86_64
uname -r = 4.15.0-1082-azure
uname -s = Linux
@@ -747,7 +747,7 @@ generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_COMMANDS =
$ ./config.status
on az-ubuntu-general1a4400
on az-ubuntu-generala37872
config.status:1238: creating Makefile
config.status:1238: creating bdw-gc.pc

View File

@@ -1 +1 @@
9a8b0c875e476a1255a9e03fb7c47a1daca8853b
c2c3f46f950f38965c2709deeb9dfbc7bf047010

View File

@@ -230,7 +230,8 @@ class GtkPackage (GitHubPackage):
# https://devdiv.visualstudio.com/DevDiv/_workitems/edit/993471
'patches/gtk/gtk-pboard-types.patch',
'patches/gtk/define-NSPasteboardTypeURL.patch'
'patches/gtk/define-NSPasteboardTypeURL.patch',
'patches/gtk/Fix-1080409-StackOverflow-exception-opening-Gtk-host.patch'
])
def prep(self):

View File

@@ -0,0 +1,56 @@
From 588cba301ee3c43bdaebd41922b7bb60eb85c2ce Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?David=20Karlas=CC=8C?= <david.karlas@gmail.com>
Date: Thu, 14 May 2020 15:13:56 +0200
Subject: [PATCH] Fix 1080409: StackOverflow exception opening Gtk hosted
NSView
Problem was that if `r.origin.x`/`r.origin.y` were 0, same value was looped until stackoverflow.
Whole logic of method assumes that it will loop over children hence recursive but in fact it kept passing same NSView over and over again...
---
gdk/quartz/gdkevents-quartz.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/gdk/quartz/gdkevents-quartz.c b/gdk/quartz/gdkevents-quartz.c
index a12597d0f9..1734762e5c 100644
--- a/gdk/quartz/gdkevents-quartz.c
+++ b/gdk/quartz/gdkevents-quartz.c
@@ -729,9 +729,8 @@ _gdk_quartz_events_send_map_event (GdkWindow *window)
}
static NSView *
-find_nsview_at_pos (GdkWindowImplQuartz *impl, gint x, gint y)
+find_nsview_at_pos (NSView *view, NSView *layer_view, gint x, gint y)
{
- NSView *view = impl->view;
guint n_subviews;
guint i;
@@ -742,14 +741,14 @@ find_nsview_at_pos (GdkWindowImplQuartz *impl, gint x, gint y)
NSView* sv = [[view subviews] objectAtIndex:i];
NSRect r = [sv frame];
- if (sv == impl->layer_view)
+ if (sv == layer_view)
continue;
if (![sv isHidden] &&
r.origin.x <= x && r.origin.x + r.size.width >= x &&
r.origin.y <= y && r.origin.y + r.size.height >= y)
{
- NSView* child = find_nsview_at_pos (impl, x - r.origin.x, y - r.origin.y);
+ NSView* child = find_nsview_at_pos (sv, layer_view, x - r.origin.x, y - r.origin.y);
if (child != NULL)
return child;
else
@@ -933,7 +932,7 @@ find_window_for_ns_event (NSEvent *nsevent,
toplevel_private = (GdkWindowObject *)toplevel;
toplevel_impl = (GdkWindowImplQuartz *)toplevel_private->impl;
- subview = find_nsview_at_pos (toplevel_impl, x_tmp, y_tmp);
+ subview = find_nsview_at_pos (toplevel_impl->view, toplevel_impl->layer_view, x_tmp, y_tmp);
if (subview != NULL && ![subview isKindOfClass:[GdkQuartzView class]]) {
g_signal_emit_by_name (toplevel, "native-child-event",
subview, nsevent);
--
2.21.1 (Apple Git-122.3)