main window: doc index loading: never emit the signal index-loading-end more than once

Signed-off-by: Jerome Flesch <jflesch@gmail.com>
Main window: Index update: Add a weird hack to make sure Gtk has enough CPU time while updating the index

Signed-off-by: Jerome Flesch <jflesch@gmail.com>