diff options
Diffstat (limited to 'ui')
-rw-r--r-- | ui/gtk/main.c | 86 | ||||
-rw-r--r-- | ui/qt/main_window_slots.cpp | 2 |
2 files changed, 30 insertions, 58 deletions
diff --git a/ui/gtk/main.c b/ui/gtk/main.c index 5870daef0b..86a3574843 100644 --- a/ui/gtk/main.c +++ b/ui/gtk/main.c @@ -426,41 +426,27 @@ selected_ptree_info_cb(GtkWidget *widget _U_, gpointer data _U_) proto_abbrev = proto_registrar_get_abbrev(field_id); - if (!proto_is_private(field_id)) { - /* ask the user if the wiki page really should be opened */ - dialog = simple_dialog(ESD_TYPE_CONFIRMATION, ESD_BTNS_OK_CANCEL, - "%sOpen Wireshark Wiki page of protocol \"%s\"?%s\n" - "\n" - "This will open the \"%s\" related Wireshark Wiki page in your Web browser.\n" - "\n" - "The Wireshark Wiki is a collaborative approach to provide information " - "about Wireshark in several ways (not limited to protocol specifics).\n" - "\n" - "This Wiki is new, so the page of the selected protocol " - "may not exist and/or may not contain valuable information.\n" - "\n" - "As everyone can edit the Wiki and add new content (or extend existing), " - "you are encouraged to add information if you can.\n" - "\n" - "Hint 1: If you are new to wiki editing, try out editing the Sandbox first!\n" - "\n" - "Hint 2: If you want to add a new protocol page, you should use the ProtocolTemplate, " - "which will save you a lot of editing and will give a consistent look over the pages.", - simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); - simple_dialog_set_cb(dialog, selected_ptree_info_answered_cb, (gpointer)proto_abbrev); - } else { - /* appologize to the user that the wiki page cannot be opened */ - simple_dialog(ESD_TYPE_WARN, ESD_BTN_OK, - "%sCan't open Wireshark Wiki page of protocol \"%s\"%s\n" - "\n" - "This would open the \"%s\" related Wireshark Wiki page in your Web browser.\n" - "\n" - "Since this is a private protocol, such information is not available in " - "a public wiki. Therefore this wiki entry is blocked.\n" - "\n" - "Sorry for the inconvenience.\n", - simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); - } + /* ask the user if the wiki page really should be opened */ + dialog = simple_dialog(ESD_TYPE_CONFIRMATION, ESD_BTNS_OK_CANCEL, + "%sOpen Wireshark Wiki page of protocol \"%s\"?%s\n" + "\n" + "This will open the \"%s\" related Wireshark Wiki page in your Web browser.\n" + "\n" + "The Wireshark Wiki is a collaborative approach to provide information " + "about Wireshark in several ways (not limited to protocol specifics).\n" + "\n" + "This Wiki is new, so the page of the selected protocol " + "may not exist and/or may not contain valuable information.\n" + "\n" + "As everyone can edit the Wiki and add new content (or extend existing), " + "you are encouraged to add information if you can.\n" + "\n" + "Hint 1: If you are new to wiki editing, try out editing the Sandbox first!\n" + "\n" + "Hint 2: If you want to add a new protocol page, you should use the ProtocolTemplate, " + "which will save you a lot of editing and will give a consistent look over the pages.", + simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); + simple_dialog_set_cb(dialog, selected_ptree_info_answered_cb, (gpointer)proto_abbrev); } } @@ -504,28 +490,14 @@ selected_ptree_ref_cb(GtkWidget *widget _U_, gpointer data _U_) proto_abbrev = proto_registrar_get_abbrev(field_id); - if (!proto_is_private(field_id)) { - /* ask the user if the wiki page really should be opened */ - dialog = simple_dialog(ESD_TYPE_CONFIRMATION, ESD_BTNS_OK_CANCEL, - "%sOpen Wireshark filter reference page of protocol \"%s\"?%s\n" - "\n" - "This will open the \"%s\" related Wireshark filter reference page in your Web browser.\n" - "\n", - simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); - simple_dialog_set_cb(dialog, selected_ptree_ref_answered_cb, (gpointer)proto_abbrev); - } else { - /* appologize to the user that the wiki page cannot be opened */ - simple_dialog(ESD_TYPE_WARN, ESD_BTN_OK, - "%sCan't open Wireshark filter reference page of protocol \"%s\"%s\n" - "\n" - "This would open the \"%s\" related Wireshark filter reference page in your Web browser.\n" - "\n" - "Since this is a private protocol, such information is not available on " - "a public website. Therefore this filter entry is blocked.\n" - "\n" - "Sorry for the inconvenience.\n", - simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); - } + /* ask the user if the wiki page really should be opened */ + dialog = simple_dialog(ESD_TYPE_CONFIRMATION, ESD_BTNS_OK_CANCEL, + "%sOpen Wireshark filter reference page of protocol \"%s\"?%s\n" + "\n" + "This will open the \"%s\" related Wireshark filter reference page in your Web browser.\n" + "\n", + simple_dialog_primary_start(), proto_abbrev, simple_dialog_primary_end(), proto_abbrev); + simple_dialog_set_cb(dialog, selected_ptree_ref_answered_cb, (gpointer)proto_abbrev); } } diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp index 460fdcb591..f0b3cf0a25 100644 --- a/ui/qt/main_window_slots.cpp +++ b/ui/qt/main_window_slots.cpp @@ -1234,7 +1234,7 @@ void MainWindow::setMenusForSelectedTreeRow(field_info *fi) { field_id = proto_registrar_get_parent(fi->hfinfo->id); } - if (field_id >= 0 && !proto_is_private(field_id)) { + if (field_id >= 0) { can_open_url = true; main_ui_->actionContextWikiProtocolPage->setData(field_id); main_ui_->actionContextFilterFieldReference->setData(field_id); |