improved element event listening