Commit Graph

21 Commits

Author SHA1 Message Date
Álvaro Velad Galván 0d3f3d0140 feat(UI): Support sub menus on context button (#9526) 2025-12-18 15:49:50 +01:00
Álvaro Velad Galván 0f4e849acf fix(UI): Fix position of sub menus (#9485)
Now the submenus are rendered within the overflow menu
2025-12-10 13:28:40 +01:00
Álvaro Velad Galván 02a2bb54d0 feat(Cast): Support getCurrentAd while casting (#9306) 2025-10-28 13:25:57 +01:00
Álvaro Velad Galván 879f927db3 feat(UI): Support ad events when casting (#9280) 2025-10-24 14:59:11 +02:00
Álvaro Velad Galván 76cea8d75a feat: Handle AdManager in CastProxy, CastSender and CastReceiver (#9266)
Co-authored-by: Wojciech Tyczyński <tykus160@gmail.com>
2025-10-23 22:12:32 +02:00
Álvaro Velad Galván e39defb6f7 feat(Ads): Remove circular dependency (#6868)
To eliminate `* @suppress {missingRequire}` it was necessary to create a
new class with the constants and deprecate the old ones. That's why this
change is feat.
2024-06-20 07:51:58 +02:00
Theodore Abshire 655493f441 Fix(ads): Fix bug w/ configuring UI during CS ads
Previously, the client-side ad container was put inside the controls
container, which was cleared when the UI was configured. This meant
that re-configuring the UI made client-side ads go away, basically.
This moves client-side ads to go into their own container, which
is never re-made or uprooted, even when the DOM is recreated, in
order to not break the IMA SDK.
This has the side-effect of fixing a bug where client-side ads were
not always cleared upon loading a new asset, and could show up
unexpectedly in future playbacks.

Fixes #2869
Fixes #2943

Change-Id: I3cf67b0b278764c10c6ff2f678316dc9cc85929e
2020-12-16 14:26:09 -08:00
Theodore Abshire 67a49d45e3 cleanup: Add missing requires.
This is a port of the internal changes: cl/329816039

Change-Id: If162e80e107ef7dc40956d6f4160d24f6d50858d
2020-09-14 22:50:49 +00:00
Joey Parrish 2d4f36f509 fix: Add missing require statements
Caught by a newer compiler

Change-Id: I27a392b35302cce0817c2e95cd25584df4c2b58d
2020-08-25 16:30:53 -07:00
Joey Parrish f539147d48 fix: Correct license headers in compiled output
This fixes all the license headers in the main library, which corrects
the appearance of the main license in the compiled output.

It seems that the `!` in the header forces the compiler to keep it in
the output.  I believe older compiler releases did this purely based
on `@license`.

Issue #2638

Change-Id: I7f0e918caad10c9af689c9d07672b7fe9be7b2f3
2020-06-09 16:05:09 -07:00
Joey Parrish 64896d70b0 Use shorter license header
This reflects changes in Google's policy on JavaScript license
headers, which should be smaller to avoid increasing the size of the
binary unnecessarily.

This also updates the company name from "Google, Inc" to "Google LLC".

Change-Id: I3f8b9ed3700b6351f43173d50c94d35c333e82b4
2019-11-22 18:18:36 +00:00
Sandra Lokshina 47c857d100 Make it possible to exclude ads from the build.
Closes #2231

Change-Id: I3ef4ce09fa3a08bfcaffa2d53aae4bbec70b33c1
2019-11-14 18:13:55 +00:00
Sandra Lokshina d47362ac5e Integrate play button icon change with ads and fix fade out.
1) Play buttons' icons now toggle between play and pause
depending on ad state during ad playback.

2) Controls fade in and out on mouse out/in during
ad playback similar to how they do it during the
presentation.

Issue #2222.

Change-Id: I97ce3b5aa70bdfdd758a54894a3d94b38bccf953
2019-11-01 14:02:19 -07:00
Sandra Lokshina 688d8881d9 Change controls behavior when an ad is playing.
This CL makes the controls switch between controlling
the ad and the presentation. If there's an ad currently
playing, pause button will pause the ad instead of the
presentation, mute button will mute the ad, etc.

Change-Id: I42f57df9a5ce491ed842f39e0f1e6031d1e3a93c
2019-11-01 16:25:52 +00:00
Sandra Lokshina 02847e3b1f Show ad controls and update ad counter when ad starts.
(Also hide ad controls when ad ends).

Change-Id: Ifd5b8ec47fe08ef277d86f96632677c7c07cfbd4
2019-10-28 22:10:55 +00:00
Sandra Lokshina fdd2602acd Release old ui.Elements on controls.configure() calls.
The calls to controls.configure() deleted the old layout
in terms of the html elements, but the ui.Elements
owning the html still survived.
This CL fixes that. It also switches ui.Element from
IDestroyable to IReleasable to make the release synchronous.

Fixes #2089.

Change-Id: Ic4ce70e91a1b028ef4d971ac3fb9281d8a667ea8
2019-08-20 21:09:15 +00:00
Sandra Lokshina a4a2ef5a7c Make the demo close button implement shaka.ui.Element
Issue #2011

Change-Id: I51c828b0457133ccee4b3f3ff2e1a33da8b3a34c
2019-06-28 09:42:11 -07:00
Sandra Lokshina 24f5a29501 Export protected memebers of shaka.ui.Element
This enables custom buttons that aren't part of the
library to be used in compiled mode.

Closes #2011

Change-Id: I500f93a86bfd2893948e594a969b6f8208836251
2019-06-25 22:07:34 +00:00
Joey Parrish e5620f3891 Thoroughly wipe out references in UI destroy
There are some cases in testing where held references cause issues,
such as video elements lingering between tests on Tizen.  This does a
better job of clearing out resources in destroy() methods in the UI.

Change-Id: Ib1434ed11561216cd41ec247535ea7b32c1154d1
2019-05-06 16:13:39 +00:00
Aaron Vaage 43afe3a7c8 Refactor Event Manager To "Release" and not "Destroy"
We often use the IDestroyable interface to provide us with a standardized
way to break internal references and tear-down objects, however many
objects don't need this to be async. Once using IDestroyable, everyone
must assume that you must be async.

This change introduces IReleasable, a sibling to IDestryable, which
provides the |release| method. IReleasable is the synchronous version of
IDestroyable.

This change converts EventManager from IDestroyable to IReleasable as
the first of many conversions.

Change-Id: Ic3e90e594abc1c7326eccbe2521eb71676b74a09
2019-01-24 01:11:38 +00:00
Sandra Lokshina 121b615c3e Break UI into components design.
What's already done:
- UIElement and IUIElement interface
- All elements register themselves with controls
- Each element is responsible for its' behavior
- A bit of clean up with constants/enums moving to
their own files

What is not done yet:
- Overflow menu is a dumping ground now. Its'
elements will move to the UIElement model eventually, too.
- Build files are hacked a bit and will need more attention.
- No clean up has been done except for the constants/enums.

Change-Id: I9917aa705e85158a2f26830bd988552fe177e53b
2019-01-17 21:58:12 +00:00