コード例 #1
0
        /// <summary>
        /// Install plugin
        /// </summary>
        public override void Install()
        {
            _localizationService.ImportPluginResourcesFromXml(this.PluginDescriptor);

            var settings = new GlimpseSettings()
            {
                IsEnabled = false,
                ShowConsoleInAdminArea  = false,
                AllowAdministratorsOnly = true,
                EnableOnRemoteServer    = true,
                ShowConfigurationTab    = true,
                ShowEnvironmentTab      = true,
                ShowExecutionTab        = true,
                ShowMetadataTab         = true,
                ShowRequestTab          = true,
                ShowModelBindingTab     = true,
                ShowRoutesTab           = true,
                ShowServerTab           = true,
                ShowSessionTab          = false,
                ShowSqlTab      = false,
                ShowTimelineTab = true,
                ShowTraceTab    = true,
                ShowViewsTab    = true
            };

            _settingService.SaveSetting(settings);

            base.Install();
        }
コード例 #2
0
 public GlimpsePlugin(GlimpseSettings settings, ILocalizationService localizationService, ISettingService settingService)
 {
     _settings            = settings;
     _localizationService = localizationService;
     _settingService      = settingService;
 }