Index: Source/core/rendering/RenderThemeChromiumDefault.cpp |
diff --git a/Source/core/rendering/RenderThemeChromiumDefault.cpp b/Source/core/rendering/RenderThemeChromiumDefault.cpp |
index eb88f0064ddba03f78823faca9dcfc01284cadaa..3b851088278c86b3a036d31f2c6546b2e0b23ac3 100644 |
--- a/Source/core/rendering/RenderThemeChromiumDefault.cpp |
+++ b/Source/core/rendering/RenderThemeChromiumDefault.cpp |
@@ -26,7 +26,6 @@ |
#include "core/rendering/RenderThemeChromiumDefault.h" |
#include "core/CSSValueKeywords.h" |
-#include "core/UserAgentStyleSheets.h" |
#include "core/rendering/PaintInfo.h" |
#include "core/rendering/RenderObject.h" |
#include "core/rendering/RenderProgress.h" |
@@ -35,6 +34,7 @@ |
#include "platform/graphics/GraphicsContext.h" |
#include "platform/graphics/GraphicsContextStateSaver.h" |
#include "public/platform/Platform.h" |
+#include "public/platform/WebData.h" |
#include "public/platform/WebRect.h" |
#include "public/platform/WebThemeEngine.h" |
#include "wtf/StdLibExtras.h" |
@@ -130,16 +130,26 @@ String RenderThemeChromiumDefault::extraDefaultStyleSheet() |
// FIXME: We should not have OS() branches here. |
// We should have something like RenderThemeWin, RenderThemeLinux, or |
// should concatenate UA stylesheets on build time. |
+ String otherDefaultStyleSheets; |
#if !OS(WIN) |
- return RenderThemeChromiumSkia::extraDefaultStyleSheet() + |
#if !OS(ANDROID) |
- String(themeInputMultipleFieldsCss, sizeof(themeInputMultipleFieldsCss)) + |
+ const WebData& themeInputMultipleFieldsCssResource = Platform::current()->loadResource("themeInputMultipleFields.css"); |
+ String themeInputMultipleFieldsRules = themeInputMultipleFieldsCssResource.toASCIIString(); |
+ ASSERT(!themeInputMultipleFieldsRules.isEmpty()); |
+ otherDefaultStyleSheets = otherDefaultStyleSheets + themeInputMultipleFieldsRules; |
#endif |
- String(themeChromiumLinuxCss, sizeof(themeChromiumLinuxCss)); |
+ const WebData& themeChromiumLinuxCssResource = Platform::current()->loadResource("themeChromiumLinux.css"); |
+ String themeChromiumLinuxRules = themeChromiumLinuxCssResource.toASCIIString(); |
+ ASSERT(!themeChromiumLinuxRules.isEmpty()); |
+ otherDefaultStyleSheets = otherDefaultStyleSheets + themeChromiumLinuxRules; |
#else |
- return RenderThemeChromiumSkia::extraDefaultStyleSheet() + |
- String(themeInputMultipleFieldsCss, sizeof(themeInputMultipleFieldsCss)); |
+ const WebData& themeInputMultipleFieldsCssResource = Platform::current()->loadResource("themeInputMultipleFields.css"); |
+ String themeInputMultipleFieldsRules = themeInputMultipleFieldsCssResource.toASCIIString(); |
+ ASSERT(!themeInputMultipleFieldsRules.isEmpty()); |
+ otherDefaultStyleSheets = otherDefaultStyleSheets + themeInputMultipleFieldsRules; |
#endif |
+ |
+ return RenderThemeChromiumSkia::extraDefaultStyleSheet() + otherDefaultStyleSheets; |
} |
bool RenderThemeChromiumDefault::controlSupportsTints(const RenderObject* o) const |