From 553f41a2dbc068a8a43f613e088713cd3ec7680e Mon Sep 17 00:00:00 2001 From: steckbrief Date: Tue, 26 May 2015 22:30:41 +0200 Subject: Show Online status in contact list with respect to SHOW_ONLINE_STATUS preference --- .../java/eu/siacs/conversations/ui/adapter/ListItemAdapter.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/main/java/eu') diff --git a/src/main/java/eu/siacs/conversations/ui/adapter/ListItemAdapter.java b/src/main/java/eu/siacs/conversations/ui/adapter/ListItemAdapter.java index 5bc67b8b..10500bfc 100644 --- a/src/main/java/eu/siacs/conversations/ui/adapter/ListItemAdapter.java +++ b/src/main/java/eu/siacs/conversations/ui/adapter/ListItemAdapter.java @@ -58,8 +58,10 @@ public class ListItemAdapter extends ArrayAdapter { view = inflater.inflate(R.layout.contact, parent, false); } - TextView tvStatus = (TextView) view.findViewById(R.id.contact_status); - tvStatus.setBackgroundColor(item.getStatusColor()); + if (Settings.SHOW_ONLINE_STATUS) { + TextView tvStatus = (TextView) view.findViewById(R.id.contact_status); + tvStatus.setBackgroundColor(item.getStatusColor()); + } TextView tvName = (TextView) view.findViewById(R.id.contact_display_name); TextView tvJid = (TextView) view.findViewById(R.id.contact_jid); -- cgit v1.2.3