Fix P2P PIN accept button greyed out incorrectly on config change

The P2P PIN accept button in the P2P invitation dialog should be greyed
out if the PIN is not 4 or 8 digits in length. However, if the correct
number of digits is inputted and then a configuration change reloads the
dialog (e.g. light -> dark mode), then the accept button is still greyed
out upon reload. Add an extra check when reloading the dialog to enable
the button if the pre-existing input is the correct length.

Bug: 292441663
Test: manually verify using adb shell cmd wifi
launch-dialog-p2p-invitation-received Device -p -c 0, input 4 digits to
PIN entry, change device from light->dark mode, verify Accept button is
not greyed out upon reloading the dialog.

Change-Id: Ia90f7dd23316cc0d04a5326dbd27e771ef77af1d
1 file changed