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

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

Issue 22454003: Support subtitles for native fullscreen video (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebased Created 7 years, 3 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
« no previous file with comments | « Source/core/css/fullscreen.css ('k') | Source/core/html/HTMLMediaElement.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) 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 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 if (!document()->page()) 360 if (!document()->page())
361 return; 361 return;
362 362
363 ASSERT(document()->page()->settings().fullScreenEnabled()); 363 ASSERT(document()->page()->settings().fullScreenEnabled());
364 364
365 if (m_fullScreenRenderer) 365 if (m_fullScreenRenderer)
366 m_fullScreenRenderer->unwrapRenderer(); 366 m_fullScreenRenderer->unwrapRenderer();
367 367
368 m_fullScreenElement = element; 368 m_fullScreenElement = element;
369 369
370 #if USE(NATIVE_FULLSCREEN_VIDEO)
371 if (element && element->isMediaElement())
372 return;
373 #endif
374
375 // Create a placeholder block for a the full-screen element, to keep the pag e from reflowing 370 // Create a placeholder block for a the full-screen element, to keep the pag e from reflowing
376 // when the element is removed from the normal flow. Only do this for a Rend erBox, as only 371 // when the element is removed from the normal flow. Only do this for a Rend erBox, as only
377 // a box will have a frameRect. The placeholder will be created in setFullSc reenRenderer() 372 // a box will have a frameRect. The placeholder will be created in setFullSc reenRenderer()
378 // during layout. 373 // during layout.
379 RenderObject* renderer = m_fullScreenElement->renderer(); 374 RenderObject* renderer = m_fullScreenElement->renderer();
380 bool shouldCreatePlaceholder = renderer && renderer->isBox(); 375 bool shouldCreatePlaceholder = renderer && renderer->isBox();
381 if (shouldCreatePlaceholder) { 376 if (shouldCreatePlaceholder) {
382 m_savedPlaceholderFrameRect = toRenderBox(renderer)->frameRect(); 377 m_savedPlaceholderFrameRect = toRenderBox(renderer)->frameRect();
383 m_savedPlaceholderRenderStyle = RenderStyle::clone(renderer->style()); 378 m_savedPlaceholderRenderStyle = RenderStyle::clone(renderer->style());
384 } 379 }
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
559 if (!target) 554 if (!target)
560 target = fullscreen->webkitCurrentFullScreenElement(); 555 target = fullscreen->webkitCurrentFullScreenElement();
561 } 556 }
562 557
563 if (!target) 558 if (!target)
564 target = doc; 559 target = doc;
565 m_fullScreenChangeEventTargetQueue.append(target); 560 m_fullScreenChangeEventTargetQueue.append(target);
566 } 561 }
567 562
568 } // namespace WebCore 563 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/css/fullscreen.css ('k') | Source/core/html/HTMLMediaElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698