Kill floating activities running in the same thread when tapping outside

This change makes all activities from the same app to be finished when we tap outside the halo window. Other apps running in different threads
(floating or not) won't be finished.

Port from here: https://github.com/ParanoidAndroid/android_frameworks_base/commit/f489f45ab2ba5dd4991c241917f7f4b0fd74b884

Change-Id: Ie6d6f46b2e23be60f991520ed480c2866fb2d0e3
Media process is crashing with NullPointer exception

Sometime, while creating thumnails list of media files in
compose MMS->attach file,  filepath may be null due to
synchronization issue.
Adding NULL check to avoid NUllPointer exception.

Change-Id: Id6cf5612a959b3ae15b44bc60dbbcbe40c624f09
CRs-Fixed: 636494
Merge "Media process is crashing with NullPointer exception" into kitkat
Merge "Kill floating activities running in the same thread when tapping outside" into kitkat
Merge branch 'kitkat' of https://github.com/AOSPA/android_frameworks_base into kitkat

Signed-off-by: houst0nn <houstonn@gmail.com>

Conflicts:
	core/java/android/provider/Settings.java

Change-Id: Ia8b4f44a08396b7754799d07a6473aa028d0b97d