Index: Source/core/css/CSSDefaultStyleSheets.cpp |
diff --git a/Source/core/css/CSSDefaultStyleSheets.cpp b/Source/core/css/CSSDefaultStyleSheets.cpp |
index 96ad4f3cde30302c5926ab2212a0e85f15bd4750..730831f9051ccfbc4f4628b8deecaaefd03790a1 100644 |
--- a/Source/core/css/CSSDefaultStyleSheets.cpp |
+++ b/Source/core/css/CSSDefaultStyleSheets.cpp |
@@ -148,7 +148,7 @@ void CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement(Element* element, |
} |
// FIXME: We should assert that this sheet only contains rules for <video> and <audio>. |
- if (!m_mediaControlsStyleSheet && (element->hasTagName(videoTag) || element->hasTagName(audioTag))) { |
+ if (!m_mediaControlsStyleSheet && (isHTMLVideoElement(*element) || isHTMLAudioElement(*element))) { |
String mediaRules = String(mediaControlsUserAgentStyleSheet, sizeof(mediaControlsUserAgentStyleSheet)) + RenderTheme::theme().extraMediaControlsStyleSheet(); |
m_mediaControlsStyleSheet = parseUASheet(mediaRules); |
m_defaultStyle->addRulesFromSheet(mediaControlsStyleSheet(), screenEval()); |