MCPcopy Create free account
hub / github.com/Codeya-IDE/deepin-ide / DTreeView

Function DTreeView

src/plugins/debugger/interface/breakpointview.cpp:20–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18#include <QMouseEvent>
19
20DWIDGET_USE_NAMESPACE
21
22BreakpointView::BreakpointView(QWidget *parent)
23 : DTreeView(parent)
24{
25 initHeaderView();
26 setHeader(headerView);
27 setTextElideMode(Qt::TextElideMode::ElideLeft);
28 setSelectionBehavior(QAbstractItemView::SelectionBehavior::SelectRows);
29 setSelectionMode(QAbstractItemView::ExtendedSelection);
30 setFrameStyle(QFrame::NoFrame);
31 setAlternatingRowColors(true);
32 setItemDelegate(new BaseItemDelegate(this));
33 editService = dpfGetService(dpfservice::EditorService);
34
35 connect(this, &QAbstractItemView::clicked,
36 this, [=](const QModelIndex &index) {
37 BreakpointModel *bpModel = static_cast<BreakpointModel *>(model());
38 bpModel->setCurrentIndex(index.row());
39 });
40}
41
42BreakpointView::~BreakpointView()
43{

Callers

nothing calls this directly

Calls 4

connectFunction · 0.85
modelClass · 0.85
rowMethod · 0.80
setCurrentIndexMethod · 0.45

Tested by

no test coverage detected