Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8875f841 authored by Mohammed Althaf T's avatar Mohammed Althaf T 😊
Browse files

split: Remove unused codes

parent 3ebc19c9
Loading
Loading
Loading
Loading
+4 −7
Original line number Diff line number Diff line
/*
 * Copyright ECORP SAS 2022
 * Copyright ECORP SAS 2022-2025
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
@@ -33,12 +33,9 @@ class SplitInstallBinder(
    }

    override fun installSplitModule(packageName: String, modulePath: String) {

        Log.i(TAG, "installing $modulePath")
        val packageManager = applicationContext.packageManager
        val packageInstaller = packageManager.packageInstaller
        val params = PackageInstaller.SessionParams(PackageInstaller.SessionParams.MODE_INHERIT_EXISTING)
            .apply {
        val packageInstaller = applicationContext.packageManager.packageInstaller
        val params = PackageInstaller.SessionParams(PackageInstaller.SessionParams.MODE_INHERIT_EXISTING).apply {
            setAppPackageName(packageName)
            setDontKillApp(true)
        }
+4 −4
Original line number Diff line number Diff line
/*
 * Copyright ECORP SAS 2022
 * Copyright ECORP SAS 2022-2025
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
@@ -45,12 +45,12 @@ class SplitInstallBroadcastReceiver : BroadcastReceiver() {
        }

        if (extras.get(PM_INSTALL_EXTRA_STATUS_KEY) != MODULE_INSTALLED_SUCCESS_STATUS) {
            val statusMessage = extras.get(PM_INSTALL_EXTRA_STATUS_MESSAGE_KEY)
            val statusMessage = extras.getString(PM_INSTALL_EXTRA_STATUS_MESSAGE_KEY)
            Log.e(TAG, "Could not install a split apk: $statusMessage")
            return
        }

        val updatedPackage = extras.get(PM_INSTALL_EXTRA_PACKAGE_NAME_KEY)
        val updatedPackage = extras.getString(PM_INSTALL_EXTRA_PACKAGE_NAME_KEY)
        Log.i(TAG, "Package updated successfully: $updatedPackage")
    }
}
+1 −12
Original line number Diff line number Diff line
/*
 * Copyright ECORP SAS 2022
 * Copyright ECORP SAS 2022-2025
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
@@ -16,21 +16,10 @@

package foundation.e.splitinstall.service

import android.app.Notification
import android.app.NotificationChannel
import android.app.NotificationManager
import android.app.Service
import android.app.PendingIntent
import android.content.Context
import android.content.Intent
import android.content.pm.PackageInstaller.Session
import android.content.pm.PackageInstaller.SessionParams
import android.os.Build
import android.os.IBinder
import android.util.Log
import foundation.e.splitinstall.service.R

import java.io.File

class SplitInstallService : Service() {