Ejemplo n.º 1
0
        public void RefreshSettings()
        {
            XmlDocument xDoc = new XmlDocument();
            Options     f2   = new Options();

            try
            {
                xDoc.Load(Application.StartupPath.ToString() + "\\config.xml");
                vlcLoc   = xDoc.GetElementsByTagName("vlc-loc")[0].InnerText;
                suppress = xDoc.GetElementsByTagName("suppress")[0].InnerText;

                apiUser = xDoc.SelectSingleNode("/rtmpGUI/api/@user").Value;
                apiKey  = xDoc.SelectSingleNode("/rtmpGUI/api/@key").Value;

                if (suppress == "true")
                {
                    supcom = true;
                }
                else
                {
                    supcom = false;
                }
            }
            catch (Exception ex)
            {
                f2.Show();
                MessageBox.Show("There was an error with the config file.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                DebugLog(ex.ToString());
            }
        }
Ejemplo n.º 2
0
        private void optionsMenu_Click(object sender, EventArgs e)
        {
            Options form = Options.Instance();

            if (!form.Visible)
            {
                form.Show();
            }
            else
            {
                form.BringToFront();
            }
        }
Ejemplo n.º 3
0
        public void RefreshSettings()
        {
            XmlDocument xDoc = new XmlDocument();
            Options f2 = new Options();
            try
            {
                xDoc.Load(Application.StartupPath.ToString() + "\\config.xml");
                vlcLoc = xDoc.GetElementsByTagName("vlc-loc")[0].InnerText;
                suppress = xDoc.GetElementsByTagName("suppress")[0].InnerText;

                apiUser = xDoc.SelectSingleNode("/rtmpGUI/api/@user").Value;
                apiKey = xDoc.SelectSingleNode("/rtmpGUI/api/@key").Value;

                if (suppress == "true")
                {
                    supcom = true;
                }
                else
                {
                    supcom = false;
                }
            }
            catch (Exception ex)
            {
                f2.Show();
                MessageBox.Show("There was an error with the config file.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                DebugLog(ex.ToString());
            }
        }
Ejemplo n.º 4
0
        public void LoadSettings()
        {
            XmlDocument xDoc = new XmlDocument();
            Options f2 = new Options();
            try
            {
                xDoc.Load(Application.StartupPath.ToString() + "\\config.xml");
                vlcLoc = xDoc.GetElementsByTagName("vlc-loc")[0].InnerText;
                list = xDoc.SelectSingleNode("/rtmpGUI/list/@remote").Value;
                updates = xDoc.GetElementsByTagName("updates")[0].InnerText;
                altload = xDoc.SelectSingleNode("/rtmpGUI/altpage/@load").Value;
                altpage = xDoc.GetElementsByTagName("altpage")[0].InnerText;
                suppress = xDoc.GetElementsByTagName("suppress")[0].InnerText;
                default_commands = xDoc.GetElementsByTagName("default_commands")[0].InnerText;

                apiUser = xDoc.SelectSingleNode("/rtmpGUI/api/@user").Value;
                apiKey = xDoc.SelectSingleNode("/rtmpGUI/api/@key").Value;

                if (list == "true")
                {
                    ThreadStart update = new ThreadStart(RemoteXML);
                    Thread check = new Thread(update);
                    check.Start();
                }
                else
                {
                    localloadloc = xDoc.GetElementsByTagName("list")[0].InnerText;
                    ThreadStart update = new ThreadStart(LocalXml);
                    Thread check = new Thread(update);
                    check.Start();
                }

                if (updates == "true")
                {
                    CheckUpdates();
                }
                else
                {
                    //Do jack
                }

                if (altload == "true")
                {
                    homepage = altpage;
                }
                else
                {
                    homepage = "http://tvlistings.tvguide.com/ListingsWeb/listings/ScrollingGridIFrame.aspx";
                }
                wbApp.Navigate(homepage);

                if (suppress == "true")
                {
                    supcom = true;
                }
                else
                {
                    supcom = false;
                }

                if (default_commands == "true")
                {
                    txtCommands.BringToFront();
                    wbApp.SendToBack();
                }
                else
                {
                    wbApp.BringToFront();
                    txtCommands.SendToBack();
                }
            }
            catch (Exception ex)
            {
                f2.Show();
                MessageBox.Show("There was an error with the config file.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                DebugLog(ex.ToString());
            }
        }
Ejemplo n.º 5
0
        public void LoadSettings()
        {
            XmlDocument xDoc = new XmlDocument();
            Options     f2   = new Options();

            try
            {
                xDoc.Load(Application.StartupPath.ToString() + "\\config.xml");
                vlcLoc           = xDoc.GetElementsByTagName("vlc-loc")[0].InnerText;
                list             = xDoc.SelectSingleNode("/rtmpGUI/list/@remote").Value;
                updates          = xDoc.GetElementsByTagName("updates")[0].InnerText;
                altload          = xDoc.SelectSingleNode("/rtmpGUI/altpage/@load").Value;
                altpage          = xDoc.GetElementsByTagName("altpage")[0].InnerText;
                suppress         = xDoc.GetElementsByTagName("suppress")[0].InnerText;
                default_commands = xDoc.GetElementsByTagName("default_commands")[0].InnerText;

                apiUser = xDoc.SelectSingleNode("/rtmpGUI/api/@user").Value;
                apiKey  = xDoc.SelectSingleNode("/rtmpGUI/api/@key").Value;

                if (list == "true")
                {
                    ThreadStart update = new ThreadStart(RemoteXML);
                    Thread      check  = new Thread(update);
                    check.Start();
                }
                else
                {
                    localloadloc = xDoc.GetElementsByTagName("list")[0].InnerText;
                    ThreadStart update = new ThreadStart(LocalXml);
                    Thread      check  = new Thread(update);
                    check.Start();
                }

                if (updates == "true")
                {
                    CheckUpdates();
                }
                else
                {
                    //Do jack
                }

                if (altload == "true")
                {
                    homepage = altpage;
                }
                else
                {
                    homepage = "http://tvlistings.tvguide.com/ListingsWeb/listings/ScrollingGridIFrame.aspx";
                }
                wbApp.Navigate(homepage);

                if (suppress == "true")
                {
                    supcom = true;
                }
                else
                {
                    supcom = false;
                }

                if (default_commands == "true")
                {
                    txtCommands.BringToFront();
                    wbApp.SendToBack();
                }
                else
                {
                    wbApp.BringToFront();
                    txtCommands.SendToBack();
                }
            }
            catch (Exception ex)
            {
                f2.Show();
                MessageBox.Show("There was an error with the config file.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                DebugLog(ex.ToString());
            }
        }