6020 Commits

Author SHA1 Message Date
Michael Pöhn
5dd866d39e fix checkstyle 2019-06-12 12:04:15 +02:00
Michael Pöhn
067d39f72d preferences fragment: setup use tor preferences changed only once 2019-06-11 16:23:22 +02:00
Michael Pöhn
88f3a68f83 deduplicate error prone proxy settings code 2019-06-11 16:23:22 +02:00
Michael Pöhn
292950898e replace prone useTor preference mirror value from FDroidApp with direct preference calls 2019-06-11 16:23:22 +02:00
Hans-Christoph Steiner
1f565d7638 Merge branch 'typo-fixes' into 'master'
Fix Typos

See merge request fdroid/fdroidclient!826
2019-06-11 12:11:03 +00:00
Yoginth
0851fea8eb
Fix Typos 2019-06-05 03:52:40 +00:00
Hans-Christoph Steiner
3ea365a1f5 update changelog 1.7-alpha0 2019-05-24 15:47:48 +02:00
Hans-Christoph Steiner
6d3a7d4537 move all QR Code related classes to .qr package 2019-05-24 15:47:48 +02:00
Hans-Christoph Steiner
23fc17ba5f purge confusing, unused duplicate string/icon assignment in bottom nav
fdroid/fdroidclient#1785
2019-05-24 15:47:48 +02:00
Hans-Christoph Steiner
c652718a4a fix lint: Repeated word "do" in message: possible typo [Typos] 2019-05-24 15:47:48 +02:00
Hans-Christoph Steiner
1b670df1fd
./tools/remove-unused-and-blank-translations.py 2019-05-24 15:38:36 +02:00
Hosted Weblate
36f29bc6a8 Translated using Weblate: Portuguese (pt) by ssantos <ssantos@web.de>
Currently translated at 100.0% (431 of 431 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/pt/

Translated using Weblate: Portuguese (pt) by ssantos <ssantos@web.de>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/pt/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Translated using Weblate: Portuguese (pt) by ssantos <ssantos@web.de>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/pt/

Translated using Weblate: Portuguese (pt) by Rui Mendes <xz9@protonmail.com>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/pt/

Translated using Weblate: Portuguese (pt) by Rui Mendes <xz9@protonmail.com>

Currently translated at 100.0% (21 of 21 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/pt/

Translated using Weblate: Portuguese (pt) by Rui Mendes <xz9@protonmail.com>

Currently translated at 100.0% (21 of 21 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/pt/

Translated using Weblate: Portuguese (pt) by Rui Mendes <xz9@protonmail.com>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/pt/

Added translation using Weblate: Portuguese (pt) by Rui Mendes <xz9@protonmail.com>
2019-05-24 15:36:13 +02:00
Hosted Weblate
2289a07483 Translated using Weblate: Icelandic (is) by Sveinn í Felli <sv1@fellsnet.is>
Currently translated at 100.0% (431 of 431 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/is/

Translated using Weblate: Icelandic (is) by Sveinn í Felli <sv1@fellsnet.is>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/is/
2019-05-24 15:36:13 +02:00
Hosted Weblate
4258315286 Translated using Weblate: Hebrew (he) by Yaron Shahrabani <sh.yaron@gmail.com>
Currently translated at 100.0% (431 of 431 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/he/

Translated using Weblate: Hebrew (he) by Yaron Shahrabani <sh.yaron@gmail.com>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/he/

Translated using Weblate: Hebrew (he) by Yaron Shahrabani <sh.yaron@gmail.com>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/he/

Translated using Weblate: Hebrew (he) by Yaron Shahrabani <sh.yaron@gmail.com>

Currently translated at 100.0% (21 of 21 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/he/
2019-05-24 15:36:13 +02:00
Hosted Weblate
c2070fb76f Translated using Weblate: German (de) by Hans-Christoph Steiner <hans@guardianproject.info>
Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Translated using Weblate: German (de) by ssantos <ssantos@web.de>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/de/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Translated using Weblate: German (de) by C. Rüdinger <Mail-an-CR@web.de>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Translated using Weblate: German (de) by C. Rüdinger <Mail-an-CR@web.de>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Update translation files

Updated by "Squash Git commits" hook in Weblate.

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/

Translated using Weblate: German (de) by ssantos <ssantos@web.de>

Currently translated at 100.0% (22 of 22 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/de/

Translated using Weblate: German (de) by CurlingTongs <o11577482@nwytg.net>

Currently translated at 100.0% (21 of 21 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/de/

Translated using Weblate: German (de) by C. Rüdinger <Mail-an-CR@web.de>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Translated using Weblate: German (de) by Sören Strecke <soeren.strecke@live.de>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Translated using Weblate: German (de) by C. Rüdinger <Mail-an-CR@web.de>

Currently translated at 100.0% (429 of 429 strings)

Translation: F-Droid/F-Droid
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid/de/

Translated using Weblate: German (de) by ssantos <ssantos@web.de>

Currently translated at 100.0% (21 of 21 strings)

Translation: F-Droid/F-Droid metadata
Translate-URL: https://hosted.weblate.org/projects/f-droid/f-droid-metadata/de/
2019-05-24 15:36:13 +02:00
Hans-Christoph Steiner
f69b38aad5 Merge branch 'major-swap-overhaul' into 'master'
major swap overhaul

See merge request fdroid/fdroidclient!825
2019-05-24 13:34:51 +00:00
Hans-Christoph Steiner
14e006b924 mark two flaky swap test classes to omit them from gitlab-ci runs
They work fine on my machine, but fail often/always on gitlab-ci
2019-05-24 15:01:33 +02:00
Hans-Christoph Steiner
7acc0cd4c3 make LocalHTTPDTest resilient to LocalHTTPDManagerTest's detritus
LocalHTTPDManagerTest seems to leave port 8888 running sometimes, causing
all of LocalHTTPDTest tests to fail.
2019-05-24 13:36:47 +02:00
Hans-Christoph Steiner
051d58acaf start LocalRepoService once SelectApps is shown to speed up connecting 2019-05-24 13:36:47 +02:00
Hans-Christoph Steiner
6e8c4eb1bf store the current Bluetooth name and restore it when swap is done
fdroid/fdroidclient#1669
2019-05-24 13:36:47 +02:00
Hans-Christoph Steiner
7f35420e37 purge last RxAndroid code, replace with good ol' Intents
Rx needs to be used as the basis of the whole system, it doesn't make sense
to just have one small part handled by Rx.

RxJava is still used in InstallAppProviderService, so that would have to be
tackled separately.
2019-05-24 13:36:47 +02:00
Hans-Christoph Steiner
18a7690758 track all successful peers, and remove all unsuccessful peers
Since it is possible to connect to a peer via NFC, "Swap back", QR Code,
etc. once a peer is successfully used, it can show up in the StartSwapView
list of peers.
2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
0727787713 make BonjourPeer and WifiPeer equals if they point to the same device 2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
74c3c24f0a reset idle timer each time a new swap screen is loaded
This means that as long as the user is using swap, it'll stay running.
2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
e02bc4134a fix display of swap cancel button and installing progress
closes #1612
2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
fea778793c replace BluetoothSwap with BluetoothManager, using HandlerThread
This is the last of the SwapType stuff!

fdroid/fdroidclient#1723
fdroid/fdroidclient#1669
2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
ddbe93aeb4 SwapWorkflowActivity: save BluetoothAdapter instance for reuse 2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
da66949b9e turn LocalRepoService Intents into status Intents like other Services 2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
effcf4bfa9 purge WifiSwap class in favor of Intents and Services 2019-05-24 13:35:56 +02:00
Hans-Christoph Steiner
46472ba7a4 create BonjourManager to manage jmdns in HandlerThread, with tests 2019-05-24 13:35:55 +02:00
Hans-Christoph Steiner
79e7e78e7f create testable LocalHTTPDManager for controlling the webserver
The RxJava tricks were a nightmare...
2019-05-24 10:02:22 +02:00
Hans-Christoph Steiner
5b610798c2 more reliably set WiFi SSID in nearby/swap interfaces
Often times, the WiFi is properly setup, the IP address is showing, but the
SSID is showing as "No network yet".
2019-05-24 10:02:22 +02:00
Hans-Christoph Steiner
11e0c1926c move swap repo polling to SwapService
SwapService is the long lived background service, and it was already doing
the core work anyway.
2019-05-24 10:02:22 +02:00
Hans-Christoph Steiner
6c1375bf3a quick hack to show "Installing..." when swap install process runs 2019-05-24 10:02:22 +02:00
Hans-Christoph Steiner
e7979fca48 name all SwapService getters properly: getSwapService()
This also switches to always using getActivity().getSwapService() to make
it easily traceable where that is happening.  It shouldn't be happening in
SwapViews...
2019-05-24 10:02:22 +02:00
Hans-Christoph Steiner
e98393f092 use launchMode="singleTask", there can be only one SwapWorkflowActivity!
* https://developer.android.com/reference/android/app/Activity.html#onNewIntent(android.content.Intent)
* https://developer.android.com/guide/topics/manifest/activity-element#lmode
* https://inthecheesefactory.com/blog/understand-android-activity-launchmode/en
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
289976667d fix NullPointerException in BonjourPeer and BluetoothPeer
java.lang.IllegalStateException: Fatal Exception thrown on Scheduler.Worker thread.
    at rx.internal.schedulers.ScheduledAction.run(ScheduledAction.java:62)
    at android.os.Handler.handleCallback(Handler.java:751)
    at android.os.Handler.dispatchMessage(Handler.java:95)
    at android.os.Looper.loop(Looper.java:154)
    at android.app.ActivityThread.main(ActivityThread.java:6128)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference
    at org.fdroid.fdroid.localrepo.peers.BonjourPeer.equals(BonjourPeer.java:34)
    at java.util.HashMap.put(HashMap.java:427)
    at java.util.HashSet.add(HashSet.java:217)
    at rx.internal.operators.OperatorDistinct$1.onNext(OperatorDistinct.java:62)
    at rx.internal.operators.OperatorObserveOn$ObserveOnSubscriber.pollQueue(OperatorObserveOn.java:202)
    at rx.internal.operators.OperatorObserveOn$ObserveOnSubscriber$2.call(OperatorObserveOn.java:162)
    at rx.internal.schedulers.ScheduledAction.run(ScheduledAction.java:55)
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
779a0122fd fix ConcurrentModificationException crash in LocalRepoService
https://stackoverflow.com/a/602660

java.util.ConcurrentModificationException
    at java.util.HashMap$HashIterator.nextEntry(HashMap.java:851)
    at java.util.HashMap$ValueIterator.next(HashMap.java:879)
    at org.fdroid.fdroid.localrepo.LocalRepoManager.copyIconsToRepo(LocalRepoManager.java:296)
    at org.fdroid.fdroid.localrepo.LocalRepoService$1.run(LocalRepoService.java:131)
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
910f5da81a create download and install receivers per-app, not globally
Each individual app needs its own receivers for these things, just like in
AppListActivity and InstallManagerService.
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
d91fbe7b0e rework swap startup putting SwapService first
SwapService is the thing that needs to be always running, and the last
thing killed.  So it should start first, and stop last.  So now, the user
clicking the button starts SwapService, which starts SwapWorkflowActivity.
This also eliminatings the "Loading" screen in favor of just showing the
StartSwapView with various inline progress indicators.
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
035a89e5f6 move all current View tracking to SwapWorkflowActivity
This information is only ever used in SwapWorkflowActivity and nowhere else
so if it needs to be stored, it could be stored via saveInstanceState().
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
39f23f6876 add required length limits to swap strings for the translators 2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
9dc9a23a41 fix all RtL lint errors in swap layouts 2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
89f5127f6d turn inline Install button into Cancel button during download 2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
bc14e62e46 receive Downloader error messages in swap 2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
f0158063fb show full error messages from UpdateService
The "cause" is the Exception that was caught and embedded into the
UpdateException, so it has more info on what happened.
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
ad3fd26756 immediately regenerate swap repo when user changes app selections
Instead of waiting for the user to make all the app selections, then click
next, this constantly regenerates the swap repo on each click of the app
list.  This means that the swap repo is more likely to be immediately ready
when the user clicks next.
2019-05-24 10:00:08 +02:00
Hans-Christoph Steiner
b5d94b7476 convert swap error "back" button to "Try again"
The Android back button provides a working back function, and the Swap
"close" button on the upper left already provides a reset function. So this
turns the "back" button to be a "try again" button which re-runs the
connection process.
2019-05-24 10:00:07 +02:00
Hans-Christoph Steiner
5851ea73e0 move ConnectingView to pure XML view, and remove Receiver superclass
The Receiver superclass is not reusing difficult code, but it is hiding the
simple list of UI configuration that it does.

This also eliminates the "error" TextView and just reuses the existing
TextView for error messages.
2019-05-24 10:00:07 +02:00
Hans-Christoph Steiner
5ddc287ab3 move NfcView to pure XML view 2019-05-24 10:00:07 +02:00