From 2ad0861559c687d438b181fdb9933e9614282419 Mon Sep 17 00:00:00 2001 From: qwe7002 Date: Thu, 2 Apr 2020 17:47:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=AE=A1=E6=95=B0=E5=99=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../qwe7002/telegram_sms_compat/chat_command_service.java | 7 ++++++- .../telegram_sms_compat/notify_apps_list_activity.java | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/qwe7002/telegram_sms_compat/chat_command_service.java b/app/src/main/java/com/qwe7002/telegram_sms_compat/chat_command_service.java index 7758023..62bd476 100644 --- a/app/src/main/java/com/qwe7002/telegram_sms_compat/chat_command_service.java +++ b/app/src/main/java/com/qwe7002/telegram_sms_compat/chat_command_service.java @@ -197,7 +197,12 @@ private void receive_handle(JsonObject result_obj) { break; case "/ping": case "/getinfo": - request_body.text = getString(R.string.system_message_head) + "\n" + context.getString(R.string.current_battery_level) + get_battery_info(context) + "\n" + getString(R.string.current_network_connection_status) + public_func.get_network_type(context) + "\nSIM:" + public_func.get_sim_name(context); + String spam_count = ""; + ArrayList spam_list = Paper.book().read("spam_sms_list", new ArrayList<>()); + if (spam_list.size() != 0) { + spam_count = "\n" + getString(R.string.spam_count_title) + spam_list.size(); + } + request_body.text = getString(R.string.system_message_head) + "\n" + context.getString(R.string.current_battery_level) + get_battery_info(context) + "\n" + getString(R.string.current_network_connection_status) + public_func.get_network_type(context) + spam_count + "\nSIM:" + public_func.get_sim_name(context); has_command = true; break; case "/log": diff --git a/app/src/main/java/com/qwe7002/telegram_sms_compat/notify_apps_list_activity.java b/app/src/main/java/com/qwe7002/telegram_sms_compat/notify_apps_list_activity.java index bd50d1b..a3e27ef 100644 --- a/app/src/main/java/com/qwe7002/telegram_sms_compat/notify_apps_list_activity.java +++ b/app/src/main/java/com/qwe7002/telegram_sms_compat/notify_apps_list_activity.java @@ -204,7 +204,6 @@ static class view_holder { TextView package_name; CheckBox app_checkbox; } - } static class app_info {