-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainActivityMatt.java
More file actions
41 lines (31 loc) · 1015 Bytes
/
MainActivityMatt.java
File metadata and controls
41 lines (31 loc) · 1015 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package cs2340.woms;
import android.os.Bundle;
import android.app.Activity;
import android.view.*;
import android.content.Intent;
import android.widget.Button;
import android.view.View.OnClickListener;
public class MainActivityMatt extends Activity {
Button loginButton;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main_activity_matt);
loginButton = (Button) this.findViewById(R.id.button1);
loginButton.setOnClickListener(new OnClickListener(){
public void onClick(View v){
Intent intent = new Intent(MainActivityMatt.this,LoginScreen.class);
startActivity(intent);
};
});
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(R.menu.main_activity_matt, menu);
return true;
}
public void gotoLogin(View x){
Intent intent = new Intent(this, LoginScreen.class);
}
}