Skip to content

Commit

Permalink
feat: Use "Unknown" when resolution is not found
Browse files Browse the repository at this point in the history
  • Loading branch information
bdlukaa committed Apr 23, 2024
1 parent 637ce60 commit 7dd956a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
8 changes: 6 additions & 2 deletions lib/screens/layouts/desktop/device_info_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,12 @@ class _DeviceInfoDialogState extends State<DeviceInfoDialog> {
),
),
_buildInfoTile(loc.uri, widget.device.uri),
_buildInfoTile(loc.resolution,
'${widget.device.resolutionX}x${widget.device.resolutionY}'),
_buildInfoTile(
loc.resolution,
'${widget.device.resolutionX ?? '${loc.unknown} '}'
'x'
'${widget.device.resolutionY ?? ' ${loc.unknown}'}',
),
_buildInfoTile(
loc.isPtzSupported, widget.device.hasPTZ ? loc.yes : loc.no),
_buildInfoTileWidget(
Expand Down
5 changes: 2 additions & 3 deletions lib/screens/layouts/desktop/stream_data.dart
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,8 @@ class _StreamDataState extends State<StreamData> {

const borderSize = 4.0;

//This, basically, would
// contain all the information about this stream - and provide
// more options, such as adding/changing overlays.
// This, basically, would contain all the information about this stream -
// and provide more options, such as adding/changing overlays.
return AlertDialog(
title: RichText(
text: TextSpan(
Expand Down

0 comments on commit 7dd956a

Please sign in to comment.