I've resolved this issue. The problem was not as I thought, related to
the behaviour of the onload event, but rather to a failure of IE to
cache the preloaded image. This meant that when the original image's
src attribute was modified to that of the new image there was no image
to load from the cache so a new request was made to the server.
The reason the image was not cached is the 'Vary' response header sent
by the application server (Apache Cocoon). This header is a directive
specifying which request headers are to be used in addition to the
request URI in determining if a suitable match exists in the cache. IE
will _not_ cache responses containing the Vary header unless the field
specified is the "User-Agent" field. For more detail on this issue
see:
http://lists.over.net/pipermail/mod_...er/006826.html
Removing the 'Vary' header results in the preloaded images being cached
correctly and the code works as expected.
Cheers
Adam