Chromium Code Reviews| 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 53 #include "core/css/StyleSheetContents.h" | 53 #include "core/css/StyleSheetContents.h" |
| 54 #include "core/css/StyleSheetList.h" | 54 #include "core/css/StyleSheetList.h" |
| 55 #include "core/css/invalidation/StyleInvalidator.h" | 55 #include "core/css/invalidation/StyleInvalidator.h" |
| 56 #include "core/css/parser/CSSParser.h" | 56 #include "core/css/parser/CSSParser.h" |
| 57 #include "core/css/resolver/FontBuilder.h" | 57 #include "core/css/resolver/FontBuilder.h" |
| 58 #include "core/css/resolver/StyleResolver.h" | 58 #include "core/css/resolver/StyleResolver.h" |
| 59 #include "core/css/resolver/StyleResolverStats.h" | 59 #include "core/css/resolver/StyleResolverStats.h" |
| 60 #include "core/dom/AddConsoleMessageTask.h" | 60 #include "core/dom/AddConsoleMessageTask.h" |
| 61 #include "core/dom/Attr.h" | 61 #include "core/dom/Attr.h" |
| 62 #include "core/dom/CDATASection.h" | 62 #include "core/dom/CDATASection.h" |
| 63 #include "core/dom/ClientRect.h" | |
| 63 #include "core/dom/Comment.h" | 64 #include "core/dom/Comment.h" |
| 64 #include "core/dom/ContextFeatures.h" | 65 #include "core/dom/ContextFeatures.h" |
| 65 #include "core/dom/DOMImplementation.h" | 66 #include "core/dom/DOMImplementation.h" |
| 66 #include "core/dom/DocumentFragment.h" | 67 #include "core/dom/DocumentFragment.h" |
| 67 #include "core/dom/DocumentLifecycleNotifier.h" | 68 #include "core/dom/DocumentLifecycleNotifier.h" |
| 68 #include "core/dom/DocumentLifecycleObserver.h" | 69 #include "core/dom/DocumentLifecycleObserver.h" |
| 69 #include "core/dom/DocumentMarkerController.h" | 70 #include "core/dom/DocumentMarkerController.h" |
| 70 #include "core/dom/DocumentType.h" | 71 #include "core/dom/DocumentType.h" |
| 71 #include "core/dom/Element.h" | 72 #include "core/dom/Element.h" |
| 72 #include "core/dom/ElementDataCache.h" | 73 #include "core/dom/ElementDataCache.h" |
| (...skipping 5565 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 5638 TrackExceptionState exceptionState; | 5639 TrackExceptionState exceptionState; |
| 5639 AtomicString selector(metaElementContents.substring(0, firstSemicolon)); | 5640 AtomicString selector(metaElementContents.substring(0, firstSemicolon)); |
| 5640 RefPtrWillBeRawPtr<StaticElementList> elementList = querySelectorAll(sel ector, exceptionState); | 5641 RefPtrWillBeRawPtr<StaticElementList> elementList = querySelectorAll(sel ector, exceptionState); |
| 5641 if (!elementList || exceptionState.hadException()) | 5642 if (!elementList || exceptionState.hadException()) |
| 5642 continue; | 5643 continue; |
| 5643 | 5644 |
| 5644 unsigned nodeListLength = elementList->length(); | 5645 unsigned nodeListLength = elementList->length(); |
| 5645 if (!nodeListLength) | 5646 if (!nodeListLength) |
| 5646 continue; | 5647 continue; |
| 5647 | 5648 |
| 5649 TransitionElementData newElements; | |
| 5648 StringBuilder markup; | 5650 StringBuilder markup; |
| 5649 for (unsigned nodeIndex = 0; nodeIndex < nodeListLength; ++nodeIndex) { | 5651 for (unsigned nodeIndex = 0; nodeIndex < nodeListLength; ++nodeIndex) { |
| 5650 Element* element = elementList->item(nodeIndex); | 5652 Element* element = elementList->item(nodeIndex); |
| 5651 markup.append(createStyledMarkupForNavigationTransition(element)); | 5653 markup.append(createStyledMarkupForNavigationTransition(element)); |
| 5654 newElements.rects.append(element->boundsInRootViewSpace()); | |
| 5655 newElements.names.append(element->getIdAttribute().string()); | |
|
esprehn
2014/10/21 20:50:48
These elements don't have to have ids, you just se
Zhen Wang
2014/10/21 21:36:47
These elements are from the elementList, which are
| |
| 5652 } | 5656 } |
| 5653 | 5657 |
| 5654 TransitionElementData newElements; | |
| 5655 newElements.scope = metaElementContents.substring(firstSemicolon + 1).st ripWhiteSpace(); | 5658 newElements.scope = metaElementContents.substring(firstSemicolon + 1).st ripWhiteSpace(); |
| 5656 newElements.selector = selector; | 5659 newElements.selector = selector; |
| 5657 newElements.markup = markup.toString(); | 5660 newElements.markup = markup.toString(); |
| 5658 elementData.append(newElements); | 5661 elementData.append(newElements); |
| 5659 } | 5662 } |
| 5660 } | 5663 } |
| 5661 | 5664 |
| 5662 void Document::hideTransitionElements(const AtomicString& cssSelector) | 5665 void Document::hideTransitionElements(const AtomicString& cssSelector) |
| 5663 { | 5666 { |
| 5664 TrackExceptionState exceptionState; | 5667 TrackExceptionState exceptionState; |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 5854 using namespace blink; | 5857 using namespace blink; |
| 5855 void showLiveDocumentInstances() | 5858 void showLiveDocumentInstances() |
| 5856 { | 5859 { |
| 5857 WeakDocumentSet& set = liveDocumentSet(); | 5860 WeakDocumentSet& set = liveDocumentSet(); |
| 5858 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 5861 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
| 5859 for (WeakDocumentSet::const_iterator it = set.begin(); it != set.end(); ++it ) { | 5862 for (WeakDocumentSet::const_iterator it = set.begin(); it != set.end(); ++it ) { |
| 5860 fprintf(stderr, "- Document %p URL: %s\n", *it, (*it)->url().string().ut f8().data()); | 5863 fprintf(stderr, "- Document %p URL: %s\n", *it, (*it)->url().string().ut f8().data()); |
| 5861 } | 5864 } |
| 5862 } | 5865 } |
| 5863 #endif | 5866 #endif |
| OLD | NEW |