From 5f4f71d43d7494e87e42ceedac7cf7b8ecd4c497 Mon Sep 17 00:00:00 2001 From: Austen Adler Date: Mon, 25 Jul 2016 02:29:02 -0400 Subject: [PATCH] Possibly improved screenshots --- .../java/org/telegram/ui/ChatActivity.java | 27 +------------------ 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/TMessagesProj/src/main/java/org/telegram/ui/ChatActivity.java b/TMessagesProj/src/main/java/org/telegram/ui/ChatActivity.java index ce9f0f8a..97c5b0f1 100644 --- a/TMessagesProj/src/main/java/org/telegram/ui/ChatActivity.java +++ b/TMessagesProj/src/main/java/org/telegram/ui/ChatActivity.java @@ -725,13 +725,6 @@ public class ChatActivity extends BaseFragment implements NotificationCenter.Not } if (currentEncryptedChat != null) { MediaController.getInstance().stopMediaObserver(); - try { - if (Build.VERSION.SDK_INT >= 14) { - getParentActivity().getWindow().clearFlags(WindowManager.LayoutParams.FLAG_SECURE); - } - } catch (Throwable e) { - FileLog.e("tmessages", e); - } } if (currentUser != null) { MessagesController.getInstance().cancelLoadFullUser(currentUser.id); @@ -7025,25 +7018,7 @@ public class ChatActivity extends BaseFragment implements NotificationCenter.Not } private void updateInformationForScreenshotDetector() { - if (currentEncryptedChat == null) { - return; - } - ArrayList visibleMessages = new ArrayList<>(); - if (chatListView != null) { - int count = chatListView.getChildCount(); - for (int a = 0; a < count; a++) { - View view = chatListView.getChildAt(a); - MessageObject object = null; - if (view instanceof ChatBaseCell) { - ChatBaseCell cell = (ChatBaseCell) view; - object = cell.getMessageObject(); - } - if (object != null && object.getId() < 0 && object.messageOwner.random_id != 0) { - visibleMessages.add(object.messageOwner.random_id); - } - } - } - MediaController.getInstance().setLastEncryptedChatParams(chatEnterTime, chatLeaveTime, currentEncryptedChat, visibleMessages); + return; } private boolean fixLayoutInternal() {