aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2018-02-07 16:18:30 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2018-02-07 16:18:30 +0200
commitd27a0bac82a94b9f7cc380b03cc4c73012aaacd7 (patch)
treed60d43c48d9e8d151c3b85d00c7cdb7aea7ffb87 /Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
parentbd63d7d2f7769e5534fb9a58d97358564c2cb674 (diff)
downloadTango-d27a0bac82a94b9f7cc380b03cc4c73012aaacd7.tar.gz
Tango-d27a0bac82a94b9f7cc380b03cc4c73012aaacd7.zip
Changes Sensors Table to IOS.
Added IO TYPE field for IOS Table.
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs10
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml2
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml.cs4
3 files changed, 8 insertions, 8 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
index e1d4bc7fa..100880cec 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
@@ -209,11 +209,11 @@ namespace Tango.MachineStudio.Developer.ViewModels
set { _isSideBarOpened = value; RaisePropertyChangedAuto(); }
}
- private ObservableCollection<Sensor> _availableSensors;
+ private ObservableCollection<Io> _availableSensors;
/// <summary>
/// Gets or sets the available sensors.
/// </summary>
- public ObservableCollection<Sensor> AvailableSensors
+ public ObservableCollection<Io> AvailableSensors
{
get { return _availableSensors; }
set { _availableSensors = value; RaisePropertyChangedAuto(); }
@@ -475,7 +475,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
if (!this.DesignMode)
{
Adapter = ObservablesEntitiesAdapter.Instance;
- AvailableSensors = Adapter.Sensors.ToObservableCollection();
+ AvailableSensors = Adapter.Ios.ToObservableCollection();
}
Graphs = new ObservableCollection<IRealTimeGraph>();
@@ -1124,7 +1124,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
/// Add sensor graph from available sensors to displayed graphs.
/// </summary>
/// <param name="sensor">The sensor.</param>
- public void OnDropAvailableSensor(Sensor sensor)
+ public void OnDropAvailableSensor(Io sensor)
{
if (Graphs.Count < 8)
{
@@ -1208,7 +1208,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
/// <param name="graph">The graph.</param>
public void RemoveGraph(IRealTimeGraph graph)
{
- var sensor = graph.Tag as Sensor;
+ var sensor = graph.Tag as Io;
_controllers.Remove(sensor.Name);
graph.InnerGraph.Dispose();
Graphs.Remove(graph);
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml
index 820c5bb18..f92f96160 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml
@@ -1796,7 +1796,7 @@
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
- <DataTemplate DataType="{x:Type observables:Sensor}">
+ <DataTemplate DataType="{x:Type observables:Io}">
<Border dragAndDrop:DragAndDropService.Draggable="True" dragAndDrop:DragAndDropService.DraggingSurface="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DraggingSurface}" Margin="5" CornerRadius="3" Height="120" BorderThickness="1" BorderBrush="Silver" ClipToBounds="True">
<Border.Background>
<ImageBrush ImageSource="../Images/line_graph.png" Stretch="Fill"></ImageBrush>
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml.cs
index 1df4728d3..9a0a4dc0e 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml.cs
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/MainView.xaml.cs
@@ -106,9 +106,9 @@ namespace Tango.MachineStudio.Developer.Views
private void OnDropAvailableSensor(object sender, DropEventArgs e)
{
- if (e.Draggable.DataContext is Sensor)
+ if (e.Draggable.DataContext is Io)
{
- _vm.OnDropAvailableSensor(e.Draggable.DataContext as Sensor);
+ _vm.OnDropAvailableSensor(e.Draggable.DataContext as Io);
}
}