forked from GitHub-Mirror/riotX-android
Merge pull request #463 from vector-im/feature/fix_theme
Fix theme not well defined at runtime after configurationChange
This commit is contained in:
commit
23466fb5a4
@ -119,6 +119,8 @@ abstract class VectorBaseActivity : BaseMvRxActivity(), HasScreenInjector {
|
|||||||
injectWith(screenComponent)
|
injectWith(screenComponent)
|
||||||
}
|
}
|
||||||
Timber.v("Injecting dependencies into ${javaClass.simpleName} took $timeForInjection ms")
|
Timber.v("Injecting dependencies into ${javaClass.simpleName} took $timeForInjection ms")
|
||||||
|
ThemeUtils.setActivityTheme(this, getOtherThemes())
|
||||||
|
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
viewModelFactory = screenComponent.viewModelFactory()
|
viewModelFactory = screenComponent.viewModelFactory()
|
||||||
configurationViewModel = ViewModelProviders.of(this, viewModelFactory).get(ConfigurationViewModel::class.java)
|
configurationViewModel = ViewModelProviders.of(this, viewModelFactory).get(ConfigurationViewModel::class.java)
|
||||||
@ -135,8 +137,6 @@ abstract class VectorBaseActivity : BaseMvRxActivity(), HasScreenInjector {
|
|||||||
|
|
||||||
// Shake detector
|
// Shake detector
|
||||||
|
|
||||||
ThemeUtils.setActivityTheme(this, getOtherThemes())
|
|
||||||
|
|
||||||
doBeforeSetContentView()
|
doBeforeSetContentView()
|
||||||
|
|
||||||
if (getLayoutRes() != -1) {
|
if (getLayoutRes() != -1) {
|
||||||
|
Loading…
Reference in New Issue
Block a user