Merge "Merging Motorola's patch to disable apps when is safe mode." into ub-now-master