1 | // SPDX-FileCopyrightText: 2023 UnionTech Software Technology Co., Ltd. |
---|---|
2 | // |
3 | // SPDX-License-Identifier: GPL-3.0-or-later |
4 | |
5 | #include "perfrecorddisplay.h" |
6 | |
7 | #include <QCheckBox> |
8 | #include <QVBoxLayout> |
9 | |
10 | class PerfRecordDisplayPrivate |
11 | { |
12 | friend class PerfRecordDisplay; |
13 | QCheckBox *showWebBrowse{nullptr}; |
14 | QVBoxLayout *vLayout{nullptr}; |
15 | }; |
16 | |
17 | PerfRecordDisplay::PerfRecordDisplay(QWidget *parent, Qt::WindowFlags f) |
18 | : QWidget (parent, f) |
19 | , d (new PerfRecordDisplayPrivate) |
20 | { |
21 | d->showWebBrowse = new QCheckBox(QCheckBox::tr("use WebBrowser show flame-Graph")); |
22 | |
23 | d->vLayout = new QVBoxLayout(); |
24 | d->vLayout->addWidget(d->showWebBrowse); |
25 | setLayout(d->vLayout); |
26 | |
27 | QObject::connect(d->showWebBrowse, &QCheckBox::toggled, |
28 | this, &PerfRecordDisplay::showWebBrowserGP); |
29 | d->showWebBrowse->setChecked(false); |
30 | } |
31 | |
32 | PerfRecordDisplay::~PerfRecordDisplay() |
33 | { |
34 | if (d) |
35 | delete d; |
36 | } |
37 |