pick code from android 4.2, fix media scanner slow issue

MIUI-14439

Change-Id: Ia1a2d381e2ab8f614c752db62ad92d4bc0ff5773
Ref-Id: I67a008073070dfb48c3fb5d3a522dfd00a5c3a3c

Conflicts:

	framework.jar.out/smali/android/media/MediaScanner.smali