summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-08-05 11:13:40 +0200
committerLionel Elie Mamane <lionel@mamane.lu>2013-08-06 12:19:10 +0200
commitfb0a2199b6baf1166f05b2f19098bc40e677b540 (patch)
tree36b755e7fb59ab78ff4d2e569c67b92b6379ba05
parent586d0ad6f260a00365b1238ed69c98f488fa611a (diff)
Add cases for css.uno.Date/Time to ValueChanger
...needed since 8ee69b0ba13f74d1515fac71df92947eb6328ab1 "fdo#67235 adapt form control code to time nanosecond API change, step 3." Change-Id: Id561151ac4b57b972761ec19f0e8943b8d25a54f
-rw-r--r--qadevOOo/runner/util/ValueChanger.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/qadevOOo/runner/util/ValueChanger.java b/qadevOOo/runner/util/ValueChanger.java
index 6e18ee84c4a5..8df2feea3ffd 100644
--- a/qadevOOo/runner/util/ValueChanger.java
+++ b/qadevOOo/runner/util/ValueChanger.java
@@ -806,6 +806,12 @@ public class ValueChanger {
newVal.Value = changePValue(((PropertyValue)oldValue).Value);
newValue = newVal;
} else
+ if (oldValue instanceof com.sun.star.util.Date) {
+ com.sun.star.util.Date oldD = (com.sun.star.util.Date) oldValue;
+ com.sun.star.util.Date newD = new com.sun.star.util.Date();
+ newD.Day = (short) (oldD.Day+(short) 1);
+ newValue = newD;
+ } else
if (oldValue instanceof com.sun.star.util.DateTime) {
com.sun.star.util.DateTime oldDT = (com.sun.star.util.DateTime) oldValue;
com.sun.star.util.DateTime newDT = new com.sun.star.util.DateTime();
@@ -813,6 +819,12 @@ public class ValueChanger {
newDT.Hours = (short) (oldDT.Hours+(short) 1);
newValue = newDT;
} else
+ if (oldValue instanceof com.sun.star.util.Time) {
+ com.sun.star.util.Time oldT = (com.sun.star.util.Time) oldValue;
+ com.sun.star.util.Time newT = new com.sun.star.util.Time();
+ newT.Hours = (short) (oldT.Hours+(short) 1);
+ newValue = newT;
+ } else
if (oldValue instanceof com.sun.star.text.TableColumnSeparator) {
com.sun.star.text.TableColumnSeparator oldTCS = (com.sun.star.text.TableColumnSeparator) oldValue;
com.sun.star.text.TableColumnSeparator newTCS = new com.sun.star.text.TableColumnSeparator();