ipc/android: Bump ktfmt to 0.53 and reformat it

Signed-off-by: utzcoz <utzcoz@outlook.com>
Part-of: <https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2382>
This commit is contained in:
utzcoz 2024-12-28 13:29:16 +08:00 committed by korejan
parent 19539af51f
commit b04fbb6756
3 changed files with 5 additions and 5 deletions

View file

@ -94,6 +94,6 @@ spotless {
kotlin {
target 'src/main/java/**/*.kt'
// Use ktfmt(https://github.com/facebook/ktfmt) as the default Kotlin formatter.
ktfmt('0.43').kotlinlangStyle()
ktfmt("$ktfmtVersion").kotlinlangStyle()
}
}

View file

@ -41,7 +41,7 @@ class MonadoService : Service(), Watchdog.ShutdownListener {
// If the surface comes from client, just stop the service when client disconnected
// because the surface belongs to the client.
if (binder.canDrawOverOtherApps()) BuildConfig.WATCHDOG_TIMEOUT_MILLISECONDS else 0,
this
this,
)
watchdog.startMonitor()
@ -88,7 +88,7 @@ class MonadoService : Service(), Watchdog.ShutdownListener {
this,
0,
Intent(BuildConfig.SHUTDOWN_ACTION).setPackage(packageName),
flags
flags,
)
val notification = serviceNotification.buildNotification(this, pendingShutdownIntent)
@ -97,7 +97,7 @@ class MonadoService : Service(), Watchdog.ShutdownListener {
startForeground(
serviceNotification.getNotificationId(),
notification,
ServiceInfo.FOREGROUND_SERVICE_TYPE_MANIFEST
ServiceInfo.FOREGROUND_SERVICE_TYPE_MANIFEST,
)
} else {
startForeground(serviceNotification.getNotificationId(), notification)

View file

@ -16,7 +16,7 @@ import java.util.concurrent.atomic.AtomicInteger
/** Client watchdog, to determine whether runtime service should be stopped. */
class Watchdog(
private val shutdownDelayMilliseconds: Long,
private val shutdownListener: ShutdownListener
private val shutdownListener: ShutdownListener,
) {
/**
* Interface definition for callbacks to be invoked when there's no client connected. Noted that