summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.iOS
diff options
context:
space:
mode:
authorSamantha Houts <samhouts@users.noreply.github.com>2017-09-16 01:52:24 (GMT)
committerSamantha Houts <samantha.houts@xamarin.com>2017-09-16 01:52:50 (GMT)
commitc1095f45a994f5b8ba4e6ca6e44cccb3dffeef95 (patch)
treedf4292fd1bb8a490b0140378769537b4ac037323 /Xamarin.Forms.Platform.iOS
parent352773a8432033fa384b8d1e841f0987d175f93b (diff)
downloadxamarin-forms-c1095f45a994f5b8ba4e6ca6e44cccb3dffeef95.zip
xamarin-forms-c1095f45a994f5b8ba4e6ca6e44cccb3dffeef95.tar.gz
xamarin-forms-c1095f45a994f5b8ba4e6ca6e44cccb3dffeef95.tar.bz2
[iOS] Can activate ContextActions on ListViews reliably again (#1144)
* Add ContextActions test category * Add repro for 58875 * [iOS] Null check for the Delegate; clear the static WeakRef on dispose
Diffstat (limited to 'Xamarin.Forms.Platform.iOS')
-rw-r--r--Xamarin.Forms.Platform.iOS/ContextScrollViewDelegate.cs5
1 files changed, 4 insertions, 1 deletions
diff --git a/Xamarin.Forms.Platform.iOS/ContextScrollViewDelegate.cs b/Xamarin.Forms.Platform.iOS/ContextScrollViewDelegate.cs
index e0e00c5..22f57fc 100644
--- a/Xamarin.Forms.Platform.iOS/ContextScrollViewDelegate.cs
+++ b/Xamarin.Forms.Platform.iOS/ContextScrollViewDelegate.cs
@@ -203,7 +203,9 @@ namespace Xamarin.Forms.Platform.iOS
return false;
UIScrollView scrollViewBeingScrolled;
- if (!s_scrollViewBeingScrolled.TryGetTarget(out scrollViewBeingScrolled) || ReferenceEquals(scrollViewBeingScrolled, scrollView) || !ReferenceEquals(((ContextScrollViewDelegate)scrollViewBeingScrolled.Delegate)._table, ((ContextScrollViewDelegate)scrollView.Delegate)._table))
+ if (!s_scrollViewBeingScrolled.TryGetTarget(out scrollViewBeingScrolled)
+ || ReferenceEquals(scrollViewBeingScrolled, scrollView)
+ || !ReferenceEquals(((ContextScrollViewDelegate)scrollViewBeingScrolled.Delegate)?._table, ((ContextScrollViewDelegate)scrollView.Delegate)?._table))
return false;
scrollView.SetContentOffset(new PointF(0, 0), false);
@@ -221,6 +223,7 @@ namespace Xamarin.Forms.Platform.iOS
{
ClosedCallback = null;
+ s_scrollViewBeingScrolled = null;
_table = null;
_backgroundView = null;
_container = null;