@@ -49,6 +49,11 @@ Rectangle {
49 shellLoader.active = true;
49 shellLoader.active = true;
53+ id: clickThroughCatcher
54+ anchors.fill: shellContainer
53 id: shellContainer
58 id: shellContainer
54 anchors.left: root.left
59 anchors.left: root.left
@@ -291,6 +296,12 @@ Rectangle {
291 signalName: "applicationRemoved"
296 signalName: "applicationRemoved"
301+ target: clickThroughCatcher
302+ signalName: "clicked"
294 Telephony.CallEntry {
305 Telephony.CallEntry {
295 id: phoneCall
306 id: phoneCall
296 phoneNumber: "+447812221111"
307 phoneNumber: "+447812221111"
@@ -1977,5 +1988,47 @@ Rectangle {
1977 compare(ApplicationManager.findApplication("libreoffice") === null, true);
1988 compare(ApplicationManager.findApplication("libreoffice") === null, true);
1992+ function test_inputEventsOnEdgesEndUpInAppSurface_data() {
1994+ { tag: "phone", repeaterName: "spreadRepeater" },
1995+ { tag: "tablet", repeaterName: "spreadRepeater" },
1996+ { tag: "desktop", repeaterName: "appRepeater" },
2000+ function test_inputEventsOnEdgesEndUpInAppSurface(data) {
2001+ loadShell(data.tag);
2002+ shell.usageScenario = data.tag;
2003+ waitForRendering(shell);
2004+ swipeAwayGreeter();
2006+ // Let's open a fullscreen app
2007+ var app = ApplicationManager.startApplication("camera-app");
2008+ waitUntilAppWindowIsFullyLoaded(app);
2010+ var appRepeater = findChild(shell, data.repeaterName);
2011+ var topmostAppDelegate = appRepeater.itemAt(0);
2012+ verify(topmostAppDelegate);
2014+ var topmostSurfaceItem = findChild(topmostAppDelegate, "surfaceItem");
2015+ verify(topmostSurfaceItem);
2017+ mouseClick(shell, 1, shell.height / 2);
2018+ compare(topmostSurfaceItem.mousePressCount, 1);
2019+ compare(topmostSurfaceItem.mouseReleaseCount, 1);
2021+ mouseClick(shell, shell.width - 1, shell.height / 2);
2022+ compare(topmostSurfaceItem.mousePressCount, 2);
2023+ compare(topmostSurfaceItem.mouseReleaseCount, 2);
2025+ tap(shell, 1, shell.height / 2);
2026+ compare(topmostSurfaceItem.touchPressCount, 1);
2027+ compare(topmostSurfaceItem.touchReleaseCount, 1);
2029+ tap(shell, shell.width - 1, shell.height / 2);
2030+ compare(topmostSurfaceItem.touchPressCount, 2);
2031+ compare(topmostSurfaceItem.touchReleaseCount, 2);