summaryrefslogtreecommitdiff
path: root/core/java/android/view/HardwareCanvas.java
diff options
context:
space:
mode:
authorRomain Guy <romainguy@google.com>2012-02-16 19:24:51 -0800
committerRomain Guy <romainguy@google.com>2012-02-17 13:10:00 -0800
commit33f6beb10f98e8ba96250e284876d607055d278d (patch)
tree215fc7d5624b6b41a018374f5d19f7dac84cf72b /core/java/android/view/HardwareCanvas.java
parent445c83c7755fae179cf3328e89307e2775e97a5e (diff)
Record possible clip rejects when recording display lists
This optimization allows us to quickly skip operations that lie entirely outside of the known bounds of a display list. Because of ViewGroup.setClipChildren, we must keep the operations recorded in the display list. setClipChildren(false) is however a very uncommon operation and we will therefore often benefit from this new optimization. Change-Id: I0942c864e55298e6dccd9977d15adefbce3ba3ad
Diffstat (limited to 'core/java/android/view/HardwareCanvas.java')
-rw-r--r--core/java/android/view/HardwareCanvas.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/java/android/view/HardwareCanvas.java b/core/java/android/view/HardwareCanvas.java
index cbdbbde45b70..838c03c96dd7 100644
--- a/core/java/android/view/HardwareCanvas.java
+++ b/core/java/android/view/HardwareCanvas.java
@@ -57,11 +57,14 @@ public abstract class HardwareCanvas extends Canvas {
* @param height The height of the display list.
* @param dirty The dirty region to redraw in the next pass, matters only
* if this method returns true, can be null.
+ * @param flags Optional flags about drawing, see {@link DisplayList} for
+ * the possible flags.
*
* @return True if the content of the display list requires another
* drawing pass (invalidate()), false otherwise
*/
- public abstract boolean drawDisplayList(DisplayList displayList, int width, int height, Rect dirty);
+ public abstract boolean drawDisplayList(DisplayList displayList, int width, int height,
+ Rect dirty, int flags);
/**
* Outputs the specified display list to the log. This method exists for use by