protected override void OnCreate (Bundle savedInstanceState)
        {
            bool pageLoadSelection = true;
            base.OnCreate (savedInstanceState);

            var doubleTapDetector = new GestureDetector (this, new DoubleTapGestureListener ());
            doubleTapDetector.DoubleTap += (sender, e) => ShowAlert ("DoubleTap Alert", "DoubleTap");
            // Create your application here
            SetContentView(Resource.Layout.TapTests);
            ActionBar.SetHomeButtonEnabled (true);
            ActionBar.SetDisplayHomeAsUpEnabled (true);

            Button tapButton = FindViewById<Button> (Resource.Id.tap_test_tap_button);
            Button doubleTapButton = FindViewById<Button> (Resource.Id.tap_test_double_tap_button);
            Button longPressButton = FindViewById<Button> (Resource.Id.tap_test_long_press_button);
            Spinner spinner = FindViewById<Spinner> (Resource.Id.tap_test_spinner);

            var adapter = ArrayAdapter.CreateFromResource (this, Resource.Array.tap_test_spinner_array, global::Android.Resource.Layout.SimpleSpinnerItem);
            adapter.SetDropDownViewResource (global::Android.Resource.Layout.SimpleSpinnerDropDownItem);
            spinner.Adapter = adapter;
                
            tapButton.Click += (sender, e) => ShowAlert ("Tap Alert", "Tap");
            doubleTapButton.Touch += (sender, e) => doubleTapDetector.OnTouchEvent (e.Event);
            longPressButton.LongClick += (sender, e) => ShowAlert ("LongPress Alert", "LongPress");
            spinner.ItemSelected += (sender, e) => {
                if (!pageLoadSelection) {
                    var selection = spinner.GetItemAtPosition(e.Position);
                    ShowAlert("You chose " + selection, selection.ToString());
                }
                pageLoadSelection = false;
            };
        }
        protected override void OnElementChanged(ElementChangedEventArgs<Frame> e)
        {
            base.OnElementChanged (e);

            _frame = e.NewElement as GesturedFrame;
            _gestureDetector = new GestureDetector (new InternalGestureCapture (_frame));

            this.ChildViewAdded += (object sender, ChildViewAddedEventArgs e2) => {
                e2.Child.Touch += (object sender2, TouchEventArgs e3) => _gestureDetector.OnTouchEvent (e3.Event);
            };
        }