summaryrefslogtreecommitdiff
path: root/qadevOOo/tests/java/ifc
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-11-02 09:52:08 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-11-02 12:00:34 +0100
commit41d9584179ef7b4e18eda47c2c0a955df8c087a5 (patch)
tree272551363a71f4ea34c032504cc4e058a60a91ae /qadevOOo/tests/java/ifc
parentcb982f14796aa4dc4362bc6fde74161afa11777b (diff)
'new Double' is deprecated in Java
replace with Double.valueOf Change-Id: If5be8e500e31ebf9d5fb20ea7dd474677d7c74ff Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158785 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'qadevOOo/tests/java/ifc')
-rw-r--r--qadevOOo/tests/java/ifc/accessibility/_XAccessibleValue.java2
-rw-r--r--qadevOOo/tests/java/ifc/awt/_UnoControlCurrencyFieldModel.java2
-rw-r--r--qadevOOo/tests/java/ifc/awt/_UnoControlFormattedFieldModel.java8
-rw-r--r--qadevOOo/tests/java/ifc/awt/_UnoControlNumericFieldModel.java2
-rw-r--r--qadevOOo/tests/java/ifc/chart/_ChartAxis.java2
-rw-r--r--qadevOOo/tests/java/ifc/form/component/_CurrencyField.java2
-rw-r--r--qadevOOo/tests/java/ifc/form/component/_NumericField.java2
-rw-r--r--qadevOOo/tests/java/ifc/sheet/_XCellRangeData.java2
8 files changed, 11 insertions, 11 deletions
diff --git a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleValue.java b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleValue.java
index e9e84bbb3429..865e8884d53f 100644
--- a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleValue.java
+++ b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleValue.java
@@ -326,7 +326,7 @@ public class _XAccessibleValue extends MultiMethodTest {
return Float.valueOf((float)val);
}
else if (clazz.equals(Double.class)) {
- return new Double(val);
+ return Double.valueOf(val);
}
else {
throw new StatusException
diff --git a/qadevOOo/tests/java/ifc/awt/_UnoControlCurrencyFieldModel.java b/qadevOOo/tests/java/ifc/awt/_UnoControlCurrencyFieldModel.java
index a4daa1315add..5698cab3f363 100644
--- a/qadevOOo/tests/java/ifc/awt/_UnoControlCurrencyFieldModel.java
+++ b/qadevOOo/tests/java/ifc/awt/_UnoControlCurrencyFieldModel.java
@@ -121,7 +121,7 @@ public class _UnoControlCurrencyFieldModel extends MultiPropertyTest {
testProperty("Value", new PropertyTester() {
@Override
protected Object getNewValue(String prop, Object old) {
- return utils.isVoid(old) ? new Double(777) :
+ return utils.isVoid(old) ? Double.valueOf(777) :
super.getNewValue(prop, old) ;
}
}) ;
diff --git a/qadevOOo/tests/java/ifc/awt/_UnoControlFormattedFieldModel.java b/qadevOOo/tests/java/ifc/awt/_UnoControlFormattedFieldModel.java
index 3538eb6afe10..4ab1a03bdfc5 100644
--- a/qadevOOo/tests/java/ifc/awt/_UnoControlFormattedFieldModel.java
+++ b/qadevOOo/tests/java/ifc/awt/_UnoControlFormattedFieldModel.java
@@ -137,7 +137,7 @@ public class _UnoControlFormattedFieldModel extends MultiPropertyTest {
* new value must be specified.
*/
public void _EffectiveDefault() {
- testProperty("EffectiveDefault", new Double(5.8),new Double(2.3)) ;
+ testProperty("EffectiveDefault", Double.valueOf(5.8),Double.valueOf(2.3)) ;
}
/**
@@ -145,7 +145,7 @@ public class _UnoControlFormattedFieldModel extends MultiPropertyTest {
* new value must be specified.
*/
public void _EffectiveValue() {
- testProperty("EffectiveValue", new Double(5.8),new Double(2.3)) ;
+ testProperty("EffectiveValue", Double.valueOf(5.8),Double.valueOf(2.3)) ;
}
/**
@@ -156,7 +156,7 @@ public class _UnoControlFormattedFieldModel extends MultiPropertyTest {
testProperty("EffectiveMax", new PropertyTester() {
@Override
protected Object getNewValue(String p, Object v) {
- return utils.isVoid(v) ? new Double(123.8) :
+ return utils.isVoid(v) ? Double.valueOf(123.8) :
super.getNewValue(p,v) ;
}
}) ;
@@ -190,7 +190,7 @@ public class _UnoControlFormattedFieldModel extends MultiPropertyTest {
testProperty("EffectiveMin", new PropertyTester() {
@Override
protected Object getNewValue(String p, Object v) {
- return utils.isVoid(v) ? new Double(0.1) :
+ return utils.isVoid(v) ? Double.valueOf(0.1) :
super.getNewValue(p,v) ;
}
}) ;
diff --git a/qadevOOo/tests/java/ifc/awt/_UnoControlNumericFieldModel.java b/qadevOOo/tests/java/ifc/awt/_UnoControlNumericFieldModel.java
index 218696664d2a..f305c5823e9a 100644
--- a/qadevOOo/tests/java/ifc/awt/_UnoControlNumericFieldModel.java
+++ b/qadevOOo/tests/java/ifc/awt/_UnoControlNumericFieldModel.java
@@ -121,7 +121,7 @@ public class _UnoControlNumericFieldModel extends MultiPropertyTest {
testProperty("Value", new PropertyTester() {
@Override
protected Object getNewValue(String p, Object old) {
- return utils.isVoid(old) ? new Double(234.89) :
+ return utils.isVoid(old) ? Double.valueOf(234.89) :
super.getNewValue(p, old) ;
}
}) ;
diff --git a/qadevOOo/tests/java/ifc/chart/_ChartAxis.java b/qadevOOo/tests/java/ifc/chart/_ChartAxis.java
index 2a295c20886f..0528158b21b4 100644
--- a/qadevOOo/tests/java/ifc/chart/_ChartAxis.java
+++ b/qadevOOo/tests/java/ifc/chart/_ChartAxis.java
@@ -151,7 +151,7 @@ public class _ChartAxis extends MultiPropertyTest {
Double ValueToSet = (Double) ValueChanger.changePValue(oldValue);
double stm = ValueToSet.doubleValue();
stm = stm / 5;
- return new Double(stm);
+ return Double.valueOf(stm);
}
};
diff --git a/qadevOOo/tests/java/ifc/form/component/_CurrencyField.java b/qadevOOo/tests/java/ifc/form/component/_CurrencyField.java
index ae1d7de26fd4..422e447c348a 100644
--- a/qadevOOo/tests/java/ifc/form/component/_CurrencyField.java
+++ b/qadevOOo/tests/java/ifc/form/component/_CurrencyField.java
@@ -40,7 +40,7 @@ public class _CurrencyField extends MultiPropertyTest {
testProperty("DefaultValue", new PropertyTester() {
@Override
protected Object getNewValue(String p, Object old) {
- return util.utils.isVoid(old) ? new Double(17.5) :
+ return util.utils.isVoid(old) ? Double.valueOf(17.5) :
super.getNewValue(p, old) ;
}
}) ;
diff --git a/qadevOOo/tests/java/ifc/form/component/_NumericField.java b/qadevOOo/tests/java/ifc/form/component/_NumericField.java
index 463e780c908f..987ba4daa327 100644
--- a/qadevOOo/tests/java/ifc/form/component/_NumericField.java
+++ b/qadevOOo/tests/java/ifc/form/component/_NumericField.java
@@ -40,7 +40,7 @@ public class _NumericField extends MultiPropertyTest {
testProperty("DefaultValue", new PropertyTester() {
@Override
protected Object getNewValue(String prop, Object old) {
- return util.utils.isVoid(old) ? new Double(111.11) :
+ return util.utils.isVoid(old) ? Double.valueOf(111.11) :
super.getNewValue(prop, old) ;
}
}) ;
diff --git a/qadevOOo/tests/java/ifc/sheet/_XCellRangeData.java b/qadevOOo/tests/java/ifc/sheet/_XCellRangeData.java
index 18d8ca0f981a..6e556bbd7518 100644
--- a/qadevOOo/tests/java/ifc/sheet/_XCellRangeData.java
+++ b/qadevOOo/tests/java/ifc/sheet/_XCellRangeData.java
@@ -52,7 +52,7 @@ public class _XCellRangeData extends MultiMethodTest {
newData = new Object[maCRData.length][maCRData[0].length];
for (int i=0; i<newData.length; i++) {
for (int j=0; j<newData[i].length; j++) {
- newData[i][j] = new Double(10*i +j);
+ newData[i][j] = Double.valueOf(10*i +j);
}
}
}