OSDN Git Service

AppliStation-GUI,プロキシ設定GUIの改善
[applistation/AppliStation.git] / AppliStation / UserPrefForm.cs
index e5f1bd6..984c169 100644 (file)
@@ -2,6 +2,7 @@
 using System.Collections.Generic;\r
 using System.Drawing;\r
 using System.Windows.Forms;\r
+using System.Diagnostics;\r
 \r
 using NaGet.Packages;\r
 \r
@@ -240,6 +241,20 @@ namespace AppliStation
                        updateProxyURLEnability();\r
                }\r
                \r
+               void OpenInternetOptionLinkLabelLinkClicked(object sender, LinkLabelLinkClickedEventArgs e)\r
+               {\r
+                       try {\r
+                               ProcessStartInfo procInfo = new ProcessStartInfo("rundll32.exe");\r
+                               procInfo.Arguments = "shell32.dll,Control_RunDLL inetcpl.cpl,,4";\r
+                               procInfo.UseShellExecute = true;\r
+                               procInfo.Verb = "open";\r
+                               \r
+                               Process.Start(procInfo);\r
+                       } catch (Exception) {\r
+                               MessageBox.Show("インターネットオプションが開けませんでした", openInternetOptionLinkLabel.Text, MessageBoxButtons.OK, MessageBoxIcon.Error);\r
+                       }\r
+               }\r
+               \r
                /// <summary>\r
                /// プロキシ設定を、指定された設定オブジェクトに設定する。\r
                /// </summary>\r