Icon for group chats in messages list

(DEBUG) Option in settings to switch to test datacenters
Update some images
This commit is contained in:
DrKLO 2014-03-26 03:38:23 +04:00
parent d485410192
commit 1eeb12f666
45 changed files with 204 additions and 156 deletions

View File

@ -82,7 +82,7 @@ android {
defaultConfig {
minSdkVersion 8
targetSdkVersion 19
versionCode 211
versionName "1.4.8"
versionCode 212
versionName "1.4.9"
}
}

View File

@ -53,8 +53,7 @@ public class ConnectionsManager implements Action.ActionDelegate, TcpConnection.
public int currentDatacenterId;
public int movingToDatacenterId;
private long lastOutgoingMessageId = 0;
private int useDifferentBackend = 0;
private final int SESSION_VERSION = 2;
private int isTestBackend = 0;
public int timeDifference = 0;
public int currentPingTime;
private int lastDestroySessionRequestTime;
@ -228,7 +227,30 @@ public class ConnectionsManager implements Action.ActionDelegate, TcpConnection.
}
}
void loadSession() {
public void switchBackend() {
Utilities.stageQueue.postRunnable(new Runnable() {
@Override
public void run() {
if (isTestBackend == 0) {
isTestBackend = 1;
} else {
isTestBackend = 0;
}
datacenters.clear();
fillDatacenters();
saveSession();
Utilities.stageQueue.postRunnable(new Runnable() {
@Override
public void run() {
UserConfig.clearConfig();
System.exit(0);
}
});
}
});
}
private void loadSession() {
Utilities.stageQueue.postRunnable(new Runnable() {
@Override
public void run() {
@ -236,68 +258,61 @@ public class ConnectionsManager implements Action.ActionDelegate, TcpConnection.
if (configFile.exists()) {
try {
SerializedData data = new SerializedData(configFile);
int datacenterSetId = data.readInt32();
isTestBackend = data.readInt32();
int version = data.readInt32();
if (datacenterSetId == useDifferentBackend && version == SESSION_VERSION) {
sessionsToDestroy.clear();
int count = data.readInt32();
for (int a = 0; a < count; a++) {
sessionsToDestroy.add(data.readInt64());
}
timeDifference = data.readInt32();
count = data.readInt32();
for (int a = 0; a < count; a++) {
Datacenter datacenter = new Datacenter(data, 0);
datacenters.put(datacenter.datacenterId, datacenter);
}
currentDatacenterId = data.readInt32();
} else {
UserConfig.clearConfig();
sessionsToDestroy.clear();
int count = data.readInt32();
for (int a = 0; a < count; a++) {
sessionsToDestroy.add(data.readInt64());
}
timeDifference = data.readInt32();
count = data.readInt32();
for (int a = 0; a < count; a++) {
Datacenter datacenter = new Datacenter(data, 0);
datacenters.put(datacenter.datacenterId, datacenter);
}
currentDatacenterId = data.readInt32();
} catch (Exception e) {
UserConfig.clearConfig();
}
} else {
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("dataconfig", Context.MODE_PRIVATE);
int datacenterSetId = preferences.getInt("datacenterSetId", 0);
if (datacenterSetId == useDifferentBackend) {
currentDatacenterId = preferences.getInt("currentDatacenterId", 0);
timeDifference = preferences.getInt("timeDifference", 0);
lastDcUpdateTime = preferences.getInt("lastDcUpdateTime", 0);
try {
sessionsToDestroy.clear();
String sessionsString = preferences.getString("sessionsToDestroy", null);
if (sessionsString != null) {
byte[] sessionsBytes = Base64.decode(sessionsString, Base64.DEFAULT);
if (sessionsBytes != null) {
SerializedData data = new SerializedData(sessionsBytes);
int count = data.readInt32();
for (int a = 0; a < count; a++) {
sessionsToDestroy.add(data.readInt64());
}
isTestBackend = preferences.getInt("datacenterSetId", 0);
currentDatacenterId = preferences.getInt("currentDatacenterId", 0);
timeDifference = preferences.getInt("timeDifference", 0);
lastDcUpdateTime = preferences.getInt("lastDcUpdateTime", 0);
try {
sessionsToDestroy.clear();
String sessionsString = preferences.getString("sessionsToDestroy", null);
if (sessionsString != null) {
byte[] sessionsBytes = Base64.decode(sessionsString, Base64.DEFAULT);
if (sessionsBytes != null) {
SerializedData data = new SerializedData(sessionsBytes);
int count = data.readInt32();
for (int a = 0; a < count; a++) {
sessionsToDestroy.add(data.readInt64());
}
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
try {
String datacentersString = preferences.getString("datacenters", null);
if (datacentersString != null) {
byte[] datacentersBytes = Base64.decode(datacentersString, Base64.DEFAULT);
if (datacentersBytes != null) {
SerializedData data = new SerializedData(datacentersBytes);
int count = data.readInt32();
for (int a = 0; a < count; a++) {
Datacenter datacenter = new Datacenter(data, 1);
datacenters.put(datacenter.datacenterId, datacenter);
}
try {
String datacentersString = preferences.getString("datacenters", null);
if (datacentersString != null) {
byte[] datacentersBytes = Base64.decode(datacentersString, Base64.DEFAULT);
if (datacentersBytes != null) {
SerializedData data = new SerializedData(datacentersBytes);
int count = data.readInt32();
for (int a = 0; a < count; a++) {
Datacenter datacenter = new Datacenter(data, 1);
datacenters.put(datacenter.datacenterId, datacenter);
}
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
}
@ -310,69 +325,7 @@ public class ConnectionsManager implements Action.ActionDelegate, TcpConnection.
}
}
if (datacenters.size() == 0) {
if (useDifferentBackend == 0) {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 1;
datacenter.addAddressAndPort("173.240.5.1", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.193", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.6", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 4;
datacenter.addAddressAndPort("31.210.235.12", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 5;
datacenter.addAddressAndPort("116.51.22.2", 443);
datacenters.put(datacenter.datacenterId, datacenter);
} else {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 1;
datacenter.addAddressAndPort("173.240.5.253", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.195", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.5", 443);
datacenters.put(datacenter.datacenterId, datacenter);
}
} else if (datacenters.size() == 1) {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.193", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.6", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 4;
datacenter.addAddressAndPort("31.210.235.12", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 5;
datacenter.addAddressAndPort("116.51.22.2", 443);
datacenters.put(datacenter.datacenterId, datacenter);
}
fillDatacenters();
for (Datacenter datacenter : datacenters.values()) {
datacenter.authSessionId = getNewSessionId();
@ -387,14 +340,80 @@ public class ConnectionsManager implements Action.ActionDelegate, TcpConnection.
});
}
void saveSession() {
private void fillDatacenters() {
if (datacenters.size() == 0) {
if (isTestBackend == 0) {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 1;
datacenter.addAddressAndPort("173.240.5.1", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.193", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.6", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 4;
datacenter.addAddressAndPort("31.210.235.12", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 5;
datacenter.addAddressAndPort("116.51.22.2", 443);
datacenters.put(datacenter.datacenterId, datacenter);
} else {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 1;
datacenter.addAddressAndPort("173.240.5.253", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.195", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.5", 443);
datacenters.put(datacenter.datacenterId, datacenter);
}
} else if (datacenters.size() == 1) {
Datacenter datacenter = new Datacenter();
datacenter.datacenterId = 2;
datacenter.addAddressAndPort("109.239.131.193", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 3;
datacenter.addAddressAndPort("174.140.142.6", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 4;
datacenter.addAddressAndPort("31.210.235.12", 443);
datacenters.put(datacenter.datacenterId, datacenter);
datacenter = new Datacenter();
datacenter.datacenterId = 5;
datacenter.addAddressAndPort("116.51.22.2", 443);
datacenters.put(datacenter.datacenterId, datacenter);
}
}
private void saveSession() {
Utilities.stageQueue.postRunnable(new Runnable() {
@Override
public void run() {
try {
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("dataconfig", Context.MODE_PRIVATE);
SharedPreferences.Editor editor = preferences.edit();
editor.putInt("datacenterSetId", useDifferentBackend);
editor.putInt("datacenterSetId", isTestBackend);
Datacenter currentDatacenter = datacenterWithId(currentDatacenterId);
if (currentDatacenter != null) {
editor.putInt("currentDatacenterId", currentDatacenterId);

View File

@ -22,7 +22,6 @@ import org.telegram.PhoneFormat.PhoneFormat;
import org.telegram.messenger.LocaleController;
import org.telegram.messenger.TLRPC;
import org.telegram.messenger.ConnectionsManager;
import org.telegram.messenger.ContactsController;
import org.telegram.messenger.MessagesController;
import org.telegram.messenger.R;
import org.telegram.messenger.UserConfig;
@ -296,27 +295,16 @@ public class ChatOrUserCell extends BaseCell {
if (chat != null) {
nameString2 = chat.title;
} else if (user != null) {
if (user.id / 1000 != 333 && ContactsController.getInstance().contactsDict.get(user.id) == null) {
if (ContactsController.getInstance().contactsDict.size() == 0 && ContactsController.getInstance().loadingContacts) {
nameString2 = Utilities.formatName(user.first_name, user.last_name);
} else {
if (user.phone != null && user.phone.length() != 0) {
nameString2 = PhoneFormat.getInstance().format("+" + user.phone);
} else {
nameString2 = Utilities.formatName(user.first_name, user.last_name);
}
}
} else {
nameString2 = Utilities.formatName(user.first_name, user.last_name);
}
nameString2 = Utilities.formatName(user.first_name, user.last_name);
}
nameString = nameString2.replace("\n", " ");
}
if (nameString.length() == 0) {
if (user.phone != null && user.phone.length() != 0) {
nameString = PhoneFormat.getInstance().format("+" + user.phone);
} else {
nameString = LocaleController.getString("HiddenName", R.string.HiddenName);
}
nameString = LocaleController.getString("HiddenName", R.string.HiddenName);
}
if (encryptedChat != null) {
currentNamePaint = nameEncryptedPaint;

View File

@ -47,6 +47,7 @@ public class DialogCell extends BaseCell {
private static Drawable errorDrawable;
private static Drawable lockDrawable;
private static Drawable countDrawable;
private static Drawable groupDrawable;
private TLRPC.TL_dialog currentDialog;
private ImageReceiver avatarImage;
@ -127,6 +128,10 @@ public class DialogCell extends BaseCell {
countDrawable = getResources().getDrawable(R.drawable.dialogs_badge);
}
if (groupDrawable == null) {
groupDrawable = getResources().getDrawable(R.drawable.grouplist);
}
if (avatarImage == null) {
avatarImage = new ImageReceiver();
avatarImage.parentView = new WeakReference<View>(this);
@ -260,6 +265,9 @@ public class DialogCell extends BaseCell {
if (cellLayout.drawNameLock) {
setDrawableBounds(lockDrawable, cellLayout.nameLockLeft, cellLayout.nameLockTop);
lockDrawable.draw(canvas);
} else if (cellLayout.drawNameGroup) {
setDrawableBounds(groupDrawable, cellLayout.nameLockLeft, cellLayout.nameLockTop);
groupDrawable.draw(canvas);
}
canvas.save();
@ -313,8 +321,9 @@ public class DialogCell extends BaseCell {
private int nameWidth;
private StaticLayout nameLayout;
private boolean drawNameLock;
private boolean drawNameGroup;
private int nameLockLeft;
private int nameLockTop = Utilities.dp(13);
private int nameLockTop;
private int timeLeft;
private int timeTop = Utilities.dp(13);
@ -359,6 +368,8 @@ public class DialogCell extends BaseCell {
if (encryptedChat != null) {
drawNameLock = true;
drawNameGroup = false;
nameLockTop = Utilities.dp(13);
if (!LocaleController.isRTL) {
nameLockLeft = Utilities.dp(77);
nameLeft = Utilities.dp(81) + lockDrawable.getIntrinsicWidth();
@ -368,10 +379,23 @@ public class DialogCell extends BaseCell {
}
} else {
drawNameLock = false;
if (!LocaleController.isRTL) {
nameLeft = Utilities.dp(77);
if (chat != null) {
drawNameGroup = true;
nameLockTop = Utilities.dp(14);
if (!LocaleController.isRTL) {
nameLockLeft = Utilities.dp(77);
nameLeft = Utilities.dp(81) + groupDrawable.getIntrinsicWidth();
} else {
nameLockLeft = width - Utilities.dp(77) - groupDrawable.getIntrinsicWidth();
nameLeft = Utilities.dp(14);
}
} else {
nameLeft = Utilities.dp(14);
drawNameGroup = false;
if (!LocaleController.isRTL) {
nameLeft = Utilities.dp(77);
} else {
nameLeft = Utilities.dp(14);
}
}
}
@ -547,6 +571,8 @@ public class DialogCell extends BaseCell {
}
if (drawNameLock) {
nameWidth -= Utilities.dp(4) + lockDrawable.getIntrinsicWidth();
} else if (drawNameGroup) {
nameWidth -= Utilities.dp(4) + groupDrawable.getIntrinsicWidth();
}
if (drawClock) {
int w = clockDrawable.getIntrinsicWidth() + Utilities.dp(2);

View File

@ -263,11 +263,8 @@ public class LanguageSelectActivity extends BaseFragment {
searching = false;
searchWas = false;
if (listView != null) {
listView.setEmptyView(emptyTextView);
emptyTextView.setVisibility(View.GONE);
}
if (listAdapter != null) {
listAdapter.notifyDataSetChanged();
listView.setAdapter(listAdapter);
}
((LaunchActivity)parentActivity).fixBackButton();
return true;

View File

@ -77,6 +77,7 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
private int logoutRow;
private int sendLogsRow;
private int clearLogsRow;
private int switchBackendButtonRow;
private int rowCount;
private int messagesSectionRow;
private int sendByEnterRow;
@ -175,6 +176,7 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
if (BuildVars.DEBUG_VERSION) {
sendLogsRow = rowCount++;
clearLogsRow = rowCount++;
switchBackendButtonRow = rowCount++;
}
askQuestionRow = rowCount++;
logoutRow = rowCount++;
@ -408,6 +410,18 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
}
} else if (i == languageRow) {
((LaunchActivity)parentActivity).presentFragment(new LanguageSelectActivity(), "settings_wallpapers", false);
} else if (i == switchBackendButtonRow) {
AlertDialog.Builder builder = new AlertDialog.Builder(parentActivity);
builder.setMessage(LocaleController.getString("AreYouSure", R.string.AreYouSure));
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setPositiveButton(LocaleController.getString("OK", R.string.OK), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
ConnectionsManager.getInstance().switchBackend();
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
builder.show().setCanceledOnTouchOutside(true);
}
// else if (i == 6) {
// UserConfig.saveIncomingPhotos = !UserConfig.saveIncomingPhotos;
@ -542,7 +556,8 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
public boolean isEnabled(int i) {
return i == textSizeRow || i == enableAnimationsRow || i == blockedRow || i == notificationRow || i == backgroundRow ||
i == askQuestionRow || i == sendLogsRow || i == sendByEnterRow || i == terminateSessionsRow || i == photoDownloadPrivateRow ||
i == photoDownloadChatRow || i == clearLogsRow || i == audioDownloadChatRow || i == audioDownloadPrivateRow || i == languageRow;
i == photoDownloadChatRow || i == clearLogsRow || i == audioDownloadChatRow || i == audioDownloadPrivateRow || i == languageRow ||
i == switchBackendButtonRow;
}
@Override
@ -748,6 +763,9 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
} else if (i == terminateSessionsRow) {
textView.setText(LocaleController.getString("TerminateAllSessions", R.string.TerminateAllSessions));
divider.setVisibility(View.INVISIBLE);
} else if (i == switchBackendButtonRow) {
textView.setText("Switch Backend");
divider.setVisibility(View.VISIBLE);
}
} else if (type == 3) {
if (view == null) {
@ -883,7 +901,7 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
return 5;
} else if (i == enableAnimationsRow || i == sendByEnterRow || i == photoDownloadChatRow || i == photoDownloadPrivateRow || i == audioDownloadChatRow || i == audioDownloadPrivateRow) {
return 3;
} else if (i == numberRow || i == notificationRow || i == blockedRow || i == backgroundRow || i == askQuestionRow || i == sendLogsRow || i == terminateSessionsRow || i == clearLogsRow) {
} else if (i == numberRow || i == notificationRow || i == blockedRow || i == backgroundRow || i == askQuestionRow || i == sendLogsRow || i == terminateSessionsRow || i == clearLogsRow || i == switchBackendButtonRow) {
return 2;
} else if (i == logoutRow) {
return 4;

Binary file not shown.

After

Width:  |  Height:  |  Size: 552 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 952 B

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 967 B

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 301 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 709 B

After

Width:  |  Height:  |  Size: 806 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 715 B

After

Width:  |  Height:  |  Size: 805 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 838 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 857 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 464 B

After

Width:  |  Height:  |  Size: 564 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 475 B

After

Width:  |  Height:  |  Size: 591 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 377 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 812 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 848 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 688 B

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 722 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 598 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 877 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 5.1 KiB

View File

@ -37,15 +37,15 @@
android:id="@+id/chat_photo_image"/>
<org.telegram.ui.Views.FrameLayoutFixed
android:layout_height="40dp"
android:layout_width="40dp"
android:layout_height="44dp"
android:layout_width="44dp"
android:id="@+id/chat_view_action_layout"
android:layout_gravity="center"
android:visibility="visible">
<ImageView
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_width="44dp"
android:layout_height="44dp"
android:scaleType="centerInside"
android:id="@+id/chat_view_action_cancel_button"
android:src="@drawable/photo_download_states"

View File

@ -27,15 +27,15 @@
android:id="@+id/chat_photo_image"/>
<org.telegram.ui.Views.FrameLayoutFixed
android:layout_height="40dp"
android:layout_width="40dp"
android:layout_height="44dp"
android:layout_width="44dp"
android:id="@+id/chat_view_action_layout"
android:layout_gravity="center"
android:visibility="visible">
<ImageView
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_width="44dp"
android:layout_height="44dp"
android:scaleType="centerInside"
android:id="@+id/chat_view_action_cancel_button"
android:src="@drawable/photo_download_states"

View File

@ -151,7 +151,7 @@
android:layout_marginTop="2dp"
android:maxLines="4"
android:minHeight="48dp"
android:textSize="18dp"
android:textSize="18sp"
android:textColorHint="#909090"
android:ems="10"
android:imeOptions="flagNoExtractUi"

View File

@ -27,15 +27,15 @@
android:id="@+id/chat_photo_image"/>
<org.telegram.ui.Views.FrameLayoutFixed
android:layout_height="40dp"
android:layout_width="40dp"
android:layout_height="44dp"
android:layout_width="44dp"
android:id="@+id/chat_view_action_layout"
android:layout_gravity="center"
android:visibility="visible">
<ImageView
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_width="44dp"
android:layout_height="44dp"
android:scaleType="centerInside"
android:id="@+id/chat_view_action_cancel_button"
android:src="@drawable/photo_download_cancel_states"