Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add missing properties to PlayButton type #6130

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ Swank Motion Pictures Inc. <*@swankmp.com>
TalkTalk Plc <*@talktalkplc.com>
Tatsiana Gelahova <tatsiana.gelahova@gmail.com>
Tian Shao <tyrelltle@gmail.com>
Thomas Champion <thchampi@gmail.com>
Tomas Tichy <mr.tichyt@gmail.com>
Tomohiro Matsuzawa <thmatuza75@hotmail.com>
Toshihiro Suzuki <t.suzuki326@gmail.com>
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTORS
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ Thomas Stephens <thomas@ustudio.com>
Tian Shao <tyrelltle@gmail.com>
Tim Plummer <objelisks@google.com>
Timothy Drews <tdrews@google.com>
Thomas Champion <thchampi@gmail.com>
Tomas Bucher <collapsingtesseract@gmail.com>
Tomas Tichy <mr.tichyt@gmail.com>
Tomohiro Matsuzawa <thmatuza75@hotmail.com>
Expand Down
24 changes: 24 additions & 0 deletions ui/externs/ui.js
Original file line number Diff line number Diff line change
Expand Up @@ -497,3 +497,27 @@ shaka.extern.IUISeekBar.Factory = class {
*/
create(rootElement, controls) {}
};

/**
* @interface
* @exportDoc
*/
shaka.extern.IUIPlayButton = class {
/**
* @param {!HTMLElement} parent
* @param {!shaka.ui.Controls} controls
*/
constructor(parent, controls) {
/**
* @protected {!HTMLButtonElement}
* @exportDoc
*/
this.button;
}

/** @return {boolean} */
isPaused() {}

/** @return {boolean} */
isEnded() {}
};
3 changes: 3 additions & 0 deletions ui/play_button.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ goog.requireType('shaka.ui.Controls');

/**
* @extends {shaka.ui.Element}
* @implements {shaka.extern.IUIPlayButton}
* @export
*/
shaka.ui.PlayButton = class extends shaka.ui.Element {
Expand Down Expand Up @@ -95,6 +96,7 @@ shaka.ui.PlayButton = class extends shaka.ui.Element {
/**
* @return {boolean}
* @protected
* @override
*/
isPaused() {
if (this.ad && this.ad.isLinear()) {
Expand All @@ -107,6 +109,7 @@ shaka.ui.PlayButton = class extends shaka.ui.Element {
/**
* @return {boolean}
* @protected
* @override
*/
isEnded() {
if (this.ad && this.ad.isLinear()) {
Expand Down