File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
src/main/java/io/github/axolotlclient/util Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -34,9 +34,19 @@ public static OperatingSystem getOS() {
3434 }
3535
3636 public enum OperatingSystem {
37- WINDOWS ("win" ),
37+ WINDOWS ("win" ){
38+ @ Override
39+ protected String [] getURLOpenCommand (URL url ) {
40+ return new String []{"rundll32" , "url.dll,FileProtocolHandler" , url .toString ()};
41+ }
42+ },
3843 LINUX ("nix" , "nux" , "aix" ),
39- MAC ("mac" ),
44+ MAC ("mac" ) {
45+ @ Override
46+ protected String [] getURLOpenCommand (URL url ) {
47+ return new String []{"open" , url .toString ()};
48+ }
49+ },
4050 OTHER ();
4151
4252 final String [] s ;
@@ -70,7 +80,7 @@ public void open(URI uri) {
7080
7181 }
7282
73- private String [] getURLOpenCommand (URL url ) {
83+ protected String [] getURLOpenCommand (URL url ) {
7484 String string = url .toString ();
7585 if ("file" .equals (url .getProtocol ())) {
7686 string = string .replace ("file:" , "file://" );
You can’t perform that action at this time.
0 commit comments