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

Side by Side Diff: third_party/WebKit/WebCore/rendering/RenderLayer.h

Issue 39293: WebKit merge 41447:41498 [third_party/WebKit] (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: remove CRLF Created 11 years, 9 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003 Apple Computer, Inc. 2 * Copyright (C) 2003 Apple Computer, Inc.
3 * 3 *
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Robert O'Callahan <roc+@cs.cmu.edu> 7 * Robert O'Callahan <roc+@cs.cmu.edu>
8 * David Baron <dbaron@fas.harvard.edu> 8 * David Baron <dbaron@fas.harvard.edu>
9 * Christian Biesinger <cbiesinger@web.de> 9 * Christian Biesinger <cbiesinger@web.de>
10 * Randall Jesup <rjesup@wgate.com> 10 * Randall Jesup <rjesup@wgate.com>
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
394 void setNeedsFullRepaint(bool f = true) { m_needsFullRepaint = f; } 394 void setNeedsFullRepaint(bool f = true) { m_needsFullRepaint = f; }
395 395
396 int staticX() const { return m_staticX; } 396 int staticX() const { return m_staticX; }
397 int staticY() const { return m_staticY; } 397 int staticY() const { return m_staticY; }
398 void setStaticX(int staticX) { m_staticX = staticX; } 398 void setStaticX(int staticX) { m_staticX = staticX; }
399 void setStaticY(int staticY); 399 void setStaticY(int staticY);
400 400
401 bool hasTransform() const { return renderer()->hasTransform(); } 401 bool hasTransform() const { return renderer()->hasTransform(); }
402 // Note that this transform has the transform-origin baked in. 402 // Note that this transform has the transform-origin baked in.
403 TransformationMatrix* transform() const { return m_transform.get(); } 403 TransformationMatrix* transform() const { return m_transform.get(); }
404 // currentTransform computes a transform which takes accelerated animations into account. The
405 // resulting transform has transform-origin baked in. If the layer does not have a transform,
406 // returns the identity matrix.
407 TransformationMatrix currentTransform() const;
408
404 // Get the perspective transform, which is applied to transformed sublayers. 409 // Get the perspective transform, which is applied to transformed sublayers.
405 // Returns true if the layer has a -webkit-perspective. 410 // Returns true if the layer has a -webkit-perspective.
406 // Note that this transform has the perspective-origin baked in. 411 // Note that this transform has the perspective-origin baked in.
407 TransformationMatrix perspectiveTransform() const; 412 TransformationMatrix perspectiveTransform() const;
408 FloatPoint perspectiveOrigin() const; 413 FloatPoint perspectiveOrigin() const;
409 bool preserves3D() const { return renderer()->style()->transformStyle3D() == TransformStyle3DPreserve3D; } 414 bool preserves3D() const { return renderer()->style()->transformStyle3D() == TransformStyle3DPreserve3D; }
410 bool has3DTransform() const { return m_transform && !m_transform->isAffine() ; } 415 bool has3DTransform() const { return m_transform && !m_transform->isAffine() ; }
411 416
412 void destroy(RenderArena*);
413
414 // Overloaded new operator. Derived classes must override operator new 417 // Overloaded new operator. Derived classes must override operator new
415 // in order to allocate out of the RenderArena. 418 // in order to allocate out of the RenderArena.
416 void* operator new(size_t, RenderArena*) throw(); 419 void* operator new(size_t, RenderArena*) throw();
417 420
418 // Overridden to prevent the normal delete from being called. 421 // Overridden to prevent the normal delete from being called.
419 void operator delete(void*, size_t); 422 void operator delete(void*, size_t);
420 423
421 #if USE(ACCELERATED_COMPOSITING) 424 #if USE(ACCELERATED_COMPOSITING)
422 bool isComposited() const { return m_backing != 0; } 425 bool isComposited() const { return m_backing != 0; }
423 RenderLayerBacking* backing() const { return m_backing.get(); } 426 RenderLayerBacking* backing() const { return m_backing.get(); }
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 void updateResizerStyle(); 510 void updateResizerStyle();
508 511
509 #if USE(ACCELERATED_COMPOSITING) 512 #if USE(ACCELERATED_COMPOSITING)
510 bool hasCompositingDescendant() const { return m_hasCompositingDescendant; } 513 bool hasCompositingDescendant() const { return m_hasCompositingDescendant; }
511 void setHasCompositingDescendant(bool b) { m_hasCompositingDescendant = b; } 514 void setHasCompositingDescendant(bool b) { m_hasCompositingDescendant = b; }
512 #endif 515 #endif
513 516
514 private: 517 private:
515 friend class RenderLayerBacking; 518 friend class RenderLayerBacking;
516 friend class RenderLayerCompositor; 519 friend class RenderLayerCompositor;
520 friend class RenderBoxModelObject;
521
522 // Only safe to call from RenderBoxModelObject::destroyLayer(RenderArena*)
523 void destroy(RenderArena*);
517 524
518 protected: 525 protected:
519 RenderBoxModelObject* m_renderer; 526 RenderBoxModelObject* m_renderer;
520 527
521 RenderLayer* m_parent; 528 RenderLayer* m_parent;
522 RenderLayer* m_previous; 529 RenderLayer* m_previous;
523 RenderLayer* m_next; 530 RenderLayer* m_next;
524 RenderLayer* m_first; 531 RenderLayer* m_first;
525 RenderLayer* m_last; 532 RenderLayer* m_last;
526 533
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
615 RenderScrollbarPart* m_resizer; 622 RenderScrollbarPart* m_resizer;
616 623
617 #if USE(ACCELERATED_COMPOSITING) 624 #if USE(ACCELERATED_COMPOSITING)
618 OwnPtr<RenderLayerBacking> m_backing; 625 OwnPtr<RenderLayerBacking> m_backing;
619 #endif 626 #endif
620 }; 627 };
621 628
622 } // namespace WebCore 629 } // namespace WebCore
623 630
624 #endif // RenderLayer_h 631 #endif // RenderLayer_h
OLDNEW
« no previous file with comments | « third_party/WebKit/WebCore/rendering/RenderBoxModelObject.cpp ('k') | third_party/WebKit/WebCore/rendering/RenderLayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698