Skip to content
This repository was archived by the owner on Feb 4, 2023. It is now read-only.

Commit e10794f

Browse files
committed
Merge branch 'develop'
2 parents c7308fe + e9f09c7 commit e10794f

File tree

2 files changed

+28
-1
lines changed

2 files changed

+28
-1
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
11
.DS_Store
2+
3+
# shc compiler
4+
*.x
5+
*.x.c

README.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,9 +192,23 @@ You can use the Plist key `LSEnvironment` to export and set the `$JAVA_HOME` env
192192
```
193193

194194

195+
Use a compiled binary for macOS 10.15 and above
196+
-----------------------------------------------
197+
198+
Starting with macOS 10.15 Apple by default prevents access to _Protected Resources_ like the user's _Download_, _Documents_ or _Desktop_ folders and shows a security dialog which the user has to accept before access is granted.
199+
200+
When using `javax.swing.JFileChooser` in your application, which supports these kinds of security dialogs (interestingly `java.awt.FileDialog` does not!), you should use a compiled binary of the `universalJavaApplicationStub` script instead of the plain bash script. See [issue #85](https://github.com/tofi86/universalJavaApplicationStub/issues/85) for more details.
201+
202+
Starting with version 3.1.0 we provide pre-built binaries on the [Releases page](https://github.com/tofi86/universalJavaApplicationStub/releases/) which are automatically compiled with [`shc`](https://github.com/neurobin/shc) via GitHub Actions CI.
203+
204+
Additionaly we recommend you set _Usage Description_ Plist keys as described further below.
205+
206+
195207
Recommended additional Plist keys
196208
---------------------------------
197209

210+
### `NSAppleEventsUsageDescription`
211+
198212
Starting with Mac OS 10.14 users may be confronted with an additional system security dialog before any warning dialog of this stub is shown. See [issue #77](https://github.com/tofi86/universalJavaApplicationStub/issues/77) for more details.
199213

200214
This happens because the warning dialogs of this launcher stub are displayed with AppleScript.
@@ -206,7 +220,16 @@ It's recommended to at least set the following Plist key in order to display a d
206220
<string>There was an error while launching the application. Please click OK to display a dialog with more information or cancel and view the syslog for details.</string>
207221
```
208222

209-
The message itself is just a sample...
223+
### Access to "Protected Resources"
224+
225+
If your app requires access to _Protected Resources_ like the user's _Download_, _Documents_ or _Desktop_ folders, there are [a couple more properties](https://developer.apple.com/documentation/bundleresources/information_property_list/protected_resources) to add in your Plist file for setting a _Usage Description_:
226+
227+
* [`NSDownloadsFolderUsageDescription`](https://developer.apple.com/documentation/bundleresources/information_property_list/nsdownloadsfolderusagedescription)
228+
* [`NSDocumentsFolderUsageDescription`](https://developer.apple.com/documentation/bundleresources/information_property_list/nsdocumentsfolderusagedescription)
229+
* [`NSDesktopFolderUsageDescription`](https://developer.apple.com/documentation/bundleresources/information_property_list/nsdesktopfolderusagedescription)
230+
* and maybe more...
231+
232+
This may be extra important when using `javax.swing.JFileChooser` in your application. See [issue #85](https://github.com/tofi86/universalJavaApplicationStub/issues/85) for more details.
210233

211234

212235
Logging

0 commit comments

Comments
 (0)