Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-client-android
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-client-android
Commits
a1fca572
Commit
a1fca572
authored
3 years ago
by
Amirhossein Naghshzan
Committed by
Adrien Béraud
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
tv: update conversation adapter
Change-Id: I7bd0a6daad83277b7c0a537bfa93ec002e4376fc
parent
b7ff1de9
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
ring-android/app/src/main/java/cx/ring/tv/conversation/TvConversationAdapter.kt
+8
-5
8 additions, 5 deletions
...ain/java/cx/ring/tv/conversation/TvConversationAdapter.kt
with
8 additions
and
5 deletions
ring-android/app/src/main/java/cx/ring/tv/conversation/TvConversationAdapter.kt
+
8
−
5
View file @
a1fca572
...
@@ -660,11 +660,14 @@ class TvConversationAdapter(
...
@@ -660,11 +660,14 @@ class TvConversationAdapter(
private
fun
configureForContactEvent
(
viewHolder
:
ConversationViewHolder
,
interaction
:
Interaction
)
{
private
fun
configureForContactEvent
(
viewHolder
:
ConversationViewHolder
,
interaction
:
Interaction
)
{
val
event
=
interaction
as
ContactEvent
val
event
=
interaction
as
ContactEvent
if
(
event
.
event
===
ContactEvent
.
Event
.
ADDED
)
{
viewHolder
.
mMsgTxt
?.
setText
(
when
(
event
.
event
)
{
viewHolder
.
mMsgTxt
?.
setText
(
R
.
string
.
hist_contact_added
)
ContactEvent
.
Event
.
ADDED
->
R
.
string
.
hist_contact_added
}
else
if
(
event
.
event
===
ContactEvent
.
Event
.
INCOMING_REQUEST
)
{
ContactEvent
.
Event
.
INVITED
->
R
.
string
.
hist_contact_invited
viewHolder
.
mMsgTxt
?.
setText
(
R
.
string
.
hist_invitation_received
)
ContactEvent
.
Event
.
REMOVED
->
R
.
string
.
hist_contact_left
}
ContactEvent
.
Event
.
BANNED
->
R
.
string
.
hist_contact_banned
ContactEvent
.
Event
.
INCOMING_REQUEST
->
R
.
string
.
hist_invitation_received
else
->
R
.
string
.
hist_contact_added
})
viewHolder
.
compositeDisposable
.
add
(
timestampUpdateTimer
.
subscribe
{
t
:
Long
?
->
viewHolder
.
compositeDisposable
.
add
(
timestampUpdateTimer
.
subscribe
{
t
:
Long
?
->
val
timeSeparationString
=
TextUtils
.
timestampToDetailString
(
viewHolder
.
itemView
.
context
,
event
.
timestamp
)
val
timeSeparationString
=
TextUtils
.
timestampToDetailString
(
viewHolder
.
itemView
.
context
,
event
.
timestamp
)
viewHolder
.
mMsgDetailTxt
?.
text
=
timeSeparationString
viewHolder
.
mMsgDetailTxt
?.
text
=
timeSeparationString
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment