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

Unified Diff: cc/resources/prioritized_resource.h

Issue 145313006: [#7] Pass gfx structs by const ref (gfx::Size) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 11 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/resources/picture_pile_base.cc ('k') | cc/resources/prioritized_resource.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/prioritized_resource.h
diff --git a/cc/resources/prioritized_resource.h b/cc/resources/prioritized_resource.h
index 641782e79d98c590259f2ddcae0ca4a2457c4293..cf8df6a0cc52cb7c1f1dffbe87d6eaf025582658 100644
--- a/cc/resources/prioritized_resource.h
+++ b/cc/resources/prioritized_resource.h
@@ -25,7 +25,7 @@ class CC_EXPORT PrioritizedResource {
public:
static scoped_ptr<PrioritizedResource> Create(
PrioritizedResourceManager* manager,
- gfx::Size size,
+ const gfx::Size& size,
ResourceFormat format) {
return make_scoped_ptr(new PrioritizedResource(manager, size, format));
}
@@ -40,7 +40,7 @@ class CC_EXPORT PrioritizedResource {
// Setting these to the same value is a no-op.
void SetTextureManager(PrioritizedResourceManager* manager);
PrioritizedResourceManager* resource_manager() { return manager_; }
- void SetDimensions(gfx::Size size, ResourceFormat format);
+ void SetDimensions(const gfx::Size& size, ResourceFormat format);
ResourceFormat format() const { return format_; }
gfx::Size size() const { return size_; }
size_t bytes() const { return bytes_; }
@@ -107,7 +107,7 @@ class CC_EXPORT PrioritizedResource {
public:
Backing(unsigned id,
ResourceProvider* resource_provider,
- gfx::Size size,
+ const gfx::Size& size,
ResourceFormat format);
~Backing();
void UpdatePriority();
@@ -150,7 +150,7 @@ class CC_EXPORT PrioritizedResource {
};
PrioritizedResource(PrioritizedResourceManager* resource_manager,
- gfx::Size size,
+ const gfx::Size& size,
ResourceFormat format);
bool is_above_priority_cutoff() { return is_above_priority_cutoff_; }
« no previous file with comments | « cc/resources/picture_pile_base.cc ('k') | cc/resources/prioritized_resource.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698