Exemplo n.º 1
0
        private void comboBoxTV_SelectedIndexChanged(object sender, EventArgs e)
        {
            Samsung.iRemoteWrapper.TVInfo info = (Samsung.iRemoteWrapper.TVInfo)comboBoxTV.SelectedItem;

            if (_device.iRemote.CurrentTV.ToString() != info.ToString())
            {
                _device.iRemote.ConnectTo((Samsung.iRemoteWrapper.TVInfo)comboBoxTV.SelectedItem);
                _device.IPAddress = info.ToString();
            }
        }
Exemplo n.º 2
0
        public void TVRemoved(ref Samsung.iRemoteWrapper.TVInfo info)
        {
            int i = comboBoxTV.FindStringExact(info.ToString());

            if (i > 0)
            {
                comboBoxTV.Items.RemoveAt(i);
            }
        }
Exemplo n.º 3
0
        public void TVAdded(ref Samsung.iRemoteWrapper.TVInfo info)
        {
            comboBoxTV.Items.Add(info);

            String tv = comboBoxTV.Items[0].ToString();

            using (Settings reader = new MPSettings())
            {
                tv = reader.GetValueAsString("Auto3DPlugin", "SamsungAddress", info.ToString());
            }

            foreach (Samsung.iRemoteWrapper.TVInfo item in comboBoxTV.Items)
            {
                if (item.ToString() == info.ToString())
                {
                    comboBoxTV.SelectedItem = item;
                    break;
                }
            }

            comboBoxTV.SelectedItem = info;
        }
Exemplo n.º 4
0
        void _iRemote_addTVEvent(TVInfo info)
        {
            ((SamsungTVSetup)GetSetupControl()).TVAdded(ref info);

              if (info.ToString() == IPAddress)
              {
            MAC = Auto3DHelpers.RequestMACAddress(IPAddress);

            if (iRemote.ToString() != info.ToString())
              _iRemote.ConnectTo(info);
              }
        }