summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Android
diff options
context:
space:
mode:
authorJason Smith <jason.smith@xamarin.com>2016-10-03 04:05:09 -0700
committerRui Marinho <me@ruimarinho.net>2016-10-03 12:05:09 +0100
commit4f8af14f13f34d9b66d92e315c8486edd28e851a (patch)
treea959eb281cf9dac46eb153f84f9af362dabf1a68 /Xamarin.Forms.Platform.Android
parenta749558c6710c6e1e0b6bd0ae3cd567c00c5387c (diff)
downloadxamarin-forms-4f8af14f13f34d9b66d92e315c8486edd28e851a.tar.gz
xamarin-forms-4f8af14f13f34d9b66d92e315c8486edd28e851a.tar.bz2
xamarin-forms-4f8af14f13f34d9b66d92e315c8486edd28e851a.zip
Make CreateNativeControl virtual instead of abstract (#406)
Fixes backwards compatibility issue.
Diffstat (limited to 'Xamarin.Forms.Platform.Android')
-rw-r--r--Xamarin.Forms.Platform.Android/ViewRenderer.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.Android/ViewRenderer.cs b/Xamarin.Forms.Platform.Android/ViewRenderer.cs
index 057fbcee..c4bd3fa0 100644
--- a/Xamarin.Forms.Platform.Android/ViewRenderer.cs
+++ b/Xamarin.Forms.Platform.Android/ViewRenderer.cs
@@ -13,7 +13,10 @@ namespace Xamarin.Forms.Platform.Android
public abstract class ViewRenderer<TView, TNativeView> : VisualElementRenderer<TView>, AView.IOnFocusChangeListener where TView : View where TNativeView : AView
{
- protected abstract TNativeView CreateNativeControl();
+ protected virtual TNativeView CreateNativeControl()
+ {
+ return default(TNativeView);
+ }
ViewGroup _container;
@@ -224,4 +227,4 @@ namespace Xamarin.Forms.Platform.Android
Control.Enabled = Element.IsEnabled;
}
}
-} \ No newline at end of file
+}