mirror of
https://github.com/mitb-archive/filebot
synced 2024-11-04 16:35:08 -05:00
* default to cross-platform laf used in scripting to nimbus instead of metal (if possible)
This commit is contained in:
parent
92fa4bb410
commit
c0d0022907
@ -93,6 +93,16 @@ public class Main {
|
|||||||
|
|
||||||
// CLI mode => run command-line interface and then exit
|
// CLI mode => run command-line interface and then exit
|
||||||
if (args.runCLI()) {
|
if (args.runCLI()) {
|
||||||
|
// default cross-platform laf used in scripting to nimbus instead of metal (if possible)
|
||||||
|
if (args.script != null) {
|
||||||
|
try {
|
||||||
|
Class<?> nimbusLook = Class.forName("javax.swing.plaf.nimbus.NimbusLookAndFeel", false, Thread.currentThread().getContextClassLoader());
|
||||||
|
System.setProperty("swing.crossplatformlaf", nimbusLook.getName());
|
||||||
|
} catch (Throwable e) {
|
||||||
|
// ignore all errors and stick with default cross-platform laf
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int status = cli.process(args, new CmdlineOperations());
|
int status = cli.process(args, new CmdlineOperations());
|
||||||
System.exit(status);
|
System.exit(status);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user