private void optionsChanged(object sender, OptionsChangedEventArgs e)
 {
     if (e.GetOption <int>("checkUpdateTime") != 0)
     {
         checkUpdate_timer.Interval = Options.TimeSelections[e.GetOption <int>("checkUpdateTime")] * 60000;
         checkUpdate_timer.Start();
     }
     else
     {
         checkUpdate_timer.Stop();
     }
     if (e.GetOption <bool>("discordRichPresence"))
     {
         if (!client.IsInitialized)
         {
             client        = new DiscordRpcClient("718605351263535106");
             client.Logger = new ConsoleLogger()
             {
                 Level = LogLevel.Warning
             };
             client.Initialize();
             client.SetPresence(RichPresence);
         }
     }
     else
     {
         if (client.IsInitialized)
         {
             client.Deinitialize();
         }
     }
 }
Exemplo n.º 2
0
 private void CR_MarkerExtensionsPlugIn_OptionsChanged(OptionsChangedEventArgs e)
 {
     if (e.OptionsPages.Contains(typeof(Opt_MarkerExtensions)))
     {
         Opt_MarkerExtensions.LoadSettings(_settings);
     }
 }
 private void SmartQuotesPluginOptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SmartQuoteOptions)))
     {
         this.settings.Load();
     }
 }
Exemplo n.º 4
0
 private void CR_SmartGenerics_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SmartGenericsOptions)))
     {
         this.settings.Load();
     }
 }
 private void BlockPainterPlugIn_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(_optionsPageFullName))
     {
         BlockPaintingStrategyProvider.LoadBlockPaintingStrategies();
     }
 }
        private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
        {
            if (!ea.OptionsPages.Contains(typeof(OptProjectDefaults)))
                return;

            LoadSettings();
        }
Exemplo n.º 7
0
 private void Refactor_SplitString_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SplitStringOptions)))
     {
         this.settings.Load();
     }
 }
 private void Refactor_SplitString_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SplitStringOptions)))
     {
         this.settings.Load();
     }
 }
 private void BlockPainterPlugIn_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(_optionsPageFullName))
     {
         BlockPaintingStrategyProvider.LoadBlockPaintingStrategies();
     }
 }
Exemplo n.º 10
0
        public bool Send(object sender, Dictionary <string, Value> options)
        {
            var eventArgs = new OptionsChangedEventArgs(options);

            OptionsChanged?.Invoke(sender, eventArgs);

            return(eventArgs.Reloaded);
        }
 private void dxCoreEvents1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(OptXkeysLayout)))
     {
         xkeyLayout.Load();
         pnlKeyPreview.Invalidate();
     }
 }
Exemplo n.º 12
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(OptRedGreenPlugIn)))
     {
         LoadSettings();
         DxCoreUtil.Invalidate(CodeRush.Source.ActiveClass);
     }
 }
Exemplo n.º 13
0
        private void ModTabSettingsOptionsChanged(object sender, OptionsChangedEventArgs e)
        {
            e.Reloaded = RefreshConfig(out var error);

            if (!e.Reloaded)
            {
                Monitor.Log(error, LogLevel.Error);
            }
        }
 private void Options_OnOptionsChanged(object sender, OptionsChangedEventArgs e)
 {
     if (_autoShelve != null)
     {
         _autoShelve.MaximumShelvesets = e.MaximumShelvesets;
         _autoShelve.ShelvesetName     = e.ShelvesetName;
         _autoShelve.Interval          = e.Interval;
     }
 }
 private void Options_OnOptionsChanged(object sender, OptionsChangedEventArgs e)
 {
     if (_autoShelve != null)
     {
         _autoShelve.MaximumShelvesets = e.MaximumShelvesets;
         _autoShelve.OutputPane        = e.OutputPane;
         _autoShelve.ShelvesetName     = e.ShelvesetName;
         _autoShelve.SuppressDialogs   = e.SuppressDialogs;
         _autoShelve.TimerInterval     = e.Interval;
     }
 }
        private void OnOptionsChanged(object sender, OptionsChangedEventArgs args)
        {
            var properties = new Dictionary <string, string>
            {
                { "Prompt before build start", (!args.AppVeyorOptions.ConfirmStart).ToString() },
                { "Prompt before build stop", (!args.AppVeyorOptions.ConfirmStart).ToString() }
            };

            Telemetry.Instance.TrackEvent("Options changed", properties);

            Initialize();
        }
