Make granting default SMS and Phone permissions robust

The default dialer and sms apps are provided by the telecomm
stak which is brought up asynchronously as a service to which
the system binds. Hence, by the time we grant default permissions
this service is not bound and we do not know the default dialer
(accidentally the default SMS app is available before the service
is up). Now the default permission grant code is robust to handle
both cases of the default sms and phone apps being available
at grant time or asynchronously.

bug:22208642

Change-Id: I6385a0432368731aa9caea046d57eccbfb5abac0
2 files changed