import static com.example.administrator.myandroid.BroadcastReceive.AnotherActivity.ACTION;
public class MyReceiveActivity extends Activity implements View.OnClickListener { private Button mBtnStartReceive; private Button mBtnStopReceive; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_receive); mBtnStartReceive = (Button) findViewById(R.id.start_receive); mBtnStopReceive = (Button) findViewById(R.id.stop_receive); mBtnStartReceive.setOnClickListener(this); mBtnStopReceive.setOnClickListener(this); } private boolean flagReceiveRegis; @Override public void onClick(View v) { switch (v.getId()) { case R.id.start_receive: IntentFilter intentFilter = new IntentFilter(); intentFilter