package com.example.plugina;

import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import com.bingo.apkloader.base.ApkBaseActivity;
import com.bingo.apkloader.base.ApkIntent;

public class ActivityA extends ApkBaseActivity implements View.OnClickListener {
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        this.setContentView(R.layout.activity_test);

        Button btnStartActivityB = (Button) this.findViewById(R.id.btnStartActivityB);
        btnStartActivityB.setOnClickListener(this);
        Button btnStartActivityC = (Button) this.findViewById(R.id.btnStartActivityC);
        btnStartActivityC.setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        ApkIntent apkIntent = new ApkIntent();
        apkIntent.setPackageName("com.example.plugina");
        if (v.getId() == R.id.btnStartActivityB){
            apkIntent.setClassName(ActivityB.class);
            this.startActivity(apkIntent);
        }
//        else if (v.getId() == R.id.btnStartActivityC){
//            apkIntent.setClassName(ActivityC.class);
//            this.startActivity(apkIntent);
//        }
    }
}
