How to show Popup/Flyout at clicked item in ListView/GridView in Windows Store App

后端 未结 3 1129
佛祖请我去吃肉
佛祖请我去吃肉 2021-01-05 11:21

I am working on a Windows Store App and would like to show some additional information about an Item that was clicked in ListView or GridView. This information should be sho

3条回答
  •  挽巷
    挽巷 (楼主)
    2021-01-05 11:31

    I've created a solution that works just like the old Windows Phone Toolkit ContextMenuService. The MenuFlyoutService. You can find the source on my blog. Using the service removes the need to subscribe to event handlers wherever you want to show the menu.

    Your DataTemplate would look something like:

    
        
            
                
                
    
                
                
    
                
                
            
        
    
        
    
    

提交回复
热议问题