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, 2010, 2012 Apple Inc. All r ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 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) 2010 Nokia Corporation and/or its subsidiary(-ies) | 8 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 9 * Copyright (C) 2013 Google Inc. All rights reserved. | 9 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 10 * | 10 * |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 224 // node document: | 224 // node document: |
| 225 | 225 |
| 226 // The fullscreen element ready check returns false. | 226 // The fullscreen element ready check returns false. |
| 227 if (!fullscreenElementReady(element, requestType)) | 227 if (!fullscreenElementReady(element, requestType)) |
| 228 break; | 228 break; |
| 229 | 229 |
| 230 // This algorithm is not allowed to show a pop-up: | 230 // This algorithm is not allowed to show a pop-up: |
| 231 // An algorithm is allowed to show a pop-up if, in the task in which t he algorithm is running, either: | 231 // An algorithm is allowed to show a pop-up if, in the task in which t he algorithm is running, either: |
| 232 // - an activation behavior is currently being processed whose click e vent was trusted, or | 232 // - an activation behavior is currently being processed whose click e vent was trusted, or |
| 233 // - the event listener for a trusted click event is being handled. | 233 // - the event listener for a trusted click event is being handled. |
| 234 if (!UserGestureIndicator::processingUserGesture()) | 234 if (!UserGestureIndicator::processingUserGesture()) { |
| 235 document()->executionContext()->addConsoleMessage(ConsoleMessage::cr eate(JSMessageSource, WarningMessageLevel, | |
| 236 "requestFullScreen can only be initiated by a user gesture.")); | |
|
Mike West
2014/09/29 12:24:08
I'd suggest pulling in 'ExceptionMessages::failedT
Mayur Kankanwadi
2014/09/30 13:56:39
Done.
| |
| 235 break; | 237 break; |
| 238 } | |
| 236 | 239 |
| 237 // Fullscreen is not supported. | 240 // Fullscreen is not supported. |
| 238 if (!fullscreenIsSupported(element.document(), element)) | 241 if (!fullscreenIsSupported(element.document(), element)) |
| 239 break; | 242 break; |
| 240 | 243 |
| 241 // 2. Let doc be element's node document. (i.e. "this") | 244 // 2. Let doc be element's node document. (i.e. "this") |
| 242 Document* currentDoc = document(); | 245 Document* currentDoc = document(); |
| 243 | 246 |
| 244 // 3. Let docs be all doc's ancestor browsing context's documents (if an y) and doc. | 247 // 3. Let docs be all doc's ancestor browsing context's documents (if an y) and doc. |
| 245 Deque<Document*> docs; | 248 Deque<Document*> docs; |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 603 void Fullscreen::trace(Visitor* visitor) | 606 void Fullscreen::trace(Visitor* visitor) |
| 604 { | 607 { |
| 605 visitor->trace(m_fullScreenElement); | 608 visitor->trace(m_fullScreenElement); |
| 606 visitor->trace(m_fullScreenElementStack); | 609 visitor->trace(m_fullScreenElementStack); |
| 607 visitor->trace(m_fullScreenRenderer); | 610 visitor->trace(m_fullScreenRenderer); |
| 608 visitor->trace(m_eventQueue); | 611 visitor->trace(m_eventQueue); |
| 609 DocumentSupplement::trace(visitor); | 612 DocumentSupplement::trace(visitor); |
| 610 } | 613 } |
| 611 | 614 |
| 612 } // namespace blink | 615 } // namespace blink |
| OLD | NEW |