Commit graph

279 commits

Author SHA1 Message Date
Daniel Gultsch 1d62cb0024 pdf renderer might throw security exception on password protected pdf 2020-04-20 15:57:06 +02:00
Daniel Gultsch d64bc1776b show pdf previews in media browser
fixes #3639
2020-02-14 16:02:15 +01:00
Daniel Gultsch a06eb10ed8 fixed rendering of transparent pdfs; white overlay for very dark pdf 2020-02-12 09:09:34 +01:00
Daniel Gultsch fc2b27c3b4 create pdf overlay for pdf thumbs 2020-02-11 19:55:31 +01:00
Daniel Gultsch 2aee26c49a display PDF previews 2020-02-11 17:41:54 +01:00
Daniel Gultsch 843d7fe12d evict cached previews when file gets deleted 2020-01-20 10:54:55 +01:00
Daniel Gultsch ed4a73e1c7 persist file size across aborts
fixes #3601
2019-12-26 19:01:01 +01:00
Daniel Gultsch 8d245fc754 don’t use secure delete when migrating edit column 2019-12-08 11:33:09 +01:00
Daniel Gultsch cc79d8f6b3 properly restore LMC edits. switch to LMC v1.1
fixes #3566

closes #3592
2019-12-04 19:20:24 +01:00
Daniel Gultsch a99d7a7400 increase cursor window size on Android P when restoring messages 2019-12-02 13:20:53 +01:00
Daniel Gultsch ab516299e7 catch all exceptions when closing closable 2019-10-23 22:34:25 +02:00
Daniel Gultsch aef394c9f0 ability to open files from media preview. fixes #3521 2019-09-29 02:00:06 +02:00
Daniel Gultsch 863ac7f2e5 show resource prompt when sending uncompressed video 2019-09-28 23:56:02 +02:00
Daniel Gultsch 9bf5fb98ac show language in message bubble if multiple language variants were received
XML and by inheritence XMPP has the feature of transmitting multiple language
variants for the same content. This can be really useful if, for example, you
are talking to an automated system. A chat bot could greet you in your own
language.

On the wire this will usually look like this:

```xml
<message to="you">
  <body>Good morning</body>
  <body xml:lang="de">Guten Morgen</body>
</message>
```

However receiving such a message in a group chat can be very confusing and
potentially dangerous if the sender puts conflicting information in there and
different people get shown different strings.

Disabeling support for localization entirely isn’t an ideal solution as on
principle it is still a good feature; and other clients might still show a
localization even if Conversations would always show the default language.

So instead Conversations now shows the displayed language in a corner of the
message bubble if more than one translation has been received.

If multiple languages are received Conversations will attempt to find one in
the language the operating system is set to. If no such translation can be
found it will attempt to display the English string.

If English can not be found either (for example a message that only has ru and
fr on a phone that is set to de) it will display what ever language came first.

Furthermore Conversations will discard (not show at all) messages with with
multiple bodies of the same language. (This is considered an invalid message)

The lanuage tag will not be shown if Conversations received a single body in
a language not understood by the user. (For example operating system set to
'de' and message received with one body in 'ru' will just display that body as
usual.)

