public MainPageModel() { LumixManager = new LumixManager(CultureInfo.CurrentCulture.TwoLetterISOLanguageName, network); LumixManager.DeviceDiscovered += Lumix_DeviceDiscovered; var cameraRefreshTimer = new DispatcherTimer { Interval = TimeSpan.FromSeconds(5) }; cameraRefreshTimer.Tick += CameraRefreshTimer_Tick; cameraRefreshTimer.Start(); ConnectableDevices.CollectionChanged += ConnectableDevices_CollectionChanged; wifi.AutoconnectAlways = GeneralSettings.WiFiAutoconnectAlways; foreach (var ap in GeneralSettings.WiFiAutoconnectAccessPoints.Value) { wifi.AutoconnectAccessPoints.Add(ap); } wifi.AutoconnectAlways = GeneralSettings.WiFiAutoconnectAlways; wifi.PropertyChanged += Wifi_PropertyChanged; wifi.AccessPointsUpdated += Wifi_AccessPointsUpdated; WifiAutoconnectAccessPoints.CollectionChanged += WifiAutoconnectAccessPoints_CollectionChanged; WifiAutoconnectAccessPoints.AddRange(GeneralSettings.WiFiAutoconnectAccessPoints.Value); }
public MainPageModel() { wifi.AutoconnectAlways = GeneralSettings.WiFiAutoconnectAlways; foreach (var ap in GeneralSettings.WiFiAutoconnectAccessPoints.Value) { wifi.AutoconnectAccessPoints.Add(ap); } wifi.AutoconnectAlways = GeneralSettings.WiFiAutoconnectAlways; wifi.PropertyChanged += Wifi_PropertyChanged; wifi.AccessPointsUpdated += Wifi_AccessPointsUpdated; WifiAutoconnectAccessPoints.CollectionChanged += WifiAutoconnectAccessPoints_CollectionChanged; WifiAutoconnectAccessPoints.AddRange(GeneralSettings.WiFiAutoconnectAccessPoints.Value); ConnectionsManager = new ConnectionsManager(this, CultureInfo.CurrentUICulture); }