DTG: Enable by default on Windows

This commit is contained in:
zzz
2016-09-24 14:54:30 +00:00
parent 1376237e08
commit b123720fa3
2 changed files with 8 additions and 3 deletions

View File

@ -281,8 +281,10 @@ public class RouterConsoleRunner implements RouterApp {
return;
}
try {
// default false for now
boolean desktopguiEnabled = _context.getBooleanProperty(PROP_DTG_ENABLED);
// default false for now, except on non-service windows
String sdtg = _context.getProperty(PROP_DTG_ENABLED);
boolean desktopguiEnabled = Boolean.parseBoolean(sdtg) ||
(sdtg == null && SystemVersion.isWindows());
if (desktopguiEnabled) {
//Check if we are in a headless environment, set properties accordingly
System.setProperty("java.awt.headless", Boolean.toString(GraphicsEnvironment.isHeadless()));