示例#1
0
 public void Start()
 {
     Log.Info("MiniDisplay.Start(): called");
     Log.Info("MiniDisplay.Start(): {0}", MiniDisplayHelper.Plugin_Version);
     Log.Info("MiniDisplay.Start(): plugin starting...");
     if (!File.Exists(Config.GetFile(Config.Dir.Config, "MiniDisplay.xml")))
     {
         Log.Info("MiniDisplay.Start(): plugin not configured... Unable to start");
     }
     else
     {
         MiniDisplayHelper.MPStatus = new SystemStatus();
         MiniDisplayHelper.InitSystemStatus(ref MiniDisplayHelper.MPStatus);
         this.GetTVSource();
         if (Settings.Instance.ShowPropertyBrowser)
         {
             lock (MiniDisplayHelper.PropertyBrowserMutex)
             {
                 Log.Info("MiniDisplay.Start(): opening PropertyBrowser.");
                 this.browser              = new PropertyBrowser();
                 this.browser.FormClosing += new FormClosingEventHandler(this.browser_Closing);
                 this.browser.Show();
                 MiniDisplayHelper._PropertyBrowserAvailable = true;
             }
         }
         this.DoStart();
         Log.Info("MiniDisplay.Start(): completed");
     }
 }
示例#2
0
 private void browser_Closing(object sender, FormClosingEventArgs e)
 {
     if (Settings.Instance.ExtensiveLogging)
     {
         Log.Info("MiniDisplay.browser_Closing(): PropertyBrowser is closing.");
     }
     this.browser = null;
 }
示例#3
0
        public void Stop()
        {
            Settings.Instance.LogInfo("MiniDisplay.Stop(): called");
            Settings.Instance.LogDebug("MiniDisplay: Plugin is being stopped.");

            MiniDisplayHelper._PropertyBrowserAvailable = false;
            SystemEvents.PowerModeChanged -= new PowerModeChangedEventHandler(this.SystemEvents_PowerModeChanged);
            this.DoStop();
            if (this.browser != null)
            {
                Log.Info("MiniDisplay.Stop(): closing PropertyBrowser.");
                this.browser.Close();
                this.browser = null;
            }
            if (this.display != null)
            {
                this.display.Dispose();
                this.display = null;
            }
            Log.Info("MiniDisplay.Stop(): completed");
        }
示例#4
0
    public void Stop()
    {
      Settings.Instance.LogInfo("MiniDisplay.Stop(): called");
      Settings.Instance.LogDebug("MiniDisplay: Plugin is being stopped.");

      MiniDisplayHelper._PropertyBrowserAvailable = false;
      SystemEvents.PowerModeChanged -= new PowerModeChangedEventHandler(this.SystemEvents_PowerModeChanged);
      this.DoStop();
      if (this.browser != null)
      {
        Log.Info("MiniDisplay.Stop(): closing PropertyBrowser.");
        this.browser.Close();
        this.browser = null;
      }
      if (this.display != null)
      {
        this.display.Dispose();
        this.display = null;
      }
      Log.Info("MiniDisplay.Stop(): completed");
    }
示例#5
0
 public void Start()
 {
   Log.Info("MiniDisplay.Start(): called");
   Log.Info("MiniDisplay.Start(): {0}", MiniDisplayHelper.Plugin_Version);
   Log.Info("MiniDisplay.Start(): plugin starting...");
   if (!File.Exists(Config.GetFile(Config.Dir.Config, "MiniDisplay.xml")))
   {
     Log.Info("MiniDisplay.Start(): plugin not configured... Unable to start");
   }
   else
   {
     MiniDisplayHelper.MPStatus = new SystemStatus();
     MiniDisplayHelper.InitSystemStatus(ref MiniDisplayHelper.MPStatus);
     this.GetTVSource();
     if (Settings.Instance.ShowPropertyBrowser)
     {
       lock (MiniDisplayHelper.PropertyBrowserMutex)
       {
         Log.Info("MiniDisplay.Start(): opening PropertyBrowser.");
         this.browser = new PropertyBrowser();
         this.browser.FormClosing += new FormClosingEventHandler(this.browser_Closing);
         this.browser.Show();
         MiniDisplayHelper._PropertyBrowserAvailable = true;
       }
     }
     this.DoStart();
     Log.Info("MiniDisplay.Start(): completed");
   }
 }
示例#6
0
 private void browser_Closing(object sender, FormClosingEventArgs e)
 {
   Settings.Instance.LogInfo("MiniDisplay.browser_Closing(): PropertyBrowser is closing.");
   this.browser = null;
 }
示例#7
0
 private void browser_Closing(object sender, FormClosingEventArgs e)
 {
     Settings.Instance.LogInfo("MiniDisplay.browser_Closing(): PropertyBrowser is closing.");
     this.browser = null;
 }
示例#8
0
 private void browser_Closing(object sender, FormClosingEventArgs e)
 {
   if (Settings.Instance.ExtensiveLogging)
   {
     Log.Info("MiniDisplay.browser_Closing(): PropertyBrowser is closing.");
   }
   this.browser = null;
 }