Summary: | Change IDL enumerations to be nested in their C++ class instead of at WebCore namespace level | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Darin Adler <darin> | ||||||||||||
Component: | Bindings | Assignee: | Darin Adler <darin> | ||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||
Severity: | Normal | CC: | achristensen, cdumez | ||||||||||||
Priority: | P2 | ||||||||||||||
Version: | WebKit Nightly Build | ||||||||||||||
Hardware: | Unspecified | ||||||||||||||
OS: | Unspecified | ||||||||||||||
Attachments: |
|
Description
Darin Adler
2016-05-02 00:36:48 PDT
Created attachment 277897 [details]
Patch
OK, Chris, Alex, here is the change we discussed. Build failures on GTK and iOS should be quick to fix; just a couple call sites that need the class prefixes. Created attachment 277907 [details]
Patch
New patch may fix the GTK and iOS builds. Created attachment 277908 [details]
Patch
iOS still does not build: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:404:75: error: no type named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? static inline HTMLMediaElementEnums::VideoFullscreenMode toFullscreenMode(HTMLMediaElement::VideoPresentationMode mode) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:407:10: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? case HTMLMediaElement::VideoPresentationMode::Fullscreen: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:409:10: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? case HTMLMediaElement::VideoPresentationMode::PictureInPicture: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:411:10: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? case HTMLMediaElement::VideoPresentationMode::Inline: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:436:8: error: no type named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? static HTMLMediaElement::VideoPresentationMode toPresentationMode(HTMLMediaElement::VideoFullscreenMode mode) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:439:16: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? return HTMLMediaElement::VideoPresentationMode::Fullscreen; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:442:16: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? return HTMLMediaElement::VideoPresentationMode::PictureInPicture; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:445:16: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? return HTMLMediaElement::VideoPresentationMode::Inline; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:448:12: error: no member named 'VideoPresentationMode' in 'WebCore::HTMLMediaElement'; did you mean 'HTMLVideoElement::VideoPresentationMode'? return HTMLMediaElement::VideoPresentationMode::Inline; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:451:1: error: unknown type name 'VideoPresentationMode'; did you mean 'HTMLVideoElement::VideoPresentationMode'? VideoPresentationMode HTMLVideoElement::webkitPresentationMode() const ^~~~~~~~~~~~~~~~~~~~~ HTMLVideoElement::VideoPresentationMode In file included from /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.cpp:28: /Volumes/Data/EWS/WebKit/Source/WebCore/html/HTMLVideoElement.h:81:16: note: 'HTMLVideoElement::VideoPresentationMode' declared here enum class VideoPresentationMode { Fullscreen, PictureInPicture, Inline }; ^ 10 errors generated. Created attachment 277909 [details]
Patch
Comment on attachment 277909 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=277909&action=review r=me > Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:815 > +sub PrefixIsWordsThatMatchStartOrEndWords I find this name to bit unclear. If we cannot find a better name, I suggest a comment explaining what this routine does. (In reply to comment #9) > Comment on attachment 277909 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=277909&action=review > > r=me > > > Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:815 > > +sub PrefixIsWordsThatMatchStartOrEndWords > > I find this name to bit unclear. If we cannot find a better name, I suggest > a comment explaining what this routine does. BTW, I think the code looks much nicer now after this change. However, it looks like iOS is still red. I’ll land this tonight, I guess, after fixing iOS. Created attachment 277982 [details]
Patch
Will land this as soon as I see the iOS build succeeding on the EWS. Committed r200361: <http://trac.webkit.org/changeset/200361> |