Commit 2676fac9 by Cooper Partin Committed by Geoff Lang

Fixed invalid IsWindow( ) call for WinRT Windows Store applications.

Change-Id: Ic5f2aca0100a842be193cec9e89872187742f2c6 Reviewed-on: https://chromium-review.googlesource.com/238821Tested-by: 's avatarCooper Partin <coopp@microsoft.com> Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
parent cd1db9e6
......@@ -72,7 +72,7 @@ egl::Error DisplayD3D::restoreLostDevice()
bool DisplayD3D::isValidNativeWindow(EGLNativeWindowType window) const
{
return (IsWindow(window) == TRUE);
return NativeWindow::isValidNativeWindow(window);
}
}
......@@ -54,6 +54,7 @@ class NativeWindow
bool initialize();
bool getClientRect(LPRECT rect);
bool isIconic();
static bool isValidNativeWindow(EGLNativeWindowType window);
HRESULT createSwapChain(ID3D11Device* device, DXGIFactory* factory,
DXGI_FORMAT format, UINT width, UINT height,
......
......@@ -32,6 +32,11 @@ bool NativeWindow::isIconic()
return IsIconic(mWindow) == TRUE;
}
bool NativeWindow::isValidNativeWindow(EGLNativeWindowType window)
{
return IsWindow(window) == TRUE;
}
HRESULT NativeWindow::createSwapChain(ID3D11Device* device, DXGIFactory* factory,
DXGI_FORMAT format, unsigned int width, unsigned int height,
DXGISwapChain** swapChain)
......
......@@ -74,6 +74,11 @@ bool NativeWindow::isIconic()
return false;
}
bool NativeWindow::isValidNativeWindow(EGLNativeWindowType window)
{
return IsValidEGLNativeWindowType(window);
}
HRESULT NativeWindow::createSwapChain(ID3D11Device *device, DXGIFactory *factory, DXGI_FORMAT format, unsigned int width, unsigned int height, DXGISwapChain **swapChain)
{
if (mImpl)
......
......@@ -82,6 +82,7 @@ protected:
EventRegistrationToken mSizeChangedEventToken;
};
bool IsValidEGLNativeWindowType(EGLNativeWindowType window);
bool IsCoreWindow(EGLNativeWindowType window, ComPtr<ABI::Windows::UI::Core::ICoreWindow> *coreWindow = nullptr);
bool IsSwapChainPanel(EGLNativeWindowType window, ComPtr<ABI::Windows::UI::Xaml::Controls::ISwapChainPanel> *swapChainPanel = nullptr);
bool IsEGLConfiguredPropertySet(EGLNativeWindowType window, ABI::Windows::Foundation::Collections::IPropertySet **propertySet = nullptr, IInspectable **inspectable = nullptr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment