1298 Commits

Author SHA1 Message Date
Daniel Martí
0655abe3b9 Bump to 0.100-alpha1
Also update CONTRIBUTING, since we're now going to use three digits in
the version codes for the second part in each version.
2016-03-10 16:53:01 +00:00
F-Droid Translatebot
8f24759a33 Pull translation updates from Weblate
Translators:

Adrià García-Alzórriz      Catalan
Adrià García-Alzórriz      Spanish
Benedikt Volkmer           German
Irvan Kurniawan            Indonesian
Licaon Kter                Romanian
Marcelo Santana            Portuguese (Brazil)
Massimiliano Caniparoli    Italian
Mladen Pejaković           Serbian
Mohamad Hasan Al Banna     Indonesian
naofum                     Japanese
Pander                     Dutch
Phạm Nguyễn Hoàng          Vietnamese
riotism                    Chinese (Hong Kong)
Tobias Bannert             German
Verdulo                    Esperanto
Verdulo                    Polish
2016-03-10 16:48:08 +00:00
Peter Serwylo
da8c0e0e16 Merge branch 'gradle-updates' into 'master'
Misc gradle, lint and markdown updates



See merge request !223
2016-03-07 14:00:27 +00:00
Peter Serwylo
0f64f2c181 Clarify threading when loading categories
Previously, it was not explicit that the `onCreate` happened to be invoked
in the UI thread. Now it is, due to passing `new Handler(Looper.getMainLooper())`.
Also, the categories are now loaded in a background task, and then the UI is
updated on the UI thread.
2016-03-07 23:46:06 +11:00
Peter Serwylo
7421d33c3a Expand null check to include isAdded() check
Also, don't call `getActivity()` in the separate thread. Instead, use the
`Activity` which we have already checked and ensured is not null.
2016-03-07 23:45:58 +11:00
Daniel Martí
80a3faa4d5 Explicitly set fullBackupContent to true
An F-Droid backup should contain all the app's data.
2016-03-05 23:27:18 +00:00
Daniel Martí
b534bba440 Bump targetSdkVersion to 23
compileSdkVersion in the build.gradle file was already bumped, but we
forgot about this one.
2016-03-05 23:27:00 +00:00
Daniel Martí
25a9360a58 Fix ScrollViewSize lint warnings 2016-03-05 23:21:15 +00:00
Daniel Martí
28988b9fdd Bump libsuperuser to the latest version 2016-03-05 23:15:47 +00:00
Paresh Chouhan
683ba8d20f Enhancement|UI : Repository URL added to APK's on AppDetails Activity.
Fixes issue #527.
Repository URL's now shown as Provided By domain.name/repo
2016-03-06 01:23:13 +05:30
Peter Serwylo
018a8231d6 Merge branch 'pmd' into 'master'
Add PMD



See merge request !221
2016-03-04 22:14:22 +00:00
F-Droid Translatebot
37ef67e1b8 Pull translation updates from Weblate
Translators:

ageru              French
Danial Behzadi     Persian
enolp              Asturian
ezjerry liao       Chinese (Taiwan)
Fr Translation     French
Hsiu-Ming Chang    Chinese (Taiwan)
Jonatan            Swedish
relan              Russian
riotism            Chinese (Hong Kong)
2016-03-04 17:04:38 +00:00
Daniel Martí
85ba537d95 PMD: Add a few rulesets that we already obey 2016-03-01 17:46:38 +00:00
Daniel Martí
fbeb6d140f PMD: Enable java-android, fix issues 2016-03-01 17:46:38 +00:00
Daniel Martí
78d15dd4a8 Add PMD, for now with no rules
Unlike findbugs, PMD is very easy to configure. Should be very useful as
long as we set a correct ruleSet.
2016-03-01 17:46:38 +00:00
relan
e2b81c6b77 Permit deprecated Apache HTTP Client
This is a temporary solution. All code that uses Apache HTTP Client
should be rewritten.
2016-03-01 12:34:20 +03:00
relan
21a78054d5 Bump target SDK to 23
Also update Support Library components to 23.2.0.
2016-03-01 12:34:20 +03:00
relan
77074f83e2 Remove PackageInfo.REQUESTED_PERMISSION_REQUIRED
This flag existed in Android 4.2-5.1 and has always been set. Stop
checking it.
2016-03-01 12:33:21 +03:00
Daniel Martí
26ce365c22 Enable test coverage for Gitlab CI 2016-02-29 20:11:29 +00:00
Daniel Martí
4aa44cb150 Bump to 0.99 2016-02-28 22:46:53 +00:00
F-Droid Translatebot
91482e05f0 Pull translation updates from Weblate
Translators:

