Fix some Android Studio warnings.

This commit is contained in:
Peter Osterlund
2019-03-17 11:23:43 +01:00
parent bd99154def
commit eaadffa6b0
87 changed files with 652 additions and 659 deletions

View File

@@ -161,7 +161,7 @@ public class ChessBoard extends View {
}
}
private final void drawPiece(Canvas canvas, int xCrd, int yCrd, int p) {
private void drawPiece(Canvas canvas, int xCrd, int yCrd, int p) {
String ps;
switch (p) {
case Piece.EMPTY:
@@ -218,10 +218,10 @@ public class ChessBoard extends View {
}
}
private final int getXCrd(int x) {
private int getXCrd(int x) {
return x0 + sqSize * (flipped ? 7 - x : x);
}
private final int getYCrd(int y) {
private int getYCrd(int y) {
return y0 + sqSize * (flipped ? y : (7 - y));
}

View File

@@ -134,7 +134,7 @@ public class CuckooChess extends Activity implements GUIInterface {
tmp = settings.getString("numUndo", null);
if (tmp != null) numUndo = tmp;
}
List<String> posHistStr = new ArrayList<String>();
List<String> posHistStr = new ArrayList<>();
posHistStr.add(fen);
posHistStr.add(moves);
posHistStr.add(numUndo);