Commit Graph

139 Commits

Author SHA1 Message Date
str4d
c5708ee3ce Add a UI for changing the password 2016-06-11 22:49:45 +00:00
Torsten Grote
1a1dd80810 Merge branch '408-forum-list-unread-posts-badges' into 'master'
Adds badges to the forum list that indicate unread posts

This MR adds  badges to the forum list that indicate unread posts. It does so by extending the compound view `TextAvatarView` and provides convenient setters that take care of the required UI changes. The new badge can also be used to indicate a problem with the forum.

![device-2016-06-02-134048](/uploads/133f365f5654be304f590a4f5b667d06/device-2016-06-02-134048.png)![device-2016-06-02-134453](/uploads/423a88f6306a558828181f0c539aa1cb/device-2016-06-02-134453.png)

I decided not to check if the forum is shared from someone or with someone and indicate a problem in this case, because this requires iterating two times over all contacts and their group metadata for each forum. If someone considers it important to check for this information, we can create a ticket for doing this within the forum and not in the forum list.

See merge request !207
2016-06-07 14:36:42 +00:00
Torsten Grote
3f838b0472 Blog Fragment in Navigation Drawer with Tabs
This replaces the custom layouts in the navigation drawer with a
`NavigationView` and adds a menu entry for Blogs.

A Main Blogs fragment is added that holds a `TabLayout` and a
`ViewPager`. Five tabs are already added, but they just have a single
placeholder fragment that is to be replaced by the actual fragments.

Closes #409
2016-06-03 13:51:31 -03:00
Torsten Grote
5d06f42000 This commit adds badges to the forum list that indicate unread posts.
It does so by extending the compound view `TextAvatarView` and provides
convienient setters that take care of the required UI changes.
The new badge can also be used to indicate a problem with the forum.

Closes #408
2016-06-03 12:44:03 -03:00
Ernir Erlingsson
86039b81c0 Forum, nested discussions front end UI/UX, rev 2 2016-05-30 23:57:01 +02:00
Torsten Grote
b13bf66165 Add a new activity that shows sharing status of forum
The new activity shows who you are sharing a forum with and who shares a
forum with you. It is accessible from the overflow menu when in a forum.

Closes #398
2016-05-19 11:42:05 -03:00
akwizgran
1724fbe5a9 Merge branch '121-new-forum-sharing-ui' into 'master'
Forum Sharing Client UI

This changes `ShareForumActivity` to use two fragments to facilitate
forum sharing with the new Forum Sharing Client backend.

The `ContactSelectorFragment` allows the user to select a
number of contacts. If there is an ongoing sharing session or the forum
is already shared with the contact, it is disabled in the list. If there
is at least one contact selected, a button appears in the toolbar that
brings the user to the `ShareForumMessageFragment` where the user can
write an optional message to be send along with the invitation.

After sending an invitation, the user is brought back to the forum that
she shared and there is a snackbar showing up briefly to indicate the
successful invitation.

The invitation is shown along with the message within the private
conversation of each contact. The person who shares the forum also sees
the invitation and the message as outgoing messages that also display
the current status of the messages.

A notification is shown like for other private messages as well.

Please note that this commit does not include a way for users to respond
to invitations. This is in MR !172. Both MRs are based on the new backend in !170.

![device-2016-05-03-182928](/uploads/48499ca4c149a8e7f13f8b28a24537ad/device-2016-05-03-182928.png)
![device-2016-05-03-182855](/uploads/5f49c43bf8f39780862247848a5b9c27/device-2016-05-03-182855.png)

See merge request !171
2016-05-11 09:13:07 +00:00
Torsten Grote
3a9d66a85f Forum Sharing Client UI
This changes `ShareForumActivity` to use two fragments to facilitate
forum sharing with the new Forum Sharing Client backend.

The `ContactSelectorFragment` allows the user to select a
number of contacts. If there is an ongoing sharing session or the forum
is already shared with the contact, it is disabled in the list. If there
is at least one contact selected, a button appears in the toolbar that
brings the user to the `ShareForumMessageFragment` where the user can
write an optional message to be send along with the invitation.

After sending an invitation, the user is brought back to the forum that
she shared and there is a snackbar showing up briefly to indicate the
successful invitation.

The invitation is shown along with the message within the private
conversation of each contact. The person who shares the forum also sees
the invitation and the message as outgoing messages that also display
the current status of the messages.

A notification is shown like for other private messages as well.

Please note that this commit does not include a way for users to respond
to invitations.
2016-05-10 21:04:08 -03:00
Torsten Grote
bcfdd848a4 Modernize AvailableForumsActivity
Turn list of available forums into a BriarRecyclerView with XML layout.
Allow to respond to forum invitations from the list of available forums.
The user can either accept or decline an invitation.
2016-05-10 20:07:42 -03:00
Torsten Grote
271e390b9d New List of Forums
The adapter of the `ForumListFragment` has been changed into a
`BriarRecyclerView` and all its code has been adapted and simplified
accordingly.

