Improving the performance of ultrafast microchannel-plate photomultipliers in time-correlated photon counting by pulse pre-shaping