Adrià García-Alzórriz    Catalan
Adrià García-Alzórriz    Spanish
Ajeje Brazorf            Sardinian
Alberto Moshpirit        Spanish
Alex Kalles              Greek
jetamkadlec              Czech
Ldm Public               French
Licaon Kter              Romanian
Mladen Pejaković         Serbian
naofum                   Japanese
Olexandr Nesterenko      Ukrainian
Verdulo                  Esperanto
Verdulo                  Polish
2016-02-28 22:41:02 +00:00
Daniel Martí
a203545e48 Bump checkstyle to 6.16
Due to fixes and improvements, some new checkstyle changes are due.
2016-02-28 16:44:44 +00:00
Daniel Martí
d061dafcd7 Remove a few extra spaces that checkstyle missed
There's also a change in a SQL string, but it should be safe.
2016-02-28 14:29:51 +00:00
Daniel Martí
3af5f55abd Remove unused repo field
Found by Android Studio.
2016-02-28 14:22:27 +00:00
Daniel Martí
9c86655af0 Make some declaration accesses weaker
As suggested by Android Studio.
2016-02-28 14:19:02 +00:00
Daniel Martí
982bf42a4b Remove unused resources from old search screen
We didn't remove the search results class until after reworking the
feature, which is probably why this was kept around.
2016-02-28 14:04:15 +00:00
Peter Serwylo
ad63e52e50 Extract BroadcastReceivers to member variables, so they can be unregistered correctly.
Previously, they were registered, then forgotten. This means that each time
the start swap view was run, another receiver was registered. As a result,
they were being invoked multiple times.

It doesn't appear that this had any specific side effects which were terrible,
but they definitely have the potential to going forward.

Note that because we are not using `Fragments` with their convoluted, but at
least well documented API, I'm not 100% certain that I've unregistered the
receivers at the right location.
2016-02-28 13:58:49 +11:00
Peter Serwylo
1323e800b7 Temporarily disable listeners when updating switch state in response to background process.
Previously, something like this would happen:
 * Swap service is cancelled
 * WiFi swap is asked to stop
 * Event is broadcast when done
 * UI listens to this event
 * Upon receiving the event, it updates the UI
 * Updating the UI triggers an event, causing the process to happen again

An alternative solution to this would have been for the UI to stop listening
to listeners before WiFi swap is shut down, but that is then only specific
to the case when the swap view is being destroyed/removed. This could also
happen in other situations however, such as when the swap service times out.
2016-02-28 13:43:07 +11:00
Peter Serwylo
209afd6bf2 Extract switch change listeners to member variables, so that they can be unregistered.
When the view is detached, then the listeners will be unregistered.
This will also help in the future so that they can be temporarily
unregistered when manually changing the state of the switches.
2016-02-28 12:49:50 +11:00
Peter Serwylo
62b080a8d9 Rename logging tag to make logcat debugging clearer. 2016-02-28 12:36:06 +11:00
Daniel Martí
1eedf66d66 Bump to 0.99-alpha2 2016-02-27 13:02:24 +00:00
Hans-Christoph Steiner
fd03ebd764 annotate swap methods that require android-10
swap only works on >= android-10 anyway

closes #581 https://gitlab.com/fdroid/fdroidclient/issues/581
2016-02-27 11:05:16 +01:00
Hans-Christoph Steiner
26b35723d3 use AsyncTask for SwapType operations to run in background
Thread runs at normal priority by default.  AsyncTasks are integrated into
Android for handling things running in the background while keeping the UI
responsive.