All UI of the forum list is now defined in XML layouts.
2016-05-04 18:07:12 -03:00
akwizgran
5a84e0fe5c Added "Touch to open Briar" to ongoing notification. 2016-05-04 09:32:47 +01:00
akwizgran
5fab9c383d Updated forum toasts and renamed delete icon. 2016-05-03 16:21:26 +01:00
akwizgran
da60e567e0 Merge branch '305-remove-forum' into 'master'
Move forum removal action from long press menu to action bar

This is part of the UI changes for #305 

See merge request !164
2016-05-03 15:02:01 +00:00
Torsten Grote
684898ef09 Move forum removal action from long press menu to action bar
part of UI changes for #305
2016-05-03 12:00:09 -03:00
akwizgran
3b65144ff6 Merge branch '154-ongoing-notification' into 'master'
Set ongoing notification to minimum priority

Setting the priority of the ongoing notification to PRIORITY_MIN prevents it from being shown in the status bar on Android 4.1 and later. The service still runs in the foreground.

Thanks to @str4d for finding the solution. Closes #154.

See merge request !169
2016-05-03 14:59:19 +00:00
Torsten Grote
9f9a216305 Prepare for new Forum Sharing Client
Methods for creating, adding and removing forums have been moved to the
`ForumManager`. In order to still handle removing forums properly, a
`RemoveForumHook` has been introduced.

Methods for sharing forums with all current and future contacts have
been removed along with the localGroup where this information was saved.

The `ShareForumActivity` now has the proper label.

The `SessionId` and the `ProtocolEngine` have been moved to the
`clients` package.

This addresses part of #322 and part of what has been discussed in #320.
2016-05-03 11:48:45 -03:00
akwizgran
25b165ac1e Set ongoing notification to minimum priority. #154 2016-05-03 14:14:15 +01:00
Torsten Grote
82e1ef0ea6 Add Snackbar and Toolbar Button to Forum List
This commit is a small change that replaces the custom UI elements in
the forum list with a Snackbar and an Toolbar menu.

Addresses one part (2b) of #305
2016-05-02 13:00:19 -03:00
akwizgran
c72e5be804 Removed old user feedback activity. #336 2016-04-29 22:54:37 +01:00
str4d
c44b6a4095 Implement encrypted feedback 2016-04-28 16:44:01 +12:00
str4d
f73f0aa4ab Migrate crash reports to ACRA 2016-04-27 22:22:16 +12:00
akwizgran
3200a9f8f8 Merge branch '313-move-forum-buttons-to-toolbar' into 'master'
Move create forum post and share forum buttons in action bar

According to the designs in #305, the 'create forum post' and 'share forum' buttons will go into the in action bar.

In the spirit of keeping MRs small and to avoid conflicts with #306, I did this first and independently of future work.

This also introduces constants for the `GROUP_ID`, `FORUM_NAME` and `MIN_TIMESTAMP` as they were used for the two buttons.

Closes #313

See merge request !150
2016-04-25 13:57:14 +00:00
akwizgran
3b8689f892 Tweaked introduction wording, use Collections.emptyList(). 2016-04-25 13:14:22 +01:00
akwizgran
7779319f9a Merge branch '295-show-declined-introductions' into 'master'
Show relevant introduction decline responses in the conversation

* If the user has already declined, we don't show that the other
  introducee has declined as well. The backend doesn't have that information, so
  this is compatible with the principle of showing what we know.
* If the user has already accepted or hasn't yet responded, we now show the
  decline response in the private conversation with the introducer. If
  the user hasn't yet responded, we hide the accept/decline buttons
  in the introduction request message.

Please note that I do not have three devices at the moment to test this MR in its entirety in practice. I created another test which is hopefully sufficient to ensure that the modifications are correct.

Closes #295 

See merge request !149
2016-04-25 12:07:13 +00:00
Torsten Grote
44b3d4c14f Move create forum post and share forum buttons in action bar
This also introduces constants for the GROUP_ID, FORUM_NAME and
MIN_TIMESTAMP as they were used for the two buttons.

Closes #313
2016-04-21 12:06:42 -03:00
Torsten Grote
11e6d64e4d Show relevant decline responses in the conversation
* If the user has already declined, we don't show that the other
  introducee has declined as well. The backend doesn't have that information, so
  this is compatible with the principle of showing what we know.
* If the user has already accepted or hasn't yet responded, we show the
  decline response in the private conversation with the introducer. If
  the user hasn't yet responded, we hide the accept/decline buttons
  in the introduction request message.

Messages an introducee receives in a `FINISHED` state are now being
ignored and deleted.

Closes #295
2016-04-21 11:08:15 -03:00
str4d
d545aaa892 Encrypt and save crash reports, send them the next time TorPlugin start
Will currently fail at runtime; requires a public key and a server onion.
2016-04-20 23:42:46 +00:00
Torsten Grote
d0036deaf7 This addresses two types of introduction corner cases:
* force decline when two of our own identities are introduced to each
  other