As a guide line to the user: If you are reading a message where it is important
that this message is not interpreted differently by different people (like a
vote (+1 / -1) in a chat room) make sure it has *no* language tag.
2019-09-12 10:12:51 +02:00
Daniel Gultsch 1c413edf06 bare minimum direct connections 2019-09-01 15:06:59 +02:00
Daniel Gultsch 98c4e9056f use helper method to close socket 2019-07-04 10:12:08 +02:00
Daniel Gultsch 73d66fd703 go forward through cursor in message restore
We have seen some weird CursorIndexNotFoundException that we were unable to reproduce.
We assume that going forward (moveToNext()) through the cursor instead of (moveToPrevious() fixes that issue
2019-04-30 10:45:28 +02:00
Daniel Gultsch b2ea91909b introduced type private_file_message to handle attachments in PMs. fixes #3372 2019-04-27 11:46:43 +02:00
Daniel Gultsch c7dea9dded fixed security exception when attempting to display image in notification 2019-03-03 08:32:54 +01:00
Daniel Gultsch 8fbe445c99 scan all files in case some files were previously marked as deleted by accident 2019-01-24 15:03:58 +01:00
Daniel Gultsch 2e0db4dcda do not show installed accounts in restore view 2019-01-23 12:45:15 +01:00
Daniel Gultsch c9fc40dfe5 WIP backup & restore 2019-01-22 19:25:45 +01:00
Daniel Gultsch e714d7cd29 null checks when deleting old files
fixes #3345
2019-01-17 11:56:34 +01:00
Daniel Gultsch e9bf2b464c explicitly set type=images for all media with an image mime type
this is in preperation to be able to query the database for all images
2019-01-12 09:01:35 +01:00
Daniel Gultsch 7cabb2c377 check if encrypted pgp file get deleted 2019-01-10 21:24:24 +01:00
Daniel Gultsch a644b40c3e don’t check if files exists when loading attachments 2019-01-10 17:43:09 +01:00
Daniel Gultsch 52afcac230 mark deleted files in database and not query them when querying for media 2019-01-10 14:52:27 +01:00
Daniel Gultsch 96e3546904 put images into MessageStyle notifications 2019-01-09 12:47:09 +01:00
Daniel Gultsch 3eaa48fa46 added epub and azw mime types. try to resolve application/octet-stream by file extension instead. added preview icons for ebooks 2018-12-22 13:02:45 +01:00
Daniel Gultsch ae9bfe1643 limit video transcoding to api >= 18 and other api 16 fixes 2018-12-10 13:58:05 +01:00
Daniel Gultsch bcfd3f20c2 postpone prekey removal and republish to after mam 2018-12-05 10:42:56 +01:00
Daniel Gultsch c02676ea4c implement self healing omemo
after receiving a SignalMessage that can’t be decrypted because of broken sessions
Conversations will attempt to grab a new pre key bundle and send a new PreKeySignalMessage
wrapped in a key transport message.
2018-12-02 14:41:29 +01:00
Daniel Gultsch f1e1c4a78d keep track of previously edited ids 2018-12-01 15:52:44 +01:00
Daniel Gultsch 45dba15376 one time migration for existing quicksy account to set magic create flag 2018-11-25 20:47:50 +01:00
Daniel Gultsch 6d67854086 catch cursor window allocation exception 2018-11-13 09:58:28 +01:00
Daniel Gultsch 3e1d01798c refresh synced contacts even if offline 2018-10-31 13:33:55 +01:00
Daniel Gultsch 18752a5c58 write null bitmap to imageview to replace asyncdrawable 2018-10-24 20:00:56 +02:00
Daniel Gultsch 284861de65 Do not attempt to draw overlay on null bitmap 2018-10-07 13:44:20 +02:00
Daniel Gultsch 70845c5e95 do not compress/resize images with strange aspect ratios. fixes #3188 2018-09-22 16:51:00 +02:00
Daniel Gultsch 1985f6bdec store avatars received over muc presence in contact 2018-09-21 12:27:58 +02:00
Daniel Gultsch bd128335d3 do not show media overview in contact/conference details when missing storage permission 2018-09-17 21:24:25 +02:00
Daniel Gultsch 7a0c53aa71 introduce media browser activity 2018-09-15 21:10:17 +02:00
Daniel Gultsch 06972ec95c show conversation media in contact/conference details 2018-09-15 19:38:45 +02:00
Daniel Gultsch 3608b0eb44 WIP: preview media before sending them
Note that this commit breaks a few things in that non video/image do not work and sharing media isn’t currently using the new mechanism either
2018-09-11 09:56:32 +02:00
Daniel Gultsch f533e526fb catch illegalargument exception when discovering extension from url 2018-09-01 16:56:20 +02:00
Daniel Gultsch 8f057a0c95 try to catch out of memory exception 2018-08-18 18:13:51 +02:00
Daniel Gultsch 49d5c1eb52 only look at inner 70% to calculate overlay 2018-07-01 12:06:09 +02:00
Daniel Gultsch 55fcda3cee use dark play/gif button as overlay when image is mostly light 2018-06-30 17:52:34 +02:00
Daniel Gultsch dfb95f0a84 persist muc avatar and show in bookmarks 2018-06-30 13:35:17 +02:00
Daniel Gultsch d7ebd7d453 WIP: set room avatar and slight redesign of group details 2018-06-18 14:15:19 +02:00