1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-16 16:22:57 +08:00
osu-lazer/osu.Game/Overlays
Bartłomiej Dach 6c943681b0
Fix preview tracks playing after their owning overlay has hidden
RFC. Closes https://github.com/ppy/osu/issues/27883.

The idea here is that `PopOut()` is called _when the hide is requested_,
so once an overlay trigger would hide, the overlay would
`StopAnyPlaying()`, but because of async load things, the actual track
would start playing after that but before the overlay has fully hidden.
(That last part is significant because after the overlay has fully
hidden, schedules save the day.)

Due to the loose coupling between `PreviewTrackManager` and
`IPreviewTrackOwner` there's really no easy way to handle this locally
to the usages of the preview tracks. Heck, `PreviewTrackManager` doesn't
really know which preview track owner is to be considered _present_ at
any time, it just kinda works on vibes based on DI until the owner tells
all of its preview tracks to stop.

This solution causes the preview tracks to stop a little bit later but
maybe that's fine? Just trying to not overthink the issue is all.

No tests because this is going to suck to test automatically while it is
pretty easy to test manually (got it in a few tries on master).

The issue also mentions that the track can sometimes resume playing
after the overlay is pulled up again, but I don't see that as a problem
necessarily, and even if it was, it's not going to be that easy to
address due to the aforementioned loose coupling - to fix that, play
buttons would have to know who is the current preview track owner and
cancel schedules upon determining that their preview track owner has
gone away.
2024-04-16 16:19:26 +02:00
..
AccountCreation Add 2FA verification screen to registration flow 2024-02-02 07:25:04 +01:00
BeatmapListing Wrap beatmap listing filter names too 2024-03-11 14:58:28 +01:00
BeatmapSet Fix advanced stats in beatmap info overlay showing "key count" on non-mania beatmaps 2024-02-25 21:18:15 +03:00
Changelog Fix changelog stream user count only accounting for latest build 2024-01-18 16:15:52 -08:00
Chat Apply padding to GridContainers directly 2024-02-20 23:18:37 +03:00
Comments Use better value for alignment 2024-02-14 12:24:28 +01:00
Dashboard Show local user in online users 2023-12-28 17:40:07 +09:00
Dialog Change default masking value to true 2024-01-21 04:57:48 +03:00
FirstRunSetup Split copy info text into two rather than parameterise 2024-02-05 16:30:04 +01:00
Login Fix bindable not being correctly re-bound across local user changes 2024-03-29 15:50:10 +08:00
MedalSplash Demote medal "overlay" to animation 2024-02-20 16:31:31 +01:00
Mods Replace usages of is null with == null 2024-04-03 01:50:39 +08:00
Music Use new LINQ Order() instead of OrderBy() when possible 2024-02-08 18:01:00 +01:00
News Replace hexacons in toolbar with new icons 2023-12-27 17:42:18 +01:00
Notifications Fix progress notifications queueing up infinite text changes when not visible 2023-12-18 19:00:44 +09:00
OSD Remove touch device toasts entirely 2023-11-06 10:54:32 +01:00
Profile Merge pull request #27107 from Joehuu/rank-highest-tooltip 2024-02-22 09:08:22 +01:00
Rankings Rearrange rankings overlay tabs to match web 2024-03-12 21:15:59 -07:00
Settings Remove unused using directives 2024-03-06 07:57:59 +01:00
SkinEditor Fix newly placed items in skin editor not getting correct anchor placement 2024-04-12 17:08:49 +08:00
Toolbar Fixed type inconsistency and rounding 2024-04-14 15:10:05 +02:00
Volume Update usage of CircularProgress.Current 2024-03-06 12:13:10 +08:00
Wiki Fix WikiPanelContainer causing poor performance 2024-03-09 00:51:33 +03:00
AccountCreationOverlay.cs Enable NRT in AccountCreationOverlay 2024-02-02 07:24:32 +01:00
BeatmapListingOverlay.cs Uncomment net6.0 code and remove old code 2023-12-04 20:17:22 +01:00
BeatmapSetOverlay.cs Normalise overlay horizontal padding const 2023-04-02 20:24:13 -07:00
BreadcrumbControlOverlayHeader.cs Automated pass 2023-06-24 01:00:03 +09:00
ChangelogOverlay.cs Change some order and assert for positive visibility before scheduling an operation in changelog overlay 2023-01-24 17:59:25 +09:00
ChatOverlay.cs Replace hexacons in toolbar with new icons 2023-12-27 17:42:18 +01:00
DashboardOverlay.cs Retrofit user presence watching into dashboard overlay 2023-12-06 19:37:35 +01:00
DialogOverlay.cs Apply safeties for AudioFilter usage around drawables which go non-present 2024-02-26 21:22:25 +08:00
FirstRunSetupOverlay.cs Fix the MOTHERLOAD of undetected issues that are now visible thanks to net6.0 2022-12-16 18:16:26 +09:00
FullscreenOverlay.cs Replace all hexacon lookups with strongly typed properties 2023-11-24 13:17:39 +09:00
HoldToConfirmOverlay.cs Partial everything 2022-11-27 00:00:27 +09:00
IDialogOverlay.cs Automated #nullable processing 2022-06-17 16:37:17 +09:00
INamedOverlayComponent.cs Replace all hexacon lookups with strongly typed properties 2023-11-24 13:17:39 +09:00
INotificationOverlay.cs Flip and rename CompletedOrCancelled to Ongoing 2023-07-08 14:11:58 +02:00
IOverlayManager.cs Automated pass 2023-06-24 01:00:03 +09:00
KudosuTable.cs Add ability to view kudosu rankings 2023-11-07 15:58:17 -08:00
LoginOverlay.cs Reduce LoginOverlay pop-in/pop-out sample panning to match NowPlayingOverlay 2023-10-20 21:01:36 +09:00
MedalAnimation.cs NRT-annotate MedalAnimation and fix possible nullref 2024-02-20 17:59:21 +01:00
MedalOverlay.cs Fix test failures 2024-02-20 17:25:11 +01:00
MusicController.cs Adjust xmldoc to explicitly metnion it only affects end user control 2023-07-30 13:52:58 +09:00
NewsOverlay.cs Partial everything 2022-11-27 00:00:27 +09:00
NotificationOverlay.cs Replace hexacons in toolbar with new icons 2023-12-27 17:42:18 +01:00
NotificationOverlayToastTray.cs Expose all notifications from INotificationOverlay 2023-06-23 15:19:21 +09:00
NowPlayingOverlay.cs Fix now playing beatmap backgrounds not being correctly centred 2024-01-23 17:30:00 +09:00
OnlineOverlay.cs Automated pass 2023-06-24 01:00:03 +09:00
OnScreenDisplay.cs Use new ArgumentNullException.ThrowIfNull throw-helper API 2022-12-22 21:27:59 +01:00
OverlayActivation.cs Remove redundant nullable suppression directives 2023-06-07 08:20:41 +03:00
OverlayColourProvider.cs Automated pass 2023-06-24 01:00:03 +09:00
OverlayHeader.cs Manual fixes to reduce warnings to zero 2023-06-24 01:52:53 +09:00
OverlayHeaderBackground.cs Automated pass 2023-06-24 01:00:03 +09:00
OverlayPanelDisplayStyleControl.cs Partial everything 2022-11-27 00:00:27 +09:00
OverlayRulesetSelector.cs Automated pass 2023-06-24 01:00:03 +09:00
OverlayRulesetTabItem.cs Automated pass 2023-06-24 01:00:03 +09:00
OverlayScrollContainer.cs Ensure scroll-to-top button is displayed above all overlay content 2023-05-17 15:42:38 +09:00
OverlaySidebar.cs Increase the minimum size of the scroll bar 2023-07-02 00:04:56 +09:00
OverlaySortTabControl.cs Add failing beatmap listing sort direction on criteria change test 2023-03-21 15:08:37 -07:00
OverlayStreamControl.cs Avoid using .Children for enumeration in other locations 2024-01-23 05:32:11 +09:00
OverlayStreamItem.cs Replace other hardcoded horizontal padding with const 2023-04-02 20:50:18 -07:00
OverlayTabControl.cs Partial everything 2022-11-27 00:00:27 +09:00
OverlayTitle.cs Replace all hexacon lookups with strongly typed properties 2023-11-24 13:17:39 +09:00
OverlayView.cs Partial everything 2022-11-27 00:00:27 +09:00
RankingsOverlay.cs Add ability to view kudosu rankings 2023-11-07 15:58:17 -08:00
RevertToDefaultButton.cs Fix revert-to-default button appearing on disabled settings regardless of value 2024-01-18 14:24:49 +03:00
SettingsOverlay.cs Merge branch 'master' into universal-offset-from-session-plays 2023-12-28 14:07:46 +01:00
SettingsPanel.cs Speed up fades in transition to avoid ugliness 2023-12-27 13:49:00 +09:00
SettingsSearchTextBox.cs Only run "select all on focus" behaviour on desktop platforms 2023-10-30 11:54:19 +03:00
SettingsSubPanel.cs Move back button inside sidebar to fix weird animation 2023-12-27 13:39:13 +09:00
SettingsToolboxGroup.cs Fix SettingsToolboxGroup allocating excessively due to missing cache validation 2024-01-09 18:34:20 +09:00
SortDirection.cs Remove redundant nullable suppression directives 2023-06-07 08:20:41 +03:00
TabbableOnlineOverlay.cs Partial everything 2022-11-27 00:00:27 +09:00
TabControlOverlayHeader.cs Manual fixes to reduce warnings to zero 2023-06-24 01:52:53 +09:00
UserProfileOverlay.cs Ensure only run once 2023-11-22 12:03:42 +09:00
VersionManager.cs Automated pass 2023-06-24 01:00:03 +09:00
VolumeOverlay.cs Partial everything 2022-11-27 00:00:27 +09:00
WaveOverlayContainer.cs Fix preview tracks playing after their owning overlay has hidden 2024-04-16 16:19:26 +02:00
WikiOverlay.cs Use better method of ignore case comparison 2024-01-09 13:13:32 +09:00