InputProfilFirstSixActivity.kt
1.2 KB
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
package com.example.vip
import android.content.Context
import android.content.Intent
import android.content.SharedPreferences
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import kotlinx.android.synthetic.main.activity_input_profil_first_six.*
class InputProfilFirstSixActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_input_profil_first_six)
previousButton.setOnClickListener {
var intent = Intent(this, InputProfilFirstFiveActivity::class.java)
startActivity(intent)
}
val prof: SharedPreferences =getSharedPreferences("profdata", Context.MODE_PRIVATE)
val editor: SharedPreferences.Editor=prof.edit()
nextButton.setOnClickListener {
if(gagoojooButton.isChecked){
editor.putInt("c13_2",1); editor.commit()
}else if(gagoowonButton.isChecked){
editor.putInt("c13_3",1); editor.commit()
}else{
}
var intent = Intent(this, InputProfilSecondOneActivity::class.java)
startActivity(intent)
}
}
}