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

Unified Diff: remoting/host/capturer_win.cc

Issue 10799013: Removing unused and private methods remoting::Capturer interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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: remoting/host/capturer_win.cc
diff --git a/remoting/host/capturer_win.cc b/remoting/host/capturer_win.cc
index db48a5dd22d151c9e07d4c85f5c43a7873344be4..a22d9001cb38bbd9fdda042f24fbc59598ab679a 100644
--- a/remoting/host/capturer_win.cc
+++ b/remoting/host/capturer_win.cc
@@ -49,12 +49,8 @@ class CapturerGdi : public Capturer {
// Capturer interface.
virtual void Start(const CursorShapeChangedCallback& callback) OVERRIDE;
virtual void Stop() OVERRIDE;
- virtual void ScreenConfigurationChanged() OVERRIDE;
virtual media::VideoFrame::Format pixel_format() const OVERRIDE;
- virtual void ClearInvalidRegion() OVERRIDE;
virtual void InvalidateRegion(const SkRegion& invalid_region) OVERRIDE;
- virtual void InvalidateScreen(const SkISize& size) OVERRIDE;
- virtual void InvalidateFullScreen() OVERRIDE;
virtual void CaptureInvalidRegion(
const CaptureCompletedCallback& callback) OVERRIDE;
virtual const SkISize& size_most_recent() const OVERRIDE;
@@ -156,7 +152,6 @@ CapturerGdi::CapturerGdi()
current_buffer_(0),
pixel_format_(media::VideoFrame::RGB32),
composition_func_(NULL) {
- ScreenConfigurationChanged();
}
CapturerGdi::~CapturerGdi() {
@@ -166,22 +161,10 @@ media::VideoFrame::Format CapturerGdi::pixel_format() const {
return pixel_format_;
}
-void CapturerGdi::ClearInvalidRegion() {
- helper_.ClearInvalidRegion();
-}
-
void CapturerGdi::InvalidateRegion(const SkRegion& invalid_region) {
helper_.InvalidateRegion(invalid_region);
}
-void CapturerGdi::InvalidateScreen(const SkISize& size) {
- helper_.InvalidateScreen(size);
-}
-
-void CapturerGdi::InvalidateFullScreen() {
- helper_.InvalidateFullScreen();
-}
-
void CapturerGdi::CaptureInvalidRegion(
const CaptureCompletedCallback& callback) {
// Force the system to power-up display hardware, if it has been suspended.
@@ -231,10 +214,6 @@ void CapturerGdi::Stop() {
}
}
-void CapturerGdi::ScreenConfigurationChanged() {
- // We poll for screen configuration changes, so ignore notifications.
-}
-
void CapturerGdi::PrepareCaptureResources() {
// Switch to the desktop receiving user input if different from the current
// one.
@@ -279,7 +258,11 @@ void CapturerGdi::PrepareCaptureResources() {
// may still be reading from them.
if (resource_generation_ != buffers_[current_buffer_].resource_generation) {
AllocateBuffer(current_buffer_);
- InvalidateFullScreen();
+
+ SkRegion region;
+ region.op(SkIRect::MakeSize(helper_.size_most_recent()),
+ SkRegion::kUnion_Op);
+ InvalidateRegion(region);
}
}
@@ -332,7 +315,7 @@ void CapturerGdi::CalculateInvalidRegion() {
if ((current.size != prev.size) ||
(current.bytes_per_pixel != prev.bytes_per_pixel) ||
(current.bytes_per_row != prev.bytes_per_row)) {
- InvalidateScreen(current.size);
+ helper_.InvalidateScreen(current.size);
return;
}

Powered by Google App Engine
This is Rietveld 408576698