Edited to allow targetting API > 10