mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 784739 - Switch from NULL to nullptr in gfx/layers/d3d11/; r=ehsan
--HG-- extra : rebase_source : 9e5625a5318cfb79370c6e944bc9e651822ddd2c
This commit is contained in:
parent
45adea6c72
commit
24af72d1d5
@ -80,7 +80,7 @@ CompositorD3D11::~CompositorD3D11()
|
|||||||
mDevice->GetPrivateData(sDeviceAttachmentsD3D11, &size, &attachments);
|
mDevice->GetPrivateData(sDeviceAttachmentsD3D11, &size, &attachments);
|
||||||
// No LayerManagers left for this device. Clear out interfaces stored which
|
// No LayerManagers left for this device. Clear out interfaces stored which
|
||||||
// hold a reference to the device.
|
// hold a reference to the device.
|
||||||
mDevice->SetPrivateData(sDeviceAttachmentsD3D11, 0, NULL);
|
mDevice->SetPrivateData(sDeviceAttachmentsD3D11, 0, nullptr);
|
||||||
|
|
||||||
delete attachments;
|
delete attachments;
|
||||||
}
|
}
|
||||||
@ -338,7 +338,7 @@ CompositorD3D11::CreateRenderTarget(const gfx::IntRect &aRect,
|
|||||||
D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET);
|
D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET);
|
||||||
|
|
||||||
RefPtr<ID3D11Texture2D> texture;
|
RefPtr<ID3D11Texture2D> texture;
|
||||||
mDevice->CreateTexture2D(&desc, NULL, byRef(texture));
|
mDevice->CreateTexture2D(&desc, nullptr, byRef(texture));
|
||||||
|
|
||||||
RefPtr<CompositingRenderTargetD3D11> rt = new CompositingRenderTargetD3D11(texture);
|
RefPtr<CompositingRenderTargetD3D11> rt = new CompositingRenderTargetD3D11(texture);
|
||||||
rt->SetSize(IntSize(aRect.width, aRect.height));
|
rt->SetSize(IntSize(aRect.width, aRect.height));
|
||||||
@ -360,7 +360,7 @@ CompositorD3D11::CreateRenderTargetFromSource(const gfx::IntRect &aRect,
|
|||||||
D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET);
|
D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET);
|
||||||
|
|
||||||
RefPtr<ID3D11Texture2D> texture;
|
RefPtr<ID3D11Texture2D> texture;
|
||||||
mDevice->CreateTexture2D(&desc, NULL, byRef(texture));
|
mDevice->CreateTexture2D(&desc, nullptr, byRef(texture));
|
||||||
|
|
||||||
RefPtr<CompositingRenderTargetD3D11> rt = new CompositingRenderTargetD3D11(texture);
|
RefPtr<CompositingRenderTargetD3D11> rt = new CompositingRenderTargetD3D11(texture);
|
||||||
rt->SetSize(IntSize(aRect.width, aRect.height));
|
rt->SetSize(IntSize(aRect.width, aRect.height));
|
||||||
@ -658,7 +658,7 @@ CompositorD3D11::UpdateRenderTarget()
|
|||||||
}
|
}
|
||||||
|
|
||||||
mDefaultRT = new CompositingRenderTargetD3D11(nullptr);
|
mDefaultRT = new CompositingRenderTargetD3D11(nullptr);
|
||||||
mDevice->CreateRenderTargetView(backBuf, NULL, byRef(mDefaultRT->mRTView));
|
mDevice->CreateRenderTargetView(backBuf, nullptr, byRef(mDefaultRT->mRTView));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
@ -759,7 +759,7 @@ CompositorD3D11::PaintToTarget()
|
|||||||
|
|
||||||
nsRefPtr<ID3D11Texture2D> readTexture;
|
nsRefPtr<ID3D11Texture2D> readTexture;
|
||||||
|
|
||||||
HRESULT hr = mDevice->CreateTexture2D(&softDesc, NULL, getter_AddRefs(readTexture));
|
HRESULT hr = mDevice->CreateTexture2D(&softDesc, nullptr, getter_AddRefs(readTexture));
|
||||||
mContext->CopyResource(readTexture, backBuf);
|
mContext->CopyResource(readTexture, backBuf);
|
||||||
|
|
||||||
D3D11_MAPPED_SUBRESOURCE map;
|
D3D11_MAPPED_SUBRESOURCE map;
|
||||||
|
@ -50,7 +50,7 @@ CompositingRenderTargetD3D11::CompositingRenderTargetD3D11(ID3D11Texture2D *aTex
|
|||||||
RefPtr<ID3D11Device> device;
|
RefPtr<ID3D11Device> device;
|
||||||
mTextures[0]->GetDevice(byRef(device));
|
mTextures[0]->GetDevice(byRef(device));
|
||||||
|
|
||||||
HRESULT hr = device->CreateRenderTargetView(mTextures[0], NULL, byRef(mRTView));
|
HRESULT hr = device->CreateRenderTargetView(mTextures[0], nullptr, byRef(mRTView));
|
||||||
|
|
||||||
if (FAILED(hr)) {
|
if (FAILED(hr)) {
|
||||||
LOGD3D11("Failed to create RenderTargetView.");
|
LOGD3D11("Failed to create RenderTargetView.");
|
||||||
@ -249,7 +249,7 @@ DeprecatedTextureClientD3D11::ReleaseTexture()
|
|||||||
void
|
void
|
||||||
DeprecatedTextureClientD3D11::ClearDT()
|
DeprecatedTextureClientD3D11::ClearDT()
|
||||||
{
|
{
|
||||||
// An Azure DrawTarget needs to be locked when it gets NULL'ed as this is
|
// An Azure DrawTarget needs to be locked when it gets nullptr'ed as this is
|
||||||
// when it calls EndDraw. This EndDraw should not execute anything so it
|
// when it calls EndDraw. This EndDraw should not execute anything so it
|
||||||
// shouldn't -really- need the lock but the debug layer chokes on this.
|
// shouldn't -really- need the lock but the debug layer chokes on this.
|
||||||
//
|
//
|
||||||
|
Loading…
Reference in New Issue
Block a user