Implement custom event dispatcher, which provides events batching

[#51140737]
Add automated tests of new event dispatcher

[#51140737]
Use new event dispatcher in MD2D Modeler

[#51140737]
Simplify removeAminoAcids in genetic engine due to new event dispatcher

[#51140737]