MCPcopy Create free account
hub / github.com/ElementsProject/elements / eventFilter

Method eventFilter

src/qt/modaloverlay.cpp:48–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

46}
47
48bool ModalOverlay::eventFilter(QObject * obj, QEvent * ev) {
49 if (obj == parent()) {
50 if (ev->type() == QEvent::Resize) {
51 QResizeEvent * rev = static_cast<QResizeEvent*>(ev);
52 resize(rev->size());
53 if (!layerIsVisible)
54 setGeometry(0, height(), width(), height());
55
56 if (m_animation.endValue().toPoint().y() > 0) {
57 m_animation.setEndValue(QPoint(0, height()));
58 }
59 }
60 else if (ev->type() == QEvent::ChildAdded) {
61 raise();
62 }
63 }
64 return QWidget::eventFilter(obj, ev);
65}
66
67//! Tracks parent widget changes
68bool ModalOverlay::event(QEvent* ev) {

Callers

nothing calls this directly

Calls 3

QPointClass · 0.85
typeMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected