Skip to content

Commit

Permalink
修复触发Cancel导致程序崩溃
Browse files Browse the repository at this point in the history
  • Loading branch information
Sanheiii committed Feb 23, 2023
1 parent f65e04a commit 0512826
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Mageki/Mageki.Android/Properties/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="10" android:versionName="2.1.0" package="icu.sanhei.mageki" android:installLocation="auto">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="11" android:versionName="2.1.1" package="icu.sanhei.mageki" android:installLocation="auto">
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="31" />
<application android:label="Mageki" android:theme="@style/MainTheme" android:icon="@mipmap/ic_launcher"></application>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
Expand Down
2 changes: 1 addition & 1 deletion Mageki/Mageki.iOS/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<key>NFCReaderUsageDescription</key>
<string>Read Aime cards with NFC.</string>
<key>CFBundleShortVersionString</key>
<string>2.1.0</string>
<string>2.1.1</string>
<key>CFBundleLocalizations</key>
<array>
<string>en</string>
Expand Down
4 changes: 3 additions & 1 deletion Mageki/Mageki/Drawables/TouchableObject.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using SkiaSharp;

using System.Collections.Generic;
using System.Linq;

using Xamarin.Essentials;

Expand Down Expand Up @@ -42,7 +43,8 @@ public virtual void HandleTouchCancelled(long id)
{
if (DeviceInfo.Platform == DevicePlatform.Android)
{
foreach (var key in touchPoints.Keys)
var keys = touchPoints.Keys.ToArray();
foreach (var key in keys)
{
HandleTouchReleased(key);
}
Expand Down

0 comments on commit 0512826

Please sign in to comment.