Last active
July 28, 2020 21:56
-
-
Save Meherdeep/57a76728092991c78600697ab3237571 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Widget _viewRows() { | |
final views = _getRenderViews(); | |
switch (views.length) { | |
case 1: | |
return Container( | |
child: Column( | |
children: <Widget>[_videoView(views[0])], | |
)); | |
case 2: | |
return Container( | |
child: Column( | |
children: <Widget>[ | |
_expandedVideoRow([views[0]]), | |
_expandedVideoRow([views[1]]) | |
], | |
)); | |
case 3: | |
return Container( | |
child: Column( | |
children: <Widget>[ | |
_expandedVideoRow(views.sublist(0, 2)), | |
_expandedVideoRow(views.sublist(2, 3)) | |
], | |
)); | |
case 4: | |
return Container( | |
child: Column( | |
children: <Widget>[ | |
_expandedVideoRow(views.sublist(0, 2)), | |
_expandedVideoRow(views.sublist(2, 4)) | |
], | |
)); | |
default: | |
} | |
return Container(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment