Remove unneccesary cast to Node* in MediaControlTextTrackContainerElement::updateDisplay
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 26 Jun 2013 18:17:28 +0000 (18:17 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 26 Jun 2013 18:17:28 +0000 (18:17 +0000)
https://bugs.webkit.org/show_bug.cgi?id=118020

Reviewed by Christophe Dumez.

Merge https://chromium.googlesource.com/chromium/blink/+/2de89f61bb316f5e166b45ce71bb2b293dbf575d

TextTrackCue is a Node, there's no reason to static_cast from it to Node*.

* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlTextTrackContainerElement::updateDisplay):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@152003 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/html/shadow/MediaControlElements.cpp

index a58a8c0ab11436418c17b46667eceb5408506fe7..a2b948b63b203a6a5a10d53d58bc4be29c4577d2 100644 (file)
@@ -1,3 +1,17 @@
+2013-06-26  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Remove unneccesary cast to Node* in MediaControlTextTrackContainerElement::updateDisplay
+        https://bugs.webkit.org/show_bug.cgi?id=118020
+
+        Reviewed by Christophe Dumez.
+
+        Merge https://chromium.googlesource.com/chromium/blink/+/2de89f61bb316f5e166b45ce71bb2b293dbf575d
+
+        TextTrackCue is a Node, there's no reason to static_cast from it to Node*.
+
+        * html/shadow/MediaControlElements.cpp:
+        (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
+
 2013-06-26  Ryosuke Niwa  <rniwa@webkit.org>
 
         RenderBox::hasRenderOverflow should return bool instead of RenderOverflow*
index c9a78f87de1a0a363f56debeefe7bef50cf423c6..e8f8a357ca2c1386c837a5d33889b48188e2e36e 100644 (file)
@@ -1278,7 +1278,7 @@ void MediaControlTextTrackContainerElement::updateDisplay()
             continue;
 
         RefPtr<TextTrackCueBox> displayBox = cue->getDisplayTree(m_videoDisplaySize.size());
-        if (displayBox->hasChildNodes() && !contains(static_cast<Node*>(displayBox.get()))) {
+        if (displayBox->hasChildNodes() && !contains(displayBox.get())) {
             // Note: the display tree of a cue is removed when the active flag of the cue is unset.
             appendChild(displayBox, ASSERT_NO_EXCEPTION, AttachNow);
             cue->setFontSize(m_fontSize, m_videoDisplaySize.size(), m_fontSizeIsImportant);