简体   繁体   中英

Can't build apk because of Cordova plugin that seems to overwrite Theme.AppCompat

I'm having an issue with a plugin called cordova-plugin-kiosk. I did not have this issue before but I'm unable to build the apk successfully or the app crashes in the emulator. It seems it has something to do with the following setting in the AndroidManifest.xml android:theme="@android:style/Theme.DeviceDefault.NoActionBar" . I'm not sure what to replace that with and still make the plugin work. Also here is the error I get in the log:

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.tablezig.v6/org.cordova.plugin.labs.kiosk.KioskActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.

我通过将以下内容添加到<activity> android:theme="@style/Theme.AppCompat.DayNight.NoActionBar"中的 AndroidManifest.xml 解决了这个问题

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM