From 689b7fc0e6efc6c219411dbe077ac5016a511a8f Mon Sep 17 00:00:00 2001 From: Sergey Karashevich Date: Mon, 19 Feb 2018 17:44:15 +0300 Subject: [PATCH] [gui-test] add one shortcut method for multiple systems --- .../src/com/intellij/testGuiFramework/impl/GuiTestCase.kt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/GuiTestCase.kt b/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/GuiTestCase.kt index a89e503a1f07..06bccefb2652 100644 --- a/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/GuiTestCase.kt +++ b/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/GuiTestCase.kt @@ -631,6 +631,11 @@ open class GuiTestCase { fun shortcut(shortcut: Shortcut) = shortcut(shortcut.getKeystroke()) + fun shortcut(winShortcut: Shortcut, macShortcut: Shortcut) { + if (SystemInfo.isMac()) shortcut(macShortcut) + else shortcut(winShortcut) + } + fun shortcut(key: Key) = shortcut(key.name) /**