Possibly fixed listener class, not yet tested