#include "main.h"#include "MainWindow.h"#include "KeyTranslator.h"#include <QApplication>int main(int argc, char* argv[]){ QApplication app(argc, argv); KeyTranslator *keyTranslator = new KeyTranslator(); app.installEventFilter(keyTranslator); MainWindow w; w.show(); return app.exec(); delete keyTranslator;//не обязательно}