enhance jquery.spinner, keeping backwards compatibility
authorMatmaRex <matma.rex@gmail.com>
Mon, 3 Sep 2012 15:08:46 +0000 (17:08 +0200)
committerTimo Tijhof <ttijhof@wikimedia.org>
Tue, 11 Sep 2012 03:29:40 +0000 (05:29 +0200)
commita2593d7f2be05fc0f34fbb381646a9f726b94f6b
tree3aa8eec877d98c10033ee12564cbd2281266cb7b
parent92d1f06eeb2487cd7121ded56f856490f0c341a0
enhance jquery.spinner, keeping backwards compatibility

Replaced single `id` argument to $.createSpinner with an options object.
The options allow one to set the id (as before), spinner size (small or
large), and its display mode (inline or block). Analogic change was made
to $.fn.injectSpinner.

Default options are kept the same as they used to be, and old-style calls
still work. However, the definition of .mw-spinner CSS class has been
changed (although, with a bit of hairy code, it could be kept
compatible...).

These changes should be enough to allow us to replace old usages of
.mw-small-spinner and .mw-ajax-loader classes, as defined in shared.css.

This is a reimplementation of the idea described in Ie55ffb6b.

Copied spinner.gif and ajax-loader.gif from /skins/common/images/.

Change-Id: I0ff71ba1eef299e0e699df84c68f1be1c20492f7
resources/jquery/images/spinner-large.gif [new file with mode: 0644]
resources/jquery/images/spinner.gif
resources/jquery/jquery.spinner.css
resources/jquery/jquery.spinner.js