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

Unified Diff: cc/test/fake_picture_pile.h

Issue 671653005: SetNeedsRedraw directly when updating a visible tile. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: pinchblurmerge-test: . Created 6 years, 1 month 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
« no previous file with comments | « cc/test/fake_picture_layer.cc ('k') | cc/test/fake_picture_pile.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_picture_pile.h
diff --git a/cc/test/fake_picture_pile.h b/cc/test/fake_picture_pile.h
index e486e3b4cd37c63fb53bc38c13f6c9ababb83622..2d8f4bfb989d56aca32ccfe52c3b94dbc1276823 100644
--- a/cc/test/fake_picture_pile.h
+++ b/cc/test/fake_picture_pile.h
@@ -7,12 +7,20 @@
#include "cc/resources/picture_pile.h"
+namespace base {
+class WaitableEvent;
+}
+
namespace cc {
class FakePicturePile : public PicturePile {
public:
+ FakePicturePile() : playback_allowed_event_(nullptr) {}
~FakePicturePile() override {}
+ // PicturePile overrides.
+ scoped_refptr<RasterSource> CreateRasterSource() const override;
+
using PicturePile::buffer_pixels;
using PicturePile::CanRasterSlowTileCheck;
using PicturePile::Clear;
@@ -37,6 +45,10 @@ class FakePicturePile : public PicturePile {
has_any_recordings_ = has_recordings;
}
+ void SetPlaybackAllowedEvent(base::WaitableEvent* event) {
+ playback_allowed_event_ = event;
+ }
+
TilingData& tiling() { return tiling_; }
bool is_solid_color() const { return is_solid_color_; }
@@ -47,7 +59,11 @@ class FakePicturePile : public PicturePile {
typedef PicturePile::PictureInfo PictureInfo;
typedef PicturePile::PictureMapKey PictureMapKey;
typedef PicturePile::PictureMap PictureMap;
+
+ private:
+ base::WaitableEvent* playback_allowed_event_;
};
+
} // namespace cc
#endif // CC_TEST_FAKE_PICTURE_PILE_H_
« no previous file with comments | « cc/test/fake_picture_layer.cc ('k') | cc/test/fake_picture_pile.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698