Bug 1587469 - Remove MinGW conditionals for IDCompositionDesktopDevice/IDCompositionDevice2 r=sotaro

Differential Revision: https://phabricator.services.mozilla.com/D55998

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Tom Ritter 2019-12-10 15:38:20 +00:00
Родитель f85cc45712
Коммит 00d9d1fdc5
4 изменённых файлов: 0 добавлений и 51 удалений

Просмотреть файл

@ -308,9 +308,6 @@ bool DeviceManagerDx::CreateCanvasDevice() {
}
void DeviceManagerDx::CreateDirectCompositionDevice() {
// Currently, MinGW build environment does not handle IDCompositionDesktopDevice
// and IDCompositionDevice2
#if !defined(__MINGW32__)
if (!gfxVars::UseWebRenderDCompWin()) {
return;
}
@ -350,7 +347,6 @@ void DeviceManagerDx::CreateDirectCompositionDevice() {
}
mDirectCompositionDevice = compositionDevice;
#endif
}
void DeviceManagerDx::ImportDeviceInfo(const D3D11DeviceStatus& aDeviceStatus) {
@ -1142,13 +1138,10 @@ RefPtr<ID3D11Device> DeviceManagerDx::GetCanvasDevice() {
return mCanvasDevice;
}
// Currently, MinGW build environment does not handle IDCompositionDevice2
#if !defined(__MINGW32__)
RefPtr<IDCompositionDevice2> DeviceManagerDx::GetDirectCompositionDevice() {
MutexAutoLock lock(mDeviceLock);
return mDirectCompositionDevice;
}
#endif
unsigned DeviceManagerDx::GetCompositorFeatureLevel() const {
if (!mDeviceStatus) {
@ -1230,12 +1223,7 @@ bool DeviceManagerDx::CanUseP016() {
bool DeviceManagerDx::CanUseDComp() {
MutexAutoLock lock(mDeviceLock);
// Currently, MinGW build environment does not handle IDCompositionDevice2
#if !defined(__MINGW32__)
return !!mDirectCompositionDevice;
#else
return false;
#endif
}
void DeviceManagerDx::InitializeDirectDraw() {

Просмотреть файл

@ -59,10 +59,7 @@ class DeviceManagerDx final {
RefPtr<ID3D11Device> GetContentDevice();
RefPtr<ID3D11Device> GetCanvasDevice();
RefPtr<ID3D11Device> GetImageDevice();
// Currently, MinGW build environment does not handle IDCompositionDevice2
#if !defined(__MINGW32__)
RefPtr<IDCompositionDevice2> GetDirectCompositionDevice();
#endif
RefPtr<ID3D11Device> GetVRDevice();
RefPtr<ID3D11Device> CreateDecoderDevice();
RefPtr<layers::MLGDevice> GetMLGDevice();
@ -175,9 +172,7 @@ class DeviceManagerDx final {
RefPtr<ID3D11Device> mImageDevice;
RefPtr<ID3D11Device> mVRDevice;
RefPtr<ID3D11Device> mDecoderDevice;
#if !defined(__MINGW32__)
RefPtr<IDCompositionDevice2> mDirectCompositionDevice;
#endif
RefPtr<layers::DeviceAttachmentsD3D11> mCompositorAttachments;
RefPtr<layers::MLGDevice> mMLGDevice;
bool mCompositorDeviceSupportsVideo;

Просмотреть файл

@ -23,10 +23,6 @@
namespace mozilla {
namespace wr {
// Currently, MinGW build environment does not handle IDCompositionDesktopDevice
// and IDCompositionDevice2
#if !defined(__MINGW32__)
/* static */
UniquePtr<DCLayerTree> DCLayerTree::Create(gl::GLContext* aGL,
EGLConfig aEGLConfig,
@ -489,6 +485,5 @@ void DCLayer::EndDraw() {
DestroyEGLSurface();
}
#endif
} // namespace wr
} // namespace mozilla

Просмотреть файл

@ -32,10 +32,6 @@ class GLContext;
namespace wr {
// Currently, MinGW build environment does not handle IDCompositionDesktopDevice
// and IDCompositionDevice2
#if !defined(__MINGW32__)
class DCLayer;
/**
@ -156,31 +152,6 @@ class DCLayer {
RefPtr<IDCompositionVisual2> mVisual;
};
#else
class DCLayerTree {
public:
static UniquePtr<DCLayerTree> Create(gl::GLContext* aGL, EGLConfig aEGLConfig,
ID3D11Device* aDevice, HWND aHwnd) {
return nullptr;
}
void SetDefaultSwapChain(IDXGISwapChain1* aSwapChain) {}
void MaybeUpdateDebug() {}
void WaitForCommitCompletion() {}
// Interface for wr::Compositor
void CompositorBeginFrame() {}
void CompositorEndFrame() {}
void Bind(wr::NativeSurfaceId aId, wr::DeviceIntPoint* aOffset,
uint32_t* aFboId, wr::DeviceIntRect aDirtyRect) {}
void Unbind() {}
void CreateSurface(wr::NativeSurfaceId aId, wr::DeviceIntSize aSize,
bool aIsOpaque) {}
void DestroySurface(NativeSurfaceId aId) {}
void AddSurface(wr::NativeSurfaceId aId, wr::DeviceIntPoint aPosition,
wr::DeviceIntRect aClipRect) {}
};
#endif
} // namespace wr
} // namespace mozilla