This reverts most of commit 828cc272ee5235f868104b009349cc7e835e144f.
2016-02-27 11:05:16 +01:00
Hans-Christoph Steiner
96fe1f9584 do not show "Swap" as an option on less than android-10
Swap requires lots of APIs that are only all available in android-10, so
hide the menu item on older platforms.

closes #581 https://gitlab.com/fdroid/fdroidclient/issues/581
closes #575 https://gitlab.com/fdroid/fdroidclient/issues/575
2016-02-27 11:04:08 +01:00
Hans-Christoph Steiner
38e4b38602 Re-enable NetCipher to provide decent TLS on all Android versions
Revert "Revert netcipher to fix SNI regression"
This reverts commit 6c8e726aadbe6714d6295882c5be87a7bf81a9f0.

NetCipher is important for making sure that the client running on older
versions of Android is not using extremely crappy default TLS settings.  It
also streamlines the Tor support.

closes #431 https://gitlab.com/fdroid/fdroidclient/issues/431
closes #576 https://gitlab.com/fdroid/fdroidclient/issues/576
2016-02-27 11:04:08 +01:00
Hans-Christoph Steiner
eed0070d4b do not bail out of wifi settings if there is no DhcpInfo
There is still much useful information to be had without DhcpInfo.
2016-02-27 11:04:08 +01:00
Peter Serwylo
db120133b9 Don't try to start bonjour without an IP.
Although not reproduced, it looks very much like this would be related
to, and should subsequently fix #556.
2016-02-27 09:28:17 +11:00
Peter Serwylo
3dd0589b08 Don't say wifi is connected until both wifi + bonjour are ready.
Although I can't reproduce reliably, I am hopeful that this will resolve
a lot of the errors such as #557.
2016-02-27 09:28:17 +11:00
Peter Serwylo
cd3a064a5a Don't call unregisterService(...) then unregisterAllSerivces().
The later will unregister the service we were explicitly unregistering anyway.
2016-02-27 09:28:17 +11:00
Peter Serwylo
1505d21781 Set connected status after disconnecting from wifi swap. 2016-02-27 09:28:17 +11:00
Peter Serwylo
2ed6110ae5 Cleanup looper after shutting down. 2016-02-27 09:28:17 +11:00
Peter Serwylo
18f97602e8 Don't start swap wifi when there is no network.
Not sure if we should be here or not in this situation, so this is
a little bit defensive. Can't bind to an IP address of `null`, so
don't bother starting LocalHTTP server unless we have an IP.
2016-02-27 09:28:17 +11:00
Peter Serwylo
ddbd9e2ea9 Actually run thread in background.
`Thread.run()` is not the correct call, changed to the correct `Thread.start()`.
Also, explicitly indicate that we want the stopping of wifi to happen in the
background.
2016-02-27 09:28:17 +11:00
Peter Serwylo
1eae135929 Add user feedback for when WiFi is being disabled.
On some devices this can take some time (i.e. a second) and the UI needs
to be disabled for that time. This should stop users quickly stopping and
starting regularly, queuing up many "start jmdns, stop jmdns, start jmdns"
calls.
2016-02-27 09:28:17 +11:00
Peter Serwylo
8364aa15f1 Don't try to start swap again if we have gone from network -> no network. 2016-02-27 09:27:57 +11:00
Daniel Martí
b08b97466f Fix a single rogue ellipsis 2016-02-26 15:00:50 +00:00
Daniel Martí
91c3278920 Take RTL suggestions from lint (warnings) 2016-02-26 14:57:42 +00:00
Daniel Martí
e390561c7c install_confirm: remove useless lines
These are already in its layout-v11 version. And as lint points out,
these need v11:

	?android:attr/buttonBarStyle requires API level 11 (current min is 8)
	?android:attr/buttonBarButtonStyle requires API level 11 (current min is 8)
2016-02-26 14:48:45 +00:00
Daniel Martí
1b6fc3da7c Move app_permission_item_money to layout-v17
Since it's only ever used on android-17 or later, move it there to keep
lint happy with all the NewApi errors.
2016-02-26 14:47:09 +00:00
Daniel Martí
5179e032db Fix NewApi bug introduced in 8e193cec 2016-02-26 14:39:02 +00:00