chore: add debug logging for registration and call state enums

This commit is contained in:
Andrew 2026-03-30 18:33:36 +07:00
parent f64284f963
commit cf701bda8d

View file

@ -30,6 +30,9 @@ class LinphoneBridge(
private var currentCall: Call? = null private var currentCall: Call? = null
private var registrationState: RegistrationState by Delegates.observable(RegistrationState.None) { _, oldValue, newValue -> private var registrationState: RegistrationState by Delegates.observable(RegistrationState.None) { _, oldValue, newValue ->
RegistrationState.entries.forEach { e ->
Log.i(LiblinphoneFlutterPlugin.TAG, "enum dump | RegistrationState | Name: ${e.name}, Ordinal: ${e.ordinal}")
}
Log.i( Log.i(
LiblinphoneFlutterPlugin.TAG, LiblinphoneFlutterPlugin.TAG,
"registrationState delegate: oldValue: $oldValue, newValue: $newValue" "registrationState delegate: oldValue: $oldValue, newValue: $newValue"
@ -37,6 +40,9 @@ class LinphoneBridge(
onRegistrationStateChanged(newValue.ordinal) onRegistrationStateChanged(newValue.ordinal)
} }
private var callState: Call.State by Delegates.observable(Call.State.Idle) { _, oldValue, newValue -> private var callState: Call.State by Delegates.observable(Call.State.Idle) { _, oldValue, newValue ->
Call.State.entries.forEach { e ->
Log.i(LiblinphoneFlutterPlugin.TAG, "enum dump | Call.State | Name: ${e.name}, Ordinal: ${e.ordinal}")
}
Log.i( Log.i(
LiblinphoneFlutterPlugin.TAG, LiblinphoneFlutterPlugin.TAG,
"callState delegate: oldValue: $oldValue, newValue: $newValue" "callState delegate: oldValue: $oldValue, newValue: $newValue"