Add SMS Middleware layer.

Add fix so ordered broadcasts are delivered to system
apps first in the event of a tie. This works around
the issue where terrible apps steal SMS notifications
from the broadcast queue to simply prevent notifications
that could otherwise be removed by a toggle.

Change-Id: I4fff0c584f8fce9c5f2f4fe86a82fe6480c307c7

Conflicts:
	core/res/res/values/cm_strings.xml
Frameworks: privacy guard fix possible NPE

If the user flash a data app over recovery
(like a lot themed apps or gapps packages are doing)
the user will get into a bootloop because of an NPE
due an unknown state of the assigned userid

To fix it go same way like in PackageManagerService
Check if installUser exists if yes use
installUser.getIdentifier() to get the identifier
to call the provider settings value for the current
user.

Change-Id: Ie5f94a0d0a11ae24fdfdc8372c0433b26793b66e
am: Fix the privacy guard notification

 * The privacy guard notification was not showing everytime. Fix the
   logic and handle it in the right place so it hits both the create and
   resume startup path.

Change-Id: I80c88ffb0fcb4ed3ea64ceb228bb436975278ecc