MCPcopy Create free account
hub / github.com/PolyMC/PolyMC / eventFilter

Method eventFilter

launcher/ui/pages/modplatform/ftb/FtbPage.cpp:83–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

81}
82
83bool FtbPage::eventFilter(QObject* watched, QEvent* event)
84{
85 if (watched == ui->searchEdit && event->type() == QEvent::KeyPress) {
86 QKeyEvent* keyEvent = static_cast<QKeyEvent*>(event);
87 if (keyEvent->key() == Qt::Key_Return) {
88 triggerSearch();
89 keyEvent->accept();
90 return true;
91 }
92 }
93 return QWidget::eventFilter(watched, event);
94}
95
96bool FtbPage::shouldDisplay() const
97{

Callers

nothing calls this directly

Calls 2

typeMethod · 0.45
acceptMethod · 0.45

Tested by

no test coverage detected