MCPcopy Create free account
hub / github.com/Audio4Linux/JDSP4Linux / AppManagerFragment

Method AppManagerFragment

src/interface/fragment/AppManagerFragment.cpp:9–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7#include "interface/item/AppItemStyleDelegate.h"
8
9AppManagerFragment::AppManagerFragment(IAppManager* appMgr, QWidget *parent) :
10 BaseFragment(parent),
11 ui(new Ui::AppManagerFragment),
12 appMgr(appMgr)
13{
14 ui->setupUi(this);
15
16 model = new AppItemModel(appMgr, this);
17
18 ui->apps->setEmptyViewEnabled(true);
19 ui->apps->setEmptyViewTitle(tr("No apps are playing audio"));
20 ui->apps->setFocusPolicy(Qt::FocusPolicy::NoFocus);
21 ui->apps->setModel(model);
22 ui->apps->setItemDelegate(new AppItemStyleDelegate(ui->apps));
23
24 connect(model, &AppItemModel::rowsInserted, this, &AppManagerFragment::rowsInserted);
25 connect(model, &AppItemModel::rowsAboutToBeRemoved, this, &AppManagerFragment::rowsAboutToBeRemoved);
26
27 connect(ui->close, &QPushButton::clicked, this, &AppManagerFragment::closePressed);
28}
29
30AppManagerFragment::~AppManagerFragment()
31{

Callers

nothing calls this directly

Calls 3

connectFunction · 0.85
setEmptyViewEnabledMethod · 0.45
setEmptyViewTitleMethod · 0.45

Tested by

no test coverage detected