Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
L
location share white
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
location share white
Commits
7e78de00
Commit
7e78de00
authored
Oct 15, 2024
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
b3762285
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
5 deletions
+33
-5
HowUseShareActivity.kt
.../base/locationsharewhite/ui/howuse/HowUseShareActivity.kt
+28
-3
activity_how_use_share.xml
app/src/main/res/layout/activity_how_use_share.xml
+3
-2
strings.xml
app/src/main/res/values/strings.xml
+2
-0
No files found.
app/src/main/java/com/base/locationsharewhite/ui/howuse/HowUseShareActivity.kt
View file @
7e78de00
package
com.base.locationsharewhite.ui.howuse
package
com.base.locationsharewhite.ui.howuse
import
android.graphics.Color
import
android.graphics.Color
import
androidx.activity.addCallback
import
androidx.core.view.updatePadding
import
androidx.core.view.updatePadding
import
androidx.viewpager2.widget.MarginPageTransformer
import
androidx.viewpager2.widget.MarginPageTransformer
import
com.base.locationsharewhite.R
import
com.base.locationsharewhite.R
...
@@ -23,6 +24,7 @@ class HowUseShareActivity : BaseActivity<ActivityHowUseShareBinding>() {
...
@@ -23,6 +24,7 @@ class HowUseShareActivity : BaseActivity<ActivityHowUseShareBinding>() {
binding
.
root
.
updatePadding
(
top
=
BarUtils
.
getStatusBarHeight
())
binding
.
root
.
updatePadding
(
top
=
BarUtils
.
getStatusBarHeight
())
initBanner
()
initBanner
()
step1ui
()
}
}
private
fun
initBanner
()
{
private
fun
initBanner
()
{
...
@@ -44,12 +46,35 @@ class HowUseShareActivity : BaseActivity<ActivityHowUseShareBinding>() {
...
@@ -44,12 +46,35 @@ class HowUseShareActivity : BaseActivity<ActivityHowUseShareBinding>() {
}
}
fun
step1ui
()
{
override
fun
initListener
()
{
super
.
initListener
()
onBackPressedDispatcher
.
addCallback
{
finish
()
}
binding
.
flFanhui
.
setOnClickListener
{
onBackPressedDispatcher
.
onBackPressed
()
}
binding
.
tvBtn
.
setOnClickListener
{
if
(
uiType
==
1
)
{
step2ui
()
}
else
{
}
}
}
private
var
uiType
=
0
private
fun
step1ui
()
{
uiType
=
1
binding
.
tvStep
.
text
=
resources
.
getString
(
R
.
string
.
how_share_location_step_1
)
binding
.
tvStep
.
text
=
resources
.
getString
(
R
.
string
.
how_share_location_step_1
)
binding
.
banner
binding
.
banner
.
currentItem
=
0
binding
.
tvBtn
.
text
=
getString
(
R
.
string
.
next
)
}
}
fun
step2ui
()
{
private
fun
step2ui
()
{
uiType
=
2
binding
.
tvStep
.
text
=
resources
.
getString
(
R
.
string
.
how_share_location_step_2
)
binding
.
tvStep
.
text
=
resources
.
getString
(
R
.
string
.
how_share_location_step_2
)
binding
.
banner
.
currentItem
=
1
binding
.
tvBtn
.
text
=
getString
(
R
.
string
.
let_s_go
)
}
}
}
}
\ No newline at end of file
app/src/main/res/layout/activity_how_use_share.xml
View file @
7e78de00
...
@@ -65,11 +65,11 @@
...
@@ -65,11 +65,11 @@
<TextView
<TextView
android:id=
"@+id/tv_step"
android:id=
"@+id/tv_step"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
50dp
"
android:layout_gravity=
"center_horizontal"
android:layout_gravity=
"center_horizontal"
android:layout_marginHorizontal=
"24dp"
android:layout_marginHorizontal=
"24dp"
android:layout_marginTop=
"36dp"
android:layout_marginTop=
"36dp"
android:gravity=
"center"
android:gravity=
"center
_horizontal
"
android:textColor=
"#7BB2E1"
android:textColor=
"#7BB2E1"
tools:text=
"@string/how_share_location_step_2"
/>
tools:text=
"@string/how_share_location_step_2"
/>
...
@@ -97,6 +97,7 @@
...
@@ -97,6 +97,7 @@
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_gravity=
"center_horizontal"
android:layout_marginHorizontal=
"18dp"
android:layout_marginHorizontal=
"18dp"
android:layout_marginTop=
"16dp"
android:gravity=
"center"
android:gravity=
"center"
android:text=
"@string/more_two_use"
android:text=
"@string/more_two_use"
android:textColor=
"#00101D"
android:textColor=
"#00101D"
...
...
app/src/main/res/values/strings.xml
View file @
7e78de00
...
@@ -27,4 +27,6 @@
...
@@ -27,4 +27,6 @@
<string
name=
"how_share_location_step_1"
>
1. Ask Your Friend To Send You The Location Code.
</string>
<string
name=
"how_share_location_step_1"
>
1. Ask Your Friend To Send You The Location Code.
</string>
<string
name=
"how_share_location_step_2"
>
2. Then paste your friend\'s location code below and click the share button to share your location.
</string>
<string
name=
"how_share_location_step_2"
>
2. Then paste your friend\'s location code below and click the share button to share your location.
</string>
<string
name=
"more_two_use"
>
Reminder: Two or more people need to download the ap simultaneously to use it
</string>
<string
name=
"more_two_use"
>
Reminder: Two or more people need to download the ap simultaneously to use it
</string>
<string
name=
"next"
>
Next
</string>
<string
name=
"let_s_go"
>
LET\'S GO
</string>
</resources>
</resources>
\ No newline at end of file
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