mediawiki-extensions-Multim.../resources/mmv/provider
Gergő Tisza fec24e02f7 Refactor progressbar & blur handling
This tries to fix a number of related issues:
* the blurred thumbnail was visible for a split-second sometimes
  when switching back to an already-loaded image. (Presumably when
  JS was sluggish enough to take more than 10 ms to execute.) We
  now check whether the promise is pending before showing a placeholder.
  (More generally, a lot of unnecessary logic was executed when paging
  through already loaded images, like displaying the placeholder, so
  this might make the UI a bit more responsive.)
* the blur could get stuck sometimes - I have seen this a few times,
  but have never been able to reproduce it, so I'm only guessing, but
  maybe the timing was really unfortunate, and we switched back less
  than 10 ms before loading finished. We now remove the blur on every
  branch, just to be sure.
* adding a progress handler to a promise might not have any immediate
  effect, so when switching to an image which was loading, the progress
  bar reacted too late. We now store the progress state per thumbnail
  so it is always available immediately.
* the progress would animate from 0 to its actual state whenever we
  navigated to the image. The change on paging is now instant; the
  progress bar only animates when we are looking at it.
* switching quickly back and forthe between a loaded and a loading
  image resulted in the loading image becoming unblurred. This seems
  fixed now, I'm not sure why. Maybe the "skip on non-pending promise"
  logic affects it somehow.

Also removes some unused things / renames some things which were
confusing, and makes an unrelated fix in the image provider, which kept
amassing fail handlers.

Change-Id: I580becff246f197ec1bc65e82acd422620e35578
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/489
2014-05-01 21:09:28 +00:00
..
mmv.provider.Api.js Cache API responses 2014-04-22 10:56:52 +02:00
mmv.provider.FileRepoInfo.js Cache API responses 2014-04-22 10:56:52 +02:00
mmv.provider.GlobalUsage.js Skip userinfo request if no message depends on the gender. 2014-04-23 00:59:23 +00:00
mmv.provider.GuessedThumbnailInfo.js Guess thumbnail URLs without extra API call 2014-04-17 01:21:35 +00:00
mmv.provider.Image.js Refactor progressbar & blur handling 2014-05-01 21:09:28 +00:00
mmv.provider.ImageInfo.js Cache API responses 2014-04-22 10:56:52 +02:00
mmv.provider.ImageUsage.js Cache API responses 2014-04-22 10:56:52 +02:00
mmv.provider.ThumbnailInfo.js Cache API responses 2014-04-22 10:56:52 +02:00
mmv.provider.UserInfo.js Skip userinfo request if no message depends on the gender. 2014-04-23 00:59:23 +00:00