| 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 5285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5296 if (!element->isInTopLayer()) | 5296 if (!element->isInTopLayer()) |
| 5297 return; | 5297 return; |
| 5298 size_t position = m_topLayerElements.find(element); | 5298 size_t position = m_topLayerElements.find(element); |
| 5299 DCHECK_NE(position, kNotFound); | 5299 DCHECK_NE(position, kNotFound); |
| 5300 m_topLayerElements.remove(position); | 5300 m_topLayerElements.remove(position); |
| 5301 element->setIsInTopLayer(false); | 5301 element->setIsInTopLayer(false); |
| 5302 } | 5302 } |
| 5303 | 5303 |
| 5304 HTMLDialogElement* Document::activeModalDialog() const | 5304 HTMLDialogElement* Document::activeModalDialog() const |
| 5305 { | 5305 { |
| 5306 if (m_topLayerElements.isEmpty()) | 5306 for (auto it = m_topLayerElements.rbegin(); it != m_topLayerElements.rend();
++it) { |
| 5307 return 0; | 5307 if (isHTMLDialogElement(*it)) |
| 5308 return toHTMLDialogElement(m_topLayerElements.last().get()); | 5308 return toHTMLDialogElement((*it).get()); |
| 5309 } |
| 5310 |
| 5311 return nullptr; |
| 5309 } | 5312 } |
| 5310 | 5313 |
| 5311 void Document::exitPointerLock() | 5314 void Document::exitPointerLock() |
| 5312 { | 5315 { |
| 5313 if (!page()) | 5316 if (!page()) |
| 5314 return; | 5317 return; |
| 5315 if (Element* target = page()->pointerLockController().element()) { | 5318 if (Element* target = page()->pointerLockController().element()) { |
| 5316 if (target->document() != this) | 5319 if (target->document() != this) |
| 5317 return; | 5320 return; |
| 5318 page()->pointerLockController().requestPointerUnlock(); | 5321 page()->pointerLockController().requestPointerUnlock(); |
| (...skipping 691 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6010 } | 6013 } |
| 6011 | 6014 |
| 6012 void showLiveDocumentInstances() | 6015 void showLiveDocumentInstances() |
| 6013 { | 6016 { |
| 6014 WeakDocumentSet& set = liveDocumentSet(); | 6017 WeakDocumentSet& set = liveDocumentSet(); |
| 6015 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 6018 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
| 6016 for (Document* document : set) | 6019 for (Document* document : set) |
| 6017 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().get
String().utf8().data()); | 6020 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().get
String().utf8().data()); |
| 6018 } | 6021 } |
| 6019 #endif | 6022 #endif |
| OLD | NEW |