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

Unified Diff: Source/core/layout/LayoutTextTrackContainer.cpp

Issue 962923002: Ideas for text track container follow-up Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase and ramble Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/track/TextTrackContainer.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutTextTrackContainer.cpp
diff --git a/Source/core/layout/LayoutTextTrackContainer.cpp b/Source/core/layout/LayoutTextTrackContainer.cpp
index 4bbceb42c28777bdf38c5325da727d8dd111a87c..84190ba9caa7615df1852e2e26025b8659d65647 100644
--- a/Source/core/layout/LayoutTextTrackContainer.cpp
+++ b/Source/core/layout/LayoutTextTrackContainer.cpp
@@ -30,7 +30,6 @@
#include "core/layout/LayoutTextTrackContainer.h"
#include "core/frame/DeprecatedScheduleStyleRecalcDuringLayout.h"
-#include "core/html/HTMLMediaElement.h"
#include "core/html/track/TextTrackContainer.h"
namespace blink {
@@ -43,15 +42,13 @@ LayoutTextTrackContainer::LayoutTextTrackContainer(Element* element)
void LayoutTextTrackContainer::layout()
{
LayoutBlockFlow::layout();
- if (style()->display() == NONE)
- return;
DeprecatedScheduleStyleRecalcDuringLayout marker(node()->document().lifecycle());
TextTrackContainer* textTrackContainer = toTextTrackContainer(node());
- HTMLMediaElement* mediaElement = toHTMLMediaElement(parent()->node());
- ASSERT(textTrackContainer && mediaElement);
- textTrackContainer->updateSizes(*mediaElement);
+ ASSERT(textTrackContainer);
+ LayoutSize size = contentBoxRect().size();
+ textTrackContainer->updateSizes(size);
}
} // namespace blink
« no previous file with comments | « Source/core/html/track/TextTrackContainer.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698