Commit b748c1b3 authored by Christian Stenger's avatar Christian Stenger
Browse files

Squish: Avoid Squish crash on Mac



Squish 5.0.1 has problems handling special locations of menus on Mac
using Qt5.2.

Change-Id: I9acc6d0f63e00815ff9ab532cb56a8ca5bb69d6a
Reviewed-by: default avatarRobert Loehning <robert.loehning@digia.com>
parent cae78029
...@@ -228,6 +228,14 @@ def invokeMenuItem(menu, item, *subItems): ...@@ -228,6 +228,14 @@ def invokeMenuItem(menu, item, *subItems):
waitForObject(":Qt Creator.QtCreator.MenuBar_QMenuBar", 2000) waitForObject(":Qt Creator.QtCreator.MenuBar_QMenuBar", 2000)
except: except:
nativeMouseClick(waitForObject(":Qt Creator_Core::Internal::MainWindow", 1000), 20, 20, 0, Qt.LeftButton) nativeMouseClick(waitForObject(":Qt Creator_Core::Internal::MainWindow", 1000), 20, 20, 0, Qt.LeftButton)
# HACK to avoid squish crash using Qt5.2 on Squish 5.0.1 - remove asap
if platform.system() == "Darwin" and not isQt4Build:
if menu == "Tools" and item == "Options...":
nativeType("<Command+,>")
return
if menu == "File" and item == "Exit":
nativeType("<Command+q>")
return
menuObject = waitForObjectItem(":Qt Creator.QtCreator.MenuBar_QMenuBar", menu) menuObject = waitForObjectItem(":Qt Creator.QtCreator.MenuBar_QMenuBar", menu)
waitFor("menuObject.visible", 1000) waitFor("menuObject.visible", 1000)
activateItem(menuObject) activateItem(menuObject)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment