feat(bluetooth): use spinner widget from libcosmic for connecting and pairing states
This commit is contained in:
parent
c2a00a36a8
commit
1f7c59fb2b
1 changed files with 6 additions and 8 deletions
|
|
@ -21,7 +21,7 @@ use cosmic::{
|
||||||
widget::{Column, column, container, row},
|
widget::{Column, column, container, row},
|
||||||
},
|
},
|
||||||
theme,
|
theme,
|
||||||
widget::{button, divider, icon, scrollable, text},
|
widget::{button, divider, icon, indeterminate_circular, scrollable, text},
|
||||||
};
|
};
|
||||||
use futures::FutureExt;
|
use futures::FutureExt;
|
||||||
use std::{collections::HashMap, sync::LazyLock, time::Duration};
|
use std::{collections::HashMap, sync::LazyLock, time::Duration};
|
||||||
|
|
@ -367,14 +367,12 @@ impl cosmic::Application for CosmicBluetoothApplet {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
BluerDeviceStatus::Paired => {}
|
BluerDeviceStatus::Paired => {}
|
||||||
BluerDeviceStatus::Connecting | BluerDeviceStatus::Disconnecting => {
|
BluerDeviceStatus::Connecting
|
||||||
row = row.push(
|
| BluerDeviceStatus::Disconnecting
|
||||||
icon::from_name("process-working-symbolic")
|
| BluerDeviceStatus::Pairing => {
|
||||||
.size(24)
|
row = row.push(indeterminate_circular().size(24.0));
|
||||||
.symbolic(true),
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
BluerDeviceStatus::Disconnected | BluerDeviceStatus::Pairing => continue,
|
BluerDeviceStatus::Disconnected => continue,
|
||||||
}
|
}
|
||||||
|
|
||||||
known_bluetooth.push(
|
known_bluetooth.push(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue