Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- value.addValueEventListener(new ValueEventListener() {
- @Override
- public void onDataChange(DataSnapshot dataSnapshot) {
- long v= (long) dataSnapshot.getValue();
- CountDownTimer countDownTimer=new CountDownTimer(v,1000) {
- @Override
- public void onTick(long millisUntilFinished) {
- show.setText("time : "+millisUntilFinished/1000);
- }
- @Override
- public void onFinish() {
- Intent i=new Intent(Main4Activity.this,OneActivity.class);
- startActivity(i);
- }
- }.start();
- }
- @Override
- public void onCancelled(DatabaseError databaseError) {
- }
Add Comment
Please, Sign In to add comment