Index: Source/web/WebLocalFrameImpl.cpp |
diff --git a/Source/web/WebLocalFrameImpl.cpp b/Source/web/WebLocalFrameImpl.cpp |
index d0c099b10d3316a056370afd074d54345b09eafd..11c22c9d43cb10e8155f0daac6597885a796ff95 100644 |
--- a/Source/web/WebLocalFrameImpl.cpp |
+++ b/Source/web/WebLocalFrameImpl.cpp |
@@ -1284,6 +1284,17 @@ void WebLocalFrameImpl::extendSelectionAndDelete(int before, int after) |
frame()->inputMethodController().extendSelectionAndDelete(before, after); |
} |
+void WebLocalFrameImpl::addStyleSheetByURL(const WebString& url) |
+{ |
+ RefPtr<Element> styleElement = frame()->document()->createElement(HTMLNames::linkTag, false); |
+ |
+ styleElement->setAttribute(HTMLNames::typeAttr, "text/css"); |
+ styleElement->setAttribute(HTMLNames::relAttr, "stylesheet"); |
+ styleElement->setAttribute(HTMLNames::hrefAttr, url); |
+ |
+ frame()->document()->head()->appendChild(styleElement.release(), IGNORE_EXCEPTION); |
+} |
+ |
void WebLocalFrameImpl::setCaretVisible(bool visible) |
{ |
frame()->selection().setCaretVisible(visible); |