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

Unified Diff: cc/tiles/software_image_decode_controller.h

Issue 2286583002: Make cc::SoftwareImageDecodeController, cc::ResourcePool, and cc::StagingBufferPoo… (Closed)
Patch Set: Patch for landing Created 4 years, 3 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
« no previous file with comments | « cc/tiles/gpu_image_decode_controller.cc ('k') | cc/tiles/software_image_decode_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/tiles/software_image_decode_controller.h
diff --git a/cc/tiles/software_image_decode_controller.h b/cc/tiles/software_image_decode_controller.h
index 700913e9240c21452a957132837728d714e2adbe..d34fd1a52280b216029372b408d257e181f28c53 100644
--- a/cc/tiles/software_image_decode_controller.h
+++ b/cc/tiles/software_image_decode_controller.h
@@ -15,6 +15,7 @@
#include "base/containers/mru_cache.h"
#include "base/hash.h"
#include "base/memory/discardable_memory_allocator.h"
+#include "base/memory/memory_coordinator_client.h"
#include "base/memory/ref_counted.h"
#include "base/numerics/safe_math.h"
#include "base/threading/thread_checker.h"
@@ -102,7 +103,8 @@ struct ImageDecodeControllerKeyHash {
class CC_EXPORT SoftwareImageDecodeController
: public ImageDecodeController,
- public base::trace_event::MemoryDumpProvider {
+ public base::trace_event::MemoryDumpProvider,
+ public base::MemoryCoordinatorClient {
public:
using ImageKey = ImageDecodeControllerKey;
using ImageKeyHash = ImageDecodeControllerKeyHash;
@@ -264,6 +266,9 @@ class CC_EXPORT SoftwareImageDecodeController
const char* cache_name,
base::trace_event::ProcessMemoryDump* pmd) const;
+ // Overriden from base::MemoryCoordinatorClient.
+ void OnMemoryStateChange(base::MemoryState state) override;
+
std::unordered_map<ImageKey, scoped_refptr<TileTask>, ImageKeyHash>
pending_image_tasks_;
« no previous file with comments | « cc/tiles/gpu_image_decode_controller.cc ('k') | cc/tiles/software_image_decode_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698