The StringBufferInputStream is deprecated, because it doesn't know the
encoding of the string it is buffering. This has been changed to use
a ByteArrayInputStream with UTF-8 encoding now.
Also made use of previously unused mimeType parameter to set the
Content-Type header of the response.
Sets a stream handler in FDroidApp which understands bluetooth://
URLs and returns a non-functioning URL handler for such URLs.
The reason it is non-funcitoning is because the openConnection()
function is not being used by the BluetoothDownloader at this point.
In the absense of this, a MalformedURLException is thrown.
The bluetooth stuff is still broken, but it is not broken in
this way any more.
The AppDetails subclass used to be used when you couldn't install apps
directly from the swap workflow. Now we don't send people to app
details, so the activity is unneeded.
The swap progress also now listens for progress broadcasts, rather than
showing an indeterminant progress bar.
Seems to work pretty-alright even when installing multiple apps.
Shows a progress (indeterminent at this stage) bar for each downloading
item, and hides the install button.
InnerView.getToolbarColour() was expecting a @ColorRes, except all views
were returning integers which were the colour value, not a pointer to
the resource as they should have been. Now only one place requires a
call to getResources().getColor() whereas before it was in each view.
Notifications on pre 4.1 devices require a pending intent to work. This
is so that when you touch the intent, it takes you somewhere meaningfull.
Without it, the update process crashes.
Add timeout for Http request
The timeout of HttpURLConnection is 0, which means the request would never return if either connection or read timeouts, and the code would never catch these exceptions.
This patch set explicit timeout value (10s for connection timeout and 40s for read timeout), so the code would catch and handle timeout exceptions as you would expect.
Best,
See merge request !117
Two views weren't hidden by default, so they were taking up space before they
were needed. The java code already takes care of showing them when necessary.
Target/Support version bumps
This is part of the (unmergeable as of now) !96. These changes are simple yet important enough for me to think that they deserve their own merge request.
I didn't push the changes directly because I haven't worked with the material stuff enough to notice whether anything is breaking or not. For all I can see, the app looks the same and the bumps just added lots more deprecation warnings (which is fine, they can be dealt with over time).
See merge request !109
Prompt for beta updates
Ready to get merged. 👍
~~This MR is ready to get merged, the last thing that needs to be fixed is [this](72ed814a73 (note_1726274)).~~
This closes#313.
See merge request !112