Exemplo n.º 1
0
 //private CheckBox chkCombineItems;
 public ConfigForm(Config configuration)
 {
     this.InitializeComponent();
     this.config = configuration;
 }
Exemplo n.º 2
0
 public KVStatusCodes Init()
 {
     Action action = (Action)null;
     this.State = ModuleState.UpdateSettings;
     InstaModule.logger.DebugFormat("Initializing. Module version: {0}", (object)this.ModuleVersion);
     this.icon = (KVAppIcon)new ModuleIcon();
     this.config = new Config(this.ModuleConfigFilePath);
     if (this.config.LoadConfiguration())
     {
         try
         {
             if (this.AppConfigForm == null)
                 this.AppConfigForm = (KVAppConfig)new AppConfig(this.config, (IKVModule)this);
         }
         catch (Exception ex)
         {
             InstaModule.logger.Error((object)"An error has occurred.", ex);
             this.State = ModuleState.Error;
             this.ErrorMessage = Resources.errGeneric;
             return (KVStatusCodes)1;
         }
         if (action == null)
         {
             // ISSUE: method pointer
             //action = new Action((object)this, __methodptr(\u003CInit\u003Eb__0));
         }
         this.asynch_InitGetFeeds = action;
         this.asynch_InitGetFeeds.BeginInvoke((AsyncCallback)null, (object)null);
         return (KVStatusCodes)0;
     }
     InstaModule.logger.Error((object)"Error loading configuration.");
     this.State = ModuleState.Error;
     this.ErrorMessage = Resources.errLoadingConfiguration;
     return (KVStatusCodes)0;
 }
Exemplo n.º 3
0
 public Renderer(Config config)
 {
     this.config = config;
     this.ContentTopLeft = new Point(900, 0);
     this.ReplacingTopLeft = new Point(124, 0);
 }
Exemplo n.º 4
-1
 public AppConfig(Config configuration, IKVModule module)
 {
     this.InitializeComponent();
     this.config = configuration;
     this.module = module;
     this.lblError.Text = string.Empty;
     this.DisableEventHandlers();
     //this.chkMivzakim.Checked = this.config.Mivzakim;
     //this.chkNews.Checked = this.config.News;
     //this.chkEconomy.Checked = this.config.Economy;
     //this.chkCulture.Checked = this.config.Culture;
     //this.chkSports.Checked = this.config.Sports;
     //this.chkComputers.Checked = this.config.Computers;
     //this.chkScience.Checked = this.config.Science;
     //this.chkHealth.Checked = this.config.Health;
     //this.chkGreen.Checked = this.config.Green;
     //this.chkConsumers.Checked = this.config.Consumers;
     //this.chkParents.Checked = this.config.Parents;
     //this.chkFood.Checked = this.config.Food;
     //this.chkAuto.Checked = this.config.Auto;
     //this.chkJudaism.Checked = this.config.Judaism;
     this.VerifySelectedChannels();
     this.numRefreshFrequency.Value = !((Decimal)this.config.RefreshFrequency < this.numRefreshFrequency.Minimum) ? (!((Decimal)this.config.RefreshFrequency > this.numRefreshFrequency.Maximum) ? (Decimal)this.config.RefreshFrequency : this.numRefreshFrequency.Maximum) : this.numRefreshFrequency.Minimum;
     this.numItemsToFetch.Value = !((Decimal)this.config.ItemsToFetch < this.numItemsToFetch.Minimum) ? (!((Decimal)this.config.ItemsToFetch > this.numItemsToFetch.Maximum) ? (Decimal)this.config.ItemsToFetch : this.numItemsToFetch.Maximum) : this.numItemsToFetch.Minimum;
     this.numDisplayDuration.Value = !((Decimal)this.config.DisplayDuration < this.numDisplayDuration.Minimum) ? (!((Decimal)this.config.DisplayDuration > this.numDisplayDuration.Maximum) ? (Decimal)this.config.DisplayDuration : this.numDisplayDuration.Maximum) : this.numDisplayDuration.Minimum;
     //this.chkCombineItems.Checked = this.config.CombineItems;
     //this.chkShowImages.Checked = this.config.ShowImages;
     this.EnableEventHandlers();
     this.d_DoAsynchInit = new AppConfig.D_DoAsynchInit(this.DoAsynchInit);
     this.initCallback = new AsyncCallback(this.initCallbackMethod);
 }