Added docs for the task tile methods
This commit is contained in:
parent
578c6dd57f
commit
fe316b336e
2 changed files with 5 additions and 2 deletions
|
|
@ -54,13 +54,13 @@ class ActionButton extends StatelessWidget {
|
|||
color: color,
|
||||
borderRadius: BorderRadius.circular(radius),
|
||||
),
|
||||
child: getButtonBody(),
|
||||
child: buildButtonBody(),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/// Returns the button body.
|
||||
Widget getButtonBody() {
|
||||
Widget buildButtonBody() {
|
||||
final children = <Widget>[];
|
||||
if (leadingIconData != null) {
|
||||
children.addAll([
|
||||
|
|
|
|||
|
|
@ -61,6 +61,7 @@ class TaskListTile extends StatelessWidget {
|
|||
);
|
||||
}
|
||||
|
||||
/// Builds the section that contains the task's event and its text.
|
||||
Widget buildTextSection() {
|
||||
return Expanded(
|
||||
flex: 6,
|
||||
|
|
@ -91,6 +92,7 @@ class TaskListTile extends StatelessWidget {
|
|||
);
|
||||
}
|
||||
|
||||
/// Builds the section that contains the 3 buttons for the tile.
|
||||
Widget buildButtonSection() {
|
||||
return Expanded(
|
||||
flex: 5,
|
||||
|
|
@ -130,6 +132,7 @@ class TaskListTile extends StatelessWidget {
|
|||
);
|
||||
}
|
||||
|
||||
/// Builds the badge that showcases the tasks priority.
|
||||
Widget buildBadge() {
|
||||
final badgeColor = getColorFromPriority(task.priority);
|
||||
return Container(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue