public virtual void Save(ManagedTreeItem i) { Type type = base.GetType(); i.setValue <Type>("Type", type); i.setValue <string>("Name", this.Name); i.setValue <string>("GUID", this.GUID); i.setValue <bool>("UseBacktrack", this.UseBacktrack); }
public void Save(ManagedTreeItem mti) { MidiPlugin.log.Debug("Saving RuleSet {0}", Name); mti.setValue <string>("Name", this.Name); mti.setValue <string>("InputDeviceID", this.InputDeviceID); mti.setValue <string>("OutputDeviceID", this.OutputDeviceID); mti.setValue <string>("GUID", this.GUID); foreach (DeviceRule rule in this.Rules) { ManagedTreeItem mtir = new ManagedTreeItem("Rule"); rule.Save(mtir); mti.AddChild(mtir); } }
public override void Save(ManagedTreeItem i) { MidiPlugin.log.Debug("Saving ButtonRule {0}, {1}, {2}", EnableMessage.Data, DisableMessage.Data, Treshold); base.Save(i); i.setValue <bool>("State", this.State); i.setValue <byte>("Treshold", this.Treshold); i.setValue <bool>("IsToggle", this.IsToggle); i.setValue <int>("EnableMessage", this.EnableMessage.Data); i.setValue <int>("EnabledBacktrack", this.EnabledBacktrack.Data); i.setValue <int>("DisableMessage", this.DisableMessage.Data); i.setValue <int>("DisabledBacktrack", this.DisabledBacktrack.Data); }
public override void Save(ManagedTreeItem i) { MidiPlugin.log.Debug("Saving EncoderRule {0}, {1}, {2}", CWMessage.Data, CCWMessage.Data, Increment); base.Save(i); i.setValue <double>("Value", this.Value); i.setValue <double>("Increment", this.Increment); i.setValue <int>("CWMessage", this.CWMessage.Data); i.setValue <int>("MinimumBacktrack", this.MinimumBacktrack.Data); i.setValue <int>("CCWMessage", this.CCWMessage.Data); i.setValue <int>("MaximumBacktrack", this.MaximumBacktrack.Data); }