Strange fly behaviour

Strange fly behaviour

Observation - Strange fly behaviour - UK and Ireland. Description: The day was cold and grey with light rain and I spotted a fly roosting, head down, on the outside of

The day was cold and grey with light rain and I spotted a fly roosting, head down, on the outside of the kitchen window frame. The kitchen faces north and there must have been a southerly component to the weather flow because no rain was falling on the window.
The fly had a droplet of clear liquid hanging from its face, but the next time I looked, the droplet was not there. For some time I watched the fly and the liquid appeared to come from its mouth parts. The droplet seemed to be produced and reabsorbed on a slow repeat cycle, every couple of minutes. There was no rainwater on the window, so the liquid could not have been water trickling onto and dripping from, the fly.
How long this went on for I can't tell, but I watched the process, on and off, for at least fifteen minutes before the fly disappeared. Can anyone explain what I saw, or thought I saw?
The attached photograph was captured through the double glazing panes.