[Xwt] If the native window is null, return null
This is a more logical behaviour and prevents us from hitting silly null reference exceptions later on in the apps lifespan. This probably explains some mysterious null reference exceptions we've been seeing for the last few weeks.
This commit is contained in:
Родитель
754b15c626
Коммит
80bf8fb35d
|
@ -88,6 +88,8 @@ namespace Xwt.Engine
|
|||
|
||||
public static WindowFrame WrapWindow (object nativeWindow)
|
||||
{
|
||||
if (nativeWindow == null)
|
||||
return null;
|
||||
return new NativeWindowFrame (Application.EngineBackend.GetBackendForWindow (nativeWindow));
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче