예제 #1
0
        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);
        }
예제 #2
0
 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);
     }
 }
예제 #3
0
 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);
 }
예제 #4
0
 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);
 }