X-Git-Url: http://git.sourceforge.jp/view?p=applistation%2FAppliStation.git;a=blobdiff_plain;f=AppliStation%2FUserPrefForm.cs;h=8005bf322694210db1ac760792b33a3b84235b43;hp=9478094f63aae672d77b4aba51fc1488a4f04db6;hb=5f97683021498f777ca0a733d7d3b2465d71b0f1;hpb=831700d1136c6e067c99faffcc5e6280ff6798db diff --git a/AppliStation/UserPrefForm.cs b/AppliStation/UserPrefForm.cs index 9478094..8005bf3 100644 --- a/AppliStation/UserPrefForm.cs +++ b/AppliStation/UserPrefForm.cs @@ -27,6 +27,7 @@ namespace AppliStation InitializeComponent(); this.openInternetOptionLinkAdminLabel.Visible = ! NaGet.Utils.IsAdministrators(); + AppliStation.Util.NativeMethods.LinkLabel_SetElevationRequiredState(this.openInternetOptionLinkAdminLabel, true); loadCurrentPref(); } @@ -43,6 +44,7 @@ namespace AppliStation this.EnableScanInstallerFile = userPref.EnableScanInstallerFile; this.InstallOnBackground = userPref.InstallOnBackground; this.CacheFolder = userPref.CacheFolder; + this.ExcludeUpdatePackageNames = userPref.ExcludeUpdatePackageNames; } #region レポジトリリスト設定関連 @@ -168,7 +170,7 @@ namespace AppliStation } } - void RepoUrlTextBoxLeave(object sender, EventArgs e) + void RepoUrlTextBoxValidated(object sender, EventArgs e) { int selectedIndex = repoListCheckedListBox.SelectedIndex; if ((0 <= selectedIndex) && (selectedIndex < repos.Count)) { @@ -329,6 +331,37 @@ namespace AppliStation #endregion + #region ソフト更新設定関連 + + + public string[] ExcludeUpdatePackageNames { + set { + this.upgradeExcludeTextBox.Lines = value; + } + get { + List list = new List(); + + foreach (string line in this.upgradeExcludeTextBox.Lines) { + if (!string.IsNullOrEmpty(line)) { + list.Add(line); + } + } + + return list.ToArray(); + } + } + + /// + /// ソフト更新関連設定を、指定された設定オブジェクトに設定する。 + /// + /// 設定オブジェクト + private void commitUpgradeSetting(NaGet.NaGetLibPref pref) + { + pref.ExcludeUpdatePackageNames = this.ExcludeUpdatePackageNames; + } + + #endregion + /// /// 指定された設定オブジェクトをファイルとして保存する /// @@ -350,6 +383,7 @@ namespace AppliStation commitRepositoryListSetting(); commitProxySetting(pref); commitInstallSetting(pref); + commitUpgradeSetting(pref); commitNaGetLibPref(pref); }