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

Commit f7404b7a authored by Ajay Panicker's avatar Ajay Panicker
Browse files

Initialize the Browsable Player list at user unlock instead of boot complete

Bug: 34471252
Test: Code compiles and the browsable player list is built earlier in the boot process
Change-Id: I664e0dbaecade43df58ce464a634306db2910f5b
parent dde97e79
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -291,7 +291,7 @@ public final class Avrcp {
        context.registerReceiver(mAvrcpReceiver, pkgFilter);

        IntentFilter bootFilter = new IntentFilter();
        bootFilter.addAction(Intent.ACTION_BOOT_COMPLETED);
        bootFilter.addAction(Intent.ACTION_USER_UNLOCKED);
        context.registerReceiver(mBootReceiver, bootFilter);
    }

@@ -1414,8 +1414,8 @@ public final class Avrcp {
        @Override
        public void onReceive(Context context, Intent intent) {
            String action = intent.getAction();
            if (action.equals(Intent.ACTION_BOOT_COMPLETED)) {
                if (DEBUG) Log.d(TAG, "Boot completed, initializing player lists");
            if (action.equals(Intent.ACTION_USER_UNLOCKED)) {
                if (DEBUG) Log.d(TAG, "User unlocked, initializing player lists");
                /* initializing media player's list */
                buildBrowsablePlayerList();
            }