/// <summary> /// User clicked on the "web" button to the left of the git repo address. /// Find the canonical web site and open it /// </summary> private void BtWwwClick(object sender, EventArgs e) { string key = ((Button)sender).Tag.ToString(); ClassUrl.Url url = key == "Fetch" ? _fetchUrl : _pushUrl; // Find a generic host name string target = "http://" + url.Host; // Detect some special hosts for which we can form a complete path if (url.Host.Contains("github")) { target += "/" + url.Path; } if (url.Host.Contains(".code.sf.net")) { target = "https://sourceforge.net/projects/" + url.Name; } ClassUtils.OpenWebLink(target); }
/// <summary> /// Open the web browser with a link to msysgit /// </summary> private void GitLinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { ClassUtils.OpenWebLink(linkLabel.Tag.ToString()); }
/// <summary> /// Called when the user clicks on an HTML link inside the output text. /// </summary> private void textLinkClicked(object sender, LinkClickedEventArgs e) { ClassUtils.OpenWebLink(e.LinkText); }