-
Notifications
You must be signed in to change notification settings - Fork 410
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 crash when multiple Android Service are active #2418
base: main
Are you sure you want to change the base?
Conversation
@@ -18,15 +18,20 @@ | |||
namespace CommunityToolkit.Maui.Media.Services; | |||
|
|||
[SupportedOSPlatform("Android26.0")] | |||
[Service(Exported = false, Enabled = true, Name = "communityToolkit.maui.media.services", ForegroundServiceType = ForegroundService.TypeMediaPlayback)] | |||
[Service(Exported = false, Enabled = true, Name = "CommunityToolkit.Maui.Media.Services", ForegroundServiceType = ForegroundService.TypeMediaPlayback)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changing the case to uppercase will break older API's compatibility and prevent app from running on Android 23 or below. We only support android 26+ now on media element but I do want to point out this would break some current apps. Also changing this here requires changing the string in the manifest to match which has not been done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your PR, but I can't see what I should review. Where's the actual fix for the issue?
Can you also revert all code style changes that you made and follow ours?
public const string ActionPlay = "MediaAction.play"; | ||
public const string ActionPause = "MediaAction.pause"; | ||
public const string ActionUpdateUI = "CommunityToolkit.Maui.Services.action.UPDATE_UI"; | ||
public const string ActionUpdatePlayer = "CommunityToolkit.Maui.Services.action.UPDATE_PLAYER"; | ||
public const string ActionRewind = "MediaAction.rewind"; | ||
public const string ActionFastForward = "MediaAction.fastForward"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you change the pattern? Can you revert and follow our pattern
Description of Change
Linked Issues
PR Checklist
approved
(bug) orChampioned
(feature/proposal)main
at time of PRAdditional information