Added QtLockedFile class to prevent simultaneous read/write of .tmx and .tbx files.

This class was taken from QtCreator.  It provides a sort of mutex lock on
file reads and writes that works across threads and processes as long as
each thread/process uses the QtLockedFile class.

Simultaneous reads are possible, but only one writer is allowed.  Any attempt
to lock a file for reading or writing while it is being written will block
the new readers/writers until writing is complete.  Simultaneous reading
and writing is not allowed.
MapManager does all its map loading in threads.

loadMap() uses a thread to do the loading, processing events until the map
is done loading (or fails to load) - unless asynch loading was asked for.

fileChangedTimeout() uses a thread to load a map. mapLoadedByThread() will
do the job of replacing any already-loaded map with the newly-loaded one.
In that case, the mapAboutToChange()/mapChanged() signals are emitted.
mapChanged() is a new signal that other classes were modified to make use of,
rather than mapFileChanged().
Fixed crashiness in BuildingReader.
Optimized CompositeLayerGroup::orderedCellsAt().

The change is: don't bother getting cells from submaps if the position is
outside the submap. SubMapLayers gained mBounds to do this checking.  It
made a huge difference when rendering map images.
Fixed MapImageManager not seeing changes to map files.

Because no ImageData.sources were set before rendering a map image in a thread,
the mapFileChanged() method didn't try to recreate the image.
Fixed thread-contention issue in MiniMap.
Fixed MiniMap not synching layer-groups before rendering.
Be a bit more efficient checking if tilesets are used by a map.
Interrupt the map image render thread if a loaded map changes.
Simplify MapImageManager::mapFileChanged().
Added noise() function to replace qDebug().

This is just so I can compile out the debug messages.  Qt has #defines to
do this as well.
Ported some MapManager code from WorldEd.