1.1 --- a/Server/FormSelectHarmonyCommand.cs Mon Aug 29 17:36:02 2016 +0200
1.2 +++ b/Server/FormSelectHarmonyCommand.cs Tue Aug 30 03:07:59 2016 +0200
1.3 @@ -19,7 +19,7 @@
1.4 }
1.5
1.6 public string DeviceId;
1.7 - public string FunctionName;
1.8 + public string Command;
1.9
1.10 /// <summary>
1.11 ///
1.12 @@ -51,7 +51,7 @@
1.13
1.14 foreach (HarmonyHub.Function f in cg.Functions)
1.15 {
1.16 - TreeNode fNode = cgNode.Nodes.Add(f.Name);
1.17 + TreeNode fNode = cgNode.Nodes.Add(f.Label);
1.18 fNode.Tag = f;
1.19 }
1.20 }
1.21 @@ -74,9 +74,9 @@
1.22 HarmonyHub.Function f = tag;
1.23 HarmonyHub.Device d = (HarmonyHub.Device)e.Node.Parent.Parent.Tag;
1.24
1.25 - Trace.WriteLine($"Harmony: Sending {f.Name} to {d.Label}...");
1.26 + Trace.WriteLine($"Harmony: Sending {f.Label} to {d.Label}...");
1.27
1.28 - await Program.HarmonyClient.SendCommandAsync(d.Id, f.Name);
1.29 + await Program.HarmonyClient.TrySendKeyPressAsync(d.Id, f.Action.Command);
1.30 }
1.31 }
1.32
1.33 @@ -97,12 +97,12 @@
1.34 HarmonyHub.Device d = (HarmonyHub.Device)e.Node.Parent.Parent.Tag;
1.35
1.36 DeviceId = d.Id;
1.37 - FunctionName = f.Name;
1.38 + Command = f.Action.Command;
1.39 }
1.40 else
1.41 {
1.42 DeviceId = "";
1.43 - FunctionName = "";
1.44 + Command = "";
1.45 }
1.46
1.47 }