From 137ade24ff93ebe73f35ef8d4ba25e54dbc80294 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Mon, 27 Jan 2025 12:45:17 +0100 Subject: [PATCH] Adjust javadoc format --- .../schabi/newpipe/player/PlayerService.java | 8 +++++--- .../newpipe/player/helper/PlayerHolder.java | 18 ++++++++++++------ 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/player/PlayerService.java b/app/src/main/java/org/schabi/newpipe/player/PlayerService.java index 924a0e251..0e8ff795e 100644 --- a/app/src/main/java/org/schabi/newpipe/player/PlayerService.java +++ b/app/src/main/java/org/schabi/newpipe/player/PlayerService.java @@ -174,9 +174,10 @@ public final class PlayerService extends Service { return mBinder; } - /** Allows us this {@link org.schabi.newpipe.player.PlayerService} over the Service boundary + /** + * Allows us this {@link org.schabi.newpipe.player.PlayerService} over the Service boundary * back to our {@link org.schabi.newpipe.player.helper.PlayerHolder}. - */ + */ public static class LocalBinder extends Binder { private final WeakReference playerService; @@ -184,7 +185,8 @@ public final class PlayerService extends Service { this.playerService = new WeakReference<>(playerService); } - /** Get the PlayerService object itself. + /** + * Get the PlayerService object itself. * @return this * */ public @Nullable PlayerService getService() { diff --git a/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHolder.java b/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHolder.java index 478436d93..707a44ea5 100644 --- a/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHolder.java +++ b/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHolder.java @@ -24,8 +24,10 @@ import org.schabi.newpipe.player.event.PlayerServiceEventListener; import org.schabi.newpipe.player.event.PlayerHolderLifecycleEventListener; import org.schabi.newpipe.player.playqueue.PlayQueue; -/** Singleton that manages a `PlayerService` - * and can be used to control the player instance through the service. */ +/** + * Singleton that manages a `PlayerService` + * and can be used to control the player instance through the service. + */ public final class PlayerHolder { private PlayerHolder() { @@ -121,7 +123,8 @@ public final class PlayerHolder { } } - /** Helper to handle context in common place as using the same + /** + * Helper to handle context in common place as using the same * context to bind/unbind a service is crucial. * * @return the common context @@ -131,7 +134,8 @@ public final class PlayerHolder { } - /** Connect to (and if needed start) the {@link PlayerService} + /** + * Connect to (and if needed start) the {@link PlayerService} * and bind {@link PlayerServiceConnection} to it. * If the service is already started, only set the listener. * @param playAfterConnect If the service is started, start playing immediately @@ -172,7 +176,8 @@ public final class PlayerHolder { context.stopService(new Intent(context, PlayerService.class)); } - /** Call {@link Context#unbindService(ServiceConnection)} on our service + /** + * Call {@link Context#unbindService(ServiceConnection)} on our service * (does not necesarily stop the service right away). * Remove all our listeners and deinitialize them. * @param context shared context @@ -229,7 +234,8 @@ public final class PlayerHolder { } } - /** Delegate all {@link PlayerServiceEventListener} events to our current `listener` object. + /** + * Delegate all {@link PlayerServiceEventListener} events to our current `listener` object. * Only difference is that if {@link PlayerServiceEventListener#onServiceStopped()} is called, * it also calls {@link PlayerHolder#unbind(Context)}. * */