Reduce number of calls to getApplicationInfo

Converted PrivacyApplication calls to PackageManager#getApplicationInfo
to lazy and removed sort by app name in PrivacyDialogBuilder (only the
actual dialog needs that sort). This makes it so the calls to
getApplicationInfo are only realized when needed.

Test: manual using trace-ipc. In one minute of usage, calls are reduced
from ~6000 to 7.
Test: atest
Test: manual, no change in observed behavior
Bug: 122878595

Change-Id: Iff4d2b27b8210687079cb12d1bbae83ba33f8392
4 files changed