// Path: app/src/main/java/com/topnews/android/adapter/ShareIconAdapter.java
// public class ShareIconAdapter extends RecyclerView.Adapter<ShareIconAdapter.ViewHolder>{
// 
//     private ArrayList<ShareIconInfo> mDatas;
//     private ImageView mImage;
//     private EditText et_input;
// 
//     static class ViewHolder extends RecyclerView.ViewHolder{
// 
//         ImageView iv_cutoon;
//         ImageView iv_select;
// 
//         View itemView;
// 
//         public ViewHolder(View itemView) {
//             super(itemView);
// 
//             this.itemView=itemView;
// 
//             iv_cutoon=  (ImageView) itemView.findViewById(R.id.iv_cutoon);
//             iv_select= (ImageView) itemView.findViewById(R.id.iv_select);
//         }
//     }
// 
//     public ShareIconAdapter(ArrayList<ShareIconInfo> mDatas, ImageView imageView , EditText editText){
// 
//         this.mDatas=mDatas;
//         this.mImage=imageView;
//         this.et_input=editText;
//     }
// 
//     @Override
//     public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
// 
//         View view= LayoutInflater.from(parent.getContext()).inflate(R.layout.share_recycler_item,parent,false);
//         final ViewHolder holder=new ViewHolder(view);
// 
//         holder.itemView.setOnClickListener(new View.OnClickListener() {
//             @Override
//             public void onClick(View v) {
// 
//                 for (ShareIconInfo iconBean:mDatas) {
//                     iconBean.isSelected=false;
//                 }
// 
//                 int position=holder.getAdapterPosition();
//                 mDatas.get(position).isSelected=true;
//                 notifyDataSetChanged();
//                 mImage.setImageResource(mDatas.get(position).mIconId);
//                 et_input.setText(mDatas.get(position).des);
// 
//             }
//         });
// 
//         return holder;
//     }
// 
//     @Override
//     public void onBindViewHolder(ViewHolder holder, int position) {
// 
//         ShareIconInfo mIcon=mDatas.get(position);
// 
//         holder.iv_cutoon.setImageResource(mIcon.mIconId);
//         holder.iv_select.setImageResource(R.drawable.select);
// 
//         if(mIcon.isSelected){
//             holder.iv_select.setVisibility(View.VISIBLE);
//         }else{
//             holder.iv_select.setVisibility(View.INVISIBLE);
//         }
// 
//     }
// 
//     @Override
//     public int getItemCount() {
//         return mDatas.size();
//     }
// }
// 
// Path: app/src/main/java/com/topnews/android/gson/ShareIconInfo.java
// public class ShareIconInfo {
// 
//     public boolean isSelected;
// 
//     public int mIconId;       //图片Id
// 
//     public String des;        //描述信息
// }


import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.Bundle;
import android.os.Environment;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.support.v7.widget.Toolbar;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.WindowManager;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.Toast;
import com.topnews.android.R;
import com.topnews.android.adapter.ShareIconAdapter;
import com.topnews.android.gson.ShareIconInfo;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.ArrayList;
import cn.sharesdk.framework.ShareSDK;
import cn.sharesdk.onekeyshare.OnekeyShare;
package com.topnews.android.ui;





public class ScreenCutActivity extends AppCompatActivity implements View.OnClickListener{

    private ImageView imageView;
    private RecyclerView mRecycler;

    private int[] iconIds;
    private ArrayList<ShareIconInfo> mDatas;
    private ImageView iv_icon_show;
    private EditText et_input;
    private Toolbar toolbar;
    private ImageView mOne;
    private ImageView mTwo;
    private ImageView mThree;
// Path: app/src/main/java/com/topnews/android/adapter/ShareIconAdapter.java
// public class ShareIconAdapter extends RecyclerView.Adapter<ShareIconAdapter.ViewHolder>{
// 
//     private ArrayList<ShareIconInfo> mDatas;
//     private ImageView mImage;
//     private EditText et_input;
// 
//     static class ViewHolder extends RecyclerView.ViewHolder{
// 
//         ImageView iv_cutoon;
//         ImageView iv_select;
// 
//         View itemView;
// 
//         public ViewHolder(View itemView) {
//             super(itemView);
// 
//             this.itemView=itemView;
// 
//             iv_cutoon=  (ImageView) itemView.findViewById(R.id.iv_cutoon);
//             iv_select= (ImageView) itemView.findViewById(R.id.iv_select);
//         }
//     }
// 
//     public ShareIconAdapter(ArrayList<ShareIconInfo> mDatas, ImageView imageView , EditText editText){
// 
//         this.mDatas=mDatas;
//         this.mImage=imageView;
//         this.et_input=editText;
//     }
// 
//     @Override
//     public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
// 
//         View view= LayoutInflater.from(parent.getContext()).inflate(R.layout.share_recycler_item,parent,false);
//         final ViewHolder holder=new ViewHolder(view);
// 
//         holder.itemView.setOnClickListener(new View.OnClickListener() {
//             @Override
//             public void onClick(View v) {
// 
//                 for (ShareIconInfo iconBean:mDatas) {
//                     iconBean.isSelected=false;
//                 }
// 
//                 int position=holder.getAdapterPosition();
//                 mDatas.get(position).isSelected=true;
//                 notifyDataSetChanged();
//                 mImage.setImageResource(mDatas.get(position).mIconId);
//                 et_input.setText(mDatas.get(position).des);
// 
//             }
//         });
// 
//         return holder;
//     }
// 
//     @Override
//     public void onBindViewHolder(ViewHolder holder, int position) {
// 
//         ShareIconInfo mIcon=mDatas.get(position);
// 
//         holder.iv_cutoon.setImageResource(mIcon.mIconId);
//         holder.iv_select.setImageResource(R.drawable.select);
// 
//         if(mIcon.isSelected){
//             holder.iv_select.setVisibility(View.VISIBLE);
//         }else{
//             holder.iv_select.setVisibility(View.INVISIBLE);
//         }
// 
//     }
// 
//     @Override
//     public int getItemCount() {
//         return mDatas.size();
//     }
// }
// 
// Path: app/src/main/java/com/topnews/android/gson/ShareIconInfo.java
// public class ShareIconInfo {
// 
//     public boolean isSelected;
// 
//     public int mIconId;       //图片Id
// 
//     public String des;        //描述信息
// }


// Path: app/src/main/java/com/topnews/android/ui/ScreenCutActivity.java
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.Bundle;
import android.os.Environment;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.support.v7.widget.Toolbar;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.WindowManager;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.Toast;
import com.topnews.android.R;
import com.topnews.android.adapter.ShareIconAdapter;
import com.topnews.android.gson.ShareIconInfo;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.ArrayList;
import cn.sharesdk.framework.ShareSDK;
import cn.sharesdk.onekeyshare.OnekeyShare;

package com.topnews.android.ui;





public class ScreenCutActivity extends AppCompatActivity implements View.OnClickListener{

    private ImageView imageView;
    private RecyclerView mRecycler;

    private int[] iconIds;
    private ArrayList<ShareIconInfo> mDatas;
    private ImageView iv_icon_show;
    private EditText et_input;
    private Toolbar toolbar;
    private ImageView mOne;
    private ImageView mTwo;
    private ImageView mThree;
    private ShareIconAdapter mAdapter;