Android 启动白屏,简单解决方法

 

1、打开styles、找到ThemeSplash,或者AppTheme

 

添加windowBackground即可/windowFullscreen是满屏属性。可去掉

也就是添加启动背景图

 

<style name="ThemeSplash" parent="Theme.AppCompat.Light.NoActionBar"><item name="android:windowNoTitle">true</item><item name="android:windowFullscreen">true</item><item name="windowActionBar">false</item><item name="windowNoTitle">true</item><item name="android:windowBackground">@mipmap/newbg</item>
</style>

2、在application使用这个style即可实现启动不白屏或者黑屏,或者在LAUNCHER.activity中使用该style

 

<activity android:name="com.tianxinyw.mapclient.liteapp.TwoMainActivity"android:screenOrientation="portrait"android:launchMode="singleTask"android:theme="@style/ThemeSplash"><intent-filter><action android:name="android.intent.action.MAIN" /><category android:name="android.intent.category.LAUNCHER" /></intent-filter>
</activity>

 

<applicationandroid:name=".YwApplication"android:allowBackup="true"android:icon="@mipmap/ywlogo"android:label="@string/app_name"android:largeHeap="true"android:supportsRtl="true"tools:replace="android:icon, android:label, android:theme"android:theme="@style/ThemeSplash">

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/415033.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

工作200:视频上传和图片编辑功能

1眼睛一定要看清 本地接口 稳得很

highcharts x轴 按照时间 datetime排序

1、我的配置文件代码&#xff1a; var chart Highcharts.chart(warningCharts, {chart: {type: line,},style: {fontSize: 12px,color: #006cee,padding: 10rpx,},title: {text: null,},subtitle: {text: null,},series: data,xAxis: {type: datetime,dateTimeLabelFormats: …

Android 起调系统功能,打开系统浏览器,拨打电话,发送短信,手机震动,跳转到设置通知开关页面

1、打开系统浏览器 try {startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://github.com/jaredrummler/MaterialSpinner"))); } catch (ActivityNotFoundException ignored) { } 2、拨打电话 Intent intent new Intent(Intent.ACTION_DIAL, Uri.pa…

B. 重载技术(overloading)

转载于:https://www.cnblogs.com/youyuanjuyou/p/8120968.html

Highchart series一次只显示一条

核心代码如下&#xff1a; plotOptions: {series: {events: {show: function () {const chart this.chartconst series chart.serieslet i series.lengthlet otherSerieswhile (i--) {otherSeries series[i];if (otherSeries ! this && otherSeries.visible) {oth…

android xml中设置水平虚线及竖直虚线

水平线背景 <?xml version"1.0" encoding"utf-8"?> <shape xmlns:android"http://schemas.android.com/apk/res/android"android:shape"line"><strokeandroid:width"1dp"android:color"color/colorA…

highcharts默认选中最后一个点数据

效果图如下&#xff1a; 核心代码如下&#xff1a; chart: {type: line,events: {load: function () {let chart thisconst points []Highcharts.each(chart.series, function (s) {if (s.visible) {points.push(s.points[s.points.length - 1])}})chart.tooltip.refresh(p…

Ajax——php基础知识(二)

header header(content-type:text/html; charset utf-8);//设置编码格式为:utf-8 header(location:http://www.baidu.com);//设置跳转到百度首页 header(refresh:3; urlhttp://www.xiaomi.com);//设置页面间隔刷新 数据类型 <?phpheader("content-type:text/html;char…

python utc 时间

python中&#xff0c;我们使用datetime处理日期、时间相关。 获取当前时间&#xff0c;主要有两个方法&#xff1a; datetime.now datetime.now()&#xff1a;读取的时间是系统的本地时间&#xff0c;也就是说&#xff0c;如果系统时区默认没有设置&#xff0c;那么读取的就是世…

[02] JSP内置对象

1、内置对象的来历JSP是由一些内置对象的&#xff0c;即不需要定义&#xff0c;也不需要我们主动创建&#xff0c;就可以直接使用的对象。当然&#xff0c;其对象名称也是固定的&#xff0c;无法修改&#xff0c;我们可以直接调用其相关方法。在 [01] JSP的基本认识 已经说过JS…

上传Android应用到腾讯应用宝,乐固加固应用使用

当我们开发完安卓系统APP之后。需要上传到应用市场 在上传到腾讯应用宝是&#xff0c;需要使用腾讯加固工具 乐固 加固apk。才能正常上架。 如没有加固应用会提示&#xff1a; 加固步骤: 1、下载乐固包&#xff1a;https://download.csdn.net/download/meixi_android/107534…

工作203:实现预览效果

1子组件 成功 ChangeRest(event, file){/* console.log(event)console.log(file)*//* console.log(URL.createObjectURL(file.raw))*/this.imageUrl URL.createObjectURL(file.raw);/* this.imageUrlevent.tmp_urlconsole.log(this.imageUrl)*/console.log(1)this.eventSav…

python根据文件路径获取上级目录路径

import ospath /Users/caowei/数据集/Stable/EN-2300-103-RevA.txtp_path os.path.abspath(os.path.join(path, "..")) print(p_path)saveDir os.path.dirname(path) print(saveDir)

【深入Java虚拟机】之一:Java内存区域与内存溢出

内存区域 Java虚拟机在执行Java程序的过程中会把他所管理的内存划分为若干个不同的数据区域。Java虚拟机规范将JVM所管理的内存分为以下几个运行时数据区&#xff1a;程序计数器、Java虚拟机栈、本地方法栈、Java堆、方法区。下面详细阐述各数据区所存储的数据类型。 程序计数器…

java.lang.NoSuchMethodError: android.app.Notification$Builder.setChannelId

报错原因&#xff1a;低版本安卓系统没有这个setChannelld方法 解决方法&#xff1a; 判断当前手机版本进行调用setChannelld if (Build.VERSION.SDK_INT > Build.VERSION_CODES.O) {builder.setChannelId("com.tianxin.mapclient.liteapp"); }

工作204:进行输入成功后验证

this.$refs["form"].validate(valid > {if (valid) {setTimeout(() > {this.$message("校验成功")/*声明变量*/let method postAction;/*声明url* position()* *//*url/user*/let url this.url.add;/*4 判断是否有id 确定新增还是编辑 根据表单数…

python判断是否在docker中

设定很简单&#xff0c;docker中有一个文件.dockerenv&#xff0c;只要判断此文件是否存在&#xff0c;来判断python是否运行在docker环境中。代码如下&#xff1a; import os def idDocker():return os.path.exists(/.dockerenv)

文件手动删除后 同步到git

http://www.tk4479.net/xiaoyuanzhiying/article/details/44085135转载于:https://www.cnblogs.com/wzqx/p/8137829.html

Android应用安装apk版本升级,适配Android 8.0和Android 10.0下载安装,shell命令安装APK

安装失败&#xff0c;gradle.properties文件下添加 即可 android.injected.testOnly false shell命令安装 /*** 安装apk** param path apk文件路径*/ public void installAPK(String path) {Log.i(TAG, "installAPK:" path);com.dlc.xiaohaitun.utils.ShellUtil…