question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

iOS - ListView inside of Popup no longer firing ItemSelected unless list item is long pressed

See original GitHub issue

I am using a Popup with a ListView and custom ViewCell inside. This was working just fine in version 0.0.9, but since upgrading to 0.0.12 I now have to press the listview item for a few seconds and release in order for ItemSelected to fire. I used to only need to tap the list item quickly.

Again, this worked fine in 0.0.9. Not sure what changed since then. The XAML in my PCL looks like this…

<pages:PopupPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" 
xmlns:pages="clr-namespace:Rg.Plugins.Popup.Pages;assembly=Rg.Plugins.Popup">

<ListView x:Name="ListView" ItemSelected="OnSelection" >
        <ListView.ItemTemplate>
            <DataTemplate>
                    <ViewCell>
                             <StackLayout Orientation="Horizontal" >
                        <Label Text = "{Binding DisplayValue}" ></Label>
                         </StackLayout>
                    </ViewCell>
            </DataTemplate>
        </ListView.ItemTemplate>
</ListView>

</pages:PopupPage>

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:15 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
Amenticommented, Jun 23, 2017

@rotorgames Sorry to have bothered you. The problem is in fact not Rg.Plugins.Popup but the different handling of GestureRecognizers in iOS and Android. When multiple GestureRecognizers are registered iOS seems to favor the last one and Android calls them all. This led to the problem in my case.

1reaction
rotorgamescommented, Mar 21, 2016

@iupchris10 Yes, I can confirm this bug. This is due to the implementation of gestures PopupPageRenderer for ios. Once corrected, I will inform you. Thank you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

long press event on listview items in xamarin forms
I need to implemnet long press event on listview item and need to open a custom popup with listview item details. I tried...
Read more >
Longpress and list scrolling
The problem is that when I set "onLongPressGesture" anywhere in the list (on items, on the list itself), the list cannot be scrolled...
Read more >
Working with ListView in Xamarin ListView (SfListView)
The SfListView allows displaying a pop-up menu with different menu items to an item when it is long pressed by customizing the SfListView...
Read more >
Xamarin.Forms CollectionView Selection
This property has a default binding mode of OneWay , and has a null value when no items are selected. SelectionChangedCommand , of...
Read more >
ListView Interactivity - Xamarin
None indicates that items cannot be selected. When a user taps an item, two events are fired: ItemSelected fires when a new item...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found