aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity
diff options
context:
space:
mode:
authorRoy Ben Shabat <Roy.mail.net@gmail.com>2025-03-26 15:45:11 +0200
committerRoy Ben Shabat <Roy.mail.net@gmail.com>2025-03-26 15:45:11 +0200
commit6f9ecad11d3b73f67baedaef00e4df80cb0d644c (patch)
treeab34140f3b0e8abd52298fff97906787a890377c /Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity
parent3a6dea9cf60040d6c0a267cbb1cdc9396a074f0c (diff)
downloadTango-6f9ecad11d3b73f67baedaef00e4df80cb0d644c.tar.gz
Tango-6f9ecad11d3b73f67baedaef00e4df80cb0d644c.zip
Removed Wifi from Eureka.
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity/DefaultConnectivityProvider.cs29
1 files changed, 22 insertions, 7 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity/DefaultConnectivityProvider.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity/DefaultConnectivityProvider.cs
index a2275a72d..a55506be6 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity/DefaultConnectivityProvider.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Connectivity/DefaultConnectivityProvider.cs
@@ -16,6 +16,7 @@ using Tango.Core.Commands;
using Tango.Core.Cryptography;
using Tango.PPC.Common;
using Tango.PPC.Common.Application;
+using Tango.PPC.Common.Build;
using Tango.PPC.Common.Connection;
using Tango.PPC.Common.Connectivity;
using Tango.PPC.Common.Notifications;
@@ -34,6 +35,7 @@ namespace Tango.PPC.UI.Connectivity
private System.Timers.Timer _lanUpdateTimer;
private WiFiNetwork _connectedNetwork;
private PPCSettings _settings;
+ private IBuildProvider _buildProvider;
/// <summary>
/// Occurs when the connectivity provider state has changed (e.g network connected/disconnected).
@@ -46,7 +48,10 @@ namespace Tango.PPC.UI.Connectivity
/// </summary>
public bool IsConnected
{
- get { return _isConnected; }
+ get
+ {
+ return _buildProvider.IsEureka ? true : _isConnected;
+ }
private set { _isConnected = value; RaisePropertyChangedAuto(); }
}
@@ -56,7 +61,10 @@ namespace Tango.PPC.UI.Connectivity
/// </summary>
public bool IsLanConnected
{
- get { return _isLanConnected; }
+ get
+ {
+ return _buildProvider.IsEureka ? true : _isLanConnected;
+ }
private set { _isLanConnected = value; RaisePropertyChangedAuto(); }
}
@@ -98,10 +106,11 @@ namespace Tango.PPC.UI.Connectivity
/// <summary>
/// Initializes a new instance of the <see cref="DefaultConnectivityProvider"/> class.
/// </summary>
- public DefaultConnectivityProvider(IPPCApplicationManager applicationManager, INotificationProvider notificationProvider, IMachineProvider machineProvider)
+ public DefaultConnectivityProvider(IPPCApplicationManager applicationManager, INotificationProvider notificationProvider, IMachineProvider machineProvider, IBuildProvider buildProvider)
{
_cryptographer = new Rfc2898Cryptographer();
+ _buildProvider = buildProvider;
_notification = notificationProvider;
_machineProvider = machineProvider;
@@ -112,9 +121,11 @@ namespace Tango.PPC.UI.Connectivity
AvailableWiFiNetworksViewSource.SortDescriptions.Add(new SortDescription(nameof(WiFiNetwork.IsConnected), ListSortDirection.Descending));
AvailableWiFiNetworksViewSource.SortDescriptions.Add(new SortDescription(nameof(WiFiNetwork.SignalStrength), ListSortDirection.Descending));
- _wifi = new Wifi();
-
- applicationManager.ApplicationReady += ApplicationManager_Ready;
+ if (!_buildProvider.IsEureka)
+ {
+ _wifi = new Wifi();
+ applicationManager.ApplicationReady += ApplicationManager_Ready;
+ }
ConnectToWiFiCommand = new RelayCommand<WiFiNetwork>(async (x) =>
{
@@ -251,7 +262,11 @@ namespace Tango.PPC.UI.Connectivity
return Task.Factory.StartNew(() =>
{
AvailableWiFiNetworks.Clear();
- GetAvailableWiFiNetworks().Wait();
+
+ if (!_buildProvider.IsEureka)
+ {
+ GetAvailableWiFiNetworks().Wait();
+ }
});
}