Commit e84f3f97 authored by james.clarke2's avatar james.clarke2

Delete DiscountPercent.java

parent 94b6cc1a
import androidx.appcompat.app.AppCompatActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;
import java.util.Random;
public class DiscountPercent extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_discount_percent);
final Random myRandom = new Random();
Button buttonGenerate = (Button)findViewById(R.id.generate);
final TextView textGenerateNumber = (TextView)findViewById(R.id.generatenumber);
buttonGenerate.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
textGenerateNumber.setText(String.valueOf(myRandom.nextInt(50)));
}
});
Button mButton = (Button) findViewById(R.id.button5);
mButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
startActivity(new Intent(DiscountPercent.this, CountdownTimer.class));
}
});
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment