Skip to content

Commit b9baa7c

Browse files
committed
Minor fixes and changes
1 parent f73c7d6 commit b9baa7c

4 files changed

Lines changed: 8 additions & 13 deletions

File tree

Assets/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
var StandaloneFileBrowserWebGLPlugin = {
22
// Open file.
3-
// gameObjectNamePtr: GameObject name required for calling back unity side with SendMessage. And it should be unique
4-
// filter(disabled): Filter files. Example filters:
3+
// gameObjectNamePtr: Unique GameObject name. Required for calling back unity with SendMessage.
4+
// methodNamePtr: Callback method name on given GameObject.
5+
// filter: Filter files. Example filters:
56
// Match all image files: "image/*"
67
// Match all video files: "video/*"
78
// Match all audio files: "audio/*"
8-
// Custom: ".plist,.xml,.yaml"
9-
// multiselect(disabled): Allows multiple file selection
9+
// Custom: ".plist, .xml, .yaml"
10+
// multiselect: Allows multiple file selection
1011
UploadFile: function(gameObjectNamePtr, methodNamePtr, filterPtr, multiselect) {
1112
gameObjectName = Pointer_stringify(gameObjectNamePtr);
1213
methodName = Pointer_stringify(methodNamePtr);
@@ -53,13 +54,6 @@ var StandaloneFileBrowserWebGLPlugin = {
5354
}
5455
},
5556

56-
// Open folder. - NOT IMPLEMENTED
57-
UploadFolder: function(gameObjectNamePtr) {
58-
gameObjectName = Pointer_stringify(gameObjectNamePtr);
59-
methodName = Pointer_stringify(methodNamePtr);
60-
SendMessage(gameObjectName, methodName, '');
61-
},
62-
6357
// Save file
6458
// DownloadFile method does not open SaveFileDialog like standalone builds, its just allows user to download file
6559
// gameObjectNamePtr: Unique GameObject name. Required for calling back unity with SendMessage.

Assets/StandaloneFileBrowser/Sample/CanvasSampleOpenFileImage.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public class CanvasSampleOpenFileImage : MonoBehaviour, IPointerDownHandler {
1919
private static extern void UploadFile(string gameObjectName, string methodName, string filter, bool multiple);
2020

2121
public void OnPointerDown(PointerEventData eventData) {
22-
UploadFile(gameObject.name, "OnFileUploadcl", ".png, .jpg", false);
22+
UploadFile(gameObject.name, "OnFileUpload", ".png, .jpg", false);
2323
}
2424

2525
// Called from browser

ProjectSettings/EditorBuildSettings.asset

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ EditorBuildSettings:
88
- enabled: 1
99
path: Assets/StandaloneFileBrowser/Sample/BasicSampleScene.unity
1010
guid: d97280fe82b874466870f709c3315d41
11+
m_configObjects: {}

ProjectSettings/ProjectSettings.asset

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ PlayerSettings:
548548
webGLAnalyzeBuildSize: 0
549549
webGLUseEmbeddedResources: 0
550550
webGLCompressionFormat: 1
551-
webGLLinkerTarget: 1
551+
webGLLinkerTarget: 2
552552
scriptingDefineSymbols: {}
553553
platformArchitecture: {}
554554
scriptingBackend:

0 commit comments

Comments
 (0)