Resolves #486 Fix for very small screens

This commit is contained in:
Yegor Vialov 2019-10-29 17:44:18 +00:00
parent 9c42ad687d
commit ced008a7c1
2 changed files with 5 additions and 3 deletions

View File

@ -50,8 +50,6 @@ class _EntityViewPageState extends State<EntityViewPage> {
leading: IconButton(icon: Icon(Icons.arrow_back), onPressed: (){ leading: IconButton(icon: Icon(Icons.arrow_back), onPressed: (){
Navigator.pop(context); Navigator.pop(context);
}), }),
// Here we take the value from the MyHomePage object that was created by
// the App.build method, and use it to set our appbar title.
title: new Text("${entity.displayName}"), title: new Text("${entity.displayName}"),
), ),
body: body, body: body,

View File

@ -86,7 +86,11 @@ class RenderCustomLayoutBox extends RenderBox
int columnsCount; int columnsCount;
List<double> columnXPositions = []; List<double> columnXPositions = [];
List<double> columnYPositions = []; List<double> columnYPositions = [];
columnsCount = (constraints.maxWidth ~/ this.minColumnWidth); if (constraints.maxWidth < this.minColumnWidth) {
columnsCount = 1;
} else {
columnsCount = (constraints.maxWidth ~/ this.minColumnWidth);
}
if (childCount == 0 || columnsCount == 0) { if (childCount == 0 || columnsCount == 0) {
size = constraints.biggest; size = constraints.biggest;
assert(size.isFinite); assert(size.isFinite);