From ce29b9eeb646478539040385829acb23ec4e9916 Mon Sep 17 00:00:00 2001 From: GiWoong Kim Date: Fri, 12 Jun 2015 19:29:41 +0900 Subject: [PATCH] menu: modified controller menu change the menu depth modified menu name on SWT UI remove some separator menu items Change-Id: I2847ba5d4de9cb47760d13aee304e043fcda4adb Signed-off-by: GiWoong Kim --- .../skins/mobile-general-3btn/layout.xml | 2 +- .../skin/client/skins/tv-1920x1080/layout.xml | 2 +- .../skins/wearable-general-1btn/layout.xml | 2 +- .../tizen/emulator/skin/menu/PopupMenu.java | 39 ++++++++----------- 4 files changed, 19 insertions(+), 26 deletions(-) diff --git a/tizen/src/skin/client/skins/mobile-general-3btn/layout.xml b/tizen/src/skin/client/skins/mobile-general-3btn/layout.xml index 6f4b217d9b..47e2e551a7 100644 --- a/tizen/src/skin/client/skins/mobile-general-3btn/layout.xml +++ b/tizen/src/skin/client/skins/mobile-general-3btn/layout.xml @@ -47,9 +47,9 @@ - + Ctrl+F7 diff --git a/tizen/src/skin/client/skins/tv-1920x1080/layout.xml b/tizen/src/skin/client/skins/tv-1920x1080/layout.xml index e94ffd118b..2dc65ae935 100644 --- a/tizen/src/skin/client/skins/tv-1920x1080/layout.xml +++ b/tizen/src/skin/client/skins/tv-1920x1080/layout.xml @@ -31,9 +31,9 @@ - + Ctrl+F7 diff --git a/tizen/src/skin/client/skins/wearable-general-1btn/layout.xml b/tizen/src/skin/client/skins/wearable-general-1btn/layout.xml index 9d8d46a8a1..a355d372da 100644 --- a/tizen/src/skin/client/skins/wearable-general-1btn/layout.xml +++ b/tizen/src/skin/client/skins/wearable-general-1btn/layout.xml @@ -37,9 +37,9 @@ Ctrl+Num+9 - + Ctrl+F7 diff --git a/tizen/src/skin/client/src/org/tizen/emulator/skin/menu/PopupMenu.java b/tizen/src/skin/client/src/org/tizen/emulator/skin/menu/PopupMenu.java index afe51ba7ad..1bd07cc71f 100644 --- a/tizen/src/skin/client/src/org/tizen/emulator/skin/menu/PopupMenu.java +++ b/tizen/src/skin/client/src/org/tizen/emulator/skin/menu/PopupMenu.java @@ -57,7 +57,7 @@ public class PopupMenu { public static final String ROTATE_MENUITEM_NAME = "&Rotate"; public static final String SCALE_MENUITEM_NAME = "&Scale"; public static final String INTERPOLATION_MENUITEM_NAME = "&Quality"; - public static final String KEYWINDOW_MENUITEM_NAME = "&Key Window"; + public static final String KEYWINDOW_MENUITEM_NAME = "Contro&ller"; public static final String ADVANCED_MENUITEM_NAME = "Ad&vanced"; public static final String SCREENSHOT_MENUITEM_NAME = "&Screen Shot"; public static final String HOSTKBD_MENUITEM_NAME = "&Host Keyboard"; @@ -191,22 +191,22 @@ public class PopupMenu { new MenuItem(menu, SWT.SEPARATOR); } - /* Key Window menu */ - if (itemProperties == null || - itemProperties.getKeywindowItem() == null) { - keyWindowItem = createKeyWindowItem(menu, KEYWINDOW_MENUITEM_NAME); - } else { - MenuItemType keywindowMenuType = itemProperties.getKeywindowItem(); - if (keywindowMenuType.isVisible() == true) { - keyWindowItem = createKeyWindowItem(menu, - (keywindowMenuType.getItemName().isEmpty()) ? - KEYWINDOW_MENUITEM_NAME : keywindowMenuType.getItemName()); - } - } - /* Advanced menu */ Menu advancedSubMenu = new Menu(menu.getShell(), SWT.DROP_DOWN); { + /* Key Window menu */ + if (itemProperties == null || + itemProperties.getKeywindowItem() == null) { + keyWindowItem = createKeyWindowItem(advancedSubMenu, KEYWINDOW_MENUITEM_NAME); + } else { + MenuItemType keywindowMenuType = itemProperties.getKeywindowItem(); + if (keywindowMenuType.isVisible() == true) { + keyWindowItem = createKeyWindowItem(advancedSubMenu, + (keywindowMenuType.getItemName().isEmpty()) ? + KEYWINDOW_MENUITEM_NAME : keywindowMenuType.getItemName()); + } + } + /* Screen shot menu */ screenshotItem = createScreenShotItem( advancedSubMenu, SCREENSHOT_MENUITEM_NAME); @@ -258,10 +258,6 @@ public class PopupMenu { aboutItem = createAboutItem( advancedSubMenu, ABOUT_MENUITEM_NAME); - if (aboutItem != null) { - new MenuItem(advancedSubMenu, SWT.SEPARATOR); - } - /* Force close menu */ if (itemProperties == null || itemProperties.getForceCloseItem() == null) { @@ -308,10 +304,6 @@ public class PopupMenu { } } - if (keyWindowItem != null || advancedItem != null || shellItem != null) { - new MenuItem(menu, SWT.SEPARATOR); - } - /* Emulator Control Panel menu */ if (itemProperties == null || itemProperties.getControlPanelItem() == null) { @@ -325,7 +317,8 @@ public class PopupMenu { } } - if (ecpItem != null) { + if (keyWindowItem != null || advancedItem != null || + shellItem != null || ecpItem != null) { new MenuItem(menu, SWT.SEPARATOR); } -- 2.34.1