Exemplo n.º 17
0
        protected override void OnApply(PageApplyEventArgs e)
        {
            base.OnApply(e);
            bool flag = OnOptionsChanged == null;

            if (!flag)
            {
                var optionsEventArg = new OptionsChangedEventArgs
                {
                    Interval          = TimerSaveInterval,
                    MaximumShelvesets = MaximumShelvesets,
                    OutputPane        = OutputPane,
                    ShelvesetName     = ShelvesetName,
                    SuppressDialogs   = SuppressDialogs
                };
                OnOptionsChanged(this, optionsEventArg);
            }
        }
Exemplo n.º 18
0
        protected override void OnApply(PageApplyEventArgs e)
        {
            base.OnApply(e);
            bool flag = OnOptionsChanged == null;

            if (!flag)
            {
                var optionsEventArg = new OptionsChangedEventArgs
                {
                    PauseWhileDebugging = PauseWhileDebugging,
                    Interval            = TimerSaveInterval,
                    MaximumShelvesets   = MaximumShelvesets,
                    OutputPane          = OutputPane,
                    ShelvesetName       = ShelvesetName,
                };
                OnOptionsChanged(this, optionsEventArg);
            }
        }
Exemplo n.º 19
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     LoadSettings();
 }
        void EventNexus_OptionsChanged(OptionsChangedEventArgs ea)
        {
            if (!ea.OptionsPages.Contains(typeof(OptMultiSelect)))
                return;

            SetHighlightColor(OptMultiSelect.Storage.ReadColor("Appearance", "SelectionColor"));
            RefreshAllHighlighting();
        }
Exemplo n.º 21
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     _DisplayTile = LoadSettings();
 }
 private void SmartQuotesPluginOptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SmartQuoteOptions)))
     {
         this.settings.Load();
     }
 }
 private void ClassCleanerPlugIn_OptionsChanged(OptionsChangedEventArgs ea)
 {
     ClassCleanerConfig.Current.Load();
 }
Exemplo n.º 24
0
 private static void OnOptionsChanged(object sender, OptionsChangedEventArgs e)
 {
 }
Exemplo n.º 25
0
 private void CR_Initials_OptionsChanged(OptionsChangedEventArgs ea)
 {
     LoadSettings();
 }
 private void ClassCleanerPlugIn_OptionsChanged(OptionsChangedEventArgs ea)
 {
     ClassCleanerConfig.Current.Load();
 }
 private void CR_Initials_OptionsChanged(OptionsChangedEventArgs ea)
 {
     LoadSettings();
 }
Exemplo n.º 28
0
		private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
		{
			if(ea.OptionsPages.Contains(typeof(OptRedGreenPlugIn)))
			{
				LoadSettings();
				DxCoreUtil.Invalidate(CodeRush.Source.ActiveClass);
			}
		}
 private void CR_MarkerExtensionsPlugIn_OptionsChanged(OptionsChangedEventArgs e)
 {
   if ( e.OptionsPages.Contains(typeof(Opt_MarkerExtensions)) )
     Opt_MarkerExtensions.LoadSettings(_settings);
 }
Exemplo n.º 30
0
 private void AdvancedOptions4GL_OptionsChanged(object sender, OptionsChangedEventArgs e)
 {
     UpdateSettings(e.ChangedOptions);
 }
Exemplo n.º 31
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     _DisplayTile = LoadSettings();
 }
 private void NavigateToDefinition_OptionsChanged(OptionsChangedEventArgs ea)
 {
     loadSettings();
 }
 private void events_OptionsChanged(OptionsChangedEventArgs ea)
 {
     DisposeGraphicElements();
     RestartTimer();
     PluginOptions.MiniCodeColumnEnabled = true;
 }
Exemplo n.º 34
0
 private void events_OptionsChanged(OptionsChangedEventArgs ea)
 {
     DisposeGraphicElements();
     RestartTimer();
     PluginOptions.MiniCodeColumnEnabled = true;
 }
