Exemplo n.º 1
0
        public void SaveConfiguration(ConfigurePluginEventArgs cpea)
        {
            var pluginElement = cpea.CreateNewPluginNode(this.PluginName);

            pluginElement.SetAttribute("enabled", this.Enabled.ToString());
            pluginElement.SetAttribute("showInTaskBar", this.showInTaskBar.ToString());
            pluginElement.SetAttribute("alwaysOnTop", this.alwaysOnTop.ToString());
        }
Exemplo n.º 2
0
        public void SaveConfiguration(ConfigurePluginEventArgs cpea)
        {
            var pluginElement = cpea.CreateNewPluginNode(this.PluginName);
            pluginElement.SetAttribute("enabled", this.Enabled.ToString());

            pluginElement.SetAttribute("playRewindSound", this.soundSettings.PlayRewindSound.ToString());
            pluginElement.SetAttribute("playTickingSound", this.soundSettings.PlayTickingSound.ToString());
            pluginElement.SetAttribute("playRingSound", this.soundSettings.PlayRingSound.ToString());
        }
Exemplo n.º 3
0
        public void LoadConfiguration(ConfigurePluginEventArgs cpea)
        {
            XmlElement fromElement = cpea.GetMyNode(this.PluginName);

            if (fromElement != null)
            {
                this.Enabled = bool.Parse(fromElement.GetAttribute("enabled"));
            }
        }
Exemplo n.º 4
0
        public ConfigurePluginEventArgs GetEventArgs()
        {
            if (this.eventArgs == null)
            {
                this.eventArgs = new ConfigurePluginEventArgs(this.document);
            }

            return(this.eventArgs);
        }
Exemplo n.º 5
0
        public void SaveConfiguration(ConfigurePluginEventArgs cpea)
        {
            var pluginElement = cpea.CreateNewPluginNode(this.PluginName);

            pluginElement.SetAttribute("enabled", this.Enabled.ToString());

            var inPomodoroStatusNode = pluginElement.OwnerDocument.CreateElement("inPomodoroStatus");

            inPomodoroStatusNode.InnerText = inPomodoroTextTemplate;
            pluginElement.AppendChild(inPomodoroStatusNode);
        }
Exemplo n.º 6
0
        public void LoadConfiguration(ConfigurePluginEventArgs cpea)
        {
            XmlElement fromElement = cpea.GetMyNode(this.PluginName);

            if (fromElement != null)
            {
                this.Enabled = bool.Parse(fromElement.GetAttribute("enabled"));
                var inPomodoroStatusNode = (XmlElement)fromElement.SelectSingleNode("inPomodoroStatus");
                inPomodoroTextTemplate = inPomodoroStatusNode.InnerText;
            }
        }
Exemplo n.º 7
0
        public void LoadConfiguration(ConfigurePluginEventArgs cpea)
        {
            XmlElement fromElement = cpea.GetMyNode(this.PluginName);

            if (fromElement != null)
            {
                this.Enabled       = bool.Parse(fromElement.GetAttribute("enabled"));
                this.ShowInTaskBar = bool.Parse(fromElement.GetAttribute("showInTaskBar"));
                this.AlwaysOnTop   = bool.Parse(fromElement.GetAttribute("alwaysOnTop"));
            }
        }
Exemplo n.º 8
0
        public void SaveConfiguration(ConfigurePluginEventArgs cpea)
        {
            var pluginElement = cpea.CreateNewPluginNode(this.PluginName);

            foreach (var proc in this.configuredVictims)
            {
                var processNode = cpea.Document.CreateElement("process");
                processNode.SetAttribute("name", proc);
                pluginElement.AppendChild(processNode);
            }
        }
Exemplo n.º 9
0
 public void LoadConfiguration(ConfigurePluginEventArgs cpea)
 {
     XmlElement fromElement = cpea.GetMyNode(this.PluginName);
     if (fromElement != null)
     {
         this.Enabled = bool.Parse(fromElement.GetAttribute("enabled"));
         this.soundSettings = new SoundSettings()
         {
             PlayRewindSound = bool.Parse(fromElement.GetAttribute("playRewindSound")),
             PlayTickingSound = bool.Parse(fromElement.GetAttribute("playTickingSound")),
             PlayRingSound = bool.Parse(fromElement.GetAttribute("playRingSound")),
         };
     }
 }
Exemplo n.º 10
0
        public void LoadConfiguration(ConfigurePluginEventArgs cpea)
        {
            this.configuredVictims.Clear();
            XmlElement fromElement = cpea.GetMyNode(this.PluginName);

            if (fromElement != null)
            {
                foreach (XmlElement node in fromElement.SelectNodes("process"))
                {
                    string name = node.GetAttribute("name");
                    this.configuredVictims.Add(name);
                }
            }
        }
Exemplo n.º 11
0
        private void LoadConfig(ConfigureEventArgs cea)
        {
            var cpea = new ConfigurePluginEventArgs(cea.Document);

            this.loadPluginConfigEvent.Fire(new ConfigurePluginEventArgs(cea.Document));
        }
Exemplo n.º 12
0
        public void SaveConfiguration(ConfigurePluginEventArgs cpea)
        {
            var pluginElement = cpea.CreateNewPluginNode(this.PluginName);

            pluginElement.SetAttribute("enabled", this.Enabled.ToString());
        }
 private void LoadConfig(ConfigureEventArgs cea)
 {
     var cpea = new ConfigurePluginEventArgs(cea.Document);
     this.loadPluginConfigEvent.Fire(new ConfigurePluginEventArgs(cea.Document));
 }