diff options
author | Noel Grandin <noel@peralex.com> | 2014-08-12 15:12:27 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-08-19 14:57:18 +0200 |
commit | 0764292c5dcb7daa62e9adeb1ac9af1dbe14066f (patch) | |
tree | 17a4e9f2393d23aaba1e68bbc944aa8e18b9e2f6 /framework | |
parent | java: use 'Long.valueOf' instead of 'new Long' (diff) | |
download | core-0764292c5dcb7daa62e9adeb1ac9af1dbe14066f.tar.gz core-0764292c5dcb7daa62e9adeb1ac9af1dbe14066f.zip |
java: use 'Short.valueOf' instead of 'new Short'
Change-Id: Icef19ef61ee0af2dd3bda527263934006271f219
Diffstat (limited to 'framework')
-rw-r--r-- | framework/qa/complex/accelerators/KeyMapping.java | 146 | ||||
-rw-r--r-- | framework/qa/complex/contextMenuInterceptor/ContextMenuInterceptor.java | 2 |
2 files changed, 74 insertions, 74 deletions
diff --git a/framework/qa/complex/accelerators/KeyMapping.java b/framework/qa/complex/accelerators/KeyMapping.java index 8573051dd51a..0eb23b08b452 100644 --- a/framework/qa/complex/accelerators/KeyMapping.java +++ b/framework/qa/complex/accelerators/KeyMapping.java @@ -48,78 +48,78 @@ public class KeyMapping public KeyMapping() { KeyIdentifierInfo[] aInfoMap = { - new KeyIdentifierInfo("0", new Short(com.sun.star.awt.Key.NUM0)), - new KeyIdentifierInfo("1", new Short(com.sun.star.awt.Key.NUM1)), - new KeyIdentifierInfo("2", new Short(com.sun.star.awt.Key.NUM2)), - new KeyIdentifierInfo("3", new Short(com.sun.star.awt.Key.NUM3)), - new KeyIdentifierInfo("4", new Short(com.sun.star.awt.Key.NUM4)), - new KeyIdentifierInfo("5", new Short(com.sun.star.awt.Key.NUM5)), - new KeyIdentifierInfo("6", new Short(com.sun.star.awt.Key.NUM6)), - new KeyIdentifierInfo("7", new Short(com.sun.star.awt.Key.NUM7)), - new KeyIdentifierInfo("8", new Short(com.sun.star.awt.Key.NUM8)), - new KeyIdentifierInfo("9", new Short(com.sun.star.awt.Key.NUM9)), - new KeyIdentifierInfo("A", new Short(com.sun.star.awt.Key.A)), - new KeyIdentifierInfo("B", new Short(com.sun.star.awt.Key.B)), - new KeyIdentifierInfo("C", new Short(com.sun.star.awt.Key.C)), - new KeyIdentifierInfo("D", new Short(com.sun.star.awt.Key.D)), - new KeyIdentifierInfo("E", new Short(com.sun.star.awt.Key.E)), - new KeyIdentifierInfo("F", new Short(com.sun.star.awt.Key.F)), - new KeyIdentifierInfo("G", new Short(com.sun.star.awt.Key.G)), - new KeyIdentifierInfo("H", new Short(com.sun.star.awt.Key.H)), - new KeyIdentifierInfo("I", new Short(com.sun.star.awt.Key.I)), - new KeyIdentifierInfo("J", new Short(com.sun.star.awt.Key.J)), - new KeyIdentifierInfo("K", new Short(com.sun.star.awt.Key.K)), - new KeyIdentifierInfo("L", new Short(com.sun.star.awt.Key.L)), - new KeyIdentifierInfo("M", new Short(com.sun.star.awt.Key.M)), - new KeyIdentifierInfo("N", new Short(com.sun.star.awt.Key.N)), - new KeyIdentifierInfo("O", new Short(com.sun.star.awt.Key.O)), - new KeyIdentifierInfo("P", new Short(com.sun.star.awt.Key.P)), - new KeyIdentifierInfo("Q", new Short(com.sun.star.awt.Key.Q)), - new KeyIdentifierInfo("R", new Short(com.sun.star.awt.Key.R)), - new KeyIdentifierInfo("S", new Short(com.sun.star.awt.Key.S)), - new KeyIdentifierInfo("T", new Short(com.sun.star.awt.Key.T)), - new KeyIdentifierInfo("U", new Short(com.sun.star.awt.Key.U)), - new KeyIdentifierInfo("V", new Short(com.sun.star.awt.Key.V)), - new KeyIdentifierInfo("W", new Short(com.sun.star.awt.Key.W)), - new KeyIdentifierInfo("X", new Short(com.sun.star.awt.Key.X)), - new KeyIdentifierInfo("Y", new Short(com.sun.star.awt.Key.Y)), - new KeyIdentifierInfo("Z", new Short(com.sun.star.awt.Key.Z)), - new KeyIdentifierInfo("F1", new Short(com.sun.star.awt.Key.F1)), - new KeyIdentifierInfo("F2", new Short(com.sun.star.awt.Key.F2)), - new KeyIdentifierInfo("F3", new Short(com.sun.star.awt.Key.F3)), - new KeyIdentifierInfo("F4", new Short(com.sun.star.awt.Key.F4)), - new KeyIdentifierInfo("F5", new Short(com.sun.star.awt.Key.F5)), - new KeyIdentifierInfo("F6", new Short(com.sun.star.awt.Key.F6)), - new KeyIdentifierInfo("F7", new Short(com.sun.star.awt.Key.F7)), - new KeyIdentifierInfo("F8", new Short(com.sun.star.awt.Key.F8)), - new KeyIdentifierInfo("F9", new Short(com.sun.star.awt.Key.F9)), - new KeyIdentifierInfo("F10", new Short(com.sun.star.awt.Key.F10)), - new KeyIdentifierInfo("F11", new Short(com.sun.star.awt.Key.F11)), - new KeyIdentifierInfo("F12", new Short(com.sun.star.awt.Key.F12)), - new KeyIdentifierInfo("DOWN", new Short(com.sun.star.awt.Key.DOWN)), - new KeyIdentifierInfo("UP", new Short(com.sun.star.awt.Key.UP)), - new KeyIdentifierInfo("LEFT", new Short(com.sun.star.awt.Key.LEFT)), - new KeyIdentifierInfo("RIGHT", new Short(com.sun.star.awt.Key.RIGHT)), - new KeyIdentifierInfo("HOME", new Short(com.sun.star.awt.Key.HOME)), - new KeyIdentifierInfo("END", new Short(com.sun.star.awt.Key.END)), - new KeyIdentifierInfo("PAGEUP", new Short(com.sun.star.awt.Key.PAGEUP)), - new KeyIdentifierInfo("PAGEDOWN", new Short(com.sun.star.awt.Key.PAGEDOWN)), - new KeyIdentifierInfo("RETURN", new Short(com.sun.star.awt.Key.RETURN)), - new KeyIdentifierInfo("ESCAPE", new Short(com.sun.star.awt.Key.ESCAPE)), - new KeyIdentifierInfo("TAB", new Short(com.sun.star.awt.Key.TAB)), - new KeyIdentifierInfo("BACKSPACE", new Short(com.sun.star.awt.Key.BACKSPACE)), - new KeyIdentifierInfo("SPACE", new Short(com.sun.star.awt.Key.SPACE)), - new KeyIdentifierInfo("INSERT", new Short(com.sun.star.awt.Key.INSERT)), - new KeyIdentifierInfo("DELETE", new Short(com.sun.star.awt.Key.DELETE)), - new KeyIdentifierInfo("ADD", new Short(com.sun.star.awt.Key.ADD)), - new KeyIdentifierInfo("SUBTRACT", new Short(com.sun.star.awt.Key.SUBTRACT)), - new KeyIdentifierInfo("MULTIPLY", new Short(com.sun.star.awt.Key.MULTIPLY)), - new KeyIdentifierInfo("DIVIDE", new Short(com.sun.star.awt.Key.DIVIDE)), - new KeyIdentifierInfo("CUT", new Short(com.sun.star.awt.Key.CUT)), - new KeyIdentifierInfo("COPY", new Short(com.sun.star.awt.Key.COPY)), - new KeyIdentifierInfo("PASTE", new Short(com.sun.star.awt.Key.PASTE)), - new KeyIdentifierInfo("UNDO", new Short(com.sun.star.awt.Key.UNDO)), - new KeyIdentifierInfo("REPEAT", new Short(com.sun.star.awt.Key.REPEAT)) + new KeyIdentifierInfo("0", Short.valueOf(com.sun.star.awt.Key.NUM0)), + new KeyIdentifierInfo("1", Short.valueOf(com.sun.star.awt.Key.NUM1)), + new KeyIdentifierInfo("2", Short.valueOf(com.sun.star.awt.Key.NUM2)), + new KeyIdentifierInfo("3", Short.valueOf(com.sun.star.awt.Key.NUM3)), + new KeyIdentifierInfo("4", Short.valueOf(com.sun.star.awt.Key.NUM4)), + new KeyIdentifierInfo("5", Short.valueOf(com.sun.star.awt.Key.NUM5)), + new KeyIdentifierInfo("6", Short.valueOf(com.sun.star.awt.Key.NUM6)), + new KeyIdentifierInfo("7", Short.valueOf(com.sun.star.awt.Key.NUM7)), + new KeyIdentifierInfo("8", Short.valueOf(com.sun.star.awt.Key.NUM8)), + new KeyIdentifierInfo("9", Short.valueOf(com.sun.star.awt.Key.NUM9)), + new KeyIdentifierInfo("A", Short.valueOf(com.sun.star.awt.Key.A)), + new KeyIdentifierInfo("B", Short.valueOf(com.sun.star.awt.Key.B)), + new KeyIdentifierInfo("C", Short.valueOf(com.sun.star.awt.Key.C)), + new KeyIdentifierInfo("D", Short.valueOf(com.sun.star.awt.Key.D)), + new KeyIdentifierInfo("E", Short.valueOf(com.sun.star.awt.Key.E)), + new KeyIdentifierInfo("F", Short.valueOf(com.sun.star.awt.Key.F)), + new KeyIdentifierInfo("G", Short.valueOf(com.sun.star.awt.Key.G)), + new KeyIdentifierInfo("H", Short.valueOf(com.sun.star.awt.Key.H)), + new KeyIdentifierInfo("I", Short.valueOf(com.sun.star.awt.Key.I)), + new KeyIdentifierInfo("J", Short.valueOf(com.sun.star.awt.Key.J)), + new KeyIdentifierInfo("K", Short.valueOf(com.sun.star.awt.Key.K)), + new KeyIdentifierInfo("L", Short.valueOf(com.sun.star.awt.Key.L)), + new KeyIdentifierInfo("M", Short.valueOf(com.sun.star.awt.Key.M)), + new KeyIdentifierInfo("N", Short.valueOf(com.sun.star.awt.Key.N)), + new KeyIdentifierInfo("O", Short.valueOf(com.sun.star.awt.Key.O)), + new KeyIdentifierInfo("P", Short.valueOf(com.sun.star.awt.Key.P)), + new KeyIdentifierInfo("Q", Short.valueOf(com.sun.star.awt.Key.Q)), + new KeyIdentifierInfo("R", Short.valueOf(com.sun.star.awt.Key.R)), + new KeyIdentifierInfo("S", Short.valueOf(com.sun.star.awt.Key.S)), + new KeyIdentifierInfo("T", Short.valueOf(com.sun.star.awt.Key.T)), + new KeyIdentifierInfo("U", Short.valueOf(com.sun.star.awt.Key.U)), + new KeyIdentifierInfo("V", Short.valueOf(com.sun.star.awt.Key.V)), + new KeyIdentifierInfo("W", Short.valueOf(com.sun.star.awt.Key.W)), + new KeyIdentifierInfo("X", Short.valueOf(com.sun.star.awt.Key.X)), + new KeyIdentifierInfo("Y", Short.valueOf(com.sun.star.awt.Key.Y)), + new KeyIdentifierInfo("Z", Short.valueOf(com.sun.star.awt.Key.Z)), + new KeyIdentifierInfo("F1", Short.valueOf(com.sun.star.awt.Key.F1)), + new KeyIdentifierInfo("F2", Short.valueOf(com.sun.star.awt.Key.F2)), + new KeyIdentifierInfo("F3", Short.valueOf(com.sun.star.awt.Key.F3)), + new KeyIdentifierInfo("F4", Short.valueOf(com.sun.star.awt.Key.F4)), + new KeyIdentifierInfo("F5", Short.valueOf(com.sun.star.awt.Key.F5)), + new KeyIdentifierInfo("F6", Short.valueOf(com.sun.star.awt.Key.F6)), + new KeyIdentifierInfo("F7", Short.valueOf(com.sun.star.awt.Key.F7)), + new KeyIdentifierInfo("F8", Short.valueOf(com.sun.star.awt.Key.F8)), + new KeyIdentifierInfo("F9", Short.valueOf(com.sun.star.awt.Key.F9)), + new KeyIdentifierInfo("F10", Short.valueOf(com.sun.star.awt.Key.F10)), + new KeyIdentifierInfo("F11", Short.valueOf(com.sun.star.awt.Key.F11)), + new KeyIdentifierInfo("F12", Short.valueOf(com.sun.star.awt.Key.F12)), + new KeyIdentifierInfo("DOWN", Short.valueOf(com.sun.star.awt.Key.DOWN)), + new KeyIdentifierInfo("UP", Short.valueOf(com.sun.star.awt.Key.UP)), + new KeyIdentifierInfo("LEFT", Short.valueOf(com.sun.star.awt.Key.LEFT)), + new KeyIdentifierInfo("RIGHT", Short.valueOf(com.sun.star.awt.Key.RIGHT)), + new KeyIdentifierInfo("HOME", Short.valueOf(com.sun.star.awt.Key.HOME)), + new KeyIdentifierInfo("END", Short.valueOf(com.sun.star.awt.Key.END)), + new KeyIdentifierInfo("PAGEUP", Short.valueOf(com.sun.star.awt.Key.PAGEUP)), + new KeyIdentifierInfo("PAGEDOWN", Short.valueOf(com.sun.star.awt.Key.PAGEDOWN)), + new KeyIdentifierInfo("RETURN", Short.valueOf(com.sun.star.awt.Key.RETURN)), + new KeyIdentifierInfo("ESCAPE", Short.valueOf(com.sun.star.awt.Key.ESCAPE)), + new KeyIdentifierInfo("TAB", Short.valueOf(com.sun.star.awt.Key.TAB)), + new KeyIdentifierInfo("BACKSPACE", Short.valueOf(com.sun.star.awt.Key.BACKSPACE)), + new KeyIdentifierInfo("SPACE", Short.valueOf(com.sun.star.awt.Key.SPACE)), + new KeyIdentifierInfo("INSERT", Short.valueOf(com.sun.star.awt.Key.INSERT)), + new KeyIdentifierInfo("DELETE", Short.valueOf(com.sun.star.awt.Key.DELETE)), + new KeyIdentifierInfo("ADD", Short.valueOf(com.sun.star.awt.Key.ADD)), + new KeyIdentifierInfo("SUBTRACT", Short.valueOf(com.sun.star.awt.Key.SUBTRACT)), + new KeyIdentifierInfo("MULTIPLY", Short.valueOf(com.sun.star.awt.Key.MULTIPLY)), + new KeyIdentifierInfo("DIVIDE", Short.valueOf(com.sun.star.awt.Key.DIVIDE)), + new KeyIdentifierInfo("CUT", Short.valueOf(com.sun.star.awt.Key.CUT)), + new KeyIdentifierInfo("COPY", Short.valueOf(com.sun.star.awt.Key.COPY)), + new KeyIdentifierInfo("PASTE", Short.valueOf(com.sun.star.awt.Key.PASTE)), + new KeyIdentifierInfo("UNDO", Short.valueOf(com.sun.star.awt.Key.UNDO)), + new KeyIdentifierInfo("REPEAT", Short.valueOf(com.sun.star.awt.Key.REPEAT)) }; aIdentifierHashMap = new IdentifierHashMap(); @@ -138,6 +138,6 @@ public class KeyMapping public String mapCode2Identifier(short nCode) { - return aCodeHashMap.get(new Short(nCode)); + return aCodeHashMap.get(Short.valueOf(nCode)); } } diff --git a/framework/qa/complex/contextMenuInterceptor/ContextMenuInterceptor.java b/framework/qa/complex/contextMenuInterceptor/ContextMenuInterceptor.java index 306ba6d3bb78..d3430486560c 100644 --- a/framework/qa/complex/contextMenuInterceptor/ContextMenuInterceptor.java +++ b/framework/qa/complex/contextMenuInterceptor/ContextMenuInterceptor.java @@ -53,7 +53,7 @@ public class ContextMenuInterceptor implements XContextMenuInterceptor // create a line separator for our new help sub menu com.sun.star.beans.XPropertySet xSeparator = UnoRuntime.queryInterface(com.sun.star.beans.XPropertySet.class, xMenuElementFactory.createInstance("com.sun.star.ui.ActionTriggerSeparator")); - Short aSeparatorType = new Short(ActionTriggerSeparatorType.LINE); + Short aSeparatorType = Short.valueOf(ActionTriggerSeparatorType.LINE); xSeparator.setPropertyValue("SeparatorType", aSeparatorType); // query sub menu for index container to get access |