diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-03-09 16:20:50 -0600 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-03-09 16:20:50 -0600 |
commit | cc5db648bcc3114fefcbf9741586f7cb6aa00b2f (patch) | |
tree | 518184d1a205c0173f30a54bbee0ffaa0f9bb433 /wizards/com/sun/star/wizards/form | |
parent | 7fc838e84c345c13e1dbd32052e1d9c5985a7859 (diff) | |
parent | 8427b0f498b040a465cc20c4a323191d6b2aea5f (diff) |
Merge commit 'ooo/DEV300_m101' into integration/dev300_m101
* commit 'ooo/DEV300_m101': (185 commits)
masterfix DEV300: #i10000# usage of L10N build_type
masterfix: #i10000# INT16 -> sal_Int16
fixed compile errors after resync to m100, part2
gridsort: post-rebase fixes
CWS gnumake3: found another tools integer type
removetooltypes01: Fix build problems after rebase to DEV300m99 in basctl, cui, reportdesign, sw
native359: #i114398# changing mac langpack icon
native359: #i115669# fixing package description for solaris packages
gnumake3: remove comphelper version; fix including extract.hxx
locales34: #i106785# add Haitian_Haiti [ht-HT] to language list and locale data; locale data contributed by <jcpoulard>
sb138: #i116659# timely termination of OnLogRotateThread
accfixes: removed include of obsolete header file
accfixes: removed obsolete file
removetooltypes01: #i112600# Fix build problems on non-pro
accfixes: moved some shared strings to svx part2
accfixes: moved some shared strings to svx
accfixes: added more accessibility information and fixed tab orders in multiple dialogs (cui module)
removetooltypes01: #i112600# Remove tools types for Mac specific parts
fixed tab order in BasicIDE, Library dialog tab page
added some accessible names in BasicIDE
...
Conflicts:
UnoControls/source/base/registercontrols.cxx
accessibility/inc/accessibility/standard/vclxaccessiblelistboxlist.hxx
automation/inc/automation/communi.hxx
automation/inc/automation/simplecm.hxx
automation/source/communi/communi.cxx
automation/source/inc/rcontrol.hxx
automation/source/miniapp/servuid.hxx
automation/source/server/XMLParser.cxx
automation/source/server/cmdbasestream.cxx
automation/source/server/profiler.hxx
automation/source/server/recorder.cxx
automation/source/server/retstrm.hxx
automation/source/server/server.cxx
automation/source/server/sta_list.cxx
automation/source/server/statemnt.cxx
automation/source/server/statemnt.hxx
automation/source/simplecm/packethandler.cxx
automation/source/simplecm/simplecm.cxx
automation/source/simplecm/tcpio.cxx
automation/source/simplecm/tcpio.hxx
automation/source/testtool/comm_bas.hxx
automation/source/testtool/cretstrm.hxx
automation/source/testtool/httprequest.cxx
automation/source/testtool/httprequest.hxx
automation/source/testtool/objtest.cxx
automation/source/testtool/objtest.hxx
basctl/source/basicide/baside2.cxx
basctl/source/basicide/baside2.hxx
basctl/source/basicide/baside2b.cxx
basctl/source/basicide/baside3.cxx
basctl/source/basicide/basides1.cxx
basctl/source/basicide/basides2.cxx
basctl/source/basicide/basidesh.cxx
basctl/source/basicide/basidesh.src
basctl/source/basicide/basobj3.cxx
basctl/source/basicide/bastype2.cxx
basctl/source/basicide/bastype3.cxx
basctl/source/basicide/bastypes.cxx
basctl/source/basicide/brkdlg.cxx
basctl/source/basicide/iderdll.cxx
basctl/source/basicide/macrodlg.cxx
basctl/source/basicide/moduldl2.cxx
basctl/source/basicide/moduldlg.cxx
basctl/source/basicide/objdlg.cxx
basctl/source/basicide/scriptdocument.cxx
basctl/source/basicide/tbxctl.cxx
basctl/source/basicide/tbxctl.hxx
basctl/source/basicide/tbxctl.src
basctl/source/dlged/dlged.cxx
basctl/source/dlged/dlgedfunc.cxx
basctl/source/dlged/dlgedobj.cxx
basctl/source/inc/basidesh.hxx
basctl/source/inc/bastypes.hxx
basctl/source/inc/dlgedmod.hxx
basctl/source/inc/dlgedpage.hxx
crashrep/prj/build.lst
cui/inc/pch/precompiled_cui.hxx
cui/source/customize/acccfg.cxx
cui/source/customize/acccfg.hrc
cui/source/customize/acccfg.src
cui/source/customize/cfg.cxx
cui/source/customize/cfgutil.cxx
cui/source/customize/macropg.cxx
cui/source/customize/macropg.src
cui/source/customize/selector.cxx
cui/source/dialogs/SpellDialog.cxx
cui/source/dialogs/commonlingui.cxx
cui/source/dialogs/cuicharmap.cxx
cui/source/dialogs/cuifmsearch.cxx
cui/source/dialogs/cuigaldlg.cxx
cui/source/dialogs/cuigrfflt.cxx
cui/source/dialogs/hldocntp.cxx
cui/source/dialogs/hldoctp.cxx
cui/source/dialogs/hlinettp.cxx
cui/source/dialogs/hlmailtp.cxx
cui/source/dialogs/hlmarkwn.cxx
cui/source/dialogs/hlmarkwn.src
cui/source/dialogs/hltpbase.cxx
cui/source/dialogs/iconcdlg.cxx
cui/source/dialogs/passwdomdlg.cxx
cui/source/dialogs/pastedlg.cxx
cui/source/dialogs/scriptdlg.cxx
cui/source/dialogs/thesdlg.cxx
cui/source/dialogs/zoom.cxx
cui/source/factory/dlgfact.hxx
cui/source/inc/SpellDialog.hxx
cui/source/inc/autocdlg.hxx
cui/source/inc/backgrnd.hxx
cui/source/inc/bbdlg.hxx
cui/source/inc/cfg.hxx
cui/source/inc/cfgutil.hxx
cui/source/inc/cuigaldlg.hxx
cui/source/inc/cuigrfflt.hxx
cui/source/inc/cuitabarea.hxx
cui/source/inc/cuitabline.hxx
cui/source/inc/hldocntp.hxx
cui/source/inc/hltpbase.hxx
cui/source/inc/iconcdlg.hxx
cui/source/inc/numpages.hxx
cui/source/inc/page.hxx
cui/source/inc/postdlg.hxx
cui/source/inc/scriptdlg.hxx
cui/source/inc/transfrm.hxx
cui/source/inc/zoom.hxx
cui/source/options/cfgchart.cxx
cui/source/options/cuisrchdlg.cxx
cui/source/options/dbregister.cxx
cui/source/options/dbregister.src
cui/source/options/fontsubs.cxx
cui/source/options/internationaloptions.cxx
cui/source/options/optasian.cxx
cui/source/options/optchart.cxx
cui/source/options/optcolor.cxx
cui/source/options/optcolor.src
cui/source/options/optfltr.cxx
cui/source/options/optfltr.src
cui/source/options/optgdlg.cxx
cui/source/options/optgdlg.src
cui/source/options/optgenrl.cxx
cui/source/options/opthtml.cxx
cui/source/options/optimprove.cxx
cui/source/options/optinet2.cxx
cui/source/options/optinet2.hxx
cui/source/options/optjava.cxx
cui/source/options/optlingu.cxx
cui/source/options/optsave.cxx
cui/source/options/optsave.hxx
cui/source/options/treeopt.cxx
cui/source/options/webconninfo.cxx
cui/source/tabpages/autocdlg.cxx
cui/source/tabpages/backgrnd.cxx
cui/source/tabpages/border.cxx
cui/source/tabpages/chardlg.cxx
cui/source/tabpages/dstribut.cxx
cui/source/tabpages/grfpage.cxx
cui/source/tabpages/macroass.cxx
cui/source/tabpages/measure.cxx
cui/source/tabpages/numfmt.cxx
cui/source/tabpages/numpages.cxx
cui/source/tabpages/page.cxx
cui/source/tabpages/paragrph.cxx
cui/source/tabpages/swpossizetabpage.cxx
cui/source/tabpages/tabarea.src
cui/source/tabpages/textanim.cxx
cui/source/tabpages/textattr.cxx
cui/source/tabpages/tparea.cxx
cui/source/tabpages/tpbitmap.cxx
cui/source/tabpages/tpcolor.cxx
cui/source/tabpages/tpgradnt.cxx
cui/source/tabpages/tphatch.cxx
cui/source/tabpages/tpline.cxx
cui/source/tabpages/tplnedef.cxx
cui/source/tabpages/tplneend.cxx
cui/source/tabpages/tpshadow.cxx
cui/source/tabpages/transfrm.cxx
embedserv/source/embed/register.cxx
extensions/inc/pch/precompiled_extensions.hxx
extensions/inc/propctrlr.hrc
extensions/source/abpilot/abpservices.cxx
extensions/source/bibliography/bibload.cxx
extensions/source/bibliography/datman.cxx
extensions/source/bibliography/general.cxx
extensions/source/dbpilots/dbpservices.cxx
extensions/source/inc/componentmodule.cxx
extensions/source/nsplugin/source/so_env.cxx
extensions/source/ole/oleobjw.cxx
extensions/source/ole/oleobjw.hxx
extensions/source/oooimprovement/invite_job.cxx
extensions/source/oooimprovement/onlogrotate_job.cxx
extensions/source/plugin/base/service.cxx
extensions/source/plugin/inc/plugin/unx/mediator.hxx
extensions/source/plugin/inc/plugin/unx/plugcon.hxx
extensions/source/plugin/unx/mediator.cxx
extensions/source/plugin/unx/nppapi.cxx
extensions/source/plugin/unx/plugcon.cxx
extensions/source/preload/services.cxx
extensions/source/propctrlr/formmetadata.cxx
extensions/source/propctrlr/pcrservices.cxx
extensions/source/resource/resource.cxx
extensions/source/scanner/sane.hxx
extensions/source/scanner/sanedlg.cxx
extensions/source/scanner/scanunx.cxx
extensions/source/scanner/scanwin.cxx
extensions/source/scanner/twain.cxx
extensions/source/scanner/twain.hxx
extensions/source/update/check/updatecheckconfig.cxx
extensions/test/stm/datatest.cxx
extensions/test/stm/marktest.cxx
extensions/test/stm/pipetest.cxx
extensions/test/stm/testfactreg.cxx
extensions/workben/testpgp.cxx
forms/qa/complex/forms/CheckOGroupBoxModel.java
forms/qa/makefile.mk
forms/source/component/Button.cxx
forms/source/component/Button.hxx
forms/source/component/ListBox.cxx
forms/source/inc/forms_module_impl.hxx
forms/source/misc/services.cxx
forms/source/solar/control/navtoolbar.cxx
javainstaller2/prj/build.lst
javainstaller2/src/JavaSetup/org/openoffice/setup/Util/ModuleCtrl.java
lingucomponent/prj/build.lst
lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx
lingucomponent/source/spellcheck/spell/sreg.cxx
lingucomponent/source/spellcheck/spell/sspellimp.cxx
package/source/manifest/ManifestExport.cxx
package/source/manifest/UnoRegister.cxx
package/source/xstor/owriteablestream.cxx
package/source/xstor/owriteablestream.hxx
package/source/xstor/xstorage.hxx
package/source/zippackage/ZipPackageFolder.cxx
package/source/zippackage/ZipPackageStream.cxx
setup_native/source/mac/ooo/DS_Store
setup_native/source/win32/customactions/shellextensions/registerextensions.cxx
xmlsecurity/prj/build.lst
xmlsecurity/source/component/registerservices.cxx
xmlsecurity/source/dialogs/stbcontrl.cxx
xmlsecurity/source/framework/xsec_framework.cxx
xmlsecurity/source/xmlsec/xsec_xmlsec.cxx
xmlsecurity/tools/demo/util.hxx
xmlsecurity/workben/signaturetest.cxx
Diffstat (limited to 'wizards/com/sun/star/wizards/form')
12 files changed, 170 insertions, 131 deletions
diff --git a/wizards/com/sun/star/wizards/form/CallFormWizard.java b/wizards/com/sun/star/wizards/form/CallFormWizard.java index 9a8e73951c69..0538eb5fa1b3 100644 --- a/wizards/com/sun/star/wizards/form/CallFormWizard.java +++ b/wizards/com/sun/star/wizards/form/CallFormWizard.java @@ -31,9 +31,7 @@ import com.sun.star.uno.Type; import com.sun.star.wizards.common.Properties; /** This class capsulates the class, that implements the minimal component, a - * factory for creating the service (<CODE>__getServiceFactory</CODE>) and a - * method, that writes the information into the given registry key - * (<CODE>__writeRegistryServiceInfo</CODE>). + * factory for creating the service (<CODE>__getServiceFactory</CODE>). * @author Bertram Nolte */ public class CallFormWizard @@ -62,19 +60,6 @@ public class CallFormWizard return xsingleservicefactory; } - /** Writes the service information into the given registry key. - * This method is called by the <code>JavaLoader</code>. - * @return returns true if the operation succeeded - * @see com.sun.star.comp.loader.JavaLoader# - * @param xregistrykey Makes structural information (except regarding tree - * structures) of a single - * registry key accessible. - */ - public static boolean __writeRegistryServiceInfo(com.sun.star.registry.XRegistryKey xregistrykey) - { - return com.sun.star.comp.loader.FactoryHelper.writeRegistryServiceInfo(FormWizardImplementation.class.getName(), FormWizardImplementation.__serviceName, xregistrykey); - } - /** This class implements the component. At least the interfaces XServiceInfo, * XTypeProvider, and XInitialization should be provided by the service. */ diff --git a/wizards/com/sun/star/wizards/form/DataEntrySetter.java b/wizards/com/sun/star/wizards/form/DataEntrySetter.java index 2844e0b53104..ae042fa7de76 100644 --- a/wizards/com/sun/star/wizards/form/DataEntrySetter.java +++ b/wizards/com/sun/star/wizards/form/DataEntrySetter.java @@ -34,6 +34,7 @@ import com.sun.star.wizards.common.Properties; import com.sun.star.wizards.ui.UnoDialog; import com.sun.star.wizards.ui.WizardDialog; import com.sun.star.wizards.ui.UIConsts; +import com.sun.star.wizards.common.PropertyNames; public class DataEntrySetter { @@ -61,53 +62,53 @@ public class DataEntrySetter optNewDataOnly = CurUnoDialog.insertRadioButton("optNewDataOnly", "toggleCheckBoxes", this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34461", sNewDataOnly, new Integer(98), new Integer(25), IDataStep, new Short(curtabindex++), new Integer(195) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTNEWDATAONLY", sNewDataOnly, new Integer(98), new Integer(25), IDataStep, new Short(curtabindex++), new Integer(195) }); optDisplayAllData = CurUnoDialog.insertRadioButton("optDisplayAllData", "toggleCheckBoxes", this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34462", sDisplayAllData, new Integer(98), new Integer(50), new Short((short) 1), IDataStep, new Short(curtabindex++), new Integer(197) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTDISPLAYALLDATA", sDisplayAllData, new Integer(98), new Integer(50), new Short((short) 1), IDataStep, new Short(curtabindex++), new Integer(197) }); chknomodification = CurUnoDialog.insertCheckBox("chknomodification", null, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34463", sNoModification, new Integer(108), new Integer(62), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(189) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_CHKNOMODIFICATION", sNoModification, new Integer(108), new Integer(62), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(189) }); chknodeletion = CurUnoDialog.insertCheckBox("chknodeletion", null, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34464", sNoDeletion, new Integer(108), new Integer(74), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(189) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_CHKNODELETION", sNoDeletion, new Integer(108), new Integer(74), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(189) }); chknoaddition = CurUnoDialog.insertCheckBox("chknoaddition", null, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34465", sNoAddition, new Integer(108), new Integer(86), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(191) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_CHKNOADDITION", sNoAddition, new Integer(108), new Integer(86), new Short((short) 0), IDataStep, new Short(curtabindex++), new Integer(191) }); CurUnoDialog.insertLabel("lbldontdisplayExistingData", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -121,9 +122,9 @@ public class DataEntrySetter if (optDisplayAllData.getState()) { retProperties = new PropertyValue[3]; - boolean bAllowUpdates = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknomodification), "State")).shortValue()) != 1; - boolean bAllowDeletes = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknodeletion), "State")).shortValue()) != 1; - boolean bAllowInserts = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknoaddition), "State")).shortValue()) != 1; + boolean bAllowUpdates = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknomodification), PropertyNames.PROPERTY_STATE)).shortValue()) != 1; + boolean bAllowDeletes = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknodeletion), PropertyNames.PROPERTY_STATE)).shortValue()) != 1; + boolean bAllowInserts = (((Short) Helper.getUnoPropertyValue(UnoDialog.getModel(chknoaddition), PropertyNames.PROPERTY_STATE)).shortValue()) != 1; retProperties[0] = Properties.createProperty("AllowUpdates", new Boolean(bAllowUpdates)); retProperties[1] = Properties.createProperty("AllowDeletes", new Boolean(bAllowDeletes)); retProperties[2] = Properties.createProperty("AllowInserts", new Boolean(bAllowInserts)); @@ -140,8 +141,8 @@ public class DataEntrySetter public void toggleCheckBoxes() { boolean bdisplayalldata = optDisplayAllData.getState(); - Helper.setUnoPropertyValue(UnoDialog.getModel(chknomodification), "Enabled", new Boolean(bdisplayalldata)); - Helper.setUnoPropertyValue(UnoDialog.getModel(chknodeletion), "Enabled", new Boolean(bdisplayalldata)); - Helper.setUnoPropertyValue(UnoDialog.getModel(chknoaddition), "Enabled", new Boolean(bdisplayalldata)); + Helper.setUnoPropertyValue(UnoDialog.getModel(chknomodification), PropertyNames.PROPERTY_ENABLED, new Boolean(bdisplayalldata)); + Helper.setUnoPropertyValue(UnoDialog.getModel(chknodeletion), PropertyNames.PROPERTY_ENABLED, new Boolean(bdisplayalldata)); + Helper.setUnoPropertyValue(UnoDialog.getModel(chknoaddition), PropertyNames.PROPERTY_ENABLED, new Boolean(bdisplayalldata)); } } diff --git a/wizards/com/sun/star/wizards/form/FieldLinker.java b/wizards/com/sun/star/wizards/form/FieldLinker.java index f5555421a4b3..b0fecf192bb8 100644 --- a/wizards/com/sun/star/wizards/form/FieldLinker.java +++ b/wizards/com/sun/star/wizards/form/FieldLinker.java @@ -32,12 +32,14 @@ import com.sun.star.awt.XFixedText; import com.sun.star.awt.XListBox; import com.sun.star.uno.Exception; import com.sun.star.wizards.common.Helper; +import com.sun.star.wizards.common.HelpIds; import com.sun.star.wizards.common.JavaTools; import com.sun.star.wizards.db.RelationController; import com.sun.star.wizards.ui.UnoDialog; import com.sun.star.wizards.ui.WizardDialog; import com.sun.star.wizards.ui.UIConsts; import com.sun.star.wizards.ui.DBLimitedFieldSelection; +import com.sun.star.wizards.common.PropertyNames; public class FieldLinker extends DBLimitedFieldSelection { @@ -86,13 +88,13 @@ public class FieldLinker extends DBLimitedFieldSelection SOFIRSTLINKLST, SOSECLINKLST, SOTHIRDLINKLST, SOFOURTHLINKLST }; } - sSlaveHidString = "HID:" + Integer.toString(FirstHelpIndex + (i * 2)); - sMasterHidString = "HID:" + Integer.toString(FirstHelpIndex + (i * 2) + 1); + sSlaveHidString = HelpIds.getHelpIdString(FirstHelpIndex + (i * 2)); + sMasterHidString = HelpIds.getHelpIdString(FirstHelpIndex + (i * 2) + 1); boolean bDoEnable = (i < 2); lblSlaveFields[i] = CurUnoDialog.insertLabel("lblSlaveFieldLink" + new Integer(i + 1).toString(), new String[] { - "Enabled", "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -102,15 +104,15 @@ public class FieldLinker extends DBLimitedFieldSelection new String[] { "Dropdown", - "Enabled", - "Height", - "HelpURL", + PropertyNames.PROPERTY_ENABLED, + PropertyNames.PROPERTY_HEIGHT, + PropertyNames.PROPERTY_HELPURL, "LineCount", - "PositionX", - "PositionY", - "Step", - "TabIndex", - "Width" + PropertyNames.PROPERTY_POSITION_X, + PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_STEP, + PropertyNames.PROPERTY_TABINDEX, + PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -129,7 +131,7 @@ public class FieldLinker extends DBLimitedFieldSelection lblMasterFields[i] = CurUnoDialog.insertLabel("lblMasterFieldLink" + new Integer(i + 1).toString(), new String[] { - "Enabled", "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -140,15 +142,15 @@ public class FieldLinker extends DBLimitedFieldSelection new String[] { "Dropdown", - "Enabled", - "Height", - "HelpURL", + PropertyNames.PROPERTY_ENABLED, + PropertyNames.PROPERTY_HEIGHT, + PropertyNames.PROPERTY_HELPURL, "LineCount", - "PositionX", - "PositionY", - "Step", - "TabIndex", - "Width" + PropertyNames.PROPERTY_POSITION_X, + PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_STEP, + PropertyNames.PROPERTY_TABINDEX, + PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -204,10 +206,10 @@ public class FieldLinker extends DBLimitedFieldSelection { if (i < rowcount) { - Helper.setUnoPropertyValue(UnoDialog.getModel(lblSlaveFields[i]), "Enabled", new Boolean(bDoEnable)); - Helper.setUnoPropertyValue(UnoDialog.getModel(lstSlaveFields[i]), "Enabled", new Boolean(bDoEnable)); - Helper.setUnoPropertyValue(UnoDialog.getModel(lblMasterFields[i]), "Enabled", new Boolean(bDoEnable)); - Helper.setUnoPropertyValue(UnoDialog.getModel(lstMasterFields[i]), "Enabled", new Boolean(bDoEnable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lblSlaveFields[i]), PropertyNames.PROPERTY_ENABLED, new Boolean(bDoEnable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lstSlaveFields[i]), PropertyNames.PROPERTY_ENABLED, new Boolean(bDoEnable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lblMasterFields[i]), PropertyNames.PROPERTY_ENABLED, new Boolean(bDoEnable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lstMasterFields[i]), PropertyNames.PROPERTY_ENABLED, new Boolean(bDoEnable)); if (bDoEnable == false) { Helper.setUnoPropertyValue(UnoDialog.getModel(lstSlaveFields[i]), "SelectedItems", new short[] { 0 }); diff --git a/wizards/com/sun/star/wizards/form/Finalizer.java b/wizards/com/sun/star/wizards/form/Finalizer.java index fa1f9ce56074..c5f12728e527 100644 --- a/wizards/com/sun/star/wizards/form/Finalizer.java +++ b/wizards/com/sun/star/wizards/form/Finalizer.java @@ -29,6 +29,7 @@ package com.sun.star.wizards.form; import com.sun.star.awt.XRadioButton; import com.sun.star.awt.XTextComponent; import com.sun.star.wizards.common.Desktop; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.ui.*; /** @@ -59,7 +60,7 @@ public class Finalizer CurUnoDialog.insertLabel("lblFormName", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -68,16 +69,16 @@ public class Finalizer txtFormName = CurUnoDialog.insertTextField("txtFormName", "toggleFinishButton", this, new String[] { - "Height", "HelpURL", "PositionX", "PositionY", "Step", "TabIndex", "Text", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, "Text", PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGER_12, "HID:34481", new Integer(97), new Integer(35), UIConsts.INTEGERS[8], new Short((short) 82), "", new Integer(185) + UIConsts.INTEGER_12, "HID:WIZARDS_HID_DLGFORM_TXTPATH", new Integer(97), new Integer(35), UIConsts.INTEGERS[8], new Short((short) 82), "", new Integer(185) }); CurUnoDialog.insertLabel("lblProceed", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -86,20 +87,20 @@ public class Finalizer CurUnoDialog.insertRadioButton("optWorkWithForm", null, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34482", sWorkWithForm, new Integer(101), new Integer(77), new Short((short) 1), UIConsts.INTEGERS[8], new Short(curtabindex++), new Integer(107) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTWORKWITHFORM", sWorkWithForm, new Integer(101), new Integer(77), new Short((short) 1), UIConsts.INTEGERS[8], new Short(curtabindex++), new Integer(107) }); optModifyForm = CurUnoDialog.insertRadioButton("optModifyForm", null, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34483", sModifyForm, new Integer(101), new Integer(89), UIConsts.INTEGERS[8], new Short(curtabindex++), new Integer(107) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTMODIFYFORM", sModifyForm, new Integer(101), new Integer(89), UIConsts.INTEGERS[8], new Short(curtabindex++), new Integer(107) }); } diff --git a/wizards/com/sun/star/wizards/form/FormConfiguration.java b/wizards/com/sun/star/wizards/form/FormConfiguration.java index 8e2c36ae0966..9c18ab47d79d 100644 --- a/wizards/com/sun/star/wizards/form/FormConfiguration.java +++ b/wizards/com/sun/star/wizards/form/FormConfiguration.java @@ -31,6 +31,7 @@ import com.sun.star.awt.XFixedText; import com.sun.star.awt.XListBox; import com.sun.star.awt.XRadioButton; import com.sun.star.wizards.common.Helper; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.ui.CommandFieldSelection; import com.sun.star.wizards.ui.UIConsts; import com.sun.star.wizards.ui.UnoDialog; @@ -78,34 +79,34 @@ public class FormConfiguration chkcreateSubForm = CurUnoDialog.insertCheckBox("chkcreateSubForm", SSUBFORMMODE, this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[8], "HID:34421", sSelectManually, new Integer(97), new Integer(26), ISubFormStep, new Short(curtabindex++), new Integer(160) + UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_CHKCREATESUBFORM", sSelectManually, new Integer(97), new Integer(26), ISubFormStep, new Short(curtabindex++), new Integer(160) }); optOnExistingRelation = CurUnoDialog.insertRadioButton("optOnExistingRelation", STOGGLESTEPS, this, new String[] { - "Enabled", "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - Boolean.FALSE, UIConsts.INTEGERS[8], "HID:34422", sOnExistingRelation, new Integer(107), new Integer(43), ISubFormStep, new Short(curtabindex++), new Integer(160) + Boolean.FALSE, UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTONEXISTINGRELATION", sOnExistingRelation, new Integer(107), new Integer(43), ISubFormStep, new Short(curtabindex++), new Integer(160) }); optSelectManually = CurUnoDialog.insertRadioButton("optSelectManually", STOGGLESTEPS, this, new String[] { - "Enabled", "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - Boolean.FALSE, UIConsts.INTEGERS[8], "HID:34423", sOnManualRelation, new Integer(107), new Integer(99), new Short((short) 1), ISubFormStep, new Short(curtabindex++), new Integer(160) + Boolean.FALSE, UIConsts.INTEGERS[8], "HID:WIZARDS_HID_DLGFORM_OPTSELECTMANUALLY", sOnManualRelation, new Integer(107), new Integer(99), new Short((short) 1), ISubFormStep, new Short(curtabindex++), new Integer(160) }); lblRelations = CurUnoDialog.insertLabel("lblSelectRelation", new String[] { - "Enabled", "Height", "Label", "MultiLine", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -114,16 +115,16 @@ public class FormConfiguration lstRelations = CurUnoDialog.insertListBox("lstrelations", SONEXISTINGRELATIONSELECTION, SONEXISTINGRELATIONSELECTION, this, new String[] { - "Enabled", "Height", "HelpURL", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_ENABLED, PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - Boolean.FALSE, new Integer(37), "HID:34424", new Integer(201), new Integer(55), ISubFormStep, new Short(curtabindex++), new Integer(103) + Boolean.FALSE, new Integer(37), "HID:WIZARDS_HID_DLGFORM_lstRELATIONS", new Integer(201), new Integer(55), ISubFormStep, new Short(curtabindex++), new Integer(103) }); lblSubFormDescription = CurUnoDialog.insertLabel("lblSubFormDescription", new String[] { - "Height", "Label", "MultiLine", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -134,7 +135,7 @@ public class FormConfiguration // public void disableSubFormCheckBox() // { - // Helper.setUnoPropertyValue(UnoDialog.getModel(chkcreateSubForm), "Enabled", Boolean.FALSE); + // Helper.setUnoPropertyValue(UnoDialog.getModel(chkcreateSubForm), PropertyNames.PROPERTY_ENABLED, Boolean.FALSE); // } public RelationController getRelationController() @@ -150,8 +151,8 @@ public class FormConfiguration public void toggleSubFormMode() { boolean bdoEnable = (this.chkcreateSubForm.getState() == 1); - Helper.setUnoPropertyValue(UnoDialog.getModel(optOnExistingRelation), "Enabled", new Boolean(bdoEnable && bsupportsRelations)); - Helper.setUnoPropertyValue(UnoDialog.getModel(optSelectManually), "Enabled", new Boolean(bdoEnable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(optOnExistingRelation), PropertyNames.PROPERTY_ENABLED, new Boolean(bdoEnable && bsupportsRelations)); + Helper.setUnoPropertyValue(UnoDialog.getModel(optSelectManually), PropertyNames.PROPERTY_ENABLED, new Boolean(bdoEnable)); toggleSteps(); } @@ -163,7 +164,7 @@ public class FormConfiguration Helper.setUnoPropertyValue(UnoDialog.getModel(lstRelations), "StringItemList", sreferencedTables); this.CurSubFormFieldSelection = _CurSubFormFieldSelection; toggleRelationsListbox(); - Helper.setUnoPropertyValue(UnoDialog.getModel(optOnExistingRelation), "Enabled", new Boolean(bsupportsRelations && (chkcreateSubForm.getState() == 1))); + Helper.setUnoPropertyValue(UnoDialog.getModel(optOnExistingRelation), PropertyNames.PROPERTY_ENABLED, new Boolean(bsupportsRelations && (chkcreateSubForm.getState() == 1))); } public void toggleSteps() @@ -230,8 +231,8 @@ public class FormConfiguration private void toggleRelationsListbox() { boolean bdoenable = bsupportsRelations && this.optOnExistingRelation.getState() && (chkcreateSubForm.getState() == 1); - Helper.setUnoPropertyValue(UnoDialog.getModel(lblRelations), "Enabled", new Boolean(bdoenable)); - Helper.setUnoPropertyValue(UnoDialog.getModel(lstRelations), "Enabled", new Boolean(bdoenable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lblRelations), PropertyNames.PROPERTY_ENABLED, new Boolean(bdoenable)); + Helper.setUnoPropertyValue(UnoDialog.getModel(lstRelations), PropertyNames.PROPERTY_ENABLED, new Boolean(bdoenable)); } public boolean hasSubForm() diff --git a/wizards/com/sun/star/wizards/form/FormControlArranger.java b/wizards/com/sun/star/wizards/form/FormControlArranger.java index 9a0c58fd41b8..f5478525eab1 100644 --- a/wizards/com/sun/star/wizards/form/FormControlArranger.java +++ b/wizards/com/sun/star/wizards/form/FormControlArranger.java @@ -36,6 +36,7 @@ import com.sun.star.uno.AnyConverter; import com.sun.star.uno.Exception; import com.sun.star.wizards.common.Helper; import com.sun.star.wizards.common.Resource; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.db.*; import com.sun.star.wizards.document.Control; import com.sun.star.wizards.document.DatabaseControl; @@ -643,7 +644,7 @@ public class FormControlArranger if (DBControlList[i].getControlType() == FormHandler.SOCHECKBOX) { // Checkboxes have no Label near by - DBControlList[i].setPropertyValue("Label", ""); + DBControlList[i].setPropertyValue(PropertyNames.PROPERTY_LABEL, ""); } } } @@ -662,7 +663,7 @@ public class FormControlArranger } if (nFieldType == DataType.LONGVARCHAR) /* memo */ { - Helper.setUnoPropertyValue(LabelControlList[i], "MultiLine", Boolean.TRUE); + Helper.setUnoPropertyValue(LabelControlList[i], PropertyNames.PROPERTY_MULTILINE, Boolean.TRUE); } checkOuterPoints(nXDBPos, nDBWidth, nYDBPos, nDBHeight, true); aDBControl.setPropertyValue("Border", NBorderType); diff --git a/wizards/com/sun/star/wizards/form/FormDocument.java b/wizards/com/sun/star/wizards/form/FormDocument.java index ae1a795368e4..0070fed3ada1 100644 --- a/wizards/com/sun/star/wizards/form/FormDocument.java +++ b/wizards/com/sun/star/wizards/form/FormDocument.java @@ -297,7 +297,9 @@ public class FormDocument extends TextDocument public ControlForm[] getControlForms() { - return (ControlForm[]) oControlForms.toArray(); + ControlForm[] aResult = new ControlForm[oControlForms.size()]; + oControlForms.toArray( aResult ); + return aResult; } public boolean finalizeForms(DataEntrySetter _curDataEntrySetter, FieldLinker _curFieldLinker, FormConfiguration _curFormConfiguration) diff --git a/wizards/com/sun/star/wizards/form/FormWizard.java b/wizards/com/sun/star/wizards/form/FormWizard.java index eb25fb65c78d..f75f3e1b84ab 100644 --- a/wizards/com/sun/star/wizards/form/FormWizard.java +++ b/wizards/com/sun/star/wizards/form/FormWizard.java @@ -32,6 +32,7 @@ import com.sun.star.lang.XMultiServiceFactory; import com.sun.star.lang.XComponent; import com.sun.star.sdb.application.DatabaseObject; import com.sun.star.wizards.common.Helper; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.common.JavaTools; import com.sun.star.wizards.common.NoValidPathException; import com.sun.star.wizards.common.Properties; @@ -81,7 +82,7 @@ public class FormWizard extends DatabaseObjectWizard Helper.setUnoPropertyValues(xDialogModel, new String[] { - "Height", "Moveable", "Name", "PositionX", "PositionY", "Step", "TabIndex", "Title", "Width" + PropertyNames.PROPERTY_HEIGHT, "Moveable", PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, "Title", PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -230,7 +231,7 @@ public class FormWizard extends DatabaseObjectWizard insertLabel("lblBinaryHelpText", new String[] { - "Height", "Label", "MultiLine", "PositionX", "PositionY", "Step", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -245,7 +246,7 @@ public class FormWizard extends DatabaseObjectWizard insertLabel("lblSubFormBinaryHelpText", new String[] { - "Height", "Label", "MultiLine", "PositionX", "PositionY", "Step", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -457,7 +458,7 @@ public class FormWizard extends DatabaseObjectWizard curDBCommandFieldSelection.setModified(true); boolean benable = curDBCommandFieldSelection.getSelectedFieldNames().length > 0; enablefromStep(SOSUBFORM_PAGE, benable); - setControlProperty("btnWizardNext", "Enabled", new Boolean(benable)); + setControlProperty("btnWizardNext", PropertyNames.PROPERTY_ENABLED, new Boolean(benable)); if (benable) { if (curFormConfiguration.hasSubForm()) @@ -470,7 +471,7 @@ public class FormWizard extends DatabaseObjectWizard setStepEnabled(SOFIELDLINKER_PAGE, false); } } - setControlProperty("btnWizardFinish", "Enabled", new Boolean(benable)); + setControlProperty("btnWizardFinish", PropertyNames.PROPERTY_ENABLED, new Boolean(benable)); } } } diff --git a/wizards/com/sun/star/wizards/form/StyleApplier.java b/wizards/com/sun/star/wizards/form/StyleApplier.java index 79e0321a3c0b..5098a1ffbb74 100644 --- a/wizards/com/sun/star/wizards/form/StyleApplier.java +++ b/wizards/com/sun/star/wizards/form/StyleApplier.java @@ -43,6 +43,7 @@ import com.sun.star.wizards.common.FileAccess; import com.sun.star.wizards.common.Helper; import com.sun.star.wizards.common.JavaTools; import com.sun.star.wizards.common.NoValidPathException; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.document.Control; import com.sun.star.wizards.document.DatabaseControl; import com.sun.star.wizards.document.GridControl; @@ -111,7 +112,7 @@ public class StyleApplier CurUnoDialog.insertLabel("lblStyles", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -121,47 +122,47 @@ public class StyleApplier lstStyles = CurUnoDialog.insertListBox("lstStyles", null, SCHANGELAYOUT, this, new String[] { - "Height", "HelpURL", "PositionX", "PositionY", "SelectedItems", "Step", "StringItemList", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, "SelectedItems", PropertyNames.PROPERTY_STEP, "StringItemList", PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - new Integer(143), "HID:34471", new Integer(92), new Integer(35), SelLayoutPos, IStyleStep, this.StyleNames, new Short(curtabindex++), new Integer(90) + new Integer(143), "HID:WIZARDS_HID_DLGFORM_LSTSTYLES", new Integer(92), new Integer(35), SelLayoutPos, IStyleStep, this.StyleNames, new Short(curtabindex++), new Integer(90) }); optNoBorder = CurUnoDialog.insertRadioButton("otpNoBorder", SCHANGEBORDERTYPE, this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Tag", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, "Tag", PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[10], "HID:34472", sNoBorder, new Integer(196), new Integer(39), IStyleStep, new Short(curtabindex++), "0", new Integer(93) + UIConsts.INTEGERS[10], "HID:WIZARDS_HID_DLGFORM_CMDNOBORDER", sNoBorder, new Integer(196), new Integer(39), IStyleStep, new Short(curtabindex++), "0", new Integer(93) }); opt3DLook = CurUnoDialog.insertRadioButton("otp3DLook", SCHANGEBORDERTYPE, this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Tag", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, "Tag", PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[10], "HID:34473", s3DLook, new Integer(196), new Integer(53), new Short((short) 1), IStyleStep, new Short(curtabindex++), "1", new Integer(93) + UIConsts.INTEGERS[10], "HID:WIZARDS_HID_DLGFORM_CMD3DBORDER", s3DLook, new Integer(196), new Integer(53), new Short((short) 1), IStyleStep, new Short(curtabindex++), "1", new Integer(93) }); optFlat = CurUnoDialog.insertRadioButton("otpFlat", SCHANGEBORDERTYPE, this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Tag", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, "Tag", PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[10], "HID:34474", sFlat, new Integer(196), new Integer(67), IStyleStep, new Short(curtabindex++), "2", new Integer(93) + UIConsts.INTEGERS[10], "HID:WIZARDS_HID_DLGFORM_CMDSIMPLEBORDER", sFlat, new Integer(196), new Integer(67), IStyleStep, new Short(curtabindex++), "2", new Integer(93) }); CurUnoDialog.insertFixedLine("lnFieldBorder", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -193,7 +194,7 @@ public class StyleApplier for (int i = 0; i < StyleNodeNames.length; i++) { Object oStyleNode = xNameAccess.getByName(StyleNodeNames[i]); - StyleNames[i] = (String) Helper.getUnoPropertyValue(oStyleNode, "Name"); + StyleNames[i] = (String) Helper.getUnoPropertyValue(oStyleNode, PropertyNames.PROPERTY_NAME); FileNames[i] = (String) Helper.getUnoPropertyValue(oStyleNode, "CssHref"); } } @@ -341,7 +342,7 @@ public class StyleApplier { String[] sPropList = JavaTools.ArrayoutofString(scurline, ":"); String sPropValue = sPropList[1]; - sPropValue.trim(); + sPropValue = sPropValue.trim(); if (sPropValue.indexOf("#") > 0) { sPropValue = JavaTools.replaceSubString(sPropValue, "", ";"); diff --git a/wizards/com/sun/star/wizards/form/UIControlArranger.java b/wizards/com/sun/star/wizards/form/UIControlArranger.java index b596efe143ea..d4cd1ccc7cb6 100644 --- a/wizards/com/sun/star/wizards/form/UIControlArranger.java +++ b/wizards/com/sun/star/wizards/form/UIControlArranger.java @@ -34,6 +34,7 @@ import com.sun.star.awt.XItemListener; import com.sun.star.awt.XRadioButton; import com.sun.star.lang.EventObject; import com.sun.star.wizards.common.Helper; +import com.sun.star.wizards.common.PropertyNames; import com.sun.star.wizards.common.NoValidPathException; import com.sun.star.wizards.document.Control; // import com.sun.star.wizards.ui.ImageList; @@ -78,7 +79,7 @@ public class UIControlArranger flnLabelPlacement = CurUnoDialog.insertFixedLine("lnLabelPlacement", new String[] { - "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -88,21 +89,21 @@ public class UIControlArranger optAlignLeft = CurUnoDialog.insertRadioButton("optAlignLeft", SOALIGNMETHOD, this, new String[] { - "Height", "HelpURL", "Label", "PositionX", "PositionY", "State", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[10], "HID:34451", sAlignLeft, new Integer(107), new Integer(38), new Short((short) 1), IControlStep, new Short(curtabindex++), new Integer(171) + UIConsts.INTEGERS[10], "HID:WIZARDS_HID_DLGFORM_CMDALIGNLEFT", sAlignLeft, new Integer(107), new Integer(38), new Short((short) 1), IControlStep, new Short(curtabindex++), new Integer(171) }); // Radio Button "Align Right" optAlignRight = CurUnoDialog.insertRadioButton("optAlignRight", SOALIGNMETHOD, this, new String[] { - "Height", "HelpURL", "Label", "MultiLine", "PositionX", "PositionY", "Step", "TabIndex", "Width" + PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH }, new Object[] { - UIConsts.INTEGERS[10], "HID:34452", sAlignRight, Boolean.TRUE, new Integer(107), new Integer(50), IControlStep, new Short(curtabindex++), new Integer(171) + UIConsts.INTEGERS[10], "HID:WIZARDS_HID_DLGFORM_CMDALIGNRIGHT", sAlignRight, Boolean.TRUE, new Integer(107), new Integer(50), IControlStep, new Short(curtabindex++), new Integer(171) }); @@ -114,7 +115,7 @@ public class UIControlArranger // flnLabelPlacement = CurUnoDialog.insertFixedLine("lnArrangementHeader1", // new String[] // { -// "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" +// PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH // }, // new Object[] // { @@ -128,21 +129,21 @@ public class UIControlArranger // CurUnoDialog.insertButton("btnLayout1", "btnLayout1", // new String[] // { -// "Enabled", -// "Height", -// "HelpURL", -// "Label", -// "PositionX", -// "PositionY", -// "Step", -// "TabIndex", -// "Width" +// PropertyNames.PROPERTY_ENABLED, +// PropertyNames.PROPERTY_HEIGHT, +// PropertyNames.PROPERTY_HELPURL, +// PropertyNames.PROPERTY_LABEL, +// PropertyNames.PROPERTY_POSITION_X, +// PropertyNames.PROPERTY_POSITION_Y, +// PropertyNames.PROPERTY_STEP, +// PropertyNames.PROPERTY_TABINDEX, +// PropertyNames.PROPERTY_WIDTH // }, // new Object[] // { // Boolean.valueOf(bEnabled), // new Integer(14), -///* TODO: WRONG!*/ "HID:34452", +///* TODO: WRONG!*/ "HID:WIZARDS_HID_DLGFORM_CMDALIGNRIGHT", // "1", // new Integer(nXPos + nBtnWidth), // new Integer(nYPos), @@ -200,7 +201,7 @@ public class UIControlArranger public void enableSubFormImageList(boolean _bdoEnable) { m_aArrangeList[1].m_aButtonList.setenabled(_bdoEnable); - CurUnoDialog.setControlProperty("lnLabelPlacment_2", "Enabled", new Boolean(_bdoEnable)); + CurUnoDialog.setControlProperty("lnLabelPlacment_2", PropertyNames.PROPERTY_ENABLED, new Boolean(_bdoEnable)); } public short getAlignValue() @@ -243,9 +244,9 @@ public class UIControlArranger private void enableAlignControlGroup(boolean _bEnableAlignControlGroup) { - Helper.setUnoPropertyValue(UnoDialog.getModel(flnLabelPlacement), "Enabled", new Boolean(_bEnableAlignControlGroup)); - Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), "Enabled", new Boolean(_bEnableAlignControlGroup)); - Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignRight), "Enabled", new Boolean(_bEnableAlignControlGroup)); + Helper.setUnoPropertyValue(UnoDialog.getModel(flnLabelPlacement), PropertyNames.PROPERTY_ENABLED, new Boolean(_bEnableAlignControlGroup)); + Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), PropertyNames.PROPERTY_ENABLED, new Boolean(_bEnableAlignControlGroup)); + Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignRight), PropertyNames.PROPERTY_ENABLED, new Boolean(_bEnableAlignControlGroup)); } // private class ArrangeImageList implements XItemListener @@ -262,7 +263,7 @@ public class UIControlArranger // CurUnoDialog.insertFixedLine("lnLabelPlacment_" + (_formindex + 1), // new String[] // { -// "Height", "Label", "PositionX", "PositionY", "Step", "TabIndex", "Width" +// PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_POSITION_X, PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH // }, // new Object[] // { @@ -293,7 +294,7 @@ public class UIControlArranger // // public void setToLeftAlign() // { -// Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), "State", new Short((short) 1)); +// Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), PropertyNames.PROPERTY_STATE, new Short((short) 1)); // } // // /* (non-Javadoc) @@ -383,13 +384,13 @@ public class UIControlArranger CurUnoDialog.insertFixedLine("lnLabelPlacment_" + (_formindex + 1), new String[] { - "Height", - "Label", - "PositionX", - "PositionY", - "Step", - "TabIndex", - "Width" + PropertyNames.PROPERTY_HEIGHT, + PropertyNames.PROPERTY_LABEL, + PropertyNames.PROPERTY_POSITION_X, + PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_STEP, + PropertyNames.PROPERTY_TABINDEX, + PropertyNames.PROPERTY_WIDTH }, new Object[] { @@ -426,7 +427,7 @@ public class UIControlArranger public void setToLeftAlign() { - Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), "State", new Short((short) 1)); + Helper.setUnoPropertyValue(UnoDialog.getModel(optAlignLeft), PropertyNames.PROPERTY_STATE, new Short((short) 1)); } /* (non-Javadoc) diff --git a/wizards/com/sun/star/wizards/form/form.component b/wizards/com/sun/star/wizards/form/form.component new file mode 100644 index 000000000000..3f010d8bc88f --- /dev/null +++ b/wizards/com/sun/star/wizards/form/form.component @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--********************************************************************** +* +* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +* +* Copyright 2000, 2010 Oracle and/or its affiliates. +* +* OpenOffice.org - a multi-platform office productivity suite +* +* This file is part of OpenOffice.org. +* +* OpenOffice.org is free software: you can redistribute it and/or modify +* it under the terms of the GNU Lesser General Public License version 3 +* only, as published by the Free Software Foundation. +* +* OpenOffice.org is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Lesser General Public License version 3 for more details +* (a copy is included in the LICENSE file that accompanied this code). +* +* You should have received a copy of the GNU Lesser General Public License +* version 3 along with OpenOffice.org. If not, see +* <http://www.openoffice.org/license.html> +* for a copy of the LGPLv3 License. +* +**********************************************************************--> + +<component loader="com.sun.star.loader.Java2" + xmlns="http://openoffice.org/2010/uno-components"> + <implementation + name="com.sun.star.wizards.form.CallFormWizard$FormWizardImplementation"> + <service name="com.sun.star.wizards.form.CallFormWizard"/> + </implementation> +</component> diff --git a/wizards/com/sun/star/wizards/form/makefile.mk b/wizards/com/sun/star/wizards/form/makefile.mk index 0a229c96ce5e..abd66032dda2 100644 --- a/wizards/com/sun/star/wizards/form/makefile.mk +++ b/wizards/com/sun/star/wizards/form/makefile.mk @@ -60,3 +60,11 @@ JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) # --- Targets ------------------------------------------------------ .INCLUDE : target.mk + +ALLTAR : $(MISC)/form.component + +$(MISC)/form.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ + form.component + $(XSLTPROC) --nonet --stringparam uri \ + '$(COMPONENTPREFIX_BASIS_JAVA)$(JARTARGET)' -o $@ \ + $(SOLARENV)/bin/createcomponent.xslt form.component |