Compare commits

...

4686 Commits

Author SHA1 Message Date
Alex Hart
9e7c55847e Bump version to 4.78.3 2020-11-20 16:54:53 -04:00
Alex Hart
5209b74605 Updated language translations. 2020-11-20 16:51:57 -04:00
Cody Henthorne
b90a74d26a Add additional Group Calling features. 2020-11-20 15:42:46 -05:00
Alan Evans
8c1737e597 Increase uncompressed video attachment size to 300 Mb. 2020-11-20 15:15:42 -04:00
Greyson Parrelli
2ea5bd2d44 Convert GV1->GV2 migration flags to booleans. 2020-11-20 13:50:14 -05:00
Greyson Parrelli
4166e7931e Fix membership diffs that occur during a GV1->GV2 migration.
Co-authored-by: Alan Evans <alan@signal.org>
2020-11-20 13:26:17 -05:00
Alan Evans
89f2c25d73 Display video file output size and duration during clipping.
Prevent video upscale, i.e. use input bit rate if lower than our normal target rates.
Do not time limit videos that are under the send file size.
Increase time limit to 10 minutes to match our lowest acceptable bitrate.
2020-11-20 13:27:58 -04:00
Alan Evans
abb1ca2afe Increase in-app recording duration to 60 seconds. 2020-11-20 13:11:48 -04:00
Greyson Parrelli
f7befd1593 Block GV1 creation if forced migrations are enabled. 2020-11-20 11:49:18 -05:00
Greyson Parrelli
28511de23c Ensure we properly detect update messages for migrations. 2020-11-20 11:39:55 -05:00
Greyson Parrelli
2ff3d1b7c5 Update phrasing on donate megaphone dismiss button. 2020-11-19 13:46:35 -05:00
Greyson Parrelli
fe6ae7e142 Don't show donate or research megaphones on new app installs. 2020-11-19 08:42:35 -05:00
Greyson Parrelli
0da6c83ce4 Bump version to 4.78.2 2020-11-18 19:52:48 -05:00
Greyson Parrelli
184b7db43c Updated language translations. 2020-11-18 19:51:15 -05:00
Greyson Parrelli
e442e34c1b More reliably setup initial preferences. 2020-11-18 19:47:27 -05:00
Greyson Parrelli
011efb0ce7 Request READ_PHONE_NUMBERS permission when necessary. 2020-11-18 19:47:27 -05:00
Alex Hart
63d00f87d8 Bump version to 4.78.1 2020-11-18 19:26:12 -04:00
Alex Hart
0323858145 Updated language translations. 2020-11-18 19:22:19 -04:00
Greyson Parrelli
a70e8ec7a7 Update reproducible build instructions. 2020-11-18 19:11:48 -04:00
Alex Hart
b306a3ef41 Update Dockerfile to utilize new commandline tools distributable. 2020-11-18 19:11:48 -04:00
Greyson Parrelli
ccd3467a61 Fix crash with MediaSendActivity progress dialog.
Co-authored-by: Alan Evans <alan@signal.org>
2020-11-18 17:31:43 -05:00
Alex Hart
40338afe7a Bump version to 4.78.0 2020-11-18 16:30:43 -04:00
Alex Hart
ff97f6af56 Updated language translations. 2020-11-18 16:30:43 -04:00
Alan Evans
6e7858e00f Restrict video send duration. 2020-11-18 16:30:43 -04:00
Greyson Parrelli
95468c85a8 Break large read receipt messages into chunks. 2020-11-18 14:19:28 -05:00
Cody Henthorne
f59e10d82c Fix read/unread conversation list colors. 2020-11-18 14:00:14 -05:00
Alex Hart
930370783e Implement ShortcutInfo for API 30. 2020-11-18 14:25:01 -04:00
Alex Hart
75062ada8a Upgrade SDK to 30. 2020-11-18 13:38:27 -04:00
Cody Henthorne
23618923d8 Attempt to recover from reoccurring exceptions when showing notifications. 2020-11-18 12:28:05 -05:00
Greyson Parrelli
f1d3a2f322 Fix Android 11 issue where keyboard wasn't auto-showing for PIN reminders. 2020-11-18 11:57:33 -05:00
Cody Henthorne
3b7fbbaf6e Fix crash when call concluded on non-existent remote peer. 2020-11-18 11:34:06 -05:00
Greyson Parrelli
725d793b20 Fix issue with link preview UI sizing. 2020-11-18 11:33:44 -05:00
Greyson Parrelli
5c3baca055 Add support for a donation megaphone. 2020-11-18 10:33:46 -05:00
Alan Evans
6e5abc92a0 Fix situation where group thread does not yet exist. 2020-11-17 15:52:38 -04:00
Alex Hart
8df6e95781 Stop proximity sensor on pause. 2020-11-17 15:15:13 -04:00
Alex Hart
2290a6c0df Synchronize voice note queue reads and writes. 2020-11-17 14:42:01 -04:00
Jack Lloyd
907e8d93a3 Move to Signal Protocol written in Rust.
Co-authored-by: Alex Hart <alex@signal.org>
2020-11-16 12:28:11 -05:00
Cody Henthorne
918497fb94 Bump version to 4.77.3 2020-11-16 11:49:35 -05:00
Cody Henthorne
3ccd6304c7 Updated language translations. 2020-11-16 11:47:55 -05:00
Greyson Parrelli
51d47adf57 Fix issue where FeatureFlags were triggering listeners for non-changes. 2020-11-16 11:27:58 -05:00
Cody Henthorne
f1e5206f56 Fix Invite Friend theming bug. 2020-11-16 10:17:42 -05:00
Cody Henthorne
f410635e2c Bump version to 4.77.2 2020-11-13 15:01:12 -05:00
Cody Henthorne
302d57bf19 Updated language translations. 2020-11-13 14:54:53 -05:00
Fumiaki Yoshimatsu
4c301a49b4 Fix appearance of small audio view to show correct background color and the progress circle. 2020-11-13 14:39:46 -05:00
Cody Henthorne
4ecfee292e Fix incorrect restarting and theming when system changes night mode. 2020-11-13 14:39:00 -05:00
Alex Hart
2a193ef455 Refactor with WindowUtil and correct some colors. 2020-11-13 14:43:58 -04:00
Cody Henthorne
96e241ef9c Fix RTL constraints for Help screen. 2020-11-13 12:32:55 -05:00
Cody Henthorne
e294a895e8 Bump version to 4.77.1 2020-11-12 12:54:33 -05:00
Cody Henthorne
003b9b1551 Updated language translations. 2020-11-12 12:49:45 -05:00
Alex Hart
a4e4af502e Retheme action modes. 2020-11-12 13:42:07 -04:00
Alex Hart
06aada20c1 Open keyboard when we open contact selection from blocked preference. 2020-11-12 13:39:38 -04:00
Greyson Parrelli
2dace38d43 Add support for GV1->GV2 forced migration. 2020-11-12 12:32:10 -05:00
Greyson Parrelli
554aa1ddf0 Trim message bodies at display time. 2020-11-12 12:18:20 -05:00
Greyson Parrelli
3b2a5f1ce3 Remove old profile sharing UI. 2020-11-12 12:01:43 -05:00
Cody Henthorne
3fc4b098e8 Show correct emojis for recipient names. 2020-11-12 11:22:00 -05:00
Fumiaki Yoshimatsu
a7d672f6b4 Apply locale updates correctly for appcompat-v1.2.0.
Fixes #9736

See https://developer.android.com/jetpack/androidx/releases/appcompat#1.2.0
for how the code is "correctly" applying a new configuration.

Co-authored-by: Cody Henthorne <cody@signal.org>
2020-11-12 09:56:07 -05:00
Greyson Parrelli
7e347f5cce Add support for manual initiation of GV1->GV2 migrations. 2020-11-12 09:52:21 -05:00
Cody Henthorne
4eaa6ebb47 Bump version to 4.77.0 2020-11-11 15:39:00 -05:00
Cody Henthorne
e85ef6881d Updated language translations. 2020-11-11 15:34:15 -05:00
Cody Henthorne
b1f6786392 Add initial support for Group Calling. 2020-11-11 15:29:02 -05:00
Cody Henthorne
696fffb603 Improve mention notifications by only showing alerting notifications once. 2020-11-11 15:29:02 -05:00
Alan Evans
3bb366ee04 Do not send typing indicator when deleting from the end & send stopped typing indicator when compose completely empty. 2020-11-11 15:29:02 -05:00
Alex Hart
6a59974f89 Add group settings UI polish. 2020-11-11 15:29:02 -05:00
Alan Evans
8e39267c42 Center number display vertically for non-signal contacts. 2020-11-11 15:29:02 -05:00
Jim Gustafson
b937534ce5 Update to RingRTC v2.8.0. 2020-11-11 15:29:01 -05:00
Alex Hart
f5b46f7356 Consolidate AnimatedDialog themes to single DayNight theme. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
cd58c09be3 Proper handling of GV1->GV2 migrations in storage service. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
e8f0038c36 Perform bulk receipt processing in a transaction. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
0b77b33902 Add the ability to trace methods in internal builds.
Currently only for internal builds. Use the @Trace annotation to trace
methods for viewing in Perfetto.
2020-11-11 15:29:01 -05:00
Cody Henthorne
c3b5323010 Update assets and themes to leverage DayNight system. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
81eaae4070 Update emoji to Unicode 13.0 2020-11-11 15:29:01 -05:00
Cody Henthorne
65461ce86f Fix incorrect reaction notification copy for various attachment types.
Fixes #10141. Thanks to @Sgn-32 for the initial PR.
2020-11-11 15:29:01 -05:00
Cody Henthorne
536e3139a2 Add foundation for using Android's DayNight theming system. 2020-11-11 15:29:01 -05:00
Alex Hart
e9c7b120a0 Improve contact blocking UX via settings. 2020-11-11 15:29:01 -05:00
Cody Henthorne
d6a230a235 Update AppCompat to 1.2 along with other Android UI libraries. 2020-11-11 15:29:01 -05:00
Alex Hart
6bf300ada8 Do not require write to read from single backup uri. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
d307db8a95 Add the ability to add suggested members after a GV1 migration. 2020-11-11 15:29:01 -05:00
Alex Hart
c4c32d80b2 Update CameraX to 1.0.0-beta11. 2020-11-11 15:29:01 -05:00
Greyson Parrelli
f4c1e34402 Enforce max envelope size in more places. 2020-11-11 15:29:00 -05:00
Alan Evans
0068d62122 Bump version to 4.76.3 2020-11-09 14:39:30 -04:00
Alan Evans
3f1fa59e09 Updated language translations. 2020-11-09 14:38:11 -04:00
Greyson Parrelli
df5114c62c Fix website signing task. 2020-11-09 14:21:56 -04:00
Greyson Parrelli
956e3924ff Log the version in our PersistentLogger. 2020-11-09 12:47:10 -05:00
Greyson Parrelli
20ad166e0f Fix issue where we were double-logging job info. 2020-11-09 12:18:45 -05:00
Greyson Parrelli
12ea88f409 Improve logging around deletions. 2020-11-09 12:18:27 -05:00
Alan Evans
0c5648bfb1 Hide "Read More" when long message is remote deleted. 2020-11-09 10:24:11 -04:00
Greyson Parrelli
91ca19f294 Bump version to 4.76.2 2020-11-05 18:19:51 -05:00
Greyson Parrelli
71250afd2c Updated language translations. 2020-11-05 18:19:22 -05:00
Greyson Parrelli
cfdef7bca7 Only use the NATIONAL format for the US and UK. 2020-11-05 18:14:37 -05:00
Alan Evans
872f935fd5 Revert "Do not set or read quote author phone number."
This reverts commit 936e772ba0.
2020-11-05 18:56:17 -04:00
Alex Hart
0ed1f73990 Fix crash with multitouch in call screen pip. 2020-11-05 17:43:14 -04:00
Cody Henthorne
349a2f72cb Fix crash when handling call messaging failures. 2020-11-05 15:56:56 -05:00
Alex Hart
2b4a4d6109 Add support for Incoming / Outgoing Video Type. 2020-11-05 13:41:22 -04:00
Greyson Parrelli
9f882d2fbb Fix crash around creating MMS groups. 2020-11-05 10:57:31 -05:00
Greyson Parrelli
cb4a9730aa Bump version to 4.76.1 2020-11-04 20:11:55 -05:00
Greyson Parrelli
e0657d09d8 Fix issue where we weren't calling setTransactionSuccessful().
In a chain of events, this manifested by preventing the persistence of
media messages in group threads.
2020-11-04 20:07:57 -05:00
Alan Evans
01b9cb13b4 Bump version to 4.76.0 2020-11-04 16:51:23 -04:00
Alan Evans
2c7260557c Updated language translations. 2020-11-04 16:51:23 -04:00
Greyson Parrelli
9e5156ab73 Pretty-print phone numbers. 2020-11-04 16:51:23 -04:00
Alex Hart
3dc1614fbc Add basic profile spoofing detection. 2020-11-04 16:24:45 -04:00
Alan Evans
2f69a9c38e Share media from within Media Preview and share QR code image. 2020-11-04 16:05:35 -04:00
Greyson Parrelli
5e536c3fa5 Render GV1->GV2 migration event. 2020-11-04 16:05:35 -04:00
Greyson Parrelli
6bb9d27d4e Add the ability to migrate GV1 groups to GV2.
Co-authored-by: Alan Evans <alan@signal.org>
2020-11-04 16:05:35 -04:00
Greyson Parrelli
2d1bf33902 Update group table schema to support GV1->GV2 migration.
Also puts in protections to make sure we don't insert bad recipients or
groups.
2020-11-04 16:05:35 -04:00
Alan Evans
985a220fca Migrate GV1 to GV2 on to server. Allow query of group status. 2020-11-04 16:05:34 -04:00
Alex Hart
31e137cf6d Add support for MISSED_VIDEO_CALL type. 2020-11-04 16:05:34 -04:00
Alex Hart
f796447815 Add better error logging for single backup Uris. 2020-11-04 16:05:34 -04:00
Alan Evans
936e772ba0 Do not set or read quote author phone number. 2020-11-04 16:05:34 -04:00
Greyson Parrelli
ecee797d00 Always consider yourself a member of MMS groups.
Fixes #10162
2020-11-04 16:05:34 -04:00
Greyson Parrelli
357a8fc124 Remove name change for flipper and internal releases. 2020-11-04 16:02:11 -04:00
Alan Evans
1233af0ddd Add environment dimension. 2020-11-04 16:02:11 -04:00
Alex Hart
a264d10685 Fix issue with KitKat picture saves.
Fixes #10153
2020-11-04 16:01:58 -04:00
Alex Hart
ed17701a0a Remove look-behind and ding for single voice notes. 2020-11-02 11:50:37 -04:00
Greyson Parrelli
49e1ccea28 Allow more control over debug and staging signing. 2020-11-02 10:01:59 -05:00
Alan Evans
4c43b0d1e3 Update gradle plugin to 4.1.0, gradle to 6.5. 2020-11-02 10:01:59 -05:00
Greyson Parrelli
5ce09defca Include whether a user has a linked device in the debug log. 2020-11-02 10:01:59 -05:00
Greyson Parrelli
da9064b714 Bump version to 4.75.8 2020-11-02 10:00:23 -05:00
Greyson Parrelli
7bb53e4b06 Updated language translations. 2020-11-02 09:59:52 -05:00
Cody Henthorne
6a4ce1b658 Fix SMS role bug introduced for pre-Q devices. 2020-10-30 17:45:28 -04:00
Greyson Parrelli
f84595e1e8 Bump version to 4.75.7 2020-10-30 16:15:12 -04:00
Greyson Parrelli
41d5c54033 Updated language translations. 2020-10-30 16:14:30 -04:00
Greyson Parrelli
b9d6b63c09 Fix name of internal signing task. 2020-10-30 16:06:57 -04:00
Cody Henthorne
506ad0b3f1 Fix bug handling mentions in sync messages. 2020-10-30 15:13:54 -04:00
Cody Henthorne
c8302174a9 Fix mention suggestions for groups of 1.
Fixes #10152
2020-10-30 13:05:14 -04:00
Cody Henthorne
39cebfbb4e Fix SMS role request for Q+. 2020-10-30 12:34:47 -04:00
Cody Henthorne
d36ec9af47 Fix permission bug with avatar gallery selection. 2020-10-30 11:36:12 -04:00
Greyson Parrelli
5f6d971bf7 Bump version to 4.75.6 2020-10-30 08:24:14 -04:00
Greyson Parrelli
7a722d92a3 Updated language translations. 2020-10-30 08:23:25 -04:00
Greyson Parrelli
0bf0eba450 Fix NPE in BackupUtil. 2020-10-30 08:17:50 -04:00
Greyson Parrelli
d40783f794 Add signing task for internal builds. 2020-10-30 08:17:29 -04:00
Greyson Parrelli
88733473e2 Bump version to 4.75.5 2020-10-29 15:55:17 -04:00
Greyson Parrelli
7b65533095 Updated language translations. 2020-10-29 15:51:04 -04:00
Cody Henthorne
52b533c121 Add internal product flavor. 2020-10-29 15:33:15 -04:00
Greyson Parrelli
a4fa2e14fb Fix versioning issue with Dockerfile. 2020-10-29 15:31:05 -04:00
Cody Henthorne
6933f1d818 Fail call gracefully on turn server network error. 2020-10-29 13:51:30 -04:00
Greyson Parrelli
b5d6cb2a8d Notify about accidentally disabled backups. 2020-10-29 13:32:55 -04:00
Greyson Parrelli
d1478c5ce0 Reduce impact of CDS rate-limiting issues.
This will at least allow users with > RateLimit contacts to perform a successful sync. More work needs to be done here in the future to handle this better.
2020-10-29 10:16:21 -04:00
Greyson Parrelli
fbe62f0f3e Add more Huawei phones to the CameraX blacklist. 2020-10-29 08:04:29 -04:00
Greyson Parrelli
f84705b756 Include additional system properties in debuglog. 2020-10-28 17:01:34 -04:00
Cody Henthorne
cf2189c11a Ensure speakerphone is correctly enabled during call setup.
Race condition between handleStartOutgoingCall being enqueued from ringrtc and
handleSetEnableVideo being enqueued from the main thread.
2020-10-28 17:01:34 -04:00
Alex Hart
dfc4178252 Localize 'camera' folder title. 2020-10-28 17:01:34 -04:00
Greyson Parrelli
07952f2146 Bump version to 4.75.4.
Accidentally went the wrong direction with canonicalVersionCode in
4.75.3. So this release just fixes that and uses the correct
canonicalVersionCode.
2020-10-28 16:54:00 -04:00
Cody Henthorne
a90dad22a9 Bump version to 4.75.3 2020-10-28 16:22:16 -04:00
Cody Henthorne
64f7330609 Updated language translations. 2020-10-28 16:21:12 -04:00
Cody Henthorne
5e382c120b Fix security crash during directory refresh. 2020-10-28 16:14:45 -04:00
Greyson Parrelli
3eea568f5f Fix possible storage permission crash on camera. 2020-10-28 16:00:01 -04:00
Cody Henthorne
0077b29d6e Mitigate PSTN callback crash when service is in background. 2020-10-28 15:48:04 -04:00
Cody Henthorne
dfa6306b61 Bump version to 4.75.2 2020-10-26 16:08:44 -04:00
Cody Henthorne
a4bf075a1a Updated language translations. 2020-10-26 16:06:57 -04:00
Alex Hart
373d622535 Fix SMS, bad MODIFIED timestamp, and API19 beta crash. 2020-10-26 13:41:30 -03:00
Greyson Parrelli
ba1df58eb3 Do not show modern profile sharing on brand new conversations. 2020-10-26 12:08:01 -04:00
Greyson Parrelli
9fb85f7c76 Build log sections in series.
Doing them in parallel was causing possible bad blocked thread reports,
since the thread section could be built at the same time we were
building the jobs section.
2020-10-26 11:07:44 -04:00
Cody Henthorne
5e58f0a212 Bump version to 4.75.1 2020-10-23 15:45:20 -04:00
Cody Henthorne
8fa01f13e9 Updated language translations. 2020-10-23 15:44:07 -04:00
Alan Evans
4ce136be17 Fix missing message request on V2 re-invites. 2020-10-23 15:37:42 -04:00
Alan Evans
4099154dc0 Infer contact multi-select allowing assertion removal.
Hide count on invite friends.

Fixes #10125
2020-10-23 15:37:42 -04:00
Greyson Parrelli
3f983a5c82 Various UI adjustments to conversation updates. 2020-10-23 15:37:42 -04:00
Alex Hart
9743e3689a Add MimeType to MediaStore values. 2020-10-23 14:11:42 -03:00
Greyson Parrelli
1363f55f77 Fix back button behavior on OnePlus phones.
Couple things happened:
- Core issue: The device always thought the keyboard was open, so it was
always trying to dismiss the keyboard when you pressed back (instead of
actually going back)
- Big fix: Increase the tolerance of our view height differentialt that
detects if the keyboard is open
- Other fix: the getViewInset() method is always missing on Q, so as a
temp fix we fall back to the status bar height. Gets the calculation to
be closer, even if not truly correct.
2020-10-23 12:43:34 -04:00
Alex Hart
f1d98f6c7b Fix failed media saves on API < 29.
Fixes #10119
2020-10-23 13:12:07 -03:00
Alex Hart
9279a54d28 Fix bad voice note duration and listener breakage. 2020-10-23 13:00:46 -03:00
Alan Evans
81889d8130 Fix plural. 2020-10-23 11:13:37 -03:00
Cody Henthorne
6aecb8fbc1 Bump version to 4.75.0. 2020-10-22 17:04:24 -04:00
Cody Henthorne
8aa413032d Updated language translations. 2020-10-22 17:02:27 -04:00
Alan Evans
5bc4686eb8 Ignore some more ZKGroup dependent tests on mac. 2020-10-22 16:56:16 -04:00
Greyson Parrelli
f676d1c61c Enforce a configurable max envelope size. 2020-10-22 16:56:16 -04:00
Alex Hart
ac54b5cbdf Add polish to voice note bubbles. 2020-10-22 16:56:16 -04:00
Alan Evans
b4b1e5b605 Add feature flag driven group recommended size and hard size limits. 2020-10-22 16:56:16 -04:00
Greyson Parrelli
5eace49739 Improve PushProcessMessageJob logging. 2020-10-22 16:56:16 -04:00
Alex Hart
e93d7518f3 Add some polish to backups changes. 2020-10-22 16:56:16 -04:00
Greyson Parrelli
9c97cd8816 Improve conversation update message stylings. 2020-10-22 16:56:16 -04:00
Jim Gustafson
90f20c36c5 Update to RingRTC v2.7.3 2020-10-22 16:56:16 -04:00
Greyson Parrelli
9f8dd7992a Remove remote delete option for group updates. 2020-10-22 16:56:16 -04:00
Alex Hart
f4d3fe9176 Implement better backup failure notification strategy. 2020-10-22 16:56:16 -04:00
Alan Evans
ffc7c13717 Group GET 404 and PUT 409 handling. 2020-10-22 16:56:16 -04:00
Greyson Parrelli
daf93c473b Reduce verbosity of KeyboardAwareLinearLayout logs. 2020-10-22 16:56:16 -04:00
Greyson Parrelli
d21782696a Read the new GV1 Migration capability. 2020-10-22 15:55:18 -03:00
Greyson Parrelli
3357475fc4 Move capabilities into a single column. 2020-10-22 15:55:18 -03:00
Greyson Parrelli
ead64d92a5 Rename Recipient.isLocalNumber() to Recipient.isSelf() 2020-10-22 15:55:18 -03:00
Cody Henthorne
5eaac6cb17 Call handling state machine refactor. 2020-10-22 15:55:18 -03:00
Alex Hart
b3f0a44f10 Bump version to 4.74.3 2020-10-21 11:11:43 -03:00
Alex Hart
e4d0e2f730 Updated language translations. 2020-10-21 11:11:43 -03:00
Cody Henthorne
492a42883e Change Surveygizmo to Alchemer due to name change. 2020-10-21 11:11:43 -03:00
Alex Hart
b182f73415 Fix wakelock release exception. 2020-10-21 11:11:42 -03:00
Alan Evans
e766b9737e Do not enable admin approval on group links by default. 2020-10-20 19:39:51 -03:00
Alan Evans
2335f93579 Staging CDS enclave change. 2020-10-20 19:20:01 -03:00
Greyson Parrelli
1730260343 Bump version to 4.74.2 2020-10-19 17:34:08 -04:00
Greyson Parrelli
27506e9ed8 Updated language translations. 2020-10-19 17:33:25 -04:00
Alex Hart
dc64a186d5 Fix mediastore access for Android Q. 2020-10-19 18:16:29 -03:00
Alex Hart
3163e09b98 Fix issue with backup deletion. 2020-10-19 10:27:18 -03:00
Alex Hart
dcb9978bb1 Bump version to 4.74.1 2020-10-16 16:40:15 -03:00
Alex Hart
4a94a0a5c5 Updated language translations. 2020-10-16 16:36:47 -03:00
Alex Hart
8a2d20403e Add Proximity sensing back to voice note. 2020-10-16 16:23:04 -03:00
Alex Hart
ec706e95cc Backup style and copy tweak. 2020-10-16 16:17:34 -03:00
Alex Hart
bd3b14a27f Fix seeking voice notes that do not have waveforms. 2020-10-16 15:37:26 -03:00
Alex Hart
082d9e852c Voice Note Beta Feedback fixes. 2020-10-16 13:14:01 -03:00
Alex Hart
36da519b26 Bump version to 4.74.0 2020-10-15 17:43:35 -03:00
Alex Hart
06ffdde892 Updated language translations. 2020-10-15 17:42:28 -03:00
Greyson Parrelli
1ec57c080c Update targetSdk to 29. 2020-10-15 16:19:17 -04:00
Alan Evans
a635f27c68 Hide group link when not enabled. 2020-10-15 16:19:17 -04:00
Alex Hart
ee3d7a9a35 Implement new workflow for scoped storage backup selection. 2020-10-15 16:19:17 -04:00
Alex Hart
9a1c869efe Allow consecutive voice notes to be played as a playlist. 2020-10-15 16:19:17 -04:00
Alan Evans
837ed76f85 Show reminder banner to administrators for pending group join requests. 2020-10-15 16:19:17 -04:00
Cody Henthorne
b46589cd14 Remove mentions feature flag. 2020-10-15 16:19:17 -04:00
Alan Evans
d04e4606d2 Remove GV2 create flag. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
385bd0eb8a Fix possible crash for unregistered devices. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
089656e5c4 Add an application migration to do a CDS refresh. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
84ec6dd458 Improve network reliability during resumable uploads. 2020-10-15 16:19:17 -04:00
Cody Henthorne
322c139c26 Fix bug of video showing on next call after cancel pre-join.
Fixes #10083
2020-10-15 16:19:17 -04:00
Alan Evans
babe1833bb Derive GV2 master key and group id from GV1. 2020-10-15 16:19:17 -04:00
Alex Hart
9effa47dd8 Allow voice notes to continue playback after leaving conversation. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
7ef57cc0cf Add support for syncing pinned status with storage service. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
97420aae1b Add a Github Action to test our docker build every day.
Runs at 5am UTC, which is ~midnight EST.
2020-10-15 16:19:17 -04:00
Greyson Parrelli
415e6309f9 Ensure CI runs on 5.x branches. 2020-10-15 16:19:17 -04:00
Greyson Parrelli
83e63ff854 Improve the reproducible build process.
* Moved stuff into it's own `reproducible-builds` directory.
* Improved reproducible build by using a debian snapshot and more clearly listing dependencies.
* Removed signing from assembleReelase.
* Updated README.
2020-10-15 16:19:17 -04:00
Greyson Parrelli
de7f103130 Add support for modern profile sharing. 2020-10-15 16:19:12 -04:00
Alan Evans
2cb912681d Bump version to 4.73.4 2020-10-13 15:18:00 -03:00
Alan Evans
04bdf94b78 Updated language translations. 2020-10-13 15:18:00 -03:00
Cody Henthorne
c7389ddaa7 Fix bug causing incorrect mention suggestions. 2020-10-13 15:18:00 -03:00
Greyson Parrelli
e778ab2e3a Fix issue with remote delete sent transcripts. 2020-10-13 13:50:21 -04:00
Alan Evans
533d86607f Bump version to 4.73.3 2020-10-12 15:24:34 -03:00
Alan Evans
cb2096670f Updated language translations. 2020-10-12 15:19:00 -03:00
Alan Evans
284f221a9d Handle no actual change to group. 2020-10-12 15:11:57 -03:00
Greyson Parrelli
bc639dd438 Show error message when unable to compute safety number. 2020-10-12 12:14:13 -04:00
Greyson Parrelli
1baddbb40e Fix some oddities with message request behavior.
There was a weird case where how our intent checking could behave
differently when coming from search. There's also some funny
interactions where backups, where because the 'time message requests was
enabled' is reset to System.currentTimeMillis() post-restore, we thought
there were always 'pre-message-request messages'. Only mattered when
profileSharing is also disabled, so impact isn't huge. Given a lot of
this UI is going away soon, rather than doing the complicated thing of
backing up the true timestamp, I just default it to 0 to mitigate
things.
2020-10-12 10:09:35 -04:00
Alan Evans
f784dab868 Bump version to 4.73.2 2020-10-09 17:46:21 -03:00
Alan Evans
85192aaa21 Updated language translations. 2020-10-09 17:46:21 -03:00
Alan Evans
054c705fe2 Respect the 206 paged response from the server group logs endpoint.
Prevent the deduplicate message logic firing and log it if it does.
2020-10-09 17:46:21 -03:00
Alan Evans
07b0d8cf6e Utilities for correctly handling json parsing errors on network responses. 2020-10-09 17:11:19 -03:00
Greyson Parrelli
597d16f566 Ensure one row per recipient in getRecipientSettingsForSync().
Technically there's no unique constraint in ThreadDatabase to guarantee
only one thread per recipient. We saw a crash that indicated that one
user has two threads for the same recipient. That's not true for any of
my devices. Still, best to play it safe here while we try to figure out
why this is happening.
2020-10-09 12:16:38 -04:00
Greyson Parrelli
0ca2c781c3 Only show the delivery status icon for 'sending' on remote deletes. 2020-10-08 16:29:13 -04:00
Greyson Parrelli
f642de9c41 Disable mention clicks in multi-select mode. 2020-10-08 14:09:44 -04:00
Greyson Parrelli
8965388d05 Fix rendering of remote-deleted view-once messages. 2020-10-08 14:04:00 -04:00
Alan Evans
58c4582f15 Bump version to 4.73.1 2020-10-08 12:53:17 -03:00
Alan Evans
44bc1b5cc0 Updated language translations. 2020-10-08 12:51:08 -03:00
Greyson Parrelli
714ebb3e08 Allow remote deletes of pending messages. 2020-10-08 10:58:55 -04:00
Greyson Parrelli
8f871c2e3a Don't allow quote-jumps to remote deleted messages. 2020-10-08 10:29:46 -04:00
Greyson Parrelli
5cdc5bc441 Ensure reactions are deleted for remote-deleted messages.
We were doing this for MmsDatabase, but not SmsDatabase. Includes a
migration to cleanup any existing bad state.
2020-10-08 10:21:57 -04:00
Cody Henthorne
8d060837ad Cleanup abandoned mentions during backup restore. 2020-10-08 09:46:26 -04:00
Greyson Parrelli
1d230d4cd6 Schedule another attribute refresh for GV2. 2020-10-07 20:29:40 -04:00
Greyson Parrelli
3636ae7667 Add the Pixel 4 back to the CameraX blacklist.
It's having pretty bad exposure problems.
2020-10-07 19:54:24 -04:00
Greyson Parrelli
9ffb5112c6 Bump version to 4.73.0 2020-10-07 17:22:05 -04:00
Greyson Parrelli
ca5d574cd7 Updated language translations. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
c80283dbcc Inline remote delete feature flag. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
3fcaddf2d3 Update delete for everyone education text. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
6ecff5bce9 Ensure the storage manifest has all inserts and deletes.
A user hit a fishy case where not all inserts were present in the full
keyset. It's unclear how that would happen, so I'm being even more
explicit here.
2020-10-07 17:22:05 -04:00
Greyson Parrelli
a103c7dcb6 Apply storage service values for phone number privacy. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
63746bbb47 Add support for syncing forced unread status. 2020-10-07 17:22:05 -04:00
Alan Evans
ed0be6fc9a Add dialog transitions to group manager. 2020-10-07 17:22:05 -04:00
Alan Evans
26404ff5d7 More descriptive copy for group link permission errors. 2020-10-07 17:22:05 -04:00
Alan Evans
adf1674877 Support sgnl://signal.group links. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
ab2235fc88 Prefer remote value for profile sharing for groups during storage sync. 2020-10-07 17:22:05 -04:00
Cody Henthorne
441a6d3fe7 Fix start call resizing improperly with wrapping text. 2020-10-07 17:22:05 -04:00
Greyson Parrelli
e00397620a Simplify storing storage-service-specific recipient values.
This gives us the ability to separate things we need for the Recipient
class from things we only need for storage syncing.

Not only does this simplify the storage service model building code
(i.e. we no longer need to pass around a set of archived recipients),
but it also eliminates a join on the Identity table for building regular
recipients, which should help perf.
2020-10-07 17:22:05 -04:00
Alan Evans
38fa58c0a3 Write previous group state to the database for advanced change messages. 2020-10-06 11:21:56 -03:00
Alan Evans
b40fd7b243 Fix Audio slides reporting images.
Fixes #10063
2020-10-06 11:09:50 -03:00
Alan Evans
ae34877496 Use Emoji respecting textview in group member lists. 2020-10-06 10:36:48 -03:00
Greyson Parrelli
599cf1e5cb Ensure we refresh recipients after changing storage keys. 2020-10-06 10:32:03 -03:00
Greyson Parrelli
474963dcf1 Add the ability to migrate to new KBS enclaves. 2020-10-06 10:32:03 -03:00
Alan Evans
e22384b6b4 New copy for GV2 direct add message request. 2020-10-05 14:54:18 -03:00
Cody Henthorne
fb00652396 Fix incorrect UI for inactive groups. 2020-10-05 12:59:00 -04:00
Alan Evans
a5dbb5d91f Block unknown group messages from blocked senders. 2020-10-05 12:30:29 -03:00
Alan Evans
e75a03b6f8 Bump version to 4.72.6 2020-10-02 12:25:40 -03:00
Alan Evans
eb7fe7f3e0 Updated language translations. 2020-10-02 12:25:40 -03:00
Cody Henthorne
3179808f17 Cleanup mentions with bad thread ids or ranges, or duplicates. 2020-10-02 12:25:40 -03:00
Alan Evans
fde9f05bd0 Use GV2 change descriptions for invite events. 2020-10-02 10:40:57 -03:00
Alan Evans
8de4290c5b Fix can create backups when timed backup is waiting for charging constraint. 2020-10-02 10:32:04 -03:00
Alan Evans
19c74c8872 Fix English use of quantity zero string. 2020-10-02 10:31:11 -03:00
Alan Evans
50edb5d1f4 Bump version to 4.72.5 2020-09-30 17:38:38 -03:00
Cody Henthorne
c6ccfd7e75 Fix API19 crash when inflating new WebRTC UI. 2020-09-30 17:38:15 -03:00
Alan Evans
3796ce69e4 Clear auth cache on first verification failure. 2020-09-30 17:28:42 -03:00
Cody Henthorne
9835e31b46 Attempt to cleanup invalid mentions. 2020-09-30 15:56:23 -04:00
Alan Evans
a35040c909 Bump version to 4.72.4 2020-09-30 16:05:27 -03:00
Alan Evans
a4c94638ca Updated language translations. 2020-09-30 15:59:29 -03:00
Cody Henthorne
e70a8ae6a0 Drop messages with mentions not sent to V2 Groups. 2020-09-30 14:52:18 -04:00
Alan Evans
100359e38d Allow in notification reply to multi message if you can reply to latest. 2020-09-30 15:42:07 -03:00
Cody Henthorne
cd995aca56 Fix incorrect mention association when messages are deleted. 2020-09-30 14:35:02 -04:00
Alan Evans
3a4bae88ca Add network spinner to add members. 2020-09-30 13:59:39 -03:00
Cody Henthorne
e60eae27fb Tweak font sizes and PIP boundaries in call view. 2020-09-30 11:51:48 -04:00
Alan Evans
cd6c01e230 Fix spinner not disappearing when adding members with no network. 2020-09-30 12:25:35 -03:00
Alan Evans
0af264429f During GV2 storage sync, recover from recipient present but group not present. 2020-09-30 10:11:51 -03:00
Alan Evans
a6d3862350 Ignore bad messages from blocked senders. 2020-09-30 10:08:21 -03:00
Alan Evans
3fca4850dd Fix xml inflation crash. 2020-09-29 16:40:37 -03:00
Alan Evans
ba7e41d9a6 Fix missing Submit Debug Log loading progress spinner. 2020-09-29 15:23:31 -03:00
Alan Evans
fe33ce3413 Various groups V2 dialog copy changes. 2020-09-29 12:03:32 -03:00
Alan Evans
4e25e8aaa2 Ensure clock adjustments does not stop remote config refresh. 2020-09-29 11:10:25 -03:00
Alan Evans
91be826c7d Bump version to 4.72.3 2020-09-28 16:35:44 -03:00
Alan Evans
fdfe0cddb8 Updated language translations. 2020-09-28 16:32:18 -03:00
Alan Evans
e8ef62116f Write gv2-3 capability. 2020-09-28 14:15:19 -03:00
Alan Evans
caf8bb39d8 Fix desktop sync with body-less messages. 2020-09-28 11:53:27 -03:00
Alan Evans
222ba6ee53 Hide admin options on bottom sheet for members not currently in group. 2020-09-28 10:15:29 -03:00
Alan Evans
8dcda73072 Fix media preview crash. 2020-09-28 09:45:06 -03:00
Alan Evans
810365d334 Bump version to 4.72.2 2020-09-25 15:29:36 -03:00
Alan Evans
4b31510589 Updated language translations. 2020-09-25 15:24:47 -03:00
Alan Evans
dfce9a34b8 Fix leave group crash. 2020-09-25 15:18:34 -03:00
Alex Hart
dc9370c32b Fix false group name and avatar updates. 2020-09-25 15:18:34 -03:00
Cody Henthorne
8dbc721c08 Fix stale call preview state by finishing when leaving. 2020-09-25 15:18:34 -03:00
Cody Henthorne
6448b84430 Fix various mention issues.
Fixes #9960
2020-09-25 15:18:34 -03:00
Alan Evans
93d6ce40c3 GV2 learn more copy update. 2020-09-25 15:18:34 -03:00
Alan Evans
ce5be2c1be Share group link via signal to one recipient. 2020-09-25 12:33:14 -03:00
Alan Evans
20fe837022 Enable and disable group link options with first switch. 2020-09-25 12:32:48 -03:00
Greyson Parrelli
e3ce18fa3e Fix possible threading issues with attachment cleanup.
The way things were ordered, it was possible for us to create an
attachment file, but have it 'cleaned up' before we were able to link it
to an attachment row.
2020-09-24 16:51:20 -04:00
Greyson Parrelli
864a1d5e93 Prefer remote value for profile sharing during storage sync. 2020-09-24 12:41:31 -04:00
Greyson Parrelli
9cf7eec247 Log sent timestamps when hitting message processing errors. 2020-09-24 12:26:18 -04:00
Greyson Parrelli
d9c15621f6 Log more details around conversation fetch times. 2020-09-24 12:26:02 -04:00
Greyson Parrelli
fea14218a9 Don't allow borderless images to have quotes attached.
Fixes #9924
2020-09-24 12:11:40 -04:00
Greyson Parrelli
dbbded5250 Bump version to 4.72.1 2020-09-24 10:54:07 -04:00
Greyson Parrelli
d65cfc7981 Updated language translations. 2020-09-24 10:53:44 -04:00
Greyson Parrelli
dc9124f291 Fix crash in RetrieveProfileJob. 2020-09-24 10:46:56 -04:00
Cody Henthorne
4cd433b6bc Retain call start timestamp per peer to prevent race conditions. 2020-09-24 10:43:39 -04:00
Greyson Parrelli
f9a9ee6b0c Bump version to 4.72.0 2020-09-23 16:54:38 -04:00
Greyson Parrelli
1741f7ed58 Updated language translations. 2020-09-23 16:54:38 -04:00
Alan Evans
d459c751be Show linked device update message if we don't have the capability to join a group by link. 2020-09-23 16:54:38 -04:00
Alan Evans
34ef8b52f6 Display a loading message if group update message is taking a while to load. 2020-09-23 16:54:38 -04:00
Alan Evans
5ae96905bb Do not allow replying on reactions and messages without visible content. 2020-09-23 16:54:38 -04:00
Alan Evans
b1fdbc0151 Refresh own GV2 capability on group create. 2020-09-23 16:54:38 -04:00
Alan Evans
a5ad27b5f2 Hide "My contacts" phone number privacy option. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
efcd5052a2 Remove Pixel 4 from the CameraX blacklist on Android 11. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
f2b10c0ba8 Always include ourselves in optimistic profile fetches. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
f182be2d79 Inline CDS feature flag. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
41b10630bb Default to WEBP for sticker contentTypes. 2020-09-23 16:54:38 -04:00
Alan Evans
45915bed90 Inline GV2 feature flag. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
a2c2ab428a Fallback to profile fetches for unlisted contacts. 2020-09-23 16:54:38 -04:00
Alan Evans
a05f74d302 Do not set color before profile name is known. 2020-09-23 16:54:38 -04:00
Alan Evans
74e94f3a97 Separate capability reads from writes and introduce gv2-2 write flag. 2020-09-23 16:54:38 -04:00
Christian Ascheberg
15ee8c6cac Fix timestamp of missed call record.
Fixes #7647
2020-09-23 16:54:38 -04:00
Alex Hart
18957b1f41 Remove members menu item for group message requests. 2020-09-23 16:54:38 -04:00
Cody Henthorne
29930cac41 Use mention-updated body for unread reaction notification text. 2020-09-23 16:54:38 -04:00
Cody Henthorne
e3338dc3ff Add MMS info to conversation settings. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
97b7b4a501 Fix crash when receiving SMS before finishing registration.
If someone has set Signal as the default SMS but has cleared data or
otherwise reset the app's storage state, it can get into a weird
situation. Notably, it'll crash because SmsReceiveJob.onRun() expects
Recipient.self() to be available.

However, it also makes it impossible to get the registration SMS,
because the app won't post a notification for the code.

This change will post notifications and SmsRetriever broadcasts for
relevant SMS messages.
2020-09-23 16:54:38 -04:00
Greyson Parrelli
b471a72856 Don't show the link preview megaphone to new users. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
fed7d911a3 Revert "Listen to the uiMode configuration changes."
This reverts commit dda98a474d.

This commit ended up causing spontaneous theme changes that have been
hard to track down. It's likely it just didn't fit into our theme system
well. We need to take a closer look, but in the meantime, a revert is in
order.
2020-09-23 16:54:38 -04:00
Cody Henthorne
ca442970a3 Add Research Megaphone. 2020-09-23 16:54:38 -04:00
Angus Turnbull
9dbb77c10a Remove some calls to GMS APIs for utility functions.
Fixes #9629
2020-09-23 16:54:38 -04:00
Dan
1116502bc0 Add vCard support for received MMS. 2020-09-23 16:54:38 -04:00
Cody Henthorne
edaf17bdd4 Fix invisible media controls and notch jank.
Fixes #9993.
2020-09-23 16:54:38 -04:00
Alan Evans
c61d731358 Allow side-by-side installation of staging build. 2020-09-23 16:54:38 -04:00
Cody Henthorne
a8415a3484 Add pre-join vanity view for 1:1 video calls. 2020-09-23 16:54:38 -04:00
Alan Evans
cd2467085e Correct storage query deleted filter argument. 2020-09-23 16:54:38 -04:00
Alan Evans
64efb3d2a4 Do not set or read reaction target phone number. 2020-09-23 16:54:38 -04:00
Alex Hart
e05f137bd8 Add animations to call screen. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
0c73ddc08b Ensure we HTML-decode the <title> tag.
Fixes #10020
2020-09-23 16:54:38 -04:00
Greyson Parrelli
19cc43c442 Add a charging constraint to the backup job. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
7108fc81a9 Prevent redundant JobScheduler jobs.
Some devices actually enforce a scheduling rate, and will crash if you
submit more than, say, 250 jobs in 1 minute. This can happen when
catching up with messages and scheduling a lot of
PushDecryptMessageJobs.

While it'd be tricky to limit jobs with constraints, this just does the
simple thing of not enqueueing unnecessary jobs for constraint-less
jobs.
2020-09-23 16:54:38 -04:00
Alex Hart
5943b9d7d6 Fix sending receipts.
Fixes #10016
2020-09-23 16:54:38 -04:00
Alex Hart
0271e4c918 Add lifecycle check in SnackbarAsyncTask. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
9dc33eff3a Remove thumbnails from the AttachmentDatabase.
Glide can do everything for us now, including video thumbnails.
2020-09-23 16:54:38 -04:00
Jim Gustafson
5aef1c8a68 Update to RingRTC v2.7.0 2020-09-23 16:54:38 -04:00
Alan Evans
c608a05270 Prevent a resolve call in main. 2020-09-23 16:54:38 -04:00
Cody Henthorne
e2cfd247c3 Fix mention parsing for quotes. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
97eb9154b2 Prevent NPE when setting sticker emoji. 2020-09-23 16:54:38 -04:00
Jim Gustafson
d7ff635445 RingRTC: Update to v2.6.0
Co-authored-by: Peter Thatcher <peter@signal.org>
2020-09-23 16:54:38 -04:00
Alan Evans
aff57fb54e Create the temporary backup file hidden in the final location.
Fixes #10003
2020-09-23 16:54:38 -04:00
Greyson Parrelli
e89285a219 Reduce log noise. 2020-09-23 16:54:38 -04:00
Greyson Parrelli
706f43caa8 Remove AttachmentsV3 feature flag. 2020-09-23 16:54:38 -04:00
Cody Henthorne
dc4faf57cb Add foundational UX and state support for Group Calling. 2020-09-23 16:54:38 -04:00
Alex Hart
7baf8052a2 Fix savedInstanceState crash. 2020-09-23 16:54:37 -04:00
Alan Evans
d3c59585fd Bump version to 4.71.5 2020-09-14 11:16:09 -03:00
Alan Evans
859bb8dc79 Updated language translations. 2020-09-14 11:12:30 -03:00
Alan Evans
58cd2e07ba Add some required face blurring models back.
Fixes #10009
2020-09-14 10:49:33 -03:00
Greyson Parrelli
a5a6fb590a Bump version to 4.71.4 2020-09-10 18:03:51 -04:00
Greyson Parrelli
3619993e68 Updated language translations. 2020-09-10 18:03:28 -04:00
Greyson Parrelli
88e12c78fa Disable mentions megaphone. 2020-09-10 17:54:57 -04:00
Alan Evans
5c285b4ac6 Cycle groups v2 feature flag. 2020-09-10 18:47:36 -03:00
Cody Henthorne
c6b729c470 Bump version to 4.71.3 2020-09-10 15:38:55 -04:00
Cody Henthorne
890014759e Updated language translations. 2020-09-10 15:38:12 -04:00
Cody Henthorne
68c1c43381 Update radio styling in storage settings. 2020-09-10 14:40:29 -04:00
Greyson Parrelli
d0dfcaaad5 Fix issue with storage key intersections.
- When doing the intersection, ignore keys that have type mismatches (same storageId, different types)
- If we detect that scenario, schedule a force push to happen afterwards
- Also schedule a force push afterwards if we detect that there's keys in the manifest that don't have any storage item on the service
2020-09-10 14:01:41 -04:00
Alan Evans
3cffaddc0a Validate incoming Group lengths and remote delete entries if wrong.
Ignore incoming messages with bad V1 group lengths.
2020-09-10 14:39:29 -03:00
Alex Hart
bf4cac0c82 Fix unarchive menu action. 2020-09-10 13:49:16 -03:00
Alex Hart
f680749a00 Use proper lifecycle for SimpleTask which touches fragment view. 2020-09-10 13:40:09 -03:00
Cody Henthorne
13a67980d9 Fix wrong timestamp being used when trimming by length. 2020-09-10 12:09:28 -04:00
Alan Evans
f110d595d2 Fix selection limit for add members GV1.
Fixes #10005
2020-09-10 09:59:57 -03:00
Cody Henthorne
9c8857352b Bump version to 4.71.2 2020-09-09 16:09:49 -04:00
Cody Henthorne
c09a1fdba8 Updated language translations. 2020-09-09 16:04:27 -04:00
Greyson Parrelli
cdc7033a51 Update CDS enclave. 2020-09-09 15:38:42 -04:00
Alex Hart
fa30c759d7 Fix PIP positioning in video calls. 2020-09-09 13:06:38 -03:00
Fumiaki Yoshimatsu
d040be2df0 Use the light styles in the action bar style in the light theme, but keep the dark theme version of it in the action mode.
Fixes #9932
2020-09-09 12:24:45 -03:00
Alan Evans
935c831a7f Fix equality comparison causing blank updates and "The group was updated" messages. 2020-09-09 12:16:09 -03:00
Cody Henthorne
867e95eef1 Re-download sticker if backing file data no longer exists. 2020-09-09 11:15:34 -04:00
Alan Evans
2ee04bd1b6 Insert placeholder group on GV2 storage service sync. 2020-09-09 11:59:09 -03:00
Greyson Parrelli
75d567e555 Implement new client deprecation UI. 2020-09-09 10:22:22 -04:00
Alex Hart
d8a489971c Fix missing reply arrows. 2020-09-09 10:42:14 -03:00
Greyson Parrelli
19ce5b5c76 Reduce APNGParser logging. 2020-09-08 18:08:40 -04:00
Greyson Parrelli
7c70ea4d3e Change directory refresh interval to every 24 hours. 2020-09-08 18:06:09 -04:00
Greyson Parrelli
2784285d47 Add support for fetching remote deprecation. 2020-09-08 18:03:56 -04:00
Cody Henthorne
c946a7a1d5 Bump version to 4.71.1 2020-09-08 14:30:22 -04:00
Greyson Parrelli
3e60b49b8b Updated language translations. 2020-09-08 14:25:34 -04:00
Cody Henthorne
4e7331bbb8 Fix typo in trim message history copy. 2020-09-08 14:15:10 -04:00
Cody Henthorne
b8c7e86223 Fix improper deletion of stickers when restored from backup. 2020-09-08 14:07:56 -04:00
Alex Hart
3b925f8674 Add in-app donate button to preferences screen. 2020-09-08 12:48:52 -03:00
Cody Henthorne
f1f6d41c73 Bumped version to 4.71.0 2020-09-08 09:47:58 -04:00
Alan Evans
29ef1cb1be Updated language translations. 2020-09-08 09:47:58 -04:00
Alan Evans
4296085d65 Show no notification actions when the message content is hidden.
Fixes #9928
2020-09-08 09:47:57 -04:00
Alan Evans
c797b09228 Set profile sharing based on who added you to the group. 2020-09-08 09:47:57 -04:00
Greyson Parrelli
a870ef0030 Set isRecipientUpdate based on delivery status, not address count.
We were setting isRecipientUpdate to `true` incorrectly if there were
unregistered people in the group, resulting in the message not being
rendered on linked devices. Instead of using the address count, we can
just look at the current receipt status of the message.

Fixes #9981
2020-09-08 09:47:57 -04:00
Alan Evans
43ed9e7310 Set discoverable account attribute. 2020-09-08 09:47:57 -04:00
Cody Henthorne
bcd27355f9 Add trim conversations by time option. 2020-09-08 09:47:57 -04:00
Alan Evans
6a14dc69c0 Make Group V2 creation driven by version flag. 2020-09-03 20:23:26 -04:00
Jim Gustafson
ed9acd25f9 Ensure serial handling of calling events and improve busy UX. 2020-09-03 20:23:26 -04:00
Alan Evans
7b24e66ed3 Phone number privacy settings and certificate support behind feature flag. 2020-09-03 20:23:26 -04:00
Alan Evans
abd3d4b546 Group link copy changes. 2020-09-03 20:23:26 -04:00
Alan Evans
4040c4240a Lighter weight mentions membership query. 2020-09-03 20:23:26 -04:00
Alan Evans
1ee747f3ef Always share profile as part of unblocking. 2020-09-03 20:23:26 -04:00
Alan Evans
f88874bec8 Default values for member level and admin when no UUID. 2020-09-03 20:23:26 -04:00
Greyson Parrelli
ed440a2150 Do not clear UUID for unregistered users.
Otherwise, a number could be unregistered and re-registered by a
different person, assigning a new UUID to an existing RecipientId,
which we never want to do.
2020-09-03 20:23:26 -04:00
Greyson Parrelli
2fd46b196b Show sticker emoji in notification. 2020-09-03 20:23:26 -04:00
Greyson Parrelli
12dfcaf7e7 Log sent timestamp with message sends. 2020-09-03 20:23:26 -04:00
Greyson Parrelli
f4a199f621 Add support for animated stickers. 2020-09-03 20:23:26 -04:00
Alan Evans
bb708e0aa3 Ignore link preview descriptions that match the title. 2020-09-03 20:23:26 -04:00
Alan Evans
d625740ca4 Ensure feature flag is string before cast. 2020-09-03 20:23:26 -04:00
Greyson Parrelli
250402e9b9 Add support for rendering APNGs. 2020-09-03 20:23:26 -04:00
Jim Gustafson
1d2ffe56fb Update to RingRTC v2.5.1 2020-09-01 15:43:07 -04:00
Alan Evans
d16c0d2887 Prevent autofill for username editor. 2020-09-01 15:43:07 -04:00
Cody Henthorne
b3555f2f94 Use updated Safety Number Change dialog for calls.
Fixes [#9940](https://github.com/signalapp/Signal-Android/issues/9940)
2020-09-01 15:43:07 -04:00
Greyson Parrelli
83a638fc6d Bump version to 4.70.5 2020-09-01 14:56:32 -04:00
Greyson Parrelli
f1534a710f Updated language translations. 2020-09-01 14:56:08 -04:00
Greyson Parrelli
a16845340b Update CDS enclave. 2020-09-01 14:56:08 -04:00
Alan Evans
ffa4725f8e Bump version to 4.70.4 2020-08-31 12:54:22 -03:00
Alan Evans
7792c66c64 Updated language translations. 2020-08-31 12:50:08 -03:00
Alan Evans
1a3985d709 Add QR group link share. 2020-08-31 12:35:38 -03:00
Greyson Parrelli
4714895c59 Do not attempt to send to unregistered users when using CDS flag.
CDS is slow, and unregistered users will always trigger a CDS lookup on
send (since we can't get their UUID).

This starts skipping sends to unregistered users and shortens the time
window to do a full CDS lookup from every 12 hours to every 6 hours.
2020-08-31 11:33:57 -04:00
Fumiaki Yoshimatsu
1e37951701 Use onCreateOptionsMenu when to inflate a menu in order for menu items to appear correctly in RTL languages.
The bug was reported in
https://community.signalusers.org/t/beta-feedback-for-the-upcoming-android-4-70-release/16449/20?u=alan-signal, but it was not necessarily a regression caused by the commit suggested in the forum post. It is more like that the bug was finally exposed by the commit. Before the commit the menu items were not properly aligned nor translated upon configuration changes in RTL languages.
2020-08-31 12:12:15 -03:00
Alan Evans
e8be1ad752 Handle GV2 sync messages. 2020-08-31 12:07:03 -03:00
Alan Evans
e316a70b6c Fix group limit enforcement and display. 2020-08-31 12:02:50 -03:00
Alan Evans
40a8d21c15 Fix to allow send of Signal invitation SMS to a single person.
Fixes #9970
2020-08-31 11:33:50 -03:00
Alan Evans
28d5ca7ed9 Bump version to 4.70.3 2020-08-28 10:49:31 -03:00
Alan Evans
110b18545f Updated language translations. 2020-08-28 10:44:03 -03:00
Alan Evans
a478605da4 Remove requesting members if they are directly added to the group. 2020-08-28 10:32:20 -03:00
Alan Evans
f5f1589813 Fix class cast exception when member is approved. 2020-08-28 10:32:20 -03:00
Greyson Parrelli
0c332b6adb Fix corner cases with LinkPreviewViewModel enabled state. 2020-08-28 09:30:03 -04:00
Greyson Parrelli
ba712ce357 Fix crash with link preview date formatting on Android < 7.
The 'X' wasn't supported until Android 7.
2020-08-28 09:30:03 -04:00
Alan Evans
2d2395accf Hide block options if recipient is not blockable. 2020-08-28 10:13:23 -03:00
Alan Evans
8634289b7a Bump version to 4.70.2 2020-08-27 17:39:17 -03:00
Alan Evans
45043fb9a8 Updated language translations. 2020-08-27 17:38:23 -03:00
Cody Henthorne
0449795725 Make top gradient disappear with call controls.
Fixes [#9951](https://github.com/signalapp/Signal-Android/issues/9951)
2020-08-27 16:26:15 -04:00
Alan Evans
a96093f1b7 Exclude unused facial models from APK. 2020-08-27 17:01:10 -03:00
Alex Hart
bd4f7691e9 Add proper background color to camera icon.
Fixes #9945
2020-08-27 17:00:05 -03:00
Alex Hart
e12acbae70 Add @ to username in preferences. 2020-08-27 16:34:21 -03:00
Alan Evans
48dc4eac10 Bump version to 4.70.1 2020-08-27 12:25:39 -03:00
Alan Evans
a869c92eee Updated language translations. 2020-08-27 12:23:00 -03:00
Greyson Parrelli
4fefd14538 Add unit test to prevent shipping forced feature flags. 2020-08-27 11:14:20 -04:00
Greyson Parrelli
c09dbfa47c Prevent corner-case where link previews were generated for SMS.
Also added some hardening to make sure that it's impossible for any link
previews to be fetched if the setting is disabled (this was already the
case in practice, we just have some assertions in there now).

Fixes #9956
2020-08-27 12:12:44 -03:00
Alan Evans
d3c9f66de6 Prevent simple dialog flicker. 2020-08-27 12:12:44 -03:00
Alan Evans
01d7694108 Add reset confirmation dialog and copy to group link management screen. 2020-08-27 12:12:44 -03:00
Alex Hart
1425b651d4 Update username UX and UI. 2020-08-27 12:12:44 -03:00
Greyson Parrelli
b1befbeefc Add additional LinkPreviewUtil unit tests.
Also updated the date format -- funnily enough Android will work with
either Z or X in the format, but the test JVM will fail if it doesn't
use X. X is definitely the correct thing to use based on the Javadoc, I
think Android's implementation is just a little more lenient.
2020-08-27 09:32:33 -04:00
Panagiotis Vasilopoulos
3a9a84a0b1 Do not attempt to create link previews for .i2p links 2020-08-27 10:01:50 -03:00
Alan Evans
368284cccc Enable auto verify for signal.group links. 2020-08-26 20:48:42 -03:00
Alan Evans
ef777f4db9 Make group links remote capable. 2020-08-26 18:02:42 -03:00
Alan Evans
a8e4e8e882 Bump version to 4.70.0 2020-08-26 17:25:54 -03:00
Alan Evans
cf93760d00 Updated language translations. 2020-08-26 17:25:54 -03:00
Greyson Parrelli
dd8b9ff8fb Add support for article dates in link previews. 2020-08-26 17:25:54 -03:00
Alan Evans
bfed03b7b5 Manage group links behind feature flag. 2020-08-26 17:25:54 -03:00
Alan Evans
860f06ec9e Join group via invite link. 2020-08-26 12:51:25 -03:00
Alex Hart
b58376920f Order pinned conversations in "first added" order instead of reordering as messages come in. 2020-08-26 11:13:01 -03:00
Alan Evans
4ace075ddf Display membership count in link preview description field. 2020-08-26 09:26:25 -03:00
Fumiaki Yoshimatsu
dda98a474d Listen to the uiMode configuration changes.
Fixes #9736
Fixes #9922
2020-08-25 17:11:29 -03:00
Alan Evans
f1c0df7d87 Update KBS Service Id on staging. 2020-08-25 17:10:07 -03:00
Greyson Parrelli
c78e098cb4 Add support for link preview descriptions. 2020-08-25 16:05:39 -04:00
Alex Hart
a3438c4f8d Change where edit profile screen requests camera permission. 2020-08-25 16:35:16 -03:00
Alan Evans
92ecf2d5de Add group link join version feature flag. 2020-08-25 16:35:06 -03:00
Alex Hart
f18b653725 Fix crash when scrolling to the top of a conversation. 2020-08-25 15:17:21 -03:00
Alex Hart
5128438cfb Fix action bar usability in vertical screen split. 2020-08-25 09:33:11 -03:00
Greyson Parrelli
f29f25822b Have DatabaseFactory.getMmsDatabase() return MessageDatabase. 2020-08-24 16:40:47 -04:00
Greyson Parrelli
ecfe218840 Bump version to 4.69.6 2020-08-24 14:34:53 -04:00
Greyson Parrelli
dd33d2b5d0 Updated language translations. 2020-08-24 14:34:28 -04:00
Alex Hart
12a8d4e10b Fix crash on multi-archive. 2020-08-24 14:34:28 -04:00
Alex Hart
c5c2fb31b1 Fix CREATE statement for RecipientDatabase. 2020-08-24 14:25:37 -04:00
Alex Hart
343b7faf98 Bumped version to 4.69.5 2020-08-24 11:16:41 -03:00
Alex Hart
18aa8bbf60 Updated language translations. 2020-08-24 11:16:41 -03:00
Greyson Parrelli
a358d1630f Rotate the CDS feature flag. 2020-08-24 11:16:41 -03:00
Alan Evans
01375b321c Don't release bitmaps managed by Glide, and don't cache group preview avatars. 2020-08-24 11:16:41 -03:00
Alex Hart
d2739d52e0 Remember position in react-with-any-emoji picker. 2020-08-24 11:16:41 -03:00
Alex Hart
4668510106 Fix crash when archiving multiple conversations. 2020-08-24 11:16:41 -03:00
Alex Hart
ffcd311c90 Fix strange long press behavior in convo list.
Fixes #9944
2020-08-24 11:16:41 -03:00
Alex Hart
b94a636542 Apply Content-Range and Content-Length headers to resumable upload request. 2020-08-24 11:16:41 -03:00
Jim Gustafson
a7aec6bfbc Update to RingRTC v2.5.0 2020-08-24 11:16:41 -03:00
Greyson Parrelli
190ca9eddd Have DatabaseFactory.getSmsDatabase() return MessageDatabase.
Slowly moving towards a single interface.
2020-08-24 11:16:41 -03:00
Greyson Parrelli
2cf9eb69eb Add support for handling unknown protobuf fields. 2020-08-24 11:16:41 -03:00
Alan Evans
ffcb90da52 Accept any length group link password. 2020-08-24 11:16:41 -03:00
Alan Evans
878b0c9275 Change group invite link host. 2020-08-24 11:16:41 -03:00
Evan Hahn
5505cb0dea Update donation link in contribution instructions. 2020-08-24 11:16:41 -03:00
Alex Hart
7ac14dccda Refresh username in onResume and utilize imeAction. 2020-08-24 11:16:41 -03:00
Greyson Parrelli
6cffd0a723 Update link preview sync settings.
We need to rotate the link preview setting to avoid newer desktops with
older mobile clients from generating proxy-less previews.
2020-08-24 11:16:41 -03:00
Alan Evans
220ebf93c7 During registration, persist time that call me is available.
Fixes #9926
2020-08-19 16:32:01 -04:00
Greyson Parrelli
d0681a5592 Make calling status strings consistent.
Fixes #9904
2020-08-19 16:32:01 -04:00
Alan Evans
09d167c16d Group link preview and info display bottom sheet. 2020-08-19 16:32:01 -04:00
Alan Evans
477bb45df7 Group invite link epoch support. 2020-08-19 16:32:01 -04:00
Alex Hart
e006306036 Utilize ItemCallback for ReactWithAnyAdapter.
Fixes #9918
2020-08-19 16:32:01 -04:00
Greyson Parrelli
065cbcf0f9 Bump version to 4.69.4 2020-08-19 16:08:07 -04:00
Greyson Parrelli
7a6b958bbe Updated language translations. 2020-08-19 16:07:46 -04:00
Cody Henthorne
ef6a5b6599 Fix bug causing call requests to not be handled properly. 2020-08-19 15:49:16 -04:00
Greyson Parrelli
cdae919b5e Bump version to 4.69.3 2020-08-19 10:03:26 -04:00
Greyson Parrelli
12889f4549 Updated language translations. 2020-08-19 10:03:04 -04:00
Greyson Parrelli
089d59b691 Properly mark local note-to-self attachments as uploaded. 2020-08-19 09:59:37 -04:00
Alex Hart
b3e247e9cc Fix crash when loading vector from typed array.
Fixes #9933
2020-08-19 10:45:01 -03:00
Greyson Parrelli
56392b87f7 Bump version to 4.69.2 2020-08-18 19:22:42 -04:00
Greyson Parrelli
1b1a4aeb38 Updated language translations. 2020-08-18 19:22:18 -04:00
Greyson Parrelli
16147e0c08 Ensure link preview fetches are canceled on message send. 2020-08-18 18:34:18 -04:00
Cody Henthorne
139317cf1b Improve various aspects of mentions. 2020-08-18 18:13:45 -04:00
Cody Henthorne
72b94127fb Stop muted threads from triggering full notification updates. 2020-08-18 14:15:55 -04:00
Alan Evans
1f1fc94d22 Fix flakey robolectric test. 2020-08-18 11:57:35 -03:00
Greyson Parrelli
a574fe026c Bump version to 4.69.1 2020-08-17 12:04:41 -04:00
Greyson Parrelli
aa82083d30 Updated language translations. 2020-08-17 12:04:41 -04:00
Greyson Parrelli
08d5df70c2 Don't show the link preview megaphone if previously disabled. 2020-08-17 12:04:41 -04:00
Greyson Parrelli
29b8fa5897 Keep pinned chats at the top of the 'recent' chat section. 2020-08-17 11:12:10 -04:00
Alex Hart
e96faf31d4 Fix browser opening on long-press of debug log links. 2020-08-17 11:54:41 -03:00
Greyson Parrelli
157a73aa99 Fix title of conversation pin menu item. 2020-08-17 10:37:17 -04:00
Greyson Parrelli
bdd298c8a0 Prevent swipe actions on the 'Pinned' header. 2020-08-17 10:31:28 -04:00
Greyson Parrelli
3f7dd21186 Do not attempt to create link previews for .onion links. 2020-08-17 10:27:30 -04:00
Greyson Parrelli
086b708cf7 Fix NPE when double-tapping the conversation pinning icon. 2020-08-17 10:07:58 -04:00
Alan Evans
57e0e57f48 Fix NPE when link preview image cannot be decoded. 2020-08-15 10:10:15 -03:00
Greyson Parrelli
4b7efbfdc0 Bump version to 4.69.0 2020-08-14 15:54:06 -04:00
Greyson Parrelli
7dc2653042 Updated language translations. 2020-08-14 15:54:06 -04:00
Cody Henthorne
e428453835 Fix conversation list bug with pinned chats.
Co-authored-by: Alex Hart <alex@signal.org>
2020-08-14 15:54:06 -04:00
Greyson Parrelli
f84c8229de Revert "Replace a call to a deprecated method to update context with the new one."
This reverts commit 5f0d384c9e.

Introduced a bug where the system theme wasn't changing until app
restart.
2020-08-14 15:54:06 -04:00
Alex Hart
a73427d68d Fix issues with conversation list position. 2020-08-14 15:54:05 -04:00
Alan Evans
e4456bb236 Handle GV2 addresses. 2020-08-14 15:54:05 -04:00
Alex Hart
06eadd0c15 Add mentions unread counter. 2020-08-14 15:54:05 -04:00
Alan Evans
3c90dfa660 Ensure a GV2 update message mentioning you as a new member is first in the list. 2020-08-14 15:54:05 -04:00
Greyson Parrelli
ace1b8ee71 Update link preview settings and add some UI polish. 2020-08-14 15:54:05 -04:00
Cody Henthorne
676356e800 Add Mentions Megaphone. 2020-08-14 15:54:05 -04:00
Greyson Parrelli
f732e54c22 Update group size flag. 2020-08-14 15:54:05 -04:00
Cody Henthorne
cdc2e74f68 Stop conversations without meaningful messages from showing in list. 2020-08-14 15:54:05 -04:00
Cody Henthorne
724f3e872b Update Mention UI/UX to match latest designs. 2020-08-14 15:54:05 -04:00
Alex Hart
d63e5165eb Add ability to pin up to 4 conversations. 2020-08-14 15:54:05 -04:00
Cody Henthorne
9892c4392e Fix janky avatar preview transition for notched devices. 2020-08-14 15:54:05 -04:00
Cody Henthorne
5ced1a775c Fix bug where SN change dialog appeared unnecessarily. 2020-08-14 15:54:05 -04:00
Cody Henthorne
761de1318e Update mention data during recipient merge. 2020-08-14 15:54:05 -04:00
Cody Henthorne
02508512d5 Fix incorrect snippet generation by ignoring profile name change messages. 2020-08-14 15:54:05 -04:00
Greyson Parrelli
6e6105af05 Open up link previews to work with all sites. 2020-08-14 15:54:05 -04:00
Jared Andrews
d569419e13 Fixes conversation overflow menu items not being tappable.
Fixes #9908
2020-08-13 19:47:46 -04:00
Greyson Parrelli
93f1641803 Bump version to 4.68.8 2020-08-10 21:13:19 -04:00
Greyson Parrelli
ff52bf93fa Make the CDS flag remote capable. 2020-08-10 13:27:11 -04:00
Greyson Parrelli
a039275a0c Bump version to 4.68.7 2020-08-10 11:40:37 -04:00
Greyson Parrelli
a98d10104d Updated language translations. 2020-08-10 11:39:30 -04:00
Alan Evans
8924bc59b1 Hide legacy group warning when GV2 create feature flag is off or MMS is forced.
Fixes #9913
2020-08-08 17:43:07 -03:00
Greyson Parrelli
eefe60a9c9 Bump version to 4.68.6 2020-08-07 19:37:05 -04:00
Greyson Parrelli
fe1cb3d904 Updated language translations. 2020-08-07 19:36:26 -04:00
Greyson Parrelli
0448278a78 Include a recipient in sent transcripts when possible. 2020-08-07 19:20:35 -04:00
Greyson Parrelli
99c0c2ff4c Fix crash when opening debuglogs during registration. 2020-08-07 19:20:35 -04:00
Greyson Parrelli
b369b734ca Improve storage service insert recovery. 2020-08-07 19:20:35 -04:00
Greyson Parrelli
57150a20fd Make verificationV2 a separate flag. 2020-08-07 19:20:35 -04:00
Cody Henthorne
1634d7d531 Show mention picker immediately after @ entered. 2020-08-07 15:27:15 -04:00
Cody Henthorne
d563de4207 Add mention detection to search flows. 2020-08-07 15:18:40 -04:00
Greyson Parrelli
5cd4b82ed0 Bump version to 4.68.5 2020-08-06 21:03:31 -04:00
Greyson Parrelli
5f728d348c Updated language translations. 2020-08-06 21:02:22 -04:00
Greyson Parrelli
596c4b6e40 Don't include inactive groups when listing groups in common. 2020-08-06 20:57:50 -04:00
Alex Hart
36d1e7c44a Disable Contact Join Notification via Action. 2020-08-06 20:57:50 -04:00
Alan Evans
25c17082f2 Share a common groups v2 capacity flag across clients. 2020-08-06 20:57:50 -04:00
Alan Evans
810ccf8e94 Improve GV2 Invitation revoke experience. 2020-08-06 20:57:50 -04:00
Alex Hart
c8ed0b19f0 Do not update thread on profile name change. 2020-08-06 20:57:50 -04:00
Alan Evans
9e09444c65 Increment the Groups V2 feature flags version. 2020-08-06 20:57:50 -04:00
Greyson Parrelli
5923fa0cd5 Block sends on CDS lookups. 2020-08-06 20:57:50 -04:00
Cody Henthorne
b2d4c5d14b Add mentions for v2 group chats. 2020-08-06 20:57:50 -04:00
Alex Hart
0bb9c1d650 Add light and dark spinner lotties with correct coloring. 2020-08-06 20:57:50 -04:00
Alan Evans
fbfa3abffd Skip delete actions where the removed member/pending member is not in the group. 2020-08-06 20:57:50 -04:00
Alan Evans
b5656aa5dd Exclude non-translatable multiline blocks. 2020-08-06 20:57:50 -04:00
Alan Evans
d53fd6a109 Change invite cancel to invite revoke. 2020-08-06 20:57:50 -04:00
Alan Evans
b0650b926b Fix pending member group edit rights. 2020-08-06 20:57:50 -04:00
Alan Evans
845f6a0a93 Notify user during group create of members that do not support GV2. 2020-08-06 20:57:50 -04:00
Alex Hart
d8daa83c79 Remove autoLink from conversation update items. 2020-08-06 20:57:50 -04:00
Alex Hart
7bb0199e83 Change additional groups copy to match iOS. 2020-08-06 20:57:50 -04:00
Alex Hart
f014dadf06 Adjust Zoom levels and transition duration. 2020-08-06 20:57:50 -04:00
Alex Hart
393e54ce91 Update how we mark messages as read. 2020-08-06 20:57:50 -04:00
Alan Evans
fdf4ad9543 Remove the GV2 "anyone" access level. 2020-08-06 20:57:50 -04:00
Fumiaki Yoshimatsu
5f0d384c9e Replace a call to a deprecated method to update context with the new one.
Fixes #9736
2020-08-06 20:57:50 -04:00
Christian Ascheberg
4271700046 Do not collapse list to hide only one entry. 2020-08-06 20:57:50 -04:00
Niko Lockenvitz
e153b0ab78 Fix message compose hint on fullscreen.
Fixes #5294
Closes #5348
2020-08-06 20:57:50 -04:00
Alan Evans
26868ae668 Get authoritative profile keys from group changes only. 2020-08-06 20:57:50 -04:00
Greyson Parrelli
17c0364eda Ensure group avatars have V2 attachmentIds. 2020-08-06 20:57:50 -04:00
Alan Evans
b28ac7af8c Additional tests around rigid Groups V2 change application. 2020-08-06 20:57:50 -04:00
Greyson Parrelli
2dcaa21a44 Remove UuidRecipientError. 2020-08-04 19:12:25 -04:00
Greyson Parrelli
33cc8363f9 Add internal setting to see recipient details. 2020-08-04 19:12:25 -04:00
Greyson Parrelli
9b61e1c85c Show a message request for certain GV2 adds. 2020-08-04 19:12:25 -04:00
Greyson Parrelli
6f53fdc02d Clean up log statement in FcmFetchService. 2020-08-04 19:12:25 -04:00
Greyson Parrelli
6f850f5a55 Bump version to 4.68.4 2020-08-04 17:53:22 -04:00
Greyson Parrelli
a482a4b1f4 Updated language translations. 2020-08-04 17:46:11 -04:00
Greyson Parrelli
3664e6f96d Fix processing of unsupported messages. 2020-08-04 17:37:25 -04:00
Greyson Parrelli
dda8808173 Bump version to 4.68.3 2020-08-03 12:30:51 -04:00
Greyson Parrelli
63a24c23cc Updated language translations. 2020-08-03 12:29:52 -04:00
Greyson Parrelli
1ec3a72f79 Fix issue with thread summaries being updated after message deletion.
Fixes #9902
2020-08-03 10:36:02 -04:00
Greyson Parrelli
566285ec0e Fix crash in MMS group creation.
Fixes #9901
2020-08-03 10:03:45 -04:00
Greyson Parrelli
d5ba82338d Fix issue with text rendering in search results. 2020-08-03 09:47:27 -04:00
Greyson Parrelli
cbecd2a2fc Bump version to 4.68.2 2020-07-31 16:47:55 -04:00
Greyson Parrelli
3772dd40ac Updated language translations. 2020-07-31 16:46:01 -04:00
Alex Hart
f69a0f0261 Refine reaction details fragment. 2020-07-31 16:49:52 -03:00
Alex Hart
cb323ffb84 Fix reaction overlay toolbar and status bar. 2020-07-31 15:51:41 -03:00
Alex Hart
0db73e71a0 Remove sticky header on list reinitailization.
When we forward a message or share into the app, it is possible that we are going to reuse the same activity. In this case, when the adapter was reinitialized, we were just adding a new ItemDecoration every time.

This fix checks if we've already added one and removes it if necessary, just like the last seen decorator.
2020-07-31 14:26:31 -03:00
Alex Hart
eeb0c838db Fix masking when attachment keyboard is visible. 2020-07-31 11:34:46 -03:00
Greyson Parrelli
dc48ee5aed Bump version to 4.68.1 2020-07-30 23:32:20 -04:00
Greyson Parrelli
c0acfa57a9 Updated language translations. 2020-07-30 23:32:19 -04:00
Greyson Parrelli
3e166ef927 Fix issue where group updates were mis-rendered. 2020-07-30 23:32:19 -04:00
Greyson Parrelli
4942d83de5 Properly render reset session update messages. 2020-07-30 23:32:19 -04:00
Alex Hart
4c30b39e71 Add section to recent reactions page listing emoji already applied to message. 2020-07-30 23:32:19 -04:00
Alex Hart
e55f4fe6b6 Save preference on emoji send. 2020-07-30 22:26:59 -04:00
Greyson Parrelli
aff74cffa0 Fix crash with UnknownSenderView.
The listener was being called on a background thread, but it was doing
UI work.
2020-07-30 13:31:51 -04:00
Alex Hart
8b29bb8664 Fix info icon in light mode. 2020-07-30 10:48:45 -03:00
Greyson Parrelli
3cee57b6c2 Bump version to 4.68.0 2020-07-29 23:54:46 -04:00
Greyson Parrelli
857f4a4fc8 Updated language translations. 2020-07-29 23:54:09 -04:00
Jim Gustafson
a942293a74 RingRTC v2.4.0 Release Integration.
Co-authored-by: Peter Thatcher <peter@signal.org>
2020-07-29 23:43:06 -04:00
Greyson Parrelli
550b121990 Prevent UUID-only contacts from being added to GV1 groups. 2020-07-29 23:43:06 -04:00
Alex Hart
cc84901a49 Add dropshadow to emoji variation popup. 2020-07-29 23:43:06 -04:00
Alex Hart
9d3764c5d9 Reactions UX polish. 2020-07-29 23:43:06 -04:00
Greyson Parrelli
0950235ccd Fix typo in RemappedRecords. 2020-07-29 23:19:21 -04:00
Greyson Parrelli
8ed7fc894e Improve handling of partially bi-directional text. 2020-07-29 23:19:21 -04:00
Greyson Parrelli
e504ffa225 Clean up conversation list data loading sequence.
- The Paging library was giving us empty paged lists when loading was
invalidated, but only *sometimes*. This library, man. Fixed it by
ignoring invalid lists, which you'd think the library would do for us...
- Noticed we were doing a ton of list refreshes because of how we were
listening to archive count. Switched from combine to switchMap.
- Noticed that we could become double-subscribed to LiveDatas in the
ConversationListFragment if you went to archived. Fixed by observing on
the fragment's view lifecycle.

Fixes #9803
2020-07-29 23:19:21 -04:00
Cody Henthorne
9c63b37bb4 Refactor use of MessageRecord to increase flexibility of ConversationAdapter. 2020-07-29 23:19:21 -04:00
Greyson Parrelli
5c110ca359 Remove UUIDs from GV1 membership lists. 2020-07-29 23:19:21 -04:00
Cody Henthorne
1ab61beeb9 Add initial Mentions UI/UX for picker and compose edit. 2020-07-28 15:20:20 -04:00
Alan Evans
8e45a546c9 Fix NPE on Group multi-invite. 2020-07-28 15:20:20 -04:00
Alan Evans
745a7f76ea Change position of GroupsV2 leave update message. 2020-07-28 15:20:20 -04:00
Alan Evans
8cb9ab3204 Fetch newly found profiles on Groups V2 inline. 2020-07-28 15:20:20 -04:00
Alan Evans
12533d1414 Ensure profile key is up to date on Group V2 conversation open. 2020-07-28 15:20:20 -04:00
Alan Evans
bd1c164d57 Live group update messages on conversation list and conversation. 2020-07-28 15:20:20 -04:00
Greyson Parrelli
7446c2096d Don't ellipsize multi-line text in conversation list.
Instead, basically convert newlines to spaces.
2020-07-28 15:19:52 -04:00
Greyson Parrelli
8ce5c4b885 Cleanup naming of RecipientDatabase GLOB search. 2020-07-28 15:19:52 -04:00
Alan Evans
ab76112f5f Prevent leading and trailing whitespace in group names. 2020-07-28 15:19:52 -04:00
Alan Evans
9c54e39eae Adjust scope of Groups V2 feature flag. 2020-07-28 15:19:52 -04:00
Greyson Parrelli
61eab44474 Bump version to 4.67.3 2020-07-27 18:04:05 -04:00
Greyson Parrelli
f6285ec710 Updated language translations. 2020-07-27 18:02:31 -04:00
Alex Hart
ed878ec4b4 Add more generic SMS verification code pattern. 2020-07-27 17:57:56 -04:00
Greyson Parrelli
e38d41d67a Reduce the number of cats in giphy sticker search results. 2020-07-27 15:25:26 -04:00
Greyson Parrelli
3d237d72bd Fix issue where feature flag fetches weren't limited. 2020-07-27 15:25:01 -04:00
Cody Henthorne
8044d2390c Fix bug causing profile updates to unarchive threads. 2020-07-27 13:32:38 -04:00
Greyson Parrelli
6b82e6b5ac Bump version to 4.67.2 2020-07-24 14:31:06 -04:00
Greyson Parrelli
842e6a93e2 Updated language translations. 2020-07-24 14:31:06 -04:00
Alan Evans
f140f054e5 Ignore typing indicators from blocked group members. 2020-07-24 14:31:06 -04:00
Greyson Parrelli
5cd4726e23 Do not show profile name changes if names are visually identical.
Fixes #9860
2020-07-24 14:30:58 -04:00
Greyson Parrelli
bccc58d693 Bump version to 4.67.1 2020-07-22 22:58:21 -04:00
Greyson Parrelli
e25f1c1481 Updated language translations. 2020-07-22 22:58:21 -04:00
Greyson Parrelli
fc4e690996 Revert "Ensure GV1 length is exactly the length expected."
This reverts commit 8e962bf992.
2020-07-22 22:58:21 -04:00
Greyson Parrelli
dadb2f9d37 Allow auto-downloads from groups you've accepted. 2020-07-22 22:58:21 -04:00
Greyson Parrelli
5bf15b0587 Fix casing issues with non-ASCII characters in contact search.
SQLite's case-related stuff is ASCII-only. That means that even though LIKE is supposed to be case-insensitive, it fails when used on non-ASCII characters.

There appears to be no relief in SQLite itself, so I swapped our contact search to use GLOB instead of LIKE and wrote a little thing to convert query strings into a case-insensitive unicode-compatible patterns. Didn't see any noticeable performance difference.
2020-07-22 22:58:21 -04:00
Cody Henthorne
5f9c0c3204 Fix bug with skipping resend message on safety number change. 2020-07-22 22:58:21 -04:00
Alan Evans
dfa4f0c309 Fix group change failure reason display logic. 2020-07-22 22:58:21 -04:00
Greyson Parrelli
f0063b4b0d Sync ContactRecords as whitelisted if they're a system contact. 2020-07-22 22:58:21 -04:00
Alan Evans
5dc51c34ea Fix recipient resolution during add to Groups V2. 2020-07-22 22:58:21 -04:00
Greyson Parrelli
5bf7a55bfa Bump version to 4.67.0 2020-07-21 16:11:45 -04:00
Greyson Parrelli
eb9ae8d5dc Updated language translations. 2020-07-21 16:11:45 -04:00
Greyson Parrelli
2a133587cc Add a flag for recipientTrust. 2020-07-21 16:11:45 -04:00
Greyson Parrelli
0e4a19c368 Improve exception stack traces in OptimizedMessageNotifier. 2020-07-21 15:31:53 -04:00
Greyson Parrelli
813c820227 Fix issue with GV1 avatars using attachmentsV3. 2020-07-21 15:31:53 -04:00
Greyson Parrelli
870cee5707 Remove uuidOnlyContacts feature flag. 2020-07-21 15:31:53 -04:00
Alan Evans
4e55d2d941 Tint pending group invites menu icon. 2020-07-21 15:31:53 -04:00
Alan Evans
8e962bf992 Ensure GV1 length is exactly the length expected. 2020-07-21 15:31:53 -04:00
Cody Henthorne
0815715f7b Enable call requests always. 2020-07-21 15:31:53 -04:00
Alan Evans
85e4697b7f Increment the Groups V2 feature flags version. 2020-07-21 15:31:53 -04:00
Alan Evans
16fdb9bf4c Make identity record list immutable. 2020-07-21 12:53:25 -03:00
Greyson Parrelli
46f3d50a54 Increment the attachmentsV3 feature flag version. 2020-07-21 10:49:19 -04:00
Alan Evans
3a38240fb2 Groups V2 group manager copy updates. 2020-07-21 11:47:11 -03:00
Greyson Parrelli
662f0b8fb6 Improve detection of websocket drained status.
Will now work when you lose and regain network. Also removes the
unnecessary InitialMessageRetriever.
2020-07-21 10:38:42 -04:00
Alan Evans
96ce42ae91 Legacy group learn more badge and info bottom sheet. 2020-07-21 06:05:16 -03:00
Alan Evans
93f587b851 For atomic Groups V2 block and leave, block after leaving group. 2020-07-21 06:04:44 -03:00
Greyson Parrelli
89a940ec81 Fix issue with contact syncing with attachmentsV3. 2020-07-20 17:57:22 -04:00
Alan Evans
a33771b15d Added progress feedback to leave and block group actions and additional group v2 error handling. 2020-07-20 15:20:56 -03:00
Greyson Parrelli
9a566e5559 Group together skin tone variations of the same reaction. 2020-07-20 10:26:39 -04:00
Greyson Parrelli
6e75d42a92 Enable skin tone selection for emoji reactions. 2020-07-20 10:26:39 -04:00
Alan Evans
575413cac9 Wait for message queue to drain before updating v2 groups. 2020-07-20 11:09:42 -03:00
Greyson Parrelli
6a9476c6d0 Fix retry issues with RotateProfileKeyJob. 2020-07-19 10:45:20 -04:00
Greyson Parrelli
5468f1705c Ensure we refresh attributes if key changes from storage service. 2020-07-19 10:45:20 -04:00
Greyson Parrelli
5ea132e712 Delay directory refresh until registration is complete. 2020-07-19 10:22:05 -04:00
Cody Henthorne
8128fcf8bc Hide compose for inactive groups. 2020-07-19 09:32:16 -04:00
Greyson Parrelli
e89655f793 Resolve newly-entered numbers before starting a conversation. 2020-07-19 09:32:16 -04:00
Cody Henthorne
2db2b068c4 Do not show typing indicators for inactive groups. 2020-07-19 09:32:16 -04:00
Alan Evans
a59e214317 Show Group V2 invited member dialog explaining invites on new group and add to group. 2020-07-19 09:32:16 -04:00
Cody Henthorne
ae2b6e4d7a Prevent last admin from leaving without selecting new admin. 2020-07-19 09:32:16 -04:00
Alan Evans
b10fc6a0b0 Support Groups v2 Change Epochs. 2020-07-19 09:32:16 -04:00
Cody Henthorne
70977e5228 Show expiration time exactly as set instead of rounding. 2020-07-19 09:32:16 -04:00
Greyson Parrelli
4482391574 Update libphonenumber to v8.12.6 2020-07-19 09:32:16 -04:00
Greyson Parrelli
bd078fc883 Handle UUID-only recipients and merging. 2020-07-19 09:32:16 -04:00
Alan Evans
644af87782 Groups V2 invite decline. 2020-07-19 09:32:16 -04:00
Greyson Parrelli
1ce36c1069 Bump version to 4.66.8 2020-07-17 17:32:33 -04:00
Greyson Parrelli
0a71005ecc Updated language translations. 2020-07-17 17:32:07 -04:00
Cody Henthorne
698618a4b3 Only show profile updates in active groups. 2020-07-17 17:32:07 -04:00
Alan Evans
f9642dd79f Reduce scrim overlap when scrolling new manage screens. 2020-07-17 17:32:07 -04:00
Cody Henthorne
85d1a3c016 Add system contact indicator to recipient bottom sheet. 2020-07-17 17:32:07 -04:00
Alan Evans
38c74c81a6 Add qa to translate task. 2020-07-17 17:32:07 -04:00
Greyson Parrelli
4c04991b70 Refresh recipient after viewing system contact details.
They might have changed the name or otherwise edited the contact, so we
want to try to keep things in sync.
2020-07-17 17:32:07 -04:00
Cody Henthorne
293a339fed Only show delete action when long pressing on profile change update. 2020-07-17 17:32:07 -04:00
Greyson Parrelli
5255a527f9 Do not show profile name changes for blocked users. 2020-07-17 17:32:07 -04:00
Cody Henthorne
9440dfb66c Do not show profile name changes on first update. 2020-07-17 09:42:13 -04:00
Alan Evans
7a019eee19 Updated language translations. 2020-07-16 16:21:02 -03:00
Greyson Parrelli
93f56a5dc8 Bump version to 4.66.7 2020-07-16 10:40:04 -04:00
Greyson Parrelli
68264228b8 Updated language translations. 2020-07-16 10:33:33 -04:00
Greyson Parrelli
66c1b8e26c Fix contact icon tint issues on older android versions. 2020-07-16 10:27:23 -04:00
Cody Henthorne
5776c048ea Do not update threads that do not exist. 2020-07-16 09:27:41 -04:00
Greyson Parrelli
76dd09bc50 Handle null profile names better. 2020-07-16 08:34:53 -04:00
Greyson Parrelli
73d18d3abd Bump version to 4.66.6 2020-07-15 17:12:37 -04:00
Greyson Parrelli
c1c9d0c8a3 Updated language translations. 2020-07-15 17:12:09 -04:00
Cody Henthorne
64420ead7c Show Profile Name Change update messages. 2020-07-15 16:15:15 -04:00
Alan Evans
6d035c6888 Allow sending of group v2 updates to inactive groups. 2020-07-15 12:31:59 -03:00
Alan Evans
833ca8cce9 Add disable GV2 creation option to internal preferences UI. 2020-07-15 12:28:47 -03:00
Ehren Kret
d02d506b13 Add force refresh of remote values to internal preferences UI. 2020-07-15 12:16:07 -03:00
Alan Evans
f306056e5d Enable lint StopShip comments. 2020-07-15 12:04:05 -03:00
Greyson Parrelli
58ec669d15 Fix quote attachmentV3 usage. 2020-07-14 19:43:17 -04:00
Greyson Parrelli
d1b61bfed3 Add indicator for system contacts. 2020-07-14 10:37:09 -04:00
Greyson Parrelli
325e0c6781 Bump version to 4.66.5 2020-07-14 10:26:15 -04:00
Greyson Parrelli
8d66cd52b5 Updated language translations. 2020-07-14 10:25:46 -04:00
Greyson Parrelli
4b9277629c Fix issue with tracking registration state. 2020-07-13 19:00:44 -04:00
Greyson Parrelli
6515a6188b Bump version to 4.66.4 2020-07-13 11:01:18 -04:00
Greyson Parrelli
8b3ca52502 Updated language translations. 2020-07-13 11:00:34 -04:00
Alan Evans
fae003e085 Do not sync group v2 recipients that we do not have the master key for. 2020-07-13 11:52:06 -03:00
Greyson Parrelli
4b961d2d8f Simplify PIN opt-out code. 2020-07-13 09:29:17 -04:00
Greyson Parrelli
e27fc512b4 Add a migration for users of the previous PIN opt-out flow. 2020-07-13 08:53:02 -04:00
Greyson Parrelli
8f0f600b6b Bump version to 4.66.3 2020-07-11 11:42:51 -04:00
Greyson Parrelli
5950610690 Updated language translations. 2020-07-11 11:42:51 -04:00
Greyson Parrelli
fce3df0c82 Update pin opt-out strings and behavior. 2020-07-11 11:42:51 -04:00
Greyson Parrelli
e2021231c6 Bump version to 4.66.2 2020-07-10 17:23:50 -04:00
Greyson Parrelli
f61dd7509e Updated language translations. 2020-07-10 17:23:50 -04:00
Greyson Parrelli
db2b64e58c Update PIN opt-out strings. 2020-07-10 17:23:50 -04:00
Alan Evans
d70999c386 Add storage force push internal option. 2020-07-10 17:23:50 -04:00
Alan Evans
eb6ecc59ab Consolidate duplicated group send job logic. 2020-07-10 17:23:50 -04:00
Cody Henthorne
1e0e2fadfd Improve scroll to last position behavior. 2020-07-10 17:23:50 -04:00
Alan Evans
4325f714b9 Silent group update send job for profile key rotation. 2020-07-10 17:23:50 -04:00
Alan Evans
137cd45497 Hide "Add to a group" if you don't have any groups. 2020-07-10 17:23:50 -04:00
Alan Evans
f3dbe4416f Add lint to detect non-numeric version code checks. 2020-07-10 17:23:50 -04:00
Greyson Parrelli
7fb55c0f51 Keep borderless property when forwarding media. 2020-07-10 17:23:50 -04:00
Greyson Parrelli
fdc6cbc507 Bump version to 4.66.1 2020-07-09 19:10:27 -04:00
Greyson Parrelli
072085ae82 Updated language translations. 2020-07-09 19:09:54 -04:00
Greyson Parrelli
04a8996348 Add the ability to opt out of PINs. 2020-07-09 19:07:21 -04:00
Cody Henthorne
c26dcc2618 Fix theming issues with snackbars and alert dialogs. 2020-07-09 19:07:21 -04:00
Alan Evans
a4dc340bbc Handle empty group change byte array. 2020-07-09 19:07:21 -04:00
Cody Henthorne
3c069fb588 Enable Media Preview to respond to media changes. 2020-07-09 19:07:21 -04:00
Fumiaki Yoshimatsu
1fe38f5ed1 Fix pen/highlighter tool single tap.
Fixes #9745
2020-07-09 11:25:10 -03:00
Greyson Parrelli
841c9424e9 Remove GV2 flag requirement for WakeGroupV2Job. 2020-07-09 10:02:59 -04:00
Greyson Parrelli
9c44a0c7d3 Don't run ProfileUploadJob if you're not registered. 2020-07-09 07:57:37 -04:00
Greyson Parrelli
2883d2eb31 Enable video call PiP. 2020-07-09 07:50:38 -04:00
Greyson Parrelli
f5aade943e Bump version to 4.66.0 2020-07-08 17:15:10 -04:00
Greyson Parrelli
d17c3f39d0 Updated language translations. 2020-07-08 17:12:19 -04:00
Alan Evans
9ac9ace6b8 Groups V2 state comparison and gap handling. 2020-07-08 17:12:19 -04:00
Greyson Parrelli
c9d2cef58d Add support for sending borderless keyboard stickers. 2020-07-08 16:51:30 -04:00
Alan Evans
a9e30eefdc Prevent adding self to group by number.
Fixes #9821
2020-07-08 16:51:30 -04:00
Cody Henthorne
1a895db9bd Finalize support for calling with system PIP. 2020-07-08 16:51:30 -04:00
Alan Evans
a955bc3b9b Fix single line text input for group names. 2020-07-08 16:51:30 -04:00
Alan Evans
96e888a4f5 Remove versioned profiles feature flag. 2020-07-08 16:51:30 -04:00
Alan Evans
99ff0c1e3c Ensure direct add members to a group removes any matching pending. 2020-07-08 16:51:30 -04:00
Alan Evans
599e89b1f9 Fix audio waveform RTL rendering.
Fixes #9823
2020-07-08 16:51:30 -04:00
Greyson Parrelli
33c527f15e Remove the final KBS feature flags. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
eb02dacfdc Convert HEIC/HEIF to JPEG. 2020-07-08 16:51:30 -04:00
Alan Evans
e6a0e5b858 Add internal preferences under Advanced behind feature flag.
Initially for GV2 testing.
2020-07-08 16:51:30 -04:00
Greyson Parrelli
545ba80697 Add support for borderless images.
Added support for 'borderless' images. Basically images that we'd like to render 
as if they were stickers, even though they're not stickers. On iOS, this will be 
stuff like memoji and bitmoji. On Android, in my initial pass, I've just added 
support for Giphy stickers. However, we can also detect bitmoji and keyboard 
stickers in the future. This is kind of a 'best effort' thing, so as long as we 
support receiving, we can just add sending support for more things as we go.
2020-07-08 16:51:30 -04:00
Cody Henthorne
1e250ee95c Add Calling Requests. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
5a12eedc2c Prevent possible deadlock with LiveRecipientCache.
Thread A: DirectoryHelper#updateContactsDatabase() acquires database lock
Thread B: LiveRecipientCache#getSelf() acquires lock on LiveRecipientCache
Thread A: DirectoryHelper#updateContactsDatabase() calls Recipient.externalContact(), which eventually needs LiveRecipientCache lock
Thread B: Needs to read the database (e.g. line 120) to get information about itself

So A has the DB lock but needs the LiveRecipientCache lock, and B has
the LiveRecipientCache lock but needs the DB lock.

In general, we need to avoid acquiring any new locks in a transaction,
but for now, this specific instance looks like it could be solved by
using a unique lock for LiveRecipientCache#getSelf().
2020-07-08 16:51:30 -04:00
Greyson Parrelli
5605fde777 Rename the UUID flag to be more explicit. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
9ac142688a Increase the max PIN reminder interval to 4 weeks. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
2791790bf5 Implement new CDS changes. 2020-07-08 16:51:30 -04:00
Cody Henthorne
1752972be9 Update delete for everyone functionality to match requirements. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
c877aba09f Use resolved recipients in the conversation list. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
70e33518a9 Do registration checks for new numbers during group creation. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
cb81a9f783 Disallow 'visually empty' profile names. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
b6b499d865 Refresh recipients outside of a transaction for storage service. 2020-07-08 16:51:30 -04:00
Alan Evans
6704ad8193 Do not show update messages for profile key updates. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
942628a261 Improve ConversationListDataSource logging. 2020-07-08 16:51:30 -04:00
Greyson Parrelli
4ea8bac10d Re-enable view prefetching. 2020-07-08 16:51:30 -04:00
Alan Evans
eafccc5721 Add GV2 copy for the unknown editor. 2020-06-30 14:46:10 -03:00
Greyson Parrelli
a01bec3a11 Bump version to 4.65.2 2020-06-30 11:38:26 -04:00
Greyson Parrelli
3868175b85 Updated language translations. 2020-06-30 11:37:44 -04:00
Greyson Parrelli
904cb01067 Use the BlobProvider in the contact and group sync jobs. 2020-06-30 11:17:29 -04:00
Alan Evans
5c0cb425a6 Only sync V1 groups with linked devices. 2020-06-30 10:17:42 -03:00
Cody Henthorne
9dbb2ef630 Ensure user knows Safety Number Change Dialog list is scrollable when necessary. 2020-06-26 16:36:01 -04:00
Alan Evans
bafd2817ee Fix pending member activity background color. 2020-06-26 17:29:05 -03:00
Greyson Parrelli
3380293923 Bump version to 4.65.1 2020-06-26 15:40:23 -04:00
Greyson Parrelli
a549c1ec8b Updated language translations. 2020-06-26 15:38:48 -04:00
Greyson Parrelli
ad84997ce0 Fix display of quotes in 'All Media' view. 2020-06-26 15:33:08 -04:00
Alan Evans
42e2576813 Prevent repeat attempts when waveforms cannot be generated. 2020-06-26 16:18:27 -03:00
Cody Henthorne
31b995fa98 Retrieve profiles on mismatch to notify user of updates quicker. 2020-06-26 14:25:39 -03:00
Greyson Parrelli
0364bec995 Allow skipping if you hit a network error during PIN restore. 2020-06-26 14:25:39 -03:00
Alan Evans
aa39f3d0a3 Fix create new pin option in registration flow. 2020-06-26 13:29:00 -03:00
Greyson Parrelli
db545f43ea Remove profile name reminder megaphone. 2020-06-26 11:52:00 -04:00
Cody Henthorne
bbe003a454 Improve messaging and UX around safety number changes. 2020-06-26 11:10:54 -04:00
Greyson Parrelli
819f0f68f6 Fix issue with some search results returning empty. 2020-06-26 10:46:44 -04:00
Greyson Parrelli
8c0160937b Fix crash with 'select all' in conversation list.
Fixes #9790
2020-06-26 10:12:16 -04:00
Cody Henthorne
6de789dfe3 Prevent attachment download button re-animation. 2020-06-26 10:10:34 -04:00
Greyson Parrelli
afa2bb3bf5 Disallow swipe actions in search mode.
Fixes #9771
2020-06-26 10:08:01 -04:00
Greyson Parrelli
89e66c0741 Bump version to 4.65.0 2020-06-25 18:14:54 -04:00
Greyson Parrelli
0dc4afba99 Updated language translations. 2020-06-25 18:14:54 -04:00
Greyson Parrelli
152578e576 Add reserved job runners for inbound and outbound messages. 2020-06-25 18:14:54 -04:00
Greyson Parrelli
63d6ab6fa7 Throttle conversation list update frequency.
This helps fast phones process messages faster by reducing contention on
the database while processing a large batch of messages.
2020-06-25 18:14:54 -04:00
Greyson Parrelli
75c8c59d78 Reduce notification update interval. 2020-06-25 18:14:54 -04:00
Greyson Parrelli
87a59b6a9b Add support for memory-only jobs. 2020-06-25 18:14:54 -04:00
Alan Evans
2001fa86cf Log capabilities. 2020-06-25 18:14:54 -04:00
Alan Evans
52747782a7 Full screen avatar circle to square shape transition. 2020-06-25 18:14:54 -04:00
Fumiaki Yoshimatsu
66f2668326 Do not cache locale in each conversation object.
Fixes #9751
2020-06-25 18:14:54 -04:00
Cody Henthorne
b262efc24c Clear up warnings in string resource file. 2020-06-25 18:14:54 -04:00
Alan Evans
ce7ad76447 Cycle Versioned Profiles feature flag. 2020-06-25 08:29:48 -04:00
Greyson Parrelli
9e98b6616e Log job run time. 2020-06-25 08:29:48 -04:00
Alan Evans
f4c9eaa904 Remove some unused resources. 2020-06-25 08:29:48 -04:00
Greyson Parrelli
f8a0988e5f Various JobManager performance improvements. 2020-06-25 08:29:48 -04:00
Greyson Parrelli
bf919207ed Various logging improvements.
* Improve lifecycle logging.
* Remove 'action bar' from base activity names.
* Remove some unnecessary glide logs.
2020-06-25 08:29:48 -04:00
Greyson Parrelli
dac6b5c992 Bump version to 4.64.7 2020-06-24 20:09:31 -04:00
Greyson Parrelli
7f8043777e Updated language translations. 2020-06-24 20:09:00 -04:00
Greyson Parrelli
854b3feb36 Reduce verbosity of job logs. 2020-06-24 20:00:42 -04:00
Greyson Parrelli
22447e6ddb Fix theming issue with snackbar. 2020-06-24 20:00:42 -04:00
Alan Evans
be2ec36e1f Fix clipping issues with archive icon.
Fixes #8344
2020-06-24 20:00:12 -04:00
Greyson Parrelli
98cf16479d Bump version to 4.64.6 2020-06-24 10:58:13 -04:00
Greyson Parrelli
584735cbd0 Updated language translations. 2020-06-24 10:57:45 -04:00
Alan Evans
3741493cb7 Remove frame rate reporter and unused FPS ringbuffer. 2020-06-24 11:44:35 -03:00
Greyson Parrelli
4ea861fe5c Improve 'mark all read' performance. 2020-06-24 10:34:52 -04:00
Jim Gustafson
cd3df4d3c1 Update to ringrtc v2.2.0 2020-06-24 09:50:43 -04:00
Alan Evans
881a1edccb Bump version to 4.64.5 2020-06-22 10:53:52 -03:00
Alan Evans
1b7b574289 Updated language translations. 2020-06-22 10:50:27 -03:00
Alan Evans
d1d7498447 Fix text colors when system theme doesn't match. 2020-06-22 10:02:18 -03:00
Greyson Parrelli
50c18727e7 Bump version to 4.64.4 2020-06-21 12:23:31 -04:00
Greyson Parrelli
e9bfde470a Updated language translations. 2020-06-21 12:23:10 -04:00
Greyson Parrelli
68f718a210 Fix issue with conversation list times not updating.
Just started calling notifyDataSetChanged() in onResume() to provide
some sort of time update regularity.
2020-06-21 12:20:18 -04:00
Greyson Parrelli
c3e528ad4b Bump version to 4.64.3 2020-06-19 19:17:16 -04:00
Greyson Parrelli
28af97c400 Updated language translations. 2020-06-19 19:17:16 -04:00
Jim Gustafson
c2e4c343ab Update to ringrtc v2.1.1 2020-06-19 19:12:59 -04:00
Cody Henthorne
8a78589c2f Fix light navigation buttons in conversation settings screens. 2020-06-19 16:53:38 -04:00
Alan Evans
841ee18435 Add default option to message vibrate for pre API26. 2020-06-19 13:08:54 -03:00
Greyson Parrelli
71f54701d2 Add additional safeguards around disappearing messages. 2020-06-19 10:17:23 -04:00
Alan Evans
1c99939dfa Bump version to 4.64.2 2020-06-18 17:30:38 -03:00
Alan Evans
50462cecd0 Updated language translations. 2020-06-18 17:29:20 -03:00
Cody Henthorne
aa6a32f023 Make conversation footer always show. 2020-06-18 16:14:38 -04:00
Alan Evans
c4dc9064e3 Handle Attachment Keyboard selection of a too large item. 2020-06-18 15:55:26 -03:00
Alan Evans
bc5be10a0e Respect emoji config on conversation banner title. 2020-06-18 15:39:02 -03:00
Alan Evans
98d9b57379 Add copy to bottom sheet for Note to Self. 2020-06-18 14:34:30 -03:00
Cody Henthorne
021a16050a Stop back transition jank from avatar viewer to settings. 2020-06-18 13:16:08 -04:00
Alan Evans
555104aff0 Make message button navigate back if launched from the conversation. 2020-06-18 14:00:06 -03:00
Alan Evans
95d63b78f4 Add call and message buttons to recipient bottom sheet.
And insecure call button for non-registered contacts.
2020-06-18 13:23:46 -03:00
Alan Evans
80f9e1f4f1 Fix not able to get to archived conversations when all archived. 2020-06-18 12:23:20 -03:00
Alan Evans
a77997a4de Fix margins for "No groups in common" & unregistered case. 2020-06-18 09:49:22 -03:00
Alan Evans
ec4eb8e2a9 Bump version to 4.64.1 2020-06-17 17:54:58 -03:00
Alan Evans
1bdeade71e Updated language translations. 2020-06-17 17:53:19 -03:00
Greyson Parrelli
629ba105cb Detect real age of call request by using server timestamps. 2020-06-17 17:53:18 -03:00
Alan Evans
891a1af995 Show Note to Self for local number recipient preferences. 2020-06-17 17:49:44 -03:00
Cody Henthorne
0fbc6ac151 Revert improperly removed code for Message Request footer. 2020-06-17 17:49:43 -03:00
Alan Evans
a6384d1b73 Add insecure call ability to recipient settings. 2020-06-17 17:49:43 -03:00
Alan Evans
2fb9514890 Respect emoji setting in profile/group name editing. 2020-06-17 17:49:43 -03:00
Alan Evans
fe89794505 Hide recipient subtitle if no name/username set. 2020-06-17 17:49:43 -03:00
Cody Henthorne
08800c9faf Make Message Details update views in more situations. 2020-06-17 17:49:43 -03:00
Cody Henthorne
469a4700d2 Fix improper tinting on screens when using FallbackPhoto. 2020-06-17 17:49:43 -03:00
Alan Evans
6707f974a5 Remove NewGroupUI FeatureFlag. 2020-06-17 17:49:43 -03:00
Alan Evans
c122cada2b Change call button shade. 2020-06-17 17:49:43 -03:00
Alan Evans
96f02d8c95 Hide some views for Note to Self conversation. 2020-06-17 17:49:43 -03:00
Greyson Parrelli
dd717b60b8 Bump version to 4.64.0 2020-06-16 23:47:15 -04:00
Greyson Parrelli
3c20c7f4b4 Updated language translations. 2020-06-16 23:46:41 -04:00
Cody Henthorne
1a09e70a04 Remove old Message Details. 2020-06-16 19:30:35 -04:00
Alan Evans
027453bbd2 Prevent IllegalStateException on recipient bottom sheet. 2020-06-16 19:30:35 -04:00
Greyson Parrelli
b621efa4a5 Don't prefetch views for the conversation list. 2020-06-16 19:30:35 -04:00
Cody Henthorne
2915e4698c Show registration rate limit error messaging. 2020-06-16 19:30:35 -04:00
Cody Henthorne
b687b1a4c5 Fix repeat alerts by using explicit reminder intent. 2020-06-16 19:30:35 -04:00
Alan Evans
b53827f32b Manage recipient activity. 2020-06-16 19:30:35 -04:00
Cody Henthorne
d9641128a8 Refresh Message Details screen. 2020-06-16 19:30:35 -04:00
Alan Evans
dfb5562142 Use group manager for MMS groups. 2020-06-16 19:30:35 -04:00
Jim Gustafson
d467c04749 Ensure speaker off at start of any call 2020-06-16 19:30:35 -04:00
Greyson Parrelli
3d7cffef2b Remove Message Requests feature flag. 2020-06-16 19:30:35 -04:00
Alex Hart
f2fe81d9b5 Fix conversation jumping when loading at last scroll position. 2020-06-16 19:30:35 -04:00
Greyson Parrelli
cf98a22269 Add placeholder support for ConversationListAdapter. 2020-06-16 19:30:35 -04:00
Alex Hart
49f75d7036 Migrate ConversationList to paging library and apply abstractions to conversation. 2020-06-16 19:30:35 -04:00
Greyson Parrelli
ce940235b0 Optimistically fetch profiles. 2020-06-16 19:30:35 -04:00
Alan Evans
f5626f678d Make CustomNotificationsDialogFragment work with recipients. 2020-06-16 19:30:35 -04:00
Alan Evans
b3a59c3946 Use recipient display name in recipient bottom sheet. 2020-06-16 19:30:35 -04:00
Fumiaki Yoshimatsu
93c390c4fc Don't send a read receipt when the recipient is blocked.
Fixes #9610
2020-06-16 19:30:35 -04:00
Cody Henthorne
941ab5a98f Prevent avatar from showing a start of outgoing video call. 2020-06-16 19:30:35 -04:00
Jim Gustafson
2ecdf803c0 Update to ringrtc v2.1.0 2020-06-16 19:30:35 -04:00
Cody Henthorne
5b2a399392 Return to previous scroll position when returning to a conversation. 2020-06-16 19:30:35 -04:00
Alex Hart
a9ea1d7606 Utilize DayNight theme when launching the app. 2020-06-12 11:36:15 -03:00
Greyson Parrelli
1ce8ac2de6 Light refactor of SignalStore. 2020-06-12 11:36:15 -03:00
Greyson Parrelli
e2019579fb Bump version to 4.63.3 2020-06-12 10:09:20 -04:00
Greyson Parrelli
fb3c6e56ee Updated language translations. 2020-06-12 10:08:51 -04:00
Greyson Parrelli
3fad007ae0 Cancel typing jobs when you send a group message. 2020-06-12 10:06:20 -04:00
Greyson Parrelli
8891b6c930 Properly throw UnregisteredUserException in SignalServicePipe. 2020-06-11 12:08:40 -04:00
Alan Evans
400c592acf Display 'Unknown group' for groups with no name. 2020-06-10 17:17:47 -03:00
Alex Hart
e13f3254ad Fix message jump-to-position. 2020-06-10 17:06:40 -03:00
Greyson Parrelli
bf40a07bb9 Bump version to 4.63.2 2020-06-10 14:43:24 -04:00
Greyson Parrelli
8f3a6b8479 Update unblock string. 2020-06-10 14:37:03 -04:00
Greyson Parrelli
7642b7cc72 Fix issue with typing indicators in blocked groups. 2020-06-10 14:28:12 -04:00
Greyson Parrelli
e12ea60d85 Bump version to 4.63.1 2020-06-10 12:48:15 -04:00
Greyson Parrelli
0b13c4aed6 Updated language translations. 2020-06-10 12:48:15 -04:00
Alan Evans
47919382e9 Show 'Add to another group' when launched from a group context. 2020-06-10 12:59:57 -03:00
Greyson Parrelli
d60d67ee7e Set contact colors more aggressively. 2020-06-10 10:49:22 -04:00
Alan Evans
559aa687a5 Show group participants menu item on a MMS group. 2020-06-10 11:32:50 -03:00
Cody Henthorne
bc0761f002 Fix navigate up behavior for Conversations. 2020-06-10 10:28:34 -04:00
Alan Evans
c0c2fc0eba When there are no recipients left on group create screen toast and return to list. 2020-06-10 09:07:12 -03:00
Alan Evans
44fe43c74c Hide 'Add to a group' for non-registered users. 2020-06-10 08:54:57 -03:00
Alan Evans
53a2a5d693 Prevent highlighter opacity affecting blur tool. 2020-06-09 23:56:03 -03:00
Greyson Parrelli
2334c26cbb Bump version to 4.63.0 2020-06-09 16:56:57 -04:00
Greyson Parrelli
0b6dde46d9 Updated language translations. 2020-06-09 16:55:50 -04:00
Greyson Parrelli
98d9d81aff Insert receipts in a transaction. 2020-06-09 15:11:37 -04:00
Greyson Parrelli
736a62b632 Update strings related to message requests. 2020-06-09 14:12:52 -04:00
Cody Henthorne
cea6a83d8a Show member count in contact selection list. 2020-06-09 13:32:48 -04:00
Greyson Parrelli
2751fd7efc Retrieve profiles in parallel. 2020-06-09 12:47:11 -04:00
Cody Henthorne
2822042eeb Show recent groups in Add to Groups screen. 2020-06-09 12:13:13 -04:00
Cody Henthorne
dc46d88ddd Provide two ways of listening for thread/message db updates. 2020-06-09 11:52:58 -04:00
Alex Hart
e04f76b558 Fix issue where invalid PagedList objects were passed to ConversationAdapter. 2020-06-09 12:37:19 -03:00
Alan Evans
a758056494 Take highlighter down from 50% to 37.5% opacity. 2020-06-09 12:35:53 -03:00
Alan Evans
1ecdea5db3 Reinstate highlighter under drawing menu. 2020-06-09 12:10:40 -03:00
Alan Evans
e1bb773d85 Add 'Add to a group' button to bottom sheet. 2020-06-09 12:09:59 -03:00
Alan Evans
7e934eff5d Make quotes not hold strong references to attachments. 2020-06-09 12:07:41 -03:00
Greyson Parrelli
cfdf5603af Bump version to 4.62.4 2020-06-09 00:39:55 -04:00
Greyson Parrelli
45bfb8c6b6 Updated language translations. 2020-06-09 00:38:19 -04:00
Alex Hart
65608a51b8 Fix API 19 crash by using different resource. 2020-06-09 00:33:38 -04:00
Greyson Parrelli
b6314597fe Bump version to 4.62.3 2020-06-08 16:32:08 -04:00
Greyson Parrelli
20a588199a Updated language translations. 2020-06-08 16:32:00 -04:00
Greyson Parrelli
59916f1e95 Add 'Add to contacts' button to bottom sheet. 2020-06-08 16:07:14 -04:00
Alan Evans
8b91f8f9e7 Disable disappearing messages option and remove from menu. 2020-06-08 12:31:55 -03:00
Alex Hart
cbc3cce66f Fix API 19 drawable crash in ManageGroupFragment. 2020-06-08 11:34:39 -03:00
Alex Hart
b4b63b5860 Add auto-mirroring to ic_forward_outline. 2020-06-08 10:23:43 -03:00
Alex Hart
b9ae15a890 Fix group name RTL alignment. 2020-06-08 10:21:55 -03:00
Greyson Parrelli
d955389c46 Bump version to 4.62.2 2020-06-07 22:05:02 -04:00
Greyson Parrelli
975eb885c1 Updated language translations. 2020-06-07 22:05:02 -04:00
Alan Evans
a3aed96757 Sort contacts without names after contacts with names. 2020-06-07 22:05:02 -04:00
Alan Evans
dc70bfabaf Lighter ultramarine + in dark mode. 2020-06-07 22:05:02 -04:00
Greyson Parrelli
6932340671 Add ability to copy a number via long-press. 2020-06-07 19:59:42 -04:00
Alan Evans
f6637b7caf Restore mute in conversation menu. 2020-06-07 19:59:42 -04:00
Alan Evans
4f4be44caa Load identities in transaction. 2020-06-07 19:59:42 -04:00
Greyson Parrelli
7832497ba7 Shorten logging in ConversationActivity. 2020-06-07 19:59:42 -04:00
Alex Hart
7d06e2395f Rework how ConversationFragment RecyclerView responds to data updates. 2020-06-07 19:59:42 -04:00
Greyson Parrelli
3a479d7eef Reduce database notifications for disappearing conversations. 2020-06-07 19:59:42 -04:00
Greyson Parrelli
8fe8a1e9ee Put refresh and upload profile jobs in the same queue. 2020-06-07 19:59:42 -04:00
Alan Evans
2d8b2e7fb0 Transitions for group settings. 2020-06-07 19:59:42 -04:00
Alan Evans
9c0365f92c Open group settings from group avatar click. 2020-06-07 19:59:42 -04:00
Greyson Parrelli
b48abb08d2 Show custom notifications for API < 26. 2020-06-07 19:59:42 -04:00
Alan Evans
d8f3e032c7 Fix group name clearing after avatar change. 2020-06-07 19:59:42 -04:00
Alan Evans
8dbcb255ad Hide Block and Leave options when not available in group settings, add unblock. 2020-06-07 19:59:42 -04:00
Greyson Parrelli
db06cbbc86 Remove unnecessary recipient refreshes. 2020-06-07 19:59:42 -04:00
Cody Henthorne
98ab23c1a3 Make Custom Notification dialog dismiss itself on up press. 2020-06-07 10:23:41 -04:00
Cody Henthorne
d0ca9ba6a6 Make text button color responsive to theme. 2020-06-07 09:43:14 -04:00
Alan Evans
b242368675 Remove group members button. 2020-06-07 09:31:18 -03:00
Alan Evans
664527ce63 Fix sort order for group members. 2020-06-07 08:25:31 -03:00
Alan Evans
99e4f80be0 Allow whole row selection for Shared media in group settings. 2020-06-07 08:12:25 -03:00
Alan Evans
702dae9fcd Fix double tap required for "See all" media in group settings. 2020-06-07 07:47:28 -03:00
Alan Evans
48fe1ba559 Fix group settings divider shade in dark mode. 2020-06-07 07:42:28 -03:00
Greyson Parrelli
382ac7ba0d Bump version to 4.62.1 2020-06-06 20:28:18 -04:00
Greyson Parrelli
a46f47f352 Updated language translations. 2020-06-06 20:27:48 -04:00
Greyson Parrelli
e984d8a42c Change Gif -> GIF. 2020-06-06 20:27:22 -04:00
Greyson Parrelli
554bad6b8d Improve DB access in group sends. 2020-06-06 20:25:02 -04:00
Jim Gustafson
ed13c97ad7 Handle legacy hangup properly. 2020-06-06 20:25:02 -04:00
Greyson Parrelli
d33873d59a Fix possible crash with null thread body. 2020-06-06 20:25:02 -04:00
Greyson Parrelli
1234899ea1 Add support for non-blocking media sends. 2020-06-06 20:25:02 -04:00
Cody Henthorne
13027dc44b Fix leaking MessageDetailsActivity via list items. 2020-06-06 20:25:02 -04:00
Cody Henthorne
5b4d74b7fe Move group resolution for conversations to background LiveData. 2020-06-06 20:25:02 -04:00
Alan Evans
18c7bc2b5b Prevent edit of a group post leave. 2020-06-06 20:25:02 -04:00
Alan Evans
bbbee0f372 Fix group create arrow for RTL. 2020-06-06 20:25:02 -04:00
Alex Hart
cf9d090154 Start Paging @ Unread count instead of -1. 2020-06-06 20:25:02 -04:00
Alan Evans
718471917f Separate text only message layouts. 2020-06-06 20:25:02 -04:00
Greyson Parrelli
bb97407cde Bump version to 4.62.0 2020-06-05 22:04:18 -04:00
Greyson Parrelli
92ce678e29 Updated language translations. 2020-06-05 22:04:16 -04:00
Cody Henthorne
e100aea2c7 Preserve scroll position in Message Details on update. 2020-06-05 21:46:04 -04:00
Greyson Parrelli
fea3b6cb4a Don't show 'conversation settings' for groups. 2020-06-05 21:46:04 -04:00
Cody Henthorne
afbc132faa Fix conversation item and data source memory leaks. 2020-06-05 21:46:04 -04:00
Alan Evans
b27198286d MMS proof new group UI. 2020-06-05 21:46:04 -04:00
Greyson Parrelli
ac93d81032 Remove pins4all feature flag. 2020-06-05 21:46:04 -04:00
Alan Evans
9981e5ca76 Enable new group UI. 2020-06-05 20:19:03 -03:00
Cody Henthorne
7dd3efeb53 Remove listeners when detaching conversation item views. 2020-06-05 19:29:55 -03:00
Greyson Parrelli
d38d702adf Parallelize group sends. 2020-06-05 18:10:50 -04:00
Alex Hart
04a000a8a8 Always display labels in contact search. 2020-06-05 15:16:55 -03:00
Fumiaki Yoshimatsu
3bbf0741ee Use localized string for Phone number.
Fixes #9626
2020-06-05 15:01:20 -03:00
Fumiaki Yoshimatsu
e9a336100b Display backup date in users locale on restore.
Fixes #9693
2020-06-05 15:01:20 -03:00
Cody Henthorne
fb600e9829 Update SMS/MMS as sending when retrying failed send.
This was only impacting SMS/MMS as Push already reset the status.
2020-06-05 13:46:25 -04:00
Alex Hart
4a455ff958 Implement new Add Members UI. 2020-06-05 13:44:02 -03:00
Cody Henthorne
707e238e5c Make borderless button style responsive to theme. 2020-06-05 12:01:00 -04:00
Alan Evans
90f22a4b66 Include face position and projection matrix into elements matrix. 2020-06-04 19:49:22 -03:00
Alex Hart
b4f134adf7 Add more descriptive messages for media notifications and chat previews. 2020-06-04 13:13:42 -03:00
Greyson Parrelli
1e00fc6149 Bump version to 4.61.6 2020-06-04 10:21:23 -04:00
Greyson Parrelli
f52133a69c Updated language translations. 2020-06-04 10:21:23 -04:00
Alan Evans
91b142e0d9 Fix waveform array out of bounds. 2020-06-04 10:21:10 -04:00
Greyson Parrelli
26a9dd98c1 Bump version to 4.61.5 2020-06-03 19:01:03 -04:00
Greyson Parrelli
99e38e1d23 Updated language translations. 2020-06-03 18:58:34 -04:00
Greyson Parrelli
a2d8a25fd9 Blur UI tweaks. 2020-06-03 18:51:38 -04:00
Alan Evans
d86d625bcc Smoother blur rendering. 2020-06-03 19:47:51 -03:00
Greyson Parrelli
18e3fb6609 Fix string format. 2020-06-03 17:19:32 -04:00
Greyson Parrelli
da33ba0ed5 Update blur UI. 2020-06-03 17:12:47 -04:00
Greyson Parrelli
66f021d01a Fix issue where rail wasn't showing in some situations. 2020-06-03 17:12:47 -04:00
Greyson Parrelli
40231ea45f Fix issue with view-once toggle and face blurring. 2020-06-03 17:12:42 -04:00
Alex Hart
cd80a47c04 Made edit profile save button move with the keyboard. 2020-06-03 17:12:27 -04:00
Alan Evans
1033bd7bda Blur faces rotation and crop and zoom support. 2020-06-03 14:02:24 -03:00
Greyson Parrelli
b4f60f3acb Bump version to 4.61.4 2020-06-03 06:40:09 -04:00
Greyson Parrelli
bed3b571cc Updated language translations. 2020-06-03 06:39:34 -04:00
Greyson Parrelli
c8dd4e5254 Added support for blurring faces.
Co-authored-by: Alan Evans <alan@signal.org>
2020-06-03 06:39:20 -04:00
Alan Evans
514048171b Add Image Editor support for blur mask layer. 2020-06-03 03:33:06 -03:00
Greyson Parrelli
32e9901592 Bump version to 4.61.3 2020-06-02 19:22:22 -04:00
Greyson Parrelli
d83f86a469 Revert "Make notifications and chat previews for media messages more descriptive."
This reverts commit a3f9737e63.
2020-06-02 19:19:30 -04:00
Greyson Parrelli
403d53586c Bump version to 4.61.2 2020-06-02 17:40:56 -04:00
Greyson Parrelli
6acae58694 Updated language translations. 2020-06-02 17:33:41 -04:00
Alex Hart
a3f9737e63 Make notifications and chat previews for media messages more descriptive. 2020-06-02 17:34:50 -03:00
Cody Henthorne
263af7c139 Add registration lock status to support email. 2020-06-02 16:14:19 -04:00
Alex Hart
7f2439f1e9 Fix contact selection behavior when searching and clear search on selection. 2020-06-02 16:27:04 -03:00
Alex Hart
ae87d23003 Always use the new group settings screen if the flag is enabled. 2020-06-02 16:09:48 -03:00
Alex Hart
3192cc0aac Add outlined view-once close icon. 2020-06-02 16:05:16 -03:00
Alex Hart
6102e9aa72 Apply better coordinatorlayout animation and RTL support. 2020-06-02 15:02:35 -03:00
Alan Evans
f4a152b0fe Fetch own profile after GV2 feature flag is enabled, improve GV2 capability check. 2020-06-02 11:48:40 -03:00
Greyson Parrelli
2b11bca7dc Guard against possible invalid conversation data loads. 2020-06-02 10:20:55 -04:00
Artem Varaksa
07d19f38e3 Fix typos in logging for remote delete. 2020-06-02 10:22:29 -03:00
Greyson Parrelli
cd228c439e Be more explicit with the ID we use for account updates. 2020-06-02 09:03:54 -04:00
Alan Evans
7a859c8961 For smaller width devices, use original 210dp for audio messages. 2020-06-02 09:32:59 -03:00
Alan Evans
543f38c75d Fix Wave form IOException thread issue. 2020-06-02 07:38:15 -03:00
Greyson Parrelli
f7b150f2d2 Bump version to 4.61.1 2020-06-01 17:43:05 -04:00
Greyson Parrelli
11328f643f Updated language translations. 2020-06-01 17:43:05 -04:00
Greyson Parrelli
f270a6b8c4 Fix potential crash by removing an unnecessary column.
The column I removed is already in the recipient half of the projection.
Having two representations of the groupId made reading the groupId out
of the cursor non-deterministic, and when compounded with another bug,
could cause a crash if one of them was null.
2020-06-01 17:43:05 -04:00
Alan Evans
3fec23fd36 Show remaining time on wave form view and cache wave form in database. 2020-06-01 17:43:05 -04:00
Alex Hart
e01838e996 Fix text size for pending members. 2020-06-01 17:43:05 -04:00
Greyson Parrelli
f70e41e7cd Don't allow account record updates to delete our profile key. 2020-06-01 17:43:05 -04:00
Greyson Parrelli
c4ec0c9897 Handle devices disallowing start of FcmFetchService.
Some devices are overzealous with battery management and disallow
starting services even when they're in response to a high-priority FCM
message (which should be allowed). So in these situations, we just
fall back to what we were doing before.
2020-06-01 17:43:05 -04:00
Greyson Parrelli
989b071a6d Ignore contacts that don't have a phone number. 2020-06-01 17:43:05 -04:00
Greyson Parrelli
c39751f9db Add info about play services to the debug log. 2020-06-01 17:43:05 -04:00
jimio-signal
dbf74a2234 Update copyright in README.md 2020-05-31 10:39:19 -07:00
Greyson Parrelli
837230d72d Bump version to 4.61.0 2020-05-29 19:18:55 -04:00
Greyson Parrelli
f544ec4126 Updated language translations. 2020-05-29 19:18:02 -04:00
Greyson Parrelli
79dbf85c1e Improve local encrypted PIN storage. 2020-05-29 19:15:56 -04:00
Greyson Parrelli
61fe6cc961 Enable the ability to react with any emoji. 2020-05-29 19:14:37 -04:00
Greyson Parrelli
70c88b68e2 Store recent reactions separately from keyboard emoji. 2020-05-29 19:14:37 -04:00
Greyson Parrelli
d70c33d20f Add support for mark as unread. 2020-05-29 19:14:37 -04:00
Greyson Parrelli
6b2e000e61 Prevent waiting for old queues in our retrieval strategies. 2020-05-29 19:14:37 -04:00
Alan Evans
b9f11dafff New internal testing flag and V1 group creation button. All menus create GV1. 2020-05-29 19:14:37 -04:00
Alan Evans
9b32eaeb8a Do not log URLs. 2020-05-29 19:14:37 -04:00
Alan Evans
a99c0d438e Rename GV2 "version" to "revision". 2020-05-29 19:14:37 -04:00
Alex Hart
c634c24afb Utilize Wrapper instead of dynamic theme. 2020-05-29 19:14:37 -04:00
Alex Hart
2ddd1437cf Utilize exclusive AudioFocus. 2020-05-29 19:14:37 -04:00
Alan Evans
9da309ca48 Enforce a local GV2 capacity limit driven by a feature flag. 2020-05-29 19:14:37 -04:00
henry
cfcd451db7 Fix crash on unlink device when offline. 2020-05-29 09:51:21 -04:00
Alex Hart
5ab72fd1a9 Ask for permission before launching avatar sheet. 2020-05-29 09:51:21 -04:00
Alan Evans
daace9bd1a Audio wave forms on voice notes. 2020-05-29 09:51:21 -04:00
Alan Evans
69adcd1d69 Tap avatar in chat preferences or group management to see full screen. 2020-05-29 09:51:21 -04:00
Alex Hart
0711a22188 Add overflow toast and fix edit menu option. 2020-05-29 09:51:21 -04:00
Greyson Parrelli
3a06412cd8 Throttle notifications when doing the intial message fetch. 2020-05-29 09:51:21 -04:00
Alan Evans
51c82702e2 Remove expectation of ActionBar in DeviceProvisioningActivity.
Fixes #9661
2020-05-29 09:51:21 -04:00
Greyson Parrelli
1b01196ec6 Refactor ThreadRecord. 2020-05-29 09:51:21 -04:00
Greyson Parrelli
1cd6b58ece Don't enqueue duplicate PushDecryptMessageJobs. 2020-05-29 09:51:21 -04:00
Greyson Parrelli
ea8e13b1c8 Create a WebsocketDrainedConstraint. 2020-05-29 09:51:21 -04:00
Greyson Parrelli
f392229393 Extract MessageNotifier interface. 2020-05-29 09:51:21 -04:00
Greyson Parrelli
a299bafe89 Create a new system for fetching the intial batch of messages. 2020-05-29 09:51:21 -04:00
Alex Hart
d2bf539504 Clear sticky WebRtcViewModel events when initiating a new call. 2020-05-29 09:51:21 -04:00
Alex Hart
903c3989b9 Fix chip jank and other groups v2 ux issues. 2020-05-29 09:51:21 -04:00
Alan Evans
00996f0d7a Rename back to build.gradle 2020-05-29 09:51:21 -04:00
Alan Evans
4aded3a436 Close keyboard on contact list scroll. 2020-05-29 09:51:20 -04:00
Alan Evans
9acdc37729 Alphabetical member order. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
d4cdcbe54f Improve logging around group sends. 2020-05-29 09:51:20 -04:00
Alex Hart
6fa2a0f411 Polish UX for groups v2 management. 2020-05-29 09:51:20 -04:00
Alex Hart
558a8e4a14 Add polish to groups v2 creation flow. 2020-05-29 09:51:20 -04:00
Alan Evans
8947b82034 Make GV2 feature flags remote capable. 2020-05-29 09:51:20 -04:00
Alan Evans
56551025e9 Detect if group v2 is active from membership. 2020-05-29 09:51:20 -04:00
Alan Evans
befb4939d5 Restore groups from storage service. 2020-05-29 09:51:20 -04:00
Alan Evans
289f7aba63 Add versioned profiles feature flag. 2020-05-29 09:51:20 -04:00
Alan Evans
28bd245b96 While testing GV2 without UUID, fail jobs that hit UuidRecipientError. 2020-05-29 09:51:20 -04:00
Alan Evans
c5e7300df2 Fix matches logic in contact selection. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
fe25d941bb Prevent FCM bottlenecking. 2020-05-29 09:51:20 -04:00
Alan Evans
4cda267f3b Show pending count and allow view of zero pending screen. 2020-05-29 09:51:20 -04:00
Alex Hart
82ba7e2b8b Display "You" at end of members list in ConversationTitleView. 2020-05-29 09:51:20 -04:00
Alex Hart
41ebaf3938 Clean up Overflow menu for GV2 groups. 2020-05-29 09:51:20 -04:00
Alex Hart
090c400037 Collapse title into toolbar on scroll in ManageGroupFragment. 2020-05-29 09:51:20 -04:00
Alan Evans
12b1232ac0 Fix groups v2 patch response handler. 2020-05-29 09:51:20 -04:00
Alex Hart
204a84c522 Apply proper spacing to RecipientBottomSheetDialogFragment. 2020-05-29 09:51:20 -04:00
Alan Evans
526afd539b Fix avatar tap in conversation multi-select mode. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
d708984abd Require users be a system contact or whitelisted to appear in the contact list. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
9d39db6428 Add additional account restore logging, prevent double avatar fetch. 2020-05-29 09:51:20 -04:00
Alan Evans
67a8ec0d39 Only admin can cancel any invite. 2020-05-29 09:51:20 -04:00
Alan Evans
297a7d0ef8 Handle absent change during invite. 2020-05-29 09:51:20 -04:00
Bastian Köcher
4712833853 Always convert HEIC images to JPEG.
This pr changes the behavior of sending HEIC images to always convert
them to JPEG. This conversion is required to support image inline
viewing accross different devices and operating systems. This follows
the same strategy as on IOS: https://github.com/signalapp/Signal-iOS/pull/2511

Fixes: https://github.com/signalapp/Signal-iOS/issues/4374 & https://github.com/signalapp/Signal-Android/issues/9395
2020-05-29 09:51:20 -04:00
Alan Evans
11d17f7496 GV2 storage service syncing. 2020-05-29 09:51:20 -04:00
Alan Evans
36df3f234f Enable the Zk group library. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
098b298646 Add a network constraint to RemoteConfigRefreshJob. 2020-05-29 09:51:20 -04:00
Alan Evans
2f9320989a Server signed group v2 changes sent and received P2P. 2020-05-29 09:51:20 -04:00
Alan Evans
ec8d5defd4 Protect against unknown GV2 UUIDs. 2020-05-29 09:51:20 -04:00
Greyson Parrelli
981676c7f8 Bump version to 4.60.9 2020-05-29 09:40:26 -04:00
Greyson Parrelli
7c5ae57784 Updated language translations. 2020-05-29 09:38:57 -04:00
Alex Hart
fc7be87468 Downgrade AudioManagerCompat errors to warnings. 2020-05-29 10:31:36 -03:00
Greyson Parrelli
e55d8007fc Bump version to 4.60.8 2020-05-28 18:34:06 -04:00
Greyson Parrelli
43b7aa2d52 Updated language translations. 2020-05-28 18:33:46 -04:00
Alex Hart
cd1bad0718 Fix bluetooth behavior. 2020-05-28 17:36:40 -03:00
Greyson Parrelli
6b47618351 Bump version to 4.60.7 2020-05-26 18:27:05 -04:00
Greyson Parrelli
b6d384120d Updated language translations. 2020-05-26 18:26:39 -04:00
Greyson Parrelli
1268b26c1f Auto-dismiss PIN reminder dialog as you type. 2020-05-26 18:13:19 -04:00
Greyson Parrelli
f1233bfddc Bump version to 4.60.6 2020-05-25 14:57:59 -04:00
Greyson Parrelli
1aa3e6afea Updated language translations. 2020-05-25 14:57:59 -04:00
Greyson Parrelli
ce21eb241a Fix potential crash with data size in ConversationDataSource. 2020-05-25 14:57:59 -04:00
Greyson Parrelli
f96fb72eb1 Don't show PIN reminders if you're not registered.
Fixes #9657
2020-05-25 13:14:38 -04:00
Greyson Parrelli
207c467c6b Don't insert identity verification message for the initial restore. 2020-05-24 13:00:16 -04:00
Alex Hart
9d1d9e33ed Bumped version to 4.60.5 2020-05-21 20:03:31 -03:00
Alex Hart
e4a76c0690 Updated language translations. 2020-05-21 20:03:31 -03:00
Alex Hart
124c3e25e9 Implement layout changes to new call screen UX. 2020-05-21 20:03:31 -03:00
Greyson Parrelli
5cb1201903 Add the ability to disable PIN reminders. 2020-05-21 19:56:30 -03:00
Greyson Parrelli
bb6ca80d5a Don't create identity change methods for brand new contacts. 2020-05-21 19:56:30 -03:00
Greyson Parrelli
dc7c54a1f8 Ensure we upload the profile after a PIN restore. 2020-05-21 19:56:30 -03:00
Greyson Parrelli
23401440bf Prevent insertion of UUID-only contacts at the database level. 2020-05-21 19:56:30 -03:00
Greyson Parrelli
f8f959e05a Make rate limit message more generic. 2020-05-20 14:22:33 -04:00
Alex Hart
edbd4d2d03 Properly set profile key update flag. 2020-05-20 12:15:54 -03:00
Greyson Parrelli
a0b4065be3 Fix potention OOB error when pulse-highlighting a message.
This basically happened if you used full-text search to search for the
latest message in a conversation, but when you navigated there, it
*also* had a header set (like a typing indicator or unknownSenderView).
2020-05-19 17:09:25 -04:00
Greyson Parrelli
1b2f964f32 Fix possible crash around loading initial conversation pages. 2020-05-19 16:20:20 -04:00
Alex Hart
eaf5280d99 Bumped version to 4.60.4 2020-05-19 16:51:33 -03:00
Alex Hart
d435da980f Updated language translations. 2020-05-19 16:51:33 -03:00
Greyson Parrelli
8d3a91f3a4 Fix possible data source invalidation loop. 2020-05-19 16:51:33 -03:00
Greyson Parrelli
b80c339c5a Fix an issue where the add profile prompt wasn't dismissed. 2020-05-19 16:51:33 -03:00
Alan Evans
34159fc9da Log successful pin setting. 2020-05-19 16:34:52 -03:00
Alex Hart
b509ee9ee0 Bumped version to 4.60.3 2020-05-18 17:03:45 -03:00
Alex Hart
a6819448b9 fixup! Consolidate Call UI visibility selection logic. 2020-05-18 16:43:30 -03:00
Alex Hart
f2847f9aa5 Bumped version to 4.60.2 2020-05-18 16:31:20 -03:00
Alex Hart
8f01e5e1c3 Updated language translations. 2020-05-18 16:31:20 -03:00
Alan Evans
acb2f43620 Make Manage Group menu item replace Edit Group for GV2. 2020-05-18 16:31:20 -03:00
Greyson Parrelli
62ac65e4d8 Improve paging performance on slower devices. 2020-05-18 16:31:20 -03:00
Alex Hart
8f183bdcdc Consolidate Call UI visibility selection logic. 2020-05-18 16:31:20 -03:00
Greyson Parrelli
3d135d155e Disable view prefetching for now. 2020-05-18 16:31:20 -03:00
Alan Evans
090c811391 Force app compat version 1.1.0-beta01. 2020-05-18 16:31:20 -03:00
Alex Hart
2a9e8dc525 Bumped version to 4.60.1 2020-05-15 19:02:18 -03:00
Alex Hart
cb0b22cf2c Updated language translations. 2020-05-15 19:02:18 -03:00
Alex Hart
5aba3517ce Upgrade to RingRTC 2.0.3 and implement rounded corners for local pip. 2020-05-15 19:02:18 -03:00
Alex Hart
726f665388 Upgrade AppCompat to 1.2.0-rc01. 2020-05-15 19:02:18 -03:00
Alex Hart
e2ac55e9ac Fix ellapsed call timer restarting between activity restarts. 2020-05-15 19:02:18 -03:00
Greyson Parrelli
fa5729bac6 Better handle identity key changes in response to storage service syncs. 2020-05-15 19:02:18 -03:00
Greyson Parrelli
e714cb6423 Fix potential issues with ConversationDataSource boundaries. 2020-05-15 19:02:18 -03:00
Alex Hart
35a0162d5c Utilize EmojiTextView instead of TextView. 2020-05-15 19:02:18 -03:00
Alex Hart
76740adc3f Fix controls are removed when remote video is disabled. 2020-05-15 13:05:00 -03:00
Alex Hart
1c814141a2 Fix NullPointerException when trying to launch InviteActivity. 2020-05-15 10:43:25 -03:00
Alan Evans
5545daf992 Live group membership count in conversation. 2020-05-15 10:28:48 -03:00
Alan Evans
d300615d90 Ensure new group UI behind feature flag. 2020-05-15 10:27:39 -03:00
Alex Hart
908a5260c2 Enable note to self as recipient in share activity. 2020-05-15 10:03:49 -03:00
Alex Hart
7aac6644c3 Expand tappable area in header. 2020-05-14 16:27:52 -03:00
Alan Evans
3b673c07a0 Support gv2 avatar removal. 2020-05-14 15:57:40 -03:00
Alan Evans
d726da822c Add network constraint to GV2 messages. 2020-05-14 15:23:15 -03:00
Alex Hart
7894f72b0f Enable speaker when initiating a video call. 2020-05-14 14:18:49 -03:00
Alan Evans
4c5822ac67 GV2 Update message description. 2020-05-14 13:59:34 -03:00
Alex Hart
b917cccbee Bumped version to 4.60.0 2020-05-14 11:22:28 -03:00
Alex Hart
01d2d05d8e Updated language translations. 2020-05-14 11:22:28 -03:00
Alan Evans
4de86cb6cf Prevent ZkGroup link crashes. 2020-05-14 11:22:28 -03:00
henry
8861ad76ed Fix start SubmitDebugLog from registration and passphrase prompt. 2020-05-14 11:22:28 -03:00
Alan Evans
ef86372635 Ensure that the unknown UUID does not create an entry. 2020-05-14 11:22:28 -03:00
Alex Hart
ccff7b1148 Implement new group creation screens behind flag. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
ed0825112d Fix some ordering problems with conversation data loading. 2020-05-14 11:22:28 -03:00
Alan Evans
b8df90531f GV2 message contexts. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
f099c3591c Run PushProcessMessageJobs in parallel. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
ed33e048ad Add CachedLayoutInflater to improve conversation render performance. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
7fd3bfa30c Revert "Check to see if FCM is available at app launch."
This reverts commit eea7174f1d.
2020-05-14 11:22:28 -03:00
Alex Hart
07a492a32c Add dot character to reactions bottom sheet all tab label. 2020-05-14 11:22:28 -03:00
Alan Evans
11fffbd79e Remove P2P group change sending. 2020-05-14 11:22:28 -03:00
Alan Evans
eff564ad88 Adapt message requests to support invite flow. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
d3d53e6099 Reduce recipient dirty state logging verbosity. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
53d122ed55 Fix jumping to last seen position. 2020-05-14 11:22:28 -03:00
Alan Evans
1778c1ef7d Prevent some IOExceptions when past the end of stream. 2020-05-14 11:22:28 -03:00
Alan Evans
a510bc74e6 Recipient Id cache. 2020-05-14 11:22:28 -03:00
Alan Evans
a9ecdbdfec Groups V2 capability set by the feature flag. 2020-05-14 11:22:28 -03:00
Alan Evans
06ab3cf013 Fix cases of inlined & missing log tags. 2020-05-14 11:22:28 -03:00
Alan Evans
3db5da1c8d Generalize media input for use with Audio. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
5937a50b6d Fix message receive timestamps on media messages. 2020-05-14 11:22:28 -03:00
Alan Evans
b4191ee5cc Fix usages of service logging in app. 2020-05-14 11:22:28 -03:00
Alan Evans
c63e42715e New logging lint checks.
[LogNotAppSignal] tells you about using signal service logger in the app.
[LogTagInlined] tells you about not using a constant tag.
2020-05-14 11:22:28 -03:00
Alex Hart
26e582d806 Integrate RingRTC v2.0.1 2020-05-14 11:22:28 -03:00
Alan Evans
ee9270845a Create GV2 group behind feature flag. 2020-05-14 11:22:28 -03:00
Alan Evans
6cf33897c0 Remove superfluous groups v2 capability checks. 2020-05-14 11:22:28 -03:00
Freddy Tuxworth
2161bbb8fa Display "No matching countries" when no filter matches found.
Fixes #9518
2020-05-14 11:22:28 -03:00
Greyson Parrelli
b75088874e Migrate conversation rendering to the paging library. 2020-05-14 11:22:28 -03:00
Alan Evans
9ac1897880 Job changes for GroupsV2 message receive and profile key updates. 2020-05-14 11:22:28 -03:00
Alan Evans
36c43ed2fa Ensure latest V2 group state from server upon conversation open. 2020-05-14 11:22:28 -03:00
Alan Evans
8084822f16 Connect GV2 title and avatar updates and prevent no-change avatar updates. 2020-05-14 11:22:28 -03:00
Alan Evans
959718618f Deprecate some ViewUtil methods. Inline others. Remove some old API code. 2020-05-14 11:22:28 -03:00
Alan Evans
75f3fe0cec Correct access control for MMS groups. 2020-05-14 11:22:28 -03:00
Alan Evans
b800477365 GV2 leave and eject operations. 2020-05-14 11:22:28 -03:00
Alex Hart
b191341c57 Add some polish to the groups V2 manager UI. 2020-05-14 11:22:28 -03:00
leet
88a40be901 Fix backup timestamp language.
Fixes #8842
Fixes #8986
2020-05-14 11:22:28 -03:00
Greyson Parrelli
3fef58057e Add additional info to support emails and debuglogs. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
b156e4a79a Always use the UD cert with a UUID. 2020-05-14 11:22:28 -03:00
Alan Evans
30ac264cd3 Rename Group update message classes. 2020-05-14 11:22:28 -03:00
Alan Evans
a9b00e1cd3 Remove instances of Android logging. 2020-05-14 11:22:28 -03:00
Alex Hart
d94fc4bc13 Implement ability to react with any emoji behind a flag. 2020-05-14 11:22:28 -03:00
Greyson Parrelli
40b5339ef8 Allow auto-download for users you've shared your profile with. 2020-05-14 11:22:28 -03:00
Alan Evans
86f0456e8c Group Manager V2 operations. 2020-05-14 11:22:28 -03:00
Alan Evans
48a693793f GV2 Group Manager. 2020-05-14 11:22:28 -03:00
Alan Evans
ff28d72db6 New GV2 internal prefix and scrubber. 2020-05-13 16:18:18 -04:00
Alan Evans
456857bbbd Add custom lint rule project. 2020-05-13 16:18:18 -04:00
Alan Evans
7f17b66a6c Upgrade gradle and gradle plugin. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
310ec8f296 Remove CellServiceConstraint in favor of NetworkOrCellServiceConstraint.
If a job was enqueued with a CellServiceConstraint (which is currently
only SMS jobs), then it'll never run until it gets service, even if you
flip the "enable SMS sending over wifi" toggle.

This has created bad situations in the past, where SMS jobs just get
stuck on devices that never report having cell service (like VM's or
wifi only devices).

This fixes it by *always* using NetworkOrCellServiceConstraint, and then
deciding whether a constraint is met by checking the "wifi SMS" setting
at decision-time.
2020-05-13 16:18:18 -04:00
Alan Evans
0c2afa9438 Fix FCM token via phone call registration.
Fixes #8992
2020-05-13 16:18:18 -04:00
Alex Hart
c3832cf8b1 New group notifications management ui. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
a2de8a2a05 Ensure you can't set null values in DefaultValueLiveData. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
3b601896d2 Fix crash in SubmitDebugLogActivity. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
e1a90bcb00 Transition conversation loading from a Loader to a Repository. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
2b65916344 Show calling foreground notification on all OS versions.
Fixes #9516
Fixes #9414
2020-05-13 16:18:18 -04:00
Greyson Parrelli
f149005026 Add support for remote config v1.1 2020-05-13 16:18:18 -04:00
Alex Hart
5eb663aa1b New group avatar and name selection screen. 2020-05-13 16:18:18 -04:00
Alan Evans
12b7d6c0e3 Use bottom sheet shape. 2020-05-13 16:18:18 -04:00
Alan Evans
723639d928 New group management screen. 2020-05-13 16:18:18 -04:00
Greyson Parrelli
e0502c24e1 Only search for visible parts of a contact. 2020-05-13 16:18:18 -04:00
Alex Hart
358d6333c3 Open new recipient bottom sheet when accessing contact from group context. 2020-05-13 16:18:18 -04:00
Alan Evans
0b279d1df3 Group contact chips behind feature flag. 2020-05-13 16:18:18 -04:00
Alan Evans
8e0fba7992 New group button behind new Group UI feature flag. 2020-05-13 16:18:18 -04:00
Alex Hart
d5419ec9fa Implement new call screen UI/UX. 2020-05-13 16:18:18 -04:00
Alan Evans
33e3f78be6 LiveDataUtil combineLatest. 2020-05-13 16:17:29 -04:00
Alex Hart
3c5ad519dd Decrease QuoteView reveal animation duration to 150ms. 2020-05-13 16:17:29 -04:00
Alan Evans
17c5b858b5 Recipient bottom sheet. 2020-05-13 16:17:29 -04:00
Greyson Parrelli
f6f6496c9c Bump version to 4.59.10 2020-05-13 15:40:44 -04:00
Greyson Parrelli
b1d725e23a Updated language translations. 2020-05-13 15:40:44 -04:00
Greyson Parrelli
a74622997e Bump libsignal-metadata to 0.1.2
Includes fix for how we're prioritizing UUID vs E164.

Fixes #9621
2020-05-13 15:40:42 -04:00
Greyson Parrelli
b1a200001e Bump version to 4.59.9 2020-05-09 13:19:57 -04:00
Greyson Parrelli
3b1041fa1f Updated language translations. 2020-05-09 13:19:31 -04:00
Greyson Parrelli
a83ccc18bb Fix processing of early messages.
1. Eliminated any possibility of infinite recursion.
2. Handle the fact that you can have multiple 'early contents' for a
   single message.
2020-05-09 13:16:45 -04:00
Greyson Parrelli
618b1b5ace Handle PIN creation failure better. 2020-05-09 13:16:45 -04:00
Greyson Parrelli
14858adc88 Bump version to 4.59.8 2020-05-04 18:22:45 -04:00
Greyson Parrelli
c07f35f3aa Updated language translations. 2020-05-04 18:21:50 -04:00
Alan Evans
87eab27996 Prevent the creation of 'weak' PINs.
Simple checks to prevent the same number, or sequentially
increasing/decreasing PINs. e.g. 1111, 1234, 54321, etc.
2020-05-04 18:17:36 -04:00
Greyson Parrelli
b7296a4fe3 Bump version to 4.59.7 2020-05-04 11:06:28 -04:00
Greyson Parrelli
3fb9ae1fb4 Updated language translations. 2020-05-04 11:05:55 -04:00
Greyson Parrelli
9705939489 Fix issue with editing and forwarding a received video. 2020-05-04 10:54:55 -04:00
Greyson Parrelli
eca67b1204 Broaden exception handling in custom DNS.
A set of LG devices is crashing when using the custom DNS. Safest thing
for now would be to treat all failures as network errors while we we try
to get a repro to figure out what's happening.
2020-05-04 10:54:55 -04:00
Greyson Parrelli
c59fc3581a Make LiveRecipientCache throw exceptions instead of errors.
Errors were causing crash loops if they occur in a job. This will still
allow the app to crash, but prevent loops.
2020-05-04 00:48:09 -04:00
Greyson Parrelli
e00f8c94ff Bumped version to 4.59.6 2020-04-30 17:03:28 -04:00
Greyson Parrelli
4186153f0c Updated language translations. 2020-04-30 17:03:28 -04:00
Greyson Parrelli
6c01807f4f Fix issue with PIN verification. 2020-04-30 17:03:28 -04:00
Greyson Parrelli
9d35fb397b Fix issue with re-using forwarded attachment pointers.
We were deleting upload data for incoming attachments when we shouldn't
have.

Fixes #9570
2020-04-30 16:36:06 -04:00
Jim Gustafson
c9f2f57427 Update to ringrtc v1.3.2 2020-04-30 08:12:31 -07:00
Greyson Parrelli
c862ab0c56 Bump version to 4.59.5 2020-04-28 10:41:37 -04:00
Greyson Parrelli
7aaaa57c14 Updated language translations. 2020-04-28 10:41:06 -04:00
Greyson Parrelli
11b6394a87 Fix issue with group storage IDs. 2020-04-28 10:38:58 -04:00
Greyson Parrelli
bdd48fd2df Show PIN reminder for non-reglock users. 2020-04-28 10:38:49 -04:00
Alan Evans
e99af75400 Fix crash when blocking group. 2020-04-27 16:52:17 -03:00
Greyson Parrelli
321440e13f Bump version to 4.59.4 2020-04-27 13:07:41 -04:00
Greyson Parrelli
0556d984e0 Updated language translations. 2020-04-27 13:07:19 -04:00
Greyson Parrelli
0ba1f66136 Use the same Recipient.self() instance in storage sync. 2020-04-27 13:05:22 -04:00
Greyson Parrelli
7562555687 Add additional storage sync validations. 2020-04-27 12:38:07 -04:00
Greyson Parrelli
668ccfcd12 Clean up logging. 2020-04-27 11:29:52 -04:00
Greyson Parrelli
9c0337c4ef Fix threading issue with message resends. 2020-04-27 11:11:24 -04:00
Greyson Parrelli
3fde06ab0f Bump version to 4.59.3 2020-04-24 19:48:20 -04:00
Greyson Parrelli
73959f328a Updated language translations. 2020-04-24 19:47:57 -04:00
Greyson Parrelli
cca85bfee3 Fix some PinState bugs. 2020-04-24 19:40:50 -04:00
Greyson Parrelli
575caa53d3 Fix some storage service consistency issues. 2020-04-24 19:14:08 -04:00
Greyson Parrelli
33874a8866 Fix attachment upload bug. 2020-04-24 09:24:43 -04:00
Greyson Parrelli
b8e909a134 Revert to preferring system photos over profile photos. 2020-04-24 08:45:58 -04:00
Greyson Parrelli
5193a5d309 Prevent some crash loops. 2020-04-23 22:25:56 -04:00
Greyson Parrelli
7db288b9aa Make PINs work with password managers. 2020-04-23 22:25:56 -04:00
Greyson Parrelli
9f033e64aa Fix lint error. 2020-04-23 22:25:56 -04:00
Greyson Parrelli
5a15ba97dc Bump version to 4.59.2 2020-04-23 13:33:59 -04:00
Greyson Parrelli
ce6ec72683 Updated language translations. 2020-04-23 13:33:59 -04:00
Greyson Parrelli
eedbcdd564 Fix issue with group storage sync. 2020-04-23 13:33:59 -04:00
Greyson Parrelli
0ca2848e01 Improve logging for storage service. 2020-04-23 12:03:31 -04:00
Greyson Parrelli
208275b6a9 Improve logging for PinState. 2020-04-23 11:24:23 -04:00
Greyson Parrelli
4bdcaa72cd Fix some more UX issues with blocked users. 2020-04-23 11:06:52 -04:00
Greyson Parrelli
8c6001fa5a Improve correctness and performance of camera contact search. 2020-04-23 10:25:45 -04:00
Greyson Parrelli
c4e88abce1 Update PIN change strings. 2020-04-22 19:42:17 -04:00
Greyson Parrelli
eea7174f1d Check to see if FCM is available at app launch. 2020-04-22 19:32:40 -04:00
Greyson Parrelli
3f7d0688fc Bump version to 4.59.1 2020-04-22 14:18:28 -04:00
Greyson Parrelli
6d319618c6 Updated language translations. 2020-04-22 14:18:28 -04:00
Greyson Parrelli
4250fa707b Fix crash when videos are missing a duration.
Fixes #9556
2020-04-22 14:18:28 -04:00
Greyson Parrelli
7734cd2c8f Clean up some corner cases in storage syncing. 2020-04-22 14:18:28 -04:00
Alan Evans
57467bb338 Dismiss group participant list on contact click. 2020-04-22 14:18:28 -04:00
Alex Hart
8ad61a52b9 Fix call termination when muting before call is connected. 2020-04-22 14:18:28 -04:00
Alan Evans
9742a212a2 Fix Transifex string name clash. 2020-04-22 14:18:28 -04:00
Greyson Parrelli
fd21fc1a31 Fix some UX issues with blocked users. 2020-04-22 14:18:28 -04:00
Greyson Parrelli
1b5a0ab9f3 Sync the profile photo to linked devices when appropriate. 2020-04-22 10:34:43 -04:00
Greyson Parrelli
f466fef20a Fix issue where contact photos weren't being shown at all. 2020-04-22 10:13:56 -04:00
Greyson Parrelli
9bc70adbbd Update PIN setting strings. 2020-04-21 19:23:47 -04:00
Greyson Parrelli
6f39f9849a Bump version to 4.59.0 2020-04-21 16:09:30 -04:00
Greyson Parrelli
5bc950ed28 Updated language translations. 2020-04-21 16:09:30 -04:00
Alan Evans
b80d460a8f Account for deleted conversations in profile key send job. 2020-04-21 16:09:30 -04:00
Alan Evans
3f555ce5e2 Extract method for creating safety number intents. 2020-04-21 16:09:30 -04:00
Jim Gustafson
9513b476ef Update to ringrtc v1.3.1 2020-04-21 16:09:30 -04:00
Greyson Parrelli
8f9e79ae37 Updated PIN strings. 2020-04-21 16:09:30 -04:00
Alan Evans
53b681ef67 Make reaction and remote delete jobs GV2 ready. 2020-04-21 16:09:30 -04:00
Alan Evans
9a8094cb8a Guard against malformed group ids. 2020-04-21 16:09:30 -04:00
Alex Hart
00ee6d0bbd Dialog theme rename. 2020-04-21 16:09:30 -04:00
Greyson Parrelli
83f6640bd3 Add a more generic system for handling early messages. 2020-04-21 16:09:30 -04:00
Alex Hart
2afb939ee6 Implement send support for resumable uploads behind a flag. 2020-04-21 16:09:30 -04:00
Greyson Parrelli
7c442865c5 Interpret non-present message bodies as 'null'. 2020-04-21 16:09:30 -04:00
Greyson Parrelli
b3d57edb24 Update and centralize block strings. 2020-04-21 16:09:30 -04:00
Alex Hart
6d6e017c71 Proactively share profile key after accepting a message request. 2020-04-21 16:09:30 -04:00
Greyson Parrelli
fc6b5c1d7c Add ultramarine as a conversation color option. 2020-04-21 16:09:30 -04:00
Greyson Parrelli
6ecd3b59fd Add pre-alpha receive support for remote delete. 2020-04-21 16:09:13 -04:00
Ehren Kret
456bcf3d57 Require CDN number match rather than use default CDN
This marks messages as failed if the CDN number does not match a
configured CDN number rather than falling back to the default CDN in
the event the CDN is not recognized.
2020-04-21 13:33:41 -04:00
Greyson Parrelli
f12a9b9ac7 Store the server timestamp for a message. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
00b6a222bd Remove jumpiness when rendering reactions. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
b8ccc4453e Update pins4all flag.
We still have to keep the legacy one though so that people in the old
bucket stay in the new one.
2020-04-21 13:33:41 -04:00
Alan Evans
dbb31420af Ensure all support article urls are the correct format and not translatable. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
35f4f3f81e Add support for passing data between jobs. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
acbfff89d3 Update registration to allow PIN entry. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
6b37675a81 Remove long-press action in settings. 2020-04-21 13:33:41 -04:00
Greyson Parrelli
a471ffa6d8 Fix UD indicators for sent transcripts. 2020-04-21 13:33:41 -04:00
Alan Evans
7bf090fdab GroupsV2 state mapping. 2020-04-21 13:33:41 -04:00
Alan Evans
4e0279200f Refactor out MediaPreviewActivity Intent creation method. 2020-04-21 13:33:41 -04:00
Alan Evans
78055e3ccb GroupsV2 update sending and local context storage. 2020-04-21 13:33:41 -04:00
Alan Evans
f5e6fd6340 Allow RetrieveProfileJob to be used for self. 2020-04-21 13:33:33 -04:00
Alex Hart
2d60d5fb1f Check menu item visibility when calculating menu size. 2020-04-21 13:33:33 -04:00
Alan Evans
c6dd25a119 Ensure group membership for typing indicators. 2020-04-21 13:33:33 -04:00
Alan Evans
68d29d9a0f Allow pending member invite cancelation. 2020-04-21 13:33:33 -04:00
Alan Evans
1d63970a25 Hardcode all class names in old work manager migration. 2020-04-21 13:33:33 -04:00
Alan Evans
2b1ffac564 Groups V2 avatar download job. 2020-04-21 13:33:33 -04:00
Alan Evans
e2d3a43593 Use readBodyBytes for correct exceptions. 2020-04-21 13:33:33 -04:00
Greyson Parrelli
8e13403cca Separate PINs from Registration Lock.
You can now have a PIN without having registration lock.

Note: We still need to change the registration flow to allow non-reglock
users to enter their PIN.
2020-04-21 13:33:33 -04:00
Ehren Kret
3c6a7b76ca Send increased protocol version number if CDN key or attachment are used. 2020-04-21 13:33:33 -04:00
Alan Evans
428128651e Move database protos to separate files. 2020-04-21 13:33:33 -04:00
Alan Evans
326678f214 Add support for GV2 group update messages. 2020-04-21 13:33:29 -04:00
Alex Hart
1f994495f8 Clear search if user sends message. 2020-04-21 13:33:29 -04:00
Greyson Parrelli
fb1637006d Include screen size details in debuglogs. 2020-04-21 13:33:29 -04:00
Ehren Kret
37a35e8f70 Add initial support for send/receive on CDN2. 2020-04-21 13:33:29 -04:00
Alan Evans
1290d0ead9 Add pending member activity. 2020-04-21 13:33:25 -04:00
Greyson Parrelli
ef0f26b64c Remove borders from images in the gallery picker. 2020-04-03 12:20:15 -04:00
Greyson Parrelli
485d211768 Remove border from images in the attachment keyboard. 2020-04-03 12:20:15 -04:00
Greyson Parrelli
f1ea035197 Re-enable and clean up Signal PINs.
- Require PINs during registration agian.
- Change min length to 4.
- Allow the full-screen megaphone to be enabled remotely.
- Clean up and remove some code.
2020-04-03 12:20:15 -04:00
Martijn van den Hoek
6f961ade74 Fix crash when importing vcf after exporting it.
Fixes #9465
2020-04-03 12:20:15 -04:00
Alan Evans
b8e17e0116 Enable video trimming feature by default. 2020-04-03 12:20:15 -04:00
Alan Evans
040e1fe8f6 Apply dark theme to scroll to bottom button. 2020-04-03 12:20:15 -04:00
Alan Evans
e9c92bdf51 Show unblock dialog when tap blocked contact. 2020-04-03 12:20:15 -04:00
Alan Evans
48c33f3dcd GroupsV2 service changes. 2020-04-03 12:20:15 -04:00
Alex Hart
6b2bc924dd Prefer profile photo over system contact photo. 2020-04-03 12:20:15 -04:00
Ehren Kret
a65c4f90f4 Avoid potential race condition in attachment uploads. 2020-04-03 12:19:13 -04:00
Alan Evans
04bb4b351a Refactor group leave dialog out of conversation. 2020-04-03 12:19:13 -04:00
Alan Evans
e02e4d52b4 Prevent empty message processing. 2020-04-03 12:19:13 -04:00
Alex Hart
6f3c4434f6 Add animation when replying to a message. 2020-04-03 12:19:13 -04:00
Greyson Parrelli
711715ca1e Add DNS fallback system. 2020-04-03 12:19:12 -04:00
Greyson Parrelli
d6000af843 Re-use recently-acquired attachment pointers. 2020-04-03 12:19:12 -04:00
Greyson Parrelli
9b0954a898 Bump version to 4.58.5 2020-04-03 11:18:39 -04:00
Greyson Parrelli
42a2c33fd7 Updated language translations. 2020-04-03 11:18:13 -04:00
Greyson Parrelli
a4d18a18d9 Don't use vector assets for notification icon. 2020-04-03 11:14:36 -04:00
Alex Hart
bf32409d4e Split drawable into light and dark. 2020-04-03 12:14:09 -03:00
Greyson Parrelli
e38aec225f Bump version to 4.58.4 2020-04-01 14:48:47 -04:00
Greyson Parrelli
995b7a4712 Updated language translations. 2020-04-01 14:48:25 -04:00
Alex Hart
9fe3026941 Fix AdaptiveActionsToolbar sizing algorithm. 2020-04-01 11:26:19 -03:00
Greyson Parrelli
520658e1b8 Bump version to 4.58.3 2020-03-31 17:10:00 -04:00
Greyson Parrelli
f822d8eddb Updated language translations. 2020-03-31 16:59:36 -04:00
Alex Hart
2f879ce4d6 Remove MMS groups from message request logic. 2020-03-31 16:00:26 -03:00
Greyson Parrelli
24528bf101 Fix accent color in alert dialogs in dark theme. 2020-03-31 14:59:00 -04:00
Greyson Parrelli
822682caba Fix NPE in BitmapUtil.toJpeg()
Fixes #9513
2020-03-31 11:44:18 -04:00
Greyson Parrelli
5dc3cc65a8 Bump version to 4.58.2 2020-03-30 17:53:08 -04:00
Greyson Parrelli
0f80caffb5 Updated language translations. 2020-03-30 17:53:08 -04:00
Greyson Parrelli
6c428b2777 Fix issue with some notifications linking to the wrong conversation. 2020-03-30 17:53:08 -04:00
Greyson Parrelli
c9be37b84a Fix camera rotation issues.
Had to manually detect when CameraX is giving us bad data.

Fixes #9509
2020-03-30 16:04:28 -04:00
Jim Gustafson
87ea2f86c0 Update ringrtc to v1.2.0 2020-03-30 13:01:14 -07:00
Greyson Parrelli
7e80be5ca0 Separate out model info in debug logs. 2020-03-30 15:24:29 -04:00
Greyson Parrelli
989a818a67 Fix issue where reaction notifications may jump to the wrong message. 2020-03-30 12:49:08 -04:00
Greyson Parrelli
af2e17df9e Ensure old typing observers are unsubscribed. 2020-03-30 11:33:21 -04:00
Greyson Parrelli
728ec1c16d Fix issue where leave messages were pending forever. 2020-03-30 10:11:15 -04:00
Greyson Parrelli
f859c5b1b5 Prevent conscrypt crash during profile retrieval.
This was a mitigation that was previously in place that was forgotten
during the recent avatar refactor.
2020-03-29 18:53:30 -04:00
Greyson Parrelli
ab600d7df1 Bump version to 4.58.1 2020-03-27 16:51:21 -04:00
Greyson Parrelli
4644f64fd6 Updated language translations. 2020-03-27 16:51:21 -04:00
Greyson Parrelli
c274312265 Fix scrolling in the emoji variation popup. 2020-03-27 16:51:21 -04:00
Greyson Parrelli
f8e63098a2 Don't show empty date popovers. 2020-03-27 16:40:55 -04:00
Greyson Parrelli
264d353ec2 Bump quality of camera1 photos. 2020-03-27 16:30:36 -04:00
Alex Hart
2b58dcbe7f Remove explicit CameraX initialization. 2020-03-27 16:30:36 -04:00
Greyson Parrelli
dc791487c5 Jump to the relevant message when tapping a reaction notification.
Fixes #9503
2020-03-27 16:30:36 -04:00
Greyson Parrelli
5637f132d4 Fixed issue where leave message wasn't displayed locally. 2020-03-27 16:30:36 -04:00
Alan Evans
9e6cca1cd0 GV2 database. 2020-03-27 16:30:36 -04:00
Alan Evans
640c82d517 GV2 group context proto. 2020-03-27 16:30:36 -04:00
Greyson Parrelli
20d1a93b09 Don't refresh own profile if not registered. 2020-03-27 16:30:36 -04:00
Greyson Parrelli
f5d1b11bda Fix some dark theme text contrast issues. 2020-03-27 16:30:36 -04:00
Alan Evans
66c7f8bcb2 GroupId for GV2. 2020-03-27 11:28:48 -03:00
Alex Hart
d8fa46c558 Copy action should display if message body is not empty.
Fixes #9491
2020-03-27 11:18:02 -03:00
Greyson Parrelli
10bfc8a753 Migrate avatars and group avatars. 2020-03-26 22:38:33 -04:00
Greyson Parrelli
9848599807 Bump version to 4.58.0 2020-03-26 17:49:10 -04:00
Greyson Parrelli
2e38ebcfbb Updated language translations. 2020-03-26 17:46:51 -04:00
Greyson Parrelli
f875623cd0 Resize avatars to 1024x1024. 2020-03-26 17:37:52 -04:00
Greyson Parrelli
e6f9cb9929 Remove TextSecurePreferences.getAvatarId() 2020-03-26 17:37:52 -04:00
Greyson Parrelli
6aac3baa55 Remove TextSecurePreferences.getProfileName() 2020-03-26 17:37:52 -04:00
Alan Evans
a860315587 GroupId class. 2020-03-26 17:37:52 -04:00
Greyson Parrelli
a73a73e42c Fix AudioView tinting on Android 10. 2020-03-26 17:37:52 -04:00
Greyson Parrelli
a3358e5b21 Rotate profile key after blocking if shared via group. 2020-03-26 17:37:52 -04:00
Alex Hart
7e9e2fead2 Fix NPE after call failure. 2020-03-26 17:37:52 -04:00
Alan Evans
0269a3eb6f Groups V2 protobufs and local conflict resolution. 2020-03-26 17:37:51 -04:00
Alex Hart
f449a45912 Utilize normal fallback for homescreen icons. 2020-03-26 17:37:51 -04:00
Alan Evans
f69d4ccd22 Increase Lib Signal Service compatibility to Java 8. 2020-03-26 17:37:51 -04:00
Alan Evans
0e2df2adbb Image Editor: Keep text on top.
Sorts children by a new z-order.
2020-03-26 17:37:51 -04:00
Alex Hart
d46894e5db Upgrade CameraX to Beta01. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
951a61117a Add storage support for the AccountRecord. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
7a038ab09d Add interim storage support for GroupV2Record. 2020-03-26 17:37:51 -04:00
Alex Hart
707a2aca0a Swap profile megaphone icon and use user avatar if present. 2020-03-26 17:37:51 -04:00
Alan Evans
624837fcf1 Include zkgroup 0.4.1
All behind feature flag, excluding .so files for space.
2020-03-26 17:37:51 -04:00
Greyson Parrelli
e3ea36c76f Remove unnecessary okhttp close when canceling.
Canceling should handle closing stuff now. And if we close from a
different thread than the calling thread, okhttp will crash.
2020-03-26 17:37:51 -04:00
Alan Evans
453996c374 Restrict CI branches. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
8add9ba0a6 Removed ExperienceUpgradeActivity.
Pour one out.
2020-03-26 17:37:51 -04:00
Alan Evans
da11b56eab Check for and clear quote on new intent.
Fixes #9478
2020-03-26 17:37:51 -04:00
Greyson Parrelli
19377c2132 Remote maxInstance restriction on RetrieveProfileAvatarJob. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
b2bff39fe1 Don't send group info requests in response to group info requests. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
5f7075d39a Update and refactor storage service syncing.
Switched to proto3, updated protos, and generally refactored things to
make it easier to add new storage record types.
2020-03-26 17:37:51 -04:00
Alex Hart
40d9d663ec Disable auto-mirror for help icon 2020-03-26 17:37:51 -04:00
Greyson Parrelli
31f9b77c32 Ignore empty names when populating contact list. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
690a66a093 Show any user with a displayable name in the contact list. 2020-03-26 17:37:51 -04:00
Ehren Kret
e7e7d36774 Configure Android Studio to pickup protobuf generated sources 2020-03-26 17:37:51 -04:00
Greyson Parrelli
f95a37956c Improve emoji sticker suggestions.
There was a bug around some emoji being marked as 'obsolete' and
therefore not being found.

I also made a change so that you can use skin variations of emoji and
still find emoji tagged with the default yellow version of it.

Fixes #9471
2020-03-26 17:37:51 -04:00
Greyson Parrelli
1e2a27f902 Close dangling groups cursor. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
d90e3dc210 Fix crash when syncing empty usernames. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
5df4b56c0d Update okhttp to 3.12.10 2020-03-26 17:37:51 -04:00
Jim Gustafson
436da1cb32 Update ringrtc to v1.1.0 2020-03-26 17:37:51 -04:00
Greyson Parrelli
4d0dbbc6cd Add ability to listen to jobs based on a filter. 2020-03-26 17:37:51 -04:00
Alan Evans
033bf77cbb Allow future display of pending member count. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
1068c3ca7e Fix UnknownSenderView in dark theme. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
df4422369d Update icons and colors. 2020-03-26 17:37:51 -04:00
Greyson Parrelli
a62183c9e0 Reduce AttachmentCipherTest flakiness. 2020-03-19 14:50:06 -04:00
Greyson Parrelli
de48cf8243 Bump version to 4.57.2 2020-03-19 14:49:52 -04:00
Greyson Parrelli
acd4fc4518 Fix issue where minimum PIN length was miscalculated.
Fixes #9484
2020-03-19 14:49:10 -04:00
Greyson Parrelli
da59ed019f Bump version to 4.57.1 2020-03-07 16:43:35 -05:00
Greyson Parrelli
e73b174d1d Updated language translations. 2020-03-07 16:43:08 -05:00
Alan Evans
2753a22e3a Remove old activity from manifest. 2020-03-07 16:40:17 -05:00
Alex Hart
79fc33630b Add toast instead of crash if no email app installed. 2020-03-07 16:40:17 -05:00
Greyson Parrelli
bf5331ba6e Bump version to 4.57.0 2020-03-05 18:51:45 -05:00
Greyson Parrelli
3be47d3e54 Updated language translations. 2020-03-05 18:51:21 -05:00
Alex Hart
f9de131017 Add new contact us flow. 2020-03-05 18:42:17 -05:00
Alan Evans
f1f505d41c Try getKeyStoreEntry twice on UnrecoverableKeyException.
To try to get around potentially temporary UnrecoverableKeyExceptions.
2020-03-05 18:42:17 -05:00
Alan Evans
51603be5ec Add video trimming time indication pill. 2020-03-05 18:42:17 -05:00
Alex Hart
2152b4a2cd Add warning dialog for insecure calls. 2020-03-05 18:42:17 -05:00
Alan Evans
a70023a32b Use group manager to leave group. 2020-03-05 18:42:17 -05:00
Alan Evans
5038210d78 Add tap to pause to video trimming editor. 2020-03-05 18:42:17 -05:00
Alan Evans
28bbfd88b2 Group member dialog update. 2020-03-05 18:42:17 -05:00
Greyson Parrelli
d05a71c8fe Update Glide to 4.11.0 2020-03-03 08:52:11 -05:00
Greyson Parrelli
245b0a7e50 Add a new buildType with Flipper. 2020-03-02 16:25:05 -05:00
Alan Evans
ceb9e4aee2 Write capabilities to service. 2020-03-02 12:01:50 -04:00
Alan Evans
d2e94dad7e Remove argon2 test job. 2020-03-02 11:22:37 -04:00
Alex Hart
240b2108f3 Use the image editor for avatars. 2020-03-02 11:21:57 -04:00
Greyson Parrelli
f68d99d16d Clean up dangling transfer files.
Fixes #9033
2020-03-02 10:11:40 -05:00
Greyson Parrelli
44e845c875 Update emoji. 2020-03-02 10:11:40 -05:00
Alan Evans
d8e2368a18 Convert UUID supported into a Capability enum. 2020-03-02 10:11:40 -05:00
Alan Evans
172a43679d Add GV2 recipient capability. 2020-03-02 10:11:40 -05:00
Greyson Parrelli
82305ce2b3 Bump version to 4.56.4 2020-03-02 09:55:04 -05:00
Greyson Parrelli
eaf73edcad Updated language translations. 2020-03-02 09:54:35 -05:00
Greyson Parrelli
543a4ee177 Fix backup restore crash. 2020-03-02 09:48:18 -05:00
Greyson Parrelli
fd2a464bae Use internal contact viewer for avatar clicks. 2020-03-02 08:33:25 -05:00
Alex Hart
b06152ba58 Fix and simplify Y translation calculation for Conversation. 2020-03-02 08:57:11 -04:00
Greyson Parrelli
c24d285cd3 Bump version to 4.56.3 2020-02-28 17:35:13 -05:00
Greyson Parrelli
be39cd653e Updated language translations. 2020-02-28 17:35:13 -05:00
Greyson Parrelli
6813f47bc1 Remove feature flags that are no longer remote capable. 2020-02-28 17:35:10 -05:00
Greyson Parrelli
8e795c4177 Read the sticker length during backup import. 2020-02-28 16:58:47 -05:00
Greyson Parrelli
9c96afee09 Fix storage service crash with new users. 2020-02-28 16:58:47 -05:00
Greyson Parrelli
d507be0ab0 Don't backup the KeyValueDatabase. 2020-02-28 16:58:47 -05:00
Greyson Parrelli
75a52f801a Implement storage service protocol changes. 2020-02-28 16:58:47 -05:00
Greyson Parrelli
d3b123f3a9 Fix StorageSyncHelperTest. 2020-02-28 08:07:36 -05:00
Greyson Parrelli
da3cdd984b Bump version to 4.56.2 2020-02-26 17:57:36 -05:00
Greyson Parrelli
6184e5f828 Update the storage service. 2020-02-26 17:11:34 -05:00
Curt Brune
133bd44b85 Update ringrtc to v1.0.2 2020-02-26 17:11:34 -05:00
Greyson Parrelli
0c254c9621 Improve debuglog submission. 2020-02-26 17:11:34 -05:00
Greyson Parrelli
1faf196f82 Implement additional message request improvements. 2020-02-26 17:11:29 -05:00
Greyson Parrelli
81c7887d47 Switch language string to 'System default.' 2020-02-26 17:08:27 -05:00
Greyson Parrelli
e62e630987 Fix theming issue in CameraContactSelectionFragment. 2020-02-26 17:08:27 -05:00
Alex Hart
739e38a047 Fix reaction details bottom sheet scrolling. 2020-02-26 17:08:27 -05:00
Greyson Parrelli
8c23b17517 Fix some state issues post backup restore. 2020-02-26 17:08:27 -05:00
Greyson Parrelli
fda8f3e1ce Refer to yourself as 'you' in reactions and group membership. 2020-02-26 17:08:27 -05:00
Alex Hart
9e5f64c431 Improve message requests, add megaphone. 2020-02-26 17:08:27 -05:00
Alex Hart
dc689d325b Various PIN bug fixes. 2020-02-26 17:06:21 -05:00
Greyson Parrelli
0a883dc234 Fix issue with mimeType resolution in share flow. 2020-02-26 17:06:06 -05:00
Greyson Parrelli
3824e90997 Improve prekey refresh logic. 2020-02-26 17:06:06 -05:00
Greyson Parrelli
5158a15379 Disable PIN requirement for new registrations. 2020-02-26 17:06:06 -05:00
Curt Brune
1bae79af5b Check callManager reference is still valid in ListenableFutureTask callbacks. 2020-02-26 17:06:04 -05:00
Curt Brune
58b7612987 Drop requests to deny stale incoming calls.
This is not an illegal state, as the remote side could have hung-up
a microsecond before the local side tries to deny the call.
2020-02-26 17:06:02 -05:00
Curt Brune
9506da6dd3 Validate activePeer during Bluetooth and Speaker audio state transitions. 2020-02-26 17:05:54 -05:00
Greyson Parrelli
4ea886d05a Bump version to 4.56.1 2020-02-14 12:20:40 -05:00
Greyson Parrelli
7a52fccfd1 Updated language translations. 2020-02-14 12:20:40 -05:00
Greyson Parrelli
f79d308a9f Update profile name megaphone. 2020-02-14 12:20:40 -05:00
Curt Brune
5aa64641d2 Convert IllegalStateException to warning log in receivedBusy()
This is not a fatal condition.  Convert to warning log message in
order to gather more information.
2020-02-14 08:13:11 -08:00
Curt Brune
ae594a0400 Check activeRemote is non-null during handleScreenOffChange() 2020-02-14 08:13:11 -08:00
Curt Brune
eeece55b45 Check activeRemote is non-null during handleWiredHeadsetChange() 2020-02-14 08:13:11 -08:00
Greyson Parrelli
9fbc50d26f Fix crash when cleared ShareViewModel. 2020-02-14 09:57:26 -05:00
Greyson Parrelli
16ebf0556a Bump version to 4.56.0 2020-02-13 20:53:10 -05:00
Greyson Parrelli
bb104b5763 Updated language translations. 2020-02-13 20:53:10 -05:00
Greyson Parrelli
9bac88697b Support sharing multiple photos/videos into Signal. 2020-02-13 20:53:10 -05:00
Alan Evans
7ab240643e Remove build instructions. 2020-02-13 20:53:10 -05:00
Greyson Parrelli
70d5b798b2 Add some developer utils. 2020-02-13 20:53:10 -05:00
Greyson Parrelli
4e7a92637c Follow system theme on Android 10+. 2020-02-13 20:53:10 -05:00
Greyson Parrelli
2e19d0459b Fix album ordering issue.
Fixes #9381
2020-02-13 20:53:10 -05:00
Curt Brune
0970fd7040 Update ringrtc to v1.0.1
Add support for RingRTC Call Manager, a new component which provides
the control layer for all calling features.
2020-02-13 20:53:10 -05:00
Greyson Parrelli
81532cad95 Use a min length of 6 for new PIN reminders. 2020-02-13 20:53:10 -05:00
Greyson Parrelli
dcb5f7b211 Update copy for PIN setting. 2020-02-13 20:53:10 -05:00
Alan Evans
40fd7ca332 Video trimming behind feature flag. 2020-02-13 20:53:10 -05:00
Alan Evans
7f867a6185 Remove KBS restore after set check. 2020-02-13 20:53:10 -05:00
Alan Evans
23e55ac5f7 Clear unidentified access mode when profile key changes. 2020-02-13 20:53:10 -05:00
Jonathan Leitschuh
455974cb05 Add official Gradle Wrapper validation action.
See: https://github.com/gradle/wrapper-validation-action
2020-02-13 20:53:10 -05:00
Greyson Parrelli
66a668f55b Add some Swoon blessed packs. 2020-02-13 20:53:10 -05:00
Alan Evans
7ecb50a3fe Versioned Profiles support (disabled). 2020-02-13 20:53:10 -05:00
Alan Evans
f10d1eac61 Migrate profile key into database. 2020-02-13 20:53:10 -05:00
Alan Evans
b92c389a5b Fix media rail thumbnail for in-app recorded video. 2020-02-13 20:53:10 -05:00
Alex Hart
9dfc57c462 Fix RTL icon issue in toolbar. 2020-02-13 20:53:10 -05:00
Alex Hart
3ea1492d67 Add profile names megaphone. 2020-02-13 20:53:07 -05:00
Greyson Parrelli
c041614d1f Only store remote values for flags in a whitelist. 2020-02-11 12:03:34 -05:00
Greyson Parrelli
d9c5907ea9 Bump version to 4.55.8 2020-02-11 12:03:12 -05:00
Greyson Parrelli
0b6a52277d Fixed PIN reminders showing too often, reminder UI improvements. 2020-02-11 12:03:12 -05:00
Greyson Parrelli
944adb5d7c Bump version to 4.55.7 2020-02-10 20:01:47 -05:00
Greyson Parrelli
ac4129c1e1 Updated language translations. 2020-02-10 20:01:28 -05:00
Greyson Parrelli
0220a88ea5 Mark registration complete after PIN failure. 2020-02-10 19:56:41 -05:00
Greyson Parrelli
6d33763ec9 Bump version to 4.55.6 2020-02-08 10:58:43 -05:00
Greyson Parrelli
3cedadbb97 Fix video duration rendering issue. 2020-02-08 10:58:12 -05:00
Greyson Parrelli
5a6d339a89 Bump version to 4.55.5 2020-02-08 10:26:01 -05:00
Greyson Parrelli
905d8a4f33 Updated language translations. 2020-02-08 10:26:01 -05:00
Greyson Parrelli
917d312ea0 Reduced padding above megaphone button. 2020-02-08 10:26:01 -05:00
Greyson Parrelli
ddc01b539f Use megaphones for PIN reminders. 2020-02-07 21:14:20 -05:00
Greyson Parrelli
38e4733433 Improve network reliability when setting PINs. 2020-02-07 01:06:41 -05:00
Greyson Parrelli
cbd7160e23 Show profile creation before PIN creation. 2020-02-07 00:47:52 -05:00
Greyson Parrelli
f2b3acb0c9 Update string for creating PIN. 2020-02-07 00:15:42 -05:00
Greyson Parrelli
49c7b5c442 Bump version to 4.55.4 2020-02-06 11:19:46 -05:00
Greyson Parrelli
7b7d180207 Updated language translations. 2020-02-06 11:19:46 -05:00
Alex Hart
21cf390d0e Clip reactions mask if the view falls below the input panel. 2020-02-06 11:19:46 -05:00
Greyson Parrelli
5e59f77f83 Update PIN feature flags. 2020-02-06 11:19:46 -05:00
Greyson Parrelli
62814490b3 Only store remote values for flags in a whitelist. 2020-02-06 11:19:46 -05:00
Alan Evans
e5fedb8163 Add pull request trigger. 2020-02-06 07:52:32 -05:00
Greyson Parrelli
cfc74c1080 Bump version to 4.55.3 2020-02-05 20:50:25 -05:00
Greyson Parrelli
eaf53ad3b9 Updated language translations. 2020-02-05 20:49:59 -05:00
Greyson Parrelli
a1f0c198a7 Auto-show keyboard for PIN entry. 2020-02-05 18:49:31 -05:00
Greyson Parrelli
6b1e48e485 Don't show the full-screen PIN megaphone. 2020-02-05 18:49:31 -05:00
Greyson Parrelli
83ea919434 Remove "(You)" from the reactions details.
This reverts commit ed2b049ad4.
2020-02-05 11:36:57 -05:00
Greyson Parrelli
c94e93b916 Fix issue with reactions pill not appearing. 2020-02-05 11:32:20 -05:00
Alex Hart
49d418bb39 Fix RTL support for reaction sending. 2020-02-05 11:20:36 -05:00
Greyson Parrelli
23adda1817 Update reaction pill padding. 2020-02-05 10:40:08 -05:00
Alex Hart
7c729c2c4e Add AdaptiveActionsToolbar for better context bar controls. 2020-02-05 08:51:05 -04:00
Greyson Parrelli
ecf7a416eb Bump version to 4.55.2 2020-02-04 20:10:36 -05:00
Greyson Parrelli
2f87f2bb62 Updated language translations. 2020-02-04 20:10:00 -05:00
Greyson Parrelli
39f4102e81 Fix issue where quoted replies showed a 'save' option. 2020-02-04 19:21:01 -05:00
Greyson Parrelli
4fcd6b15ed Improved feel of reaction popover. 2020-02-04 19:21:01 -05:00
Greyson Parrelli
8f9ed4bc40 Fix the shape of reaction pills. 2020-02-04 19:21:01 -05:00
Alex Hart
73dedd79d2 Fix crash in reactions overlay OnTouch. 2020-02-04 19:21:01 -05:00
Greyson Parrelli
2754b397d5 Darken the background more when selecting a message. 2020-02-04 19:21:01 -05:00
Greyson Parrelli
7d949ee8fd Prevent crash in megaphones after backup restore. 2020-02-04 19:21:01 -05:00
Greyson Parrelli
28e2f22550 Fix layout issues with reaction badges. 2020-02-04 19:21:01 -05:00
Alex Hart
eaa1760511 Animate toolbar in reactions overlay. 2020-02-04 19:21:01 -05:00
Alex Hart
53dfd3f4c0 Fix wrong avatar displaying in reactions fragment. 2020-02-04 19:21:01 -05:00
Alex Hart
ed2b049ad4 Add You to reactions you've sent in the bottom dialog fragment. 2020-02-04 10:35:45 -04:00
Alex Hart
092fb40333 Check if target is attached to window before trying to mask it. 2020-02-04 09:47:26 -04:00
Alan Evans
36a4225858 Always return passphrase without spaces. 2020-02-04 08:10:58 -05:00
Greyson Parrelli
e551ea8bd9 Bump version to 4.55.1 2020-02-04 00:59:45 -05:00
Greyson Parrelli
5a28b1bf1c Updated language translations. 2020-02-04 00:59:15 -05:00
Greyson Parrelli
4cd1129c92 Show snooze snackbars for longer. 2020-02-04 00:55:38 -05:00
Greyson Parrelli
a5d7bc4efc Force custom emoji for reactions. 2020-02-04 00:42:41 -05:00
Greyson Parrelli
1ff5b2af2a Capitalize 'PIN' in strings. 2020-02-04 00:01:07 -05:00
Greyson Parrelli
82446ce30a Hide attachment keyboard after selecting an action. 2020-02-04 00:00:06 -05:00
Alan Evans
6465248483 Fix megaphone snooze. 2020-02-03 22:44:43 -05:00
Greyson Parrelli
48e7f82466 Fix issue with view-once toggle breaking video controls. 2020-02-03 18:26:49 -05:00
Greyson Parrelli
6fef21ebc0 Update permission copy in attachment keyboard. 2020-02-03 15:32:20 -05:00
Greyson Parrelli
837e594607 Bump version to 4.55.0 2020-02-03 15:05:05 -05:00
Greyson Parrelli
ab0cb55b80 Updated language translations. 2020-02-03 15:05:05 -05:00
Greyson Parrelli
2d24c8c525 Update conditions for PIN megaphone.
Handles additional corner cases.
- Shows megaphone when you register with a v1 pin.
- Show fullscreen when you fail to set a PIN during registration.
2020-02-03 15:04:53 -05:00
Alan Evans
40383f3733 Handle presenting KBS account locked cases. 2020-02-03 15:04:53 -05:00
Alex Hart
e14861d79d CreatePinActivity naming update and copy fixes. 2020-02-03 15:04:53 -05:00
Alan Evans
b29b3d0432 Require at least 4 digits during registration. 2020-02-03 15:04:53 -05:00
Greyson Parrelli
c21d4861c0 Clear text entry after changing PIN types. 2020-02-03 15:04:53 -05:00
Greyson Parrelli
a6786e5c2b Fix strings in KBS PIN flow. 2020-02-03 15:04:53 -05:00
Greyson Parrelli
77caa9e9d4 Fix crash in getIntentForPinCreate(), show 'Create' in prefs. 2020-02-03 15:04:53 -05:00
Greyson Parrelli
835ef02872 Add an 'All' tab to reaction details. 2020-02-03 15:04:53 -05:00
Alex Hart
279dcb1428 Apply KBS Lock fixes and pluralization 2020-02-03 15:04:53 -05:00
Alan Evans
4a8c312e0a Clear pin on confirm screen on submit. 2020-02-03 15:04:53 -05:00
Alan Evans
c2bc376f87 Hide PIN from summary when feature flag set. 2020-02-03 15:04:37 -05:00
Greyson Parrelli
73160d4d26 Update reactions UI. 2020-02-03 14:20:08 -05:00
Alan Evans
1dd2a4e9c5 Allow backup passphrase verification. 2020-02-03 14:20:08 -05:00
Alan Evans
ed0c4b8de5 Remove KBS feature flag. 2020-02-03 14:20:08 -05:00
Greyson Parrelli
4f921d761d Enable reaction sending. 2020-02-03 14:20:08 -05:00
Greyson Parrelli
37f85d6deb Delete unused megaphones from the database. 2020-02-03 14:20:08 -05:00
Alex Hart
e1b75c78ab Add Pins for All Megaphone Kill Switch. 2020-02-03 14:20:08 -05:00
Alan Evans
5e83206e6e Fix group timer message. 2020-02-03 14:20:08 -05:00
Alan Evans
1ea6838db6 Bring KBS fragment source into RegistrationLockFragment and handle account locked. 2020-02-03 14:20:08 -05:00
Alex Hart
fb82420376 Implement new PIN UX. 2020-02-01 12:42:29 -04:00
Greyson Parrelli
109d67956f Implement new attachment keyboard.
Such beauty. Such grace.
2020-02-01 12:38:53 -04:00
Greyson Parrelli
9f7b2e2cfd Track the first time a megaphone appeared. 2020-01-30 11:40:22 -05:00
Greyson Parrelli
22f9bfeceb Add support for creating Megaphones. Includes reactions megaphone. 2020-01-29 19:15:02 -05:00
Greyson Parrelli
ef4c7e96da Bump version to 4.54.3 2020-01-29 18:31:07 -05:00
Greyson Parrelli
02865f99a9 Limit impact of crash on unexpected SMS receive. 2020-01-29 18:28:59 -05:00
Greyson Parrelli
ef6019f13b Fix reddit link previews. 2020-01-29 18:26:16 -05:00
Greyson Parrelli
33d02bb7b8 Bump version to 4.54.2 2020-01-28 15:31:11 -05:00
Greyson Parrelli
d34df2c1cf Updated language translations. 2020-01-28 15:30:11 -05:00
Alex Hart
7fdf540742 Implement new reaction notifications. 2020-01-28 15:48:24 -04:00
Alex Hart
f916aabb98 Fix NPE when retrieving display name of unknown recipient. 2020-01-28 15:22:41 -04:00
Alex Hart
4ae7d56db4 Fix NPE when returning to profile from background.
Also generally improves saved-state management for Profile editor.
2020-01-28 14:57:17 -04:00
Alex Hart
e3878ffde7 Change profile preference screen to use toolbar. 2020-01-28 13:41:06 -04:00
Alex Hart
5221b6fb43 Fix expiration timer display issue on devices with modified font sizes.
Fixes #9335
2020-01-27 14:54:04 -04:00
Alex Hart
5e0fe86858 Add SM-G920F and BLK-L09 to LegacyCameraModels. 2020-01-27 14:32:48 -04:00
Alex Hart
c86ced0911 Add back arrow to profile editor. 2020-01-27 14:30:53 -04:00
Alex Hart
0aad82d3d7 Check content disposition flag in carrier config before parsing PDU.
Fixes #9081
2020-01-27 12:15:32 -04:00
Greyson Parrelli
ce86adab82 Bump version to 4.54.1 2020-01-27 10:09:48 -05:00
Greyson Parrelli
b543f727be Fix lint error. 2020-01-27 10:09:24 -05:00
Greyson Parrelli
8de7e0f198 Bump version to 4.54.0 2020-01-27 09:51:00 -05:00
Alan Evans
866dacf198 Updated language translations. 2020-01-27 09:51:00 -05:00
Alan Evans
3589fa381d Make better effort to delete leftover temporary backup files. 2020-01-27 09:51:00 -05:00
Greyson Parrelli
5d54ebfaa0 Fix crash when notification state is empty. 2020-01-27 09:51:00 -05:00
Alan Evans
fea2b6253f KBS remote feature flag. 2020-01-27 09:51:00 -05:00
Alan Evans
ba6e1ab15a Add type to KBS json. 2020-01-27 09:51:00 -05:00
Curt Brune
1d9fff3c98 Update ringrtc to 0.3.3 2020-01-27 09:51:00 -05:00
Greyson Parrelli
526adce603 Add support for sticky and hot-swappable feature flags. 2020-01-27 09:51:00 -05:00
Alan Evans
e7f568e162 Trimming profile names to fit byte budget and remove leading/trailing spaces. 2020-01-27 09:51:00 -05:00
Alan Evans
7d15c602a6 Enable KBS. 2020-01-27 09:51:00 -05:00
Greyson Parrelli
bdb30ebc48 Set a better User-Agent on requests. 2020-01-27 09:51:00 -05:00
Greyson Parrelli
a31da7616d Rename 'userAgent' to 'signalAgent'.
This wasn't actually being used in the User-Agent header. Instead, it
was used as the value for an X-Signal-Agent header. To avoid confusion,
I'm renaming this.
2020-01-27 09:51:00 -05:00
Alex Hart
f1147c10ee Disable reaction sending on update messages. 2020-01-27 09:51:00 -05:00
Alan Evans
544a5386ad Always show sticker icon in image editor.
Fixes flicker seen jumping toggling view once.
2020-01-27 09:51:00 -05:00
Greyson Parrelli
2d502213e4 Remove forced feature flag for reaction sending. 2020-01-27 09:51:00 -05:00
Greyson Parrelli
55e9f8722f Add support for remote feature flags. 2020-01-27 09:51:00 -05:00
Greyson Parrelli
b8602ee004 Fix issues with Mexican phone number formatting.
Fixes #9317
2020-01-27 09:40:27 -05:00
Alan Evans
e37c4b1f87 Replace pinstretcher with Argon2 and new PIN encryption. 2020-01-24 10:54:39 -05:00
Greyson Parrelli
f7a3bb2ae8 Add the ability to re-order sticker packs. 2020-01-24 10:54:39 -05:00
Alan Evans
7d70ea78cd Hmac-SIV encryption/decryption. 2020-01-24 10:54:39 -05:00
Alex Hart
3907ec8b51 Add support for setting an optional last name in profiles. 2020-01-24 10:54:39 -05:00
Alan Evans
f2b9bf0b8c Use SignalStore for KBS Values. 2020-01-24 10:54:38 -05:00
Greyson Parrelli
fadcc606f8 Optimize uploads during media composition.
By uploading in advance (when on unmetered connections), media messages
can send almost instantly.
2020-01-24 10:54:38 -05:00
Alex Hart
92e97e61c1 Clear cached self id on successful registration. 2020-01-24 10:54:38 -05:00
Greyson Parrelli
4b5b9fbde8 Add an encrypted key-value store.
SignalStore is backed by SQLCipher and is intended to be used instead of
TextSecurePreferences moving forward.
2020-01-24 10:54:38 -05:00
Alan Evans
711d22a0ed Do not specify random provider. 2020-01-24 10:54:38 -05:00
Greyson Parrelli
06757153b3 Add support for adding jobs with existing dependencies. 2020-01-24 10:54:38 -05:00
Greyson Parrelli
38597aea00 Add support for canceling Jobs. 2020-01-24 10:54:38 -05:00
Alex Hart
b10ce080a9 Consolidate Notification Ids to a centralized constants class. 2020-01-16 05:41:27 -05:00
Alan Evans
72e10ac597 Bump version to 4.53.7 2020-01-15 16:20:47 -05:00
Alan Evans
5b591364ba Updated language translations. 2020-01-15 16:18:45 -05:00
Alan Evans
ace1855797 Test various Argon2 parameters. 2020-01-15 16:11:41 -05:00
Alan Evans
ddedf73939 Bump version to 4.53.6 2020-01-13 14:15:48 -05:00
Alan Evans
538014935e Updated language translations. 2020-01-13 12:22:55 -05:00
Greyson Parrelli
5e9bbf1200 Reduce avatar outlines to 1px. 2020-01-13 12:13:22 -05:00
qrest
29d6d3c041 Add Xiaomi Mi A2 to echo cancellation blacklist. 2020-01-13 08:09:00 -05:00
Alan Evans
53ab303fd9 Bump version to 4.53.5 2020-01-10 16:54:40 -05:00
Alan Evans
24103ee856 Updated language translations. 2020-01-10 16:48:54 -05:00
Greyson Parrelli
20e368ab5e Update outgoing view-once message toast. 2020-01-10 16:28:30 -05:00
Greyson Parrelli
05763191ce Show the correct quoted media type for unviewed view-once messages. 2020-01-10 15:34:38 -05:00
Alan Evans
f6685fb9c9 Fix content NPE. 2020-01-10 07:48:06 -05:00
Greyson Parrelli
dbdf9602c2 Bump version to 4.53.4 2020-01-09 18:45:38 -05:00
Greyson Parrelli
6173f7049c Updated language translations. 2020-01-09 18:44:48 -05:00
Greyson Parrelli
4adacf4b98 Fix issue where you could send text with a view-once message. 2020-01-09 18:38:34 -05:00
Greyson Parrelli
8cb6ed26a1 Update view-once design. 2020-01-09 18:32:14 -05:00
Greyson Parrelli
fd7aa9ccfa Fix view-once sync and quote descriptions. 2020-01-09 18:32:14 -05:00
Alex Hart
e2a48d1714 Fix notification reply image. 2020-01-09 12:36:46 -04:00
Greyson Parrelli
a5c4c1e0a6 Converted outlines from 1px to 1dp. 2020-01-08 15:27:55 -05:00
Alan Evans
b29d03e872 Bump version to 4.53.3 2020-01-08 11:51:27 -05:00
Alan Evans
dff11092ec Updated language translations. 2020-01-08 11:50:39 -05:00
Greyson Parrelli
5e9c4e8fa3 Remove tap-to-dismiss from view-once. 2020-01-07 21:44:41 -05:00
Greyson Parrelli
c346f32762 Made view-once a non-sticky setting. 2020-01-07 16:18:07 -05:00
Greyson Parrelli
d2d450aff2 Make view-once viewed bubble match the conversation background. 2020-01-07 16:14:11 -05:00
Greyson Parrelli
09af858be8 Show upload progress for view-once messages. 2020-01-07 15:50:12 -05:00
Alan Evans
9c8a99c79c Bump version to 4.53.2 2020-01-07 15:02:43 -05:00
Greyson Parrelli
c6b9855198 Always show view-once video remaining time. 2020-01-07 15:02:43 -05:00
Alan Evans
c142928fad Updated language translations. 2020-01-07 13:45:45 -05:00
Greyson Parrelli
fc0cfd5188 Disable multiselect actions for inapplicable message types. 2020-01-07 13:09:25 -05:00
Greyson Parrelli
d9c78e5c3e Fix toolbar overlap with cutouts in recipient preferences.
Fixes #9323
2020-01-07 12:17:41 -05:00
Greyson Parrelli
b449fceca0 Dismiss conversation search after swipe-to-reply.
Fixes #9325
2020-01-07 11:13:16 -05:00
Greyson Parrelli
f0d15c0bce Fix crash when clicking group avatars. 2020-01-07 10:51:40 -05:00
Greyson Parrelli
8f031f61ea Fix group update string when re-added to group. 2020-01-06 18:36:56 -05:00
Alan Evans
502e8559f0 Bump version to 4.53.1 2020-01-06 16:53:31 -05:00
Alan Evans
8cf6f7e936 Relocate jni libs. 2020-01-06 16:52:41 -05:00
Alan Evans
0ef01cc620 Bump version to 4.53.0 2020-01-06 11:08:30 -05:00
Alan Evans
930828ef86 Updated language translations. 2020-01-06 11:08:30 -05:00
Alan Evans
9ebe920195 Move all files to natural position. 2020-01-06 11:08:30 -05:00
Greyson Parrelli
0df36047e7 Ensure transport type gets reset in onNewIntent()
Fixes #9319
2020-01-06 11:08:27 -05:00
Greyson Parrelli
94604921f9 Fix issue with swipe-to-reply triggering incorrectly.
Fixes #9227
2020-01-06 11:08:27 -05:00
Curt Brune
284fe294ac Skip monochrome cameras when switching cameras on video calls. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
ffa01d491a Do not list yourself in group membership updates. 2020-01-06 11:08:27 -05:00
Kevin T. Berstene
1d9513e743 Respect local camera aspect ratio in calls.
Fixes #8615
2020-01-06 11:08:27 -05:00
Greyson Parrelli
277c9e22f1 Show long-press-magnify in sticker preview screen. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
4e7b4da941 Implement resumable downloads. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
7e72c9c33b Add view-once tooltip. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
e0e2c3a3f5 Fix some UI bugs in view-once sending. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
3b5e444e76 Enable view-once send support. 2020-01-06 11:08:27 -05:00
Alan Evans
02006e3ff5 Update copyright year. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
8083596f19 Use FitCenter sizing for stickers. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
6551689a0c Increase the size of stickers in the conversation. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
3fbf21a34e Don't crash on packs missing metadata. 2020-01-06 11:08:27 -05:00
Alan Evans
b598431237 Separate message decryption from message processing. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
3b5d9a2cae Consider groups 'unknown' if they have no title, avatar, or members. 2020-01-06 11:08:27 -05:00
Alex Hart
3bd8aa8a86 Apply MessageStyle and fix chronology issues. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
fe5fca8eaf Sync thread order and archive status with linked devices. 2020-01-06 11:08:27 -05:00
Greyson Parrelli
848101a783 Refactor AvatarImageView#setAvatarClickHandler.
This triggered a call to Recipient#isGroup when rendering a view, which
itself could trigger a DB read. This delays the call to #isGroup to
lower the possibility of doing DB reads on the main thread.
2019-12-19 18:06:29 -05:00
Alex Hart
d7c350f987 Fix in-call proximity lock for wireless, speaker, and bluetooth. 2019-12-19 18:06:29 -05:00
Curt Brune
4c526f0b3c Update ringrtc to 0.3.0 2019-12-19 18:06:29 -05:00
Greyson Parrelli
876ffb5b13 Bump version to 4.52.4 2019-12-19 18:00:56 -05:00
Greyson Parrelli
0b14cf3d6a Show sticker install tooltips less often. 2019-12-19 17:59:42 -05:00
Greyson Parrelli
c2044b36b1 Bump version to 4.52.3 2019-12-18 20:58:07 -05:00
Greyson Parrelli
f970b4acfa Revert "Remove the Pixel 4 from the CameraX blacklist."
This reverts commit 1f5a597d50.
2019-12-18 20:55:03 -05:00
Greyson Parrelli
e69c0af613 Bump version to 4.52.2 2019-12-18 19:56:16 -05:00
Greyson Parrelli
42e2dd8b30 Updated language translations. 2019-12-18 18:04:42 -05:00
Greyson Parrelli
4fd6e7b033 Fix issue with stickers flickering on send. 2019-12-18 16:45:07 -05:00
Greyson Parrelli
3580816eac Bump version to 4.52.1 2019-12-18 00:50:02 -05:00
Greyson Parrelli
f1c2e5f194 Updated language translations. 2019-12-18 00:49:36 -05:00
Greyson Parrelli
b6d59f1d46 Fix sticker manager text wrapping issues. 2019-12-17 22:26:09 -05:00
Greyson Parrelli
a3521681e7 Bump version to 4.52.0 2019-12-17 15:38:12 -05:00
Alan Evans
ca10e1136c Updated language translations. 2019-12-17 15:37:11 -05:00
Greyson Parrelli
282fb2af0e Fix tinting issues on API 21. 2019-12-17 14:36:54 -05:00
Greyson Parrelli
1f5a597d50 Remove the Pixel 4 from the CameraX blacklist. 2019-12-17 14:36:54 -05:00
Greyson Parrelli
a32666817c Remove old image editor stickers. 2019-12-17 14:36:54 -05:00
Greyson Parrelli
b9bd3f2b4c Launch stickers. 2019-12-17 14:36:54 -05:00
Alex Hart
4173efbe5a Fix NPE on call initalization 2019-12-16 11:01:32 -04:00
yate
8121c8bd41 Remove blank MMS config overrides.
Some SIM cards include blank values for `uaProfUrl` and `userAgent`.

Passing in these blank values along with the overrides causes a 412 precondition error when downloading MMS from ATT&T.

If these values happen to be blank, then they should be removed completely from the overrides, allowing the request to use the default `uaProfUrl` and `userAgent` for the system.

Fixes #9173
2019-12-14 11:29:46 -05:00
Greyson Parrelli
6ca8218d55 Bump version to 4.51.6 2019-12-06 11:58:12 -05:00
Greyson Parrelli
653afbdd46 Updated language translations. 2019-12-06 11:57:33 -05:00
Alex Hart
4453d1752f Fix reactions scrubber positioning on vertically split multiscreen. 2019-12-06 11:43:51 -05:00
Alan Evans
5782c8a58b Make media overview view pager scrollable for long translations. 2019-12-06 11:43:51 -05:00
Greyson Parrelli
3e041befc8 Bump version to 4.51.5 2019-12-06 01:14:24 -05:00
Greyson Parrelli
6d3847c26f Updated language translations. 2019-12-06 01:10:47 -05:00
Alex Hart
4bdfc37bc1 Fix swipe to reply clobbering long press events. 2019-12-06 01:00:39 -05:00
Alan Evans
28afe0d829 Fix first media overview item selected text. 2019-12-06 01:00:39 -05:00
Greyson Parrelli
04dddd3378 Bump version to 4.51.4 2019-12-05 19:15:10 -05:00
Greyson Parrelli
23a14583fe Updated language translations. 2019-12-05 19:14:48 -05:00
Greyson Parrelli
19c83de510 Fix possible performance issues with reactions query. 2019-12-05 19:10:37 -05:00
Greyson Parrelli
e94d4b64cf Bump version to 4.51.3 2019-12-05 12:21:12 -05:00
Greyson Parrelli
7380c99f3a Updated language translations. 2019-12-05 12:20:28 -05:00
Greyson Parrelli
2961a372c3 Avoid unneccessary recipient refreshes. 2019-12-05 12:20:28 -05:00
Greyson Parrelli
5e2a4fb058 Put safeguards around Recipient creation in the IdentityStore. 2019-12-05 12:20:28 -05:00
Greyson Parrelli
a16242b9f8 Fix issues with RecipientDatabase#update(). 2019-12-05 12:20:28 -05:00
Alan Evans
acfba9ac96 Show total file size of selected items when appropriate. 2019-12-05 12:20:28 -05:00
Alan Evans
006343460e Fix long press on image thumbnail in detail view.
Allow long press to select inside select mode.
2019-12-05 12:20:28 -05:00
Alex Hart
1cc8634cc7 Display reactions in ImageView instead of TextView on message bubbles. 2019-12-05 12:20:27 -05:00
Greyson Parrelli
9f8a110428 Bump version to 4.51.2 2019-12-05 02:59:42 -05:00
Greyson Parrelli
07b4279d0b Updated language translations. 2019-12-05 02:59:42 -05:00
Greyson Parrelli
6a33b231e3 Add a FrameRateTracker to log frame drops. 2019-12-05 02:59:42 -05:00
Greyson Parrelli
b38d02061d Improve logging in RetrieveProfileJob. 2019-12-05 02:59:42 -05:00
Greyson Parrelli
f832a36a5e Prevent possible UUID-only recipient creations. 2019-12-05 02:59:42 -05:00
Alan Evans
911ca7c29d Improve storage management detail view descriptions. 2019-12-05 02:59:42 -05:00
Greyson Parrelli
544b75a2a7 Bump version to 4.51.2 2019-12-04 15:30:30 -05:00
Greyson Parrelli
56e8d4fb06 Updated language translations. 2019-12-04 15:28:45 -05:00
Greyson Parrelli
36a2278aef Add sanity checks for phone number during link process. 2019-12-04 15:28:45 -05:00
Alex Hart
0c785b85b8 Fix video icon issue. 2019-12-04 15:28:45 -05:00
Alan Evans
a0ecba147e Use decimal digit groups in file size pretty printing. 2019-12-04 15:28:45 -05:00
Alan Evans
977591ac82 Remove assertion error in recipient preferences. 2019-12-04 15:28:28 -05:00
Greyson Parrelli
fe1838d3fe Fix issue where unlocking would dismiss MainActivity. 2019-12-04 15:25:26 -05:00
Greyson Parrelli
ede06cf97d Remove unnecessary directory refreshes. 2019-12-04 15:25:26 -05:00
Greyson Parrelli
93deee6824 Attempt to fix crash in ClassicOpenHelper.
These users must have > 1.5-year-old installs that haven't been updated,
but it's still a top crash for whatever reason, so gotta try to fix it.
2019-12-04 15:25:26 -05:00
Greyson Parrelli
db19077834 Fix crash when receiving a PreKey message in a new session.
We don't allow creating recipients with only a UUID at the moment
(for good reason), but the way the decrypt method was written, it
was possible to do so. Until we have CDS, we should prefer the phone
number in scenarios like these.
2019-12-04 15:25:26 -05:00
Alex Hart
6f91f62db2 Fix InviteActivity sendSmsMessage type error. 2019-12-04 15:25:26 -05:00
Greyson Parrelli
1fc63b7597 Fix crash in conversation search. 2019-12-04 15:25:26 -05:00
Alex Hart
a079e479ec Skip call dialog if signal call is already active. 2019-12-04 15:25:26 -05:00
Alex Hart
e90705b459 Add correct archive icon to light theme. 2019-12-04 15:25:26 -05:00
Alex Hart
244db437cb Fix reaction display issues. 2019-12-04 15:25:25 -05:00
Alan Evans
6558eae032 Fix audio color on light theme. 2019-12-04 09:10:48 -05:00
Greyson Parrelli
88b54a262b Bump version to 4.51.0 2019-12-04 00:17:03 -05:00
Alan Evans
4fa8b8a4bd Updated language translations. 2019-12-04 00:08:01 -05:00
Greyson Parrelli
cc0ced9a81 Add internal pre-alpha support for storage service. 2019-12-04 00:08:01 -05:00
Alan Evans
52447f5e97 Add storage management features. 2019-12-04 00:07:49 -05:00
Alex Hart
bceb69b284 Add internal pre-alpha support for receiving reactions. 2019-12-04 00:07:49 -05:00
Alex Hart
a8d826020d Implement new video call experience. 2019-12-04 00:07:49 -05:00
Alan Evans
2ada7f87f2 Update lib phone number. 2019-12-04 00:07:49 -05:00
Alan Evans
7f8ca58762 Add internal pre-alpha support for Registration Lock v2. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
058c25808b Clean up website auto-update APKs.
I think previously we thought that because we always used the same
filename, that we were just overwring the same file repeatedly. However,
DownloadManager will actually append numbers to a filename instead of
overwriting, so we were generating a ton of files.

Now we just clear out any previous files before downloading a new one.

Related to #9033
2019-12-04 00:07:49 -05:00
Greyson Parrelli
c1e6b6b086 Add better Loader performance logs. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
b0a6bb79f6 Fix issue with setting Note to Self color.
Fixes #9235
2019-12-04 00:07:49 -05:00
Greyson Parrelli
de52bf50a2 Improve image and sticker notifications. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
207dd23c86 Fix performance issue with large number of notifications.
Constructing the notification would call KeyCachingService#isLocked()
many times in a loop. This call is slow, because when the device isn't
locked, it would construct the master secret each time, which can take
50+ ms. Do that twice in a loop a hundred times, and it adds up.

This simplified #isLocked to avoid the unnecessary master secret
generation.
2019-12-04 00:07:49 -05:00
Alex Hart
7e0de29dd7 Add notification policy permission and runtime check.
Fixes #9217
2019-12-04 00:07:49 -05:00
Greyson Parrelli
eaa8f1ee8f Ignore expiration updates from groups you've left. 2019-12-04 00:07:49 -05:00
Alex Hart
fb494c1151 Implement new invite screen. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
49ecd9ef5d Added additional logging in RetrieveProfileJob. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
8772214fd4 Increase number of log files to 7. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
5b74d0cbeb Improve activity lifecycle logging. 2019-12-04 00:07:49 -05:00
Greyson Parrelli
1e7c93007d Convert the conversation list into a real fragment.
It was a fragment before, but it's functionality was inappropriately
split between the various layers.

This also sets us up better to do tablet stuff in the future, if we
choose to do that.
2019-12-04 00:07:49 -05:00
Greyson Parrelli
608815a69b Add internal pre-alpha support for usernames. 2019-12-04 00:07:42 -05:00
Greyson Parrelli
fb49efa34d Add internal pre-alpha libsignal support for reactions. 2019-12-04 00:07:13 -05:00
Android Team
b20e8616ec Move libsignal-service-java into this repo.
libsignal-service-java repo commit: 1a01c22636
2019-12-04 00:07:13 -05:00
Alan Evans
acf78b6b63 Make new top level gradle file, make app dir and move build.gradle. 2019-12-04 00:07:13 -05:00
Alex Hart
d68fe928b8 Fix nav bar contrast on sticker preview. 2019-12-04 00:07:13 -05:00
Alex Hart
db4d561d9e Fix nav bar color on shared contacts edit screen. 2019-12-04 00:07:07 -05:00
Alex Hart
6933ca50a7 Implement new Message Request UI. 2019-12-04 00:07:07 -05:00
Greyson Parrelli
88c0e6f8ab Fail a job when you can't instantiate it.
This will still crash, but prevent apps from getting into crash loops
when we have bad data in a job.
2019-11-25 11:32:16 -05:00
Greyson Parrelli
6cd4728e3c Update job serialized data after retry. 2019-11-25 11:32:16 -05:00
Greyson Parrelli
97cc82837c Don't backup the JobsDatabase. 2019-11-25 11:32:16 -05:00
Greyson Parrelli
5f0b0e8495 Bump version to 4.50.6 2019-11-25 11:32:07 -05:00
Greyson Parrelli
c837d590ab Removed RefreshUnidentifiedDeliveryAvailabilityJob.
It's been long enough -- it's no longer necessary to check.

Also, the service is going to start returning certs no matter what, so
at this point it's just an unnecessary network call.
2019-11-25 11:32:06 -05:00
Greyson Parrelli
6108a32631 Prevent reading UUIDs from external contacts. 2019-11-25 11:29:58 -05:00
Greyson Parrelli
6d78e1760d Fix possible crash in very old database migration.
The NumberMigrator constructor is crashing. One possibility is that this
migration is running before the user registered, in which case they
wouldn't have a number. Wrapped the parts that don't need to run in this
situation in an `if` block.
2019-11-25 11:29:58 -05:00
Greyson Parrelli
c7b7242eff Fix issues with blocking and MMS groups.
Fixes #9218.

Note that this removes MMS group blocking for now, just because it never
really worked, and I don't want to hotfix in a feature.
2019-11-25 11:29:19 -05:00
Greyson Parrelli
77c687efcf Bump version to 4.50.5 2019-11-21 13:28:23 -05:00
Greyson Parrelli
274af2f010 Ensure group message is being sent to a group. 2019-11-21 13:28:00 -05:00
Greyson Parrelli
6cd5100530 Ensure Recipient.self() is available. 2019-11-21 13:24:54 -05:00
Alan Evans
115a408b0b Bump version to 4.50.4 2019-11-18 09:36:14 -05:00
Alan Evans
d983016137 Updated language translations. 2019-11-18 09:33:53 -05:00
Greyson Parrelli
a8309b6b2b Fix attachment sizes during backup exports. 2019-11-18 09:19:11 -05:00
Alan Evans
e241589c92 Bump version to 4.50.3 2019-11-15 15:43:47 -05:00
Alan Evans
dcb6240a6a Updated language translations. 2019-11-15 15:39:39 -05:00
Alex Hart
599bb5ab0f Update insights copy and queries. 2019-11-15 16:33:54 -04:00
Alan Evans
739fe584c6 Bump version to 4.50.2 2019-11-14 14:49:48 -05:00
Alan Evans
920d1c6207 Updated language translations. 2019-11-14 14:49:48 -05:00
Greyson Parrelli
c1d3d26a15 Removed unnecessary subtext in Insights. 2019-11-14 14:49:48 -05:00
theBoatman
e3b66dc7e8 Fixing RealtimeSleepTimer to work in concurrent threads. 2019-11-14 13:56:12 -05:00
Alan Evans
dfa08d1356 In dark mode, use a dark theme base for RegistrationLockDialog and RationaleDialog.
Fixes #8995
Closes #9077
2019-11-14 13:51:01 -05:00
Curt Brune
6da734c2f9 Update ringrtc to 0.2.0 2019-11-13 14:05:22 -08:00
Alan Evans
a9f3141a77 Create android.yml running qa task. 2019-11-13 15:49:22 -05:00
Alan Evans
ee267d4702 Bump version to 4.50.1 2019-11-13 14:40:04 -05:00
Alan Evans
c39174ed8a Updated language translations. 2019-11-13 14:40:04 -05:00
Greyson Parrelli
9c872b6da6 Fix issue where SMS groups showing up as 'Unnamed Group'. 2019-11-13 11:37:49 -05:00
Greyson Parrelli
2924a09936 Don't run UuidMigration if not registered. 2019-11-13 11:37:49 -05:00
Greyson Parrelli
b9da012cc4 Fix media send issues on Android 4.4.
Before lollipop, Android would ignore activity results for activities
launched with singleTask. So I switched to singleTop, since that should
still solve the problem of double-activity-opens without running into
this issue.

Fixes #9149
2019-11-13 11:37:49 -05:00
Alan Evans
8626d41787 I18N for "Unlock Signal". 2019-11-13 11:37:49 -05:00
Alex Hart
c58705722a Fix Insights Adapter item text clashing. 2019-11-13 11:37:49 -05:00
Greyson Parrelli
c702ff676a Support additional sync behavior for linked devices. 2019-11-13 11:37:49 -05:00
Alan Evans
995569dd50 Bump version to 4.50.0 2019-11-12 10:55:41 -05:00
Greyson Parrelli
a0dfd42527 Fix possible context crash. 2019-11-12 10:55:41 -05:00
Alex Hart
a7dd78cce6 Implement in-app insights. 2019-11-12 10:55:41 -05:00
Greyson Parrelli
e2e9cd40b3 Blacklist additional phone models from the new camera. 2019-11-11 18:13:34 -05:00
Alan Evans
e4fc6f41b8 Schedule first backup after restore for 24hrs time. 2019-11-11 13:00:01 -05:00
Alan Evans
778b2a0d27 Remove old strings file. 2019-11-10 09:23:44 -05:00
Alan Evans
64cd15ca0b Make AlbumThumbnailView_plus non-translatable. 2019-11-10 09:23:43 -05:00
Alan Evans
1e46c3c0ba Make app_name non-translatable. 2019-11-10 09:23:43 -05:00
Alan Evans
91772b4e11 Exclude non-translatable strings.
Lint exclude ExtraTranslation.
2019-11-10 09:23:42 -05:00
Alan Evans
af5c7cb7ca Added dotted lines to time icons. 2019-11-09 07:45:53 -05:00
Alan Evans
e760474fa9 Clear unauthorized flag on connect. 2019-11-09 07:01:08 -05:00
Greyson Parrelli
28bb88e347 Lower max number of JobScheduler IDs.
Some devices can only handle 25 job IDs, so I lowered it to 20.
2019-11-09 07:01:08 -05:00
Curt Brune
17a1fe97ca Send hangup message when terminating on call errors.
When errors occur during a call, attempt to send the remote peer a
hangup message before terminating the call.  This allows the remote
peer to shutdown their side of the call in a timely manner.
2019-11-09 07:01:08 -05:00
Alan Evans
7348237862 Lint.
- baseline update.
- eradicate ButtonOrder.
- eradicate VectorRaster.
- eradicate HardcodedText.
2019-11-09 07:01:08 -05:00
Alex Hart
4e66db5dc1 Fix timer disabled icon. 2019-11-09 07:01:08 -05:00
Alex Hart
ffa6c9acd1 Utilize icon_tint color filter for UpdateItem icons. 2019-11-09 07:01:08 -05:00
Greyson Parrelli
b3e66a9259 Prevent creation of UUID-only recipients. 2019-11-09 07:01:08 -05:00
Alan Evans
5c0cf8c1f0 English staging app name. 2019-11-09 07:01:08 -05:00
Alex Hart
89c716fca4 Fix layout gravity on recv long message footer. 2019-11-09 07:01:08 -05:00
Alan Evans
aae9830dfa Use lib-signal-servivce 2.15.1 2019-11-09 07:01:08 -05:00
Alan Evans
48c72697c1 Add protobuf lite exception for proguard. 2019-11-09 07:01:08 -05:00
Greyson Parrelli
aac7e9ea53 Fix issue with ShareActivity contact display. 2019-11-09 07:01:08 -05:00
Alan Evans
a1b10b3222 Update to protobuf 3.10 lite.
Update fingerprint logic.
Update for additional validation around SignalServiceAddresses.

Co-authored-by: Greyson Parrelli <greyson@signal.org>
2019-11-09 07:01:08 -05:00
Curt Brune
2ab8db33e3 Update ringrtc to 0.1.9 2019-11-09 07:01:08 -05:00
Curt Brune
2b1386232f Implement logging interface for ringrtc-0.1.8
Implement the org.signal.ringrtc.Log.Logger interface, using
org.thoughtcrime.securesms.logging.Log as the underlying logger.

This allows ringrtc to log in the same way as the rest of the
application.
2019-11-09 07:01:07 -05:00
Alex Hart
7bb1caa22e Remove unused pictures that were captured outside of the in-app camera. 2019-11-09 07:01:07 -05:00
Alex Hart
72c14b8651 Apply new Keyboard and Dial Pad icons. 2019-11-09 07:01:07 -05:00
Alex Hart
f85c3bb1e6 Add feature flag to new Profile display. 2019-11-09 07:01:07 -05:00
Alan Evans
d8714fe3b4 Delegate to library Base64. 2019-11-09 07:01:07 -05:00
Alex Hart
c54c1907b6 Fix nav bar colors on reg and call screen. 2019-11-09 07:01:07 -05:00
Greyson Parrelli
55257155dd Handle ProtocolInvalidMessageExceptions with no sender. 2019-11-09 07:01:07 -05:00
alex-signal
55a8bd86de Consolidate profile display labels. 2019-11-09 07:01:07 -05:00
Greyson Parrelli
c60909272b UUID migration. 2019-11-09 07:01:07 -05:00
Greyson Parrelli
3dcc2d8171 Moved DirectoryHelper. 2019-11-09 07:01:07 -05:00
Greyson Parrelli
0ccbb22e4c Unsubscribe from old recipient observers in ConversationActivity. 2019-11-09 07:01:07 -05:00
Greyson Parrelli
0ffa10eaea Bump version to 4.49.18 2019-11-08 20:27:14 -05:00
Alan Evans
9824073023 Keep line numbers within R8. 2019-11-08 16:17:32 -05:00
Alan Evans
d2adc11a2d New languages.
bn,bs,ms,mr,ta,ur
2019-11-08 16:17:32 -05:00
Alan Evans
4d0b870c88 Updated language translations. 2019-11-08 16:17:32 -05:00
Alan Evans
840997cb7d Translate tasks. 2019-11-08 11:41:38 -05:00
Alex Hart
e4406621ed Fix lint issues. 2019-11-08 11:41:38 -05:00
Greyson Parrelli
7f96ee0b62 Clear DATA_HASH column. 2019-11-08 11:30:48 -05:00
Alan Evans
17f850b31a Ensure that we can still navigate when we get a response from server. 2019-11-08 11:19:57 -05:00
Alan Evans
5d87ad0301 Ignore period in phone number entry.
Fixes #9168
2019-11-08 11:19:32 -05:00
Greyson Parrelli
a33eeed6d3 Bump version to 4.49.17 2019-11-07 16:18:27 -05:00
Alex Hart
554ce29337 Adjust Typing Indicator margin in groups. 2019-11-07 16:03:13 -05:00
Alex Hart
6054d0b36f Nullify Data Hash when Data is Nullified 2019-11-07 16:02:56 -05:00
Greyson Parrelli
8ba15cf3b4 Bump version to 4.49.16 2019-11-06 16:42:16 -05:00
Greyson Parrelli
b15e5b4867 Fix potential invalid context crash. 2019-11-06 16:38:28 -05:00
Greyson Parrelli
544511905a Fix issue where deduped media might not be kept in sync. 2019-11-06 16:37:25 -05:00
Greyson Parrelli
02e3f511bd Bump version to 4.49.15 2019-11-04 11:30:08 -05:00
Alex Hart
0539b071e7 Fix message info icon inflation error on API 19 devices.
Fixes #9148
2019-11-04 11:29:31 -05:00
Greyson Parrelli
36e400650c Fix backup restore issue.
Fixes #9133
2019-11-04 11:21:11 -05:00
Greyson Parrelli
d8930daf4b Bump version to 4.49.14 2019-11-01 17:23:52 -04:00
Greyson Parrelli
17b5816d5b Skip corrupt attachments during backup restore.
Instead of aborting the entire backup restore.

Related to #8355
2019-11-01 17:11:10 -04:00
Curt Brune
e574c81ea2 Update ringrtc to 0.1.7.2 2019-11-01 12:26:00 -07:00
Greyson Parrelli
6799a2f841 Bump version to 4.49.13 2019-10-29 16:10:09 -04:00
Curt Brune
61fb20f412 Update ringrtc to v0.1.7 2019-10-29 12:46:01 -07:00
Alan Evans
47f648e7bc Correct text on registration lock fragment. 2019-10-29 13:47:14 -04:00
Alan Evans
064c0ddb82 Manually restrict to 30 digits to allow pasting containing any number of spaces. 2019-10-29 09:59:53 -04:00
Greyson Parrelli
b42c42007d Bump version to 4.49.12 2019-10-28 19:48:07 -04:00
Greyson Parrelli
807cdfce2e Increase backup passphrase input length to 35.
The way pasting works, it could prevent you from pasting in text if you
included the spaces in between number chunks.
2019-10-28 19:47:05 -04:00
Greyson Parrelli
43dc3aeebd Fix 'direct share' icon rendering issue.
Fixes #9138
2019-10-28 16:51:06 -04:00
Greyson Parrelli
0369c5ee16 Make avatars larger in conversations. 2019-10-28 16:46:21 -04:00
Greyson Parrelli
3df2390fe4 Bump version to 4.49.11 2019-10-28 12:28:58 -04:00
Greyson Parrelli
9ec4a7af0f Update max video duration for MMS. 2019-10-28 12:09:54 -04:00
Alex Hart
70636fb4a7 Blacklist Pixel4 from CameraX (#319)
* Blacklist Pixel4 from CameraX

* Create isSupported method
2019-10-28 13:07:28 -03:00
Alex Hart
3c4efdd8f9 Apply proper color when action mode destroyed 2019-10-28 12:00:59 -04:00
Greyson Parrelli
80deb301e5 Bump version to 4.49.10 2019-10-25 14:00:33 -07:00
Greyson Parrelli
5eabfdc34c Fix crash if you leave during log generation. 2019-10-25 14:00:33 -07:00
Greyson Parrelli
5e96832666 Disable video capture for legacy camera devices. 2019-10-25 13:54:38 -07:00
Alan Evans
1ccce24cf8 Fix drawable crash on API 19. 2019-10-25 15:33:34 -04:00
Greyson Parrelli
d59e4f2da7 Bump version to 4.49.9 2019-10-24 14:20:09 -07:00
Greyson Parrelli
a254c1a7b2 Updated language translations. 2019-10-24 14:17:19 -07:00
Alex Hart
82cc610938 Apply themed context to SingleRecipientNotificationBuilder 2019-10-24 17:59:34 -03:00
Greyson Parrelli
becf7c40e8 Bump version to 4.49.8 2019-10-23 23:45:13 -07:00
Greyson Parrelli
ed21c3ca03 Improve send button in media send flow.
Fixes #8988
2019-10-23 23:45:13 -07:00
Greyson Parrelli
631005e565 CameraX cleanup. 2019-10-23 23:45:13 -07:00
Greyson Parrelli
b57fab8c75 Make MediaSendActivity singleTask. 2019-10-23 23:45:13 -07:00
Greyson Parrelli
4260a8436b Fix possible de-duping issues.
- Clean bad hashes from earlier release.
- Fix file equality comparison.
- Given our new de-duping, we don't want to run into a situation where two
simultaneous compressions could be happening on the same image.
2019-10-23 23:45:13 -07:00
Greyson Parrelli
23d478191f Don't render 'null' contact labels. 2019-10-23 23:45:13 -07:00
Greyson Parrelli
d075a33d4e Fix issue where video controls may be missing.
Fixes #9121
2019-10-23 23:45:13 -07:00
Greyson Parrelli
7507dadbe7 Bump version to 4.49.7 2019-10-22 14:17:24 -04:00
Greyson Parrelli
bfd0363390 Fix potential tooltip crash. 2019-10-22 14:17:01 -04:00
Greyson Parrelli
cfb22825f4 Fix recent conversation query. 2019-10-22 13:49:31 -04:00
Greyson Parrelli
d37fafbfe7 Bump version to 4.49.6 2019-10-22 13:02:26 -04:00
Greyson Parrelli
2dc2eb5835 Updated language translations. 2019-10-22 13:02:26 -04:00
Greyson Parrelli
019d036f69 Fix soft nav color in conversation list.
Going in and out of multi-select mode would screw it up.

This fixes it by setting the flags correctly instead of blasting them
all away.
2019-10-22 13:02:26 -04:00
Greyson Parrelli
f1ca5fc8e2 Exclude inactive groups from search results where appropriate.
Fixes #9091
Fixes #9080
2019-10-22 12:41:20 -04:00
Greyson Parrelli
9089fc4001 Fix potential display issues in Message Details screen. 2019-10-22 11:00:03 -04:00
Greyson Parrelli
b281b817ba Add additional logging around attachment upload/deletion. 2019-10-22 10:52:55 -04:00
Greyson Parrelli
cee6736656 Fix flickering 'about' section in group recipient preferences.
Gotta disable those pesky layout animations.

Fixes #9092
2019-10-22 10:30:11 -04:00
Greyson Parrelli
350ca059b9 Pick camera resolution based on screen resolution. 2019-10-22 10:16:14 -04:00
Greyson Parrelli
a7cc5bdc5e Ensure keyboard is hidden when going to the gallery.
Fixes #9120
2019-10-22 09:50:01 -04:00
Greyson Parrelli
2893dfff60 Bump version to 4.49.5 2019-10-21 20:05:31 -04:00
Greyson Parrelli
1c14f06734 Updated language translations. 2019-10-21 20:04:20 -04:00
Greyson Parrelli
ff053437e3 Fix issue where album rail wasn't immediately shown.
Fixes #9111
2019-10-21 20:04:20 -04:00
Alex Hart
03dc220cea Fix crash related to unsupported camera mode.
Fixes #9106
2019-10-21 19:32:19 -04:00
Greyson Parrelli
097f97b5e4 Add system to allow skipping attachment compression. 2019-10-21 19:32:19 -04:00
Alex Hart
95d3db3260 Add ic_message webp files 2019-10-21 15:30:20 -03:00
Greyson Parrelli
0485ae603b Set targetResolution to something reasonable for camera capture. 2019-10-21 10:58:07 -04:00
Alex Hart
2f93da6f1a Fix wrong icon color in expiry footer 2019-10-21 11:50:32 -03:00
Alex Hart
78f3e28974 Fix progress wheel color in share screen 2019-10-21 10:53:18 -03:00
Alex Hart
fecd8300c3 Swap ValueAnimator with version from NineOldAndroids 2019-10-21 10:51:04 -03:00
Alex Hart
262f90dbe7 Add new info icon to message details view 2019-10-21 10:09:54 -03:00
Alex Hart
ed271c6f3e Fix longmessage and shared contact footer alignment 2019-10-21 10:00:28 -03:00
Greyson Parrelli
3fa5843c93 Bump version to 4.49.4 2019-10-21 01:13:19 -04:00
Greyson Parrelli
7f544cb3e5 Updated language translations. 2019-10-21 01:12:51 -04:00
Greyson Parrelli
9f4d40a364 Revert "Prevent compression of images without EXIF data."
This reverts commit 8449d75684.
2019-10-21 01:00:31 -04:00
Greyson Parrelli
09f0c5b63f Fix bug in manual conversation search query submission.
Fixes #9115
2019-10-21 00:49:06 -04:00
Greyson Parrelli
53e0dc5dee Potential MMS download fix for some users.
Special thanks to @mdaniel

Fixes #8571
2019-10-21 00:36:54 -04:00
Greyson Parrelli
8b06051e7c Fix blurhash being visible on transparent images. 2019-10-21 00:21:53 -04:00
Greyson Parrelli
660ec88202 Fix data deduping issues.
Fixes #9109
2019-10-21 00:21:48 -04:00
Greyson Parrelli
b9057a1c11 Use fallback images for Giphy results. 2019-10-20 01:13:02 -04:00
Greyson Parrelli
1f85b1f3d2 Bump version to 4.49.3 2019-10-19 12:37:00 -04:00
Greyson Parrelli
71f78f03f4 Updated language translations. 2019-10-19 12:34:30 -04:00
Greyson Parrelli
4b3d129097 Cleanup some possible bad RecipientIds in the MMS table. 2019-10-19 12:31:06 -04:00
Greyson Parrelli
daeb823399 Fix CameraX crash. 2019-10-19 12:25:40 -04:00
Greyson Parrelli
c7f76c5d1c Add a util to safely set a MediaMetadataRetriever data source. 2019-10-19 12:23:23 -04:00
Greyson Parrelli
9ba1391a1e Fix issue with non-contact avatar colors not updating. 2019-10-19 12:15:14 -04:00
Greyson Parrelli
5d137465e8 Bump version to 4.49.2 2019-10-18 18:46:07 -04:00
Greyson Parrelli
78cbb3c073 Updated language translations. 2019-10-18 18:45:43 -04:00
Greyson Parrelli
097d95428a Fix conversation list toolbar styling. 2019-10-18 17:34:01 -04:00
Greyson Parrelli
2cfb6ede7f Increase record button size. 2019-10-18 17:34:01 -04:00
Greyson Parrelli
695663a5b1 Log more data about video capture support. 2019-10-18 17:34:01 -04:00
Greyson Parrelli
a2204c8370 Update video recording tooltip text. 2019-10-18 17:34:01 -04:00
Alex Hart
8c4757ea02 Fix safety number theme 2019-10-18 17:34:01 -04:00
Greyson Parrelli
85821274fa Don't render null phone number labels. 2019-10-18 17:34:01 -04:00
Greyson Parrelli
a8b1ec8e52 Increase compose maxLines to 5. 2019-10-18 17:34:01 -04:00
Alex Hart
adbdaebd69 Fix invite screen theme. 2019-10-18 17:33:45 -04:00
Alex Hart
c2da4fcd7d Update CameraX to Alpha06 and bring in new View / Module code. 2019-10-18 17:36:00 -03:00
Greyson Parrelli
46ebff3659 Bump version to 4.49.1 2019-10-18 13:58:59 -04:00
Greyson Parrelli
452ccd0350 Updated language translations. 2019-10-18 13:58:35 -04:00
Alan Evans
6e6c809690 Use lighter-weight shadow view. 2019-10-18 13:51:56 -04:00
Greyson Parrelli
7b5c1904cf Update contact list divider styling. 2019-10-18 13:09:20 -04:00
Alex Hart
c0aa9d7587 Update preference divider colors 2019-10-18 13:09:20 -04:00
Alex Hart
5d03e3d516 Apply video recording permissions checks and error handling. 2019-10-18 13:09:20 -04:00
Greyson Parrelli
2bc3a4417f Fix possible crash when retrieving a video thumbnail. 2019-10-18 11:10:26 -04:00
Greyson Parrelli
59d03cbeb2 Address possible issues with AvatarMigrationJob. 2019-10-18 11:08:06 -04:00
Alex Hart
f9f9ae68f5 Fix MediaSendActivity send button metrics and positioning. 2019-10-18 10:49:54 -03:00
Alex Hart
88f2b67984 Fix crash on conversation color picker open. 2019-10-18 10:33:10 -03:00
Greyson Parrelli
44dba4bd98 Only show video tooltip if capable. 2019-10-18 09:31:01 -04:00
Alan Evans
ef585eba42 Revert "Fix invite drawable on API 21."
This reverts commit 78fbfe40736dd8c9ccafb402aa7fc6921c1d4496.

We have turned on AppCompatDelegate.setCompatVectorFromResourcesEnabled(true) now for API19.
2019-10-18 09:15:20 -04:00
Alex Hart
42967dab13 Apply proper tinting to conversation app bar. 2019-10-18 09:55:27 -03:00
Greyson Parrelli
4f75d1a5db Bump version to 4.49.0 2019-10-17 22:45:56 -04:00
Greyson Parrelli
debacbdf58 Updated language translations. 2019-10-17 22:44:32 -04:00
Greyson Parrelli
12c4283c30 Conditionally show a toolbar shadow in the conversation list. 2019-10-17 22:23:27 -04:00
Greyson Parrelli
096c9e0ff7 Ensure videos are paused properly in MediaSendActivity. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
2f23a13a6f Fix issue where video playback controls sometimes don't appear. 2019-10-17 21:33:52 -04:00
Alan Evans
bdadbaaac4 Remove larger images for link preview intro.
(I bet you thought they would be together forever).
2019-10-17 21:33:52 -04:00
Alan Evans
16f41555ba Local SMS rate limiting. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
8c037456e7 Warm up LiveRecipientCache at launch. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
feccee557e Include better defaults for ConversationActivity. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
67f5605bc4 Block in RestStrategy until PushDecryptJobs finish. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
ccb18cd46c Added JobTracker. 2019-10-17 21:33:52 -04:00
Alan Evans
5b1d91016c Fix backup sorting logic and do not delete non-backups in path. 2019-10-17 21:33:52 -04:00
Alan Evans
27ab04ab41 Add version and spread out witness information. 2019-10-17 21:33:52 -04:00
alex-signal
9432a45b39 Implement blur-hash based low resolution thumbnail previews. 2019-10-17 21:33:52 -04:00
alex-signal
9e3475ed94 Upgrade Gradle to 5.6.2 and AGP to 3.5.1 2019-10-17 21:33:52 -04:00
Alan Evans
86d088bce2 Improved registration flow. 2019-10-17 21:33:52 -04:00
alex-signal
a135e7efa2 Check DND settings before show activity or play ring or vibrate. 2019-10-17 21:33:52 -04:00
tzm
c247935f1a Fix NPE when has no contact permissions.
Fixes #9048

Co-authored-by: Alan Evans <alan@signal.org>
2019-10-17 21:33:52 -04:00
Alan Evans
31657f5c15 Gradle witness sort dependencies and move to own auto generated file. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
bcecc30d33 Disallow RecipientId's of zero. 2019-10-17 21:33:52 -04:00
Greyson Parrelli
7193252d77 Fix TooltipPopup positioning. 2019-10-17 21:33:51 -04:00
Greyson Parrelli
5b682a3a3d Use our own location retriever. 2019-10-17 21:33:51 -04:00
Greyson Parrelli
6b8659a393 Move JobManager to ApplicationDependencies. 2019-10-17 21:33:51 -04:00
Alan Evans
14557d3dc1 Change default GZIP behavior on Base64.decode(String).
Remove only reference to Base64.decode(byte[]).
2019-10-17 21:33:51 -04:00
Curt Brune
03cbee0277 Add ringrtc support.
RingRTC provides Signal Messenger applications with a common interface
for video and voice calling services built on top of WebRTC.
2019-10-17 21:33:51 -04:00
alex-signal
adc0907906 Copy image to encrypted blob and delete from device immediately.
Fixes #9097
2019-10-17 21:33:51 -04:00
Alan Evans
f14a71a076 Update Lint suppressions. 2019-10-17 21:33:51 -04:00
alex-signal
12c2b53f7c Set icon to themed version via attribute.
Fixes #9054
2019-10-17 21:33:51 -04:00
alex-signal
ff60b5b731 Add in-app video recording for supported devices. 2019-10-17 21:33:51 -04:00
alex-signal
43954a176a Apply new Signal icons and color palette. 2019-10-17 21:33:51 -04:00
Alex Hart
d698d3bd6f Added support for view-once video. 2019-10-17 16:01:34 -04:00
Greyson Parrelli
50a81c0e60 Added a simple staging build config. 2019-10-17 16:01:34 -04:00
Greyson Parrelli
b0b8377a8e Migrate notification channels to recipientId's. 2019-10-17 16:01:34 -04:00
alex-signal
7d02bb8487 Store file hash to avoid data duplication. 2019-10-17 16:01:34 -04:00
alex-signal
8449d75684 Prevent compression of images without EXIF data. 2019-10-17 16:01:34 -04:00
Greyson Parrelli
b89163bb14 Migrate avatars to use recipientId filenames. 2019-10-17 16:01:34 -04:00
Greyson Parrelli
b7ce220600 Updated libsignal version to 2.13.8 2019-10-15 10:35:59 -04:00
Greyson Parrelli
948079a42e Bump version to 4.48.17 2019-10-15 10:35:15 -04:00
Greyson Parrelli
de1c6cdd0c Fix crash when MMS messages have no 'from' address. 2019-10-15 10:35:15 -04:00
Greyson Parrelli
37147fb0a5 Bump version to 4.48.16 2019-10-08 21:28:54 -07:00
Greyson Parrelli
33334f80c3 Add back proper support for unknown recipients.
Fixes #9085
2019-10-08 21:28:35 -07:00
Greyson Parrelli
36286da9bd Bump version to 4.48.15 2019-10-08 14:23:29 -07:00
Greyson Parrelli
2248acb9f2 Remove unnecessary resolves. 2019-10-08 14:23:29 -07:00
Greyson Parrelli
3632a2cc95 Hide no-name contacts from system search results. 2019-10-08 13:38:20 -07:00
Greyson Parrelli
9447ea12cb Remove concept of 'unknown' recipient. 2019-10-08 13:33:13 -07:00
Greyson Parrelli
89c2329fdf Bump version to 4.48.14 2019-10-07 16:52:36 -07:00
Greyson Parrelli
84012c7adb Fix crash in SmsMigrator. 2019-10-07 16:41:47 -07:00
Greyson Parrelli
d7395af774 Simplify recipient inserts. 2019-10-07 16:31:04 -07:00
Greyson Parrelli
be4daff0f3 Ensure recipient models are up-to-date. 2019-10-07 16:31:04 -07:00
Greyson Parrelli
c2459d0a31 Bump version to 4.48.13 2019-10-04 12:13:16 -04:00
Greyson Parrelli
5f993ed0f7 Fix threading issue in RecipientDatabase. 2019-10-04 12:07:46 -04:00
Greyson Parrelli
acea24c19c Reduce Recipient refreshes. 2019-10-04 10:52:43 -04:00
Greyson Parrelli
82b5d58d04 Fix threading issues in LiveRecipient. 2019-10-04 10:52:43 -04:00
Greyson Parrelli
af2990fa08 Bump version to 4.48.12 2019-10-03 16:08:18 -04:00
Greyson Parrelli
0fa48540e1 Fix migration of old pending SMS sends. 2019-10-03 16:07:53 -04:00
Greyson Parrelli
0f06b96832 Bump version to 4.48.11 2019-10-03 11:18:51 -04:00
Greyson Parrelli
4f423be6f9 Updated language translations. 2019-10-03 11:18:07 -04:00
Greyson Parrelli
bea21ed5ff Further recipient insertion improvements. 2019-10-03 11:17:48 -04:00
Greyson Parrelli
a9cff032f5 Bump version to 4.48.10 2019-10-02 20:44:22 -04:00
Greyson Parrelli
b2d02d4ace Add extra protections to recipient insertions. 2019-10-02 20:13:49 -04:00
Greyson Parrelli
066df77abf Revert "Use recipientId's in ContactSelectionListAdapter."
This reverts commit 89e075c56e.
2019-10-02 19:26:24 -04:00
Greyson Parrelli
b38a3e6259 Remove unnecessary recipient resolves. 2019-10-02 19:16:59 -04:00
Greyson Parrelli
d78919acf8 Bump version to 4.48.9 2019-10-02 12:36:24 -04:00
Greyson Parrelli
af96d11188 Pretty-print missing recipientId crashes. 2019-10-02 12:22:26 -04:00
Greyson Parrelli
5e1bef26ed Fix display of profile names in FTS results. 2019-10-02 12:22:26 -04:00
Greyson Parrelli
95333eccd4 Cleanup bad recipients. 2019-10-02 12:22:26 -04:00
Greyson Parrelli
89e075c56e Use recipientId's in ContactSelectionListAdapter. 2019-10-02 11:24:55 -04:00
Greyson Parrelli
d026498a8c Use recipientId's in SearchRepository. 2019-10-02 11:24:55 -04:00
Greyson Parrelli
bae381e6f8 Bump version to 4.48.8 2019-10-01 08:20:16 -04:00
Greyson Parrelli
050f7a24c9 Updated language translations. 2019-10-01 08:19:46 -04:00
Greyson Parrelli
77ad1ea729 Prevent ConversationActivity recipientId crash. 2019-10-01 08:17:25 -04:00
Greyson Parrelli
bf667c0cfc Revert "Add logging to track down ConversationActivity crash."
This reverts commit 447236ee38.
2019-10-01 08:16:57 -04:00
Greyson Parrelli
ccb8ef98b4 Bump version to 4.48.7 2019-09-30 15:19:41 -04:00
Greyson Parrelli
a1f0660339 Updated language translations. 2019-09-30 15:19:24 -04:00
Greyson Parrelli
447236ee38 Add logging to track down ConversationActivity crash. 2019-09-30 15:19:24 -04:00
Alan Evans
ebf3b0dfe1 Change versionCode for universal builds. 2019-09-30 14:16:49 -04:00
Greyson Parrelli
ee9216df8a Ensure group status is available in ConversationAdapter constructor. 2019-09-30 14:15:19 -04:00
Greyson Parrelli
3e34668232 Bump version to 4.48.6 2019-09-28 00:16:41 -04:00
Curt Brune
8f8f41f184 Localize call audio and video activation code 2019-09-28 00:16:09 -04:00
Greyson Parrelli
4f7cba8d7c Bump version to 4.48.5 2019-09-27 14:26:08 -04:00
Greyson Parrelli
00b719c783 Updated language translations. 2019-09-27 14:22:13 -04:00
Greyson Parrelli
b03eccec33 Persist the JobFactory key after job migrations. 2019-09-27 14:18:15 -04:00
Greyson Parrelli
5805539deb Revert "Potential MMS download fix for some users."
This reverts commit 1e375ec494.
2019-09-27 14:02:01 -04:00
Greyson Parrelli
1b48fd07a3 Bump version to 4.48.4 2019-09-26 18:32:28 -04:00
Greyson Parrelli
1e375ec494 Potential MMS download fix for some users.
Special thanks to @mdaniel

Fixes #8571
2019-09-26 18:32:28 -04:00
Greyson Parrelli
ee9acf2687 Show tooltip for swipe-to-reply. 2019-09-26 16:37:09 -04:00
Greyson Parrelli
1d8e85fcad Updated the feel of swipe-to-reply. 2019-09-26 16:36:52 -04:00
Greyson Parrelli
4e2afa7362 Fix some more broken JobMigrations. 2019-09-26 11:18:04 -04:00
Greyson Parrelli
d06564c7b9 Bump version to 4.48.3 2019-09-25 19:12:24 -04:00
Greyson Parrelli
ced48d0788 Fix custom notification creation. 2019-09-25 18:58:21 -04:00
Greyson Parrelli
e273593343 Fix more possible JobMigration crashes. 2019-09-25 15:19:08 -04:00
Greyson Parrelli
c5767b07a7 Initialize CameraX on a background thread.
We saw a situation where CameraX initialization could lock up when
trying to obtain system resource. We already fallback to the
Camera1Fragment when CameraX isn't initialized, so it should be safe to
do this initialization on its own thread.
2019-09-25 15:17:35 -04:00
Greyson Parrelli
709ce7e9de Bump version to 4.48.2 2019-09-25 11:37:55 -04:00
Greyson Parrelli
a8f7908ed4 Updated language translations. 2019-09-25 11:37:55 -04:00
Greyson Parrelli
8230786638 Added permissions to the debug log. 2019-09-25 11:23:23 -04:00
Greyson Parrelli
df4ecc4e32 Add blocked threads to the debug log. 2019-09-25 11:23:23 -04:00
Greyson Parrelli
5b755b9501 Crash early when using a null RecipientId. 2019-09-25 09:51:50 -04:00
Greyson Parrelli
b3c7c8db5c Fix possible crash in DirectoryRefreshJob. 2019-09-25 09:51:50 -04:00
Greyson Parrelli
a21c537428 Fix crash during JobMigration. 2019-09-25 09:51:50 -04:00
Greyson Parrelli
6d339cd023 Fix a crash when starting a call from the system contacts. 2019-09-25 09:51:50 -04:00
Alan Evans
840c493265 Fix pretty print phone numbers.
Fixes #9047
2019-09-25 09:49:26 -04:00
alex-signal
14999800e2 Fix Swipe to Reply progress reset when AnimatorDurationScale is 0.
Fixes #9051
2019-09-25 10:08:10 -03:00
Greyson Parrelli
8e332d0798 Bump version to 4.48.1 2019-09-24 12:13:27 -04:00
Greyson Parrelli
cd007a20d7 Fix possible thread visibility issue in CellConstraintObserver.
Related to #9030.
2019-09-24 12:13:27 -04:00
Greyson Parrelli
8b99af3eef Fix threading issues with LiveRecipient. 2019-09-24 12:03:33 -04:00
Greyson Parrelli
d354de806e Bump version to 4.48.0 2019-09-24 10:24:37 -04:00
alex-signal
c7ef0c06f8 Fix exif dimension edge case and handle invalid dimens better in ThumbnailView. 2019-09-24 10:11:17 -04:00
Greyson Parrelli
9d14bcb808 Enable sticker sharing. 2019-09-24 10:11:17 -04:00
alex-signal
de03706d8d Fix video thumbnail not displaying after sharing to conversation thread. 2019-09-24 10:11:17 -04:00
alex-signal
a3caabcafd Fix video forwarding thumbnail display. 2019-09-24 10:11:17 -04:00
alex-signal
faafa40122 Fix DecryptableStreamLocalUriFetcher bug for external video thumbnails.
Fix bug where external video thumbnails do not appear.
2019-09-24 10:11:17 -04:00
Greyson Parrelli
d1a6582ad7 Support independent application migration versions. 2019-09-24 10:11:17 -04:00
alex-signal
f81c0b448e Add CameraXFlashToggleView and selfie flash. 2019-09-24 10:11:17 -04:00
Greyson Parrelli
70347e754c Add a feature flag system. 2019-09-24 10:11:17 -04:00
Greyson Parrelli
a1245baf61 Don't show MMS groups in recent Signal contacts list. 2019-09-24 10:11:17 -04:00
Alex Hart
007ea43dc8 Add Swipe-To-Reply in conversations.
Swipe-To-Reply is a progress based animation that is controlled
by the ConversationItemSwipeCallback.  We use the TouchListener to
keep track of the latest down coordinates, so that we can check whether
we are over a seek bar. The SwipeAnimationHelper is responsible for
actually performing the transitions as the swipe progresses.
2019-09-24 10:11:17 -04:00
Greyson Parrelli
582028f2c2 Search contacts via the RecipientDatabase. 2019-09-24 10:11:17 -04:00
Greyson Parrelli
0e2d52026e Migrated to locally-assigned RecipientId's.
Oh boy.
2019-09-24 10:11:17 -04:00
Greyson Parrelli
233cc7ecce Bump version to 4.47.6 2019-09-16 17:00:06 -04:00
Greyson Parrelli
1baf03f51a Fix message fetching bug when app is in the foreground.
Fixes #9036
2019-09-16 16:58:51 -04:00
Greyson Parrelli
f066a9cab2 Bump version to 4.47.5 2019-09-11 18:01:50 -04:00
Curt Brune
825d1a02ab Update to WebRTC M77 2019-09-11 13:55:26 -07:00
Curt Brune
97cc8b7777 Revert "Add ringrtc support."
Revert the following commits:

"Handle busy call while in PSTN call."
Commit 23a0bb3ce0.

"Add ringrtc support."
Commit 3ac540c687.
2019-09-11 11:17:23 -07:00
Greyson Parrelli
72662b5b52 Bump version to 4.47.4 2019-09-06 13:56:17 -04:00
Greyson Parrelli
ea4e0b6d6f Updated language translations. 2019-09-06 13:56:04 -04:00
Alan Evans
6df93c0bb5 Fix potential contact search crash. 2019-09-06 13:53:26 -04:00
Curt Brune
23a0bb3ce0 Handle busy call while in PSTN call. 2019-09-06 10:20:32 -07:00
Greyson Parrelli
4cd5256267 Bump version to 4.47.3 2019-09-04 11:10:47 -04:00
Greyson Parrelli
5362e07a5c Fix crash that may happen upon first sticker install. 2019-09-04 11:09:30 -04:00
Greyson Parrelli
936bd327bd Bump version to 4.47.2 2019-09-03 15:38:34 -04:00
Greyson Parrelli
db89619a4a Updated language translations. 2019-09-03 15:38:20 -04:00
Alan Evans
b5ce7325fc Fix invite drawable on API 19. 2019-09-03 15:20:09 -04:00
Greyson Parrelli
ccaeb089ab Bump version to 4.47.1 2019-09-02 18:57:14 -04:00
Greyson Parrelli
3240ba3a55 Updated language translations. 2019-09-02 18:53:57 -04:00
Alan Evans
bb7be66efe Fix stickers in image editor.
Fixes #9012
2019-09-02 18:16:30 -04:00
Alan Evans
8814a0d949 Update invite icon. 2019-09-02 18:15:27 -04:00
Greyson Parrelli
9aa488223f Bump version to 4.47.0 2019-08-31 11:28:34 -04:00
Greyson Parrelli
30d9233365 Updated language translations. 2019-08-31 11:28:34 -04:00
Curt Brune
3ac540c687 Add ringrtc support.
RingRTC provides Signal Messenger applications with a common interface
for video and voice calling services built on top of WebRTC.
2019-08-31 07:54:47 -07:00
Alan Evans
8d561ead21 Stickers in image editor. 2019-08-30 17:45:35 -04:00
Alan Evans
15b650382e Fullscreen media preview on tap. 2019-08-30 17:31:59 -04:00
Oscar Mira
110a40592b Make E164 log scrubber redact numbers of length >= 7. 2019-08-30 08:20:21 -04:00
Alan Evans
d0ce4ff032 Lottie play pause animation. 2019-08-29 11:57:41 -04:00
Alan Evans
85c9a9050a Add an invite button in the new conversation screen. 2019-08-29 11:07:33 -04:00
Greyson Parrelli
af42d5b671 Create system for job migrations. 2019-08-29 11:07:33 -04:00
Greyson Parrelli
9580bb0a38 Renamed WorkManager migration package. 2019-08-29 11:07:33 -04:00
Greyson Parrelli
9abb167874 Bump version to 4.46.2 2019-08-28 10:27:40 -04:00
Greyson Parrelli
cd13676a21 Updated language translations. 2019-08-28 10:26:29 -04:00
Greyson Parrelli
1dd59bee36 Use raw versionCodes in web apk json.
We missed a spot when transitioning to split apk versions. It ended up
breaking the update prompt for web apks.

This will put the raw universal apk version in the json file, which
should put us back on the right track.

Fixes #8936
2019-08-28 10:26:29 -04:00
Greyson Parrelli
59bcbe592b Revert "Add ringrtc support"
This reverts commit 7f0a7b0c13.
2019-08-28 09:16:51 -04:00
Greyson Parrelli
0917e17c69 Fix bug where you couldn't reply with media.
Fixes ##8999
2019-08-27 09:40:32 -04:00
Greyson Parrelli
eb249ca69a Bump version to 4.46.1 2019-08-24 15:18:22 -04:00
Greyson Parrelli
97d1175915 Updated language translations. 2019-08-24 14:35:35 -04:00
Alan Evans
2141f1073e Ensure memory file descriptor is available. 2019-08-24 14:30:02 -04:00
Greyson Parrelli
c6287547a3 Improve video transcoding exception handling.
Previously, we'd crash if we couldn't find the attachment at runtime,
but that's not uncommon if someone deletes before sending. Now we just
fail.

Also, previously we'd fail if we couldn't create a memory file. Now we
will only fail if the attachment is >100mb (same as the other video
failures).
2019-08-24 09:27:08 -04:00
Greyson Parrelli
9257c6ddf3 Fix failure propogation in longer job chains. 2019-08-24 09:09:20 -04:00
Greyson Parrelli
480748e1aa Bump version to 4.46.0 2019-08-23 10:01:29 -04:00
Greyson Parrelli
c015687951 Updated language translations. 2019-08-23 10:01:06 -04:00
Alan Evans
1bd1e9cc65 Read optional video display dimensions.
Add RequiresApi annotations.

Fixes #8982
2019-08-22 10:15:56 -04:00
Alan Evans
c4a4374465 RTL screen animations.
RTL fix Profile name in Settings.
2019-08-22 10:15:56 -04:00
Alan Evans
90681d47f8 Fix first item sticky header. 2019-08-22 10:15:56 -04:00
Alan Evans
936be693ce Enlarge some home touch targets and add search content description. 2019-08-22 10:15:56 -04:00
Alan Evans
a32b875587 Support disabled animations for accessibility. 2019-08-22 10:15:56 -04:00
Alan Evans
4e6798e38e Fix occasional double scroll bar on fast scroller. 2019-08-22 10:15:56 -04:00
Alan Evans
6352f7baf4 Update item design in contact selection. 2019-08-22 10:15:56 -04:00
Alan Evans
aac9725adc Move shared attachment job generation code to parent class. 2019-08-22 10:15:56 -04:00
Alan Evans
900371bb30 Call answer button listens to accessibility changes. 2019-08-22 10:15:56 -04:00
Alan Evans
a58f564d1e Escape string within Full Text Search.
Fixes #8975
2019-08-22 10:15:56 -04:00
Alan Evans
942154a61f Separate compression job. 2019-08-22 10:04:23 -04:00
Curt Brune
7f0a7b0c13 Add ringrtc support
Initial commit of the RingRTC Java interface implementation.

The implementation lives in an external .aar with the package
org.signal.ringrtc.

The package provides two high level objects of interest
=======================================================

org.signal.ringrtc.CallConnection -- represents the session of a call,
very similar to WebRTC's PeerConnection.

org.signal.ringrtc.CallConnectionFactory -- creates CallConnection
objects, very similar to WebRTC's PeerConnectionFactory.

The implementation interfaces with the Android application in a few
places:
==================================================================

src/org/thoughtcrime/securesms/ApplicationContext.java -- RingRTC
library initialization at application startup.

src/org/thoughtcrime/securesms/service/WebRtcCallService.java -- Call
creation and state machine.

src/org/thoughtcrime/securesms/ringrtc -- this package implements
interface classes needed by ringrtc and a CallConnectionWrapper helper
class.

The two interfaces needed so far are:

  ringrtc/Logger.java
  ringrtc/SignalMessageRecipient.java

The logger is self-explanatory, but SignalMessageRecipient is a little
more involved.  SignalMessageRecipient encapsulates the Signal-Android
notion of "Recipient" and the mechanism for sending Signal Messages
related to audio/video calling.

The CallConnectionWrapper class is clone of the original
org.thoughtcrime.securesms.webrtc.PeerConnectionWrapper, suitably
modified to match the CallConnection interface.

This class continues to handle the Camera switching APIs, with that
portion of the code remaining unmodified from the original.

CallConnectionFactory Details
=============================

The primary public methods:

initialize() -- initialize the WebRTC library and RingRTC library.
The WebRTC initialization is lifted from the original Signal-Android
code.

createCallConnectionFactory() -- creates a CallConnectionFactory
object.  Internally it creates a WebRTC PeerConnectionFactory object
and a RingRTC CallConnectionFactory object.

dispose() -- tears down the CallConnectionFactory object, including
the internal PeerConnectionFactory and RingRTC CallConnectionFactory.

createCallConnection() -- creates a CallConnection object, connecting
that with an application controlled CallConnection.Observer object.

This function takes a CallConnection.Configuration object to link the
CallConnection object with some application provided services, like
sending Signal protocol messages.

CallConnection Details
======================

This object is a subclass of WebRTC's PeerConnection class.

The primary public methods and objects:

CallConnection.Configuration
----------------------------

Configuration object used to parameterize a call.  Notable members:

- SignalServiceMessageSender messageSender
- long callId
- org.signal.SignalMessageRecipient recipient

The 'accountManager' is used to fetch public information from the Signal
service, specifically used here to obtain the public Signal TURN
server details.

The 'callId' is a 64-bit pseudo-random number generated when the call
is initiated, used to identify the call through out its lifetime.

The "recipient' is an implementation of the
org.signal.SignalMessageRecipient interface, which encapsulates the
sending of Signal service messages to a recipient (remote peer) using
existing Signal protocol data structures.

The native library needs to be able to send Signal messages via the
service, but it does not have a native implementation to do so.
Instead the native code calls out to the client for sending Signal
messages.  To accomplish this, the client implements the
org.signal.SignalMessageRecipient interface and passes an instance of
that in a CallConnection.Configuration object.

CallConnection
--------------

dispose() -- tears down the CallConnection object, including the
internal PeerConnection and RingRTC CallConnection.

sendOffer() -- initiates a call to a remote recipient.  This is the
beginning of an outbound call.

validateResponse() -- checks an offer response recipient against the
originating call details.

handleOfferAnswer() -- handles the receipt of answer, which was a
response from an originating offer.

acceptOffer() -- accept an offer from a remote participant.  This is
the begin of an incoming call.

answerCall() -- invoked when the call is completely established and
online.

hangUp() -- hang up the connection and shut things done.  This is the
end of the call.

sendBusy() -- send the remote side an indication that the local side
is already in a call and the line is busy.

sendVideoStatus() -- send the current state of the local camera video
stream to the remote side.

CallConnection.Observer
-----------------------

Observer object, used by the RingRTC library to notify the client
application of important events and status changes.  Similar in spirit
to WebRTC's PeerConnection.Observer.

Observer callbacks come in three flavors:

- state change notifications,
- on stream notifications
- errors conditions

For state notifications, the callback contains the callId, the
recipient and a CallConnection.CallEvent type.

For streams, the callback contains the callId, the
recipient and a org.webrtc.MediaStream.

For errors, the callback contains the callId, the recipient and an
exception type.  The currently thrown exceptions include:

- UntrustedIdentityException
- UnregisteredUserException
- IOException

Signed-off-by: Curt Brune <curt@signal.org>

Updates to support ringrtc-android version 0.1.0.

* simplify logging interface

It is no longer necessary for the application to specify a Log object
as the library can log via the NDK directly.

* improve error handling and notification

In a number of places where ringrtc errors could occur, no
notification was ever sent to the user, nor was the UI cleaned up.  It
would look like the app was in hung state.

This patch updates these situations to send the WebRtcViewModel a
NETWORK_FAILURE message.

* update handleIncomingCall() for lockManager and notification

During the conversion to RingRTC, the implementation of
handleIncomingCall() missed a couple of things:

-- updating the Phone state with the lockManager
-- sending a message to the viewModel

* log the callId in various handler methods

For debugging purposes it is very handy to have the callId present in
the log during the various call handler methods.

Signed-off-by: Curt Brune <curt@signal.org>
2019-08-22 10:04:23 -04:00
Alan Evans
37bcac40bb URL encoded scrubber.
* Replace scrubber and tests.

* Improves email regex performance.
2019-08-22 10:04:23 -04:00
Greyson Parrelli
02ea99254a Reset message receiver upon REST failure.
We've been seeing a lot of socket timeouts on REST requests under
certain conditions. The issue seems to be a problem with the OkHttp
client. Through testing, I've seen that resetting the receiver and
retrying again seems to resolve most issues.
2019-08-22 10:04:23 -04:00
Greyson Parrelli
3849b46f0a Refactor ApplicationDependencies. 2019-08-22 10:04:23 -04:00
Greyson Parrelli
116bd41c63 Use EmojiTextView in the sticker preview. 2019-08-22 10:04:23 -04:00
Greyson Parrelli
457ad4c607 Added a central system for message retrieval. 2019-08-22 10:04:23 -04:00
Greyson Parrelli
d0a9bd4c6d Create a new system for application-level migrations. 2019-08-22 10:04:23 -04:00
Greyson Parrelli
d3bed549f2 Switch back to storing incoming messages in PushDatabase.
On a Pixel 3, this adds ~30-40ms of delay, but it's going to be a
requirement for upcoming migrations.
2019-08-22 10:04:23 -04:00
Alan Evans
fe1aa016b9 Refactor group operations. 2019-08-22 10:04:17 -04:00
Greyson Parrelli
af55cb0c03 Bump version to 4.45.2 2019-08-05 15:48:22 -04:00
Greyson Parrelli
714eaa62a8 Updated language translations. 2019-08-05 15:48:22 -04:00
Greyson Parrelli
5038f49487 Fix issue with sticker preview sizing. 2019-08-05 15:48:22 -04:00
Greyson Parrelli
57835dc8f1 Update view-once message behavior. 2019-08-05 15:46:43 -04:00
Alan Evans
3439eb4536 Replace disk icon with download icon. 2019-08-05 12:13:15 -04:00
Alan Evans
929ee04814 Handle missing video duration.
On EncodingException, or no duration metadata found, when video < 100MB, continue with send.
2019-08-05 10:48:18 -04:00
Greyson Parrelli
9d98a779a8 Bump version to 4.45.1 2019-08-02 17:01:11 -04:00
Greyson Parrelli
5a23ddeaf4 Updated language translations. 2019-08-02 17:01:11 -04:00
Greyson Parrelli
7ae5159194 Downgrade some job exceptions.
Runtime exceptions were being thrown where it'd be safer to either
ignore it or throw a checked, failing exception.
2019-08-02 17:00:48 -04:00
Alan Evans
bdf93af3db Clear outstanding glide requests.
Fixes #8967
2019-08-02 16:00:22 -04:00
Alan Evans
dcc147d994 Reduce frame timeout crashes. 2019-08-02 15:57:20 -04:00
Greyson Parrelli
19b2658414 Fix Job.Result logging. 2019-08-01 16:42:59 -04:00
Greyson Parrelli
1c4833f3b4 Bump version to 4.45.0 2019-08-01 10:40:52 -04:00
Greyson Parrelli
e8ca673bf8 Updated language translations. 2019-08-01 10:40:52 -04:00
Alan Evans
5a614faee1 Camera content descriptions and allow camera capture in talk back. 2019-08-01 10:40:52 -04:00
Greyson Parrelli
af8042c5f4 Use proper icon and theme for camera button. 2019-08-01 10:40:52 -04:00
Greyson Parrelli
a46e7541d0 Switch from contentUris to fileUris in the media gallery.
Android Q encounters massive slowdown when using contentUris for media.
Switching to fileUris (which we're already doing for the folder
thumbnail) gets us back to the expected performance level.
2019-08-01 10:40:37 -04:00
Alan Evans
a6890fc8dd Video playback on TextureView and DepthPageTransformer. 2019-08-01 08:45:29 -04:00
Alan Evans
0c0d7aeead Remove old pre-v9, pre-v11, and pre-v12 assets. 2019-08-01 08:45:29 -04:00
Ellen Poe
874697f6e5 Added content descriptions for some important controls.
Fixes #8728

Co-authored-by: Alan Evans <alan@signal.org>
2019-08-01 08:45:29 -04:00
Alan Evans
e0d1987445 Accessible call answering/rejecting and content descriptions. 2019-08-01 08:45:29 -04:00
Greyson Parrelli
17400020b7 Allow RuntimeExceptions thrown by Jobs to crash. 2019-07-31 09:54:46 -04:00
Alan Evans
e8e80e5d05 Transcode video during attachment upload. 2019-07-31 09:54:46 -04:00
Alan Evans
f9946083dd Video transcoding. 2019-07-30 14:09:33 -04:00
Greyson Parrelli
453f93a84f Bump version to 4.44.7 2019-07-28 10:20:38 -04:00
Greyson Parrelli
a8c47b5091 Guard media reads with a permissions check. 2019-07-28 10:20:04 -04:00
Greyson Parrelli
78a818eba6 Bump version to 4.44.6 2019-07-28 10:05:58 -04:00
Greyson Parrelli
4ca90374b9 Fix bug displaying an empty camera contacts search result. 2019-07-28 10:05:22 -04:00
Greyson Parrelli
a5fbcffa14 Bump version to 4.44.5 2019-07-26 15:38:10 -04:00
Greyson Parrelli
a21ec2f166 Updated language translations. 2019-07-26 15:37:39 -04:00
Greyson Parrelli
cdfb88ea18 Some tweaks to the camera FAB. 2019-07-26 15:29:44 -04:00
Greyson Parrelli
1ec45fe364 Fix bug where search wasn't focused in contact select.
Introduced in c0a44c7fc3.
Apparently targetSdk 28 changed the view focus model.
We have to manually focus this particular view now.
2019-07-26 15:06:09 -04:00
Greyson Parrelli
60b5c82da8 Bump version to 4.44.4 2019-07-25 11:29:03 -04:00
Greyson Parrelli
f0af5743c4 Updated language translations. 2019-07-25 11:25:57 -04:00
Alan Evans
81930a6833 Fix push challenge, Event bus needs public. 2019-07-25 11:19:21 -04:00
Greyson Parrelli
278ee79df0 Update camera-first contact display. 2019-07-25 10:10:32 -04:00
Greyson Parrelli
7f2a758400 Require contacts permission for camera-first flow.
Fixes #8950
2019-07-25 10:04:03 -04:00
Greyson Parrelli
fc1c092cf0 Bump version to 4.44.3 2019-07-24 19:31:52 -04:00
Greyson Parrelli
f42a8cf962 Updated language translations. 2019-07-24 19:31:52 -04:00
Greyson Parrelli
27db9d06e4 Ensure media folder title is not null.
Fixes #8949
2019-07-24 19:31:52 -04:00
Greyson Parrelli
3d5cfb3c74 Remove some dead code. 2019-07-24 19:24:21 -04:00
Greyson Parrelli
df9186827c Fix some UI issues with view-once photo receive. 2019-07-24 19:24:16 -04:00
Greyson Parrelli
e0137706b2 Bump version to 4.44.2 2019-07-24 11:25:01 -04:00
Greyson Parrelli
99bcda8709 Updated language translations. 2019-07-24 11:25:01 -04:00
Greyson Parrelli
eddff07eb8 Fix TimedEventManager crash in a sane way.
Follow up on acb48752c.

Just have the subclass call that method to guarantee that everything is
initialized.
2019-07-24 11:24:52 -04:00
Greyson Parrelli
4e859a84ce UI tweaks in the media send flow. 2019-07-24 11:04:21 -04:00
Greyson Parrelli
8665dad867 Prevent clicks from passing through media rail. 2019-07-23 10:48:23 -04:00
Greyson Parrelli
c0996ed116 Bump version to 4.44.1 2019-07-23 09:48:16 -04:00
Greyson Parrelli
830e651fef Updated language translations. 2019-07-23 09:39:15 -04:00
Greyson Parrelli
acb48752ce Fix possible crash in RevealableMessageManager.
The crash happened because #getNextClosestEvent was called when
mmsDatabase was null, which would normally be impossible. However, it
seems implied that somehow #getNextClosestEvent was being called in the
parent constructor before the child class was fully initialized. That
would imply that the looper was called synchronously in some freak
scenario, but it's the only explanation. So I added a delay to the call
in the parent constructor.

```java
java.lang.NullPointerException:
  at org.thoughtcrime.securesms.revealable.RevealableMessageManager.getNextClosestEvent (RevealableMessageManager.java:40)
  at org.thoughtcrime.securesms.revealable.RevealableMessageManager.getNextClosestEvent (RevealableMessageManager.java:23)
  at org.thoughtcrime.securesms.service.TimedEventManager.lambda$scheduleIfNecessary$1 (TimedEventManager.java:44)
  at org.thoughtcrime.securesms.service.-$$Lambda$TimedEventManager$kZDO3F2WBQVtGx-SkAgEDt8jCeU.run (Unknown Source:2)
  at android.os.Handler.handleCallback (Handler.java:873)
  at android.os.Handler.dispatchMessage (Handler.java:99)
  at android.os.Looper.loop (Looper.java:193)
  at android.os.HandlerThread.run (HandlerThread.java:65)
```
2019-07-23 09:39:15 -04:00
Greyson Parrelli
ba8597900a Fix NPE in MediaSendActivity. 2019-07-23 09:39:15 -04:00
Alan Evans
c1f0253aa3 Resolve MissingSuperCall lint. 2019-07-23 09:35:23 -04:00
Alan Evans
d70d82c5ea Make fragments public.
Fixes #8940
2019-07-23 08:56:07 -04:00
Greyson Parrelli
29b9d3f902 Fix crash when viewing "inbox zero" state. 2019-07-23 08:50:27 -04:00
Greyson Parrelli
1a85a9cb31 Fix media send HUD consistency issue.
Only affects people who have force-enabled revealable messages and then
gone back to a build that doesn't have it enabled.
2019-07-23 08:50:20 -04:00
Greyson Parrelli
ead6e6b2f3 Bump version to 4.44.0 2019-07-22 23:33:54 -04:00
Alan Evans
03b1eb4bd5 Prevent attempting to send push media messages to non-phone addresses.
Prevents crash loop in #8910
2019-07-22 23:16:01 -04:00
Greyson Parrelli
5c870ca8ea Prevent sending revealable messages in Note to Self.
Send support isn't enabled yet, but didn't want to forget about it.
2019-07-22 23:16:01 -04:00
Greyson Parrelli
965de16de1 Fix possible hangup with CellServiceConstraint.
On phones with no SIM card, if you manage to enqueue a job with a
CellServiceConstraint, the previous check we were using to check if
there was cell service could hang indefinitely on some devices.

This changes it to a fast check, which all constraints should be.
2019-07-22 23:16:01 -04:00
Greyson Parrelli
a210ef3136 Added ability to save image captures to external storage. 2019-07-22 23:16:01 -04:00
Greyson Parrelli
beaa86389d Implement camera-first capture flow.
This allows you to take a photo, then choose the recipients after. This
also makes it so we only upload the attachment once.
2019-07-22 23:15:50 -04:00
Greyson Parrelli
4fbb87b5b7 Created a new SectionedRecyclerViewAdapter. 2019-07-22 20:55:31 -04:00
Sebastian Kürten
76d1382d9a Fix some Javadoc typos 2019-07-22 20:55:31 -04:00
Alan Evans
79a142c1be Refactor media preview to use fragments. 2019-07-22 20:55:26 -04:00
Greyson Parrelli
dd66e22443 Ensure that camera captures have correct dimensions. 2019-07-18 16:10:59 -04:00
Greyson Parrelli
c77809fa90 Add support for view-once messages. 2019-07-18 16:10:10 -04:00
Greyson Parrelli
9f7bb69341 Update the media send flow with a persistent rail. 2019-07-18 11:04:14 -04:00
Alan Evans
b58faf4fd1 Change settings transitions. 2019-07-18 10:29:27 -04:00
Alan Evans
dbeb2b5330 Fix play button in RTL layouts. 2019-07-18 10:08:08 -04:00
Alan Evans
9574a19ec2 Signal service update 2.13.6.
Fixes #8901
2019-07-18 10:06:44 -04:00
Greyson Parrelli
73bb7873e1 Log FCM notification delay. 2019-07-17 17:07:32 -04:00
Greyson Parrelli
475c54213d Move from dagger to a service locator pattern. 2019-07-17 16:12:53 -04:00
Alan Evans
8d6f1341f1 Reduce resolution of image editor preview and make memory efficiencies.
Fixes #8929
2019-07-17 15:05:19 -04:00
Alan Evans
80d0ba31ca Specify locale in some String.formats. 2019-07-17 14:07:39 -04:00
Alan Evans
c7bfede74c Do not use Canvas size. 2019-07-17 14:07:20 -04:00
Greyson Parrelli
c902d17f98 Remove additional log information that is not necessary for debugging purposes. 2019-07-16 19:24:51 -04:00
Greyson Parrelli
6c31d656dd Fix queueKey for SmsSendJob. 2019-07-16 19:19:56 -04:00
Greyson Parrelli
34e8d5ac57 Ignore whitespace when determining if we show jumbomoji. 2019-07-15 16:02:51 -04:00
Greyson Parrelli
d636f37132 Updated Emoji icons. 2019-07-12 13:25:36 -04:00
Curt Brune
150a21bfa3 Update to WebRTC M75 2019-07-11 10:25:07 -04:00
Alan Evans
5b61c8ac18 Request a push challenge and supply to SMS and voice verification. 2019-07-10 16:59:08 -04:00
Alan Evans
d72d4c4c41 Update libsignal to 2.13.5 2019-07-10 15:19:23 -04:00
Greyson Parrelli
5a1464c069 Remove pending messages notification. 2019-07-10 14:38:28 -04:00
Greyson Parrelli
c2ec09f079 Remove AttachmentServer. 2019-07-03 19:04:17 -04:00
Greyson Parrelli
8a8817f8d3 Remove video player usage of AttachmentServer. 2019-07-03 19:04:17 -04:00
Greyson Parrelli
a5368b7ea9 Remove audio player usage of AttachmentServer.
Now that we use ExoPlayer, it's no longer needed.
2019-07-03 19:04:17 -04:00
Greyson Parrelli
d8a75d599d Update emoji. 2019-07-03 19:04:17 -04:00
Greyson Parrelli
f92e2bae4a Bump version to 4.43.8 2019-07-03 12:14:28 -04:00
Greyson Parrelli
19d15cb3e5 Updated language translations. 2019-07-03 12:14:28 -04:00
Greyson Parrelli
b66e0e7e32 Fix incorrect EditorModel being restored. 2019-07-03 11:51:22 -04:00
Alan Evans
4a1f39f4be Drop shadow below conversation title bar. 2019-07-03 11:41:13 -04:00
Greyson Parrelli
a17d3e1b47 Bump version to 4.43.7 2019-07-02 18:08:03 -04:00
Greyson Parrelli
f580128366 Fix camera crash on API 21. 2019-07-02 18:07:13 -04:00
Greyson Parrelli
18252712a5 Bump version to 4.43.6 2019-07-02 10:18:44 -04:00
Greyson Parrelli
ed5f5adc9b Prevented avatar read failures from crashing.
There are a handful of devices that refuse to use our AesGcmProvider,
and as a result they would crash with AssertionErrors when downloading
avatars. Still haven't found why, but for now, probably best to stop
these devices from crashing, since it puts them in a crash loop, and the
app is still usable without avatars.
2019-07-02 10:06:20 -04:00
Greyson Parrelli
4c30aa9f13 Fixed crash when setting your profile picture.
The version of the cropping library we were using had a targetSdk 28 bug
in it. Updating to the newest version fixes the problem.
2019-07-02 10:05:23 -04:00
Greyson Parrelli
3cdf17ccaa Bump version to 4.43.5 2019-07-01 17:15:46 -04:00
Greyson Parrelli
a8dbfd812d Fix issue with bad camera quality on some devices.
There appears to be a weird bucketing thing that happens on some
devices, where if you give them a resolution that's too small, it'll
default you to some potato resolution. So we just bumped it up to
1920x1920, and that seems to be working on my swath of devices.
2019-07-01 17:15:14 -04:00
Greyson Parrelli
ff3890cc12 Name threads more consistently. 2019-07-01 17:15:04 -04:00
Greyson Parrelli
9c196bd2d5 Fix issue where an empty file could be read forever.
If you gave the class an empty file, it would get back -1 for read(),
causing it to fall forever into negative values, never escaping the
existing conditions.

The side effect of this was weird corner cases where these infinite
reads could clog up threads, causing audio recordings to get blocked
and such.

Fixes #8898
2019-07-01 17:15:01 -04:00
Greyson Parrelli
4508aa7c35 Clean up logging. 2019-07-01 15:12:34 -04:00
Greyson Parrelli
f15a629731 Bump version to 4.43.4 2019-06-30 09:43:32 -04:00
Greyson Parrelli
857fda42c8 Fix audio playback on API 28 devices. 2019-06-30 09:41:58 -04:00
Greyson Parrelli
a5eb823a17 Avoid crash with Address parcelable.
There seems to be a bad implementation of Address parcelization that
pops up in certain scenarios. We can avoid it by just excluding it
from the parcel altogether.
2019-06-30 09:26:08 -04:00
Greyson Parrelli
31435128f4 Bump version to 4.43.3 2019-06-30 01:10:50 -04:00
Greyson Parrelli
6656077edc Updated language translations. 2019-06-30 01:10:34 -04:00
Greyson Parrelli
9974f6edf1 Correctly retrict BucketInfo API level. 2019-06-30 00:54:51 -04:00
Greyson Parrelli
6715a89a25 Disable default CameraX initializer.
CameraX was initializing Camera2 API stuff on API < 21, causing
crashes at boot. To handle this, we disable the default
ContentProvider initializer and initialize things ourselves for
appropriate API levels.
2019-06-30 00:54:42 -04:00
Greyson Parrelli
23b4a9b191 Bump version to 4.43.2 2019-06-28 19:17:35 -04:00
Greyson Parrelli
666cdeae6b Change compileSdk back to 28. 2019-06-28 19:16:27 -04:00
Greyson Parrelli
5d7ac81c4b Bump version to 4.43.1 2019-06-28 18:57:34 -04:00
Greyson Parrelli
93856ed8cf Fix some bookkeeping in CameraXFragment. 2019-06-28 18:57:04 -04:00
Greyson Parrelli
84fd1a9140 Bump version to 4.43.0 2019-06-28 18:39:32 -04:00
Greyson Parrelli
9949e5e3a5 Updated language translations. 2019-06-28 18:39:20 -04:00
Alan Evans
c0a44c7fc3 Target API 28. 2019-06-27 16:18:53 -04:00
Alan Evans
d9df1ec39e Preparing to target API 28. 2019-06-27 16:18:53 -04:00
Greyson Parrelli
abcd599ad8 Support Android Q call notifications. 2019-06-27 15:46:13 -04:00
Greyson Parrelli
8a3d0dde91 Bump compileSdk to 29. 2019-06-27 15:46:13 -04:00
Alan Evans
0f3de6c979 Check action mode is still valid.
Due to support library bug, onActionItemClicked can be called after finish/onDestroyActionMode so we can check for that by checking if our reference to the action mode is still valid.

Fixes #8891
2019-06-27 15:44:05 -04:00
Alan Evans
c089d6cd43 Allow multiple messages on the Generic Foreground Service. Show the oldest still active. 2019-06-27 12:18:52 -04:00
Alan Evans
cfcb9a8cdb Custom place picker to replace places SDK. 2019-06-27 12:14:54 -04:00
Matthias Riedl
83479d11b7 White text on dark theme pin input.
Fixed #7509
2019-06-27 11:28:59 -04:00
Greyson Parrelli
73b8f11b5a Improve camera capture with CameraX. 2019-06-26 18:11:49 -04:00
Greyson Parrelli
4593014d00 Bump version to 4.42.3 2019-06-24 12:55:02 -04:00
Greyson Parrelli
2cf5d57454 Updated language translations. 2019-06-24 12:54:37 -04:00
Greyson Parrelli
048d859881 Handle missing profile photos better.
There were a couple funny behaviors you could run into if you had a
contact that previously had a profile photo, but then removed it.
2019-06-24 12:36:05 -04:00
Greyson Parrelli
1df28c6564 Bump version to 4.42.2 2019-06-20 09:35:20 -04:00
Greyson Parrelli
f59e937006 Updated language translations. 2019-06-20 09:34:38 -04:00
Greyson Parrelli
5948b46ac7 Fix crash in AvatarImageView. 2019-06-20 09:27:58 -04:00
Greyson Parrelli
75b232bfdc Bump version to 4.42.1 2019-06-19 13:01:58 -04:00
Greyson Parrelli
9e6594cc0b Updated language translations. 2019-06-19 12:56:56 -04:00
Greyson Parrelli
7f85b61e89 Serialize RotateSignedPreKeyJob. 2019-06-19 12:56:56 -04:00
Alan Evans
1a32bc8232 Fix flickering avatar. 2019-06-19 12:29:15 -04:00
Greyson Parrelli
e603162ee7 Bump version to 4.42.0 2019-06-17 13:51:16 -04:00
Greyson Parrelli
08eca5d844 Updated language translations. 2019-06-17 13:51:16 -04:00
Greyson Parrelli
1d1dbcf9cd Fix RecyclerView lint errors. 2019-06-17 13:51:16 -04:00
Alan Evans
e6b107fa78 Add a content description for the inline add attachment button.
Fixes #8730
2019-06-17 13:51:16 -04:00
Alan Evans
284cca3e25 Prevent reply and mark as read abilities while Signal is locked.
Fixes #8874
2019-06-17 13:51:16 -04:00
Greyson Parrelli
1e0b0d926a Update libsignal to 2.13.4 2019-06-17 13:51:16 -04:00
Alan Evans
cb86be578b Handle accented characters in country name sorting.
Closes #8419
2019-06-17 13:51:16 -04:00
Alan Evans
b8bb2b78bd Query total memory just once.
Closes #8315
2019-06-17 13:51:16 -04:00
Alan Evans
6fceb25121 Take typing indicator into account when moving to quoted message.
Fixes #8858

And fixes same bug in search.
2019-06-17 13:51:16 -04:00
Alan Evans
0484047b4e Fix avatar removal. 2019-06-17 13:51:16 -04:00
Alan Evans
b9a10653f1 Image Editor - Multi-line text.
* Two pass rendering for text on top while editing.
2019-06-17 13:51:16 -04:00
Alan Evans
42a5504f0d Do not attempt to retrieve a profile when it is not a number.
Fixes #8855
2019-06-17 13:51:16 -04:00
Alan Evans
ae784db80d Video is initially disabled.
Fixes #8867
2019-06-17 12:52:42 -04:00
Alan Evans
f5cbf64ccf Fix initial visibility of scroll to bottom button.
Fixes #8862
2019-06-17 12:52:42 -04:00
Alan Evans
cecf16c595 Do not show contact address in subtitle. 2019-06-17 12:52:42 -04:00
Greyson Parrelli
fb4c9d3bf1 Improve message download reliability. 2019-06-17 12:52:43 -04:00
Greyson Parrelli
b5aa46bb67 Convert to AndroidX. 2019-06-17 12:52:42 -04:00
Greyson Parrelli
2dc68ed053 Switch from compile to implementation. 2019-06-17 12:52:42 -04:00
Greyson Parrelli
58d818923d Convert /res folder to webp.
Used lossless.
2019-06-17 12:52:42 -04:00
Greyson Parrelli
f4a6cd9c68 Convert emoji to webp.
Used lossy at 99% quality. No perceivable degredation at max font size,
but a pretty big improvement in size over lossless.
2019-06-17 12:52:42 -04:00
Greyson Parrelli
ed04535537 Convert image editor stickers to webp.
Used lossless.
2019-06-17 12:52:42 -04:00
Greyson Parrelli
7d4de3d4cb Removed some unused resources. 2019-06-17 12:52:42 -04:00
Greyson Parrelli
bc7cc306cb Bump version code to 4.41.6 2019-06-11 01:52:52 -04:00
Greyson Parrelli
5fa07e7094 Improve network reliability. 2019-06-11 01:51:46 -04:00
Greyson Parrelli
2b069fa63f Bump version to 4.41.5 2019-06-07 16:53:48 -04:00
Greyson Parrelli
99848f98d3 Sanitize sticker URL inputs. 2019-06-07 16:08:33 -04:00
Greyson Parrelli
967e9dd9a7 Disable sticker pack sharing. 2019-06-07 16:08:29 -04:00
Greyson Parrelli
4a720289e2 Bump version to 4.41.4 2019-06-06 10:56:52 -04:00
Greyson Parrelli
86d58e97cf Updated language translations. 2019-06-06 10:56:04 -04:00
Greyson Parrelli
bc6b7d15f1 Fix number formatting issue. 2019-06-06 10:41:37 -04:00
Greyson Parrelli
37f3b1f1ba Bump version to 4.41.3 2019-06-04 03:35:14 -04:00
Greyson Parrelli
262012887c Revert "Do not show contact address in subtitle."
This reverts commit dae0d30367.
2019-06-04 03:30:24 -04:00
Greyson Parrelli
d2cb6098fc Bump version to 4.41.2 2019-06-03 18:58:38 -04:00
Greyson Parrelli
1973fbf376 Fix programmatic VectorDrawable references.
Have to be careful with pre-21 devices. You have to use specific
compat loading methods with VectorDrawables or it'll crash.
2019-06-03 18:53:18 -04:00
Greyson Parrelli
bd63b9bec9 Updated language translations. 2019-06-03 14:50:15 -04:00
Greyson Parrelli
faa8c78f8d Clean up string for translators. 2019-06-03 14:46:51 -04:00
Greyson Parrelli
923016f12c Fix backup restore crash.
Fixes #8011
2019-06-03 14:06:55 -04:00
Greyson Parrelli
f469ce049d Bump version to 4.41.1 2019-05-30 20:22:54 -04:00
Greyson Parrelli
922f6d89e9 Render placeholders for unsupported messages. 2019-05-30 20:18:53 -04:00
Greyson Parrelli
4741a76f37 Add support for isRecipientUpdate flag. 2019-05-30 20:16:14 -04:00
Alan Evans
d197c57c55 Gradle witness - Do not hide resolution errors. 2019-05-30 20:22:03 -03:00
Greyson Parrelli
4ee60bf867 Fix bug where you couldn't forward albums. 2019-05-30 16:17:45 -04:00
Alan Evans
4351578838 Darker nav bar. 2019-05-30 17:11:56 -03:00
Greyson Parrelli
56c17e32f1 Bump version to 4.41.0 2019-05-30 01:17:07 -04:00
Alan Evans
48698381fc Dark theme navigation bar.
Fixes #8758
2019-05-30 01:10:10 -04:00
Alan Evans
5ad02f724c Enable 64-bit.
* Multiply version codes by 10 and add a code for each abi in order to generate different version codes for the play store.
2019-05-30 01:08:01 -04:00
Alan Evans
132c81b142 Bring Gradle Witness into repo.
- Api/Implementation compatible.
- Regex configuration name.
2019-05-30 01:08:01 -04:00
Greyson Parrelli
77e3cc40e0 Fix message bubble sizing with link previews and quotes.
Previously, quotes could extend beyond the width of the link preview
banner image. Now quotes will be constrained to the size of the link
preview banner image.
2019-05-30 01:08:01 -04:00
Greyson Parrelli
2a644437fb Add sticker support.
No sticker packs are available for use yet, but we now have the
latent ability to send and receive.
2019-05-30 01:08:01 -04:00
Alan Evans
d5fffb0132 Fix conversation menu colors. 2019-05-28 17:36:07 -03:00
Alan Evans
c8c152fe60 Lint - baseline of errors.
* qa task calls lint.
2019-05-28 17:36:07 -03:00
Alan Evans
350d1f47d3 Give conversation a standard navigate up button.
* Prevent a failing IDE preview.
2019-05-28 17:36:07 -03:00
Alan Evans
2ae42cb095 Hide local video when toggled on and off.
Fixes #8827
2019-05-28 17:36:07 -03:00
Alan Evans
dae0d30367 Do not show contact address in subtitle. 2019-05-23 16:57:50 -03:00
Alan Evans
e5f70bdbda End RTC call on incoming PSTN call.
* Hangs up when new device call is answered.
* Ensure not on a device call when starting a Signal call.
2019-05-23 16:56:05 -03:00
Alan Evans
156fe37a60 Get SubscriptionManager by name due to ContextCompat bug for API 22.
Fixes #8826
2019-05-23 11:38:24 -03:00
Alan Evans
56848fb83d Replace sgnl.link urls with a more readable url.
* Taken out random string, reverted to single "Let's switch".

#8767
2019-05-23 08:02:15 -03:00
Alan Evans
3cba8ab58a Keep system default SIM as a fallback for when no conversation default SIM.
Fixes #8452
2019-05-22 16:59:00 -03:00
Alan Evans
88dac70087 Lint - Custom Widgets extend Appcompat Widgets. 2019-05-22 14:02:21 -03:00
Alan Evans
9445555d66 Code analysis - address @NotNull/@Nullable issues. 2019-05-22 13:51:56 -03:00
Alan Evans
7db1588578 Do not assume phone number in conversation.
Fixes #8813
2019-05-22 13:30:27 -03:00
Alan Evans
0a7970ad0c Image Editor - Allow undoing back to the original state when exceeds the undo limit. 2019-05-22 13:28:02 -03:00
Alan Evans
10ad3fbf82 Lint - Use easily identifiable wake lock tags. 2019-05-20 13:24:34 -03:00
Alan Evans
95858898d7 Lint - avoid calling a restricted API. 2019-05-20 13:24:33 -03:00
Alan Evans
16c8cc88d7 Update visibility and icon of camera flip control in call.
Fixes #8221
2019-05-20 13:24:33 -03:00
Greyson Parrelli
c0c051bb66 Bump version to 4.40.4 2019-05-20 08:31:47 -07:00
Greyson Parrelli
bd0d1e842f Updated language translations. 2019-05-20 08:28:28 -07:00
Alan Evans
7f0c998b24 Image Editor - Further crop improvements.
* Thumb accuracy improved.
* When out of bounds from drag, try to fix by adjusting translation.
* Update undo state when listener changes.
2019-05-20 12:02:40 -03:00
Greyson Parrelli
5a4c2fc7b0 Bump version to 4.40.3 2019-05-17 15:56:50 -07:00
Alan Evans
456ba5fa02 Image Editor - Replace minimum scale, with minimum pixel count.
- Anti alias images.
- Minimum crop ratio of 15:1 or original image ratio.
2019-05-17 19:42:12 -03:00
Alan Evans
9de420fde6 Image Editor - On flip or rotate, ensure undo button visibility is updated. 2019-05-17 19:00:10 -03:00
Alan Evans
401e3687de Image Editor - when no sticker selected, go back to mode NONE. 2019-05-17 16:22:07 -03:00
Alan Evans
6777b3e0e6 Image Editor - Undo button visibility. 2019-05-17 16:15:27 -03:00
Greyson Parrelli
b5d37702f9 Switch back to the classic handling of landscape text entry.
Fixes #8814
2019-05-17 12:14:14 -07:00
Greyson Parrelli
320ea9eb4e Bump version to 4.40.2 2019-05-16 16:23:19 -07:00
Greyson Parrelli
86d8cde9b4 Updated language translations. 2019-05-16 16:22:32 -07:00
Alan Evans
bf759711ef Image Editor - Keep image within crop bounds.
* 4% of original pixels must be visible.
* The entire crop must be within the image.
* On release, try to scale crop area and image to fit if the crop is invalid.
* Undo to last valid position if that didn't work.
* Additionally, center thumbs now do not respect aspect ratio lock.
2019-05-16 15:52:15 -07:00
Alan Evans
068ffc2167 Image Editor - Allow undoing during croping. 2019-05-16 15:52:03 -07:00
Alan Evans
95304fe001 Image Editor - Remove initial text.
- Flashing cursor.
2019-05-16 15:51:56 -07:00
Alan Evans
2de64fca02 Image Editor - Fix double HUD animation on older devices. 2019-05-16 15:51:41 -07:00
Greyson Parrelli
3211dd2a8f Ignore resources.arsc in apkdiff.py
Due to a bug described in:

https://issuetracker.google.com/issues/110237303

Ordering of resources can be non-deterministic.

A comment on the issue indicates that this may be resolved in
Android Gradle Plugin 3.4. We should revisit when we update.
2019-05-11 10:46:25 -07:00
Peter Gerber
b6dc25a368 Reproducible build: Ensure apkdiff.py works properly again
The recent switch to Python3 (2ccdf0e396) introduced a regression
that led to file content no longer being compared:

   In compareEntries(), two generators/iterators are created:

     sourceInfoList      = filter(lambda sourceInfo: …, sourceZip.infolist())
     destinationInfoList = filter(lambda destinationInfo: …, destinationZip.infolist())

   Few lines later, those are exhausted:

     if len(sourceInfoList) != len(destinationInfoList):

   Yet another few lines later, the exhausted generator is used again:

     for sourceEntryInfo in sourceInfoList:
        …          # <-- unreachable

This is caused by behavioral differences between Python2 and Python3:

   user@z_signal:~$ python2
   Python 2.7.13 (default, Sep 26 2018, 18:42:22)
   [GCC 6.3.0 20170516] on linux2
   Type "help", "copyright", "credits" or "license" for more information.
   >>> f = filter(lambda i: i % 2 == 0, [0, 1, 2, 3, 4, 5, 6])
   >>> list(f)
   [0, 2, 4, 6]
   >>> list(f)
   [0, 2, 4, 6]
   >>>

   user@z_signal:~$ python3
   Python 3.5.3 (default, Sep 27 2018, 17:25:39)
   [GCC 6.3.0 20170516] on linux
   Type "help", "copyright", "credits" or "license" for more information.
   >>> f = filter(lambda i: i % 2 == 0, [0, 1, 2, 3, 4, 5, 6])
   >>> list(f)
   [0, 2, 4, 6]
   >>> list(f)
   []
   >>>
2019-05-11 10:43:51 -07:00
Greyson Parrelli
4e64242883 Bump version to 4.40.1 2019-05-10 13:08:49 -07:00
Greyson Parrelli
fcd3b501eb Revert "Enable 64-bit."
This reverts commit 67704612df.
2019-05-10 13:01:34 -07:00
Greyson Parrelli
62ed098687 Bump version to 4.40.0 2019-05-10 09:35:11 -07:00
Greyson Parrelli
2a93ddfb99 Updated language translations. 2019-05-10 09:19:39 -07:00
Alan Evans
387392f38b End align footer for long message bubble sent.
Fixes #8806
2019-05-10 12:41:15 -03:00
Alan Evans
5b298b4a04 Resize image in attempts to get it to fit into the maxImageSize bytes.
Fixes #8803
2019-05-10 12:16:19 -03:00
Alan Evans
cb78684282 Ensure push groups cannot have isForceSmsSelection set.
Fixes #8807
2019-05-10 12:13:59 -03:00
Alan Evans
67704612df Enable 64-bit. 2019-05-10 12:03:45 -03:00
Alan Evans
f3c8b51520 Web RTC M74 for 64-bit. 2019-05-10 12:03:16 -03:00
Alan Evans
b1057d63a1 Lint.
- Check for permissions.
- Fix Welsh positional format.
- Remove UIThread restriction.
- Asynchronous method does not need to be restricted to UIThread and there is no StaticFieldLeak to suppress.
- Fix or Ignore New API errors.
- Reduce severity of some errors from L10N.
2019-05-10 11:57:43 -03:00
Alan Evans
2ccdf0e396 Bring the Reproducible Builds instructions and script into repo. 2019-05-10 11:57:43 -03:00
Alan Evans
93e6ccb9e4 Replace image editor. 2019-05-10 11:57:43 -03:00
Alan Evans
196ef60a82 Update camera icons. 2019-05-09 14:38:28 -03:00
Alan Evans
478e5667b4 Update signal-service-android to 2.13.1 for 64-bit curve-25519. 2019-05-09 14:38:28 -03:00
Alan Evans
06ea000f42 Repeat count for format args of plural string.
Fixes #8724
2019-05-07 12:26:01 -03:00
Alan Evans
d1b8e77fdc Always show the SIM on the footer of a multi-SIM device, even if one SIM is disabled. 2019-05-07 12:25:11 -03:00
Alan Evans
8cf2654c5b Show reply method SMS/Signal and respect sticky.
Fixes #8792
2019-05-06 16:45:30 -07:00
Alan Evans
18531146f7 Update the sticky EventBus message to reflect changes in microphone enabled state.
Fixes #7827
2019-05-06 16:45:30 -07:00
Jeffrey Griffin
c274c1bb28 Eliminate noisy directory feedback
We observed IOExceptions loading the Contact Discovery IAS KeyStore. We will now throw an AssertionError upon any error
creating the IAS KeyStore, matching the behaviour for creation of the TrustStore used for the main Signal Service. NB: If
this assertion is hit, the user will not even be able to refresh their contacts with the old directory service.
2019-05-06 16:45:30 -07:00
Alan Evans
42a8522e98 Manually call the onPageSelected when entering page 0.
Fixes #7610
2019-05-06 16:45:30 -07:00
Greyson Parrelli
960e165c7d Bump version to 4.39.4 2019-05-06 15:51:10 -07:00
Greyson Parrelli
eab23a9e66 Fixed issue where giphy results weren't loading. 2019-05-06 15:48:43 -07:00
Greyson Parrelli
c7b626082c Bump version to 4.39.3 2019-05-06 12:31:59 -07:00
Greyson Parrelli
59f362495a Add additional checks around link preview domains.
We never make requests to non-whitelisted domains, but there were
situations where some links would redirect to non-whitelisted domains,
which would hit a final failsafe that resulted in a crash.

To prevent this, we detect bad redirects earlier and fail more
gracefully.

Fixes #8796
2019-05-06 12:25:53 -07:00
Greyson Parrelli
6c44437c6f Bump version to 4.39.2 2019-05-02 15:38:25 -07:00
Greyson Parrelli
fed8ae68e9 Updated language translations. 2019-05-02 15:32:44 -07:00
Greyson Parrelli
934a2a67bc Fix some keyboard issues in landscape. 2019-05-02 14:32:53 -07:00
Greyson Parrelli
05345b8582 Remove some unnecessary logging. 2019-05-02 14:32:53 -07:00
Greyson Parrelli
cef5de2be4 Removed unnecessary WorkManager relic. 2019-05-02 14:32:53 -07:00
Greyson Parrelli
7b4299d5da Bring back conscrypt, improve provider initialization ordering. 2019-05-02 14:32:48 -07:00
Alan Evans
ec20b0e0e3 Fallback to SIM index.
#8725
2019-05-02 18:16:59 -03:00
Greyson Parrelli
ff1531b836 Bump version to 4.39.1 2019-05-01 08:42:49 -07:00
Greyson Parrelli
1675c8a79a Updated language translations. 2019-05-01 08:42:44 -07:00
Greyson Parrelli
bb90987e7c Fix potential crash when retrieving SIM list. 2019-05-01 08:36:24 -07:00
Greyson Parrelli
ecea6abeb6 Temporary revert (again) to fix an avatar retrieval issue.
This reverts commit 77524ae1f2.
2019-05-01 08:25:14 -07:00
Greyson Parrelli
4a2f3136c6 Bump version to 4.39.0 2019-04-30 12:51:58 -07:00
Greyson Parrelli
d12b02fac5 Updated language translations. 2019-04-30 12:51:58 -07:00
Greyson Parrelli
1e564b6ad1 Fix exponential backoff retry limits. 2019-04-30 12:51:58 -07:00
Alan Evans
c77daa8226 Display carrier or number if any SIM descriptions clash.
Fixes #8725
2019-04-30 12:51:58 -07:00
Alan Evans
fa35814344 Disable transport disables all matching TransportOptions.
Fixes #8744
2019-04-30 12:51:58 -07:00
Alan Evans
48efcaa785 Do not list SIMs that are not ready.
Fixes #8426
2019-04-30 12:51:58 -07:00
Greyson Parrelli
f3f6cc87d9 Request a small chunk instead of HEAD for images of unknown size. 2019-04-30 12:51:58 -07:00
Greyson Parrelli
29cdb5290b Make headers for giphy requests random sizes. 2019-04-30 12:51:58 -07:00
Greyson Parrelli
77524ae1f2 Revert "Temporary revert to fix an avatar retrieval issue."
This reverts commit 267bc32e23.
2019-04-30 12:51:58 -07:00
Greyson Parrelli
30ba9d7e27 Improve CDN reliability. 2019-04-30 12:51:58 -07:00
Alan Evans
9652fd2844 Update MMS configs. 2019-04-30 12:51:58 -07:00
Francois Blackburn
d2ece1c1f2 Add MI 5 to hardware AEC blacklist 2019-04-30 12:51:57 -07:00
Arnt Gulbrandsen
8bdc257963 Avoid hardware echo cancellation for Fairphone FP2
The issue has as been confirmed by me with the stock ROM as of November
2018, and other users have complained for almost 18 months, see
https://forum.fairphone.com/t/fnord/28849 and
https://bugtracker.fairphone.com/project/fairphone-fairphone-os-android-6/issue/77
2019-04-30 12:51:57 -07:00
Kevin Mark
88f9ec313f Close SQL statement, preventing finalizer crashes
This will stop instances of the following from occuring in the logs
on SMS migration:

W/SQLiteCompiledSql: Releasing statement in a finalizer. Please ensure
that you explicitly call close() on your cursor: INSERT INTO sms
(address, person, date_sent, date, protocol, read, status, type,
reply_path_present,
    net.sqlcipher.database.DatabaseObjectNotClosedException: Application did not close the cursor or database object that was opened here
        at net.sqlcipher.database.SQLiteCompiledSql.<init>(SQLiteCompiledSql.java:62)
        at net.sqlcipher.database.SQLiteProgram.<init>(SQLiteProgram.java:109)
        at net.sqlcipher.database.SQLiteStatement.<init>(SQLiteStatement.java:39)
        at net.sqlcipher.database.SQLiteDatabase.compileStatement(SQLiteDatabase.java:1647)
        at org.thoughtcrime.securesms.database.SmsDatabase.createInsertStatement(SmsDatabase.java:767)
        at org.thoughtcrime.securesms.database.SmsMigrator.migrateConversation(SmsMigrator.java:166)
        at org.thoughtcrime.securesms.database.SmsMigrator.migrateDatabase(SmsMigrator.java:210)
        at org.thoughtcrime.securesms.service.ApplicationMigrationService$ImportRunnable.run(ApplicationMigrationService.java:159)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
        at java.lang.Thread.run(Thread.java:764)

We aren't closing Statement objects before the finalizer on those
objects runs. When the GC runs, we'll get warnings like the above
which alert us to the fact that these objects are being automatically
closed for us in the finalizer, but that this is suboptimal behavior.

If we leave too many Statement (or Cursor) objects to be closed in
their finalizers, when the GC runs, it'll take longer than 10 seconds
to close them all and Android will kill the app. This 10 second limit
is hardcoded and we can only try to avoid it. A crash will look like:

java.util.concurrent.TimeoutException: net.sqlcipher.database.SQLiteCompiledSql.finalize() timed out after 10 seconds
    at java.lang.Object.wait(Native Method)
    at java.lang.Thread.parkFor$(Thread.java:1220)
    at sun.misc.Unsafe.park(Unsafe.java:299)
    at java.util.concurrent.locks.LockSupport.park(LockSupport.java:158)
    at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:810)
    at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireQueued(AbstractQueuedSynchronizer.java:844)
    at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquire(AbstractQueuedSynchronizer.java:1173)
    at java.util.concurrent.locks.ReentrantLock$FairSync.lock(ReentrantLock.java:196)
    at java.util.concurrent.locks.ReentrantLock.lock(ReentrantLock.java:257)
    at net.sqlcipher.database.SQLiteDatabase.lock(SQLiteDatabase.java:553)
    at net.sqlcipher.database.SQLiteCompiledSql.releaseSqlStatement(SQLiteCompiledSql.java:106)
    at net.sqlcipher.database.SQLiteCompiledSql.finalize(SQLiteCompiledSql.java:152)
    at java.lang.Daemons$FinalizerDaemon.doFinalize(Daemons.java:202)
    at java.lang.Daemons$FinalizerDaemon.run(Daemons.java:185)
    at java.lang.Thread.run(Thread.java:818)

I was able to replicate the above crash consistently on a
Samsung Galaxy S7 edge when importing well over 100k SMS messages.
But as soon as I attached a debugger the crash did not persist. I
assume this is because of some VM-level interactions between the two
and did not investigate further after fixing it.

I do not have access to the stack trace for issue #7953 but this
could potentially resolve it. The crash is identical to that in #7477
but this patch is for SMS migration not restoring from a backup. I
was not able to replicate the crash on restoring a >100k message
backup.
2019-04-30 12:51:57 -07:00
Michael Walker
8ad5126408 Add pinterest domain and asset domains for link preview support 2019-04-30 12:51:57 -07:00
Greyson Parrelli
1e27847015 Update link preview meta tag regex. 2019-04-30 12:51:57 -07:00
Greyson Parrelli
e67eca77ff Prevent landscape text editing from taking over the screen.
It used to be that we let Android do the default behavior of
full-screening the EditText when in landscape, but honestly I
don't know who prefers that. So I've turned it off.

Fixes #8769
2019-04-30 12:51:52 -07:00
Greyson Parrelli
ba46a9d81a Bump version to 4.38.3 2019-04-28 11:44:23 -07:00
Greyson Parrelli
49cccc6927 Update job logging. 2019-04-28 11:44:17 -07:00
Greyson Parrelli
5977e9141d Wrap transactions in try-finally. 2019-04-28 11:42:02 -07:00
Greyson Parrelli
c0982293bf Fix bug where sticky SMS setting wasn't respected.
Fixes #8783
2019-04-28 11:34:56 -07:00
Greyson Parrelli
ae6ef62160 Bump version to 4.38.2 2019-04-16 10:56:59 -04:00
Greyson Parrelli
d95b08d4fd Updated language translations. 2019-04-16 10:51:25 -04:00
Greyson Parrelli
128da6db04 Fix crash in backup restore related to sqlite_sequence.
The new JobManager stuff created a table that had an
auto-incrementing ID, which was incorrectly being backed
up and restored, causing a crash. Now we skip it on both
import and export.
2019-04-16 10:10:02 -04:00
Greyson Parrelli
2701607810 Reduce the possible number of unique jobs to avoid crash.
Some devices have a limit of 100 unique JobScheduler jobs.
Previously we allowed up to 1,000. Given that we just need
_some_ job running, I lowered the limit to 75 to give us
some head room.
2019-04-16 09:52:12 -04:00
Greyson Parrelli
4055fe183b Bump version to 4.38.1 2019-04-15 15:45:16 -04:00
Greyson Parrelli
1c47812877 Fix crash when migrating read receipt jobs.
Fixes #8764
2019-04-15 15:45:16 -04:00
Greyson Parrelli
060bed8559 Bump version to 4.38.0 2019-04-15 10:59:38 -04:00
Greyson Parrelli
4a3c173adb Migrated to new JobManager. 2019-04-15 10:56:26 -04:00
Greyson Parrelli
8cf3ba424a Trim long text before displaying if necessary.
Fixes #8759
2019-04-15 10:13:35 -04:00
Alan Evans
9c40de5bf1 Save the SMS setting on a per-conversation basis. 2019-04-15 10:13:35 -04:00
Greyson Parrelli
11a2ed0743 Increase reliability of locally logging crashes.
Exception logging tends to be race-y, so now we block and wait
for all logs to be written before continuing with the crash.
2019-04-10 12:53:55 -04:00
Alan Evans
01a9931d92 Do not use background threads for download UI events. 2019-04-10 13:13:10 -03:00
Greyson Parrelli
38bcc6c293 Long text detail view now respects text size preference.
Fixes #8747
2019-04-09 09:40:32 -04:00
Greyson Parrelli
bceb9b4972 Fixed quotes not being cleared when forwarding.
Fixes #8748
Fixes #7935
2019-04-09 09:35:47 -04:00
Alan Evans
ecdc285378 Fix unresponsive button on image send with text in landscape.
Fixes #8575
Closes #8638

Co-authored-by: Jakub Gregorek <jg@inthemeadow.net>
2019-04-08 07:45:16 -03:00
Greyson Parrelli
6d111e5f68 Bump version to 4.37.2 2019-04-04 23:18:30 -04:00
Greyson Parrelli
9aed2343c1 Attempt to resolve connectivity problems for some users. 2019-04-04 18:10:41 -04:00
Greyson Parrelli
733d54e339 Linkify links in long message view.
Fixes #8735
2019-04-04 10:09:32 -04:00
Greyson Parrelli
267bc32e23 Temporary revert to fix an avatar retrieval issue.
This reverts commit 8aa185070b.
2019-04-03 16:32:52 -04:00
Greyson Parrelli
7acb4973d8 Bump version to 4.37.1 2019-04-01 17:29:26 -04:00
Alan Evans
39ba8c2ad3 Remove armeabi from splits. 2019-04-01 17:43:10 -03:00
Alan Evans
621ac62c7e Add red flashing voice note microphone. 2019-04-01 17:42:57 -03:00
Greyson Parrelli
652306edd0 Bump version to 4.37.0 2019-03-29 09:55:09 -07:00
Alan Evans
b9b4dccff4 ABI splits. 2019-03-28 17:21:57 -03:00
Alan Evans
ce6d2d9c69 MMS image quality.
Fixes #8590
- Scale image larger within the dimensions.
- Apply a minimum dimension of 1024.
2019-03-28 15:14:06 -03:00
Alan Evans
e842f78457 Voice Note Locking.
Limit of 60 minutes, after which it's cancelled.
2019-03-28 15:04:38 -03:00
Alan Evans
cab3657ab0 ABI info for device. 2019-03-26 17:29:08 -03:00
Alan Evans
a7aa980e58 New dynamic locale system.
- Fixes #7619
2019-03-26 17:08:05 -03:00
Alan Evans
6a0a419f0c Add self to MMS group.
- Fixes #7683
- Closes #8296
2019-03-26 17:07:04 -03:00
Greyson Parrelli
94e8303022 Remove dead code from ScribbleHud/Fragment. 2019-03-22 12:47:16 -07:00
Greyson Parrelli
ccfcfa71df Enable the sending of long messages. 2019-03-22 12:28:41 -07:00
Alan Evans
cfdcd61e51 Local build quality assurance task. 2019-03-21 11:19:07 -07:00
Greyson Parrelli
b89c20ff40 Switch to 'start' and 'end' instead of 'left' and 'right'.
We can do this now that our minSdk is 19.
2019-03-21 11:19:06 -07:00
Greyson Parrelli
8caaf057e8 Remove unnecessary pre-19 code branches.
Now that our minSdk is 19, we can remove a lot of old code paths that
only ran pre-19.
2019-03-21 11:19:06 -07:00
Moxie Marlinspike
a52c295a38 Simplify access to SecureRandom
This shouldn't matter at all, but it's more "correct," and shows
my age less.
2019-03-21 11:19:06 -07:00
Moxie Marlinspike
8aa185070b Update libsignalservice to 2.13.0
- Eliminate the explicit spongycastle dependency. All access to
  primitives is done through the JCE interfaces now, which allows
  us to use a secure native-backed provider like conscrypt.

- Use conscrypt for our default security provider. This gives us
  fast TLS 1.2 and 1.3 support on all devices, even before they
  had platform support (like 4.4).

- Update minSdk to 18. Unfortunately the JCE interfaces for GCM
  primitives are JDK 7+ (!) only, which became supported by Android
  at 18.
2019-03-21 11:19:06 -07:00
Alan Evans
de60d4d37f 64-bit native utils.
* Update Application.mk.
* 64-bit libnative-utils
* New build of x86 and armeabi-v7a libnative-utils.
* Update to API19.
2019-03-21 11:19:06 -07:00
Alan Evans
6e5658431b Remove armeabi. 2019-03-21 11:19:06 -07:00
Greyson Parrelli
6df5457305 Bump minSdk to 19. 2019-03-21 11:19:06 -07:00
Greyson Parrelli
fd50b38630 Bump version to 4.36.2 2019-03-21 11:02:12 -07:00
Alan Evans
d41b24f9ae Fix "multiple substitutions specified in non-positional format" lint. 2019-03-21 11:02:12 -07:00
Greyson Parrelli
aa5e32f0ee Add back the highlight and sticker tools. 2019-03-21 11:02:07 -07:00
Greyson Parrelli
749d096931 Updated language translations. 2019-03-21 09:57:12 -07:00
Greyson Parrelli
8e86c7d81a Fix media button visibility issue on older Android versions.
Turns out setVisibility doesn't work unless you call clearAnimation()
first on older Android versions. Isn't that grand?
2019-03-21 00:11:01 -07:00
Greyson Parrelli
148cfd1b53 Fix crash when single-selecting large media. 2019-03-20 23:01:32 -07:00
Greyson Parrelli
93c1277fd0 Fix voice note button clipping. 2019-03-20 22:25:19 -07:00
Greyson Parrelli
23e069ffa8 Bump version to 4.36.1 2019-03-19 19:27:29 -07:00
Greyson Parrelli
6e7fab40ac Guard against OOB moves in media send flow. 2019-03-19 18:38:06 -07:00
Greyson Parrelli
8a7cac7c03 Switch gallery to permanent dark theme. 2019-03-19 18:38:06 -07:00
Greyson Parrelli
932e7b4af5 Fix button flicker when selecting single media item. 2019-03-19 18:38:02 -07:00
Greyson Parrelli
2f8a7fa296 Bounce the media select button when selecting media. 2019-03-19 15:42:08 -07:00
Greyson Parrelli
5e6f71cd32 Show selection order in multi-select. 2019-03-19 15:42:08 -07:00
Greyson Parrelli
ce0058864f Make BlobProvider write to disk on a background thread.
Otherwise we hit some weird blocking issues with voice note recording.
2019-03-19 15:34:04 -07:00
Greyson Parrelli
5a8753de85 Fix group string. 2019-03-19 10:34:56 -07:00
Greyson Parrelli
c646316a97 Block typing indicators from blocked contacts. 2019-03-19 09:39:19 -07:00
Greyson Parrelli
6df8988f54 Updated to WebRTC M73. 2019-03-19 09:03:02 -07:00
Greyson Parrelli
5b534c8b1a Update URL homograph rules. 2019-03-18 17:37:19 -07:00
Greyson Parrelli
ab2e85f6c7 Bump version to 4.36.0 2019-03-18 15:10:13 -07:00
Greyson Parrelli
975a121c55 Show a warning for users on API < 19.
We'll be updating minSdk to 19 in 4.37. This lets these users continue
to use the app, but they'll be warned with a persistent banner saying
that they can't receive updates.
2019-03-18 15:09:56 -07:00
Greyson Parrelli
64cf032181 Updated media send UI. 2019-03-18 15:09:56 -07:00
Alan Evans
d8a56be5e8 Gradle/Gradlew/AndroidGradlePlugin update. 2019-03-18 15:09:56 -07:00
Alan Evans
286b64274c Replace Avatar Cropper. 2019-03-18 15:09:50 -07:00
Alan Evans
0cb2404735 Lint error fixes.
* Old Gingerbread code removed.
* Add missing super call.
2019-03-18 11:14:18 -03:00
Greyson Parrelli
0a8bbf14a6 Merge camera into send flow. 2019-03-14 16:25:35 -07:00
Greyson Parrelli
eb1dd58a0b Persistent media in multi-send. 2019-03-14 16:20:36 -07:00
Alan Evans
a79df7d815 Automatic resConfig.
- Test to ensure language_entries list matches exactly the available resources.
2019-03-14 13:33:43 -03:00
Alan Evans
e0c11998c3 Make DisplayRecord take context as argument, so locale is more likely to be correct. 2019-03-13 18:28:16 -03:00
Alan Evans
de72eceecf Update help URL to avoid redirect. 2019-03-13 18:19:33 -03:00
Alan Evans
c46e53ab24 Add Esperanto and Swahili (Kiswahili) to language selection. 2019-03-13 17:45:53 -03:00
Alan Evans
2c28fa6a57 Make GIF search layout option sticky.
Fixes #7843
2019-03-12 11:41:54 -03:00
Alan Evans
f010a3ec0d Consistent Recipient to add contact Intent export. 2019-03-12 11:29:59 -03:00
Alan Evans
e390fb4fc5 Fix ShareMessage toolbar back button. 2019-03-12 11:29:59 -03:00
Greyson Parrelli
a4ce77cbcc Remove unused method. 2019-03-12 11:29:59 -03:00
Greyson Parrelli
18613e3b6f Remove generic foreground service condition from Job.
I don't think it actually helps at all, meaning it just adds
complexity.

Fixes #8677
2019-03-12 11:29:59 -03:00
Greyson Parrelli
278fdebf43 Update WorkManager to 1.0.0. 2019-03-12 11:29:59 -03:00
Greyson Parrelli
a122bb4899 Created new BlobProvider.
One unified place to create blobs for different lifespans.
2019-03-10 15:18:39 -07:00
Greyson Parrelli
22ed8caed3 Bump version to 4.35.3 2019-03-07 17:59:18 -08:00
Greyson Parrelli
8b6ecd1d2e Fixed profile screen layout on small screens.
Fixes #8670
2019-03-07 17:25:02 -08:00
Greyson Parrelli
f2703f0b7b Bump version to 4.35.2 2019-03-06 08:12:42 -08:00
Greyson Parrelli
1efb92b913 Fix issue where SMS were sometimes sent as MMS.
Fixes #8664
2019-03-06 08:12:00 -08:00
Greyson Parrelli
5ccf84f7a2 Bump version to 4.35.1 2019-03-02 21:01:15 -08:00
Greyson Parrelli
c3368f6de6 Updated language translations. 2019-03-02 20:46:40 -08:00
Greyson Parrelli
77e971cb9b Fix bug where system emoji setting was ignored in message bubbles.
EmojiTextView. It is our gift. It is our curse.
2019-03-02 19:31:28 -08:00
Greyson Parrelli
003fa1b059 Make long text attachments contain the entire message.
Instead of just containing the 'overflow', long text attachments now
contain the entire body in full.
2019-03-02 19:31:22 -08:00
Greyson Parrelli
03aa9e9712 Bump version to 4.35.0 2019-03-01 14:19:21 -08:00
Greyson Parrelli
55699e27bc Added ability to receive long messages.
Send support is in here too. We'll enable it in a future release after
enough people have updated.
2019-03-01 14:15:08 -08:00
Greyson Parrelli
bf28e109d3 Update registration UI. 2019-03-01 14:15:01 -08:00
Greyson Parrelli
6b476876d9 Lower volume of call connect/disconnect sound.
It's now closer in amplitude to the ringing sound.

Fixes #8165
2019-03-01 13:44:32 -08:00
Greyson Parrelli
fd862e575b Fix situation where search nav could get stuck.
If you navigated to the ConversationActivity again via some action (like
a shared contact invite) while searching, we don't get the toolbar close
event, and therefore the search nav would stay open. Now we just reset
it on newIntent() to be safe.
2019-03-01 13:44:32 -08:00
Greyson Parrelli
7fd6f5b3ff Fix search highlight in multi-whitespace bodies.
The way the highlight was done could get screwed up if you had multiple
whitespaces in a row. This particularly came up with messages with
multiple newlines.
2019-03-01 13:44:32 -08:00
Greyson Parrelli
42e94d8f92 Remove leftover half-height camera code. 2019-03-01 13:44:32 -08:00
Greyson Parrelli
b572fce658 Remove some unnecessary intermediate blob creation. 2019-03-01 13:44:32 -08:00
Greyson Parrelli
276e867f9a Improved address resolution for ContentProxySelector.
We can use an unresolved address to avoid all the threading stuff in
that class.
2019-03-01 13:42:10 -08:00
Greyson Parrelli
b2d4608cdb Improved handling for URLs that are composed of mixed character sets. 2019-02-24 10:00:44 -08:00
Greyson Parrelli
9d21c36ddf Bump verstion to 4.34.8
Again, no changes. Needed to resubmit to the Play Store.
2019-02-21 18:04:44 -08:00
Greyson Parrelli
983290aa5b Bump version to 4.34.7
No changes. Necessary to resubmit to Google Play.
2019-02-21 12:57:55 -08:00
Greyson Parrelli
88b9fc25d2 Bump version to 4.34.6 2019-02-20 17:23:54 -08:00
Greyson Parrelli
60c7fb0056 Fix possible NPE. 2019-02-20 17:20:12 -08:00
Greyson Parrelli
fa6da1902f Fix button spinning after failed CAPTCHA. 2019-02-19 13:13:32 -08:00
Greyson Parrelli
5cc3ac00c7 Bump version to 4.34.5 2019-02-19 09:37:30 -08:00
Greyson Parrelli
33daa21ad9 Guard against devices not supporting mandatory ContentProvider columns.
The docs specify that this column is supposed to be present, but a
crash says it wasn't, so alas, here in goes the check.
2019-02-19 09:34:24 -08:00
Greyson Parrelli
c4d1bdc44d Bump version to 4.34.4
No changes. Necessary to resubmit to the Play Store.
2019-02-18 16:03:15 -08:00
Greyson Parrelli
ca99c732f8 Bump version to 4.34.3 2019-02-18 11:47:40 -08:00
Greyson Parrelli
1f79808cf0 Remove unneccesary FCM manifest attribute.
`firebase_analytics_collection_enabled` is used for temporarily
enabling/disabling analytics.

We already use `firebase_analytics_collection_deactivated`, which is
used for permanently disabling analytics.
2019-02-18 11:46:53 -08:00
Greyson Parrelli
5c0e1100ed Fix possible NPE in conversation menu.
Would occur if someone had previously muted a conversation with
themselves.
2019-02-16 11:45:09 -08:00
Greyson Parrelli
d0b763c16e Bump version to 4.34.2 2019-02-15 19:34:19 -08:00
Greyson Parrelli
b962751c96 Fix possible IllegalArgumentException during a database migration. 2019-02-15 19:33:16 -08:00
Greyson Parrelli
94e8553b73 Fix possible NPE during conversation load. 2019-02-15 19:24:23 -08:00
Greyson Parrelli
351b625975 Bump version to 4.34.1 2019-02-15 14:21:27 -08:00
Greyson Parrelli
a2b6dbda14 Correctly sync Note to Self conversation color. 2019-02-15 14:21:27 -08:00
Greyson Parrelli
a6564f8f84 FCM improvements. 2019-02-15 14:21:23 -08:00
Greyson Parrelli
4dbe165c18 Bump version to 4.34.0 2019-02-14 21:04:01 -08:00
Greyson Parrelli
f29a42411e Update WorkManager to beta05. 2019-02-14 20:19:07 -08:00
Greyson Parrelli
02b0800b22 Support requesting a CAPTCHA during registration. 2019-02-14 20:19:07 -08:00
Greyson Parrelli
2cfa431cad Supply a reason for CDS error reporting. 2019-02-14 20:19:07 -08:00
Greyson Parrelli
fe4068afce Don't preview links if your cursor is touching them. 2019-02-14 20:19:07 -08:00
Greyson Parrelli
1c23603c25 Add the Redmi Note 5 to the hardware AEC blacklist. 2019-02-14 20:19:07 -08:00
Greyson Parrelli
c2a86fcc74 Sync self-sends to desktop.
Updated UI to show self-conversations as "Note to Self".
2019-02-14 20:19:07 -08:00
Greyson Parrelli
d42c9b5dbc Ensure the group shortstring in the action bar is up-to-date.
There were situations where adding/removing members from a group
would update the group member list, but the short string (the little
text listing the first couple members of the group) wouldn't be updated
until you left the screen and came back.
2019-02-14 20:19:06 -08:00
Greyson Parrelli
3b6429c163 Don't unnecessarily stop the ShareActivity in onPause.
1. Due to ShareActivity having noHistory=true, it will already be
ditched when you leave the activity.
2. We only need to truly finish() here if we've dropped the underlying
media.

Fixes #8591
2019-02-14 20:19:06 -08:00
Greyson Parrelli
6896f8ea15 Properly check attachment size during media send.
Prevent users from trying to send videos that exceed the size limit.

Also, this commit properly populates height/width on media shared into
the app.

Fixes #8573
2019-02-14 20:19:06 -08:00
Greyson Parrelli
a3768c7d74 Fix StickyHeader measuring.
It didn't re-measure when pulling an item from the cache, screwing stuff
up after a phone rotation. Had a workaround for it for specific screens,
but this fixes the problem at the source.

Fixes #8583
2019-02-14 20:19:06 -08:00
Greyson Parrelli
c9a0a66f18 Migrate backup passphrase to be keystore-encrypted when available. 2019-02-14 20:19:06 -08:00
Greyson Parrelli
db1ad39c6b Fix issues with bundled notifications. 2019-02-14 20:19:06 -08:00
Greyson Parrelli
9f04c28bfd Implemented conversation search.
You can now search for messages within a specific conversation.
2019-02-14 20:19:01 -08:00
Greyson Parrelli
10631d7e71 Add a gradle.properties with increased memory size. 2019-02-14 14:29:12 -08:00
Greyson Parrelli
cfff10622a Move conversation classes to their own package. 2019-02-14 14:29:12 -08:00
Greyson Parrelli
b769c7d9b6 Properly batch contact inserts.
Fixes #8580
2019-02-14 14:29:12 -08:00
Greyson Parrelli
1e0f691a56 Updated to WebRTC M72. 2019-02-14 14:28:57 -08:00
Greyson Parrelli
f0852d1d39 Bump version to 4.33.5 2019-02-07 16:54:59 -08:00
Greyson Parrelli
1ee422a012 Update link preview splash to say 'Got it'. 2019-02-07 16:43:40 -08:00
Greyson Parrelli
ca87820dd5 Updated language translations. 2019-02-07 16:20:39 -08:00
Greyson Parrelli
45ddb7e1ad Revert "Fix notification badge display."
This reverts commit a0c1446e9f.
2019-02-07 16:17:17 -08:00
Greyson Parrelli
fd46777f04 Bump version to 4.33.4
No changes. Need to create a new version to handle Play Store issues.
2019-02-06 10:27:59 -08:00
Greyson Parrelli
5bb36c15d5 Bump version to 4.33.3 2019-02-06 09:22:19 -08:00
Meteor0id
c5571e8a8d Add 'Got it' as string to be used on link preview splash screen.
"Understood" or "Got it" is a way of dismissing a splash screen of notification without any change that is applies agreeing to anything.
It replaces "OK" which was sometimes misinterpreted as "I am OK with what I just read".
2019-02-06 09:22:19 -08:00
Greyson Parrelli
b8ab1bc3b2 Updated language translations. 2019-02-06 08:39:00 -08:00
Greyson Parrelli
3683e6a9e2 Revert "Apply contact updates in batches of 50."
This reverts commit 5d9d6ac12b.
2019-02-06 00:54:03 -08:00
Greyson Parrelli
c364345e1d Add some additional FCM logging. 2019-02-06 00:53:52 -08:00
Greyson Parrelli
7da73bbc30 Updated link preview splash layout. 2019-02-06 00:34:48 -08:00
Greyson Parrelli
177322eca4 Bump version to 4.33.2 2019-02-04 13:57:49 -08:00
Greyson Parrelli
506491d13d Updated language translations. 2019-02-04 13:56:06 -08:00
Greyson Parrelli
e884911b60 Update the link preview domain whitelist. 2019-02-04 09:05:40 -08:00
Greyson Parrelli
7b20fca1ac Clearing the text field resets link preview cancellation. 2019-02-04 08:54:54 -08:00
Greyson Parrelli
e2c2e59442 Bump version to 4.33.1 2019-02-02 10:13:37 -08:00
Greyson Parrelli
be66db898c Fix possible double-cancel in CallRequestController. 2019-02-02 10:09:38 -08:00
Greyson Parrelli
5d9d6ac12b Apply contact updates in batches of 50.
If batch sizes are too large, we'll get a Binder exception.

Fixes #8580
2019-02-01 12:47:34 -08:00
Greyson Parrelli
c6d3bed8da Hide emoji button in media flows when system emoji are enabled.
Fixes #8581
2019-02-01 09:17:07 -08:00
Greyson Parrelli
e74c429695 Bump version to 4.33.0 2019-01-30 16:34:10 -08:00
Greyson Parrelli
90a37852cc Hide quoted attachments from All Media and media rails.
Fixes #8009
2019-01-30 16:34:10 -08:00
Greyson Parrelli
1763be2956 Hide call settings for groups. 2019-01-30 16:33:02 -08:00
Greyson Parrelli
9797c54a4d Removed sonar ping from calls.
People rarely understood what it meant, and the information is available
on the screen if-needed ('dialing' vs 'ringing').
2019-01-30 16:10:47 -08:00
Greyson Parrelli
c5114e2cb3 Updated to WebRTC M71. 2019-01-30 16:10:47 -08:00
Greyson Parrelli
e3b22dabce Harden notification channels.
There's odd corner cases where channels can be duplicated. This commit
adds some hard checks where we trim any dead channels, and unset any
notification channels from recipients whose notification channel isn't
present in the system settings.
2019-01-30 16:10:47 -08:00
Bas van Schaik
ba67796992 Fix invalid equals in NotificationChannels.channelExists
`DEFAULT_CHANNEL_ID` is a String, but `channel` is a NotificationChannel. Equals will therefore always return `false`. I think my fix (using `getId()`) is what was intended.
2019-01-30 16:10:47 -08:00
Greyson Parrelli
d482c60a98 Switch from GCM to FCM. 2019-01-30 16:10:47 -08:00
Greyson Parrelli
ebe8d38a91 Update WorkManager to beta03. 2019-01-30 16:10:47 -08:00
Greyson Parrelli
c76081d99c Added support for link previews. 2019-01-30 16:10:43 -08:00
Greyson Parrelli
bef9beff16 Updated Gradle to 5.1 2019-01-29 09:22:44 -08:00
Greyson Parrelli
25e82ff5e4 Fixed issue where we'd incorrectly show input shadow.
We might have also scrolled with typing indicators when we shouldn't of.

All came down to #isAtBottom() being calculated incorrectly.
2019-01-27 22:07:55 -08:00
Greyson Parrelli
13ffba1c99 Updated language translations. 2019-01-25 17:55:31 -08:00
Greyson Parrelli
a0c1446e9f Fix notification badge display.
This reverts commit 2489ea0d5b.
2019-01-21 16:43:59 -08:00
Greyson Parrelli
657b520908 Bump version to 4.32.8 2019-01-20 14:22:27 -08:00
Greyson Parrelli
51e8e8c2c8 Go back to WorkManager beta01.
Looks like there may be a rescheduling bug in beta02. Working through it
with the WorkManager devs.
2019-01-20 14:12:29 -08:00
Greyson Parrelli
1e534a2a10 Fix group avatars not sending.
Fixes #8547
2019-01-20 12:00:18 -08:00
Greyson Parrelli
9fe30524b2 Bump version to 4.32.7 2019-01-17 15:39:13 -08:00
Greyson Parrelli
e6b4249cf3 Deprecate usage of the signaling key. 2019-01-17 15:37:53 -08:00
Greyson Parrelli
57ef0e9024 Bump version to 4.32.6 2019-01-17 12:33:41 -08:00
Greyson Parrelli
9ed290b8f6 Updated language translations. 2019-01-17 12:33:41 -08:00
Greyson Parrelli
d2be554e1b Use orientation in media picker to determine width and height. 2019-01-17 12:33:41 -08:00
Greyson Parrelli
e7a807ab5b Ensure body text is carried through to the media send screen.
We were only doing it if you entered through the media rail. Now we also
do it if you enter through the gallery.
2019-01-17 11:42:01 -08:00
Greyson Parrelli
9ff8f8587b Bump version to 4.32.5 2019-01-16 14:34:36 -08:00
Greyson Parrelli
a6f31c60bd Show a toast when you've gone over the max media selection. 2019-01-16 14:31:59 -08:00
Greyson Parrelli
4643dea2ad Filter out non-media from media send screen. 2019-01-16 13:32:39 -08:00
Greyson Parrelli
f70bf9c5bd Default to 'All media' bucket for items from the rail.
This should give people a better multi-send experience when they want to
add more media.
2019-01-16 13:18:16 -08:00
Greyson Parrelli
557e6a800f Bump version to 4.32.4 2019-01-16 00:10:46 -08:00
Greyson Parrelli
17a391d3cf Updated language translations. 2019-01-16 00:06:53 -08:00
Greyson Parrelli
fc989f3820 Fix album sizing issues on skinnier devices. 2019-01-15 23:57:43 -08:00
Greyson Parrelli
2be382afab Bump version to 4.32.3 2019-01-15 15:10:18 -08:00
Greyson Parrelli
b08f81a8dc Fix bug where back stack can get stuck in the gallery. 2019-01-15 15:08:35 -08:00
Greyson Parrelli
535e00c6d0 Saving an album will now save every item.
Fixes a bug where saving would incorrectly only save the first image.
2019-01-15 14:56:27 -08:00
Greyson Parrelli
db1abf3746 Bump version to 4.32.2 2019-01-15 13:52:02 -08:00
Greyson Parrelli
66dde4415d Added an 'All media' folder in the gallery. 2019-01-15 13:38:06 -08:00
Greyson Parrelli
ce3deb4057 Update WorkManager to beta02. 2019-01-15 12:54:14 -08:00
Greyson Parrelli
2209ff2272 Use AttachmentUploadJob in PushGroupSendJob. 2019-01-15 12:43:38 -08:00
Greyson Parrelli
1502b0ae3e Add processing rules for partial US and BR phone numbers. 2019-01-15 11:57:42 -08:00
Greyson Parrelli
553669de45 Bump version to 4.32.1 2019-01-14 15:43:21 -08:00
Greyson Parrelli
4952b4470d Fix bug related to gallery selection state.
TreeSets are annoying. contains() is calculated with the comparator,
which can lead to some weird bugs. Made sure the comparator didn't think
two items with the same date were identical.

Also fixed stableId generation to avoid any potential weirdness there.
2019-01-14 15:40:38 -08:00
Greyson Parrelli
5450967d00 Ensure all Workers have a public WorkManager constructor. 2019-01-14 15:15:53 -08:00
Greyson Parrelli
37b9e4f200 Bump version to 4.32.0 2019-01-14 11:25:12 -08:00
Greyson Parrelli
254275a8e0 Updated language translations. 2019-01-14 11:25:12 -08:00
Greyson Parrelli
8434813ad6 Updated libsignal-service-java to 2.12.5 2019-01-14 11:25:12 -08:00
Greyson Parrelli
dcae8a8a2f Update WorkManager to beta01. 2019-01-14 11:25:12 -08:00
Greyson Parrelli
6fa7eca60b Implement new media send flow.
Update our media send flow to allow users to send multiple images/videos
at once. This change includes:

- New in-app media picker flow.
- Ability to caption images and videos.
- Image editing tools are made more prominent in the flow.
- Some fixes to the image editing tools.
2019-01-14 11:25:06 -08:00
Greyson Parrelli
bae55f4b2f Remove redundant km_KH mapping. 2019-01-13 19:25:40 -08:00
riyapenn-signal
7278f6db76 Update in-app language list for Welsh, Hindi, Quechua, Khmer
Languages added: 

1. Welsh Cymraeg cy
2. Hindi Hindi हिंदी hi 
3. Quechua qu_EC

Languages modified: 

1. Khmer from kh-rKH to kh
2019-01-13 19:25:40 -08:00
Greyson Parrelli
b553bb1cb0 Don't allow sending SMS unless we're the default. 2019-01-13 19:25:40 -08:00
Greyson Parrelli
3b67382f67 Remove call log permissions, use SMS Retriever API during registration.
This is to adhere to the Play Store policy updates.

See: https://play.google.com/about/privacy-security-deception/permissions/
2019-01-13 19:25:40 -08:00
Greyson Parrelli
19d5ba5c0e Upload attachments in a separate job. 2019-01-13 19:25:40 -08:00
Greyson Parrelli
96c641c2a0 Add support for Job chains. 2019-01-13 19:25:40 -08:00
Greyson Parrelli
1a50910910 Update WorkManager to alpha12. 2019-01-13 19:25:40 -08:00
Greyson Parrelli
40f9b32a75 Fix tap-to-upgrade on website releases.
Tested on Android 9.0, 7.0, and 5.1.

Fixes #7936
2019-01-13 19:08:33 -08:00
Greyson Parrelli
975d7268a1 Bump version to 4.31.8 2019-01-13 07:26:52 -08:00
Greyson Parrelli
7bda952ee5 Fix crash when DeviceName is shorter than 4 characters. 2019-01-13 07:26:16 -08:00
Greyson Parrelli
1c3052a580 Bump version to 4.31.7 2019-01-12 15:50:59 -08:00
Greyson Parrelli
7c66c4a4f7 Updated logging. 2019-01-12 13:32:24 -08:00
Greyson Parrelli
c6f3a66cad Support encrypted linked device names. 2019-01-12 13:32:24 -08:00
Greyson Parrelli
4ab02f5b9c Bump version to 4.31.6 2018-12-11 13:37:57 -08:00
Greyson Parrelli
2ab2b2306d Fixed build issues caused by Google jcenter fiasco.
Google removed a bunch of binaries from jcenter that they shouldn't
have, breaking everyone's builds. So now we have manually add repos for
the missing binaries in the meantime.
2018-12-11 13:34:16 -08:00
Greyson Parrelli
3a7f01e16a Updated language translations. 2018-12-11 13:21:54 -08:00
Greyson Parrelli
e5a2cea6b0 Fix voice note seeking issue.
On some devices, pausing+resuming (or seeking) would restart playback
from the beginning, but show a progress bar further up. This seems to
have been caused by same race condition-y thing where we were seeking
multiple times in rapid succession. Now we'll only play once, and things
seem to be fine now.

Also removed usage of some deprecated methods.

Fixes #8432
2018-12-11 13:05:36 -08:00
Greyson Parrelli
be215b3b1e Bump version to 4.31.5 2018-12-06 23:53:51 -08:00
Greyson Parrelli
2d5c2d24e5 Updated language translations. 2018-12-06 23:53:13 -08:00
Greyson Parrelli
038238a333 Allow multiple attachments to download at once.
Not only will this be faster, but it serves as a mitigation
for the times when WorkManager gets 'stuck'.

Fixes #8427
2018-12-06 23:29:55 -08:00
Greyson Parrelli
bfdad2f47c Updated logging. 2018-12-06 12:43:45 -08:00
Greyson Parrelli
2489ea0d5b Revert "Fix notification badge display."
This reverts commit caf93b9203.
2018-12-06 12:14:45 -08:00
Greyson Parrelli
053f071f41 Bump version to 4.31.4 2018-12-04 18:16:00 -08:00
Greyson Parrelli
caf93b9203 Fix notification badge display.
Fixes #7580
2018-12-03 15:32:13 -08:00
Greyson Parrelli
f0bfd7224f Handle having a null sender certificate at send time.
Fixes #8425
2018-12-03 13:16:29 -08:00
Greyson Parrelli
f13becc50b Bump version to 4.31.3 2018-12-01 10:39:48 -08:00
Greyson Parrelli
4b88f7b845 Unsubscribe from typing observers when forwarding messages. 2018-12-01 10:39:48 -08:00
Greyson Parrelli
a81cc685b2 Fix crash where toolbar was updated off of the main thread. 2018-12-01 10:22:05 -08:00
Greyson Parrelli
b6098a26b4 Update typing indicator intro strings. 2018-12-01 09:55:21 -08:00
Greyson Parrelli
d6abf89a7a Filter out typing indicators from ourself. 2018-12-01 09:51:28 -08:00
Greyson Parrelli
dd55fe90bc Fix typing experience upgrade version.
Because of the production hotfix, we need to up this version to be
higher than what is currently in prod.
2018-11-28 09:29:19 -08:00
Greyson Parrelli
5a53268534 Update typing indicator intro screen. 2018-11-27 17:45:58 -08:00
Greyson Parrelli
1f9a65e389 Bump version to 4.31.2 2018-11-27 12:51:20 -08:00
Greyson Parrelli
81055e61a6 Update WorkManager to 1.0.0-alpha11. 2018-11-27 12:35:41 -08:00
Greyson Parrelli
8a1a47e773 Fix MediaPreview NPE. 2018-11-27 09:32:56 -08:00
Greyson Parrelli
193d82789f Bump version to 4.31.1 2018-11-26 11:50:55 -08:00
Greyson Parrelli
7f09d1d0d7 Updated language translations. 2018-11-26 11:50:55 -08:00
Greyson Parrelli
187d7b3e3a Fix the caption database migration. 2018-11-26 11:50:55 -08:00
Greyson Parrelli
5d1fcdaded Fix typing indicator animation.
The Android animators were getting out of sync when frames were dropped
(despite my best efforts), so now we just manually render each animation
frame as a function of time, so it never gets screwed up.

Fixes #8388
2018-11-26 09:33:31 -08:00
Greyson Parrelli
36b24d0a20 Rotate sender cert at send time if it's expired. 2018-11-26 07:52:59 -08:00
Greyson Parrelli
f9d7cf0e19 Bump version to 4.31.0 2018-11-21 01:55:30 -08:00
Greyson Parrelli
47a10a0288 Added support for multi-image receive. 2018-11-21 01:55:30 -08:00
Greyson Parrelli
e665252b86 Add more logging to GenericForegroundService. 2018-11-21 01:55:30 -08:00
Greyson Parrelli
a3411072ba Remove MasterSecret job.
It's no longer necessary.
2018-11-21 01:55:30 -08:00
Greyson Parrelli
776b0e23ae Add support for typing indicators. 2018-11-21 01:55:25 -08:00
Greyson Parrelli
3f25fb7d5f Handle voice note media playback with ExoPlayer.
There are several (popular) phone models out there that have bugs in
their MediaPlayer implementation that cause them to be unable to play
voice notes. By moving to ExoPlayer, an application-level media player,
we should avoid most of these headaches and stardardize playback.

Fixes #7748
2018-11-19 11:36:08 -08:00
Greyson Parrelli
053e6fc223 Bump version to 4.30.7 2018-11-17 10:00:55 -08:00
Greyson Parrelli
a2ea115650 Initialize jobs in the try block.
In the case where we add new fields to a Job's InputData, we want to
make sure that initialize() is called in the try block so that if it
fails, it simply fails the job (allowing the user to retry with the new
field) instead of crashing.
2018-11-17 09:56:52 -08:00
Greyson Parrelli
3f7e9cb46f Bump version to 4.30.6 2018-11-15 12:50:03 -08:00
Greyson Parrelli
cefe50e8a9 Updated language translations. 2018-11-15 12:49:56 -08:00
Greyson Parrelli
ff9d5df0e0 Dark theme support for emoji variation selector. 2018-11-15 11:43:38 -08:00
Greyson Parrelli
3716d69b0b Dismiss emoji variation popup when keyboard is dismissed.
Fixes #8372
2018-11-15 10:17:07 -08:00
Greyson Parrelli
d5be43cc85 Bump version to 4.30.5 2018-11-14 17:23:03 -08:00
Greyson Parrelli
481ff5c81e Updated language translations. 2018-11-14 17:21:43 -08:00
Greyson Parrelli
3e26060e99 Updated libsignal-service-java to 2.12.2 2018-11-14 16:25:16 -08:00
Greyson Parrelli
d93bfbf693 Prevent SendJobs from sending already-sent messages.
This is to guard against behavior WorkManager has where it may
re-enqueue a job that has already been completed (if, for instance, it
was preempted).

Fixes #8268
2018-11-14 16:20:55 -08:00
Greyson Parrelli
a7e15dc21e Removed unused asset. 2018-11-14 09:18:45 -08:00
Greyson Parrelli
bb566cb11f Bump version to 4.30.4 2018-11-13 20:04:25 -08:00
Greyson Parrelli
28081abe1c Split the 'people' emoji spritesheet into multiple chunks.
The aim of this is to help performance by breaking up the single massive
spritesheet into smaller ones. This will limit the amount of data that
needs to be kept in memory to render emoji.

(Hopefully) Fixes #8357
2018-11-13 19:29:51 -08:00
Greyson Parrelli
e7c00a3066 Fix issue where we may oversend SMS messages.
Because SMS sending is split over two jobs, there's no max retry limit
respected if we find out about the failure in SmsSentJob -- it's
requeued as a new job with a fresh attempt counter.

This commit carries a retry count between the two jobs. It also verifies
that we have service before attempting to send a message at all.

Relates to #8268
2018-11-13 15:07:33 -08:00
Greyson Parrelli
446585ad68 Fix emoji variation selector on older devices.
Weird platform-specific bug was preventing the display of the
PopupWindow.
2018-11-13 11:19:29 -08:00
Greyson Parrelli
4ebca9ddde Register RotateSenderCertificateListener in the manifest. 2018-11-13 10:35:02 -08:00
Greyson Parrelli
4c6655bd9a Bump version to 4.30.3 2018-11-09 12:37:27 -08:00
Greyson Parrelli
cbc7288242 Updated language translations. 2018-11-09 12:37:27 -08:00
Greyson Parrelli
78627ecb08 Updated libsignal-service-java to 2.12.1 2018-11-09 12:37:24 -08:00
Greyson Parrelli
bf9582c97e Only set UNRESTRICTED mode if recipients have a non-null verifier.
Otherwise we could send UD messages to people with non-UD linked
devices.
2018-11-06 09:58:45 -08:00
Greyson Parrelli
1ab3d57378 Fix some places where we were using the Android Logger.
We pretty much always want to be using our own logger.
2018-11-06 09:22:25 -08:00
Greyson Parrelli
b36d196873 Bump version to 4.30.2 2018-10-31 14:22:58 -07:00
Greyson Parrelli
e31029da89 Update recipient's sealed sender status in more places. 2018-10-31 11:18:35 -07:00
Yassine El Khadiri
787bcf7752 Fix backup MAC checking.
if(MessageDigest.isEqual(ourMac, theirMac) was always returning false
since ourMac was of length 32 and theirMac was of length 10.
2018-10-31 11:17:29 -07:00
Greyson Parrelli
8c3d50c6dc Ignore messages without content. 2018-10-31 08:26:45 -07:00
Greyson Parrelli
532431b0ad Guard against notifying for errors on non-existent SMS threads.
All of the other send jobs do this already, just didn't do it here.
2018-10-31 08:19:33 -07:00
Greyson Parrelli
cfeee25488 Use correct link for Sealed Sender blog post.
Fixes #8324
2018-10-30 14:12:34 -07:00
Moxie Marlinspike
608b7ef89a Bump version to 4.30.1 2018-10-30 09:21:31 -07:00
Moxie Marlinspike
4063ef39a4 Update release config 2018-10-30 09:20:54 -07:00
Greyson Parrelli
eeb2e2e3af Bump version to 4.30.0 2018-10-30 09:07:57 -07:00
Greyson Parrelli
2573900c30 Updated language translations. 2018-10-30 09:07:57 -07:00
Greyson Parrelli
2acab563d9 Support for sealed sender - Part 2 2018-10-30 08:48:08 -07:00
Moxie Marlinspike
5f31762220 Support for sealed sender - Part 1 2018-10-30 08:48:08 -07:00
Greyson Parrelli
b7b9554364 Prevent multiple instances of the same job running concurrently.
There are rare corner cases where a Job could be preempted by the
JobScheduler and then be rescheduled before the preempted job finished
running. This could create weird race conditions with bad consequences.

To fix this, we create a fun locking system that prevents two jobs with
the same UUID from running at the same time.
2018-10-30 08:48:07 -07:00
Greyson Parrelli
f15fb904bf Fix desktop double notification bug.
There were situations where we were posting two notifications for messages
when you had an 'active desktop'. This removes that.
2018-10-30 08:48:07 -07:00
Greyson Parrelli
86e4221182 Use a unique notification icon for backups. 2018-10-27 23:34:18 -07:00
Greyson Parrelli
dfe8b25dd7 Use a unique notification icon for the persistent background connection. 2018-10-27 23:32:28 -07:00
Greyson Parrelli
53050b3845 Fix issue with group avatar display.
Some legacy code was making the contact photo visible when it shouldn't
be.
2018-10-27 23:12:25 -07:00
Greyson Parrelli
6ce278114f Ensure profile photo in ConversationList is accurate.
Fixes #8270
2018-10-26 11:05:14 -07:00
Greyson Parrelli
48ff9673b9 Allow the selection of fitzpatrick emoji. 2018-10-26 11:05:10 -07:00
Greyson Parrelli
1999d09901 Updated emoji set.
Includes display support for more genders, and more notably, skin tones.
These are not currently selectable in the UI, but they will be rendered
properly when other clients send them.
2018-10-24 17:11:17 -07:00
Greyson Parrelli
f93a79ae37 Bump version to 4.29.7 2018-10-24 17:05:23 -07:00
Greyson Parrelli
fac56be499 Fix the build by listing google repo first.
Apparently jcenter() is lame and it broke our build. Listing the google
repo first fixes everything.
2018-10-24 16:57:19 -07:00
Greyson Parrelli
638012f3d0 Bump version to 4.29.6 2018-10-24 10:58:42 -07:00
Greyson Parrelli
bf452dfa92 Slightly shorten time before we show a foreground notification for pushes.
There's some ANRs, not many, that are likely caused by us riding the
5-second ANR timeout a little too closely. Giving us a little buffer to
see if that helps.
2018-10-24 10:58:06 -07:00
Greyson Parrelli
2b14c98eb0 Do not call bluetooth state listener after service is destroyed. 2018-10-24 10:43:08 -07:00
Greyson Parrelli
f164ac90db Disallow punctuation in icon initials. 2018-10-24 09:57:48 -07:00
Greyson Parrelli
14abbb1bbb Bump version to 4.29.5 2018-10-22 13:04:19 -07:00
Greyson Parrelli
91db26437d Fix camera scaling issues on some phones.
Some phones, notably the Pixel 3, had some problems with scaling after
taking photos. This fixes it by using the takePicture API instead of
pulling the bitmap from the TextureView.

Fixes #8292
2018-10-22 01:12:05 -07:00
Greyson Parrelli
76054a9e33 Ignore events after BluetoothStateManager is destroyed.
Fixes crash.
2018-10-21 13:03:28 -07:00
Greyson Parrelli
ae9c53bdf8 Ensure jobs have a Context during onAdded().
Fixes a crash.
2018-10-20 22:52:14 -07:00
Greyson Parrelli
0dd7b39bb1 Fix recipient prefrence display problem on Android P.
Android P's new ringtone selector is a whole new activity that can cause
RecipientPreferenceActivity to go through the full onCreate() flow after
the ringtone selection. This could cause a race between setting the
preference and reading the preference from the notification channel.
Just threw them on a serial executor to guarantee ordering.
2018-10-20 22:42:35 -07:00
Greyson Parrelli
4a0ea0c51c Handle contexts more consistently in RecipientPreferences.
Fixes a crash that was happening on the Pixel 3.
2018-10-20 22:22:07 -07:00
Greyson Parrelli
668e8dee5d Catch more camera exceptions.
Some devices will simply fail to open the camera with a runtime
exception. In this case, all we can do is catch it and report the error.
2018-10-19 15:57:34 -07:00
Greyson Parrelli
8ec3cf6a43 Bump version to 4.29.4 2018-10-18 09:52:47 -07:00
Greyson Parrelli
a287408a7a Only start the screen lock timeout when the app is backgrounded. 2018-10-18 09:40:32 -07:00
Greyson Parrelli
78124ef224 Bump version to 4.29.3 2018-10-17 14:01:44 -07:00
Greyson Parrelli
45e0bb281f Turn MessageRetrievalService into IncomingMessageObserver.
Due to an Android P bug, we basically need to stop calling
startService() in onResume()/onPause(). That means I had to turn
MessageRetrieval service into a singlton instead of a service. I also
moved the offending KeyCachingService calls into static methods that
didn't have to start the service.
2018-10-17 13:58:47 -07:00
Greyson Parrelli
7a6d863ff7 Bump version to 4.29.2 2018-10-16 22:55:35 -07:00
Greyson Parrelli
feb9e1d513 Post startService() in onPause() as a possible fix to an Android P bug.
We already did it for onResume(), and while it fixed the crash there,
the crash just moved to onPause(). Let's see if the same magic works.
2018-10-16 22:54:29 -07:00
Greyson Parrelli
1a5c1a4b42 Bump version to 4.29.1 2018-10-16 11:53:48 -07:00
Greyson Parrelli
e41ed92f49 Updated language translations. 2018-10-16 11:53:08 -07:00
Greyson Parrelli
7e485b8095 Post startService() in onResume() as a possible fix to an Android P bug.
Got confirmation that the crash we're seeing is a bug, and this might be
a possible workaround.
2018-10-16 11:47:58 -07:00
Greyson Parrelli
92773b1a12 Update delivery icon tint in conversation list. 2018-10-16 11:18:49 -07:00
Greyson Parrelli
7cadb0d35a Properly set the document download icon tint. 2018-10-16 10:58:19 -07:00
Greyson Parrelli
e1f572e1f4 Update GCM foreground notification icon.
Using the default Signal icon can confuse people into thinking they're
message notifications.
2018-10-15 16:56:24 -07:00
Greyson Parrelli
ead323c1af Don't unnecessarily stack GCM message processing.
If we already have two active processing GCM messages, there's no
benefit to a third. In fact, enqueuing additional ones will likely only
end up showing the foreground notification unnecessariliy.
2018-10-15 10:37:30 -07:00
Greyson Parrelli
20c059280c Refactor OrderEnforcer. 2018-10-12 09:30:01 -07:00
Greyson Parrelli
50eb8f2322 Bump version to 4.29.0 2018-10-11 11:30:18 -07:00
Greyson Parrelli
15f418f2cc Updated language translations. 2018-10-11 11:30:06 -07:00
Greyson Parrelli
b133546ca6 Bump targetSdkVersion to 26. 2018-10-11 09:55:46 -07:00
Greyson Parrelli
5219d79e27 Remove unnecessary start of KeyCachingService. 2018-10-11 09:55:46 -07:00
Greyson Parrelli
89f97f57cb Update our boot receiver to schedule a message pull.
Previously we were starting a background service, which isn't allowed
for targetSdk 26. This will do the same thing but at a time decided by
the system.
2018-10-11 09:55:46 -07:00
Greyson Parrelli
4c63428b71 Ensure GenericForegroundService is started with startForegroundService.
If we don't, we run the risk of the app crashing if the service is
started in the background.
2018-10-11 09:55:46 -07:00
Greyson Parrelli
704715de8f Fix message details delivery status icon tint (again). 2018-10-11 09:55:33 -07:00
Greyson Parrelli
0d48f10806 Fix issue where a Job had null JobParameters. 2018-10-10 09:00:14 -07:00
Greyson Parrelli
275ca9e3ba Remove the ability to set a color for a group.
No longer applicable given that we're adding back per-person colors in
groups.
2018-10-09 15:34:08 -07:00
Greyson Parrelli
710fa4a6f0 Switch the conversation color back to incoming messages. 2018-10-09 15:34:04 -07:00
Greyson Parrelli
b1d653a230 Bump version to 4.28.1 2018-10-08 10:20:47 -07:00
Greyson Parrelli
1b736e9e04 Ensure notifications are processed after receiving GCM message.
It's unreliable to run these tasks on WorkManager, as there's no
scheduling guarantees.
2018-10-08 10:00:15 -07:00
Greyson Parrelli
1c197ad93d Reset attachment transfer state if auto-download requirements are not met. 2018-10-07 14:21:33 -07:00
Greyson Parrelli
a1ba5003d3 Fix some dark theme color consistency issues.
Fixes #8253
2018-10-05 17:21:26 -07:00
Greyson Parrelli
f26c6f890f Fix non-contact icon in recipient preferences being too small.
Relates to #8252
2018-10-04 11:35:19 -07:00
Greyson Parrelli
eb11d5ceda Make avatar color in toolbar match conversation color.
Relates to #8252
2018-10-04 11:27:12 -07:00
Greyson Parrelli
43ebcfdee5 Added more contrast to shared contact button color in dark theme.
Relates to #8252
2018-10-04 11:12:49 -07:00
Greyson Parrelli
d9272c3b33 Fix message details delivery status icon tint.
Fixes #8251
2018-10-04 11:01:46 -07:00
Greyson Parrelli
1d7f7b6c38 Do not auto-assign Steel as a color for contacts/groups.
Should be reserved for non-contacts, but selectable in the color picker.

Fixes #8247
2018-10-04 09:22:24 -07:00
Greyson Parrelli
07d7af6e75 Initialize WorkManager ourself.
This gives us more control over when it happens, as well as lets us set
things like the debug level. Also let's us get rid of the synchronized
block we had in Application#onCreate().
2018-10-04 09:09:04 -07:00
Greyson Parrelli
4da1af9a7b Use the correct save icon in the ScribbleHud. 2018-10-03 18:13:21 -07:00
Greyson Parrelli
0840175d6f Remove shutter sound on camera capture.
This sound isn't supposed to play when you have notification sound off,
but apparently some Huawei phones will play it anyway. Until we can
figure out a better way to handle it, we're just removing it.
2018-10-03 18:11:50 -07:00
Greyson Parrelli
b6e40ea812 Bump version to 4.28.0 2018-10-03 15:33:00 -07:00
Greyson Parrelli
c81bc22943 Fix avatar location in a group conversation. 2018-10-03 14:25:23 -07:00
Greyson Parrelli
547b7a3c6f Migrate legacy color palette.
We don't store non-user-selected colors in the database. That means that
when we update the palette, we still have to hash based off of the legacy
palette when generating a color if we want to migrate to a
similar-looking color.

Unfortunately, because the new palette is smaller, some colors are
"overloaded", meaning that when we hash based off of the legacy palette,
some colors will be more/less common than others. To fix this, we simply
persist all current colors in the database, then switch our hashing list
to what we really want.
2018-10-03 14:25:17 -07:00
Greyson Parrelli
5eec3c9541 Add hairline border to avatars. 2018-10-03 14:24:00 -07:00
Greyson Parrelli
f725dd5a7e Show profile avatar in toolbar. 2018-10-03 14:24:00 -07:00
Greyson Parrelli
a3cba66450 Update fallback avatars. 2018-10-03 14:24:00 -07:00
Greyson Parrelli
bab92fca7b Move unread indicator to be above the avatar. 2018-10-03 14:23:59 -07:00
Greyson Parrelli
c37c1dffd4 Allow setting the color for a group. 2018-10-03 14:23:59 -07:00
Greyson Parrelli
127505af0b Implement new color palette. 2018-10-03 14:23:59 -07:00
Greyson Parrelli
cfd20d23e8 Fix double onClick() notifications in preferences.
Fixes #8241
2018-10-03 11:31:07 -07:00
Greyson Parrelli
e4b56d4e40 Show foreground notification for jobs when network is restricted.
Occasionally a job may be run when the app is in a network-restricted
mode, like a form of doze. When this happens, jobs can timeout due to
lack of network access, causing a cascade of job delays. This is
particularly bad in the case of message retrieval.

To prevent this, if a job that normally requires network detects that no
network is available when running, then we start a foreground
notification.
2018-10-03 10:00:42 -07:00
Greyson Parrelli
c86c2c51bb Bump version to 4.27.3 2018-10-02 12:53:29 -07:00
Greyson Parrelli
5a623810cb Broaden exception handling around Camera#startPreview().
Some devices will randomly throw RuntimeExceptions here due to hardware
issues. We were already doing broader catch statement in CameraView, so
I moved it here as well.
2018-10-02 12:47:07 -07:00
Greyson Parrelli
444e01deae Improve key presence checking in SafeData.
This isn't a perfect check either, but it should be safer and more
consistent than using static "invalid values".
2018-10-02 12:31:12 -07:00
Greyson Parrelli
d25ebdc818 Fix indentation in preference fragments.
Unfortunately, while there does exist an XML property to disable the
indentation, it's bugged for category headings, so we have to do this
silly thing where we strip the padding in the adapter. Hopefully they'll
fix the bug and we can move to use the sanctioned property.

See: https://issuetracker.google.com/issues/111662669

Fixes #8233
2018-10-02 12:08:01 -07:00
Greyson Parrelli
24e82abf80 Don't report contact discovery accuracy if it encountered an error.
Otherwise we're double-reporting. Also made the sanitize method more
accurate.
2018-10-02 09:16:37 -07:00
Greyson Parrelli
cfa13867e5 Allow null for profileAvatar in RetrieveProfileAvatarJob. 2018-10-02 08:43:18 -07:00
Greyson Parrelli
34770a2333 Fixed Camera capture crash on API <= 19.
On older versions of Android, TextureView#getBitmap() needs to be called
on the main thread. On mid range phones, this is ~50ms. Normally that'd
be bad, but the UI isn't doing anything at that point anyway.

Fixes #8232
2018-10-01 23:53:33 -07:00
Greyson Parrelli
2c5fa155ae Fix re-enabling tab switching in MediaOverview.
We were being inconsistent in how we were handling exiting multiselect,
and it wasn't behaving properly when you left by clicking the 'x'. Now
it's all handled centrally.

Fixes #8234
2018-10-01 23:38:07 -07:00
Greyson Parrelli
bc6941589c Bump version to 4.27.2 2018-10-01 16:15:16 -07:00
Greyson Parrelli
12afdad291 Log Job retryable exceptions. 2018-10-01 16:14:45 -07:00
Greyson Parrelli
4799d30077 Update the Dockerfile.
We updated our build tools and stuff, so we have to update the
Dockerfile. Took this opportunity to also update the version of
Ubuntu we were using as the base.
2018-10-01 16:12:10 -07:00
Greyson Parrelli
fafad0d555 Fix the command line build. 2018-10-01 15:39:05 -07:00
Greyson Parrelli
3f4133b163 Bump version to 4.27.1 2018-10-01 12:49:41 -07:00
Greyson Parrelli
68746bcecb Move targetSdk back to 25.
It was accidentally bumped to 26.
2018-10-01 12:47:47 -07:00
Greyson Parrelli
0fbb4ac333 Bump version to 4.27.0 2018-10-01 12:39:14 -07:00
Greyson Parrelli
f2e4f626c1 Updated language translations. 2018-10-01 12:38:57 -07:00
Greyson Parrelli
2f530dc970 Remove CameraView usage of JobManager.
WorkManager flat-out can't handle anonymous implementations of Worker
classes due to it using reflection to instantiate them.
2018-10-01 12:12:50 -07:00
Greyson Parrelli
87e6aa48bb Schedule jobs with WorkManager.
Should help solve most of our pressing targetSdk=26 migration issues.
2018-10-01 12:12:50 -07:00
Greyson Parrelli
d10a44f8eb Suppress some noisy logs. 2018-10-01 12:12:50 -07:00
Greyson Parrelli
6359961a82 Ensure numbers are properly formatted before giving them to contact discovery service.
We were sending "Unknown" addresses, which would cause the service to
choke.
2018-10-01 12:12:12 -07:00
Greyson Parrelli
946f76a442 Fix layout problems in conversation item footer. 2018-09-27 12:25:30 -07:00
Greyson Parrelli
616912d85f Prefer local state in dial click listener. 2018-09-27 11:45:56 -07:00
Greyson Parrelli
bd38b96095 Long-press timestamps in message details to copy. 2018-09-27 11:34:43 -07:00
Greyson Parrelli
12d9d7741b Clean up batch saving.
- Post a better string for when batch saving completes successfully
- Exit multi-select after saving
2018-09-27 10:35:56 -07:00
FeuRenard
91a119393c Allow batch saving in media overview 2018-09-27 10:35:56 -07:00
FeuRenard
c82afd8944 Allow selecting all media in overview 2018-09-27 10:35:56 -07:00
Greyson Parrelli
84c71fce16 Disable tab switching in media overview during multiselect.
Multiselect only applies to items in the "media" tab, so people
shouldn't be able to switch tabs during multiselect.
2018-09-27 10:35:56 -07:00
Greyson Parrelli
a0ab252bc9 Add preliminary contact discovery service support. 2018-09-27 10:35:56 -07:00
Greyson Parrelli
08ace15f95 Implemented new camera capture flow.
A new, fullscreen camera capture flow that easily allows you to capture
and edit a photo before sending it. Replaces the current half-screen
camera button.
2018-09-27 10:35:56 -07:00
Greyson Parrelli
e9a38bab1e Turned SingleUseBlobProvider into MemoryBlobProvider.
Keep the single-use behavior, but allow the creation of multi-use memory
blobs that can be deleted when we're done with them. Will help out with
having URI's for temporary images during the camera capture flow.
2018-09-27 10:35:56 -07:00
Greyson Parrelli
e63773e5c8 Added OrderEnforcer class to schedule ordered tasks. 2018-09-27 10:35:56 -07:00
Greyson Parrelli
bcebf58b76 Added a new Stopwatch class to easily log timings. 2018-09-27 10:35:56 -07:00
Unknown
2209e68ae0 Changed URL of the user forum. 2018-09-27 10:29:30 -07:00
Greyson Parrelli
6a0b89feaa Bump version to 4.26.2 2018-09-25 10:01:39 -07:00
Greyson Parrelli
6eb8693546 Don't block messages from unknown groups.
We were incorrectly considering unknown groups to have been "left".
2018-09-25 10:00:14 -07:00
Greyson Parrelli
c5f53b23fa Bump version to 4.26.1 2018-09-19 16:47:33 -07:00
Greyson Parrelli
11127c0d97 Clear external cache upon upgrade. 2018-09-19 16:41:51 -07:00
Greyson Parrelli
1af930437a Bump version to 4.26.0 2018-09-18 17:44:18 -07:00
Greyson Parrelli
94bfebeef1 Updated language translations. 2018-09-18 17:43:29 -07:00
Greyson Parrelli
45c4eafbd7 Add the ability to block groups.
This also fixes the situation where we block group-leave messages,
preventing blocked contacts from leaving groups.

Fixes #7970

Also, this forced us to upgrade libsignal-service, which fixes the
websocket timeout issues. Thanks to @dpapavas!

Fixes #6644
2018-09-18 15:26:50 -07:00
Greyson Parrelli
741b775d3e Ensure external camera blob is deleted. 2018-09-17 20:29:21 -07:00
Greyson Parrelli
e09c99102e Clear Glide disk cache after image deletion. 2018-09-17 19:17:36 -07:00
Greyson Parrelli
1d4020ffc6 Disable forwarding for shared contacts.
Forwarding of shared contacts currently just creates an empty draft.
You can't preview a shared contact before you send, which would make the
forwarding flow inconsistent across media types. So it's easier to just
hide it for now.

Fixes #8195
2018-09-16 22:50:59 -07:00
Greyson Parrelli
5d11e321a8 Fix setting global notification sound to 'None'.
Fixes #8206
2018-09-16 22:29:55 -07:00
Greyson Parrelli
9dd3e50ebd Don't set subscriptionId for quick-reply push messages.
This could cause us to think push messages were actually sent with
a SIM. We also now prevent rendering SIM info on push messages in
the conversation view.

Fixes #8176
2018-09-08 10:08:22 -07:00
Greyson Parrelli
ad7dd7584e Fixed document display in media overview in dark theme.
Shoutout to @aleb2000 for working on this as well!

Fixes #8151
2018-09-08 08:23:33 -07:00
Greyson Parrelli
c1a827f6d4 Update WebRTC to M69. 2018-09-08 07:48:20 -07:00
Greyson Parrelli
440ad70d79 Allow submitting a debug log during registration. 2018-09-08 07:48:20 -07:00
Greyson Parrelli
a1b2887bf3 Fixed off-by-one crash when navigating to message from FTS.
Related to #8145
2018-09-08 07:48:20 -07:00
Greyson Parrelli
da60cac833 Fix PersistentBlobProvider problems with external storage.
If the user has an external SD card set as their default storage
(notably on a Huawei device, like the Huawei Mate 10 Lite), then
PersistentBlobProvider will try to write a file to the SD card, but
would fail to generate a URI for it due to us missing a line in our
FileProvider setup. This just adds that missing entry.

Special thanks to @aleb2000 for digging into this!

Fixes #8144
Fixes #7726
2018-09-08 07:48:20 -07:00
Greyson Parrelli
db9bfb4b2f Update ExoPlayer to 2.8.4 2018-09-08 07:48:20 -07:00
Greyson Parrelli
c3bdc48ee3 Create placeholder ContentProviders for database observations.
Required for the API 26 migration.

See https://developer.android.com/about/versions/oreo/android-8.0-changes#ccn
2018-09-08 07:48:20 -07:00
Greyson Parrelli
1c75f375c3 Bump version to 4.25.10 2018-09-07 17:59:33 -07:00
Greyson Parrelli
7c5e1db6a2 Fix NPE in MultiDeviceContactUpdateJob.
Fixes #8180
2018-09-07 17:52:50 -07:00
Greyson Parrelli
82c0ea792a Fix animation crash.
Shoutout to @bomba1990 for fixing this around the same time as me :)

Fixes #8182
2018-09-07 17:52:50 -07:00
Greyson Parrelli
70eecb754e Address bugs in notification channel backup restore. 2018-09-07 17:49:15 -07:00
Greyson Parrelli
ad036b0d6a Fix backup restore issues from restoring newer Signal backups.
Fixes #8184
2018-09-07 16:08:45 -07:00
Greyson Parrelli
15b4517e35 Prevent restoring newer backups into older versions of Signal.
Relates to #8184
2018-09-07 15:54:38 -07:00
Greyson Parrelli
d2a8abe769 Bump version to 4.25.9 2018-09-04 18:12:13 -07:00
Greyson Parrelli
8d43fb850d Make group notifications use the latest sender's ringtone. 2018-09-04 18:10:47 -07:00
Greyson Parrelli
11d34512a0 Fix double notifications in O+. 2018-09-04 18:10:42 -07:00
Greyson Parrelli
604e5d788e Bump version to 4.25.8 2018-09-04 11:13:54 -07:00
Greyson Parrelli
73b18fc1dd Fix NotificationChannel backup import.
We were recreating the channels before the database upgrade. We
have to do it after.

Fixes #8174
2018-09-04 10:57:33 -07:00
Greyson Parrelli
d9ba6962c7 Fixed NPE during channel update. 2018-09-03 17:48:55 -07:00
Greyson Parrelli
5cc91274d1 Bump version to 4.25.7 2018-08-31 12:01:46 -07:00
Greyson Parrelli
3da1a3e270 Restore notification channels after backup. 2018-08-31 12:00:46 -07:00
Greyson Parrelli
e840dc6687 Move notification preferences back in-app for O+.
Fixes #8147
2018-08-31 11:10:54 -07:00
Greyson Parrelli
3f9ddaf409 Update the Android Transifex links in CONTRIBUTING.md. 2018-08-30 08:21:55 -07:00
Joshua Lund
005188735a Update the Transifex links in CONTRIBUTING.md. 2018-08-30 08:18:34 -07:00
Greyson Parrelli
a6e4114151 Bump version to 4.25.6 2018-08-27 10:31:21 -07:00
Greyson Parrelli
5d91a94252 Fix shortcut images being too large.
We were hitting the transaction limit size. This change scales down
shortcut icons to be at most 300x300, which comes out to ~360kb, which
should be safely under the limit of 1mb.

Fixes #8139
2018-08-25 10:40:58 -07:00
Greyson Parrelli
25db207e24 Bump version to 4.25.5 2018-08-24 12:13:39 -07:00
Greyson Parrelli
ab58eab9f4 Fix potential crash with recipient preferences. 2018-08-24 12:00:02 -07:00
Greyson Parrelli
96c39ec100 Updated language translations. 2018-08-24 11:53:40 -07:00
Greyson Parrelli
c5309ce11e Bump version to 4.25.4 2018-08-22 16:30:54 -07:00
Greyson Parrelli
cedab7f504 Fix migration of group names when creating Notification Channels. 2018-08-22 14:19:37 -07:00
Greyson Parrelli
ca2efcac8a Added safeguards during NotificationChannel creation.
We were getting an IllegalArgumentException during channel creation on
some Samsung phones. Stack trace didn't give me much more than that, so
just adding in some additional safeguards that make sense based on
reading AOSP.
2018-08-22 13:19:59 -07:00
Greyson Parrelli
f1efe2b589 Use correct in-thread message tone on O+.
We manually play the ringtone when in-thread notifications are enabled,
but we weren't using the sound specified by the channel in the system
settings. This fixes that problem by reading the NotificationChannel
setting.
2018-08-22 11:58:41 -07:00
Greyson Parrelli
54715e9c43 Bump version to 4.25.3 2018-08-21 11:16:48 -07:00
Greyson Parrelli
e1f8e87327 Fix log submission OOM, improve log scrolling.
We were getting a TransactionTooLargeException when giving an
EditText a very large (1.5MB+) text block. This has been resolved
by switching to a RecyclerView to show the text line-by-line. As a
side-effect, this improves scroll performance on lower-end devices.

Also, I added a button to jump to the bottom of the log because I
really wanted one :)

Fixes #8124
2018-08-20 01:24:36 -07:00
Greyson Parrelli
88d94cad92 Substantially improve Scrubber performance.
Previously, we were making a new copy of the entire source string after
every scrubbed substitution. In the case of our new, larger log files,
this was very slow. It's been changed so we only ever create one new
copy.

In practice, on a Moto E (2014), scrubbing a 1.5MB log went from
>4000ms to ~100ms.
2018-08-19 23:19:08 -07:00
Greyson Parrelli
7370bbacea Fix inline animation toggle initial transition.
Fixes #8116
2018-08-17 16:07:13 -07:00
Greyson Parrelli
e9b85a10a6 Add per-contact notification channels.
Fixes #8119
Fixes #8121
Fixes #8122
2018-08-17 15:51:01 -07:00
Greyson Parrelli
e23fd9d491 Bump version to 4.25.2 2018-08-15 13:41:02 -07:00
Greyson Parrelli
c49b0348bd Add failsafe for invalid shortcuts.
Some launchers may create broken shortcuts, so we just want to have
a smooth fallback in that scenario.

Fixes #8109
2018-08-15 12:48:04 -07:00
Greyson Parrelli
3c6b8bcf9b Hide inline attachment button when attachment present. 2018-08-15 12:35:41 -07:00
Greyson Parrelli
a6473bc922 Link priority setting to message channel setting on Oreo+
When using notification channels, us setting priority actually has
no effect. So instead of having a non-functional setting, we've
routed the notification priority setting to go to the system
notification channel settings page for our Messages channel.
2018-08-15 12:11:10 -07:00
Greyson Parrelli
10a790df88 Fix notifications triggering too often. 2018-08-14 20:19:25 -07:00
Greyson Parrelli
b79748bbb1 Change lock status channel name to 'lock status'. 2018-08-14 16:59:21 -07:00
Greyson Parrelli
7eeafee1c2 Bump version to 4.25.1 2018-08-14 13:28:00 -07:00
Greyson Parrelli
eabaead700 Revert "Fingerprint unlock UX improvements"
This reverts commit 8441ac4091.

Fixes #8106
2018-08-14 13:04:33 -07:00
Greyson Parrelli
d581525a61 Fix Log secret reading.
Accidentally typed '>' instead of '>='.

Fixes #8107
2018-08-14 15:09:24 -04:00
Greyson Parrelli
f9adb4e455 Bump version to 4.25.0 2018-08-13 18:38:59 -04:00
Greyson Parrelli
d79564021f Remove extra space below notification text.
Special thanks to @dwong

Fixes #7905
2018-08-13 18:38:59 -04:00
Greyson Parrelli
2acbea014b Fix videos losing their extension after forwarding.
Special thanks to @signalien

Fixes #7783
2018-08-13 18:38:59 -04:00
Greyson Parrelli
2882ef6d9f Reset register button status after an error.
Fixes #8052
2018-08-13 18:38:59 -04:00
art1fa
8441ac4091 Fingerprint unlock UX improvements 2018-08-13 18:38:59 -04:00
Greyson Parrelli
20c896413b Stop linkifying addresses.
Address linkification on Android is pretty busted, and the docs
acknowledge it (see Linkify#MAP_ADDRESSES). Safest thing to do
at the moment is remove it. Looks like we may be able to get
better address linkification on API >= 28, but adding it will
be more involved.

Fixes #7730
2018-08-13 18:38:59 -04:00
Greyson Parrelli
13c72779af Visually note quotes for messages you don't have.
We will now show a small footer under quotes for messages that you
don't have locally.

Also fixes #7850
2018-08-13 18:38:59 -04:00
Greyson Parrelli
4d565990c9 Add drop shadow under attachment drawer. 2018-08-13 18:38:59 -04:00
Greyson Parrelli
5cdf5499d0 Clean up shortcut code. 2018-08-13 18:38:59 -04:00
Leonard Ehrenfried
c3c44e324b Allow users to add conversation shortcuts to the home screen. 2018-08-13 18:38:59 -04:00
Greyson Parrelli
c7da83a702 Show attachment button while composing text.
Previously, we'd only show the attachment button when the user had
yet to enter any text. To add an attachment after text was entered,
you'd have to go to the three-dot menu. Now we just show a little
attach button in the text area.

I also took the opportunity to clean up other button paddings and
stuff in the compose area so things look better and react to text
sizes more predictably.
2018-08-13 18:38:59 -04:00
Greyson Parrelli
dbd42c4af2 Add notification channel support.
Bucket our notifications into channels. Required to target API 26.
2018-08-13 18:38:53 -04:00
Greyson Parrelli
d0db6aa509 Added more logging around message sending and attachment downloads. 2018-08-06 10:50:06 -04:00
Greyson Parrelli
43068e0613 Reduce usage of Log.w() 2018-08-06 10:50:06 -04:00
Greyson Parrelli
a498176043 Switch logs to use new Log class. 2018-08-06 10:50:06 -04:00
Greyson Parrelli
acb40c6133 Added new logger.
Added a new logger that persists logs for a longer duration to the
user's cache directory. Logs are encrypted. The new logs are sent
in addition to the user's logcat output.
2018-08-06 10:50:06 -04:00
Greyson Parrelli
b7d83c7a1f Make libpaste a source dependency. 2018-08-06 10:50:06 -04:00
Greyson Parrelli
1028da116f Bump version to 4.24.8 2018-08-06 10:47:44 -04:00
Greyson Parrelli
c8571d7bc7 Use correct timestamp for footer collapse.
Fixes #8071
2018-08-06 10:34:02 -04:00
Greyson Parrelli
f6951b9ae0 Bump version to 4.24.7 2018-08-03 14:09:50 -04:00
Greyson Parrelli
d42cecc32a Fix timer issue with sync messages from desktop.
Related to #8068
2018-08-03 14:08:16 -04:00
Greyson Parrelli
7d210c8e0d Bump version to 4.24.6 2018-08-02 17:15:18 -04:00
Greyson Parrelli
c5014f9471 Fix quote crash when we decode an image of 0 length.
Fixes #7983
2018-08-02 15:57:30 -04:00
Greyson Parrelli
6db3f249c6 Populate contact name when adding shared contact.
Fixes #8016
2018-08-02 15:16:51 -04:00
Greyson Parrelli
5a1ef31b49 Fix crash with moveToLastSeen() 2018-08-02 11:57:10 -04:00
Greyson Parrelli
8ca11756be Bump version to 4.24.5 2018-07-27 16:32:46 -04:00
Greyson Parrelli
76428bd19b Fix issue with author names getting cut off. 2018-07-27 16:31:39 -04:00
art1fa
faea8fd2ec Apply message bubble paddings to both top and bottom
Batch selecting messages now feels better. Fixes #8035.
2018-07-27 16:15:37 -04:00
Greyson Parrelli
79830049c4 Fix emoji vertical positioning.
Fixes #8023
2018-07-27 16:01:52 -04:00
Greyson Parrelli
1e895e960f Fix various padding and alignment issues. 2018-07-27 14:00:11 -04:00
Greyson Parrelli
a3115c14ac Use proper target for Glide bitmap requests.
Fixes #8042
2018-07-27 09:12:54 -04:00
Greyson Parrelli
c33363d0bd Bump version to 4.24.4 2018-07-26 12:58:25 -04:00
Greyson Parrelli
44856ca8cd Updated language translations. 2018-07-26 12:40:48 -04:00
Greyson Parrelli
67190774cc Jump to the oldest unread message after loading a draft. 2018-07-25 13:10:35 -04:00
Greyson Parrelli
d5a9efa96a Reduce letter spacing on Preview text. 2018-07-25 09:58:43 -04:00
Greyson Parrelli
d5753bc306 Fix spacing issue between short clustered group chats.
For short messages in a cluster, the contact photo was sometimes taller
than the actual bubble, leading to extra weird space. So instead we use
a container to hold the width of the cell, and set the avatar to be GONE
instead of INVISIBLE.
2018-07-25 01:16:48 -04:00
Greyson Parrelli
e96a02ab35 Fix next/prev message detection with fastRecords.
The previous way we were getting the next/previous record didn't take into
consideration that some records aren't in the cursor -- some are in the
fastRecords map. We now use the proper position to get the next/previous
message.
2018-07-25 00:24:49 -04:00
Greyson Parrelli
ec43c3ae5a Bump version to 4.24.3 2018-07-24 20:47:43 -04:00
Christian Ascheberg
0bb44f2034 Improve disappearing message time strings
Fixes #7501
2018-07-24 20:35:51 -04:00
Moxie Marlinspike
fbd3f3db3f Update webrtc to M68 2018-07-24 17:06:43 -07:00
Greyson Parrelli
d82e91ca20 Fix message button in conversation settings.
Switching to use our convenience methods for start texts and calls.

Fixes #8026
2018-07-24 17:15:03 -04:00
Greyson Parrelli
c7fb1d79c4 Properly show group message header after a date divider. 2018-07-24 16:33:45 -04:00
Greyson Parrelli
0ced767ef2 Use person's name in call update text. 2018-07-24 16:33:05 -04:00
Greyson Parrelli
39b27a9d7a Properly map hashed legacy colors to the new color palette.
Fixes #8021
2018-07-24 12:53:36 -04:00
Greyson Parrelli
6a1fd8b1c6 Increase difference between read/unread conversations in list.
Updating to match the design.
2018-07-24 12:34:21 -04:00
Greyson Parrelli
d8ddb142a9 Fixed bug in onMeasure() overflow safeguard.
Fixes #8008
2018-07-23 07:54:24 -07:00
Greyson Parrelli
fbbf9dede8 Bump version to 4.24.2 2018-07-20 19:05:13 -07:00
Greyson Parrelli
214658b99e Fix recording not resetting properly after a send on older API's.
Apparently onAnimationEnd is not a reliable event on some Android
versions, so I've moved to instead using a simple postDelayed() that is
the same length as the animation.
2018-07-20 19:02:19 -07:00
Greyson Parrelli
415fe3463d Don't collapse outgoing footers for pending or failed messages. 2018-07-20 18:45:18 -07:00
Greyson Parrelli
6234e56e78 Allow outgoing messages to collapse footers. 2018-07-20 18:35:04 -07:00
Greyson Parrelli
f82b2c0d3f Prevent author name from making media messages too wide.
The media size traditionally determines the bubble size, but the author
could make it wider, which would lead to rendering issues. In the case
of media attachments (images, videos, and shared contacts), we restrict
the width of the author name. When there's a number+profile name combo,
we split the space 50/50 between the two.
2018-07-20 18:24:52 -07:00
Greyson Parrelli
a4214300ec Fix crash with conversations with "uknown contact" header.
We weren't accounting for ConversationAdapter header position when
getting the next and previous record in a conversation.
2018-07-20 17:50:54 -07:00
Greyson Parrelli
6a090bd5f1 Some visual tweak fixes.
- Use correct color action bar in contact name edit activity.
- Fix compose text height to match send button height.
2018-07-20 16:37:34 -07:00
Greyson Parrelli
c9bb3dd469 Remove now-unnecessary thumbnail onMeasure(). 2018-07-20 16:16:19 -07:00
Greyson Parrelli
6fd10042fb Move expiration timer to be next to the date. 2018-07-20 16:05:14 -07:00
Greyson Parrelli
aa25f39fe9 Fix footer icon tints. 2018-07-20 15:40:13 -07:00
Greyson Parrelli
860047c2d3 Remove CornerMaskingView. 2018-07-20 14:24:04 -07:00
Greyson Parrelli
d0eaee60e9 Add additional safeguards for picking an expiration timer frame.
Fixes #8010
2018-07-20 14:08:58 -07:00
Greyson Parrelli
d303a88803 Fix quote dismiss button not showing up.
Fixes #8006
2018-07-20 14:03:03 -07:00
Greyson Parrelli
f4ef586681 Bump version to 4.24.1 2018-07-18 16:54:49 -07:00
Greyson Parrelli
8f551c8b32 Fix various redesign issues with Android 4.x.
In particular, there were many issues with drawing corners.
Unfortunately, there's no pretty way to get masking working on every
Android version, so we have to switch back to using custom backgrounds
and then using multiple masking methods depending on Android version.

Also, I had to remove attr references in drawables. They crash on 4.x.
2018-07-18 16:53:36 -07:00
Greyson Parrelli
d3e194aefe Bump version to 4.24.0 2018-07-18 09:40:20 -07:00
Jonathan Fung
85d963047e Adding a long press icon description for the Search icon
Fixes #7836
2018-07-18 09:04:42 -07:00
floesche
df9833472f Add z5 compact (E5823) to AEC blacklist
Following fixes for other models to reduce echo on callee side during Signal call. 

The problem has been reported for this model for example in #6241
2018-07-18 08:53:27 -07:00
Greyson Parrelli
99f7133afe Updated language translations. 2018-07-18 08:34:21 -07:00
Greyson Parrelli
1c023b5218 Remove unused resources. 2018-07-17 12:06:50 -07:00
Greyson Parrelli
bf692e8da3 Throttle background contact syncs to once every 6 hours.
Unfortunately, there's apps out there that trigger contact changes
very frequently. Because we listen to the system for contact
changes to tell us when to sync, that could result in us sending
an abundance of contact syncs to linked desktop instances.

This throttles contact sync requests using the following methodology:

- By default, throttle contact syncs to 6 hrs while the app is
  backgrounded.
- If a sync is throttled in the background, we set a dirty flag and
  will execute the sync the next time the app is foregrounded.
- Syncs explicitly requested by desktop are never throttled.
2018-07-17 12:06:50 -07:00
RiseT
7960a5785d Export some strings from shared contact details activity 2018-07-17 12:06:50 -07:00
Greyson Parrelli
8579c30909 Styling improvements and code cleanup. 2018-07-17 12:06:42 -07:00
Greyson Parrelli
845fcf0864 Remove ability to set group conversation colors (for now). 2018-07-17 09:54:13 -07:00
Greyson Parrelli
24b062d8dd Improve the look of message bubbles. 2018-07-17 09:53:52 -07:00
Greyson Parrelli
7cfcb62c25 Added colors and styles. 2018-07-12 10:59:29 -07:00
Greyson Parrelli
b02dda405c Use NetworkBackoffRequirement for group messages. 2018-07-12 10:59:10 -07:00
Moxie Marlinspike
bc60cba2b8 Fix default SMS app intent >= N
Fixes #7964
2018-07-10 10:14:35 -07:00
Greyson Parrelli
4df1743ed1 Bump version to 4.23.4 2018-07-09 14:57:43 -07:00
Greyson Parrelli
e3bf91b99b Get rid of old references to @drawable/icon.
Fixes #7957
2018-07-09 14:56:31 -07:00
Greyson Parrelli
d06b129156 Bump version to 4.23.3 2018-07-06 09:54:15 -07:00
Greyson Parrelli
f074c7e5b7 Fixed FAB sometimes blocking shared contact toggle.
Fixes #7968
2018-07-06 09:52:28 -07:00
Greyson Parrelli
e334f1e035 Bump verison to 4.23.2 2018-07-05 10:08:40 -07:00
Greyson Parrelli
84e2fcad54 Update UI of toggling shared contact photo. 2018-07-05 10:05:54 -07:00
Greyson Parrelli
42236d6c3d Bump version to 4.23.1 2018-07-03 17:18:23 -07:00
Greyson Parrelli
6ce8516b93 Make contact photos optional when sharing contacts.
Previously, if you had a contact photo for a user, we'd always send it
Now you can choose whether or not it is sent.
2018-07-03 17:16:50 -07:00
Greyson Parrelli
7237e919be Bump version to 4.23.0 2018-07-02 18:22:22 -07:00
Greyson Parrelli
67407ec667 Hard-code migration for full-text search. 2018-07-02 18:10:11 -07:00
Ryan Koesters
8be0fd0867 Remove reference to Pixelapse in BUILDING.md.
Pixelapse ceased functioning in November 2016.
2018-07-02 17:58:26 -07:00
RiseT
e75822c6fd Remove unused strings
- Removed unused strings
- Removed some obsolete header comments
- Removed some whitespace
2018-07-02 17:56:07 -07:00
RiseT
6a465e6589 Update locales per 2018-06-23
Translation completion >= 90%, with the exception of Irish (80%), but they've been waiting for a rather long time.

Added:
- Irish
- Kurdish
- Telugu
- Ukrainian
2018-07-02 17:49:29 -07:00
b0m0x
2290549349 add Mi A1 to hardware AEC blacklist
See #7635
2018-07-02 17:45:55 -07:00
Greyson Parrelli
bf07048d7b Use earlier read timestamp when syncing read status with desktop.
Previously, we'd always use the value desktop gave us. However, if we
have an earlier read time locally, we want to use that instead.
2018-07-02 17:39:10 -07:00
Greyson Parrelli
3134837d56 Remove plaintext backup import option.
We have our own secure backup solution built into the app now.
No need to support plaintext backups.
2018-07-02 17:11:13 -07:00
Greyson Parrelli
5d8ada0219 Update SQLCipher. 2018-07-02 16:57:06 -07:00
Greyson Parrelli
c7066c0796 Cast to MmsMessageRecord in ConversationFragment#handleForwardMessage.
Was causing a crash for MMS messages.

Fixes #7951
2018-07-02 08:56:11 -07:00
unknown
69ea116b2b Updated authenticator icons (Fixes #7908) 2018-06-29 14:38:36 -07:00
Greyson Parrelli
18756aedf6 Remove the ability to save backups to the external SD card.
The directory we were previously saving backups to on the external SD
card is actually deleted upon app uninstall and/or clearing the app's
data. There's also no reliable way to write to the root of an external
SD card (that isn't comically inconvenient), so for now it's safer if we
just move back to getting the regular 'ol standard external storage
directory (which is likely internal storage, despite its name).

Fixes #7845
2018-06-29 14:10:45 -07:00
Greyson Parrelli
290b184491 Enable shared contact sending. 2018-06-29 11:08:13 -07:00
Greyson Parrelli
707ca53a23 Bump version to 4.22.4 2018-06-28 12:54:32 -07:00
Greyson Parrelli
0d386d3c14 Fix progress bar showing for self-sends.
For self-sends, we were never marking attachments as uploaded. I made is
so that happens now, but to prevent it for showing for already-sent
messages, we also don't show controls for self-send conversations.
2018-06-28 12:07:23 -07:00
Greyson Parrelli
8e186f7c62 Bump version to 4.22.3 2018-06-27 09:48:42 -07:00
Greyson Parrelli
708cd5335d Updated language translations. 2018-06-27 09:47:58 -07:00
Greyson Parrelli
fd6d947df3 Fix ClassCastException in ThreadDatabase.
I casted too deep. Forgot about NotificationMmsMessageRecord.
2018-06-27 09:43:02 -07:00
Greyson Parrelli
6a9d19e73d Bump version to 4.22.2 2018-06-25 19:42:11 -07:00
Greyson Parrelli
c33c74960e Update libwebrtc to M67. 2018-06-25 19:41:35 -07:00
Greyson Parrelli
f11f99366d Bump version to 4.22.1 2018-06-25 14:32:02 -07:00
Greyson Parrelli
8af076a796 Restore res/values-be/strings.xml 2018-06-25 14:28:54 -07:00
Greyson Parrelli
28dc477b54 Bump version to 4.22.0 2018-06-25 12:18:39 -07:00
Greyson Parrelli
7fb53edc3c Updated language translations. 2018-06-25 12:18:04 -07:00
Greyson Parrelli
381547d668 Fix crash with formatting emails in recipient settings.
Fixes #7868
2018-06-22 13:24:36 -07:00
Greyson Parrelli
f72f75ee61 Show a link for privacy policy. 2018-06-22 13:09:43 -07:00
Greyson Parrelli
b39a7ac939 Add expiration time to group update requests. 2018-06-22 11:29:16 -07:00
Greyson Parrelli
b5d4cac90a Send/receive expiration times for group updates.
This particularly helps with the bug where people who were newly added
to a group wouldn't receive an expiration timer until the first message
was sent.
2018-06-22 11:01:55 -07:00
Greyson Parrelli
20cc6f4d0e Return registration permission string to previous value. 2018-06-22 10:59:53 -07:00
riyapenn-signal
b9c337d0b7 Updated for small copy change 2018-06-22 10:59:53 -07:00
riyapenn-signal
3654856be5 Updated strings.xml to include minor copy changes
- Permission prompt to include text about backups
- Updated support email
- Updated domain to signal.org in a link
2018-06-22 10:59:53 -07:00
Greyson Parrelli
4f72f4c649 Remove unused string. 2018-06-22 10:59:53 -07:00
Greyson Parrelli
dae655fd01 Fix conversation snippet for contact shares.
Previously, contact shares would be displayed as "Media Message". Now
it'll show the same as it does in a notification, namely
"{contact-emoji} {contact-name}".
2018-06-22 10:59:53 -07:00
Greyson Parrelli
933be54035 Update scheduling of ServiceOutageDetectionJob.
Previously, we were running this job in PushSendJob#onCanceled().
However, with the new retry logic, this won't happen for 24 hours.

Instead, we now schedule the job in PushSendJob#onRetry().
2018-06-22 10:59:53 -07:00
2-4601
f1d8fd8838 Add devices to hardware AEC blacklist
- Moto G4
- Nokia 5 (TA-1053)

Alleviates #7635
2018-06-22 10:59:53 -07:00
Greyson Parrelli
a50edc3d25 Keep retrying message sends for 24 hours.
Previously, we retried based on a count. Now we've added the ability to
keep retrying for a specified time, using exponential backoff to
throttle attempts.
2018-06-22 10:59:53 -07:00
Greyson Parrelli
cddb8082f4 Remove unnecessary maven repo. 2018-06-22 10:59:53 -07:00
Greyson Parrelli
62c42a3513 Fix disappearing message corner case.
We never properly registered the ExpirationListener, meaning we were
relying on the wait-notify loop of ExpirationManager to delete things.
This normally works, but fails when your phone goes to sleep. So I
properly registered the receiver, and then added a failsafe to re-run
the ExpirationManager if we're about to render an expired message.

Fixes #7906
2018-06-22 10:59:53 -07:00
Greyson Parrelli
42f1baaf61 Imported JobManager as a source dependency.
We have to make some changes, and it's gotten to the point where
maintaining it as a separate library is more hassle than it's worth,
especially with Google releasing WorkManager as the preferred job
scheduling library.
2018-06-22 10:59:53 -07:00
Greyson Parrelli
5f99470226 Allow searching for words with apostrophes.
Previously, because apostrophes were 'banned' characters, searching for
them wouldn't work. That meant you couldn't find words like "I'm". Now
we just replace the apostrophe with a space and things "just work"
because of the nature of SQLite tokenization and prefix queries.
2018-06-22 10:59:53 -07:00
Greyson Parrelli
afec9e8cb0 Improve highlighting in search results.
Previously, we didn't support highlighting search results that had
tokens in the middle of the matches, which is a possibility with FTS.
Now we do more robust highlighting, as well as highlight matches in
phone numbers.
2018-06-22 10:59:53 -07:00
Greyson Parrelli
89fd7dda23 Break FTS queries into multiple prefix queries.
Previously, we made each full-text search query a single prefix query.
That means that the query "do c" would turn into "do c*". That means it
would match "do cat" but not "dog cat".

Now, we make each token a prefix query. So "do c" would turn into
"do* c*". That means it would match both "do cat" and "dog cat".
2018-06-22 10:59:53 -07:00
Greyson Parrelli
3563efc7de Update search query results when messages disappear.
Previously, if a message disappeared while looking at it in the search
results, it'd still stick around. Now they'll disappear from the results
in real-time.
2018-06-22 10:59:53 -07:00
Greyson Parrelli
febf3c249e Bump version to 4.21.6 2018-06-22 10:39:16 -07:00
Greyson Parrelli
ea4ac9db30 Fixed issue where self-sends didn't auto download.
1) There was an issue where we wouldn't auto-download group syncs.
2) There was another issue where we didn't show the download controls
   for messages you sent yourself.

Fixed #7920
2018-06-22 10:37:07 -07:00
Greyson Parrelli
e6277c0544 Bump version to 4.21.5 2018-06-21 19:10:04 -07:00
Greyson Parrelli
71a34dac5f Fix backup/import issue with expiring messages.
There was an issue where we were backing up group receipts and attachments
that were for expiring messages (which are already excluded from the backup).

This commit excludes these items from the backup, and for backups made
before this change, this commit also deletes these invalid entries at
the end of the restore process.

We also do a little database migration to cleanup any bad state that may
have been imported in the past.
2018-06-21 19:07:27 -07:00
Greyson Parrelli
61b2da9c8a Fix NPE during busy call. 2018-06-21 18:47:14 -07:00
Greyson Parrelli
d6ac17d0ee Bump version to 4.21.4 2018-06-20 13:25:53 -07:00
Greyson Parrelli
3a85c966d0 Fix false-positive outage detection.
Turns out that there's some weird quasi-state when you come out of
airplane mode, that if you do an InetAdress lookup, it returns some
weird IPv6-looking garbage address. Going to retry in that scenario
instead of assuming an outage.
2018-06-20 13:24:33 -07:00
Greyson Parrelli
f8747748f9 Bump version to 4.21.3 2018-06-20 07:33:25 -07:00
Greyson Parrelli
cc1350ba5b Updated language translations. 2018-06-20 07:32:24 -07:00
Greyson Parrelli
bb7a33ed8e Bump version to 4.21.2 2018-06-18 16:33:00 -07:00
Greyson Parrelli
fe4ce88439 Revert "Upgrade SQLCipher to respect a max window size."
This reverts commit dace93abb3.
2018-06-18 16:24:35 -07:00
Greyson Parrelli
2c7769ae26 Bump version to 4.21.1 2018-06-18 14:33:44 -07:00
Greyson Parrelli
542e962be9 Fixed crash when ScribbleView failed to save.
Previously, if an operation failed, we set the result to "null".
However, this was a mistake. Setting the result at all assumes success.
Instead, we need to set an exception so the ListenableFuture knows that
the operation failed.
2018-06-18 14:33:44 -07:00
Greyson Parrelli
e65cd2636b Bump version to 4.21.0 2018-06-18 14:33:44 -07:00
Greyson Parrelli
2c17b54ef9 Show a banner in the event of a service outage.
We will now determine if there has been a service outage and render a
banner at the top of the conversation list if we detect that there has
been one.
2018-06-18 14:32:45 -07:00
Greyson Parrelli
0999359454 Improve the image editor.
A variety of improvements to the image editor, such as:

- New, fullscreen styling
- Smoother lines
- Better text and sticker handling
- Improved color picker with a history pallette
- New highlighter tool
2018-06-18 14:32:45 -07:00
Greyson Parrelli
dace93abb3 Upgrade SQLCipher to respect a max window size.
Previously, SQLCipher's memory usage would grow indefinitely, up until
it hit the end of the cursor. We've now switched to a release where the
memory  used by the cursor can be bounded.
2018-06-18 14:32:45 -07:00
Greyson Parrelli
eed2c6ec4c Added adaptive icon support.
Also moved our non-adaptive app icon into the mipmap folders, which is
where they should be.

Fixes #7607
2018-06-18 14:32:45 -07:00
Greyson Parrelli
df2c5d38b0 Don't notify new users if there is a pending SQLCipher migration.
If a user is upgrading to use the SQLCipher database (which happened
back in 4.16, so this only applies to relatively dormant users who are
just getting back into the app) and received a new "user X joind signal"
message, then it could screw up the migration. So we're just dropping
these notifications that happen in this narrow window.
2018-06-18 14:32:45 -07:00
Greyson Parrelli
a6b6775aa1 Bump version to 4.20.9. 2018-06-18 14:11:50 -07:00
Greyson Parrelli
79857b98b3 Fix bug with quoted reply notifications. 2018-06-18 14:08:47 -07:00
Greyson Parrelli
0c3535cff8 Bump version to 4.20.8 2018-06-14 11:13:04 -07:00
Greyson Parrelli
626e6930a5 Fix search header rendering after rotation.
The sticky header cache was keeping views across rotations, causing them
to render incorrectly afterwards. I added a method to invalidate the
header layouts after rotation.

Fixes #7890.
2018-06-14 10:50:21 -07:00
Greyson Parrelli
44f5cc9070 Annotate methods in AttachmentUtil as @WorkerThread. 2018-06-11 11:08:25 -07:00
Greyson Parrelli
e45a4b86d8 Bump version to 4.20.7 2018-06-11 10:48:24 -07:00
Greyson Parrelli
30be732ae8 Don't auto-download attachments from unknown contacts. 2018-06-11 10:47:27 -07:00
Greyson Parrelli
643dd0b679 Bump version to 4.20.6 2018-06-06 20:14:05 -07:00
Greyson Parrelli
2b45b3caa2 Fixed export and restore of FTS tables.
First, FTS index contents do not need to be exported. They will be recreated naturally.

Second, we can't export the secret FTS tables, or SQLite will think it's corrupted.
2018-06-06 20:12:17 -07:00
Greyson Parrelli
b7282589de Fixed issue with backup and restore when creating new tables.
Fixes #7863
2018-06-06 09:07:38 -07:00
Greyson Parrelli
6bc7f2a5a4 Fix NPE in FTS when snippet is null. 2018-06-06 08:08:52 -07:00
Greyson Parrelli
3731e2a74a Fix jumbomoji rendering and EmojiTextView resizing.
Fixed an issue where jumbomoji were not properly being rendered
when using system emoji. Also fixed an issue where the text
content wasn't properly being recalculated when the view is
resized.

Fixes #7875
2018-06-06 07:57:03 -07:00
Greyson Parrelli
bb40f38124 Bump version to 4.20.5 2018-05-29 13:42:21 -04:00
Greyson Parrelli
f0e5aa312e Allow EmojiTextView to redraw after changing emoji setting.
Also just fixed some minor formatting issues.
2018-05-28 17:20:28 -04:00
Greyson Parrelli
ceafb0d130 Reduce emoji flickering and other ellipsize woes.
1. Switch to using default text rendering if there's no emoji present in
the string.

2. Reduce redudant redraws by skipping of setText() calls for identical
strings.

Together, these two changes should reduce the vast majority of
flickering we see with EmojiTextView ellipsizing.
2018-05-24 13:32:56 -04:00
Moxie Marlinspike
70c2a863cc Correctly store backup
Fixes #7831
2018-05-24 09:57:16 -07:00
Greyson Parrelli
d813275f42 Increase number of recent conversations shown when sharing.
Intended to reduce the pain of #7202.
2018-05-24 10:25:58 -04:00
Greyson Parrelli
5650a02cfb Sort search results exclusively by date.
I think I was initially lured into searching by rank because it gives
the illusion of providing the "best match". However, in practice, FTS
never gives back "bad" matches with low ranks -- all of the results it
returns will contain your query in some form (most commonly a direct
substring, but they do take some liberties if you have multiple tokens
in your queries). Given that, in general, more recent search results are
in fact more relevant, we can sort by date exclusively and get a better
ordering overall.
2018-05-24 09:39:57 -04:00
Greyson Parrelli
0503c9eea5 Prevent replies on action messages.
Fixes #7829
2018-05-23 15:16:42 -04:00
Greyson Parrelli
abae419853 Flatten multiline text snippets in search results.
If a search result snippet spans two lines, we only show the first line.
For the purpose of display, we first remove all newlines in order to
make the full snippet visible.
2018-05-23 14:32:46 -04:00
Greyson Parrelli
71ccbf2a1b Secondarily sort search results by date.
This should help with getting back search results that more closely
match user intention.
2018-05-23 14:17:43 -04:00
Greyson Parrelli
92a64f59a4 Switch search to use the existing header.
Probably best to not try out any possible new design changes just yet.
Let's stick with what we have.
2018-05-23 11:06:07 -04:00
Greyson Parrelli
6d56447de2 Bump version to 4.20.4 2018-05-23 08:36:25 -04:00
Greyson Parrelli
e189fff856 Fixed some cursor-related bugs in Search. 2018-05-23 08:32:46 -04:00
Greyson Parrelli
8fc63c4d78 Bump version to 4.20.3 2018-05-23 08:28:50 -04:00
Greyson Parrelli
e6e8416aec Use correct recipient for message search results.
Previously, we'd always use the recipient of the message record, which
was incorrect for messages sent to groups. Now we always use the
recipient for the matching thread record.

Fixes #7823
2018-05-23 08:22:08 -04:00
Greyson Parrelli
a792a6e6ae Fixed ThumbnailView sizing problems.
Glide will use the dimensions of the target ImageView as the dimensions
for the image it's loading. This caused problems in the case of
ThumbnailView, as we were constantly changing the ImageView dimensions,
meaning Glide may not have the most recent values (it may be called in
between measure calls, for instance).

To solve this, we now will always override the default image dimensions
when we load an image. If no dimensions are present, we will default to
the layout_width and layout_height of the ThumbnailView.

Fixes #7810
2018-05-22 17:03:51 -04:00
Greyson Parrelli
07e8ae716c Fix EmojiTextView regression.
Using the singleLine attribute will make the TextView report that the
lineCount is always 1, regardless of actual text length. This breaks our
manual ellipsize calculation. Because you can't actually read the
singleLine attribute at runtime, I've switched relevant usages of
singleLine to use maxLines=1 (relevant usages are EmojiTextViews where
singleLine was set and ellipsize was set to 'end').

Fixes #7744
2018-05-22 14:20:50 -04:00
Greyson Parrelli
0b1b568893 Fix notifications for replies.
Notifications for replies will no longer display as a "Media Message" if
they do not contain media. Instead, they will just contain the reply
text.

Fixes #7798
2018-05-22 13:12:13 -04:00
Greyson Parrelli
3a827d1c48 Fix dark theme in search.
Fixed #7821
2018-05-22 12:37:00 -04:00
Moxie Marlinspike
622b3afce0 Update build instructions 2018-05-22 08:25:44 -07:00
Moxie Marlinspike
107f6b4277 Bump version to 4.20.2 2018-05-22 07:17:49 -07:00
Moxie Marlinspike
32b608ff2f Updated language translations 2018-05-22 07:17:24 -07:00
Greyson Parrelli
eb42b7b26a Bump version to 4.20.1. 2018-05-21 19:59:56 -04:00
Greyson Parrelli
93effc8890 Disable contact sending. 2018-05-21 19:57:50 -04:00
Greyson Parrelli
5d75f11cbc Bump version to 4.20.0. 2018-05-21 17:19:03 -04:00
Greyson Parrelli
0449647cf9 Implemented full-text search.
You can now use the search bar on the conversation list to find
conversations, messages, and contacts.
2018-05-21 16:36:59 -04:00
Greyson Parrelli
c0b75c2ef5 Disable shared contact sending.
Sending shared contacts isn't backwards-compatible, so we want to have a
few releases where receiving is enabled, but not sending. That way, when
we enable sending, most users should be able to properly receive the
shared contact messages.
2018-05-21 15:45:22 -04:00
Greyson Parrelli
ca260a92e3 Convert vCard attachments to Shared Contacts.
When you share a vCard from an external app (like the Contacts app) into
Signal, we'll now convert it to a pretty Shared Contact message and
allow you to choose which fields of the contact you wish to send.
2018-05-21 15:45:22 -04:00
Greyson Parrelli
e6c16cf28d Allow editing of contact names.
Took care to properly format CJK names.
2018-05-21 15:45:22 -04:00
Greyson Parrelli
54dbffaf30 Added ability to share contacts.
The "contact" option in the attachments tray now brings you through an
optimized contact sharing flow, allowing you to select specific fields
to share. The contact is then presented as a special message type,
allowing you to interact with the card to add the contact to your system
contacts, invite them to signal, initiate a signal message, etc.
2018-05-21 15:45:22 -04:00
Greyson Parrelli
17dbdbd0a9 Handle quote position task finishing after fragment detaches.
There's a chance that the AsyncTask that retrieves a quoted message's
position could finish after the fragment is detached, which would cause
a crash. I've changed it so if this case occurs, the result is ignored.

Also, I noticed that when searching the message table, if a quote can't
be found, we'd end up traversing the entire table. To prevent this from
taking forever on large message tables, I've limited it to searchin only
what is currently present in the adapter.

Fixes #7756
2018-05-21 15:45:22 -04:00
Greyson Parrelli
ca8fecea9c Clean up camera flipping, handle having missing cameras.
Did a refactor to better organize the camera flipping code. Also, I
wanted to make sure we handle the cases where the user doesn't have two
cameras (or no cameras, for that matter). In these cases, we just don't
show the appropriate buttons.
2018-05-21 15:45:22 -04:00
Niklas Hambüchen
f1c79eaebf Add button to flip camera (front vs rear). Fixes #6279 2018-05-21 15:45:22 -04:00
Moxie Marlinspike
6c1a1fb9ad Use cache directory on removable storage for backups if present
Fixes #7692
2018-05-21 15:45:22 -04:00
Moxie Marlinspike
35d158cfee Treat Permissions "not now" as a denial
Fixes #7713
2018-05-21 15:45:22 -04:00
Moxie Marlinspike
a5047cb17b Fix for sender's expiring messages in group with unregistered user
Fixes #7719
2018-05-21 15:45:22 -04:00
Moxie Marlinspike
5006b36e2d Show lock notification immediately after setting is toggled
Fixes #7659
Closes #7678
2018-05-21 15:45:22 -04:00
Moxie Marlinspike
c6e20f715b Merge pull request #7782 from jlund-signal/contributing-updates
Update the contribution guidelines.
2018-05-20 05:18:43 -07:00
Joshua Lund
fcc9c2778d Update the contribution guidelines. 2018-05-10 10:52:00 -06:00
Moxie Marlinspike
e20b973872 Add local backup listener to manifest 2018-05-06 23:52:36 -07:00
Moxie Marlinspike
7951df09ad Bump version to 4.19.3 2018-04-26 17:48:43 -07:00
Greyson Parrelli
f580edaf91 Fix voice recording UI when replying to a message.
Just had to relayer some of the views so the recording UI positions
correctly lined up at the bottom.
2018-04-26 17:43:35 -07:00
Greyson Parrelli
102941c18c Fix QuoteView measuring when voice notes are present.
Fixes #7740
2018-04-26 17:41:37 -07:00
Moxie Marlinspike
0c8b2b23da Bump version to 4.19.2 2018-04-26 09:33:35 -07:00
Moxie Marlinspike
aa33be6b03 Updated language translations 2018-04-26 09:33:03 -07:00
Greyson Parrelli
43622e603d Save replies in drafts.
Previously, quotes were not saved to drafts, meaning they would be lost
when leaving the conversation or app. Now, a QuoteId (which represents
the necessary data to restore the QuoteModel) is serialized and stored
in the DraftDatabase.

Fixes #7716
Closes #7729
2018-04-26 09:19:22 -07:00
RiseT
7100030c22 Export string conversation_context__menu_reply_to_message
Additionally changed from "Reply" to "Reply to message" as other
related strings are more comprehensive as well.

Closes #7732
2018-04-25 10:41:26 -07:00
Greyson Parrelli
63a3b1acb9 Also make author text EmojiTextView. 2018-04-24 12:18:33 -07:00
Greyson Parrelli
6fbbc9d078 Render emoji's properly in quote bubbles.
Unfortunately, the change wasn't as simple as just switching to use our
EmojiTextView. That view only supported single-line text. I added
support for multi-line text.

Fixes #7704.
2018-04-24 12:18:33 -07:00
Greyson Parrelli
cbe394025d Fix reply-to colors in dark mode to increase contrast.
Fixes #7705
2018-04-20 17:35:48 -07:00
RiseT
29af1669e1 Export strings from registration_call_me_view
Export strings from webrtc_call_screen

Closes #7543
2018-04-19 18:03:45 -07:00
Nicholas Rizzio
e6f76159b0 Export "creating backup" string
Closes #7656
2018-04-19 17:59:31 -07:00
Henning Dodenhof
e0603abdd3 Use FileProvider for update file handling
Fixes #7654
Closes #7658
2018-04-19 13:30:21 -07:00
Moxie Marlinspike
2a1ce859c4 Add Moto G (5S) Plus to hardware AEC blacklist
For #7635
2018-04-19 10:58:39 -07:00
Moxie Marlinspike
8452fc6c58 Correctly avoid displaying about category in groups
Fixes #7702
2018-04-19 10:53:37 -07:00
Moxie Marlinspike
2ac0179d65 Handle odd sized buffers on backup import decrypt
Fixes #7701
2018-04-18 21:20:06 -07:00
Moxie Marlinspike
8b74e9a075 Bump version to 4.19.1 2018-04-18 10:40:49 -07:00
Moxie Marlinspike
afbf6a91bb Bump version to 4.19.0 2018-04-18 10:15:00 -07:00
Moxie Marlinspike
8e2ae6c288 Updated language translations 2018-04-18 10:12:56 -07:00
Greyson Parrelli
fa99e8f0d0 Updated reply-to UI.
All UI components are now properly styled and functioning according to
spec.
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
d567534609 replies 2018-04-16 17:33:26 -07:00
Moxie Marlinspike
8bec5a96f5 Make delivery receipts work correctly on CDMA networks
Fixes #7646
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
d8a6fcf979 Retain latest 2 instead of latest 5 backups
Fixes #7650
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
4669c45ff7 Perpetuate the original sin of dark theme
Fixes #7614
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
2c405d1769 Delete raw contacts that are marked for deletion
Fixes #7628
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
821957137a Check for context liveness to prevent NPE
Fixes #7633
2018-04-16 17:33:26 -07:00
Greyson Parrelli
b8fbc91f33 Only show copy if text is selected, remove newlines from copied text.
We now check if _any_ text is selected when doing a batch selection
to determine if we should show the copy option. Also, previously it
was putting in empty lines for messages that don't have any text. I
changed it so empty messages have no effect on the text that is copied.

Fixes #7472
2018-04-16 17:33:26 -07:00
FeuRenard
404610fbcd Pass correct address from media overview to preview
Fixes #7384
Closes #7387
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
3f3d7f549b Make an attempt to store/retrieve backups from removable storage
Fixes #7521
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
7dd8baba5a Add permission callback to preference fragment 2018-04-16 17:33:26 -07:00
Moxie Marlinspike
eb0af13887 Fix location URL encoding
Fixes #7604
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
72310ed3c6 Group member dialog tap takes you to recipient preference
Fixes #7463
2018-04-16 17:33:26 -07:00
Moxie Marlinspike
e86a9ce7eb Add phone number and direct dial to recipient preferences 2018-04-16 17:33:26 -07:00
Moxie Marlinspike
c2c180e38d Bump version to 4.18.3 2018-04-12 17:19:44 -07:00
Moxie Marlinspike
0b0853a223 Clear cache on update 2018-04-12 17:19:18 -07:00
Moxie Marlinspike
c573d5703b Bump version to 4.18.2 2018-04-09 09:10:05 -07:00
Moxie Marlinspike
8da8867bac Update language translations 2018-04-09 09:09:58 -07:00
Moxie Marlinspike
ccc3ff4aac Fix for Glide image caching issue
Fixes #7630
2018-04-09 09:03:42 -07:00
Moxie Marlinspike
ca471b1408 Explicitly remove messages.db journal
Fixes #7636
2018-04-05 03:50:33 -07:00
Moxie Marlinspike
c3882e9d51 Bump version to 4.18.1 2018-04-04 05:09:55 -07:00
Moxie Marlinspike
3bceb0d8ec Delete old message DB 2018-04-04 05:09:43 -07:00
Moxie Marlinspike
0753ff85ed Default snippet type to 0 if it's null
Fixes #7551
2018-04-03 08:59:19 -07:00
Moxie Marlinspike
5f7c30e840 Remove some old tests
Fixes #7458
2018-04-03 00:53:29 -07:00
Moxie Marlinspike
b9f99f9941 Manually calculate length of attachments if they're super old
Fixes #7560
2018-04-02 10:03:26 -07:00
Moxie Marlinspike
2c82b3610d Mark DB current after backup upgrade process
Fixes #7596
2018-04-02 06:27:50 -07:00
Moxie Marlinspike
c0da061072 Bump version to 4.18.0 2018-03-31 02:21:35 -07:00
Moxie Marlinspike
90f2398219 Updated language translations 2018-03-31 02:20:53 -07:00
Greyson Parrelli
18039bc3f4 Show groups when searching for contacts.
Currently, if you're searching for a contact to start a conversation
with or send a share to (via the Android sharing system), groups do not
appear. With this change, groups will now appear when searching, located
under their own  heading.

Fixes #7202.
Closes #7577
2018-03-31 02:14:02 -07:00
Greyson Parrelli
5dc5503896 Fixed 'All Media' toolbar color mismatch.
In landscape, you'd see that the tabs were a different color from the
toolbar. This has been corrected so they're all the same color now.

Fixes #7578
Closes #7579
2018-03-31 02:14:02 -07:00
Greyson Parrelli
a573ab7c76 Setup alternate domain front.
In preparation for Google shutting down domain fronting.

Closes #7584
2018-03-31 02:14:02 -07:00
Greyson Parrelli
ea374735e1 Render images in a conversation true-to-size.
Previously, we were always rendering images as squares. Instead of doing
that, we now render them as close to true-to-size as possible (within
reasonable min/max width/height boundaries).
2018-03-31 02:14:02 -07:00
Moxie Marlinspike
9f8b4cf892 Populate incoming attachments with width and height from message 2018-03-31 02:14:02 -07:00
Moxie Marlinspike
3c30db7edf No longer generate image thumbnails manually
Delete manually calculated image thumbnails
2018-03-31 02:14:02 -07:00
Moxie Marlinspike
95d76638dc Simple encrypted glide disk cache 2018-03-31 02:14:02 -07:00
Greyson Parrelli
7e1e666172 Strip EXIF metadata from all JPEG images.
Strip all EXIF metadata from all JPEGs by re-encoding the JPEG. This
will keep all of the necessary visual effects of the tags (by encoding
them directly in the image data) while stripped the EXIF tags
themselves.
2018-03-31 02:14:02 -07:00
Greyson Parrelli
10e5b24cfd Allow batch deletion of media.
It is now possible to batch-delete media in the "media overview" screen.
You can long press to enter multi-select mode. Then a delete button
appears on the menu bar. After pressing delete, you will get a
confirmation, and if the user confirms, the items will delete while a
progres dialog shows.
2018-03-31 02:14:02 -07:00
Greyson Parrelli
0c768a24e4 Allow deletion of media through preview.
When viewing a media in the media preview, you can delete it by pressing
a delete button on the action bar. It will then ask you to confirm your
choice. If you confirm, it will delete the attachment from the database
and from disk. If it was the only attachment for that message, the
message itself will also be deleted.
2018-03-31 02:14:02 -07:00
Joshua Lund
a8cf5b8efa Update the issue template.
Closes #7581
2018-03-31 02:01:26 -07:00
Moxie Marlinspike
f48f4a8812 Bump version to 4.17.5 2018-03-20 11:36:38 -07:00
Moxie Marlinspike
d6610f0dd0 Add profile avatars to backup
Fixes #7450
2018-03-19 14:10:21 -07:00
Moxie Marlinspike
261296e41b Don't crash direct share service if avatar photo is missing
Fixes #7541
2018-03-19 13:17:57 -07:00
Moxie Marlinspike
26a16bf0ca Bump version to 4.17.4 2018-03-15 16:48:22 -07:00
FeuRenard
9c0129c4b0 Allow skipping registration PIN intervals on success
Closes #7517
Closes #7518
2018-03-15 12:14:43 -07:00
Moxie Marlinspike
b168e14985 Move salt outside the loop 2018-03-15 10:18:14 -07:00
Moxie Marlinspike
73233c01ba Fix backup NPE
Fixes #7526
2018-03-14 23:40:01 -07:00
Moxie Marlinspike
90006e81db Add salt to backup header 2018-03-14 10:28:41 -07:00
Greyson Parrelli
f544b7d7b4 Reduce image stutter by using subsampling more often.
Fixes #7208.
2018-03-13 13:25:41 -07:00
Moxie Marlinspike
5f12696bed Bump version to 4.17.3 2018-03-13 09:45:43 -07:00
Moxie Marlinspike
41d06fc8c2 Simplify reminder interval lookup
Fixes #7513
2018-03-13 09:39:56 -07:00
Moxie Marlinspike
aff65abe91 Hide keyboard after backup passphrase entered
Fixes #7508
2018-03-13 09:28:27 -07:00
Moxie Marlinspike
64afce5f66 Switch to parameterized statements for backup
Fixes #7507
2018-03-13 09:27:58 -07:00
Moxie Marlinspike
52ca295131 Bump version to 4.17.2 2018-03-11 17:34:16 -07:00
Moxie Marlinspike
6b5da7f8cf Disable registration lock reminders for <=KK devices
Fixes #7500
2018-03-11 17:30:31 -07:00
Moxie Marlinspike
43d7e99a50 Don't offer backup restore on reregistration
Fixes #7502
2018-03-11 17:12:42 -07:00
平民·寻梦(Pingmin Fenlly Liu)
cc288d1e43 Just update to the new repo path "github.com/signalapp"
Closes #7469
2018-03-11 17:06:22 -07:00
FeuRenard
150601c51e Replace '1' with '%d' in plural strings
Fixes #7470
Closes #7471
2018-03-11 17:05:01 -07:00
RiseT
375ebeb661 Update Transifex locales as per 2018-03-01
Remove:
- Kannada

Add (>= 90% of strings translated):
- Burmese
- Galician
- Khmer
- Lithuanian
- Thai

Closes #7490
2018-03-11 17:03:31 -07:00
junitas
7f7aab044c Escape single quotes in SQLite entries for message backups
Fixes #7491
Closes #7497
2018-03-11 17:00:53 -07:00
Moxie Marlinspike
fd7a3190f8 Bump version to 4.17.1 2018-03-10 11:19:05 -08:00
Moxie Marlinspike
c8dd62cecf Make it possible to set a zero value for screen lock timeout
Fixes #7485
2018-03-09 15:27:20 -08:00
Moxie Marlinspike
11ce4ee807 Actually increment event count 2018-03-09 14:29:15 -08:00
Moxie Marlinspike
40d14698b8 Fix NPE introduced by #6886 2018-03-09 11:14:37 -08:00
Moxie Marlinspike
34ed55d3ac Post backup progress event for every item
Fixes #7483
2018-03-09 11:03:18 -08:00
Moxie Marlinspike
954b2f22f6 Don't immediately prompt for registration lock pin after reregistration
Fixes #7484
2018-03-09 10:41:43 -08:00
Moxie Marlinspike
b39820dcb6 Clarify Registration Lock reminder
Fixes #7484
2018-03-09 10:40:29 -08:00
Moxie Marlinspike
1a24885110 Fix issue "home button" issue with screen lock
Fixes #7475
2018-03-09 10:25:29 -08:00
Moxie Marlinspike
29fcce23b1 Prevent double screen lock intent from firing
Fixes #7475
2018-03-08 17:41:27 -08:00
Moxie Marlinspike
a2d04f4806 Prevent us from sql injecting ourselves on backup/restore
Fixes #7478
2018-03-08 16:39:57 -08:00
Moxie Marlinspike
9fb67b9f03 Bump version to 4.17.0 2018-03-08 08:49:26 -08:00
Moxie Marlinspike
46e5d64857 Updated language translations 2018-03-08 08:45:28 -08:00
Moxie Marlinspike
9c63c6045d Export string 2018-03-07 12:13:58 -08:00
Moxie Marlinspike
3c0bbfe6f0 s/External Storage/Storage 2018-03-07 12:10:38 -08:00
Andy Staudacher
61a7062030 Remove obsolete workaround for DE/FI/SK shortcodes
libphonenumber supports these since December 2015 / January 2016.
Most of these changes went into libphonenumber-7.2.2 (Dec 15, 2015),
the last changes related to this into libphonenumber-7.2.4 (Jan 28, 2016).
This was about adding EU-wide helplines 116xxx (http://ec.europa.eu/digital-agenda/en/116-helplines).
See: https://github.com/googlei18n/libphonenumber/blob/master/java/release_notes.txt

Closes #6130
2018-03-07 09:59:43 -08:00
Sam Lanning
69f180a5ec Fix some potential integer overflows for expiration time
In a number of locations in the code, there were conversions of message
expiration times from seconds to milliseconds, and then assigned to `long`
contexts. However these conversions were being done as integer multiplication
rather than long multiplication, meaning that there was a potential for
overflows.

Specifically, the maximum value that could be represented before overflowing
was (2^31 / 1000 / 60 / 60 / 24) days = 24.8 days (< 1 month). Luckily the
current allowed timeouts are all less than that value, but this fix would
remove the artificial restriction, effectively allowing values of 1000x greater
(68 years), at least for android.

Related #5775
Closes #7338
2018-03-07 09:55:24 -08:00
Andrew Gaul
10c1ee70e8 Make some inner classes static
Closes #7370
2018-03-07 09:51:05 -08:00
Win Ribeka
c5e495bfe5 Adding task affinity to the share activity. Fixes #7312.
Closes #7371
2018-03-07 09:44:11 -08:00
FeuRenard
0efda2df91 Make toast after saving attachment translatable
Closes #7374
2018-03-07 09:41:33 -08:00
art1fa
4bdb2acd29 Batch selection mode improvements
Simplified and now the same for conversation and conversation list.

Added also some styling.

Closes #7410
2018-03-07 09:38:51 -08:00
Moxie Marlinspike
56c95d1d1b Extract string resource 2018-03-07 09:36:15 -08:00
Moxie Marlinspike
d44bfc3ce3 s/password/passphrase 2018-03-07 09:34:41 -08:00
FeuRenard
527e39eee8 Don't save white space drafts
Fixes #7308
Closes #7383
2018-03-07 09:33:57 -08:00
Moxie Marlinspike
2beb1dd8d9 Layout adjustments 2018-03-07 09:08:13 -08:00
Marek Sebera
694a5de2c3 Send m-notifyresp-ind (NotifyRespInd) for retrieved MMS on Lollipop API 2018-03-06 17:34:31 -08:00
art1fa
feee09cd28 Fix color in toolbars 2018-03-06 10:14:23 -08:00
art1fa
6dd8300c73 Add standard elevation to Toolbars 2018-03-06 10:14:23 -08:00
art1fa
4281097828 Decrease back button padding / margin 2018-03-06 10:00:44 -08:00
art1fa
1e62934220 Reduce avatar size in ConversationView 2018-03-06 10:00:44 -08:00
junitas
4b5d7bbfa4 Ignore swipe events for ConversationListItemInboxZero
Fixes #7423
2018-03-06 09:35:13 -08:00
Moxie Marlinspike
f5f1305af8 Update libpastelog to 1.1.2 2018-03-05 20:17:55 -08:00
Moxie Marlinspike
110d33ddf8 Support for Registration Lock PINs 2018-03-05 16:13:56 -08:00
Moxie Marlinspike
d28dc670ea Migrate to Android fingerprints and auth for Signal screen lock 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
3970a30e14 Add chunk IV to chunk MAC 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
24e573e537 Support for full backup/restore to sdcard 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
9f6b761d98 Migrate sessions into database 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
9f3c04dfb5 Migrate prekeys into database 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
6239508b39 Clean file names for belt and suspenders 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
71c7ef5b5e Support for custom call ringtone selection and per-chat ringtones 2018-03-05 16:11:49 -08:00
Moxie Marlinspike
35a6ec707f Update libpastelog to 1.1.1 2018-03-01 18:19:34 -08:00
Moxie Marlinspike
8eb8f9e724 Bump version to 4.16.9 2018-02-28 10:47:49 -08:00
Moxie Marlinspike
bebdbe2aaa Remove master secret requirement from SMS received job
Fixes #7444
2018-02-28 10:45:50 -08:00
Moxie Marlinspike
eaf11744c7 Bump version to 4.16.8 2018-02-26 14:03:49 -08:00
Moxie Marlinspike
18aa202695 Really really delay SMS processing until sqlcipher migration completes
Blocking the SMS job on the screen lock isn't enough, since then
the job races against the migration.

Fixes #7390
2018-02-26 14:02:12 -08:00
Moxie Marlinspike
a0a9e412b4 Correctly lock screen when locked from conversation list
Fixes #7441
2018-02-26 10:47:41 -08:00
Moxie Marlinspike
9ebd8682b5 Bump version to 4.16.7 2018-02-24 11:12:11 -08:00
Moxie Marlinspike
028c6edd8a Manually calculate attachment offsets
The CipherInputStream skip() method is pretty non-functional

Fixes #7438
2018-02-24 11:09:26 -08:00
Moxie Marlinspike
4324f0b7ec Update libpastelog 2018-02-24 11:09:05 -08:00
Moxie Marlinspike
c940e984f0 Bump version to 4.16.6 2018-02-22 13:14:56 -08:00
Moxie Marlinspike
43bb1d2290 Updated language translations 2018-02-22 13:13:36 -08:00
Moxie Marlinspike
7318236286 Delay processing SMS messages until after sqlcipher migration
When screen lock passphrase is enabled

Fixes #7390
2018-02-21 18:49:52 -08:00
Moxie Marlinspike
a40d7158de Bump version to 4.16.5 2018-02-05 17:38:05 -08:00
Moxie Marlinspike
0bbe83f8f2 Don't copy column to sqlcipher db if it doesn't exist there
Fixes #7386
2018-02-05 17:32:24 -08:00
Moxie Marlinspike
2b651ee323 Prevent NPE in #7375 2018-02-05 12:08:40 -08:00
Moxie Marlinspike
3be45f093c Bump version to 4.16.4 2018-02-04 11:26:54 -08:00
Moxie Marlinspike
9d5d43cf3a Wait to process messages until after migration when screenlocked
Fixes #7390
2018-02-04 11:26:02 -08:00
Moxie Marlinspike
751cc0e86a Bump version to 4.16.3 2018-02-02 16:32:05 -08:00
Moxie Marlinspike
01c3244f75 Specify supported ABIs 2018-02-02 16:31:49 -08:00
Moxie Marlinspike
f17c144a60 Bump version to 4.16.2 2018-02-01 19:36:29 -08:00
Moxie Marlinspike
93ca2ad8cf Fix new conversation activity crash 2018-02-01 19:36:09 -08:00
Moxie Marlinspike
a4aac62bcb Bump version to 4.16.1 2018-02-01 19:23:29 -08:00
Moxie Marlinspike
3633d805c8 More MasterSecret cleanup 2018-02-01 19:22:48 -08:00
Moxie Marlinspike
59092e2ec0 No need for an encrypted serializer any longer 2018-02-01 18:33:12 -08:00
Moxie Marlinspike
e6a069af6d Remove unnecessary body model 2018-02-01 18:29:09 -08:00
Moxie Marlinspike
23aee53c7d Add determinte progress and foreground service for sqlcipher migration 2018-02-01 16:01:24 -08:00
Moxie Marlinspike
bdd4b456c4 Have stream generate random value 2018-02-01 15:42:28 -08:00
Moxie Marlinspike
c004ead940 Bump version to 4.16.0 2018-02-01 10:25:27 -08:00
Moxie Marlinspike
69d18dfa6a Update libsignal-service to latest 2018-01-31 19:29:19 -08:00
Moxie Marlinspike
7b353a94d8 Trigger DB schema change on application DB update Activity 2018-01-31 17:49:08 -08:00
Moxie Marlinspike
5496f5baac Deprecate encrypted storage DB types 2018-01-30 17:45:12 -08:00
Moxie Marlinspike
f36b296e2e Migrate from SQLite and ciphertext blobs to SQLCipher + KeyStore 2018-01-30 17:27:05 -08:00
Moxie Marlinspike
d1819b6361 Bump version to 4.15.5 2018-01-23 14:01:28 -08:00
Moxie Marlinspike
970e24ef26 Bump version to 4.15.4 2018-01-23 13:44:33 -08:00
Moxie Marlinspike
799b9c2074 Adjust media preview viewpager swipe direction for rtl 2018-01-23 13:43:37 -08:00
Moxie Marlinspike
14644077e7 Change media preview swipe direction based on entry point
Fixes #7354
2018-01-23 12:52:24 -08:00
Moxie Marlinspike
9939461d9e Bump version to 4.15.3 2018-01-22 11:38:54 -08:00
Moxie Marlinspike
0403cbfd65 Updated language translations 2018-01-22 11:38:29 -08:00
Moxie Marlinspike
24e6605024 Reverse media order in ViewPager
Fixes #7354
2018-01-22 09:32:27 -08:00
Moxie Marlinspike
be0ddb9756 Bump version to 4.15.2 2018-01-18 10:18:58 -08:00
Moxie Marlinspike
bc64230a65 Switch to HackyViewPager for media preview
Fixes #7344
Fixes #7335
2018-01-18 10:16:35 -08:00
Moxie Marlinspike
763fa0dd21 Catch exception on image decoding error in notification 2018-01-18 10:11:33 -08:00
Moxie Marlinspike
e60715587f Update service lib to 2.7.0 2018-01-18 10:01:41 -08:00
Moxie Marlinspike
47194e7079 Bump version to 4.15.1 2018-01-16 12:08:46 -08:00
Moxie Marlinspike
95ebae5d5f Support onStop/onStart media display in the correct position
Fixes #7330
Fixes #7329
2018-01-16 12:06:55 -08:00
Moxie Marlinspike
fe02b3f8d3 Catch exception from misconfigured MMSC
Fixes #7339
2018-01-16 11:32:51 -08:00
Moxie Marlinspike
94e2b9e66e Make video player in media player control a view stub 2018-01-16 11:21:58 -08:00
Moxie Marlinspike
d3bf6a1c59 Bump version to 4.15.0 2018-01-09 09:55:31 -08:00
Moxie Marlinspike
97244e8624 Updated language translations 2018-01-09 09:55:24 -08:00
Moxie Marlinspike
551470123d Update glide to 4.5.0 2018-01-08 17:04:39 -08:00
Moxie Marlinspike
b307980d8c Perform a contact sync with every directory refresh 2018-01-04 11:56:55 -08:00
Moxie Marlinspike
8bba45f396 Add swipe gestures to media view
Fixes #2355
Closes #6632
2018-01-04 11:11:49 -08:00
Moxie Marlinspike
34424a9b3e Fix crash when signal messages disabled in group conversation
Fixes #6419
Closes #6803
2017-12-25 15:57:33 -08:00
Joshua Lund
c4991e857d Update the API level in the build documentation. 2017-12-25 14:42:30 -08:00
vpo
05daa71977 Adjust permission request dialog colors in dark theme
Fixes #7252
Closes #7292
2017-12-25 14:39:43 -08:00
Moxie Marlinspike
da8cea9878 Update glide to 4.4 2017-12-21 17:43:24 -08:00
Moxie Marlinspike
419ef2c6f8 Update support library to 27.0.2 2017-12-21 16:38:55 -08:00
Moxie Marlinspike
a798f97aa3 Update to webrtc M64 2017-12-21 16:37:07 -08:00
Moxie Marlinspike
b17451b867 Bump version to 4.14.10 2017-12-20 11:46:14 -08:00
Moxie Marlinspike
feaea32cdd Updated language translations 2017-12-20 11:46:04 -08:00
Moxie Marlinspike
6dcec7c2c5 Fix service calls that won't foreground 2017-12-20 11:27:57 -08:00
Moxie Marlinspike
512dc19471 Fix dynamic permissions problem for MMS messages 2017-12-20 11:21:00 -08:00
Moxie Marlinspike
425d6b8adf Fix crash for dynamic permissions + background directory load 2017-12-20 11:10:12 -08:00
Moxie Marlinspike
81cd20062c Bump version to 4.14.9 2017-12-19 14:48:40 -08:00
Moxie Marlinspike
4acedd2a4b Fix notification ringtone problems
Default ringtone was often showing up as a call tone

Silent wasn't working correctly globally
2017-12-19 14:42:00 -08:00
Moxie Marlinspike
d782d3006b Per-recipient ringtones can't be file based 2017-12-19 11:01:55 -08:00
Moxie Marlinspike
9c77ffc2a4 The webrtc busy state could be idle, but system dialer connected 2017-12-19 10:57:34 -08:00
Moxie Marlinspike
0ec1ae4ed3 Request needed permissions for thread search 2017-12-19 10:54:06 -08:00
Moxie Marlinspike
6d7553563f Bump version to 4.14.8 2017-12-16 10:54:29 -08:00
Moxie Marlinspike
f22186e6f4 Debounce call screen answer button
Fixes #7274
2017-12-15 15:27:23 -08:00
Moxie Marlinspike
4de14a5dc1 Only use startForegroundService for initial service construction 2017-12-15 09:45:00 -08:00
Moxie Marlinspike
71727e1474 Bump version to 4.14.7 2017-12-13 10:30:01 -08:00
Moxie Marlinspike
f72e35bf42 Fix typo that requests SMS permission for media/group message
Fixes #7271
2017-12-13 10:29:19 -08:00
Moxie Marlinspike
a8040b00cf Bump version to 4.14.6 2017-12-12 11:17:24 -08:00
Moxie Marlinspike
303b98b7c2 Register and unregister receiver with same context
Fixes #7267
2017-12-12 11:16:40 -08:00
Moxie Marlinspike
13434d620c Bump version to 4.14.5 2017-12-11 09:56:15 -08:00
Moxie Marlinspike
d5215b3593 Avoid potentially unregistering bluetooth twice 2017-12-11 09:52:03 -08:00
Moxie Marlinspike
62489846e3 Bump version to 4.14.4 2017-12-08 15:22:08 -08:00
Moxie Marlinspike
f315b1db80 Make save attachment task toast location instead of snackbar 2017-12-08 15:21:46 -08:00
Moxie Marlinspike
f100137e0f Synchronize and copy Recipient.getParticipants 2017-12-08 14:38:01 -08:00
Moxie Marlinspike
37092eee01 Externalize strings 2017-12-08 14:36:56 -08:00
Moxie Marlinspike
261d187567 Don't perform multi-device contact update without contact perms 2017-12-08 14:36:36 -08:00
Moxie Marlinspike
907a1767f4 Bump version to 4.14.3 2017-12-07 11:58:44 -08:00
Moxie Marlinspike
bf70f830f3 Update language translations 2017-12-07 11:58:11 -08:00
Moxie Marlinspike
b58c87a56b Only notify when address is in contacts 2017-12-07 11:53:17 -08:00
Moxie Marlinspike
27d3dc918e s/External Storage/Storage 2017-12-06 11:59:29 -08:00
Moxie Marlinspike
7ba0f4b279 Bump version to 4.14.2 2017-12-05 12:08:51 -08:00
Moxie Marlinspike
23e9b3a61e Fix colors in all images toolbar
Fixes #7242
2017-12-05 12:07:37 -08:00
Moxie Marlinspike
06e0d7d72d Appease the linter 2017-12-05 11:52:03 -08:00
Moxie Marlinspike
27e11e9627 Make sure we have SEND_SMS permission before sending an SMS
Fixes #7246
2017-12-05 11:35:15 -08:00
Moxie Marlinspike
8686691a5a Fix missing recipient calculation for system contact
Fixes #7244
2017-12-05 10:27:34 -08:00
Moxie Marlinspike
8b3a3d163f Don't check subscription info on dual sim devices wihout permission
Fixes #7239
2017-12-02 12:23:14 -08:00
Moxie Marlinspike
6d0b8bd737 Bump version to 4.14.1 2017-12-01 14:05:50 -08:00
Moxie Marlinspike
53e87562c1 Updated language translations 2017-12-01 14:05:21 -08:00
Moxie Marlinspike
02c422cb26 Some old group avatar IDs can be 0
Fixes #7235
2017-12-01 13:56:56 -08:00
Moxie Marlinspike
3523952ef9 As of 'N' we can no longer offer external ringtone selection
1. Replace custom ringtone picker with system Intent, since we
   don't need it anymore. Fixes #7174

2. Make sure 'silent' ringtone selection is stored appropriately
   Fixes #7115 Closes #7141

3. Replace any existing file:// notification URIs with the system
   default Fixes #7234
2017-12-01 12:55:24 -08:00
Moxie Marlinspike
4cb2ac7b27 Use FileProvider for external camera capture Uri on L+
Fixes #7237
2017-12-01 11:06:37 -08:00
Moxie Marlinspike
4932171bbf Bump version to 4.14.0 2017-11-30 14:25:06 -08:00
Moxie Marlinspike
81c7cb1a87 Updated language translations 2017-11-30 14:24:54 -08:00
Moxie Marlinspike
2b80e98bf1 Update dockerfile 2017-11-30 14:06:21 -08:00
Moxie Marlinspike
8cd5ff5fa1 Mark directory retrieved on registered update 2017-11-30 13:30:15 -08:00
Moxie Marlinspike
6f10de5e30 Fix trying to launch a dialog from an application context 2017-11-30 13:05:16 -08:00
Moxie Marlinspike
c58d5c32bb Remove request for permission that doesn't exist < O 2017-11-30 13:04:11 -08:00
scienmind
7b2b5742c7 Update readme.md and contributing.md to use signal.org URLs
Closes #7217
2017-11-30 11:05:16 -08:00
Moxie Marlinspike
0dbcb1a49b Support for adaptive icons
Closes #6887
Fixes #6511
2017-11-30 10:59:10 -08:00
Moxie Marlinspike
e7a9893e94 Fix string typo 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
0f35bc6fd9 Increase targetSdkVersion to 25 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
acfc9d75e0 Use startForegroundService instead of startService on Android 8 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
d9ab1a93f8 Fix problem with creating group and empty avatar 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
c2dbb34b25 Extract string resource 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
ed508a8def Be more explicit with mastersecret passing 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
d5cb804f90 Switch from PACKAGE_REPLACED to MY_PACKAGE_REPLACED
As part of the Oreo 'no more implicit intents' thing
2017-11-30 10:26:41 -08:00
Moxie Marlinspike
c8104a91a4 Remove dead code 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
4c8e259b56 Update compileSdk to 27 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
7a5846a6d4 Move more system contact info into recipient database
1) Move contact URI, contact photo URI, and custom label
   into recipient database, so there are no longer any
   contact DB queries during Recipient object loading.

2) Use a SoftHashMap so that any referenced Recipient objects
   can't get kicked out of the cache.

3) Don't load Recipient objects through the provider during sync.
   This was a super expensive thing to do, and blew up the cache.

4) Only apply changes to Recipient objects during sync if they
   are in the cache. Otherwise, there should be no outstanding
   references, and the changes are fine going exclusively to
   the DB.
2017-11-30 10:26:41 -08:00
Moxie Marlinspike
64c8b4b2ef Support for selective permissions 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
99a26e2bcc Don't invalidate entire recipient cache when contact data changes 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
886298674e Adjust inbox zero empty state 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
e9a82502b9 Fix up converstion list empty state look 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
f855e161d9 Ensure notifications for new users won't be generated first fetch 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
66e1be1aeb Don't invalidate entire recipient cache when contact data changes 2017-11-30 10:26:41 -08:00
Moxie Marlinspike
8f6440ce17 Bump version to 4.13.7 2017-11-29 21:56:25 -08:00
Moxie Marlinspike
73c75a9b34 Don't delete GCM id during registration if it never existed
Fixes #7229
2017-11-28 14:33:22 -08:00
Moxie Marlinspike
f916dcd5de Bump version to 4.13.6 2017-11-27 09:48:56 -08:00
Moxie Marlinspike
1ea913cea6 Updated language translations 2017-11-27 09:48:47 -08:00
Moxie Marlinspike
a350106f7d Don't check DB workaround if push group
Fixes #7225
2017-11-27 09:44:50 -08:00
Moxie Marlinspike
17f8a81a56 Bump version to 4.13.5 2017-11-25 09:52:59 -08:00
Moxie Marlinspike
7eb089c9de Temporary fix for Signal contact displaying as SMS for N seconds
The whole recipient pipeline needs to be changed more subsantially,
particularly given the way directory discovery works with it. This
will temporarily solve the problem though.
2017-11-25 09:50:36 -08:00
Moxie Marlinspike
6ff0a62338 Bump version to 4.13.4 2017-11-20 19:13:13 -08:00
Moxie Marlinspike
ba5febd222 Fix some emoji rendering issues related to obsolete images
1) The "obsolete" images like "swimmer" need to alias to
"man_swimming" so that they can be rendered correctly.

2) There are a whole bunch of emoji-data elements
(like white_frowning_face) that have "unified" code points which
have changed to include a "terminator."

Fixes #7212
2017-11-20 19:11:26 -08:00
Moxie Marlinspike
e1026785f7 Bump version to 4.13.3 2017-11-20 11:22:29 -08:00
Moxie Marlinspike
9004474748 Updated language translations 2017-11-20 11:21:57 -08:00
Moxie Marlinspike
c1b2098bd9 Fix race condition that would display end call button over answer
Fixes #7211
2017-11-20 11:17:50 -08:00
Moxie Marlinspike
efb9ba6496 Bump version to 4.13.2 2017-11-19 18:48:20 -08:00
Moxie Marlinspike
19d49ed281 Add slight drop shadow to slide up / slide down answer button text 2017-11-19 18:47:24 -08:00
Moxie Marlinspike
4ecb65a262 Lighten conversation list item dividers in light theme 2017-11-19 18:39:32 -08:00
Moxie Marlinspike
d3c72fa697 Avoid green background on item below archived conversation list item 2017-11-19 18:34:03 -08:00
Moxie Marlinspike
80042ae3aa Display action mode over toolbar
Fixes #7198
2017-11-19 18:19:01 -08:00
Moxie Marlinspike
58f1e68961 Update emoji
Fixes #6637
Fixes #7206
2017-11-19 18:11:25 -08:00
Moxie Marlinspike
be6a51b123 Hide photo/mic options on whitespace entry
Fixes #7204
2017-11-19 16:53:12 -08:00
Moxie Marlinspike
08c72ed874 Don't show group ID in recent contact selection list
Fixes #7201
2017-11-19 16:46:12 -08:00
Moxie Marlinspike
86bd2351bc Replace answer/decline button and action for incoming calls
Fixes #7199
2017-11-19 16:32:22 -08:00
Moxie Marlinspike
e14a97cf68 Bump version to 4.13.1 2017-11-16 15:34:29 -08:00
Moxie Marlinspike
cf81815bf6 Add recent chats to top of share list 2017-11-16 15:21:46 -08:00
Moxie Marlinspike
c5a9f27c31 Catch some activity not found exceptions for expired builds 2017-11-16 12:31:42 -08:00
Moxie Marlinspike
de812d3f0f Extract string resources 2017-11-16 12:28:29 -08:00
Moxie Marlinspike
e31ce39967 Fix background on attachment manager 2017-11-16 12:26:23 -08:00
Moxie Marlinspike
2da47c3bb3 Fix share list crash and update look/feel
Fixes #7195
2017-11-16 12:22:09 -08:00
Moxie Marlinspike
0960ff1fa9 Bump version to 4.13.0 2017-11-15 16:38:07 -08:00
Moxie Marlinspike
749eeb87b2 Update language translations 2017-11-15 16:37:58 -08:00
Moxie Marlinspike
e37c06c563 Show dialog if another device registered with same number 2017-11-15 16:29:00 -08:00
Moxie Marlinspike
909c0c544c Make sure thread preview text is to left of unread indicator 2017-11-15 15:49:45 -08:00
Moxie Marlinspike
40004b5be3 Updated language translations 2017-11-14 20:52:58 -08:00
Moxie Marlinspike
b42e91134b Remove inset divider from last recyclerview element 2017-11-14 12:09:19 -08:00
Moxie Marlinspike
682abbf66b Add unread count to synthesized cursor 2017-11-14 11:47:15 -08:00
Moxie Marlinspike
1986e58c5f Remove unused resources
According to Android Studio
2017-11-14 11:43:25 -08:00
Moxie Marlinspike
b88069f396 Revert "Remove unused resources"
AS seems to have miscalculated

This reverts commit 344af622b7.
2017-11-14 11:29:20 -08:00
Moxie Marlinspike
344af622b7 Remove unused resources
Or so says Android Studio
2017-11-14 11:15:03 -08:00
Moxie Marlinspike
ad9a995ffa Correctly display cropped profile image
Fixes #7191
2017-11-14 10:50:17 -08:00
Moxie Marlinspike
21ddc1dbba Fix profile crash
Fixes #7192
2017-11-14 10:50:17 -08:00
Moxie Marlinspike
534dec282f Brighten light theme
1) Brighten background color

2) Add unread indicator in conversation list

3) Eliminate some conversation list overdraw
2017-11-14 10:50:17 -08:00
Moxie Marlinspike
03573df00f Add inset dividers in conversation list
Closes #7074
2017-11-14 10:50:17 -08:00
Moxie Marlinspike
6b94d0679c Remove unused resource 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
1cee253b41 Fix contact list search cursor color 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
40caf20188 Make sure nav drawable is mutable before tinting 2017-11-14 10:50:17 -08:00
Nicholas Rizzio
99ea6f9812 Remove the last references to BitHub and Coinbase
Closes #7176
2017-11-14 10:50:17 -08:00
Moxie Marlinspike
405ee3b741 Improve search bar visibility 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
9a75f49aa1 Add an empty state for search 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
9c50057909 Add an empty state for archived 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
bb878f8a67 Adjust Conversation List toolbar to match RecyclerView alignment 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
3097c2855e Add empty state for conversation list 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
90ff0e58b0 Update registration flow 2017-11-14 10:50:17 -08:00
Moxie Marlinspike
e56e55363d Add some debug logging 2017-11-14 10:49:54 -08:00
Moxie Marlinspike
50ae2dd1b8 Fix multi device race condition
Fixes #7175
2017-11-12 13:54:37 -08:00
Moxie Marlinspike
60f4e245e9 Bump version to 4.12.3 2017-11-06 15:53:01 -08:00
Moxie Marlinspike
9c1e846049 Update circular progress button dep to be compat w/ build tools 2017-11-06 15:52:18 -08:00
Moxie Marlinspike
0593de85df Update Dockerfile to support new build tools 2017-11-06 09:25:07 -08:00
Moxie Marlinspike
e245281b69 Update Android plugin to 3.0.0 2017-11-06 09:20:52 -08:00
Moxie Marlinspike
ad6ae10a41 Fix scaling issue when loading emoji sprites
Fixes #5973
// FREEBIE
2017-11-06 08:11:36 -08:00
Moxie Marlinspike
1c680a2c64 Update libwebrtc to M63
// FREEBIE
2017-11-03 18:01:18 -07:00
Moxie Marlinspike
648b2f24f6 Bump version to 4.12.2
// FREEBIE
2017-11-03 12:56:11 -07:00
Moxie Marlinspike
42ef64aebe Updated language translations
// FREEBIE
2017-11-03 12:55:45 -07:00
Moxie Marlinspike
9f0252dfb9 Update domain fronting cert store with new Google roots
// FREEBIE
2017-11-03 12:05:57 -07:00
Moxie Marlinspike
bcdf3bf311 Fix for scribbles on Android 8
Fixes #6998
// FREEBIE
2017-11-03 11:32:18 -07:00
Moxie Marlinspike
3e9bfcb3fd Delete "external" persistent blobs on cleanup
Also switch external persistent blog directory to cache

Fixes #6909
// FREEBIE
2017-11-03 10:53:37 -07:00
Moxie Marlinspike
3ed82c1726 Glide -> glideRequests in GiphyAdapter
// FREEBIE
2017-11-02 18:12:06 -07:00
Moxie Marlinspike
90203e4872 Bump version to 4.12.1
// FREEBIE
2017-11-01 15:57:00 -07:00
Moxie Marlinspike
d93ba54f0e Bump version to 4.12.0
// FREEBIE
2017-11-01 15:56:55 -07:00
Moxie Marlinspike
f4e8ecf740 Update Dockerfile for compileSdk 26
// FREEBIE
2017-11-01 15:56:49 -07:00
Christian Ascheberg
69e656af76 Add back a way to access quick contact from conversation
Closes #7051
// FREEBIE
2017-11-01 15:56:46 -07:00
Greg Cooksey
23a23ebd72 CreateProfileActivity uses DynamicTheme
Fixes #6981
Closes #6997
// FREEBIE
2017-11-01 15:56:46 -07:00
Christian Ascheberg
fdd070c1dd Do not show sent checkmark for verification status changes
Fixes #6743
Closes #7041
// FREEBIE
2017-11-01 15:56:46 -07:00
Nicholas Rizzio
0ab9b56a18 Add a space between group member names
Fixes #7059
Closes #7060
// FREEBIE
2017-11-01 15:56:46 -07:00
haffenloher
3df9112cf8 Fix synced sent media messages expiring too fast
Fixes #6928
Closes #7135
2017-11-01 15:56:46 -07:00
Moxie Marlinspike
9a8d058051 Update to glide 4.3.0
// FREEBIE
2017-11-01 15:56:44 -07:00
Moxie Marlinspike
6d88710a88 Update to libsignal-service 2.6.11
// FREEBIE
2017-11-01 15:56:31 -07:00
Moxie Marlinspike
e056bd1aa2 Update giphy connectivity strategy for glide
// FREEBIE
2017-11-01 15:51:38 -07:00
Moxie Marlinspike
e7937fd424 Cache external address formatter for better performance
// FREEBIE
2017-10-11 17:47:12 -07:00
Moxie Marlinspike
b80408bcb4 Use Glide for all contact photo caching
// FREEBIE
2017-10-11 17:47:12 -07:00
Moxie Marlinspike
10f224ede5 Update to glide 4.x
// FREEBIE
2017-10-11 17:47:12 -07:00
Moxie Marlinspike
17dd681dc8 Run all AsyncTasks on thread pool executor
Should Fix #7002
2017-10-23 13:03:32 -07:00
Moxie Marlinspike
263846bba0 Fix mms group migration for those who haven't encountered it yet
Fixes #7091
// FREEBIE
2017-10-23 09:52:34 -07:00
Moxie Marlinspike
0bcf46bacd Remove lingering bithub reference 2017-10-18 12:39:33 -07:00
Moxie Marlinspike
4bf91aa86a Bump version to 4.11.5
// FREEBIE
2017-10-16 11:04:26 -07:00
Moxie Marlinspike
7a8bd0597a Correctly load group avatars in RecipientPreferencesActivity
Fixes #7102
// FREEBIE
2017-10-16 10:16:15 -07:00
Moxie Marlinspike
e87aa85bae Bump version to 4.11.4
// FREEBIE
2017-10-15 10:12:39 -07:00
Moxie Marlinspike
5711adb2c9 Fix profile out of memory errors on low mem devices
Fixes #7094
// FREEBIE
2017-10-15 10:00:03 -07:00
Moxie Marlinspike
4bd3094bad Fix problem where recycled group avatar icons have stale listener
Fixes #7089
// FREEBIE
2017-10-13 09:51:37 -07:00
Moxie Marlinspike
671023d0c8 Bump version to 4.11.3
// FREEBIE
2017-10-10 10:05:19 -07:00
Moxie Marlinspike
afa0807827 Updated language translations
// FREEBIE
2017-10-10 10:04:45 -07:00
Moxie Marlinspike
4e45d53bd9 Scroll on list post
Fixes #7054

// FREEBIE
2017-10-10 10:00:24 -07:00
Moxie Marlinspike
d40fea9423 Catch Glide exception when loading avatar image
Workaround for #7016
// FREEIBE
2017-10-10 09:18:00 -07:00
Moxie Marlinspike
c15d1a3bce Update pipe when injecting message sender
// FREEBIE
2017-10-10 09:14:53 -07:00
Moxie Marlinspike
77c232760c No documents found -> No documents
// FREEBIE
2017-10-09 10:38:36 -07:00
Moxie Marlinspike
655be5adf4 Fix RingtoneManager cursor crash on some devices
Fixes #7055
// FREEBIE
2017-10-08 18:46:09 -07:00
Moxie Marlinspike
445f3c234c Connect "mark all read" to sync and read receipts
Fixes #7069
// FREEBIE
2017-10-08 18:09:46 -07:00
Moxie Marlinspike
5be1a5e3d5 Fix "no media" text alignment in conversation gallery
Fixes #7066
// FREEBIE
2017-10-08 17:46:35 -07:00
Moxie Marlinspike
a382694b1f Don't hide keyboard when back arrow tapped in Conversation Activity
Fixes #7065
// FREEBIE
2017-10-08 17:44:18 -07:00
Moxie Marlinspike
12020a3f86 Fix vector drawable problems < Android 5.0
Fixes #7056
// FREEBIE
2017-10-08 17:42:45 -07:00
Moxie Marlinspike
9fa4ba126b Fix non-collapsing layout when scrolled from horiz recyclerview
Fixes #7042
// FREEBIE
2017-10-08 17:36:35 -07:00
Moxie Marlinspike
5a607918d2 Name message retrieval service thread
// FREEBIE
2017-10-08 11:34:24 -07:00
Moxie Marlinspike
d0570ef7cb Fix media preview crash
Fixes #7050
// FREEBIE
2017-10-05 17:20:28 -07:00
Moxie Marlinspike
d24fb8c855 Bump version to 4.11.2
// FREEBIE
2017-10-04 15:25:11 -07:00
Moxie Marlinspike
ac282ccf70 Display contact color in background for generated avatars
Fixes #7028
// FREEBIE
2017-10-04 15:24:04 -07:00
Moxie Marlinspike
42f613e722 Be more explicit with running on main thread
// FREEBIE
2017-10-04 14:56:31 -07:00
Moxie Marlinspike
99b2149deb Fixed avatar icons not rendering in contact selection view
// FREEBIE
2017-10-04 14:47:29 -07:00
Moxie Marlinspike
0a3ede7c32 Fix expiring messages timer colors in dark theme
Fixes #5759
// FREEBIE
2017-10-04 14:08:56 -07:00
Moxie Marlinspike
5ad7e3b48a Make avatar in conversation activity tappable
Fixes #7025
// FREEBIE
2017-10-04 14:04:04 -07:00
Moxie Marlinspike
5270dad789 Fix screen security preference migration
// FREEBIE
2017-10-04 12:37:53 -07:00
Moxie Marlinspike
10e305d204 Remove elevation
Helps #6894

// FREEBIE
2017-10-04 12:35:17 -07:00
Moxie Marlinspike
cee3858e2e Fix mysteriously missing string content
// FREEBIE
2017-10-04 12:27:45 -07:00
Moxie Marlinspike
b430be9759 Fix color for shared media in dark theme
ugh dark theme

Fixes #7024
// FREEBIE
2017-10-04 12:26:03 -07:00
FeuRenard
d71fb4c958 Adjust dark themed NoActionBar activities
// FREEBIE
2017-10-04 11:50:55 -07:00
Veeti Paananen
eb456ef2b0 Fix implicit locale string formatting bugs
Depending on the phone language the default format may use Arabic
numerals, etc. when not desired.

Bug: fixes #7006
Closes #7040
2017-10-04 11:36:43 -07:00
Moxie Marlinspike
9a876a3672 Show "you" in MediaPreviewActivity
Fixes #7038
// FREEBIE
2017-10-04 11:35:16 -07:00
Moxie Marlinspike
677c7732cf Update incognito keyboard string
Fixes #7037
// FREEBIE
2017-10-04 11:21:03 -07:00
Moxie Marlinspike
4ebf97550c Fix unlocked icon color in dark theme
Fixes #7036
// FREEBIE
2017-10-04 11:15:02 -07:00
Moxie Marlinspike
8a99d9b126 Bump version to 4.11.1
// FREEBIE
2017-10-03 19:11:25 -07:00
Moxie Marlinspike
4dfaec977f Fix string reference
// FREEBIE
2017-10-03 19:11:02 -07:00
Moxie Marlinspike
ba849bce2c Add support for incognito keyboard preference
Closes #6985
// FREEBIE
2017-10-03 18:57:23 -07:00
Moxie Marlinspike
5de89d4f26 Correctly disable preferences in group conversation preferences
Fixes #7031
// FREEBIE
2017-10-03 17:05:52 -07:00
Moxie Marlinspike
b7340cc356 Don't show voice notes in conversation documents overview
Fixes #7029
// FREEBIE
2017-10-03 16:43:31 -07:00
Moxie Marlinspike
b3147aad55 Make "Shared media" string translatable
// FREEBIE
2017-10-03 16:29:11 -07:00
Moxie Marlinspike
9287b00317 Make conversation settings menu item work
Fixes #7023
// FREEBIE
2017-10-03 16:27:12 -07:00
Moxie Marlinspike
d7d6f38cb6 Enable censorship circumvention in Qatar
// FREEBIE
2017-10-03 14:08:41 -07:00
Moxie Marlinspike
b34eb08088 Fix look of default group photo in conversation preferences view
Fixes #7022
// FREEBIE
2017-10-03 14:01:02 -07:00
Moxie Marlinspike
9389fe47bd Fix call screen FAB being off-center
Fixes #7021
// FREEBIE
2017-10-03 13:32:08 -07:00
Moxie Marlinspike
a929bf91f1 Show profile name in call screen
Fixes #7020
// FREEBIE
2017-10-03 13:29:49 -07:00
Moxie Marlinspike
04fcb9c531 Bump version to 4.11.0
// FREEBIE
2017-10-03 10:43:13 -07:00
Moxie Marlinspike
c09d2951b1 Fix preference compat crash
Fixes #7018
// FREEBIE
2017-10-03 10:43:06 -07:00
Moxie Marlinspike
2c1337b33e Make early receipts work in group messages
For both conversation item view and message details view

// FREEBIE
2017-10-02 14:54:55 -07:00
Moxie Marlinspike
856a4d2860 Process configuration request messages
// FREEBIE
2017-10-02 12:39:44 -07:00
Moxie Marlinspike
b3f0888a2e Synchronize read receipt configuration from splash screen
// FREEBIE
2017-10-02 12:15:45 -07:00
Moxie Marlinspike
e388524a2f Update Dockerfile
// FREEBIE
2017-10-02 11:56:55 -07:00
Moxie Marlinspike
edc00d858b Updated language translations
// FREEBIE
2017-10-02 11:20:16 -07:00
Moxie Marlinspike
182d571e1b Fix experience upgrade strings for notification
// FREEBIE
2017-10-02 10:45:43 -07:00
Moxie Marlinspike
e145875164 Fix json serialization for group message error
Fixes #6919
// FREEBIE
2017-10-02 10:35:49 -07:00
Moxie Marlinspike
2e56a0aa70 Fix typo
// FREEBIE
2017-10-02 09:58:08 -07:00
Moxie Marlinspike
4c2269175b Improve profile upload animation
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
893cf9c01d Add support for setting empty profile names
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
285947eb66 Show per-member delivery/read status on message info in groups
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
2b4064f3b7 Add splash screen for read receipts
// FREEBIE
2017-10-01 22:36:52 -07:00
Brian St. Pierre
6e6bfaa932 set MMS default characterset to utf-8.
Fixes #6374
Closes #6965
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
8d08f3969a Switch from secure indicator to insecure indicator
Instead of cluttering Signal messages with a little padlock,
let's highlight the insecurity of SMS messages instead.

// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
8ce914a344 Refactor media overview activity to display documents
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
c6b2e785a5 Reorganize conversation media activity to have sticky headers
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
5189fbf686 Bump minSdk to API 14
The Android v4 and v7 support libraries now only support a minSdk
of v14. This means that they are both essentially a v14 support
library now.

In order to bump compileSdk to 26, we'll have to update the support
library, which will break < v14 compatibility. Android is
essentially forcing all applications to break compatibility with
devices older than API 14.

// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
b47665aa44 Fix migration typo
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
d0e781ccb4 Sync read receipt configuration to sibling devices
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
e5e0bc2333 Reorganize preference widgets
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
4828a8a274 Add conversation media photo rail to recipient preferences
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
a1c276f70b Update to V7 PreferencesCompat library
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
cb9bc9659b Support for read receipts
// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
65124fd1f2 Redesign conversation and conversation preferences layouts
Remove avatars from conversation items unless in a group chat.

// FREEBIE
2017-10-01 22:36:52 -07:00
Moxie Marlinspike
30916d8e19 Bump version to 4.10.12
// FREEBIE
2017-09-25 09:33:02 -07:00
Moxie Marlinspike
009c01fd7e Move experience upgrade after passphrase and registration
// FREEBIE
2017-09-25 09:32:44 -07:00
Moxie Marlinspike
a39d9bf132 Fix for RTL layout detection crash on < API 17
Fixes #6987
// FREEBIE
2017-09-25 09:05:41 -07:00
Moxie Marlinspike
185d22809e Bump version to 4.10.11
// FREEBIE
2017-09-19 11:03:53 -07:00
Moxie Marlinspike
74779adc34 Use correct open helper for old directory database
// FREEBIE
2017-09-19 11:03:18 -07:00
Moxie Marlinspike
b5ad2fc744 Bump version to 4.10.10
// FREEBIE
2017-09-15 10:37:04 -07:00
Moxie Marlinspike
260383ac21 Fix problem with direct share
Fixes #6968
// FREEBIE
2017-09-15 10:36:33 -07:00
Moxie Marlinspike
b6aedd330e Disable signal messaging if unregistered
Fixes #6963
// FREEBIE
2017-09-14 16:46:12 -07:00
Moxie Marlinspike
989ec6a40a Bump version to 4.10.9
// FREEBIE
2017-09-13 17:26:56 -07:00
Moxie Marlinspike
c7e972026c Updated language translations
// FREEBIE
2017-09-13 17:26:43 -07:00
Moxie Marlinspike
5a0f671aa4 Fix not sending group info request messages
Fixes #6962
// FREEBIE
2017-09-13 17:19:59 -07:00
Moxie Marlinspike
b7109e9ebb Fix for NPE if MMS notification has no transaction ID
// FREEBIE
2017-09-13 16:38:02 -07:00
Moxie Marlinspike
93395c3ff4 Include own profile key in normal contact sync
// FREEBIE
2017-09-12 22:49:30 -07:00
Moxie Marlinspike
2e5b0bcee2 Bump version to 4.10.8
// FREEBIE
2017-09-11 14:18:17 -07:00
Moxie Marlinspike
40d7826fb9 Fix <= KitKat bug that prompts for MMS configuration
Fixes #6954
2017-09-11 13:04:20 -07:00
Moxie Marlinspike
77fb541090 Bump version to 4.10.7
// FREEBIE
2017-09-10 11:48:57 -07:00
Moxie Marlinspike
0f65bf08b8 Align info graphic with text
Fixes #6949
// FREEBIE
2017-09-10 11:48:27 -07:00
Moxie Marlinspike
962944a974 Add some annotations
// FREEBIE
2017-09-10 11:21:51 -07:00
Moxie Marlinspike
08948fe05a Don't create groups for 1:1 MMS conversations
Fixes #6947
// FREEBIE
2017-09-10 11:13:53 -07:00
Moxie Marlinspike
f3d943270c Be more conservative with handlers and references
Expiring message timers could end up leaking references and
executing work even after their conversation item was no longer
visible

Maybe fixes #6898

// FREEBIE
2017-09-09 23:46:48 -07:00
Moxie Marlinspike
6a10c69df8 Bump version to 4.10.6
// FREEBIE
2017-09-08 11:49:26 -07:00
Moxie Marlinspike
f335a65d32 Stop Thread.interrupt() from being called
// FREEBIE
2017-09-08 11:48:44 -07:00
Moxie Marlinspike
79a88f378b Avoid NPE if capture file isn't available
// FREEBIE
2017-09-08 11:38:07 -07:00
Moxie Marlinspike
afed60f870 Handle recipient modification callbacks on main thread
// FREEBIE
2017-09-08 11:36:09 -07:00
Moxie Marlinspike
989ea4042c MMS group includes the sender
Fixes #6942
// FREEBIE
2017-09-08 11:19:57 -07:00
Moxie Marlinspike
0bd9606666 Bump version to 4.10.5
// FREEBIE
2017-09-07 20:45:26 -07:00
Moxie Marlinspike
5173921ce0 Fix bad MMS group creation logic
Fixes #6939
Fixes #6938

// FREEBIE
2017-09-07 20:41:34 -07:00
Moxie Marlinspike
032eaa4389 Fix crash on conversation list search
Fixes #6936
// FREEBIE
2017-09-07 13:52:58 -07:00
Moxie Marlinspike
962fb60ffb Don't synchronize MMS groups to sibling devices
Fixes #6934
// FREEBIE
2017-09-07 11:12:57 -07:00
Moxie Marlinspike
6d1f4bc2f0 Bump version to 4.10.4
// FREEBIE
2017-09-06 17:59:20 -07:00
Moxie Marlinspike
844ffdad54 Add padding to finish button for non-english languages
Fixes #6930
// FREEBIE
2017-09-06 17:58:01 -07:00
Moxie Marlinspike
6455c66a0b Fix bug that prevented selecting insecure SMS
Fixes #6929

// FREEBIE
2017-09-06 17:54:32 -07:00
Moxie Marlinspike
af265bc3c2 Bump version to 4.10.3
// FREEBIE
2017-09-06 16:16:51 -07:00
Moxie Marlinspike
2890490ab4 Support cameras that don't return data intent
Fixes #6926

// FREEBIE
2017-09-06 16:16:01 -07:00
Moxie Marlinspike
bcff186b10 Add self to MMS groups when migrating
Fixes #6925
// FREEBIE
2017-09-06 16:08:20 -07:00
Moxie Marlinspike
967c374213 Display error when camera doesn't return image
Partial #6926
// FREEBIE
2017-09-06 16:03:08 -07:00
Moxie Marlinspike
e172b84603 Fix crash on displaying unknown contact header
Fixes #6924

// FREEBIE
2017-09-06 15:49:10 -07:00
Moxie Marlinspike
bdb67725c5 Add additional debug information for mysterious stack trace
Related #6923

// FREEBIE
2017-09-06 13:56:09 -07:00
Moxie Marlinspike
d6aeeaef2c Bump version to 4.10.2
// FREEBIE
2017-09-06 10:55:04 -07:00
Moxie Marlinspike
612ad49a8b Updated language translations
// FREEBIE
2017-09-06 10:54:27 -07:00
Moxie Marlinspike
29b561fe41 Fix group conversation items glitching to use conversation recipient
// FREEBIE
2017-09-06 10:31:48 -07:00
Moxie Marlinspike
56c720cd4f Bump version to 4.10.1
// FREEBIE
2017-09-06 00:30:50 -07:00
Moxie Marlinspike
19be527370 Fix recursive experience upgrade activity problem
// FREEBIE
2017-09-06 00:29:49 -07:00
Moxie Marlinspike
efc4a5ab9d Fix problem with prefetched recipient details
Don't use a cached recipient if we have a prefetched recipient
detail object and the cached recipient is still in progress
and without a name

// FREEBIE
2017-09-06 00:11:11 -07:00
Moxie Marlinspike
79f8cf8e35 Bump version to 4.10.0
// FREEBIE
2017-09-05 22:16:13 -07:00
Moxie Marlinspike
26c7a68a66 Updated language translations
// FREEBIE
2017-09-05 22:15:05 -07:00
Moxie Marlinspike
7197d513a3 Add target for 'who can see this' profile link
// FREEBIE
2017-09-05 12:52:50 -07:00
Moxie Marlinspike
5cccea5846 Revert "Change default charset to UTF-8"
This reverts commit 86eb14b7bb.
2017-09-05 12:43:21 -07:00
Moxie Marlinspike
258910504c BH seems to be broken.
Wasn't really ever super effective or useful in the end anyway.
2017-09-04 14:59:51 -07:00
Christian Bundy
86eb14b7bb Change default charset to UTF-8
This resolves #6374 where the character set is set to
`CharacterSets.MIMENAME_ANY_CHARSET` but the character set being
 used is _actually_ UTF-8.

Fixes #6374
Closes #6892
2017-09-04 14:58:25 -07:00
Moxie Marlinspike
2add02c62f Add splash screen for setting profiles
// FREEBIE
2017-09-03 19:45:43 -07:00
Moxie Marlinspike
3e3ae5f865 Adjust profile key sharing based on sync messages
// FREEBIE
2017-08-28 17:57:07 -07:00
Moxie Marlinspike
62c738ee58 Update libsignal-service to 2.6.5
// FREEBIE
2017-08-28 17:56:49 -07:00
jdaminato94
6945ecf81d Keep screen on when viewing a video
Fixes #6642
Closes #6837

// FREEBIE
2017-08-28 10:45:32 -07:00
Markus Brenneis
66062f200a Work around SmsMessage.calculateLength NPE on broken ROMs
//FREEBIE
2017-08-28 10:43:14 -07:00
marcoscezar
37a5622525 Display appropriate registration error msg w/ bad verification code
Fixes #6551
2017-08-28 10:38:35 -07:00
Moxie Marlinspike
d0cd2621ca Only process messages if a body is present
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
51c1e4485f Support for profile key syncing to sibling devices
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
beed9d8034 Add length limit feedback when setting profile name
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
3e22c37425 Allow conversation subtitle to support emoji
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
638a9576f8 Add censorship circumvention endpoints for CDN
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
6bfe05323e Update recipient preference style
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
64ad9ec9dd Add group profile sharing logic
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
f17af19d09 Access all RecipientDatabase settings directly from Recipient
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
d1790dfe17 Rename RecipientPreferences -> RecipientSettings
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
8e6ca53023 Rename RecipientPreferencesDatabase -> RecipientDatabase
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
6924f0519e No need for a RecipientFactory any longer
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
6af836735b Remove unnecessary logging
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
1252b3ca00 Don't display unknown sender footer for group messages
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
1b2f52209d Display unknown sender footer for unknown senders
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
5942e93a33 Share profile key when initiating a conversation
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
c11f2eddf5 Display user profile information in settings activity
Allow for editing

// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
df99deb480 Insert profile creation into registration flow, fix capture
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
e7c20499ec Display profile name in when appropriate
Display in conversation list, conversation actionbar, group
messages, and group members list when address is not in system
contacts

// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
77a216b705 Support for retrieving and storing profile information
Initial support for sharing profile keys

// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
1893047a78 Profile creation activity
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
da94fd5f9e Join group information into conversation list query
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
159fdb317f Store system contacts display name in recipient preferences db
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
f61c52aace Consolidate user "capability" enums to a single value
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
5a5e47f2df Move "directory" information into RecipientPreferencesDatabase
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
a02f223a96 Join recipient preferences into thread query for faster lookup
// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
375207f073 Switch MMS groups to use the group database infrastructure
Eliminate the concept of 'Recipients' (plural). There is now just
a 'Recipient', which contains an Address that is either an individual
or a group ID.

MMS groups now exist as part of the group database, just like push
groups.

// FREEBIE
2017-08-28 10:30:50 -07:00
Moxie Marlinspike
81682e0302 Bump version to 4.9.9
// FREEBIE
2017-08-23 10:46:41 -07:00
mcloo
60eaade6b0 Fix plaintext export XML name escaping
Fixes #6830
Closes #6861
2017-08-22 15:22:03 -07:00
Benedikt Constantin Radtke
54396a3a9c Fix group info request responses
GroupRecords have a list of Addresses, not Strings.

Fixes #6881
Closes #6882
2017-08-22 15:19:39 -07:00
Moxie Marlinspike
8d473f4f50 Bump version to 4.9.8
// FREEBIE
2017-08-10 12:31:32 -07:00
Moxie Marlinspike
a80fe178ea Canonicalize addresses during import from system SMS database
// FREEBIE
2017-08-10 12:30:13 -07:00
Moxie Marlinspike
422b4c345b Catch IllegalArgumentException thrown internally on some devices
// FREEBIE
2017-08-10 12:17:05 -07:00
Moxie Marlinspike
c0ec531daa Bump version to 4.9.7
// FREEBIE
2017-08-07 12:41:26 -07:00
Moxie Marlinspike
47901e4198 Disallow alpha chars in country code field
// FREEBIe
2017-08-07 12:40:40 -07:00
Moxie Marlinspike
25a30d63a5 A blocked contact doesn't necessarily have to be a number
// FREEBIE
2017-08-07 12:27:34 -07:00
Moxie Marlinspike
1c3ba4b675 Bump version to 4.9.6
// FREEBIE
2017-08-04 09:30:54 -07:00
Moxie Marlinspike
c5a7d320f7 Don't query contacts DB if we have nothing to query
// FREEBIE
2017-08-04 09:28:20 -07:00
Moxie Marlinspike
8de9261081 MMS addresses can be email addresses
Fixes #6853
// FREEBIE
2017-08-04 09:22:58 -07:00
Moxie Marlinspike
f41e9c181c Bump version to 4.9.5
// FREEBIE
2017-08-03 13:01:38 -07:00
Moxie Marlinspike
cb4303ac23 Handle migration case where recipient_ids is completely empty
No idea how a DB is in that state, but apparently it's possible

Fixes #6850
// FREEBIE
2017-08-03 09:32:56 -07:00
Moxie Marlinspike
9a78615991 Switch regexp matcher to find() in order to handle alpha addresses
Any address with an alpha character anywhere in it should be used
as-is.

Fixes #6849

// FREEBIE
2017-08-03 09:24:08 -07:00
Moxie Marlinspike
dc61c67856 Bump version to 4.9.4
// FREEBIE
2017-08-02 13:08:19 -07:00
Moxie Marlinspike
7f46e99f9c Use SIM country code when registered number is unavailable
Convert directory operations to Addresses

Fixes #6845
// FREEBIE
2017-08-02 12:51:46 -07:00
Moxie Marlinspike
4838fade6c Fix typo
// FREEBIE
2017-08-02 11:15:58 -07:00
Moxie Marlinspike
1e934f6146 Escape addresess in thread and recipient pref migrations
For clients that have not yet migrated

// FREEBIE
2017-08-02 11:08:38 -07:00
Moxie Marlinspike
aacf50316d Escape addresses in thread, recipient pref, and group databases
Fixes #6847
// FREEBIE
2017-08-02 11:04:10 -07:00
Moxie Marlinspike
3d29445373 Bump version to 4.9.3
// FREEBIE
2017-08-02 08:15:21 -07:00
Moxie Marlinspike
24c48afd2e Fix typo in migration constraint resolution
Fixes #6846

// FREEBIE
2017-08-02 08:02:15 -07:00
Moxie Marlinspike
ae93038d66 Bump version to 4.9.2
// FREEBIE
2017-08-01 18:46:16 -07:00
Moxie Marlinspike
9a55632202 During migration, support recipient id of "-1"
Fixes #6843
// FREEBIE
2017-08-01 18:45:13 -07:00
Moxie Marlinspike
6ff9d3cc72 Bump version to 4.9.1
// FREEBIE
2017-08-01 14:53:07 -07:00
Moxie Marlinspike
6ed549cfb2 If two recipient ids get canonicalized to the same thing, drop one
There's not a great way for me to know which of them is the "real"
entry, which means that I could be deleting the wrong one. In the
case of recipient "preferences," it's hopefully not a huge loss,
and there aren't any other great options.

Fixes #6838

// FREEBIE
2017-08-01 14:52:03 -07:00
Moxie Marlinspike
8a5c89244a Be more liberal with migration addresses.
Anything alpha is an address as-is.

// FREEBIE.
2017-08-01 14:46:38 -07:00
Moxie Marlinspike
a67d0b18ff Be more liberal with external address formatting
A string like "bonbon" should just be "bonbon". That is apparently
a valid SMS source address.

// FREEBIE
2017-08-01 14:04:51 -07:00
Moxie Marlinspike
abea2d0bdf Fix for MediaOverviewActivity NPE
// FREEBIE
2017-08-01 10:00:55 -07:00
Moxie Marlinspike
5f9a3b7930 Only lookup contact address by number if address is a phone number
// FREEBIE
2017-08-01 09:57:50 -07:00
Moxie Marlinspike
4229c21bdc Fix NPE on contact update request
Fixes #6840

// FREEBIE
2017-08-01 08:57:26 -07:00
Moxie Marlinspike
45ecca69d3 Bump version to 4.9.0
// FREEBIE
2017-07-31 15:39:44 -07:00
Moxie Marlinspike
8c7ffe73f3 Updated language translations
// FREEBIE
2017-07-31 15:38:57 -07:00
Moxie Marlinspike
0ae60da68b Fix some bugs that would mis-label threads in migration
// FREEBIE
2017-07-31 14:04:47 -07:00
Moxie Marlinspike
737810475e Remove the Canonical Address Database
This was a holdover from Signal's origins as a pure SMS app.
It causes problems, depends on undefined device specific behavior,
and should no longer be necessary now that we have all the
information we need to E164 all numbers.

// FREEBIE
2017-07-31 12:02:29 -07:00
Moxie Marlinspike
e452862813 Catch unsatisfied link error on start if webrtc so isn't found
// FREEBIE
2017-07-21 16:29:03 -07:00
Moxie Marlinspike
5be246ec8f Fix NPE for SMS pdus that could potentially be null
// FREEBIE
2017-07-21 16:11:55 -07:00
Moxie Marlinspike
72afb33c1b Add Moto G5 to hardware AEC blacklist
For #6241
// FREEBIE
2017-07-21 16:03:31 -07:00
Moxie Marlinspike
0b39224d88 getMemoryClass -> getLargeMemoryClass
Fixes #6812

// FREEBIe
2017-07-21 16:01:32 -07:00
Moxie Marlinspike
82b5b35d3b Eliminate MediaNetworkRequirement style attachment job handling
// FREEBIE
2017-07-21 15:59:27 -07:00
Moxie Marlinspike
b5259f6847 Bump version to 4.8.1
// FREEBIE
2017-07-12 18:17:39 -07:00
AndHell
10de144b77 Trim message text to prohibit sending empty whitespace messages
Closes #6788
2017-07-12 18:15:49 -07:00
Moxie Marlinspike
f62fa2dc4e Updated language translations
// FREEBIE
2017-07-12 18:10:34 -07:00
Moxie Marlinspike
18f6196388 Update to libsignal-service 2.5.16
// FREEBIE
2017-07-12 18:05:27 -07:00
Moxie Marlinspike
c36db03a3a Prevent audio control click handler feedback loops
Fixes #6356
Fixes #6406
Fixes #6169

Closes #6800
// FREEBIE
2017-07-12 16:18:54 -07:00
Moxie Marlinspike
9dd508b6f5 Track pending incoming ice updates in addition to outgoing
// FREEBIE
2017-07-12 11:15:28 -07:00
Moxie Marlinspike
34443b059c Revert "We can now send trickle ice candidates immediately"
Need to hold off on this for some iOS changes.

This reverts commit 338f8de787.
2017-07-12 10:59:10 -07:00
Moxie Marlinspike
666f648c59 Bump version to 4.8.0
// FREEBIE
2017-07-07 11:13:09 -07:00
Moxie Marlinspike
54bab07483 Update language translations
// FREEBIE
2017-07-07 11:11:59 -07:00
Moxie Marlinspike
526d510423 Start creating "persistent" blobs in cache directory
Helps #5515
// FREEBIE
2017-07-06 12:58:05 -07:00
Gavin Howard
381237a315 Make plaintext export more compatible with SMS Backup and Restore
This commit adds the contact name and the readable date (and time) to
the plaintext export of every message. That's because that is how SMS
Backup and Restore does it, so this commit makes Signal more compatible.

Closes #6452
// FREEBIE
2017-07-06 12:19:12 -07:00
FeuRenard
512c6dc581 Keep screen off after end of audio playback
Fixes #6654
Closes #6669
// FREEBIE
2017-07-05 18:31:14 -07:00
Sebastian Malek
170b869a22 larger google play badge
Closes #6701
//FREEBIE
2017-07-05 18:22:25 -07:00
Christian Ascheberg
d0bb68e137 Fix group creation through group info request
Closes #6763
// FREEBIE
2017-07-05 14:19:55 -07:00
Christian Ascheberg
95d48bd3e9 Improve wording of joined contact notification
Fixes #6757
Closes #6764
// FREEBIE
2017-07-05 14:18:07 -07:00
Mateo Hernandez
5e1d63696f Fix ConversationAdapterTest#testGetItemIdEquals()
Regression introduced at cb670d67

Fixes #6652
Closes #6779
// FREEBIE
2017-07-05 14:13:35 -07:00
Moxie Marlinspike
338f8de787 We can now send trickle ice candidates immediately
// FREEBIE
2017-07-05 14:06:31 -07:00
Moxie Marlinspike
2c4c0f1349 Archive sessions and generate new registration id on re-register
Fixes #6703
// FREEBIE
2017-07-05 13:13:53 -07:00
Moxie Marlinspike
39b95ca4ed Do more to keep MessageRetrievalService alive
Closes #6456
2017-07-03 11:36:31 -07:00
Moxie Marlinspike
fcbcffe9ba Bump version to 4.7.4
// FREEBIE
2017-06-25 22:34:01 -07:00
Moxie Marlinspike
501b351f80 Update signal-service to 2.5.14
// FREEBIE
2017-06-25 22:33:31 -07:00
Moxie Marlinspike
b72b1cda94 Bump version to 4.7.3
// FREEBIE
2017-06-23 14:10:15 -07:00
Moxie Marlinspike
074e46b2d9 Enable verification syncing
// FREEBIE
2017-06-23 13:59:06 -07:00
Moxie Marlinspike
91612cb6f2 Bump version to 4.7.2
// FREEBIE
2017-06-22 11:04:23 -07:00
Moxie Marlinspike
f193723182 Don't display verified marker in conversation if unregistered
Closes #6755
// FREEBIE
2017-06-22 10:37:26 -07:00
Moxie Marlinspike
a0e23612d4 We need to disable this until push notifications contain more info
This could be a sync message, delivery receipt, or some other
message that isn't user-visible. The push notification content
would need to indicate whether that's the case in order to be
able to accurately display a notification

// FREEBIE
2017-06-20 10:57:11 -07:00
Moxie Marlinspike
8b12bc9acc Bump version to 4.7.1
// FREEBIE
2017-06-19 12:02:18 -07:00
Moxie Marlinspike
e2439278f4 Update libsignal-server to 2.5.12
Fixes #6734
// FREEBIE
2017-06-19 12:00:49 -07:00
Moxie Marlinspike
04f364942e Don't update thread state for groups w/ verified/default SNs
Fixes #6744
// FREEBIE
2017-06-19 11:20:15 -07:00
Moxie Marlinspike
0cc5618ba9 Only offer share/compare options when SN calculation is complete
Now that we're loading this asynchronously, these options need
to respond asynchronously as well

Fixes #6739
// FREEBIE
2017-06-19 10:39:15 -07:00
Moxie Marlinspike
8208bbf3c0 Remove stale identity approval preference (no longer used)
Fixes #6745
// FREEBIE
2017-06-19 09:27:35 -07:00
Moxie Marlinspike
1c8077a7fe Switch from a hardware AEC whitelist back to a blacklist
Disabling OpenSL ES seems to make the hardware AEC "work" on
devices where it was previously causing problems.

Using the WebRTC-based software AEC *without* OpenSL ES seems to
be causing new problems.

Fixes #6737
Related #6432
Related #6241
// FREEBIE
2017-06-19 09:22:07 -07:00
Moxie Marlinspike
7c2191f9a0 Bump version to 4.7.0
// FREEBIE
2017-06-15 12:41:55 -07:00
Moxie Marlinspike
83b1e7ba6c Updated language translations
// FREEBIE
2017-06-15 12:41:30 -07:00
Moxie Marlinspike
ec240a94e6 Fix capitalization (innocuous)
// FREEBIE
2017-06-15 12:04:50 -07:00
Moxie Marlinspike
666be5f358 Preserve unverified status if aleady unverified on update
// FREEBIE
2017-06-14 11:01:24 -07:00
Moxie Marlinspike
7f76bcc976 Don't attempt to fetch profiles for SMS contacts
// FREEBIE
2017-06-14 09:53:22 -07:00
Moxie Marlinspike
2dbeebac77 Maintain placeholder encrypted body to avoid processing error
// FREEBIE
2017-06-14 09:45:38 -07:00
Moxie Marlinspike
fa64c5de62 Updated language translations
// FREEBIE
2017-06-14 09:39:20 -07:00
Moxie Marlinspike
0f6823d37e Null check just in case the profile comes back empty
// FREEBIE
2017-06-14 09:35:32 -07:00
Moxie Marlinspike
172de96ce4 Update to webrtc M59
// FREEBIE
2017-06-13 12:28:12 -07:00
Moxie Marlinspike
f92d768be5 Correctly handle ice candidate for stale call
Fixes #6373
Fixes #6305
// FREEBIE
2017-06-13 09:21:42 -07:00
RiseT
52311eb881 "Message notifications" >> "Messages"
Closes #6700
// FREEBIE
2017-06-12 09:52:46 -07:00
Moxie Marlinspike
414a885b54 Make string plural
// FREEBIE
2017-06-12 09:49:04 -07:00
Moxie Marlinspike
1eccc07673 Temporarily disable synchronization messages
Until desktop catches up

// FREEBIE
2017-06-12 09:47:58 -07:00
Moxie Marlinspike
59d3e666fe Rename 'verify safety number' to 'view safety number'
// FREEBIE
2017-06-09 19:58:05 -07:00
Moxie Marlinspike
76c28cfa7a Add support for SN verification
// FREEBIE
2017-06-09 19:58:01 -07:00
Moxie Marlinspike
58273997b9 Explicitly check for disabled play services if needs update
Fixes #6381
// FREEBIE
2017-06-02 09:59:23 -07:00
Moxie Marlinspike
5672701a60 Add uncaught exception handler to message retrieval thread
Related #6644
// FREEBIE
2017-06-02 09:49:44 -07:00
Moxie Marlinspike
711740d156 Update to libsignal-service 2.5.10
// FREEBIE
2017-06-02 09:49:29 -07:00
Moxie Marlinspike
b50a3fa2b8 Actually handle busy signal correctly
// FREEBIE
2017-06-01 13:11:48 -07:00
Moxie Marlinspike
c09c7b6649 Update language translations
// FREEBIE
2017-06-01 10:58:22 -07:00
Moxie Marlinspike
7e40204eb2 Fix migration
Fixes #6695
// FREEBIE
2017-06-01 10:57:45 -07:00
Moxie Marlinspike
d413b80b15 Canonicalize number when retrieving profile
// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
73410f64b5 Display a notification when unable retrieve messages for push
Fixes #6684
// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
cd55feb2b9 Update signal-service to 2.5.9
// FREEBIE
2017-05-31 14:51:48 -07:00
FeuRenard
a9ea672888 Resolve media message race condition
Fixes #6677
Closes #6681
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
5455bdffb2 Make sure existing identity entries are approved in migration
// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
0367bf0de4 Update signal-service to 2.5.8
// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
e9ae439b70 Fix for out of bounds on last seen search
Fixes #6661
Fixes #6660
// FREEBIE
2017-05-31 14:51:48 -07:00
Paride Legovini
99d229bb45 Don't connect to server if !isPushRegistered
Partial fix for #6620.
Closes #6627
// FREEBIE
2017-05-31 14:51:48 -07:00
Nicholas Rizzio
3d7331159f Set the advanced menu icon correctly
Fixes #6638
Closes #6639
// FREEBIE
2017-05-31 14:51:48 -07:00
Christian Ascheberg
662fe826cb Fix conversation list safety number change snippet for groups
Fixes #5985
Closes #6655
// FREEBIE
2017-05-31 14:51:48 -07:00
FeuRenard
ec1a0547d6 Don't show sent checkmark for outgoing calls
Fixes #6502
Closes #6667
// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
d507756821 Some identity key handling changes
1) Prefetch identity keys when possible

2) Always accept prefetched keys or keys from incoming messages

3) Block sending only if it's a recent change, or if always
   block is enabled

// FREEBIE
2017-05-31 14:51:48 -07:00
Moxie Marlinspike
ca701df1e4 Update copyright date
Closes #6678
// FREEBIE
2017-05-25 11:34:24 -07:00
Moxie Marlinspike
56f85e7f85 Bump version to 4.6.1
// FREEBIE
2017-05-24 11:03:40 -07:00
Moxie Marlinspike
4509077338 Lollipop MMS API doesn't seem to work reliably until L_MR1
Fixes #6663
Fixes #6668
// FREEBIE
2017-05-24 10:52:08 -07:00
Moxie Marlinspike
4dd5a92817 Fix for NPE when place picker name is unavailable
Fixes #6671
// FREEBIE
2017-05-24 10:03:35 -07:00
Moxie Marlinspike
782bd6003b Actually fallback to manual MMS receiving when system fails
Should resolve #6668 for tmobile users on older lollipop phones
// FREEBIE
2017-05-23 18:23:47 -07:00
Moxie Marlinspike
15df691017 Bump version to 4.6.0
// FREEBIE
2017-05-12 15:47:53 -07:00
Moxie Marlinspike
0d6f8a003d Add proguard config for klinker library
// FREEBIE
2017-05-12 15:47:04 -07:00
Moxie Marlinspike
50cec22aa1 Updated language translations
// FREEBIE
2017-05-11 22:49:26 -07:00
Moxie Marlinspike
b78c05e70b Keep track of when audio attachments are voice notes
// FREEBIE
2017-05-11 22:46:35 -07:00
Moxie Marlinspike
e96bf2bdc7 Allow share intents for arbitrary file types
Fixes #6608
// FREEBIE
2017-05-10 15:21:52 -07:00
Moxie Marlinspike
1c8c6d5f85 Be sure to canonicalize numbers when updating groups
// FREEBIE
2017-05-09 17:46:07 -07:00
Moxie Marlinspike
1525d0833c Enforce ordered data channel
// FREEBIE
2017-05-09 12:13:42 -07:00
Moxie Marlinspike
3fd5e58bd5 Disable OpenSL ES by default
Fixes #6432
// FREEBIE
2017-05-09 11:03:32 -07:00
Moxie Marlinspike
51d6144591 Significant MMS changes
1) Remove all our PDU code and switch to the PDU code from the
   klinker library

2) Switch to using the system Lollipop MMS library by default,
   and falling back to our own custom library if that fails.

3) Format SMIL differently, using code from klinker instead of
   what we've pieced together.

4) Pull per-carrier MMS media constraints from the XML config
   files in the klinker library, instead of hardcoding it at 280kb.

Hopefully this is an improvement, but given that MMS is involved,
it will probably make things worse instead.
2017-05-08 18:14:55 -07:00
Audric Ackermann
165fae5734 Display contact custom label instead of phone number
Fixes #6211
2017-05-07 19:23:55 -07:00
AndHell
dc18f73594 update contact query
update query to remove duplicated numbers

Fixes #4191
Closes #6475
2017-05-07 19:18:26 -07:00
Moxie Marlinspike
12ce92bb83 Fix super call
// FREEBIE
2017-05-07 18:59:35 -07:00
Moxie Marlinspike
b0b08a37db Rename "other" to "sms"
// FREEBIE
2017-05-07 18:59:18 -07:00
FeuRenard
1b75d00de5 Color registration buttons correctly <API21
Fixes #6604
Closes #6605
// FREEBIE
2017-05-07 18:23:19 -07:00
Joan Montané
6ede47d4f7 FREEBIE: Add Catalan to language selector
Closes #6612
2017-05-06 14:08:43 -07:00
Jonas Vautherin
dd3cef5ec2 Refactor storage management to have a centralized,
clearer way to get the Signal output directories

Closes #6476
// FREEBIE
2017-05-06 14:06:04 -07:00
Moxie Marlinspike
757ccd0c36 Updated emoji set
Fixes #4279
Fixes #6587
2017-05-05 19:42:23 -07:00
Moxie Marlinspike
bfc9ad7761 Bump version to 4.5.3
// FREEBIE
2017-04-30 10:29:31 -07:00
Moxie Marlinspike
e340f85258 Tint devices icon too
Fixes #6601
// FREEBIE
2017-04-28 16:30:20 -07:00
Moxie Marlinspike
89d1232bdc Bump version to 4.5.2
// FREEBIE
2017-04-28 14:57:01 -07:00
Moxie Marlinspike
cf04b0521e Updated language translations
// FREEBIE
2017-04-28 14:56:35 -07:00
Mateo Hernandez
a93fb1a0e5 Fix font size preference
Closes #6597
// FREEBIE
2017-04-28 14:51:56 -07:00
Moxie Marlinspike
50cf9c448a Bump version to 4.5.1
// FREEBIE
2017-04-27 17:59:15 -07:00
Mateo Hernandez
da6a00c4dc Tweak reminder layout
Closes #6586
// FREEBIE
2017-04-27 17:56:21 -07:00
Shenka
58a5e1f33c Fix vertical space in import_export_fragment
Fixes #6590
// FREEBIE
2017-04-27 17:47:09 -07:00
Mateo Hernandez
31e78f5fae Tweak contact selection layout
Fixes #6588

// FREEBIE
2017-04-27 18:42:25 -05:00
Mateo Hernandez
f4f0a97fc6 Revert "Tweak contact selection layout"
This reverts commit 59a2bf8a.
(wrong commit merged)

// FREEBIE
2017-04-27 18:41:18 -05:00
Christian Juner
1c94137f7a Fall back to Camera1Enumerator on exceptions
If Camera2Enumerator.isSupported() throws, consider Camera2Enumerator to
not be supported, log the Throwable, and use Camera1Enumerator instead.

Before this patch, an exception thrown by Camera2Enumerator.isSupported
would crash any Signal call (even if video was not enabled).

Fixes #6537
// FREEBIE
2017-04-27 20:51:31 +02:00
Moxie Marlinspike
2e8250f25e Add LG G3 to OpenSLES blacklist
// FREEBIE
2017-04-27 11:38:49 -07:00
Moxie Marlinspike
12062bdfe1 Bump version to 4.5.0
// FREEBIE
2017-04-26 18:08:32 -07:00
Moxie Marlinspike
bc9a52c510 Updated language translations
// FREEBIE
2017-04-26 18:08:05 -07:00
Mateo Hernandez
59a2bf8ae7 Tweak contact selection layout
Closes #6563
// FREEBIE
2017-04-26 18:05:07 -07:00
Mateo Hernandez
b17cba621e Show emoji-only messages larger
Closes #6531
// FREEBIE
2017-04-26 17:52:16 -07:00
mcloo
5ffee53faa Fix Unread Badger for Sony Launcher
Closes #6552
Fixes #6484
2017-04-26 10:27:30 -07:00
Mateo Hernandez
869630b7f4 Tint and resize import/export icons
Closes #6567
// FREEBIE
2017-04-26 10:27:30 -07:00
Mateo Hernandez
291dafa5c8 Switch import/export activity from cards to a list
Add touch ripple to items

Closes #6564
// FREEBIE
2017-04-26 10:27:30 -07:00
Moxie Marlinspike
cb670d6783 Improve UI send latency
// FREEBIE
2017-04-26 10:27:30 -07:00
Moxie Marlinspike
4d889a45e2 Blacklist Nexus 5 from OpenSL ES
Fixes #6432
// FREEBIE
2017-04-26 10:26:32 -07:00
Moxie Marlinspike
66d1d88686 Fix file push media constraint
// FREEBIE
2017-04-25 10:01:09 -07:00
Moxie Marlinspike
e4ac1b8dde Update language translations
// FREEBIE
2017-04-24 18:08:59 -07:00
Moxie Marlinspike
31a549449b Mutate Drawables we tint
Fixes #6575
// FREEBIE
2017-04-24 16:37:13 -07:00
Moxie Marlinspike
9bf198bb81 Add media constraints for arbitrary file types
Fixes #6573
// FREEBIE
2017-04-24 15:53:22 -07:00
Moxie Marlinspike
03e347bfd9 s/Document/File
// FREEBIE
2017-04-23 16:28:10 -07:00
Ahmed Ibrahim Khalil
c2796285d5 Fix copying links when scrolling in #6343
Closes #6565
// FREEBIE
2017-04-23 16:25:57 -07:00
Moxie Marlinspike
3acfba7bd0 Bump version to 4.4.0
// FREEBIE
2017-04-22 09:50:02 -07:00
Moxie Marlinspike
9377fb6ce0 Updated language translations
// FREEBIE
2017-04-22 09:49:22 -07:00
Moxie Marlinspike
25c7459464 Add support for notification priority preference
Fixes #6315
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
2dceef50b7 Slim down some preference screens
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
438a78ed30 Switch jobs with network requirement to timed wakelock
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
8e7c7a9c54 Improve video thumbnail generation and handling on send side
For direct attach only

// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
ad4657df1f Fix video selection support with extra mime type
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
bc33f8ec02 Remove unused resources
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
d00671e7a5 Tweak attachment type selector look
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
2b79e131a7 Support for sending arbitrary file types
// FREEBIE
2017-04-21 23:05:59 -07:00
Ahmed Ibrahim Khalil
c3164a8e84 Support copying links on long click.
Fixes #6343
Closes #6454
2017-04-21 23:05:59 -07:00
Mateo Hernandez
f07ce7b1f1 Move SMS/MMS pref hiding logic to onCreate
Closes #6528
// FREEBIE
2017-04-21 23:05:59 -07:00
Mateo Hernandez
a353ebd834 Add tint to preference icons
Closes #6540
// FREEBIE
2017-04-21 23:05:59 -07:00
Moxie Marlinspike
a697fcea04 Bump version to 4.3.2
// FREEBIE
2017-04-19 18:08:53 -07:00
Mateo Hernandez
9716849bb9 Fix preference divider crash on KitKat
Closes #6546
Fixes #6544
// FREEBIE
2017-04-19 18:08:44 -07:00
Moxie Marlinspike
9c5fe77e96 Bump version to 4.3.1
// FREEBIE
2017-04-17 16:03:06 -07:00
Moxie Marlinspike
0a0203a019 Update language translations
// FREEBIE
2017-04-17 16:02:56 -07:00
Moxie Marlinspike
8aab61c2e3 Make preference category card dividers more dark theme compatible
// FREEBIE
2017-04-17 15:31:54 -07:00
RiseT
9d3ff55457 Make "Contact joined Signal" translatable
Closes #6534
// FREEBIE
2017-04-17 10:29:34 -07:00
Mateo Hernandez
19c7fd21a8 Update preference screen icons
Closes #6538
// FREEBIE
2017-04-17 10:27:02 -07:00
Moxie Marlinspike
a5500655a7 Bump version to 4.3.0
// FREEBIE
2017-04-16 15:59:30 -07:00
Moxie Marlinspike
4a516084a6 Updated langauge translations
// FREEBIE
2017-04-16 15:59:01 -07:00
Moxie Marlinspike
f583c14e0e s/text/font size
// FREEBIE
2017-04-16 12:54:42 -07:00
Moxie Marlinspike
ddf6126abf Fix VideoPlayer Build.VERSION minimum
// FREEBIE
2017-04-16 11:11:08 -07:00
Mateo Hernandez
c389a9d3ce Support non-BMP chars (e.g. emojis) in avatars
Closes #6527
Fixes #6522
// FREEBIE
2017-04-16 10:35:08 -07:00
Moxie Marlinspike
cd56f03e07 Adjust conversation list look
// FREEBIE
2017-04-15 11:19:06 -07:00
Moxie Marlinspike
fe1cc3d6d1 Adjust compose field look
1) Align top of compose bubble with top of attach/send icon

2) Simplify hint

3) Make hint size same as input size

// FREEBIE
2017-04-15 10:12:00 -07:00
Moxie Marlinspike
5f5db5ded7 Support for message body text size preference
// FREEBIE
2017-04-14 22:59:30 -07:00
Moxie Marlinspike
e5a287b4e5 Add preference for SMS invitation prompt
// FREEBIE
2017-04-14 20:51:22 -07:00
Moxie Marlinspike
13d785894a Fix up preference screen a little
1) Remove phantom padding on left margin for all fragments

2) Move preferences around slightly

3) Add some card separators and style led list pref

// FREEBIE
2017-04-14 20:39:38 -07:00
Moxie Marlinspike
4fd41080ac Use exoplayer for playing video on API 16+ devices
// FREEBIE
2017-04-13 14:15:06 -07:00
Moxie Marlinspike
fad697ba2a Fix CipherInputStream seek behavior
Fixes #6518
// FREEBIE
2017-04-13 12:21:38 -07:00
Moxie Marlinspike
51f27631ef Switch from hardware AEC blacklist to whitelist
Related #6241
// FREEBIE
2017-04-12 15:12:13 -07:00
Taylor Kline
04153a3869 Grey 'LED blink pattern' when LED Color is None
Add BooleanListPreference to allow pref_led_blink to depend on
pref_led_color being non-None.

Closes #6480
2017-04-12 15:01:35 -07:00
Simon
b0b1cdef35 Add Redmi Note 4 to HARDWARE_AEC_BLACKLIST
See #6241
Closes #6516
// FRЕЕBIЕ
2017-04-10 14:31:45 -07:00
AQNOUCH Mohammed
6f6632c08a fix warning: XML has empty body
Closes #6473
2017-04-10 11:07:55 -07:00
Nicholas Rizzio
407c5d5ed2 Remove unused settings.gradle file
Closes #6479
// FREEBIE
2017-04-10 10:53:13 -07:00
Taylor Kline
b7f9525680 Remove unused summary field for notification.
Closes #6481
2017-04-10 10:45:18 -07:00
Moxie Marlinspike
68e68508a7 Bump version to 4.2.5
// FREEBIE
2017-04-10 09:46:34 -07:00
Moxie Marlinspike
e6f693a677 Updated language translations
// FREEBIE
2017-04-10 09:45:11 -07:00
Moxie Marlinspike
6b7174bb35 Add OnePlus One to AEC blacklist
// FREEBIE
2017-04-10 09:29:46 -07:00
Moxie Marlinspike
92ea7549d4 Make UpdateApkJob use a timed wakelock
Fixes #6514
// FREEBIE
2017-04-10 09:25:52 -07:00
Moxie Marlinspike
0a4d1569fb Clean up file name some on save
Rusty Bird points out that we don't want the save action to create
files outside the parent or hidden files.

// FREEBIE
2017-04-10 09:14:59 -07:00
Moxie Marlinspike
4c83e2ce10 Bump version to 4.2.4
// FREEBIE
2017-04-03 17:25:02 -07:00
Moxie Marlinspike
7c5df81840 Fix for busted OpenSSL JCE provider on older versions of android
Fixes #6477
// FREEBIE
2017-04-03 17:23:56 -07:00
Moxie Marlinspike
6afee68831 Bump version to 4.2.3
// FREEBIE
2017-04-03 10:13:40 -07:00
Moxie Marlinspike
bae549b1cc Update language translations
// FREEBIE
2017-04-03 10:11:07 -07:00
Moxie Marlinspike
ce9a67d095 Fix case
// FREEBIE
2017-04-02 18:26:28 -07:00
Moxie Marlinspike
3356f7c190 Bump version to 4.2.2
// FREEBIE
2017-04-02 09:33:58 -07:00
Moxie Marlinspike
2ce9eeabed Fix for broken attachments
Fixes #6467
// FREEBIE
2017-04-02 09:29:26 -07:00
Moxie Marlinspike
5b8e75c068 Bump version to 4.2.1
// FREEBIE
2017-03-31 16:55:20 -07:00
Paride Legovini
c97fa0d3d1 Blacklist OnePlus X from hardware AEC
Closes #6465
// FREEBIE
2017-03-31 16:54:22 -07:00
Moxie Marlinspike
b0bd6ad729 Fix for crash when opening group conversation
Fixes #6464
// FREEBIE
2017-03-31 16:52:50 -07:00
Moxie Marlinspike
d85ddbcd10 Bump version to 4.2.0
// FREEBIE
2017-03-31 10:24:24 -07:00
Moxie Marlinspike
51807226a7 Update language translations
// FREEBIE
2017-03-31 10:23:55 -07:00
FeuRenard
07c8db824e Disable screen during earpiece voice note playback
Fixes #6437
Closes #6445
// FREEBIE
2017-03-31 09:13:00 -07:00
Moxie Marlinspike
75782affd1 Adjust joined signal string
// FREEBIE
2017-03-31 08:54:07 -07:00
FeuRenard
49117a4138 Remove unused icon
Closes #6444
// FREEBIE
2017-03-30 18:51:43 -07:00
Paride Legovini
9d52e6af6a Don't mention CyanogenMod
Closes #6422
// FREEBIE
2017-03-30 18:50:40 -07:00
Moxie Marlinspike
706835584e Update shortcut badger
// FREEBIE
2017-03-30 18:41:29 -07:00
Moxie Marlinspike
f7261cc9e7 Remove GV from registration problems list
// FREEBIE
2017-03-30 18:41:18 -07:00
Moxie Marlinspike
3aae86d20c Update registration activity style
// FREEBIE
2017-03-30 18:18:04 -07:00
Moxie Marlinspike
ad0f2830c8 Raise max gif limit to 25MB
// FREEBIE
2017-03-30 16:12:55 -07:00
Moxie Marlinspike
056f2717ed Remove duplicate column in SQL query
// FREEBIE
2017-03-30 16:12:42 -07:00
Moxie Marlinspike
f67eb5f9f3 Support for receiving arbitrary attachment types
// FREEBIE
2017-03-29 18:17:34 -07:00
Moxie Marlinspike
c69efbffd2 Don't enable speakerphone when video enabled if headset on
Fixes #6431
// FREEBIE
2017-03-24 11:11:48 -07:00
Moxie Marlinspike
3dfc72dad0 Bump version to 4.1.0
// FREEBIE
2017-03-23 16:30:13 -07:00
Moxie Marlinspike
372cdc4b9f Update language translations
// FREEBIE
2017-03-23 16:29:35 -07:00
Moxie Marlinspike
01d66087aa Blacklist Nexus 6 from hardware AEC
Remove all blacklisting from library

// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
e0e932df02 Add Samsung Galaxy S7 and Sony Xperia SP to AEC blacklist
Related #6241
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
3ca653627d Add LG G3 to hardware AEC blacklist
Helps #6241
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
f4acaad407 Add Pixel, S5, Redmi Note 3, and Xiaomi Mi4 to AEC blacklist
Make these application-level changes

Helps #6241
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
6787a96d71 Revert "Add Pixel, S5, Redmi Note 3, and Xiaomi Mi4 to AEC blacklist"
This reverts commit f5768220f2a0ea6ccc09d2026a29f96bc5046027.
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
e7f5022a75 Add Pixel, S5, Redmi Note 3, and Xiaomi Mi4 to AEC blacklist
Addresses #6241
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
93e7a626bf Make voice note playback proximity aware
1) Play audio through earpiece if placed to ear

2) Stop playing audio if removed from ear

Fixes #6195
// FREEBIE
2017-03-23 16:18:07 -07:00
Moxie Marlinspike
448335e9bc Bump version to 4.0.1
// FREEBIE
2017-03-22 09:53:37 -07:00
Moxie Marlinspike
7ad68296dd Fix for crash when call initiated from contacts
Fixes #6428
// FREEBIE
2017-03-22 09:49:06 -07:00
Moxie Marlinspike
3d28db3453 Bump version to 4.0.0
// FREEBIE
2017-03-17 11:25:01 -07:00
Moxie Marlinspike
56c0ea0a4f Remove redphone keystore (thanks @paride)
Closes #6405
// FREEBIE
2017-03-17 11:24:13 -07:00
Moxie Marlinspike
b964c74ce8 Updated language translations
// FREEBIE
2017-03-17 10:58:28 -07:00
Moxie Marlinspike
a3445fb2fd Update Dockerfile for new build tools version
// FREEBIE
2017-03-17 10:47:32 -07:00
Moxie Marlinspike
0d11b3dd26 Lets limit GCM refresh to every 6hrs, and only retry once
// FREEBIE
2017-03-17 10:40:34 -07:00
greenjoe
deb96646a3 Add action indicator when resending a message.
When message is being resent, "RESEND" button now disappears.
"Resending..." text is displayed instead of an error message.

Fixes #6307
Closes #6347
2017-03-16 15:27:26 -07:00
FeuRenard
a421630789 Update input after enabling SMS
Fixes #6363
Closes #6387
// FREEBIE
2017-03-16 15:22:02 -07:00
RiseT
4f0422ee94 Fixes misnamed string resource
Closes #6398
// FREEBIE
2017-03-16 15:19:04 -07:00
FeuRenard
0f548a431b Fallback to SMS app for invitations
Fixes #6369
Closes #6400
// FREEBIE
2017-03-16 14:29:41 -07:00
Benedikt Constantin Radtke
742b54f32d fix ContactUpdates for non-e164 contacts
convert every number to e164 before sending it to slaves/siblings.

Closes #6310
2017-03-16 14:25:47 -07:00
Paride Legovini
1c9715f700 More RedPhone cleanup
Closes #6393
// FREEBIE
2017-03-15 16:59:46 -07:00
FeuRenard
52b1e17c36 Unify alert dialog button colors
Fixes #5227
Closes #5415
// FREEBIE
2017-03-15 16:57:11 -07:00
Moxie Marlinspike
9273f5cc67 Switch import/export activity from tabs to cards
// FREEBIE
2017-03-15 16:53:15 -07:00
Moxie Marlinspike
a8366387ab Fix the build
// FREEBIE
2017-03-14 15:47:08 -07:00
Admir Ireiz
5e02715a2c Change the app icon
Closes #6189
2017-03-14 15:46:19 -07:00
Christian Ascheberg
3506f2db12 Improve group update descriptions
Closes #5416
// FREEBIE
2017-03-14 14:26:14 -07:00
haffenloher
66c9fd44df Honor synced end session messages
Fixes #5174
Closes #5178
2017-03-14 14:07:18 -07:00
Tim Serong
944f5aad0d BUILDING.md: clarify build tools version
Closes #6264
// FREEBIE
2017-03-14 13:57:14 -07:00
RiseT
a41e82bb7d Make WebRtcCallScreen_new_safety_numbers_title singular
Closes #6364
// FREEBIE
2017-03-14 13:42:39 -07:00
Moxie Marlinspike
94964474b2 So long redphone
// FREEBIE
2017-03-14 13:24:24 -07:00
Moxie Marlinspike
2f46c6ca1f Don't redisplay notifications after they have been dismissed
Fixes #5751
Fixes #6218
// FREEBIE
2017-03-14 10:09:24 -07:00
Moxie Marlinspike
33e0b4fc6d Bump version to 3.31.4
// FREEBIE
2017-03-13 11:50:20 -07:00
Moxie Marlinspike
bb5e7db57e We don't need to refresh attributes in redphone any longer
// FREEBIE
2017-03-13 11:50:10 -07:00
Moxie Marlinspike
e1d0f2f4e9 Bump version to 3.31.3
// FREEBIE
2017-03-12 11:00:06 -07:00
Moxie Marlinspike
20af8045e8 Update language translations
// FREEBIE
2017-03-12 10:59:39 -07:00
Moxie Marlinspike
3127fda7fe Actually show the GMS update dialog
// FREEBIE
2017-03-12 10:56:51 -07:00
Christian Ascheberg
12b27cc56b Fix WebRTC capability check for unregistered users
Fixes #6358
Closes #6368
// FREEBIE
2017-03-12 10:50:13 -07:00
mcloo
1683bb4636 Choose AudioManager SCO action device depended
Closes #6367
//FREEBIE
2017-03-12 10:47:35 -07:00
mcloo
9d13b9437c Fix NPE crash when no bluetooth is available
Fixes #6355
Closes #6366
2017-03-12 10:45:52 -07:00
Christian Ascheberg
97c3e8fa3f Inform about timed out incoming calls
Closes #6344
// FREEBIE
2017-03-12 10:43:55 -07:00
Moxie Marlinspike
76c41a8295 Bump version to 3.31.2
// FREEBIE
2017-03-10 09:33:55 -08:00
Moxie Marlinspike
edbd20899e Update language translations
// FREEBIE
2017-03-10 09:33:24 -08:00
Moxie Marlinspike
8e25689c24 Modify upstream webrtc NetEq to pass bounds information to speex
Just in case

Closes #6334
// FREEBIE
2017-03-10 09:28:54 -08:00
Moxie Marlinspike
057c348d08 Bump version to 3.31.1
// FREEBIE
2017-03-09 17:31:07 -08:00
Moxie Marlinspike
6866a74d95 Don't display the last seen divider for outgoing calls
// FREEBIE
2017-03-09 17:31:07 -08:00
Moxie Marlinspike
cbba8c0d76 Update signal-service
// FREEBIE
2017-03-09 17:31:03 -08:00
Moxie Marlinspike
c7c411b3f3 Bump version to 3.31.0
// FREEBIE
2017-03-07 13:55:37 -08:00
Moxie Marlinspike
c7782c51db Updated language translations
// FREEBIE
2017-03-07 13:55:27 -08:00
mcloo
7ae0f38c45 Update language list
Closes #6055
2017-03-07 13:20:44 -08:00
Max Muth
2c1a5aef1c Fix occasional crash on Android 7 direct reply
Fixes #6185
Closes #6322
//FREEBIE
2017-03-06 14:08:25 -08:00
FeuRenard
defb173ffe Dark theme support for audio drafts
Fixes #4681
Closes #6251
// FREEBIE
2017-03-06 13:51:03 -08:00
FeuRenard
0095e00bc7 Keep screen on during voice note recording
Closes #6239
Fixes #4646
// FREEBIE
2017-03-06 13:45:34 -08:00
Moxie Marlinspike
ed5faa4ba9 Add video calling intro screen
// FREEBIE
2017-03-06 12:32:09 -08:00
Moxie Marlinspike
1e02d70052 Make webrtc calling default
// FREEBIE
2017-03-06 12:10:26 -08:00
Moxie Marlinspike
b110c8a2cb Reregister GCM on every app start
Fixes #5531
// FREEBIE
2017-03-06 11:50:51 -08:00
Moxie Marlinspike
bdcfabf1ee Silence incoming ringer when power button is pressed
// FREEBIE
2017-03-05 10:36:01 -08:00
Moxie Marlinspike
cd28cd172f Refactor webrtc audio management
Attempts to:

1) Successfully play ringtone through speaker instead of earpiece
   when possible.

2) Manage bluetooth headset connectivity as well as possible

3) Eliminate notification sounds while in-call when possible

4) Make sure audio is correctly setup when receiving calls

Fixes #6271
Fixes #6248
Fixes #6238
Fixes #6184
Fixes #6169

// FREEBIE
2017-03-05 10:35:55 -08:00
Moxie Marlinspike
3904c76261 Some additional debug logging
Related #6305
// FREEBIE
2017-02-28 17:06:05 -08:00
Moxie Marlinspike
cb6e048070 Don't try to unregister for GCM if Play Services doesn't exist
Fixes #6314
// FREEBIE
2017-02-28 16:59:15 -08:00
Moxie Marlinspike
9b8719e2d5 Support for website distribution build with auto-updating APK
// FREEBIE
2017-02-27 23:53:36 -08:00
Moxie Marlinspike
79e925051a Support for attachment digests
// FREEBIE
2017-02-26 11:16:01 -08:00
Moxie Marlinspike
a37d2f568c Update webrtc to M57
// FREEBIE
2017-02-26 11:16:01 -08:00
Moxie Marlinspike
e92b51ed98 Run webrtc calls as foreground service
Should hopefully stop performance degredation when in background

Fixes #6249
// FREEBIE
2017-02-26 11:16:01 -08:00
Moxie Marlinspike
cb9f225f59 Don't start VideoCapturer until video enabled.
Should help with battery consumption on audio-only calls

Fixes #6259
// FREEBIE
2017-02-26 11:16:01 -08:00
Moxie Marlinspike
f4a7f354c5 Bump version to 3.30.4
// FREEBIE
2017-02-26 10:51:13 -08:00
Moxie Marlinspike
8f96cff104 Don't let outgoing messages trigger last seen divider
Closes #6306
// FREEBIE
2017-02-26 10:49:48 -08:00
Siloportem
1d3f1cc79e Revert "Fixing broken unit test for ConversationAdapter"
Fixes #6250
Commit 7286fd9 that broke this unit test was reverted so the change to
this unit test has also to be reverted since the unit test currently
fails.

Closes #6308
This reverts commit 11463d410d.
2017-02-26 10:13:15 -08:00
Christian Ascheberg
25daf01307 Fix unread messages timestamp comparison
Closes #6302
// FREEBIE
2017-02-26 10:11:37 -08:00
Moxie Marlinspike
741066a10e Bump version to 3.30.3
// FREEBIE
2017-02-24 17:28:49 -08:00
Christian Ascheberg
44bb2c7c72 Do not call Notification.setSound with empty ringtone
Closes #6293
// FREEBIE
2017-02-24 17:27:25 -08:00
Moxie Marlinspike
65c05e0388 Fix outbound calls for non-play-services users
Fixes #6272
// FREEBIE
2017-02-23 10:07:12 -08:00
Moxie Marlinspike
8cd50d1e82 Update last seen state on desktop sync send
// FREEBIE
2017-02-22 15:05:35 -08:00
Moxie Marlinspike
2395b79bfc Bump version to 3.30.2
// FREEBIE
2017-02-22 12:48:01 -08:00
haffenloher
76ac95756f Fix last seen divider crash on Android <5.0
Apparently, it's not possible to reference an attribute in an xml
drawable on API <21, so we have to use separate light and dark theme
drawables instead.

Closes #6285
2017-02-22 17:57:42 +01:00
Moxie Marlinspike
d9659219de Bump version to 3.30.1
// FREEBIE
2017-02-21 22:34:46 -08:00
Moxie Marlinspike
bdc464193d Adjust last seen divider on read sync
Fixes #6273
// FREEBIE
2017-02-21 22:33:16 -08:00
Moxie Marlinspike
b43beaab75 Reduce size of new message divider, adjust style slightly
// FREEBIE
2017-02-21 12:55:44 -08:00
Moxie Marlinspike
4ee607878c Fix unread message conversation separator for dark theme
Fixes #6265
// FREEBIE
2017-02-21 12:37:40 -08:00
Moxie Marlinspike
a0489a9f48 Bump version to 3.30.0
// FREEBIE
2017-02-20 16:45:03 -08:00
Moxie Marlinspike
8aab9b0fc1 Fix build (grr)
// FREEBIE
2017-02-20 16:44:25 -08:00
Moxie Marlinspike
4bd3841788 Updated language translations
// FREEBIE
2017-02-20 15:32:59 -08:00
Moxie Marlinspike
b27d829013 Extract some strings for localization
// FREEBIE
2017-02-20 13:59:23 -08:00
Moxie Marlinspike
1669731329 Support for using Signal without Play Services
This is now possible with beta calling, so non-GCM users are a
part of beta calling by default.

// FREEBIE
2017-02-20 12:00:03 -08:00
Moxie Marlinspike
4112f23f33 Remove item animations on conversation list recyclerview
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
eddb97013a Disable proximity lock when local video is enabled
Fixes #6179
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
a075bf7505 Don't scroll to last seen until the recyclerview has been measured
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
acca4a72d3 Improve default SMS subscription id intelligence
Fixes #5266
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
1b1470aae2 Upgrade to EventBus 3.X
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
d5b7ff58e2 Fix for last_seen crash when archive placeholder is visible
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
d2eebbc55a Little bit of extra SmsListener logging
Related #5253
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
cf891edce9 Should fix "locked message" on reminder notification issue
Fixes #5782
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
f541e33356 Publish TURN-only ICE candidates in some situations
1) Incoming call is from a number not in user's address book

2) Turn-only preference is enabled for all incoming/outgoing calls

// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
aa30f3e410 Revert "Don't use SHA1 for stable IDs"
This reverts commit 7286fd9b06.

Fixes #6223
// FREEBIE
2017-02-19 12:29:33 -08:00
haffenloher
83e31cac07 Show videos in media overview
Fixes #5941
Closes #6152
// FREEBIE
2017-02-19 12:29:33 -08:00
FeuRenard
98d223f094 Don't display date for drafts in media preview
Closes #6208
// FREEBIE
2017-02-19 12:29:33 -08:00
RiseT
917389131c Fix some wording for group conversations
Closes #6204
Fixes #6193

// FREEBIE
2017-02-19 12:29:33 -08:00
Nicholas Rizzio
e1f09e0437 Debloat ConversationAdapter's tag
getName() includes the full package name, which adds a ridiculous
amount of text to the debug log. Using getSimpleName() is in line with
the rest of the repository.

Closes #6202
// FREEBIE
2017-02-19 12:29:33 -08:00
Mattias Eriksson
0f820e6beb Re-add Android Auto manifest entry
Voice reply is now verified to work,
so it should be safe to re-add the
Android Auto manifest entry.

Closes #6180
//FREEBIE
2017-02-19 12:29:33 -08:00
Mattias Eriksson
e2d94adfdb Add Intent.FLAG_INCLUDE_STOPPED_PACKAGES
Add Intent.FLAG_INCLUDE_STOPPED_PACKAGES to Android Auto intents to
match https://developer.android.com/training/auto/messaging/index.html

// FREEBIE
2017-02-19 12:29:33 -08:00
brumsel
c594691b93 Fix resend buttons being shown when they shouldn't
Correctly set the IS_PUSH_GROUP_EXTRA flag for MessageDetailsActivities
started by selecting a message and pressing the (i) icon in the action
bar

Closes #6171
Fixes #3582

// FREEBIE
2017-02-19 12:29:33 -08:00
haffenloher
9395f7faa0 Correct PushGroupUpdateJob's TAG
Closes #6166

// FREEBIE
2017-02-19 12:29:33 -08:00
haffenloher
9c1f7f1657 Make VideoPlayer toast error message translatable
Closes #6150
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
8bf160532e Make safety numbers singular in webrtc call screen
Closes #6148
// FREEBIE
2017-02-19 12:29:33 -08:00
Christian Ascheberg
1aa2d546d2 enable silent per recipient ringtone preference
Closes #4957
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
143fb1fe21 Make header decorations play well together
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
d9b42c4369 Support for a "new messages" divider in conversations
// FREEBIE
2017-02-19 12:29:33 -08:00
Moxie Marlinspike
0075940050 Delete archived sessions on identity change
// FREEBIE
2017-02-19 12:29:08 -08:00
Moxie Marlinspike
7d10560575 Workaround android SurfaceView bug
Fixes #6225
// FREEBIE
2017-02-16 13:01:45 -08:00
Moxie Marlinspike
0adce89eec Bumped version to 3.29.6
// FREEBIE
2017-02-13 23:01:43 -08:00
Moxie Marlinspike
be53bc6138 Updated language translations
// FREEBIE
2017-02-13 23:01:32 -08:00
Moxie Marlinspike
e25d31ceb6 Disable webrtc calling for Gingerbread users
Fixes #6220
// FREEBIE
2017-02-13 22:55:06 -08:00
Moxie Marlinspike
70d94c0130 Bump version to 3.29.5
// FREEBIE
2017-02-12 20:24:22 -08:00
Moxie Marlinspike
55c1b6d72c Updated language translations
// FREEBIE
2017-02-12 20:24:00 -08:00
Moxie Marlinspike
42211ccca6 Bump version to 3.29.4
// FREEBIE
2017-02-12 16:54:31 -08:00
Moxie Marlinspike
0efd6d9341 Don't use AsyncTask for beta calling capabilities refresh
Also, actually store the result in the directory db.

Fixes #6212
// FREEBIE
2017-02-12 11:27:26 -08:00
Moxie Marlinspike
6b737a3d48 Bump version to 3.29.3
// FREEBIE
2017-02-11 21:11:28 -08:00
Moxie Marlinspike
f3e47f7b60 Support for minimized controls during video call
// FREEBIE
2017-02-11 20:48:42 -08:00
Moxie Marlinspike
6b8336db06 Blacklist Nexus 6p from hardware AEC
// FREEBIE
2017-02-08 23:40:22 -08:00
Moxie Marlinspike
739ee89fb1 Bump version to 3.29.2
// FREEBIE
2017-02-05 13:02:55 -08:00
Moxie Marlinspike
fb8440f886 Correctly manage busy state for (webrtc, redphone, pstn) tuple
Fixes #6156
// FREEBIE
2017-02-05 12:38:08 -08:00
Moxie Marlinspike
d92cbfe305 More intelligent default behavior with speakerphone and wired headset
When video is enabled, speakerphone is now enabled unless
there's a wired headset.  If speakerphone is enabled and
a wired headset gets plugged in, speakerphone is disabled.
If video is enabled and a wired headset is removed, speakerphone
is enabled.

Fixes #6153
// FREEBIE
2017-02-03 12:01:03 -08:00
Moxie Marlinspike
5cfd7477ab Keep websocket connection open during call
// FREEBIE
2017-02-03 11:59:10 -08:00
Moxie Marlinspike
0992d6545e Don't sleep screen in calls
Fixes #6141
// FREEBIE
2017-02-02 19:02:26 -08:00
Moxie Marlinspike
7d644ae9c6 Run local hangup events through view model
Fixes #6143
// FREEBIE
2017-02-02 18:53:45 -08:00
Moxie Marlinspike
9a93a8b28d Better support for building webrtc call view off of model
Fixes #6144
// FREEBIE
2017-02-02 18:46:34 -08:00
Moxie Marlinspike
8dc6f2b15b Mark egl resources as freed in webrtc terminate
Fixes #6138
// FREEBIE
2017-02-01 22:55:19 -08:00
Moxie Marlinspike
f148ff8bfa Bump version to 3.29.1
// FREEBIE
2017-02-01 18:37:57 -08:00
Moxie Marlinspike
2408bd4d65 Fix for groups crash when beta calling enabled
Fixes #6137
// FREEBIE
2017-02-01 18:30:53 -08:00
Moxie Marlinspike
94c61f8af9 Bump version to 3.29.0
// FREEBIE
2017-02-01 13:57:19 -08:00
Benedikt Constantin Radtke
85aa5c5b97 use canonical number when sending blocked updates
MultiDeviceBlockedUpdates now send e164 numbers instead
 of localized ones.

Fixes #6093
Closes #6109
// FREEBIE
2017-02-01 13:55:52 -08:00
FeuRenard
c88a0ba324 Fix linkifying in selection mode
Fixes #6106
Closes #6108
// FREEBIE
2017-02-01 13:55:52 -08:00
Stuart Gilbert
11463d410d Fixing broken unit test for ConversationAdapter
The unit test for ConversationAdapter.getItemId() was
broken by this change: 7286fd9

Fixes #6088
// FREEBIE
2017-02-01 13:55:52 -08:00
Moxie Marlinspike
53d590947e Force capability refresh on conversation load if in webrtc beta
// FREEBIE
2017-02-01 13:55:52 -08:00
Moxie Marlinspike
ea0945d406 Beta support for webrtc video and voice calling
// FREEBIE
2017-02-01 13:55:52 -08:00
Moxie Marlinspike
a9651e2e9c Bump version to 3.28.4
// FREEBIE
2017-01-31 21:55:33 -08:00
Moxie Marlinspike
9afbdaa2be Don't let failed capability retrieval erroneously disable SMS
Fixes #6135
// FREEBIE
2017-01-31 21:46:20 -08:00
Moxie Marlinspike
bdc8618889 Bump version to 3.28.3
// FREEBIE
2017-01-30 19:19:26 -08:00
Moxie Marlinspike
a2de60a75c Remove Android Auto manifest entry to get past the reviewers
(There are reviewers now?)

Related #6124
// FREEBIE
2017-01-30 19:17:17 -08:00
Moxie Marlinspike
b2e93ec502 Bump version to 3.28.2
// FREEBIE
2017-01-29 13:34:51 -08:00
Moxie Marlinspike
4fb8d1fa49 Fix for NPE when MMS From is absent
Fixes #6115
// FREEBIE
2017-01-29 13:16:51 -08:00
Moxie Marlinspike
67cab3ce86 Fix illegalargumentexception on rotate
Fixes #6118
// FREEBIE
2017-01-29 13:02:59 -08:00
Moxie Marlinspike
3be55e36d9 Bump version to 3.28.1
// FREEBIE
2017-01-26 12:08:23 -08:00
Moxie Marlinspike
cee0edff7c Updated language translations
// FREEBIE
2017-01-26 12:08:04 -08:00
Moxie Marlinspike
15a389c171 Don't calculate date header item for adapter header
Fixes #6098
// FREEBIE
2017-01-25 18:00:26 -08:00
Moxie Marlinspike
d46d3b72c8 Make the sticky date header only visible during scroll
// FREEBIE
2017-01-25 16:38:36 -08:00
Moxie Marlinspike
2e16c6cf41 Bump version to 3.28.0
// FREEBIE
2017-01-24 18:31:35 -08:00
Moxie Marlinspike
03e2075ba4 Updated language translations
// FREEBIE
2017-01-24 17:54:19 -08:00
Moxie Marlinspike
d9f19fe36c Move scroll-to-bottom arrow placement up slightly
// FREEBIE
2017-01-24 17:51:32 -08:00
Moxie Marlinspike
b575b4e6ae Fix for intermittent crash
// FREEBIE
2017-01-24 17:51:32 -08:00
Moxie Marlinspike
342fd37799 Updated language translations
// FREEBIE
2017-01-24 11:11:53 -08:00
Moxie Marlinspike
e2b81c9637 Update look and feel of fast-scroll-to-bottom
Closes #6086
// FREEBIE
2017-01-24 11:05:32 -08:00
Stuart Gilbert
aa9d8e4d14 Add scroll to bottom button in conversation view
Added a FloatingActionButton to the conversation_fragment
that appears and disappears using the same logic as the
existing compose divider: appear when the conversation list
is scrolled away from the bottom, disappear when the list is
scrolled to the bottom.

Fixes #5651
2017-01-24 11:05:03 -08:00
Moxie Marlinspike
4c815db076 Support for sticky date headers
Closes #4696
// FREEBIE
2017-01-23 16:44:38 -08:00
Moxie Marlinspike
b677370597 Apparently this doesn't work in Cuba
// FREEBIE
2017-01-23 10:46:57 -08:00
Moxie Marlinspike
f53d64ab7a Remove ShortcutBadger "default launcher" junk
// FREEBIE
2017-01-22 22:45:58 -08:00
Benedikt Constantin Radtke
4461ebf662 check if image decoding succeeded before using the result
Fixes #6061
Closes #6080
// FREEBIE
2017-01-22 22:05:27 -08:00
Moxie Marlinspike
21a0fe3a48 Don't return unresolved asynchronous recipients for non-async callers
Fixes #6082
// FREEBIE
2017-01-22 21:57:23 -08:00
Moxie Marlinspike
dadc8d0183 Refactor "unnamed" group logic
// FREEBIE
2017-01-22 21:23:51 -08:00
Moxie Marlinspike
7e51d61c79 Ignore duplicate signal messages
Fixes #5579

// FREEBIE
2017-01-22 14:47:02 -08:00
john gravois
47aa7979b2 small CONTRIBUTING copyedits
Closes #6067
// FREEBIE
2017-01-21 10:32:11 -08:00
Nicholas Rizzio
da05cf9192 Use HTTPS for all support links
support.whispersystems.org is now available through TLS, but is not
included in the HSTS preload list. Hence, these links are vulnerable
to SSL stripping until the user visits the site over HTTPS for the
first time. Changing these links to https:// ensures that the user
always gets the encrypted version of the support website.

Closes #6056
// FREEBIE
2017-01-21 10:20:58 -08:00
Piotr Prucia
970448d43d Disable AudioView controls clicks when message is selected
Fixes: #5898
Closes #6054
2017-01-21 10:18:18 -08:00
RiseT
333a0f38e3 Remove one ellipsis I've overlooked in #5887
Closes #6052
// FREEBIE
2017-01-21 10:13:40 -08:00
Moxie Marlinspike
86df150374 Update ShortcutBadger
Fixes #6069
// FREEBIE
2017-01-21 10:06:49 -08:00
Moxie Marlinspike
235a8472d9 Remove dedicated MMS download controls
// FREEBIE
2017-01-20 15:26:17 -08:00
Moxie Marlinspike
183f8742a7 ViewStub for ThumbnailView in ConversationItem
// FREEBIE
2017-01-20 10:27:18 -08:00
Moxie Marlinspike
e270e8d429 ViewStub for AudioView in ConversationItems
// FREEBIE
2017-01-20 09:11:40 -08:00
Moxie Marlinspike
7286fd9b06 Don't use SHA1 for stable IDs
// FREEBIE
2017-01-19 19:06:46 -08:00
Moxie Marlinspike
9f2328457e Mark application largeHeap
// FREEBIE
2017-01-19 18:42:17 -08:00
Moxie Marlinspike
f2a9b02b5e Add a little timing information
// FREEBIE
2017-01-19 11:47:02 -08:00
Moxie Marlinspike
41c9bed155 ViewStub for EmojiDrawer
// FREEBIE
2017-01-19 11:47:02 -08:00
Moxie Marlinspike
508a666e76 ViewStub for ReminderView, lazy create AttachmentTypeSelector
// FREEBIE
2017-01-19 11:47:02 -08:00
Moxie Marlinspike
3d6cbdd775 ViewStub for entire AttachmentManager
// FREEBIE
2017-01-19 11:47:02 -08:00
Moxie Marlinspike
4906bdbdcc Make default SMS provider lookup asynchronous
// FREEBIE
2017-01-18 11:01:13 -08:00
Moxie Marlinspike
f0b615eda6 Bump version to 3.27.1
// FREEBIE
2017-01-17 20:57:22 -08:00
Moxie Marlinspike
0a25c3a33d Updated language translations
// FREEBIE
2017-01-17 20:56:56 -08:00
Moxie Marlinspike
bbb8ac113b Disable image keyboards for SDK < 5.0
Fixes #6045
// FREEBIE
2017-01-17 20:46:20 -08:00
Moxie Marlinspike
360c2b2a50 This attempts to work around a ROM crash bug
getActiveNotifications() seems to throw an NPE on some Motorola
ROMs, all of which appear to be 6.0.1.  This change just swallows
the exception.

6.0 doesn't support bundled notifications, so I think it's alright
if they don't get canceled, since the summary notification will
still be displayed correctly.

This would only affect users who have an android wear device
attached to one of these buggy ROMs. By swallowing this exception,
they would not always get notifictions dismissed on their wear
 device.

Fixes #6043
// FREEBIE
2017-01-17 20:41:24 -08:00
Moxie Marlinspike
cfef855d99 Bump version to 2.27.0
// FREEBIE
2017-01-13 18:06:41 -08:00
Moxie Marlinspike
80503067e9 Updated language translations
// FREEBIE
2017-01-13 18:06:19 -08:00
Moxie Marlinspike
9779604932 Had to re-publish signal-service dependency
// FREEBIE
2017-01-13 16:38:45 -08:00
Moxie Marlinspike
c6d6e0e97e Updated language translations
// FREEBIE
2017-01-12 16:37:30 -08:00
Moxie Marlinspike
edac0e85c7 Fix non-thread-safe operations on canonical id cache
// FREEBIE
2017-01-12 16:06:14 -08:00
Moxie Marlinspike
fd3d02d818 Fix typo
// FREEBIE
2017-01-12 12:26:50 -08:00
Veeti Paananen
25f9bef74c Display elapsed voice recording time in user language
Closes #6011
// FREEBIE
2017-01-12 11:49:47 -08:00
Veeti Paananen
4dae4444bc Fix right-to-left language support for voice recording
Bug: fixes #5999

// FREEBIE
2017-01-12 11:47:43 -08:00
RiseT
49e78d16ba Remove redundant ellipses in strings according to Material guidelines
Quote :
"Use to indicate an action in progress ("Downloading…") or
 incomplete or truncated text. No space before the ellipses.

 Omit from menu items or buttons that open a dialog or start
  some other process.

 Midline ellipses (three-bullet glyphs) are also used to represent
 numeric truncation and the redaction of sensitive data, such as
 credit cards."

 https://material.google.com/style/writing.html

Closes #5887
// FREEBIE
2017-01-12 10:38:49 -08:00
Moxie Marlinspike
cb23e3a930 Untrusted identity is not always a legacy message content
Closes #5924
Fixes #5922
// FREEBIE
2017-01-12 10:33:23 -08:00
Niklas Wenzel
770026d4ee Fix the faulty tests in AttachmentDatabaseTest.java
Fixes #5948
Closes #5952
2017-01-12 10:23:35 -08:00
Moxie Marlinspike
7b928476a2 Make sure recipients are fully resolved, limit size of results
// FREEBIE
2017-01-12 09:52:24 -08:00
Moxie Marlinspike
a125fcb8fa Support for direct share targets
Fixes #4333
// FREEBIE
2017-01-11 19:54:58 -08:00
FeuRenard
bd819d7d10 Disable verify button if no message was exchanged
Fixes #5878
Closes #5951
// FREEBIE
2017-01-11 18:51:11 -08:00
Piotr Prucia
e5fcc465c9 Fixed action bar title not being translated after language change
Fixes #6009
Closes #6010
// FREEBIE
2017-01-11 18:46:08 -08:00
Moxie Marlinspike
94a29e375f Specify ConnectionSpecs for domain fronts
// FREEBIE
2017-01-11 15:37:51 -08:00
Moxie Marlinspike
ec5ac44cd3 Update okhttp and support for transmitting messages over websocket
// FREEBIE
2017-01-10 13:59:32 -08:00
Moxie Marlinspike
ac2626437e Bump version to 3.26.2
// FREEBIE
2017-01-09 08:00:53 -08:00
Moxie Marlinspike
99b8cfc82b Include missing cardview dependency
Fixes #6026
// FREEBIE
2017-01-09 07:51:56 -08:00
Moxie Marlinspike
6eef1a6ee4 Bump version to 3.26.1
// FREEBIE
2017-01-08 13:11:48 -08:00
Moxie Marlinspike
4ad989cc38 Fix rounded corners bitmap double free
Fixes #4732
// FREEBIE
2017-01-08 13:06:11 -08:00
Moxie Marlinspike
5804213152 Eliminate item animations in ConversationFragment
Experience feels faster this way too

// FREEBIE
2017-01-08 10:16:23 -08:00
Moxie Marlinspike
d599c058c6 No choice but to multiDex
// FREEBIE
2017-01-08 09:58:01 -08:00
Moxie Marlinspike
b7d4294314 This is no longer testable =(
// FREEBIE
2017-01-07 11:36:50 -08:00
Moxie Marlinspike
d280604f1f Fix compileSdk 25 problems with GIF search
For #5965
// FREEBIE
2017-01-07 11:02:18 -08:00
AsamK
7817e38e5f Fix crash when clicking on a gif image
For gif images, the dimensions is always null.

Closes #6021
//FREEBIE
2017-01-07 10:40:22 -08:00
Moxie Marlinspike
f310dd6047 Update Play Services
Apparently we've put this off for as long as we can

Fixes #6018
// FREEBIE
2017-01-06 18:00:40 -08:00
Moxie Marlinspike
30633c9672 Bump version to 3.26.0
// FREEBIE
2017-01-06 11:48:49 -08:00
Moxie Marlinspike
16c44812c8 Update Dockerfile to support new compileSdk target
// FREEBIE
2017-01-06 11:48:35 -08:00
Moxie Marlinspike
1a57ff16cd Updated language translations
// FREEBIE
2017-01-06 11:36:02 -08:00
Moxie Marlinspike
c3451d19db This doesn't work in Iran
// FREEBIE
2017-01-06 09:40:04 -08:00
Moxie Marlinspike
bb5dcb7131 Start increasing frequency of signed prekey rotation
// FREEBIE
2017-01-06 09:19:58 -08:00
Moxie Marlinspike
884d8b7f72 Store display name in Signal contacts
Fixes #5974
// FREEBIE
2017-01-05 12:42:28 -08:00
Moxie Marlinspike
57cdbaedd6 Remove EXTRA_SUBJECT from safety number share.
Negatively impacts share through email slightly, positively
impacts share through a few other mechanisms somewhat
significantly.

Fixes #5959
// FREEBIE
2017-01-03 13:57:09 -08:00
Moxie Marlinspike
3861084ea2 Disable expiration menu on inactive group
Fixes #6007
// FREEBIE
2017-01-03 13:51:29 -08:00
Piotr Prucia
bb1ab2e929 Added Iran to domain fronting list
Fixes #5992
Closes #6006
// FREEBIE
2017-01-02 17:22:24 -08:00
Ali Makki
5a6e75a7e1 +968 uses google.com.om +53 uses google.com.cu
Closes #6001
2017-01-02 17:18:42 -08:00
Moxie Marlinspike
d2be49af42 Support for tiling image view and large image viewing
Fixes #5949
Fixes #5574
Fixes #4380
// FREEBIE
2017-01-02 17:17:48 -08:00
FeuRenard
477589b092 Color passphrase prompt text field blue
Closes #5424
// FREEBIE
2017-01-02 17:17:48 -08:00
Benedikt Constantin Radtke
a6488b3652 fix zero length attachments crashing signal
Fixes #5331
Closes #5926
2017-01-02 17:17:48 -08:00
FeuRenard
cde92256a6 Convert file save toast string to plural
Closes #5961
// FREEBIE
2017-01-02 17:17:48 -08:00
Echo
47f1f0b9a0 Update crowdfunding link
Closes #5984
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
a3019be7b6 Support for image keyboards
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
373a0f9527 Support for Android N direct reply notifications
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
a9bd84c69c Support for bundled notifications (Android wear and Android N)
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
0c6bfdbd0d Improve canonical address database caching
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
cdf3a849e9 Reduce DB updates on send path, move support SDK up to 24
// FREEBIE
2017-01-02 17:17:48 -08:00
Moxie Marlinspike
4e32fb21fe Bump version to 3.25.4
// FREEBIE
2016-12-30 08:47:10 -08:00
Moxie Marlinspike
ae40715526 Support for expanded domain fronting strategies
// FREEBIE
2016-12-29 20:54:05 -08:00
Moxie Marlinspike
7488525641 Add Cuba and Oman to domain fronting list
// FREEBIE
2016-12-21 14:28:41 -08:00
Moxie Marlinspike
fd00298930 Bump version to 3.25.3
// FREEBIE
2016-12-21 09:59:40 -08:00
Moxie Marlinspike
f3f2f29b23 Fix avatar download crash bug
Fixes #5980
// FREEBIE
2016-12-21 09:58:45 -08:00
Moxie Marlinspike
d35133b3bc Bump version to 3.25.2
// FREEBIE
2016-12-20 09:56:38 -08:00
Moxie Marlinspike
541718fd11 Support for censorship circumvention in Egypt and UAE
// FREEBIE
2016-12-20 09:55:52 -08:00
Moxie Marlinspike
777aeea138 Bump version to 3.25.1
// FREEBIE
2016-12-19 11:10:42 -08:00
Moxie Marlinspike
c3ab6e6c29 Updated language translations
// FREEBIE
2016-12-19 11:10:35 -08:00
Moxie Marlinspike
c7e373ed55 Update emoji category images to fix SDK <21 tinting issues
Fixes #5973
// FREEBIE
2016-12-18 21:05:01 -08:00
Moxie Marlinspike
71f8e9eb31 Revert support library update, the future wasn't all we hoped for
Fixes #5965
// FREEBIE
2016-12-18 19:06:39 -08:00
Moxie Marlinspike
899f3af5e4 Scale down bitmap during scribble rendering on lowmem devices
Fixes #5969

// FREEBIE
2016-12-17 18:59:47 -08:00
Moxie Marlinspike
4ff8de0ca8 Remove superfluous icon and padding that came with sdk 24
Fixes #5965
// FREEBIE
2016-12-17 15:52:27 -08:00
Moxie Marlinspike
d6d3d1fee4 Bump version to 3.25.0
// FREEBIE
2016-12-16 09:59:19 -08:00
Moxie Marlinspike
9a1225fe21 Updated language translations
// FREEBIE
2016-12-16 09:59:06 -08:00
Moxie Marlinspike
5d6439030d Update Dockerfile to support new compileSdk target
// FREEBIE
2016-12-16 09:53:13 -08:00
Moxie Marlinspike
f871d83e68 No need to run this job on install
// FREEBIE
2016-12-16 09:10:44 -08:00
Moxie Marlinspike
47471f09f4 Update photoview library
Fixes #5955

// FREEBIE
2016-12-15 11:34:46 -08:00
Moxie Marlinspike
ee07a59950 Updated language translations
// FREEBIE
2016-12-15 10:44:03 -08:00
RiseT
e8555a84ac Make description strings in audio_view.xml translatable.
Closes #5916
// FREEBIE
2016-12-15 10:41:18 -08:00
Paul Lanctot
73bf75f65f Accessible content labels for attachment icons
Fixes #5908
Closes #5917
// FREEBIE
2016-12-14 20:56:37 -08:00
Moxie Marlinspike
01bc2ebde4 Don't print safety number changes in inactive groups
Fixes #5930
// FREEBIE
2016-12-14 16:20:09 -08:00
Moxie Marlinspike
b16a27c249 Update libsignal-service
Fixes #5928

// FREEBIE
2016-12-14 16:17:42 -08:00
Moxie Marlinspike
791cc4b4f8 Use downsampled GIFs for MMS messages
Fixes #5958
// FREEBIE
2016-12-14 11:58:47 -08:00
Amire80
71276161fc Remove comma splice from an English interface string 2016-12-12 17:44:04 -08:00
Moxie Marlinspike
a4c17e5325 Support for generating video thumbnails
// FREEBIE
2016-12-12 17:38:05 -08:00
Moxie Marlinspike
6308e6491a A slight foray into the modern era
// FREEBIE
2016-12-12 17:38:05 -08:00
Moxie Marlinspike
f7474362ff Updated emoji set
// FREEBIE
2016-12-12 17:37:27 -08:00
Moxie Marlinspike
1b44bdcd3c Support for stickers and scribbles
// FREEBIE
2016-12-12 17:37:00 -08:00
Moxie Marlinspike
c8fe671f9c Bump version to 3.24.1
// FREEBIE
2016-12-04 18:13:35 -08:00
Nicholas Rizzio
2197d77ffc Fix the content description of the audio record button
Fixes #5910
Closes #5911
// FREEBIE
2016-12-04 18:12:48 -08:00
Benedikt Constantin Radtke
d9ff5b00b7 fix NPE in PushGroupUpdateJob
Fixes #5919
Closes #5921
// FREEBIE
2016-12-04 18:06:25 -08:00
Moxie Marlinspike
5d341e175d Bump version to 3.24.0
// FREEBIE
2016-12-01 12:03:34 -08:00
Moxie Marlinspike
f6cbae602d Fix broken build (grrr @RiseT)
// FREEBIE
2016-12-01 12:03:01 -08:00
Moxie Marlinspike
e3a7781392 Updated language translations
// FREEBIE
2016-12-01 11:38:19 -08:00
Moxie Marlinspike
cf01959e16 Support recovering forgotten/unknown group info from sender
Closes #5876
// FREEBIE
2016-12-01 10:34:47 -08:00
FeuRenard
10abd09239 Catch up on renaming 'All images' button
Closes #5896
// FREEBIE
2016-11-28 14:57:32 -08:00
FeuRenard
3136cadf59 Use Signal's language for media preview timestamp
Fixes #3449
Closes #5600

// FREEBIE
2016-11-28 09:45:44 -08:00
FeuRenard
09ff8d5865 Add gallery button to MediaPreview
// FREEBIE
2016-11-28 09:42:26 -08:00
RiseT
43e1d452c7 Change DateUtils string 'Now' to 'Just now'
Changes the DateUtils string 'Now' to 'Just now' which is a better fit
imho.
Used for messages in the conversation view that e. g. just have been
received.

// FREEBIE

Closes #5761
2016-11-28 09:16:38 -08:00
Moxie Marlinspike
ed8215de81 Move null recipients check
// FREEBIE

Closes #5800
2016-11-28 09:14:44 -08:00
Moxie Marlinspike
69b102bfe3 Support for playing video in-app
// FREEBIE

Closes #5892
2016-11-27 19:38:59 -08:00
Moxie Marlinspike
8b342ee18b Support for "recent photos" thumbnailsabove attachment selector
// FREEBIE

Closes #5893
2016-11-27 19:37:31 -08:00
RiseT
e8ae6d67b1 Change safety number strings to be singular
// FREEBIE

Closes #5894
2016-11-27 19:35:54 -08:00
Mattias Eriksson
9148b7da5f Initial Android Auto support
This adds android auto support accordign to
https://developer.android.com/training/auto/messaging/index.html#messaging
However, since android auto is not officially supported in my country,
the functionality is limited. Which means that I have not been able
to fully test everything yet.

What work is:
* Message notification is shown.
* When you click on it, the message is read.

Closes #5880
2016-11-27 19:33:11 -08:00
Moxie Marlinspike
ce812ed8ba Bump version to 3.23.0
// FREEBIE
2016-11-24 09:11:37 -08:00
Moxie Marlinspike
030df09f67 Updated language translations
// FREEBIE
2016-11-24 09:05:16 -08:00
zaprice
794e2cb872 Do not disable multiline input when enter key sends
Fixes #5264
Closes #5783
2016-11-24 08:31:12 -08:00
Niklas Wenzel
0d493a3af9 Get the automated tests up and running again
* Fix the build.gradle file
* Use the correct VisibleForTesting class
* Fix the Android test setUp() logic
* Enable a test in DeliveryReceiptJobTest.java where the @Test anotation was missing

It should be noted that the tests in AttachmentDatabaseTest.java fail.

Fixes #3474
Closes #5882
2016-11-24 08:13:46 -08:00
Moxie Marlinspike
3787551878 Squelch notifications for active desktop converastions
Additionally, limit audible notifications to once every 2 seconds.

// FREEBIE

Fixes #4905
Fixes #3165
Closes #5813
2016-11-24 08:09:34 -08:00
Moxie Marlinspike
7c0dacc627 Updated language translations
// FREEBIE
2016-11-22 21:46:36 -08:00
Moxie Marlinspike
8af9b7fd15 Improve animations on audio controls, enable push to talk
// FREEBIE
2016-11-21 18:58:10 -08:00
FeuRenard
3e008f6752 Hide linked devices pref for unregistered users
Fixes #4860
Closes #5872
// FREEBIE
2016-11-21 09:53:36 -08:00
Moxie Marlinspike
8fdcff9f20 If Signal isn't enabled for receiving SMS, don't allow sending SMS
Closes #5877
// FREEBIE
2016-11-21 08:56:21 -08:00
Moxie Marlinspike
7947222ac5 Bump version to 3.22.2
// FREEBIE
2016-11-14 19:55:19 -08:00
Moxie Marlinspike
f4b5daabdb Updated language translations
// FREEBIE
2016-11-14 19:53:56 -08:00
Moxie Marlinspike
b55a7ff5c0 Add copy and compare safety numbers from clipboard actions
// FREEBIE
2016-11-14 19:50:29 -08:00
Moxie Marlinspike
ca3337232b Bump version to 3.22.1
// FREEBIE
2016-11-14 13:41:12 -08:00
Moxie Marlinspike
7d98b85ae7 Updated language translations
// FREEBIE
2016-11-14 13:40:24 -08:00
Moxie Marlinspike
c5bf84cf9c Make blocking SN changes the default for now
// FREEBIE
2016-11-14 13:36:48 -08:00
Moxie Marlinspike
fd0acf4e00 Bump version to 3.22.0
// FREEBIE
2016-11-13 18:18:39 -08:00
Moxie Marlinspike
95a6c41b6e Update dependency
// FREEBIE
2016-11-13 18:18:22 -08:00
Moxie Marlinspike
06325470ce Updated language translations
// FREEBIE
2016-11-13 17:35:34 -08:00
Moxie Marlinspike
cb28e7c1f9 Update libsignal-service to 2.4.0
// FREEBIE
2016-11-13 10:58:51 -08:00
FeuRenard
92aeafc261 Add share button for safety numbers
Fixes #5798
Closes #5854
// FREEBIE
2016-11-13 10:42:40 -08:00
Moxie Marlinspike
0abe56171a Enable non-blocking safety number changes
// FREEBIE
2016-11-11 19:07:35 -08:00
Corey Hunter
9064c02fa8 Improve #3990
By catching the crash Signal remains unlocked. The user can quickly
retry sharing from the previous app and it will work, rather than
having to return to the home screen and unlock Signal.

Closes #5805

// FREEBIE
2016-11-11 18:44:22 -08:00
FeuRenard
f5966af781 Allow 2nd person conjugation in timer messages
Fixes #5658
// FREEBIE
2016-11-11 18:37:16 -08:00
RiseT
2d104d3783 "No results found." --> "Nothing found"
Closes #5814

// FREEBIE
2016-11-11 18:34:03 -08:00
Amire80
5d1cfb50a9 Change "GiF" to "GIF" in an English user interface string
Closes #5830
2016-11-11 18:14:31 -08:00
FeuRenard
a3244de587 Add forward button to MediaPreview
Closes #5833
Related to #4906
// FREEBIE
2016-11-11 18:03:20 -08:00
FeuRenard
0945b19364 Recycle correctly instead of turning it off
Closes #5841
Fixes #5831
2016-11-11 17:57:29 -08:00
FeuRenard
06b1045e09 Lower memory consumption of Giphy browser
Fixes #5831
// FREEBIE
2016-11-06 17:45:23 +01:00
Moxie Marlinspike
0396494d57 Bump version to 3.21.3
// FREEBIE
2016-11-01 09:03:21 -07:00
Moxie Marlinspike
971bcb8213 Updated language translations
// FREEBIE
2016-11-01 09:03:02 -07:00
Moxie Marlinspike
4bf3632b40 Better null result handling
// FREEBIE
2016-11-01 09:01:10 -07:00
Moxie Marlinspike
469f41b955 Fix NPE
Fixes #5829
// FREEBIE
2016-11-01 08:53:54 -07:00
Moxie Marlinspike
80a96aa83c Bump version to 3.21.2
// FREEBIE
2016-10-29 11:06:07 -07:00
Moxie Marlinspike
0e5d71e1a5 Updated language translations
// FREEBIE
2016-10-29 11:05:55 -07:00
Moxie Marlinspike
9d3b764fec Missed some glide caching
Fixes #5817
// FREEBIE
2016-10-28 12:30:50 -07:00
Moxie Marlinspike
16f277761e Use smaller gifs to improve load time
// FREEBIE
2016-10-27 18:06:16 -07:00
Moxie Marlinspike
9170020141 Bump version to 3.21.1
// FREEBIE
2016-10-27 11:51:29 -07:00
Moxie Marlinspike
1ef5e5eb52 Updated language translations
// FREEBIE
2016-10-27 11:51:06 -07:00
Moxie Marlinspike
11dbb82bf1 Close giphy keyboard when search button is pressed
Fixes #5807
// FREEBIE
2016-10-26 17:24:56 -07:00
Moxie Marlinspike
2bcbbb0601 Bump version to 3.21.0
// FREEBIE
2016-10-25 13:41:33 -07:00
Moxie Marlinspike
ab00ce7455 Updated language translations
// FREEBIE
2016-10-25 13:41:04 -07:00
Moxie Marlinspike
b54a271a75 Bump up push media max edge to 2048 and max size to 4MB
Fixes #672
// FREEBIE
2016-10-25 12:43:48 -07:00
haffenloher
23544fae8a Increase JPEG quality & slow down quality decrease
Related #672
Closes #5772

//FREEBIE
2016-10-25 12:23:21 -07:00
mateoeh
0a72f6b32e Add shadow under compose view on scroll
Fixes #5098
Closes #5796
// FREEBIE
2016-10-24 16:10:51 -07:00
Moxie Marlinspike
b8d938a020 Limit giphy search bar to one line
// FREEBIE
2016-10-24 14:00:56 -07:00
Moxie Marlinspike
2c7fcbed60 Only load stills for low memory devices
// FREEBIE
2016-10-24 13:51:34 -07:00
Moxie Marlinspike
69d0242574 Giphy integration
// FREEBIE
2016-10-18 10:28:42 -07:00
Moxie Marlinspike
8e9e3847b6 Bump version to 3.20.4
// FREEBIE
2016-10-10 13:36:25 -07:00
Moxie Marlinspike
66bc5e9f5b Update language translations
// FREEBIE
2016-10-10 13:35:57 -07:00
Moxie Marlinspike
8d44a145f0 Start expiration timer when marked read from notification
// FREEBIE
2016-10-10 11:13:37 -07:00
RiseT
8e1970c398 Make message and thread records for changed safety numbers translatable
Fixes #5769
Closes #5771

Makes the message and thread records for 'Your safety numbers with %s
have changed' translatable.

// FREEBIE
2016-10-10 10:16:23 -07:00
Moxie Marlinspike
38ec5647dd Don't mark expiration updates as unread
Fixes #5768
// FREEBIE
2016-10-10 10:14:12 -07:00
FeuRenard
ff2cb6935d Make 'Tap to scan' readable in dark theme
Fixes #5749
Closes #5762
//FREEBIE
2016-10-09 09:48:17 -07:00
Moxie Marlinspike
c4fd050b09 Bump version to 3.20.3
// FREEBIE
2016-10-08 14:32:35 -07:00
Moxie Marlinspike
f85ff090f5 Update language translations
// FREEBIE
2016-10-08 14:07:04 -07:00
Moxie Marlinspike
21258f244c Don't crash on recipient preference change for non-signal user
Fixes #5760
// FREEBIe
2016-10-08 14:04:33 -07:00
Moxie Marlinspike
338c0d82e1 Bump version to 3.20.2
// FREEBIE
2016-10-07 18:55:15 -07:00
Moxie Marlinspike
6708193938 Updated language translations
// FREEBIE
2016-10-07 18:54:35 -07:00
RiseT
e3da0ac908 Make 'Disappears' in message details translatable
Fixes #5755
Closes #5756

// FREEBIE
2016-10-07 10:42:05 -07:00
Moxie Marlinspike
383a266400 Fix bad projection on MMS sync read query
// FREEBIE
2016-10-07 10:41:15 -07:00
Moxie Marlinspike
dbc59bc682 Bump version to 3.20.1
// FREEBIE
2016-10-06 21:48:51 -07:00
Moxie Marlinspike
4365d7c029 Revert build tools upgrade, seems to negatively affect reproducibility
// FREEBIE
2016-10-06 21:48:29 -07:00
Moxie Marlinspike
c64966c0fb Update fingerprint view on main thread
// FREEBIE
2016-10-06 20:39:03 -07:00
Moxie Marlinspike
6422178baf Updated language translations
// FREEBIE
2016-10-06 19:59:55 -07:00
Moxie Marlinspike
7d1c5a0d40 Don't transmit SMS contact information to multi-device on change
Fixes #5710

// FREEBIE
2016-10-05 16:57:52 -07:00
Moxie Marlinspike
2f9bf27ed7 Upgrade gradle tools version
// FREEBIE
2016-10-05 16:34:01 -07:00
Moxie Marlinspike
954d795bb5 Fix for fragment transaction crash in verify identity activity
Fixes #5747

// FREEBIE
2016-10-05 16:33:19 -07:00
Moxie Marlinspike
d36d000dc5 Increase minLines on disappearing messages duration dialog
This isn't foolproof across all translations, but it's probably
the best we can do.

Fixes #5746

// FREEBIE
2016-10-05 16:17:10 -07:00
Moxie Marlinspike
e6dd5db860 Bump version to 3.20.0
// FREEBIE
2016-10-05 13:00:36 -07:00
Moxie Marlinspike
18897ffccc Update Dockerfile for new build tools
// FREEBIE
2016-10-05 12:59:04 -07:00
Moxie Marlinspike
65b482c7b0 Remove missing string
// FREEBIE
2016-10-05 12:58:38 -07:00
Moxie Marlinspike
da029ebc24 Update language translations
// FREEBIE
2016-10-05 12:37:54 -07:00
Moxie Marlinspike
549e45e2d6 Disable non-blocking identity changes for iOS compat
// FREEBIE
2016-10-05 10:27:32 -07:00
Moxie Marlinspike
5ed1c9c72b Fix for expiration update sync sent messages
// FREEBIE
2016-10-03 12:48:30 -07:00
Christian Ascheberg
314dd9181c Fix timer update group notification expiry
Closes #5727
// FREEBIE
2016-10-02 22:43:21 -07:00
Moxie Marlinspike
68b48ebe00 Start disappearing message timer on read sync messages
Fixes #5733
// FREEBIE
2016-10-02 12:08:30 -07:00
Brinly Taylor
8b9e0b7ab8 Fix typo that breaks build.
// FREEBIE
2016-09-27 15:59:08 +10:00
Moxie Marlinspike
14d73d82c3 Enable disappearing message controls
// FREEBIE
2016-09-25 20:04:13 -07:00
Moxie Marlinspike
2b4d41de03 Safety number string fixes
// FREEBIE
2016-09-25 19:50:03 -07:00
paolo.ingls@gmail.com
4cb4a76e33 Added Samsung multi window support
Closes #5714
//FREEBIE
2016-09-25 19:22:36 -07:00
FeuRenard
d00441e20d Implement onStartLoading() in DeviceListLoader
Fixes #4641
Closes #5682
// FREEBIE
2016-09-25 14:58:27 -07:00
RiseT
8fe96fc1b7 String improvement: Blocking and unblocking contacts
This fixes/improves several strings related to blocking and unblocking
contacts regarding:

- Wording consistency
- Compliance with Google's Design Guidelines
- Clarity

Closes #5696
// FREEBIE
2016-09-25 14:55:03 -07:00
RiseT
33a79dde06 Fix string: Adding group members
This changes the string "Add member" to "Add members" as the
corresponding list is multi-selectable.

Closes #5697
// FREEBIE
2016-09-25 14:51:21 -07:00
FeuRenard
442a8b5c7d Use contact color in VerifyIdentityActivity
Fixes #3630
Closes #5664
// FREEBIE
2016-09-25 14:42:48 -07:00
Moxie Marlinspike
48d6d1c21d Canonicalize numbers in fingerprint scan
Closes #5693
Closes #5646

// FREEBIE
2016-09-25 14:36:26 -07:00
Moxie Marlinspike
666cdb39a4 Add identity changed notification even in blocking mode
// FREEBIE
2016-09-25 14:27:40 -07:00
Moxie Marlinspike
848a25664b Make fingerprint changes optionally non-blocking
Also complete the rename from "identity" to "safety numbers."

// FREEBIE
2016-09-25 14:27:40 -07:00
Moxie Marlinspike
852634b294 Support for updated fingerprint format
// FREEBIE
2016-09-25 14:23:52 -07:00
Moxie Marlinspike
0619a4d3cd Bump version to 3.19.1
// FREEBIE
2016-09-20 01:28:43 -07:00
Moxie Marlinspike
cbbe25c852 Fix contact update NPE
Fixes #5704
// FREEBIE
2016-09-19 23:25:15 -07:00
Moxie Marlinspike
3ede281e5e Bump version to 3.19.0
// FREEBIE
2016-09-14 17:03:55 -07:00
Moxie Marlinspike
751830d38f Updated language translations
// FREEBIE
2016-09-14 17:03:36 -07:00
Christian Ascheberg
bd2fc82360 always set LED notification
Closes #5654
// FREEBIE
2016-09-14 16:37:28 -07:00
Christian Ascheberg
e1b24ab878 Fix display of secure session reset records
Fixes #5605
Closes #5680

// FREEBIE
2016-09-14 16:37:28 -07:00
Moxie Marlinspike
224ef9785e Upgrade libsignal-service
// FREEBIE
2016-09-14 16:37:28 -07:00
Moxie Marlinspike
8f256fa285 Drop malformed RTP packets
// FREEBIE
2016-09-14 16:37:28 -07:00
FeuRenard
85ea7e1bf4 Preserve maxLength for EmojiEditText
Addresses #3388
Closes #5649
// FREEBIE
2016-09-14 16:37:28 -07:00
FeuRenard
24c99c322c Let LogSubmitActivity adapt to theme
Addresses #2625
Closes #5665
// FREEBIE
2016-09-14 16:37:28 -07:00
FeuRenard
677f80b8ef Theme number picker text (disappearing messages)
Fixes #5659
Closes #5667
// FREEBIE
2016-09-14 16:37:28 -07:00
Christian Ascheberg
3432db37d9 Fix scrollbars
Fixes #5487
Closes #5671

// FREEBIE
2016-09-14 16:37:28 -07:00
Moxie Marlinspike
32f5bd5336 Support for syncing contact colors and block lists
Closes #5638
// FREEBIE
2016-09-14 16:37:28 -07:00
Moxie Marlinspike
0a569676f7 Bump version to 3.18.3
// FREEBIE
2016-09-09 11:54:50 -07:00
Moxie Marlinspike
893f106189 Fix divide by zero error
Fixes #5674

// FREEBIE
2016-09-09 11:53:37 -07:00
Moxie Marlinspike
530b93c318 Bump version to 3.18.2
// FREEBIE
2016-09-06 18:43:44 -07:00
Moxie Marlinspike
df19cdd4fb Updated language translations
// FREEBIE
2016-09-06 18:26:38 -07:00
Moxie Marlinspike
29548f4019 Don't display save for conversation actions
// FREEBIE
Fixes #5661
Closes #5668
2016-09-06 18:21:35 -07:00
Moxie Marlinspike
54fc3c5690 Bump version to 3.18.1
// FREEBIE
2016-09-01 20:58:10 -07:00
Moxie Marlinspike
f961c0574a Updated language translations
// FREEBIE
2016-09-01 20:46:45 -07:00
Moxie Marlinspike
1d8276d148 Add EXPIRES_IN column to matrix cursor archived placeholder
Fixes #5656

// FREEBIE
2016-09-01 20:43:59 -07:00
Moxie Marlinspike
8266730551 Bump version to 3.18.0
// FREEBIE
2016-09-01 17:06:52 -07:00
Moxie Marlinspike
a23abda5fc Fix translation
// FREEBIE
2016-09-01 17:06:42 -07:00
Moxie Marlinspike
17c28da2ac Updated language translations
// FREEBIE
2016-09-01 16:57:30 -07:00
FeuRenard
792d4a5939 Resize group images
Fixes #5461
Closes #5597

// FREEBIE
2016-09-01 12:29:11 -07:00
Christian Ascheberg
e6347a38a2 mark group update messages as unread
Closes #5575
// FREEBIE
2016-09-01 11:08:21 -07:00
Christian Ascheberg
53e9b2ad1b ignore fast sender clock
Closes #5577
// FREEBIE
2016-09-01 11:02:57 -07:00
Christian Ascheberg
40332f57ad improve invite strings
Fixes #4869
Closes #5393
//FREEBIE
2016-09-01 10:44:45 -07:00
2-4601
1b04e38377 Clarify that first commit matters for keywords
// FREEBIE
2016-09-01 10:40:21 -07:00
2-4601
4b3d422443 Update PR template to help auto-closing issues
Closes #5399

// FREEBIE
2016-09-01 10:40:21 -07:00
Christian Ascheberg
a698477e10 don't play in-thread notification sound in priority mode
Fixes #3337
Closes #5439

// FREEBIE
2016-08-31 19:57:23 -07:00
FeuRenard
e4fccbe26e Calculate SMS characters respecting encoding
Fixes #1171
Closes #5448

// FREEBIE
2016-08-31 19:51:34 -07:00
Christian Ascheberg
4242ae1b70 Resize fast scroller when keyboard is shown
Fixes #5487
Closes #5505
// FREEBIE
2016-08-31 19:29:21 -07:00
Hans-Christoph Steiner
9a671783c9 respond to generic panic trigger Intent by locking
PanicKit provides a common framework for creating "panic button"
apps that can trigger actions in "panic responder" apps.  In this
case, the response is to lock the app, if it has been configured
to do so.

As previously discussed in #5341

Closes #5550

//FREEBIE
2016-08-31 19:26:05 -07:00
FeuRenard
a370f086c0 Respect privacy settings on ticker content for Android <5
Fixes #5517
Closes #5592

// FREEBIE
2016-08-31 18:44:15 -07:00
Christian Ascheberg
e7ad77398f fix ConversationItem recipients listener
Fixes #4420
Closes #5615
// FREEBIE
2016-08-31 18:30:13 -07:00
FeuRenard
5bf1707d60 Catch ActivityNotFoundExceptions
Fixes #3726
Closes #5617
// FREEBIE
2016-08-31 18:17:15 -07:00
FeuRenard
db10e5fec6 Mark verified messages as push
Fixes #4769
Closes #5627
// FREEBIE
2016-08-31 18:09:29 -07:00
FeuRenard
63f7faf5bb Clear invite reminder if recipient isn't a contact
Fixes #5637
Closes #5640
// FREEBIE
2016-08-31 18:02:57 -07:00
Moxie Marlinspike
059ff3e2e1 Hide disappearing messages menu for coordinated release
// FREEBIE
2016-08-28 17:05:30 -07:00
Moxie Marlinspike
d7e4928f22 Support for disappearing messages
// FREEBIE
2016-08-28 17:03:23 -07:00
Moxie Marlinspike
f03a086191 Bump version to 3.17.0
// FREEBIE
2016-08-22 19:06:08 -07:00
Nicholas Rizzio
8c631ad765 Correct a couple more invite shortlinks to use HTTPS
Closes #5511
// FREEBIE
2016-08-22 18:45:15 -07:00
Mikhail Klementyev
716ed251bc Use gravity instead of calculations
For avoid freezes when trying to add an attachment

Fixes #5583
Closes #5601
// FREEBIE
2016-08-22 18:37:42 -07:00
Moxie Marlinspike
643da569ec Bump version to 3.16.1
// FREEBIE
2016-08-08 18:31:05 -07:00
Moxie Marlinspike
975ae735dc Bump version to 3.16.0
// FREEBIE
2016-05-20 14:19:52 -07:00
Moxie Marlinspike
474920280c Fix broken escapes
// FREEBIE
2016-05-20 14:19:40 -07:00
Moxie Marlinspike
263b0921c3 Updated language translations
// FREEBIE
2016-05-20 13:56:42 -07:00
Jonathan Cross
7292d08272 Bitly links now support HTTPS - Yay!
Both invite links now work over `https` -- yes I tested  :-)
More info:

https://github.com/EFForg/https-everywhere/pull/4505
http://webmasters.stackexchange.com/questions/87163/do-bitly-branded-short-domains-support-https/92407#92407

PS: https://sgnl.link/1IvurmD also works.

Closes #5460
Fixes #4060

// FREEBIE
2016-05-20 13:38:47 -07:00
Christian Ascheberg
49a539a985 prevent contact number NPE
Closes #5460
Fixes #5454
//FREEBIE
2016-05-20 13:36:25 -07:00
Marcus Ofenhed
31970c4644 Stop crash on multiple attachment selected
Fixed #5272
Closes #5440
// FREEBIE
2016-05-20 13:32:53 -07:00
Christian Ascheberg
209d8148ab fix avatar content type
Closes #5417
// FREEBIE
2016-05-20 13:29:13 -07:00
Taylor Kline
3aa024e553 Ensure the browser does not re-use the current tab by removing the
Browser.EXTRA_APPLICATION_ID Extra instead of adding the newer
EXTRA_CREATE_NEW_TAB extra.

Closes #5397
Fixes #4874
Fixes #5356
2016-05-20 13:25:21 -07:00
Christian Ascheberg
2a23b53988 add contextual menu items to NewConversationActivity
Closes #5390
// FREEBIE
2016-05-20 13:16:08 -07:00
Clam
a8a8ec1d40 Extend DPAD support.
Allows the hardware DPAD to control more of the UI.

Closes #4989
// FREEBIE
2016-05-20 13:09:38 -07:00
Moxie Marlinspike
b94c72ea7f Fix APK comparison script.
Fixes #5404

// FREEBIE
2016-04-01 09:50:51 -07:00
Moxie Marlinspike
a307ff350c Bump version to 3.15.2
// FREEBIE
2016-03-25 17:10:01 -07:00
Moxie Marlinspike
f2b81d88ba Check file uri sharing owner rather than prohibiting outright
Fixes #5381
// FREEBIE
2016-03-25 17:08:43 -07:00
Moxie Marlinspike
f1bd2d9193 Bump version to 3.15.1
// FREEBIE
2016-03-25 10:21:59 -07:00
Moxie Marlinspike
2f64b84838 Fix identity key formatting regression
Fixes #5376
// FREEBIE
2016-03-25 10:19:12 -07:00
Moxie Marlinspike
df2e39f251 Bump version to 3.15.0
// FREEBIE
2016-03-24 14:52:44 -07:00
Moxie Marlinspike
2e4f8be235 Updated language translations
// FREEBIE
2016-03-24 14:47:44 -07:00
Moxie Marlinspike
8704daa5f8 Add Dockerfile for an Android build environment
// FREEBIE
2016-03-24 14:36:13 -07:00
2-4601
e1898621c9 Update issue and pull request templates
Closes #5285
// FREEBIE
2016-03-24 14:33:57 -07:00
haffenloher
3c99d66ccd Accept verification SMSes with missing colons
Apparently some Argentinian mobile providers strip the colons from
Signal's verification SMS messages.

Fixes #5363
Fixes #3490
Closes #5371

// FREEBIE
2016-03-24 14:28:48 -07:00
Christian Ascheberg
13c1b15dc2 fix OutgoingRinger crashes
Closes #5357
2016-03-24 14:18:05 -07:00
Christian Ascheberg
cc1bfec08a replace toasts in PassphraseChangeActivity with errors
Closes #5347
// FREEBIE
2016-03-24 14:14:41 -07:00
David Novak
8c36e20681 Add cancel to device management network failure alert dialog
Closes #4844
2016-03-24 14:12:04 -07:00
Moxie Marlinspike
7b589c4300 TextSecure is now SignalService
// FREEBIE
2016-03-24 14:05:56 -07:00
Moxie Marlinspike
3b8ec792ee Prohibit sharing file:// Uris
Just in case someone tries something sneaky...

// FREEBIE
2016-03-23 16:45:29 -07:00
haffenloher
4168092f5d Use high-res callcard for TransparentContactPhoto
Closes #5228

// FREEBIE
2016-03-18 12:54:35 -07:00
Christian Ascheberg
ec922704f4 prepare to use Signal in verification SMS text
Closes #5352
// FREEBIE
2016-03-17 12:21:25 -07:00
Moxie Marlinspike
ec63f7014e Bump version to 3.14.2
// FREEBIE
2016-03-15 21:21:28 -07:00
Pascal Hartig
6a88434338 Change ic_menu_lock_dark to full opacity white
Fixes #5342
Closes #5343
// FREEBIE
2016-03-15 19:15:10 -07:00
Moxie Marlinspike
dd986dbc4b Fall back to lollipop MMS API if PDU response isn't success
Fixes #4131
// FREEBIE
2016-03-14 12:52:15 -07:00
Moxie Marlinspike
aa3aa70c6c Bump version to 3.14.1
// FREEBIE
2016-03-14 11:12:56 -07:00
Moxie Marlinspike
e0f6a92c73 Forgot that we do need the JCE EC stuff
Fixes #5337
// FREEBIE
2016-03-14 11:05:36 -07:00
Moxie Marlinspike
6c995aa191 Bump version to 3.14.0
// FREEBIE
2016-03-13 16:06:21 -07:00
Moxie Marlinspike
94b0176515 Updated language translations
// FREEBIE
2016-03-13 15:48:37 -07:00
Pascal Hartig
f0b832e287 Change lock icons
Closes #5325
// FREEBIE
2016-03-13 15:46:41 -07:00
Moxie Marlinspike
8c8cd41359 Be more persistent about completing the spk job
// FREEBIE
2016-03-11 17:07:22 -08:00
Moxie Marlinspike
9aec80beda Drop some packages from spongycastle to accomodate GB dexopt
Fixes #5269
// FREEBIE
2016-03-11 16:57:29 -08:00
Moxie Marlinspike
95b57e22f8 Revert "Avoid using Toasts in PassphraseChangeActivity"
This reverts commit 30a0981d4c.

// FREEBIE
2016-03-10 09:55:19 -08:00
haffenloher
021942fd43 Don't issue errors when group members unregister
Fixes #2408
Fixes #4550
Closes #5318

// FREEBIE
2016-03-09 16:34:25 -08:00
McLoo
fd43dbdcdb Be more specific when toasting "Success!"
Closes #4871
//FREEBIE
2016-03-09 15:58:26 -08:00
RiseT
ff1a5a5197 'Devices' & 'Manage linked devices' -> 'Linked devices'
Fixes #5201
Closes #5213
// FREEBIE
2016-03-09 14:05:16 -08:00
haffenloher
bd1dc37bab Clarify "SMS import complete" notification text
Fixes #5262
Closes #5274

// FREEBIE
2016-03-09 13:47:17 -08:00
Pascal Hartig
30a0981d4c Avoid using Toasts in PassphraseChangeActivity
Closes #5283
// FREEBIE
2016-03-09 13:45:18 -08:00
Jani Monoses
0155d21967 Use switch instead of checkbox for emoji setting.
Closes #5167
Fixes #5073
// FREEBIE.
2016-03-07 16:09:38 -08:00
Christian Ascheberg
2642f4f15d Make some missed call notifications alert user
Closes #5220
// FREEBIE
2016-03-07 16:03:39 -08:00
Moxie Marlinspike
432e229698 Bump version to 3.13.1
// FREEBIE
2016-03-02 17:55:37 -08:00
Moxie Marlinspike
5ce4e5a630 Revert "Do not decrease compose hint font size"
This reverts commit bf806bd717.

Fixes #5297
// FREEBIE
2016-03-02 17:38:48 -08:00
Geonu Kang
a7cbe5e2a2 Fix bug on getting MIME type for external Persistent Blob URI's
Fixes #5295
Closes #5300
// FREEBIE
2016-03-02 12:48:44 -08:00
Geonu Kang
ba960a82e2 Extract compose subhint for SIM name to string resource
Fixes #5304
Closes #5305
// FREEBIE
2016-03-02 12:46:59 -08:00
haffenloher
fa22fb7550 Don't stop MediaPlayers before releasing them
Fixes #5298
Closes #5303

// FREEBIE
2016-03-02 00:02:32 +01:00
Moxie Marlinspike
24d103df8f Bump version to 3.13.0
// FREEBIE
2016-02-26 14:29:33 -08:00
Moxie Marlinspike
97ff7a192d Updated language translations
// FREEBIE
2016-02-26 10:17:42 -08:00
Geonu Kang
a2f478570a Add MIME type to PersistentBlobProvider
Fixes #4536
Closes #4689
2016-02-24 10:51:58 -08:00
Andreas Fehn
bf806bd717 Do not decrease compose hint font size
Fixes #4903
Closes #5275
// FREEBIE
2016-02-22 11:49:21 -08:00
Pascal Hartig
f2c5e904e8 Replace passphrase mismatch toast with error
Display a form error instead of a toast if the passphrase
doesn't match.

Closes #5268
// FREEBIE
2016-02-22 11:45:33 -08:00
Brad Erickson
ca5bd84a67 Remove text emoji/kamoji using extended Unicode
The original text-emoji set in #5200 added a number of unicode
characters only available in newer versions of Android using the
Noto font set. This severely reduces the text-emoji set to be
compatible with older versions of Android using Roboto or Droid.

Fixes #5249
Closes #5265

// FREEBIE
2016-02-22 11:43:37 -08:00
Moxie Marlinspike
08e2221dc0 Support for synchronizing read state to/from desktop
// FREEBIE
2016-02-19 17:07:41 -08:00
Moxie Marlinspike
f5c90df780 Bump version to 3.12.0
// FREEBIE
2016-02-19 11:06:13 -08:00
Moxie Marlinspike
25020d114a Updated language translations
// FREEBIE
2016-02-19 10:53:47 -08:00
agrajaghh
bb498fdfc9 update README.md
- add links to the community forum
- remove references to the mailing list (as suggested by Riya)

Closes #5263
//FREEBIE
2016-02-19 10:34:57 -08:00
2-4601
ea5dc719c3 Improve CONTRIBUTING.md
- add links to the community forum
 - remove references to the mailing list (as suggested by Riya)
 - clarify and emphasize why bumping is annoying

Closes #5261
//FREEBIE
2016-02-19 10:32:00 -08:00
Christian Ascheberg
3d651ef29a rename plaintext backup filename
Closes #5260
// FREEBIE
2016-02-19 10:29:36 -08:00
haffenloher
72064d8827 Exclude the user's own number from notifyNewUsers
Closes #5229
// FREEBIE
2016-02-18 17:56:08 -08:00
haffenloher
156c5c6e09 Use sent time as timestamp for push image records
Use received time for non-push messages only. This makes the displayed
date for images accessed through "All images" consistent with the date
displayed everywhere else.

Related: #3535
Closes #5230
// FREEBIE
2016-02-18 17:53:37 -08:00
haffenloher
25d7931358 Make system database import notification translatable
Also replace "TextSecure" with "Signal" in the notification text.

Closes #5256
// FREEBIE
2016-02-18 17:52:41 -08:00
Andreas Fehn
238471b847 Allow saving all attachments of a thread
Closes #3975
2016-02-18 17:52:01 -08:00
Moxie Marlinspike
170a4291de Upgrade glide to 1.7.0
// FREEBIE
2016-02-18 17:52:01 -08:00
Moxie Marlinspike
0d6b2d899e Fix broken strings
Fixes #5218
// FREEBIE
2016-02-18 17:52:01 -08:00
agrajaghh
ca2457db8d swap statusbar color in dark theme
Fixes #5242
Closes #5240
// FREEBIE
2016-02-18 17:52:01 -08:00
Christian Ascheberg
8cf574bb32 exclude call screen from recents
Closes #5217
// FREEBIE
2016-02-18 17:52:01 -08:00
RiseT
12957d96e0 Improve identity key scanning strings
Closes #5218
Fixes #1481
// FREEBIE
2016-02-18 17:52:01 -08:00
Ali İskender Turan
1575665266 Update notification_icon.png
Old notification icon replaced with new one.

Closes #5250
2016-02-18 17:52:01 -08:00
Moxie Marlinspike
03efe02e65 Add active status to group multi-device sync messages
// FREEBIE
2016-02-18 17:52:01 -08:00
2-4601
df021643aa Add template for pull request descriptions
Closes #5258
// FREEBIE
2016-02-18 17:50:53 -08:00
Justin Tracey
3772293f8e Add issue template
Closes #5257
// FREEBIE

Changes template as per comments
2016-02-18 17:48:26 -08:00
Moxie Marlinspike
02b8eabf57 Bump version to 3.11.1
// FREEBIE
2016-02-12 13:03:10 -08:00
Moxie Marlinspike
77fb2f520f Add nullable annotation to Recipient contact URI
// FREEBIE
2016-02-12 12:47:05 -08:00
Moxie Marlinspike
efdb57e76b Add a recipient listener to the call card
Fixes #5216
// FREEBIE
2016-02-12 12:33:47 -08:00
Moxie Marlinspike
f1cec5a2ca Don't pass null contact uri into glide
Fixes #5216
// FREEBIE
2016-02-12 11:19:11 -08:00
Moxie Marlinspike
5cb7b7a981 Bump version to 3.11.0
// FREEBIE
2016-02-10 17:56:01 -08:00
Moxie Marlinspike
3a5a7cac73 Only display sim card info on incoming SMS when multiple SIMs
// FREEBIE
2016-02-10 17:50:23 -08:00
Moxie Marlinspike
b69c109d6b Updated language translations
// FREEBIE
2016-02-10 17:50:15 -08:00
Christian Ascheberg
694e6064bd Add message notification task stack
Closes #4893
// FREEBIE
2016-02-10 16:08:26 -08:00
Moxie Marlinspike
6da86e482d Support for dual-sim SMS/MMS functionality
Allow source selection for sending SMS/MMS, and display the
SIM that received SMS/MMS.

Fixes #555
Closes #5199
// FREEBIE
2016-02-09 16:53:15 -08:00
Brad Erickson
c1106d98dd Add 48 text-only emoji/emoticons/kaomoji
Grouped by western and eastern styles, then sorted roughly by emotion.
Happy->Joking->Flirting->Surprise->Worry->Sadness->Anger->Misc

Fixes #5191
Closes #5200
// FREEBIE
2016-02-09 15:47:15 -08:00
Brad Erickson
4c7d2d2c66 Fix text emoji pane font size and vertical align
Fixes #3426
Closes #5196
2016-02-08 17:45:11 -08:00
Moxie Marlinspike
bc4dd7d002 Add Slovakia to list of 6-digit shortcodes that libphonenumber misses
Fixes #4478
// FREEBIE
2016-02-02 14:15:19 -08:00
Moxie Marlinspike
ce12e381a5 Revert "Update libphonennumber for new shortcode metadata"
This reverts commit 8c58d031bd.

wtf is wrong with google
2016-02-02 14:12:56 -08:00
Moxie Marlinspike
8c58d031bd Update libphonennumber for new shortcode metadata
Fixes #4478
// FREEBIE
2016-02-01 10:54:38 -08:00
Moxie Marlinspike
135762b222 Bump version to 3.10.0
// FREEBIE
2016-01-30 16:13:08 -08:00
Moxie Marlinspike
cba0ff7750 COLLATE LOCALIZED seems to imply COLLATE NOCASE
// FREEBIE
2016-01-30 16:08:18 -08:00
Moxie Marlinspike
31224014cc Skip onNewIntent if activity is finishing
We didn't call through to onCreate(), so everything isn't setup.

Fixes #2971
// FREEBIE
2016-01-30 15:33:47 -08:00
Moxie Marlinspike
4a261bcf68 Check result of bitmap size operation for failure
Fixes #5046
// FREEBIE
2016-01-30 15:22:55 -08:00
Moxie Marlinspike
1b97756b05 Use collate localized to sort contacts
Fixes #5144
// FREEBIE
2016-01-30 14:36:06 -08:00
Moxie Marlinspike
7fcd9c36bf Updated language translations
// FREEBIE
2016-01-30 14:33:37 -08:00
Moxie Marlinspike
873a0ab249 Only attempt MMS "direct connect" on Sprint MCCMNCs.
Fixes #5134
// FREEBIE
2016-01-30 14:16:50 -08:00
Moxie Marlinspike
cf223e9ba2 Update APN database from latest CM list
Fixes #4474
// FREEBIE
2016-01-30 13:57:27 -08:00
theroflcoptr
c5bb60611a Fix google play store badge link in readme.md
Closes #5147
2016-01-29 20:19:06 -08:00
2-4601
9f2f3df2ea Fix passphrase string resource reference
Fixes a stupid mistake in pr #5095 where I changed a string again but
forgot to change the resource reference in code :/

Closes #5140
// FREEBIE
2016-01-29 20:16:22 -08:00
Jani Monoses
847142d0f6 No need for capitalization in page title.
Closes #5097
// FREEBIE
2016-01-27 12:22:30 -08:00
2-4601
058585bf81 Fix five strings
Fixes
- one ambiguous pronoun
- one remaining reference of ambiguous 'lock screen'
- three cases of 'click' -> 'tap'

And gets rid of unnecessary line breaks in two strings.

Closes #5095
// FREEBIE
2016-01-27 12:21:32 -08:00
Christian Ascheberg
4049b997ee fix silent in-thread notification
Fixes #5090
Closes #5091
// FREEBIE
2016-01-27 12:19:46 -08:00
Moxie Marlinspike
39a0567e52 Update copyright date
Closes #5089
// FREEBIE
2016-01-27 12:18:31 -08:00
Geonu Kang
999a7431ac Make debug log strings more consistent
Fixes #5083
Closes #5087
// FREEBIE
2016-01-27 12:17:43 -08:00
2-4601
3315186773 Expand CONTRIBUTING.md
Add section for issues, pull requests and other contributions
to address most common issues.

Closes #5084
// FREEBIE
2016-01-27 12:16:45 -08:00
Luc Ritchie
f3f80f0c6e Theme background color in device link screens
Fixes #4611
Closes #5066
2016-01-27 12:14:40 -08:00
Jake McGinty
2e51073a79 update libpastelog to 1.0.7
fixes crash caused by https://github.com/WhisperSystems/libpastelog/issues/13
Closes #5053
// FREEBIE
2016-01-27 12:12:12 -08:00
haffenloher
1512f6e172 Release MediaPlayers immediately after stopping ringers
Closes #4987
// FREEBIE
2016-01-27 12:04:12 -08:00
haffenloher
1abf39685a Use larger version of ic_contact_picture in calls
Closes #4971
Fixes #4245
// FREEBIE
2016-01-27 11:59:10 -08:00
Moxie Marlinspike
1e2a45d440 minSdk of 9 means that providers are exported by default
// FREEBIE
2016-01-15 22:09:58 -08:00
Moxie Marlinspike
df27fa47ed Bump version to 3.9.1
// FREEBIE
2016-01-04 13:21:43 -08:00
Moxie Marlinspike
d8b197dbc4 Updated language translations
// FREEBIE
2016-01-04 13:13:26 -08:00
Christian Ascheberg
0067d2628d revert #4885 requestAudioFocus change
Closes #5015
// FREEBIE
2016-01-04 13:08:59 -08:00
Moxie Marlinspike
524d06d033 Animate location button in
Fixes #5023
// FREEBIE
2016-01-04 13:07:36 -08:00
Moxie Marlinspike
759f9d8016 Support for location drafts
Fixes #4979
// FREEBIE
2016-01-04 13:02:22 -08:00
Moxie Marlinspike
83ec4e0627 Bump version to 3.9.0
// FREEBIE
2015-12-27 18:11:46 -08:00
Moxie Marlinspike
2b359d4642 Updated language translations
// FREEBIE
2015-12-27 13:21:05 -08:00
agrajaghh
d61e5094de remove newlines in text-only group messages
Closes #4963
//FREEBIE
2015-12-27 12:37:39 -08:00
agrajaghh
759ecbc7b8 completely hide location button on API < 16
Closes #4964
// FREEBIE
2015-12-25 14:39:49 -08:00
agrajaghh
f9c9068ca8 fix crash on gingerbread
Closes #4962
//FREEBIE
2015-12-25 14:39:11 -08:00
mimi89999
8b46dda004 Center "Take photo" text in attachment selector
Fixes #4959
Closes #4961
2015-12-25 14:37:56 -08:00
David Novák
ee9b89c4d4 Make the 'try again' device management option actually try again.
Fixes #4648
Closes #4882
2015-12-24 08:08:24 -08:00
Christian Ascheberg
0caad7f348 Do not automatically enable bluetooth audio routing
Fixes some call volume problems

Fixes #4773
Fixes #4188
Closes #4885
2015-12-24 08:01:50 -08:00
haffenloher
6ad2c4bb29 Stop inbox snippet from overflowing the thumbnail
Also ensure the thumbnails are placed correctly in the archive view.

Closes #4954
// FREEBIE
2015-12-24 07:48:19 -08:00
Moxie Marlinspike
bcf95e50aa Support for location messages
Start with encoding as a simple image thumbnail for compatibility
with MMS and iOS

// FREEBIE
2015-12-24 07:47:25 -08:00
agrajaghh
4fa6680f83 RTL support
Closes #4916
Fixes #4714
2015-12-24 07:47:25 -08:00
agrajaghh
94452e7784 add more debugging info to direct capture
should help debugging  #4899

closes #4941

//FREEBIE
2015-12-24 07:47:25 -08:00
Christian Ascheberg
fd570310e0 fix more plurals
Closes #4898
// FREEBIE
2015-12-24 07:47:25 -08:00
agrajaghh
ed592950c0 setting to disable notifications for new contacts
also mute these notifications between 23:00 and 09:00

fixes #4572
Closes #4926
2015-12-24 07:47:25 -08:00
RiseT
d238e2bbc5 Wording: Improve some strings in Privacy preferences
Closes #4907
Fixes #4651
// FREEBIE
2015-12-24 07:47:25 -08:00
McLoo
ec53c6ab04 Fix forwarding text to new coversation
Closes #4870
//FREEBIE
2015-12-24 07:47:25 -08:00
Moxie Marlinspike
ccfea3c834 Fix broken test
Closes #4890
// FREEBIE
2015-12-23 13:28:43 -08:00
Moxie Marlinspike
54f1c91def Update copyright in readme
Closes #4948
Closes #4940
// FREEBIE
2015-12-21 16:10:55 -08:00
Moxie Marlinspike
b80721ef4a Bump version to 3.8.1
// FREEBIE
2015-12-20 08:51:16 -08:00
Javier Arteaga
e9b53cc164 Fix crash when adding a contact from a conversation
Closes #4872
// FREEBIE
2015-12-20 08:46:44 -08:00
Moxie Marlinspike
f7e5404cf7 Bump version to 3.8.0
// FREEBIE
2015-12-16 02:03:21 -08:00
Moxie Marlinspike
e0c3b105e7 Updated language translations
// FREEBIE
2015-12-11 23:29:41 -08:00
McLoo
e79ee7803f Enable preview for image drafts
Closes #4863
2015-12-11 23:17:24 -08:00
Colin Snover
50c432aaf0 Strip separators prior to validating non-email SMS recipients
Refs #1516. Refs #3099. Refs #4833.
Closes #4861
2015-12-11 23:11:35 -08:00
Moxie Marlinspike
67e6031d25 Catch ActivityNotFoundException on contact add intent
Fixes #4865
// FREEBIE
2015-12-11 22:57:18 -08:00
McLoo
50d33be0aa Add Chinese (Traditional) to language list
Closes #4855
//FREEBIE
2015-12-10 18:58:54 -08:00
Jake McGinty
7625ba919e prevent overwriting external capture URIs
Closes #4719
fixes #4538
// FREEBIE
2015-12-10 18:53:40 -08:00
Moxie Marlinspike
bde838d35a Let's take this SMS number cleaning thing to its logical extreme
Fixes #4833
// FREEBIE
2015-12-10 18:49:58 -08:00
Moxie Marlinspike
e32736359b Move group message to group after accepting new identity key
Fixes #2739
// FREEBIE
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
3efcb5dfa1 Fix libphonenumber shortcode data for Finland
Fixes #4853
// FREEBIE
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
371ef3ce95 Strip whitespace in addition to parentheses for outgoing SMS
Fixes #4833
// FREEBIE
2015-12-10 05:04:03 -08:00
brumsel
09cac1e36b Enable proximity sensor while call is ringing
Fixes #4519

// FREEBIE
2015-12-10 05:04:03 -08:00
Darren Foong
43c784f564 Fix wrong Chinese language entry
Fixes #4845
Closes #4846
// FREEBIE
2015-12-10 05:04:03 -08:00
Christian Ascheberg
08b61572e9 fix some plurals
Closes #4815
Fixes #4811
// FREEBIE
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
49f60971bd Cache delivery receipts when they arrive before sync message
// FREEBIE
2015-12-10 05:04:03 -08:00
Christian Ascheberg
4696837f2f warn user before build expires
Closes #4322
// FREEBIE
2015-12-10 05:04:03 -08:00
Gil
b40f0ffeb0 Update recipient info after adding a contact
Fixes #4074
Closes #4259
2015-12-10 05:04:03 -08:00
brumsel
57cb68849e Don't notify of failure when viewing message details
If message delivery fails and the currently visible activity is the
MessageDetailsActivity of the failed message, treat the failure
notification as an in-thread notification.

Closes #3947
2015-12-10 05:04:03 -08:00
PurplePlatypus
fe5e101463 Change TS Media message timestamp from received time to sent time
Fix #3525
Closes #3535
//FREEBIE
2015-12-10 05:04:03 -08:00
junitas
038f24f394 Set maximum group name
Closes #3438
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
81fa209910 Use Ringtone instead of MediaPlayer directly
(Copied from rhodey's PR)

Fixes #3340
Closes #3342

// FREEBIe
2015-12-10 05:04:03 -08:00
McLoo
c7dd956f45 Fix for getting the device number with national prefix
Closes #2312
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
3b80e35547 Display group info in message notifications
Fixes #1033
Fixes #2558
Closes #3020
// FREEBIE
2015-12-10 05:04:03 -08:00
RiseT
307578eb18 Wording ambiguity: Archived conversation -> Conversation archived
Closes #4802
// FREEBIE
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
8a3762b337 Don't issue new user notification if secure session exists
Fixes #4800
// FREEBIE
2015-12-10 05:04:03 -08:00
Moxie Marlinspike
ef5a0a0ff3 Bump version to 3.7.2
// FREEBIE
2015-12-09 12:02:21 -08:00
haffenloher
e5cd3e4fd1 Update inbox status icon on SMS delivery receipt
Closes #4848
// FREEBIE
2015-12-09 11:24:45 -08:00
Moxie Marlinspike
2bd5b5fd68 Add gitter link to contributing
// FREEBIE
2015-12-09 06:57:03 -08:00
Geonu Kang
b8cbfe0b0d Update Transifex link in contributing.md
Fixes #4828
Closes #4829
// FREEBIE
2015-12-08 09:35:39 -08:00
Eric Hanchrow
b23898ee09 Some clarifications for BUILDING.md
Closes #4501
// FREEBIE
2015-12-08 05:35:11 -08:00
Moxie Marlinspike
2cfc86307d Bump version to 3.7.1
// FREEBIE
2015-12-08 00:26:12 -08:00
Moxie Marlinspike
e4cf4dacd4 Update language translations
// FREEBIE
2015-12-07 23:49:26 -08:00
haffenloher
b41364c709 Add inbox delivery status migration
Fixes #4799
Closes #4809

// FREEBIE
2015-12-07 23:34:28 -08:00
Moxie Marlinspike
b99c4e3e39 Bump version to 3.7.0
// FREEBIE
2015-12-03 18:14:32 -08:00
Moxie Marlinspike
6c4df2919c Updated language translations
// FREEBIE
2015-12-03 17:57:24 -08:00
Moxie Marlinspike
73acd1f3a2 Take people into Signal when they attempt to link w/ 3rd party scan
// FREEBIE
2015-12-03 14:39:13 -08:00
Moxie Marlinspike
adda7622f4 Mark messages read when swipe archiving
// FREEBIE
2015-12-03 12:36:47 -08:00
Geonu Kang
43aef3ecb0 Integrate DynamicLanguage with DeviceListFragment
Fixes #4752
Closes #4793
2015-12-03 11:55:37 -08:00
Philippe Laferriere
03faff443c Removed lazy class SmsTransportDetails
Moved constants into SmsCharacterCalculator.

Closes #4788
2015-12-03 11:52:12 -08:00
haffenloher
eebe227a20 Return to archive on back button press in archived convo
When the back/up/home button in the action bar is pressed in an
archived conversation, return to the archive instead of the inbox.

Closes #4770
// FREEBIE
2015-12-03 11:51:22 -08:00
Moxie Marlinspike
8fb73a092d Slight optimization for message status updates
// FREEBIE
2015-12-03 11:47:28 -08:00
haffenloher
7c95adc7e6 Add delivery status icons to the conversation list
Closes #4710
2015-12-03 11:28:04 -08:00
Jake McGinty
df5c497b5b remove compat actionbar shadow for invite page
// FREEBIE
2015-12-03 10:22:11 -08:00
Geonu Kang
8afdbc1f4d Fix NewConversationActivity toolbar/overflow dynamic theming
Fixes #4624
Closes #4626
2015-12-03 10:21:58 -08:00
Geonu Kang
8269047c88 Update attachment content type when updating attachment data
Fixes #4687
Closes #4688
2015-12-02 09:45:57 -08:00
Geonu Kang
afb21203b7 Extract "Today" in device list item to string resource
Related to #4752
Closes #4780
// FREEBIE
2015-12-02 09:36:32 -08:00
Geonu Kang
d0a65f86f5 Add color to "Scan the QR code" in DeviceAddFragment
Fixes #4771
Closes #4776
// FREEBIE
2015-12-02 09:35:10 -08:00
Geonu Kang
29f4f269fc Make "New Message!" notification string more consistent with guidelines
Fixes #4758
Closes #4759
// FREEBIE
2015-12-02 09:33:23 -08:00
RiseT
65176c940e Wording consistency: thread -> conversation
Closes #4753
// FREEBIE
2015-12-02 09:31:56 -08:00
Geonu Kang
591ee92e45 Add string resource for unarchive button title
Fixes #4747
Closes #4748
// FREEBIE
2015-12-02 09:30:29 -08:00
Geonu Kang
fa411f5623 Increase swipe-to-archive snackbar duration
Fixes #4745
Closes #4746
// FREEBIE
2015-12-02 09:28:54 -08:00
clashman
24360bf5b6 Remove unnecessary capitalizations
Closes #4739
// FREEBIE
2015-12-02 09:26:43 -08:00
Moxie Marlinspike
9fe1a7c38d Bump version to 3.6.1
// FREEBIE
2015-11-30 11:31:31 -08:00
Moxie Marlinspike
6de77879db Updated language translations
// FREEBIE
2015-11-30 11:22:44 -08:00
Moxie Marlinspike
adcb29616a Keep track of attachmentmanager garbage
Fixes #4764
// FREEBIE
2015-11-30 11:16:30 -08:00
Moxie Marlinspike
3bf8052811 Don't add "archive (n)" placeholder to list of batch selected
Fixes #4750
// FREEBIE
2015-11-30 10:37:38 -08:00
Moxie Marlinspike
cdb122d3d1 Reposition thumbnail when in archived view
Fixes #4744
// FREEBIE
2015-11-30 10:36:56 -08:00
Moxie Marlinspike
bde6c9092d Bump version to 3.6.0
// FREEBIE
2015-11-27 17:32:35 -08:00
Moxie Marlinspike
db0b4d43cb Updated language translations
// FREEBIE
2015-11-27 17:27:22 -08:00
Jake McGinty
b07003ae34 fix yakju JWR66Y front-camera misbehavior
fixes #4715
Closes #4738
// FREEBIE
2015-11-27 17:04:12 -08:00
Moxie Marlinspike
0a9f28c228 Fix rogue action button toggleing in contact selection
Fixes #4700
// FREEBIE
2015-11-27 15:46:40 -08:00
Jake McGinty
946c43940b add equals/hashCode to glide models
Closes #4737
// FREEBIE
2015-11-27 15:20:24 -08:00
Geonu Kang
e83827ab75 "image/jpg"->"image/jpeg" on MIME type checks and saving
Fixes #4602
Closes #4643
2015-11-27 13:04:59 -08:00
McLoo
6431773288 Add Hebrew to language list
Closes #4707
//FREEBIE
2015-11-27 13:02:05 -08:00
Geonu Kang
3319748926 Signal-ize last remaining "data channel" and "push" string resources
Fixes #4730
Closes #4731
// FREEBIE
2015-11-27 13:00:21 -08:00
Moxie Marlinspike
2ab0029d49 Support for archive actions
Fixes #1141
Closes #4698
// FREEBIE
2015-11-27 12:45:23 -08:00
char32
796decdb0f Switch from 'Contents Hidden' to 'New message'
Fixes #4004
Closes #4566
2015-11-26 08:07:31 -08:00
brumsel
64ee669728 Reset audio mode on incoming ringer stop
Don't request audio focus in IncomingRinger either.

Fixes #4548
Closes #4567

// FREEBIE
2015-11-26 07:59:38 -08:00
Geonu Kang
a8f4dadaf5 Delete Selected Message button strings "No"/"Yes" -> "Cancel"/"Delete"
Closes #4705
Fixes #4704
// FREEBIE
2015-11-26 07:31:48 -08:00
Jani Monoses
ec58132b25 No need for capitalization in dialog title.
Closes #4713
// FREEBIE
2015-11-26 07:28:36 -08:00
Geonu Kang
563f7e6e78 Make strings more consistent, "3G" -> "mobile data"
Fixes #4720
Closes #4721
// FREEBIE
2015-11-26 07:26:09 -08:00
AsamK
e93dcc3991 Replace emojis in GroupCreateActivity
Emojis can be typed there using the system keyboard

Closes #4692
// FREEBIE
2015-11-26 07:24:57 -08:00
AsamK
7aac137fb7 Fix group avatar issues in GroupCreateActivity
Images weren't rounded in some cases, and other
times weren't updating in the group properly.

Closes #4692
// FREEBIE
2015-11-26 07:24:57 -08:00
Moxie Marlinspike
073be6696b Mark threads as read when we get an outgoing sync message
// FREEBIE
2015-11-26 07:24:57 -08:00
Moxie Marlinspike
54b30c47f5 Display registered number in advanced preferences
Fixes #4504
// FREEBIE
2015-11-26 07:24:57 -08:00
Jake McGinty
8914c79613 fix "partial scroll" when sending in certain cases
fixes #2856
Closes #4702
// FREEBIE
2015-11-26 07:24:57 -08:00
Moxie Marlinspike
785f737244 Limit 'last active' device timestamp to day level precision
Closes #4614
// FREEBIE
2015-11-26 07:24:57 -08:00
Daniel Bartram
67415a8dcb Improve generated contact photos with emoji names
Improve the logic for generating contact photos with contact names
which start with emoji or non-language characters.

This fixes the infamous "question-mark-in-a-box" character from
appearing in the contact photo for contacts whose names begin with
an emoji or a non-language symbol.

Closes #3684
2015-11-26 07:24:57 -08:00
Jake McGinty
b4e28e219b fix false camera captures
// FREEBIE
2015-11-26 07:24:56 -08:00
Jake McGinty
3a5d4e7ebe reset surface on camera pause
fixes #4657

// FREEBIE
2015-11-26 07:24:56 -08:00
Jake McGinty
a04e737526 fix direct capture file writing race condition
fixes #4612
Closes #4634
// FREEBIE
2015-11-26 07:24:56 -08:00
Jake McGinty
3bfb123b33 fix selfie horizontal flip
Closes #4635
// FREEBIE
2015-11-26 07:24:56 -08:00
Jake McGinty
d5bd7bcf5f use same default group photo in GroupCreateActivity
fixes #3908
Closes #4639
// FREEBIE
2015-11-26 07:24:56 -08:00
Moxie Marlinspike
2ef808f406 Add help menu to conversation list overflow
Fixes #4552
// FREEBIE
2015-11-26 07:24:56 -08:00
Geonu Kang
c4f9bc2b5e Improve date localization for API >= 18 (4.3, JELLY_BEAN_MR2)
Fixes #3102
Closes #4597
2015-11-26 07:24:56 -08:00
Moxie Marlinspike
e4e8511b4c Bump version to 3.5.2
// FREEBIE
2015-11-24 12:08:13 -08:00
Moxie Marlinspike
13328ca0d0 Fix strange conversation draw behavior in GB
// FREEBIE
2015-11-24 11:47:50 -08:00
Moxie Marlinspike
6a188248a7 Bump version to 3.5.1
// FREEBIE
2015-11-23 12:03:14 -08:00
Moxie Marlinspike
5e493c90f8 Fix broken strings
// FREEBIE
2015-11-23 12:03:00 -08:00
Moxie Marlinspike
8e735cd66f Update language translations
// FREEBIE
2015-11-23 11:49:57 -08:00
Moxie Marlinspike
885fc88aad Disable voice messages until iOS gets their act together
// FREEBIE
2015-11-23 11:47:54 -08:00
Jake McGinty
69ee4cbc71 select *all* threads
fixes #4565
// FREEBIE
2015-11-23 11:43:54 -08:00
Moxie Marlinspike
2790128e9c Disable mic/camera on inactive group thread
Fixes #4653
Fixes #3334
// FREEBIE
2015-11-23 11:42:02 -08:00
Moxie Marlinspike
a4f7b78fd0 Make InputPanel fully responsible for emoji toggle
Fixes #4638
// FREEBIE
2015-11-23 11:42:02 -08:00
Moxie Marlinspike
fc5777e904 Manually encode voice messages to AAC with ADTS headers
Should resolve issues with platforms that don't support AMR (!).

Fixes #4640
Fixes #4652
Fixes #4647
// FREEBIE
2015-11-23 11:42:02 -08:00
Jake McGinty
a0beb7f0e0 scroll *all* the way
fixes #4664
closes #4695
// FREEBIE
2015-11-23 11:38:33 -08:00
Jake McGinty
d58f4d1232 don't allow fast scrolling until data is available
fixes #4666
closes #4693
// FREEBIE
2015-11-23 11:36:13 -08:00
Jake McGinty
473e470883 fix header/footer item ID issue
fixes #4667
Closes #4685
// FREEBIE
2015-11-22 17:30:36 -08:00
agrajaghh
4dce79334d fix crash in RecipientPreferenceActivity
fixes #4674
closes #4679

// FREEBIE
2015-11-22 22:14:02 +01:00
Moxie Marlinspike
e914496216 Remove identity menu option from conversation list
// FREEBIE
2015-11-22 09:32:02 -08:00
Moxie Marlinspike
9b3457f0b2 Don't choke so hard on random QR codes
Fixes #4642
// FREEBIE
2015-11-22 09:28:36 -08:00
Moxie Marlinspike
d21fe517e4 Bump version to 3.5.0
// FREEBIE
2015-11-20 11:26:36 -08:00
Moxie Marlinspike
8290970d50 Updated translations
// FREEBIE
2015-11-20 10:53:38 -08:00
Jake McGinty
2e8841c1d6 make RecyclerView unique IDs per thread
Closes #4619
// FREEBIE
2015-11-20 10:48:25 -08:00
Moxie Marlinspike
dc1b420fef Voice Note -> Voice Message
Fixes #4628
// FREEBIE
2015-11-20 10:25:08 -08:00
Moxie Marlinspike
e41f34729e Fix for voice message race conditions
Fixes #4625
// FREEBIE
2015-11-20 10:22:36 -08:00
Jake McGinty
4fe6256967 run Camera.startPreview() off main thread
Closes #4620
// FREEBIE
2015-11-20 08:15:24 -08:00
Geonu Kang
d9467ef3c5 Extract "Devices" preference category title to string resource
Fixes #4621
// FREEBIE
2015-11-20 13:50:31 +09:00
Geonu Kang
d5bf1b6137 Fix "Repeat new passphrase" spelling
Fixes #4617
// FREEBIE
2015-11-20 11:06:41 +09:00
Moxie Marlinspike
bfe4ad6c34 Voice notes
Closes #4610
Closes #3563
// FREEBIE
2015-11-19 17:37:48 -08:00
Jake McGinty
4e8e8978f4 update camera preview strategy
// FREEBIE
2015-11-19 17:34:02 -08:00
Moxie Marlinspike
7817c7697e Fix for audio attachment server NPE
Fixes #4615
// FREEBIE
2015-11-19 15:59:24 -08:00
brumsel
06f2908d78 Don't show images without data under "all images"
This affects images
- that have yet to be downloaded (using media download controls)
- that are currently being downloaded
- that failed to download

closes #4507
2015-11-19 13:21:23 -08:00
Jake McGinty
61386e9ca9 more useful contact select headers
Closes #4608
// FREEBIE
2015-11-19 11:56:40 -08:00
Jake McGinty
4314a4b42b add stable IDs to conversations
fixes #2856
Closes #4607
// FREEBIE
2015-11-19 11:46:56 -08:00
Moxie Marlinspike
945636ac5c Don't show reminder view on quick reply
Fixes #4524
// FREEBIE
2015-11-19 11:43:17 -08:00
Moxie Marlinspike
ba4ebed59b Fix checksum
Fixes #4605
// FREEBIE
2015-11-19 11:35:38 -08:00
Moxie Marlinspike
7c0bf0c871 Device provisioning
Closes #4553
// FREEBIE
2015-11-19 11:30:39 -08:00
Jake McGinty
02c37e815c enable media forwarding
fixes #1362
closes #4589
// FREEBIE
2015-11-19 11:27:13 -08:00
agrajaghh
6a99c6c4ac Fix "Silent" summary for ringtone preference
fixes #3962
Closes #4441

//FREEBIE
2015-11-19 11:13:24 -08:00
agrajaghh
a65ade5366 add action buttons to the call notification
fixes #4160
Closes #4490
2015-11-19 11:12:15 -08:00
agrajaghh
332c722f1d fix Code style Guidelines link in contributing.md
fixes #4596
closes #4598

//FREEBIE
2015-11-19 11:08:41 -08:00
Jake McGinty
7aeb4c96ee fix crash on null Android contact name
fixes #4592
Closes #4594
// FREEBIE
2015-11-19 11:07:39 -08:00
Jake McGinty
cd085faecd move instrumentation test to unit tests
Closes #4593
// FREEBIE
2015-11-19 11:06:34 -08:00
Geonu Kang
1323b49c57 Use separate menu title strings for insecure/secure calls
Fixes #4579
Closes #4580
// FREEBIE
2015-11-19 11:02:29 -08:00
Max Muth
9915fa347f Update donation image in readme
fixes #4542

//FREEBIE
2015-11-19 11:00:50 -08:00
Jake McGinty
bcd08956bd clear drafts immediately upon sending or new intent
fixes #3843
closes #3850
Closes #4571

// FREEBIE
2015-11-19 10:59:10 -08:00
Jake McGinty
25da3525fa use material labels for passphrase text
closes #3374
Closes #4570
// FREEBIE
2015-11-19 10:57:49 -08:00
McLoo
245c0adeea add dark theme to PassphraseChangeActivity
also adding DynamicLanguage to fix ActionBar language changes
2015-11-19 10:57:46 -08:00
Jake McGinty
0d06e78d25 fix quick attachment open animation
Closes #4569
// FREEBIE
2015-11-19 10:57:02 -08:00
Jake McGinty
2ce2a0d5c3 add refresh in overflow to NewConversationActivity
fixes #4470
closes #4564
// FREEBIE
2015-11-19 10:47:42 -08:00
Ben Bodenmiller
040f8c81bf remove travis ci file since travis is not used
Closes #4543
// FREEBIE
2015-11-19 10:43:43 -08:00
heyimgay
ce1c6e2372 signalize attachment filename
Closes #4541
2015-11-19 10:42:49 -08:00
Christian Ascheberg
1d8aef1669 Plural group join message
Closes #4535
Fixes #4521
// FREEBIE
2015-11-19 10:40:57 -08:00
Geonu Kang
cca38ddf3f Improve Delete Thread, Reset Secure Session confirmation dialogs
Fixes #4512
Closes #4513
// FREEBIE
2015-11-19 10:35:45 -08:00
agrajaghh
ce617fb7cb hide irrelevant preferences in RecipientPreferenceActivity
fixes #4505
Closes #4509
//FREEBIE
2015-11-19 10:31:11 -08:00
Jake McGinty
43ebf829ca remove unmaintained espresso tests
we hardly knew ye
closes #4559
// FREEBIE
2015-11-19 10:30:26 -08:00
Jake McGinty
487f8cbb38 fix broken unit tests
fixes #4534
// FREEBIE
2015-11-19 10:30:26 -08:00
Jake McGinty
36426a74c1 correct all colorControl* AppCompat attributes
solves problem described in #4494
// FREEBIE
2015-11-19 10:30:26 -08:00
heyimgay
04f9187c14 activated state of switches match textsecure color
fixes #3881
2015-11-19 10:30:26 -08:00
Sam Lanning
8efe6e7286 Make long pressing the attach button open the transport popup
// FREEBIE
2015-11-19 10:30:26 -08:00
Moxie Marlinspike
745faa12a7 Fix for outgoing group update display
Fixes #4444
// FREEBIE
2015-11-19 10:30:26 -08:00
Dustin Lim
0cd4cc67af save fragment state when changing theme/langugage
closes #2782
// FREEBIE
2015-11-19 10:30:26 -08:00
agrajaghh
9201d50f05 let the quick camera remember front/back mode
fixes #4438
closes #4440

//FREEBIE
2015-11-19 10:30:26 -08:00
Jake McGinty
f82a7fee49 re-commit refactored CameraView
closes #4529
Confirmed fixed front-camera bug in Galaxy Nexus.

// FREEBIE
2015-11-19 10:30:26 -08:00
Sam Lanning
66578a2c76 Change notification privacy setting wording
"Neither" -> "No name or message"

fixes #3903
closes #3966

// FREEBIE
2015-11-19 10:30:26 -08:00
agrajaghh
c4339813e6 migrate to AppCompatDialog
closes #3222
2015-11-19 10:30:26 -08:00
Carlin
927aac2c4a Add button to toggle passphrase visibility
closes #3776
// FREEBIE
2015-11-19 10:30:26 -08:00
Heartsucker
5a29c61dac Correctly sets subtitle on conversation batch select mode during first selection
fixes #3565
closes #3628
2015-11-19 10:30:26 -08:00
Calvin Hu
149ac9f417 when camera preview is open, the preview toggle button will close the preview
closes #3574
2015-11-19 10:30:26 -08:00
McLoo
6c20a4c08b Change 'Title' to 'Group name' in group update message
closes #3424
//FREEBIE
2015-11-19 10:30:26 -08:00
Moxie Marlinspike
8fc690d8e0 Update to libtextsecure 1.8.3
Fixes #4549

// FREEBIE
2015-11-19 10:30:26 -08:00
Jake McGinty
dd0a952c83 avoid older android 9patch transparency bugs
// FREEBIE
2015-11-19 10:30:26 -08:00
Moxie Marlinspike
ff123943cb Fully differentiate Signal vs non-Signal contacts
// FREEBIE
2015-11-19 10:30:25 -08:00
Moxie Marlinspike
493bd9be6b Update link to transifex
// FREEBIE
2015-11-18 08:36:17 -08:00
Moxie Marlinspike
028a1ab2b0 Bump version to 3.4.2
// FREEBIE
2015-11-16 11:57:02 -08:00
Moxie Marlinspike
058bcf1f4a More shortcode fixes for Germany
// FREEBIE
2015-11-16 11:35:11 -08:00
Jake McGinty
ae379cd3dd fix external gif sharing
fixes #4539
Closes #4556
// FREEBIE
2015-11-16 11:28:03 -08:00
Jake McGinty
f3a4634d30 fix keyboard/focus regressions
I don't know how it was working the first time.

fixes #4527
Closes #4555
// FREEBIE
2015-11-16 11:27:05 -08:00
Moxie Marlinspike
de3106344a Bump version to 3.4.1
// FREEBIE
2015-11-14 15:43:39 -08:00
Moxie Marlinspike
fecc5e63e8 Update language translations
// FREEBIE
2015-11-14 15:22:30 -08:00
Moxie Marlinspike
69f5aacd25 Consider everything <= len(4) a short code, except short countries
// FREEBIE
2015-11-14 15:17:05 -08:00
Moxie Marlinspike
2a753c7795 Uhh, switch from valid to possible short codes?
Fixes #4478
// FREEBIE
2015-11-13 17:07:43 -08:00
Moxie Marlinspike
c17e24250d Bump version to 3.4.0
// FREEBIE
2015-11-13 11:56:21 -08:00
Moxie Marlinspike
cb60e08da2 Update language translations
// FREEBIE
2015-11-13 11:42:19 -08:00
Moxie Marlinspike
21f04605c6 Don't E164 shortcodes
Fixes #4478
// FREEBIE
2015-11-13 11:23:37 -08:00
Jake McGinty
0c75e652eb bring back the ripple when clicking on preview
Closes #4506
// FREEBIE
2015-11-12 15:20:17 -08:00
Jake McGinty
d3000f384f adhere to android plural standards
// FREEBIE

Closes #4503
2015-11-12 15:20:17 -08:00
Jake McGinty
76b0183e0f move db query off main thread, fix group self-add
fixes #4168
Closes #4502
// FREEBIE
2015-11-12 15:20:17 -08:00
Jake McGinty
e51e5cdfd4 fail faster in FileNotFoundException case
Fixes #3053
Closes #4499
// FREEBIE
2015-11-12 15:20:17 -08:00
Jake McGinty
5b1e5b18f9 reset contact selection after batch invite
fixes #4452
Closes #4498
// FREEBIE
2015-11-12 15:20:16 -08:00
Moxie Marlinspike
fb9ba8cb8d Tint audio controls to be visible in dark theme
Fixes #4353
Closes #4466
// FREEBIE
2015-11-12 15:20:16 -08:00
Moxie Marlinspike
b136fed6f7 Update contact DB on incoming messages
When we receive a Signal message from a previously unregistered
user, reflect that in the contact DB.

Fixes #3949
Closes #4492
// FREEBIE
2015-11-12 15:20:16 -08:00
Jake McGinty
fb8d6cb538 contact selection reeemix
1) RecyclerView-based, with better long scroller
   and more material-inspired look.
2) Add badge for Signal users to contact selection
   list.

// FREEBIE
2015-11-12 15:20:16 -08:00
Moxie Marlinspike
7bec5efe1a Add 'Signal Call' option to contact card
Fixes #4392
Closes #4465
// FREEBIE
2015-11-12 15:20:16 -08:00
agrajaghh
5c59c3f423 make invite strings plural
fixes #4388
Closes #4389

// FREEBIE
2015-11-12 15:20:16 -08:00
Sebastian Morr
181c7dfd85 Add the option to mute notifications for one year.
Fixes #4448.
Closes #4454
2015-11-12 15:20:16 -08:00
Jake McGinty
d05097a6fd Refactor group logic (no visual changes)
Closes #4480
// FREEBIE
2015-11-12 15:20:16 -08:00
Moxie Marlinspike
75483299dc Upgrade libtextsecure 1.8.2
// FREEBIE
2015-11-12 15:20:16 -08:00
brumsel
5333647794 Always play "sonar" on call initialization
If "sonar" was the last sound played on the last call, it wasn't
 being played on the next calling attempt.

Closes #4473
2015-11-12 15:20:16 -08:00
RiseT
e1f9519235 Replace 'my' with 'your'
See
https://www.google.com/design/spec/style/writing.html#writing-language

// FREEBIE
2015-11-12 15:20:16 -08:00
RiseT
7f0b0803bc Change 'SD card' to 'storage' & cosmetic corrections
Fixes #3920
2015-11-12 15:20:16 -08:00
Moxie Marlinspike
c867316e6a Bump version to 3.3.2
// FREEBIE
2015-11-11 08:33:28 -08:00
Jake McGinty
b0137c08cb go back to old CameraView
Fixes #4415
Closes #4484
// FREEBIE
2015-11-10 15:48:50 -08:00
Simeon J Morgan
534421eb57 Update build instructions with new URLs.
Expand Android Studio steps.

Closes #4462
2015-11-10 14:14:25 -08:00
Moxie Marlinspike
b97363e407 Reintroduce telephony requirement
Fixes #4457
// FREEBIE
2015-11-09 09:58:24 -08:00
Moxie Marlinspike
aaf3f70ce5 Bump version to 3.3.1
// FREEBIE
2015-11-06 16:59:50 -08:00
Jake McGinty
5fd5b1e1ed Fix "twitchy fingers" bug in CameraView
better diagnostic information, too.

Fixes #4422
Closes #4427
// FREEBIE
2015-11-06 15:00:29 -08:00
Moxie Marlinspike
56a3c99289 Resolve service deadlock issue
Fixes #4409
// FREEBIE
2015-11-06 11:57:22 -08:00
Moxie Marlinspike
b5b564cfe1 Make sure the number we add canonicalizes to the number we know.
Fixes #4406
// FREEBIE
2015-11-06 10:50:47 -08:00
Moxie Marlinspike
0b7b37bf00 Bump version to 3.3.0
// FREEBIE
2015-11-05 13:04:20 -08:00
Moxie Marlinspike
5b08be8d01 We don't need jitter stats logging in production anyway
// FREEBIE
2015-11-05 12:52:31 -08:00
Moxie Marlinspike
8d4f3803df Switch SMS listener to using dotall
// FREEBIE
2015-11-05 11:44:03 -08:00
Moxie Marlinspike
56117237b6 Updated translations
// FREEBIE
2015-11-05 11:39:02 -08:00
Jake McGinty
796940bda5 fix ContactSelectionListItem NPE
Fixes #4394
Closes #4399
// FREEBIE
2015-11-05 11:12:22 -08:00
Jake McGinty
00a18f58a7 catch MMS NPE for time being
Fixes #4379
Closes #4401
// FREEBIE
2015-11-05 11:11:28 -08:00
agrajaghh
0ef56fb86d add custom color to MessageDetailsActivity
Fixes #3560
Closes #3580

// FREEBIE
2015-11-05 11:10:20 -08:00
Jake McGinty
381c8820b1 remove unused CircleIndicator
Fixes #4393
closes #4397
// FREEBIE
2015-11-05 11:02:56 -08:00
Jodson Leandro
a930ec5404 Flag secure in all activities that extends BaseActionBarActivity
Closes #4152
Fixes #3327
2015-11-05 11:00:31 -08:00
Stefan Seide
e808ae0ddc remove brackets from recipient numbers as not allowed for dialing
Closes #3450
2015-11-05 10:07:52 -08:00
rafael81
750e25388f Update regular expression pattern for sms verification
Closes #4375
2015-11-05 09:52:03 -08:00
Moxie Marlinspike
5757962f95 Don't require implicit features
// FREEBIE
2015-11-05 09:51:42 -08:00
Moxie Marlinspike
c15d8ebd2e Better locking on jitter buffer stats printing
// FREEBIE
2015-11-04 17:56:21 -08:00
Moxie Marlinspike
09c57f3f44 Add close button to attachment type selector
// FREEBIE
2015-11-04 17:56:21 -08:00
Moxie Marlinspike
be0ca330f5 Nicer looking attachment type selector
Closes #4367
// FREEBIE
2015-11-04 17:56:21 -08:00
Moxie Marlinspike
2941ac0e2c Update material-dialogs dependency
Closes #4103
// FREEBIE
2015-11-04 17:56:21 -08:00
Jake McGinty
d6a061d50f extra logging for activity lifecycle
to help debug #2971
Closes #4342
// FREEBIE
2015-11-04 17:56:21 -08:00
Jake McGinty
59f2446a2b unjankify incoming media sharing
Closes #4374
Fixes #3989
// FREEBIE
2015-11-04 17:56:21 -08:00
Moxie Marlinspike
60ab71099f Don't show group avatar icons in thread preview
Fixes #4383
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
3f6cdd4133 Add audio focus into the audio dance.
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
72b9c37ec8 Mark muted messages as read when in thread
Fixes #3562
Closes #3643
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
5704fad7cc Fix for broken build
// FREEBIE
2015-11-04 17:56:20 -08:00
Gil
849c346a21 Updates visibleThreadId after sending a message in a new thread
Fixes #3536
Closes #4146
2015-11-04 17:56:20 -08:00
Manuel Geier
328a3ff20e show total number of messages or threads to be deleted
in delete-confirm-dialogs

Closes #4284

// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
24bcea393f Removed backup file
Closes #4293
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
aade4c7af3 Correctly set audio mode
Fixes #4244
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
58406d6b37 Consider unregister successfull on 401 from RP server.
Fixes #4362
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
004a87eba9 Lower SMS retry count to 15
Closes #4296
// FREEBIE
2015-11-04 17:56:20 -08:00
Jake McGinty
3fa11d9931 show transfer progress when re-sending failed media
Closes #4341
fixes #4104
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
cad8ff766a Don't set media volume to zero.
Not sure what SOA was thinking with this one.

Fixes #4201
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
5b6f49c993 Switch RedPhone view<->service interaction to use event bus
Fixes #4234
// FREEBIE
2015-11-04 17:56:20 -08:00
Jake McGinty
3e798a9863 batch invitation
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
4371708fc4 Fix onNewIntent transport selection assertion
Fixes #4301
// FREEBIE
2015-11-04 17:56:20 -08:00
Jake McGinty
d4887e11be fix failed incoming MMS regression
Fixes #4308
Closes #4334
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
d0e852f19f Retry on network failures during media message sends.
Fixes #4332
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
8d82033855 Notify when contacts join Signal
Closes #4314
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
434ce4f9c9 Canonicalize entries in canonical address database.
Make all our queries E164, so eventually everything in there
will be E164.  Stops thrashing between formats.

Closes #4306

// FREEBIE
2015-11-04 17:56:20 -08:00
Jake McGinty
8fd0ea39aa Simplify excessively convoluted camera logic
1) QuickCamera logic moved into CameraView

2) The strategies for texture vs. surface view were too complex
   with no observed gain. Better to remove and have to re-add
   if necessary than assume it to be necessary.

3) Drop CWAC-Camera dependency - the device profiles weren't being
   used very much and even that is deprecated so we'd be left on
   our own with new hardware. Not worth it.

4) Selfies first.

5) Layout/orientation mathy logic from CWAC moved into CameraUtils,
   with the  hopes that most of it might be further simplified or
   rendered unnecessary in the future.

Closes #4326

// FREEBIE
2015-11-04 17:56:20 -08:00
RiseT
08be47c03e Adjust a couple of strings in order to include calls AND messages.
Closes #4311
2015-11-04 17:56:20 -08:00
RiseT
13bd3c773c Make some 'notification sound' strings consistent with the rest
Closes #4324
// FREEBIE
2015-11-04 17:56:20 -08:00
Moxie Marlinspike
751fa21f60 Ignore envelopes with unknown type
// FREEBIE
2015-11-04 17:56:19 -08:00
Moxie Marlinspike
339d352d6e Better support for revoked audio permissions.
// FREEBIE
2015-11-04 17:56:19 -08:00
Sam Lanning
79cb6166d5 Consolodate Base64 Classes
both org.thoughtcrime.redphone.util and
org.thoughtcrime.securesms.util have a Base64 util class,
however, other than whitespace changes, and the securesms
one having a couple of extra methods, they are the same.

This commit removes org.thoughtcrime.redphone.util.Base64 and
anything referencing it now uses
org.thoughtcrime.securesms.util.Base64

Closes #4294
2015-11-04 17:56:19 -08:00
Moxie Marlinspike
11a93fabe5 Synchronize with paired devices when a contact changes.
// FREEBIE
2015-11-04 17:56:19 -08:00
Moxie Marlinspike
05eba8c2f0 Remove travis badge
Closes #4381
// FREEBIE
2015-11-04 17:53:11 -08:00
Moxie Marlinspike
ac66c41aee Updated README to reflect name change
// FREEBIE
2015-11-03 16:47:03 -08:00
Moxie Marlinspike
c70904d7f7 Bump version to 3.1.1
// FREEBIE
2015-10-28 17:12:06 -07:00
Moxie Marlinspike
bd280ec895 Only prompt for importing system SMS db when we're the SMS app
// FREEBIE
2015-10-28 16:50:45 -07:00
Jake McGinty
02c781eb25 update reminders when dismissed
Closes #4325
// FREEBIE
2015-10-28 16:43:48 -07:00
Moxie Marlinspike
50794ba49d Updated language translations
// FREEBIE
2015-10-28 16:14:20 -07:00
Moxie Marlinspike
a086a2471c Fix crash when creating group with no avatar icon
Fixes #4320
// FREEBIE
2015-10-28 10:36:21 -07:00
Moxie Marlinspike
4271732b10 Be more rigorous about discerning media message thread.
Fixes #4312
// FREEBIE
2015-10-28 10:24:55 -07:00
Moxie Marlinspike
79313c8093 Bump version to 3.1.0
// FREEBIE
2015-10-26 14:26:23 -07:00
Moxie Marlinspike
f80909738d Update translations
// FREEBIE
2015-10-26 13:52:21 -07:00
Jake McGinty
15b131d8c2 don't show invite reminder for non-contacts
Closes #4310
// FREEBIE
2015-10-26 12:41:43 -07:00
Moxie Marlinspike
40108d5276 Catch exception strangely thrown by system query from Sony device.
Fixes #4309
// FREEBIE
2015-10-26 12:34:27 -07:00
Geonu Kang
ea4def7ea1 Change string "Load" to "See"
Fixes #4304
Closes #4305
// FREEBIE
2015-10-26 12:26:21 -07:00
Jake McGinty
285bd3de0e tweak reminder jedi mind tricks
// FREEBIE
2015-10-26 12:24:53 -07:00
Moxie Marlinspike
35bcd30b24 Updated languages
// FREEBIE
2015-10-26 11:48:21 -07:00
Moxie Marlinspike
3453aadcfd Revert "Change string "Load" to "See""
This reverts commit 7a0765c1c2.
2015-10-26 11:45:28 -07:00
Jake McGinty
758b306527 really fix crash from incorrect send job
Closes #4246
// FREEBIE
2015-10-26 11:44:45 -07:00
Geonu Kang
7a0765c1c2 Change string "Load" to "See"
Fixes #4304
Closes #4305
// FREEBIE
2015-10-26 11:42:12 -07:00
Moxie Marlinspike
f6a5f117b8 Generate thumbnails for outgoing pending messages.
Fixes #4307
// FREEBIE
2015-10-26 11:39:00 -07:00
Jake McGinty
46def68776 really show reminders
fixes #4291
// FREEBIE
2015-10-26 10:59:39 -07:00
Moxie Marlinspike
f714f5b572 Really limit the number of rows that can be joined from parts.
Fixes #4299
Fixes #4298
// FREEBIE
2015-10-25 09:58:21 -07:00
Moxie Marlinspike
a64dba8a7e Correctly format numbers in outgoing MMS
// FREEBIE
2015-10-24 18:36:03 -07:00
Moxie Marlinspike
cb3f9a6805 Distinct rows from join
// FREEBIE
2015-10-24 14:38:03 -07:00
Sam Lanning
c342f0d7e4 Change text of dialog box confirming blocking.
Blocking users now also blocks incoming calls, so the block confirmation
message has been updated.

fixes #4217
Closes #4295

// FREEBIE
2015-10-24 11:04:10 -07:00
Moxie Marlinspike
34b80f91ee Propagate clicks on conversation list thumbnails.
Closes #4292
// FREEBIE
2015-10-24 10:33:20 -07:00
Moxie Marlinspike
c258b4c7aa Expand MMS-specific queries, properly parse incoming MMS.
// FREEBIE
2015-10-24 09:40:04 -07:00
Moxie Marlinspike
474922493f Fix audio seekbar layout on GB
Fixes #4287
// FREEBIE
2015-10-23 17:47:06 -07:00
Moxie Marlinspike
a5971da2ad Revert "fix crash from incorrect send job"
This reverts commit 8fe5f35b13.
2015-10-23 17:08:17 -07:00
Jake McGinty
8fe5f35b13 fix crash from incorrect send job
related to #4153
Clsoes #4246
// FREEBIE
2015-10-23 17:02:10 -07:00
Moxie Marlinspike
d70f0f1216 Stop audio when leaving conversation.
Fixes #4290
// FREEBIE
2015-10-23 17:00:51 -07:00
Moxie Marlinspike
a1f46b3aae Reset seekbar at end of play if mediaplayer doesn't do it for us.
Fixes #4286
// FREEBIE
2015-10-23 16:55:23 -07:00
Moxie Marlinspike
2ce16297ff Fix start/stop audio race condition.
Fixes #4289
// FREEBIE
2015-10-23 16:54:58 -07:00
Moxie Marlinspike
9dc003a753 Register for audio progress events.
Closes #4288
// FREEBIE
2015-10-23 16:23:32 -07:00
Jake McGinty
2f568c6400 go back to old reminder view look
Closes #4283
// FREEBIE
2015-10-23 12:53:19 -07:00
Moxie Marlinspike
23a2a5e5f3 Fix test
// FREEBIE
2015-10-23 12:24:43 -07:00
Moxie Marlinspike
91785e5590 Updated language translations
// FREEBIE
2015-10-23 11:36:07 -07:00
Moxie Marlinspike
5111fe2e95 Display thumbnail previews for images in conversation list.
Closes #4262
// FREEBIE
2015-10-22 10:45:04 -07:00
Moxie Marlinspike
15c6f18750 Support for an audio view to allow in-app playback of audio.
Closes #4270
// FREEBIE
2015-10-22 10:32:45 -07:00
Moxie Marlinspike
d2f44f6584 Join attachments instead of running an asynchronous query.
No more SlideDeck futures, just SlideDecks.

// FREEBIE
2015-10-22 10:31:22 -07:00
Moxie Marlinspike
25e099a309 Fix two message ordering issues.
1) The group ID for jobs that process received messages was
   previously set to the sender's e164.  This guaranteed
   serialization of messages per-recipient, while allowing
   processing of multiple recipients in parallel.  Unfortunately
   in the case of groups, this results in out of order
   conversations, since the "sender" for each message is
   different.  And we can't determine that it was a group
   message until *after* we process it.  So this change just
   puts all message processing from all senders in one big queue.

2) Synchronization messages were always being displayed before
   received messages, due to the "received time" for those
   being set to the time they were sent.

Fixes #3618
Fixes #2385

// FREEBIE
2015-10-16 10:07:50 -07:00
Moxie Marlinspike
5fd9874ab6 Support for group update messages from paired devices.
Fixes #3566
// FREEBIE
2015-10-15 17:10:54 -07:00
Jake McGinty
4ffb1ea95e in-conversation invite reminder
Closes #4250
// FREEBIE
2015-10-15 13:23:37 -07:00
Bastelbursche
38d0b5caa8 Remove unused strings with "session"
Closes #4208
2015-10-15 11:34:13 -07:00
WhiteHatTux
93b82843a7 Fix minor spelling mistake in RedPhone Constant
Closes #4235
//FREEBIE
2015-10-15 11:26:32 -07:00
Jake McGinty
ae97495c47 only load partial conversation by default
Closes #4252
Fixes #3911
// FREEBIE
2015-10-15 11:16:49 -07:00
Jake McGinty
4a3faf9086 stop listening on old recipient changes
Closes #4251
// FREEBIE
2015-10-15 11:11:56 -07:00
Moxie Marlinspike
09e52834a6 Refactor "parts" to contain MMS/PDU madness to MMS code paths.
Closes #4248
// FREEBIE
2015-10-15 11:11:39 -07:00
Moxie Marlinspike
84fa2d1a34 Bump version to 3.0.3
// FREEBIE
2015-10-09 09:59:13 -07:00
Moxie Marlinspike
7342d839bc Updated translations
// FREEBIE
2015-10-09 09:49:23 -07:00
Moxie Marlinspike
450128ed63 Fix for sending secure messages to insecure groups.
Fixes #4225
// FREEBIE
2015-10-09 09:37:36 -07:00
Moxie Marlinspike
e4cd2cadf6 Bump version to 3.0.2
// FREEBIE
2015-10-05 11:38:54 -07:00
Moxie Marlinspike
b960f908dc Updated translations
// FREEBIE
2015-10-05 11:05:22 -07:00
Moxie Marlinspike
143f786322 Extern Incoming call string.
Fixes #4196
// FREEBIE
2015-10-04 17:41:23 -07:00
Geonu Kang
a0859a71b2 Make 'reset secure session' consistent
Closes #4200
Fixes #4198
// FREEBIE
2015-10-04 10:24:21 -07:00
Moxie Marlinspike
399dfb1a98 Restrict Google's MultiWaveView animation to JB+
Fixes #4203
// FREEBIE
2015-10-04 10:21:08 -07:00
Moxie Marlinspike
0225db9db5 Bump version to 3.0.1
// FREEBIE
2015-10-02 14:01:51 -07:00
Moxie Marlinspike
f01cab57c7 Screen security if enabled.
Fixes #4187
// FREEBIE
2015-10-02 13:40:49 -07:00
Moxie Marlinspike
26f8870344 server failed -> network failed
// FREEBIE
2015-10-02 13:37:16 -07:00
Moxie Marlinspike
ccbe856ffb Handle voice GCM intents in AsyncTask.
// FREEBIE
2015-10-02 13:36:51 -07:00
Moxie Marlinspike
c041495834 Correctly parse RedPhone JSON.
Fixes #4182
// FREEBIE
2015-10-02 11:42:24 -07:00
Moxie Marlinspike
c91315c0f1 Bump version to 3.0.0
// FREEBIE
2015-10-02 08:07:31 -07:00
Moxie Marlinspike
94776c40e1 Put directory refresh into Signal migration
// FREEBIE
2015-10-02 07:55:59 -07:00
Moxie Marlinspike
b45e6b6139 Updated translations
// FREEBIE
2015-10-02 07:37:43 -07:00
Moxie Marlinspike
e0ebe6c858 Switch up thread record strings
// FREEBIE
2015-10-01 18:01:15 -07:00
Moxie Marlinspike
cbfd3af5c2 Handle drafts after security information has been resolved.
// FREEBIE
2015-10-01 17:46:47 -07:00
Moxie Marlinspike
c0a26862f3 No special missed call notifications.
Fixes #4174
// FREEBIE
2015-10-01 17:33:10 -07:00
Moxie Marlinspike
214629e2db Fix redraw issue on GB.
// FREEBIE
2015-10-01 17:27:34 -07:00
Moxie Marlinspike
77d73fa572 Correctly display call actions in thread list
Fixes #4170
// FREEBIE
2015-10-01 17:27:22 -07:00
Moxie Marlinspike
a7348f6ae0 Updated translations
// FREEBIE
2015-10-01 16:21:45 -07:00
Geonu Kang
56ae12a29f Fix "MMS download failed" click intercept
Fixes #4153
Closes #4154
// FREEBIE
2015-10-01 16:17:02 -07:00
Jake McGinty
d071625326 fix experience upgrade versioning
Closes #4169
// FREEBIE
2015-10-01 16:02:05 -07:00
Moxie Marlinspike
ff1f190110 Rename some strings
// FREEBIE
2015-10-01 12:47:13 -07:00
Jake McGinty
cdf982a356 be safer when processing parts in AttachmentDownloadJob
Closes #4166
// FREEBIE
2015-10-01 12:36:54 -07:00
Moxie Marlinspike
c6abb7dc64 Switch recipient preference from Rington -> Notification tone
// FREEBIE
2015-10-01 12:22:17 -07:00
Moxie Marlinspike
2eeb7c43da Fix for transport selection
// FREEBIE
2015-10-01 12:22:02 -07:00
char32
7ff8c99055 Add the verizon MSISDN x-vzw-mdn header to MMS requests.
Closes #4148
Fixes #3150
2015-10-01 12:14:47 -07:00
Moxie Marlinspike
1fd8025cb5 No secure calls to yourself.
Fixes #4156
// FREEBIE
2015-10-01 11:14:11 -07:00
Moxie Marlinspike
003787e4a6 Externalize missing strings.
Fixes #4158
// FREEBIE
2015-10-01 10:27:20 -07:00
Brinly Taylor
0d05a2bf09 Signal: Clarify a string.
Closes #4157
// FREEBIE
2015-10-01 10:19:03 -07:00
Moxie Marlinspike
bd54b1a053 Update JobManager and libtextsecure pins
// FREEBIE
2015-09-30 18:33:35 -07:00
Jake McGinty
3035dc4df9 Experience upgrade splash screen.
Behaves similarly to the DatabaseUpgradeActivity. You have a
static list of ExperienceUpgrade models that include a "trigger"
version, where when a user upgrades through it a notification
will appear, and there will be a splash explanation screen.

Right now the splash screens are basic and not too configurable,
but that can be reworked as upgrades demand.

Closes #4151
2015-09-30 18:29:54 -07:00
Moxie Marlinspike
0b20e99cd2 Refresh attributes to signal voice support on update.
// FREEBIE
2015-09-30 18:24:40 -07:00
Moxie Marlinspike
5a73884b0b Switch to production.
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
e46caa024d Don't ring on incoming calls from blocked numbers
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
3bec127020 Disable backups for Android M
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
31e20ca87e Distinguish between secure and insecure call in conversation menu.
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
c87012ea69 Fixes #4142
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
7f59983ce4 Fix for bluetooth NPE lollipop bug
Fixes #4141
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
0402b45480 Simplify keyguard stuff.
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
123c7b2119 Extract RedPhone string resources
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
b68691bf05 Remove unnecessary volume level watcher.
// FREEBIE
2015-09-30 14:30:11 -07:00
Moxie Marlinspike
d9a3f5a3b8 Fix up security initialization stuff in ConversationActivity
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
a0fc948519 Menu should be 'reset secure session,' since it'll never end.
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
4044da849e Replace all strings containing 'TextSecure' with 'Signal'
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
7377e6c7da Support for syncing and checking secure voice support.
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
cf14b0478d Fix up incoming call colors
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
ba67f108d4 Support unregistration from RedPhone
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
4fb5c6dd9a Tagify RedPhone classes.
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
826dc601c1 Remove dead RedPhone code.
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
26979b1c62 Log calls to conversations
// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
36b7f767b6 Fixes for poorly merged behavior
1) Fixed call in progress notification

2) Don't cache auth info in service

// FREEBIE
2015-09-30 14:30:10 -07:00
Moxie Marlinspike
fdfa15aa4d Working proximity lock.
// FREEBIE
2015-09-30 14:30:09 -07:00
Moxie Marlinspike
961b9b882f Working bluetooth
// FREEBIE
2015-09-30 14:30:09 -07:00
Moxie Marlinspike
d83a3d71bc Support for Signal calls.
Merge in RedPhone

// FREEBIE
2015-09-30 14:30:09 -07:00
Moxie Marlinspike
3d4ae60d81 Remove unused class
// FREEBIE
2015-09-30 14:30:08 -07:00
Moxie Marlinspike
ea50714b0a Bump version to 2.28.1
// FREEBIE
2015-09-28 17:07:39 -07:00
Jake McGinty
92422a939a trim threads in the right direction
Closes #4143
// FREEBIE
2015-09-28 16:59:06 -07:00
Moxie Marlinspike
d543c0b36e Bump version to 2.28.0
// FREEBIE
2015-09-27 09:35:00 -07:00
Jake McGinty
c6e2b5f6c5 fix more batch select click edge cases
Closes #4122
// FREEBIE
2015-09-27 09:08:05 -07:00
Jake McGinty
368f5c8dba setHasStableIds(false)
because that shit is not stable
fixes #4128
// FREEBIE
2015-09-25 17:10:36 -07:00
Jake McGinty
14f7c2d7a1 fix thumbnail click handling when batch selecting
Closes #4118
// FREEBIE
2015-09-24 15:59:48 -07:00
Moxie Marlinspike
ffae7a24f7 Updated language translations
// FREEBIE
2015-09-24 14:14:38 -07:00
Jake McGinty
f047df0fe8 fix bubble height change glitch
Closes #4033
// FREEBIE
2015-09-24 14:12:09 -07:00
Jake McGinty
469c3298cc fix click interception logic to handle failures
Closes #4111
// FREEBIE
2015-09-24 14:12:09 -07:00
Moxie Marlinspike
92593d459b Remove the final vestiges of encrypted SMS
Fixes #4026
// FREEBIE
2015-09-24 14:12:09 -07:00
Jake McGinty
99d3374d35 migrate conversation list to RecyclerView
fixes #2488
fixes #2333
// FREEBIE
2015-09-24 14:12:09 -07:00
Matthias Voppichler
cbcd53a8a0 fixing duplicate system-contacts
Fixes #4029
Closes #4072
2015-09-24 14:12:09 -07:00
Moxie Marlinspike
6ba95446ec Bump version to 2.27.2
// FREEBIE
2015-09-24 14:11:31 -07:00
Moxie Marlinspike
50f079af8c Fix for AIOBE when language is no longer supported.
// FREEBIE
2015-09-24 13:58:14 -07:00
Moxie Marlinspike
8c96f9fd93 Bump version to 2.27.1
// FREEBIE
2015-09-23 12:14:43 -07:00
Jake McGinty
e574bcf15c initialize security in conversation first
Closes #4108
// FREEBIE
2015-09-23 12:03:45 -07:00
Moxie Marlinspike
7520af749c Bump version to 2.27.0
// FREEBIE
2015-09-21 12:25:44 -07:00
Jake McGinty
b55df9e186 don't cache preference for emoji
Closes #4098
// FREEBIE
2015-09-21 12:08:23 -07:00
Jake McGinty
9ea53d7b1e fix gingerbread view issues
Closes #4085
// FREEBIE
2015-09-20 19:40:32 -07:00
Jake McGinty
6ae38d0718 fix glide bitmap locking issue
Closes #4086
// FREEBIE
2015-09-20 19:08:40 -07:00
Jake McGinty
eedbc667c6 fix system emoji transparency
Closes #4084
// FREEBIE
2015-09-17 15:05:21 -07:00
Moxie Marlinspike
9b524e0496 Updated language translations
// FREEBIE
2015-09-17 13:24:43 -07:00
Jake McGinty
92b2da0286 download control details
Closes #4063
// FREEBIE
2015-09-17 12:51:57 -07:00
Moxie Marlinspike
0794380ca8 Listen for recipient changes in conversations and group updates.
Closes #4079
// FREEBIE
2015-09-17 12:22:35 -07:00
Jake McGinty
a7e05c4cd6 catch Camera RuntimeExceptions
fixes #3895
Closes #4083
// FREEBIE
2015-09-17 12:22:01 -07:00
Jake McGinty
336962eb55 fix EmojiEditText typo causing crash
fixes #4078
// FREEBIE
2015-09-17 12:22:01 -07:00
Jake McGinty
fbc527145c re-introduce unit tests
Closes #4057
// FREEBIE
2015-09-17 12:22:01 -07:00
Jake McGinty
2d65464c04 fix attachment remove button alignment
fixes #3597
Closes #4077
// FREEBIE
2015-09-17 12:22:01 -07:00
Jake McGinty
415a61a09b TransferControlView
Closes #4044
// FREEBIE
2015-09-17 12:22:01 -07:00
Jake McGinty
f95435b0f1 show IME emoji button when using system
Closes #4043
// FREEBIE
2015-09-17 12:20:25 -07:00
Jake McGinty
e077cc6581 advanced pref to use android emoji
// FREEBIE
2015-09-17 12:20:25 -07:00
Jake McGinty
551274f167 Large attachment support
Closes #4019
// FREEBIE
2015-09-17 12:20:25 -07:00
Moxie Marlinspike
4f7ac59c6f Bump version to 2.26.5
// FREEBIE
2015-09-15 12:18:46 -07:00
Jake McGinty
0e06e2de97 fix queuing of pending parts that had data already
fixes #4061
Closes #4073
// FREEBIE
2015-09-14 18:06:03 -07:00
Moxie Marlinspike
ed1d411bde Bump version to 2.26.4
// FREEBIE
2015-09-09 18:21:01 -07:00
Jake McGinty
8933e03c02 prevent blocking recipient resolution on UI thread
fixes #4058
Closes #4059
// FREEBIE
2015-09-09 18:13:25 -07:00
Moxie Marlinspike
2c48155769 Bump version to 2.26.3
// FREEBIE
2015-09-09 17:14:55 -07:00
Moxie Marlinspike
16e258bdbc Only schedule a reminder if it's an alerting notification.
// FREEBIE
2015-09-09 16:53:00 -07:00
Jake McGinty
c418ca1890 fix thumbnail click
fixes #4051
Closes #4053
// FREEBIE
2015-09-09 16:52:53 -07:00
Moxie Marlinspike
3be011bdaf Bump version to 2.26.2
// FREEBIE
2015-09-07 15:15:20 -07:00
Jake McGinty
526f6e3058 don't try generating an in-progress part thumbnail
Closes #4042
// FREEBIE
2015-09-07 14:56:56 -07:00
Jake McGinty
21b7dccf1c fix persistent stale attachment jobs
Closes #4041
// FREEBIE
2015-09-07 14:37:53 -07:00
Jake McGinty
adc6fc8524 only allow thumbnail clicks when slide is present
fixes #4024
Closes #4040
// FREEBIE
2015-09-07 14:16:29 -07:00
Moxie Marlinspike
b5216ed7af Make recipient lookup asynchronous, add listener when appropriate.
Fixes #4032

// FREEBIE
2015-09-07 11:22:53 -07:00
Moxie Marlinspike
d4718c373a Fix for scanning provided identity
Fixes #4028
// FREEBIE
2015-09-06 21:26:43 -07:00
Moxie Marlinspike
797513b372 Bump version to 2.26.1
// FREEBIE
2015-09-04 14:24:37 -07:00
Moxie Marlinspike
0b7342ba67 Updated langauge translations
// FREEBIE
2015-09-04 14:15:47 -07:00
Jake McGinty
103686f89b damnit, glide.
fixes #2957
// FREEBIE
2015-09-04 12:47:48 -07:00
Jake McGinty
aaf3d6a7c7 media download controls i18n
fixes #4015
// FREEBIE
2015-09-04 12:11:06 -07:00
Jake McGinty
923d9fb07b fix crash on pending self-sent media
fixes #4016
Closes #4017
// FREEBIE
2015-09-04 11:42:58 -07:00
Jake McGinty
df164a58c9 remove BitmapUtilTest
fixes #4014
// FREEBIE
2015-09-04 11:19:50 -07:00
Moxie Marlinspike
5ef65f039d Run notification reminder broadcast in an AsyncTask
Fixes #4016
// FREEBIE
2015-09-04 09:40:59 -07:00
Moxie Marlinspike
fd61fcef0d Bump version to 2.26.0
// FREEBIE
2015-09-03 16:59:31 -07:00
Moxie Marlinspike
d67d985b81 Mark implicit features not required
// FREEBIE
2015-09-03 16:59:11 -07:00
Moxie Marlinspike
a74276d31b Updated language translations
// FREEBIE
2015-09-03 16:39:09 -07:00
Jake McGinty
6d0e783236 fix GB StringSet compat issue.
// FREEBIE
2015-09-03 14:04:47 -07:00
Jake McGinty
17cde0cbb7 fix minSdk 10 for pref library
// FREEBIE
2015-09-03 12:40:31 -07:00
Jake McGinty
80ce83ef9d Media download controls
Closes #3991
// FREEBIE
2015-09-03 11:40:55 -07:00
f41c0r
7e2c9f97e9 Adds dependency for display in notifications
Fixes #3982
Closes #3986

// FREEBIE
2015-09-02 12:56:54 -07:00
Sam Lanning
727c471234 Maintenance: Removed unused field in MediaPreviewActivity
Closes #3934
// FREEBIE
2015-09-02 12:51:30 -07:00
Sam Lanning
201da6f2a2 Maintenance: changed upcast to use method type parameter.
Closes #3933
// FREEBIE
2015-09-02 12:50:38 -07:00
Sam Lanning
99adbe5784 Made some inner classes static (For Efficiency)
(and made one explicitly private)

Closes #3932
// FREEBIE
2015-09-02 12:46:56 -07:00
Jake McGinty
d0fc5268a6 add vietnamese translations
Closes #3978
// FREEBIE
2015-09-02 12:37:17 -07:00
Jake McGinty
0c9d9e8dcf use glide for encoding and resizing outgoing media
Closes #3915
// FREEBIE
2015-09-02 12:34:28 -07:00
Jake McGinty
1641fd91cf let ThumbnailView handle remove button placement
Closes #3849
// FREEBIE
2015-09-02 12:23:24 -07:00
Moxie Marlinspike
835f1efc76 Bump version to 2.25.3
// FREEBIE
2015-08-12 13:20:16 -07:00
Moxie Marlinspike
d6179bc12b Update notifications on background thread.
// FREEBIE
2015-08-12 10:44:27 -07:00
Moxie Marlinspike
3edda51379 Bump version to 2.25.2
// FREEBIE
2015-08-10 10:52:58 -07:00
Moxie Marlinspike
82b74e8ce7 Fix NPE on media message with no media.
Fixes #3921
// FREEBIE
2015-08-10 09:33:57 -07:00
Moxie Marlinspike
65ac2b3e18 Revert "use new android unit test support"
This reverts commit 06e137aee9.
2015-08-10 09:30:59 -07:00
Jake McGinty
ae17b4b24a bright background for unread messages
Closes #3909
// FREEBIE
2015-08-07 17:15:50 -07:00
Jake McGinty
06e137aee9 use new android unit test support
Closes #3904
// FREEBIE
2015-08-07 17:11:54 -07:00
Moxie Marlinspike
e97255a17f Bump version to 2.25.1
// FREEBIE
2015-08-07 17:08:06 -07:00
Moxie Marlinspike
58fd6f9273 Actually play the default notification sound.
Fixes #3912
// FREEBIE
2015-08-07 12:52:32 -07:00
Moxie Marlinspike
31b2fab6e9 Bump version to 2.25.0
// FREEBIE
2015-08-06 12:38:21 -07:00
Moxie Marlinspike
9053bccd33 Updated language translations
// FREEBIE
2015-08-06 12:19:20 -07:00
Jake McGinty
edc47247f9 add thread/date multi-col SQLite indices
Closes #3880
// FREEBIE
2015-08-06 11:29:59 -07:00
Jake McGinty
107e202ab4 emojify!! emojify!?
fixes #3802
Closes #3902
// FREEBIE
2015-08-06 11:11:29 -07:00
Jake McGinty
3c400f958e handle null emojify inputs better
fixes #3889
Closes #3901
// FREEBIE
2015-08-06 10:51:05 -07:00
Moxie Marlinspike
973ed7686b Don't sync groups when there are no groups.
Fixes #3882
// FREEBIE
2015-08-06 10:20:13 -07:00
McLoo
716ed94ca1 Fix notification repeat
by adding an undeniable truth
Until now we use the reminderCount as threadId and
 afterwards we updateNotification with a repeat count of always 0

Fixes #3893
Closes #3896
2015-08-06 10:15:14 -07:00
McLoo
5fe1a28954 Fix broken multiple contact selection
Increased tap area of action button too

Closes #3855
2015-08-05 14:20:04 -07:00
agrajaghh
a820500ae0 finish MessageRecipientAsyncTask when context is destroyed
Closes #3591

// FREEBIE
2015-08-05 13:57:19 -07:00
Jake McGinty
f812efff3c only create DB readers as needed
Closes #3730
// FREEBIE
2015-08-05 13:48:07 -07:00
f41c0r
a3a7f8fb6c Add support to copy multiple messages
Fixes #3748
Closes #3798

// FREEBIE
2015-08-05 13:41:16 -07:00
Jake McGinty
00eb637e51 stop sync resolution of recipients on ui thread
Closes #3885
// FREEBIE
2015-08-05 13:14:21 -07:00
Jake McGinty
151eca971b stop conversation list from hogging db
Closes #3883
// FREEBIE
2015-08-05 13:13:08 -07:00
RiseT
f693a04531 Preferences Message Notifications Description
// FREEBIE
Closes #3871
2015-08-05 13:11:13 -07:00
Geonu Kang
eae80e2c86 Fix Japanese language entry
Fixes #3861
Closes #3862
// FREEBIE
2015-08-05 13:09:39 -07:00
Moxie Marlinspike
f8bb065ffd Support for images in notifications.
Closes #3859
Fixes #1858
// FREEBIE
2015-08-05 13:08:28 -07:00
Moxie Marlinspike
120cde9917 Support for notification privacy settings.
// FREEBIE
2015-08-05 13:06:37 -07:00
Jake McGinty
d6d7ca19c1 reduce overdraw
Closes #3856
// FREEBIE
2015-08-05 13:05:01 -07:00
Jake McGinty
ec8b06e96c fix custom input race case
fixes #3824
Closes #3851
// FREEBIE
2015-08-05 13:00:58 -07:00
Jake McGinty
0c14639f9c fix GB half-screen cropping
Closes #3848
// FREEBIE
2015-08-05 12:56:26 -07:00
Moxie Marlinspike
27aabbc4d9 Bump version to 2.24.1
// FREEBIE
2015-08-03 14:13:21 -07:00
Moxie Marlinspike
09186cd8ad Fix libtextsecure pins
Fixes #3853
// FREEBIe
2015-08-03 13:52:55 -07:00
Jake McGinty
52e4abf562 prevent a thread race in CameraView
when a camera preview surface is destroyed, send it down the same pipelien
to make sure a race condition isn't hit

fixes #3864
Closes #3875
// FREEBIE
2015-08-03 13:50:02 -07:00
Moxie Marlinspike
324c85cd9f Update coinbase image
// FREEBIE
2015-07-30 17:09:38 -07:00
Moxie Marlinspike
a5e3935672 Update beta info for open beta
// FREEBIE
2015-07-30 16:06:05 -07:00
Moxie Marlinspike
c58ba19451 Bump version to 2.24.0
// FREEBIE
2015-07-30 13:53:39 -07:00
Jake McGinty
b5318ed248 fix composition bar disappearing
Closes #3846
// FREEBIE
2015-07-30 13:28:16 -07:00
Moxie Marlinspike
964171b26a Upgrade to recent libtextsecure
// FREEBIE
2015-07-30 13:03:54 -07:00
Moxie Marlinspike
1fa29f89f9 Fix broken tests.
// FREEBIE
2015-07-30 13:03:44 -07:00
Moxie Marlinspike
68df5f832c Updated language translations.
// FREEBIE
2015-07-30 11:06:19 -07:00
Moxie Marlinspike
40a3134b32 Updated language translations.
// FREEBIE
2015-07-30 10:50:55 -07:00
Heartsucker
9f3310f67a single initialization
Closes #3794
// FREEBIE
2015-07-30 10:18:38 -07:00
Geonu Kang
278214ef86 Improve multi-device strings consistency
Fixes #3830
Closes #3840
// FREEBIE
2015-07-30 10:15:50 -07:00
McLoo
109a6ed599 Update language list for 90%+ translations
Closes #3841
//FREEBIE
2015-07-30 08:17:52 -07:00
Moxie Marlinspike
99d3a76b56 Soften a few colors that are a bit too vibrant.
Closes #3814
// FREEBIE
2015-07-29 16:44:41 -07:00
Sam Lanning
c72719747a Added white background to indicator for BLOCKED indicator
Also modified text colour in light theme to nicer red

fixes #3524
Closes #3806
// FREEBIE
2015-07-29 16:18:12 -07:00
Jake McGinty
a84dcf6a8e assert gif size constraints before OOMEs
fixes #3778
closes #3833
// FREEBIE
2015-07-29 16:17:27 -07:00
Jake McGinty
c36c759c8b fix EmojiTextView...
Closes #3837
// FREEBIE
2015-07-29 16:17:27 -07:00
Moxie Marlinspike
bbf33f88e0 Support for static RecipientDetails for certain shortcodes.
Closes #3813
// FREEBIE
2015-07-29 16:17:27 -07:00
agrajaghh
e2e5aa32a8 fix icon for "Take Photo" in the attachment dialog and
also change "Take Photo" to "Camera"

fixes #3819
closes #3820

// FREEBIE
2015-07-29 16:17:27 -07:00
Moxie Marlinspike
e88a7c3fd7 Update blocked contact list item on main thread.
Fixes #3825
// FREEBIE
2015-07-29 16:17:27 -07:00
Jake McGinty
98393ba2e1 fix new QAD layout issues
fixes #3707
// FREEBIE
2015-07-29 16:17:27 -07:00
Jake McGinty
e145b8171d revert emoji ellipsizing temporarily
it doesn't react to layout changes correct, better
to not have it for the time being.

closes #3718
closes #3812
// FREEBIE
2015-07-29 16:17:27 -07:00
Jake McGinty
5cf95f5b3d fix issue with camera controls going missing
fixes #3775
Closes #3823
// FREEBIE
2015-07-29 16:17:27 -07:00
Jake McGinty
8fbc14b191 enable half preview in GB
Closes #3826
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
30f2c71861 work around weird GB layout limitations
that was freaking annoying

// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
d4fc12f56c unbreak build
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
7c32e5b1fb support variable keyboard heights
Fixes #3661
Closes #3822
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
13bad6dfed Smooth transition for custom keyboards and softkey
Closes #3786
Fixes #3780
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
24e14cbc73 fix gif NPE
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
a2d63d117b fix rounded corners memory thrash
// FREEBIE
2015-07-29 16:17:26 -07:00
agrajaghh
102a151127 fix icon size of quick_camera_rear
this also changes BUILDING.md to reflect the new syntax of pngs_from_svg.py

fixes #3769
closes #3770

// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
cc5d779050 add previewFormat logging to QuickCamera
Closes #3760
//FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
2c41394892 inflate transport popup opportunistically
Closes #3763
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
454c604b86 asyncify reminderView
Closes #3762
// FREEBIE
2015-07-29 16:17:26 -07:00
Jake McGinty
f13ad54ba1 ditch RoundedImageView, make animated gifs work
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
a66dd8be82 Gradle wrapper, all.
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
7de1683195 Add recipient listener to ConversationItem
Fixes #3626
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
b1f336c874 Fix color selection dialog on GB.
Fixes #3626
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
39ac2b5042 Expand tap target of contact selection keyboard toggles.
Fixes #3750
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
c27459a760 Enable PTR for JB+
Fixes #3754
// FREEBIE
2015-07-29 16:17:26 -07:00
Moxie Marlinspike
0a3b78fec1 Bump version to 2.23.3
// FREEBIE
2015-07-24 15:14:32 -07:00
Moxie Marlinspike
156a86013f Add phone number type to contacts DB to fix HTC bug.
Fixes #3784
// FREEBIE
2015-07-24 10:39:29 -07:00
Moxie Marlinspike
20313127f5 Remove automation build type, bump gradle and tools versions.
// FREEBIE
2015-07-22 14:29:50 -07:00
5282 changed files with 447461 additions and 98712 deletions

45
.github/ISSUE_TEMPLATE.md vendored Normal file
View File

@@ -0,0 +1,45 @@
<!-- This is a bug report template. By following the instructions below and filling out the sections with your information, you will help the developers get all the necessary data to fix your issue.
You can also preview your report before submitting it. You may remove sections that aren't relevant to your particular case.
Before we begin, please note that this tracker is only for issues. It is not for questions, comments, or feature requests.
If you would like to discuss a new feature or submit suggestions, please visit the community forum:
https://community.signalusers.org
If you are looking for support, please visit our support center:
https://support.signal.org/
or email support@signal.org
Let's begin with a checklist: Replace the empty checkboxes [ ] below with checked ones [x] accordingly. -->
- [ ] I have searched open and closed issues for duplicates
- [ ] I am submitting a bug report for existing functionality that does not work as intended
- [ ] I have read https://github.com/signalapp/Signal-Android/wiki/Submitting-useful-bug-reports
- [ ] This isn't a feature request or a discussion topic
----------------------------------------
### Bug description
Describe here the issue that you are experiencing.
### Steps to reproduce
- using hyphens as bullet points
- list the steps
- that reproduce the bug
**Actual result:** Describe here what happens after you run the steps above (i.e. the buggy behaviour)
**Expected result:** Describe here what should happen after you run the steps above (i.e. what would be the correct behaviour)
### Screenshots
<!-- you can drag and drop images below -->
### Device info
<!-- replace the examples with your info -->
**Device:** Manufacturer Model XVI
**Android version:** 0.0.0
**Signal version:** 0.0.0
### Link to debug log
<!-- immediately after the bug has happened capture a debug log via Signal's advanced settings and paste the link below -->

23
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@@ -0,0 +1,23 @@
<!-- You can remove this first section if you have contributed before -->
### First time contributor checklist
<!-- replace the empty checkboxes [ ] below with checked ones [x] accordingly -->
- [ ] I have read [how to contribute](https://github.com/signalapp/Signal-Android/blob/master/CONTRIBUTING.md) to this project
- [ ] I have signed the [Contributor License Agreement](https://whispersystems.org/cla/)
### Contributor checklist
<!-- replace the empty checkboxes [ ] below with checked ones [x] accordingly -->
- [ ] I am following the [Code Style Guidelines](https://github.com/signalapp/Signal-Android/wiki/Code-Style-Guidelines)
- [ ] I have tested my contribution on these devices:
* Device A, Android X.Y.Z
* Device B, Android Z.Y
* Virtual device W, Android Y.Y.Z
- [ ] My contribution is fully baked and ready to be merged as is
- [ ] I ensure that all the open issues my contribution fixes are mentioned in the commit message of my first commit using the `Fixes #1234` [syntax](https://help.github.com/articles/closing-issues-via-commit-messages/)
----------
### Description
<!--
Describe briefly what your pull request proposes to fix. Especially if you have more than one commit, it is helpful to give a summary of what your contribution as a whole is trying to solve.
Also, please describe shortly how you tested that your fix actually works.
-->

31
.github/workflows/android.yml vendored Normal file
View File

@@ -0,0 +1,31 @@
name: Android CI
on:
pull_request:
push:
branches:
- 'master'
- '4.**'
- '5.**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Install NDK
run: echo "y" | sudo /usr/local/lib/android/sdk/tools/bin/sdkmanager --install "ndk;21.0.6113669" --sdk_root=${ANDROID_SDK_ROOT}
- name: Validate Gradle Wrapper
uses: gradle/wrapper-validation-action@v1
- name: Build with Gradle
run: ./gradlew qa

18
.github/workflows/docker.yml vendored Normal file
View File

@@ -0,0 +1,18 @@
name: Reproducible Build Check
on:
schedule:
- cron: '0 5 * * *'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build image
run: cd reproducible-builds && docker build -t signal-android . && cd ..
- name: Test build
run: docker run --rm -v $(pwd):/project -w /project signal-android ./gradlew clean assembleRelease

8
.gitignore vendored
View File

@@ -1,5 +1,8 @@
.classpath
captures/
project.properties
keystore.debug.properties
keystore.staging.properties
.project
.settings
bin/
@@ -8,7 +11,6 @@ gen/
*.iml
out
tests
lint.xml
local.properties
ant.properties
.DS_Store
@@ -21,3 +23,7 @@ library/lib/
library/obj/
ffpr
test/androidTestEspresso/res/values/arrays.xml
obj/
jni/libspeex/.deps/
pkcs11.password
dev.keystore

View File

@@ -1,7 +0,0 @@
language: android
android:
components:
- platform-tools
- build-tools-19.1.0
- android-19
- extra-android-m2repository

View File

@@ -1,11 +0,0 @@
[main]
host = https://www.transifex.com
lang_map = fr_CA:fr-rCA,pt_BR:pt-rBR,pt_PT:pt,zh_CN:zh-rCN,zh_HK:zh-rHK,zh_TW:zh-rTW,da_DK:da-rDK,de_DE:de,tr_TR:tr,fr_FR:fr,es_ES:es,hu_HU:hu,sv_SE:sv-rSE,bg_BG:bg,el_GR:el,kn_IN:kn-rIN,cs_CZ:cs,sr:sr,he:iw,id:in
[textsecure-official.master]
file_filter = res/values-<lang>/strings.xml
source_file = res/values/strings.xml
source_lang = en
type = ANDROID

View File

@@ -1,423 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="org.thoughtcrime.securesms"
android:versionCode="138"
android:versionName="2.23.2">
<uses-sdk tools:overrideLibrary="com.amulyakhare.textdrawable,com.astuetz.pagerslidingtabstrip,pl.tajchert.waitingdots"/>
<permission android:name="org.thoughtcrime.securesms.ACCESS_SECRETS"
android:label="Access to TextSecure Secrets"
android:protectionLevel="signature" />
<uses-feature android:name="android.hardware.camera" android:required="false" />
<uses-permission android:name="org.thoughtcrime.securesms.ACCESS_SECRETS"/>
<uses-permission android:name="android.permission.READ_PROFILE"/>
<uses-permission android:name="android.permission.WRITE_PROFILE"/>
<uses-permission android:name="android.permission.BROADCAST_WAP_PUSH"
tools:ignore="ProtectedPermissions"/>
<uses-permission android:name="android.permission.READ_CONTACTS"/>
<uses-permission android:name="android.permission.WRITE_CONTACTS"/>
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.RECEIVE_SMS"/>
<uses-permission android:name="android.permission.RECEIVE_MMS"/>
<uses-permission android:name="android.permission.READ_SMS"/>
<uses-permission android:name="android.permission.SEND_SMS"/>
<uses-permission android:name="android.permission.WRITE_SMS"/>
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_CALL_LOG" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<!-- For sending location tiles in the future -->
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
<!-- So we can add a TextSecure 'Account' -->
<uses-permission android:name="android.permission.READ_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.AUTHENTICATE_ACCOUNTS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS"/>
<!-- For conversation 'shortcuts' on the desktop -->
<uses-permission android:name="android.permission.INSTALL_SHORTCUT"/>
<!-- For sending/receiving events -->
<uses-permission android:name="android.permission.WRITE_CALENDAR"/>
<uses-permission android:name="android.permission.READ_CALENDAR"/>
<!-- For fixing MMS -->
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/>
<!-- Set image as wallpaper -->
<uses-permission android:name="android.permission.SET_WALLPAPER"/>
<!-- Permissions from RedPhone -->
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BROADCAST_STICKY" />
<uses-permission android:name="android.permission.MODIFY_PHONE_STATE" />
<uses-permission android:name="android.permission.PROCESS_OUTGOING_CALLS" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="android.permission.CALL_PRIVILEGED" />
<uses-permission android:name="android.permission.DISABLE_KEYGUARD" />
<uses-permission android:name="android.permission.RAISED_THREAD_PRIORITY" />
<uses-permission android:name="android.permission.READ_CALL_STATE"/>
<uses-permission android:name="android.permission.READ_LOGS"/>
<uses-permission android:name="android.permission.WRITE_CALL_LOG"/>
<permission android:name="org.thoughtcrime.securesms.permission.C2D_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="org.thoughtcrime.securesms.permission.C2D_MESSAGE" />
<application android:name=".ApplicationContext"
android:icon="@drawable/icon"
android:label="@string/app_name"
android:theme="@style/TextSecure.LightTheme">
<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<meta-data android:name="org.thoughtcrime.securesms.mms.TextSecureGlideModule"
android:value="GlideModule" />
<activity android:name=".CountrySelectionActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ImportExportActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PromptMmsActivity"
android:label="Configure MMS Settings"
android:windowSoftInputMode="stateUnchanged"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DeviceProvisioningActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="tsdevice"/>
</intent-filter>
</activity>
<activity android:name=".preferences.MmsPreferencesActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ShareActivity"
android:excludeFromRecents="true"
android:launchMode="singleTask"
android:noHistory="true"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.SEND" />
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="audio/*" />
<data android:mimeType="image/*" />
<data android:mimeType="text/plain" />
<data android:mimeType="video/*" />
</intent-filter>
</activity>
<activity android:name=".ConversationListActivity"
android:label="@string/app_name"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"
android:exported="true" />
<activity-alias android:name=".RoutingActivity"
android:targetActivity=".ConversationListActivity"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity-alias>
<activity android:name=".ConversationActivity"
android:windowSoftInputMode="stateUnchanged"
android:launchMode="singleTask"
android:theme="@style/TextSecure.LightTheme.Popup"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".ConversationPopupActivity"
android:windowSoftInputMode="stateVisible"
android:launchMode="singleTask"
android:taskAffinity=""
android:excludeFromRecents="true"
android:theme="@style/TextSecure.LightTheme.Popup"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".MessageDetailsActivity"
android:label="@string/AndroidManifest__message_details"
android:windowSoftInputMode="stateHidden"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".GroupCreateActivity"
android:windowSoftInputMode="stateVisible"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DatabaseMigrationActivity"
android:theme="@style/NoAnimation.Theme.AppCompat.Light.DarkActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DatabaseUpgradeActivity"
android:theme="@style/NoAnimation.Theme.AppCompat.Light.DarkActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphraseCreateActivity"
android:label="@string/AndroidManifest__create_passphrase"
android:windowSoftInputMode="stateUnchanged"
android:theme="@style/TextSecure.LightIntroTheme"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphrasePromptActivity"
android:label="@string/AndroidManifest__enter_passphrase"
android:launchMode="singleTask"
android:theme="@style/TextSecure.LightIntroTheme"
android:windowSoftInputMode="stateAlwaysVisible"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".NewConversationActivity"
android:theme="@style/TextSecure.LightNoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PushContactSelectionActivity"
android:label="@string/AndroidManifest__select_contacts"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ViewIdentityActivity"
android:label="@string/AndroidManifest__public_identity_key"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ViewLocalIdentityActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphraseChangeActivity"
android:label="@string/AndroidManifest__change_passphrase"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".VerifyIdentityActivity"
android:label="@string/AndroidManifest__verify_identity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ApplicationPreferencesActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".RegistrationActivity"
android:windowSoftInputMode="stateUnchanged"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".RegistrationProgressActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DeviceListActivity"
android:label="@string/AndroidManifest_manage_paired_devices"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".LogSubmitActivity"
android:label="@string/AndroidManifest__log_submit"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".MediaPreviewActivity"
android:label="@string/AndroidManifest__media_preview"
android:windowSoftInputMode="stateHidden"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".MediaOverviewActivity"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DummyActivity"
android:theme="@android:style/Theme.NoDisplay"
android:enabled="true"
android:allowTaskReparenting="true"
android:noHistory="true"
android:excludeFromRecents="true"
android:alwaysRetainTaskState="false"
android:stateNotNeeded="true"
android:clearTaskOnLaunch="true"
android:finishOnTaskLaunch="true" />
<activity android:name=".PlayServicesProblemActivity"
android:theme="@android:style/Theme.Translucent.NoTitleBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".SmsSendtoActivity">
<intent-filter>
<action android:name="android.intent.action.SENDTO" />
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="sms" />
<data android:scheme="smsto" />
<data android:scheme="mms" />
<data android:scheme="mmsto" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="vnd.android.cursor.item/vnd.org.thoughtcrime.securesms.contact" />
</intent-filter>
</activity>
<activity android:name=".RecipientPreferenceActivity"
android:theme="@style/TextSecure.LightNoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".BlockedContactsActivity"
android:theme="@style/TextSecure.LightTheme"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name="com.soundcloud.android.crop.CropImageActivity" />
<service android:enabled="true" android:name=".service.ApplicationMigrationService"/>
<service android:enabled="true" android:name=".service.KeyCachingService"/>
<service android:enabled="true" android:name=".service.RegistrationService"/>
<service android:enabled="true" android:name=".service.MessageRetrievalService"/>
<service android:name=".service.QuickResponseService"
android:permission="android.permission.SEND_RESPOND_VIA_MESSAGE"
android:exported="true" >
<intent-filter>
<action android:name="android.intent.action.RESPOND_VIA_MESSAGE" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="sms" />
<data android:scheme="smsto" />
<data android:scheme="mms" />
<data android:scheme="mmsto" />
</intent-filter>
</service>
<service android:name=".service.AccountAuthenticatorService" android:exported="true">
<intent-filter>
<action android:name="android.accounts.AccountAuthenticator" />
</intent-filter>
<meta-data android:name="android.accounts.AccountAuthenticator" android:resource="@xml/authenticator" />
</service>
<service android:name=".service.ContactsSyncAdapterService" android:exported="true">
<intent-filter>
<action android:name="android.content.SyncAdapter"/>
</intent-filter>
<meta-data android:name="android.content.SyncAdapter" android:resource="@xml/syncadapter" />
<meta-data android:name="android.provider.CONTACTS_STRUCTURE" android:resource="@xml/contactsformat" />
</service>
<receiver android:name=".gcm.GcmBroadcastReceiver" android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<category android:name="org.thoughtcrime.securesms" />
</intent-filter>
</receiver>
<receiver android:name=".service.SmsListener"
android:permission="android.permission.BROADCAST_SMS"
android:enabled="true"
android:exported="true">
<intent-filter android:priority="1001">
<action android:name="android.provider.Telephony.SMS_RECEIVED"/>
</intent-filter>
<intent-filter>
<action android:name="android.provider.Telephony.SMS_DELIVER"/>
</intent-filter>
</receiver>
<receiver android:name=".service.SmsDeliveryListener"
android:exported="true">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.services.MESSAGE_SENT"/>
</intent-filter>
</receiver>
<receiver android:name=".service.MmsListener"
android:enabled="true"
android:exported="true"
android:permission="android.permission.BROADCAST_WAP_PUSH">
<intent-filter android:priority="1001">
<action android:name="android.provider.Telephony.WAP_PUSH_RECEIVED"/>
<data android:mimeType="application/vnd.wap.mms-message" />
</intent-filter>
<intent-filter>
<action android:name="android.provider.Telephony.WAP_PUSH_DELIVER"/>
<data android:mimeType="application/vnd.wap.mms-message" />
</intent-filter>
</receiver>
<receiver android:name=".notifications.MarkReadReceiver"
android:enabled="true"
android:exported="true">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.CLEAR"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.WearReplyReceiver"
android:enabled="true"
android:exported="true">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.WEAR_REPLY"/>
</intent-filter>
</receiver>
<provider android:name=".providers.PartProvider"
android:grantUriPermissions="true"
android:authorities="org.thoughtcrime.provider.securesms" />
<provider android:name=".providers.MmsBodyProvider"
android:grantUriPermissions="true"
android:authorities="org.thoughtcrime.provider.securesms.mms" />
<receiver android:name=".service.RegistrationNotifier"
android:exported="false">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.REGISTRATION_EVENT" />
</intent-filter>
</receiver>
<receiver android:name=".service.DirectoryRefreshListener">
<intent-filter>
<action android:name="org.whispersystems.whisperpush.DIRECTORY_REFRESH"/>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name=".notifications.MessageNotifier$ReminderReceiver">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.MessageNotifier.REMINDER_ACTION"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.MessageNotifier$DeleteReceiver">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.MessageNotifier.DELETE_REMINDER_ACTION"/>
</intent-filter>
</receiver>
</application>
</manifest>

View File

@@ -1,69 +0,0 @@
Building TextSecure
=====================
Basics
------
TextSecure uses [Gradle](http://gradle.org) to build the project and to maintain
dependencies.
Building TextSecure
-------------------
The following steps should help you (re)build TextSecure from the command line.
1. Checkout the source somewhere on your filesystem with
git clone https://github.com/WhisperSystems/TextSecure.git
2. Make sure you have the [Android SDK](https://developer.android.com/sdk/index.html) installed somewhere on your system.
3. Ensure that the following packages are installed from the Android SDK manager:
* Android SDK Build Tools
* SDK Platform
* Android Support Repository
* Google Repository
4. Create a local.properties file at the root of your source checkout and add an sdk.dir entry to it.
sdk.dir=\<path to your sdk installation\>
5. Execute Gradle:
./gradlew build
Visual assets
----------------------
Source assets tend to be large binary blobs, which are best stored outside of git repositories. We host ours in a [Pixelapse repository](https://www.pixelapse.com/openwhispersystems/projects/signal-android/). Some source files are SVGs that can be auto-colored and sized using a tool like [android-res-utils](https://github.com/sebkur/android-res-utils).
Sample command for generating our audio placeholder image:
```bash
pngs_from_svg.py ic_audio.svg /path/to/TextSecure/res/ 150 "#000" 0.54 _light
pngs_from_svg.py ic_audio.svg /path/to/TextSecure/res/ 150 "#fff" 1.0 _dark
```
Setting up a development environment
------------------------------------
[Android Studio](https://developer.android.com/sdk/installing/studio.html) is the recommended development environment.
1. Install Android Studio.
2. Make sure the "Android Support Repository" is installed in the Android Studio SDK.
3. Make sure the latest "Android SDK build-tools" is installed in the Android Studio SDK.
4. Create a new Android Studio project. from the Quickstart pannel (use File > Close Project to see it), choose "Checkout from Version Control" then "git".
5. Paste the URL for the TextSecure project when prompted (https://github.com/WhisperSystems/TextSecure.git).
6. Android studio should detect the presence of a project file and ask you whether to open it. Click "yes".
7. Default config options should be good enough.
8. Project initialisation and build should proceed.
Contributing code
-----------------
Code contributions should be sent via github as pull requests, from feature branches [as explained here](https://help.github.com/articles/using-pull-requests).
Mailing list
------------
Development discussion happens on the whispersystems mailing list.
[To join](https://lists.riseup.net/www/info/whispersystems)
Send emails to whispersystems@lists.riseup.net

89
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,89 @@
# Contributing to Signal Android
Thank you for supporting Signal and looking for ways to help. Please note that some conventions here might be a bit different than what you are used to, even if you have contributed to other open source projects before. Reading this document will help you save time and work effectively with the developers and other contributors.
## Development Ideology
Truths which we believe to be self-evident:
1. **The answer is not more options.** If you feel compelled to add a preference that's exposed to the user, it's very possible you've made a wrong turn somewhere.
1. **The user doesn't know what a key is.** We need to minimize the points at which a user is exposed to this sort of terminology as extremely as possible.
1. **There are no power users.** The idea that some users "understand" concepts better than others has proven to be, for the most part, false. If anything, "power users" are more dangerous than the rest, and we should avoid exposing dangerous functionality to them.
1. **If it's "like PGP," it's wrong.** PGP is our guide for what not to do.
1. **It's an asynchronous world.** Be wary of anything that is anti-asynchronous: ACKs, protocol confirmations, or any protocol-level "advisory" message.
1. **There is no such thing as time.** Protocol ideas that require synchronized clocks are doomed to failure.
## Translations
Thanks to a dedicated community of volunteer translators, Signal is now available in more than one hundred languages. We use Transifex to manage our translation efforts, not GitHub. Any suggestions, corrections, or new translations should be submitted to the [Signal localization project for Android](https://www.transifex.com/signalapp/signal-android/).
## Issues
### Useful bug reports
1. Please search both open and closed issues to make sure your bug report is not a duplicate.
1. Read the [guide to submitting useful bug reports](https://github.com/signalapp/Signal-Android/wiki/Submitting-useful-bug-reports) before posting a bug.
### The issue tracker is for bugs, not feature requests
The GitHub issue tracker is not used for feature requests, but new ideas can be submitted and discussed on the [community forum](https://community.signalusers.org/c/feature-requests). The purpose of this issue tracker is to track bugs in the Android client. Bug reports should only be submitted for existing functionality that does not work as intended. Comments that are relevant and concise will help the developers solve issues more quickly.
### Send support questions to support
You can reach support by sending an email to support@signal.org or by visiting the [Signal Support Center](https://support.signal.org/) where you can also search for existing troubleshooting articles and find answers to frequently asked questions. Please do not post support questions on the GitHub issue tracker.
### GitHub is not a generic discussion forum
Conversations about open bug reports belong here. However, all other discussions should take place on the [community forum](https://community.signalusers.org). You can use the community forum to discuss anything that is related to Signal or to hang out with your fellow users in the "Off Topic" category.
### Don't bump issues
Every time someone comments on an issue, GitHub sends an email to [hundreds of people](https://github.com/signalapp/Signal-Android/watchers). Bumping issues with a "+1" (or asking for updates) generates a lot of unnecessary email notifications and does not help anyone solve the issue any faster. Please be respectful of everyone's time and only comment when you have new information to add.
### Open issues
#### If it's open, it's tracked
The developers read every issue, but high-priority bugs or features can take precedence over others. Signal is an open source project, and everyone is encouraged to play an active role in diagnosing and fixing open issues.
### Closed issues
#### "My issue was closed without giving a reason!"
Although we do our best, writing detailed explanations for every issue can be time consuming, and the topic also might have been covered previously in other related issues.
## Pull requests
### Smaller is better
Big changes are significantly less likely to be accepted. Large features often require protocol modifications and necessitate a staged rollout process that is coordinated across millions of users on multiple platforms (Android, iOS, and Desktop).
Try not to take on too much at once. As a first-time contributor, we recommend starting with small and simple PRs in order to become familiar with the codebase. Most of the work should go into discovering which three lines need to change rather than writing the code.
### Sign the Contributor License Agreement (CLA)
You will need to [sign our CLA](https://signal.org/cla/) before your pull request can be merged.
### Follow the Code Style Guidelines
Ensure that your code adheres to the [Code Style Guidelines](https://github.com/signalapp/Signal-Android/wiki/Code-Style-Guidelines) before submitting a pull request.
### Submit finished and well-tested pull requests
Please do not submit pull requests that are still a work in progress. Pull requests should be thoroughly tested and ready to merge before they are submitted.
### Merging can sometimes take a while
If your pull request follows all of the advice above but still has not been merged, this usually means that the developers haven't had time to review it yet. We understand that this might feel frustrating, and we apologize. The Signal team is still small, but [we are hiring](https://signal.org/workworkwork/).
## How can I contribute?
There are several other ways to get involved:
* Help new users learn about Signal.
* Redirect support questions to support@signal.org and the [Signal Support Center](https://support.signal.org/).
* Redirect non-bug discussions to the [community forum](https://community.signalusers.org).
* Improve documentation in the [wiki](https://github.com/signalapp/Signal-Android/wiki).
* Join the community of volunteer translators on Transifex:
* [Android](https://www.transifex.com/signalapp/signal-android/)
* [iOS](https://www.transifex.com/signalapp/signal-ios/)
* [Desktop](https://www.transifex.com/signalapp/signal-desktop/)
* Find and mark duplicate issues.
* Try to reproduce issues and help with troubleshooting.
* Discover solutions to open issues and post any relevant findings.
* Test other people's pull requests.
* [Donate to Signal.](https://signal.org/donate/)
* Share Signal with your friends and family.
Signal is made for you. Thank you for your feedback and support.

View File

@@ -1,67 +1,51 @@
# TextSecure [![Build Status](https://travis-ci.org/WhisperSystems/TextSecure.svg?branch=master)](https://travis-ci.org/WhisperSystems/TextSecure)
# Signal Android
TextSecure is a messaging app for simple private communication with friends.
Signal is a messaging app for simple private communication with friends.
TextSecure uses your phone's data connection (WiFi/3G/4G) to communicate securely, optionally supports plain SMS/MMS to function as a unified messenger, and can also encrypt the stored messages on your phone.
Signal uses your phone's data connection (WiFi/3G/4G) to communicate securely, optionally supports plain SMS/MMS to function as a unified messenger, and can also encrypt the stored messages on your phone.
Currently available on the Play store.
*[![Play Store Badge](https://developer.android.com/images/brand/en_app_rgb_wo_60.png)](https://play.google.com/store/apps/details?id=org.thoughtcrime.securesms)*
<a href='https://play.google.com/store/apps/details?id=org.thoughtcrime.securesms&pcampaignid=MKT-Other-global-all-co-prtnr-py-PartBadge-Mar2515-1'><img alt='Get it on Google Play' src='https://play.google.com/intl/en_us/badges/images/generic/en_badge_web_generic.png' height='80px'/></a>
## Contributing Bug reports
We use GitHub for bug tracking. Please search the existing issues for your bug and create a new one if the issue is not yet tracked!
https://github.com/WhisperSystems/TextSecure/issues
https://github.com/signalapp/Signal-Android/issues
## Joining the Beta
Want to live life on the bleeding edge and help out with testing?
You can subscribe to TextSecure Beta releases in two steps:
You can subscribe to Signal Android Beta releases here:
https://play.google.com/apps/testing/org.thoughtcrime.securesms
1. Join the [TextSecure Beta Google+ Community](https://plus.google.com/communities/114424213916773497091).
1. After you've joined the community, [subscribe to the beta](https://play.google.com/apps/testing/org.thoughtcrime.securesms).
If you're interested in a life of peace and tranquility, stick with the standard releases.
## Contributing Translations
Interested in helping to translate TextSecure? Contribute here:
Interested in helping to translate Signal? Contribute here:
https://www.transifex.com/projects/p/textsecure-official/
https://www.transifex.com/projects/p/signal-android/
## Contributing Code
Instructions on how to setup your development environment and build TextSecure can be found in [BUILDING.md](https://github.com/WhisperSystems/TextSecure/blob/master/BUILDING.md).
If you're new to the TextSecure codebase, we recommend going through our issues and picking out a simple bug to fix (check the "easy" label in our issues) in order to get yourself familiar.
If you're new to the Signal codebase, we recommend going through our issues and picking out a simple bug to fix (check the "easy" label in our issues) in order to get yourself familiar. Also please have a look at the [CONTRIBUTING.md](https://github.com/signalapp/Signal-Android/blob/master/CONTRIBUTING.md), that might answer some of your questions.
For larger changes and feature ideas, we ask that you propose it on the mailing list for a high-level discussion before implementation.
This repository is set up with [BitHub](https://whispersystems.org/blog/bithub/), so you can make money for committing to TextSecure. The current BitHub price for an accepted pull request is:
[![Current BitHub Price](https://bithub.herokuapp.com/v1/status/payment/commit/)](https://whispersystems.org/blog/bithub/)
For larger changes and feature ideas, we ask that you propose it on the [unofficial Community Forum](https://community.signalusers.org) for a high-level discussion with the wider community before implementation.
## Contributing Ideas
Have something you want to say about Open Whisper Systems projects or want to be part of the conversation? Get involved in the mailing list!
whispersystems@lists.riseup.net
https://lists.riseup.net/www/info/whispersystems
## Contributing Funds
[![Donate](https://www.coinbase.com/assets/buttons/donation_large-36ee936185fdf9a88e3a28cc685fb9b7.png)](https://coinbase.com/checkouts/d29fd4c37ca442393e32fdcb95304701)
You can add funds to BitHub to directly help further development efforts.
Have something you want to say about Open Whisper Systems projects or want to be part of the conversation? Get involved in the [community forum](https://community.signalusers.org).
Help
====
## Support
For troubleshooting and questions, please visit our support center!
http://support.whispersystems.org/
https://support.signal.org/
## Documentation
Looking for documentation? Check out the wiki!
https://github.com/WhisperSystems/TextSecure/wiki
https://github.com/signalapp/Signal-Android/wiki
# Legal things
## Cryptography Notice
@@ -75,8 +59,8 @@ The form and manner of this distribution makes it eligible for export under the
## License
Copyright 2011 Whisper Systems
Copyright 2013-2014 Open Whisper Systems
Copyright 2013-2020 Signal
Licensed under the GPLv3: http://www.gnu.org/licenses/gpl-3.0.html
Google Play and the Google Play logo are trademarks of Google Inc.

10
app/.tx/config Normal file
View File

@@ -0,0 +1,10 @@
[main]
host = https://www.transifex.com
lang_map = da_DK:da-rDK,fil:tl,he:iw,id:in,kn_IN:kn-rIN,pa_PK:pa-rPK,pt_BR:pt-rBR,pt_PT:pt,qu_EC:qu-rEC,sv_SE:sv-rSE,zh_CN:zh-rCN,zh_HK:zh-rHK,zh_TW:zh-rTW
[signal-android.master]
file_filter = src/main/res/values-<lang>/strings.xml
source_file = src/main/res/values/strings.xml
source_lang = en
type = ANDROID

539
app/build.gradle Normal file
View File

@@ -0,0 +1,539 @@
import org.signal.signing.ApkSignerUtil
import java.security.MessageDigest
buildscript {
repositories {
google()
maven {
url "https://repo1.maven.org/maven2"
}
jcenter {
content {
includeVersion 'org.jetbrains.trove4j', 'trove4j', '20160824'
includeGroupByRegex "com\\.archinamon.*"
}
}
}
dependencies {
classpath 'com.android.tools.build:gradle:4.0.2'
classpath 'androidx.navigation:navigation-safe-args-gradle-plugin:2.1.0'
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.10'
classpath 'com.archinamon:android-gradle-aspectj:4.2.0'
}
}
apply plugin: 'com.android.application'
apply plugin: 'com.google.protobuf'
apply plugin: 'androidx.navigation.safeargs'
apply plugin: 'witness'
apply plugin: 'com.archinamon.aspectj-ext'
apply from: 'translations.gradle'
apply from: 'witness-verifications.gradle'
if (getGradle().getStartParameter().getTaskRequests().toString().contains("Internal")) {
aspectj {
includeJar 'sqlcipher'
includeAspectsFromJar 'Signal-Android'
java = JavaVersion.VERSION_1_8
}
} else if (getGradle().getStartParameter().getTaskRequests().toString().contains("Test")) {
aspectj {
compileTests = false
}
}
repositories {
maven {
url "https://raw.github.com/signalapp/maven/master/photoview/releases/"
content {
includeGroupByRegex "com\\.github\\.chrisbanes.*"
}
}
maven {
url "https://raw.github.com/signalapp/maven/master/shortcutbadger/releases/"
content {
includeGroupByRegex "me\\.leolin.*"
}
}
maven {
url "https://raw.github.com/signalapp/maven/master/circular-progress-button/releases/"
content {
includeGroupByRegex "com\\.github\\.dmytrodanylyk\\.circular-progress-button\\.*"
}
}
maven {
url "https://raw.github.com/signalapp/maven/master/sqlcipher/release/"
content {
includeGroupByRegex "org\\.signal.*"
}
}
maven { // textdrawable
url 'https://dl.bintray.com/amulyakhare/maven'
content {
includeGroupByRegex "com\\.amulyakhare.*"
}
}
google()
mavenCentral()
jcenter()
mavenLocal()
}
protobuf {
protoc {
artifact = 'com.google.protobuf:protoc:3.10.0'
}
generateProtoTasks {
all().each { task ->
task.builtins {
java {
option "lite"
}
}
}
}
}
def canonicalVersionCode = 744
def canonicalVersionName = "4.78.3"
def postFixSize = 10
def abiPostFix = ['universal' : 0,
'armeabi-v7a' : 1,
'arm64-v8a' : 2,
'x86' : 3,
'x86_64' : 4]
def keystores = [ 'debug' : loadKeystoreProperties('keystore.debug.properties') ]
android {
flavorDimensions 'distribution', 'environment'
compileSdkVersion 30
buildToolsVersion '30.0.2'
useLibrary 'org.apache.http.legacy'
dexOptions {
javaMaxHeapSize "4g"
}
signingConfigs {
if (keystores.debug != null) {
debug {
storeFile file("${project.rootDir}/${keystores.debug.storeFile}")
storePassword keystores.debug.storePassword
keyAlias keystores.debug.keyAlias
keyPassword keystores.debug.keyPassword
}
}
}
defaultConfig {
versionCode canonicalVersionCode * postFixSize
versionName canonicalVersionName
minSdkVersion 19
targetSdkVersion 30
multiDexEnabled true
vectorDrawables.useSupportLibrary = true
project.ext.set("archivesBaseName", "Signal");
buildConfigField "long", "BUILD_TIMESTAMP", getLastCommitTimestamp() + "L"
buildConfigField "String", "SIGNAL_URL", "\"https://textsecure-service.whispersystems.org\""
buildConfigField "String", "STORAGE_URL", "\"https://storage.signal.org\""
buildConfigField "String", "SIGNAL_CDN_URL", "\"https://cdn.signal.org\""
buildConfigField "String", "SIGNAL_CDN2_URL", "\"https://cdn2.signal.org\""
buildConfigField "String", "SIGNAL_CONTACT_DISCOVERY_URL", "\"https://api.directory.signal.org\""
buildConfigField "String", "SIGNAL_SERVICE_STATUS_URL", "\"uptime.signal.org\""
buildConfigField "String", "SIGNAL_KEY_BACKUP_URL", "\"https://api.backup.signal.org\""
buildConfigField "String", "SIGNAL_SFU_URL", "\"https://sfu.voip.signal.org\""
buildConfigField "String", "CONTENT_PROXY_HOST", "\"contentproxy.signal.org\""
buildConfigField "int", "CONTENT_PROXY_PORT", "443"
buildConfigField "String", "SIGNAL_AGENT", "\"OWA\""
buildConfigField "String", "CDS_MRENCLAVE", "\"c98e00a4e3ff977a56afefe7362a27e4961e4f19e211febfbb19b897e6b80b15\""
buildConfigField "KbsEnclave", "KBS_ENCLAVE", "new KbsEnclave(\"fe7c1bfae98f9b073d220366ea31163ee82f6d04bead774f71ca8e5c40847bfe\"," +
"\"fe7c1bfae98f9b073d220366ea31163ee82f6d04bead774f71ca8e5c40847bfe\", " +
"\"a3baab19ef6ce6f34ab9ebb25ba722725ae44a8872dc0ff08ad6d83a9489de87\")";
buildConfigField "KbsEnclave[]", "KBS_FALLBACKS", "new KbsEnclave[0]"
buildConfigField "String", "UNIDENTIFIED_SENDER_TRUST_ROOT", "\"BXu6QIKVz5MA8gstzfOgRQGqyLqOwNKHL6INkv3IHWMF\""
buildConfigField "String", "ZKGROUP_SERVER_PUBLIC_PARAMS", "\"AMhf5ywVwITZMsff/eCyudZx9JDmkkkbV6PInzG4p8x3VqVJSFiMvnvlEKWuRob/1eaIetR31IYeAbm0NdOuHH8Qi+Rexi1wLlpzIo1gstHWBfZzy1+qHRV5A4TqPp15YzBPm0WSggW6PbSn+F4lf57VCnHF7p8SvzAA2ZZJPYJURt8X7bbg+H3i+PEjH9DXItNEqs2sNcug37xZQDLm7X0=\""
buildConfigField "String[]", "LANGUAGES", "new String[]{\"" + autoResConfig().collect { s -> s.replace('-r', '_') }.join('", "') + '"}'
buildConfigField "int", "CANONICAL_VERSION_CODE", "$canonicalVersionCode"
buildConfigField "int", "TRACE_EVENT_MAX", "2000"
ndk {
abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
}
resConfigs autoResConfig()
splits {
abi {
enable true
reset()
include 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
universalApk true
}
}
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
packagingOptions {
exclude 'LICENSE.txt'
exclude 'LICENSE'
exclude 'NOTICE'
exclude 'asm-license.txt'
exclude 'META-INF/LICENSE'
exclude 'META-INF/NOTICE'
exclude 'META-INF/proguard/androidx-annotations.pro'
}
aaptOptions {
ignoreAssetsPattern '!contours.tfl:!LMprec_600.emd:!blazeface.tfl'
}
buildTypes {
debug {
if (keystores['debug'] != null) {
signingConfig signingConfigs.debug
}
isDefault true
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'),
'proguard/proguard-firebase-messaging.pro',
'proguard/proguard-google-play-services.pro',
'proguard/proguard-jackson.pro',
'proguard/proguard-sqlite.pro',
'proguard/proguard-appcompat-v7.pro',
'proguard/proguard-square-okhttp.pro',
'proguard/proguard-square-okio.pro',
'proguard/proguard-spongycastle.pro',
'proguard/proguard-rounded-image-view.pro',
'proguard/proguard-glide.pro',
'proguard/proguard-shortcutbadger.pro',
'proguard/proguard-retrofit.pro',
'proguard/proguard-webrtc.pro',
'proguard/proguard-klinker.pro',
'proguard/proguard-retrolambda.pro',
'proguard/proguard-okhttp.pro',
'proguard/proguard-ez-vcard.pro',
'proguard/proguard.cfg'
testProguardFiles 'proguard/proguard-automation.pro',
'proguard/proguard.cfg'
}
flipper {
initWith debug
isDefault false
minifyEnabled false
}
release {
minifyEnabled true
proguardFiles = buildTypes.debug.proguardFiles
}
}
productFlavors {
play {
dimension 'distribution'
isDefault true
ext.websiteUpdateUrl = "null"
buildConfigField "boolean", "PLAY_STORE_DISABLED", "false"
buildConfigField "String", "NOPLAY_UPDATE_URL", "$ext.websiteUpdateUrl"
}
website {
dimension 'distribution'
ext.websiteUpdateUrl = "https://updates.signal.org/android"
buildConfigField "boolean", "PLAY_STORE_DISABLED", "true"
buildConfigField "String", "NOPLAY_UPDATE_URL", "\"$ext.websiteUpdateUrl\""
}
internal {
dimension 'distribution'
ext.websiteUpdateUrl = "null"
buildConfigField "boolean", "PLAY_STORE_DISABLED", "false"
buildConfigField "String", "NOPLAY_UPDATE_URL", "$ext.websiteUpdateUrl"
buildConfigField "int", "TRACE_EVENT_MAX", "30_000"
}
prod {
dimension 'environment'
isDefault true
}
staging {
dimension 'environment'
applicationIdSuffix ".staging"
buildConfigField "String", "SIGNAL_URL", "\"https://textsecure-service-staging.whispersystems.org\""
buildConfigField "String", "STORAGE_URL", "\"https://storage-staging.signal.org\""
buildConfigField "String", "SIGNAL_CDN_URL", "\"https://cdn-staging.signal.org\""
buildConfigField "String", "SIGNAL_CDN2_URL", "\"https://cdn2-staging.signal.org\""
buildConfigField "String", "SIGNAL_CONTACT_DISCOVERY_URL", "\"https://api-staging.directory.signal.org\""
buildConfigField "String", "SIGNAL_KEY_BACKUP_URL", "\"https://api-staging.backup.signal.org\""
buildConfigField "String", "CDS_MRENCLAVE", "\"c98e00a4e3ff977a56afefe7362a27e4961e4f19e211febfbb19b897e6b80b15\""
buildConfigField "KbsEnclave", "KBS_ENCLAVE", "new KbsEnclave(\"823a3b2c037ff0cbe305cc48928cfcc97c9ed4a8ca6d49af6f7d6981fb60a4e9\", " +
"\"038c40bbbacdc873caa81ac793bb75afde6dfe436a99ab1f15e3f0cbb7434ced\", " +
"\"a3baab19ef6ce6f34ab9ebb25ba722725ae44a8872dc0ff08ad6d83a9489de87\")"
buildConfigField "KbsEnclave[]", "KBS_FALLBACKS", "new KbsEnclave[0]"
buildConfigField "String", "UNIDENTIFIED_SENDER_TRUST_ROOT", "\"BbqY1DzohE4NUZoVF+L18oUPrK3kILllLEJh2UnPSsEx\""
buildConfigField "String", "ZKGROUP_SERVER_PUBLIC_PARAMS", "\"ABSY21VckQcbSXVNCGRYJcfWHiAMZmpTtTELcDmxgdFbtp/bWsSxZdMKzfCp8rvIs8ocCU3B37fT3r4Mi5qAemeGeR2X+/YmOGR5ofui7tD5mDQfstAI9i+4WpMtIe8KC3wU5w3Inq3uNWVmoGtpKndsNfwJrCg0Hd9zmObhypUnSkfYn2ooMOOnBpfdanRtrvetZUayDMSC5iSRcXKpdls=\""
}
}
android.applicationVariants.all { variant ->
variant.outputs.each { output ->
output.outputFileName = output.outputFileName.replace(".apk", "-${variant.versionName}.apk")
def abiName = output.getFilter("ABI") ?: 'universal'
def postFix = abiPostFix.get(abiName, 0)
if (postFix >= postFixSize) throw new AssertionError("postFix is too large")
output.versionCodeOverride = canonicalVersionCode * postFixSize + postFix
}
}
lintOptions {
abortOnError true
baseline file("lint-baseline.xml")
disable "LintError"
}
testOptions {
unitTests {
includeAndroidResources = true
}
}
}
dependencies {
lintChecks project(':lintchecks')
implementation ('androidx.appcompat:appcompat:1.2.0') {
force = true
}
implementation 'androidx.recyclerview:recyclerview:1.1.0'
implementation 'com.google.android.material:material:1.2.1'
implementation 'androidx.legacy:legacy-support-v13:1.0.0'
implementation 'androidx.cardview:cardview:1.0.0'
implementation 'androidx.preference:preference:1.0.0'
implementation 'androidx.legacy:legacy-preference-v14:1.0.0'
implementation 'androidx.gridlayout:gridlayout:1.0.0'
implementation 'androidx.exifinterface:exifinterface:1.0.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation 'androidx.multidex:multidex:2.0.1'
implementation 'androidx.navigation:navigation-fragment:2.1.0'
implementation 'androidx.navigation:navigation-ui:2.1.0'
implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0'
implementation 'androidx.lifecycle:lifecycle-viewmodel-savedstate:1.0.0-alpha05'
implementation 'androidx.lifecycle:lifecycle-common-java8:2.1.0'
implementation "androidx.camera:camera-core:1.0.0-beta11"
implementation "androidx.camera:camera-camera2:1.0.0-beta11"
implementation "androidx.camera:camera-lifecycle:1.0.0-beta11"
implementation "androidx.camera:camera-view:1.0.0-alpha18"
implementation "androidx.concurrent:concurrent-futures:1.0.0"
implementation "androidx.autofill:autofill:1.0.0"
implementation "androidx.paging:paging-common:2.1.2"
implementation "androidx.paging:paging-runtime:2.1.2"
implementation 'com.google.firebase:firebase-ml-vision:24.0.3'
implementation 'com.google.firebase:firebase-ml-vision-face-model:20.0.1'
implementation ('com.google.firebase:firebase-messaging:20.2.0') {
exclude group: 'com.google.firebase', module: 'firebase-core'
exclude group: 'com.google.firebase', module: 'firebase-analytics'
exclude group: 'com.google.firebase', module: 'firebase-measurement-connector'
}
implementation 'com.google.android.gms:play-services-maps:16.1.0'
implementation 'com.google.android.gms:play-services-auth:16.0.1'
implementation 'com.google.android.exoplayer:exoplayer-core:2.9.1'
implementation 'com.google.android.exoplayer:exoplayer-ui:2.9.1'
implementation 'com.google.android.exoplayer:extension-mediasession:2.9.1'
implementation 'org.conscrypt:conscrypt-android:2.0.0'
implementation 'org.signal:aesgcmprovider:0.0.3'
implementation project(':libsignal-service')
implementation 'org.signal:zkgroup-android:0.7.0'
implementation 'org.whispersystems:signal-client-android:0.1.3'
implementation 'com.google.protobuf:protobuf-javalite:3.10.0'
implementation 'org.signal:argon2:13.1@aar'
implementation 'org.signal:ringrtc-android:2.8.3'
implementation "me.leolin:ShortcutBadger:1.1.16"
implementation 'se.emilsjolander:stickylistheaders:2.7.0'
implementation 'com.jpardogo.materialtabstrip:library:1.0.9'
implementation 'org.apache.httpcomponents:httpclient-android:4.3.5'
implementation 'com.github.chrisbanes:PhotoView:2.1.3'
implementation 'com.github.bumptech.glide:glide:4.11.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.11.0'
annotationProcessor 'androidx.annotation:annotation:1.1.0'
implementation 'com.makeramen:roundedimageview:2.1.0'
implementation 'com.pnikosis:materialish-progress:1.5'
implementation 'org.greenrobot:eventbus:3.0.0'
implementation 'pl.tajchert:waitingdots:0.1.0'
implementation 'com.melnykov:floatingactionbutton:1.3.0'
implementation 'com.google.zxing:android-integration:3.1.0'
implementation 'mobi.upod:time-duration-picker:1.1.3'
implementation 'com.amulyakhare:com.amulyakhare.textdrawable:1.0.1'
implementation 'com.google.zxing:core:3.2.1'
implementation ('com.davemorrissey.labs:subsampling-scale-image-view:3.6.0') {
exclude group: 'com.android.support', module: 'support-annotations'
}
implementation ('cn.carbswang.android:NumberPickerView:1.0.9') {
exclude group: 'com.android.support', module: 'appcompat-v7'
}
implementation ('com.tomergoldst.android:tooltips:1.0.6') {
exclude group: 'com.android.support', module: 'appcompat-v7'
}
implementation ('com.klinkerapps:android-smsmms:4.0.1') {
exclude group: 'com.squareup.okhttp', module: 'okhttp'
exclude group: 'com.squareup.okhttp', module: 'okhttp-urlconnection'
}
implementation 'com.annimon:stream:1.1.8'
implementation ('com.takisoft.fix:colorpicker:0.9.1') {
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'com.android.support', module: 'recyclerview-v7'
}
implementation 'com.airbnb.android:lottie:3.0.7'
implementation 'com.codewaves.stickyheadergrid:stickyheadergrid:0.9.4'
implementation 'com.github.dmytrodanylyk.circular-progress-button:library:1.1.3-S2'
implementation 'org.signal:android-database-sqlcipher:3.5.9-S3'
implementation ('com.googlecode.ez-vcard:ez-vcard:0.9.11') {
exclude group: 'com.fasterxml.jackson.core'
exclude group: 'org.freemarker'
}
implementation 'dnsjava:dnsjava:2.1.9'
flipperImplementation 'com.facebook.flipper:flipper:0.32.2'
flipperImplementation 'com.facebook.soloader:soloader:0.8.2'
testImplementation 'junit:junit:4.12'
testImplementation 'org.assertj:assertj-core:3.11.1'
testImplementation 'org.mockito:mockito-core:2.8.9'
testImplementation 'org.powermock:powermock-api-mockito2:1.7.4'
testImplementation 'org.powermock:powermock-module-junit4:1.7.4'
testImplementation 'org.powermock:powermock-module-junit4-rule:1.7.4'
testImplementation 'org.powermock:powermock-classloading-xstream:1.7.4'
testImplementation 'androidx.test:core:1.2.0'
testImplementation ('org.robolectric:robolectric:4.4') {
exclude group: 'com.google.protobuf', module: 'protobuf-java'
}
testImplementation 'org.robolectric:shadows-multidex:4.4'
testImplementation 'org.hamcrest:hamcrest:2.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
dependencyVerification {
configuration = '(play|website)(Prod|Staging)(Debug|Release)RuntimeClasspath'
}
def assembleWebsiteDescriptor = { variant, file ->
if (file.exists()) {
MessageDigest md = MessageDigest.getInstance("SHA-256");
file.eachByte 4096, {bytes, size ->
md.update(bytes, 0, size);
}
String digest = md.digest().collect {String.format "%02x", it}.join();
String url = variant.productFlavors.get(0).ext.websiteUpdateUrl
String apkName = file.getName()
String descriptor = "{" +
"\"versionCode\" : ${canonicalVersionCode * postFixSize + abiPostFix['universal']}," +
"\"versionName\" : \"$canonicalVersionName\"," +
"\"sha256sum\" : \"$digest\"," +
"\"url\" : \"$url/$apkName\"" +
"}"
File descriptorFile = new File(file.getParent(), apkName.replace(".apk", ".json"))
descriptorFile.write(descriptor)
}
}
def signProductionRelease = { variant ->
variant.outputs.collect { output ->
String apkName = output.outputFile.name
File inputFile = new File(output.outputFile.path)
File outputFile = new File(output.outputFile.parent, apkName.replace('-unsigned', ''))
new ApkSignerUtil('sun.security.pkcs11.SunPKCS11',
'pkcs11.config',
'PKCS11',
'file:pkcs11.password').calculateSignature(inputFile.getAbsolutePath(),
outputFile.getAbsolutePath())
inputFile.delete()
outputFile
}
}
task signProductionPlayRelease {
doLast {
signProductionRelease(android.applicationVariants.find { (it.name == 'playProdRelease') })
}
}
task signProductionInternalRelease {
doLast {
signProductionRelease(android.applicationVariants.find { (it.name == 'internalProdRelease') })
}
}
task signProductionWebsiteRelease {
doLast {
def variant = android.applicationVariants.find { (it.name == 'websiteProdRelease') }
File signedRelease = signProductionRelease(variant).find { it.name.contains('universal') }
assembleWebsiteDescriptor(variant, signedRelease)
}
}
def getLastCommitTimestamp() {
new ByteArrayOutputStream().withStream { os ->
def result = exec {
executable = 'git'
args = ['log', '-1', '--pretty=format:%ct']
standardOutput = os
}
return os.toString() + "000"
}
}
tasks.withType(Test) {
testLogging {
events "failed"
exceptionFormat "full"
showCauses true
showExceptions true
showStackTraces true
}
}
def loadKeystoreProperties(filename) {
def keystorePropertiesFile = file("${project.rootDir}/${filename}")
if (keystorePropertiesFile.exists()) {
def keystoreProperties = new Properties()
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
return keystoreProperties;
} else {
return null;
}
}

11
app/jni/Android.mk Normal file
View File

@@ -0,0 +1,11 @@
JNI_DIR := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := native-utils
LOCAL_C_INCLUDES := $(JNI_DIR)/utils/
LOCAL_CFLAGS += -Wall
LOCAL_SRC_FILES := $(JNI_DIR)/utils/org_thoughtcrime_securesms_util_FileUtils.cpp
include $(BUILD_SHARED_LIBRARY)

6
app/jni/Application.mk Normal file
View File

@@ -0,0 +1,6 @@
# Built with NDK 19.2.5345600
APP_ABI := armeabi-v7a x86 arm64-v8a x86_64
APP_PLATFORM := android-19
APP_STL := c++_static
APP_CPPFLAGS += -fexceptions
APP_OPTIM := debug

View File

@@ -0,0 +1,45 @@
#include "org_thoughtcrime_securesms_util_FileUtils.h"
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <linux/memfd.h>
#include <syscall.h>
jint JNICALL Java_org_thoughtcrime_securesms_util_FileUtils_getFileDescriptorOwner
(JNIEnv *env, jclass clazz, jobject fileDescriptor)
{
jclass fdClass = env->GetObjectClass(fileDescriptor);
if (fdClass == NULL) {
return -1;
}
jfieldID fdFieldId = env->GetFieldID(fdClass, "descriptor", "I");
if (fdFieldId == NULL) {
return -1;
}
int fd = env->GetIntField(fileDescriptor, fdFieldId);
struct stat stat_struct;
if (fstat(fd, &stat_struct) != 0) {
return -1;
}
return stat_struct.st_uid;
}
JNIEXPORT jint JNICALL Java_org_thoughtcrime_securesms_util_FileUtils_createMemoryFileDescriptor
(JNIEnv *env, jclass clazz, jstring jname)
{
const char *name = env->GetStringUTFChars(jname, NULL);
int fd = syscall(SYS_memfd_create, name, MFD_CLOEXEC);
env->ReleaseStringUTFChars(jname, name);
return fd;
}

View File

@@ -0,0 +1,29 @@
/* DO NOT EDIT THIS FILE - it is machine generated */
#include <jni.h>
/* Header for class org_thoughtcrime_securesms_util_FileUtils */
#ifndef _Included_org_thoughtcrime_securesms_util_FileUtils
#define _Included_org_thoughtcrime_securesms_util_FileUtils
#ifdef __cplusplus
extern "C" {
#endif
/*
* Class: org_thoughtcrime_securesms_util_FileUtils
* Method: getFileDescriptorOwner
* Signature: (Ljava/io/FileDescriptor;)I
*/
JNIEXPORT jint JNICALL Java_org_thoughtcrime_securesms_util_FileUtils_getFileDescriptorOwner
(JNIEnv *, jclass, jobject);
/*
* Class: org_thoughtcrime_securesms_util_FileUtils
* Method: createMemoryFileDescriptor
* Signature: (Ljava/lang/String;)I
*/
JNIEXPORT jint JNICALL Java_org_thoughtcrime_securesms_util_FileUtils_createMemoryFileDescriptor
(JNIEnv *, jclass, jstring);
#ifdef __cplusplus
}
#endif
#endif

48
app/lint-baseline.xml Normal file
View File

@@ -0,0 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<issues format="5" by="lint 3.3.2" client="gradle" variant="playRelease" version="3.3.2">
<issue
id="MissingPermission"
message="Call requires permission which may be rejected by user: code should explicitly check to see if permission is available (with `checkPermission`) or explicitly handle a potential `SecurityException`"
errorLine1=" List&lt;SubscriptionInfo> list = subscriptionManager.getActiveSubscriptionInfoList();"
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
<location
file="src/main/java/org/thoughtcrime/securesms/util/dualsim/SubscriptionManagerCompat.java"
line="101"
column="35"/>
</issue>
<issue
id="ResourceType"
message="Expected resource of type styleable"
errorLine1=" drawables.getColor(1, 0xff000000);"
errorLine2=" ~">
<location
file="src/main/java/org/thoughtcrime/securesms/contacts/ContactSelectionListAdapter.java"
line="187"
column="36"/>
</issue>
<issue
id="AppLinkUrlError"
message="Missing URL"
errorLine1=" &lt;intent-filter>"
errorLine2=" ^">
<location
file="AndroidManifest.xml"
line="368"
column="9"/>
</issue>
<issue
id="AppLinkUrlError"
message="Missing URL"
errorLine1=" &lt;intent-filter>"
errorLine2=" ^">
<location
file="AndroidManifest.xml"
line="381"
column="9"/>
</issue>
</issues>

42
app/lint.xml Normal file
View File

@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="UTF-8"?>
<lint>
<!-- Wont pass lint or qa with a STOPSHIP in a comment -->
<issue id="StopShip" severity="fatal" />
<!-- L10N errors -->
<!-- This is a runtime crash so we don't want to ship with this. -->
<issue id="StringFormatMatches" severity="error" />
<!-- L10N warnings -->
<issue id="MissingTranslation" severity="ignore" />
<issue id="MissingQuantity" severity="warning" />
<issue id="MissingDefaultResource" severity="error">
<ignore path="*/res/values-*/strings.xml" /> <!-- Ignore for non-English, excludeNonTranslatables task will remove these -->
</issue>
<issue id="ExtraTranslation" severity="warning" />
<issue id="ImpliedQuantity" severity="warning" />
<issue id="TypographyDashes" severity="error" >
<ignore path="*/res/values-*/strings.xml" /> <!-- Ignore for non-English -->
</issue>
<issue id="CanvasSize" severity="error" />
<issue id="HardcodedText" severity="error" />
<issue id="VectorRaster" severity="error" />
<issue id="ButtonOrder" severity="error" />
<issue id="ExtraTranslation" severity="warning" />
<!-- Custom lints -->
<issue id="LogNotSignal" severity="error" />
<issue id="LogNotAppSignal" severity="error" />
<issue id="LogTagInlined" severity="error" />
<issue id="RestrictedApi" severity="error">
<ignore path="*/org/thoughtcrime/securesms/mediasend/camerax/VideoCapture.java" />
<ignore path="*/org/thoughtcrime/securesms/mediasend/camerax/CameraXModule.java" />
<ignore path="*/org/thoughtcrime/securesms/conversation/*.java" />
<ignore path="*/org/thoughtcrime/securesms/lock/v2/CreateKbsPinViewModel.java" />
<ignore path="*/org/thoughtcrime/securesms/jobs/StickerPackDownloadJob.java" />
</issue>
</lint>

View File

@@ -0,0 +1,13 @@
# https://code.google.com/p/android/issues/detail?id=78377
-keepnames class !android.support.v7.internal.view.menu.**, ** { *; }
-keep public class android.support.v7.widget.** { *; }
-keep public class android.support.v7.internal.widget.** { *; }
-keep public class * extends android.support.v4.view.ActionProvider {
public <init>(android.content.Context);
}
-keepattributes *Annotation*
-keep public class * extends android.support.design.widget.CoordinatorLayout.Behavior { *; }
-keep public class * extends android.support.design.widget.ViewOffsetBehavior { *; }

View File

@@ -9,3 +9,5 @@
-dontwarn org.hamcrest.**
-dontwarn org.mockito.**
-dontwarn com.squareup.**
-dontobfuscate

View File

@@ -0,0 +1 @@
-dontwarn ezvcard.io.html.HCardPage

View File

@@ -0,0 +1 @@
-dontwarn com.google.firebase.analytics.connector.AnalyticsConnector

View File

@@ -0,0 +1,6 @@
-keep public class * implements com.bumptech.glide.module.GlideModule
-keep public class * extends com.bumptech.glide.AppGlideModule
-keep public enum com.bumptech.glide.load.resource.bitmap.ImageHeaderParser$** {
**[] $VALUES;
public *;
}

View File

@@ -0,0 +1,3 @@
-dontwarn android.net.ConnectivityManager
-dontwarn android.net.ConnectivityManager$NetworkCallback
-dontwarn org.webrtc.NetworkMonitorAutoDetect$ConnectivityManagerDelegate

View File

@@ -0,0 +1,3 @@
-dontwarn okio.**
-dontwarn javax.annotation.Nullable
-dontwarn javax.annotation.ParametersAreNonnullByDefault

View File

@@ -0,0 +1,4 @@
-dontwarn retrofit.**
-keep class retrofit.** { *; }
-keepattributes Signature
-keepattributes Exceptions

View File

@@ -0,0 +1,2 @@
-dontwarn java.lang.invoke.*
-dontwarn **$$Lambda$*

View File

@@ -0,0 +1,5 @@
-keep class org.sqlite.** { *; }
-keep class org.sqlite.database.** { *; }
-keep class net.sqlcipher.** { *; }
-dontwarn net.sqlcipher.**

11
app/proguard/proguard.cfg Normal file
View File

@@ -0,0 +1,11 @@
-dontoptimize
-dontobfuscate
-keepattributes SourceFile,LineNumberTable
-keep class org.whispersystems.** { *; }
-keep class org.thoughtcrime.securesms.** { *; }
-keepclassmembers class ** {
public void onEvent*(**);
}
# Protobuf lite
-keep class * extends com.google.protobuf.GeneratedMessageLite { *; }

View File

@@ -0,0 +1,29 @@
{
"data": [
{
"name": "Ottttooooooooo Ocataaaaaaaavius",
"number": "+1 (555) 555-5555",
"label": "Mobile"
},
{
"name": "Victor Von Doom Phd",
"number": "+1 (555) 123-4567",
"label": "Home"
},
{
"name": "Flash Thompson",
"number": "+1 (555) 435-1261",
"label": "Work"
},
{
"name": "Dr. Curtis Connors",
"number": "+1 (555) 992-1567",
"label": "Mobile"
},
{
"name": "Billy Russo",
"number": "+1 (555) 234-1516",
"label": "Mobile"
}
]
}

View File

@@ -0,0 +1,93 @@
package org.thoughtcrime.securesms.lock;
import org.junit.Test;
import org.thoughtcrime.securesms.util.Hex;
import org.whispersystems.signalservice.api.kbs.HashedPin;
import org.whispersystems.signalservice.api.kbs.KbsData;
import org.whispersystems.signalservice.api.kbs.MasterKey;
import java.io.IOException;
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
public final class PinHashing_hashPin_Test {
@Test
public void argon2_hashed_pin_password() throws IOException {
String pin = "password";
byte[] backupId = Hex.fromStringCondensed("000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f");
MasterKey masterKey = new MasterKey(Hex.fromStringCondensed("202122232425262728292a2b2c2d2e2f303132333435363738393a3b3c3d3e3f"));
HashedPin hashedPin = PinHashing.hashPin(pin, () -> backupId);
KbsData kbsData = hashedPin.createNewKbsData(masterKey);
assertArrayEquals(hashedPin.getKbsAccessKey(), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("ab7e8499d21f80a6600b3b9ee349ac6d72c07e3359fe885a934ba7aa844429f8"), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("3f33ce58eb25b40436592a30eae2a8fabab1899095f4e2fba6e2d0dc43b4a2d9cac5a3931748522393951e0e54dec769"), kbsData.getCipherText());
assertEquals(masterKey, kbsData.getMasterKey());
String localPinHash = PinHashing.localPinHash(pin);
assertTrue(PinHashing.verifyLocalPinHash(localPinHash, pin));
}
@Test
public void argon2_hashed_pin_another_password() throws IOException {
String pin = "anotherpassword";
byte[] backupId = Hex.fromStringCondensed("202122232425262728292a2b2c2d2e2f303132333435363738393a3b3c3d3e3f");
MasterKey masterKey = new MasterKey(Hex.fromStringCondensed("88a787415a2ecd79da0d1016a82a27c5c695c9a19b88b0aa1d35683280aa9a67"));
HashedPin hashedPin = PinHashing.hashPin(pin, () -> backupId);
KbsData kbsData = hashedPin.createNewKbsData(masterKey);
assertArrayEquals(hashedPin.getKbsAccessKey(), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("301d9dd1e96f20ce51083f67d3298fd37b97525de8324d5e12ed2d407d3d927b"), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("9d9b05402ea39c17ff1c9298c8a0e86784a352aa02a74943bf8bcf07ec0f4b574a5b786ad0182c8d308d9eb06538b8c9"), kbsData.getCipherText());
assertEquals(masterKey, kbsData.getMasterKey());
String localPinHash = PinHashing.localPinHash(pin);
assertTrue(PinHashing.verifyLocalPinHash(localPinHash, pin));
}
@Test
public void argon2_hashed_pin_password_with_spaces_diacritics_and_non_arabic_numerals() throws IOException {
String pin = " Pass६örd ";
byte[] backupId = Hex.fromStringCondensed("cba811749042b303a6a7efa5ccd160aea5e3ea243c8d2692bd13d515732f51a8");
MasterKey masterKey = new MasterKey(Hex.fromStringCondensed("9571f3fde1e58588ba49bcf82be1b301ca3859a6f59076f79a8f47181ef952bf"));
HashedPin hashedPin = PinHashing.hashPin(pin, () -> backupId);
KbsData kbsData = hashedPin.createNewKbsData(masterKey);
assertArrayEquals(hashedPin.getKbsAccessKey(), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("ab645acdccc1652a48a34b2ac6926340ff35c03034013f68760f20013f028dd8"), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("11c0ba1834db15e47c172f6c987c64bd4cfc69c6047dd67a022afeec0165a10943f204d5b8f37b3cb7bab21c6dfc39c8"), kbsData.getCipherText());
assertEquals(masterKey, kbsData.getMasterKey());
assertEquals("577939bccb2b6638c39222d5a97998a867c5e154e30b82cc120f2dd07a3de987", kbsData.getMasterKey().deriveRegistrationLock());
String localPinHash = PinHashing.localPinHash(pin);
assertTrue(PinHashing.verifyLocalPinHash(localPinHash, pin));
}
@Test
public void argon2_hashed_pin_password_with_just_non_arabic_numerals() throws IOException {
String pin = " ६१८ ";
byte[] backupId = Hex.fromStringCondensed("717dc111a98423a57196512606822fca646c653facd037c10728f14ba0be2ab3");
MasterKey masterKey = new MasterKey(Hex.fromStringCondensed("0432d735b32f66d0e3a70d4f9cc821a8529521a4937d26b987715d8eff4e4c54"));
HashedPin hashedPin = PinHashing.hashPin(pin, () -> backupId);
KbsData kbsData = hashedPin.createNewKbsData(masterKey);
assertArrayEquals(hashedPin.getKbsAccessKey(), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("d2fedabd0d4c17a371491c9722578843a26be3b4923e28d452ab2fc5491e794b"), kbsData.getKbsAccessKey());
assertArrayEquals(Hex.fromStringCondensed("877ef871ef1fc668401c717ef21aa12e8523579fb1ff4474b76f28c2293537c80cc7569996c9e0229bea7f378e3a824e"), kbsData.getCipherText());
assertEquals(masterKey, kbsData.getMasterKey());
assertEquals("23a75cb1df1a87df45cc2ed167c2bdc85ab1220b847c88761b0005cac907fce5", kbsData.getMasterKey().deriveRegistrationLock());
String localPinHash = PinHashing.localPinHash(pin);
assertTrue(PinHashing.verifyLocalPinHash(localPinHash, pin));
}
}

View File

@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="org.thoughtcrime.securesms">
<application
android:name=".FlipperApplicationContext"
tools:replace="android:name">
<activity
android:name="com.facebook.flipper.android.diagnostics.FlipperDiagnosticActivity"
android:exported="true" />
</application>
</manifest>

View File

@@ -0,0 +1,27 @@
package org.thoughtcrime.securesms;
import com.facebook.flipper.android.AndroidFlipperClient;
import com.facebook.flipper.core.FlipperClient;
import com.facebook.flipper.plugins.databases.DatabasesFlipperPlugin;
import com.facebook.flipper.plugins.inspector.DescriptorMapping;
import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin;
import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin;
import com.facebook.soloader.SoLoader;
import org.thoughtcrime.securesms.database.FlipperSqlCipherAdapter;
public class FlipperApplicationContext extends ApplicationContext {
@Override
public void onCreate() {
super.onCreate();
SoLoader.init(this, false);
FlipperClient client = AndroidFlipperClient.getInstance(this);
client.addPlugin(new InspectorFlipperPlugin(this, DescriptorMapping.withDefaults()));
client.addPlugin(new DatabasesFlipperPlugin(new FlipperSqlCipherAdapter(this)));
client.addPlugin(new SharedPreferencesFlipperPlugin(this));
client.start();
}
}

View File

@@ -0,0 +1,257 @@
package org.thoughtcrime.securesms.database;
import android.content.Context;
import android.database.Cursor;
import android.text.TextUtils;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.facebook.flipper.plugins.databases.DatabaseDescriptor;
import com.facebook.flipper.plugins.databases.DatabaseDriver;
import net.sqlcipher.DatabaseUtils;
import net.sqlcipher.database.SQLiteDatabase;
import net.sqlcipher.database.SQLiteStatement;
import org.thoughtcrime.securesms.database.helpers.SQLCipherOpenHelper;
import org.thoughtcrime.securesms.logging.Log;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* A lot of this code is taken from {@link com.facebook.flipper.plugins.databases.impl.SqliteDatabaseDriver}
* and made to work with SqlCipher. Unfortunately I couldn't use it directly, nor subclass it.
*/
public class FlipperSqlCipherAdapter extends DatabaseDriver<FlipperSqlCipherAdapter.Descriptor> {
private static final String TAG = Log.tag(FlipperSqlCipherAdapter.class);
public FlipperSqlCipherAdapter(Context context) {
super(context);
}
@Override
public List<Descriptor> getDatabases() {
try {
Field databaseHelperField = DatabaseFactory.class.getDeclaredField("databaseHelper");
databaseHelperField.setAccessible(true);
SQLCipherOpenHelper sqlCipherOpenHelper = (SQLCipherOpenHelper) databaseHelperField.get(DatabaseFactory.getInstance(getContext()));
return Collections.singletonList(new Descriptor(sqlCipherOpenHelper));
} catch (Exception e) {
Log.i(TAG, "Unable to use reflection to access raw database.", e);
}
return Collections.emptyList();
}
@Override
public List<String> getTableNames(Descriptor descriptor) {
SQLiteDatabase db = descriptor.getReadable();
List<String> tableNames = new ArrayList<>();
try (Cursor cursor = db.rawQuery("SELECT name FROM sqlite_master WHERE type IN (?, ?)", new String[] { "table", "view" })) {
while (cursor != null && cursor.moveToNext()) {
tableNames.add(cursor.getString(0));
}
}
return tableNames;
}
@Override
public DatabaseGetTableDataResponse getTableData(Descriptor descriptor, String table, String order, boolean reverse, int start, int count) {
SQLiteDatabase db = descriptor.getReadable();
long total = DatabaseUtils.queryNumEntries(db, table);
String orderBy = order != null ? order + (reverse ? " DESC" : " ASC") : null;
String limitBy = start + ", " + count;
try (Cursor cursor = db.query(table, null, null, null, null, null, orderBy, limitBy)) {
String[] columnNames = cursor.getColumnNames();
List<List<Object>> rows = cursorToList(cursor);
return new DatabaseGetTableDataResponse(Arrays.asList(columnNames), rows, start, rows.size(), total);
}
}
@Override
public DatabaseGetTableStructureResponse getTableStructure(Descriptor descriptor, String table) {
SQLiteDatabase db = descriptor.getReadable();
Map<String, String> foreignKeyValues = new HashMap<>();
try(Cursor cursor = db.rawQuery("PRAGMA foreign_key_list(" + table + ")", null)) {
while (cursor != null && cursor.moveToNext()) {
String from = cursor.getString(cursor.getColumnIndex("from"));
String to = cursor.getString(cursor.getColumnIndex("to"));
String tableName = cursor.getString(cursor.getColumnIndex("table")) + "(" + to + ")";
foreignKeyValues.put(from, tableName);
}
}
List<String> structureColumns = Arrays.asList("column_name", "data_type", "nullable", "default", "primary_key", "foreign_key");
List<List<Object>> structureValues = new ArrayList<>();
try (Cursor cursor = db.rawQuery("PRAGMA table_info(" + table + ")", null)) {
while (cursor != null && cursor.moveToNext()) {
String columnName = cursor.getString(cursor.getColumnIndex("name"));
String foreignKey = foreignKeyValues.containsKey(columnName) ? foreignKeyValues.get(columnName) : null;
structureValues.add(Arrays.asList(columnName,
cursor.getString(cursor.getColumnIndex("type")),
cursor.getInt(cursor.getColumnIndex("notnull")) == 0,
getObjectFromColumnIndex(cursor, cursor.getColumnIndex("dflt_value")),
cursor.getInt(cursor.getColumnIndex("pk")) == 1,
foreignKey));
}
}
List<String> indexesColumns = Arrays.asList("index_name", "unique", "indexed_column_name");
List<List<Object>> indexesValues = new ArrayList<>();
try (Cursor indexesCursor = db.rawQuery("PRAGMA index_list(" + table + ")", null)) {
List<String> indexedColumnNames = new ArrayList<>();
String indexName = indexesCursor.getString(indexesCursor.getColumnIndex("name"));
try(Cursor indexInfoCursor = db.rawQuery("PRAGMA index_info(" + indexName + ")", null)) {
while (indexInfoCursor.moveToNext()) {
indexedColumnNames.add(indexInfoCursor.getString(indexInfoCursor.getColumnIndex("name")));
}
}
indexesValues.add(Arrays.asList(indexName,
indexesCursor.getInt(indexesCursor.getColumnIndex("unique")) == 1,
TextUtils.join(",", indexedColumnNames)));
}
return new DatabaseGetTableStructureResponse(structureColumns, structureValues, indexesColumns, indexesValues);
}
@Override
public DatabaseGetTableInfoResponse getTableInfo(Descriptor databaseDescriptor, String table) {
SQLiteDatabase db = databaseDescriptor.getReadable();
try (Cursor cursor = db.rawQuery("SELECT sql FROM sqlite_master WHERE name = ?", new String[] { table })) {
cursor.moveToFirst();
return new DatabaseGetTableInfoResponse(cursor.getString(cursor.getColumnIndex("sql")));
}
}
@Override
public DatabaseExecuteSqlResponse executeSQL(Descriptor descriptor, String query) {
SQLiteDatabase db = descriptor.getWritable();
String firstWordUpperCase = getFirstWord(query).toUpperCase();
switch (firstWordUpperCase) {
case "UPDATE":
case "DELETE":
return executeUpdateDelete(db, query);
case "INSERT":
return executeInsert(db, query);
case "SELECT":
case "PRAGMA":
case "EXPLAIN":
return executeSelect(db, query);
default:
return executeRawQuery(db, query);
}
}
private static String getFirstWord(String s) {
s = s.trim();
int firstSpace = s.indexOf(' ');
return firstSpace >= 0 ? s.substring(0, firstSpace) : s;
}
private static DatabaseExecuteSqlResponse executeUpdateDelete(SQLiteDatabase database, String query) {
SQLiteStatement statement = database.compileStatement(query);
int count = statement.executeUpdateDelete();
return DatabaseExecuteSqlResponse.successfulUpdateDelete(count);
}
private static DatabaseExecuteSqlResponse executeInsert(SQLiteDatabase database, String query) {
SQLiteStatement statement = database.compileStatement(query);
long insertedId = statement.executeInsert();
return DatabaseExecuteSqlResponse.successfulInsert(insertedId);
}
private static DatabaseExecuteSqlResponse executeSelect(SQLiteDatabase database, String query) {
try (Cursor cursor = database.rawQuery(query, null)) {
String[] columnNames = cursor.getColumnNames();
List<List<Object>> rows = cursorToList(cursor);
return DatabaseExecuteSqlResponse.successfulSelect(Arrays.asList(columnNames), rows);
}
}
private static DatabaseExecuteSqlResponse executeRawQuery(SQLiteDatabase database, String query) {
database.execSQL(query);
return DatabaseExecuteSqlResponse.successfulRawQuery();
}
private static @NonNull List<List<Object>> cursorToList(Cursor cursor) {
List<List<Object>> rows = new ArrayList<>();
int numColumns = cursor.getColumnCount();
while (cursor.moveToNext()) {
List<Object> values = new ArrayList<>(numColumns);
for (int column = 0; column < numColumns; column++) {
values.add(getObjectFromColumnIndex(cursor, column));
}
rows.add(values);
}
return rows;
}
private static @Nullable Object getObjectFromColumnIndex(Cursor cursor, int column) {
switch (cursor.getType(column)) {
case Cursor.FIELD_TYPE_NULL:
return null;
case Cursor.FIELD_TYPE_INTEGER:
return cursor.getLong(column);
case Cursor.FIELD_TYPE_FLOAT:
return cursor.getDouble(column);
case Cursor.FIELD_TYPE_BLOB:
return cursor.getBlob(column);
case Cursor.FIELD_TYPE_STRING:
default:
return cursor.getString(column);
}
}
static class Descriptor implements DatabaseDescriptor {
private final SQLCipherOpenHelper sqlCipherOpenHelper;
Descriptor(@NonNull SQLCipherOpenHelper sqlCipherOpenHelper) {
this.sqlCipherOpenHelper = sqlCipherOpenHelper;
}
@Override
public String name() {
return sqlCipherOpenHelper.getDatabaseName();
}
public @NonNull SQLiteDatabase getReadable() {
return sqlCipherOpenHelper.getReadableDatabase();
}
public @NonNull SQLiteDatabase getWritable() {
return sqlCipherOpenHelper.getWritableDatabase();
}
}
}

View File

@@ -0,0 +1,103 @@
package org.thoughtcrime.securesms.tracing;
import androidx.annotation.NonNull;
import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Pointcut;
import org.thoughtcrime.securesms.logging.Log;
/**
* Uses AspectJ to augment relevant methods to be traced with the {@link TracerImpl}.
*/
@Aspect
public class TraceAspect {
@Pointcut("within(@org.thoughtcrime.securesms.tracing.Trace *)")
public void withinAnnotatedClass() {}
@Pointcut("execution(!synthetic * *(..)) && withinAnnotatedClass()")
public void methodInsideAnnotatedType() {}
@Pointcut("execution(!synthetic *.new(..)) && withinAnnotatedClass()")
public void constructorInsideAnnotatedType() {}
@Pointcut("execution(@org.thoughtcrime.securesms.tracing.Trace * *(..)) || methodInsideAnnotatedType()")
public void annotatedMethod() {}
@Pointcut("execution(@org.thoughtcrime.securesms.tracing.Trace *.new(..)) || constructorInsideAnnotatedType()")
public void annotatedConstructor() {}
@Pointcut("execution(* *(..)) && within(net.sqlcipher.database.*)")
public void sqlcipher() {}
@Pointcut("execution(* net.sqlcipher.database.SQLiteDatabase.rawQuery(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.query(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.insert(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.insertOrThrow(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.insertWithOnConflict(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.delete(..)) || " +
"execution(* net.sqlcipher.database.SQLiteDatabase.update(..))")
public void sqlcipherQuery() {}
@Around("annotatedMethod() || annotatedConstructor() || (sqlcipher() && !sqlcipherQuery())")
public @NonNull Object profile(@NonNull ProceedingJoinPoint joinPoint) throws Throwable {
String methodName = joinPoint.getSignature().toShortString();
Tracer.getInstance().start(methodName);
Object result = joinPoint.proceed();
Tracer.getInstance().end(methodName);
return result;
}
@Around("sqlcipherQuery()")
public @NonNull Object profileQuery(@NonNull ProceedingJoinPoint joinPoint) throws Throwable {
String table;
String query;
if (joinPoint.getSignature().getName().equals("query")) {
if (joinPoint.getArgs().length == 9) {
table = (String) joinPoint.getArgs()[1];
query = (String) joinPoint.getArgs()[3];
} else if (joinPoint.getArgs().length == 7 || joinPoint.getArgs().length == 8) {
table = (String) joinPoint.getArgs()[0];
query = (String) joinPoint.getArgs()[2];
} else {
table = "N/A";
query = "N/A";
}
} else if (joinPoint.getSignature().getName().equals("rawQuery")) {
table = "";
query = (String) joinPoint.getArgs()[0];
} else if (joinPoint.getSignature().getName().equals("insert")) {
table = (String) joinPoint.getArgs()[0];
query = "";
} else if (joinPoint.getSignature().getName().equals("insertOrThrow")) {
table = (String) joinPoint.getArgs()[0];
query = "";
} else if (joinPoint.getSignature().getName().equals("insertWithOnConflict")) {
table = (String) joinPoint.getArgs()[0];
query = "";
} else if (joinPoint.getSignature().getName().equals("delete")) {
table = (String) joinPoint.getArgs()[0];
query = (String) joinPoint.getArgs()[1];
} else if (joinPoint.getSignature().getName().equals("update")) {
table = (String) joinPoint.getArgs()[0];
query = (String) joinPoint.getArgs()[2];
} else {
table = "N/A";
query = "N/A";
}
query = query == null ? "null" : query;
query = "[" + table + "] " + query;
String methodName = joinPoint.getSignature().toShortString();
Tracer.getInstance().start(methodName, "query", query);
Object result = joinPoint.proceed();
Tracer.getInstance().end(methodName);
return result;
}
}

View File

@@ -0,0 +1,193 @@
package org.thoughtcrime.securesms.tracing;
import android.os.SystemClock;
import androidx.annotation.NonNull;
import com.google.protobuf.ByteString;
import org.thoughtcrime.securesms.BuildConfig;
import org.thoughtcrime.securesms.trace.TraceProtos;
import org.thoughtcrime.securesms.trace.TraceProtos.Trace;
import org.thoughtcrime.securesms.trace.TraceProtos.TracePacket;
import org.thoughtcrime.securesms.trace.TraceProtos.TrackDescriptor;
import org.thoughtcrime.securesms.trace.TraceProtos.TrackEvent;
import org.whispersystems.signalservice.api.util.UuidUtil;
import java.util.Map;
import java.util.Queue;
import java.util.UUID;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentLinkedQueue;
import java.util.concurrent.atomic.AtomicInteger;
/**
* A class to create Perfetto-compatible traces. Currently keeps the entire trace in memory to
* avoid weirdness with synchronizing to disk.
*
* Some general info on how the Perfetto format works:
* - The file format is just a Trace proto (see Trace.proto)
* - The Trace proto is just a series of TracePackets
* - TracePackets can describe:
* - Threads
* - Start of a method
* - End of a method
* - (And a bunch of other stuff that's not relevant to use at this point)
*
* We keep a circular buffer of TracePackets for method calls, and we keep a separate list of
* TracePackets for threads so we don't lose any of those.
*
* Serializing is just a matter of throwing all the TracePackets we have into a proto.
*
* Note: This class aims to be largely-thread-safe, but prioritizes speed and memory efficiency
* above all else. These methods are going to be called very quickly from every thread imaginable,
* and we want to create as little overhead as possible. The idea being that it's ok if we don't,
* for example, keep a perfect circular buffer size if it allows us to reduce overhead. The only
* cost of screwing up would be dropping a trace packet or something, which, while sad, won't affect
* how the app functions.
*/
public final class TracerImpl implements Tracer {
private static final int TRUSTED_SEQUENCE_ID = 1;
private static final byte[] SYNCHRONIZATION_MARKER = UuidUtil.toByteArray(UUID.fromString("82477a76-b28d-42ba-81dc-33326d57a079"));
private final Clock clock;
private final Map<Long, TracePacket> threadPackets;
private final Queue<TracePacket> eventPackets;
private final AtomicInteger eventCount;
TracerImpl() {
this.clock = SystemClock::elapsedRealtimeNanos;
this.threadPackets = new ConcurrentHashMap<>();
this.eventPackets = new ConcurrentLinkedQueue<>();
this.eventCount = new AtomicInteger(0);
}
@Override
public boolean isEnabled() {
return true;
}
@Override
public void start(@NonNull String methodName) {
long time = clock.getTimeNanos();
Thread currentThread = Thread.currentThread();
if (!threadPackets.containsKey(currentThread.getId())) {
threadPackets.put(currentThread.getId(), forThread(currentThread));
}
addPacket(forMethodStart(methodName, time, currentThread.getId()));
}
@Override
public void start(@NonNull String methodName, @NonNull String key, @NonNull String value) {
long time = clock.getTimeNanos();
Thread currentThread = Thread.currentThread();
if (!threadPackets.containsKey(currentThread.getId())) {
threadPackets.put(currentThread.getId(), forThread(currentThread));
}
addPacket(forMethodStart(methodName, time, currentThread.getId(), key, value));
}
@Override
public void end(@NonNull String methodName) {
addPacket(forMethodEnd(methodName, clock.getTimeNanos(), Thread.currentThread().getId()));
}
public @NonNull byte[] serialize() {
Trace.Builder trace = Trace.newBuilder();
for (TracePacket thread : threadPackets.values()) {
trace.addPacket(thread);
}
for (TracePacket event : eventPackets) {
trace.addPacket(event);
}
trace.addPacket(forSynchronization(clock.getTimeNanos()));
return trace.build().toByteArray();
}
/**
* Attempts to add a packet to our list while keeping the size of our circular buffer in-check.
* The tracking of the event count is not perfectly thread-safe, but doing it in a thread-safe
* way would likely involve adding a lock, which we really don't want to do, since it'll add
* unnecessary overhead.
*
* Note that we keep track of the event count separately because
* {@link ConcurrentLinkedQueue#size()} is NOT a constant-time operation.
*/
private void addPacket(@NonNull TracePacket packet) {
eventPackets.add(packet);
int size = eventCount.incrementAndGet();
for (int i = size; i > BuildConfig.TRACE_EVENT_MAX; i--) {
eventPackets.poll();
eventCount.decrementAndGet();
}
}
private static TracePacket forThread(@NonNull Thread thread) {
return TracePacket.newBuilder()
.setTrustedPacketSequenceId(TRUSTED_SEQUENCE_ID)
.setTrackDescriptor(TrackDescriptor.newBuilder()
.setUuid(thread.getId())
.setName(thread.getName()))
.build();
}
private static TracePacket forMethodStart(@NonNull String name, long time, long threadId) {
return TracePacket.newBuilder()
.setTrustedPacketSequenceId(TRUSTED_SEQUENCE_ID)
.setTimestamp(time)
.setTrackEvent(TrackEvent.newBuilder()
.setTrackUuid(threadId)
.setName(name)
.setType(TrackEvent.Type.TYPE_SLICE_BEGIN))
.build();
}
private static TracePacket forMethodStart(@NonNull String name, long time, long threadId, @NonNull String key, @NonNull String value) {
return TracePacket.newBuilder()
.setTrustedPacketSequenceId(TRUSTED_SEQUENCE_ID)
.setTimestamp(time)
.setTrackEvent(TrackEvent.newBuilder()
.setTrackUuid(threadId)
.setName(name)
.setType(TrackEvent.Type.TYPE_SLICE_BEGIN)
.addDebugAnnotations(TraceProtos.DebugAnnotation.newBuilder()
.setName(key)
.setStringValue(value)
.build()))
.build();
}
private static TracePacket forMethodEnd(@NonNull String name, long time, long threadId) {
return TracePacket.newBuilder()
.setTrustedPacketSequenceId(TRUSTED_SEQUENCE_ID)
.setTimestamp(time)
.setTrackEvent(TrackEvent.newBuilder()
.setTrackUuid(threadId)
.setName(name)
.setType(TrackEvent.Type.TYPE_SLICE_END))
.build();
}
private static TracePacket forSynchronization(long time) {
return TracePacket.newBuilder()
.setTrustedPacketSequenceId(TRUSTED_SEQUENCE_ID)
.setTimestamp(time)
.setSynchronizationMarker(ByteString.copyFrom(SYNCHRONIZATION_MARKER))
.build();
}
private interface Clock {
long getTimeNanos();
}
}

View File

@@ -0,0 +1,151 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
syntax = "proto2";
package signal;
option java_package = "org.thoughtcrime.securesms.trace";
option java_outer_classname = "TraceProtos";
/*
* Minimal interface needed to work with Perfetto.
*
* https://cs.android.com/android/platform/superproject/+/master:external/perfetto/protos/perfetto/trace/trace.proto
*/
message Trace {
repeated TracePacket packet = 1;
}
message TracePacket {
optional uint64 timestamp = 8;
optional uint32 timestamp_clock_id = 58;
oneof data {
TrackEvent track_event = 11;
TrackDescriptor track_descriptor = 60;
bytes synchronization_marker = 36;
}
oneof optional_trusted_packet_sequence_id {
uint32 trusted_packet_sequence_id = 10;
}
}
message TrackEvent {
repeated uint64 category_iids = 3;
repeated string categories = 22;
repeated DebugAnnotation debug_annotations = 4;
oneof name_field {
uint64 name_iid = 10;
string name = 23;
}
enum Type {
TYPE_UNSPECIFIED = 0;
TYPE_SLICE_BEGIN = 1;
TYPE_SLICE_END = 2;
TYPE_INSTANT = 3;
TYPE_COUNTER = 4;
}
optional Type type = 9;
optional uint64 track_uuid = 11;
optional int64 counter_value = 30;
oneof timestamp {
int64 timestamp_delta_us = 1;
int64 timestamp_absolute_us = 16;
}
oneof thread_time {
int64 thread_time_delta_us = 2;
int64 thread_time_absolute_us = 17;
}
}
message TrackDescriptor {
optional uint64 uuid = 1;
optional uint64 parent_uuid = 5;
optional string name = 2;
optional ThreadDescriptor thread = 4;
optional CounterDescriptor counter = 8;
}
message ThreadDescriptor {
optional int32 pid = 1;
optional int32 tid = 2;
optional string thread_name = 5;
}
message CounterDescriptor {
enum BuiltinCounterType {
COUNTER_UNSPECIFIED = 0;
COUNTER_THREAD_TIME_NS = 1;
COUNTER_THREAD_INSTRUCTION_COUNT = 2;
}
enum Unit {
UNIT_UNSPECIFIED = 0;
UNIT_TIME_NS = 1;
UNIT_COUNT = 2;
UNIT_SIZE_BYTES = 3;
}
optional BuiltinCounterType type = 1;
repeated string categories = 2;
optional Unit unit = 3;
optional int64 unit_multiplier = 4;
optional bool is_incremental = 5;
}
message DebugAnnotation {
message NestedValue {
enum NestedType {
UNSPECIFIED = 0;
DICT = 1;
ARRAY = 2;
}
optional NestedType nested_type = 1;
repeated string dict_keys = 2;
repeated NestedValue dict_values = 3;
repeated NestedValue array_values = 4;
optional int64 int_value = 5;
optional double double_value = 6;
optional bool bool_value = 7;
optional string string_value = 8;
}
oneof name_field {
uint64 name_iid = 1;
string name = 10;
}
oneof value {
bool bool_value = 2;
uint64 uint_value = 3;
int64 int_value = 4;
double double_value = 5;
string string_value = 6;
uint64 pointer_value = 7;
NestedValue nested_value = 8;
}
}

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/core_red_shade"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>

View File

@@ -0,0 +1,814 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="org.thoughtcrime.securesms">
<uses-sdk tools:overrideLibrary="androidx.camera.core,androidx.camera.camera2,androidx.camera.lifecycle,androidx.camera.view" />
<permission android:name="${applicationId}.ACCESS_SECRETS"
android:label="Access to TextSecure Secrets"
android:protectionLevel="signature" />
<uses-feature android:name="android.hardware.camera" android:required="false" />
<uses-feature android:name="android.hardware.bluetooth" android:required="false" />
<uses-feature android:name="android.hardware.location" android:required="false"/>
<uses-feature android:name="android.hardware.location.network" android:required="false"/>
<uses-feature android:name="android.hardware.location.gps" android:required="false"/>
<uses-feature android:name="android.hardware.microphone" android:required="false"/>
<uses-feature android:name="android.hardware.wifi" android:required="false"/>
<uses-feature android:name="android.hardware.portrait" android:required="false"/>
<uses-feature android:name="android.hardware.touchscreen" android:required="false"/>
<uses-permission android:name="android.permission.USE_FINGERPRINT"/>
<uses-permission android:name="org.thoughtcrime.securesms.ACCESS_SECRETS"/>
<uses-permission android:name="android.permission.READ_PROFILE"/>
<uses-permission android:name="android.permission.WRITE_PROFILE"/>
<uses-permission android:name="android.permission.BROADCAST_WAP_PUSH"
tools:ignore="ProtectedPermissions"/>
<uses-permission android:name="android.permission.READ_CONTACTS"/>
<uses-permission android:name="android.permission.WRITE_CONTACTS"/>
<uses-permission android:name="android.permission.ACCESS_NOTIFICATION_POLICY" />
<uses-permission android:name="android.permission.RECEIVE_SMS"/>
<uses-permission android:name="android.permission.RECEIVE_MMS"/>
<uses-permission android:name="android.permission.READ_SMS"/>
<uses-permission android:name="android.permission.SEND_SMS"/>
<uses-permission android:name="android.permission.WRITE_SMS"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.READ_PHONE_NUMBERS" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"
android:maxSdkVersion="28" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-permission android:name="android.permission.READ_CALL_STATE"/>
<!-- For sending/receiving events -->
<uses-permission android:name="android.permission.WRITE_CALENDAR"/>
<uses-permission android:name="android.permission.READ_CALENDAR"/>
<!-- Normal -->
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<!-- So we can add a TextSecure 'Account' -->
<uses-permission android:name="android.permission.READ_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.AUTHENTICATE_ACCOUNTS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS"/>
<!-- For conversation 'shortcuts' on the desktop -->
<uses-permission android:name="android.permission.INSTALL_SHORTCUT"/>
<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />
<!-- For fixing MMS -->
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/>
<!-- Set image as wallpaper -->
<uses-permission android:name="android.permission.SET_WALLPAPER"/>
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BROADCAST_STICKY" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="android.permission.DISABLE_KEYGUARD" />
<uses-permission android:name="android.permission.RAISED_THREAD_PRIORITY" />
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS"/>
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT"/>
<application android:name=".ApplicationContext"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
tools:replace="android:allowBackup"
android:allowBackup="false"
android:theme="@style/TextSecure.LightTheme"
android:largeHeap="true">
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="AIzaSyCSx9xea86GwDKGznCAULE9Y5a8b-TfN9U"/>
<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<meta-data android:name="com.google.android.gms.car.application"
android:resource="@xml/automotive_app_desc" />
<meta-data android:name="firebase_analytics_collection_deactivated" android:value="true" />
<meta-data android:name="google_analytics_adid_collection_enabled" android:value="false" />
<meta-data android:name="firebase_messaging_auto_init_enabled" android:value="false" />
<activity android:name=".WebRtcCallActivity"
android:theme="@style/TextSecure.LightTheme.WebRTCCall"
android:excludeFromRecents="true"
android:screenOrientation="portrait"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateAlwaysHidden"
android:configChanges="screenSize|smallestScreenSize|screenLayout|orientation"
android:taskAffinity=".calling"
android:launchMode="singleTask"/>
<activity android:name=".messagerequests.CalleeMustAcceptMessageRequestActivity"
android:theme="@style/TextSecure.DarkNoActionBar"
android:screenOrientation="portrait"
android:noHistory="true"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".InviteActivity"
android:theme="@style/Signal.Light.NoActionBar.Invite"
android:windowSoftInputMode="stateHidden"
android:parentActivityName=".MainActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".MainActivity" />
</activity>
<activity android:name=".PromptMmsActivity"
android:label="Configure MMS Settings"
android:windowSoftInputMode="stateUnchanged"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DeviceProvisioningActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="tsdevice"/>
</intent-filter>
</activity>
<activity android:name=".preferences.MmsPreferencesActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".sharing.ShareActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:excludeFromRecents="true"
android:launchMode="singleTask"
android:taskAffinity=""
android:noHistory="true"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.SEND" />
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="audio/*" />
<data android:mimeType="image/*" />
<data android:mimeType="text/plain" />
<data android:mimeType="video/*" />
<data android:mimeType="application/*"/>
<data android:mimeType="text/*"/>
<data android:mimeType="*/*"/>
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND_MULTIPLE" />
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="image/*" />
<data android:mimeType="video/*" />
</intent-filter>
<meta-data
android:name="android.service.chooser.chooser_target_service"
android:value=".service.DirectShareService" />
</activity>
<activity android:name=".stickers.StickerPackPreviewActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:launchMode="singleTask"
android:noHistory="true"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="sgnl"
android:host="addstickers" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https"
android:host="signal.art"
android:pathPrefix="/addstickers"/>
</intent-filter>
</activity>
<activity-alias android:name=".RoutingActivity"
android:targetActivity=".MainActivity"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.intent.category.MULTIWINDOW_LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="sgnl"
android:host="signal.group" />
</intent-filter>
<intent-filter android:autoVerify="true"
tools:targetApi="23">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https"
android:host="signal.group"/>
</intent-filter>
<meta-data android:name="com.sec.minimode.icon.portrait.normal"
android:resource="@mipmap/ic_launcher" />
<meta-data android:name="com.sec.minimode.icon.landscape.normal"
android:resource="@mipmap/ic_launcher" />
</activity-alias>
<activity android:name=".conversation.ConversationActivity"
android:windowSoftInputMode="stateUnchanged"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"
android:parentActivityName=".MainActivity">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="org.thoughtcrime.securesms.MainActivity" />
</activity>
<activity android:name=".longmessage.LongMessageActivity" />
<activity android:name=".conversation.ConversationPopupActivity"
android:windowSoftInputMode="stateVisible"
android:launchMode="singleTask"
android:taskAffinity=""
android:excludeFromRecents="true"
android:theme="@style/TextSecure.LightTheme.Popup"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".messagedetails.MessageDetailsActivity"
android:label="@string/AndroidManifest__message_details"
android:windowSoftInputMode="stateHidden"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".groups.ui.pendingmemberinvites.PendingMemberInvitesActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.invitesandrequests.ManagePendingAndRequestingMembersActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize|uiMode"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.managegroup.ManageGroupActivity"
android:windowSoftInputMode="stateAlwaysHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".recipients.ui.managerecipient.ManageRecipientActivity"
android:windowSoftInputMode="stateAlwaysHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DatabaseMigrationActivity"
android:theme="@style/NoAnimation.Theme.AppCompat.Light.DarkActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".migrations.ApplicationMigrationActivity"
android:theme="@style/NoAnimation.Theme.AppCompat.Light.DarkActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphraseCreateActivity"
android:label="@string/AndroidManifest__create_passphrase"
android:windowSoftInputMode="stateUnchanged"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphrasePromptActivity"
android:launchMode="singleTask"
android:theme="@style/TextSecure.LightIntroTheme"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".NewConversationActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:windowSoftInputMode="stateAlwaysVisible"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PushContactSelectionActivity"
android:label="@string/AndroidManifest__select_contacts"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".giph.ui.GiphyActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".mediasend.MediaSendActivity"
android:theme="@style/TextSecure.FullScreenMedia"
android:windowSoftInputMode="stateHidden"
android:launchMode="singleTop"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".PassphraseChangeActivity"
android:label="@string/AndroidManifest__change_passphrase"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".VerifyIdentityActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ApplicationPreferencesActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.NOTIFICATION_PREFERENCES" />
</intent-filter>
</activity>
<activity android:name=".registration.RegistrationNavigationActivity"
android:launchMode="singleTask"
android:theme="@style/TextSecure.LightRegistrationTheme"
android:windowSoftInputMode="stateUnchanged"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".revealable.ViewOnceMessageActivity"
android:launchMode="singleTask"
android:theme="@style/TextSecure.FullScreenMedia"
android:windowSoftInputMode="stateHidden"
android:excludeFromRecents="true"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".stickers.StickerManagementActivity"
android:launchMode="singleTask"
android:theme="@style/TextSecure.LightTheme"
android:windowSoftInputMode="stateUnchanged"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DeviceActivity"
android:label="@string/AndroidManifest__linked_devices"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".logsubmit.SubmitDebugLogActivity"
android:label="@string/AndroidManifest__log_submit"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".MediaPreviewActivity"
android:label="@string/AndroidManifest__media_preview"
android:windowSoftInputMode="stateHidden"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".AvatarPreviewActivity"
android:label="@string/AndroidManifest__media_preview"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".mediaoverview.MediaOverviewActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:windowSoftInputMode="stateHidden"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".DummyActivity"
android:theme="@android:style/Theme.NoDisplay"
android:enabled="true"
android:allowTaskReparenting="true"
android:noHistory="true"
android:excludeFromRecents="true"
android:alwaysRetainTaskState="false"
android:stateNotNeeded="true"
android:clearTaskOnLaunch="true"
android:finishOnTaskLaunch="true" />
<activity android:name=".PlayServicesProblemActivity"
android:theme="@style/TextSecure.DialogActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".SmsSendtoActivity">
<intent-filter>
<action android:name="android.intent.action.SENDTO" />
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="sms" />
<data android:scheme="smsto" />
<data android:scheme="mms" />
<data android:scheme="mmsto" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="vnd.android.cursor.item/vnd.org.thoughtcrime.securesms.contact" />
</intent-filter>
</activity>
<activity android:name="org.thoughtcrime.securesms.webrtc.VoiceCallShare"
android:excludeFromRecents="true"
android:theme="@style/NoAnimation.Theme.BlackScreen"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="vnd.android.cursor.item/vnd.org.thoughtcrime.securesms.call" />
</intent-filter>
</activity>
<activity android:name=".mediasend.AvatarSelectionActivity"
android:theme="@style/TextSecure.FullScreenMedia"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".blocked.BlockedUsersActivity"
android:theme="@style/TextSecure.LightTheme"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".scribbles.ImageEditorStickerSelectActivity"
android:theme="@style/TextSecure.DarkTheme"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".profiles.edit.EditProfileActivity"
android:theme="@style/TextSecure.LightRegistrationTheme"
android:windowSoftInputMode="stateVisible|adjustResize" />
<activity android:name=".lock.v2.CreateKbsPinActivity"
android:theme="@style/TextSecure.LightRegistrationTheme"
android:windowSoftInputMode="adjustResize"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".lock.v2.KbsMigrationActivity"
android:theme="@style/TextSecure.LightRegistrationTheme"
android:windowSoftInputMode="adjustResize"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ClearProfileAvatarActivity"
android:theme="@style/Theme.AppCompat.Dialog.Alert"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"
android:icon="@drawable/clear_profile_avatar"
android:label="@string/AndroidManifest_remove_photo">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.action.CLEAR_PROFILE_PHOTO"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</activity>
<activity android:name=".contacts.TurnOffContactJoinedNotificationsActivity"
android:theme="@style/Theme.AppCompat.Dialog.Alert" />
<activity android:name=".messagerequests.MessageRequestMegaphoneActivity"
android:theme="@style/TextSecure.LightRegistrationTheme"
android:windowSoftInputMode="adjustResize"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".contactshare.ContactShareEditActivity"
android:theme="@style/TextSecure.LightTheme"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".contactshare.ContactNameEditActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".contactshare.SharedContactDetailsActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".ShortcutLauncherActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:exported="true"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity
android:name=".maps.PlacePickerActivity"
android:label="@string/PlacePickerActivity_title"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/>
<activity android:name=".MainActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:launchMode="singleTask"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".pin.PinRestoreActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".groups.ui.creategroup.CreateGroupActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.addtogroup.AddToGroupsActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.addmembers.AddMembersActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.creategroup.details.AddGroupDetailsActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar" />
<activity android:name=".groups.ui.chooseadmin.ChooseNewAdminActivity"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize" />
<activity android:name=".megaphone.ClientDeprecatedActivity"
android:theme="@style/Theme.Signal.DayNight.NoActionBar"
android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize|uiMode"
android:launchMode="singleTask" />
<service android:enabled="true" android:name=".service.WebRtcCallService"/>
<service android:enabled="true" android:name=".service.ApplicationMigrationService"/>
<service android:enabled="true" android:exported="false" android:name=".service.KeyCachingService"/>
<service android:enabled="true" android:name=".messages.IncomingMessageObserver$ForegroundService"/>
<service android:name=".components.voice.VoiceNotePlaybackService">
<intent-filter>
<action android:name="android.media.browse.MediaBrowserService" />
</intent-filter>
</service>
<receiver android:name="androidx.media.session.MediaButtonReceiver" >
<intent-filter>
<action android:name="android.intent.action.MEDIA_BUTTON" />
</intent-filter>
</receiver>
<service android:name=".service.QuickResponseService"
android:permission="android.permission.SEND_RESPOND_VIA_MESSAGE"
android:exported="true" >
<intent-filter>
<action android:name="android.intent.action.RESPOND_VIA_MESSAGE" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="sms" />
<data android:scheme="smsto" />
<data android:scheme="mms" />
<data android:scheme="mmsto" />
</intent-filter>
</service>
<service android:name=".service.AccountAuthenticatorService" android:exported="true">
<intent-filter>
<action android:name="android.accounts.AccountAuthenticator" />
</intent-filter>
<meta-data android:name="android.accounts.AccountAuthenticator" android:resource="@xml/authenticator" />
</service>
<service android:name=".service.ContactsSyncAdapterService" android:exported="true">
<intent-filter>
<action android:name="android.content.SyncAdapter"/>
</intent-filter>
<meta-data android:name="android.content.SyncAdapter" android:resource="@xml/syncadapter" />
<meta-data android:name="android.provider.CONTACTS_STRUCTURE" android:resource="@xml/contactsformat" />
</service>
<service android:name=".service.DirectShareService"
android:permission="android.permission.BIND_CHOOSER_TARGET_SERVICE">
<intent-filter>
<action android:name="android.service.chooser.ChooserTargetService" />
</intent-filter>
</service>
<service android:name=".service.GenericForegroundService"/>
<service android:name=".gcm.FcmFetchService" />
<service android:name=".gcm.FcmReceiveService">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>
</service>
<receiver android:name=".service.SmsListener"
android:permission="android.permission.BROADCAST_SMS"
android:enabled="true"
android:exported="true">
<intent-filter android:priority="1001">
<action android:name="android.provider.Telephony.SMS_RECEIVED"/>
</intent-filter>
<intent-filter>
<action android:name="android.provider.Telephony.SMS_DELIVER"/>
</intent-filter>
</receiver>
<receiver android:name=".service.SmsDeliveryListener"
android:exported="true">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.services.MESSAGE_SENT"/>
</intent-filter>
</receiver>
<receiver android:name=".service.MmsListener"
android:enabled="true"
android:exported="true"
android:permission="android.permission.BROADCAST_WAP_PUSH">
<intent-filter android:priority="1001">
<action android:name="android.provider.Telephony.WAP_PUSH_RECEIVED"/>
<data android:mimeType="application/vnd.wap.mms-message" />
</intent-filter>
<intent-filter>
<action android:name="android.provider.Telephony.WAP_PUSH_DELIVER"/>
<data android:mimeType="application/vnd.wap.mms-message" />
</intent-filter>
</receiver>
<receiver android:name=".notifications.MarkReadReceiver"
android:enabled="true"
android:exported="false">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.CLEAR"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.RemoteReplyReceiver"
android:enabled="true"
android:exported="false">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.WEAR_REPLY"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.AndroidAutoHeardReceiver"
android:exported="false">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.ANDROID_AUTO_HEARD"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.AndroidAutoReplyReceiver"
android:exported="false">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.notifications.ANDROID_AUTO_REPLY"/>
</intent-filter>
</receiver>
<receiver android:name=".service.ExpirationListener" />
<receiver android:name=".revealable.ViewOnceMessageManager$ViewOnceAlarm" />
<receiver android:name=".service.TrimThreadsByDateManager$TrimThreadsByDateAlarm" />
<provider android:name=".providers.PartProvider"
android:grantUriPermissions="true"
android:exported="false"
android:authorities="${applicationId}.part" />
<provider android:name=".providers.BlobContentProvider"
android:authorities="${applicationId}.blob"
android:exported="false"
android:grantUriPermissions="true" />
<provider android:name=".providers.MmsBodyProvider"
android:grantUriPermissions="true"
android:exported="false"
android:authorities="${applicationId}.mms" />
<provider android:name="androidx.core.content.FileProvider"
android:authorities="${applicationId}.fileprovider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/file_provider_paths" />
</provider>
<provider android:name=".database.DatabaseContentProviders$Conversation"
android:authorities="${applicationId}.database.conversation"
android:exported="false" />
<provider android:name=".database.DatabaseContentProviders$ConversationList"
android:authorities="${applicationId}.database.conversationlist"
android:exported="false" />
<provider android:name=".database.DatabaseContentProviders$Attachment"
android:authorities="${applicationId}.database.attachment"
android:exported="false" />
<provider android:name=".database.DatabaseContentProviders$Sticker"
android:authorities="${applicationId}.database.sticker"
android:exported="false" />
<provider android:name=".database.DatabaseContentProviders$StickerPack"
android:authorities="${applicationId}.database.stickerpack"
android:exported="false" />
<receiver android:name=".service.BootReceiver">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
<action android:name="org.thoughtcrime.securesms.RESTART"/>
</intent-filter>
</receiver>
<receiver android:name=".service.DirectoryRefreshListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name=".service.RotateSignedPreKeyListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name=".service.RotateSenderCertificateListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name=".service.LocalBackupListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name=".service.PersistentConnectionBootListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.LocaleChangedReceiver">
<intent-filter>
<action android:name="android.intent.action.LOCALE_CHANGED"/>
</intent-filter>
</receiver>
<receiver android:name=".notifications.MessageNotifier$ReminderReceiver"/>
<receiver android:name=".notifications.DeleteNotificationReceiver">
<intent-filter>
<action android:name="org.thoughtcrime.securesms.DELETE_NOTIFICATION"/>
</intent-filter>
</receiver>
<receiver
android:name=".service.PanicResponderListener"
android:exported="true">
<intent-filter>
<action android:name="info.guardianproject.panic.action.TRIGGER" />
</intent-filter>
</receiver>
<service
android:name=".gcm.FcmJobService"
android:permission="android.permission.BIND_JOB_SERVICE"
android:enabled="@bool/enable_job_service"
tools:targetApi="26" />
<service
android:name=".jobmanager.JobSchedulerScheduler$SystemService"
android:permission="android.permission.BIND_JOB_SERVICE"
android:enabled="@bool/enable_job_service"
tools:targetApi="26" />
<service
android:name=".jobmanager.KeepAliveService"
android:enabled="@bool/enable_alarm_manager" />
<receiver
android:name=".jobmanager.AlarmManagerScheduler$RetryReceiver"
android:enabled="@bool/enable_alarm_manager" />
<!-- Probably don't need this one -->
<receiver
android:name=".jobmanager.BootReceiver"
android:enabled="true">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<uses-library android:name="org.apache.http.legacy" android:required="false"/>
<uses-library android:name="com.sec.android.app.multiwindow" android:required="false"/>
<meta-data android:name="com.sec.android.support.multiwindow" android:value="true" />
<meta-data android:name="com.sec.android.multiwindow.DEFAULT_SIZE_W" android:value="632.0dip" />
<meta-data android:name="com.sec.android.multiwindow.DEFAULT_SIZE_H" android:value="598.0dip" />
<meta-data android:name="com.sec.android.multiwindow.MINIMUM_SIZE_W" android:value="632.0dip" />
<meta-data android:name="com.sec.android.multiwindow.MINIMUM_SIZE_H" android:value="598.0dip" />
</application>
</manifest>

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 240 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 421 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 365 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 434 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 664 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 608 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 552 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 631 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 652 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 531 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 685 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 603 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 391 KiB

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,822 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package androidx.camera.view;
import android.Manifest.permission;
import android.annotation.SuppressLint;
import android.content.Context;
import android.content.res.TypedArray;
import android.hardware.display.DisplayManager;
import android.hardware.display.DisplayManager.DisplayListener;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.os.Parcelable;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.Display;
import android.view.MotionEvent;
import android.view.ScaleGestureDetector;
import android.view.Surface;
import android.view.View;
import android.view.ViewConfiguration;
import android.view.ViewGroup;
import android.widget.FrameLayout;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.RequiresApi;
import androidx.annotation.RequiresPermission;
import androidx.annotation.RestrictTo;
import androidx.annotation.RestrictTo.Scope;
import androidx.camera.core.Camera;
import androidx.camera.core.CameraSelector;
import androidx.camera.core.FocusMeteringAction;
import androidx.camera.core.FocusMeteringResult;
import androidx.camera.core.ImageCapture;
import androidx.camera.core.ImageCapture.OnImageCapturedCallback;
import androidx.camera.core.ImageCapture.OnImageSavedCallback;
import androidx.camera.core.ImageProxy;
import androidx.camera.core.Logger;
import androidx.camera.core.MeteringPoint;
import androidx.camera.core.MeteringPointFactory;
import androidx.camera.core.VideoCapture;
import androidx.camera.core.VideoCapture.OnVideoSavedCallback;
import androidx.camera.core.impl.LensFacingConverter;
import androidx.camera.core.impl.utils.executor.CameraXExecutors;
import androidx.camera.core.impl.utils.futures.FutureCallback;
import androidx.camera.core.impl.utils.futures.Futures;
import androidx.lifecycle.LifecycleOwner;
import androidx.lifecycle.LiveData;
import com.google.common.util.concurrent.ListenableFuture;
import java.io.File;
import java.util.concurrent.Executor;
/**
* A {@link View} that displays a preview of the camera with methods {@link
* #takePicture(Executor, OnImageCapturedCallback)},
* {@link #takePicture(ImageCapture.OutputFileOptions, Executor, OnImageSavedCallback)},
* {@link #startRecording(File , Executor , OnVideoSavedCallback callback)}
* and {@link #stopRecording()}.
*
* <p>Because the Camera is a limited resource and consumes a high amount of power, CameraView must
* be opened/closed. CameraView will handle opening/closing automatically through use of a {@link
* LifecycleOwner}. Use {@link #bindToLifecycle(LifecycleOwner)} to start the camera.
*/
@RequiresApi(21)
@SuppressLint("RestrictedApi")
public final class SignalCameraView extends FrameLayout {
static final String TAG = SignalCameraView.class.getSimpleName();
static final int INDEFINITE_VIDEO_DURATION = -1;
static final int INDEFINITE_VIDEO_SIZE = -1;
private static final String EXTRA_SUPER = "super";
private static final String EXTRA_ZOOM_RATIO = "zoom_ratio";
private static final String EXTRA_PINCH_TO_ZOOM_ENABLED = "pinch_to_zoom_enabled";
private static final String EXTRA_FLASH = "flash";
private static final String EXTRA_MAX_VIDEO_DURATION = "max_video_duration";
private static final String EXTRA_MAX_VIDEO_SIZE = "max_video_size";
private static final String EXTRA_SCALE_TYPE = "scale_type";
private static final String EXTRA_CAMERA_DIRECTION = "camera_direction";
private static final String EXTRA_CAPTURE_MODE = "captureMode";
private static final int LENS_FACING_NONE = 0;
private static final int LENS_FACING_FRONT = 1;
private static final int LENS_FACING_BACK = 2;
private static final int FLASH_MODE_AUTO = 1;
private static final int FLASH_MODE_ON = 2;
private static final int FLASH_MODE_OFF = 4;
// For tap-to-focus
private long mDownEventTimestamp;
// For pinch-to-zoom
private PinchToZoomGestureDetector mPinchToZoomGestureDetector;
private boolean mIsPinchToZoomEnabled = true;
SignalCameraXModule mCameraModule;
private final DisplayManager.DisplayListener mDisplayListener =
new DisplayListener() {
@Override
public void onDisplayAdded(int displayId) {
}
@Override
public void onDisplayRemoved(int displayId) {
}
@Override
public void onDisplayChanged(int displayId) {
mCameraModule.invalidateView();
}
};
private PreviewView mPreviewView;
// For accessibility event
private MotionEvent mUpEvent;
public SignalCameraView(@NonNull Context context) {
this(context, null);
}
public SignalCameraView(@NonNull Context context, @Nullable AttributeSet attrs) {
this(context, attrs, 0);
}
public SignalCameraView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
init(context, attrs);
}
@RequiresApi(21)
public SignalCameraView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr,
int defStyleRes) {
super(context, attrs, defStyleAttr, defStyleRes);
init(context, attrs);
}
/**
* Binds control of the camera used by this view to the given lifecycle.
*
* <p>This links opening/closing the camera to the given lifecycle. The camera will not operate
* unless this method is called with a valid {@link LifecycleOwner} that is not in the {@link
* androidx.lifecycle.Lifecycle.State#DESTROYED} state. Call this method only once camera
* permissions have been obtained.
*
* <p>Once the provided lifecycle has transitioned to a {@link
* androidx.lifecycle.Lifecycle.State#DESTROYED} state, CameraView must be bound to a new
* lifecycle through this method in order to operate the camera.
*
* @param lifecycleOwner The lifecycle that will control this view's camera
* @throws IllegalArgumentException if provided lifecycle is in a {@link
* androidx.lifecycle.Lifecycle.State#DESTROYED} state.
* @throws IllegalStateException if camera permissions are not granted.
*/
@RequiresPermission(permission.CAMERA)
public void bindToLifecycle(@NonNull LifecycleOwner lifecycleOwner) {
mCameraModule.bindToLifecycle(lifecycleOwner);
}
private void init(Context context, @Nullable AttributeSet attrs) {
addView(mPreviewView = new PreviewView(getContext()), 0 /* view position */);
mCameraModule = new SignalCameraXModule(this);
if (attrs != null) {
TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.CameraView);
setScaleType(
PreviewView.ScaleType.fromId(
a.getInteger(R.styleable.CameraView_scaleType,
getScaleType().getId())));
setPinchToZoomEnabled(
a.getBoolean(
R.styleable.CameraView_pinchToZoomEnabled, isPinchToZoomEnabled()));
setCaptureMode(
CaptureMode.fromId(
a.getInteger(R.styleable.CameraView_captureMode,
getCaptureMode().getId())));
int lensFacing = a.getInt(R.styleable.CameraView_lensFacing, LENS_FACING_BACK);
switch (lensFacing) {
case LENS_FACING_NONE:
setCameraLensFacing(null);
break;
case LENS_FACING_FRONT:
setCameraLensFacing(CameraSelector.LENS_FACING_FRONT);
break;
case LENS_FACING_BACK:
setCameraLensFacing(CameraSelector.LENS_FACING_BACK);
break;
default:
// Unhandled event.
}
int flashMode = a.getInt(R.styleable.CameraView_flash, 0);
switch (flashMode) {
case FLASH_MODE_AUTO:
setFlash(ImageCapture.FLASH_MODE_AUTO);
break;
case FLASH_MODE_ON:
setFlash(ImageCapture.FLASH_MODE_ON);
break;
case FLASH_MODE_OFF:
setFlash(ImageCapture.FLASH_MODE_OFF);
break;
default:
// Unhandled event.
}
a.recycle();
}
if (getBackground() == null) {
setBackgroundColor(0xFF111111);
}
mPinchToZoomGestureDetector = new PinchToZoomGestureDetector(context);
}
@Override
@NonNull
protected LayoutParams generateDefaultLayoutParams() {
return new LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
}
@Override
@NonNull
protected Parcelable onSaveInstanceState() {
// TODO(b/113884082): Decide what belongs here or what should be invalidated on
// configuration
// change
Bundle state = new Bundle();
state.putParcelable(EXTRA_SUPER, super.onSaveInstanceState());
state.putInt(EXTRA_SCALE_TYPE, getScaleType().getId());
state.putFloat(EXTRA_ZOOM_RATIO, getZoomRatio());
state.putBoolean(EXTRA_PINCH_TO_ZOOM_ENABLED, isPinchToZoomEnabled());
state.putString(EXTRA_FLASH, FlashModeConverter.nameOf(getFlash()));
state.putLong(EXTRA_MAX_VIDEO_DURATION, getMaxVideoDuration());
state.putLong(EXTRA_MAX_VIDEO_SIZE, getMaxVideoSize());
if (getCameraLensFacing() != null) {
state.putString(EXTRA_CAMERA_DIRECTION,
LensFacingConverter.nameOf(getCameraLensFacing()));
}
state.putInt(EXTRA_CAPTURE_MODE, getCaptureMode().getId());
return state;
}
@Override
protected void onRestoreInstanceState(@Nullable Parcelable savedState) {
// TODO(b/113884082): Decide what belongs here or what should be invalidated on
// configuration
// change
if (savedState instanceof Bundle) {
Bundle state = (Bundle) savedState;
super.onRestoreInstanceState(state.getParcelable(EXTRA_SUPER));
setScaleType(PreviewView.ScaleType.fromId(state.getInt(EXTRA_SCALE_TYPE)));
setZoomRatio(state.getFloat(EXTRA_ZOOM_RATIO));
setPinchToZoomEnabled(state.getBoolean(EXTRA_PINCH_TO_ZOOM_ENABLED));
setFlash(FlashModeConverter.valueOf(state.getString(EXTRA_FLASH)));
setMaxVideoDuration(state.getLong(EXTRA_MAX_VIDEO_DURATION));
setMaxVideoSize(state.getLong(EXTRA_MAX_VIDEO_SIZE));
String lensFacingString = state.getString(EXTRA_CAMERA_DIRECTION);
setCameraLensFacing(
TextUtils.isEmpty(lensFacingString)
? null
: LensFacingConverter.valueOf(lensFacingString));
setCaptureMode(CaptureMode.fromId(state.getInt(EXTRA_CAPTURE_MODE)));
} else {
super.onRestoreInstanceState(savedState);
}
}
@Override
protected void onAttachedToWindow() {
super.onAttachedToWindow();
DisplayManager dpyMgr =
(DisplayManager) getContext().getSystemService(Context.DISPLAY_SERVICE);
dpyMgr.registerDisplayListener(mDisplayListener, new Handler(Looper.getMainLooper()));
}
@Override
protected void onDetachedFromWindow() {
super.onDetachedFromWindow();
DisplayManager dpyMgr =
(DisplayManager) getContext().getSystemService(Context.DISPLAY_SERVICE);
dpyMgr.unregisterDisplayListener(mDisplayListener);
}
/**
* Gets the {@link LiveData} of the underlying {@link PreviewView}'s
* {@link PreviewView.StreamState}.
*
* @return A {@link LiveData} containing the {@link PreviewView.StreamState}. Apps can either
* get current value by {@link LiveData#getValue()} or register a observer by
* {@link LiveData#observe}.
* @see PreviewView#getPreviewStreamState()
*/
@NonNull
public LiveData<PreviewView.StreamState> getPreviewStreamState() {
return mPreviewView.getPreviewStreamState();
}
@NonNull
PreviewView getPreviewView() {
return mPreviewView;
}
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
// Since bindToLifecycle will depend on the measured dimension, only call it when measured
// dimension is not 0x0
if (getMeasuredWidth() > 0 && getMeasuredHeight() > 0) {
mCameraModule.bindToLifecycleAfterViewMeasured();
}
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
}
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
// In case that the CameraView size is always set as 0x0, we still need to trigger to force
// binding to lifecycle
mCameraModule.bindToLifecycleAfterViewMeasured();
mCameraModule.invalidateView();
super.onLayout(changed, left, top, right, bottom);
}
/**
* @return One of {@link Surface#ROTATION_0}, {@link Surface#ROTATION_90}, {@link
* Surface#ROTATION_180}, {@link Surface#ROTATION_270}.
*/
int getDisplaySurfaceRotation() {
Display display = getDisplay();
// Null when the View is detached. If we were in the middle of a background operation,
// better to not NPE. When the background operation finishes, it'll realize that the camera
// was closed.
if (display == null) {
return 0;
}
return display.getRotation();
}
/**
* Returns the scale type used to scale the preview.
*
* @return The current {@link PreviewView.ScaleType}.
*/
@NonNull
public PreviewView.ScaleType getScaleType() {
return mPreviewView.getScaleType();
}
/**
* Sets the view finder scale type.
*
* <p>This controls how the view finder should be scaled and positioned within the view.
*
* @param scaleType The desired {@link PreviewView.ScaleType}.
*/
public void setScaleType(@NonNull PreviewView.ScaleType scaleType) {
mPreviewView.setScaleType(scaleType);
}
/**
* Returns the scale type used to scale the preview.
*
* @return The current {@link CaptureMode}.
*/
@NonNull
public CaptureMode getCaptureMode() {
return mCameraModule.getCaptureMode();
}
/**
* Sets the CameraView capture mode
*
* <p>This controls only image or video capture function is enabled or both are enabled.
*
* @param captureMode The desired {@link CaptureMode}.
*/
public void setCaptureMode(@NonNull CaptureMode captureMode) {
mCameraModule.setCaptureMode(captureMode);
}
/**
* Returns the maximum duration of videos, or {@link #INDEFINITE_VIDEO_DURATION} if there is no
* timeout.
*
* @hide Not currently implemented.
*/
@RestrictTo(Scope.LIBRARY_GROUP)
public long getMaxVideoDuration() {
return mCameraModule.getMaxVideoDuration();
}
/**
* Sets the maximum video duration before
* {@link OnVideoSavedCallback#onVideoSaved(VideoCapture.OutputFileResults)} is called
* automatically.
* Use {@link #INDEFINITE_VIDEO_DURATION} to disable the timeout.
*/
private void setMaxVideoDuration(long duration) {
mCameraModule.setMaxVideoDuration(duration);
}
/**
* Returns the maximum size of videos in bytes, or {@link #INDEFINITE_VIDEO_SIZE} if there is no
* timeout.
*/
private long getMaxVideoSize() {
return mCameraModule.getMaxVideoSize();
}
/**
* Sets the maximum video size in bytes before
* {@link OnVideoSavedCallback#onVideoSaved(VideoCapture.OutputFileResults)}
* is called automatically. Use {@link #INDEFINITE_VIDEO_SIZE} to disable the size restriction.
*/
private void setMaxVideoSize(long size) {
mCameraModule.setMaxVideoSize(size);
}
/**
* Takes a picture, and calls {@link OnImageCapturedCallback#onCaptureSuccess(ImageProxy)}
* once when done.
*
* @param executor The executor in which the callback methods will be run.
* @param callback Callback which will receive success or failure callbacks.
*/
public void takePicture(@NonNull Executor executor, @NonNull OnImageCapturedCallback callback) {
mCameraModule.takePicture(executor, callback);
}
/**
* Takes a picture and calls
* {@link OnImageSavedCallback#onImageSaved(ImageCapture.OutputFileResults)} when done.
*
* <p> The value of {@link ImageCapture.Metadata#isReversedHorizontal()} in the
* {@link ImageCapture.OutputFileOptions} will be overwritten based on camera direction. For
* front camera, it will be set to true; for back camera, it will be set to false.
*
* @param outputFileOptions Options to store the newly captured image.
* @param executor The executor in which the callback methods will be run.
* @param callback Callback which will receive success or failure.
*/
public void takePicture(@NonNull ImageCapture.OutputFileOptions outputFileOptions,
@NonNull Executor executor,
@NonNull OnImageSavedCallback callback) {
mCameraModule.takePicture(outputFileOptions, executor, callback);
}
/**
* Takes a video and calls the OnVideoSavedCallback when done.
*
* @param outputFileOptions Options to store the newly captured video.
* @param executor The executor in which the callback methods will be run.
* @param callback Callback which will receive success or failure.
*/
public void startRecording(@NonNull VideoCapture.OutputFileOptions outputFileOptions,
@NonNull Executor executor,
@NonNull OnVideoSavedCallback callback) {
mCameraModule.startRecording(outputFileOptions, executor, callback);
}
/** Stops an in progress video. */
public void stopRecording() {
mCameraModule.stopRecording();
}
/** @return True if currently recording. */
public boolean isRecording() {
return mCameraModule.isRecording();
}
/**
* Queries whether the current device has a camera with the specified direction.
*
* @return True if the device supports the direction.
* @throws IllegalStateException if the CAMERA permission is not currently granted.
*/
@RequiresPermission(permission.CAMERA)
public boolean hasCameraWithLensFacing(@CameraSelector.LensFacing int lensFacing) {
return mCameraModule.hasCameraWithLensFacing(lensFacing);
}
/**
* Toggles between the primary front facing camera and the primary back facing camera.
*
* <p>This will have no effect if not already bound to a lifecycle via {@link
* #bindToLifecycle(LifecycleOwner)}.
*/
public void toggleCamera() {
mCameraModule.toggleCamera();
}
/**
* Sets the desired camera by specifying desired lensFacing.
*
* <p>This will choose the primary camera with the specified camera lensFacing.
*
* <p>If called before {@link #bindToLifecycle(LifecycleOwner)}, this will set the camera to be
* used when first bound to the lifecycle. If the specified lensFacing is not supported by the
* device, as determined by {@link #hasCameraWithLensFacing(int)}, the first supported
* lensFacing will be chosen when {@link #bindToLifecycle(LifecycleOwner)} is called.
*
* <p>If called with {@code null} AFTER binding to the lifecycle, the behavior would be
* equivalent to unbind the use cases without the lifecycle having to be destroyed.
*
* @param lensFacing The desired camera lensFacing.
*/
public void setCameraLensFacing(@Nullable Integer lensFacing) {
mCameraModule.setCameraLensFacing(lensFacing);
}
/** Returns the currently selected lensFacing. */
@Nullable
public Integer getCameraLensFacing() {
return mCameraModule.getLensFacing();
}
/** Gets the active flash strategy. */
@ImageCapture.FlashMode
public int getFlash() {
return mCameraModule.getFlash();
}
// Begin Signal Custom Code Block
public boolean hasFlash() {
return mCameraModule.hasFlash();
}
// End Signal Custom Code Block
/** Sets the active flash strategy. */
public void setFlash(@ImageCapture.FlashMode int flashMode) {
mCameraModule.setFlash(flashMode);
}
private long delta() {
return System.currentTimeMillis() - mDownEventTimestamp;
}
@Override
public boolean onTouchEvent(@NonNull MotionEvent event) {
// Disable pinch-to-zoom and tap-to-focus while the camera module is paused.
if (mCameraModule.isPaused()) {
return false;
}
// Only forward the event to the pinch-to-zoom gesture detector when pinch-to-zoom is
// enabled.
if (isPinchToZoomEnabled()) {
mPinchToZoomGestureDetector.onTouchEvent(event);
}
if (event.getPointerCount() == 2 && isPinchToZoomEnabled() && isZoomSupported()) {
return true;
}
// Camera focus
switch (event.getAction()) {
case MotionEvent.ACTION_DOWN:
mDownEventTimestamp = System.currentTimeMillis();
break;
case MotionEvent.ACTION_UP:
if (delta() < ViewConfiguration.getLongPressTimeout()
&& mCameraModule.isBoundToLifecycle()) {
mUpEvent = event;
performClick();
}
break;
default:
// Unhandled event.
return false;
}
return true;
}
/**
* Focus the position of the touch event, or focus the center of the preview for
* accessibility events
*/
@Override
public boolean performClick() {
super.performClick();
final float x = (mUpEvent != null) ? mUpEvent.getX() : getX() + getWidth() / 2f;
final float y = (mUpEvent != null) ? mUpEvent.getY() : getY() + getHeight() / 2f;
mUpEvent = null;
Camera camera = mCameraModule.getCamera();
if (camera != null) {
MeteringPointFactory pointFactory = mPreviewView.getMeteringPointFactory();
float afPointWidth = 1.0f / 6.0f; // 1/6 total area
float aePointWidth = afPointWidth * 1.5f;
MeteringPoint afPoint = pointFactory.createPoint(x, y, afPointWidth);
MeteringPoint aePoint = pointFactory.createPoint(x, y, aePointWidth);
ListenableFuture<FocusMeteringResult> future =
camera.getCameraControl().startFocusAndMetering(
new FocusMeteringAction.Builder(afPoint,
FocusMeteringAction.FLAG_AF).addPoint(aePoint,
FocusMeteringAction.FLAG_AE).build());
Futures.addCallback(future, new FutureCallback<FocusMeteringResult>() {
@Override
public void onSuccess(@Nullable FocusMeteringResult result) {
}
@Override
public void onFailure(Throwable t) {
// Throw the unexpected error.
throw new RuntimeException(t);
}
}, CameraXExecutors.directExecutor());
} else {
Logger.d(TAG, "cannot access camera");
}
return true;
}
float rangeLimit(float val, float max, float min) {
return Math.min(Math.max(val, min), max);
}
/**
* Returns whether the view allows pinch-to-zoom.
*
* @return True if pinch to zoom is enabled.
*/
public boolean isPinchToZoomEnabled() {
return mIsPinchToZoomEnabled;
}
/**
* Sets whether the view should allow pinch-to-zoom.
*
* <p>When enabled, the user can pinch the camera to zoom in/out. This only has an effect if the
* bound camera supports zoom.
*
* @param enabled True to enable pinch-to-zoom.
*/
public void setPinchToZoomEnabled(boolean enabled) {
mIsPinchToZoomEnabled = enabled;
}
/**
* Returns the current zoom ratio.
*
* @return The current zoom ratio.
*/
public float getZoomRatio() {
return mCameraModule.getZoomRatio();
}
/**
* Sets the current zoom ratio.
*
* <p>Valid zoom values range from {@link #getMinZoomRatio()} to {@link #getMaxZoomRatio()}.
*
* @param zoomRatio The requested zoom ratio.
*/
public void setZoomRatio(float zoomRatio) {
mCameraModule.setZoomRatio(zoomRatio);
}
/**
* Returns the minimum zoom ratio.
*
* <p>For most cameras this should return a zoom ratio of 1. A zoom ratio of 1 corresponds to a
* non-zoomed image.
*
* @return The minimum zoom ratio.
*/
public float getMinZoomRatio() {
return mCameraModule.getMinZoomRatio();
}
/**
* Returns the maximum zoom ratio.
*
* <p>The zoom ratio corresponds to the ratio between both the widths and heights of a
* non-zoomed image and a maximally zoomed image for the selected camera.
*
* @return The maximum zoom ratio.
*/
public float getMaxZoomRatio() {
return mCameraModule.getMaxZoomRatio();
}
/**
* Returns whether the bound camera supports zooming.
*
* @return True if the camera supports zooming.
*/
public boolean isZoomSupported() {
return mCameraModule.isZoomSupported();
}
/**
* Turns on/off torch.
*
* @param torch True to turn on torch, false to turn off torch.
*/
public void enableTorch(boolean torch) {
mCameraModule.enableTorch(torch);
}
/**
* Returns current torch status.
*
* @return true if torch is on , otherwise false
*/
public boolean isTorchOn() {
return mCameraModule.isTorchOn();
}
/**
* The capture mode used by CameraView.
*
* <p>This enum can be used to determine which capture mode will be enabled for {@link
* SignalCameraView}.
*/
public enum CaptureMode {
/** A mode where image capture is enabled. */
IMAGE(0),
/** A mode where video capture is enabled. */
VIDEO(1),
/**
* A mode where both image capture and video capture are simultaneously enabled. Note that
* this mode may not be available on every device.
*/
MIXED(2);
private final int mId;
int getId() {
return mId;
}
CaptureMode(int id) {
mId = id;
}
static CaptureMode fromId(int id) {
for (CaptureMode f : values()) {
if (f.mId == id) {
return f;
}
}
throw new IllegalArgumentException();
}
}
static class S extends ScaleGestureDetector.SimpleOnScaleGestureListener {
private ScaleGestureDetector.OnScaleGestureListener mListener;
void setRealGestureDetector(ScaleGestureDetector.OnScaleGestureListener l) {
mListener = l;
}
@Override
public boolean onScale(ScaleGestureDetector detector) {
return mListener.onScale(detector);
}
}
private class PinchToZoomGestureDetector extends ScaleGestureDetector
implements ScaleGestureDetector.OnScaleGestureListener {
PinchToZoomGestureDetector(Context context) {
this(context, new S());
}
PinchToZoomGestureDetector(Context context, S s) {
super(context, s);
s.setRealGestureDetector(this);
}
@Override
public boolean onScale(ScaleGestureDetector detector) {
float scale = detector.getScaleFactor();
// Speeding up the zoom by 2X.
if (scale > 1f) {
scale = 1.0f + (scale - 1.0f) * 2;
} else {
scale = 1.0f - (1.0f - scale) * 2;
}
float newRatio = getZoomRatio() * scale;
newRatio = rangeLimit(newRatio, getMaxZoomRatio(), getMinZoomRatio());
setZoomRatio(newRatio);
return true;
}
@Override
public boolean onScaleBegin(ScaleGestureDetector detector) {
return true;
}
@Override
public void onScaleEnd(ScaleGestureDetector detector) {
}
}
}

View File

@@ -0,0 +1,697 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package androidx.camera.view;
import static androidx.camera.core.ImageCapture.FLASH_MODE_OFF;
import android.Manifest.permission;
import android.annotation.SuppressLint;
import android.content.Context;
import android.content.res.Resources;
import android.util.Rational;
import android.util.Size;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.RequiresApi;
import androidx.annotation.RequiresPermission;
import androidx.camera.core.AspectRatio;
import androidx.camera.core.Camera;
import androidx.camera.core.CameraInfoUnavailableException;
import androidx.camera.core.CameraSelector;
import androidx.camera.core.ImageCapture;
import androidx.camera.core.ImageCapture.OnImageCapturedCallback;
import androidx.camera.core.ImageCapture.OnImageSavedCallback;
import androidx.camera.core.Logger;
import androidx.camera.core.Preview;
import androidx.camera.core.TorchState;
import androidx.camera.core.UseCase;
import androidx.camera.core.VideoCapture;
import androidx.camera.core.VideoCapture.OnVideoSavedCallback;
import androidx.camera.core.impl.CameraInternal;
import androidx.camera.core.impl.LensFacingConverter;
import androidx.camera.core.impl.utils.CameraOrientationUtil;
import androidx.camera.core.impl.utils.executor.CameraXExecutors;
import androidx.camera.core.impl.utils.futures.FutureCallback;
import androidx.camera.core.impl.utils.futures.Futures;
import androidx.camera.lifecycle.ProcessCameraProvider;
import androidx.core.util.Preconditions;
import androidx.lifecycle.Lifecycle;
import androidx.lifecycle.LifecycleObserver;
import androidx.lifecycle.LifecycleOwner;
import androidx.lifecycle.OnLifecycleEvent;
import com.google.common.util.concurrent.ListenableFuture;
import org.thoughtcrime.securesms.mediasend.camerax.CameraXUtil;
import org.thoughtcrime.securesms.mms.MediaConstraints;
import org.thoughtcrime.securesms.video.VideoUtil;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Objects;
import java.util.Set;
import java.util.concurrent.Executor;
import java.util.concurrent.atomic.AtomicBoolean;
/** CameraX use case operation built on @{link androidx.camera.core}. */
@RequiresApi(21)
@SuppressLint("RestrictedApi")
final class SignalCameraXModule {
public static final String TAG = "CameraXModule";
private static final float UNITY_ZOOM_SCALE = 1f;
private static final float ZOOM_NOT_SUPPORTED = UNITY_ZOOM_SCALE;
private static final Rational ASPECT_RATIO_16_9 = new Rational(16, 9);
private static final Rational ASPECT_RATIO_4_3 = new Rational(4, 3);
private static final Rational ASPECT_RATIO_9_16 = new Rational(9, 16);
private static final Rational ASPECT_RATIO_3_4 = new Rational(3, 4);
private final Preview.Builder mPreviewBuilder;
private final VideoCapture.Builder mVideoCaptureBuilder;
private final ImageCapture.Builder mImageCaptureBuilder;
private final SignalCameraView mCameraView;
final AtomicBoolean mVideoIsRecording = new AtomicBoolean(false);
private SignalCameraView.CaptureMode mCaptureMode = SignalCameraView.CaptureMode.IMAGE;
private long mMaxVideoDuration = SignalCameraView.INDEFINITE_VIDEO_DURATION;
private long mMaxVideoSize = SignalCameraView.INDEFINITE_VIDEO_SIZE;
@ImageCapture.FlashMode
private int mFlash = FLASH_MODE_OFF;
@Nullable
@SuppressWarnings("WeakerAccess") /* synthetic accessor */
Camera mCamera;
@Nullable
private ImageCapture mImageCapture;
@Nullable
private VideoCapture mVideoCapture;
@SuppressWarnings("WeakerAccess") /* synthetic accessor */
@Nullable
Preview mPreview;
@SuppressWarnings("WeakerAccess") /* synthetic accessor */
@Nullable
LifecycleOwner mCurrentLifecycle;
private final LifecycleObserver mCurrentLifecycleObserver =
new LifecycleObserver() {
@OnLifecycleEvent(Lifecycle.Event.ON_DESTROY)
public void onDestroy(LifecycleOwner owner) {
if (owner == mCurrentLifecycle) {
clearCurrentLifecycle();
}
}
};
@Nullable
private LifecycleOwner mNewLifecycle;
@SuppressWarnings("WeakerAccess") /* synthetic accessor */
@Nullable
Integer mCameraLensFacing = CameraSelector.LENS_FACING_BACK;
@SuppressWarnings("WeakerAccess") /* synthetic accessor */
@Nullable
ProcessCameraProvider mCameraProvider;
SignalCameraXModule(SignalCameraView view) {
mCameraView = view;
Futures.addCallback(ProcessCameraProvider.getInstance(view.getContext()),
new FutureCallback<ProcessCameraProvider>() {
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
@Override
public void onSuccess(@Nullable ProcessCameraProvider provider) {
Preconditions.checkNotNull(provider);
mCameraProvider = provider;
if (mCurrentLifecycle != null) {
bindToLifecycle(mCurrentLifecycle);
}
}
@Override
public void onFailure(Throwable t) {
throw new RuntimeException("CameraX failed to initialize.", t);
}
}, CameraXExecutors.mainThreadExecutor());
mPreviewBuilder = new Preview.Builder().setTargetName("Preview");
mImageCaptureBuilder = new ImageCapture.Builder().setTargetName("ImageCapture");
mVideoCaptureBuilder = new VideoCapture.Builder().setTargetName("VideoCapture")
.setAudioBitRate(VideoUtil.AUDIO_BIT_RATE)
.setVideoFrameRate(VideoUtil.VIDEO_FRAME_RATE)
.setBitRate(VideoUtil.VIDEO_BIT_RATE);
}
@RequiresPermission(permission.CAMERA)
void bindToLifecycle(LifecycleOwner lifecycleOwner) {
mNewLifecycle = lifecycleOwner;
if (getMeasuredWidth() > 0 && getMeasuredHeight() > 0) {
bindToLifecycleAfterViewMeasured();
}
}
@RequiresPermission(permission.CAMERA)
void bindToLifecycleAfterViewMeasured() {
if (mNewLifecycle == null) {
return;
}
clearCurrentLifecycle();
if (mNewLifecycle.getLifecycle().getCurrentState() == Lifecycle.State.DESTROYED) {
// Lifecycle is already in a destroyed state. Since it may have been a valid
// lifecycle when bound, but became destroyed while waiting for layout, treat this as
// a no-op now that we have cleared the previous lifecycle.
mNewLifecycle = null;
return;
}
mCurrentLifecycle = mNewLifecycle;
mNewLifecycle = null;
if (mCameraProvider == null) {
// try again once the camera provider is no longer null
return;
}
Set<Integer> available = getAvailableCameraLensFacing();
if (available.isEmpty()) {
Logger.w(TAG, "Unable to bindToLifeCycle since no cameras available");
mCameraLensFacing = null;
}
// Ensure the current camera exists, or default to another camera
if (mCameraLensFacing != null && !available.contains(mCameraLensFacing)) {
Logger.w(TAG, "Camera does not exist with direction " + mCameraLensFacing);
// Default to the first available camera direction
mCameraLensFacing = available.iterator().next();
Logger.w(TAG, "Defaulting to primary camera with direction " + mCameraLensFacing);
}
// Do not attempt to create use cases for a null cameraLensFacing. This could occur if
// the user explicitly sets the LensFacing to null, or if we determined there
// were no available cameras, which should be logged in the logic above.
if (mCameraLensFacing == null) {
return;
}
// Set the preferred aspect ratio as 4:3 if it is IMAGE only mode. Set the preferred aspect
// ratio as 16:9 if it is VIDEO or MIXED mode. Then, it will be WYSIWYG when the view finder
// is in CENTER_INSIDE mode.
boolean isDisplayPortrait = getDisplayRotationDegrees() == 0
|| getDisplayRotationDegrees() == 180;
// Begin Signal Custom Code Block
int resolution = CameraXUtil.getIdealResolution(Resources.getSystem().getDisplayMetrics().widthPixels, Resources.getSystem().getDisplayMetrics().heightPixels);
// End Signal Custom Code Block
Rational targetAspectRatio;
if (getCaptureMode() == SignalCameraView.CaptureMode.IMAGE) {
// Begin Signal Custom Code Block
mImageCaptureBuilder.setTargetResolution(CameraXUtil.buildResolutionForRatio(resolution, ASPECT_RATIO_4_3, isDisplayPortrait));
// End Signal Custom Code Block
targetAspectRatio = isDisplayPortrait ? ASPECT_RATIO_3_4 : ASPECT_RATIO_4_3;
} else {
// Begin Signal Custom Code Block
mImageCaptureBuilder.setTargetResolution(CameraXUtil.buildResolutionForRatio(resolution, ASPECT_RATIO_16_9, isDisplayPortrait));
// End Signal Custom Code Block
targetAspectRatio = isDisplayPortrait ? ASPECT_RATIO_9_16 : ASPECT_RATIO_16_9;
}
// Begin Signal Custom Code Block
mImageCaptureBuilder.setCaptureMode(CameraXUtil.getOptimalCaptureMode());
// End Signal Custom Code Block
mImageCaptureBuilder.setTargetRotation(getDisplaySurfaceRotation());
mImageCapture = mImageCaptureBuilder.build();
// Begin Signal Custom Code Block
Size size = VideoUtil.getVideoRecordingSize();
mVideoCaptureBuilder.setTargetResolution(size);
mVideoCaptureBuilder.setMaxResolution(size);
// End Signal Custom Code Block
mVideoCaptureBuilder.setTargetRotation(getDisplaySurfaceRotation());
// Begin Signal Custom Code Block
if (MediaConstraints.isVideoTranscodeAvailable()) {
mVideoCapture = mVideoCaptureBuilder.build();
}
// End Signal Custom Code Block
// Adjusts the preview resolution according to the view size and the target aspect ratio.
int height = (int) (getMeasuredWidth() / targetAspectRatio.floatValue());
mPreviewBuilder.setTargetResolution(new Size(getMeasuredWidth(), height));
mPreview = mPreviewBuilder.build();
mPreview.setSurfaceProvider(mCameraView.getPreviewView().getSurfaceProvider());
CameraSelector cameraSelector =
new CameraSelector.Builder().requireLensFacing(mCameraLensFacing).build();
if (getCaptureMode() == SignalCameraView.CaptureMode.IMAGE) {
mCamera = mCameraProvider.bindToLifecycle(mCurrentLifecycle, cameraSelector,
mImageCapture,
mPreview);
} else if (getCaptureMode() == SignalCameraView.CaptureMode.VIDEO) {
mCamera = mCameraProvider.bindToLifecycle(mCurrentLifecycle, cameraSelector,
mVideoCapture,
mPreview);
} else {
mCamera = mCameraProvider.bindToLifecycle(mCurrentLifecycle, cameraSelector,
mImageCapture,
mVideoCapture, mPreview);
}
setZoomRatio(UNITY_ZOOM_SCALE);
mCurrentLifecycle.getLifecycle().addObserver(mCurrentLifecycleObserver);
// Enable flash setting in ImageCapture after use cases are created and binded.
setFlash(getFlash());
}
public void open() {
throw new UnsupportedOperationException(
"Explicit open/close of camera not yet supported. Use bindtoLifecycle() instead.");
}
public void close() {
throw new UnsupportedOperationException(
"Explicit open/close of camera not yet supported. Use bindtoLifecycle() instead.");
}
public void takePicture(Executor executor, OnImageCapturedCallback callback) {
if (mImageCapture == null) {
return;
}
if (getCaptureMode() == SignalCameraView.CaptureMode.VIDEO) {
throw new IllegalStateException("Can not take picture under VIDEO capture mode.");
}
if (callback == null) {
throw new IllegalArgumentException("OnImageCapturedCallback should not be empty");
}
mImageCapture.takePicture(executor, callback);
}
public void takePicture(@NonNull ImageCapture.OutputFileOptions outputFileOptions,
@NonNull Executor executor, OnImageSavedCallback callback) {
if (mImageCapture == null) {
return;
}
if (getCaptureMode() == SignalCameraView.CaptureMode.VIDEO) {
throw new IllegalStateException("Can not take picture under VIDEO capture mode.");
}
if (callback == null) {
throw new IllegalArgumentException("OnImageSavedCallback should not be empty");
}
outputFileOptions.getMetadata().setReversedHorizontal(mCameraLensFacing != null
&& mCameraLensFacing == CameraSelector.LENS_FACING_FRONT);
mImageCapture.takePicture(outputFileOptions, executor, callback);
}
public void startRecording(VideoCapture.OutputFileOptions outputFileOptions,
Executor executor, final OnVideoSavedCallback callback) {
if (mVideoCapture == null) {
return;
}
if (getCaptureMode() == SignalCameraView.CaptureMode.IMAGE) {
throw new IllegalStateException("Can not record video under IMAGE capture mode.");
}
if (callback == null) {
throw new IllegalArgumentException("OnVideoSavedCallback should not be empty");
}
mVideoIsRecording.set(true);
mVideoCapture.startRecording(
outputFileOptions,
executor,
new VideoCapture.OnVideoSavedCallback() {
@Override
public void onVideoSaved(
@NonNull VideoCapture.OutputFileResults outputFileResults) {
mVideoIsRecording.set(false);
callback.onVideoSaved(outputFileResults);
}
@Override
public void onError(
@VideoCapture.VideoCaptureError int videoCaptureError,
@NonNull String message,
@Nullable Throwable cause) {
mVideoIsRecording.set(false);
Logger.e(TAG, message, cause);
callback.onError(videoCaptureError, message, cause);
}
});
}
public void stopRecording() {
if (mVideoCapture == null) {
return;
}
mVideoCapture.stopRecording();
}
public boolean isRecording() {
return mVideoIsRecording.get();
}
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
public void setCameraLensFacing(@Nullable Integer lensFacing) {
// Setting same lens facing is a no-op, so check for that first
if (!Objects.equals(mCameraLensFacing, lensFacing)) {
// If we're not bound to a lifecycle, just update the camera that will be opened when we
// attach to a lifecycle.
mCameraLensFacing = lensFacing;
if (mCurrentLifecycle != null) {
// Re-bind to lifecycle with new camera
bindToLifecycle(mCurrentLifecycle);
}
}
}
@RequiresPermission(permission.CAMERA)
public boolean hasCameraWithLensFacing(@CameraSelector.LensFacing int lensFacing) {
if (mCameraProvider == null) {
return false;
}
try {
return mCameraProvider.hasCamera(
new CameraSelector.Builder().requireLensFacing(lensFacing).build());
} catch (CameraInfoUnavailableException e) {
return false;
}
}
@Nullable
public Integer getLensFacing() {
return mCameraLensFacing;
}
public void toggleCamera() {
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
Set<Integer> availableCameraLensFacing = getAvailableCameraLensFacing();
if (availableCameraLensFacing.isEmpty()) {
return;
}
if (mCameraLensFacing == null) {
setCameraLensFacing(availableCameraLensFacing.iterator().next());
return;
}
if (mCameraLensFacing == CameraSelector.LENS_FACING_BACK
&& availableCameraLensFacing.contains(CameraSelector.LENS_FACING_FRONT)) {
setCameraLensFacing(CameraSelector.LENS_FACING_FRONT);
return;
}
if (mCameraLensFacing == CameraSelector.LENS_FACING_FRONT
&& availableCameraLensFacing.contains(CameraSelector.LENS_FACING_BACK)) {
setCameraLensFacing(CameraSelector.LENS_FACING_BACK);
return;
}
}
public float getZoomRatio() {
if (mCamera != null) {
return mCamera.getCameraInfo().getZoomState().getValue().getZoomRatio();
} else {
return UNITY_ZOOM_SCALE;
}
}
public void setZoomRatio(float zoomRatio) {
if (mCamera != null) {
ListenableFuture<Void> future = mCamera.getCameraControl().setZoomRatio(
zoomRatio);
Futures.addCallback(future, new FutureCallback<Void>() {
@Override
public void onSuccess(@Nullable Void result) {
}
@Override
public void onFailure(Throwable t) {
// Throw the unexpected error.
throw new RuntimeException(t);
}
}, CameraXExecutors.directExecutor());
} else {
Logger.e(TAG, "Failed to set zoom ratio");
}
}
public float getMinZoomRatio() {
if (mCamera != null) {
return mCamera.getCameraInfo().getZoomState().getValue().getMinZoomRatio();
} else {
return UNITY_ZOOM_SCALE;
}
}
public float getMaxZoomRatio() {
if (mCamera != null) {
return mCamera.getCameraInfo().getZoomState().getValue().getMaxZoomRatio();
} else {
return ZOOM_NOT_SUPPORTED;
}
}
public boolean isZoomSupported() {
return getMaxZoomRatio() != ZOOM_NOT_SUPPORTED;
}
// TODO(b/124269166): Rethink how we can handle permissions here.
@SuppressLint("MissingPermission")
private void rebindToLifecycle() {
if (mCurrentLifecycle != null) {
bindToLifecycle(mCurrentLifecycle);
}
}
boolean isBoundToLifecycle() {
return mCamera != null;
}
int getRelativeCameraOrientation(boolean compensateForMirroring) {
int rotationDegrees = 0;
if (mCamera != null) {
rotationDegrees =
mCamera.getCameraInfo().getSensorRotationDegrees(getDisplaySurfaceRotation());
if (compensateForMirroring) {
rotationDegrees = (360 - rotationDegrees) % 360;
}
}
return rotationDegrees;
}
public void invalidateView() {
updateViewInfo();
}
void clearCurrentLifecycle() {
if (mCurrentLifecycle != null && mCameraProvider != null) {
// Remove previous use cases
List<UseCase> toUnbind = new ArrayList<>();
if (mImageCapture != null && mCameraProvider.isBound(mImageCapture)) {
toUnbind.add(mImageCapture);
}
if (mVideoCapture != null && mCameraProvider.isBound(mVideoCapture)) {
toUnbind.add(mVideoCapture);
}
if (mPreview != null && mCameraProvider.isBound(mPreview)) {
toUnbind.add(mPreview);
}
if (!toUnbind.isEmpty()) {
mCameraProvider.unbind(toUnbind.toArray((new UseCase[0])));
}
// Remove surface provider once unbound.
if (mPreview != null) {
mPreview.setSurfaceProvider(null);
}
}
mCamera = null;
mCurrentLifecycle = null;
}
// Update view related information used in use cases
private void updateViewInfo() {
if (mImageCapture != null) {
mImageCapture.setCropAspectRatio(new Rational(getWidth(), getHeight()));
mImageCapture.setTargetRotation(getDisplaySurfaceRotation());
}
if (mVideoCapture != null) {
mVideoCapture.setTargetRotation(getDisplaySurfaceRotation());
}
}
@RequiresPermission(permission.CAMERA)
private Set<Integer> getAvailableCameraLensFacing() {
// Start with all camera directions
Set<Integer> available = new LinkedHashSet<>(Arrays.asList(LensFacingConverter.values()));
// If we're bound to a lifecycle, remove unavailable cameras
if (mCurrentLifecycle != null) {
if (!hasCameraWithLensFacing(CameraSelector.LENS_FACING_BACK)) {
available.remove(CameraSelector.LENS_FACING_BACK);
}
if (!hasCameraWithLensFacing(CameraSelector.LENS_FACING_FRONT)) {
available.remove(CameraSelector.LENS_FACING_FRONT);
}
}
return available;
}
@ImageCapture.FlashMode
public int getFlash() {
return mFlash;
}
// Begin Signal Custom Code Block
public boolean hasFlash() {
if (mImageCapture == null) {
return false;
}
CameraInternal camera = mImageCapture.getCamera();
if (camera == null) {
return false;
}
return camera.getCameraInfoInternal().hasFlashUnit();
}
// End Signal Custom Code Block
public void setFlash(@ImageCapture.FlashMode int flash) {
this.mFlash = flash;
if (mImageCapture == null) {
// Do nothing if there is no imageCapture
return;
}
mImageCapture.setFlashMode(flash);
}
public void enableTorch(boolean torch) {
if (mCamera == null) {
return;
}
ListenableFuture<Void> future = mCamera.getCameraControl().enableTorch(torch);
Futures.addCallback(future, new FutureCallback<Void>() {
@Override
public void onSuccess(@Nullable Void result) {
}
@Override
public void onFailure(Throwable t) {
// Throw the unexpected error.
throw new RuntimeException(t);
}
}, CameraXExecutors.directExecutor());
}
public boolean isTorchOn() {
if (mCamera == null) {
return false;
}
return mCamera.getCameraInfo().getTorchState().getValue() == TorchState.ON;
}
public Context getContext() {
return mCameraView.getContext();
}
public int getWidth() {
return mCameraView.getWidth();
}
public int getHeight() {
return mCameraView.getHeight();
}
public int getDisplayRotationDegrees() {
return CameraOrientationUtil.surfaceRotationToDegrees(getDisplaySurfaceRotation());
}
protected int getDisplaySurfaceRotation() {
return mCameraView.getDisplaySurfaceRotation();
}
private int getMeasuredWidth() {
return mCameraView.getMeasuredWidth();
}
private int getMeasuredHeight() {
return mCameraView.getMeasuredHeight();
}
@Nullable
public Camera getCamera() {
return mCamera;
}
@NonNull
public SignalCameraView.CaptureMode getCaptureMode() {
return mCaptureMode;
}
public void setCaptureMode(@NonNull SignalCameraView.CaptureMode captureMode) {
this.mCaptureMode = captureMode;
rebindToLifecycle();
}
public long getMaxVideoDuration() {
return mMaxVideoDuration;
}
public void setMaxVideoDuration(long duration) {
mMaxVideoDuration = duration;
}
public long getMaxVideoSize() {
return mMaxVideoSize;
}
public void setMaxVideoSize(long size) {
mMaxVideoSize = size;
}
public boolean isPaused() {
return false;
}
}

View File

@@ -0,0 +1,58 @@
package org.signal.glide;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
public final class Log {
private Log() {}
public static void v(@NonNull String tag, @NonNull String message) {
SignalGlideCodecs.getLogProvider().v(tag, message);
}
public static void d(@NonNull String tag, @NonNull String message) {
SignalGlideCodecs.getLogProvider().d(tag, message);
}
public static void i(@NonNull String tag, @NonNull String message) {
SignalGlideCodecs.getLogProvider().i(tag, message);
}
public static void w(@NonNull String tag, @NonNull String message) {
SignalGlideCodecs.getLogProvider().w(tag, message);
}
public static void e(@NonNull String tag, @NonNull String message) {
e(tag, message, null);
}
public static void e(@NonNull String tag, @NonNull String message, @Nullable Throwable throwable) {
SignalGlideCodecs.getLogProvider().e(tag, message, throwable);
}
public interface Provider {
void v(@NonNull String tag, @NonNull String message);
void d(@NonNull String tag, @NonNull String message);
void i(@NonNull String tag, @NonNull String message);
void w(@NonNull String tag, @NonNull String message);
void e(@NonNull String tag, @NonNull String message, @Nullable Throwable throwable);
Provider EMPTY = new Provider() {
@Override
public void v(@NonNull String tag, @NonNull String message) { }
@Override
public void d(@NonNull String tag, @NonNull String message) { }
@Override
public void i(@NonNull String tag, @NonNull String message) { }
@Override
public void w(@NonNull String tag, @NonNull String message) { }
@Override
public void e(@NonNull String tag, @NonNull String message, @NonNull Throwable throwable) { }
};
}
}

View File

@@ -0,0 +1,18 @@
package org.signal.glide;
import androidx.annotation.NonNull;
public final class SignalGlideCodecs {
private static Log.Provider logProvider = Log.Provider.EMPTY;
private SignalGlideCodecs() {}
public static void setLogProvider(@NonNull Log.Provider provider) {
logProvider = provider;
}
public static @NonNull Log.Provider getLogProvider() {
return logProvider;
}
}

View File

@@ -0,0 +1,52 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng;
import android.content.Context;
import org.signal.glide.common.FrameAnimationDrawable;
import org.signal.glide.apng.decode.APNGDecoder;
import org.signal.glide.common.decode.FrameSeqDecoder;
import org.signal.glide.common.loader.AssetStreamLoader;
import org.signal.glide.common.loader.FileLoader;
import org.signal.glide.common.loader.Loader;
import org.signal.glide.common.loader.ResourceStreamLoader;
/**
* @Description: APNGDrawable
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
public class APNGDrawable extends FrameAnimationDrawable<APNGDecoder> {
public APNGDrawable(Loader provider) {
super(provider);
}
public APNGDrawable(APNGDecoder decoder) {
super(decoder);
}
@Override
protected APNGDecoder createFrameSeqDecoder(Loader streamLoader, FrameSeqDecoder.RenderListener listener) {
return new APNGDecoder(streamLoader, listener);
}
public static APNGDrawable fromAsset(Context context, String assetPath) {
AssetStreamLoader assetStreamLoader = new AssetStreamLoader(context, assetPath);
return new APNGDrawable(assetStreamLoader);
}
public static APNGDrawable fromFile(String filePath) {
FileLoader fileLoader = new FileLoader(filePath);
return new APNGDrawable(fileLoader);
}
public static APNGDrawable fromResource(Context context, int resId) {
ResourceStreamLoader resourceStreamLoader = new ResourceStreamLoader(context, resId);
return new APNGDrawable(resourceStreamLoader);
}
}

View File

@@ -0,0 +1,27 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import org.signal.glide.apng.io.APNGReader;
import java.io.IOException;
/**
* @Description: https://developer.mozilla.org/en-US/docs/Mozilla/Tech/APNG#.27acTL.27:_The_Animation_Control_Chunk
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class ACTLChunk extends Chunk {
static final int ID = fourCCToInt("acTL");
int num_frames;
int num_plays;
@Override
void innerParse(APNGReader apngReader) throws IOException {
num_frames = apngReader.readInt();
num_plays = apngReader.readInt();
}
}

View File

@@ -0,0 +1,211 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.PorterDuff;
import android.graphics.Rect;
import org.signal.glide.Log;
import org.signal.glide.apng.io.APNGReader;
import org.signal.glide.apng.io.APNGWriter;
import org.signal.glide.common.decode.Frame;
import org.signal.glide.common.decode.FrameSeqDecoder;
import org.signal.glide.common.io.Reader;
import org.signal.glide.common.loader.Loader;
import java.io.IOException;
import java.nio.ByteBuffer;
import java.util.ArrayList;
import java.util.List;
/**
* @Description: APNG4Android
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class APNGDecoder extends FrameSeqDecoder<APNGReader, APNGWriter> {
private static final String TAG = APNGDecoder.class.getSimpleName();
private APNGWriter apngWriter;
private int mLoopCount;
private final Paint paint = new Paint();
private class SnapShot {
byte dispose_op;
Rect dstRect = new Rect();
ByteBuffer byteBuffer;
}
private SnapShot snapShot = new SnapShot();
/**
* @param loader webp的reader
* @param renderListener 渲染的回调
*/
public APNGDecoder(Loader loader, FrameSeqDecoder.RenderListener renderListener) {
super(loader, renderListener);
paint.setAntiAlias(true);
}
@Override
protected APNGWriter getWriter() {
if (apngWriter == null) {
apngWriter = new APNGWriter();
}
return apngWriter;
}
@Override
protected APNGReader getReader(Reader reader) {
return new APNGReader(reader);
}
@Override
protected int getLoopCount() {
return mLoopCount;
}
@Override
protected void release() {
snapShot.byteBuffer = null;
apngWriter = null;
}
@Override
protected Rect read(APNGReader reader) throws IOException {
List<Chunk> chunks = APNGParser.parse(reader);
List<Chunk> otherChunks = new ArrayList<>();
boolean actl = false;
APNGFrame lastFrame = null;
byte[] ihdrData = new byte[0];
int canvasWidth = 0, canvasHeight = 0;
for (Chunk chunk : chunks) {
if (chunk instanceof ACTLChunk) {
mLoopCount = ((ACTLChunk) chunk).num_plays;
actl = true;
} else if (chunk instanceof FCTLChunk) {
APNGFrame frame = new APNGFrame(reader, (FCTLChunk) chunk);
frame.prefixChunks = otherChunks;
frame.ihdrData = ihdrData;
frames.add(frame);
lastFrame = frame;
} else if (chunk instanceof FDATChunk) {
if (lastFrame != null) {
lastFrame.imageChunks.add(chunk);
}
} else if (chunk instanceof IDATChunk) {
if (!actl) {
//如果为非APNG图片则只解码PNG
Frame frame = new StillFrame(reader);
frame.frameWidth = canvasWidth;
frame.frameHeight = canvasHeight;
frames.add(frame);
mLoopCount = 1;
break;
}
if (lastFrame != null) {
lastFrame.imageChunks.add(chunk);
}
} else if (chunk instanceof IHDRChunk) {
canvasWidth = ((IHDRChunk) chunk).width;
canvasHeight = ((IHDRChunk) chunk).height;
ihdrData = ((IHDRChunk) chunk).data;
} else if (!(chunk instanceof IENDChunk)) {
otherChunks.add(chunk);
}
}
frameBuffer = ByteBuffer.allocate((canvasWidth * canvasHeight / (sampleSize * sampleSize) + 1) * 4);
snapShot.byteBuffer = ByteBuffer.allocate((canvasWidth * canvasHeight / (sampleSize * sampleSize) + 1) * 4);
return new Rect(0, 0, canvasWidth, canvasHeight);
}
@Override
protected void renderFrame(Frame frame) {
if (frame == null || fullRect == null) {
return;
}
try {
Bitmap bitmap = obtainBitmap(fullRect.width() / sampleSize, fullRect.height() / sampleSize);
Canvas canvas = cachedCanvas.get(bitmap);
if (canvas == null) {
canvas = new Canvas(bitmap);
cachedCanvas.put(bitmap, canvas);
}
if (frame instanceof APNGFrame) {
// 从缓存中恢复当前帧
frameBuffer.rewind();
bitmap.copyPixelsFromBuffer(frameBuffer);
// 开始绘制前,处理快照中的设定
if (this.frameIndex == 0) {
canvas.drawColor(Color.TRANSPARENT, PorterDuff.Mode.CLEAR);
} else {
canvas.save();
canvas.clipRect(snapShot.dstRect);
switch (snapShot.dispose_op) {
// 从快照中恢复上一帧之前的显示内容
case FCTLChunk.APNG_DISPOSE_OP_PREVIOUS:
snapShot.byteBuffer.rewind();
bitmap.copyPixelsFromBuffer(snapShot.byteBuffer);
break;
// 清空上一帧所画区域
case FCTLChunk.APNG_DISPOSE_OP_BACKGROUND:
canvas.drawColor(Color.TRANSPARENT, PorterDuff.Mode.CLEAR);
break;
// 什么都不做
case FCTLChunk.APNG_DISPOSE_OP_NON:
default:
break;
}
canvas.restore();
}
// 然后根据dispose设定传递到快照信息中
if (((APNGFrame) frame).dispose_op == FCTLChunk.APNG_DISPOSE_OP_PREVIOUS) {
if (snapShot.dispose_op != FCTLChunk.APNG_DISPOSE_OP_PREVIOUS) {
snapShot.byteBuffer.rewind();
bitmap.copyPixelsToBuffer(snapShot.byteBuffer);
}
}
snapShot.dispose_op = ((APNGFrame) frame).dispose_op;
canvas.save();
if (((APNGFrame) frame).blend_op == FCTLChunk.APNG_BLEND_OP_SOURCE) {
canvas.clipRect(
frame.frameX / sampleSize,
frame.frameY / sampleSize,
(frame.frameX + frame.frameWidth) / sampleSize,
(frame.frameY + frame.frameHeight) / sampleSize);
canvas.drawColor(Color.TRANSPARENT, PorterDuff.Mode.CLEAR);
}
snapShot.dstRect.set(frame.frameX / sampleSize,
frame.frameY / sampleSize,
(frame.frameX + frame.frameWidth) / sampleSize,
(frame.frameY + frame.frameHeight) / sampleSize);
canvas.restore();
}
//开始真正绘制当前帧的内容
Bitmap inBitmap = obtainBitmap(frame.frameWidth, frame.frameHeight);
recycleBitmap(frame.draw(canvas, paint, sampleSize, inBitmap, getWriter()));
recycleBitmap(inBitmap);
frameBuffer.rewind();
bitmap.copyPixelsToBuffer(frameBuffer);
recycleBitmap(bitmap);
} catch (Throwable t) {
Log.e(TAG, "Failed to render!", t);
}
}
}

View File

@@ -0,0 +1,147 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Paint;
import org.signal.glide.apng.io.APNGReader;
import org.signal.glide.apng.io.APNGWriter;
import org.signal.glide.common.decode.Frame;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import java.util.zip.CRC32;
/**
* @Description: APNG4Android
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class APNGFrame extends Frame<APNGReader, APNGWriter> {
public final byte blend_op;
public final byte dispose_op;
byte[] ihdrData;
List<Chunk> imageChunks = new ArrayList<>();
List<Chunk> prefixChunks = new ArrayList<>();
private static final byte[] sPNGSignatures = {(byte) 137, 80, 78, 71, 13, 10, 26, 10};
private static final byte[] sPNGEndChunk = {0, 0, 0, 0, 0x49, 0x45, 0x4E, 0x44, (byte) 0xAE, 0x42, 0x60, (byte) 0x82};
private static ThreadLocal<CRC32> sCRC32 = new ThreadLocal<>();
private CRC32 getCRC32() {
CRC32 crc32 = sCRC32.get();
if (crc32 == null) {
crc32 = new CRC32();
sCRC32.set(crc32);
}
return crc32;
}
public APNGFrame(APNGReader reader, FCTLChunk fctlChunk) {
super(reader);
blend_op = fctlChunk.blend_op;
dispose_op = fctlChunk.dispose_op;
frameDuration = fctlChunk.delay_num * 1000 / (fctlChunk.delay_den == 0 ? 100 : fctlChunk.delay_den);
frameWidth = fctlChunk.width;
frameHeight = fctlChunk.height;
frameX = fctlChunk.x_offset;
frameY = fctlChunk.y_offset;
}
private int encode(APNGWriter apngWriter) throws IOException {
int fileSize = 8 + 13 + 12;
//prefixChunks
for (Chunk chunk : prefixChunks) {
fileSize += chunk.length + 12;
}
//imageChunks
for (Chunk chunk : imageChunks) {
if (chunk instanceof IDATChunk) {
fileSize += chunk.length + 12;
} else if (chunk instanceof FDATChunk) {
fileSize += chunk.length + 8;
}
}
fileSize += sPNGEndChunk.length;
apngWriter.reset(fileSize);
apngWriter.putBytes(sPNGSignatures);
//IHDR Chunk
apngWriter.writeInt(13);
int start = apngWriter.position();
apngWriter.writeFourCC(IHDRChunk.ID);
apngWriter.writeInt(frameWidth);
apngWriter.writeInt(frameHeight);
apngWriter.putBytes(ihdrData);
CRC32 crc32 = getCRC32();
crc32.reset();
crc32.update(apngWriter.toByteArray(), start, 17);
apngWriter.writeInt((int) crc32.getValue());
//prefixChunks
for (Chunk chunk : prefixChunks) {
if (chunk instanceof IENDChunk) {
continue;
}
reader.reset();
reader.skip(chunk.offset);
reader.read(apngWriter.toByteArray(), apngWriter.position(), chunk.length + 12);
apngWriter.skip(chunk.length + 12);
}
//imageChunks
for (Chunk chunk : imageChunks) {
if (chunk instanceof IDATChunk) {
reader.reset();
reader.skip(chunk.offset);
reader.read(apngWriter.toByteArray(), apngWriter.position(), chunk.length + 12);
apngWriter.skip(chunk.length + 12);
} else if (chunk instanceof FDATChunk) {
apngWriter.writeInt(chunk.length - 4);
start = apngWriter.position();
apngWriter.writeFourCC(IDATChunk.ID);
reader.reset();
// skip to fdat data position
reader.skip(chunk.offset + 4 + 4 + 4);
reader.read(apngWriter.toByteArray(), apngWriter.position(), chunk.length - 4);
apngWriter.skip(chunk.length - 4);
crc32.reset();
crc32.update(apngWriter.toByteArray(), start, chunk.length);
apngWriter.writeInt((int) crc32.getValue());
}
}
//endChunk
apngWriter.putBytes(sPNGEndChunk);
return fileSize;
}
@Override
public Bitmap draw(Canvas canvas, Paint paint, int sampleSize, Bitmap reusedBitmap, APNGWriter writer) {
try {
int length = encode(writer);
BitmapFactory.Options options = new BitmapFactory.Options();
options.inJustDecodeBounds = false;
options.inSampleSize = sampleSize;
options.inMutable = true;
options.inBitmap = reusedBitmap;
byte[] bytes = writer.toByteArray();
Bitmap bitmap = BitmapFactory.decodeByteArray(bytes, 0, length, options);
assert bitmap != null;
canvas.drawBitmap(bitmap, (float) frameX / sampleSize, (float) frameY / sampleSize, paint);
return bitmap;
} catch (IOException e) {
e.printStackTrace();
}
return null;
}
}

View File

@@ -0,0 +1,143 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import android.content.Context;
import org.signal.glide.apng.io.APNGReader;
import org.signal.glide.common.io.Reader;
import org.signal.glide.common.io.StreamReader;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.List;
/**
* @link {https://www.w3.org/TR/PNG/#5PNG-file-signature}
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class APNGParser {
static class FormatException extends IOException {
FormatException() {
super("APNG Format error");
}
}
public static boolean isAPNG(String filePath) {
InputStream inputStream = null;
try {
inputStream = new FileInputStream(filePath);
return isAPNG(new StreamReader(inputStream));
} catch (Exception e) {
return false;
} finally {
if (inputStream != null) {
try {
inputStream.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
}
public static boolean isAPNG(Context context, String assetPath) {
InputStream inputStream = null;
try {
inputStream = context.getAssets().open(assetPath);
return isAPNG(new StreamReader(inputStream));
} catch (Exception e) {
return false;
} finally {
if (inputStream != null) {
try {
inputStream.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
}
public static boolean isAPNG(Context context, int resId) {
InputStream inputStream = null;
try {
inputStream = context.getResources().openRawResource(resId);
return isAPNG(new StreamReader(inputStream));
} catch (Exception e) {
return false;
} finally {
if (inputStream != null) {
try {
inputStream.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
}
public static boolean isAPNG(Reader in) {
APNGReader reader = (in instanceof APNGReader) ? (APNGReader) in : new APNGReader(in);
try {
if (!reader.matchFourCC("\u0089PNG") || !reader.matchFourCC("\r\n\u001a\n")) {
throw new FormatException();
}
while (reader.available() > 0) {
Chunk chunk = parseChunk(reader);
if (chunk instanceof ACTLChunk) {
return true;
}
}
} catch (IOException e) {
return false;
}
return false;
}
public static List<Chunk> parse(APNGReader reader) throws IOException {
if (!reader.matchFourCC("\u0089PNG") || !reader.matchFourCC("\r\n\u001a\n")) {
throw new FormatException();
}
List<Chunk> chunks = new ArrayList<>();
while (reader.available() > 0) {
chunks.add(parseChunk(reader));
}
return chunks;
}
private static Chunk parseChunk(APNGReader reader) throws IOException {
int offset = reader.position();
int size = reader.readInt();
int fourCC = reader.readFourCC();
Chunk chunk;
if (fourCC == ACTLChunk.ID) {
chunk = new ACTLChunk();
} else if (fourCC == FCTLChunk.ID) {
chunk = new FCTLChunk();
} else if (fourCC == FDATChunk.ID) {
chunk = new FDATChunk();
} else if (fourCC == IDATChunk.ID) {
chunk = new IDATChunk();
} else if (fourCC == IENDChunk.ID) {
chunk = new IENDChunk();
} else if (fourCC == IHDRChunk.ID) {
chunk = new IHDRChunk();
} else {
chunk = new Chunk();
}
chunk.offset = offset;
chunk.fourcc = fourCC;
chunk.length = size;
chunk.parse(reader);
chunk.crc = reader.readInt();
return chunk;
}
}

View File

@@ -0,0 +1,53 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import android.text.TextUtils;
import org.signal.glide.apng.io.APNGReader;
import java.io.IOException;
/**
* @Description: Length (长度) 4字节 指定数据块中数据域的长度,其长度不超过(2311)字节
* Chunk Type Code (数据块类型码) 4字节 数据块类型码由ASCII字母(A-Z和a-z)组成
* Chunk Data (数据块数据) 可变长度 存储按照Chunk Type Code指定的数据
* CRC (循环冗余检测) 4字节 存储用来检测是否有错误的循环冗余码
* @Link https://www.w3.org/TR/PNG
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class Chunk {
int length;
int fourcc;
int crc;
int offset;
static int fourCCToInt(String fourCC) {
if (TextUtils.isEmpty(fourCC) || fourCC.length() != 4) {
return 0xbadeffff;
}
return (fourCC.charAt(0) & 0xff)
| (fourCC.charAt(1) & 0xff) << 8
| (fourCC.charAt(2) & 0xff) << 16
| (fourCC.charAt(3) & 0xff) << 24
;
}
void parse(APNGReader reader) throws IOException {
int available = reader.available();
innerParse(reader);
int offset = available - reader.available();
if (offset > length) {
throw new IOException("Out of chunk area");
} else if (offset < length) {
reader.skip(length - offset);
}
}
void innerParse(APNGReader reader) throws IOException {
}
}

View File

@@ -0,0 +1,121 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import org.signal.glide.apng.io.APNGReader;
import java.io.IOException;
/**
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
* @see {link=https://developer.mozilla.org/en-US/docs/Mozilla/Tech/APNG#.27fcTL.27:_The_Frame_Control_Chunk}
*/
class FCTLChunk extends Chunk {
static final int ID = fourCCToInt("fcTL");
int sequence_number;
/**
* x_offset >= 0
* y_offset >= 0
* width > 0
* height > 0
* x_offset + width <= 'IHDR' width
* y_offset + height <= 'IHDR' height
*/
/**
* Width of the following frame.
*/
int width;
/**
* Height of the following frame.
*/
int height;
/**
* X position at which to render the following frame.
*/
int x_offset;
/**
* Y position at which to render the following frame.
*/
int y_offset;
/**
* The delay_num and delay_den parameters together specify a fraction indicating the time to
* display the current frame, in seconds. If the denominator is 0, it is to be treated as if it
* were 100 (that is, delay_num then specifies 1/100ths of a second).
* If the the value of the numerator is 0 the decoder should render the next frame as quickly as
* possible, though viewers may impose a reasonable lower bound.
* <p>
* Frame timings should be independent of the time required for decoding and display of each frame,
* so that animations will run at the same rate regardless of the performance of the decoder implementation.
*/
/**
* Frame delay fraction numerator.
*/
short delay_num;
/**
* Frame delay fraction denominator.
*/
short delay_den;
/**
* Type of frame area disposal to be done after rendering this frame.
* dispose_op specifies how the output buffer should be changed at the end of the delay (before rendering the next frame).
* If the first 'fcTL' chunk uses a dispose_op of APNG_DISPOSE_OP_PREVIOUS it should be treated as APNG_DISPOSE_OP_BACKGROUND.
*/
byte dispose_op;
/**
* Type of frame area rendering for this frame.
*/
byte blend_op;
/**
* No disposal is done on this frame before rendering the next; the contents of the output buffer are left as is.
*/
static final int APNG_DISPOSE_OP_NON = 0;
/**
* The frame's region of the output buffer is to be cleared to fully transparent black before rendering the next frame.
*/
static final int APNG_DISPOSE_OP_BACKGROUND = 1;
/**
* The frame's region of the output buffer is to be reverted to the previous contents before rendering the next frame.
*/
static final int APNG_DISPOSE_OP_PREVIOUS = 2;
/**
* blend_op<code> specifies whether the frame is to be alpha blended into the current output buffer content,
* or whether it should completely replace its region in the output buffer.
*/
/**
* All color components of the frame, including alpha, overwrite the current contents of the frame's output buffer region.
*/
static final int APNG_BLEND_OP_SOURCE = 0;
/**
* The frame should be composited onto the output buffer based on its alpha,
* using a simple OVER operation as described in the Alpha Channel Processing section of the Extensions
* to the PNG Specification, Version 1.2.0. Note that the second variation of the sample code is applicable.
*/
static final int APNG_BLEND_OP_OVER = 1;
@Override
void innerParse(APNGReader reader) throws IOException {
sequence_number = reader.readInt();
width = reader.readInt();
height = reader.readInt();
x_offset = reader.readInt();
y_offset = reader.readInt();
delay_num = reader.readShort();
delay_den = reader.readShort();
dispose_op = reader.peek();
blend_op = reader.peek();
}
}

View File

@@ -0,0 +1,25 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import org.signal.glide.apng.io.APNGReader;
import java.io.IOException;
/**
* @Description: https://developer.mozilla.org/en-US/docs/Mozilla/Tech/APNG#.27fdAT.27:_The_Frame_Data_Chunk
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class FDATChunk extends Chunk {
static final int ID = fourCCToInt("fdAT");
int sequence_number;
@Override
void innerParse(APNGReader reader) throws IOException {
sequence_number = reader.readInt();
}
}

View File

@@ -0,0 +1,15 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
/**
* @Description: 作用描述
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class IDATChunk extends Chunk {
static final int ID = fourCCToInt("IDAT");
}

View File

@@ -0,0 +1,15 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
/**
* @Description: 作用描述
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class IENDChunk extends Chunk {
static final int ID = Chunk.fourCCToInt("IEND");
}

View File

@@ -0,0 +1,45 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import org.signal.glide.apng.io.APNGReader;
import java.io.IOException;
/**
* The IHDR chunk shall be the first chunk in the PNG datastream. It contains:
* <p>
* Width 4 bytes
* Height 4 bytes
* Bit depth 1 byte
* Colour type 1 byte
* Compression method 1 byte
* Filter method 1 byte
* Interlace method 1 byte
*
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
class IHDRChunk extends Chunk {
static final int ID = fourCCToInt("IHDR");
/**
* 图像宽度,以像素为单位
*/
int width;
/**
* 图像高度,以像素为单位
*/
int height;
byte[] data = new byte[5];
@Override
void innerParse(APNGReader reader) throws IOException {
width = reader.readInt();
height = reader.readInt();
reader.read(data, 0, data.length);
}
}

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.decode;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Paint;
import org.signal.glide.apng.io.APNGReader;
import org.signal.glide.apng.io.APNGWriter;
import org.signal.glide.common.decode.Frame;
import java.io.IOException;
/**
* @Description: APNG4Android
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class StillFrame extends Frame<APNGReader, APNGWriter> {
public StillFrame(APNGReader reader) {
super(reader);
}
@Override
public Bitmap draw(Canvas canvas, Paint paint, int sampleSize, Bitmap reusedBitmap, APNGWriter writer) {
BitmapFactory.Options options = new BitmapFactory.Options();
options.inJustDecodeBounds = false;
options.inSampleSize = sampleSize;
options.inMutable = true;
options.inBitmap = reusedBitmap;
Bitmap bitmap = null;
try {
reader.reset();
bitmap = BitmapFactory.decodeStream(reader.toInputStream(), null, options);
assert bitmap != null;
paint.setXfermode(null);
canvas.drawBitmap(bitmap, 0, 0, paint);
} catch (IOException e) {
e.printStackTrace();
}
return bitmap;
}
}

View File

@@ -0,0 +1,74 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.io;
import android.text.TextUtils;
import org.signal.glide.common.io.FilterReader;
import org.signal.glide.common.io.Reader;
import java.io.IOException;
/**
* @Description: APNGReader
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class APNGReader extends FilterReader {
private static ThreadLocal<byte[]> __intBytes = new ThreadLocal<>();
protected static byte[] ensureBytes() {
byte[] bytes = __intBytes.get();
if (bytes == null) {
bytes = new byte[4];
__intBytes.set(bytes);
}
return bytes;
}
public APNGReader(Reader in) {
super(in);
}
public int readInt() throws IOException {
byte[] buf = ensureBytes();
read(buf, 0, 4);
return buf[3] & 0xFF |
(buf[2] & 0xFF) << 8 |
(buf[1] & 0xFF) << 16 |
(buf[0] & 0xFF) << 24;
}
public short readShort() throws IOException {
byte[] buf = ensureBytes();
read(buf, 0, 2);
return (short) (buf[1] & 0xFF |
(buf[0] & 0xFF) << 8);
}
/**
* @return read FourCC and match chars
*/
public boolean matchFourCC(String chars) throws IOException {
if (TextUtils.isEmpty(chars) || chars.length() != 4) {
return false;
}
int fourCC = readFourCC();
for (int i = 0; i < 4; i++) {
if (((fourCC >> (i * 8)) & 0xff) != chars.charAt(i)) {
return false;
}
}
return true;
}
public int readFourCC() throws IOException {
byte[] buf = ensureBytes();
read(buf, 0, 4);
return buf[0] & 0xff | (buf[1] & 0xff) << 8 | (buf[2] & 0xff) << 16 | (buf[3] & 0xff) << 24;
}
}

View File

@@ -0,0 +1,41 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.apng.io;
import org.signal.glide.common.io.ByteBufferWriter;
import java.nio.ByteOrder;
/**
* @Description: APNGWriter
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public class APNGWriter extends ByteBufferWriter {
public APNGWriter() {
super();
}
public void writeFourCC(int val) {
putByte((byte) (val & 0xff));
putByte((byte) ((val >> 8) & 0xff));
putByte((byte) ((val >> 16) & 0xff));
putByte((byte) ((val >> 24) & 0xff));
}
public void writeInt(int val) {
putByte((byte) ((val >> 24) & 0xff));
putByte((byte) ((val >> 16) & 0xff));
putByte((byte) ((val >> 8) & 0xff));
putByte((byte) (val & 0xff));
}
@Override
public void reset(int size) {
super.reset(size);
this.byteBuffer.order(ByteOrder.BIG_ENDIAN);
}
}

View File

@@ -0,0 +1,253 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common;
import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.ColorFilter;
import android.graphics.DrawFilter;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.graphics.PaintFlagsDrawFilter;
import android.graphics.PixelFormat;
import android.graphics.drawable.Drawable;
import android.os.Handler;
import android.os.Looper;
import android.os.Message;
import androidx.annotation.NonNull;
import androidx.vectordrawable.graphics.drawable.Animatable2Compat;
import org.signal.glide.Log;
import org.signal.glide.common.decode.FrameSeqDecoder;
import org.signal.glide.common.loader.Loader;
import java.nio.ByteBuffer;
import java.util.HashSet;
import java.util.Set;
/**
* @Description: Frame animation drawable
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
public abstract class FrameAnimationDrawable<Decoder extends FrameSeqDecoder> extends Drawable implements Animatable2Compat, FrameSeqDecoder.RenderListener {
private static final String TAG = FrameAnimationDrawable.class.getSimpleName();
private final Paint paint = new Paint();
private final Decoder frameSeqDecoder;
private DrawFilter drawFilter = new PaintFlagsDrawFilter(0, Paint.ANTI_ALIAS_FLAG | Paint.FILTER_BITMAP_FLAG);
private Matrix matrix = new Matrix();
private Set<AnimationCallback> animationCallbacks = new HashSet<>();
private Bitmap bitmap;
private static final int MSG_ANIMATION_START = 1;
private static final int MSG_ANIMATION_END = 2;
private Handler uiHandler = new Handler(Looper.getMainLooper()) {
@Override
public void handleMessage(Message msg) {
switch (msg.what) {
case MSG_ANIMATION_START:
for (AnimationCallback animationCallback : animationCallbacks) {
animationCallback.onAnimationStart(FrameAnimationDrawable.this);
}
break;
case MSG_ANIMATION_END:
for (AnimationCallback animationCallback : animationCallbacks) {
animationCallback.onAnimationEnd(FrameAnimationDrawable.this);
}
break;
}
}
};
private Runnable invalidateRunnable = new Runnable() {
@Override
public void run() {
invalidateSelf();
}
};
private boolean autoPlay = true;
public FrameAnimationDrawable(Decoder frameSeqDecoder) {
paint.setAntiAlias(true);
this.frameSeqDecoder = frameSeqDecoder;
}
public FrameAnimationDrawable(Loader provider) {
paint.setAntiAlias(true);
this.frameSeqDecoder = createFrameSeqDecoder(provider, this);
}
public void setAutoPlay(boolean autoPlay) {
this.autoPlay = autoPlay;
}
protected abstract Decoder createFrameSeqDecoder(Loader streamLoader, FrameSeqDecoder.RenderListener listener);
/**
* @param loopLimit <=0为无限播放,>0为实际播放次数
*/
public void setLoopLimit(int loopLimit) {
frameSeqDecoder.setLoopLimit(loopLimit);
}
public void reset() {
frameSeqDecoder.reset();
}
public void pause() {
frameSeqDecoder.pause();
}
public void resume() {
frameSeqDecoder.resume();
}
public boolean isPaused() {
return frameSeqDecoder.isPaused();
}
@Override
public void start() {
if (autoPlay) {
frameSeqDecoder.start();
} else {
this.frameSeqDecoder.addRenderListener(this);
if (!this.frameSeqDecoder.isRunning()) {
this.frameSeqDecoder.start();
}
}
}
@Override
public void stop() {
if (autoPlay) {
frameSeqDecoder.stop();
} else {
this.frameSeqDecoder.removeRenderListener(this);
this.frameSeqDecoder.stopIfNeeded();
}
}
@Override
public boolean isRunning() {
return frameSeqDecoder.isRunning();
}
@Override
public void draw(Canvas canvas) {
if (bitmap == null || bitmap.isRecycled()) {
return;
}
canvas.setDrawFilter(drawFilter);
canvas.drawBitmap(bitmap, matrix, paint);
}
@Override
public void setBounds(int left, int top, int right, int bottom) {
super.setBounds(left, top, right, bottom);
boolean sampleSizeChanged = frameSeqDecoder.setDesiredSize(getBounds().width(), getBounds().height());
matrix.setScale(
1.0f * getBounds().width() * frameSeqDecoder.getSampleSize() / frameSeqDecoder.getBounds().width(),
1.0f * getBounds().height() * frameSeqDecoder.getSampleSize() / frameSeqDecoder.getBounds().height());
if (sampleSizeChanged)
this.bitmap = Bitmap.createBitmap(
frameSeqDecoder.getBounds().width() / frameSeqDecoder.getSampleSize(),
frameSeqDecoder.getBounds().height() / frameSeqDecoder.getSampleSize(),
Bitmap.Config.ARGB_8888);
}
@Override
public void setAlpha(int alpha) {
paint.setAlpha(alpha);
}
@Override
public void setColorFilter(ColorFilter colorFilter) {
paint.setColorFilter(colorFilter);
}
@Override
public int getOpacity() {
return PixelFormat.TRANSLUCENT;
}
@Override
public void onStart() {
Message.obtain(uiHandler, MSG_ANIMATION_START).sendToTarget();
}
@Override
public void onRender(ByteBuffer byteBuffer) {
if (!isRunning()) {
return;
}
if (this.bitmap == null || this.bitmap.isRecycled()) {
this.bitmap = Bitmap.createBitmap(
frameSeqDecoder.getBounds().width() / frameSeqDecoder.getSampleSize(),
frameSeqDecoder.getBounds().height() / frameSeqDecoder.getSampleSize(),
Bitmap.Config.ARGB_8888);
}
byteBuffer.rewind();
if (byteBuffer.remaining() < this.bitmap.getByteCount()) {
Log.e(TAG, "onRender:Buffer not large enough for pixels");
return;
}
this.bitmap.copyPixelsFromBuffer(byteBuffer);
uiHandler.post(invalidateRunnable);
}
@Override
public void onEnd() {
Message.obtain(uiHandler, MSG_ANIMATION_END).sendToTarget();
}
@Override
public boolean setVisible(boolean visible, boolean restart) {
if (this.autoPlay) {
if (visible) {
if (!isRunning()) {
start();
}
} else if (isRunning()) {
stop();
}
}
return super.setVisible(visible, restart);
}
@Override
public int getIntrinsicWidth() {
try {
return frameSeqDecoder.getBounds().width();
} catch (Exception exception) {
return 0;
}
}
@Override
public int getIntrinsicHeight() {
try {
return frameSeqDecoder.getBounds().height();
} catch (Exception exception) {
return 0;
}
}
@Override
public void registerAnimationCallback(@NonNull AnimationCallback animationCallback) {
this.animationCallbacks.add(animationCallback);
}
@Override
public boolean unregisterAnimationCallback(@NonNull AnimationCallback animationCallback) {
return this.animationCallbacks.remove(animationCallback);
}
@Override
public void clearAnimationCallbacks() {
this.animationCallbacks.clear();
}
}

View File

@@ -0,0 +1,33 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.decode;
import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Paint;
import org.signal.glide.common.io.Reader;
import org.signal.glide.common.io.Writer;
/**
* @Description: One frame in an animation
* @Author: pengfei.zhou
* @CreateDate: 2019-05-13
*/
public abstract class Frame<R extends Reader, W extends Writer> {
protected final R reader;
public int frameWidth;
public int frameHeight;
public int frameX;
public int frameY;
public int frameDuration;
public Frame(R reader) {
this.reader = reader;
}
public abstract Bitmap draw(Canvas canvas, Paint paint, int sampleSize, Bitmap reusedBitmap, W writer);
}

View File

@@ -0,0 +1,539 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.decode;
import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Rect;
import android.os.Build;
import android.os.Handler;
import android.os.Looper;
import androidx.annotation.Nullable;
import androidx.annotation.WorkerThread;
import org.signal.glide.Log;
import org.signal.glide.common.executor.FrameDecoderExecutor;
import org.signal.glide.common.io.Reader;
import org.signal.glide.common.io.Writer;
import org.signal.glide.common.loader.Loader;
import java.io.IOException;
import java.nio.ByteBuffer;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.WeakHashMap;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.locks.LockSupport;
/**
* @Description: Abstract Frame Animation Decoder
* @Author: pengfei.zhou
* @CreateDate: 2019/3/27
*/
public abstract class FrameSeqDecoder<R extends Reader, W extends Writer> {
private static final String TAG = FrameSeqDecoder.class.getSimpleName();
private final int taskId;
private final Loader mLoader;
private final Handler workerHandler;
protected List<Frame> frames = new ArrayList<>();
protected int frameIndex = -1;
private int playCount;
private Integer loopLimit = null;
private Set<RenderListener> renderListeners = new HashSet<>();
private AtomicBoolean paused = new AtomicBoolean(true);
private static final Rect RECT_EMPTY = new Rect();
private Runnable renderTask = new Runnable() {
@Override
public void run() {
if (paused.get()) {
return;
}
if (canStep()) {
long start = System.currentTimeMillis();
long delay = step();
long cost = System.currentTimeMillis() - start;
workerHandler.postDelayed(this, Math.max(0, delay - cost));
for (RenderListener renderListener : renderListeners) {
renderListener.onRender(frameBuffer);
}
} else {
stop();
}
}
};
protected int sampleSize = 1;
private Set<Bitmap> cacheBitmaps = new HashSet<>();
protected Map<Bitmap, Canvas> cachedCanvas = new WeakHashMap<>();
protected ByteBuffer frameBuffer;
protected volatile Rect fullRect;
private W mWriter = getWriter();
private R mReader = null;
/**
* If played all the needed
*/
private boolean finished = false;
private enum State {
IDLE,
RUNNING,
INITIALIZING,
FINISHING,
}
private volatile State mState = State.IDLE;
public Loader getLoader() {
return mLoader;
}
protected abstract W getWriter();
protected abstract R getReader(Reader reader);
protected Bitmap obtainBitmap(int width, int height) {
Bitmap ret = null;
Iterator<Bitmap> iterator = cacheBitmaps.iterator();
while (iterator.hasNext()) {
int reuseSize = width * height * 4;
ret = iterator.next();
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
if (ret != null && ret.getAllocationByteCount() >= reuseSize) {
iterator.remove();
if (ret.getWidth() != width || ret.getHeight() != height) {
ret.reconfigure(width, height, Bitmap.Config.ARGB_8888);
}
ret.eraseColor(0);
return ret;
}
} else {
if (ret != null && ret.getByteCount() >= reuseSize) {
if (ret.getWidth() == width && ret.getHeight() == height) {
iterator.remove();
ret.eraseColor(0);
}
return ret;
}
}
}
try {
Bitmap.Config config = Bitmap.Config.ARGB_8888;
ret = Bitmap.createBitmap(width, height, config);
} catch (OutOfMemoryError e) {
e.printStackTrace();
}
return ret;
}
protected void recycleBitmap(Bitmap bitmap) {
if (bitmap != null && !cacheBitmaps.contains(bitmap)) {
cacheBitmaps.add(bitmap);
}
}
/**
* 解码器的渲染回调
*/
public interface RenderListener {
/**
* 播放开始
*/
void onStart();
/**
* 帧播放
*/
void onRender(ByteBuffer byteBuffer);
/**
* 播放结束
*/
void onEnd();
}
/**
* @param loader webp的reader
* @param renderListener 渲染的回调
*/
public FrameSeqDecoder(Loader loader, @Nullable RenderListener renderListener) {
this.mLoader = loader;
if (renderListener != null) {
this.renderListeners.add(renderListener);
}
this.taskId = FrameDecoderExecutor.getInstance().generateTaskId();
this.workerHandler = new Handler(FrameDecoderExecutor.getInstance().getLooper(taskId));
}
public void addRenderListener(final RenderListener renderListener) {
this.workerHandler.post(new Runnable() {
@Override
public void run() {
renderListeners.add(renderListener);
}
});
}
public void removeRenderListener(final RenderListener renderListener) {
this.workerHandler.post(new Runnable() {
@Override
public void run() {
renderListeners.remove(renderListener);
}
});
}
public void stopIfNeeded() {
this.workerHandler.post(new Runnable() {
@Override
public void run() {
if (renderListeners.size() == 0) {
stop();
}
}
});
}
public Rect getBounds() {
if (fullRect == null) {
if (mState == State.FINISHING) {
Log.e(TAG, "In finishing,do not interrupt");
}
final Thread thread = Thread.currentThread();
workerHandler.post(new Runnable() {
@Override
public void run() {
try {
if (fullRect == null) {
if (mReader == null) {
mReader = getReader(mLoader.obtain());
} else {
mReader.reset();
}
initCanvasBounds(read(mReader));
}
} catch (Exception e) {
e.printStackTrace();
fullRect = RECT_EMPTY;
} finally {
LockSupport.unpark(thread);
}
}
});
LockSupport.park(thread);
}
return fullRect;
}
private void initCanvasBounds(Rect rect) {
fullRect = rect;
frameBuffer = ByteBuffer.allocate((rect.width() * rect.height() / (sampleSize * sampleSize) + 1) * 4);
if (mWriter == null) {
mWriter = getWriter();
}
}
private int getFrameCount() {
return this.frames.size();
}
/**
* @return Loop Count defined in file
*/
protected abstract int getLoopCount();
public void start() {
if (fullRect == RECT_EMPTY) {
return;
}
if (mState == State.RUNNING || mState == State.INITIALIZING) {
Log.i(TAG, debugInfo() + " Already started");
return;
}
if (mState == State.FINISHING) {
Log.e(TAG, debugInfo() + " Processing,wait for finish at " + mState);
}
mState = State.INITIALIZING;
if (Looper.myLooper() == workerHandler.getLooper()) {
innerStart();
} else {
workerHandler.post(new Runnable() {
@Override
public void run() {
innerStart();
}
});
}
}
@WorkerThread
private void innerStart() {
paused.compareAndSet(true, false);
final long start = System.currentTimeMillis();
try {
if (frames.size() == 0) {
try {
if (mReader == null) {
mReader = getReader(mLoader.obtain());
} else {
mReader.reset();
}
initCanvasBounds(read(mReader));
} catch (Throwable e) {
e.printStackTrace();
}
}
} finally {
Log.i(TAG, debugInfo() + " Set state to RUNNING,cost " + (System.currentTimeMillis() - start));
mState = State.RUNNING;
}
if (getNumPlays() == 0 || !finished) {
this.frameIndex = -1;
renderTask.run();
for (RenderListener renderListener : renderListeners) {
renderListener.onStart();
}
} else {
Log.i(TAG, debugInfo() + " No need to started");
}
}
@WorkerThread
private void innerStop() {
workerHandler.removeCallbacks(renderTask);
frames.clear();
for (Bitmap bitmap : cacheBitmaps) {
if (bitmap != null && !bitmap.isRecycled()) {
bitmap.recycle();
}
}
cacheBitmaps.clear();
if (frameBuffer != null) {
frameBuffer = null;
}
cachedCanvas.clear();
try {
if (mReader != null) {
mReader.close();
mReader = null;
}
if (mWriter != null) {
mWriter.close();
}
} catch (IOException e) {
e.printStackTrace();
}
release();
mState = State.IDLE;
for (RenderListener renderListener : renderListeners) {
renderListener.onEnd();
}
}
public void stop() {
if (fullRect == RECT_EMPTY) {
return;
}
if (mState == State.FINISHING || mState == State.IDLE) {
Log.i(TAG, debugInfo() + "No need to stop");
return;
}
if (mState == State.INITIALIZING) {
Log.e(TAG, debugInfo() + "Processing,wait for finish at " + mState);
}
mState = State.FINISHING;
if (Looper.myLooper() == workerHandler.getLooper()) {
innerStop();
} else {
workerHandler.post(new Runnable() {
@Override
public void run() {
innerStop();
}
});
}
}
private String debugInfo() {
return "";
}
protected abstract void release();
public boolean isRunning() {
return mState == State.RUNNING || mState == State.INITIALIZING;
}
public boolean isPaused() {
return paused.get();
}
public void setLoopLimit(int limit) {
this.loopLimit = limit;
}
public void reset() {
this.playCount = 0;
this.frameIndex = -1;
this.finished = false;
}
public void pause() {
workerHandler.removeCallbacks(renderTask);
paused.compareAndSet(false, true);
}
public void resume() {
paused.compareAndSet(true, false);
workerHandler.removeCallbacks(renderTask);
workerHandler.post(renderTask);
}
public int getSampleSize() {
return sampleSize;
}
public boolean setDesiredSize(int width, int height) {
boolean sampleSizeChanged = false;
int sample = getDesiredSample(width, height);
if (sample != this.sampleSize) {
this.sampleSize = sample;
sampleSizeChanged = true;
final boolean tempRunning = isRunning();
workerHandler.removeCallbacks(renderTask);
workerHandler.post(new Runnable() {
@Override
public void run() {
innerStop();
try {
initCanvasBounds(read(getReader(mLoader.obtain())));
if (tempRunning) {
innerStart();
}
} catch (IOException e) {
e.printStackTrace();
}
}
});
}
return sampleSizeChanged;
}
protected int getDesiredSample(int desiredWidth, int desiredHeight) {
if (desiredWidth == 0 || desiredHeight == 0) {
return 1;
}
int radio = Math.min(getBounds().width() / desiredWidth, getBounds().height() / desiredHeight);
int sample = 1;
while ((sample * 2) <= radio) {
sample *= 2;
}
return sample;
}
protected abstract Rect read(R reader) throws IOException;
private int getNumPlays() {
return this.loopLimit != null ? this.loopLimit : this.getLoopCount();
}
private boolean canStep() {
if (!isRunning()) {
return false;
}
if (frames.size() == 0) {
return false;
}
if (getNumPlays() <= 0) {
return true;
}
if (this.playCount < getNumPlays() - 1) {
return true;
} else if (this.playCount == getNumPlays() - 1 && this.frameIndex < this.getFrameCount() - 1) {
return true;
}
finished = true;
return false;
}
@WorkerThread
private long step() {
this.frameIndex++;
if (this.frameIndex >= this.getFrameCount()) {
this.frameIndex = 0;
this.playCount++;
}
Frame frame = getFrame(this.frameIndex);
if (frame == null) {
return 0;
}
renderFrame(frame);
return frame.frameDuration;
}
protected abstract void renderFrame(Frame frame);
private Frame getFrame(int index) {
if (index < 0 || index >= frames.size()) {
return null;
}
return frames.get(index);
}
/**
* Get Indexed frame
*
* @param index <0 means reverse from last index
*/
public Bitmap getFrameBitmap(int index) throws IOException {
if (mState != State.IDLE) {
Log.e(TAG, debugInfo() + ",stop first");
return null;
}
mState = State.RUNNING;
paused.compareAndSet(true, false);
if (frames.size() == 0) {
if (mReader == null) {
mReader = getReader(mLoader.obtain());
} else {
mReader.reset();
}
initCanvasBounds(read(mReader));
}
if (index < 0) {
index += this.frames.size();
}
if (index < 0) {
index = 0;
}
frameIndex = -1;
while (frameIndex < index) {
if (canStep()) {
step();
} else {
break;
}
}
frameBuffer.rewind();
Bitmap bitmap = Bitmap.createBitmap(getBounds().width() / getSampleSize(), getBounds().height() / getSampleSize(), Bitmap.Config.ARGB_8888);
bitmap.copyPixelsFromBuffer(frameBuffer);
innerStop();
return bitmap;
}
}

View File

@@ -0,0 +1,70 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.executor;
import android.os.HandlerThread;
import android.os.Looper;
import java.util.ArrayList;
import java.util.concurrent.atomic.AtomicInteger;
/**
* @Description: com.github.penfeizhou.animation.executor
* @Author: pengfei.zhou
* @CreateDate: 2019-11-21
*/
public class FrameDecoderExecutor {
private static int sPoolNumber = 4;
private ArrayList<HandlerThread> mHandlerThreadGroup = new ArrayList<>();
private AtomicInteger counter = new AtomicInteger(0);
private FrameDecoderExecutor() {
}
static class Inner {
static final FrameDecoderExecutor sInstance = new FrameDecoderExecutor();
}
public void setPoolSize(int size) {
sPoolNumber = size;
}
public static FrameDecoderExecutor getInstance() {
return Inner.sInstance;
}
public Looper getLooper(int taskId) {
int idx = taskId % sPoolNumber;
if (idx >= mHandlerThreadGroup.size()) {
HandlerThread handlerThread = new HandlerThread("FrameDecoderExecutor-" + idx);
handlerThread.start();
mHandlerThreadGroup.add(handlerThread);
Looper looper = handlerThread.getLooper();
if (looper != null) {
return looper;
} else {
return Looper.getMainLooper();
}
} else {
if (mHandlerThreadGroup.get(idx) != null) {
Looper looper = mHandlerThreadGroup.get(idx).getLooper();
if (looper != null) {
return looper;
} else {
return Looper.getMainLooper();
}
} else {
return Looper.getMainLooper();
}
}
}
public int generateTaskId() {
return counter.getAndIncrement();
}
}

View File

@@ -0,0 +1,67 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.nio.ByteBuffer;
/**
* @Description: APNG4Android
* @Author: pengfei.zhou
* @CreateDate: 2019-05-14
*/
public class ByteBufferReader implements Reader {
private final ByteBuffer byteBuffer;
public ByteBufferReader(ByteBuffer byteBuffer) {
this.byteBuffer = byteBuffer;
byteBuffer.position(0);
}
@Override
public long skip(long total) throws IOException {
byteBuffer.position((int) (byteBuffer.position() + total));
return total;
}
@Override
public byte peek() throws IOException {
return byteBuffer.get();
}
@Override
public void reset() throws IOException {
byteBuffer.position(0);
}
@Override
public int position() {
return byteBuffer.position();
}
@Override
public int read(byte[] buffer, int start, int byteCount) throws IOException {
byteBuffer.get(buffer, start, byteCount);
return byteCount;
}
@Override
public int available() throws IOException {
return byteBuffer.limit() - byteBuffer.position();
}
@Override
public void close() throws IOException {
}
@Override
public InputStream toInputStream() throws IOException {
return new ByteArrayInputStream(byteBuffer.array());
}
}

View File

@@ -0,0 +1,61 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.nio.ByteBuffer;
import java.nio.ByteOrder;
/**
* @Description: ByteBufferWriter
* @Author: pengfei.zhou
* @CreateDate: 2019-05-12
*/
public class ByteBufferWriter implements Writer {
protected ByteBuffer byteBuffer;
public ByteBufferWriter() {
reset(10 * 1024);
}
@Override
public void putByte(byte b) {
byteBuffer.put(b);
}
@Override
public void putBytes(byte[] b) {
byteBuffer.put(b);
}
@Override
public int position() {
return byteBuffer.position();
}
@Override
public void skip(int length) {
byteBuffer.position(length + position());
}
@Override
public byte[] toByteArray() {
return byteBuffer.array();
}
@Override
public void close() {
}
@Override
public void reset(int size) {
if (byteBuffer == null || size > byteBuffer.capacity()) {
byteBuffer = ByteBuffer.allocate(size);
this.byteBuffer.order(ByteOrder.LITTLE_ENDIAN);
}
byteBuffer.clear();
}
}

View File

@@ -0,0 +1,30 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
/**
* @Description: FileReader
* @Author: pengfei.zhou
* @CreateDate: 2019-05-23
*/
public class FileReader extends FilterReader {
private final File mFile;
public FileReader(File file) throws IOException {
super(new StreamReader(new FileInputStream(file)));
mFile = file;
}
@Override
public void reset() throws IOException {
reader.close();
reader = new StreamReader(new FileInputStream(mFile));
}
}

View File

@@ -0,0 +1,63 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.IOException;
import java.io.InputStream;
/**
* @Description: FilterReader
* @Author: pengfei.zhou
* @CreateDate: 2019-05-23
*/
public class FilterReader implements Reader {
protected Reader reader;
public FilterReader(Reader in) {
this.reader = in;
}
@Override
public long skip(long total) throws IOException {
return reader.skip(total);
}
@Override
public byte peek() throws IOException {
return reader.peek();
}
@Override
public void reset() throws IOException {
reader.reset();
}
@Override
public int position() {
return reader.position();
}
@Override
public int read(byte[] buffer, int start, int byteCount) throws IOException {
return reader.read(buffer, start, byteCount);
}
@Override
public int available() throws IOException {
return reader.available();
}
@Override
public void close() throws IOException {
reader.close();
}
@Override
public InputStream toInputStream() throws IOException {
reset();
return reader.toInputStream();
}
}

View File

@@ -0,0 +1,35 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.IOException;
import java.io.InputStream;
/**
* @link {https://developers.google.com/speed/webp/docs/riff_container#terminology_basics}
* @Author: pengfei.zhou
* @CreateDate: 2019-05-11
*/
public interface Reader {
long skip(long total) throws IOException;
byte peek() throws IOException;
void reset() throws IOException;
int position();
int read(byte[] buffer, int start, int byteCount) throws IOException;
int available() throws IOException;
/**
* close io
*/
void close() throws IOException;
InputStream toInputStream() throws IOException;
}

View File

@@ -0,0 +1,64 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.FilterInputStream;
import java.io.IOException;
import java.io.InputStream;
/**
* @Author: pengfei.zhou
* @CreateDate: 2019-05-11
*/
public class StreamReader extends FilterInputStream implements Reader {
private int position;
public StreamReader(InputStream in) {
super(in);
try {
in.reset();
} catch (IOException e) {
// e.printStackTrace();
}
}
@Override
public byte peek() throws IOException {
byte ret = (byte) read();
position++;
return ret;
}
@Override
public int read(byte[] b, int off, int len) throws IOException {
int ret = super.read(b, off, len);
position += Math.max(0, ret);
return ret;
}
@Override
public synchronized void reset() throws IOException {
super.reset();
position = 0;
}
@Override
public long skip(long n) throws IOException {
long ret = super.skip(n);
position += ret;
return ret;
}
@Override
public int position() {
return position;
}
@Override
public InputStream toInputStream() throws IOException {
return this;
}
}

View File

@@ -0,0 +1,29 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.io;
import java.io.IOException;
/**
* @Description: APNG4Android
* @Author: pengfei.zhou
* @CreateDate: 2019-05-12
*/
public interface Writer {
void reset(int size);
void putByte(byte b);
void putBytes(byte[] b);
int position();
void skip(int length);
byte[] toByteArray();
void close() throws IOException;
}

View File

@@ -0,0 +1,32 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.loader;
import android.content.Context;
import java.io.IOException;
import java.io.InputStream;
/**
* @Description: 从Asset中读取流
* @Author: pengfei.zhou
* @CreateDate: 2019/3/28
*/
public class AssetStreamLoader extends StreamLoader {
private final Context mContext;
private final String mAssetName;
public AssetStreamLoader(Context context, String assetName) {
mContext = context.getApplicationContext();
mAssetName = assetName;
}
@Override
protected InputStream getInputStream() throws IOException {
return mContext.getAssets().open(mAssetName);
}
}

View File

@@ -0,0 +1,26 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.loader;
import org.signal.glide.common.io.ByteBufferReader;
import org.signal.glide.common.io.Reader;
import java.io.IOException;
import java.nio.ByteBuffer;
/**
* @Description: ByteBufferLoader
* @Author: pengfei.zhou
* @CreateDate: 2019-05-15
*/
public abstract class ByteBufferLoader implements Loader {
public abstract ByteBuffer getByteBuffer();
@Override
public Reader obtain() throws IOException {
return new ByteBufferReader(getByteBuffer());
}
}

View File

@@ -0,0 +1,32 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.loader;
import org.signal.glide.common.io.FileReader;
import org.signal.glide.common.io.Reader;
import java.io.File;
import java.io.IOException;
/**
* @Description: 从文件加载流
* @Author: pengfei.zhou
* @CreateDate: 2019/3/28
*/
public class FileLoader implements Loader {
private final File mFile;
private Reader mReader;
public FileLoader(String path) {
mFile = new File(path);
}
@Override
public synchronized Reader obtain() throws IOException {
return new FileReader(mFile);
}
}

View File

@@ -0,0 +1,19 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.loader;
import org.signal.glide.common.io.Reader;
import java.io.IOException;
/**
* @Description: Loader
* @Author: pengfei.zhou
* @CreateDate: 2019-05-14
*/
public interface Loader {
Reader obtain() throws IOException;
}

View File

@@ -0,0 +1,32 @@
/*
* Copyright 2019 Zhou Pengfei
* SPDX-License-Identifier: Apache-2.0
*/
package org.signal.glide.common.loader;
import android.content.Context;
import java.io.IOException;
import java.io.InputStream;
/**
* @Description: 从资源加载流
* @Author: pengfei.zhou
* @CreateDate: 2019/3/28
*/
public class ResourceStreamLoader extends StreamLoader {
private final Context mContext;
private final int mResId;
public ResourceStreamLoader(Context context, int resId) {
mContext = context.getApplicationContext();
mResId = resId;
}
@Override
protected InputStream getInputStream() throws IOException {
return mContext.getResources().openRawResource(mResId);
}
}

Some files were not shown because too many files have changed in this diff Show More