Esempio n. 1
0
        public FrmOEMonitor(EventSoftwareOE soft, MainApp.logDelegate logger)
            : base(soft,logger)
        {
            InitializeComponent();
            softOE = soft;

            m_Parser = new OEParser();
            m_Parser.OnLogMessage += new MainApp.logDelegate(m_Parser_OnLogMessage);

            Text = "OE Monitor :: " + soft.Version;
            fileSystemWatcher1.Filter = "*" + softOE.FileExt;
            fileSystemWatcher1.Path = softOE.Directory;
            fileSystemWatcher1.SynchronizingObject = this;

            fileSystemWatcher1.Changed += new System.IO.FileSystemEventHandler(fileSystemWatcher1_Changed);
            fileSystemWatcher1.Created += new System.IO.FileSystemEventHandler(fileSystemWatcher1_Changed);
            fileSystemWatcher1.NotifyFilter = System.IO.NotifyFilters.LastWrite;
            fileSystemWatcher1.EnableRaisingEvents = true;
            logger("Started monitoring " + softOE.Directory + "..");
            lblCurrentlyMonitoring.Text = "Monitoring " + softOE.Directory + " for changes (filter: " + "*" + softOE.FileExt + ")";
        }
Esempio n. 2
0
        private void pageOE_CloseFromNext(object sender, Gui.Wizard.PageEventArgs e)
        {
            BroadCastProject pr = new BroadCastProject();
            Competition c = cmbOnlineEvent.SelectedItem as Competition;
            pr.EventDate = c.Date;
            pr.EventID = c.Id;
            pr.EventName = c.Name;
            pr.Password = txtOnlinePassword.Text;
            EventSoftwareOE oe = new EventSoftwareOE();
            if (rdoOE2003.Checked)
                oe.Version = "OE2003";
            else if (rdoOE2010.Checked)
                oe.Version = "OE2010";
            else if (rdoOES2003.Checked)
                oe.Version = "OE Speaker 2003";

            oe.Directory = txtOEDir.Text;
            oe.FileExt = txtOEFileExt.Text;

            pr.EventSoftwareType = oe;

            MainApp.CurrentProject = pr;
            MainApp.LastProjects.Insert(0, pr);
            MainApp.SaveRecentProjects();
        }