我已经在我的RN应用中使用https://github.com/crazycodeboy/react-native-splash-screen添加了启动画面,并遇到了下一个问题:如果android设备具有软导航键,则启动画面会在屏幕上显示几毫秒后更改其高度。好像初始高度是屏幕高度,下一个高度是窗口高度(没有软导航键栏的屏幕高度)。
有什么方法可以修复它并不断设置初始屏幕的高度吗?
Mode <- function(x) {
ux <- unique(x)
ux[which.max(tabulate(match(x, ux)))]
}
launch_screen.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/welcome_background"
android:orientation="vertical">
</LinearLayout>
splash_screen_native.xml