/// <summary> /// Show Message Window /// </summary> public static void ShowMessage(QWidget parent, string title, string message, MessageType mt) { // Gui Message if (mt == MainClass.MessageType.Info) { QMessageBox.Information(parent, title, message); } else if (mt == MainClass.MessageType.Warning) { QMessageBox.Warning(parent, title, message); } else if (mt == MainClass.MessageType.Error) { QMessageBox.Critical(parent, title, message); } }
void HandleLinkClicked(QUrl url) { // We don't open arbitrary links for security reasons. var validSchemes = new [] { "http", "https", "ftp", "xmpp" }; if (validSchemes.Contains(url.Scheme().ToLower())) { Util.Open(url); } else if (url.Scheme().ToLower() == "xmpp") { // FIXME: Add xmpp: uri handler. QMessageBox.Information(this.TopLevelWidget(), "Not implenented", "xmpp: uris not yet supported."); // Ignore # urls. } else if (!url.HasFragment()) { QMessageBox.Information(this.TopLevelWidget(), "Link Fragment", url.HasFragment() + " " + url.Fragment()); QMessageBox.Information(this.TopLevelWidget(), "Link URL", url.ToString()); } }
private void InformationButton_Clicked(bool obj) { QMessageBox.Information(this, "Information", "This Information dialog."); }