MCPcopy Create free account
hub / github.com/KDAB/GammaRay / removeClient

Method removeClient

plugins/wlcompositorinspector/clientsmodel.cpp:43–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

41}
42
43void ClientsModel::removeClient(QWaylandClient *client)
44{
45 int index = -1;
46 for (int i = 0; i < m_clients.size(); ++i) {
47 if (m_clients.at(i) == client) {
48 index = i;
49 break;
50 }
51 }
52
53 if (index == -1) {
54 return;
55 }
56
57 beginRemoveRows(QModelIndex(), index, index);
58 m_clients.removeAt(index);
59 endRemoveRows();
60}
61
62int ClientsModel::rowCount(const QModelIndex &parent) const
63{

Callers 1

addClientMethod · 0.80

Calls 2

QModelIndexClass · 0.50
sizeMethod · 0.45

Tested by 1

addClientMethod · 0.64