@@ -274,7 +274,7 @@ Item {
274274 compare(ApplicationManager.focusedApplicationId, selectedApp.appId);
275275 }
276276
277− function test_orientation_change_sent_to_focused_app() {
277+ function test_orientationChangeSentToFocusedApp() {
278278 phoneStage.orientation = Qt.PortraitOrientation;
279279 addApps(1);
280280
@@ -286,7 +286,7 @@ Item {
286286 tryCompare(app, "orientation", Qt.LandscapeOrientation);
287287 }
288288
289− function test_orientation_change_not_sent_to_apps_while_spread_open() {
289+ function test_orientationChangeNotSentToAppsWhileSpreadOpen() {
290290 phoneStage.orientation = Qt.PortraitOrientation;
291291 addApps(1);
292292
@@ -299,7 +299,7 @@ Item {
299299 tryCompare(app, "orientation", Qt.PortraitOrientation);
300300 }
301301
302− function test_orientation_change_not_sent_to_unfocused_app_until_it_focused() {
302+ function test_orientationChangeNotSentToUnfocusedAppUntilItFocused() {
303303 phoneStage.orientation = Qt.PortraitOrientation;
304304 addApps(1);
305305
@@ -357,5 +357,35 @@ Item {
357357 tryCompare(firstApp, "state", ApplicationInfoInterface.Running);
358358 tryCompare(firstApp, "focused", true);
359359 }
360+
361+ function test_cantCloseWhileSnapping() {
362+ addApps(2);
363+
364+ goToSpread();
365+
366+ var spreadView = findChild(phoneStage, "spreadView");
367+ var selectedApp = ApplicationManager.get(2);
368+
369+ goToSpread();
370+
371+ var app0 = findChild(spreadView, "appDelegate0");
372+ var app1 = findChild(spreadView, "appDelegate1");
373+ var app2 = findChild(spreadView, "appDelegate2");
374+
375+ var dragArea0 = findChild(app0, "dragArea");
376+ var dragArea1 = findChild(app1, "dragArea");
377+ var dragArea2 = findChild(app2, "dragArea");
378+
379+ compare(dragArea0.enabled, true);
380+ compare(dragArea1.enabled, true);
381+ compare(dragArea2.enabled, true);
382+
383+ phoneStage.select(selectedApp.appId);
384+
385+ // Make sure all drag areas are disabled instantly. Don't use tryCompare here!
386+ compare(dragArea0.enabled, false);
387+ compare(dragArea1.enabled, false);
388+ compare(dragArea2.enabled, false);
389+ }
360390 }
361391}