
移动Android开发
文章平均质量分 70
彦4212
这个作者很懒,什么都没留下…
展开
-
urlConnection 请求数据类的封装
URL url = new URL(urlString); //用url打开链接 HttpURLConnection urlConnection = (HttpURLConnection) url.openConnection(); //联网的状态码 int responseCode = urlConnection.getResponseCode(); if(responseCode ==原创 2017-09-28 11:09:45 · 280 阅读 · 0 评论 -
Android 实现两种黑白天模式切换
第一种一、依赖compile 'com.android.support:appcompat-v7:26.1.0'二、布局<TextView android:id="@+id/yejian" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text=...原创 2018-04-26 19:43:28 · 1441 阅读 · 0 评论 -
Android 简单实现点赞功能
一、依赖compile 'com.ldoublem.thumbUplib:ThumbUplib:0.5'二、布局<com.ldoublem.thumbUplib.ThumbUpView android:id="@+id/tpv" android:layout_width="50dp" android:layout_height="50dp" app:crack...原创 2018-04-26 19:33:07 · 4528 阅读 · 1 评论 -
Android 点赞飘心
一、依赖compile 'com.wx.goodview:goodview:1.0.0'二、布局<wangyanyong.packag.com.dianzan.DivergeViewSecond android:id="@+id/divergeView" android:layout_width="match_parent" android:layout_height...原创 2018-04-26 19:27:02 · 569 阅读 · 0 评论 -
弹幕opendanmaku.DanmakuView+节操播放器JCVideoPlayerStandard的实现
一、依赖//弹幕compile 'com.linsea:opendanmaku:1.0.0@aar'//节操播放器compile 'fm.jiecao:jiecaovideoplayer:5.5'compile 'com.github.bumptech.glide:glide:3.7.0'//根据自己的喜好,使用图片加载框架二、布局<?xml version="1.0" encodi...原创 2018-04-26 19:20:47 · 782 阅读 · 0 评论 -
RecycleView设置点击事件On ——>内部接口OnItemTouchListener
新建RecyclerViewClickListener2.java:public class RecyclerViewClickListener2 implements RecyclerView.OnItemTouchListener { private GestureDetector mGestureDetector; private OnItemClickListener m...转载 2018-04-18 19:09:21 · 3197 阅读 · 0 评论 -
OkHttp+RecycleView展示网络数据
1、依赖,权限compile 'com.android.support:recyclerview-v7:26.0.0-alpha1'compile 'com.squareup.okhttp3:okhttp:3.8.1'compile 'com.google.code.gson:gson:2.8.2'compile 'com.github.bumptech.glide:glide:3.5.2'...原创 2018-04-16 14:58:53 · 625 阅读 · 0 评论 -
Android防京东分类
效果如下:一、activity_main<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_...原创 2018-03-29 19:41:14 · 599 阅读 · 0 评论 -
Android 购物车
//购物车的适配器public class GoodsAdapter extends BaseExpandableListAdapter { private Context context; private List groupList; private List> childList; private LayoutInflater inflater;转载 2018-01-16 11:45:03 · 317 阅读 · 0 评论 -
图片菜单-属性动画
一、布局<?xml version="1.0" encoding="utf-8"?><android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/ap...原创 2018-04-27 19:02:29 · 251 阅读 · 0 评论