MCPcopy Create free account
hub / github.com/KDE/kdevelop / mousePressEvent

Function mousePressEvent

kdevplatform/sublime/container.cpp:132–143  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

130 return QTabBar::event(ev);
131 }
132 void mousePressEvent(QMouseEvent* event) override {
133 if (event->button() == Qt::MiddleButton) {
134 // just close on midbutton, drag can still be done with left mouse button
135
136 int tab = tabAt(event->pos());
137 if (tab != -1) {
138 emit tabCloseRequested(tab);
139 }
140 return;
141 }
142 QTabBar::mousePressEvent(event);
143 }
144
145 void mouseDoubleClickEvent(QMouseEvent* event) override
146 {

Callers 1

mousePressEventMethod · 0.50

Calls 2

buttonMethod · 0.80
posMethod · 0.80

Tested by

no test coverage detected