| 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 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 | 267 |
| 268 HTMLMapElement* LayoutImage::imageMap() const | 268 HTMLMapElement* LayoutImage::imageMap() const |
| 269 { | 269 { |
| 270 HTMLImageElement* i = isHTMLImageElement(node()) ? toHTMLImageElement(node()
) : 0; | 270 HTMLImageElement* i = isHTMLImageElement(node()) ? toHTMLImageElement(node()
) : 0; |
| 271 return i ? i->treeScope().getImageMap(i->fastGetAttribute(usemapAttr)) : 0; | 271 return i ? i->treeScope().getImageMap(i->fastGetAttribute(usemapAttr)) : 0; |
| 272 } | 272 } |
| 273 | 273 |
| 274 bool LayoutImage::nodeAtPoint(HitTestResult& result, const HitTestLocation& loca
tionInContainer, const LayoutPoint& accumulatedOffset, HitTestAction hitTestActi
on) | 274 bool LayoutImage::nodeAtPoint(HitTestResult& result, const HitTestLocation& loca
tionInContainer, const LayoutPoint& accumulatedOffset, HitTestAction hitTestActi
on) |
| 275 { | 275 { |
| 276 HitTestResult tempResult(result.hitTestRequest(), result.hitTestLocation()); | 276 HitTestResult tempResult(result.hitTestRequest(), result.hitTestLocation()); |
| 277 tempResult.setValidityRect(result.validityRect()); |
| 277 bool inside = LayoutReplaced::nodeAtPoint(tempResult, locationInContainer, a
ccumulatedOffset, hitTestAction); | 278 bool inside = LayoutReplaced::nodeAtPoint(tempResult, locationInContainer, a
ccumulatedOffset, hitTestAction); |
| 278 | 279 |
| 279 if (!inside && result.hitTestRequest().listBased()) | 280 if (!inside && result.hitTestRequest().listBased()) |
| 280 result.append(tempResult); | 281 result.append(tempResult); |
| 281 if (inside) | 282 if (inside) |
| 282 result = tempResult; | 283 result = tempResult; |
| 283 return inside; | 284 return inside; |
| 284 } | 285 } |
| 285 | 286 |
| 286 void LayoutImage::layout() | 287 void LayoutImage::layout() |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 353 return nullptr; | 354 return nullptr; |
| 354 | 355 |
| 355 ImageResource* cachedImage = m_imageResource->cachedImage(); | 356 ImageResource* cachedImage = m_imageResource->cachedImage(); |
| 356 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage(
)) | 357 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage(
)) |
| 357 return toSVGImage(cachedImage->image())->embeddedContentBox(); | 358 return toSVGImage(cachedImage->image())->embeddedContentBox(); |
| 358 | 359 |
| 359 return nullptr; | 360 return nullptr; |
| 360 } | 361 } |
| 361 | 362 |
| 362 } // namespace blink | 363 } // namespace blink |
| OLD | NEW |