This commit is contained in:
Daniel 2024-11-08 15:33:53 -05:00
parent de3726bfd0
commit 2d4cba8371
5 changed files with 157 additions and 124 deletions

View file

@ -17,7 +17,7 @@ class Stillbox extends ChangeNotifier {
final storage = Storer(); final storage = Storer();
final channel = Socketer(); final channel = Socketer();
late TalkgroupCache tgCache; late TalkgroupCache tgCache;
late Version version; late ServerInfo version;
bool connected = false; bool connected = false;
late Uri _wsUri; late Uri _wsUri;
LiveState _state = LiveState.LS_LIVE; LiveState _state = LiveState.LS_LIVE;
@ -50,7 +50,7 @@ class Stillbox extends ChangeNotifier {
String socketUrl; String socketUrl;
final port = (baseUri!.hasPort ? ':${baseUri!.port}' : ''); final port = (baseUri!.hasPort ? ':${baseUri!.port}' : '');
socketUrl = socketUrl =
'${baseUri!.scheme == 'http' ? 'ws' : 'wss'}://${baseUri!.host}$port/ws'; '${baseUri!.scheme == 'http' ? 'ws' : 'wss'}://${baseUri!.host}$port/api/ws';
_wsUri = Uri.parse(socketUrl); _wsUri = Uri.parse(socketUrl);
} else { } else {
baseUri = null; baseUri = null;
@ -65,7 +65,7 @@ class Stillbox extends ChangeNotifier {
if (baseUriString.endsWith('/')) { if (baseUriString.endsWith('/')) {
baseUriString = baseUriString.substring(0, baseUriString.length - 1); baseUriString = baseUriString.substring(0, baseUriString.length - 1);
} }
Uri loginUri = Uri.parse('$baseUriString/login'); Uri loginUri = Uri.parse('$baseUriString/api/login');
final form = <String, dynamic>{}; final form = <String, dynamic>{};
form['username'] = username; form['username'] = username;
form['password'] = password; form['password'] = password;
@ -145,7 +145,7 @@ class Stillbox extends ChangeNotifier {
case Message_ToClientMessage.popup: case Message_ToClientMessage.popup:
case Message_ToClientMessage.error: case Message_ToClientMessage.error:
case Message_ToClientMessage.hello: case Message_ToClientMessage.hello:
version = msg.hello.version; version = msg.hello.serverInfo;
case Message_ToClientMessage.response: case Message_ToClientMessage.response:
_handleCommandResponse(msg.response); _handleCommandResponse(msg.response);
default: default:

View file

@ -256,6 +256,7 @@ class CommandResponse extends $pb.GeneratedMessage {
class Call extends $pb.GeneratedMessage { class Call extends $pb.GeneratedMessage {
factory Call({ factory Call({
$core.String? id,
$core.String? audioName, $core.String? audioName,
$core.String? audioType, $core.String? audioType,
$0.Timestamp? dateTime, $0.Timestamp? dateTime,
@ -270,6 +271,9 @@ class Call extends $pb.GeneratedMessage {
$core.List<$core.int>? audio, $core.List<$core.int>? audio,
}) { }) {
final $result = create(); final $result = create();
if (id != null) {
$result.id = id;
}
if (audioName != null) { if (audioName != null) {
$result.audioName = audioName; $result.audioName = audioName;
} }
@ -313,18 +317,19 @@ class Call extends $pb.GeneratedMessage {
factory Call.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r); factory Call.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r);
static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Call', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create) static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Call', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create)
..aOS(1, _omitFieldNames ? '' : 'audioName', protoName: 'audioName') ..aOS(1, _omitFieldNames ? '' : 'id')
..aOS(2, _omitFieldNames ? '' : 'audioType', protoName: 'audioType') ..aOS(2, _omitFieldNames ? '' : 'audioName', protoName: 'audioName')
..aOM<$0.Timestamp>(3, _omitFieldNames ? '' : 'dateTime', subBuilder: $0.Timestamp.create) ..aOS(3, _omitFieldNames ? '' : 'audioType', protoName: 'audioType')
..a<$core.int>(4, _omitFieldNames ? '' : 'system', $pb.PbFieldType.O3) ..aOM<$0.Timestamp>(4, _omitFieldNames ? '' : 'dateTime', subBuilder: $0.Timestamp.create)
..a<$core.int>(5, _omitFieldNames ? '' : 'talkgroup', $pb.PbFieldType.O3) ..a<$core.int>(5, _omitFieldNames ? '' : 'system', $pb.PbFieldType.O3)
..a<$core.int>(6, _omitFieldNames ? '' : 'source', $pb.PbFieldType.O3) ..a<$core.int>(6, _omitFieldNames ? '' : 'talkgroup', $pb.PbFieldType.O3)
..aInt64(7, _omitFieldNames ? '' : 'frequency') ..a<$core.int>(7, _omitFieldNames ? '' : 'source', $pb.PbFieldType.O3)
..p<$fixnum.Int64>(8, _omitFieldNames ? '' : 'frequencies', $pb.PbFieldType.K6) ..aInt64(8, _omitFieldNames ? '' : 'frequency')
..p<$core.int>(9, _omitFieldNames ? '' : 'patches', $pb.PbFieldType.K3) ..p<$fixnum.Int64>(9, _omitFieldNames ? '' : 'frequencies', $pb.PbFieldType.K6)
..p<$core.int>(10, _omitFieldNames ? '' : 'sources', $pb.PbFieldType.K3) ..p<$core.int>(10, _omitFieldNames ? '' : 'patches', $pb.PbFieldType.K3)
..a<$core.int>(11, _omitFieldNames ? '' : 'duration', $pb.PbFieldType.O3) ..p<$core.int>(11, _omitFieldNames ? '' : 'sources', $pb.PbFieldType.K3)
..a<$core.List<$core.int>>(12, _omitFieldNames ? '' : 'audio', $pb.PbFieldType.OY) ..a<$core.int>(12, _omitFieldNames ? '' : 'duration', $pb.PbFieldType.O3)
..a<$core.List<$core.int>>(13, _omitFieldNames ? '' : 'audio', $pb.PbFieldType.OY)
..hasRequiredFields = false ..hasRequiredFields = false
; ;
@ -350,105 +355,114 @@ class Call extends $pb.GeneratedMessage {
static Call? _defaultInstance; static Call? _defaultInstance;
@$pb.TagNumber(1) @$pb.TagNumber(1)
$core.String get audioName => $_getSZ(0); $core.String get id => $_getSZ(0);
@$pb.TagNumber(1) @$pb.TagNumber(1)
set audioName($core.String v) { $_setString(0, v); } set id($core.String v) { $_setString(0, v); }
@$pb.TagNumber(1) @$pb.TagNumber(1)
$core.bool hasAudioName() => $_has(0); $core.bool hasId() => $_has(0);
@$pb.TagNumber(1) @$pb.TagNumber(1)
void clearAudioName() => clearField(1); void clearId() => clearField(1);
@$pb.TagNumber(2) @$pb.TagNumber(2)
$core.String get audioType => $_getSZ(1); $core.String get audioName => $_getSZ(1);
@$pb.TagNumber(2) @$pb.TagNumber(2)
set audioType($core.String v) { $_setString(1, v); } set audioName($core.String v) { $_setString(1, v); }
@$pb.TagNumber(2) @$pb.TagNumber(2)
$core.bool hasAudioType() => $_has(1); $core.bool hasAudioName() => $_has(1);
@$pb.TagNumber(2) @$pb.TagNumber(2)
void clearAudioType() => clearField(2); void clearAudioName() => clearField(2);
@$pb.TagNumber(3) @$pb.TagNumber(3)
$0.Timestamp get dateTime => $_getN(2); $core.String get audioType => $_getSZ(2);
@$pb.TagNumber(3) @$pb.TagNumber(3)
set dateTime($0.Timestamp v) { setField(3, v); } set audioType($core.String v) { $_setString(2, v); }
@$pb.TagNumber(3) @$pb.TagNumber(3)
$core.bool hasDateTime() => $_has(2); $core.bool hasAudioType() => $_has(2);
@$pb.TagNumber(3) @$pb.TagNumber(3)
void clearDateTime() => clearField(3); void clearAudioType() => clearField(3);
@$pb.TagNumber(3)
$0.Timestamp ensureDateTime() => $_ensure(2);
@$pb.TagNumber(4) @$pb.TagNumber(4)
$core.int get system => $_getIZ(3); $0.Timestamp get dateTime => $_getN(3);
@$pb.TagNumber(4) @$pb.TagNumber(4)
set system($core.int v) { $_setSignedInt32(3, v); } set dateTime($0.Timestamp v) { setField(4, v); }
@$pb.TagNumber(4) @$pb.TagNumber(4)
$core.bool hasSystem() => $_has(3); $core.bool hasDateTime() => $_has(3);
@$pb.TagNumber(4) @$pb.TagNumber(4)
void clearSystem() => clearField(4); void clearDateTime() => clearField(4);
@$pb.TagNumber(4)
$0.Timestamp ensureDateTime() => $_ensure(3);
@$pb.TagNumber(5) @$pb.TagNumber(5)
$core.int get talkgroup => $_getIZ(4); $core.int get system => $_getIZ(4);
@$pb.TagNumber(5) @$pb.TagNumber(5)
set talkgroup($core.int v) { $_setSignedInt32(4, v); } set system($core.int v) { $_setSignedInt32(4, v); }
@$pb.TagNumber(5) @$pb.TagNumber(5)
$core.bool hasTalkgroup() => $_has(4); $core.bool hasSystem() => $_has(4);
@$pb.TagNumber(5) @$pb.TagNumber(5)
void clearTalkgroup() => clearField(5); void clearSystem() => clearField(5);
@$pb.TagNumber(6) @$pb.TagNumber(6)
$core.int get source => $_getIZ(5); $core.int get talkgroup => $_getIZ(5);
@$pb.TagNumber(6) @$pb.TagNumber(6)
set source($core.int v) { $_setSignedInt32(5, v); } set talkgroup($core.int v) { $_setSignedInt32(5, v); }
@$pb.TagNumber(6) @$pb.TagNumber(6)
$core.bool hasSource() => $_has(5); $core.bool hasTalkgroup() => $_has(5);
@$pb.TagNumber(6) @$pb.TagNumber(6)
void clearSource() => clearField(6); void clearTalkgroup() => clearField(6);
@$pb.TagNumber(7) @$pb.TagNumber(7)
$fixnum.Int64 get frequency => $_getI64(6); $core.int get source => $_getIZ(6);
@$pb.TagNumber(7) @$pb.TagNumber(7)
set frequency($fixnum.Int64 v) { $_setInt64(6, v); } set source($core.int v) { $_setSignedInt32(6, v); }
@$pb.TagNumber(7) @$pb.TagNumber(7)
$core.bool hasFrequency() => $_has(6); $core.bool hasSource() => $_has(6);
@$pb.TagNumber(7) @$pb.TagNumber(7)
void clearFrequency() => clearField(7); void clearSource() => clearField(7);
@$pb.TagNumber(8) @$pb.TagNumber(8)
$core.List<$fixnum.Int64> get frequencies => $_getList(7); $fixnum.Int64 get frequency => $_getI64(7);
@$pb.TagNumber(8)
set frequency($fixnum.Int64 v) { $_setInt64(7, v); }
@$pb.TagNumber(8)
$core.bool hasFrequency() => $_has(7);
@$pb.TagNumber(8)
void clearFrequency() => clearField(8);
@$pb.TagNumber(9) @$pb.TagNumber(9)
$core.List<$core.int> get patches => $_getList(8); $core.List<$fixnum.Int64> get frequencies => $_getList(8);
@$pb.TagNumber(10) @$pb.TagNumber(10)
$core.List<$core.int> get sources => $_getList(9); $core.List<$core.int> get patches => $_getList(9);
@$pb.TagNumber(11) @$pb.TagNumber(11)
$core.int get duration => $_getIZ(10); $core.List<$core.int> get sources => $_getList(10);
@$pb.TagNumber(11)
set duration($core.int v) { $_setSignedInt32(10, v); }
@$pb.TagNumber(11)
$core.bool hasDuration() => $_has(10);
@$pb.TagNumber(11)
void clearDuration() => clearField(11);
@$pb.TagNumber(12) @$pb.TagNumber(12)
$core.List<$core.int> get audio => $_getN(11); $core.int get duration => $_getIZ(11);
@$pb.TagNumber(12) @$pb.TagNumber(12)
set audio($core.List<$core.int> v) { $_setBytes(11, v); } set duration($core.int v) { $_setSignedInt32(11, v); }
@$pb.TagNumber(12) @$pb.TagNumber(12)
$core.bool hasAudio() => $_has(11); $core.bool hasDuration() => $_has(11);
@$pb.TagNumber(12) @$pb.TagNumber(12)
void clearAudio() => clearField(12); void clearDuration() => clearField(12);
@$pb.TagNumber(13)
$core.List<$core.int> get audio => $_getN(12);
@$pb.TagNumber(13)
set audio($core.List<$core.int> v) { $_setBytes(12, v); }
@$pb.TagNumber(13)
$core.bool hasAudio() => $_has(12);
@$pb.TagNumber(13)
void clearAudio() => clearField(13);
} }
class Hello extends $pb.GeneratedMessage { class Hello extends $pb.GeneratedMessage {
factory Hello({ factory Hello({
Version? version, ServerInfo? serverInfo,
}) { }) {
final $result = create(); final $result = create();
if (version != null) { if (serverInfo != null) {
$result.version = version; $result.serverInfo = serverInfo;
} }
return $result; return $result;
} }
@ -457,7 +471,7 @@ class Hello extends $pb.GeneratedMessage {
factory Hello.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r); factory Hello.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r);
static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Hello', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create) static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Hello', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create)
..aOM<Version>(1, _omitFieldNames ? '' : 'version', subBuilder: Version.create) ..aOM<ServerInfo>(1, _omitFieldNames ? '' : 'serverInfo', subBuilder: ServerInfo.create)
..hasRequiredFields = false ..hasRequiredFields = false
; ;
@ -483,15 +497,15 @@ class Hello extends $pb.GeneratedMessage {
static Hello? _defaultInstance; static Hello? _defaultInstance;
@$pb.TagNumber(1) @$pb.TagNumber(1)
Version get version => $_getN(0); ServerInfo get serverInfo => $_getN(0);
@$pb.TagNumber(1) @$pb.TagNumber(1)
set version(Version v) { setField(1, v); } set serverInfo(ServerInfo v) { setField(1, v); }
@$pb.TagNumber(1) @$pb.TagNumber(1)
$core.bool hasVersion() => $_has(0); $core.bool hasServerInfo() => $_has(0);
@$pb.TagNumber(1) @$pb.TagNumber(1)
void clearVersion() => clearField(1); void clearServerInfo() => clearField(1);
@$pb.TagNumber(1) @$pb.TagNumber(1)
Version ensureVersion() => $_ensure(0); ServerInfo ensureServerInfo() => $_ensure(0);
} }
class UserPopup extends $pb.GeneratedMessage { class UserPopup extends $pb.GeneratedMessage {
@ -1203,12 +1217,13 @@ class Search extends $pb.GeneratedMessage {
static Search? _defaultInstance; static Search? _defaultInstance;
} }
class Version extends $pb.GeneratedMessage { class ServerInfo extends $pb.GeneratedMessage {
factory Version({ factory ServerInfo({
$core.String? serverName, $core.String? serverName,
$core.String? version, $core.String? version,
$core.String? built, $core.String? built,
$core.String? platform, $core.String? platform,
$core.String? dbSize,
}) { }) {
final $result = create(); final $result = create();
if (serverName != null) { if (serverName != null) {
@ -1223,17 +1238,21 @@ class Version extends $pb.GeneratedMessage {
if (platform != null) { if (platform != null) {
$result.platform = platform; $result.platform = platform;
} }
if (dbSize != null) {
$result.dbSize = dbSize;
}
return $result; return $result;
} }
Version._() : super(); ServerInfo._() : super();
factory Version.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r); factory ServerInfo.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r);
factory Version.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r); factory ServerInfo.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r);
static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Version', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create) static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'ServerInfo', package: const $pb.PackageName(_omitMessageNames ? '' : 'stillbox'), createEmptyInstance: create)
..aOS(1, _omitFieldNames ? '' : 'serverName') ..aOS(1, _omitFieldNames ? '' : 'serverName')
..aOS(2, _omitFieldNames ? '' : 'version') ..aOS(2, _omitFieldNames ? '' : 'version')
..aOS(3, _omitFieldNames ? '' : 'built') ..aOS(3, _omitFieldNames ? '' : 'built')
..aOS(4, _omitFieldNames ? '' : 'platform') ..aOS(4, _omitFieldNames ? '' : 'platform')
..aOS(5, _omitFieldNames ? '' : 'dbSize')
..hasRequiredFields = false ..hasRequiredFields = false
; ;
@ -1241,22 +1260,22 @@ class Version extends $pb.GeneratedMessage {
'Using this can add significant overhead to your binary. ' 'Using this can add significant overhead to your binary. '
'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. '
'Will be removed in next major version') 'Will be removed in next major version')
Version clone() => Version()..mergeFromMessage(this); ServerInfo clone() => ServerInfo()..mergeFromMessage(this);
@$core.Deprecated( @$core.Deprecated(
'Using this can add significant overhead to your binary. ' 'Using this can add significant overhead to your binary. '
'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' 'Use [GeneratedMessageGenericExtensions.rebuild] instead. '
'Will be removed in next major version') 'Will be removed in next major version')
Version copyWith(void Function(Version) updates) => super.copyWith((message) => updates(message as Version)) as Version; ServerInfo copyWith(void Function(ServerInfo) updates) => super.copyWith((message) => updates(message as ServerInfo)) as ServerInfo;
$pb.BuilderInfo get info_ => _i; $pb.BuilderInfo get info_ => _i;
@$core.pragma('dart2js:noInline') @$core.pragma('dart2js:noInline')
static Version create() => Version._(); static ServerInfo create() => ServerInfo._();
Version createEmptyInstance() => create(); ServerInfo createEmptyInstance() => create();
static $pb.PbList<Version> createRepeated() => $pb.PbList<Version>(); static $pb.PbList<ServerInfo> createRepeated() => $pb.PbList<ServerInfo>();
@$core.pragma('dart2js:noInline') @$core.pragma('dart2js:noInline')
static Version getDefault() => _defaultInstance ??= $pb.GeneratedMessage.$_defaultFor<Version>(create); static ServerInfo getDefault() => _defaultInstance ??= $pb.GeneratedMessage.$_defaultFor<ServerInfo>(create);
static Version? _defaultInstance; static ServerInfo? _defaultInstance;
@$pb.TagNumber(1) @$pb.TagNumber(1)
$core.String get serverName => $_getSZ(0); $core.String get serverName => $_getSZ(0);
@ -1293,6 +1312,15 @@ class Version extends $pb.GeneratedMessage {
$core.bool hasPlatform() => $_has(3); $core.bool hasPlatform() => $_has(3);
@$pb.TagNumber(4) @$pb.TagNumber(4)
void clearPlatform() => clearField(4); void clearPlatform() => clearField(4);
@$pb.TagNumber(5)
$core.String get dbSize => $_getSZ(4);
@$pb.TagNumber(5)
set dbSize($core.String v) { $_setString(4, v); }
@$pb.TagNumber(5)
$core.bool hasDbSize() => $_has(4);
@$pb.TagNumber(5)
void clearDbSize() => clearField(5);
} }

View file

@ -76,18 +76,19 @@ final $typed_data.Uint8List commandResponseDescriptor = $convert.base64Decode(
const Call$json = { const Call$json = {
'1': 'Call', '1': 'Call',
'2': [ '2': [
{'1': 'audioName', '3': 1, '4': 1, '5': 9, '10': 'audioName'}, {'1': 'id', '3': 1, '4': 1, '5': 9, '10': 'id'},
{'1': 'audioType', '3': 2, '4': 1, '5': 9, '10': 'audioType'}, {'1': 'audioName', '3': 2, '4': 1, '5': 9, '10': 'audioName'},
{'1': 'date_time', '3': 3, '4': 1, '5': 11, '6': '.google.protobuf.Timestamp', '10': 'dateTime'}, {'1': 'audioType', '3': 3, '4': 1, '5': 9, '10': 'audioType'},
{'1': 'system', '3': 4, '4': 1, '5': 5, '10': 'system'}, {'1': 'date_time', '3': 4, '4': 1, '5': 11, '6': '.google.protobuf.Timestamp', '10': 'dateTime'},
{'1': 'talkgroup', '3': 5, '4': 1, '5': 5, '10': 'talkgroup'}, {'1': 'system', '3': 5, '4': 1, '5': 5, '10': 'system'},
{'1': 'source', '3': 6, '4': 1, '5': 5, '10': 'source'}, {'1': 'talkgroup', '3': 6, '4': 1, '5': 5, '10': 'talkgroup'},
{'1': 'frequency', '3': 7, '4': 1, '5': 3, '10': 'frequency'}, {'1': 'source', '3': 7, '4': 1, '5': 5, '10': 'source'},
{'1': 'frequencies', '3': 8, '4': 3, '5': 3, '10': 'frequencies'}, {'1': 'frequency', '3': 8, '4': 1, '5': 3, '10': 'frequency'},
{'1': 'patches', '3': 9, '4': 3, '5': 5, '10': 'patches'}, {'1': 'frequencies', '3': 9, '4': 3, '5': 3, '10': 'frequencies'},
{'1': 'sources', '3': 10, '4': 3, '5': 5, '10': 'sources'}, {'1': 'patches', '3': 10, '4': 3, '5': 5, '10': 'patches'},
{'1': 'duration', '3': 11, '4': 1, '5': 5, '9': 0, '10': 'duration', '17': true}, {'1': 'sources', '3': 11, '4': 3, '5': 5, '10': 'sources'},
{'1': 'audio', '3': 12, '4': 1, '5': 12, '10': 'audio'}, {'1': 'duration', '3': 12, '4': 1, '5': 5, '9': 0, '10': 'duration', '17': true},
{'1': 'audio', '3': 13, '4': 1, '5': 12, '10': 'audio'},
], ],
'8': [ '8': [
{'1': '_duration'}, {'1': '_duration'},
@ -96,25 +97,27 @@ const Call$json = {
/// Descriptor for `Call`. Decode as a `google.protobuf.DescriptorProto`. /// Descriptor for `Call`. Decode as a `google.protobuf.DescriptorProto`.
final $typed_data.Uint8List callDescriptor = $convert.base64Decode( final $typed_data.Uint8List callDescriptor = $convert.base64Decode(
'CgRDYWxsEhwKCWF1ZGlvTmFtZRgBIAEoCVIJYXVkaW9OYW1lEhwKCWF1ZGlvVHlwZRgCIAEoCV' 'CgRDYWxsEg4KAmlkGAEgASgJUgJpZBIcCglhdWRpb05hbWUYAiABKAlSCWF1ZGlvTmFtZRIcCg'
'IJYXVkaW9UeXBlEjcKCWRhdGVfdGltZRgDIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3Rh' 'lhdWRpb1R5cGUYAyABKAlSCWF1ZGlvVHlwZRI3CglkYXRlX3RpbWUYBCABKAsyGi5nb29nbGUu'
'bXBSCGRhdGVUaW1lEhYKBnN5c3RlbRgEIAEoBVIGc3lzdGVtEhwKCXRhbGtncm91cBgFIAEoBV' 'cHJvdG9idWYuVGltZXN0YW1wUghkYXRlVGltZRIWCgZzeXN0ZW0YBSABKAVSBnN5c3RlbRIcCg'
'IJdGFsa2dyb3VwEhYKBnNvdXJjZRgGIAEoBVIGc291cmNlEhwKCWZyZXF1ZW5jeRgHIAEoA1IJ' 'l0YWxrZ3JvdXAYBiABKAVSCXRhbGtncm91cBIWCgZzb3VyY2UYByABKAVSBnNvdXJjZRIcCglm'
'ZnJlcXVlbmN5EiAKC2ZyZXF1ZW5jaWVzGAggAygDUgtmcmVxdWVuY2llcxIYCgdwYXRjaGVzGA' 'cmVxdWVuY3kYCCABKANSCWZyZXF1ZW5jeRIgCgtmcmVxdWVuY2llcxgJIAMoA1ILZnJlcXVlbm'
'kgAygFUgdwYXRjaGVzEhgKB3NvdXJjZXMYCiADKAVSB3NvdXJjZXMSHwoIZHVyYXRpb24YCyAB' 'NpZXMSGAoHcGF0Y2hlcxgKIAMoBVIHcGF0Y2hlcxIYCgdzb3VyY2VzGAsgAygFUgdzb3VyY2Vz'
'KAVIAFIIZHVyYXRpb26IAQESFAoFYXVkaW8YDCABKAxSBWF1ZGlvQgsKCV9kdXJhdGlvbg=='); 'Eh8KCGR1cmF0aW9uGAwgASgFSABSCGR1cmF0aW9uiAEBEhQKBWF1ZGlvGA0gASgMUgVhdWRpb0'
'ILCglfZHVyYXRpb24=');
@$core.Deprecated('Use helloDescriptor instead') @$core.Deprecated('Use helloDescriptor instead')
const Hello$json = { const Hello$json = {
'1': 'Hello', '1': 'Hello',
'2': [ '2': [
{'1': 'version', '3': 1, '4': 1, '5': 11, '6': '.stillbox.Version', '10': 'version'}, {'1': 'server_info', '3': 1, '4': 1, '5': 11, '6': '.stillbox.ServerInfo', '10': 'serverInfo'},
], ],
}; };
/// Descriptor for `Hello`. Decode as a `google.protobuf.DescriptorProto`. /// Descriptor for `Hello`. Decode as a `google.protobuf.DescriptorProto`.
final $typed_data.Uint8List helloDescriptor = $convert.base64Decode( final $typed_data.Uint8List helloDescriptor = $convert.base64Decode(
'CgVIZWxsbxIrCgd2ZXJzaW9uGAEgASgLMhEuc3RpbGxib3guVmVyc2lvblIHdmVyc2lvbg=='); 'CgVIZWxsbxI1CgtzZXJ2ZXJfaW5mbxgBIAEoCzIULnN0aWxsYm94LlNlcnZlckluZm9SCnNlcn'
'ZlckluZm8=');
@$core.Deprecated('Use userPopupDescriptor instead') @$core.Deprecated('Use userPopupDescriptor instead')
const UserPopup$json = { const UserPopup$json = {
@ -276,20 +279,21 @@ const Search$json = {
final $typed_data.Uint8List searchDescriptor = $convert.base64Decode( final $typed_data.Uint8List searchDescriptor = $convert.base64Decode(
'CgZTZWFyY2g='); 'CgZTZWFyY2g=');
@$core.Deprecated('Use versionDescriptor instead') @$core.Deprecated('Use serverInfoDescriptor instead')
const Version$json = { const ServerInfo$json = {
'1': 'Version', '1': 'ServerInfo',
'2': [ '2': [
{'1': 'server_name', '3': 1, '4': 1, '5': 9, '10': 'serverName'}, {'1': 'server_name', '3': 1, '4': 1, '5': 9, '10': 'serverName'},
{'1': 'version', '3': 2, '4': 1, '5': 9, '10': 'version'}, {'1': 'version', '3': 2, '4': 1, '5': 9, '10': 'version'},
{'1': 'built', '3': 3, '4': 1, '5': 9, '10': 'built'}, {'1': 'built', '3': 3, '4': 1, '5': 9, '10': 'built'},
{'1': 'platform', '3': 4, '4': 1, '5': 9, '10': 'platform'}, {'1': 'platform', '3': 4, '4': 1, '5': 9, '10': 'platform'},
{'1': 'db_size', '3': 5, '4': 1, '5': 9, '10': 'dbSize'},
], ],
}; };
/// Descriptor for `Version`. Decode as a `google.protobuf.DescriptorProto`. /// Descriptor for `ServerInfo`. Decode as a `google.protobuf.DescriptorProto`.
final $typed_data.Uint8List versionDescriptor = $convert.base64Decode( final $typed_data.Uint8List serverInfoDescriptor = $convert.base64Decode(
'CgdWZXJzaW9uEh8KC3NlcnZlcl9uYW1lGAEgASgJUgpzZXJ2ZXJOYW1lEhgKB3ZlcnNpb24YAi' 'CgpTZXJ2ZXJJbmZvEh8KC3NlcnZlcl9uYW1lGAEgASgJUgpzZXJ2ZXJOYW1lEhgKB3ZlcnNpb2'
'ABKAlSB3ZlcnNpb24SFAoFYnVpbHQYAyABKAlSBWJ1aWx0EhoKCHBsYXRmb3JtGAQgASgJUghw' '4YAiABKAlSB3ZlcnNpb24SFAoFYnVpbHQYAyABKAlSBWJ1aWx0EhoKCHBsYXRmb3JtGAQgASgJ'
'bGF0Zm9ybQ=='); 'UghwbGF0Zm9ybRIXCgdkYl9zaXplGAUgASgJUgZkYlNpemU=');

View file

@ -159,7 +159,7 @@ class ScannerLabel extends StatelessWidget {
child: Container( child: Container(
padding: EdgeInsets.all(20.0), padding: EdgeInsets.all(20.0),
child: Text( child: Text(
'Server info:\n${version.serverName} ${version.version}\nbuilt ${version.built}\nrunning on ${version.platform}', 'Server info:\n${version.serverName} ${version.version}\nbuilt ${version.built}\nrunning on ${version.platform}\nDB size ${version.dbSize}',
style: TextStyle(color: Colors.black), style: TextStyle(color: Colors.black),
), ),
), ),

View file

@ -24,18 +24,19 @@ message CommandResponse {
} }
message Call { message Call {
string audioName = 1; string id = 1;
string audioType = 2; string audioName = 2;
google.protobuf.Timestamp date_time = 3; string audioType = 3;
int32 system = 4; google.protobuf.Timestamp date_time = 4;
int32 talkgroup = 5; int32 system = 5;
int32 source = 6; int32 talkgroup = 6;
int64 frequency = 7; int32 source = 7;
repeated int64 frequencies = 8; int64 frequency = 8;
repeated int32 patches = 9; repeated int64 frequencies = 9;
repeated int32 sources = 10; repeated int32 patches = 10;
optional int32 duration = 11; repeated int32 sources = 11;
bytes audio = 12; optional int32 duration = 12;
bytes audio = 13;
} }
message Hello { message Hello {