Commit graph

166 commits

Author SHA1 Message Date
adbenitez
bd8698c3f3 add DcContact.isKeyContact() 2025-06-30 18:58:28 +02:00
adbenitez
966d8784f3 adapt to new PGP-contacts 2025-06-24 17:46:51 +02:00
bjoern
bc73e1a2ba
open contact in scope when tapping info messages (#3710)
* open contact in scope when tapping info messages

* update CHANGELOG

---------

Co-authored-by: adb <adb@merlinux.eu>
2025-04-12 00:22:24 +02:00
bjoern
e2d7f2c3d3
prefer NAME over NAME (ADDR) (#3699)
* prefer NAME over NAME (ADDR)

this tunes the usage of email addresses further down,
in all cases, the profile should only be a tap away before or afterwards,
so, these mentionings were never really critical

* update CHANGELOG

* Update CHANGELOG.md

Co-authored-by: adb <adb@merlinux.eu>

---------

Co-authored-by: adb <adb@merlinux.eu>
2025-04-02 16:41:36 +02:00
B. Petersen
5e6c5d7c5e remove unused ASM code; the API calls were only partly removed at #3594 2025-03-20 18:40:29 +01:00
adbenitez
a640c81c73 add bindings for new "delete for everyone" API 2025-02-27 22:29:58 +01:00
adbenitez
fb759e12f0 fix bindings 2025-02-27 17:41:53 +01:00
adbenitez
c94f9371fe add C bindings 2025-02-27 17:32:56 +01:00
B. Petersen
38ed95003f removed unused setFile()
the corresponding cffi function will be removed soon,
see https://github.com/deltachat/deltachat-core-rust/pull/6558
2025-02-20 23:28:43 +01:00
adbenitez
c1a49332d0 use JSON-RPC for addAccount 2025-02-19 16:33:31 +01:00
B. Petersen
d1f77d9de5 add 'save' option to chat's action bar 2025-02-05 16:34:43 +01:00
B. Petersen
0704f7f1e7 render saved messages accordingly 2025-02-05 16:34:43 +01:00
Hocuri
c6b89055d8
File deduplication, Android part (#3513) 2025-01-27 18:40:44 +01:00
Hocuri
963327dd64
Remove prepareMsg (and OUT_PREPARING message state) (#3468)
This PR removes prepareMsg, which put messages into the OUT_PREPARING state and was used while videos were recoded. It also removes the now-unused method isIncreation().
- It was buggy because when you forwarded a message while it was InPreparation, or when the app was killed while a message is InPreparation, the message would stay InPreparation forever.
- Android is the only UI using this InPreparation (according to @r10s, I didn't check this myself), so we can simplify some things in core, which will also make it easier to deduplicate blob files.
2024-12-11 13:53:36 +01:00
adbenitez
fbf88e102b remove 'description' parameter from webxdc's sendUpdate()
the 'description' parameter is about to be deprecated,
see https://github.com/deltachat/deltachat-core-rust/issues/6245
2024-11-24 21:34:22 +01:00
adbenitez
1ccbb7177f add DcMsg.getWebxdcHref() 2024-11-23 23:09:01 +01:00
link2xt
350cd0539c build: update NDK to r27
If we are dropping Android 4 support anyway,
can as well upgrade to the current LTS NDK
which requires API level 21 (Android 5.0).
2024-11-11 16:22:55 +00:00
B. Petersen
dad490074b the 'def' parameter is long gone. any comment will lie over time :) 2024-10-24 12:29:45 +02:00
adbenitez
4ce3869744 tweak dc_wrapper.c 2024-10-23 15:04:13 +02:00
adbenitez
249d57897e fix dc_wrapper.c 2024-10-23 15:04:13 +02:00
adbenitez
3c9cecbc39 add DcContext.createQrSvg() 2024-10-23 15:04:12 +02:00
Hocuri
28141bf942
Remove getNextMedia() to make compilation succeed again (#3330) 2024-10-04 16:16:21 +02:00
B. Petersen
e17d37ebb7 add backgroundFetch() api 2024-09-23 13:30:09 +02:00
Asiel Díaz Benítez
25f4766410
Merge pull request #3240 from deltachat/r10s/no-encrypt-database
stop 'encrypted database' experiment
2024-08-25 15:27:20 +02:00
B. Petersen
8deca3e4b4 add getAuthName() api 2024-08-22 16:01:49 +02:00
B. Petersen
c6b6b8e144 stop 'encrypted database' experiment
this PR removes options to create encrypted database.
existing encrypted databases will continue working for now.

the 'encrypted database' experiment started some years ago
was never finishes and already stopped working partly,
eg. importing backups as encrypted accounts stopped working
some years ago for newer android.

in the light of Signal's "encryption key flaw",
but also recent issues with worsending core things in Delta Chat,
it seems wise to concentrate on the core things ("you have one job!"),
and not on side topics comparable few persons are interested in.

also, it will become harder to maintain that path on upcoming api changes,
leaving the database open as opening is slow is needed but will become harder,
this will make notifications tricy,
may need additional effort to run in background etc.

all that is doable,
however, it will remove resources from far more important parts,
dangerously up to a level that breaks the app - a focus is limited.

also, no one really complained as it is already partly not-working,
it was _never_ working on desktop
(where it would make much more sense),
removal on iOS was flawless, see https://github.com/deltachat/deltachat-ios/pull/2011

tl;dr: better leave the protection up to the operating system
and concentrate on other things.
2024-08-16 13:13:44 +02:00
B. Petersen
50e66c7e66 mark bots in chat title and profile as such 2024-08-09 18:10:57 +02:00
B. Petersen
44bc7da0df add getData2Blob() needed for DC_EVENT_WEBXDC_REALTIME_DATA 2024-05-23 19:51:02 +02:00
B. Petersen
256c010b61 add FcmReceiveService 2024-05-07 15:34:50 +02:00
B. Petersen
dc55b5c64c remove unused getAllLocations() API 2024-04-29 19:49:59 +02:00
B. Petersen
e27f592c07 remove unused relicts from Mapbox -> Leaflet move 2024-04-28 23:22:59 +02:00
Asiel Díaz Benítez
9eaf8bb1f3
use new experimental maps integration (#3005)
* use new maps integration

* Update src/com/b44t/messenger/DcContext.java

Co-authored-by: bjoern <r10s@b44t.com>

* Update src/org/thoughtcrime/securesms/WebxdcActivity.java

Co-authored-by: bjoern <r10s@b44t.com>

* fix typo

---------

Co-authored-by: bjoern <r10s@b44t.com>
2024-04-25 12:04:13 -04:00
Hocuri
ee966f9006
Merge the verified-1:1 commits into main (#2752)
* Verified 1:1 chats, Android UI (#2560)

Depends on https://github.com/deltachat/deltachat-core-rust/pull/4315/.

Follow-up for https://github.com/deltachat/deltachat-android/pull/2541.

- Show a "verified" icon on protection changed update messages
- Add C API
- Show a dialog over the input bar not only for contact requests, but also when the protection is broken (using the new method `isHalfBlocked()`)
  - The positive button reads "OK" (as opposed to contact requests where it reads "Accept")
- Add SVG icons, remove PNG one
- Translations
- When tapping on the `DC_INFO_PROTECTION_{EN|DIS}ABLED` message, show more information (for now, it leads to the online preview of my FAQ PR)
- Block loading remote images in the "Full Msg View" not only for contact requests, also when the protection is broken (using the new method `isHalfBlocked()`)
- Show a big verified/crossed-out-verified symbol over the `DC_INFO_PROTECTION_{EN|DIS}ABLED` messages
- Fix a bug that was kind of present before (for contact requests) but only became really visible now:
  - Set a draft with an image (or other attachment)
  - Your chat partner breaks verification
  - Expected: Both the input bar and the draft image are hidden by the input-bar-dialog.
  - Bug behavior (before c31de5bcf): The input bar is hidden, but the draft image stays visible.

* change button order of verification-broken alert (#2621)

Having "OK" in the middle of the buttons is weird. The old order was:

```
End-to-end encryption cannot...
[More Info]  [OK] [Scan QR code]
```

1. _If_ the main purpose of the dialog would be to "Scan QR code",
   the text should point that out more, also the opening button.
   Then, the button position would be correct, however,
   it has to read "Cancel" then.

2. _However_, the main purpose of the dialog is to "Show Info",
   "Scan QR code" is only an optional offering and the button a shortcut only.
   And finishing "Show Info" is better done by a simple "OK".
   Then, the "OK" should be rightmost.

This PR implements the second option, the buttons read as follows afterwards:

```
End-to-end encryption cannot...
[More Info]  [Scan QR code] [OK]
```

* fix: load updated display name when chat protection breaks

* Implement feature flag for verified 1:1 chats

* Update res/values/strings.xml

Co-authored-by: Hocuri <hocuri@gmx.de>

* Update src/org/thoughtcrime/securesms/connect/DcHelper.java

* Make another AlertDialog

* Revert "Implement feature flag for verified 1:1 chats"

This reverts commit 2efd17edfc.

* Fix typo

* email server->email provider

---------

Co-authored-by: bjoern <r10s@b44t.com>
Co-authored-by: adbenitez <asieldbenitez@gmail.com>
2023-10-27 17:02:29 +02:00
link2xt
87d69c9a86 Remove unused osName argument from DcAccounts constructor 2023-10-26 20:09:50 +02:00
link2xt
1a13224ad2 Update to the new dc_accounts_new() API 2023-10-26 20:09:50 +02:00
B. Petersen
d208b011c5 show 'verified by SELF' as such
core was changed to return SELF from `get_verifier_id()`
at https://github.com/deltachat/deltachat-core-rust/pull/4754 -
until then, core will return always a contact-id,
which is equal to the current state
2023-09-28 21:46:15 +02:00
B. Petersen
ed9d0a9462 add getVerifierAddr/Id api 2023-09-26 10:46:37 +02:00
B. Petersen
0f09aba7af remove unused DcHttpResponse and related functions
they are replaced by jsonrpc in https://github.com/deltachat/deltachat-android/pull/2479
2023-09-25 21:14:36 +02:00
link2xt
72f2f8979e requestPtr 2023-04-22 22:53:57 +00:00
link2xt
070f2841cd Sending request works 2023-04-22 22:10:57 +00:00
link2xt
4f468a4b8f Add DcJsonrpcInstance class 2023-04-22 17:58:03 +00:00
link2xt
0e657eed56
Set WebView proxy to 0.0.0.0 when possible (#2539)
* Set WebView proxy to 0.0.0.0 when possible

* add DcHttpResponse to wrapper

* use new DcHttpResponse to show images in email-html-view

* null-encoding is fine for WebResourceResponse()

---------

Co-authored-by: B. Petersen <r10s@b44t.com>
2023-04-20 21:30:19 +02:00
bjoern
3cede346f3
add multi-device-setup (#2493)
* add DcBackupProvider add receiveBackup() wrappers

* add 'Add Another Device' item to settings

* add android-ifaddrs

core-rust uses getifaddrs() which is not available on android ndk.
pull in the code from https://github.com/morristech/android-ifaddrs
that provides an implementation.

* add BackupProviderActivity

* make SVG-hack reusable

* add BackupProviderFragment

* prepare scanning backup codes

* Revert "add android-ifaddrs"

This reverts commit 33b1424427620396f282805d37f8e05c67758546.

* more logging

* call receiveBackup() on scanning DC_QR_BACKUP

* Fixup for recvmmsg fallback

* protect BackupProviderActivity by system secret

* show transfer progress as provided form the core; hide qr-code once scanned

* add a permanent notification for the provider

* clarify what we are waiting for

* add a permanent notification for the receiver

* ask before finishing BackupProviderActivity

* it is fine to cancel the abort question by tapping outside the alert

* remove outdated comment from 'keep screen on'

* add and check TRANSFER_MODE

* rename BackupProviderActivity to BackupTransferActivity

* use our base activity

* start/stop IO in base activity

* use BackupTransferActivity also for scanning

* add BackupReceiverFragment

* show detailed transfer progress

* show details instead of percent during preparation, for now

* launch chatlist and remove welcome when transfer is done

* redirect to chatlist automatically after transfer succeeded

* reword

* make log accessible from send and receive activities

* bump version

* show error if backup provider creation fails

* remove unneeded format()

* show some context in the errors alerts, hide QR code sooner

* calculate transfer percentage as specified

* show a 'close' instead of a 'back' button to make visually clear, things are aborted (there is a quesion anyway)

* add option to copy backup-qr-code to clipboard

* remove vague retry statement, core will show a detailed error soon

* warn about QR codes on clipboard getting invalidated

* make basic strings translatable

* add troubleshooting menu item (once help is evolved, it may be a more visible button, may be localized, may be offline)

* rename to backup_transfer_fragment.xml

* add detailed instructions

* move 1,2,3 layout to the .xml

* fix layout

* use text size used elsewhere

* do best effort to show SSID on sending device

* make SSID code reusable for receiver

* adapt to otherwise used font style

* show ssid also for receiver

* minor refactorings

* make qr code subtitle translatable

* tune down 'same network hint' on scanning device

* add progress bar to provider

* add progress bar to receiver

* bump version

* use 'Add Second Device' wording

this seems slightly catchier as "Add Another Device"
and has less "A" esp. in "Add as Another Device" :)

also at least translation to german seems nicer ("Zweitgerät"),
most ppl will use max. two devices, but even if more,
that should still be fine.

this was also the first intuition also by other devs in their mockups,
so we'll give it a try.

* use "Exporting/Preparing/Prepared Account" wording

let's give that a try - "Account" is also widely used,
so that seems to make some sense.
even if not 100% fitting,
it seems better than introducing the new term "Collection".

* refine abort question

* Update res/layout/backup_provider_fragment.xml

Co-authored-by: Hocuri <hocuri@gmx.de>

* Update src/org/thoughtcrime/securesms/qr/BackupProviderFragment.java

Co-authored-by: Hocuri <hocuri@gmx.de>

* Update src/org/thoughtcrime/securesms/qr/BackupReceiverFragment.java

Co-authored-by: Hocuri <hocuri@gmx.de>

* Update src/org/thoughtcrime/securesms/qr/BackupTransferActivity.java

Co-authored-by: Hocuri <hocuri@gmx.de>

* Update src/org/thoughtcrime/securesms/qr/BackupReceiverFragment.java

Co-authored-by: Hocuri <hocuri@gmx.de>

* remove string duplicate

* refine 1,2,3

* simplify string ids

* focus on what matters

---------

Co-authored-by: link2xt <link2xt@testrun.org>
Co-authored-by: Hocuri <hocuri@gmx.de>
2023-03-24 15:22:26 +01:00
Asiel Díaz Benítez
1523e7bc07
add app icon to webxdc info messages (#2503)
* add app icon to webxdc info messages

* Update res/layout/conversation_item_update.xml

Co-authored-by: Hocuri <hocuri@gmx.de>

* check if info message type is DcMsg.DC_INFO_WEBXDC_INFO_MESSAGE before loading parent message

---------

Co-authored-by: Hocuri <hocuri@gmx.de>
2023-03-22 15:44:56 +01:00
link2xt
9b3d5df1fd
Add fallback implementations for sendmmsg, recvmmsg and getauxval (#2491)
These functions are not available in related NDK,
so we provide a fallback implementation for them.
2023-03-06 23:04:39 +01:00
link2xt
df58225192 Revert "add epoll_create fallback which is missing in API<21"
This reverts commit e29b6f9974.

Since update to `mio` 0.8.5, it does not require `epoll_create1()`
function to be present on Android anymore.
2023-02-24 12:55:45 +00:00
bjoern
2450bfc4bf
remove meanwhile superfluous data2IsString() (#2418) 2022-11-10 10:39:33 +01:00
bjoern
8a98da3c78
replace deprecated DcAccountsEventEmitter by DcEventEmitter (#2376) 2022-08-29 18:05:34 +02:00
bjoern
4b3382dab5
use dc_contact_was_seen_recently() (#2373)
* add DcContact.wasSeenRecently()

* use DcContact.wasSeenRecently() and remove isSeenRecently()

* remove now again unused imports
2022-08-26 23:13:56 +02:00
B. Petersen
9740607147 add DcChat::getMailinglistAddr 2022-07-26 22:45:29 +02:00