Fix Settings crash when click uninstall button

When mPackageName is null, mFinish is true. OnResume() doesn't
invoke refreshUI(). It causes uninstall button is still enabled.
The solution is hiding AppButtonsPreference when mFinish is true.

Fixes: 138524326
Test: make RunSettingsRoboTests ROBOTEST_FILTER
Change-Id: I9759e53f002afbd4c88d8d536df3bf01c343135e
(cherry picked from commit 88228c33994fe963022b950ff4affc81d4bf3021)
2 files changed