Switched api level to support 4.0 and above