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

Unified Diff: cc/priority_calculator.h

Issue 11122003: [cc] Rename all cc/ filenames to Chromium style (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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/prioritized_texture_manager.cc ('k') | cc/priority_calculator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/priority_calculator.h
diff --git a/cc/priority_calculator.h b/cc/priority_calculator.h
index 638cbb270ce9b24689d5095baf174ade4f4d1a13..45f2e64a649bd0944eb496d4b3395976364daf41 100644
--- a/cc/priority_calculator.h
+++ b/cc/priority_calculator.h
@@ -1,3 +1,32 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
+// Copyright 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+
+#ifndef CCPriorityCalculator_h
+#define CCPriorityCalculator_h
+
+#include "GraphicsContext3D.h"
+#include "IntRect.h"
+#include "IntSize.h"
+
+namespace cc {
+
+class CCPriorityCalculator {
+public:
+ static int uiPriority(bool drawsToRootSurface);
+ static int visiblePriority(bool drawsToRootSurface);
+ static int renderSurfacePriority();
+ static int lingeringPriority(int previousPriority);
+ static int priorityFromDistance(const IntRect& visibleRect, const IntRect& textureRect, bool drawsToRootSurface);
+ static int smallAnimatedLayerMinPriority();
+
+ static inline int highestPriority() { return std::numeric_limits<int>::min(); }
+ static inline int lowestPriority() { return std::numeric_limits<int>::max(); }
+ static inline bool priorityIsLower(int a, int b) { return a > b; }
+ static inline bool priorityIsHigher(int a, int b) { return a < b; }
+ static inline bool maxPriority(int a, int b) { return priorityIsHigher(a, b) ? a : b; }
+};
+
+}
+
+#endif
« no previous file with comments | « cc/prioritized_texture_manager.cc ('k') | cc/priority_calculator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698