https://kotlinlang.org logo
#android
Title
# android
g

Giovani Guerra

02/03/2021, 5:39 PM
How to write this with Kotlin?
Copy code
static {
    AppCompatDelegate.setDefaultNightMode(
        AppCompatDelegate.MODE_NIGHT_NO);
}
public class MyApplication extends Application {
}
google 5
d

Diego

02/03/2021, 7:06 PM
Copy code
class MyApplication : Application() {
    init { 
        AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_NO)
    }
}
❤️ 1
h

Henry

02/09/2021, 1:19 PM
You can use convert tool was embedded in Android Studio to change from Java to Kotlin by yourself
12 Views