Bug 1022821, part 1 - Stop using a RefPtr for QuartzSupport::AttachIOSurface's aSurface argument. r=BenWa

This commit is contained in:
Jonathan Watt 2014-06-11 23:08:17 +01:00
parent 8fef70114a
commit 4586865399
2 changed files with 2 additions and 5 deletions

View File

@ -53,7 +53,7 @@ public:
* is attached then an internal pixel buffer will be
* used.
*/
void AttachIOSurface(mozilla::RefPtr<MacIOSurface> aSurface);
void AttachIOSurface(MacIOSurface *aSurface);
IOSurfaceID GetIOSurfaceID();
// aX, aY, aWidth and aHeight are in "display pixels". Multiply by
// surf->GetContentsScaleFactor() to get device pixels.

View File

@ -337,12 +337,9 @@ void nsCARenderer::SetViewport(int aWidth, int aHeight) {
::glScalef(1.0, -1.0, 1.0);
}
void nsCARenderer::AttachIOSurface(RefPtr<MacIOSurface> aSurface) {
void nsCARenderer::AttachIOSurface(MacIOSurface *aSurface) {
if (mIOSurface &&
aSurface->GetIOSurfaceID() == mIOSurface->GetIOSurfaceID()) {
// This object isn't needed since we already have a
// handle to the same io surface.
aSurface = nullptr;
return;
}