Commit 0b75826d authored by rakam's avatar rakam
Browse files

Fix bug in MatchScoreView

parent 1fcb544f
......@@ -150,7 +150,6 @@ public class FileManager {
public static void deleteLast(Context context) {
String s = ReadScore(context);
if (s.length() > 5) {
Toast.makeText(context, s, Toast.LENGTH_SHORT).show();
s = s.substring(0, s.length() - 1);
}
deleteFile(context);
......
......@@ -97,6 +97,10 @@ public class MatchScoreView extends LinearLayout {
setScoreColumns.add(newSetScoreColumn);
addView(newSetScoreColumn, getChildCount() - 1);
}
while (setScoreColumns.size() > setId + 1) {
removeView(setScoreColumns.get(setScoreColumns.size() - 1));
setScoreColumns.remove(setScoreColumns.size() - 1);
}
setScoreColumns.get(setId).setScore(gameA, gameB);
setScore(scoreA, scoreB);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment