We were crashing when rotating in the detail view, because the detail
view fragment had assumed that its parent activity had already loaded
up its cursor and such before it got created -- an assumption which
fails dramatically when rotating, or switching away and back after
we got paged out of memory.
Check whether we got an object, and if not ask the parent to ping us
when it's done loading.
Also tweaked one of the older delay hacks to avoid a second crash
related to the pager's adapter.
Change-Id: Ib91c0fef0d8ffd0e6b8e0e4874f3ee9be3e9cf34
FIXME: Show progress of upload as it happens, or at least
direct them to a place where that can happen
Change-Id: I7695fcb9de7d6c2ffdfa2bc60e116a20a6298e31
Only show actions that are applicable to each state.
Also clarify that 'abort' actually only 'deleted' failed
uploads. We have no way to abort an in-progress upload yet
Change-Id: I2c18273e603e3ca6b1e03f83b7404e96b6d8bad0
List of available licenses is pre-extracted from UploadWizard
MediaWiki extension. This should eventually be switched to use
some live query to the site configuration.
The license display is more or less localizable, for known templates.
Unrecognized templates specified as parameters to {{self}} will be
recognized (unlocalized) but others may not be.
Change-Id: I9df5fe807798a191a3bb0a45464760c75f19e366
Characters in the filename weren't being encoded when generating
a URL, which seems to break something in the network fetching.
Change-Id: I10a18d1e5e32a4806cdae03b4a510a18eba9802b
This is why copy pasting code is bad, but I've no idea how exactly
I can abstract out the ContentProvider related stuff
Change-Id: Ib668ad8cd2302b832afc69b97951f3a6b1dcfe5b
Since the imageURL can be generated if it isn't set, we can
generate it once and then just return it. This is overriden when
we explicitly set it if we get it back from the API
Change-Id: I55939f2d9c0c2679847ec104f8029d9e533e202b
The SyncService constantly deletes and re-creates the campaigns
in the background to make sure they are up to date
FIXME: Handle deleted or renamed campaigns
Change-Id: I5d03995ada219481ea38887a8ea6d59fa11d2ac8
Loads and displays default or English description, and categories.
No caching of this info yet.
Scrollable pane is a ListView, with the title/desc/category label
in a 'header' view along with a spacer view. The height of the spacer
is set dynamically to the height of the total fragment minus 48dp,
giving room for an initially-visible title section and a little
spillover so you can see it's scrollable.
Clicking on a category in the cats list opens the category page in
an external web browser. In the future this should open the category
within the app, but we don't have a per-cat view yet.
Description and category list are not yet editable.
GitHub: https://github.com/wikimedia/apps-android-commons/pull/41
Change-Id: I46d0a77481dbe64a268a72f3efe49ae72168541f
LRU bitmap cache ate too much memory on low-memory devices like the
old Nexus One and some of our testers' devices. Use the in memory
cache only for higher end devices
Change-Id: Ibe238c82d5891a8a25bddcab1ae3d3738a044c41
- Removes StartUploadActivity and children
- All 'filling in' of missing contribution data is now done
in one place
- Campaigns are theoretically supported
Change-Id: I18bac1b672e4a0f95cdcdc467dd137177feaf8e6