Added a listener to the lattice.