XML namespaces are a massive pain to deal with in, and they are totally
unneeded in the translation files. xmlns:tools is only needed in the
source file to ignore some lint warnings.
All feature graphics are called `featureGraphic.png`, and so our cache
was presuming all feature graphics were the same image. By including
the full path from the server in the cached name, we don't overwrite
images any more.
Right now, org.fdroid.fdroid.privileged.ota and FFupdater do not
provide any icons and it seems that that triggers this crash:
ACRA caught a NullPointerException for org.fdroid.fdroid
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.String.lastIndexOf(int)' on a null object reference
at org.fdroid.fdroid.FDroidApp$5.generate(FDroidApp.java:282)
at com.nostra13.universalimageloader.cache.disc.impl.BaseDiskCache.getFile(BaseDiskCache.java:167)
at com.nostra13.universalimageloader.cache.disc.impl.BaseDiskCache.get(BaseDiskCache.java:98)
at com.nostra13.universalimageloader.cache.disc.impl.LimitedAgeDiskCache.get(LimitedAgeDiskCache.java:74)
at com.nostra13.universalimageloader.utils.DiskCacheUtils.findInCache(DiskCacheUtils.java:36)
at org.fdroid.fdroid.NotificationHelper.getLargeIconForEntry(NotificationHelper.java:506)
at org.fdroid.fdroid.NotificationHelper.createUpdateNotification(NotificationHelper.java:300)
at org.fdroid.fdroid.NotificationHelper.createNotification(NotificationHelper.java:191)
at org.fdroid.fdroid.NotificationHelper.access$400(NotificationHelper.java:37)
at org.fdroid.fdroid.NotificationHelper$1.onReceive(NotificationHelper.java:106)
at android.support.v4.content.LocalBroadcastManager.executePendingBroadcasts(LocalBroadcastManager.java:297)
at android.support.v4.content.LocalBroadcastManager.access$000(LocalBroadcastManager.java:46)
at android.support.v4.content.LocalBroadcastManager$1.handleMessage(LocalBroadcastManager.java:116)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
* Avoids crashes when trying to treat non apk files, such as
privileged extension ota update.zip as apks
* Doesn't do anything at all for now.
One issue with this is the app is always in the not installed state,
so what would be appropriate here would be to change the text of the
install button to download, and update that accrodingly.
However that is outside of the scope of this change.
TODO:
Add toast indicating the user that they need to install
manually, in case of OTA update.zip
This zeros out the etag in the fdroid_repo table and then asks
the update service to perform an update.
The end result is that changing the language will result in the metadata
being shown in that language.
Note: This doesn't immediately work due to pending changes around
Locale.setDefault() and the change in case from Summary to summary in
the server metadata.
This reverts to the previous behaviour before 8faf151.
Then, the InstalledAppProviderService would queue up a series of
changes, and only notify after 1 second of nothing being added to
the queue. This was good because CursorAdapters and LoaderManagers
would not continually requery the database several times a second (only
once at the end), but it meant there was a lag in the AppDetails screen
getting updated after installing/upgrading/deleting packages.
This restores that behaviour where general events (e.g. "some misc apps
in the database were changed") are "debounced" for 1 second. However it
also emits a more specific "package org.blah.com was changed" instantly.
In the long term, it would be good to remove any dependency on
ContentObservers and `notifyChange()` altogether, in preference of
either LocalBroadcastManager or RxJava. However this will depend on how
we go about changing the database layer in the future. The fact we now
depend on ContentProviders means that it would be a big change to move
away from LoaderManager + notifyChange().
Fixes#986.
connected24 tests are frequently failing saying that while an emulator
is running, its not compatible. This is bizarre. This just adds debug
output to help troubleshoot that.
I have found no explanation of what should work and why, but language
choosers seem to always include this line. This also seems to fix the
bug:
closes#943
This makes the license a link to the spdx.org page for the app's
license. I think this is an improvement over the way the license was
displayed before 0.103 since it provides a direct link to the actual
text of the license.
The license icon is a modified version of the public domain icon:
https://commons.wikimedia.org/wiki/File:Cc-sa_white.svgcloses#960
* Addition: Try to get apk details via InstalledAppProvider too.
* In certain cases, such as the "UnifiedNlp (no GAPPS)" app on a device
with actualy GAPPS / GMS installed, apk can be null which leads
to a crash
* Ask InstalledAppProvider for the app's details too, like it
was done in the old UX AppDetails.
* Also seen when uninstalling app with a signing key different,
fixes#985