Skip to content

Commit

Permalink
Handle null audio device in Settings (#1196)
Browse files Browse the repository at this point in the history
* handle null audio device option

* Update SettingsView.kt
  • Loading branch information
AnonymousWalker authored Dec 5, 2024
1 parent ba4d243 commit 97dbd95
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,9 @@ class SettingsView : View() {

buttonCell = IconComboBoxCell(FontIcon(MaterialDesign.MDI_VOLUME_HIGH))
overrideDefaultKeyEventHandler {
viewModel.updateOutputDevice(it)
it?.let {
viewModel.updateOutputDevice(it)
}
}
outputDeviceLoadingProperty.bind(showingProperty())
}
Expand Down Expand Up @@ -217,7 +219,9 @@ class SettingsView : View() {

buttonCell = IconComboBoxCell(FontIcon(MaterialDesign.MDI_MICROPHONE))
overrideDefaultKeyEventHandler {
viewModel.updateInputDevice(it)
it?.let {
viewModel.updateInputDevice(it)
}
}
inputDeviceLoadingProperty.bind(showingProperty())
}
Expand Down

0 comments on commit 97dbd95

Please sign in to comment.