Opened 10 months ago

#27065 new defect

TBA: Delete AccountManager usage from Tabs

Reported by: sysrqb Owned by: tbb-team
Priority: Medium Milestone:
Component: Applications/Tor Browser Version:
Severity: Normal Keywords: tbb-mobile
Cc: igt0, gk Actual Points:
Parent ID: #26858 Points:
Reviewer: Sponsor:

Description

When the app is started/restarted, it creates an OnAccountsUpdatedListener using the Android AccountManager in Tabs.attachToContext(). When a new account is added, the Listener calls queuePersistAllTabs() where the current tabs are cached in the local database on disk. We should avoid all of this. We already deleted most of the FxA and Sync related code, we can probably delete this, too.

        mAccountManager = AccountManager.get(appContext);

        mAccountListener = new OnAccountsUpdateListener() {
            @Override
            public void onAccountsUpdated(Account[] accounts) {
                queuePersistAllTabs();
            }
        };

        // The listener will run on the background thread (see 2nd argument).
        mAccountManager.addOnAccountsUpdatedListener(mAccountListener, ThreadUtils.getBackgroundHandler(), false);

Child Tickets

Change History (0)

Note: See TracTickets for help on using tickets.