mirror of
https://github.com/ArcaneChat/android.git
synced 2026-07-03 14:05:24 +02:00
Merge pull request #3985 from deltachat/update-core-and-stuff-1/11/25
update core to 2.23.0
This commit is contained in:
+7
-1
@@ -2,10 +2,16 @@
|
||||
|
||||
## Unreleased
|
||||
|
||||
* metadata protection: protect Date header
|
||||
* metadata protection: protect Autocrypt header
|
||||
* better multi-device: synchronize group creation across devices
|
||||
* data saving: do not send Autocrypt header in read receipts
|
||||
* improve onboarding speed
|
||||
* don't show badge counter in app icon for the permanent background notification
|
||||
* remove deprecated "companion app" code
|
||||
* remove "Watch Sent Folder" preference
|
||||
* remove deprecated "Watch Sent Folder" preference
|
||||
* fix sorting of old media in gallery
|
||||
* update to core 2.23.0
|
||||
|
||||
## v2.22.0
|
||||
2025-10
|
||||
|
||||
+2
-7
@@ -536,10 +536,10 @@ JNIEXPORT jint Java_com_b44t_messenger_DcContext_createChatByContactId(JNIEnv *e
|
||||
}
|
||||
|
||||
|
||||
JNIEXPORT jint Java_com_b44t_messenger_DcContext_createGroupChat(JNIEnv *env, jobject obj, jboolean verified, jstring name)
|
||||
JNIEXPORT jint Java_com_b44t_messenger_DcContext_createGroupChat(JNIEnv *env, jobject obj, jstring name)
|
||||
{
|
||||
CHAR_REF(name);
|
||||
jint ret = (jint)dc_create_group_chat(get_dc_context(env, obj), verified, namePtr);
|
||||
jint ret = (jint)dc_create_group_chat(get_dc_context(env, obj), 0, namePtr);
|
||||
CHAR_UNREF(name);
|
||||
return ret;
|
||||
}
|
||||
@@ -1261,11 +1261,6 @@ JNIEXPORT jboolean Java_com_b44t_messenger_DcChat_canSend(JNIEnv *env, jobject o
|
||||
}
|
||||
|
||||
|
||||
JNIEXPORT jboolean Java_com_b44t_messenger_DcChat_isProtected(JNIEnv *env, jobject obj)
|
||||
{
|
||||
return dc_chat_is_protected(get_dc_chat(env, obj))!=0;
|
||||
}
|
||||
|
||||
|
||||
JNIEXPORT jboolean Java_com_b44t_messenger_DcChat_isSendingLocations(JNIEnv *env, jobject obj)
|
||||
{
|
||||
|
||||
+1
-1
Submodule jni/deltachat-core-rust updated: 41c80cf3f2...c9b3da4a1a
@@ -54,7 +54,7 @@ public class ForwardingTest {
|
||||
// The thing is, DC_STATE_OUT_PENDING show a rotating circle animation, and Espresso doesn't work
|
||||
// with animations, and the tests would hang and never finish.
|
||||
dcContext.setConfig("bcc_self", "0");
|
||||
activityRule.getScenario().onActivity(a -> createdGroupId = DcHelper.getContext(a).createGroupChat(false, "group"));
|
||||
activityRule.getScenario().onActivity(a -> createdGroupId = DcHelper.getContext(a).createGroupChat( "group"));
|
||||
}
|
||||
|
||||
@After
|
||||
|
||||
@@ -52,7 +52,7 @@ public class SharingTest {
|
||||
|
||||
@Before
|
||||
public void createGroup() {
|
||||
activityRule.getScenario().onActivity(a -> createdGroupId = DcHelper.getContext(a).createGroupChat(false, "group"));
|
||||
activityRule.getScenario().onActivity(a -> createdGroupId = DcHelper.getContext(a).createGroupChat( "group"));
|
||||
}
|
||||
|
||||
@Before
|
||||
|
||||
@@ -44,7 +44,6 @@ public class DcChat {
|
||||
public native boolean isSelfTalk ();
|
||||
public native boolean isDeviceTalk ();
|
||||
public native boolean canSend ();
|
||||
public native boolean isProtected ();
|
||||
public native boolean isSendingLocations();
|
||||
public native boolean isMuted ();
|
||||
public native boolean isContactRequest ();
|
||||
|
||||
@@ -165,7 +165,7 @@ public class DcContext {
|
||||
public native void setChatVisibility (int chat_id, int visibility);
|
||||
public native int getChatIdByContactId (int contact_id);
|
||||
public native int createChatByContactId(int contact_id);
|
||||
public native int createGroupChat (boolean verified, String name);
|
||||
public native int createGroupChat (String name);
|
||||
public native int createBroadcastList ();
|
||||
public native boolean isContactInChat (int chat_id, int contact_id);
|
||||
public native int addContactToChat (int chat_id, int contact_id);
|
||||
|
||||
@@ -79,7 +79,6 @@ public class ContactSelectionListFragment extends Fragment
|
||||
private static final String TAG = ContactSelectionListFragment.class.getSimpleName();
|
||||
|
||||
public static final String MULTI_SELECT = "multi_select";
|
||||
public static final String SELECT_VERIFIED_EXTRA = "select_verified";
|
||||
public static final String SELECT_UNENCRYPTED_EXTRA = "select_unencrypted_extra";
|
||||
public static final String ALLOW_CREATION = "allow_creation";
|
||||
public static final String PRESELECTED_CONTACTS = "preselected_contacts";
|
||||
@@ -240,10 +239,6 @@ public class ContactSelectionListFragment extends Fragment
|
||||
return getActivity().getIntent().getBooleanExtra(MULTI_SELECT, false);
|
||||
}
|
||||
|
||||
private boolean isSelectVerfied() {
|
||||
return getActivity().getIntent().getBooleanExtra(SELECT_VERIFIED_EXTRA, false);
|
||||
}
|
||||
|
||||
private boolean isUnencrypted() {
|
||||
return getActivity().getIntent().getBooleanExtra(SELECT_UNENCRYPTED_EXTRA, false);
|
||||
}
|
||||
@@ -348,17 +343,6 @@ public class ContactSelectionListFragment extends Fragment
|
||||
return;
|
||||
}
|
||||
|
||||
if (isSelectVerfied() && !contact.getDcContact().isVerified()) {
|
||||
new AlertDialog.Builder(getActivity())
|
||||
.setMessage(R.string.verified_contact_required_explain)
|
||||
.setNeutralButton(R.string.learn_more, (d, w) -> DcHelper.openHelp(getActivity(), "#howtoe2ee"))
|
||||
.setNegativeButton(R.string.qrscan_title, (d, w) -> getActivity().startActivity(new Intent(getActivity(), QrActivity.class)))
|
||||
.setPositiveButton(R.string.ok, null)
|
||||
.setCancelable(true)
|
||||
.show();
|
||||
return;
|
||||
}
|
||||
|
||||
selectedContacts.add(contactId);
|
||||
contact.setChecked(true);
|
||||
if (onContactSelectedListener != null) {
|
||||
|
||||
@@ -60,7 +60,6 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
|
||||
private DcContext dcContext;
|
||||
|
||||
private boolean verified;
|
||||
private boolean unencrypted;
|
||||
private boolean broadcast;
|
||||
private EditText groupName;
|
||||
@@ -77,7 +76,6 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
protected void onCreate(Bundle state, boolean ready) {
|
||||
dcContext = DcHelper.getContext(this);
|
||||
setContentView(R.layout.group_create_activity);
|
||||
verified = false;
|
||||
broadcast = getIntent().getBooleanExtra(CREATE_BROADCAST, false);
|
||||
unencrypted = getIntent().getBooleanExtra(UNENCRYPTED, false);
|
||||
Objects.requireNonNull(getSupportActionBar()).setDisplayHomeAsUpEnabled(true);
|
||||
@@ -93,7 +91,6 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
if(groupChatId !=0) {
|
||||
isEdit = true;
|
||||
DcChat dcChat = dcContext.getChat(groupChatId);
|
||||
verified = dcChat.isProtected();
|
||||
broadcast = dcChat.isOutBroadcast();
|
||||
unencrypted = !dcChat.isEncrypted();
|
||||
}
|
||||
@@ -234,7 +231,6 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
if (groupChatId != 0) {
|
||||
updateGroup(groupName);
|
||||
} else {
|
||||
verified = !unencrypted && !broadcast && allMembersVerified();
|
||||
createGroup(groupName);
|
||||
}
|
||||
|
||||
@@ -244,21 +240,10 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean allMembersVerified() {
|
||||
for (int id : getAdapter().getContacts()) {
|
||||
DcContact contact = dcContext.getContact(id);
|
||||
if (contact != null && !contact.isVerified()) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onItemClick(int contactId) {
|
||||
if (contactId == DcContact.DC_CONTACT_ID_ADD_MEMBER) {
|
||||
Intent intent = new Intent(this, ContactMultiSelectionActivity.class);
|
||||
intent.putExtra(ContactSelectionListFragment.SELECT_VERIFIED_EXTRA, verified);
|
||||
intent.putExtra(ContactSelectionListFragment.SELECT_UNENCRYPTED_EXTRA, unencrypted);
|
||||
ArrayList<Integer> preselectedContacts = new ArrayList<>(getAdapter().getContacts());
|
||||
intent.putExtra(ContactSelectionListFragment.PRESELECTED_CONTACTS, preselectedContacts);
|
||||
@@ -287,7 +272,7 @@ public class GroupCreateActivity extends PassphraseRequiredActionBarActivity
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
groupChatId = dcContext.createGroupChat(verified, groupName);
|
||||
groupChatId = dcContext.createGroupChat(groupName);
|
||||
}
|
||||
|
||||
for (int contactId : getAdapter().getContacts()) {
|
||||
|
||||
@@ -201,7 +201,6 @@ public class ProfileFragment extends Fragment
|
||||
public void onAddMember() {
|
||||
DcChat dcChat = dcContext.getChat(chatId);
|
||||
Intent intent = new Intent(getContext(), ContactMultiSelectionActivity.class);
|
||||
intent.putExtra(ContactSelectionListFragment.SELECT_VERIFIED_EXTRA, dcChat.isProtected());
|
||||
ArrayList<Integer> preselectedContacts = new ArrayList<>();
|
||||
for (int memberId : dcContext.getChatContacts(chatId)) {
|
||||
preselectedContacts.add(memberId);
|
||||
|
||||
@@ -396,7 +396,7 @@ public class DcHelper {
|
||||
|
||||
return new ThreadRecord(body, recipient, date,
|
||||
unreadCount, chatId,
|
||||
chat.getVisibility(), chat.isProtected(), chat.isSendingLocations(), chat.isMuted(), chat.isContactRequest(), summary);
|
||||
chat.getVisibility(), chat.isSendingLocations(), chat.isMuted(), chat.isContactRequest(), summary);
|
||||
}
|
||||
|
||||
public static boolean isNetworkConnected(Context context) {
|
||||
|
||||
@@ -43,7 +43,6 @@ public class ThreadRecord {
|
||||
|
||||
private final int unreadCount;
|
||||
private final int visibility;
|
||||
private final boolean isProtected;
|
||||
private final boolean isSendingLocations;
|
||||
private final boolean isMuted;
|
||||
private final boolean isContactRequest;
|
||||
@@ -53,7 +52,6 @@ public class ThreadRecord {
|
||||
@NonNull Recipient recipient, long dateReceived, int unreadCount,
|
||||
long threadId,
|
||||
int visibility,
|
||||
boolean isProtected,
|
||||
boolean isSendingLocations,
|
||||
boolean isMuted,
|
||||
boolean isContactRequest,
|
||||
@@ -65,7 +63,6 @@ public class ThreadRecord {
|
||||
this.body = body;
|
||||
this.unreadCount = unreadCount;
|
||||
this.visibility = visibility;
|
||||
this.isProtected = isProtected;
|
||||
this.isSendingLocations = isSendingLocations;
|
||||
this.isMuted = isMuted;
|
||||
this.isContactRequest = isContactRequest;
|
||||
@@ -116,10 +113,6 @@ public class ThreadRecord {
|
||||
return visibility;
|
||||
}
|
||||
|
||||
public boolean isProtected() {
|
||||
return isProtected;
|
||||
}
|
||||
|
||||
public boolean isSendingLocations() {
|
||||
return isSendingLocations;
|
||||
}
|
||||
|
||||
@@ -1028,6 +1028,7 @@
|
||||
<string name="verified_by">Introduced by %1$s</string>
|
||||
<string name="verified_by_you">Introduced by me</string>
|
||||
<string name="verified_by_unknown">Introduced</string>
|
||||
<!-- deprecated -->
|
||||
<string name="verified_contact_required_explain">To guarantee end-to-end-encryption, you can only add contacts with a green checkmark to this group.\n\nYou may meet contacts in person and scan their QR Code to introduce them.</string>
|
||||
<string name="mailto_dialog_header_select_chat">Select chat to send the message to</string>
|
||||
<!-- first placeholder is the name of the chat -->
|
||||
|
||||
Reference in New Issue
Block a user