Skip to content

Commit 1b0855a

Browse files
committed
country code and country sign added
1 parent 9782e82 commit 1b0855a

File tree

9 files changed

+3522
-1575
lines changed

9 files changed

+3522
-1575
lines changed

app/src/main/kotlin/io/androidpoet/countrypickerdemo/MainActivity.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import androidx.compose.ui.Alignment
3131
import androidx.compose.ui.Modifier
3232
import androidx.compose.ui.unit.sp
3333
import io.androidpoet.countrypicker.CountryPicker
34+
import io.androidpoet.countrypicker.CountryUtils.generateCurrencySymbol
3435
import io.androidpoet.countrypickerdemo.ui.theme.CountryPickerDemoTheme
3536

3637
class MainActivity : ComponentActivity() {
@@ -44,7 +45,11 @@ class MainActivity : ComponentActivity() {
4445

4546
CountryPicker(
4647
onCountryChanged = {
47-
currantCountry = it.name + " " + it.flag + " " + it.alpha2
48+
currantCountry =
49+
it.name + " " + it.flag + " " + it.alpha2 + it.currencySign.orEmpty()
50+
51+
println(it.currencySign.orEmpty())
52+
4853
},
4954
onDismiss = {
5055
showBottomSheet = false

0 commit comments

Comments
 (0)