OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 2079 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2090 | 2090 |
2091 Image* image = cachedImage->image(); | 2091 Image* image = cachedImage->image(); |
2092 if (!image || !image->isSVGImage()) | 2092 if (!image || !image->isSVGImage()) |
2093 return 0; | 2093 return 0; |
2094 | 2094 |
2095 SVGImage* svgImage = static_cast<SVGImage*>(image); | 2095 SVGImage* svgImage = static_cast<SVGImage*>(image); |
2096 FrameView* frameView = svgImage->frameView(); | 2096 FrameView* frameView = svgImage->frameView(); |
2097 if (!frameView) | 2097 if (!frameView) |
2098 return 0; | 2098 return 0; |
2099 Frame* frame = frameView->frame(); | 2099 Frame* frame = frameView->frame(); |
2100 if (!frame) | |
2101 return 0; | |
2102 | |
2103 Document* doc = frame->document(); | 2100 Document* doc = frame->document(); |
2104 if (!doc || !doc->isSVGDocument()) | 2101 if (!doc || !doc->isSVGDocument()) |
2105 return 0; | 2102 return 0; |
2106 | 2103 |
2107 SVGSVGElement* rootElement = toSVGDocument(doc)->rootElement(); | 2104 SVGSVGElement* rootElement = toSVGDocument(doc)->rootElement(); |
2108 if (!rootElement) | 2105 if (!rootElement) |
2109 return 0; | 2106 return 0; |
2110 RenderObject* rendererRoot = rootElement->renderer(); | 2107 RenderObject* rendererRoot = rootElement->renderer(); |
2111 if (!rendererRoot) | 2108 if (!rendererRoot) |
2112 return 0; | 2109 return 0; |
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2386 if (label && label->renderer()) { | 2383 if (label && label->renderer()) { |
2387 LayoutRect labelRect = axObjectCache()->getOrCreate(label)->elementR
ect(); | 2384 LayoutRect labelRect = axObjectCache()->getOrCreate(label)->elementR
ect(); |
2388 result.unite(labelRect); | 2385 result.unite(labelRect); |
2389 } | 2386 } |
2390 } | 2387 } |
2391 | 2388 |
2392 return result; | 2389 return result; |
2393 } | 2390 } |
2394 | 2391 |
2395 } // namespace WebCore | 2392 } // namespace WebCore |
OLD | NEW |