You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
1.2 KiB
40 lines
1.2 KiB
package com.example.test1;
|
|
|
|
import android.annotation.SuppressLint;
|
|
import android.app.Activity;
|
|
import android.os.Bundle;
|
|
import android.view.View;
|
|
import android.view.View.OnClickListener;
|
|
import android.content.Intent;
|
|
import android.widget.Button;
|
|
import android.widget.*;
|
|
|
|
public class User_Activity extends Activity{
|
|
Button button = null;
|
|
@Override
|
|
protected void onCreate(Bundle savedInstanceState) {
|
|
super.onCreate(savedInstanceState);
|
|
setContentView(R.layout.content_user);
|
|
|
|
button = (Button)findViewById(R.id.button);
|
|
button.setOnClickListener(new View.OnClickListener() {
|
|
@Override
|
|
public void onClick(View v) {
|
|
Intent intent = new Intent();
|
|
intent.setClass(User_Activity.this,LoginActivity.class);
|
|
startActivity(intent);
|
|
}
|
|
});
|
|
|
|
button = (Button)findViewById(R.id.p1);
|
|
button.setOnClickListener(new View.OnClickListener() {
|
|
@Override
|
|
public void onClick(View v) {
|
|
Intent intent = new Intent();
|
|
intent.setClass(User_Activity.this,Fragment.class);
|
|
startActivity(intent);
|
|
}
|
|
});
|
|
}
|
|
|
|
} |