Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
AloqaIM-Android
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
AloqaIM-Android
Commits
ebf24317
Unverified
Commit
ebf24317
authored
Jul 27, 2018
by
Lucio Maciel
Committed by
GitHub
Jul 27, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1544 from RocketChat/fix/fix-typing-status
[FIX] fix typing status for 2.5.1
parents
9710127a
8d8f80bd
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
14 deletions
+22
-14
ChatRoomPresenter.kt
...rocket/android/chatroom/presentation/ChatRoomPresenter.kt
+16
-13
strings.xml
app/src/main/res/values-es/strings.xml
+1
-1
build.gradle
core/build.gradle
+5
-0
No files found.
app/src/main/java/chat/rocket/android/chatroom/presentation/ChatRoomPresenter.kt
View file @
ebf24317
...
...
@@ -1006,7 +1006,7 @@ class ChatRoomPresenter @Inject constructor(
}
}
private
suspend
fun
subscribeTypingStatus
()
{
private
fun
subscribeTypingStatus
()
{
launch
(
CommonPool
+
strategy
.
jobs
)
{
client
.
subscribeTypingStatus
(
chatRoomId
.
toString
())
{
_
,
id
->
typingStatusSubscriptionId
=
id
...
...
@@ -1019,22 +1019,25 @@ class ChatRoomPresenter @Inject constructor(
}
private
fun
processTypingStatus
(
typingStatus
:
Pair
<
String
,
Boolean
>)
{
if
(!
typingStatusList
.
any
{
username
->
username
==
typingStatus
.
first
})
{
if
(
typingStatus
.
second
)
{
typingStatusList
.
add
(
typingStatus
.
first
)
}
}
else
{
typingStatusList
.
find
{
username
->
username
==
typingStatus
.
first
}
?.
let
{
typingStatusList
.
remove
(
it
)
if
(
typingStatus
.
first
!=
currentLoggedUsername
)
{
if
(!
typingStatusList
.
any
{
username
->
username
==
typingStatus
.
first
})
{
if
(
typingStatus
.
second
)
{
typingStatusList
.
add
(
typingStatus
.
first
)
}
}
else
{
typingStatusList
.
find
{
username
->
username
==
typingStatus
.
first
}
?.
let
{
typingStatusList
.
remove
(
it
)
if
(
typingStatus
.
second
)
{
typingStatusList
.
add
(
typingStatus
.
first
)
}
}
}
if
(
typingStatusList
.
isNotEmpty
())
{
view
.
showTypingStatus
(
typingStatusList
.
toList
())
}
else
{
view
.
hideTypingStatusView
()
}
}
if
(
typingStatusList
.
isNotEmpty
())
{
view
.
showTypingStatus
(
typingStatusList
.
toList
())
// copy typingStatusList
}
else
{
view
.
hideTypingStatusView
()
}
}
...
...
app/src/main/res/values-es/strings.xml
View file @
ebf24317
...
...
@@ -38,7 +38,6 @@
<string
name=
"action_invisible"
>
Invisible
</string>
<string
name=
"action_drawing"
>
dibujo
</string>
<string
name=
"action_save_to_gallery"
>
Guardar en la galería
</string>
<string
name=
"action_share"
>
Compartir
</string>
<!-- Settings List -->
<string-array
name=
"settings_actions"
>
...
...
@@ -275,4 +274,5 @@
<string
name=
"msg_file_description"
>
Descripción del archivo
</string>
<string
name=
"msg_send"
>
Enviar
</string>
<string
name=
"msg_sent_attachment"
>
Envió un archivo
</string>
</resources>
core/build.gradle
View file @
ebf24317
...
...
@@ -18,6 +18,11 @@ android {
proguardFiles
getDefaultProguardFile
(
'proguard-android.txt'
),
'proguard-rules.pro'
}
}
packagingOptions
{
exclude
'META-INF/core.kotlin_module'
exclude
'META-INF/main.kotlin_module'
}
}
dependencies
{
...
...
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