- 博客(18)
- 收藏
- 关注
转载 AndroidStudio 运行时 read timeout
在项目的build.gradle中 repositories和allprojects添加...mavenCentral()maven { url 'https://maven.google.com' }...并将jcenter()放到这两个的下面
2018-09-13 16:18:25
5462
原创 IjkPlayer的简单使用
//配置权限//导入依赖implementation 'com.dou361.ijkplayer:jjdxm-ijkplayer:1.0.6'//布局文件引入控件<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk...
2018-08-09 14:51:18
493
原创 Retrofit 相机相册上传头像
接口地址https://www.zhaoapi.cn/file/upload 参数uid=用户id&file=文件//上传头像@Multipart@POST(AppConstant.USER_UP_LOAD_PIC)Call<UpLoadBean> upLoadPic(@Query("uid") String mobile, @Part MultipartBo...
2018-07-22 21:36:09
353
原创 流式布局的简单实现
public class MyFlow extends ViewGroup { public MyFlow(Context context) { super(context); } public MyFlow(Context context, AttributeSet attrs) { this(context, attrs,0); ...
2018-07-01 20:04:32
472
原创 AS属性动画的简单实现
//平移 ObjectAnimator translationAnim = ObjectAnimator.ofFloat(img, "translationX", 2f, 800f,0f); translationAnim.setDuration(3000); translationAnim.start(); //旋转 ObjectAnimator ...
2018-06-23 08:54:51
921
原创 OkHttp的简单使用
public class NetUtilsOk { /** * get请求 * @param mUrl 请求地址 * @param okCallBack 回调接口 */ public static void getNetData(String mUrl, final OkCallBack okCallBack){ //bui...
2018-06-20 14:38:29
343
原创 h5 table添加删除 隔行换色
<!DOCTYPE html><html> <head> <meta charset="utf-8" /> <title></title> <script src="js/jquery-3.2.1.min.js"></script>
2018-05-15 08:51:45
481
原创 css鼠标滑过旋转
<!DOCTYPE html><html><head><meta charset="utf-8"> <title>css鼠标滑过旋转</title> <style> div{ width:200px; height:100px; background-color:yellow; /* Rotat
2018-05-12 09:54:34
1992
原创 js 操控style属性修改标签背景图片
document.getElementById("st").style.backgroundImage="url('img/005XSXmNgy1fpsv01g24nj30hs0hsjsk.jpg')";
2018-05-11 09:01:33
11590
原创 tablayout+viewpager适配
//布局<?xml version="1.0" encoding="utf-8"?><RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layou...
2018-05-04 07:58:59
265
原创 轮播图+原点图标
<?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_paren
2018-05-04 07:55:53
1037
原创 轮播图适配
public class MyViewpagerAdapter extends PagerAdapter { private Context context; private List<String> list; private DisplayImageOptions options; private ImageLoaderConfiguration confi...
2018-05-03 18:58:48
598
原创 pulltorefresh嵌套listview重写listview高度
public class MyListView extends ListView { public MyListView(Context context) { super(context); } public MyListView(Context context, AttributeSet attrs) { super(context, ...
2018-04-25 13:46:49
404
原创 ImageLoader的使用
package wangguifa.bwie.com.demo2;import android.graphics.Bitmap;import android.os.Environment;import android.support.v7.app.AppCompatActivity;import android.os.Bundle;import android.widget.Image...
2018-04-16 20:05:15
201
原创 HttpClient加载图片
//加载图片private Bitmap loadNetImage(String urlS){ HttpClient httpClient = new DefaultHttpClient(); HttpGet httpGet = new HttpGet(urlS); try { HttpResponse httpResponse = httpCli...
2018-04-13 20:48:07
671
原创 处理HttpUrlConnection重定向的判断
private void requestNetData () {try { URL url = new URL("http://www.toutiao.com/stream/widget/local_weather/data/?city=%E5%8C%97%E4%BA%AC"); HttpURLConnection urlConnection = (HttpURLConnecti...
2018-04-13 09:48:16
2777
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人