Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_goodmoney
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_goodmoney
Commits
af8d66fe
Commit
af8d66fe
authored
Nov 23, 2020
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
ae26efe5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
3 deletions
+13
-3
LoginActivity.kt
...in/java/com/mints/goodmoney/ui/activitys/LoginActivity.kt
+13
-3
No files found.
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/LoginActivity.kt
View file @
af8d66fe
...
...
@@ -79,8 +79,13 @@ class LoginActivity : BaseActivity()
override
fun
onKeyDown
(
keyCode
:
Int
,
event
:
KeyEvent
):
Boolean
{
return
if
(
keyCode
==
KeyEvent
.
KEYCODE_BACK
)
{
if
(!
loginFlag
)
{
finish
()
return
true
}
val
channel
=
CommonUtils
.
getAppMetaData
(
MintsApplication
.
getContext
(),
"CHANNEL_NAME"
)
if
(!
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
)
&&
!
loginFlag
)
{
if
(!
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
))
{
finish
()
}
true
...
...
@@ -92,8 +97,13 @@ class LoginActivity : BaseActivity()
when
(
v
?.
id
)
{
R
.
id
.
ivLoginBack
->
{
if
(!
loginFlag
)
{
finish
()
return
}
val
channel
=
CommonUtils
.
getAppMetaData
(
MintsApplication
.
getContext
(),
"CHANNEL_NAME"
)
if
(!
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
)
&&
!
loginFlag
)
{
if
(!
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
))
{
finish
()
}
}
...
...
@@ -193,7 +203,7 @@ class LoginActivity : BaseActivity()
}
val
channel
=
CommonUtils
.
getAppMetaData
(
MintsApplication
.
getContext
(),
"CHANNEL_NAME"
)
if
(
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
)
&&
!
loginFlag
)
{
if
(
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
))
{
readyGo
(
MainActivity
::
class
.
java
)
}
...
...
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