]> git.ktnx.net Git - mobile-ledger.git/commit
asynchronous profile initialisation
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Sun, 11 Apr 2021 20:44:52 +0000 (20:44 +0000)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Sun, 11 Apr 2021 20:44:52 +0000 (20:44 +0000)
commitfac0809065787fb473646db5770f4f2fae0d1e8f
tree6814aa606637066a58bee1fdbccbdf5576275912
parent25cd3a8bb9b8196cddd1f66b7757cadc8248a37f
asynchronous profile initialisation

the problem here was that the startup profile is read from the DB,
synchronously, and all DB operations need to happen via Room off the
main thread

since at activity startup only the theme is needed, that, and the startup
profile ID can be stored in the android preferences. actual loading of
profile and further data can be done after the theme is setup, in the
background, via Room
app/src/main/java/net/ktnx/mobileledger/App.java
app/src/main/java/net/ktnx/mobileledger/dao/ProfileDAO.java
app/src/main/java/net/ktnx/mobileledger/db/DB.java
app/src/main/java/net/ktnx/mobileledger/model/Data.java
app/src/main/java/net/ktnx/mobileledger/model/MobileLedgerProfile.java
app/src/main/java/net/ktnx/mobileledger/ui/activity/MainActivity.java
app/src/main/java/net/ktnx/mobileledger/ui/activity/ProfileThemedActivity.java
app/src/main/java/net/ktnx/mobileledger/ui/activity/SplashActivity.java
app/src/main/java/net/ktnx/mobileledger/ui/new_transaction/NewTransactionActivity.java
app/src/main/java/net/ktnx/mobileledger/ui/profiles/ProfilesRecyclerViewAdapter.java