add some brackets

This commit is contained in:
tibbi 2016-03-22 20:49:49 +01:00
parent 9dfe89ba6b
commit 5c144a607b

View File

@ -270,13 +270,15 @@ public class MainActivity extends AppCompatActivity
@Override @Override
public void onItemCheckedStateChanged(ActionMode mode, int position, long id, boolean checked) { public void onItemCheckedStateChanged(ActionMode mode, int position, long id, boolean checked) {
if (checked) if (checked) {
selectedItemsCnt++; selectedItemsCnt++;
else } else {
selectedItemsCnt--; selectedItemsCnt--;
}
if (selectedItemsCnt > 0) if (selectedItemsCnt > 0) {
mode.setTitle(String.valueOf(selectedItemsCnt)); mode.setTitle(String.valueOf(selectedItemsCnt));
}
mode.invalidate(); mode.invalidate();
} }