PopupWindow bottom box effect

Previous rendering: When it is displayed, it will slide out from the bottom of the screen. When it disappears, it will slide out. The implementation method is PopWindow. Here is the code: First, define a PopupWindow class as follows: public class BottomPopupOption { //Context object private Context mContext; ...

Posted by hws on Sun, 09 Feb 2020 09:43:56 -0800

Android RefreshLayout implements pull-up refresh drop-down loading and data De duplication list pages

Add the following dependencies to build.gradle of app in the project: //RefreshLayout implementation 'com.scwang.smartrefresh:SmartRefreshLayout:1.1.0' implementation 'com.scwang.smartrefresh:SmartRefreshHeader:1.1.0' //glide is used to load pictures in item implementation 'com.github.bumptech.glide:gl ...

Posted by notaloser on Sat, 08 Feb 2020 06:16:24 -0800

Android - mixed use of ViewPager and Fragment

ViewPager is often used to connect fragments. It is very convenient to manage the life cycle of each page. Using ViewPager to manage fragments is a standard adapter implementation. The most commonly used implementations are fragmentpager adapter and fragmentstatepager adapter. By adding a ViewPager to t ...

Posted by jcrensha627 on Fri, 07 Feb 2020 07:01:16 -0800

How to design a cross platform RTMP/RTSP live player with low latency

Development background In 2015, when we tried to find a low latency player for live broadcast on the market to cooperate with the test of our RTMP push module, we found that none of them were easy to use, such as VLC or Vitamio, which were all based on FFMPEG. There were many supporting formats and ...

Posted by EZE on Fri, 07 Feb 2020 05:34:44 -0800

Android About AIDL Communication, RemoteCallbackList Implements Server Callback Client

Android Interface Definition Language (AIDL) The Android Interface Definition Language (A IDL) is similar to other interface languages (IDLs) you may have used.It allows you to define programming interfaces that are recognized by both clients and services so that they can communicate with each other ...

Posted by BPWheeler on Tue, 04 Feb 2020 19:33:10 -0800

Video decoding with ffmpeg

1. Tool preparation Computer Mac, development tool Android studio 3.4, compilation environment cmake 2. Development steps Create a new module project Create a new cpp folder and a new CMakeLists.txt file in the main directory cmake_minimum_required(VERSION 3.4.1) include_directories(../cpp/incl ...

Posted by vikela on Tue, 04 Feb 2020 10:20:14 -0800

Android - use of recycle view click and long press events

Note: the content of this chapter is Android - RecycleView easy to use Based on the added. 1, RecyclerView click and long press events Unlike ListView, RecyclerView provides click and long press listening events. In RecyclerView, we need to define it in adapter. The code is as follows: RecycleAdapter ...

Posted by Black Hobbit on Tue, 04 Feb 2020 10:02:51 -0800

DrawerLayout sideslip and NavigationView use and stepping on the pit

First, let's go on the renderings. After all, there is no renderings. I don't know if it's the effect you want. When I see half of them, I find they are not very annoyingAdd dependency implementation 'com.android.support:design:28.0.0' Use in layout <?xml version="1.0" encoding="utf-8"?> < ...

Posted by Simon180 on Tue, 04 Feb 2020 06:22:19 -0800

How do I import the system UI to Android studio step by step

Next, I will introduce the system UI to Android studio step by step. Modify the code of the relevant modules of the system. If it's a small modification, it's OK. If it needs more changes, it's best to import the source code into Android studio to modify. The modification efficiency will be improved ...

Posted by deadlyp99 on Tue, 04 Feb 2020 05:44:56 -0800

Get color int from color resource

Is there any way to get color information from color resources? I'm trying to get the red, blue, and green components of the colors defined in the resource (R.color.myColor) so that I can set the values of the three search bars to a specific level. #1 building Define your color Value / color.xml <?xml version="1.0" encoding="utf ...

Posted by Serpent7 on Mon, 03 Feb 2020 01:50:53 -0800