Pull down to record video in the same way as WeChat

Pull down to record video in the same way as WeChat

Source code introduction:

This project is a high imitation of WeChat short video + Miaopai. WeChat has launched the short video function since version 6.0. With the emergence of 4G network, video will be a trend. It can express things that words cannot express, increasing the stickiness of WeChat. Remember when the WeChat short video function was launched, it swept the circle of friends like a virus. Project source: https://github.com/motianhuo/VCameraDemo

Source code effect:

Source code snippet:

  1. package com.example.wechat01.adpter;
  2.   
  3. import android.content.Context;
  4. import android.view.LayoutInflater;
  5. import android.view.View;
  6. import android.view.ViewGroup;
  7. import android.widget.BaseAdapter;
  8. import android.widget.TextView;
  9.   
  10. import com.example.wechat01.R;
  11.   
  12. public   class NewMsgAdpter extends BaseAdapter {
  13. protected Context context;
  14. LayoutInflater mInflater;
  15.   
  16. public NewMsgAdpter(Context ctx) {
  17. context = ctx;
  18. }
  19.   
  20. @Override  
  21. public   int getCount() {
  22. return   5 ;
  23. }
  24.   
  25. @Override  
  26. public Object getItem( int position) {
  27. return   null ;
  28. }
  29.   
  30. @Override  
  31. public   long getItemId( int position) {
  32. return position;
  33. }
  34.   
  35. @Override  
  36. public View getView( int position, View convertView, ViewGroup parent) {
  37. if (convertView == null ) {
  38. convertView = LayoutInflater.from(context).inflate(
  39. R.layout.layout_item_msg, parent, false );
  40. TextView txtnum = (TextView) convertView
  41. .findViewById(R.id.unread_msg_number);
  42. if (position == 0 ) {
  43. txtnum.setVisibility(View.VISIBLE);
  44. } else {
  45. txtnum.setVisibility(View.GONE);
  46. }
  47. }
  48.   
  49. return convertView;
  50. }
  51. }

Download address: http://download..com/data/2171547

<<:  Watch is a powerful open source project abroad

>>:  The common technology terms in the IT circle that you must know in 2016

Recommend

What are the advantages of the newly emerging LTE-A?

SK Telecom's fifth-generation communication n...

Analysis of e-commerce event planning model!

When it comes to event operation, many people'...

How to use growth hacking thinking for promotion?

Back to August 1, 2017, at 11:23 am, I was still ...

What is the most important thing in server hosting?

Today, as the trend of global economic integratio...

How to operate new media? How to write a plan?

How to write a promotion plan for new media opera...

SUSE releases technology trend predictions for 2025

Author: Vishal Ghariwala, CTO, SUSE Asia Pacific ...

What should I do if I forget the Mini Program APP ID?

Q: What to do if you forget your Mini Program APP...

Dynamic zero-clearing & social zero-clearing, what is the difference?

Mixed Knowledge Specially designed to cure confus...