Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xabber-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
xabber-android
Commits
b9e1f2f5
Commit
b9e1f2f5
authored
Aug 05, 2015
by
Grigory Fedorov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ContactTitleInflater: account avatar fixed.
parent
9b547e72
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
ContactTitleInflater.java
...va/com/xabber/android/ui/helper/ContactTitleInflater.java
+9
-1
No files found.
app/src/main/java/com/xabber/android/ui/helper/ContactTitleInflater.java
View file @
b9e1f2f5
...
...
@@ -20,8 +20,10 @@ import android.widget.ImageView;
import
android.widget.TextView
;
import
com.xabber.android.R
;
import
com.xabber.android.data.extension.avatar.AvatarManager
;
import
com.xabber.android.data.extension.cs.ChatStateManager
;
import
com.xabber.android.data.roster.AbstractContact
;
import
com.xabber.xmpp.address.Jid
;
import
org.jivesoftware.smackx.chatstates.ChatState
;
...
...
@@ -33,7 +35,13 @@ public class ContactTitleInflater {
final
ImageView
avatarView
=
(
ImageView
)
titleView
.
findViewById
(
R
.
id
.
avatar
);
nameView
.
setText
(
abstractContact
.
getName
());
avatarView
.
setImageDrawable
(
abstractContact
.
getAvatar
());
// if it is account, not simple user contact
if
(
Jid
.
getBareAddress
(
abstractContact
.
getUser
()).
equals
(
Jid
.
getBareAddress
(
abstractContact
.
getAccount
())))
{
avatarView
.
setImageDrawable
(
AvatarManager
.
getInstance
().
getAccountAvatar
(
abstractContact
.
getAccount
()));
}
else
{
avatarView
.
setImageDrawable
(
abstractContact
.
getAvatar
());
}
setStatus
(
context
,
titleView
,
abstractContact
);
}
...
...
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