Toggle navigation
Toggle navigation
This project
Loading...
Sign in
신기성
/
WELLO
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Commits
Issue Boards
Authored by
신기성
2019-11-11 01:33:16 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
618e03ca54755e4cc357e99a932838c7770032ba
618e03ca
1 parent
f8ccdbe8
first third problem resolve
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
44 deletions
vip/app/src/main/java/com/example/vip/InputProfilFirstThreeActivity.kt
vip/app/src/main/java/com/example/vip/InputProfilFirstTwoActivity.kt
vip/app/src/main/java/com/example/vip/InputProfilFirstThreeActivity.kt
View file @
618e03c
...
...
@@ -35,46 +35,11 @@ class InputProfilFirstThreeActivity : AppCompatActivity() {
val
prof
:
SharedPreferences
=
getSharedPreferences
(
"profdata"
,
Context
.
MODE_PRIVATE
)
val
editor
:
SharedPreferences
.
Editor
=
prof
.
edit
()
manButton
.
setOnClickListener
{
var
id
:
Int
=
radio_group
.
checkedRadioButtonId
if
(
id
!=-
1
){
val
radio
:
RadioButton
=
findViewById
(
id
)
editor
.
putString
(
"manorwoman"
,
"man"
)
editor
.
commit
()
/*
Toast.makeText(applicationContext,"On button click : ${radio.text}"+prof.getString("manorwoman","nothing"),
Toast.LENGTH_SHORT).show()
*/
}
else
{
}
}
womanButton
.
setOnClickListener
{
var
id
:
Int
=
radio_group
.
checkedRadioButtonId
if
(
id
!=-
1
){
val
radio
:
RadioButton
=
findViewById
(
id
)
Toast
.
makeText
(
applicationContext
,
"On button click : ${radio.text}"
,
Toast
.
LENGTH_SHORT
).
show
()
editor
.
putString
(
"manorwoman"
,
"woman"
)
editor
.
commit
()
}
else
{
}
}
previousButton
.
setOnClickListener
{
var
intent
=
Intent
(
this
,
InputProfilFirstTwoActivity
::
class
.
java
)
startActivity
(
intent
)
}
var
id
:
Int
=
radio_group
.
checkedRadioButtonId
val
radio
:
RadioButton
=
findViewById
(
id
)
nextButton
.
setOnClickListener
{
var
intent
=
Intent
(
this
,
InputProfilFirstFourActivity
::
class
.
java
)
startActivity
(
intent
)
if
(
(
radio
.
text
)==
"남성"
){
if
(
manButton
.
isChecked
){
editor
.
putInt
(
"c2_1"
,
1
)
editor
.
commit
()
//마지막장에 상관없음 추가
...
...
vip/app/src/main/java/com/example/vip/InputProfilFirstTwoActivity.kt
View file @
618e03c
...
...
@@ -23,28 +23,28 @@ class InputProfilFirstTwoActivity : AppCompatActivity() {
nextButton
.
setOnClickListener
{
var
intent
=
Intent
(
this
,
InputProfilFirstThreeActivity
::
class
.
java
)
startActivity
(
intent
)
var
birthdateinput
=
findViewById
<
EditText
>(
R
.
id
.
editText
).
text
.
toString
().
toInt
()
if
((
2019
-
birthdateinput
)<
19
){
var
birthdateinput
=
findViewById
<
EditText
>(
R
.
id
.
editText
).
text
.
toString
()
var
birthdateint
=
birthdateinput
.
toInt
()
if
((
2019
-
birthdateint
)<
19
){
editor
.
putInt
(
"c1_2"
,
1
)
editor
.
commit
()
//마지막장에 상관없음 추가
}
else
if
((
2019
-
birthdatein
pu
t
)<
34
){
else
if
((
2019
-
birthdateint
)<
34
){
editor
.
putInt
(
"c1_3"
,
1
)
editor
.
commit
()
}
else
if
((
2019
-
birthdatein
pu
t
)<
40
){
else
if
((
2019
-
birthdateint
)<
40
){
editor
.
putInt
(
"c1_4"
,
1
)
editor
.
commit
()
}
else
if
((
2019
-
birthdatein
pu
t
)<
49
){
else
if
((
2019
-
birthdateint
)<
49
){
editor
.
putInt
(
"c1_5"
,
1
)
editor
.
commit
()
}
else
if
((
2019
-
birthdatein
pu
t
)<
59
){
else
if
((
2019
-
birthdateint
)<
59
){
editor
.
putInt
(
"c1_6"
,
1
)
editor
.
commit
()
}
...
...
@@ -52,6 +52,9 @@ class InputProfilFirstTwoActivity : AppCompatActivity() {
editor
.
putInt
(
"c1_7"
,
1
)
editor
.
commit
()
}
var
intent
=
Intent
(
this
,
InputProfilFirstThreeActivity
::
class
.
java
)
startActivity
(
intent
)
}
}
...
...
Please
register
or
login
to post a comment