Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1194)

Side by Side Diff: Source/core/layout/LayoutImage.cpp

Issue 869813003: Implement elementsFromPoint (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Cleanup, add a better test for tables Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/layout/Layer.cpp ('k') | Source/core/layout/LayoutPart.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 LayoutRect contentBox = contentBoxRect(); 280 LayoutRect contentBox = contentBoxRect();
281 float scaleFactor = 1 / style()->effectiveZoom(); 281 float scaleFactor = 1 / style()->effectiveZoom();
282 LayoutPoint mapLocation = locationInContainer.point() - toLayoutSize (accumulatedOffset) - locationOffset() - toLayoutSize(contentBox.location()); 282 LayoutPoint mapLocation = locationInContainer.point() - toLayoutSize (accumulatedOffset) - locationOffset() - toLayoutSize(contentBox.location());
283 mapLocation.scale(scaleFactor, scaleFactor); 283 mapLocation.scale(scaleFactor, scaleFactor);
284 284
285 if (map->mapMouseEvent(mapLocation, contentBox.size(), tempResult)) 285 if (map->mapMouseEvent(mapLocation, contentBox.size(), tempResult))
286 tempResult.setInnerNonSharedNode(node()); 286 tempResult.setInnerNonSharedNode(node());
287 } 287 }
288 } 288 }
289 289
290 if (!inside && result.isRectBasedTest()) 290 if (!inside && request.listBased())
291 result.append(tempResult); 291 result.append(tempResult, request);
292 if (inside) 292 if (inside)
293 result = tempResult; 293 result = tempResult;
294 return inside; 294 return inside;
295 } 295 }
296 296
297 void LayoutImage::layout() 297 void LayoutImage::layout()
298 { 298 {
299 LayoutReplaced::layout(); 299 LayoutReplaced::layout();
300 updateInnerContentRect(); 300 updateInnerContentRect();
301 } 301 }
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 return 0; 364 return 0;
365 365
366 ImageResource* cachedImage = m_imageResource->cachedImage(); 366 ImageResource* cachedImage = m_imageResource->cachedImage();
367 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( )) 367 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( ))
368 return toSVGImage(cachedImage->image())->embeddedContentBox(); 368 return toSVGImage(cachedImage->image())->embeddedContentBox();
369 369
370 return 0; 370 return 0;
371 } 371 }
372 372
373 } // namespace blink 373 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/layout/Layer.cpp ('k') | Source/core/layout/LayoutPart.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698