* throw away introduction requests to the same identity
  (impossible to trigger from UI)

Closes #284
2016-04-20 11:31:54 -03:00
Torsten Grote
c5bfea2155 address issues found in final review
(except refactoring of conversation item classes)
2016-04-12 17:04:52 -03:00
Torsten Grote
90d984ee52 Ensure responses shown after requests, clarify wording, reuse transactions
When devices' clocks are out of sync, it is possible that a response is
shown before the request. This commit makes sure that the timestamp of
responses is always later than the last message in the conversation.

Some wording could be misunderstood to thing introductions were
successful even though they were not. That has been clarified.

A new database transaction was created when getting contacts and local
transport properties. This has been changed to re-use the existing
transaction.

Also addresses minor issues found in review.
2016-04-12 17:04:52 -03:00
Torsten Grote
5ea7ff2857 UI for introducing two contacts to each other
Show system notification for successful introductions
2016-04-12 17:04:52 -03:00
str4d
8cacc73bef Implement BQP Android UI using QR codes 2016-03-26 15:53:09 +13:00
str4d
770d9ddc5f Migrate settings to PreferenceFragmentCompat
Includes code from https://github.com/consp1racy/android-support-preference
License: Apache License v2.0
2016-03-11 21:06:06 +00:00
akwizgran
4decdbf3e6 Giant whitespace-only indentation patch. 2016-02-05 14:54:17 +00:00
Ernir Erlingsson
dae29eecce Navigation drawer (squashed and rebased). 2016-01-21 16:49:21 +00:00
Torsten Grote
8b817be076 Offer option to uninstall Briar in a panic event
Due to the nature of how Android app install/uninstall works without
root, this requires manual confirmation after a panic was triggered.

Closes #211
2016-01-18 14:31:10 -02:00
akwizgran
42d1f6ded0 Use verbs instead of yes/no for lost password dialog. 2016-01-13 17:17:45 +00:00
akwizgran
d8c65d0029 Capitalise panic button header, tweak wording. 2016-01-13 15:32:11 +00:00
Torsten Grote
e603b4f60e Implemented Sign Out as a first PanicKit Response
This closes #204
2016-01-12 10:49:14 -02:00
Torsten Grote
4460d69a06 Improve PasswordActivity by
* removing screen border visible on small screens
* showing noticeable error message on wrong password input
* showing keyboard again after entering wrong password
* making lost password link easier to recognize as link
* renaming keyboard toggle method from 'hide' to 'toggle'
2016-01-07 14:15:57 -02:00
Torsten Grote
f309cb36d4 Create custom BriarRecyclerView and use it for the contact list.
It is a common pattern to have a list with an empty view and a progress bar.
This commit introduces a custom BriarRecyclerView and uses it for the
contact list.

No more manually hiding and showing empty views and progress bars is
necessary when using the new BriarRecyclerView instead of RecyclerView.

Please note that this conflicts with !44 at the moment and needs to be
implemented for !36 once merged.

Closes #198
2015-12-30 11:50:15 -02:00
Torsten Grote
4bcd204687 Use a RecyclerView for the Contact List 2015-12-28 14:37:23 -02:00
akwizgran
545a2c04bb Merge branch 'explain-tor-setting' into 'master'
Longer explanatory text for Tor mobile data setting



See merge request !29
2015-12-17 16:56:27 +00:00
Torsten Grote
264285ecf7 Show all transports on the dashboard
and indicate which transports are currently available.
The icons have been chosen from the official material icons and might be
replaced later with icons that better represent the given transport.

Please note that I used vector drawables which will be automatically
converted at build time to raster graphics.

Closes #96
2015-12-17 11:34:10 -02:00
Torsten Grote
2d28dcada2 Create two new events to signal enabling and disabling of transports 2015-12-17 11:34:10 -02:00
akwizgran
2c52a95ad5 Explanatory text for Tor mobile data setting. 2015-12-17 12:39:23 +00:00
akwizgran
8fa05e545f Merge branch '174-bsp-renaming' 2015-12-16 10:39:16 +00:00
akwizgran
d710841728 Merge branch '37_optionally_disable_tor' into 'master'
37 optionally disable tor

Provides:

* Checkbox in the settings view to disable Tor if not connected to a wifi network
* A network change callback in the Tor plugin to identify wifi connect/disconnect events
* A settings change event handler to disable enable tor when the user enables or disables the setting



See merge request !11
2015-12-15 17:12:39 +00:00
Santiago Torres
403ab75d13 [plugins/tor/TorPlugin] Adds tor-over-wifi setting
Provides a checkbox in the settings view, as well as an event handler to
disable/enable the tor network if the device is not on using the wifi
connection.

Refactors network-enabling code to a separate function. This function
is ran after the network state changes, or the settings change and
will update the status accordingly.
2015-12-15 10:17:29 -05:00
Torsten Grote
327073f514 Put conversation view layout in XML file
and fix message divider background for lower API levels.
2015-12-15 13:11:11 -02:00