Issue with Finger Panning in Windows WPF

2132
12
12-29-2023 02:01 PM
deeprey
Emerging Contributor

Hello Esri Community,

I'm currently developing a WPF application using the ArcGIS Runtime SDK for .NET and have encountered an issue with the map's touch interactions. While the map supports zooming in and out using a two-finger pinch gesture, I'm unable to pan the map using a single finger drag gesture.

Here's a brief overview of the issue:

  • SDK Version: 200.3.0
  • Platform: WPF application
  • Device/OS: touch screen Panel PC [Windows 10 pro]

I've tested this behaviour in both my application and the ARGIS MAPS SDK Samples app. The zooming functionality works perfectly, but panning does not seem to be responsive to touch.

I would appreciate any insights or suggestions on the following:

  1. Are there specific settings or configurations within the ArcGIS Runtime SDK that I might be missing to enable one-finger panning?
  2. Has anyone else experienced similar issues with touch gestures in WPF applications using the ArcGIS Runtime SDK?
  3. Are there known limitations or device-specific considerations that I should be aware of?

Any advice or guidance from the community would be immensely helpful. Thank you in advance for your time and assistance!

12 Replies
ZachRuiz
Occasional Contributor

I was just pulling up the forums to see if anyone else was having this issue. I haven't spent much time on figuring out the issue but my gut is telling me it happened when I updated from .net framework to .net8. It was working perfectly on .NET Framework

0 Kudos
deeprey
Emerging Contributor

New Development: We've now tested the same functionality on a Microsoft Surface Pro 8 and encountered the identical problem. This suggests that the issue is likely at the Runtime SDK for .NET in a WPF application, rather than being device-specific.

Considering this, I have a few requests and questions for the community, especially for any official Esri forum members:

Bug Reporting and Escalation for Fixing: If any official Esri forum members are reading this, could you assist in escalating this issue for potential fixing in the next SDK release? Your intervention could be vital for a timely resolution.

Thank you once again for your time and support in resolving this matter.

ZachRuiz
Occasional Contributor

I agree, this needs to be escalated. 

pshearon
Emerging Contributor

Ditto, was working also in .NET 7 but now in .NET 8  it is not working, all other finger gestures seem to work accept for scrolling the map. Stylus works. As of now I have no work around for this in code. This needs to be escalated.

pshearon
Emerging Contributor

Update: If you hold your finger down, the magnifier will appear and then panning will work. So this is a workaround for now IMO.

0 Kudos
PreetiMaske
Esri Regular Contributor

Thanks for reporting the issue. We have logged the bug in our bug tracking system as high priority. 

0 Kudos
dotMorten_esri
Esri Notable Contributor

We've identified the issue, and working on fixing this. As a workaround, you can add the following code to get pan working again:

 

    public partial class MainWindow : Window
    {
        private readonly MapViewAutomationPeer peer;
        public MainWindow()
        {
            InitializeComponent();
            peer = new MapViewAutomationPeer(MyMapView);
            MyMapView.ManipulationDelta += MyMapView_ManipulationDelta;
        }

        private void MyMapView_ManipulationDelta(object? sender, ManipulationDeltaEventArgs e)
        {
            if (e.DeltaManipulation.Translation.X != 0 || e.DeltaManipulation.Translation.Y != 0)
                peer.Pan(e.DeltaManipulation.Translation.X, e.DeltaManipulation.Translation.Y);
        }
    }

 

This should get pan working again. I did notice this leaves an issue with the new GeometryEditor not responding to drag, but if you're not using that, the above should get you going for now until an update with the fix is provided. 

0 Kudos
BrianHennessey1
Occasional Contributor

Is there an ETA for this fix? And will the workaround above need to be removed when it's fixed? 

If so, this is 2 additional deployments we need to do to all our remote computers. This is a fairly large issue to have in a production API.

 

0 Kudos
PreetiMaske
Esri Regular Contributor
The fix is planned for upcoming 200.4 release in mid April.
0 Kudos