| Index: webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
|
| diff --git a/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc b/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
|
| index caef1c2ca7b67c802b73040fd8f5337488187150..5947daf5dcccf8d8786e6d7c390721cbbc7468e8 100644
|
| --- a/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
|
| +++ b/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
|
| @@ -25,8 +25,7 @@ using Microsoft::WRL::ComPtr;
|
| namespace {
|
|
|
| bool IsValidRect(const RECT& rect) {
|
| - return rect.left >= 0 && rect.top >= 0 && rect.right > rect.left &&
|
| - rect.bottom > rect.top;
|
| + return rect.right > rect.left && rect.bottom > rect.top;
|
| }
|
|
|
| } // namespace
|
| @@ -153,4 +152,12 @@ int64_t DxgiAdapterDuplicator::GetNumFramesCaptured() const {
|
| return min;
|
| }
|
|
|
| +void DxgiAdapterDuplicator::TranslateRect(const DesktopVector& position) {
|
| + desktop_rect_.Translate(position);
|
| + RTC_DCHECK(desktop_rect_.left() >= 0 && desktop_rect_.top() >= 0);
|
| + for (auto& duplicator : duplicators_) {
|
| + duplicator.TranslateRect(position);
|
| + }
|
| +}
|
| +
|
| } // namespace webrtc
|
|
|