Skip to content

Commit

Permalink
fix(android): Set theme an content view on onCreate (#4841)
Browse files Browse the repository at this point in the history
  • Loading branch information
jcesarmobile authored Jul 16, 2021
1 parent 0479822 commit 8950c60
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ public class BridgeActivity extends AppCompatActivity {
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
bridgeBuilder.setInstanceState(savedInstanceState);
getApplication().setTheme(getResources().getIdentifier("AppTheme_NoActionBar", "style", getPackageName()));
setTheme(getResources().getIdentifier("AppTheme_NoActionBar", "style", getPackageName()));
setTheme(R.style.AppTheme_NoActionBar);
setContentView(R.layout.bridge_layout_main);
}

/**
Expand Down Expand Up @@ -63,11 +67,6 @@ protected void load(Bundle savedInstanceState) {
}

private void load() {
getApplication().setTheme(getResources().getIdentifier("AppTheme_NoActionBar", "style", getPackageName()));
setTheme(getResources().getIdentifier("AppTheme_NoActionBar", "style", getPackageName()));
setTheme(R.style.AppTheme_NoActionBar);
setContentView(R.layout.bridge_layout_main);

Logger.debug("Starting BridgeActivity");

bridge = bridgeBuilder.addPlugins(initialPlugins).setConfig(config).create();
Expand Down

0 comments on commit 8950c60

Please sign in to comment.