GeezerVison is showing github.com — Fixed rare "No such proxy method" error for native callback functions · yasirkula/UnityNativeFilePicker@c1b54d8
File treeExpand file treeCollapse file tree Open diff view settings Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: Plugins/NativeFilePicker/Android/FPPermissionCallbackAndroid.cs +2Lines changed: 2 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -15,6 +15,7 @@ public FPPermissionCallbackAndroid( object threadLock ) : base( "com.yasirkula.u | 15 | 15 | this.threadLock = threadLock; | 16 | 16 | } | 17 | 17 |
| | 18 | + [UnityEngine.Scripting.Preserve] | 18 | 19 | public void OnPermissionResult( int result ) | 19 | 20 | { | 20 | 21 | Result = result; | @@ -37,6 +38,7 @@ public FPPermissionCallbackAsyncAndroid( NativeFilePicker.PermissionCallback cal | 37 | 38 | callbackHelper = new GameObject( "FPCallbackHelper" ).AddComponent<FPCallbackHelper>(); | 38 | 39 | } | 39 | 40 |
| | 41 | + [UnityEngine.Scripting.Preserve] | 40 | 42 | public void OnPermissionResult( int result ) | 41 | 43 | { | 42 | 44 | callbackHelper.CallOnMainThread( () => callback( (NativeFilePicker.Permission) result ) ); | |
Collapse file Copy file name to clipboardExpand all lines: Plugins/NativeFilePicker/Android/FPResultCallbackAndroid.cs +3Lines changed: 3 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -20,11 +20,13 @@ public FPResultCallbackAndroid( NativeFilePicker.FilePickedCallback pickCallback | 20 | 20 | callbackHelper = new GameObject( "FPCallbackHelper" ).AddComponent<FPCallbackHelper>(); | 21 | 21 | } | 22 | 22 |
| | 23 | + [UnityEngine.Scripting.Preserve] | 23 | 24 | public void OnFilePicked( string path ) | 24 | 25 | { | 25 | 26 | callbackHelper.CallOnMainThread( () => pickCallback( !string.IsNullOrEmpty( path ) ? path : null ) ); | 26 | 27 | } | 27 | 28 |
| | 29 | + [UnityEngine.Scripting.Preserve] | 28 | 30 | public void OnMultipleFilesPicked( string paths ) | 29 | 31 | { | 30 | 32 | string[] result = null; | @@ -59,6 +61,7 @@ public void OnMultipleFilesPicked( string paths ) | 59 | 61 | callbackHelper.CallOnMainThread( () => pickCallbackMultiple( ( result != null && result.Length > 0 ) ? result : null ) ); | 60 | 62 | } | 61 | 63 |
| | 64 | + [UnityEngine.Scripting.Preserve] | 62 | 65 | public void OnFilesExported( bool result ) | 63 | 66 | { | 64 | 67 | callbackHelper.CallOnMainThread( () => exportCallback( result ) ); | |
Collapse file Copy file name to clipboardExpand all lines: Plugins/NativeFilePicker/README.txt +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 1 | | -= Native File Picker for Android & iOS (v1.3.3) = | | 1 | += Native File Picker for Android & iOS (v1.3.4) = | 2 | 2 |
| 3 | 3 | Documentation: https://github.com/yasirkula/UnityNativeFilePicker | 4 | 4 | FAQ: https://github.com/yasirkula/UnityNativeFilePicker#faq | |
Collapse file Copy file name to clipboardExpand all lines: Plugins/NativeFilePicker/iOS/FPResultCallbackiOS.cs +4Lines changed: 4 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -51,6 +51,7 @@ private void Update() | 51 | 51 | } | 52 | 52 | } | 53 | 53 |
| | 54 | + [UnityEngine.Scripting.Preserve] | 54 | 55 | public void OnFilePicked( string path ) | 55 | 56 | { | 56 | 57 | IsBusy = false; | @@ -65,6 +66,7 @@ public void OnFilePicked( string path ) | 65 | 66 | _pickCallback( path ); | 66 | 67 | } | 67 | 68 |
| | 69 | + [UnityEngine.Scripting.Preserve] | 68 | 70 | public void OnMultipleFilesPicked( string paths ) | 69 | 71 | { | 70 | 72 | IsBusy = false; | @@ -80,6 +82,7 @@ public void OnMultipleFilesPicked( string paths ) | 80 | 82 | _pickCallbackMultiple( _paths ); | 81 | 83 | } | 82 | 84 |
| | 85 | + [UnityEngine.Scripting.Preserve] | 83 | 86 | public void OnFilesExported( string message ) | 84 | 87 | { | 85 | 88 | IsBusy = false; | @@ -91,6 +94,7 @@ public void OnFilesExported( string message ) | 91 | 94 | _exportCallback( message == "1" ); | 92 | 95 | } | 93 | 96 |
| | 97 | + [UnityEngine.Scripting.Preserve] | 94 | 98 | public void OnOperationCancelled( string message ) | 95 | 99 | { | 96 | 100 | IsBusy = false; | |
Collapse file Copy file name to clipboardExpand all lines: package.json +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 1 | 1 | { | 2 | 2 | "name": "com.yasirkula.nativefilepicker", | 3 | 3 | "displayName": "Native File Picker", | 4 | | - "version": "1.3.3", | | 4 | + "version": "1.3.4", | 5 | 5 | "documentationUrl": "https://github.com/yasirkula/UnityNativeFilePicker", | 6 | 6 | "changelogUrl": "https://github.com/yasirkula/UnityNativeFilePicker/releases", | 7 | 7 | "licensesUrl": "https://github.com/yasirkula/UnityNativeFilePicker/blob/master/LICENSE.txt", | |
|