WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
WIP
bug-71968-20111206170001.patch (text/plain), 23.68 KB, created by
Erik Arvidsson
on 2011-12-06 17:00:02 PST
(
hide
)
Description:
WIP
Filename:
MIME Type:
Creator:
Erik Arvidsson
Created:
2011-12-06 17:00:02 PST
Size:
23.68 KB
patch
obsolete
>Subversion Revision: 102153 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 55134a76069b61f9a0899e986c46fd1ffc9dfa76..0d1c8a7c97b0d154d8ca02540f5f1d2ea3e5a274 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,59 @@ >+2011-12-06 Kaustubh Atrawalkar <kaustubh@motorola.com> >+ >+ Implement URL API >+ https://bugs.webkit.org/show_bug.cgi?id=71968 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Initial implementation of DOMURL IDL attributes. >+ >+ Tests: fast/dom/DOMURL/check-instanceof-domurl-functions.html >+ fast/dom/DOMURL/domurl-attribute-hash.html >+ fast/dom/DOMURL/domurl-attribute-host.html >+ fast/dom/DOMURL/domurl-attribute-hostname.html >+ fast/dom/DOMURL/domurl-attribute-pathname.html >+ fast/dom/DOMURL/domurl-attribute-port.html >+ fast/dom/DOMURL/domurl-attribute-protocol.html >+ fast/dom/DOMURL/domurl-attribute-search.html >+ fast/dom/DOMURL/stringifier-domurl-attribute-href.html >+ >+ * html/DOMURL.cpp: >+ (WebCore::DOMURL::DOMURL): >+ (WebCore::DOMURL::contextDestroyed): >+ (WebCore::DOMURL::createObjectURL): >+ (WebCore::DOMURL::revokeObjectURL): >+ (WebCore::DOMURL::host): >+ (WebCore::DOMURL::setHost): >+ (WebCore::DOMURL::setHostname): >+ (WebCore::DOMURL::port): >+ (WebCore::DOMURL::setPort): >+ (WebCore::DOMURL::setPathname): >+ (WebCore::DOMURL::search): >+ (WebCore::DOMURL::setSearch): >+ (WebCore::DOMURL::hash): >+ (WebCore::DOMURL::setHash): >+ (WebCore::DOMURL::setFilename): >+ (WebCore::DOMURL::origin): >+ (WebCore::DOMURL::getParameter): >+ (WebCore::DOMURL::appendParameter): >+ (WebCore::DOMURL::clearParameter): >+ * html/DOMURL.h: >+ (WebCore::DOMURL::create): >+ (WebCore::DOMURL::protocol): >+ (WebCore::DOMURL::setProtocol): >+ (WebCore::DOMURL::username): >+ (WebCore::DOMURL::setUsername): >+ (WebCore::DOMURL::password): >+ (WebCore::DOMURL::setPassword): >+ (WebCore::DOMURL::hostname): >+ (WebCore::DOMURL::pathname): >+ (WebCore::DOMURL::filename): >+ (WebCore::DOMURL::href): >+ (WebCore::DOMURL::setHref): >+ (WebCore::DOMURL::toString): >+ * html/DOMURL.idl: >+ * page/DOMWindow.idl: >+ > 2011-12-06 Andreas Kling <kling@webkit.org> > > MediaList: Remove constructor that takes a CSSImportRule*. >diff --git a/Source/WebCore/html/DOMURL.cpp b/Source/WebCore/html/DOMURL.cpp >index e42060d484298b7f4918b89c7a9eb48de4b37a03..c30c7a78d5f34c86b6be4636b74b02d67354be29 100644 >--- a/Source/WebCore/html/DOMURL.cpp >+++ b/Source/WebCore/html/DOMURL.cpp >@@ -1,5 +1,6 @@ > /* > * Copyright (C) 2011 Google Inc. All rights reserved. >+ * Copyright (C) 2011 Motorola Mobility Inc. > * > * Redistribution and use in source and binary forms, with or without > * modification, are permitted provided that the following conditions >@@ -24,56 +25,89 @@ > */ > > #include "config.h" >- >-#if ENABLE(BLOB) >- > #include "DOMURL.h" > >+#include "KURL.h" >+#include "NotImplemented.h" >+#include "SecurityOrigin.h" >+#include <wtf/MainThread.h> >+#include <wtf/OwnPtr.h> >+ >+#if ENABLE(BLOB) > #include "Blob.h" > #include "BlobURL.h" >-#include "KURL.h" > #include "ScriptExecutionContext.h" > #include "ThreadableBlobRegistry.h" >-#include <wtf/MainThread.h> >- > #if ENABLE(MEDIA_STREAM) > #include "MediaStream.h" > #include "MediaStreamRegistry.h" > #endif >+#endif > > namespace WebCore { > >-DOMURL::DOMURL(ScriptExecutionContext* scriptExecutionContext) >- : ContextDestructionObserver(scriptExecutionContext) >+#if ENABLE(BLOB) >+ >+ >+static HashSet<String>& publicBlobURLs(ScriptExecutionContext* scriptExecutionContext) > { >+ typedef HashMap<ScriptExecutionContext*, HashSet<String> > Map; >+ DEFINE_STATIC_LOCAL(Map, staticPublicBlobURLs, ()); >+ std::pair<Map::iterator, bool> result = staticPublicBlobURLs.add(scriptExecutionContext, HashSet<String>()); >+ return result.first->second; > } > >-DOMURL::~DOMURL() >+#if ENABLE(MEDIA_STREAM) >+ >+static HashSet<String>& publicStreamURLs(ScriptExecutionContext* scriptExecutionContext) > { >+ typedef HashMap<ScriptExecutionContext*, HashSet<String> > Map; >+ DEFINE_STATIC_LOCAL(Map, staticPublicStreamURLs, ()); >+ std::pair<Map::iterator, bool> result = staticPublicStreamURLs.add(scriptExecutionContext, HashSet<String>()); >+ return result.first->second; > } > >-void DOMURL::contextDestroyed() >-{ >- ContextDestructionObserver::contextDestroyed(); >+#endif >+#endif > >- HashSet<String>::iterator publicBlobURLsEnd = m_publicBlobURLs.end(); >- for (HashSet<String>::iterator iter = m_publicBlobURLs.begin(); iter != publicBlobURLsEnd; ++iter) >- ThreadableBlobRegistry::unregisterBlobURL(KURL(ParsedURLString, *iter)); >+DOMURL::DOMURL(const String& url, const String& baseURL) >+{ >+ m_href = KURL(KURL(), url); >+ // Resolve the URL relative to baseURL if is provide. >+ if (!baseURL.isEmpty()) >+ m_href = KURL(m_href, baseURL); >+} > >-#if ENABLE(MEDIA_STREAM) >- HashSet<String>::iterator publicStreamURLsEnd = m_publicStreamURLs.end(); >- for (HashSet<String>::iterator iter = m_publicStreamURLs.begin(); iter != publicStreamURLsEnd; ++iter) >- MediaStreamRegistry::registry().unregisterMediaStreamURL(KURL(ParsedURLString, *iter)); >-#endif >+DOMURL::~DOMURL() >+{ > } > >+#if ENABLE(BLOB) >+ >+ >+// void DOMURL::contextDestroyed() >+// { >+// ContextDestructionObserver::contextDestroyed(); >+ >+// HashSet<String>::iterator publicBlobURLsEnd = publicBlobURLs().end(); >+// for (HashSet<String>::iterator iter = publicBlobURLs().begin(); iter != publicBlobURLsEnd; ++iter) >+// ThreadableBlobRegistry::unregisterBlobURL(KURL(ParsedURLString, *iter)); >+ >+// #if ENABLE(MEDIA_STREAM) >+// HashSet<String>::iterator publicStreamURLsEnd = publicStreamURLs().end(); >+// for (HashSet<String>::iterator iter = publicStreamURLs().begin(); iter != publicStreamURLsEnd; ++iter) >+// MediaStreamRegistry::registry().unregisterMediaStreamURL(KURL(ParsedURLString, *iter)); >+// #endif >+// } >+ > #if ENABLE(MEDIA_STREAM) >-String DOMURL::createObjectURL(MediaStream* stream) >+ >+String DOMURL::createObjectURL(ScriptExecutionContext* scriptExecutionContext, MediaStream* stream) > { >- if (!m_scriptExecutionContext || !stream) >+ if (!scriptExecutionContext || !stream) > return String(); > >- KURL publicURL = BlobURL::createPublicURL(scriptExecutionContext()->securityOrigin()); >+ KURL publicURL = BlobURL::createPublicURL(scriptExecutionContext->securityOrigin()); > if (publicURL.isEmpty()) > return String(); > >@@ -81,50 +115,199 @@ String DOMURL::createObjectURL(MediaStream* stream) > ASSERT(isMainThread()); > > MediaStreamRegistry::registry().registerMediaStreamURL(publicURL, stream); >- m_publicStreamURLs.add(publicURL.string()); >+ publicStreamURLs(scriptExecutionContext).add(publicURL.string()); > > return publicURL.string(); > } >+ > #endif > >-String DOMURL::createObjectURL(Blob* blob) >+String DOMURL::createObjectURL(ScriptExecutionContext* scriptExecutionContext, Blob* blob) > { >- if (!m_scriptExecutionContext || !blob) >+ if (!scriptExecutionContext || !blob) > return String(); > >- KURL publicURL = BlobURL::createPublicURL(scriptExecutionContext()->securityOrigin()); >+ KURL publicURL = BlobURL::createPublicURL(scriptExecutionContext->securityOrigin()); > if (publicURL.isEmpty()) > return String(); > > ThreadableBlobRegistry::registerBlobURL(publicURL, blob->url()); >- m_publicBlobURLs.add(publicURL.string()); >+ publicBlobURLs(scriptExecutionContext).add(publicURL.string()); > > return publicURL.string(); > } > >-void DOMURL::revokeObjectURL(const String& urlString) >+void DOMURL::revokeObjectURL(ScriptExecutionContext* scriptExecutionContext, const String& urlString) > { >- if (!m_scriptExecutionContext) >+ if (!scriptExecutionContext) > return; > > KURL url(KURL(), urlString); > >- if (m_publicBlobURLs.contains(url.string())) { >+ HashSet<String>& blobURLs = publicBlobURLs(scriptExecutionContext); >+ if (blobURLs.contains(url.string())) { > ThreadableBlobRegistry::unregisterBlobURL(url); >- m_publicBlobURLs.remove(url.string()); >+ blobURLs.remove(url.string()); > } >- > #if ENABLE(MEDIA_STREAM) >- if (m_publicStreamURLs.contains(url.string())) { >+ HashSet<String>& streamURLs = publicStreamURLs(scriptExecutionContext); >+ if (streamURLs.contains(url.string())) { > // FIXME: make sure of this assertion below. Raise a spec question if required. > // Since WebWorkers cannot obtain Stream objects, we should be on the main thread. > ASSERT(isMainThread()); > MediaStreamRegistry::registry().unregisterMediaStreamURL(url); >- m_publicStreamURLs.remove(url.string()); >+ streamURLs.remove(url.string()); > } > #endif > } >+#endif // ENABLE(BLOB) >+ >+String DOMURL::host() const >+{ >+ if (m_href.hostEnd() == m_href.pathStart()) >+ return m_href.host(); >+ if (isDefaultPortForProtocol(m_href.port(), m_href.protocol())) >+ return m_href.host(); >+ return m_href.host() + ":" + String::number(m_href.port()); >+} >+ >+void DOMURL::setHost(const String& value) >+{ >+ if (value.isEmpty()) >+ return; >+ >+ if (!m_href.canSetHostOrPort()) >+ return; >+ >+ size_t colon = value.find(':'); >+ if (!colon) >+ return; >+ >+ if (colon == notFound) >+ m_href.setHostAndPort(value); >+ else { >+ unsigned portStart = colon + 1; >+ unsigned portEnd = portStart; >+ >+ while (isASCIIDigit(value[portEnd])) >+ ++portEnd; >+ >+ unsigned port = value.substring(portStart, portEnd - portStart).toUInt(); >+ if (!port) >+ m_href.setHostAndPort(value.substring(0, colon + 1) + "0"); >+ else { >+ if (isDefaultPortForProtocol(port, m_href.protocol())) >+ m_href.setHostAndPort(value.substring(0, colon)); >+ else >+ m_href.setHostAndPort(value.substring(0, portEnd)); >+ } >+ } >+} >+ >+void DOMURL::setHostname(const String& value) >+{ >+ unsigned i = 0; >+ unsigned hostLength = value.length(); >+ while (value[i] == '/') >+ i++; >+ >+ if (i == hostLength) >+ return; >+ >+ if (!m_href.canSetHostOrPort()) >+ return; >+ >+ m_href.setHost(value.substring(i)); >+} >+ >+String DOMURL::port() const >+{ >+ if (href().hasPort()) >+ return String::number(href().port()); >+ >+ return emptyString(); >+} >+ >+void DOMURL::setPort(const String& value) >+{ >+ if (!m_href.canSetHostOrPort()) >+ return; >+ >+ unsigned port = value.toUInt(); >+ if (isDefaultPortForProtocol(port, m_href.protocol())) >+ m_href.removePort(); >+ else >+ m_href.setPort(value.toUInt()); >+} >+ >+void DOMURL::setPathname(const String& value) >+{ >+ if (!m_href.canSetPathname()) >+ return; >+ >+ String newPathname = (value[0] == '/') ? value : ("/" + value); >+ m_href.setPath(newPathname); >+} >+ >+String DOMURL::search() const >+{ >+ String query = href().query(); >+ return query.isEmpty() ? emptyString() : "?" + query; >+} >+ >+void DOMURL::setSearch(const String& value) >+{ >+ String newSearch = (value[0] == '?') ? value.substring(1) : value; >+ m_href.setQuery(newSearch); >+} >+ >+String DOMURL::hash() const >+{ >+ String fragment = href().fragmentIdentifier(); >+ return fragment.isEmpty() ? emptyString() : "#" + fragment; >+} >+ >+void DOMURL::setHash(const String& value) >+{ >+ String newHash = (value[0] == '#') ? value.substring(1) : value; >+ m_href.setFragmentIdentifier(newHash); >+} >+ >+void DOMURL::setFilename(const String&) >+{ >+ // FIXME: Implement me. >+ notImplemented(); >+} >+ >+String DOMURL::origin() const >+{ >+ RefPtr<SecurityOrigin> origin = SecurityOrigin::create(href()); >+ return origin->toString(); >+} >+ >+String DOMURL::getParameter(const String&) >+{ >+ // FIXME: Implement me. >+ notImplemented(); >+ return String(); >+} >+ >+void DOMURL::appendParameter(const String&, const PassRefPtr<DOMStringList>) >+{ >+ // FIXME: Implement me. >+ notImplemented(); >+} >+ >+void DOMURL::appendParameter(const String&, const String&) >+{ >+ // FIXME: Implement me. >+ notImplemented(); >+} >+void DOMURL::clearParameter(const String&) >+{ >+ // FIXME: Implement me. >+ notImplemented(); >+} > > } // namespace WebCore > >-#endif // ENABLE(BLOB) >diff --git a/Source/WebCore/html/DOMURL.h b/Source/WebCore/html/DOMURL.h >index d02fe887cc8ce953c48901533778ac08e4e71290..f9e1a50d285fd469debb5a9d0c9989b2c6c7d67b 100644 >--- a/Source/WebCore/html/DOMURL.h >+++ b/Source/WebCore/html/DOMURL.h >@@ -1,5 +1,6 @@ > /* > * Copyright (C) 2011 Google Inc. All rights reserved. >+ * Copyright (C) 2011 Motorola Mobility Inc. > * > * Redistribution and use in source and binary forms, with or without > * modification, are permitted provided that the following conditions >@@ -26,11 +27,9 @@ > #ifndef DOMURL_h > #define DOMURL_h > >-#if ENABLE(BLOB) >- >-#include "ActiveDOMObject.h" >+#include "DOMStringList.h" >+#include "KURL.h" > #include "PlatformString.h" >-#include <wtf/HashSet.h> > #include <wtf/PassRefPtr.h> > #include <wtf/RefCounted.h> > >@@ -40,30 +39,68 @@ class Blob; > class MediaStream; > class ScriptExecutionContext; > >-class DOMURL : public RefCounted<DOMURL>, public ContextDestructionObserver { >+class DOMURL : public RefCounted<DOMURL> { > public: >- static PassRefPtr<DOMURL> create(ScriptExecutionContext* scriptExecutionContext) { return adoptRef(new DOMURL(scriptExecutionContext)); } >+ static PassRefPtr<DOMURL> create(const String& url, const String& baseURL) { return adoptRef(new DOMURL(url, baseURL)); } >+ static PassRefPtr<DOMURL> create(const String& url) { return adoptRef(new DOMURL(url, emptyString())); } > ~DOMURL(); > >-#if ENABLE(MEDIA_STREAM) >- String createObjectURL(MediaStream*); >-#endif >- String createObjectURL(Blob*); >- void revokeObjectURL(const String&); >+ String protocol() const { return href().protocol() + ":"; } >+ void setProtocol(const String& value) { m_href.setProtocol(value); } > >-private: >- explicit DOMURL(ScriptExecutionContext*); >+ String username() const { return href().user(); } >+ void setUsername(const String& value) { m_href.setUser(value); } >+ >+ String password() const { return href().pass(); } >+ void setPassword(const String& value) { m_href.setPass(value); } >+ >+ String host() const; >+ void setHost(const String&); >+ >+ String hostname() const { return href().host(); } >+ void setHostname(const String&); >+ >+ String port() const; >+ void setPort(const String&); >+ >+ String pathname() const { return href().path(); } >+ void setPathname(const String&); >+ >+ String search() const; >+ void setSearch(const String&); > >- virtual void contextDestroyed(); >+ String hash() const; >+ void setHash(const String&); > >- HashSet<String> m_publicBlobURLs; >+ String filename() const { return href().lastPathComponent(); } >+ void setFilename(const String&); >+ >+ String origin() const; >+ >+ KURL href() const { return m_href; } >+ void setHref(const String& value) { m_href = KURL(KURL(), value); } >+ >+ String toString() const { return m_href.string(); } >+ >+ String getParameter(const String&); >+ void appendParameter(const String&, const String&); >+ void appendParameter(const String&, const PassRefPtr<DOMStringList>); >+ void clearParameter(const String&); >+ >+#if ENABLE(BLOB) >+ static String createObjectURL(ScriptExecutionContext*, Blob*); >+ static void revokeObjectURL(ScriptExecutionContext*, const String&); > #if ENABLE(MEDIA_STREAM) >- HashSet<String> m_publicStreamURLs; >+ static String createObjectURL(ScriptExecutionContext*, MediaStream*); > #endif >+#endif >+ >+private: >+ KURL m_href; >+ >+ DOMURL(const String&, const String&); > }; > > } // namespace WebCore > >-#endif // ENABLE(BLOB) >- > #endif // DOMURL_h >diff --git a/Source/WebCore/html/DOMURL.idl b/Source/WebCore/html/DOMURL.idl >index d6d55790f7a0cc7bfd7430054af28311bb1b36db..5cecbc59a59b40b38ee43b720b631664d83fc2a4 100644 >--- a/Source/WebCore/html/DOMURL.idl >+++ b/Source/WebCore/html/DOMURL.idl >@@ -1,5 +1,6 @@ > /* > * Copyright (C) 2011 Google Inc. All rights reserved. >+ * Copyright (C) 2011 Motorola Mobility Inc. > * > * Redistribution and use in source and binary forms, with or without > * modification, are permitted provided that the following conditions >@@ -25,16 +26,35 @@ > > module html { > interface [ >- Conditional=BLOB, >- OmitConstructor, > GenerateNativeConverter, > GenerateToJS, >- NoStaticTables >+ Replaceable, >+ Constructor(in DOMString url, in [Optional=CallWithNullValue] DOMString baseURL) > ] DOMURL { >+ attribute DOMString protocol; >+ attribute DOMString username; >+ attribute DOMString password; >+ attribute DOMString host; >+ attribute DOMString hostname; >+ attribute DOMString port; >+ attribute DOMString pathname; >+ attribute DOMString search; >+ attribute DOMString hash; >+ >+ attribute DOMString filename; >+ readonly attribute DOMString origin; >+ stringifier attribute DOMString href; >+ >+ [DontEnum] DOMString toString(); >+ DOMString getParameter(in DOMString name); >+ void appendParameter(in DOMString name, in DOMString values); >+ void appendParameter(in DOMString name, in DOMString[] values); >+ void clearParameter(in DOMString name); >+ > #if defined(ENABLE_MEDIA_STREAM) && ENABLE_MEDIA_STREAM >- [ConvertNullStringTo=Undefined] DOMString createObjectURL(in MediaStream stream); >+ static [Conditional=BLOB,ConvertNullStringTo=Undefined,CallWith=ScriptExecutionContext] DOMString createObjectURL(in MediaStream stream); > #endif >- [ConvertNullStringTo=Undefined] DOMString createObjectURL(in Blob blob); >- void revokeObjectURL(in DOMString url); >+ static [Conditional=BLOB,ConvertNullStringTo=Undefined,CallWith=ScriptExecutionContext] DOMString createObjectURL(in Blob blob); >+ static [Conditional=BLOB,CallWith=ScriptExecutionContext] void revokeObjectURL(in DOMString url); > }; > } >diff --git a/Source/WebCore/page/DOMWindow.cpp b/Source/WebCore/page/DOMWindow.cpp >index 5712d66f34f8fe8b7867f4153f8b02fe9fc29a6c..3d3663525d7d94bfbcaa68ed503bfebad4c6377b 100644 >--- a/Source/WebCore/page/DOMWindow.cpp >+++ b/Source/WebCore/page/DOMWindow.cpp >@@ -1935,15 +1935,6 @@ void DOMWindow::showModalDialog(const String& urlString, const String& dialogFea > dialogFrame->page()->chrome()->runModal(); > } > >-#if ENABLE(BLOB) >-DOMURL* DOMWindow::webkitURL() const >-{ >- if (!m_domURL && isCurrentlyDisplayedInFrame()) >- m_domURL = DOMURL::create(this->scriptExecutionContext()); >- return m_domURL.get(); >-} >-#endif >- > #if ENABLE(QUOTA) > StorageInfo* DOMWindow::webkitStorageInfo() const > { >diff --git a/Source/WebCore/page/DOMWindow.h b/Source/WebCore/page/DOMWindow.h >index b503f6ecb58c3b9941fbfe0a82e231c5fca3ffd6..43c94a57ed705909804144c31fe67a106cbdee45 100644 >--- a/Source/WebCore/page/DOMWindow.h >+++ b/Source/WebCore/page/DOMWindow.h >@@ -347,10 +347,6 @@ namespace WebCore { > using RefCounted<DOMWindow>::ref; > using RefCounted<DOMWindow>::deref; > >-#if ENABLE(BLOB) >- DOMURL* webkitURL() const; >-#endif >- > #if ENABLE(SQL_DATABASE) > PassRefPtr<Database> openDatabase(const String& name, const String& version, const String& displayName, unsigned long estimatedSize, PassRefPtr<DatabaseCallback> creationCallback, ExceptionCode&); > #endif >diff --git a/Source/WebCore/page/DOMWindow.idl b/Source/WebCore/page/DOMWindow.idl >index 209bf43738b8ef27d64ec9c376454f5e8a733139..9c6f87c878078e79a8e553448ecbe25a998a8091 100644 >--- a/Source/WebCore/page/DOMWindow.idl >+++ b/Source/WebCore/page/DOMWindow.idl >@@ -813,7 +813,7 @@ module window { > > attribute [Conditional=BLOB] WebKitBlobBuilderConstructor WebKitBlobBuilder; > >- readonly attribute [Conditional=BLOB] DOMURL webkitURL; >+ attribute DOMURLConstructor webkitURL; > > #if defined(ENABLE_QUOTA) && ENABLE_QUOTA > readonly attribute [EnabledAtRuntime=Quota] StorageInfo webkitStorageInfo; >diff --git a/Source/WebCore/workers/WorkerContext.cpp b/Source/WebCore/workers/WorkerContext.cpp >index c284608f1728cfd2eb3e1d9f7bc5cabea1cf5ffb..2bc186d6049ad633b8e716d67fa22813e8826eb7 100644 >--- a/Source/WebCore/workers/WorkerContext.cpp >+++ b/Source/WebCore/workers/WorkerContext.cpp >@@ -379,15 +379,6 @@ EventTargetData* WorkerContext::ensureEventTargetData() > return &m_eventTargetData; > } > >-#if ENABLE(BLOB) >-DOMURL* WorkerContext::webkitURL() const >-{ >- if (!m_domURL) >- m_domURL = DOMURL::create(this->scriptExecutionContext()); >- return m_domURL.get(); >-} >-#endif >- > #if ENABLE(FILE_SYSTEM) > void WorkerContext::webkitRequestFileSystem(int type, long long size, PassRefPtr<FileSystemCallback> successCallback, PassRefPtr<ErrorCallback> errorCallback) > { >diff --git a/Source/WebCore/workers/WorkerContext.h b/Source/WebCore/workers/WorkerContext.h >index c94fa0978b3aa042e9123ebab374012aab4efd33..327a4e4a90defa1b5f159d5f21638e422156eae1 100644 >--- a/Source/WebCore/workers/WorkerContext.h >+++ b/Source/WebCore/workers/WorkerContext.h >@@ -131,10 +131,6 @@ namespace WebCore { > virtual bool isContextThread() const; > virtual bool isJSExecutionForbidden() const; > >-#if ENABLE(BLOB) >- DOMURL* webkitURL() const; >-#endif >- > #if ENABLE(FILE_SYSTEM) > enum FileSystemType { > TEMPORARY, >diff --git a/Source/WebCore/workers/WorkerContext.idl b/Source/WebCore/workers/WorkerContext.idl >index 736bbc133f7f2330f70ab073a88803e075ae0ad2..dc9fb79d965186f39780ac2862f7022358a46cb1 100644 >--- a/Source/WebCore/workers/WorkerContext.idl >+++ b/Source/WebCore/workers/WorkerContext.idl >@@ -101,7 +101,7 @@ module threads { > attribute FileReaderSyncConstructor FileReaderSync; > #endif > >- readonly attribute [Conditional=BLOB] DOMURL webkitURL; >+ attribute DOMURLConstructor webkitURL; > > #if defined(ENABLE_FILE_SYSTEM) && ENABLE_FILE_SYSTEM > const unsigned short TEMPORARY = 0; >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index d5c21d89c47b962ddbe53fc8c831e76056af2df3..02d281a9ce45ee93ff9a8e9df377e49cff9fea74 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,32 @@ >+2011-12-06 Kaustubh Atrawalkar <kaustubh@motorola.com> >+ >+ Implement URL API. >+ https://bugs.webkit.org/show_bug.cgi?id=71968 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Initial implementation of IDL Attributes. Added test cases. >+ >+ * fast/dom/DOMURL: Added. >+ * fast/dom/DOMURL/check-instanceof-domurl-functions-expected.txt: Added. >+ * fast/dom/DOMURL/check-instanceof-domurl-functions.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-hash-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-hash.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-host-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-host.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-hostname-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-hostname.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-pathname-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-pathname.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-port-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-port.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-protocol-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-protocol.html: Added. >+ * fast/dom/DOMURL/domurl-attribute-search-expected.txt: Added. >+ * fast/dom/DOMURL/domurl-attribute-search.html: Added. >+ * fast/dom/DOMURL/stringifier-domurl-attribute-href-expected.txt: Added. >+ * fast/dom/DOMURL/stringifier-domurl-attribute-href.html: Added. >+ > 2011-12-06 Vsevolod Vlasov <vsevik@chromium.org> > > Unreviewed chromium expectations update.
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 71968
:
114916
|
115121
|
115138
|
115532
|
115780
|
116327
|
116565
|
118024
|
118104
|
118145
|
118290
|
118365
|
118687