summaryrefslogtreecommitdiff
path: root/odk/examples/DevelopersGuide/OfficeDev
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-08-12 15:09:06 +0200
committerNoel Grandin <noel@peralex.com>2014-08-19 14:57:17 +0200
commitff0ad0493ee1729c726587f667761b04101d774c (patch)
tree8c0f97e8740fbdb2ed0cdbfc5d99d82cae8f7df6 /odk/examples/DevelopersGuide/OfficeDev
parentbe1bb7b1ccee28be616b89cc95e97d656e78bbe3 (diff)
java: use 'Integer.valueOf' instead of 'new Integer'
Change-Id: Ia8befb8d69914ce971174fc5f2ffc0e2f506a940
Diffstat (limited to 'odk/examples/DevelopersGuide/OfficeDev')
-rw-r--r--odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java2
-rw-r--r--odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java4
2 files changed, 3 insertions, 3 deletions
diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java
index 712abb91fcc3..63fc3cd8392c 100644
--- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java
+++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java
@@ -155,7 +155,7 @@ public class NativeView extends java.awt.Canvas
{
if(maHandle==null)
{
- maHandle = new Integer((int)getNativeWindow());
+ maHandle = Integer.valueOf((int)getNativeWindow());
maSystem = getNativeWindowSystemType();
}
return maHandle;
diff --git a/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java b/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java
index 0f7e25851a4d..f6a8f8c035d8 100644
--- a/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java
+++ b/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java
@@ -114,7 +114,7 @@ public class Number_Formats
com.sun.star.beans.XPropertySet.class, xCellRange );
// Set number format to default currency
- xCellProp.setPropertyValue( "NumberFormat", new Integer(nCurrencyKey) );
+ xCellProp.setPropertyValue( "NumberFormat", Integer.valueOf(nCurrencyKey) );
// Get cell B3
com.sun.star.table.XCell xCell = maSheet.getCellByPosition( 1, 2 );
@@ -158,7 +158,7 @@ public class Number_Formats
// Set the new format at the cell
if ( nIndexKey != -1 )
- xCellProp.setPropertyValue( "NumberFormat", new Integer(nIndexKey) );
+ xCellProp.setPropertyValue( "NumberFormat", Integer.valueOf(nIndexKey) );
// Set column containing the example values to optimal width to show