Beispiel #1
0
        private void LoadCopyXml(XmlNode pNode, ArrayList pFixtures)
        {
            this.mVirtualType  = VirtualChannelType.Copy;
            mCopyChannel       = new ArrayList();
            mIsChannelInverted = new bool[pNode.ChildNodes.Count];
            int i = 0;


            foreach (XmlNode node in pNode.ChildNodes)
            {
                if (node.Name == "CopyTo")
                {
                    try
                    {
                        string Name        = node.Attributes["Name"].InnerText;
                        string channelName = node.Attributes["ChannelName"].InnerText;

                        foreach (DmxFramework.Fixtures.Fixture fix in pFixtures)
                        {
                            if (fix.Name == Name)
                            {
                                foreach (Channel chan in fix.Channels)
                                {
                                    if (chan.Name == channelName)
                                    {
                                        mCopyChannel.Add(chan);
                                        mIsChannelInverted[i] = false;
                                        i++;
                                        break;
                                    }
                                }
                            }
                        }
                    }
                    catch { }
                }
                else
                {
                }
            }

            /* if (i != pNode.ChildNodes.Count)
             *   throw new Exception("Undefined node");*/
        }
Beispiel #2
0
        public VirtualChannel(string pName, string pFunction)
            : base(ChannelType.Virtual)
        {
            this.mName     = pName;
            this.mFunction = Channel.StringToFunction(pFunction);

            switch (this.mFunction)
            {
            case ChannelFunction.Btn:
            case ChannelFunction.List:
                this.mDmxValues = new ArrayList();
                mVirtualType    = VirtualChannelType.ByValue;
                break;

            default:
                mVirtualType     = VirtualChannelType.Copy;
                this.CopyChannel = new ArrayList();
                break;
            }
        }
Beispiel #3
0
 private void LoadByValueXml(XmlNode pNode, ArrayList pFixtures)
 {
     this.mVirtualType = VirtualChannelType.ByValue;
     LoadButtons(pNode, pFixtures);
 }
Beispiel #4
0
 public VirtualChannel(string pName, int pNum, VirtualChannelType pVirtualType)
     : base(ChannelType.Virtual)
 {
     mVirtualType = pVirtualType;
 }