OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
5 * (C) 2006 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2006 Allan Sandfeld Jensen (kde@carewolf.com) |
6 * (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 6 * (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. | 7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. |
8 * Copyright (C) 2010 Google Inc. All rights reserved. | 8 * Copyright (C) 2010 Google Inc. All rights reserved. |
9 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved. | 9 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved. |
10 * | 10 * |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
544 return; | 544 return; |
545 | 545 |
546 if (isHTMLInputElement(*node())) | 546 if (isHTMLInputElement(*node())) |
547 m_altText = toHTMLInputElement(node())->altText(); | 547 m_altText = toHTMLInputElement(node())->altText(); |
548 else if (isHTMLImageElement(*node())) | 548 else if (isHTMLImageElement(*node())) |
549 m_altText = toHTMLImageElement(node())->altText(); | 549 m_altText = toHTMLImageElement(node())->altText(); |
550 } | 550 } |
551 | 551 |
552 void RenderImage::layout() | 552 void RenderImage::layout() |
553 { | 553 { |
554 LayoutRect oldContentRect = replacedContentRect(); | |
554 RenderReplaced::layout(); | 555 RenderReplaced::layout(); |
555 updateInnerContentRect(); | 556 if (replacedContentRect() != oldContentRect) { |
557 setShouldDoFullPaintInvalidation(true); | |
558 updateInnerContentRect(); | |
559 } | |
556 } | 560 } |
557 | 561 |
558 bool RenderImage::updateImageLoadingPriorities() | 562 bool RenderImage::updateImageLoadingPriorities() |
559 { | 563 { |
560 if (!m_imageResource || !m_imageResource->cachedImage() || m_imageResource-> cachedImage()->isLoaded()) | 564 if (!m_imageResource || !m_imageResource->cachedImage() || m_imageResource-> cachedImage()->isLoaded()) |
561 return false; | 565 return false; |
562 | 566 |
563 LayoutRect viewBounds = viewRect(); | 567 LayoutRect viewBounds = viewRect(); |
564 LayoutRect objectBounds = absoluteContentBox(); | 568 LayoutRect objectBounds = absoluteContentBox(); |
565 | 569 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
618 if (!m_imageResource) | 622 if (!m_imageResource) |
619 return 0; | 623 return 0; |
620 | 624 |
621 ImageResource* cachedImage = m_imageResource->cachedImage(); | 625 ImageResource* cachedImage = m_imageResource->cachedImage(); |
622 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( )) | 626 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( )) |
623 return toSVGImage(cachedImage->image())->embeddedContentBox(); | 627 return toSVGImage(cachedImage->image())->embeddedContentBox(); |
624 | 628 |
625 return 0; | 629 return 0; |
626 } | 630 } |
627 | 631 |
632 | |
leviw_travelin_and_unemployed
2014/08/11 22:09:26
Nit: remove
Xianzhu
2014/08/11 22:25:16
Done.
| |
628 } // namespace blink | 633 } // namespace blink |
OLD | NEW |