Merge changes Id3c16654,I57d8730e into udc-dev

* changes:
  Simplify coexistence gating logic
  Migrate setApplicationHidden to the policy engine