Add flag for disabling next and previous image preloading