Exemplo n.º 35
0
 private void FormatOnSavePlugin_OptionsChanged(OptionsChangedEventArgs ea)
 {
     this.RefreshOptions();
 }
Exemplo n.º 36
0
 private void OnOptionsChanged(IApplicationOptionsProvider provider, OptionsChangedEventArgs e)
 {
     notificationRequest.Raise(new Notification("Title", "Content"), null);
 }
 private void NavigateToDefinition_OptionsChanged(OptionsChangedEventArgs ea)
 {
     loadSettings();
 }
Exemplo n.º 38
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     LoadSettings();
 }
 private void ExtractHqlNamedQuery_OptionsChanged(OptionsChangedEventArgs ea)
 {
     loadSettings();
 }
 private void ExtractHqlNamedQuery_OptionsChanged(OptionsChangedEventArgs ea)
 {
     loadSettings();
 }
Exemplo n.º 41
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof (Options1)))
         Logger.Enabled = Options1.LoadOptions();
 }
		private void FormatOnSavePlugin_OptionsChanged(OptionsChangedEventArgs ea)
		{
			this.RefreshOptions();
		}
Exemplo n.º 43
0
 private void PlugIn1_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(OptConvertSpacesToCamelCase)))
     {
         LoadSettings();
     }
 }
Exemplo n.º 44
0
 private void OnOptionsChanged(IApplicationOptionsProvider provider, OptionsChangedEventArgs e)
 {
 }
 private void CR_SmartGenerics_OptionsChanged(OptionsChangedEventArgs ea)
 {
     if (ea.OptionsPages.Contains(typeof(SmartGenericsOptions)))
     {
         this.settings.Load();
     }
 }
Exemplo n.º 46
0
        public override object ReadJson(
            JsonReader reader,
            Type objectType,
            object existingValue,
            JsonSerializer serializer
        )
        {
            var jObject = JObject.Load(reader);
            var eventName = jObject["event"].Value<string>();
            var jReader = jObject.CreateReader();

            switch (eventName)
            {
                case EventArgs.MuteChangedEventArgs.EventName:
                    {
                        var args = new MuteChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }

                // ** Can't receive "on_event" ? **
                //case EventArgs.OnEventEventArgs.EventName:
                //    {
                //        var args = new OnEventEventArgs();
                //        serializer.Populate(jReader, args);

                //        return args;
                //    }

                case EventArgs.OptionsChangedEventArgs.EventName:
                    {
                        var args = new OptionsChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.PlaybackStateChangedEventArgs.EventName:
                    {
                        var args = new PlaybackStateChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.PlaylistChangedEventArgs.EventName:
                    {
                        var args = new PlaylistChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.PlaylistDeletedEventArgs.EventName:
                    {
                        var args = new PlaylistDeletedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.PlaylistsLoadedEventArgs.EventName:
                    {
                        var args = new PlaylistsLoadedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.SeekedEventArgs.EventName:
                    {
                        var args = new SeekedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.StreamTitleChangedEventArgs.EventName:
                    {
                        var args = new StreamTitleChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.TracklistChangedEventArgs.EventName:
                    {
                        var args = new TracklistChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.TrackPlaybackEndedEventArgs.EventName:
                    {
                        var args = new TrackPlaybackEndedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.TrackPlaybackPausedEventArgs.EventName:
                    {
                        var args = new TrackPlaybackPausedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.TrackPlaybackResumedEventArgs.EventName:
                    {
                        var args = new TrackPlaybackResumedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.TrackPlaybackStartedEventArgs.EventName:
                    {
                        var args = new TrackPlaybackStartedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                case EventArgs.VolumeChangedEventArgs.EventName:
                    {
                        var args = new VolumeChangedEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
                default:
                    {
                        var args = new UnexpectedEventEventArgs();
                        serializer.Populate(jReader, args);

                        return args;
                    }
            }
        }
Exemplo n.º 47
0
 private void OnOptionsChanged(IApplicationOptionsProvider sender, OptionsChangedEventArgs args)
 {
 }