From acd996ade6fb6eecffa96c2e3545c66925cebda3 Mon Sep 17 00:00:00 2001 From: IonutMuthi Date: Thu, 21 Nov 2024 02:16:34 -0500 Subject: [PATCH] dac: info button added options for tutorial and documentation Signed-off-by: IonutMuthi --- plugins/dac/src/dacinstrument.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/dac/src/dacinstrument.cpp b/plugins/dac/src/dacinstrument.cpp index c6774bc9a3..0f181ffbae 100644 --- a/plugins/dac/src/dacinstrument.cpp +++ b/plugins/dac/src/dacinstrument.cpp @@ -57,7 +57,7 @@ DacInstrument::DacInstrument(const Connection *conn, QWidget *parent) openLastMenuBtn = new OpenLastMenuBtn(dynamic_cast(tool->rightContainer()), true, this); rightMenuBtnGrp = dynamic_cast(openLastMenuBtn)->getButtonGroup(); - infoBtn = new InfoBtn(this); + infoBtn = new InfoBtn(this, true); settingsBtn = new GearBtn(this); devicesGroup = new QButtonGroup(this); @@ -71,7 +71,9 @@ DacInstrument::DacInstrument(const Connection *conn, QWidget *parent) rightMenuBtnGrp->addButton(settingsBtn); rightMenuBtnGrp->addButton(devicesBtn->button()); - connect(infoBtn, &QAbstractButton::clicked, this, [=, this]() { + connect(infoBtn->getTutorialButton(), &QPushButton::clicked, this, [=]() { this->startTutorial(); }); + + connect(infoBtn->getDocumentationButton(), &QAbstractButton::clicked, this, [=, this]() { QDesktopServices::openUrl(QUrl("https://analogdevicesinc.github.io/scopy/plugins/dac/dac.html")); }); connect(devicesBtn, &QPushButton::toggled, dynamic_cast(tool->leftContainer()),