AndroidAssignFocus.cs 516 Bytes
Newer Older
Mattia's avatar
Mattia committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
using System;
using Android.Views.Accessibility;
using Xamarin.Forms;
using Xamarin.Forms.Platform.Android;
using SampleApp.Droid;
using SampleApp.DependencyServices;

[assembly: Dependency(typeof(AndroidAssignFocus))]
namespace SampleApp.Droid
{
    public class AndroidAssignFocus : IAssignFocus
    {
        public AndroidAssignFocus()
        {
        }

        public void AssignFocus(View v)
        {
            v.GetRenderer().View.SendAccessibilityEvent(EventTypes.ViewHoverEnter);
        }
    }
}