| 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) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. |
| (...skipping 2668 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2679 Node* eventTargetNodeForDocument(Document* doc) | 2679 Node* eventTargetNodeForDocument(Document* doc) |
| 2680 { | 2680 { |
| 2681 if (!doc) | 2681 if (!doc) |
| 2682 return 0; | 2682 return 0; |
| 2683 Node* node = doc->focusedElement(); | 2683 Node* node = doc->focusedElement(); |
| 2684 if (!node) | 2684 if (!node) |
| 2685 node = doc->documentElement(); | 2685 node = doc->documentElement(); |
| 2686 return node; | 2686 return node; |
| 2687 } | 2687 } |
| 2688 | 2688 |
| 2689 void Document::adjustFloatQuadsForScrollAndAbsoluteZoom(Vector<FloatQuad>& quads
, RenderObject& renderer) | 2689 // FIXME(sky): Rename and remove RenderObject argument now that we don't have zo
om. |
| 2690 void Document::adjustFloatQuadsForScrollAndAbsoluteZoom(Vector<FloatQuad>& quads
, RenderObject&) |
| 2690 { | 2691 { |
| 2691 if (!view()) | 2692 if (!view()) |
| 2692 return; | 2693 return; |
| 2693 | 2694 |
| 2694 LayoutRect visibleContentRect = view()->visibleContentRect(); | 2695 LayoutRect visibleContentRect = view()->visibleContentRect(); |
| 2695 for (size_t i = 0; i < quads.size(); ++i) { | 2696 for (size_t i = 0; i < quads.size(); ++i) { |
| 2696 quads[i].move(-FloatSize(visibleContentRect.x().toFloat(), visibleConten
tRect.y().toFloat())); | 2697 quads[i].move(-FloatSize(visibleContentRect.x().toFloat(), visibleConten
tRect.y().toFloat())); |
| 2697 adjustFloatQuadForAbsoluteZoom(quads[i], renderer); | |
| 2698 } | 2698 } |
| 2699 } | 2699 } |
| 2700 | 2700 |
| 2701 void Document::adjustFloatRectForScrollAndAbsoluteZoom(FloatRect& rect, RenderOb
ject& renderer) | 2701 // FIXME(sky): Rename and remove RenderObject argument now that we don't have zo
om. |
| 2702 void Document::adjustFloatRectForScrollAndAbsoluteZoom(FloatRect& rect, RenderOb
ject&) |
| 2702 { | 2703 { |
| 2703 if (!view()) | 2704 if (!view()) |
| 2704 return; | 2705 return; |
| 2705 | 2706 |
| 2706 LayoutRect visibleContentRect = view()->visibleContentRect(); | 2707 LayoutRect visibleContentRect = view()->visibleContentRect(); |
| 2707 rect.move(-FloatSize(visibleContentRect.x().toFloat(), visibleContentRect.y(
).toFloat())); | 2708 rect.move(-FloatSize(visibleContentRect.x().toFloat(), visibleContentRect.y(
).toFloat())); |
| 2708 adjustFloatRectForAbsoluteZoom(rect, renderer); | |
| 2709 } | 2709 } |
| 2710 | 2710 |
| 2711 bool Document::hasActiveParser() | 2711 bool Document::hasActiveParser() |
| 2712 { | 2712 { |
| 2713 return m_activeParserCount || (m_parser && m_parser->processingData()); | 2713 return m_activeParserCount || (m_parser && m_parser->processingData()); |
| 2714 } | 2714 } |
| 2715 | 2715 |
| 2716 void Document::decrementActiveParserCount() | 2716 void Document::decrementActiveParserCount() |
| 2717 { | 2717 { |
| 2718 --m_activeParserCount; | 2718 --m_activeParserCount; |
| (...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3002 using namespace blink; | 3002 using namespace blink; |
| 3003 void showLiveDocumentInstances() | 3003 void showLiveDocumentInstances() |
| 3004 { | 3004 { |
| 3005 WeakDocumentSet& set = liveDocumentSet(); | 3005 WeakDocumentSet& set = liveDocumentSet(); |
| 3006 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 3006 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
| 3007 for (WeakDocumentSet::const_iterator it = set.begin(); it != set.end(); ++it
) { | 3007 for (WeakDocumentSet::const_iterator it = set.begin(); it != set.end(); ++it
) { |
| 3008 fprintf(stderr, "- Document %p URL: %s\n", *it, (*it)->url().string().ut
f8().data()); | 3008 fprintf(stderr, "- Document %p URL: %s\n", *it, (*it)->url().string().ut
f8().data()); |
| 3009 } | 3009 } |
| 3010 } | 3010 } |
| 3011 #endif | 3011 #endif |
| OLD | NEW |