Esempio n. 1
0
        public void BeforeClose()
        {
            PageCollection.Save();
            Properties.Settings.Default.Save();

            RegistryKey registryKey    = Registry.CurrentUser.OpenSubKey("Software\\Microsoft\\Windows\\CurrentVersion\\Run", true);
            string      executablePath = AppDomain.CurrentDomain.BaseDirectory + "Sidebar.exe";

            if (Properties.Settings.Default.AddToStartup)
            {
                registryKey.SetValue("SideBar", executablePath);
            }
            else
            {
                registryKey.DeleteValue("SideBar", false);
            }
        }
Esempio n. 2
0
 /* ----------------------------------------------------------------- */
 ///
 /// ExecRecovery
 ///
 /// <summary>
 /// 復旧処理を実行します。
 /// </summary>
 ///
 /* ----------------------------------------------------------------- */
 static void ExecRecovery(PageCollection pages, SettingsFolder settings)
 {
     Puts(Properties.Resources.ExecRecovery);
     pages.Recover(settings.MaxAbstractLength);
     pages.Save();
 }