@@ -75,7 +75,7 @@ Item {
75 if (d.altPressed && !d.altTabPressed && event.key !== Qt.Key_Tab && event.key !== Qt.Key_Alt && !d.altPressInjected) {
75 if (d.altPressed && !d.altTabPressed && event.key !== Qt.Key_Tab && event.key !== Qt.Key_Alt && !d.altPressInjected) {
76 // ALT is pressed and another key that is not Tab has been received. Re-inject the alt pressed event
76 // ALT is pressed and another key that is not Tab has been received. Re-inject the alt pressed event
77 d.altPressInjected = true;
77 d.altPressInjected = true;
78− inputEventGenerator.generateEvent(root, Qt.Key_Alt, true, Qt.NoModifier, currentEventTimestamp - 1, 56);
78+ inputEventGenerator.generateKeyEvent(Qt.Key_Alt, true, Qt.NoModifier, currentEventTimestamp - 1, 56);
81 if (event.key == Qt.Key_PowerDown || event.key == Qt.Key_PowerOff) {
81 if (event.key == Qt.Key_PowerDown || event.key == Qt.Key_PowerOff) {
@@ -146,7 +146,7 @@ Item {
146 } else if (d.altPressed && !d.altPressInjected) {
146 } else if (d.altPressed && !d.altPressInjected) {
147 // Alt was released but nothing else. Let's inject a pressed event and also forward the release.
147 // Alt was released but nothing else. Let's inject a pressed event and also forward the release.
148 d.altPressInjected = true;
148 d.altPressInjected = true;
149− inputEventGenerator.generateEvent(root, Qt.Key_Alt, true, Qt.AltModifer, currentEventTimestamp, 56);
149+ inputEventGenerator.generateKeyEvent(Qt.Key_Alt, true, Qt.AltModifer, currentEventTimestamp, 56);
150 d.altPressInjected = false;
150 d.altPressInjected = false;
152 d.altPressed = false;
152 d.altPressed = false;