@@ -45,27 +45,23 @@ class SplashScreenActivity : AppCompatActivity() {
4545 override fun onStart () {
4646 super .onStart()
4747
48- APISamplesInJava .samplesForCmab(this )
49- APISamplesInJava .samplesForCmabConfig(this )
50- APISamplesInJava .samplesForCmabConfig_endpoint(this )
51-
52- // val INITIALIZE_ASYNCHRONOUSLY = true
53- //
54- // // with the new Android O differences, you need to register the service for the intent filter you desire in code instead of
55- // // in the manifest.
56- // val eventRescheduler = EventRescheduler()
57- // applicationContext.registerReceiver(eventRescheduler, IntentFilter(WifiManager.WIFI_STATE_CHANGED_ACTION))
58- //
59- // if (INITIALIZE_ASYNCHRONOUSLY) {
60- // optimizelyManager!!.initialize(this, R.raw.datafile) { _ ->
61- // addNotificationListeners()
62- // startVariation()
63- // }
64- // } else {
65- // optimizelyManager!!.initialize(this, R.raw.datafile)
66- // addNotificationListeners()
67- // startVariation()
68- // }
48+ val INITIALIZE_ASYNCHRONOUSLY = true
49+
50+ // with the new Android O differences, you need to register the service for the intent filter you desire in code instead of
51+ // in the manifest.
52+ val eventRescheduler = EventRescheduler ()
53+ applicationContext.registerReceiver(eventRescheduler, IntentFilter (WifiManager .WIFI_STATE_CHANGED_ACTION ))
54+
55+ if (INITIALIZE_ASYNCHRONOUSLY ) {
56+ optimizelyManager!! .initialize(this , R .raw.datafile) { _ ->
57+ addNotificationListeners()
58+ startVariation()
59+ }
60+ } else {
61+ optimizelyManager!! .initialize(this , R .raw.datafile)
62+ addNotificationListeners()
63+ startVariation()
64+ }
6965
7066 }
7167
0 commit comments