activity: Remove useless curly braces.

There are two ways to write lambdas that contain single statement, but one is definitely more compact and readable than the other.
This commit is contained in:
ardevd 2018-07-13 10:11:49 +02:00
parent d54b666d02
commit 57740fc0cc

View file

@ -187,17 +187,11 @@ public class PassCodeActivity extends AppCompatActivity {
setOnKeyListener(2);
setOnKeyListener(3);
mPassCodeEditTexts[1].setOnFocusChangeListener((v, hasFocus) -> {
onPassCodeEditTextFocusChange(1);
});
mPassCodeEditTexts[1].setOnFocusChangeListener((v, hasFocus) -> onPassCodeEditTextFocusChange(1));
mPassCodeEditTexts[2].setOnFocusChangeListener((v, hasFocus) -> {
onPassCodeEditTextFocusChange(2);
});
mPassCodeEditTexts[2].setOnFocusChangeListener((v, hasFocus) -> onPassCodeEditTextFocusChange(2));
mPassCodeEditTexts[3].setOnFocusChangeListener((v, hasFocus) -> {
onPassCodeEditTextFocusChange(3);
});
mPassCodeEditTexts[3].setOnFocusChangeListener((v, hasFocus) -> onPassCodeEditTextFocusChange(3));
}
private void onPassCodeEditTextFocusChange(final int passCodeIndex) {