Qt: make Decode As from packet list functional again

The "create_new" property was never set which prevented a new row from
being created once the dialog is opened.

Change-Id: I19c793ebd219bb58cb34f4d67451660ace51aa32
Fixes: v3.1.1rc0-254-gf402b4cdaa72 ("Qt: PacketList call DecodeAsDialog directly")
Reviewed-on: https://code.wireshark.org/review/36020
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
Peter Wu 2020-02-03 19:05:51 +01:00 committed by Anders Broman
parent abe50bf237
commit 6bbd61860b
1 changed files with 1 additions and 0 deletions

View File

@ -706,6 +706,7 @@ void PacketList::contextMenuEvent(QContextMenuEvent *event)
ctx_menu->addSeparator();
ctx_menu->addMenu(&proto_prefs_menu_);
action = ctx_menu->addAction(tr("Decode As" UTF8_HORIZONTAL_ELLIPSIS));
action->setProperty("create_new", QVariant(true));
connect(action, &QAction::triggered, this, &PacketList::ctxDecodeAsDialog);
// "Print" not ported intentionally
action = window()->findChild<QAction *>("actionViewShowPacketInNewWindow");