Added end functions to dialogue frames