This fly was earlier misidentified as
Phormia reginia, Calliphoridae. This is actually a Muscidae,
Hydrotaea sp.
Muscid fly is commonly called house fly because some of the species are synanthropic. I think it is better just to refer to them as muscid fly since not all of them are synanthropic. This particular black muscid fly is commonly found in the forest including secondary forests, but are rarely seen in parks around residential areas.
They have an extremely quick reflex to camera flash just like the long-legged fly (Dolichopodidae), so quick that it the fly flew off before the actual flash fires, causing your photos to only capture the leaf or background without the fly. If you are a
strobist, you'd know that a camera flash fires two times. The first fire is called a pre-flash, used by every automatic camera system to gauge the accurate amount of flash power to produce so that the photo is not under- or over-exposed. The second fire is the actual flash that is used by the camera to capture an image on the sensor. These happen in a matter of sub-milli-secconds, As the human eye is not as responsive as this fly, we did not know it actually fired twice.
Fortunately, as technology advances, there is a trick that you can deploy if you have a camera where you can control how the flash fires. These cameras have the function to disable the pre-flash and adjust the flash power manually. For some cameras, the pre-flash can be manually fired to gauge the correct exposure, when the fly landed back on the leaf, the actual flash will be fired when you press "shoot".