From cc24b5b0a9c1001455ffd6fbde0ee993bf51e4b2 Mon Sep 17 00:00:00 2001 From: Vladimir Glazounov Date: Mon, 28 Jan 2008 14:31:39 +0000 Subject: [PATCH] INTEGRATION: CWS dbawizards (1.6.116); FILE MERGED 2008/01/03 13:55:16 bc 1.6.116.2: #i49332# resetting fixed property for date textfields 2008/01/02 13:46:37 bc 1.6.116.1: #i72887# incorrect behaviour of < in wizard --- .../star/wizards/text/TextFieldHandler.java | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/wizards/com/sun/star/wizards/text/TextFieldHandler.java b/wizards/com/sun/star/wizards/text/TextFieldHandler.java index 59c7f0fb9f1b..48eb8479520b 100644 --- a/wizards/com/sun/star/wizards/text/TextFieldHandler.java +++ b/wizards/com/sun/star/wizards/text/TextFieldHandler.java @@ -4,9 +4,9 @@ * * $RCSfile: TextFieldHandler.java,v $ * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * - * last change: $Author: vg $ $Date: 2006-04-07 12:55:39 $ + * last change: $Author: vg $ $Date: 2008-01-28 15:31:39 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -228,6 +228,7 @@ public class TextFieldHandler { if (xSI.supportsService("com.sun.star.text.TextField.DateTime")) { XPropertySet xPSet = (XPropertySet) UnoRuntime.queryInterface(XPropertySet.class, oTextField); + xPSet.setPropertyValue("IsFixed", Boolean.FALSE); xPSet.setPropertyValue("DateTimeValue", dt); } } @@ -236,6 +237,20 @@ public class TextFieldHandler { } } + public void fixDateFields(boolean _bSetFixed) { + try { + XEnumeration xEnum = xTextFieldsSupplier.getTextFields().createEnumeration(); + while (xEnum.hasMoreElements()) { + Object oTextField = xEnum.nextElement(); + XServiceInfo xSI = (XServiceInfo) UnoRuntime.queryInterface(XServiceInfo.class, oTextField); + if (xSI.supportsService("com.sun.star.text.TextField.DateTime")) { + XPropertySet xPSet = (XPropertySet) UnoRuntime.queryInterface(XPropertySet.class, oTextField); + xPSet.setPropertyValue("IsFixed", new Boolean(_bSetFixed)); + } + } + } catch (Exception e) { + e.printStackTrace(); + }} public void removeUserFieldByContent(String _FieldContent) { try {