resetSizes method
Resets the size of all the views.
Implementation
void resetSizes() {
if (views.length == 2 &&
models.settings.dashboard.splitMode == SplitMode.horizontal) {
verticalController.setRatios([0.5, 0.5]);
} else if (views.length > 2) {
verticalController.setRatios([0.5, 0.5]);
}
if (views.length == 2 &&
models.settings.dashboard.splitMode == SplitMode.vertical) {
horizontalController1.setRatios([0.5, 0.5]);
} else if (views.length > 2) {
horizontalController1.setRatios([0.5, 0.5]);
}
if (views.length == 4) horizontalController2.setRatios([0.5, 0.5]);
if (views.length == 8) {
horizontalController2.setRatios([0.5, 0.5]);
horizontalController3.setRatios([0.5, 0.5]);
horizontalController4.setRatios([0.5, 0.5]);
verticalController.setRatios([0.5, 0.5]);
verticalController2.setRatios([0.5, 0.5]);
}
}