Bug 141993 - [Attachment] Give <attachment> elements an underlying File
Summary: [Attachment] Give <attachment> elements an underlying File
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sam Weinig
URL:
Keywords:
Depends on: 142001
Blocks: 142017
  Show dependency treegraph
 
Reported: 2015-02-24 17:15 PST by Sam Weinig
Modified: 2015-02-25 09:33 PST (History)
3 users (show)

See Also:


Attachments
Patch (22.50 KB, patch)
2015-02-24 17:30 PST, Sam Weinig
thorton: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Weinig 2015-02-24 17:15:04 PST
[Attachment] Give <attachment> elements an underlying File
Comment 1 Sam Weinig 2015-02-24 17:30:01 PST
Created attachment 247284 [details]
Patch
Comment 2 Tim Horton 2015-02-24 17:33:06 PST
Comment on attachment 247284 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=247284&action=review

> Source/WebCore/DerivedSources.cpp:174
> +#if ENABLE(ATTACHMENT_ELEMENT)

Shouldn't this be below in its own block?

> LayoutTests/fast/attachment/attachment-dom.html:16
> +if (window.internals) {

no braces
Comment 3 Simon Fraser (smfr) 2015-02-24 19:48:08 PST
This broke windows:

     1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(607,5): error MSB6006: "link.exe" exited with code 1120.
     1>WebCoreTestSupport.lib(Internals.obj) : error LNK2019: unresolved external symbol "public: class WTF::String __thiscall WebCore::URL::fileSystemPath(void)const " (?fileSystemPath@URL@WebCore@@QBE?AVString@WTF@@XZ) referenced in function "public: class WTF::RefPtr<class WebCore::File> __thiscall WebCore::Internals::createFile(class WTF::String const &)" (?createFile@Internals@WebCore@@QAE?AV?$RefPtr@VFile@WebCore@@@WTF@@ABVString@4@@Z)
     1>WebCoreTestSupport.lib(Internals.obj) : error LNK2019: unresolved external symbol "public: bool __thiscall WebCore::URL::isLocalFile(void)const " (?isLocalFile@URL@WebCore@@QBE_NXZ) referenced in function "public: class WTF::RefPtr<class WebCore::File> __thiscall WebCore::Internals::createFile(class WTF::String const &)" (?createFile@Internals@WebCore@@QAE?AV?$RefPtr@VFile@WebCore@@@WTF@@ABVString@4@@Z)
     1>WebCoreTestSupport.lib(Internals.obj) : error LNK2019: unresolved external symbol "private: __thiscall WebCore::File::File(class WTF::String const &)" (??0File@WebCore@@AAE@ABVString@WTF@@@Z) referenced in function "public: static class WTF::Ref<class WebCore::File> __cdecl WebCore::File::create(class WTF::String const &)" (?create@File@WebCore@@SA?AV?$Ref@VFile@WebCore@@@WTF@@ABVString@4@@Z)
     1>WebCoreTestSupport.lib(JSInternals.obj) : error LNK2019: unresolved external symbol "class JSC::JSValue __cdecl WebCore::toJS(class JSC::ExecState *,class WebCore::JSDOMGlobalObject *,class WebCore::File *)" (?toJS@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVFile@1@@Z) referenced in function "public: float __thiscall <lambda_61e80db43a2fdfc51022831809c4282b>::operator()(class WebCore::LayoutUnit,class WebCore::LayoutUnit)const " (??R<lambda_61e80db43a2fdfc51022831809c4282b>@@QBEMVLayoutUnit@WebCore@@0@Z)
     1>C:\cygwin\home\buildbot\slave\win-debug\build\WebKitBuild\Debug\bin32\DumpRenderTree.dll : fatal error LNK1120: 4 unresolved externals

Should have waited for EWS!
Comment 4 Simon Fraser (smfr) 2015-02-24 20:32:08 PST
Brent tried to fix in https://trac.webkit.org/r180610.
Comment 5 Alexey Proskuryakov 2015-02-24 21:39:17 PST
This also broke js/dom/global-constructors-attributes.html on Mac. Updated the results in r180616.

Should have waited for EWS!
Comment 6 Ryosuke Niwa 2015-02-24 21:39:44 PST
Comment on attachment 247284 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=247284&action=review

> Source/WebCore/html/HTMLAttachmentElement.idl:27
> +    Conditional=ATTACHMENT_ELEMENT

We shoudln't be generating interface object in window.
It's causing global-constructors-attributes.html to see this interface.

See https://trac.webkit.org/r180616.
Comment 7 Ryosuke Niwa 2015-02-24 21:44:05 PST
Oh interesting, this feature is runtime-enabled by default.