diff --git a/fastlane/metadata/android/en-US/changelogs/7.txt b/fastlane/metadata/android/en-US/changelogs/7.txt new file mode 100644 index 0000000000000000000000000000000000000000..cb6b88a5e99b45d1440e73e07be7c55f25777c52 --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/7.txt @@ -0,0 +1 @@ +Fix cells borders. diff --git a/fastlane/metadata/android/fr-FR/changelogs/7.txt b/fastlane/metadata/android/fr-FR/changelogs/7.txt new file mode 100644 index 0000000000000000000000000000000000000000..4a6d23b7011eb42ad91b27479c8b1a2ec98f82f0 --- /dev/null +++ b/fastlane/metadata/android/fr-FR/changelogs/7.txt @@ -0,0 +1 @@ +Correction sur les bordures des cellules. diff --git a/lib/ui/widgets/game/cell.dart b/lib/ui/widgets/game/cell.dart index 4452b3a04c2a34c5db783eef0f27af52ee7aa269..08385db862b7f9c526b51e88d06547080ac1e550 100644 --- a/lib/ui/widgets/game/cell.dart +++ b/lib/ui/widgets/game/cell.dart @@ -157,26 +157,24 @@ class CellWidget extends StatelessWidget { borders = Border( top: BorderSide( width: cellBorderWidth, - color: (hasBlockBorderTop || - (((cell.location.row) % activity.board.boardSizeVertical) == 0)) + color: (hasBlockBorderTop || (cell.location.row == 0)) ? cellBorderDarkColor : cellBorderLightColor), left: BorderSide( width: cellBorderWidth, - color: (hasBlockBorderLeft || - (((cell.location.col) % activity.board.boardSizeHorizontal) == 0)) + color: (hasBlockBorderLeft || (cell.location.col == 0)) ? cellBorderDarkColor : cellBorderLightColor), right: BorderSide( width: cellBorderWidth, color: (hasBlockBorderRight || - ((((cell.location.col) + 1) % activity.board.boardSizeHorizontal) == 0)) + ((cell.location.col + 1) == activity.board.boardSizeHorizontal)) ? cellBorderDarkColor : cellBorderLightColor), bottom: BorderSide( width: cellBorderWidth, color: (hasBlockBorderBottom || - ((((cell.location.row) + 1) % activity.board.boardSizeVertical) == 0)) + ((cell.location.row + 1) == activity.board.boardSizeVertical)) ? cellBorderDarkColor : cellBorderLightColor), ); diff --git a/lib/ui/widgets/game/game_board.dart b/lib/ui/widgets/game/game_board.dart index fc1dc77db8c367ae4c9e3ea6e659c493e45c61df..50bed58b7220dcb4c21a9203598d24d08b5e8ae2 100644 --- a/lib/ui/widgets/game/game_board.dart +++ b/lib/ui/widgets/game/game_board.dart @@ -47,36 +47,30 @@ class GameBoardWidget extends StatelessWidget { children: [ CellWidget( cell: currentActivity.board.get(CellLocation.go(row, col)), - hasBlockBorderBottom: - row == currentActivity.board.boardSizeVertical || - currentActivity.board - .get(CellLocation.go(row, col)) - .blockId != - currentActivity.board - .get(CellLocation.go(row + 1, col)) - .blockId, - hasBlockBorderLeft: col == 0 || + hasBlockBorderBottom: currentActivity.board + .get(CellLocation.go(row, col)) + .blockId != currentActivity.board - .get(CellLocation.go(row, col)) - .blockId != - currentActivity.board - .get(CellLocation.go(row, col - 1)) - .blockId, - hasBlockBorderRight: - col == currentActivity.board.boardSizeVertical || - currentActivity.board - .get(CellLocation.go(row, col)) - .blockId != - currentActivity.board - .get(CellLocation.go(row, col + 1)) - .blockId, - hasBlockBorderTop: row == 0 || + .get(CellLocation.go(row + 1, col)) + .blockId, + hasBlockBorderLeft: currentActivity.board + .get(CellLocation.go(row, col)) + .blockId != currentActivity.board - .get(CellLocation.go(row, col)) - .blockId != - currentActivity.board - .get(CellLocation.go(row - 1, col)) - .blockId, + .get(CellLocation.go(row, col - 1)) + .blockId, + hasBlockBorderRight: currentActivity.board + .get(CellLocation.go(row, col)) + .blockId != + currentActivity.board + .get(CellLocation.go(row, col + 1)) + .blockId, + hasBlockBorderTop: currentActivity.board + .get(CellLocation.go(row, col)) + .blockId != + currentActivity.board + .get(CellLocation.go(row - 1, col)) + .blockId, ) ], ), diff --git a/pubspec.yaml b/pubspec.yaml index 04dbd7922ebae44347ac77b7665865c8f2170950..b3081203220e5db6c3ec32fed40ee9b4ff1e0fb0 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -3,7 +3,7 @@ description: A suguru game application. publish_to: "none" -version: 0.0.6+6 +version: 0.0.7+7 environment: sdk: "^3.0.0"