mirror of
https://github.com/Xetibo/ReSet.git
synced 2025-04-08 22:52:01 +02:00
merge dashie
This commit is contained in:
parent
a3866294af
commit
55a6e247fa
|
@ -5,7 +5,7 @@ use std::time::{Duration, SystemTime};
|
|||
|
||||
use adw::glib;
|
||||
use adw::glib::Object;
|
||||
use adw::prelude::ComboRowExt;
|
||||
use adw::prelude::{ComboRowExt, ListModelExtManual};
|
||||
use adw::subclass::prelude::ObjectSubclassIsExt;
|
||||
use dbus::blocking::Connection;
|
||||
use dbus::message::SignalArgs;
|
||||
|
@ -13,7 +13,7 @@ use dbus::{Error, Path};
|
|||
use glib::{clone, Cast};
|
||||
use gtk::glib::Variant;
|
||||
use gtk::prelude::{ActionableExt, BoxExt, ListBoxRowExt, WidgetExt};
|
||||
use gtk::{gio, StringObject};
|
||||
use gtk::{gio, StringObject, Widget};
|
||||
use ReSet_Lib::bluetooth::bluetooth::{BluetoothAdapter, BluetoothDevice};
|
||||
use ReSet_Lib::signals::{BluetoothDeviceAdded, BluetoothDeviceChanged, BluetoothDeviceRemoved};
|
||||
|
||||
|
@ -58,7 +58,13 @@ fn setupCallbacks(
|
|||
imp.resetBluetoothSwitch.connect_state_set(move |_, state| {
|
||||
if !state {
|
||||
let imp = bluetooth_box_ref.imp();
|
||||
imp.resetBluetoothConnectedDevices.remove_all();
|
||||
for x in imp.resetBluetoothConnectedDevices.observe_children().iter::<Object>() {
|
||||
if let Ok(entry) = x { // todo test this
|
||||
if let Some(item) = entry.downcast_ref::<Widget>() {
|
||||
imp.resetBluetoothAvailableDevices.remove(item);
|
||||
}
|
||||
}
|
||||
};
|
||||
listeners.bluetooth_listener.store(false, Ordering::SeqCst);
|
||||
set_adapter_enabled(
|
||||
imp.resetCurrentBluetoothAdapter.borrow().path.clone(),
|
||||
|
|
|
@ -204,9 +204,7 @@ pub fn click_new_network(entry: Arc<WifiEntry>) {
|
|||
let imp = entry_ref.imp();
|
||||
imp.resetWifiPopup.popdown();
|
||||
imp.resetWifiEditButton.set_sensitive(true);
|
||||
imp.resetWifiConnected
|
||||
.get()
|
||||
.set_from_icon_name(Some("network-wireless-connected-symbolic"));
|
||||
imp.resetWifiConnected.set_text("Connected");
|
||||
imp.connected.replace(true);
|
||||
});
|
||||
});
|
||||
|
|
|
@ -12,9 +12,7 @@ use dbus::arg::PropMap;
|
|||
use glib::{clone, PropertySet};
|
||||
use gtk::prelude::{ButtonExt, EditableExt, WidgetExt};
|
||||
use ReSet_Lib::network::connection::{Connection, DNSMethod4, DNSMethod6, Enum, TypeSettings};
|
||||
use ReSet_Lib::network::network::AccessPoint;
|
||||
use IpProtocol::{IPv4, IPv6};
|
||||
use ReSet_Lib::network::connection::{Connection, DNSMethod4, DNSMethod6, Enum, TypeSettings};
|
||||
|
||||
use crate::components::wifi::utils::IpProtocol;
|
||||
use crate::components::wifi::wifiAddressEntry::WifiAddressEntry;
|
||||
|
|
Loading…
Reference in a new issue