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) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv
ed. |
7 * Copyright (C) 2009 Google Inc. All rights reserved. | 7 * Copyright (C) 2009 Google Inc. All rights reserved. |
8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 2872 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2883 } | 2883 } |
2884 | 2884 |
2885 Element* RenderObject::offsetParent() const | 2885 Element* RenderObject::offsetParent() const |
2886 { | 2886 { |
2887 if (isDocumentElement() || isBody()) | 2887 if (isDocumentElement() || isBody()) |
2888 return 0; | 2888 return 0; |
2889 | 2889 |
2890 if (isOutOfFlowPositioned() && style()->position() == FixedPosition) | 2890 if (isOutOfFlowPositioned() && style()->position() == FixedPosition) |
2891 return 0; | 2891 return 0; |
2892 | 2892 |
2893 // If A is an area HTML element which has a map HTML element somewhere in th
e ancestor | |
2894 // chain return the nearest ancestor map HTML element and stop this algorith
m. | |
2895 // FIXME: Implement! | |
2896 | |
2897 float effectiveZoom = style()->effectiveZoom(); | 2893 float effectiveZoom = style()->effectiveZoom(); |
2898 Node* node = 0; | 2894 Node* node = 0; |
2899 for (RenderObject* ancestor = parent(); ancestor; ancestor = ancestor->paren
t()) { | 2895 for (RenderObject* ancestor = parent(); ancestor; ancestor = ancestor->paren
t()) { |
2900 // Spec: http://www.w3.org/TR/cssom-view/#offset-attributes | 2896 // Spec: http://www.w3.org/TR/cssom-view/#offset-attributes |
2901 | 2897 |
2902 node = ancestor->node(); | 2898 node = ancestor->node(); |
2903 | 2899 |
2904 if (!node) | 2900 if (!node) |
2905 continue; | 2901 continue; |
2906 | 2902 |
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3145 { | 3141 { |
3146 if (object1) { | 3142 if (object1) { |
3147 const blink::RenderObject* root = object1; | 3143 const blink::RenderObject* root = object1; |
3148 while (root->parent()) | 3144 while (root->parent()) |
3149 root = root->parent(); | 3145 root = root->parent(); |
3150 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); | 3146 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); |
3151 } | 3147 } |
3152 } | 3148 } |
3153 | 3149 |
3154 #endif | 3150 #endif |
OLD | NEW |