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

Side by Side Diff: Source/core/dom/Document.cpp

Issue 138833005: Replace RenderFullScreen with top layer (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: protect only for top layer changes Created 6 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 | Annotate | Revision Log
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) 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 4857 matching lines...) Expand 10 before | Expand all | Expand 10 after
4868 if (!element->isInTopLayer()) 4868 if (!element->isInTopLayer())
4869 return; 4869 return;
4870 size_t position = m_topLayerElements.find(element); 4870 size_t position = m_topLayerElements.find(element);
4871 ASSERT(position != kNotFound); 4871 ASSERT(position != kNotFound);
4872 m_topLayerElements.remove(position); 4872 m_topLayerElements.remove(position);
4873 element->setIsInTopLayer(false); 4873 element->setIsInTopLayer(false);
4874 } 4874 }
4875 4875
4876 HTMLDialogElement* Document::activeModalDialog() const 4876 HTMLDialogElement* Document::activeModalDialog() const
4877 { 4877 {
4878 if (m_topLayerElements.isEmpty()) 4878 Vector<RefPtr<Element> >::const_reverse_iterator end = m_topLayerElements.re nd();
4879 return 0; 4879 for (Vector<RefPtr<Element> >::const_reverse_iterator it = m_topLayerElement s.rbegin(); it != end; ++it) {
4880 return toHTMLDialogElement(m_topLayerElements.last().get()); 4880 if (!it->get()->hasTagName(dialogTag))
4881 continue;
4882 HTMLDialogElement* dialog = toHTMLDialogElement(it->get());
4883 if (dialog->isModal())
4884 return dialog;
4885 }
4886 return 0;
4881 } 4887 }
4882 4888
4883 void Document::webkitExitPointerLock() 4889 void Document::webkitExitPointerLock()
4884 { 4890 {
4885 if (!page()) 4891 if (!page())
4886 return; 4892 return;
4887 if (Element* target = page()->pointerLockController().element()) { 4893 if (Element* target = page()->pointerLockController().element()) {
4888 if (target->document() != this) 4894 if (target->document() != this)
4889 return; 4895 return;
4890 } 4896 }
(...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after
5426 void Document::defaultEventHandler(Event* event) 5432 void Document::defaultEventHandler(Event* event)
5427 { 5433 {
5428 if (frame() && frame()->remotePlatformLayer()) { 5434 if (frame() && frame()->remotePlatformLayer()) {
5429 frame()->chromeClient().forwardInputEvent(this, event); 5435 frame()->chromeClient().forwardInputEvent(this, event);
5430 return; 5436 return;
5431 } 5437 }
5432 Node::defaultEventHandler(event); 5438 Node::defaultEventHandler(event);
5433 } 5439 }
5434 5440
5435 } // namespace WebCore 5441 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698