adding callbacks (not really finished, but WEEE)