Windows: Display.getVersion should return null when getAdapter() is null
This commit is contained in:
parent
72c0fc81b8
commit
502291c9cb
|
@ -86,7 +86,11 @@ final class Win32Display implements DisplayImplementation {
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getVersion() {
|
public String getVersion() {
|
||||||
return nGetVersion(getAdapter());
|
String driver = getAdapter();
|
||||||
|
if (driver != null)
|
||||||
|
return nGetVersion(driver);
|
||||||
|
else
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
private native String nGetVersion(String driver);
|
private native String nGetVersion(String driver);
|
||||||
public native DisplayMode init() throws LWJGLException;
|
public native DisplayMode init() throws LWJGLException;
|
||||||
|
|
Loading…
Reference in New Issue