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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.h

Issue 1891473002: WTF: Implement explicit RefPtr::operator bool. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 void setImageBuffer(ImageBuffer*); 108 void setImageBuffer(ImageBuffer*);
109 void didDraw(const FloatRect&); 109 void didDraw(const FloatRect&);
110 bool writePixels(const SkImageInfo&, const void* pixels, size_t rowBytes, in t x, int y); 110 bool writePixels(const SkImageInfo&, const void* pixels, size_t rowBytes, in t x, int y);
111 void flush(); 111 void flush();
112 void flushGpu(); 112 void flushGpu();
113 void prepareSurfaceForPaintingIfNeeded(); 113 void prepareSurfaceForPaintingIfNeeded();
114 bool isHidden() { return m_isHidden; } 114 bool isHidden() { return m_isHidden; }
115 115
116 void beginDestruction(); 116 void beginDestruction();
117 void hibernate(); 117 void hibernate();
118 bool isHibernating() const { return m_hibernationImage; } 118 bool isHibernating() const { return m_hibernationImage.get(); }
119 119
120 PassRefPtr<SkImage> newImageSnapshot(AccelerationHint, SnapshotReason); 120 PassRefPtr<SkImage> newImageSnapshot(AccelerationHint, SnapshotReason);
121 121
122 // The values of the enum entries must not change because they are used for 122 // The values of the enum entries must not change because they are used for
123 // usage metrics histograms. New values can be added to the end. 123 // usage metrics histograms. New values can be added to the end.
124 enum HibernationEvent { 124 enum HibernationEvent {
125 HibernationScheduled = 0, 125 HibernationScheduled = 0,
126 HibernationAbortedDueToDestructionWhileHibernatePending = 1, 126 HibernationAbortedDueToDestructionWhileHibernatePending = 1,
127 HibernationAbortedDueToPendingDestruction = 2, 127 HibernationAbortedDueToPendingDestruction = 2,
128 HibernationAbortedDueToVisibilityChange = 3, 128 HibernationAbortedDueToVisibilityChange = 3,
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 // Each element in this vector represents an IOSurface backed texture that 274 // Each element in this vector represents an IOSurface backed texture that
275 // is ready to be reused. 275 // is ready to be reused.
276 // Elements in this vector can safely be purged in low memory conditions. 276 // Elements in this vector can safely be purged in low memory conditions.
277 Vector<ImageInfo> m_imageInfoCache; 277 Vector<ImageInfo> m_imageInfoCache;
278 #endif // USE_IOSURFACE_FOR_2D_CANVAS 278 #endif // USE_IOSURFACE_FOR_2D_CANVAS
279 }; 279 };
280 280
281 } // namespace blink 281 } // namespace blink
282 282
283 #endif 283 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698