mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-18 03:48:08 +00:00
Some UI Fix
This commit is contained in:
parent
12a41b8325
commit
b6918c3fdc
4 changed files with 20 additions and 8 deletions
|
|
@ -97,7 +97,6 @@
|
|||
|
||||
<TextView
|
||||
android:id="@+id/unreadMessages"
|
||||
style="@style/font18"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_alignBottom="@+id/sipUri"
|
||||
|
|
@ -109,7 +108,8 @@
|
|||
android:gravity="center"
|
||||
android:maxLines="1"
|
||||
android:textAlignment="center"
|
||||
android:textSize="16sp"/>
|
||||
android:textColor="@color/colorH"
|
||||
android:textSize="15sp"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@id/lastMessageLayout"
|
||||
|
|
|
|||
|
|
@ -112,8 +112,9 @@
|
|||
android:layout_marginTop="20dp"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
android:gravity="center"
|
||||
android:textAlignment="center"
|
||||
android:textColor="#000000"
|
||||
android:textSize="17sp"
|
||||
android:textSize="15sp"
|
||||
android:visibility="invisible"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
|
@ -208,7 +209,7 @@
|
|||
android:gravity="center"
|
||||
android:textAlignment="center"
|
||||
android:textColor="#000000"
|
||||
android:textSize="17sp"
|
||||
android:textSize="15sp"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
|
|
|||
|
|
@ -203,8 +203,9 @@ public class ChatEventsAdapter extends ListSelectionAdapter {
|
|||
holder.openFileButton.setVisibility(View.GONE);
|
||||
holder.messageStatus.setVisibility(View.GONE);
|
||||
holder.messageSendingInProgress.setVisibility(View.GONE);
|
||||
holder.imdmLayout.setVisibility(View.GONE);
|
||||
holder.imdmIcon.setVisibility(View.GONE);
|
||||
holder.imdmLayout.setVisibility(View.INVISIBLE);
|
||||
holder.imdmIcon.setVisibility(View.INVISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.INVISIBLE);
|
||||
holder.contactPicture.setImageBitmap(ContactsManager.getInstance().getDefaultAvatarBitmap());
|
||||
|
||||
if (isEditionEnabled()) {
|
||||
|
|
@ -258,25 +259,35 @@ public class ChatEventsAdapter extends ListSelectionAdapter {
|
|||
/*holder.imdmLayout.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setText(R.string.sent);
|
||||
holder.imdmIcon.setImageResource(R.drawable.chat_delivered);
|
||||
holder.imdmIcon.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setTextColor(mContext.getResources().getColor(R.color.colorD));*/
|
||||
} else if (status == ChatMessage.State.DeliveredToUser) {
|
||||
holder.imdmLayout.setVisibility(View.VISIBLE);
|
||||
holder.imdmIcon.setImageResource(R.drawable.chat_delivered);
|
||||
holder.imdmIcon.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setText(R.string.delivered);
|
||||
holder.imdmLabel.setTextColor(mContext.getResources().getColor(R.color.colorD));
|
||||
} else if (status == ChatMessage.State.Displayed) {
|
||||
holder.imdmLayout.setVisibility(View.VISIBLE);
|
||||
holder.imdmIcon.setImageResource(R.drawable.chat_read);
|
||||
holder.imdmIcon.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setText(R.string.displayed);
|
||||
holder.imdmLabel.setTextColor(mContext.getResources().getColor(R.color.colorK));
|
||||
} else if (status == ChatMessage.State.NotDelivered) {
|
||||
holder.imdmLayout.setVisibility(View.VISIBLE);
|
||||
holder.imdmIcon.setImageResource(R.drawable.chat_error);
|
||||
holder.imdmIcon.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setText(R.string.error);
|
||||
holder.imdmLabel.setTextColor(mContext.getResources().getColor(R.color.colorI));
|
||||
} else if (status == ChatMessage.State.FileTransferError) {
|
||||
holder.imdmLayout.setVisibility(View.VISIBLE);
|
||||
holder.imdmIcon.setImageResource(R.drawable.chat_error);
|
||||
holder.imdmIcon.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setVisibility(View.VISIBLE);
|
||||
holder.imdmLabel.setText(R.string.file_transfer_error);
|
||||
holder.imdmLabel.setTextColor(mContext.getResources().getColor(R.color.colorI));
|
||||
}
|
||||
|
|
@ -474,7 +485,7 @@ public class ChatEventsAdapter extends ListSelectionAdapter {
|
|||
case SecurityLevelDowngraded:
|
||||
message = mContext.getString(R.string.security_level_degraded);
|
||||
break;
|
||||
case MultideviceParticipantDetected:
|
||||
case ParticipantMaxDeviceCountExceeded:
|
||||
holder.eventMessage.setTextColor(Color.RED);
|
||||
if (event.getSecurityEventFaultyDevice() != null) {
|
||||
message = mContext.getString(R.string.security_alert_multidevice_from).replace("%s", displayName);
|
||||
|
|
|
|||
|
|
@ -264,7 +264,7 @@ public class ChatRoomsAdapter extends ListSelectionAdapter {
|
|||
}
|
||||
}
|
||||
ChatRoomSecurityLevel level = chatRoom.getSecurityLevel();
|
||||
if (LinphoneManager.getLc().limeV2Enabled()) {
|
||||
if (LinphoneManager.getLc().limeX3DhEnabled()) {
|
||||
if (level == ChatRoomSecurityLevel.Safe) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_small_secure2);
|
||||
} else if (level == ChatRoomSecurityLevel.Unsafe) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue