Bug 163539

Summary: [Modern Media Controls] Basic MediaController
Product: WebKit Reporter: Antoine Quint <graouts>
Component: MediaAssignee: Antoine Quint <graouts>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, graouts, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari 10   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 163500    
Bug Blocks:    
Attachments:
Description Flags
Patch
none
Patch for landing
none
Patch for landing
none
Patch for landing
none
Patch for landing none

Antoine Quint
Reported 2016-10-17 03:36:37 PDT
Now that we have all the controls figured out, we can create a very basic MediaController object that will be instantiated by the createControls() global function that is called from HTMLMediaElement::ensureMediaControlsInjectedScript() once the shadow root has been created and the appropriate scripts injected.
Attachments
Patch (26.22 KB, patch)
2016-10-17 03:42 PDT, Antoine Quint
no flags
Patch for landing (36.48 KB, patch)
2016-10-17 14:21 PDT, Antoine Quint
no flags
Patch for landing (36.50 KB, patch)
2016-10-17 14:25 PDT, Antoine Quint
no flags
Patch for landing (36.59 KB, patch)
2016-10-17 14:27 PDT, Antoine Quint
no flags
Patch for landing (36.65 KB, patch)
2016-10-17 14:29 PDT, Antoine Quint
no flags
Radar WebKit Bug Importer
Comment 1 2016-10-17 03:37:01 PDT
Antoine Quint
Comment 2 2016-10-17 03:38:23 PDT
Once https://bugs.webkit.org/show_bug.cgi?id=163500 is reviewed and lands, this patch will be updated to add the two new JS files to the WebCore Xcode project and the list of injected scripts.
Antoine Quint
Comment 3 2016-10-17 03:42:42 PDT
Dean Jackson
Comment 4 2016-10-17 11:21:29 PDT
Comment on attachment 291807 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=291807&action=review > Source/WebCore/Modules/modern-media-controls/main.js:29 > + if (!!host) { What's the point of the !!? What value provided here would not be true as just (host)? > Source/WebCore/Modules/modern-media-controls/media/media-controller.js:36 > + this.layoutTraits = LayoutTraits.macOS; > + > + this.controls = new MacOSInlineMediaControls I think you should put a FIXME: here to make it clear it won't always be macOS. And I just noticed the M in MacOSInlineMediaControls. Are you going to have IOSInlineMediaControls?
Antoine Quint
Comment 5 2016-10-17 11:41:21 PDT
(In reply to comment #4) > Comment on attachment 291807 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=291807&action=review > > > Source/WebCore/Modules/modern-media-controls/main.js:29 > > + if (!!host) { > > What's the point of the !!? What value provided here would not be true as > just (host)? Old habits, will fix. > > Source/WebCore/Modules/modern-media-controls/media/media-controller.js:36 > > + this.layoutTraits = LayoutTraits.macOS; > > + > > + this.controls = new MacOSInlineMediaControls > > I think you should put a FIXME: here to make it clear it won't always be > macOS. > > And I just noticed the M in MacOSInlineMediaControls. Are you going to have > IOSInlineMediaControls? Yes, that's right. Class names always start with capitals.
Antoine Quint
Comment 6 2016-10-17 14:21:25 PDT
Created attachment 291873 [details] Patch for landing
Antoine Quint
Comment 7 2016-10-17 14:25:42 PDT
Created attachment 291874 [details] Patch for landing
Antoine Quint
Comment 8 2016-10-17 14:27:18 PDT
Created attachment 291876 [details] Patch for landing
Antoine Quint
Comment 9 2016-10-17 14:29:03 PDT
Created attachment 291877 [details] Patch for landing
WebKit Commit Bot
Comment 10 2016-10-17 15:05:58 PDT
Comment on attachment 291877 [details] Patch for landing Clearing flags on attachment: 291877 Committed r207436: <http://trac.webkit.org/changeset/207436>
WebKit Commit Bot
Comment 11 2016-10-17 15:06:02 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.