Creating Application Class

Let's create an Application Class (if you don't have one)
  1. 1.
    Open your main AndroidManifest.xml
  2. 2.
    Add android:name=".NewApplicationClass" to your <application> tag
<manifest xmlns:android="<http://schemas.android.com/apk/res/android>"
package="is.leap.android.test">
<application
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:name=".NewApplicationClass">
...
</application>
</manifest>
  1. 1.
    Hover over android:name=".NewApplicationClass" or press Alt + Enter or Option + Enter and select Create class NewApplicationClass
Java
Kotlin
import android.app.Application;
public class NewApplicationClass extends Application {
@Override
public void onCreate() {
super.onCreate();
// TODO: Start Leap SDK here
}
}
import android.app.Application
class NewApplicationClass : Application() {
override fun onCreate() {
super.onCreate()
// TODO: Add Leap SDK initialization here
}
}