Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(743)

Unified Diff: webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc

Issue 2852783002: Revert of Allow Windows to return a monitor out of the first quadrant (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 5947daf5dcccf8d8786e6d7c390721cbbc7468e8..caef1c2ca7b67c802b73040fd8f5337488187150 100644
--- a/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
+++ b/webrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc
@@ -25,7 +25,8 @@
namespace {
bool IsValidRect(const RECT& rect) {
- return rect.right > rect.left && rect.bottom > rect.top;
+ return rect.left >= 0 && rect.top >= 0 && rect.right > rect.left &&
+ rect.bottom > rect.top;
}
} // namespace
@@ -152,12 +153,4 @@
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

Powered by Google App Engine
This is Rietveld 408576698