Skip to content

Commit

Permalink
Fixed TimeOfDay formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcinusX committed Oct 19, 2017
1 parent e753553 commit 9cc27db
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/screens/weight_entry_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ class DateTimeItem extends StatelessWidget {
onTap: (() => _showTimePicker(context)),
child: new Padding(
padding: new EdgeInsets.symmetric(vertical: 8.0),
child: new Text('$time')),
child: new Text(time.format(context))),
),
],
);
Expand Down
4 changes: 2 additions & 2 deletions lib/weight_list_item.dart
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ class WeightListItem extends StatelessWidget {
textAlign: TextAlign.left,
),
new Text(
new TimeOfDay.fromDateTime(weightEntry.dateTime)
.toString(),
new TimeOfDay.fromDateTime(weightEntry.dateTime).format(
context),
textScaleFactor: 0.8,
textAlign: TextAlign.right,
style: new TextStyle(
Expand Down

0 comments on commit 9cc27db

Please sign in to comment.