It's an anti-mosquito spray, a very common procedure around Asia and not just on BA. It is harmless apart from contact lenses (and I'm not even sure about that, I'm sure my contacts have survived contact, as it were). It is d-phenothrin (Phenothrin)'and you can look that up if you want to be reassured about its safety.
The message you heard wasn't the correct one, at least in terms of how it appeared in your post. There is usually a pre-amble which points out it is a legal requirement, and that the purpose is to prevent the spread of disease between countries. BA doesn't have a choice about this, in some countries the first thing the IFM has to do when opening the doors for arrival is present at least one emptied spray canister per aisle (so 4 plus on a A380).