You made a mistake here. You have install the event filter of edtFileName to edtFileName. If you want to use event filter in "exportData" classui->edtFileName->installEventFilter(ui->edtFileName);
keyBoard= new KeyboardEntryImpl(ui->edtFileName,NULL);
}
But in the bool exportData::eventFilter(QObject *obj, QEvent *ev)
{
}
then you should use function in this way
Qt Code:
exportData->installEventFilter(ui->editFileName)To copy to clipboard, switch view to plain text mode
Now your code
bool exportData::eventFilter(QObject *obj, QEvent *ev)
{
}
should work fine
Bookmarks