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

BOE launches 110-inch "4K giant screen" to display 1:1 real-life images

[September 9 news] Yesterday, a message came from ...

How to optimize single-page website SEO? What are the common SEO problems?

Q: What is the specific process of keyword optimi...

Taobao live streaming methodology!

Brands’ self-broadcasting on Tmall presents both ...

"China's Sky Eye" has made new discoveries!

The "China Sky Eye" has made new discov...

[Case sharing] How did she gain 1 million followers in just two months?

1. My date was disrupted I was supposed to go on ...

My Primary Growth Map

The Internet has developed to this stage, and the...