Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
MYID Public Code
MyID Sample Android
Commits
8f400af7
Commit
8f400af7
authored
Feb 21, 2023
by
Javokhir Savriev
Browse files
Updated
parent
7c9fe85b
Changes
175
Hide whitespace changes
Inline
Side-by-side
android-sample/app/src/main/java/uz/myid/sdk/sample/ExampleWithOnActivityResultActivity.kt
deleted
100644 → 0
View file @
7c9fe85b
package
uz.myid.sdk.sample
import
android.content.Intent
import
android.os.Bundle
import
androidx.appcompat.app.AppCompatActivity
import
uz.myid.android.sdk.capture.*
import
uz.myid.android.sdk.capture.model.OrganizationDetails
import
java.util.*
class
ExampleWithOnActivityResultActivity
:
AppCompatActivity
(),
MyIdResultListener
{
private
val
myIdClient
=
MyIdClient
()
override
fun
onCreate
(
savedInstanceState
:
Bundle
?)
{
super
.
onCreate
(
savedInstanceState
)
startMyId
()
}
override
fun
onActivityResult
(
requestCode
:
Int
,
resultCode
:
Int
,
data
:
Intent
?)
{
super
.
onActivityResult
(
requestCode
,
resultCode
,
data
)
myIdClient
.
handleActivityResult
(
resultCode
,
this
)
}
override
fun
onSuccess
(
result
:
MyIdResult
)
{
// Get face bitmap and result code
}
override
fun
onError
(
e
:
MyIdException
)
{
// Get error message and code
}
override
fun
onUserExited
()
{
// User exited sdk
}
private
fun
startMyId
()
{
val
clientId
=
"client_id"
val
passportData
=
"passport_data"
val
dateOfBirth
=
"date_of_birth"
val
sdkHash
=
"sdk_hash"
val
externalId
=
"external_id"
val
threshold
=
0.50f
val
organizationDetails
=
OrganizationDetails
(
phoneNumber
=
"1234567"
,
)
val
myIdConfig
=
MyIdConfig
.
Builder
(
clientId
)
.
withPassportData
(
passportData
)
.
withBirthDate
(
dateOfBirth
)
.
withSdkHash
(
sdkHash
)
.
withExternalId
(
externalId
)
.
withThreshold
(
threshold
)
.
withBuildMode
(
MyIdBuildMode
.
PRODUCTION
)
.
withEntryType
(
MyIdEntryType
.
AUTH
)
.
withLocale
(
Locale
(
"en"
))
.
withCameraShape
(
MyIdCameraShape
.
CIRCLE
)
.
withOrganizationDetails
(
organizationDetails
)
.
withPhoto
(
false
)
.
build
()
/*
Start the flow. 1 should be your request code (customize as needed).
Must be an Activity or Fragment (support library).
This request code will be important for you on onActivityResult() to identify the MyIdResultListener.
*/
myIdClient
.
startActivityForResult
(
this
,
1
,
myIdConfig
)
}
}
\ No newline at end of file
android-sample/app/src/main/java/uz/myid/sdk/sample/MainActivity.kt
deleted
100644 → 0
View file @
7c9fe85b
package
uz.myid.sdk.sample
import
android.os.Bundle
import
android.widget.EditText
import
androidx.appcompat.app.AppCompatActivity
import
uz.myid.android.sdk.capture.*
import
uz.myid.android.sdk.capture.model.OrganizationDetails
import
uz.myid.sdk.sample.databinding.ActivityMainBinding
import
java.util.*
class
MainActivity
:
AppCompatActivity
(),
MyIdResultListener
{
private
val
binding
by
lazy
{
ActivityMainBinding
.
inflate
(
layoutInflater
)
}
private
val
myIdClient
=
MyIdClient
()
private
var
clientId
=
""
private
var
myIdBuildMode
=
MyIdBuildMode
.
PRODUCTION
private
var
myIdEntryType
=
MyIdEntryType
.
AUTH
private
var
myIdLocale
=
Locale
(
"en"
)
private
var
myIdCameraShape
=
MyIdCameraShape
.
CIRCLE
private
var
code
=
""
override
fun
onCreate
(
savedInstanceState
:
Bundle
?)
{
super
.
onCreate
(
savedInstanceState
)
setContentView
(
binding
.
root
)
with
(
binding
)
{
inputClientId
.
setText
(
clientId
)
radioGroupLang
.
setOnCheckedChangeListener
{
_
,
checkedId
->
myIdLocale
=
when
(
checkedId
)
{
R
.
id
.
radioUz
->
Locale
(
"uz"
)
R
.
id
.
radioEn
->
Locale
(
"en"
)
else
->
Locale
(
"ru"
)
}
}
radioGroupEntryType
.
setOnCheckedChangeListener
{
_
,
checkedId
->
myIdEntryType
=
if
(
checkedId
==
R
.
id
.
radioFace
)
{
MyIdEntryType
.
FACE
}
else
{
MyIdEntryType
.
AUTH
}
}
radioGroupBuildMode
.
setOnCheckedChangeListener
{
_
,
checkedId
->
myIdBuildMode
=
if
(
checkedId
==
R
.
id
.
radioProd
)
{
MyIdBuildMode
.
PRODUCTION
}
else
{
MyIdBuildMode
.
DEBUG
}
}
radioGroupShape
.
setOnCheckedChangeListener
{
_
,
checkedId
->
myIdCameraShape
=
if
(
checkedId
==
R
.
id
.
radioCircle
)
{
MyIdCameraShape
.
CIRCLE
}
else
{
MyIdCameraShape
.
ELLIPSE
}
}
buttonStart
.
setOnClickListener
{
startMyId
()
}
}
}
override
fun
onSuccess
(
result
:
MyIdResult
)
{
code
=
result
.
code
.
orEmpty
()
with
(
binding
)
{
imageResult
.
setImageBitmap
(
result
.
bitmap
)
"""
Result code: ${result.code}
Comparison value: ${result.comparison}
"""
.
trimIndent
().
also
{
textResult
.
text
=
it
}
}
}
override
fun
onError
(
e
:
MyIdException
)
{
code
=
""
with
(
binding
)
{
imageResult
.
setImageBitmap
(
null
)
"""
Result error: ${e.message}
Result error code: ${e.code}
"""
.
trimIndent
().
also
{
textResult
.
text
=
it
}
}
}
override
fun
onUserExited
()
{
code
=
""
with
(
binding
)
{
imageResult
.
setImageBitmap
(
null
)
"User exited sdk"
.
also
{
textResult
.
text
=
it
}
}
}
private
fun
startMyId
()
{
val
organizationDetails
=
OrganizationDetails
(
phoneNumber
=
binding
.
inputPhoneNumber
.
value
)
val
myIdConfig
=
MyIdConfig
.
builder
(
binding
.
inputClientId
.
value
)
.
withPassportData
(
binding
.
inputPassportData
.
value
)
.
withBirthDate
(
binding
.
inputDate
.
value
)
.
withSdkHash
(
binding
.
inputSdkHash
.
value
)
.
withExternalId
(
binding
.
inputExternalId
.
value
)
.
withThreshold
(
binding
.
thresholdSlider
.
value
)
.
withBuildMode
(
myIdBuildMode
)
.
withEntryType
(
myIdEntryType
)
.
withLocale
(
myIdLocale
)
.
withCameraShape
(
myIdCameraShape
)
.
withOrganizationDetails
(
organizationDetails
)
.
withPhoto
(
binding
.
checkboxWithPhoto
.
isChecked
)
.
build
()
val
intent
=
myIdClient
.
createIntent
(
this
,
myIdConfig
)
result
.
launch
(
intent
)
}
private
val
result
=
takeUserResult
(
this
)
private
inline
val
EditText
.
value
:
String
get
()
=
text
.
toString
().
trim
()
}
\ No newline at end of file
android-sample/app/src/main/res/drawable-v24/ic_launcher_foreground.xml
deleted
100644 → 0
View file @
7c9fe85b
<vector
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:aapt=
"http://schemas.android.com/aapt"
android:width=
"108dp"
android:height=
"108dp"
android:viewportWidth=
"108"
android:viewportHeight=
"108"
>
<path
android:pathData=
"M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z"
>
<aapt:attr
name=
"android:fillColor"
>
<gradient
android:endX=
"85.84757"
android:endY=
"92.4963"
android:startX=
"42.9492"
android:startY=
"49.59793"
android:type=
"linear"
>
<item
android:color=
"#44000000"
android:offset=
"0.0"
/>
<item
android:color=
"#00000000"
android:offset=
"1.0"
/>
</gradient>
</aapt:attr>
</path>
<path
android:fillColor=
"#FFFFFF"
android:fillType=
"nonZero"
android:pathData=
"M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
android:strokeWidth=
"1"
android:strokeColor=
"#00000000"
/>
</vector>
\ No newline at end of file
android-sample/app/src/main/res/drawable/ic_launcher_background.xml
deleted
100644 → 0
View file @
7c9fe85b
<?xml version="1.0" encoding="utf-8"?>
<vector
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:width=
"108dp"
android:height=
"108dp"
android:viewportWidth=
"108"
android:viewportHeight=
"108"
>
<path
android:fillColor=
"#3DDC84"
android:pathData=
"M0,0h108v108h-108z"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M9,0L9,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,0L19,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M29,0L29,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M39,0L39,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M49,0L49,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M59,0L59,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M69,0L69,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M79,0L79,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M89,0L89,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M99,0L99,108"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,9L108,9"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,19L108,19"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,29L108,29"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,39L108,39"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,49L108,49"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,59L108,59"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,69L108,69"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,79L108,79"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,89L108,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M0,99L108,99"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,29L89,29"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,39L89,39"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,49L89,49"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,59L89,59"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,69L89,69"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M19,79L89,79"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M29,19L29,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M39,19L39,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M49,19L49,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M59,19L59,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M69,19L69,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
<path
android:fillColor=
"#00000000"
android:pathData=
"M79,19L79,89"
android:strokeWidth=
"0.8"
android:strokeColor=
"#33FFFFFF"
/>
</vector>
android-sample/app/src/main/res/layout/activity_main.xml
deleted
100644 → 0
View file @
7c9fe85b
<?xml version="1.0" encoding="utf-8"?>
<androidx.core.widget.NestedScrollView
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
tools:context=
".MainActivity"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:padding=
"20dp"
>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"@string/client_id"
app:helperText=
"* Required"
app:helperTextEnabled=
"true"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputClientId"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:inputType=
"textMultiLine"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:hint=
"@string/passport"
app:helperText=
"* Optional"
app:helperTextEnabled=
"true"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputPassportData"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:hint=
"@string/birth_date"
app:helperText=
"* Optional"
app:helperTextEnabled=
"true"
app:placeholderText=
"дд.мм.гггг"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputDate"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:hint=
"@string/sdk_hash"
app:helperText=
"* Optional"
app:helperTextEnabled=
"true"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputSdkHash"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:inputType=
"textMultiLine"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:hint=
"@string/external_id"
app:helperText=
"* Optional"
app:helperTextEnabled=
"true"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputExternalId"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:inputType=
"textMultiLine"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
style=
"@style/Widget.Material3.TextInputLayout.OutlinedBox"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:hint=
"@string/organization_phone_number"
app:helperText=
"* Optional"
app:helperTextEnabled=
"true"
>
<com.google.android.material.textfield.TextInputEditText
android:id=
"@+id/inputPhoneNumber"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:importantForAutofill=
"no"
android:inputType=
"phone"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</com.google.android.material.textfield.TextInputLayout>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"16dp"
android:text=
"@string/threshold"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<com.google.android.material.slider.Slider
android:id=
"@+id/thresholdSlider"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:stepSize=
"0.01"
android:valueFrom=
"0.50"
android:valueTo=
"0.99"
app:labelBehavior=
"floating"
/>
<RadioGroup
android:id=
"@+id/radioGroupBuildMode"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
android:checkedButton=
"@id/radioProd"
android:orientation=
"horizontal"
>
<RadioButton
android:id=
"@+id/radioProd"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"@string/prod"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<RadioButton
android:id=
"@+id/radioDev"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"16dp"
android:text=
"@string/dev"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</RadioGroup>
<RadioGroup
android:id=
"@+id/radioGroupEntryType"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
android:checkedButton=
"@id/radioAuth"
android:orientation=
"horizontal"
>
<RadioButton
android:id=
"@+id/radioAuth"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"@string/auth"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<RadioButton
android:id=
"@+id/radioFace"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"12dp"
android:text=
"@string/face"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</RadioGroup>
<RadioGroup
android:id=
"@+id/radioGroupLang"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
android:checkedButton=
"@id/radioEn"
android:orientation=
"horizontal"
>
<RadioButton
android:id=
"@+id/radioUz"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"@string/uzbek"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<RadioButton
android:id=
"@+id/radioEn"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"12dp"
android:text=
"@string/english"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<RadioButton
android:id=
"@+id/radioRu"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"12dp"
android:text=
"@string/russian"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</RadioGroup>
<RadioGroup
android:id=
"@+id/radioGroupShape"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
android:checkedButton=
"@id/radioCircle"
android:orientation=
"horizontal"
>
<RadioButton
android:id=
"@+id/radioCircle"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"@string/circle"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<RadioButton
android:id=
"@+id/radioEllipse"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"12dp"
android:text=
"@string/ellipse"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
</RadioGroup>
<CheckBox
android:id=
"@+id/checkboxWithPhoto"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
android:checked=
"true"
android:text=
"@string/with_photo"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<com.google.android.material.button.MaterialButton
android:id=
"@+id/buttonStart"
style=
"@style/Widget.Material3.Button.UnelevatedButton"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:layout_marginTop=
"20dp"
android:text=
"@string/scan_face_data"
android:textAllCaps=
"true"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<TextView
android:id=
"@+id/textResult"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"20dp"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"20dp"
android:text=
"@string/result_image"
android:textAppearance=
"@style/TextAppearance.Material3.BodyLarge"
/>
<ImageView
android:id=
"@+id/imageResult"
android:layout_width=
"200dp"
android:layout_height=
"200dp"
android:layout_marginTop=
"16dp"
android:contentDescription=
"@string/image"
/>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
\ No newline at end of file
android-sample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
deleted
100644 → 0
View file @
7c9fe85b
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<background
android:drawable=
"@drawable/ic_launcher_background"
/>
<foreground
android:drawable=
"@drawable/ic_launcher_foreground"
/>
</adaptive-icon>
\ No newline at end of file
android-sample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
deleted
100644 → 0
View file @
7c9fe85b
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<background
android:drawable=
"@drawable/ic_launcher_background"
/>
<foreground
android:drawable=
"@drawable/ic_launcher_foreground"
/>
</adaptive-icon>
\ No newline at end of file
android-sample/app/src/main/res/mipmap-hdpi/ic_launcher.webp
deleted
100644 → 0
View file @
7c9fe85b
1.37 KB
android-sample/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp
deleted
100644 → 0
View file @
7c9fe85b
2.83 KB
android-sample/app/src/main/res/mipmap-mdpi/ic_launcher.webp
deleted
100644 → 0
View file @
7c9fe85b
982 Bytes
android-sample/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp
deleted
100644 → 0
View file @
7c9fe85b
1.73 KB
android-sample/app/src/main/res/mipmap-xhdpi/ic_launcher.webp
deleted
100644 → 0
View file @
7c9fe85b
1.86 KB
android-sample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp
deleted
100644 → 0
View file @
7c9fe85b
3.83 KB
android-sample/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp
deleted
100644 → 0
View file @
7c9fe85b
2.82 KB
android-sample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp
deleted
100644 → 0
View file @
7c9fe85b
5.78 KB
android-sample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp
deleted
100644 → 0
View file @
7c9fe85b
3.75 KB
android-sample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp
deleted
100644 → 0
View file @
7c9fe85b
7.6 KB
android-sample/app/src/main/res/values/strings.xml
deleted
100644 → 0
View file @
7c9fe85b
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<resources>
<string
name=
"app_name"
>
MyID Sample
</string>
<string
name=
"auth"
>
Auth
</string>
<string
name=
"birth_date"
>
Birth date
</string>
<string
name=
"circle"
>
Circle
</string>
<string
name=
"client_id"
>
Client ID
</string>
<string
name=
"dev"
>
Dev
</string>
<string
name=
"ellipse"
>
Ellipse
</string>
<string
name=
"english"
>
English
</string>
<string
name=
"external_id"
>
External id
</string>
<string
name=
"face"
>
Face
</string>
<string
name=
"image"
>
Image
</string>
<string
name=
"organization_phone_number"
>
Phone number
</string>
<string
name=
"passport"
>
Passport or PINFL
</string>
<string
name=
"prod"
>
Prod
</string>
<string
name=
"result_image"
>
Result image
</string>
<string
name=
"russian"
>
Russian
</string>
<string
name=
"scan_face_data"
>
Scan face data
</string>
<string
name=
"threshold"
>
Threshold
</string>
<string
name=
"uzbek"
>
Uzbek
</string>
<string
name=
"with_photo"
>
With photo
</string>
<string
name=
"without_photo"
>
Without photo
</string>
<string
name=
"sdk_hash"
>
Sdk hash
</string>
</resources>
android-sample/app/src/main/res/values/themes.xml
deleted
100644 → 0
View file @
7c9fe85b
<resources>
<style
name=
"Theme.MyIdSample"
parent=
"Theme.Material3.Light.NoActionBar"
/>
</resources>
\ No newline at end of file
android-sample/build.gradle
deleted
100644 → 0
View file @
7c9fe85b
plugins
{
id
"com.android.application"
version
"7.3.0"
apply
false
id
"com.android.library"
version
"7.3.0"
apply
false
id
"org.jetbrains.kotlin.android"
version
"1.7.10"
apply
false
}
\ No newline at end of file
Prev
1
2
3
4
5
6
7
8
9
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment