
Android
文章平均质量分 53
未来梦。
这个作者很懒,什么都没留下…
展开
-
解决webview嵌套网页,上传图片和文件点击无反应问题
package com.jsxf.jscqmlbmb.View;import android.content.Intent;import android.net.Uri;import android.os.Bundle;import android.support.annotation.Nullable;import android.util.Log;import android.view.LayoutInflater;import android.view.View;import an.转载 2021-03-04 21:27:22 · 1598 阅读 · 1 评论 -
Android关于欢迎页面启动有短暂白屏问题的解决方案
首先声明,此文章是我在网上找大神的方案进行解决之后的一个记录笔记,方便自己查看,也希望广大朋友多提意见,共同进步1,大多数APP当点击之后直接出现欢迎页面,也有APP是先进入短暂的空白页面再进入欢迎页面原因:1,在Activity启动onCreate()方法,执行setContentView()时出现白屏 &nbs...转载 2019-01-23 14:26:37 · 967 阅读 · 0 评论 -
有时候事件判断时需要弹吐司,但是当你连续点击时,吐司会长时间显示,久久不肯离去
public class MineActivity extends Activity { private Toast toast;//在类前面声明吐司,确保在这个页面只有一个吐司 //需要谈吐司的地方调用showToast() public void showToast() { String msg = "请您先登录"转载 2018-01-29 16:48:19 · 482 阅读 · 0 评论 -
Fragment保存各页面的状态
哇,今天找了好一会,才找到的答案,也就是一行代码就保存了Fragment的页面状态,好开心。我的Fragment是五个页面所以设置了5。这个方法分享给大家。原创 2018-01-09 17:06:37 · 423 阅读 · 0 评论 -
颜色渐变滚动Textview
public class FlashTextView extends android.support.v7.widget.AppCompatTextView { private Paint mPaint; private int mViewWidth; private LinearGradient mLinearGradient; private M转载 2017-11-30 11:08:41 · 437 阅读 · 0 评论 -
设置Textview最大长度,超出显示省略号
<TextView android:id="@+id/tvUserNameUgcListItem" android:layout_height="@dimen/dp45" android:layout_width="wrap_content" android:text="原创 2017-11-08 16:25:16 · 805 阅读 · 0 评论 -
Intent向下一个活动传递数据putExtra
转载自:http://blog.youkuaiyun.com/qq_16758741/article/details/521686361.新建项目2.在layout目录下,在first_layout.xml中添加按钮Button13.在layout目录下,新建second_layout.xml,并添加按钮Button24.在Java目录下,在FirstA.java中转载 2017-11-09 15:14:37 · 589 阅读 · 0 评论 -
显示和隐式的Intent 跳转界面
普通显示Intent 用法Intent intent = new Intent(); intent.setClass(MainActivity.this, activity2.class); startActivity(intent); 隐式Intent用法,通过在标签下配置的内容,可以指定当前活动能够响应的action 和category,打开AndroidMa转载 2017-11-08 10:27:15 · 591 阅读 · 0 评论 -
Android自定义dialog弹出布局
定义一个弹窗布局首先定义一个dailog_set_password.xml布局文件。<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent"转载 2017-10-31 15:35:46 · 908 阅读 · 0 评论