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 /cui | |
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 'cui')
293 files changed, 9014 insertions, 7895 deletions
diff --git a/cui/inc/pch/precompiled_cui.hxx b/cui/inc/pch/precompiled_cui.hxx new file mode 100644 index 000000000000..d1e46125d965 --- /dev/null +++ b/cui/inc/pch/precompiled_cui.hxx @@ -0,0 +1,962 @@ +/************************************************************************* + * + * 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. + * + ************************************************************************/ + +// MARKER(update_precomp.py): Generated on 2006-09-01 17:50:08.279739 +#if 0 +#ifdef PRECOMPILED_HEADERS +//---MARKER--- +#include "sal/config.h" +#include "avmedia/mediaitem.hxx" +#include "avmedia/mediawindow.hxx" +#include "basegfx/matrix/b2dhommatrix.hxx" +#include "basegfx/numeric/ftools.hxx" +#include "basegfx/point/b2dpoint.hxx" +#include "basegfx/point/b3dpoint.hxx" +#include "basegfx/polygon/b2dlinegeometry.hxx" +#include "basegfx/polygon/b2dpolygon.hxx" +#include "basegfx/polygon/b2dpolygontools.hxx" +#include "basegfx/polygon/b2dpolypolygon.hxx" +#include "basegfx/polygon/b2dpolypolygontools.hxx" +#include "basegfx/polygon/b3dpolygon.hxx" +#include "basegfx/polygon/b3dpolypolygon.hxx" +#include "basegfx/polygon/b3dpolypolygontools.hxx" +#include "basegfx/range/b2drange.hxx" +#include "basegfx/vector/b2dvector.hxx" +#include "basegfx/vector/b3dvector.hxx" +#include "basic/basmgr.hxx" +#include "basic/sbmod.hxx" +#include "basic/sbuno.hxx" +#include "basic/sbx.hxx" +#include "basic/sbxvar.hxx" +#include "boost/scoped_ptr.hpp" +#include "boost/shared_ptr.hpp" +#include "boost/spirit/core.hpp" +#include "com/sun/star/accessibility/AccessibleEventId.hpp" +#include "com/sun/star/accessibility/AccessibleEventObject.hpp" +#include "com/sun/star/accessibility/AccessibleRelationType.hpp" +#include "com/sun/star/accessibility/AccessibleRole.hpp" +#include "com/sun/star/accessibility/AccessibleStateType.hpp" +#include "com/sun/star/accessibility/AccessibleTextType.hpp" +#include "com/sun/star/accessibility/IllegalAccessibleComponentStateException.hpp" +#include "com/sun/star/accessibility/TextSegment.hpp" +#include "com/sun/star/accessibility/XAccessible.hpp" +#include "com/sun/star/accessibility/XAccessibleAction.hpp" +#include "com/sun/star/accessibility/XAccessibleContext.hpp" +#include "com/sun/star/accessibility/XAccessibleEventBroadcaster.hpp" +#include "com/sun/star/accessibility/XAccessibleEventListener.hpp" +#include "com/sun/star/accessibility/XAccessibleImage.hpp" +#include "com/sun/star/accessibility/XAccessibleRelationSet.hpp" +#include "com/sun/star/accessibility/XAccessibleSelection.hpp" +#include "com/sun/star/accessibility/XAccessibleStateSet.hpp" +#include "com/sun/star/accessibility/XAccessibleTable.hpp" +#include "com/sun/star/accessibility/XAccessibleTextAttributes.hpp" +#include "com/sun/star/accessibility/XAccessibleValue.hpp" +#include "com/sun/star/awt/CharSet.hpp" +#include "com/sun/star/awt/FocusChangeReason.hpp" +#include "com/sun/star/awt/FontDescriptor.hpp" +#include "com/sun/star/awt/FontFamily.hpp" +#include "com/sun/star/awt/FontPitch.hpp" +#include "com/sun/star/awt/FontSlant.hpp" +#include "com/sun/star/awt/FontType.hpp" +#include "com/sun/star/awt/FontWeight.hpp" +#include "com/sun/star/awt/FontWidth.hpp" +#include "com/sun/star/awt/Gradient.hpp" +#include "com/sun/star/awt/GradientStyle.hpp" +#include "com/sun/star/awt/Key.hpp" +#include "com/sun/star/awt/KeyEvent.hpp" +#include "com/sun/star/awt/KeyModifier.hpp" +#include "com/sun/star/awt/LineEndFormat.hpp" +#include "com/sun/star/awt/PosSize.hpp" +#include "com/sun/star/awt/RasterOperation.hpp" +#include "com/sun/star/awt/Rectangle.hpp" +#include "com/sun/star/awt/ScrollBarOrientation.hpp" +#include "com/sun/star/awt/SimpleFontMetric.hpp" +#include "com/sun/star/awt/Size.hpp" +#include "com/sun/star/awt/TextAlign.hpp" +#include "com/sun/star/awt/VisualEffect.hpp" +#include "com/sun/star/awt/WindowAttribute.hpp" +#include "com/sun/star/awt/WindowDescriptor.hpp" +#include "com/sun/star/awt/XBitmap.hpp" +#include "com/sun/star/awt/XCheckBox.hpp" +#include "com/sun/star/awt/XComboBox.hpp" +#include "com/sun/star/awt/XControl.hpp" +#include "com/sun/star/awt/XControlContainer.hpp" +#include "com/sun/star/awt/XControlModel.hpp" +#include "com/sun/star/awt/XDevice.hpp" +#include "com/sun/star/awt/XFocusListener.hpp" +#include "com/sun/star/awt/XFont.hpp" +#include "com/sun/star/awt/XGraphics.hpp" +#include "com/sun/star/awt/XImageConsumer.hpp" +#include "com/sun/star/awt/XItemListener.hpp" +#include "com/sun/star/awt/XLayoutConstrains.hpp" +#include "com/sun/star/awt/XListBox.hpp" +#include "com/sun/star/awt/XMouseListener.hpp" +#include "com/sun/star/awt/XProgressMonitor.hpp" +#include "com/sun/star/awt/XTabController.hpp" +#include "com/sun/star/awt/XTabControllerModel.hpp" +#include "com/sun/star/awt/XTextListener.hpp" +#include "com/sun/star/awt/XToolkit.hpp" +#include "com/sun/star/awt/XVclWindowPeer.hpp" +#include "com/sun/star/awt/XWindow.hpp" +#include "com/sun/star/awt/XWindowListener.hpp" +#include "com/sun/star/awt/XWindowPeer.hpp" +#include "com/sun/star/beans/NamedValue.hpp" +#include "com/sun/star/beans/PropertyAttribute.hpp" +#include "com/sun/star/beans/PropertyChangeEvent.hpp" +#include "com/sun/star/beans/PropertyState.hpp" +#include "com/sun/star/beans/PropertyValue.hpp" +#include "com/sun/star/beans/PropertyValues.hdl" +#include "com/sun/star/beans/PropertyValues.hpp" +#include "com/sun/star/beans/XFastPropertySet.hpp" +#include "com/sun/star/beans/XIntrospection.hpp" +#include "com/sun/star/beans/XMultiPropertySet.hpp" +#include "com/sun/star/beans/XMultiPropertyStates.hpp" +#include "com/sun/star/beans/XPropertyChangeListener.hpp" +#include "com/sun/star/beans/XPropertySet.hpp" +#include "com/sun/star/beans/XPropertySetInfo.hpp" +#include "com/sun/star/beans/XPropertyState.hpp" +#include "com/sun/star/chart/ChartAxisArrangeOrderType.hpp" +#include "com/sun/star/container/ContainerEvent.hpp" +#include "com/sun/star/container/NoSuchElementException.hpp" +#include "com/sun/star/container/XChild.hpp" +#include "com/sun/star/container/XContainer.hpp" +#include "com/sun/star/container/XContainerListener.hpp" +#include "com/sun/star/container/XContainerQuery.hpp" +#include "com/sun/star/container/XContentEnumerationAccess.hpp" +#include "com/sun/star/container/XEnumeration.hpp" +#include "com/sun/star/container/XEnumerationAccess.hpp" +#include "com/sun/star/container/XHierarchicalNameAccess.hpp" +#include "com/sun/star/container/XIdentifierContainer.hpp" +#include "com/sun/star/container/XIndexAccess.hpp" +#include "com/sun/star/container/XIndexContainer.hpp" +#include "com/sun/star/container/XIndexReplace.hpp" +#include "com/sun/star/container/XNameAccess.hpp" +#include "com/sun/star/container/XNameContainer.hpp" +#include "com/sun/star/container/XNameReplace.hpp" +#include "com/sun/star/container/XNamed.hpp" +#include "com/sun/star/container/XSet.hpp" +#include "com/sun/star/datatransfer/DataFlavor.hpp" +#include "com/sun/star/datatransfer/XTransferable.hpp" +#include "com/sun/star/datatransfer/clipboard/XClipboard.hpp" +#include "com/sun/star/datatransfer/clipboard/XFlushableClipboard.hpp" +#include "com/sun/star/datatransfer/dnd/DNDConstants.hpp" +#include "com/sun/star/datatransfer/dnd/XDragGestureRecognizer.hpp" +#include "com/sun/star/datatransfer/dnd/XDropTarget.hpp" +#include "com/sun/star/document/EventObject.hpp" +#include "com/sun/star/document/UpdateDocMode.hpp" +#include "com/sun/star/document/XActionLockable.hpp" +#include "com/sun/star/document/XBinaryStreamResolver.hpp" +#include "com/sun/star/document/XDocumentInfoSupplier.hpp" +#include "com/sun/star/document/XEmbeddedObjectResolver.hpp" +#include "com/sun/star/document/XEventBroadcaster.hpp" +#include "com/sun/star/document/XEventListener.hpp" +#include "com/sun/star/document/XEventsSupplier.hpp" +#include "com/sun/star/document/XExporter.hpp" +#include "com/sun/star/document/XFilter.hpp" +#include "com/sun/star/document/XGraphicObjectResolver.hpp" +#include "com/sun/star/document/XImporter.hpp" +#include "com/sun/star/document/XLinkTargetSupplier.hpp" +#include "com/sun/star/document/XMimeTypeInfo.hpp" +#include "com/sun/star/drawing/BitmapMode.hpp" +#include "com/sun/star/drawing/CameraGeometry.hpp" +#include "com/sun/star/drawing/CircleKind.hpp" +#include "com/sun/star/drawing/ColorMode.hpp" +#include "com/sun/star/drawing/ConnectionType.hpp" +#include "com/sun/star/drawing/ConnectorType.hpp" +#include "com/sun/star/drawing/DashStyle.hpp" +#include "com/sun/star/drawing/Direction3D.hpp" +#include "com/sun/star/drawing/DoubleSequence.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeAdjustmentValue.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeGluePointType.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeParameter.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeParameterPair.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeParameterType.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeSegment.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeSegmentCommand.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeTextFrame.hpp" +#include "com/sun/star/drawing/EnhancedCustomShapeTextPathMode.hpp" +#include "com/sun/star/drawing/FillStyle.hpp" +#include "com/sun/star/drawing/FlagSequence.hpp" +#include "com/sun/star/drawing/Hatch.hpp" +#include "com/sun/star/drawing/HomogenMatrix.hpp" +#include "com/sun/star/drawing/HomogenMatrix3.hpp" +#include "com/sun/star/drawing/LineDash.hpp" +#include "com/sun/star/drawing/LineJoint.hpp" +#include "com/sun/star/drawing/LineStyle.hpp" +#include "com/sun/star/drawing/MeasureKind.hpp" +#include "com/sun/star/drawing/MeasureTextHorzPos.hpp" +#include "com/sun/star/drawing/MeasureTextVertPos.hpp" +#include "com/sun/star/drawing/NormalsKind.hpp" +#include "com/sun/star/drawing/PolyPolygonShape3D.hpp" +#include "com/sun/star/drawing/PolygonFlags.hpp" +#include "com/sun/star/drawing/PolygonKind.hpp" +#include "com/sun/star/drawing/Position3D.hpp" +#include "com/sun/star/drawing/ProjectionMode.hpp" +#include "com/sun/star/drawing/RectanglePoint.hpp" +#include "com/sun/star/drawing/ShadeMode.hpp" +#include "com/sun/star/drawing/TextAdjust.hpp" +#include "com/sun/star/drawing/TextAnimationDirection.hpp" +#include "com/sun/star/drawing/TextAnimationKind.hpp" +#include "com/sun/star/drawing/TextFitToSizeType.hpp" +#include "com/sun/star/drawing/TextHorizontalAdjust.hpp" +#include "com/sun/star/drawing/TextVerticalAdjust.hpp" +#include "com/sun/star/drawing/TextureKind.hpp" +#include "com/sun/star/drawing/TextureMode.hpp" +#include "com/sun/star/drawing/TextureProjectionMode.hpp" +#include "com/sun/star/drawing/XGluePointsSupplier.hpp" +#include "com/sun/star/drawing/XShapeDescriptor.hpp" +#include "com/sun/star/embed/Aspects.hpp" +#include "com/sun/star/embed/ElementModes.hpp" +#include "com/sun/star/embed/EmbedMisc.hpp" +#include "com/sun/star/embed/EmbedStates.hpp" +#include "com/sun/star/embed/EntryInitModes.hpp" +#include "com/sun/star/embed/NoVisualAreaSizeException.hpp" +#include "com/sun/star/embed/XEmbedObjectCreator.hpp" +#include "com/sun/star/embed/XEmbedObjectFactory.hpp" +#include "com/sun/star/embed/XEmbedPersist.hpp" +#include "com/sun/star/embed/XEmbeddedObject.hpp" +#include "com/sun/star/embed/XInsertObjectDialog.hpp" +#include "com/sun/star/embed/XLinkageSupport.hpp" +#include "com/sun/star/embed/XStorage.hpp" +#include "com/sun/star/embed/XTransactedObject.hpp" +#include "com/sun/star/form/DatabaseDeleteEvent.hpp" +#include "com/sun/star/form/DatabaseParameterEvent.hpp" +#include "com/sun/star/form/ErrorEvent.hpp" +#include "com/sun/star/form/FormButtonType.hpp" +#include "com/sun/star/form/FormComponentType.hpp" +#include "com/sun/star/form/ListSourceType.hpp" +#include "com/sun/star/form/NavigationBarMode.hpp" +#include "com/sun/star/form/TabulatorCycle.hpp" +#include "com/sun/star/form/XBoundComponent.hpp" +#include "com/sun/star/form/XBoundControl.hpp" +#include "com/sun/star/form/XConfirmDeleteBroadcaster.hpp" +#include "com/sun/star/form/XConfirmDeleteListener.hpp" +#include "com/sun/star/form/XDatabaseParameterBroadcaster2.hpp" +#include "com/sun/star/form/XDatabaseParameterListener.hpp" +#include "com/sun/star/form/XForm.hpp" +#include "com/sun/star/form/XFormComponent.hpp" +#include "com/sun/star/form/XFormController.hpp" +#include "com/sun/star/form/XFormControllerListener.hpp" +#include "com/sun/star/form/XFormsSupplier.hpp" +#include "com/sun/star/form/XFormsSupplier2.hpp" +#include "com/sun/star/form/XGrid.hpp" +#include "com/sun/star/form/XGridColumnFactory.hpp" +#include "com/sun/star/form/XGridFieldDataSupplier.hpp" +#include "com/sun/star/form/XGridPeer.hpp" +#include "com/sun/star/form/XImageProducerSupplier.hpp" +#include "com/sun/star/form/XLoadListener.hpp" +#include "com/sun/star/form/XLoadable.hpp" +#include "com/sun/star/form/XReset.hpp" +#include "com/sun/star/form/XResetListener.hpp" +#include "com/sun/star/form/binding/XBindableValue.hpp" +#include "com/sun/star/form/binding/XListEntrySink.hpp" +#include "com/sun/star/form/binding/XValueBinding.hpp" +#include "com/sun/star/form/submission/XSubmissionSupplier.hpp" +#include "com/sun/star/form/validation/XFormComponentValidityListener.hpp" +#include "com/sun/star/form/validation/XValidatableFormComponent.hpp" +#include "com/sun/star/frame/DispatchDescriptor.hpp" +#include "com/sun/star/frame/DispatchInformation.hpp" +#include "com/sun/star/frame/FeatureStateEvent.hpp" +#include "com/sun/star/frame/FrameSearchFlag.hpp" +#include "com/sun/star/frame/XComponentLoader.hpp" +#include "com/sun/star/frame/XController.hpp" +#include "com/sun/star/frame/XDesktop.hpp" +#include "com/sun/star/frame/XDispatch.hpp" +#include "com/sun/star/frame/XDispatchInformationProvider.hpp" +#include "com/sun/star/frame/XDispatchProvider.hpp" +#include "com/sun/star/frame/XDispatchProviderInterception.hpp" +#include "com/sun/star/frame/XDispatchProviderInterceptor.hpp" +#include "com/sun/star/frame/XFrame.hpp" +#include "com/sun/star/frame/XFrameActionListener.hpp" +#include "com/sun/star/frame/XFrames.hpp" +#include "com/sun/star/frame/XFramesSupplier.hpp" +#include "com/sun/star/frame/XInterceptorInfo.hpp" +#include "com/sun/star/frame/XModel.hpp" +#include "com/sun/star/frame/XModuleManager.hpp" +#include "com/sun/star/frame/XStatusListener.hpp" +#include "com/sun/star/frame/XStorable.hpp" +#include "com/sun/star/frame/XSynchronousDispatch.hpp" +#include "com/sun/star/frame/status/ClipboardFormats.hpp" +#include "com/sun/star/frame/status/FontHeight.hpp" +#include "com/sun/star/frame/status/ItemStatus.hpp" +#include "com/sun/star/frame/status/LeftRightMargin.hpp" +#include "com/sun/star/frame/status/UpperLowerMargin.hpp" +#include "com/sun/star/frame/status/UpperLowerMarginScale.hpp" +#include "com/sun/star/gallery/GalleryItemType.hpp" +#include "com/sun/star/gallery/XGalleryItem.hpp" +#include "com/sun/star/gallery/XGalleryTheme.hpp" +#include "com/sun/star/gallery/XGalleryThemeProvider.hpp" +#include "com/sun/star/graphic/XGraphic.hpp" +#include "com/sun/star/graphic/XGraphicProvider.hpp" +#include "com/sun/star/graphic/XGraphicRenderer.hpp" +#include "com/sun/star/i18n/CharacterIteratorMode.hdl" +#include "com/sun/star/i18n/CharacterIteratorMode.hpp" +#include "com/sun/star/i18n/CollatorOptions.hpp" +#include "com/sun/star/i18n/ForbiddenCharacters.hpp" +#include "com/sun/star/i18n/InputSequenceCheckMode.hpp" +#include "com/sun/star/i18n/KCharacterType.hpp" +#include "com/sun/star/i18n/ScriptType.hdl" +#include "com/sun/star/i18n/ScriptType.hpp" +#include "com/sun/star/i18n/TextConversionOption.hdl" +#include "com/sun/star/i18n/TextConversionOption.hpp" +#include "com/sun/star/i18n/TextConversionType.hpp" +#include "com/sun/star/i18n/TransliterationModules.hpp" +#include "com/sun/star/i18n/UnicodeScript.hpp" +#include "com/sun/star/i18n/UnicodeType.hdl" +#include "com/sun/star/i18n/WordType.hpp" +#include "com/sun/star/i18n/XBreakIterator.hpp" +#include "com/sun/star/i18n/XExtendedInputSequenceChecker.hpp" +#include "com/sun/star/i18n/XExtendedTextConversion.hpp" +#include "com/sun/star/i18n/XForbiddenCharacters.hpp" +#include "com/sun/star/i18n/XTextConversion.hpp" +#include "com/sun/star/inspection/XObjectInspector.hpp" +#include "com/sun/star/inspection/XObjectInspectorModel.hpp" +#include "com/sun/star/io/IOException.hpp" +#include "com/sun/star/io/XActiveDataControl.hpp" +#include "com/sun/star/io/XActiveDataSink.hpp" +#include "com/sun/star/io/XActiveDataSource.hpp" +#include "com/sun/star/io/XInputStream.hpp" +#include "com/sun/star/io/XInputStreamProvider.hpp" +#include "com/sun/star/io/XMarkableStream.hpp" +#include "com/sun/star/io/XObjectInputStream.hpp" +#include "com/sun/star/io/XObjectOutputStream.hpp" +#include "com/sun/star/io/XOutputStream.hpp" +#include "com/sun/star/io/XPersistObject.hpp" +#include "com/sun/star/io/XSeekable.hdl" +#include "com/sun/star/io/XStream.hpp" +#include "com/sun/star/lang/DisposedException.hpp" +#include "com/sun/star/lang/EventObject.hpp" +#include "com/sun/star/lang/IllegalArgumentException.hpp" +#include "com/sun/star/lang/IndexOutOfBoundsException.hpp" +#include "com/sun/star/lang/Locale.hpp" +#include "com/sun/star/lang/NoSupportException.hpp" +#include "com/sun/star/lang/ServiceNotRegisteredException.hpp" +#include "com/sun/star/lang/XComponent.hpp" +#include "com/sun/star/lang/XEventListener.hpp" +#include "com/sun/star/lang/XInitialization.hpp" +#include "com/sun/star/lang/XMultiComponentFactory.hpp" +#include "com/sun/star/lang/XMultiServiceFactory.hpp" +#include "com/sun/star/lang/XServiceDisplayName.hpp" +#include "com/sun/star/lang/XServiceInfo.hpp" +#include "com/sun/star/lang/XServiceName.hpp" +#include "com/sun/star/lang/XSingleComponentFactory.hpp" +#include "com/sun/star/lang/XTypeProvider.hpp" +#include "com/sun/star/lang/XUnoTunnel.hpp" +#include "com/sun/star/linguistic2/ConversionDictionaryType.hpp" +#include "com/sun/star/linguistic2/ConversionDirection.hdl" +#include "com/sun/star/linguistic2/ConversionPropertyType.hpp" +#include "com/sun/star/linguistic2/DictionaryEvent.hpp" +#include "com/sun/star/linguistic2/DictionaryEventFlags.hpp" +#include "com/sun/star/linguistic2/DictionaryListEvent.hpp" +#include "com/sun/star/linguistic2/DictionaryListEventFlags.hpp" +#include "com/sun/star/linguistic2/DictionaryType.hpp" +#include "com/sun/star/linguistic2/SpellFailure.hpp" +#include "com/sun/star/linguistic2/XAvailableLocales.hpp" +#include "com/sun/star/linguistic2/XConversionDictionary.hpp" +#include "com/sun/star/linguistic2/XConversionDictionaryList.hpp" +#include "com/sun/star/linguistic2/XConversionPropertyType.hpp" +#include "com/sun/star/linguistic2/XDictionary.hpp" +#include "com/sun/star/linguistic2/XDictionary1.hpp" +#include "com/sun/star/linguistic2/XDictionaryEntry.hpp" +#include "com/sun/star/linguistic2/XDictionaryEventListener.hpp" +#include "com/sun/star/linguistic2/XDictionaryList.hpp" +#include "com/sun/star/linguistic2/XDictionaryListEventListener.hpp" +#include "com/sun/star/linguistic2/XHyphenatedWord.hpp" +#include "com/sun/star/linguistic2/XHyphenator.hpp" +#include "com/sun/star/linguistic2/XLinguServiceManager.hdl" +#include "com/sun/star/linguistic2/XLinguServiceManager.hpp" +#include "com/sun/star/linguistic2/XMeaning.hpp" +#include "com/sun/star/linguistic2/XPossibleHyphens.hpp" +#include "com/sun/star/linguistic2/XSpellAlternatives.hpp" +#include "com/sun/star/linguistic2/XSpellChecker.hpp" +#include "com/sun/star/linguistic2/XSpellChecker1.hpp" +#include "com/sun/star/linguistic2/XSupportedLocales.hpp" +#include "com/sun/star/linguistic2/XThesaurus.hpp" +#include "com/sun/star/media/XPlayer.hpp" +#include "com/sun/star/media/ZoomLevel.hpp" +#include "com/sun/star/plugin/PluginDescription.hpp" +#include "com/sun/star/plugin/XPluginManager.hpp" +#include "com/sun/star/reflection/XIdlClass.hpp" +#include "com/sun/star/reflection/XIdlMethod.hpp" +#include "com/sun/star/reflection/XInterfaceMethodTypeDescription.hpp" +#include "com/sun/star/reflection/XProxyFactory.hpp" +#include "com/sun/star/registry/XRegistryKey.hpp" +#include "com/sun/star/registry/XSimpleRegistry.hpp" +#include "com/sun/star/script/ScriptEvent.hpp" +#include "com/sun/star/script/ScriptEventDescriptor.hpp" +#include "com/sun/star/script/XEventAttacherManager.hpp" +#include "com/sun/star/script/XInvocation.hpp" +#include "com/sun/star/script/XLibraryContainer.hpp" +#include "com/sun/star/script/XScriptListener.hpp" +#include "com/sun/star/script/XTypeConverter.hpp" +#include "com/sun/star/script/browse/BrowseNodeFactoryViewTypes.hpp" +#include "com/sun/star/script/browse/BrowseNodeTypes.hpp" +#include "com/sun/star/script/browse/XBrowseNode.hpp" +#include "com/sun/star/script/browse/XBrowseNodeFactory.hpp" +#include "com/sun/star/script/provider/ScriptErrorRaisedException.hpp" +#include "com/sun/star/script/provider/ScriptExceptionRaisedException.hpp" +#include "com/sun/star/script/provider/ScriptFrameworkErrorType.hpp" +#include "com/sun/star/script/provider/XScriptProvider.hpp" +#include "com/sun/star/script/provider/XScriptProviderSupplier.hpp" +#include "com/sun/star/sdb/CommandType.hpp" +#include "com/sun/star/sdb/ParametersRequest.hpp" +#include "com/sun/star/sdb/RowChangeAction.hpp" +#include "com/sun/star/sdb/RowChangeEvent.hpp" +#include "com/sun/star/sdb/SQLContext.hpp" +#include "com/sun/star/sdb/SQLErrorEvent.hpp" +#include "com/sun/star/sdb/XColumn.hpp" +#include "com/sun/star/sdb/XColumnUpdate.hpp" +#include "com/sun/star/sdb/XCompletedConnection.hpp" +#include "com/sun/star/sdb/XInteractionSupplyParameters.hpp" +#include "com/sun/star/sdb/XQueriesSupplier.hpp" +#include "com/sun/star/sdb/XResultSetAccess.hpp" +#include "com/sun/star/sdb/XRowSetApproveBroadcaster.hpp" +#include "com/sun/star/sdb/XRowSetApproveListener.hpp" +#include "com/sun/star/sdb/XRowSetSupplier.hpp" +#include "com/sun/star/sdb/XSQLErrorBroadcaster.hpp" +#include "com/sun/star/sdb/XSQLErrorListener.hpp" +#include "com/sun/star/sdb/XSQLQueryComposer.hpp" +#include "com/sun/star/sdb/XSQLQueryComposerFactory.hpp" +#include "com/sun/star/sdb/XSingleSelectQueryComposer.hpp" +#include "com/sun/star/sdbc/ColumnValue.hpp" +#include "com/sun/star/sdbc/DataType.hpp" +#include "com/sun/star/sdbc/ResultSetConcurrency.hpp" +#include "com/sun/star/sdbc/ResultSetType.hpp" +#include "com/sun/star/sdbc/XConnection.hpp" +#include "com/sun/star/sdbc/XDataSource.hpp" +#include "com/sun/star/sdbc/XDatabaseMetaData.hpp" +#include "com/sun/star/sdbc/XPreparedStatement.hpp" +#include "com/sun/star/sdbc/XResultSet.hpp" +#include "com/sun/star/sdbc/XResultSetUpdate.hpp" +#include "com/sun/star/sdbc/XRow.hpp" +#include "com/sun/star/sdbc/XRowSet.hpp" +#include "com/sun/star/sdbc/XRowSetListener.hpp" +#include "com/sun/star/sdbc/XStatement.hpp" +#include "com/sun/star/sdbcx/Privilege.hpp" +#include "com/sun/star/sdbcx/XColumnsSupplier.hpp" +#include "com/sun/star/sdbcx/XDataDescriptorFactory.hpp" +#include "com/sun/star/sdbcx/XDeleteRows.hpp" +#include "com/sun/star/sdbcx/XRowLocate.hpp" +#include "com/sun/star/sdbcx/XTablesSupplier.hpp" +#include "com/sun/star/security/XDocumentDigitalSignatures.hpp" +#include "com/sun/star/style/BreakType.hpp" +#include "com/sun/star/style/CaseMap.hpp" +#include "com/sun/star/style/GraphicLocation.hpp" +#include "com/sun/star/style/LineSpacing.hpp" +#include "com/sun/star/style/LineSpacingMode.hpp" +#include "com/sun/star/style/NumberingType.hpp" +#include "com/sun/star/style/PageStyleLayout.hpp" +#include "com/sun/star/style/ParagraphAdjust.hpp" +#include "com/sun/star/style/TabStop.hpp" +#include "com/sun/star/style/VerticalAlignment.hpp" +#include "com/sun/star/style/XStyle.hpp" +#include "com/sun/star/style/XStyleFamiliesSupplier.hpp" +#include "com/sun/star/table/BorderLine.hpp" +#include "com/sun/star/table/CellAddress.hpp" +#include "com/sun/star/table/CellContentType.hpp" +#include "com/sun/star/table/CellHoriJustify.hpp" +#include "com/sun/star/table/CellOrientation.hpp" +#include "com/sun/star/table/CellRangeAddress.hpp" +#include "com/sun/star/table/CellVertJustify.hpp" +#include "com/sun/star/table/ShadowFormat.hpp" +#include "com/sun/star/table/ShadowLocation.hpp" +#include "com/sun/star/table/TableBorder.hpp" +#include "com/sun/star/table/TableOrientation.hpp" +#include "com/sun/star/task/XInteractionHandler.hpp" +#include "com/sun/star/task/XStatusIndicator.hpp" +#include "com/sun/star/task/XStatusIndicatorFactory.hpp" +#include "com/sun/star/text/CharacterCompressionType.hpp" +#include "com/sun/star/text/ControlCharacter.hpp" +#include "com/sun/star/text/FilenameDisplayFormat.hpp" +#include "com/sun/star/text/FontEmphasis.hpp" +#include "com/sun/star/text/GraphicCrop.hpp" +#include "com/sun/star/text/HoriOrientation.hpp" +#include "com/sun/star/text/RelOrientation.hpp" +#include "com/sun/star/text/RubyAdjust.hpp" +#include "com/sun/star/text/TextContentAnchorType.hpp" +#include "com/sun/star/text/VertOrientation.hpp" +#include "com/sun/star/text/WrapTextMode.hpp" +#include "com/sun/star/text/WritingMode.hpp" +#include "com/sun/star/text/WritingMode2.hpp" +#include "com/sun/star/text/XDefaultNumberingProvider.hpp" +#include "com/sun/star/text/XNumberingFormatter.hpp" +#include "com/sun/star/text/XNumberingTypeInfo.hpp" +#include "com/sun/star/text/XRubySelection.hpp" +#include "com/sun/star/text/XSimpleText.hpp" +#include "com/sun/star/text/XText.hpp" +#include "com/sun/star/text/XTextContent.hpp" +#include "com/sun/star/text/XTextCursor.hpp" +#include "com/sun/star/text/XTextField.hdl" +#include "com/sun/star/text/XTextField.hpp" +#include "com/sun/star/text/XTextRange.hpp" +#include "com/sun/star/text/XTextRangeCompare.hpp" +#include "com/sun/star/text/XTextRangeMover.hpp" +#include "com/sun/star/ucb/CommandAbortedException.hpp" +#include "com/sun/star/ucb/NameClash.hpp" +#include "com/sun/star/ucb/NumberedSortingInfo.hpp" +#include "com/sun/star/ucb/TransferInfo.hpp" +#include "com/sun/star/ucb/XAnyCompare.hpp" +#include "com/sun/star/ucb/XAnyCompareFactory.hpp" +#include "com/sun/star/ucb/XCommandEnvironment.hpp" +#include "com/sun/star/ucb/XContent.hpp" +#include "com/sun/star/ucb/XContentAccess.hpp" +#include "com/sun/star/ucb/XContentProvider.hpp" +#include "com/sun/star/ucb/XSimpleFileAccess.hpp" +#include "com/sun/star/ucb/XSortedDynamicResultSetFactory.hpp" +#include "com/sun/star/ui/ImageType.hpp" +#include "com/sun/star/ui/ItemStyle.hpp" +#include "com/sun/star/ui/ItemType.hpp" +#include "com/sun/star/ui/UIElementType.hpp" +#include "com/sun/star/ui/XImageManager.hpp" +#include "com/sun/star/ui/XModuleUIConfigurationManager.hpp" +#include "com/sun/star/ui/XModuleUIConfigurationManagerSupplier.hpp" +#include "com/sun/star/ui/XUIConfiguration.hpp" +#include "com/sun/star/ui/XUIConfigurationListener.hpp" +#include "com/sun/star/ui/XUIConfigurationManager.hpp" +#include "com/sun/star/ui/XUIConfigurationManagerSupplier.hpp" +#include "com/sun/star/ui/XUIConfigurationPersistence.hpp" +#include "com/sun/star/ui/XUIConfigurationStorage.hpp" +#include "com/sun/star/ui/XUIElement.hpp" +#include "com/sun/star/ui/dialogs/CommonFilePickerElementIds.hpp" +#include "com/sun/star/ui/dialogs/ExecutableDialogResults.hpp" +#include "com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp" +#include "com/sun/star/ui/dialogs/FilePreviewImageFormats.hpp" +#include "com/sun/star/ui/dialogs/ListboxControlActions.hpp" +#include "com/sun/star/ui/dialogs/TemplateDescription.hpp" +#include "com/sun/star/ui/dialogs/XExecutableDialog.hpp" +#include "com/sun/star/ui/dialogs/XFilePicker.hpp" +#include "com/sun/star/ui/dialogs/XFilePickerControlAccess.hpp" +#include "com/sun/star/ui/dialogs/XFilePickerListener.hpp" +#include "com/sun/star/ui/dialogs/XFilePickerNotifier.hpp" +#include "com/sun/star/ui/dialogs/XFilePreview.hpp" +#include "com/sun/star/ui/dialogs/XFilterManager.hpp" +#include "com/sun/star/ui/dialogs/XFolderPicker.hpp" +#include "com/sun/star/uno/Any.h" +#include "com/sun/star/uno/Any.hxx" +#include "com/sun/star/uno/Exception.hpp" +#include "com/sun/star/uno/Reference.h" +#include "com/sun/star/uno/Reference.hxx" +#include "com/sun/star/uno/RuntimeException.hpp" +#include "com/sun/star/uno/Sequence.h" +#include "com/sun/star/uno/Sequence.hxx" +#include "com/sun/star/uno/Type.h" +#include "com/sun/star/uno/XAggregation.hpp" +#include "com/sun/star/uno/XComponentContext.hpp" +#include "com/sun/star/uno/XInterface.hpp" +#include "com/sun/star/uno/XNamingService.hpp" +#include "com/sun/star/util/Date.hpp" +#include "com/sun/star/util/DateTime.hpp" +#include "com/sun/star/util/Language.hpp" +#include "com/sun/star/util/MeasureUnit.hpp" +#include "com/sun/star/util/NumberFormat.hpp" +#include "com/sun/star/util/SearchAlgorithms.hpp" +#include "com/sun/star/util/SearchFlags.hpp" +#include "com/sun/star/util/SearchOptions.hpp" +#include "com/sun/star/util/SearchResult.hpp" +#include "com/sun/star/util/SortField.hpp" +#include "com/sun/star/util/SortFieldType.hpp" +#include "com/sun/star/util/URL.hpp" +#include "com/sun/star/util/XCancellable.hpp" +#include "com/sun/star/util/XChangesBatch.hpp" +#include "com/sun/star/util/XCloneable.hpp" +#include "com/sun/star/util/XCloseable.hpp" +#include "com/sun/star/util/XFlushable.hpp" +#include "com/sun/star/util/XLocalizedAliases.hpp" +#include "com/sun/star/util/XModeChangeBroadcaster.hpp" +#include "com/sun/star/util/XModeChangeListener.hpp" +#include "com/sun/star/util/XModeSelector.hpp" +#include "com/sun/star/util/XModifiable.hpp" +#include "com/sun/star/util/XModifyBroadcaster.hpp" +#include "com/sun/star/util/XModifyListener.hpp" +#include "com/sun/star/util/XNumberFormatTypes.hpp" +#include "com/sun/star/util/XNumberFormats.hpp" +#include "com/sun/star/util/XNumberFormatsSupplier.hpp" +#include "com/sun/star/util/XNumberFormatter.hpp" +#include "com/sun/star/util/XTextSearch.hpp" +#include "com/sun/star/util/XURLTransformer.hpp" +#include "com/sun/star/util/logging/LogLevel.hpp" +#include "com/sun/star/util/logging/XLogger.hpp" +#include "com/sun/star/view/XSelectionChangeListener.hpp" +#include "com/sun/star/view/XSelectionSupplier.hpp" +#include "com/sun/star/xforms/XFormsSupplier.hpp" +#include "com/sun/star/xforms/XFormsUIHelper1.hpp" +#include "com/sun/star/xforms/XModel.hpp" +#include "com/sun/star/xforms/XSubmission.hpp" +#include "com/sun/star/xml/AttributeData.hpp" +#include "com/sun/star/xml/dom/DOMException.hpp" +#include "com/sun/star/xml/dom/XDocument.hpp" +#include "com/sun/star/xml/dom/XNode.hpp" +#include "com/sun/star/xml/dom/events/XEventListener.hpp" +#include "com/sun/star/xml/dom/events/XEventTarget.hpp" +#include "com/sun/star/xml/sax/InputSource.hpp" +#include "com/sun/star/xml/sax/SAXParseException.hpp" +#include "com/sun/star/xml/sax/XAttributeList.hpp" +#include "com/sun/star/xml/sax/XDocumentHandler.hpp" +#include "com/sun/star/xml/sax/XParser.hpp" +#include "comphelper/accessibleeventnotifier.hxx" +#include "comphelper/anytostring.hxx" +#include "comphelper/broadcasthelper.hxx" +#include "comphelper/componentcontext.hxx" +#include "comphelper/configurationhelper.hxx" +#include "comphelper/container.hxx" +#include "comphelper/embeddedobjectcontainer.hxx" +#include "comphelper/enumhelper.hxx" +#include "comphelper/implementationreference.hxx" +#include "comphelper/interaction.hxx" +#include "comphelper/numbers.hxx" +#include "comphelper/processfactory.hxx" +#include "comphelper/propertycontainer.hxx" +#include "comphelper/propertysethelper.hxx" +#include "comphelper/regpathhelper.hxx" +#include "comphelper/scopeguard.hxx" +#include "comphelper/seqstream.hxx" +#include "comphelper/sequence.hxx" +#include "comphelper/sequenceashashmap.hxx" +#include "comphelper/sequenceasvector.hxx" +#include "comphelper/servicehelper.hxx" +#include "comphelper/storagehelper.hxx" +#include "comphelper/types.hxx" +#include "comphelper/uno3.hxx" +#include "connectivity/IParseContext.hxx" +#include "connectivity/dbexception.hxx" +#include "connectivity/sqlnode.hxx" +#include "connectivity/sqlparse.hxx" +#include "cppuhelper/bootstrap.hxx" +#include "cppuhelper/compbase12.hxx" +#include "cppuhelper/compbase2.hxx" +#include "cppuhelper/compbase3.hxx" +#include "cppuhelper/compbase4.hxx" +#include "cppuhelper/compbase6.hxx" +#include "cppuhelper/compbase7.hxx" +#include "cppuhelper/component.hxx" +#include "cppuhelper/component_context.hxx" +#include "cppuhelper/exc_hlp.hxx" +#include "cppuhelper/factory.hxx" +#include "cppuhelper/implbase1.hxx" +#include "cppuhelper/implbase11.hxx" +#include "cppuhelper/implbase12.hxx" +#include "cppuhelper/implbase2.hxx" +#include "cppuhelper/implbase3.hxx" +#include "cppuhelper/implbase4.hxx" +#include "cppuhelper/implbase5.hxx" +#include "cppuhelper/implbase6.hxx" +#include "cppuhelper/implbase8.hxx" +#include "cppuhelper/implementationentry.hxx" +#include "cppuhelper/interfacecontainer.h" +#include "cppuhelper/interfacecontainer.hxx" +#include "cppuhelper/propshlp.hxx" +#include "cppuhelper/queryinterface.hxx" +#include "cppuhelper/servicefactory.hxx" +#include "cppuhelper/typeprovider.hxx" +#include "cppuhelper/weak.hxx" +#include "cppuhelper/weakagg.hxx" +#include "cppuhelper/weakref.hxx" +#include "i18npool/lang.h" +#include "i18npool/mslangid.hxx" +#include "jvmfwk/framework.h" +#include "linguistic/lngprops.hxx" +#include "osl/diagnose.h" +#include "osl/endian.h" +#include "osl/file.hxx" +#include "osl/interlck.h" +#include "osl/module.h" +#include "osl/module.hxx" +#include "osl/mutex.hxx" +#include "osl/nlsupport.h" +#include "osl/process.h" +#include "osl/security.hxx" +#include "rsc/rscsfx.hxx" +#include "rtl/bootstrap.hxx" +#include "rtl/cipher.h" +#include "rtl/crc.h" +#include "rtl/digest.h" +#include "rtl/locale.h" +#include "rtl/logfile.hxx" +#include "rtl/math.hxx" +#include "rtl/memory.h" +#include "rtl/tencinfo.h" +#include "rtl/textenc.h" +#include "rtl/ustrbuf.hxx" +#include "rtl/ustring.hxx" +#include "rtl/uuid.h" +#include "sal/config.h" +#include "sal/main.h" +#include "sal/types.h" +#include "sfx2/bindings.hxx" +#include "sfx2/ctrlitem.hxx" +#include "sfx2/dispatch.hxx" +#include "sfx2/docfilt.hxx" +#include "sfx2/event.hxx" +#include "sfx2/frame.hxx" +#include "sfx2/frmdescr.hxx" +#include "sfx2/imagemgr.hxx" +#include "sfx2/imgmgr.hxx" +#include "sfx2/linkmgr.hxx" +#include "sfx2/linksrc.hxx" +#include "sfx2/lnkbase.hxx" +#include "sfx2/minarray.hxx" +#include "sfx2/minfitem.hxx" +#include "sfx2/mnuitem.hxx" +#include "sfx2/module.hxx" +#include "sfx2/msg.hxx" +#include "sfx2/msgpool.hxx" +#include "sfx2/objface.hxx" +#include "sfx2/objitem.hxx" +#include "sfx2/progress.hxx" +#include "sfx2/querystatus.hxx" +#include "sfx2/request.hxx" +#include "sfx2/sfxdefs.hxx" +#include "sfx2/sfxdlg.hxx" +#include "sfx2/sfxhelp.hxx" +#include "sfx2/sfxhtml.hxx" +#include "sfx2/sfxstatuslistener.hxx" +#include "sfx2/sfxuno.hxx" +#include "sfx2/shell.hxx" +#include "sfx2/srchdefs.hxx" +#include "sfx2/tplpitem.hxx" +#include "sfx2/viewfrm.hxx" +#include "sot/clsids.hxx" +#include "sot/exchange.hxx" +#include "sot/factory.hxx" +#include "sot/formats.hxx" +#include <map> +#include <set> +#include <slist> +#include <vector> +#include "svtools/FilterConfigItem.hxx" +#include "svtools/accessibilityoptions.hxx" +#include "svl/adrparse.hxx" +#include "svtools/apearcfg.hxx" +#include "svl/brdcst.hxx" +#include "unotools/cacheoptions.hxx" +#include "svl/cjkoptions.hxx" +#include "unotools/cmdoptions.hxx" +#include "svl/cntwall.hxx" +#include "svtools/colorcfg.hxx" +#include "svl/ctloptions.hxx" +#include "unotools/defaultoptions.hxx" +#include "unotools/dynamicmenuoptions.hxx" +#include "svtools/ehdl.hxx" +#include "svl/eitem.hxx" +#include "unotools/eventcfg.hxx" +#include "unotools/extendedsecurityoptions.hxx" +#include "svl/filenotation.hxx" +#include "svl/flagitem.hxx" +#include "unotools/fltrcfg.hxx" +#include "unotools/fontoptions.hxx" +#include "svtools/fontsubstconfig.hxx" +#include "svtools/helpopt.hxx" +#include "svl/hint.hxx" +#include "svtools/htmlkywd.hxx" +#include "svtools/htmltokn.h" +#include "svtools/imagemgr.hxx" +#include "svtools/imapcirc.hxx" +#include "svtools/imapobj.hxx" +#include "svtools/imappoly.hxx" +#include "svtools/imaprect.hxx" +#include "svtools/inetimg.hxx" +#include "unotools/inetoptions.hxx" +#include "svl/intitem.hxx" +#include "svl/isethint.hxx" +#include "svl/itemiter.hxx" +#include "svl/itempool.hxx" +#include "svl/itemprop.hxx" +#include "svl/itemset.hxx" +#include "unotools/javaoptions.hxx" +#include "svl/languageoptions.hxx" +#include "unotools/lingucfg.hxx" +#include "unotools/linguprops.hxx" +#include "svl/lngmisc.hxx" +#include "svtools/localresaccess.hxx" +#include "svl/lstner.hxx" +#include "svl/macitem.hxx" +#include "svtools/menuoptions.hxx" +#include "svl/metitem.hxx" +#include "unotools/misccfg.hxx" +#include "svtools/miscopt.hxx" +#include "unotools/moduleoptions.hxx" +#include "svl/numuno.hxx" +#include "unotools/optionsdlg.hxx" +#include "svtools/parhtml.hxx" +#include "svtools/parrtf.hxx" +#include "unotools/pathoptions.hxx" +#include "svl/poolitem.hxx" +#include "unotools/printwarningoptions.hxx" +#include "svl/ptitem.hxx" +#include "svl/rectitem.hxx" +#include "svl/rngitem.hxx" +#include "svtools/rtfkeywd.hxx" +#include "svtools/rtfout.hxx" +#include "svtools/rtftoken.h" +#include "unotools/saveopt.hxx" +#include "unotools/searchopt.hxx" +#include "unotools/securityoptions.hxx" +#include "svl/sfontitm.hxx" +#include "svl/slstitm.hxx" +#include "svl/smplhint.hxx" +#include "svtools/soerr.hxx" +#include "unotools/sourceviewconfig.hxx" +#include "unotools/startoptions.hxx" +#include "svtools/stdmenu.hxx" +#include "svtools/stringtransfer.hxx" +#include "svl/stritem.hxx" +#include "svl/style.hxx" +#include "svl/svarray.hxx" +#include "svl/svstdarr.hxx" +#include "unotools/syslocaleoptions.hxx" +#include "svl/szitem.hxx" +#include "svtools/textdata.hxx" +#include "svtools/transfer.hxx" +#include "svtools/txtcmp.hxx" +#include "svl/undo.hxx" +#include "unotools/undoopt.hxx" +#include "svtools/unoevent.hxx" +#include "svtools/unoimap.hxx" +#include "svl/urihelper.hxx" +#include "svl/urlbmk.hxx" +#include "unotools/useroptions.hxx" +#include "unotools/viewoptions.hxx" +#include "svl/visitem.hxx" +#include "svl/whiter.hxx" +#include "sys/stat.h" +#include "sys/types.h" +#include "toolkit/awt/vclxdevice.hxx" +#include "toolkit/controls/unocontrol.hxx" +#include "tools/bigint.hxx" +#include "tools/color.hxx" +#include "tools/config.hxx" +#include "tools/contnr.hxx" +#include "tools/debug.hxx" +#include "tools/diagnose_ex.h" +#include "tools/dynary.hxx" +#include "tools/errcode.hxx" +#include "tools/errinf.hxx" +#include "tools/fract.hxx" +#include "tools/gen.hxx" +#include "tools/globname.hxx" +#include "tools/inetdef.hxx" +#include "tools/line.hxx" +#include "tools/link.hxx" +#include "tools/list.hxx" +#include "tools/multisel.hxx" +#include "tools/poly.hxx" +#include "tools/rc.h" +#include "tools/rc.hxx" +#include "tools/rcid.h" +#include "tools/ref.hxx" +#include "tools/resary.hxx" +#include "tools/resid.hxx" +#include "tools/resmgr.hxx" +#include "tools/rtti.hxx" +#include "tools/shl.hxx" +#include "tools/solar.h" +#include "tools/stack.hxx" +#include "tools/string.hxx" +#include "tools/table.hxx" +#include "tools/tenccvt.hxx" +#include "tools/urlobj.hxx" +#include "tools/vcompat.hxx" +#include "tools/vector2d.hxx" +#include "tools/weakbase.hxx" +#include "tools/wldcrd.hxx" +#include "tools/zcodec.hxx" +#include "ucbhelper/commandenvironment.hxx" +#include "ucbhelper/configurationkeys.hxx" +#include "ucbhelper/content.hxx" +#include "ucbhelper/contentbroker.hxx" +#include "unicode/ubidi.h" +#include "uno/lbnames.h" +#include "uno/mapping.hxx" +#include "unotools/accessiblerelationsethelper.hxx" +#include "unotools/accessiblestatesethelper.hxx" +#include "unotools/bootstrap.hxx" +#include "unotools/charclass.hxx" +#include "unotools/collatorwrapper.hxx" +#include "unotools/configitem.hxx" +#include "unotools/configmgr.hxx" +#include "unotools/confignode.hxx" +#include "unotools/configpathes.hxx" +#include "unotools/configvaluecontainer.hxx" +#include "unotools/localfilehelper.hxx" +#include "unotools/processfactory.hxx" +#include "comphelper/servicehelper.hxx" +#include "unotools/streamwrap.hxx" +#include "unotools/textsearch.hxx" +#include "unotools/transliterationwrapper.hxx" +#include "unotools/ucbhelper.hxx" +#include "vcl/abstdlg.hxx" +#include "vcl/animate.hxx" +#include "vcl/bitmap.hxx" +#include "vcl/bitmapex.hxx" +#include "vcl/bmpacc.hxx" +#include "vcl/cmdevt.h" +#include "vcl/configsettings.hxx" +#include "vcl/controllayout.hxx" +#include "vcl/cursor.hxx" +#include "vcl/decoview.hxx" +#include "vcl/dndhelp.hxx" +#include "vcl/fldunit.hxx" +#include "vcl/fntstyle.hxx" +#include "unotools/fontcvt.hxx" +#include "vcl/gdimtf.hxx" +#include "vcl/help.hxx" +#include "vcl/image.hxx" +#include "vcl/jobset.hxx" +#include "vcl/keycodes.hxx" +#include "vcl/mapmod.hxx" +#include "vcl/menu.hxx" +#include "vcl/mnemonic.hxx" +#include "vcl/pointr.hxx" +#include "vcl/region.hxx" +#include "vcl/salbtype.hxx" +#include "vcl/stdtext.hxx" +#include "vcl/timer.hxx" +#include "vcl/unohelp.hxx" +#include "vcl/unohelp2.hxx" +#include "vcl/wall.hxx" +#include "vcl/wintypes.hxx" +#include "vos/mutex.hxx" +#include "vos/ref.hxx" +#include "vos/refernce.hxx" +#include "vos/thread.hxx" +#include "vos/xception.hxx" +#include "xmloff/DashStyle.hxx" +#include "xmloff/GradientStyle.hxx" +#include "xmloff/HatchStyle.hxx" +#include "xmloff/ImageStyle.hxx" +#include "xmloff/MarkerStyle.hxx" +#include "xmloff/attrlist.hxx" +#include "xmloff/nmspmap.hxx" +#include "xmloff/xmlcnimp.hxx" +#include "xmloff/xmlictxt.hxx" +#include "xmloff/xmlnmspe.hxx" +#include "xmloff/xmlstyle.hxx" +#include "xmloff/xmltoken.hxx" +#include "xmlscript/xmldlg_imexp.hxx" +//---MARKER--- +#endif +#endif diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx index 13d5bff7e580..4b955b653cd4 100644 --- a/cui/source/customize/acccfg.cxx +++ b/cui/source/customize/acccfg.cxx @@ -34,10 +34,10 @@ #include <dialmgr.hxx> #include <sfx2/msg.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/app.hxx> #include <sfx2/filedlghelper.hxx> #include <sfx2/minfitem.hxx> +#include <sfx2/sfxresid.hxx> #include <svl/stritem.hxx> #include <sal/macros.h> @@ -109,7 +109,7 @@ static ::rtl::OUString MEDIATYPE_PROPNAME (RTL_CONSTASCII_USTRINGP static ::rtl::OUString MEDIATYPE_UICONFIG (RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.xml.ui.configuration" )); //----------------------------------------------- -static USHORT KEYCODE_ARRAY[] = +static sal_uInt16 KEYCODE_ARRAY[] = { KEY_F1 , KEY_F2 , @@ -616,7 +616,7 @@ static USHORT KEYCODE_ARRAY[] = KEY_DELETE | KEY_SHIFT | KEY_MOD1 | KEY_MOD2 }; -static USHORT KEYCODE_ARRAY_SIZE = SAL_N_ELEMENTS(KEYCODE_ARRAY); +static sal_uInt16 KEYCODE_ARRAY_SIZE = SAL_N_ELEMENTS(KEYCODE_ARRAY); //----------------------------------------------- // seems to be needed to layout the list box, which shows all @@ -633,20 +633,20 @@ class SfxAccCfgLBoxString_Impl : public SvLBoxString { public: SfxAccCfgLBoxString_Impl( SvLBoxEntry* pEntry, - USHORT nFlags, + sal_uInt16 nFlags, const String& sText ); virtual ~SfxAccCfgLBoxString_Impl(); virtual void Paint(const Point& aPos , SvLBox& rDevice, - USHORT nFlags , + sal_uInt16 nFlags , SvLBoxEntry* pEntry ); }; //----------------------------------------------- SfxAccCfgLBoxString_Impl::SfxAccCfgLBoxString_Impl( SvLBoxEntry* pEntry, - USHORT nFlags, + sal_uInt16 nFlags, const String& sText ) : SvLBoxString(pEntry, nFlags, sText) { @@ -660,7 +660,7 @@ SfxAccCfgLBoxString_Impl::~SfxAccCfgLBoxString_Impl() //----------------------------------------------- void SfxAccCfgLBoxString_Impl::Paint(const Point& aPos , SvLBox& rDevice, - USHORT /*nFlags*/, + sal_uInt16 /*nFlags*/, SvLBoxEntry* pEntry ) { @@ -695,8 +695,8 @@ void SfxAccCfgTabListBox_Impl::InitEntry( SvLBoxEntry* pEntry , void SfxAccCfgTabListBox_Impl::KeyInput(const KeyEvent& aKey) { KeyCode aCode1 = aKey.GetKeyCode(); - USHORT nCode1 = aCode1.GetCode(); - USHORT nMod1 = aCode1.GetModifier(); + sal_uInt16 nCode1 = aCode1.GetCode(); + sal_uInt16 nMod1 = aCode1.GetModifier(); // is it related to our list box ? if ( @@ -714,8 +714,8 @@ void SfxAccCfgTabListBox_Impl::KeyInput(const KeyEvent& aKey) TAccInfo* pUserData = (TAccInfo*)pEntry->GetUserData(); if (pUserData) { - USHORT nCode2 = pUserData->m_aKey.GetCode(); - USHORT nMod2 = pUserData->m_aKey.GetModifier(); + sal_uInt16 nCode2 = pUserData->m_aKey.GetCode(); + sal_uInt16 nMod2 = pUserData->m_aKey.GetModifier(); if ( (nCode1 == nCode2) && (nMod1 == nMod2 ) @@ -759,7 +759,6 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( Window* pParent, const SfxIt , aResetButton (this , CUI_RES(BTN_RESET )) , aLoadAccelConfigStr ( CUI_RES( STR_LOADACCELCONFIG ) ) , aSaveAccelConfigStr ( CUI_RES( STR_SAVEACCELCONFIG ) ) - , aFilterAllStr ( CUI_RES( STR_SFX_FILTERNAME_ALL ) ) , aFilterCfgStr ( CUI_RES( STR_FILTERNAME_CFG ) ) , m_bStylesInfoInitialized(sal_False) , m_xGlobal () @@ -768,6 +767,8 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( Window* pParent, const SfxIt { FreeResource(); + aFilterAllStr = String( SfxResId( STR_SFX_FILTERNAME_ALL ) ); + // install handler functions aChangeButton.SetClickHdl( LINK( this, SfxAcceleratorConfigPage, ChangeHdl )); aRemoveButton.SetClickHdl( LINK( this, SfxAcceleratorConfigPage, RemoveHdl )); @@ -782,7 +783,7 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( Window* pParent, const SfxIt aModuleButton.SetClickHdl( LINK( this, SfxAcceleratorConfigPage, RadioHdl )); // initialize Entriesbox - aEntriesBox.SetWindowBits(WB_HSCROLL|WB_CLIPCHILDREN); + aEntriesBox.SetStyle(aEntriesBox.GetStyle()|WB_HSCROLL|WB_CLIPCHILDREN); aEntriesBox.SetSelectionMode(SINGLE_SELECTION); aEntriesBox.SetTabs(&AccCfgTabs[0], MAP_APPFONT); aEntriesBox.Resize(); // OS: Hack for right selection @@ -791,7 +792,7 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( Window* pParent, const SfxIt // detect max keyname width long nMaxWidth = 0; - for ( USHORT i = 0; i < KEYCODE_ARRAY_SIZE; ++i ) + for ( sal_uInt16 i = 0; i < KEYCODE_ARRAY_SIZE; ++i ) { long nTmp = GetTextWidth( KeyCode( KEYCODE_ARRAY[i] ).GetName() ); if ( nTmp > nMaxWidth ) @@ -806,7 +807,7 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( Window* pParent, const SfxIt pGroupLBox->SetFunctionListBox(pFunctionBox); // initialize KeyBox - aKeyBox.SetWindowBits(WB_CLIPCHILDREN|WB_HSCROLL|WB_SORT); + aKeyBox.SetStyle(aKeyBox.GetStyle()|WB_CLIPCHILDREN|WB_HSCROLL|WB_SORT); } //----------------------------------------------- @@ -924,9 +925,9 @@ void SfxAcceleratorConfigPage::Init(const css::uno::Reference< css::ui::XAcceler // Insert all editable accelerators into list box. It is possible // that some accelerators are not mapped on the current system/keyboard // but we don't want to lose these mappings. - USHORT c1 = KEYCODE_ARRAY_SIZE; - USHORT i1 = 0; - USHORT nListPos = 0; + sal_uInt16 c1 = KEYCODE_ARRAY_SIZE; + sal_uInt16 i1 = 0; + sal_uInt16 nListPos = 0; for (i1=0; i1<c1; ++i1) { KeyCode aKey = KEYCODE_ARRAY[i1]; @@ -942,7 +943,7 @@ void SfxAcceleratorConfigPage::Init(const css::uno::Reference< css::ui::XAcceler css::uno::Sequence< css::awt::KeyEvent > lKeys = xAccMgr->getAllKeyEvents(); sal_Int32 c2 = lKeys.getLength(); sal_Int32 i2 = 0; - USHORT nCol = aEntriesBox.TabCount()-1; + sal_uInt16 nCol = aEntriesBox.TabCount()-1; for (i2=0; i2<c2; ++i2) { @@ -950,7 +951,7 @@ void SfxAcceleratorConfigPage::Init(const css::uno::Reference< css::ui::XAcceler ::rtl::OUString sCommand = xAccMgr->getCommandByKeyEvent(aAWTKey); String sLabel = GetLabel4Command(sCommand); KeyCode aKeyCode = ::svt::AcceleratorExecute::st_AWTKey2VCLKey(aAWTKey); - USHORT nPos = MapKeyCodeToPos(aKeyCode); + sal_uInt16 nPos = MapKeyCodeToPos(aKeyCode); if (nPos == LISTBOX_ENTRY_NOTFOUND) continue; @@ -966,12 +967,12 @@ void SfxAcceleratorConfigPage::Init(const css::uno::Reference< css::ui::XAcceler } // Map the VCL hardcoded key codes and mark them as not changeable - ULONG c3 = Application::GetReservedKeyCodeCount(); - ULONG i3 = 0; + sal_uLong c3 = Application::GetReservedKeyCodeCount(); + sal_uLong i3 = 0; for (i3=0; i3<c3; ++i3) { const KeyCode* pKeyCode = Application::GetReservedKeyCode(i3); - USHORT nPos = MapKeyCodeToPos(*pKeyCode); + sal_uInt16 nPos = MapKeyCodeToPos(*pKeyCode); if (nPos == LISTBOX_ENTRY_NOTFOUND) continue; @@ -1051,10 +1052,10 @@ IMPL_LINK(SfxAcceleratorConfigPage, Default, PushButton*, EMPTYARG) if (xReset.is()) xReset->reset(); - aEntriesBox.SetUpdateMode(FALSE); + aEntriesBox.SetUpdateMode(sal_False); ResetConfig(); Init(m_xAct); - aEntriesBox.SetUpdateMode(TRUE); + aEntriesBox.SetUpdateMode(sal_True); aEntriesBox.Invalidate(); aEntriesBox.Select(aEntriesBox.GetEntry(0, 0)); @@ -1064,7 +1065,7 @@ IMPL_LINK(SfxAcceleratorConfigPage, Default, PushButton*, EMPTYARG) //----------------------------------------------- IMPL_LINK( SfxAcceleratorConfigPage, ChangeHdl, Button*, EMPTYARG ) { - USHORT nPos = (USHORT) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); + sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData(); String sNewCommand = pFunctionBox->GetCurCommand(); String sLabel = pFunctionBox->GetCurLabel(); @@ -1072,7 +1073,7 @@ IMPL_LINK( SfxAcceleratorConfigPage, ChangeHdl, Button*, EMPTYARG ) sLabel = GetLabel4Command(sNewCommand); pEntry->m_sCommand = sNewCommand; - USHORT nCol = aEntriesBox.TabCount() - 1; + sal_uInt16 nCol = aEntriesBox.TabCount() - 1; aEntriesBox.SetEntryText(sLabel, nPos, nCol); ((Link &) pFunctionBox->GetSelectHdl()).Call( pFunctionBox ); @@ -1083,11 +1084,11 @@ IMPL_LINK( SfxAcceleratorConfigPage, ChangeHdl, Button*, EMPTYARG ) IMPL_LINK( SfxAcceleratorConfigPage, RemoveHdl, Button *, EMPTYARG ) { // get selected entry - USHORT nPos = (USHORT) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); + sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData(); // remove function name from selected entry - USHORT nCol = aEntriesBox.TabCount() - 1; + sal_uInt16 nCol = aEntriesBox.TabCount() - 1; aEntriesBox.SetEntryText( String(), nPos, nCol ); pEntry->m_sCommand = ::rtl::OUString(); @@ -1102,17 +1103,17 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox ) Help::ShowBalloon( this, Point(), String() ); if ( pListBox == &aEntriesBox ) { - USHORT nPos = (USHORT) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); + sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( aEntriesBox.FirstSelected() ); TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData(); ::rtl::OUString sPossibleNewCommand = pFunctionBox->GetCurCommand(); - aRemoveButton.Enable( FALSE ); - aChangeButton.Enable( FALSE ); + aRemoveButton.Enable( sal_False ); + aChangeButton.Enable( sal_False ); if (pEntry->m_bIsConfigurable) { if (pEntry->isConfigured()) - aRemoveButton.Enable( TRUE ); + aRemoveButton.Enable( sal_True ); aChangeButton.Enable( pEntry->m_sCommand != sPossibleNewCommand ); } } @@ -1120,25 +1121,25 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox ) { pGroupLBox->GroupSelected(); if ( !pFunctionBox->FirstSelected() ) - aChangeButton.Enable( FALSE ); + aChangeButton.Enable( sal_False ); } else if ( pListBox == pFunctionBox ) { - aRemoveButton.Enable( FALSE ); - aChangeButton.Enable( FALSE ); + aRemoveButton.Enable( sal_False ); + aChangeButton.Enable( sal_False ); // #i36994 First selected can return zero! SvLBoxEntry* pLBEntry = aEntriesBox.FirstSelected(); if ( pLBEntry != 0 ) { - USHORT nPos = (USHORT) aEntriesBox.GetModel()->GetRelPos( pLBEntry ); + sal_uInt16 nPos = (sal_uInt16) aEntriesBox.GetModel()->GetRelPos( pLBEntry ); TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData(); ::rtl::OUString sPossibleNewCommand = pFunctionBox->GetCurCommand(); if (pEntry->m_bIsConfigurable) { if (pEntry->isConfigured()) - aRemoveButton.Enable( TRUE ); + aRemoveButton.Enable( sal_True ); aChangeButton.Enable( pEntry->m_sCommand != sPossibleNewCommand ); } @@ -1151,9 +1152,9 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox ) if ( pUserData && pUserData->m_sCommand == sPossibleNewCommand ) { TAccInfo* pU1 = new TAccInfo(-1, -1, pUserData->m_aKey); - SvLBoxEntry* pE1 = aKeyBox.InsertEntry( pUserData->m_aKey.GetName(), 0L, TRUE, LIST_APPEND ); + SvLBoxEntry* pE1 = aKeyBox.InsertEntry( pUserData->m_aKey.GetName(), 0L, sal_True, LIST_APPEND ); pE1->SetUserData(pU1); - pE1->EnableChildsOnDemand( FALSE ); + pE1->EnableChildsOnDemand( sal_False ); } pIt = aEntriesBox.Next(pIt); } @@ -1164,7 +1165,7 @@ IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, Control*, pListBox ) // goto selected "key" entry of the key box SvLBoxEntry* pE2 = 0; TAccInfo* pU2 = 0; - USHORT nP2 = LISTBOX_ENTRY_NOTFOUND; + sal_uInt16 nP2 = LISTBOX_ENTRY_NOTFOUND; SvLBoxEntry* pE3 = 0; pE2 = aKeyBox.FirstSelected(); @@ -1198,10 +1199,10 @@ IMPL_LINK( SfxAcceleratorConfigPage, RadioHdl, RadioButton *, EMPTYARG ) if ( m_xAct.is() && ( xOld == m_xAct ) ) return 0; - aEntriesBox.SetUpdateMode( FALSE ); + aEntriesBox.SetUpdateMode( sal_False ); ResetConfig(); Init(m_xAct); - aEntriesBox.SetUpdateMode( TRUE ); + aEntriesBox.SetUpdateMode( sal_True ); aEntriesBox.Invalidate(); pGroupLBox->Init(m_xSMGR, m_xFrame, m_sModuleLongName); @@ -1270,10 +1271,10 @@ IMPL_LINK( SfxAcceleratorConfigPage, LoadHdl, sfx2::FileDialogHelper*, EMPTYARG // open the configuration and update our UI css::uno::Reference< css::ui::XAcceleratorConfiguration > xTempAccMgr(xCfgMgr->getShortCutManager(), css::uno::UNO_QUERY_THROW); - aEntriesBox.SetUpdateMode(FALSE); + aEntriesBox.SetUpdateMode(sal_False); ResetConfig(); Init(xTempAccMgr); - aEntriesBox.SetUpdateMode(TRUE); + aEntriesBox.SetUpdateMode(sal_True); aEntriesBox.Invalidate(); aEntriesBox.Select(aEntriesBox.GetEntry(0, 0)); @@ -1404,134 +1405,6 @@ IMPL_LINK( SfxAcceleratorConfigPage, SaveHdl, sfx2::FileDialogHelper*, EMPTYARG return 0; } -::rtl::OUString RetrieveLabelFromCommand( const ::rtl::OUString& aCmdURL ) -{ - ::rtl::OUString aLabel; - if ( aCmdURL.getLength() ) - { - try - { - uno::Reference< container::XNameAccess > xNameAccess( ::comphelper::getProcessServiceFactory()->createInstance( - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.UICommandDescription") ) ), uno::UNO_QUERY ); - if ( xNameAccess.is() ) - { - uno::Reference< container::XNameAccess > xUICommandLabels; - const ::rtl::OUString aModule( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.text.TextDocument" ) ); - uno::Any a = xNameAccess->getByName( aModule ); - uno::Reference< container::XNameAccess > xUICommands; - a >>= xUICommandLabels; - rtl::OUString aStr; - uno::Sequence< beans::PropertyValue > aPropSeq; - a = xUICommandLabels->getByName( aCmdURL ); - if ( a >>= aPropSeq ) - { - for ( sal_Int32 i = 0; i < aPropSeq.getLength(); ++i ) - { - if ( aPropSeq[i].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Name" ) )) - { - aPropSeq[i].Value >>= aStr; - break; - } - } - } - aLabel = aStr; - } - } - catch ( uno::Exception& ) - { - } - } - - return aLabel; -} - - -//----------------------------------------------- -String SfxAcceleratorConfigPage::GetFunctionName(KeyFuncType eType) const -{ - ::rtl::OUStringBuffer sName(256); - sName.appendAscii("\""); - switch(eType) - { - case KEYFUNC_NEW : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:NewDoc") ) ) ); - break; - - case KEYFUNC_OPEN : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Open") ) ) ); - break; - - case KEYFUNC_SAVE : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Save") ) ) ); - break; - - case KEYFUNC_SAVEAS : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:SaveAs") ) ) ); - break; - - case KEYFUNC_PRINT : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Print") ) ) ); - break; - - case KEYFUNC_CLOSE : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Close") ) ) ); - break; - - case KEYFUNC_QUIT : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Quit") ) ) ); - break; - - case KEYFUNC_CUT : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Cut") ) ) ); - break; - - case KEYFUNC_COPY : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Copy") ) ) ); - break; - - case KEYFUNC_PASTE : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Paste") ) ) ); - break; - - case KEYFUNC_UNDO : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Undo") ) ) ); - break; - - case KEYFUNC_REDO : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Redo") ) ) ); - break; - - case KEYFUNC_DELETE : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Delete") ) ) ); - break; - - case KEYFUNC_REPEAT : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Repeat") ) ) ); - break; - - case KEYFUNC_FIND : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Search") ) ) ); - break; - - case KEYFUNC_FINDBACKWARD : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:SearchBackwards") ) ) ); - break; - - case KEYFUNC_PROPERTIES : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Options") ) ) ); - break; - - case KEYFUNC_FRONT : - sName.append( RetrieveLabelFromCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:ToFront") ) ) ); - break; - - default: - break; - } - sName.appendAscii("\""); - return String(sName.makeStringAndClear()); -} - //----------------------------------------------- void SfxAcceleratorConfigPage::StartFileDialog( WinBits nBits, const String& rTitle ) { @@ -1552,7 +1425,7 @@ void SfxAcceleratorConfigPage::StartFileDialog( WinBits nBits, const String& rTi } //----------------------------------------------- -BOOL SfxAcceleratorConfigPage::FillItemSet( SfxItemSet& ) +sal_Bool SfxAcceleratorConfigPage::FillItemSet( SfxItemSet& ) { Apply(m_xAct); try @@ -1562,9 +1435,9 @@ BOOL SfxAcceleratorConfigPage::FillItemSet( SfxItemSet& ) catch(const css::uno::RuntimeException& exRun) { throw exRun; } catch(const css::uno::Exception&) - { return FALSE; } + { return sal_False; } - return TRUE; + return sal_True; } //----------------------------------------------- @@ -1592,7 +1465,7 @@ void SfxAcceleratorConfigPage::Reset( const SfxItemSet& rSet ) RadioHdl(0); const SfxPoolItem* pMacroItem=0; - if( SFX_ITEM_SET == rSet.GetItemState( SID_MACROINFO, TRUE, &pMacroItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( SID_MACROINFO, sal_True, &pMacroItem ) ) { m_pMacroInfoItem = PTR_CAST( SfxMacroInfoItem, pMacroItem ); pGroupLBox->SelectMacro( m_pMacroInfoItem ); @@ -1600,62 +1473,28 @@ void SfxAcceleratorConfigPage::Reset( const SfxItemSet& rSet ) else { const SfxPoolItem* pStringItem=0; - if( SFX_ITEM_SET == rSet.GetItemState( SID_CHARMAP, TRUE, &pStringItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( SID_CHARMAP, sal_True, &pStringItem ) ) m_pStringItem = PTR_CAST( SfxStringItem, pStringItem ); const SfxPoolItem* pFontItem=0; - if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_SPECIALCHAR, TRUE, &pFontItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_SPECIALCHAR, sal_True, &pFontItem ) ) m_pFontItem = PTR_CAST( SfxStringItem, pFontItem ); - - if ( m_pStringItem ) - pGroupLBox->AddAndSelect( m_pStringItem, m_pFontItem ); - } -} - -//----------------------------------------------- -void SfxAcceleratorConfigPage::SelectMacro(const SfxMacroInfoItem *pItem) -{ - m_pMacroInfoItem = pItem; - pGroupLBox->SelectMacro( pItem ); -} - -//----------------------------------------------- -void SfxAcceleratorConfigPage::CopySource2Target(const css::uno::Reference< css::ui::XAcceleratorConfiguration >& xSourceAccMgr, - const css::uno::Reference< css::ui::XAcceleratorConfiguration >& xTargetAccMgr) -{ - const css::uno::Sequence< css::awt::KeyEvent > lKeys = xSourceAccMgr->getAllKeyEvents(); - sal_Int32 c = lKeys.getLength(); - sal_Int32 i = 0; - for (i=0; i<c; ++i) - { - const css::awt::KeyEvent& rKey = lKeys[i]; - ::rtl::OUString sCommand = xSourceAccMgr->getCommandByKeyEvent(rKey); - xTargetAccMgr->setKeyEvent(rKey, sCommand); } } //----------------------------------------------- -KeyCode SfxAcceleratorConfigPage::MapPosToKeyCode(USHORT nPos) const -{ - TAccInfo* pEntry = (TAccInfo*)aEntriesBox.GetEntry(0, nPos)->GetUserData(); - KeyCode aCode(KEYCODE_ARRAY[pEntry->m_nKeyPos] & 0xFFF , - KEYCODE_ARRAY[pEntry->m_nKeyPos] & (KEY_SHIFT | KEY_MOD2)); - return aCode; -} - -//----------------------------------------------- -USHORT SfxAcceleratorConfigPage::MapKeyCodeToPos(const KeyCode& aKey) const +sal_uInt16 SfxAcceleratorConfigPage::MapKeyCodeToPos(const KeyCode& aKey) const { - USHORT nCode1 = aKey.GetCode()+aKey.GetModifier(); + sal_uInt16 nCode1 = aKey.GetCode()+aKey.GetModifier(); SvLBoxEntry* pEntry = aEntriesBox.First(); - USHORT i = 0; + sal_uInt16 i = 0; while (pEntry) { TAccInfo* pUserData = (TAccInfo*)pEntry->GetUserData(); if (pUserData) { - USHORT nCode2 = pUserData->m_aKey.GetCode()+pUserData->m_aKey.GetModifier(); + sal_uInt16 nCode2 = pUserData->m_aKey.GetCode()+pUserData->m_aKey.GetModifier(); if (nCode1 == nCode2) return i; } diff --git a/cui/source/customize/acccfg.hrc b/cui/source/customize/acccfg.hrc index ccc583d62037..eaa39b11e97b 100644 --- a/cui/source/customize/acccfg.hrc +++ b/cui/source/customize/acccfg.hrc @@ -59,7 +59,7 @@ #define STR_PDF_EXPORT_SEND 59 #define STR_RECHECK_DOCUMENT 60 #define IMG_INFO 61 -#define STR_BASICNAME 62 + // FREE #define BMP_COLLAPSED 63 #define BMP_EXPANDED 64 #define STR_BASICMACROS 67 diff --git a/cui/source/customize/acccfg.src b/cui/source/customize/acccfg.src index c993aca90b90..7e8322fc6eef 100644 --- a/cui/source/customize/acccfg.src +++ b/cui/source/customize/acccfg.src @@ -67,18 +67,21 @@ TabPage RID_SVXPAGE_KEYBOARD Size = MAP_APPFONT ( 273 , 258 ) ; RadioButton RB_OFFICE { + HelpID = "cui:RadioButton:RID_SVXPAGE_KEYBOARD:RB_OFFICE"; Pos = MAP_APPFONT ( 192 , 6 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; Text = "%PRODUCTNAME" ; }; RadioButton RB_MODULE { + HelpID = "cui:RadioButton:RID_SVXPAGE_KEYBOARD:RB_MODULE"; Pos = MAP_APPFONT ( 192 , 19 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; Text = "$(MODULE)" ; }; PushButton BTN_ACC_CHANGE { + HelpID = "cui:PushButton:RID_SVXPAGE_KEYBOARD:BTN_ACC_CHANGE"; Pos = MAP_APPFONT ( 192 , 35 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -86,6 +89,7 @@ TabPage RID_SVXPAGE_KEYBOARD }; PushButton BTN_ACC_REMOVE { + HelpID = "cui:PushButton:RID_SVXPAGE_KEYBOARD:BTN_ACC_REMOVE"; Pos = MAP_APPFONT ( 192 , 52 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -162,6 +166,7 @@ TabPage RID_SVXPAGE_KEYBOARD }; PushButton BTN_LOAD { + HelpID = "cui:PushButton:RID_SVXPAGE_KEYBOARD:BTN_LOAD"; Pos = MAP_APPFONT ( 192 , 86 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -170,6 +175,7 @@ TabPage RID_SVXPAGE_KEYBOARD }; PushButton BTN_SAVE { + HelpID = "cui:PushButton:RID_SVXPAGE_KEYBOARD:BTN_SAVE"; Pos = MAP_APPFONT ( 192 , 103 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -178,6 +184,7 @@ TabPage RID_SVXPAGE_KEYBOARD }; PushButton BTN_RESET { + HelpID = "cui:PushButton:RID_SVXPAGE_KEYBOARD:BTN_RESET"; Pos = MAP_APPFONT ( 192 , 120 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -192,10 +199,6 @@ TabPage RID_SVXPAGE_KEYBOARD { Text [ en-US ] = "Save Keyboard Configuration" ; }; - String STR_SFX_FILTERNAME_ALL - { - Text [ en-US ] = "All files (*.*)" ; - }; String STR_FILTERNAME_CFG { Text [ en-US ] = "Configuration" ; @@ -248,9 +251,6 @@ Resource RID_SVXPAGE_CONFIGGROUPBOX ImageBitmap = Bitmap { File = "im30826.png"; }; MASKCOLOR }; - String STR_BASICNAME - { - Text = "%PRODUCTNAME Basic" ; }; Image BMP_COLLAPSED { diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx index 99cb2445acc7..7ab975de6ce2 100644 --- a/cui/source/customize/cfg.cxx +++ b/cui/source/customize/cfg.cxx @@ -42,7 +42,6 @@ #include <sfx2/msg.hxx> #include <sfx2/msgpool.hxx> #include <sfx2/mnumgr.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/minfitem.hxx> #include <sfx2/objsh.hxx> #include <sfx2/request.hxx> @@ -95,7 +94,6 @@ #define ENTRY_HEIGHT 16 static const char ITEM_DESCRIPTOR_COMMANDURL[] = "CommandURL"; -static const char ITEM_DESCRIPTOR_HELPURL[] = "HelpURL"; static const char ITEM_DESCRIPTOR_CONTAINER[] = "ItemDescriptorContainer"; static const char ITEM_DESCRIPTOR_LABEL[] = "Label"; static const char ITEM_DESCRIPTOR_TYPE[] = "Type"; @@ -127,6 +125,8 @@ namespace container = com::sun::star::container; namespace beans = com::sun::star::beans; namespace graphic = com::sun::star::graphic; +#if OSL_DEBUG_LEVEL > 1 + void printPropertySet( const OUString& prefix, const uno::Reference< beans::XPropertySet >& xPropSet ) @@ -191,6 +191,8 @@ void printEntries(SvxEntries* entries) } } +#endif + OUString stripHotKey( const OUString& str ) { @@ -407,9 +409,9 @@ SvxConfigPage::CanConfig( const OUString& aModuleId ) || aModuleId.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.frame.Bibliography" ) ) ) { - return FALSE; + return sal_False; } - return TRUE; + return sal_True; } OUString GetModuleName( const OUString& aModuleId ) @@ -490,7 +492,6 @@ bool GetMenuItemData( const uno::Reference< container::XIndexAccess >& rItemContainer, sal_Int32 nIndex, OUString& rCommandURL, - OUString& rHelpURL, OUString& rLabel, sal_uInt16& rType, uno::Reference< container::XIndexAccess >& rSubMenu ) @@ -506,10 +507,6 @@ bool GetMenuItemData( { aProp[i].Value >>= rCommandURL; } - else if ( aProp[i].Name.equalsAscii( ITEM_DESCRIPTOR_HELPURL )) - { - aProp[i].Value >>= rHelpURL; - } else if ( aProp[i].Name.equalsAscii( ITEM_DESCRIPTOR_CONTAINER )) { aProp[i].Value >>= rSubMenu; @@ -524,21 +521,20 @@ bool GetMenuItemData( } } - return TRUE; + return sal_True; } } catch ( ::com::sun::star::lang::IndexOutOfBoundsException& ) { } - return FALSE; + return sal_False; } bool GetToolbarItemData( const uno::Reference< container::XIndexAccess >& rItemContainer, sal_Int32 nIndex, OUString& rCommandURL, - OUString& rHelpURL, OUString& rLabel, sal_uInt16& rType, sal_Bool& rIsVisible, @@ -560,10 +556,6 @@ bool GetToolbarItemData( { aProp[i].Value >>= rStyle; } - else if ( aProp[i].Name.equalsAscii( ITEM_DESCRIPTOR_HELPURL )) - { - aProp[i].Value >>= rHelpURL; - } else if (aProp[i].Name.equalsAscii(ITEM_DESCRIPTOR_CONTAINER)) { aProp[i].Value >>= rSubMenu; @@ -606,13 +598,10 @@ ConvertSvxConfigEntry( static const OUString aDescriptorLabel( RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_LABEL ) ); - static const OUString aDescriptorHelpURL( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_HELPURL ) ); - static const OUString aDescriptorContainer( RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_CONTAINER ) ); - uno::Sequence< beans::PropertyValue > aPropSeq( 4 ); + uno::Sequence< beans::PropertyValue > aPropSeq( 3 ); aPropSeq[0].Name = aDescriptorCommandURL; aPropSeq[0].Value <<= rtl::OUString( pEntry->GetCommand() ); @@ -625,9 +614,9 @@ ConvertSvxConfigEntry( // as an empty string. // It will be initialised again later using the command to label map. aPropSeq[2].Name = aDescriptorLabel; - if ( pEntry->HasChangedName() == FALSE && pEntry->GetCommand().getLength() ) + if ( pEntry->HasChangedName() == sal_False && pEntry->GetCommand().getLength() ) { - BOOL isDefaultName = FALSE; + sal_Bool isDefaultName = sal_False; try { uno::Any a( xCommandToLabelMap->getByName( pEntry->GetCommand() ) ); @@ -643,7 +632,7 @@ ConvertSvxConfigEntry( if ( tmpLabel.equals( pEntry->GetName() ) ) { - isDefaultName = TRUE; + isDefaultName = sal_True; } break; @@ -670,9 +659,6 @@ ConvertSvxConfigEntry( aPropSeq[2].Value <<= rtl::OUString( pEntry->GetName() ); } - aPropSeq[3].Name = aDescriptorHelpURL; - aPropSeq[3].Value <<= rtl::OUString( pEntry->GetHelpURL() ); - return aPropSeq; } @@ -690,16 +676,13 @@ ConvertToolbarEntry( static const OUString aDescriptorLabel( RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_LABEL ) ); - static const OUString aDescriptorHelpURL( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_HELPURL ) ); - static const OUString aDescriptorContainer( RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_CONTAINER ) ); static const OUString aIsVisible( RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_ISVISIBLE ) ); - uno::Sequence< beans::PropertyValue > aPropSeq( 5 ); + uno::Sequence< beans::PropertyValue > aPropSeq( 4 ); aPropSeq[0].Name = aDescriptorCommandURL; aPropSeq[0].Value <<= rtl::OUString( pEntry->GetCommand() ); @@ -712,9 +695,9 @@ ConvertToolbarEntry( // as an empty string. // It will be initialised again later using the command to label map. aPropSeq[2].Name = aDescriptorLabel; - if ( pEntry->HasChangedName() == FALSE && pEntry->GetCommand().getLength() ) + if ( pEntry->HasChangedName() == sal_False && pEntry->GetCommand().getLength() ) { - BOOL isDefaultName = FALSE; + sal_Bool isDefaultName = sal_False; try { uno::Any a( xCommandToLabelMap->getByName( pEntry->GetCommand() ) ); @@ -730,7 +713,7 @@ ConvertToolbarEntry( if ( tmpLabel.equals( pEntry->GetName() ) ) { - isDefaultName = TRUE; + isDefaultName = sal_True; } break; @@ -757,11 +740,8 @@ ConvertToolbarEntry( aPropSeq[2].Value <<= rtl::OUString( pEntry->GetName() ); } - aPropSeq[3].Name = aDescriptorHelpURL; - aPropSeq[3].Value <<= rtl::OUString( pEntry->GetHelpURL() ); - - aPropSeq[4].Name = aIsVisible; - aPropSeq[4].Value <<= pEntry->IsVisible(); + aPropSeq[3].Name = aIsVisible; + aPropSeq[3].Value <<= pEntry->IsVisible(); return aPropSeq; } @@ -867,7 +847,7 @@ short SvxConfigDialog::Ok() return SfxTabDialog::Ok(); } -void SvxConfigDialog::PageCreated( USHORT nId, SfxTabPage& rPage ) +void SvxConfigDialog::PageCreated( sal_uInt16 nId, SfxTabPage& rPage ) { (void)rPage; @@ -890,11 +870,6 @@ void SvxConfigDialog::PageCreated( USHORT nId, SfxTabPage& rPage ) } } -void SvxConfigDialog::ActivateTabPage( USHORT nSlotId ) -{ - (void)nSlotId; -} - /****************************************************************************** * * The SaveInData class is used to hold data for entries in the Save In @@ -911,9 +886,9 @@ SaveInData::SaveInData( const OUString& aModuleId, bool isDocConfig ) : - bModified( FALSE ), + bModified( sal_False ), bDocConfig( isDocConfig ), - bReadOnly( FALSE ), + bReadOnly( sal_False ), m_xCfgMgr( xCfgMgr ), m_xParentCfgMgr( xParentCfgMgr ) { @@ -1035,7 +1010,7 @@ Image SaveInData::GetImage( const OUString& rCommandURL ) bool SaveInData::PersistChanges( const uno::Reference< uno::XInterface >& xManager ) { - bool result = TRUE; + bool result = sal_True; try { @@ -1052,7 +1027,7 @@ bool SaveInData::PersistChanges( } catch ( com::sun::star::io::IOException& ) { - result = FALSE; + result = sal_False; } return result; @@ -1115,7 +1090,7 @@ MenuSaveInData::GetEntries() if ( pRootEntry == NULL ) { pRootEntry = new SvxConfigEntry( - String::CreateFromAscii("MainMenus"), String(), TRUE ); + String::CreateFromAscii("MainMenus"), String(), sal_True ); if ( m_xMenuSettings.is() ) { @@ -1159,14 +1134,13 @@ bool MenuSaveInData::LoadSubMenus( { uno::Reference< container::XIndexAccess > xSubMenu; OUString aCommandURL; - OUString aHelpURL; OUString aLabel; - bool bIsUserDefined = TRUE; + bool bIsUserDefined = sal_True; sal_uInt16 nType( css::ui::ItemType::DEFAULT ); bool bItem = GetMenuItemData( xMenuSettings, nIndex, - aCommandURL, aHelpURL, aLabel, nType, xSubMenu ); + aCommandURL, aLabel, nType, xSubMenu ); if ( bItem ) { @@ -1176,11 +1150,11 @@ bool MenuSaveInData::LoadSubMenus( try { a = m_xCommandToLabelMap->getByName( aCommandURL ); - bIsUserDefined = FALSE; + bIsUserDefined = sal_False; } catch ( container::NoSuchElementException& ) { - bIsUserDefined = TRUE; + bIsUserDefined = sal_True; } // If custom label not set retrieve it from the command @@ -1205,10 +1179,9 @@ bool MenuSaveInData::LoadSubMenus( { // popup menu SvxConfigEntry* pEntry = new SvxConfigEntry( - aLabel, aCommandURL, TRUE ); + aLabel, aCommandURL, sal_True ); pEntry->SetUserDefined( bIsUserDefined ); - pEntry->SetHelpURL( aHelpURL ); pEntries->push_back( pEntry ); @@ -1221,7 +1194,7 @@ bool MenuSaveInData::LoadSubMenus( } else { - pEntry->SetMain( TRUE ); + pEntry->SetMain( sal_True ); } subMenuTitle += stripHotKey( aLabel ); @@ -1231,9 +1204,8 @@ bool MenuSaveInData::LoadSubMenus( else { SvxConfigEntry* pEntry = new SvxConfigEntry( - aLabel, aCommandURL, FALSE ); + aLabel, aCommandURL, sal_False ); pEntry->SetUserDefined( bIsUserDefined ); - pEntry->SetHelpURL( aHelpURL ); pEntries->push_back( pEntry ); } } @@ -1250,7 +1222,7 @@ bool MenuSaveInData::LoadSubMenus( bool MenuSaveInData::Apply() { - bool result = FALSE; + bool result = sal_False; if ( IsModified() ) { @@ -1292,7 +1264,7 @@ bool MenuSaveInData::Apply() OSL_TRACE("caught some other exception saving settings"); } - SetModified( FALSE ); + SetModified( sal_False ); result = PersistChanges( GetConfigManager() ); } @@ -1408,7 +1380,7 @@ public: ~PopupPainter() { } void Paint( const Point& rPos, SvLBox& rOutDev, - USHORT nViewDataEntryFlags, SvLBoxEntry* pEntry ) + sal_uInt16 nViewDataEntryFlags, SvLBoxEntry* pEntry ) { SvLBoxString::Paint( rPos, rOutDev, nViewDataEntryFlags, pEntry ); @@ -1462,9 +1434,9 @@ SvxMenuEntriesListBox::SvxMenuEntriesListBox( Window* pParent, const ResId& rResId) : SvTreeListBox( pParent, rResId ) , pPage( (SvxMenuConfigPage*) pParent ) - , m_bIsInternalDrag( FALSE ) + , m_bIsInternalDrag( sal_False ) { - SetWindowBits( + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HIDESELECTION ); SetSpaceBetweenEntries( 3 ); @@ -1491,14 +1463,14 @@ DragDropMode SvxMenuEntriesListBox::NotifyStartDrag( (void)aTransferDataContainer; (void)pEntry; - m_bIsInternalDrag = TRUE; + m_bIsInternalDrag = sal_True; return GetDragDropMode(); } void SvxMenuEntriesListBox::DragFinished( sal_Int8 nDropAction ) { (void)nDropAction; - m_bIsInternalDrag = FALSE; + m_bIsInternalDrag = sal_False; } sal_Int8 SvxMenuEntriesListBox::AcceptDrop( const AcceptDropEvent& rEvt ) @@ -1518,27 +1490,27 @@ sal_Int8 SvxMenuEntriesListBox::AcceptDrop( const AcceptDropEvent& rEvt ) return SvTreeListBox::AcceptDrop( aNewAcceptDropEvent ); } -BOOL SvxMenuEntriesListBox::NotifyAcceptDrop( SvLBoxEntry* ) +sal_Bool SvxMenuEntriesListBox::NotifyAcceptDrop( SvLBoxEntry* ) { - return TRUE; + return sal_True; } -BOOL SvxMenuEntriesListBox::NotifyMoving( +sal_Bool SvxMenuEntriesListBox::NotifyMoving( SvLBoxEntry* pTarget, SvLBoxEntry* pSource, - SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos) + SvLBoxEntry*& rpNewParent, sal_uLong& rNewChildPos) { // only try to do a move if we are dragging within the list box if ( m_bIsInternalDrag ) { - if ( pPage->MoveEntryData( pSource, pTarget ) == TRUE ) + if ( pPage->MoveEntryData( pSource, pTarget ) == sal_True ) { SvTreeListBox::NotifyMoving( pTarget, pSource, rpNewParent, rNewChildPos ); - return TRUE; + return sal_True; } else { - return FALSE; + return sal_False; } } else @@ -1547,9 +1519,9 @@ BOOL SvxMenuEntriesListBox::NotifyMoving( } } -BOOL SvxMenuEntriesListBox::NotifyCopying( +sal_Bool SvxMenuEntriesListBox::NotifyCopying( SvLBoxEntry* pTarget, SvLBoxEntry* pSource, - SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos) + SvLBoxEntry*& rpNewParent, sal_uLong& rNewChildPos) { (void)pSource; (void)rpNewParent; @@ -1562,11 +1534,11 @@ BOOL SvxMenuEntriesListBox::NotifyCopying( // AddFunction already adds the listbox entry so return FALSE // to stop another listbox entry being added - return FALSE; + return sal_False; } // Copying is only allowed from external controls, not within the listbox - return FALSE; + return sal_False; } void SvxMenuEntriesListBox::KeyInput( const KeyEvent& rKeyEvent ) @@ -1581,11 +1553,11 @@ void SvxMenuEntriesListBox::KeyInput( const KeyEvent& rKeyEvent ) // support CTRL+UP and CTRL+DOWN for moving selected entries else if ( keycode.GetCode() == KEY_UP && keycode.IsMod1() ) { - pPage->MoveEntry( TRUE ); + pPage->MoveEntry( sal_True ); } else if ( keycode.GetCode() == KEY_DOWN && keycode.IsMod1() ) { - pPage->MoveEntry( FALSE ); + pPage->MoveEntry( sal_False ); } else { @@ -1643,7 +1615,7 @@ SvxConfigPage::SvxConfigPage( Window *pParent, const SfxItemSet& rSet ) : SfxTabPage( pParent, CUI_RES( RID_SVXPAGE_MENUS ), rSet ), - bInitialised( FALSE ), + bInitialised( sal_False ), pCurrentSaveInData( 0 ), aTopLevelSeparator( this, CUI_RES( GRP_MENUS ) ), aTopLevelLabel( this, CUI_RES( FT_MENUS ) ), @@ -1664,8 +1636,17 @@ SvxConfigPage::SvxConfigPage( pSelectorDlg( 0 ) { aDescriptionField.SetControlBackground( GetSettings().GetStyleSettings().GetDialogColor() ); - aDescriptionField.SetAutoScroll( TRUE ); - aDescriptionField.EnableCursor( FALSE ); + aDescriptionField.SetAutoScroll( sal_True ); + aDescriptionField.EnableCursor( sal_False ); + + aMoveUpButton.SetAccessibleName(String(CUI_RES(BUTTON_STR_UP))); + aMoveDownButton.SetAccessibleName(String(CUI_RES(BUTTON_STR_DOWN))); + aMoveUpButton.SetAccessibleRelationMemberOf(&aContentsSeparator); + aMoveDownButton.SetAccessibleRelationMemberOf(&aContentsSeparator); + aNewTopLevelButton.SetAccessibleRelationMemberOf(&aTopLevelSeparator); + aModifyTopLevelButton.SetAccessibleRelationMemberOf(&aTopLevelSeparator); + aAddCommandsButton.SetAccessibleRelationMemberOf(&aContentsSeparator); + aModifyCommandButton.SetAccessibleRelationMemberOf(&aContentsSeparator); } SvxConfigPage::~SvxConfigPage() @@ -1682,7 +1663,7 @@ void SvxConfigPage::Reset( const SfxItemSet& ) // all other open documents of the same module type if ( !bInitialised ) { - USHORT nPos = 0; + sal_uInt16 nPos = 0; uno::Reference < css::ui::XUIConfigurationManager > xCfgMgr; uno::Reference < css::ui::XUIConfigurationManager > xDocCfgMgr; @@ -1728,7 +1709,7 @@ void SvxConfigPage::Reset( const SfxItemSet& ) pModuleData = CreateSaveInData( xCfgMgr, uno::Reference< css::ui::XUIConfigurationManager >(), aModuleId, - FALSE ); + sal_False ); } catch ( container::NoSuchElementException& ) { @@ -1769,7 +1750,7 @@ void SvxConfigPage::Reset( const SfxItemSet& ) SaveInData* pDocData = NULL; if ( xDocCfgMgr.is() ) { - pDocData = CreateSaveInData( xDocCfgMgr, xCfgMgr, aModuleId, TRUE ); + pDocData = CreateSaveInData( xDocCfgMgr, xCfgMgr, aModuleId, sal_True ); if ( !pDocData->IsReadOnly() ) { @@ -1780,35 +1761,35 @@ void SvxConfigPage::Reset( const SfxItemSet& ) // if an item to select has been passed in (eg. the ResourceURL for a // toolbar) then try to select the SaveInData entry that has that item - bool bURLToSelectFound = FALSE; + bool bURLToSelectFound = sal_False; if ( m_aURLToSelect.getLength() != 0 ) { if ( pDocData != NULL && pDocData->HasURL( m_aURLToSelect ) ) { - aSaveInListBox.SelectEntryPos( nPos, TRUE ); + aSaveInListBox.SelectEntryPos( nPos, sal_True ); pCurrentSaveInData = pDocData; - bURLToSelectFound = TRUE; + bURLToSelectFound = sal_True; } else if ( pModuleData->HasURL( m_aURLToSelect ) ) { - aSaveInListBox.SelectEntryPos( 0, TRUE ); + aSaveInListBox.SelectEntryPos( 0, sal_True ); pCurrentSaveInData = pModuleData; - bURLToSelectFound = TRUE; + bURLToSelectFound = sal_True; } } - if ( bURLToSelectFound == FALSE ) + if ( bURLToSelectFound == sal_False ) { // if the document has menu configuration settings select it // it the SaveIn listbox, otherwise select the module data if ( pDocData != NULL && pDocData->HasSettings() ) { - aSaveInListBox.SelectEntryPos( nPos, TRUE ); + aSaveInListBox.SelectEntryPos( nPos, sal_True ); pCurrentSaveInData = pDocData; } else { - aSaveInListBox.SelectEntryPos( 0, TRUE ); + aSaveInListBox.SelectEntryPos( 0, sal_True ); pCurrentSaveInData = pModuleData; } } @@ -1884,7 +1865,7 @@ void SvxConfigPage::Reset( const SfxItemSet& ) if ( xDocCfgMgr.is() ) { - pData = CreateSaveInData( xDocCfgMgr, xCfgMgr, aModuleId, TRUE ); + pData = CreateSaveInData( xDocCfgMgr, xCfgMgr, aModuleId, sal_True ); if ( pData && !pData->IsReadOnly() ) { @@ -1900,7 +1881,7 @@ void SvxConfigPage::Reset( const SfxItemSet& ) aSaveInListBox.SetSelectHdl( LINK( this, SvxConfigPage, SelectSaveInLocation ) ); - bInitialised = TRUE; + bInitialised = sal_True; Init(); } @@ -1971,11 +1952,11 @@ void SvxConfigPage::Reset( const SfxItemSet& ) return sModuleID; } -BOOL SvxConfigPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxConfigPage::FillItemSet( SfxItemSet& ) { - bool result = FALSE; + bool result = sal_False; - for ( USHORT i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) { SaveInData* pData = (SaveInData*) aSaveInListBox.GetEntryData( i ); @@ -2027,7 +2008,7 @@ IMPL_LINK( SvxConfigPage, SelectSaveInLocation, ListBox *, pBox ) void SvxConfigPage::ReloadTopLevelListBox( SvxConfigEntry* pToSelect ) { - USHORT nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); + sal_uInt16 nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); aTopLevelListBox.Clear(); if ( GetSaveInData() && GetSaveInData()->GetEntries() ) @@ -2038,7 +2019,7 @@ void SvxConfigPage::ReloadTopLevelListBox( SvxConfigEntry* pToSelect ) for ( ; iter != end; ++iter ) { SvxConfigEntry* pEntryData = *iter; - USHORT nPos = aTopLevelListBox.InsertEntry( stripHotKey( pEntryData->GetName() ) ); + sal_uInt16 nPos = aTopLevelListBox.InsertEntry( stripHotKey( pEntryData->GetName() ) ); aTopLevelListBox.SetEntryData( nPos, pEntryData ); if ( pEntryData == pToSelect ) @@ -2059,7 +2040,7 @@ void SvxConfigPage::ReloadTopLevelListBox( SvxConfigEntry* pToSelect ) nSelectionPos = nSelectionPos < aTopLevelListBox.GetEntryCount() ? nSelectionPos : aTopLevelListBox.GetEntryCount() - 1; - aTopLevelListBox.SelectEntryPos( nSelectionPos, TRUE ); + aTopLevelListBox.SelectEntryPos( nSelectionPos, sal_True ); aTopLevelListBox.GetSelectHdl().Call( this ); } @@ -2079,7 +2060,7 @@ void SvxConfigPage::AddSubMenusToUI( subMenuTitle += OUString::createFromAscii( pMenuSeparatorStr ); subMenuTitle += stripHotKey( pEntryData->GetName() ); - USHORT nPos = aTopLevelListBox.InsertEntry( subMenuTitle ); + sal_uInt16 nPos = aTopLevelListBox.InsertEntry( subMenuTitle ); aTopLevelListBox.SetEntryData( nPos, pEntryData ); AddSubMenusToUI( subMenuTitle, pEntryData ); @@ -2128,9 +2109,8 @@ SvLBoxEntry* SvxConfigPage::AddFunction( } SvxConfigEntry* pNewEntryData = - new SvxConfigEntry( aDisplayName, aURL, FALSE ); - pNewEntryData->SetUserDefined( TRUE ); - pNewEntryData->SetHelpURL( aURL ); + new SvxConfigEntry( aDisplayName, aURL, sal_False ); + pNewEntryData->SetUserDefined( sal_True ); // check that this function is not already in the menu SvxConfigEntry* pParent = GetTopLevelSelection(); @@ -2190,7 +2170,7 @@ SvLBoxEntry* SvxConfigPage::InsertEntry( SvxEntries::const_iterator end = pEntries->end(); // Advance the iterator to the data for currently selected entry - USHORT nPos = 0; + sal_uInt16 nPos = 0; while (*iter != pEntryData && ++iter != end) { ++nPos; @@ -2213,14 +2193,14 @@ SvLBoxEntry* SvxConfigPage::InsertEntry( aContentsListBox->Select( pNewEntry ); aContentsListBox->MakeVisible( pNewEntry ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } return pNewEntry; } SvLBoxEntry* SvxConfigPage::InsertEntryIntoUI( - SvxConfigEntry* pNewEntryData, ULONG nPos ) + SvxConfigEntry* pNewEntryData, sal_uLong nPos ) { SvLBoxEntry* pNewEntry = NULL; @@ -2228,7 +2208,7 @@ SvLBoxEntry* SvxConfigPage::InsertEntryIntoUI( { pNewEntry = aContentsListBox->InsertEntry( String::CreateFromAscii( pSeparatorStr ), - 0, FALSE, nPos, pNewEntryData ); + 0, sal_False, nPos, pNewEntryData ); } else { @@ -2240,12 +2220,12 @@ SvLBoxEntry* SvxConfigPage::InsertEntryIntoUI( if ( !!aImage ) { pNewEntry = aContentsListBox->InsertEntry( - aName, aImage, aImage, 0, FALSE, nPos, pNewEntryData ); + aName, aImage, aImage, 0, sal_False, nPos, pNewEntryData ); } else { pNewEntry = aContentsListBox->InsertEntry( - aName, 0, FALSE, nPos, pNewEntryData ); + aName, 0, sal_False, nPos, pNewEntryData ); } if ( pNewEntryData->IsPopup() || @@ -2318,7 +2298,7 @@ bool SvxConfigPage::MoveEntryData( //modified by shizhoubo for issue53677 if ( NULL == pSourceEntry || NULL == pTargetEntry ) { - return FALSE; + return sal_False; } // Grab the entries list for the currently selected menu @@ -2333,9 +2313,9 @@ bool SvxConfigPage::MoveEntryData( pEntries->insert( pEntries->begin(), pSourceData ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); - return TRUE; + return sal_True; } else { @@ -2356,13 +2336,13 @@ bool SvxConfigPage::MoveEntryData( // insert the source entry at the position after the target pEntries->insert( ++iter, pSourceData ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); - return TRUE; + return sal_True; } } - return FALSE; + return sal_False; } SvxMenuConfigPage::SvxMenuConfigPage( @@ -2417,13 +2397,13 @@ void SvxMenuConfigPage::Init() ReloadTopLevelListBox(); - aTopLevelListBox.SelectEntryPos(0, TRUE); + aTopLevelListBox.SelectEntryPos(0, sal_True); aTopLevelListBox.GetSelectHdl().Call(this); } SvxMenuConfigPage::~SvxMenuConfigPage() { - for ( USHORT i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) { MenuSaveInData* pData = (MenuSaveInData*) aSaveInListBox.GetEntryData( i ); @@ -2457,12 +2437,12 @@ void SvxMenuConfigPage::UpdateButtonStates() if ( aContentsListBox->GetEntryCount() == 0 || selection == NULL ) { - aMoveUpButton.Enable( FALSE ); - aMoveDownButton.Enable( FALSE ); + aMoveUpButton.Enable( sal_False ); + aMoveDownButton.Enable( sal_False ); - pPopup->EnableItem( ID_BEGIN_GROUP, TRUE ); - pPopup->EnableItem( ID_RENAME, FALSE ); - pPopup->EnableItem( ID_DELETE, FALSE ); + pPopup->EnableItem( ID_BEGIN_GROUP, sal_True ); + pPopup->EnableItem( ID_RENAME, sal_False ); + pPopup->EnableItem( ID_DELETE, sal_False ); aDescriptionField.Clear(); @@ -2480,17 +2460,17 @@ void SvxMenuConfigPage::UpdateButtonStates() if ( pEntryData->IsSeparator() ) { - pPopup->EnableItem( ID_DELETE, TRUE ); - pPopup->EnableItem( ID_BEGIN_GROUP, FALSE ); - pPopup->EnableItem( ID_RENAME, FALSE ); + pPopup->EnableItem( ID_DELETE, sal_True ); + pPopup->EnableItem( ID_BEGIN_GROUP, sal_False ); + pPopup->EnableItem( ID_RENAME, sal_False ); aDescriptionField.Clear(); } else { - pPopup->EnableItem( ID_BEGIN_GROUP, TRUE ); - pPopup->EnableItem( ID_DELETE, TRUE ); - pPopup->EnableItem( ID_RENAME, TRUE ); + pPopup->EnableItem( ID_BEGIN_GROUP, sal_True ); + pPopup->EnableItem( ID_DELETE, sal_True ); + pPopup->EnableItem( ID_RENAME, sal_True ); aDescriptionField.SetNewText( pEntryData->GetHelpText() ); } @@ -2508,7 +2488,7 @@ void SvxMenuConfigPage::DeleteSelectedTopLevel() ReloadTopLevelListBox(); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } bool SvxMenuConfigPage::DeleteSelectedContent() @@ -2539,11 +2519,11 @@ bool SvxMenuConfigPage::DeleteSelectedContent() // delete data for menu entry delete pMenuEntry; - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } short SvxMenuConfigPage::QueryReset() @@ -2619,7 +2599,7 @@ IMPL_LINK( SvxMenuConfigPage, MenuSelectHdl, MenuButton *, pButton ) ReloadTopLevelListBox(); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } // #i68101# Memory leak (!) @@ -2643,7 +2623,7 @@ IMPL_LINK( SvxMenuConfigPage, MenuSelectHdl, MenuButton *, pButton ) ReloadTopLevelListBox( pDialog->GetSelectedEntry() ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } delete pDialog; @@ -2651,9 +2631,9 @@ IMPL_LINK( SvxMenuConfigPage, MenuSelectHdl, MenuButton *, pButton ) break; } default: - return FALSE; + return sal_False; } - return TRUE; + return sal_True; } IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) @@ -2675,14 +2655,14 @@ IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) pNameDialog->GetName(aNewName); SvxConfigEntry* pNewEntryData = - new SvxConfigEntry( aNewName, aNewName, TRUE ); - pNewEntryData->SetUserDefined( TRUE ); + new SvxConfigEntry( aNewName, aNewName, sal_True ); + pNewEntryData->SetUserDefined( sal_True ); InsertEntry( pNewEntryData ); ReloadTopLevelListBox(); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } delete pNameDialog; @@ -2692,7 +2672,7 @@ IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) case ID_BEGIN_GROUP: { SvxConfigEntry* pNewEntryData = new SvxConfigEntry; - pNewEntryData->SetUserDefined( TRUE ); + pNewEntryData->SetUserDefined( sal_True ); InsertEntry( pNewEntryData ); break; @@ -2723,7 +2703,7 @@ IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) pEntry->SetName( aNewName ); aContentsListBox->SetEntryText( pActEntry, aNewName ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } delete pNameDialog; @@ -2732,7 +2712,7 @@ IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) } default: { - return FALSE; + return sal_False; } } @@ -2741,7 +2721,7 @@ IMPL_LINK( SvxMenuConfigPage, EntrySelectHdl, MenuButton *, pButton ) UpdateButtonStates(); } - return TRUE; + return sal_True; } IMPL_LINK( SvxMenuConfigPage, AddFunctionHdl, @@ -2760,7 +2740,7 @@ IMPL_LINK( SvxMenuConfigPage, NewMenuHdl, Button *, pButton ) SvxMainMenuOrganizerDialog* pDialog = new SvxMainMenuOrganizerDialog( 0, - GetSaveInData()->GetEntries(), NULL, TRUE ); + GetSaveInData()->GetEntries(), NULL, sal_True ); bool ret = pDialog->Execute(); @@ -2768,7 +2748,7 @@ IMPL_LINK( SvxMenuConfigPage, NewMenuHdl, Button *, pButton ) { GetSaveInData()->SetEntries( pDialog->GetEntries() ); ReloadTopLevelListBox( pDialog->GetSelectedEntry() ); - GetSaveInData()->SetModified( TRUE ); + GetSaveInData()->SetModified( sal_True ); } delete pDialog; @@ -2783,7 +2763,7 @@ IMPL_LINK( SvxMenuConfigPage, AddCommandsHdl, Button *, pButton ) if ( pSelectorDlg == NULL ) { // Create Script Selector which also shows builtin commands - pSelectorDlg = new SvxScriptSelectorDialog( this, TRUE, m_xFrame ); + pSelectorDlg = new SvxScriptSelectorDialog( this, sal_True, m_xFrame ); pSelectorDlg->SetAddHdl( LINK( this, SvxMenuConfigPage, AddFunctionHdl ) ); @@ -2827,7 +2807,7 @@ SvxMainMenuOrganizerDialog::SvxMainMenuOrganizerDialog( aOKButton( this, CUI_RES( BTN_MENU_ADD ) ), aCloseButton( this, CUI_RES( BTN_MENU_CLOSE ) ), aHelpButton( this, CUI_RES( BTN_MENU_HELP ) ), - bModified( FALSE ) + bModified( sal_False ) { FreeResource(); @@ -2866,9 +2846,9 @@ SvxMainMenuOrganizerDialog::SvxMainMenuOrganizerDialog( OUString newurl = generateCustomMenuURL( pEntries ); SvxConfigEntry* pNewEntryData = - new SvxConfigEntry( newname, newurl, TRUE ); - pNewEntryData->SetUserDefined( TRUE ); - pNewEntryData->SetMain( TRUE ); + new SvxConfigEntry( newname, newurl, sal_True ); + pNewEntryData->SetUserDefined( sal_True ); + pNewEntryData->SetMain( sal_True ); pNewMenuEntry = aMenuListBox.InsertEntry( stripHotKey( pNewEntryData->GetName() ) ); @@ -2925,6 +2905,9 @@ SvxMainMenuOrganizerDialog::SvxMainMenuOrganizerDialog( LINK( this, SvxMainMenuOrganizerDialog, MoveHdl) ); aMoveDownButton.SetClickHdl ( LINK( this, SvxMainMenuOrganizerDialog, MoveHdl) ); + + aMoveUpButton.SetAccessibleName(String(CUI_RES(BUTTON_STR_UP))); + aMoveDownButton.SetAccessibleName(String(CUI_RES(BUTTON_STR_DOWN))); } IMPL_LINK(SvxMainMenuOrganizerDialog, ModifyHdl, Edit*, pEdit) @@ -3012,7 +2995,7 @@ IMPL_LINK( SvxMainMenuOrganizerDialog, MoveHdl, Button *, pButton ) aMenuListBox.GetModel()->Move( pSourceEntry, pTargetEntry ); aMenuListBox.MakeVisible( pSourceEntry ); - bModified = TRUE; + bModified = sal_True; } } @@ -3034,203 +3017,31 @@ SvxConfigEntry* SvxMainMenuOrganizerDialog::GetSelectedEntry() return (SvxConfigEntry*)aMenuListBox.FirstSelected()->GetUserData(); } -SvxConfigEntry::SvxConfigEntry( - const uno::Sequence< beans::PropertyValue >& rProperties, - const uno::Reference< container::XNameAccess >& rCommandToLabelMap ) - : - nId( 1 ), - bPopUp( FALSE ), - bStrEdited( FALSE ), - bIsUserDefined( FALSE ), - bIsMain( FALSE ), - bIsParentData( FALSE ), - bIsVisible( TRUE ), - nStyle( 0 ), - pEntries( 0 ) -{ - sal_uInt16 nType( css::ui::ItemType::DEFAULT ); - OUString aHelpURL_; - - for ( sal_Int32 i = 0; i < rProperties.getLength(); ++i ) - { - if ( rProperties[i].Name.equalsAscii( ITEM_DESCRIPTOR_COMMANDURL )) - { - rProperties[i].Value >>= aCommand; - } - else if ( rProperties[i].Name.equalsAscii( ITEM_DESCRIPTOR_HELPURL )) - { - rProperties[i].Value >>= aHelpURL_; - } - else if ( rProperties[i].Name.equalsAscii( ITEM_DESCRIPTOR_LABEL )) - { - rProperties[i].Value >>= aLabel; - } - else if ( rProperties[i].Name.equalsAscii( ITEM_DESCRIPTOR_TYPE )) - { - rProperties[i].Value >>= nType; - } - } - - if ( nType == css::ui::ItemType::DEFAULT ) - { - uno::Any a; - try - { - a = rCommandToLabelMap->getByName( aCommand ); - bIsUserDefined = FALSE; - } - catch ( container::NoSuchElementException& ) - { - bIsUserDefined = TRUE; - } - - // If custom label not set retrieve it from the command to info service - if ( aLabel.equals( OUString() ) ) - { - uno::Sequence< beans::PropertyValue > aPropSeq; - if ( a >>= aPropSeq ) - { - for ( sal_Int32 i = 0; i < aPropSeq.getLength(); ++i ) - { - if ( aPropSeq[i].Name.equalsAscii( ITEM_DESCRIPTOR_LABEL ) ) - { - aPropSeq[i].Value >>= aLabel; - break; - } - } - } - } - } -} - const OUString& SvxConfigEntry::GetHelpText() { if ( aHelpText.getLength() == 0 ) { - OUString helpid(RTL_CONSTASCII_USTRINGPARAM( "helpid:" )); - if ( aHelpURL.indexOf( helpid ) != -1 ) - { - aHelpURL = aHelpURL.copy( helpid.getLength() ); - } - - Help* pHelp = Application::GetHelp(); - if ( aHelpURL.toInt32() != 0 ) + if ( aCommand.getLength() ) { - aHelpText = pHelp->GetHelpText( aHelpURL.toInt32(), NULL ); - } - - if ( aHelpText.getLength() == 0 && aCommand.getLength() != 0 ) - { - aHelpText = pHelp->GetHelpText( aCommand, NULL ); + aHelpText = Application::GetHelp()->GetHelpText( aCommand, NULL ); } } return aHelpText; } -uno::Sequence< beans::PropertyValue > -SvxConfigEntry::GetProperties( - const uno::Reference< container::XNameAccess >& rCommandToLabelMap ) -{ - if ( IsSeparator() ) - { - uno::Sequence< beans::PropertyValue > aPropSeq( 1 ); - - aPropSeq[0].Name = OUString( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_TYPE ) ); - aPropSeq[0].Value <<= css::ui::ItemType::SEPARATOR_LINE; - - return aPropSeq; - } - - static const OUString aDescriptorCommandURL ( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_COMMANDURL ) ); - - static const OUString aDescriptorType( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_TYPE ) ); - - static const OUString aDescriptorLabel( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_LABEL ) ); - - static const OUString aDescriptorHelpURL( - RTL_CONSTASCII_USTRINGPARAM( ITEM_DESCRIPTOR_HELPURL ) ); - - uno::Sequence< beans::PropertyValue > aPropSeq( 4 ); - - aPropSeq[0].Name = aDescriptorCommandURL; - aPropSeq[0].Value <<= rtl::OUString( GetCommand() ); - - aPropSeq[1].Name = aDescriptorType; - aPropSeq[1].Value <<= css::ui::ItemType::DEFAULT; - - // If the name has not been changed and the name is the same as - // in the default command to label map then the label can be stored - // as an empty string. - // It will be initialised again later using the command to label map. - aPropSeq[2].Name = aDescriptorLabel; - if ( HasChangedName() == FALSE && GetCommand().getLength() ) - { - BOOL isDefaultName = FALSE; - try - { - uno::Any a( rCommandToLabelMap->getByName( GetCommand() ) ); - uno::Sequence< beans::PropertyValue > tmpPropSeq; - if ( a >>= tmpPropSeq ) - { - for ( sal_Int32 i = 0; i < tmpPropSeq.getLength(); ++i ) - { - if ( tmpPropSeq[i].Name.equals( aDescriptorLabel ) ) - { - OUString tmpLabel; - tmpPropSeq[i].Value >>= tmpLabel; - - if ( tmpLabel.equals( GetName() ) ) - { - isDefaultName = TRUE; - } - - break; - } - } - } - } - catch ( container::NoSuchElementException& ) - { - // isDefaultName is left as FALSE - } - - if ( isDefaultName ) - { - aPropSeq[2].Value <<= rtl::OUString(); - } - else - { - aPropSeq[2].Value <<= rtl::OUString( GetName() ); - } - } - else - { - aPropSeq[2].Value <<= rtl::OUString( GetName() ); - } - - aPropSeq[3].Name = aDescriptorHelpURL; - aPropSeq[3].Value <<= rtl::OUString( GetHelpURL() ); - - return aPropSeq; -} - SvxConfigEntry::SvxConfigEntry( const OUString& rDisplayName, const OUString& rCommandURL, bool bPopup, bool bParentData ) : nId( 1 ) , aLabel(rDisplayName) , aCommand(rCommandURL) , bPopUp(bPopup) - , bStrEdited( FALSE ) - , bIsUserDefined( FALSE ) - , bIsMain( FALSE ) + , bStrEdited( sal_False ) + , bIsUserDefined( sal_False ) + , bIsMain( sal_False ) , bIsParentData( bParentData ) - , bIsVisible( TRUE ) + , bIsVisible( sal_True ) , nStyle( 0 ) , pEntries( 0 ) { @@ -3258,27 +3069,27 @@ bool SvxConfigEntry::IsMovable() { if ( IsPopup() && !IsMain() ) { - return FALSE; + return sal_False; } - return TRUE; + return sal_True; } bool SvxConfigEntry::IsDeletable() { if ( IsMain() && !IsUserDefined() ) { - return FALSE; + return sal_False; } - return TRUE; + return sal_True; } bool SvxConfigEntry::IsRenamable() { if ( IsMain() && !IsUserDefined() ) { - return FALSE; + return sal_False; } - return TRUE; + return sal_True; } SvxToolbarConfigPage::SvxToolbarConfigPage( @@ -3323,8 +3134,8 @@ SvxToolbarConfigPage::SvxToolbarConfigPage( aMoveDownButton.SetClickHdl ( LINK( this, SvxToolbarConfigPage, MoveHdl) ); // Always enable Up and Down buttons // added for issue i53677 by shizhoubo - aMoveDownButton.Enable( TRUE ); - aMoveUpButton.Enable( TRUE ); + aMoveDownButton.Enable( sal_True ); + aMoveUpButton.Enable( sal_True ); PopupMenu* pMenu = new PopupMenu( CUI_RES( MODIFY_TOOLBAR ) ); pMenu->SetMenuFlags( @@ -3378,7 +3189,7 @@ SvxToolbarConfigPage::SvxToolbarConfigPage( SvxToolbarConfigPage::~SvxToolbarConfigPage() { - for ( USHORT i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) { ToolbarSaveInData* pData = (ToolbarSaveInData*) aSaveInListBox.GetEntryData( i ); @@ -3397,7 +3208,7 @@ SvxToolbarConfigPage::~SvxToolbarConfigPage() void SvxToolbarConfigPage::DeleteSelectedTopLevel() { - USHORT nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); + sal_uInt16 nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); ToolbarSaveInData* pSaveInData = (ToolbarSaveInData*) GetSaveInData(); pSaveInData->RemoveToolbar( GetTopLevelSelection() ); @@ -3408,11 +3219,11 @@ void SvxToolbarConfigPage::DeleteSelectedTopLevel() // subtract one from the entry count if ( nSelectionPos != aTopLevelListBox.GetEntryCount() - 1 ) { - aTopLevelListBox.SelectEntryPos( nSelectionPos + 1, TRUE ); + aTopLevelListBox.SelectEntryPos( nSelectionPos + 1, sal_True ); } else { - aTopLevelListBox.SelectEntryPos( nSelectionPos - 1, TRUE ); + aTopLevelListBox.SelectEntryPos( nSelectionPos - 1, sal_True ); } aTopLevelListBox.GetSelectHdl().Call( this ); @@ -3464,10 +3275,10 @@ bool SvxToolbarConfigPage::DeleteSelectedContent() } } - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } IMPL_LINK( SvxToolbarConfigPage, MoveHdl, Button *, pButton ) @@ -3493,7 +3304,7 @@ void SvxToolbarConfigPage::MoveEntry( bool bMoveUp ) IMPL_LINK( SvxToolbarConfigPage, ToolbarSelectHdl, MenuButton *, pButton ) { - USHORT nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); + sal_uInt16 nSelectionPos = aTopLevelListBox.GetSelectEntryPos(); SvxConfigEntry* pToolbar = (SvxConfigEntry*)aTopLevelListBox.GetEntryData( nSelectionPos ); @@ -3588,7 +3399,7 @@ IMPL_LINK( SvxToolbarConfigPage, ToolbarSelectHdl, MenuButton *, pButton ) IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) { - bool bNeedsApply = FALSE; + bool bNeedsApply = sal_False; // get currently selected toolbar SvxConfigEntry* pToolbar = GetTopLevelSelection(); @@ -3616,7 +3427,7 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) pEntry->SetName( aNewName ); aContentsListBox->SetEntryText( pActEntry, aNewName ); - bNeedsApply = TRUE; + bNeedsApply = sal_True; } delete pNameDialog; @@ -3628,10 +3439,10 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) SvxConfigEntry* pEntry = (SvxConfigEntry*) pActEntry->GetUserData(); - USHORT nSelectionPos = 0; + sal_uInt16 nSelectionPos = 0; // find position of entry within the list - for ( USHORT i = 0; i < aContentsListBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aContentsListBox->GetEntryCount(); ++i ) { if ( aContentsListBox->GetEntry( 0, i ) == pActEntry ) { @@ -3651,7 +3462,7 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) pEntry->SetName( aSystemName ); aContentsListBox->SetEntryText( pActEntry, stripHotKey( aSystemName ) ); - bNeedsApply = TRUE; + bNeedsApply = sal_True; } uno::Sequence< OUString > aURLSeq( 1 ); @@ -3681,7 +3492,7 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) aContentsListBox->Select( pNewLBEntry ); aContentsListBox->MakeVisible( pNewLBEntry ); - bNeedsApply = TRUE; + bNeedsApply = sal_True; } catch ( uno::Exception& ) { @@ -3692,14 +3503,14 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) case ID_BEGIN_GROUP: { SvxConfigEntry* pNewEntryData = new SvxConfigEntry; - pNewEntryData->SetUserDefined( TRUE ); + pNewEntryData->SetUserDefined( sal_True ); SvLBoxEntry* pNewLBEntry = InsertEntry( pNewEntryData ); aContentsListBox->SetCheckButtonState( pNewLBEntry, SV_BUTTON_TRISTATE ); - bNeedsApply = TRUE; + bNeedsApply = sal_True; break; } case ID_DELETE: @@ -3725,10 +3536,10 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) SvxConfigEntry* pEntry = (SvxConfigEntry*) pActEntry->GetUserData(); - USHORT nSelectionPos = 0; + sal_uInt16 nSelectionPos = 0; // find position of entry within the list - for ( USHORT i = 0; i < aContentsListBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aContentsListBox->GetEntryCount(); ++i ) { if ( aContentsListBox->GetEntry( 0, i ) == pActEntry ) { @@ -3808,10 +3619,10 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) SvxConfigEntry* pEntry = (SvxConfigEntry*) pActEntry->GetUserData(); - USHORT nSelectionPos = 0; + sal_uInt16 nSelectionPos = 0; // find position of entry within the list - for ( USHORT i = 0; i < aContentsListBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aContentsListBox->GetEntryCount(); ++i ) { if ( aContentsListBox->GetEntry( 0, i ) == pActEntry ) { @@ -3863,7 +3674,7 @@ IMPL_LINK( SvxToolbarConfigPage, EntrySelectHdl, MenuButton *, pButton ) } } - if ( bNeedsApply == TRUE ) + if ( bNeedsApply == sal_True ) { (( ToolbarSaveInData* ) GetSaveInData())->ApplyToolbar( pToolbar ); UpdateButtonStates(); @@ -3880,10 +3691,10 @@ void SvxToolbarConfigPage::Init() ReloadTopLevelListBox(); - USHORT nPos = 0; + sal_uInt16 nPos = 0; if ( m_aURLToSelect.getLength() != 0 ) { - for ( USHORT i = 0 ; i < aTopLevelListBox.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0 ; i < aTopLevelListBox.GetEntryCount(); ++i ) { SvxConfigEntry* pData = (SvxConfigEntry*) aTopLevelListBox.GetEntryData( i ); @@ -3900,7 +3711,7 @@ void SvxToolbarConfigPage::Init() m_aURLToSelect += OUString(RTL_CONSTASCII_USTRINGPARAM( "standardbar" )); } - aTopLevelListBox.SelectEntryPos(nPos, TRUE); + aTopLevelListBox.SelectEntryPos(nPos, sal_True); aTopLevelListBox.GetSelectHdl().Call(this); } @@ -4149,7 +3960,7 @@ SvxEntries* ToolbarSaveInData::GetEntries() { pRootEntry = new SvxConfigEntry( - String::CreateFromAscii("MainToolbars"), String(), TRUE ); + String::CreateFromAscii("MainToolbars"), String(), sal_True ); uno::Sequence< uno::Sequence < beans::PropertyValue > > info = GetConfigManager()->getUIElementsInfo( @@ -4193,9 +4004,9 @@ SvxEntries* ToolbarSaveInData::GetEntries() } SvxConfigEntry* pEntry = new SvxConfigEntry( - uiname, url, TRUE ); + uiname, url, sal_True ); - pEntry->SetMain( TRUE ); + pEntry->SetMain( sal_True ); pEntry->SetStyle( GetSystemStyle( url ) ); @@ -4205,11 +4016,11 @@ SvxEntries* ToolbarSaveInData::GetEntries() OUString custom(RTL_CONSTASCII_USTRINGPARAM(CUSTOM_TOOLBAR_STR)); if ( systemname.indexOf( custom ) == 0 ) { - pEntry->SetUserDefined( TRUE ); + pEntry->SetUserDefined( sal_True ); } else { - pEntry->SetUserDefined( FALSE ); + pEntry->SetUserDefined( sal_False ); } pRootEntry->GetEntries()->push_back( pEntry ); @@ -4281,18 +4092,18 @@ SvxEntries* ToolbarSaveInData::GetEntries() } SvxConfigEntry* pEntry = new SvxConfigEntry( - uiname, url, TRUE, TRUE ); + uiname, url, sal_True, sal_True ); - pEntry->SetMain( TRUE ); + pEntry->SetMain( sal_True ); pEntry->SetStyle( GetSystemStyle( url ) ); if ( systemname.indexOf( custom ) == 0 ) { - pEntry->SetUserDefined( TRUE ); + pEntry->SetUserDefined( sal_True ); } else { - pEntry->SetUserDefined( FALSE ); + pEntry->SetUserDefined( sal_False ); } pRootEntry->GetEntries()->push_back( pEntry ); @@ -4339,14 +4150,14 @@ ToolbarSaveInData::HasURL( const OUString& rURL ) if ( pEntry->GetCommand().equals( rURL ) ) { if ( pEntry->IsParentData() ) - return FALSE; + return sal_False; else - return TRUE; + return sal_True; } ++iter; } - return FALSE; + return sal_False; } bool ToolbarSaveInData::HasSettings() @@ -4354,9 +4165,9 @@ bool ToolbarSaveInData::HasSettings() // return true if there is at least one toolbar entry if ( GetEntries()->size() > 0 ) { - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } void ToolbarSaveInData::Reset() @@ -4404,7 +4215,7 @@ void ToolbarSaveInData::Reset() bool ToolbarSaveInData::Apply() { // toolbar changes are instantly applied - return FALSE; + return sal_False; } void ToolbarSaveInData::ApplyToolbar( @@ -4638,51 +4449,6 @@ void ToolbarSaveInData::RestoreToolbar( SvxConfigEntry* pToolbar ) } } -void ToolbarSaveInData::ReloadToolbar( const OUString& rResourceURL ) -{ - SvxEntries::const_iterator iter = GetEntries()->begin(); - SvxConfigEntry* pToolbar = NULL; - - for ( ; iter != GetEntries()->end(); ++iter ) - { - SvxConfigEntry* pEntry = *iter; - - if ( pEntry->GetCommand().equals( rResourceURL ) ) - { - pToolbar = pEntry; - break; - } - } - - if ( pToolbar != NULL ) - { - delete pToolbar->GetEntries(); - - try - { - uno::Reference< container::XIndexAccess > xToolbarSettings; - - if ( pToolbar->IsParentData() ) - { - xToolbarSettings = GetParentConfigManager()->getSettings( - pToolbar->GetCommand(), sal_False); - } - else - { - xToolbarSettings = GetConfigManager()->getSettings( - pToolbar->GetCommand(), sal_False); - } - - LoadToolbar( xToolbarSettings, pToolbar ); - } - catch ( container::NoSuchElementException& ) - { - // toolbar not found for some reason - // it will not appear in the toolbar list - } - } -} - bool ToolbarSaveInData::LoadToolbar( const uno::Reference< container::XIndexAccess >& xToolbarSettings, SvxConfigEntry* pParentData ) @@ -4693,16 +4459,15 @@ bool ToolbarSaveInData::LoadToolbar( { uno::Reference< container::XIndexAccess > xSubMenu; OUString aCommandURL; - OUString aHelpURL; OUString aLabel; - bool bIsUserDefined = TRUE; + bool bIsUserDefined = sal_True; sal_Bool bIsVisible; sal_Int32 nStyle; sal_uInt16 nType( css::ui::ItemType::DEFAULT ); bool bItem = GetToolbarItemData( xToolbarSettings, nIndex, aCommandURL, - aHelpURL, aLabel, nType, bIsVisible, nStyle, xSubMenu ); + aLabel, nType, bIsVisible, nStyle, xSubMenu ); if ( bItem ) { @@ -4712,11 +4477,11 @@ bool ToolbarSaveInData::LoadToolbar( try { a = m_xCommandToLabelMap->getByName( aCommandURL ); - bIsUserDefined = FALSE; + bIsUserDefined = sal_False; } catch ( container::NoSuchElementException& ) { - bIsUserDefined = TRUE; + bIsUserDefined = sal_True; } // If custom label not set retrieve it from the command @@ -4740,10 +4505,9 @@ bool ToolbarSaveInData::LoadToolbar( if ( xSubMenu.is() ) { SvxConfigEntry* pEntry = new SvxConfigEntry( - aLabel, aCommandURL, TRUE ); + aLabel, aCommandURL, sal_True ); pEntry->SetUserDefined( bIsUserDefined ); - pEntry->SetHelpURL( aHelpURL ); pEntry->SetVisible( bIsVisible ); pEntries->push_back( pEntry ); @@ -4753,9 +4517,8 @@ bool ToolbarSaveInData::LoadToolbar( else { SvxConfigEntry* pEntry = new SvxConfigEntry( - aLabel, aCommandURL, FALSE ); + aLabel, aCommandURL, sal_False ); pEntry->SetUserDefined( bIsUserDefined ); - pEntry->SetHelpURL( aHelpURL ); pEntry->SetVisible( bIsVisible ); pEntry->SetStyle( nStyle ); pEntries->push_back( pEntry ); @@ -4783,15 +4546,15 @@ IMPL_LINK( SvxToolbarConfigPage, SelectToolbarEntry, Control *, pBox ) void SvxToolbarConfigPage::UpdateButtonStates() { PopupMenu* pPopup = aModifyCommandButton.GetPopupMenu(); - pPopup->EnableItem( ID_RENAME, FALSE ); - pPopup->EnableItem( ID_DELETE, FALSE ); - pPopup->EnableItem( ID_BEGIN_GROUP, FALSE ); - pPopup->EnableItem( ID_DEFAULT_COMMAND, FALSE ); - pPopup->EnableItem( ID_ICON_ONLY, FALSE ); - pPopup->EnableItem( ID_ICON_AND_TEXT, FALSE ); - pPopup->EnableItem( ID_TEXT_ONLY, FALSE ); - pPopup->EnableItem( ID_CHANGE_SYMBOL, FALSE ); - pPopup->EnableItem( ID_RESET_SYMBOL, FALSE ); + pPopup->EnableItem( ID_RENAME, sal_False ); + pPopup->EnableItem( ID_DELETE, sal_False ); + pPopup->EnableItem( ID_BEGIN_GROUP, sal_False ); + pPopup->EnableItem( ID_DEFAULT_COMMAND, sal_False ); + pPopup->EnableItem( ID_ICON_ONLY, sal_False ); + pPopup->EnableItem( ID_ICON_AND_TEXT, sal_False ); + pPopup->EnableItem( ID_TEXT_ONLY, sal_False ); + pPopup->EnableItem( ID_CHANGE_SYMBOL, sal_False ); + pPopup->EnableItem( ID_RESET_SYMBOL, sal_False ); aDescriptionField.Clear(); @@ -4803,22 +4566,22 @@ void SvxToolbarConfigPage::UpdateButtonStates() SvxConfigEntry* pEntryData = (SvxConfigEntry*) selection->GetUserData(); if ( pEntryData->IsSeparator() ) - pPopup->EnableItem( ID_DELETE, TRUE ); + pPopup->EnableItem( ID_DELETE, sal_True ); else { - pPopup->EnableItem( ID_BEGIN_GROUP, TRUE ); - pPopup->EnableItem( ID_DELETE, TRUE ); - pPopup->EnableItem( ID_RENAME, TRUE ); - pPopup->EnableItem( ID_ICON_ONLY, TRUE ); - pPopup->EnableItem( ID_ICON_AND_TEXT, TRUE ); - pPopup->EnableItem( ID_TEXT_ONLY, TRUE ); - pPopup->EnableItem( ID_CHANGE_SYMBOL, TRUE ); + pPopup->EnableItem( ID_BEGIN_GROUP, sal_True ); + pPopup->EnableItem( ID_DELETE, sal_True ); + pPopup->EnableItem( ID_RENAME, sal_True ); + pPopup->EnableItem( ID_ICON_ONLY, sal_True ); + pPopup->EnableItem( ID_ICON_AND_TEXT, sal_True ); + pPopup->EnableItem( ID_TEXT_ONLY, sal_True ); + pPopup->EnableItem( ID_CHANGE_SYMBOL, sal_True ); if ( !pEntryData->IsUserDefined() ) - pPopup->EnableItem( ID_DEFAULT_COMMAND, TRUE ); + pPopup->EnableItem( ID_DEFAULT_COMMAND, sal_True ); if ( pEntryData->IsIconModified() ) - pPopup->EnableItem( ID_RESET_SYMBOL, TRUE ); + pPopup->EnableItem( ID_RESET_SYMBOL, sal_True ); aDescriptionField.SetNewText( pEntryData->GetHelpText() ); } @@ -4848,16 +4611,16 @@ IMPL_LINK( SvxToolbarConfigPage, SelectToolbar, ListBox *, pBox ) SvxConfigEntry* pToolbar = GetTopLevelSelection(); if ( pToolbar == NULL ) { - aModifyTopLevelButton.Enable( FALSE ); - aModifyCommandButton.Enable( FALSE ); - aAddCommandsButton.Enable( FALSE ); + aModifyTopLevelButton.Enable( sal_False ); + aModifyCommandButton.Enable( sal_False ); + aAddCommandsButton.Enable( sal_False ); return 0; } - aModifyTopLevelButton.Enable( TRUE ); - aModifyCommandButton.Enable( TRUE ); - aAddCommandsButton.Enable( TRUE ); + aModifyTopLevelButton.Enable( sal_True ); + aModifyCommandButton.Enable( sal_True ); + aAddCommandsButton.Enable( sal_True ); PopupMenu* pPopup = aModifyTopLevelButton.GetPopupMenu(); @@ -4925,8 +4688,8 @@ IMPL_LINK( SvxToolbarConfigPage, NewToolbarHdl, Button *, pButton ) SvxNewToolbarDialog* pNameDialog = new SvxNewToolbarDialog( 0, aNewName ); - USHORT nInsertPos; - for ( USHORT i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) + sal_uInt16 nInsertPos; + for ( sal_uInt16 i = 0 ; i < aSaveInListBox.GetEntryCount(); ++i ) { SaveInData* pData = (SaveInData*) aSaveInListBox.GetEntryData( i ); @@ -4938,7 +4701,7 @@ IMPL_LINK( SvxToolbarConfigPage, NewToolbarHdl, Button *, pButton ) } pNameDialog->aSaveInListBox.SelectEntryPos( - aSaveInListBox.GetSelectEntryPos(), TRUE ); + aSaveInListBox.GetSelectEntryPos(), sal_True ); bool ret = pNameDialog->Execute(); if ( ret == RET_OK ) @@ -4952,24 +4715,24 @@ IMPL_LINK( SvxToolbarConfigPage, NewToolbarHdl, Button *, pButton ) if ( GetSaveInData() != pData ) { - aSaveInListBox.SelectEntryPos( nInsertPos, TRUE ); + aSaveInListBox.SelectEntryPos( nInsertPos, sal_True ); aSaveInListBox.GetSelectHdl().Call(this); } SvxConfigEntry* pToolbar = - new SvxConfigEntry( aNewName, aNewURL, TRUE ); + new SvxConfigEntry( aNewName, aNewURL, sal_True ); - pToolbar->SetUserDefined( TRUE ); - pToolbar->SetMain( TRUE ); + pToolbar->SetUserDefined( sal_True ); + pToolbar->SetMain( sal_True ); pData->CreateToolbar( pToolbar ); nInsertPos = aTopLevelListBox.InsertEntry( pToolbar->GetName() ); aTopLevelListBox.SetEntryData( nInsertPos, pToolbar ); - aTopLevelListBox.SelectEntryPos( nInsertPos, TRUE ); + aTopLevelListBox.SelectEntryPos( nInsertPos, sal_True ); aTopLevelListBox.GetSelectHdl().Call(this); - pData->SetModified( TRUE ); + pData->SetModified( sal_True ); } delete pNameDialog; @@ -4984,7 +4747,7 @@ IMPL_LINK( SvxToolbarConfigPage, AddCommandsHdl, Button *, pButton ) if ( pSelectorDlg == NULL ) { // Create Script Selector which shows slot commands - pSelectorDlg = new SvxScriptSelectorDialog( this, TRUE, m_xFrame ); + pSelectorDlg = new SvxScriptSelectorDialog( this, sal_True, m_xFrame ); // Position the Script Selector over the Add button so it is // beside the menu contents list and does not obscure it @@ -5021,7 +4784,7 @@ SvLBoxEntry* SvxToolbarConfigPage::AddFunction( if ( pEntry->IsBinding() ) { - pEntry->SetVisible( TRUE ); + pEntry->SetVisible( sal_True ); aContentsListBox->SetCheckButtonState( pNewLBEntry, SV_BUTTON_CHECKED ); } @@ -5103,8 +4866,8 @@ Image SvxToolbarEntriesListBox::GetSizedImage( // Position image at the center of (width-2),(height) rectangle. // We need 2 pixels to have a bigger border to the next button image - USHORT nPosX = std::max( (USHORT) (((( aNewSize.Width() - 2 ) - aImage.GetSizePixel().Width() ) / 2 ) - 1), (USHORT) 0 ); - USHORT nPosY = std::max( (USHORT) (((( aNewSize.Height() - 2 ) - aImage.GetSizePixel().Height() ) / 2 ) + 1), (USHORT) 0 ); + sal_uInt16 nPosX = std::max( (sal_uInt16) (((( aNewSize.Width() - 2 ) - aImage.GetSizePixel().Width() ) / 2 ) - 1), (sal_uInt16) 0 ); + sal_uInt16 nPosY = std::max( (sal_uInt16) (((( aNewSize.Height() - 2 ) - aImage.GetSizePixel().Height() ) / 2 ) + 1), (sal_uInt16) 0 ); Point aPos( nPosX > 0 ? nPosX : 0, nPosY > 0 ? nPosY : 0 ); aDev.SetFillColor( aFillColor ); aDev.SetLineColor( aFillColor ); @@ -5177,14 +4940,14 @@ void SvxToolbarEntriesListBox::KeyInput( const KeyEvent& rKeyEvent ) } } -BOOL SvxToolbarEntriesListBox::NotifyMoving( +sal_Bool SvxToolbarEntriesListBox::NotifyMoving( SvLBoxEntry* pTarget, SvLBoxEntry* pSource, - SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos) + SvLBoxEntry*& rpNewParent, sal_uLong& rNewChildPos) { bool result = SvxMenuEntriesListBox::NotifyMoving( pTarget, pSource, rpNewParent, rNewChildPos ); - if ( result == TRUE ) + if ( result == sal_True ) { // Instant Apply changes to UI SvxConfigEntry* pToolbar = pPage->GetTopLevelSelection(); @@ -5199,11 +4962,11 @@ BOOL SvxToolbarEntriesListBox::NotifyMoving( return result; } -BOOL SvxToolbarEntriesListBox::NotifyCopying( +sal_Bool SvxToolbarEntriesListBox::NotifyCopying( SvLBoxEntry* pTarget, SvLBoxEntry* pSource, SvLBoxEntry*& rpNewParent, - ULONG& rNewChildPos) + sal_uLong& rNewChildPos) { (void)pSource; (void)rpNewParent; @@ -5225,11 +4988,11 @@ BOOL SvxToolbarEntriesListBox::NotifyCopying( // AddFunction already adds the listbox entry so return FALSE // to stop another listbox entry being added - return FALSE; + return sal_False; } // Copying is only allowed from external controls, not within the listbox - return FALSE; + return sal_False; } SvxNewToolbarDialog::SvxNewToolbarDialog( @@ -5292,7 +5055,7 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, ::rtl::OUStringHash, ::std::equal_to< ::rtl::OUString > > ImageInfo; - aTbSymbol.SetPageScroll( TRUE ); + aTbSymbol.SetPageScroll( sal_True ); bool bLargeIcons = GetImageType() & css::ui::ImageType::SIZE_LARGE; m_nExpectedSize = bLargeIcons ? 26 : 16; @@ -5315,7 +5078,7 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, if ( !m_xGraphProvider.is() ) { - aBtnImport.Enable( FALSE ); + aBtnImport.Enable( sal_False ); } uno::Reference< beans::XPropertySet > xPropSet( @@ -5340,7 +5103,7 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, } else { - aBtnImport.Enable( FALSE ); + aBtnImport.Enable( sal_False ); } aDirectory += ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "soffice.cfg/import" ) ); @@ -5381,7 +5144,7 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, for ( sal_Int32 n = 0; n < names.getLength(); ++n ) mImageInfo.insert( ImageInfo::value_type( names[n], false )); } - USHORT nId = 1; + sal_uInt16 nId = 1; ImageInfo::const_iterator pConstIter = mImageInfo.begin(); uno::Sequence< OUString > name( 1 ); while ( pConstIter != mImageInfo.end() ) @@ -5461,7 +5224,7 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, ++pConstIter; } - aBtnDelete.Enable( FALSE ); + aBtnDelete.Enable( sal_False ); aTbSymbol.SetSelectHdl( LINK(this, SvxIconSelectorDialog, SelectHdl) ); aBtnImport.SetClickHdl( LINK(this, SvxIconSelectorDialog, ImportHdl) ); aBtnDelete.SetClickHdl( LINK(this, SvxIconSelectorDialog, DeleteHdl) ); @@ -5471,11 +5234,11 @@ SvxIconSelectorDialog::SvxIconSelectorDialog( Window *pWindow, SvxIconSelectorDialog::~SvxIconSelectorDialog() { - USHORT nCount = aTbSymbol.GetItemCount(); + sal_uInt16 nCount = aTbSymbol.GetItemCount(); - for (USHORT n = 0; n < nCount; ++n) + for (sal_uInt16 n = 0; n < nCount; ++n ) { - USHORT nId = aTbSymbol.GetItemId(n); + sal_uInt16 nId = aTbSymbol.GetItemId(n); uno::XInterface* xi = static_cast< uno::XInterface* >( aTbSymbol.GetItemData( nId ) ); @@ -5491,8 +5254,8 @@ uno::Reference< graphic::XGraphic> SvxIconSelectorDialog::GetSelectedIcon() { uno::Reference< graphic::XGraphic > result; - USHORT nId; - for ( USHORT n = 0; n < aTbSymbol.GetItemCount(); ++n ) + sal_uInt16 nId; + for ( sal_uInt16 n = 0; n < aTbSymbol.GetItemCount(); ++n ) { nId = aTbSymbol.GetItemId( n ); if ( aTbSymbol.IsItemChecked( nId ) ) @@ -5510,29 +5273,29 @@ IMPL_LINK( SvxIconSelectorDialog, SelectHdl, ToolBox *, pToolBox ) { (void)pToolBox; - USHORT nCount = aTbSymbol.GetItemCount(); + sal_uInt16 nCount = aTbSymbol.GetItemCount(); - for (USHORT n = 0; n < nCount; ++n) + for (sal_uInt16 n = 0; n < nCount; ++n ) { - USHORT nId = aTbSymbol.GetItemId( n ); + sal_uInt16 nId = aTbSymbol.GetItemId( n ); if ( aTbSymbol.IsItemChecked( nId ) ) { - aTbSymbol.CheckItem( nId, FALSE ); + aTbSymbol.CheckItem( nId, sal_False ); } } - USHORT nId = aTbSymbol.GetCurItemId(); + sal_uInt16 nId = aTbSymbol.GetCurItemId(); aTbSymbol.CheckItem( nId ); ::rtl::OUString aSelImageText = aTbSymbol.GetItemText( nId ); if ( m_xImportedImageManager->hasImage( GetImageType(), aSelImageText ) ) { - aBtnDelete.Enable( TRUE ); + aBtnDelete.Enable( sal_True ); } else { - aBtnDelete.Enable( FALSE ); + aBtnDelete.Enable( sal_False ); } return 0; @@ -5577,11 +5340,11 @@ IMPL_LINK( SvxIconSelectorDialog, DeleteHdl, PushButton *, pButton ) if ( ret == RET_OK ) { - USHORT nCount = aTbSymbol.GetItemCount(); + sal_uInt16 nCount = aTbSymbol.GetItemCount(); - for (USHORT n = 0; n < nCount; ++n) + for (sal_uInt16 n = 0; n < nCount; ++n ) { - USHORT nId = aTbSymbol.GetItemId( n ); + sal_uInt16 nId = aTbSymbol.GetItemId( n ); if ( aTbSymbol.IsItemChecked( nId ) ) { @@ -5617,7 +5380,7 @@ bool SvxIconSelectorDialog::ReplaceGraphicItem( aMediaProps[0].Value <<= aURL; com::sun::star::awt::Size aSize; - bool bOK = FALSE; + bool bOK = sal_False; try { xGraphic = m_xGraphProvider->queryGraphic( aMediaProps ); @@ -5628,9 +5391,9 @@ bool SvxIconSelectorDialog::ReplaceGraphicItem( OUString(RTL_CONSTASCII_USTRINGPARAM("SizePixel")) ); a >>= aSize; if (0 == aSize.Width || 0 == aSize.Height) - return FALSE; + return sal_False; else - bOK = TRUE; + bOK = sal_True; } catch ( uno::Exception& ) { @@ -5638,10 +5401,10 @@ bool SvxIconSelectorDialog::ReplaceGraphicItem( } bool bResult( false ); - USHORT nCount = aTbSymbol.GetItemCount(); - for (USHORT n = 0; n < nCount; ++n) + sal_uInt16 nCount = aTbSymbol.GetItemCount(); + for (sal_uInt16 n = 0; n < nCount; ++n ) { - USHORT nId = aTbSymbol.GetItemId( n ); + sal_uInt16 nId = aTbSymbol.GetItemId( n ); if ( OUString( aTbSymbol.GetItemText( nId ) ) == aURL ) { @@ -5686,7 +5449,7 @@ void SvxIconSelectorDialog::ImportGraphics( uno::Sequence< OUString > rejected( rPaths.getLength() ); sal_Int32 rejectedCount = 0; - USHORT ret = 0; + sal_uInt16 ret = 0; sal_Int32 aIndex; OUString aIconName; uno::Sequence< OUString > URLs(1); @@ -5710,7 +5473,7 @@ void SvxIconSelectorDialog::ImportGraphics( } else { - if ( ImportGraphic( rPaths[0] ) == FALSE ) + if ( ImportGraphic( rPaths[0] ) == sal_False ) { rejected[0] = rPaths[0]; rejectedCount = 1; @@ -5730,7 +5493,7 @@ void SvxIconSelectorDialog::ImportGraphics( { aIndex = rPaths[i].lastIndexOf( '/' ); aIconName = rPaths[i].copy( aIndex+1 ); - ret = SvxIconReplacementDialog( this, aIconName, TRUE ).ShowDialog(); + ret = SvxIconReplacementDialog( this, aIconName, sal_True ).ShowDialog(); if ( ret == 2 ) { ReplaceGraphicItem( aPath ); @@ -5745,7 +5508,7 @@ void SvxIconSelectorDialog::ImportGraphics( if ( !bHasReplaced ) { bool result = ImportGraphic( aPath ); - if ( result == FALSE ) + if ( result == sal_False ) { rejected[ rejectedCount ] = rPaths[i]; ++rejectedCount; @@ -5758,7 +5521,7 @@ void SvxIconSelectorDialog::ImportGraphics( else { bool result = ImportGraphic( aSourcePath + rPaths[i] ); - if ( result == FALSE ) + if ( result == sal_False ) { rejected[ rejectedCount ] = rPaths[i]; ++rejectedCount; @@ -5787,9 +5550,9 @@ void SvxIconSelectorDialog::ImportGraphics( bool SvxIconSelectorDialog::ImportGraphic( const OUString& aURL ) { - bool result = FALSE; + bool result = sal_False; - USHORT nId = m_nNextId; + sal_uInt16 nId = m_nNextId; ++m_nNextId; uno::Sequence< beans::PropertyValue > aMediaProps( 1 ); @@ -5797,7 +5560,7 @@ bool SvxIconSelectorDialog::ImportGraphic( const OUString& aURL ) uno::Reference< graphic::XGraphic > xGraphic; com::sun::star::awt::Size aSize; - bool bOK = TRUE; + bool bOK = sal_True; aMediaProps[0].Value <<= aURL; try { @@ -5812,7 +5575,7 @@ bool SvxIconSelectorDialog::ImportGraphic( const OUString& aURL ) { a >>= aSize; if ( 0 == aSize.Width || 0 == aSize.Height ) - bOK = FALSE; + bOK = sal_False; Image aImage( xGraphic ); @@ -5844,7 +5607,7 @@ bool SvxIconSelectorDialog::ImportGraphic( const OUString& aURL ) xConfigPersistence->store(); } - result = TRUE; + result = sal_True; } else { @@ -5906,7 +5669,7 @@ rtl::OUString SvxIconReplacementDialog :: ReplaceIconName( const OUString& rMess return name; } -USHORT SvxIconReplacementDialog :: ShowDialog() +sal_uInt16 SvxIconReplacementDialog :: ShowDialog() { this->Execute(); return ( this->GetCurButtonId() ); @@ -5928,8 +5691,8 @@ SvxIconChangeDialog::SvxIconChangeDialog( FreeResource(); aFImageInfo.SetImage(InfoBox::GetStandardImage()); aLineEditDescription.SetControlBackground( GetSettings().GetStyleSettings().GetDialogColor() ); - aLineEditDescription.SetAutoScroll( TRUE ); - aLineEditDescription.EnableCursor( FALSE ); + aLineEditDescription.SetAutoScroll( sal_True ); + aLineEditDescription.EnableCursor( sal_False ); aLineEditDescription.SetText(aMessage); } diff --git a/cui/source/customize/cfg.hrc b/cui/source/customize/cfg.hrc index 74d7804dce8e..302f226623a3 100644 --- a/cui/source/customize/cfg.hrc +++ b/cui/source/customize/cfg.hrc @@ -103,3 +103,8 @@ #define EDT_ADDR (121 + CFG_OFFSET) #define MD_BTN_OK (122 + CFG_OFFSET) #define FI_INFO (123 + CFG_OFFSET) + +//IAccessibility2 Implementation 2009----- +#define BUTTON_STR_UP (130 + CFG_OFFSET) +#define BUTTON_STR_DOWN (131 + CFG_OFFSET) +//-----IAccessibility2 Implementation 2009 diff --git a/cui/source/customize/cfg.src b/cui/source/customize/cfg.src index 0b2489557053..66ac237a523b 100644 --- a/cui/source/customize/cfg.src +++ b/cui/source/customize/cfg.src @@ -136,6 +136,7 @@ TabPage RID_SVXPAGE_MENUS }; ListBox LB_MENUS { + HelpID = "cui:ListBox:RID_SVXPAGE_MENUS:LB_MENUS"; Border = TRUE ; Pos = MAP_APPFONT ( 64 , 22 ) ; Size = MAP_APPFONT ( 108 , 108 ) ; @@ -143,6 +144,7 @@ TabPage RID_SVXPAGE_MENUS }; PushButton BTN_NEW { + HelpID = "cui:PushButton:RID_SVXPAGE_MENUS:BTN_NEW"; Pos = MAP_APPFONT ( 192 , 22 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -151,6 +153,7 @@ TabPage RID_SVXPAGE_MENUS }; MenuButton BTN_CHANGE { + HelpID = "cui:MenuButton:RID_SVXPAGE_MENUS:BTN_CHANGE"; Pos = MAP_APPFONT ( 192 , 39 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -181,6 +184,7 @@ TabPage RID_SVXPAGE_MENUS }; PushButton BTN_ADD_COMMANDS { + HelpID = "cui:PushButton:RID_SVXPAGE_MENUS:BTN_ADD_COMMANDS"; Pos = MAP_APPFONT ( 192 , 67 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -189,6 +193,7 @@ TabPage RID_SVXPAGE_MENUS }; MenuButton BTN_CHANGE_ENTRY { + HelpID = "cui:MenuButton:RID_SVXPAGE_MENUS:BTN_CHANGE_ENTRY"; Pos = MAP_APPFONT ( 192 , 84 ) ; Size = MAP_APPFONT ( 75 , 14 ) ; TabStop = TRUE ; @@ -197,6 +202,7 @@ TabPage RID_SVXPAGE_MENUS }; ImageButton BTN_UP { + HelpID = "cui:ImageButton:RID_SVXPAGE_MENUS:BTN_UP"; Pos = MAP_APPFONT ( 175 , 102 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TabStop = TRUE ; @@ -205,6 +211,7 @@ TabPage RID_SVXPAGE_MENUS }; ImageButton BTN_DOWN { + HelpID = "cui:ImageButton:RID_SVXPAGE_MENUS:BTN_DOWN"; Pos = MAP_APPFONT ( 175 , 119 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TabStop = TRUE ; @@ -220,6 +227,7 @@ TabPage RID_SVXPAGE_MENUS }; ListBox LB_SAVEIN { + HelpID = "cui:ListBox:RID_SVXPAGE_MENUS:LB_SAVEIN"; Border = TRUE ; Pos = MAP_APPFONT ( 64 , 188 ) ; Size = MAP_APPFONT ( 108 , 53 ) ; @@ -234,6 +242,7 @@ TabPage RID_SVXPAGE_MENUS }; MultiLineEdit ED_DESCRIPTION { + HelpID = "cui:MultiLineEdit:RID_SVXPAGE_MENUS:ED_DESCRIPTION"; Pos = MAP_APPFONT ( 6 , 216 ) ; Size = MAP_APPFONT ( 261 , 36 ) ; Border = TRUE; @@ -493,6 +502,7 @@ ModalDialog MD_MENU_ORGANISER }; Edit EDIT_MENU_NAME { + HelpID = "cui:Edit:MD_MENU_ORGANISER:EDIT_MENU_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 19 ) ; Size = MAP_APPFONT ( 93 , 12 ) ; @@ -517,6 +527,7 @@ ModalDialog MD_MENU_ORGANISER }; ImageButton BTN_MENU_UP { + HelpID = "cui:ImageButton:MD_MENU_ORGANISER:BTN_MENU_UP"; Pos = MAP_APPFONT ( 102 , 80 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TabStop = TRUE ; @@ -524,6 +535,7 @@ ModalDialog MD_MENU_ORGANISER }; ImageButton BTN_MENU_DOWN { + HelpID = "cui:ImageButton:MD_MENU_ORGANISER:BTN_MENU_DOWN"; Pos = MAP_APPFONT ( 102 , 97 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TabStop = TRUE ; @@ -550,6 +562,7 @@ ModalDialog MD_MENU_ORGANISER // MD_NEW_TOOLBAR ------------------------------------------------- ModalDialog MD_NEW_TOOLBAR { + HelpID = "cui:ModalDialog:MD_NEW_TOOLBAR"; OutputSize = TRUE ; SvLook = TRUE ; Size = MAP_APPFONT ( 165 , 63 ) ; @@ -565,6 +578,7 @@ ModalDialog MD_NEW_TOOLBAR }; Edit EDT_STRING { + HelpID = "cui:Edit:MD_NEW_TOOLBAR:EDT_STRING"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 17 ) ; Size = MAP_APPFONT ( 97 , 12 ) ; @@ -579,6 +593,7 @@ ModalDialog MD_NEW_TOOLBAR }; ListBox LB_SAVEIN { + HelpID = "cui:ListBox:MD_NEW_TOOLBAR:LB_SAVEIN"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 43 ) ; Size = MAP_APPFONT ( 97 , 53 ) ; @@ -654,6 +669,7 @@ ModalDialog MD_ICONSELECTOR }; PushButton BTN_IMPORT { + HelpID = "cui:PushButton:MD_ICONSELECTOR:BTN_IMPORT"; Pos = MAP_APPFONT ( 184 , 7 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -662,6 +678,7 @@ ModalDialog MD_ICONSELECTOR }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:MD_ICONSELECTOR:BTN_DELETE"; Pos = MAP_APPFONT ( 184 , 24 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -691,6 +708,7 @@ ModalDialog MD_ICONSELECTOR //added for issue83555 ModalDialog MD_ICONCHANGE { + HelpID = "cui:ModalDialog:MD_ICONCHANGE"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 200 , 150 ) ; @@ -714,6 +732,7 @@ ModalDialog MD_ICONCHANGE MultiLineEdit EDT_ADDR { + HelpID = "cui:MultiLineEdit:MD_ICONCHANGE:EDT_ADDR"; Pos = MAP_APPFONT ( 30 , 38) ; Size = MAP_APPFONT ( 140 , 83 ) ; Border = TRUE; @@ -869,4 +888,12 @@ String RID_SVXSTR_RENAME_TOOLBAR Text [ en-US ] = "Rename Toolbar"; }; +String BUTTON_STR_UP +{ + Text [ en-US ] = "Up"; +}; +String BUTTON_STR_DOWN +{ + Text [ en-US ] = "Down"; +}; diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx index 18f1fa122562..6ae157ad4426 100644 --- a/cui/source/customize/cfgutil.cxx +++ b/cui/source/customize/cfgutil.cxx @@ -57,7 +57,6 @@ #include <tools/urlobj.hxx> #include "cuires.hrc" #include <sfx2/app.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/minfitem.hxx> #include <unotools/processfactory.hxx> #include <comphelper/documentinfo.hxx> @@ -276,7 +275,7 @@ SfxConfigFunctionListBox_Impl::SfxConfigFunctionListBox_Impl( Window* pParent, c , pCurEntry( 0 ) , pStylesInfo( 0 ) { - SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); GetModel()->SetSortMode( SortAscending ); // Timer for the BallonHelp @@ -311,21 +310,18 @@ void SfxConfigFunctionListBox_Impl::ClearAll() vorhandenen MacroInfos. */ { - USHORT nCount = aArr.Count(); - for ( USHORT i=0; i<nCount; ++i ) + sal_uInt16 nCount = aArr.Count(); + for ( sal_uInt16 i=0; i<nCount; ++i ) { SfxGroupInfo_Impl *pData = aArr[i]; - if ( pData->nKind == SFX_CFGFUNCTION_MACRO || - pData->nKind == SFX_CFGFUNCTION_SCRIPT ) + if ( pData->nKind == SFX_CFGFUNCTION_SCRIPT ) { - SfxMacroInfo *pInfo = (SfxMacroInfo*) pData->pObject; - SFX_APP()->GetMacroConfig()->ReleaseSlotId( pInfo->GetSlotId() ); - delete pInfo; + String* pScriptURI = (String*)pData->pObject; + delete pScriptURI; } if ( pData->nKind == SFX_CFGGROUP_SCRIPTCONTAINER - || pData->nKind == SFX_CFGGROUP_DOCBASICMGR ) { XInterface* xi = static_cast<XInterface *>(pData->pObject); @@ -342,55 +338,16 @@ void SfxConfigFunctionListBox_Impl::ClearAll() Clear(); } -SvLBoxEntry* SfxConfigFunctionListBox_Impl::GetEntry_Impl( const String& rName ) -/* Beschreibung - Ermittelt den SvLBoxEntry zu einem "ubergebenen String. Das setzt voraus, da\s - die Namen eindeutig sind. -*/ -{ - SvLBoxEntry *pEntry = First(); - while ( pEntry ) - { - if ( GetEntryText( pEntry ) == rName ) - return pEntry; - pEntry = Next( pEntry ); - } - - return NULL; -} - -SvLBoxEntry* SfxConfigFunctionListBox_Impl::GetEntry_Impl( USHORT nId ) -/* Beschreibung - Ermittelt den SvLBoxEntry zu einer "ubergebenen Id. -*/ -{ - SvLBoxEntry *pEntry = First(); - while ( pEntry ) - { - SfxGroupInfo_Impl *pData = (SfxGroupInfo_Impl*) pEntry->GetUserData(); - if ( pData && pData->nOrd == nId ) - return pEntry; - pEntry = Next( pEntry ); - } - - return NULL; -} - -SfxMacroInfo* SfxConfigFunctionListBox_Impl::GetMacroInfo() -/* Beschreibung - Gibt die MacroInfo des selektierten Entry zur"uck ( sofern vorhanden ). -*/ +String SfxConfigFunctionListBox_Impl::GetSelectedScriptURI() { SvLBoxEntry *pEntry = FirstSelected(); if ( pEntry ) { SfxGroupInfo_Impl *pData = (SfxGroupInfo_Impl*) pEntry->GetUserData(); - if ( pData && ( pData->nKind == SFX_CFGFUNCTION_MACRO || - pData->nKind == SFX_CFGFUNCTION_SCRIPT ) ) - return (SfxMacroInfo*) pData->pObject; + if ( pData && ( pData->nKind == SFX_CFGFUNCTION_SCRIPT ) ) + return *(String*)pData->pObject; } - - return 0; + return String(); } String SfxConfigFunctionListBox_Impl::GetCurCommand() @@ -417,18 +374,6 @@ String SfxConfigFunctionListBox_Impl::GetCurLabel() return pData->sCommand; } -USHORT SfxConfigFunctionListBox_Impl::GetId( SvLBoxEntry *pEntry ) -/* Beschreibung - Gibt die Ordnungsnummer ( SlotId oder Macro-Nummer ) des Eintrags zur"uck. -*/ -{ - SfxGroupInfo_Impl *pData = pEntry ? - (SfxGroupInfo_Impl*) pEntry->GetUserData() : 0; - if ( pData ) - return pData->nOrd; - return 0; -} - void SfxConfigFunctionListBox_Impl::FunctionSelected() /* Beschreibung Setzt die Balloonhelp zur"uck, da diese immer den Helptext des selektierten @@ -454,7 +399,6 @@ struct SvxConfigGroupBoxResource_Impl : public Resource String m_sDlgMacros; String m_aHumanAppName; String m_aStrGroupStyles; - String m_aScriptType; Image m_collapsedImage; Image m_expandedImage; @@ -473,7 +417,6 @@ SvxConfigGroupBoxResource_Impl::SvxConfigGroupBoxResource_Impl() : m_sDlgMacros(String(CUI_RES(STR_DLG_MACROS))), m_aHumanAppName(String(CUI_RES(STR_HUMAN_APPNAME))), m_aStrGroupStyles(String(CUI_RES(STR_GROUP_STYLES))), - m_aScriptType(String(CUI_RES(STR_BASICNAME))), m_collapsedImage(CUI_RES(BMP_COLLAPSED)), m_expandedImage(CUI_RES(BMP_EXPANDED)) { @@ -481,41 +424,12 @@ SvxConfigGroupBoxResource_Impl::SvxConfigGroupBoxResource_Impl() : } SfxConfigGroupListBox_Impl::SfxConfigGroupListBox_Impl( - Window* pParent, const ResId& rResId, ULONG nConfigMode ) + Window* pParent, const ResId& rResId, sal_uLong nConfigMode ) : SvTreeListBox( pParent, rResId ) - , pImp(new SvxConfigGroupBoxResource_Impl()), pFunctionListBox(0), nMode( nConfigMode ), bShowSF( FALSE ), bShowBasic( TRUE ), pStylesInfo(0) + , pImp(new SvxConfigGroupBoxResource_Impl()), pFunctionListBox(0), nMode( nConfigMode ), pStylesInfo(0) { - SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HASBUTTONS | WB_HASLINES | WB_HASLINESATROOT | WB_HASBUTTONSATROOT ); + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HASBUTTONS | WB_HASLINES | WB_HASLINESATROOT | WB_HASBUTTONSATROOT ); SetNodeBitmaps( pImp->m_collapsedImage, pImp->m_expandedImage ); - - // Check configuration to see whether only Basic macros, - // only Scripting Framework scripts, or both should be listed - Any value; - sal_Bool tmp = false; - - value = ::utl::ConfigManager::GetConfigManager().GetLocalProperty( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "Office.Scripting/ScriptDisplaySettings/ShowBasic" ) ) ); - - value >>= tmp; - - if (tmp == sal_True) { - bShowBasic = TRUE; - } - else { - bShowBasic = FALSE; - } - - value = ::utl::ConfigManager::GetConfigManager().GetLocalProperty( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Scripting/ScriptDisplaySettings/ShowSF" ) ) ); - - value >>= tmp; - - if (tmp == sal_True) { - bShowSF = TRUE; - } - else { - bShowSF = FALSE; - } } @@ -526,12 +440,11 @@ SfxConfigGroupListBox_Impl::~SfxConfigGroupListBox_Impl() void SfxConfigGroupListBox_Impl::ClearAll() { - USHORT nCount = aArr.Count(); - for ( USHORT i=0; i<nCount; ++i ) + sal_uInt16 nCount = aArr.Count(); + for ( sal_uInt16 i=0; i<nCount; ++i ) { SfxGroupInfo_Impl *pData = aArr[i]; if ( pData->nKind == SFX_CFGGROUP_SCRIPTCONTAINER - || pData->nKind == SFX_CFGGROUP_DOCBASICMGR ) { XInterface* xi = static_cast<XInterface *>(pData->pObject); @@ -547,33 +460,6 @@ void SfxConfigGroupListBox_Impl::ClearAll() Clear(); } -void SfxConfigGroupListBox_Impl::SetScriptType( const String& rScriptType ) -{ - pImp->m_aScriptType = rScriptType; - ULONG nPos=0; - SvLBoxEntry *pEntry = (SvLBoxEntry*) GetModel()->GetEntryAtAbsPos( nPos ); - ++nPos; - while ( pEntry ) - { - SfxGroupInfo_Impl *pInfo = (SfxGroupInfo_Impl*) pEntry->GetUserData(); - if ( pInfo->nKind == SFX_CFGGROUP_BASICLIB && ( IsExpanded( pEntry ) || pInfo->bWasOpened ) ) - { - Collapse( pEntry ); - SvLBoxEntry *pChild = FirstChild( pEntry ); - while (pChild) - { - GetModel()->Remove( pChild ); - pChild = FirstChild( pEntry ); - } - - Expand( pEntry ); - } - - pEntry = (SvLBoxEntry*) GetModel()->GetEntryAtAbsPos( nPos ); - ++nPos; - } -} - void SfxConfigGroupListBox_Impl::SetStylesInfo(SfxStylesInfo_Impl* pStyles) { pStylesInfo = pStyles; @@ -592,18 +478,6 @@ String SfxConfigGroupListBox_Impl::GetGroup() if ( pInfo->nKind == SFX_CFGGROUP_FUNCTION ) return GetEntryText( pEntry ); - if ( pInfo->nKind == SFX_CFGGROUP_BASICMGR ) - { - BasicManager *pMgr = (BasicManager*) pInfo->pObject; - return pMgr->GetName(); - } - - if ( pInfo->nKind == SFX_CFGGROUP_DOCBASICMGR ) - { - Reference< XModel > xDoc( static_cast< XModel* >( pInfo->pObject ) ); - return ::comphelper::DocumentInfo::getDocumentTitle( xDoc ); - } - pEntry = GetParent( pEntry ); } @@ -611,27 +485,6 @@ String SfxConfigGroupListBox_Impl::GetGroup() } //----------------------------------------------- -BasicManager* SfxConfigGroupListBox_Impl::GetBasicManager( const SvLBoxEntry& _rEntry ) -{ - BasicManager* pBasMgr = NULL; - - SfxGroupInfo_Impl* pInfo = (SfxGroupInfo_Impl*) _rEntry.GetUserData(); - switch ( pInfo->nKind ) - { - case SFX_CFGGROUP_BASICMGR : - pBasMgr = (BasicManager*) pInfo->pObject; - break; - case SFX_CFGGROUP_DOCBASICMGR : - { - Reference< XModel > xDoc( static_cast< XModel* >( pInfo->pObject ) ); - pBasMgr = ::basic::BasicManagerRepository::getDocumentBasicManager( xDoc ); - } - break; - } - return pBasMgr; -} - -//----------------------------------------------- void SfxConfigGroupListBox_Impl::InitModule() { try @@ -735,7 +588,7 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul const css::uno::Reference< css::frame::XFrame >& xFrame , const ::rtl::OUString& sModuleLongName) { - SetUpdateMode(FALSE); + SetUpdateMode(sal_False); ClearAll(); // Remove all old entries from treelist box m_xFrame = xFrame; @@ -753,192 +606,139 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul InitStyles(); } - SfxApplication *pSfxApp = SFX_APP(); - if ( bShowBasic ) + OSL_TRACE("** ** About to initialise SF Scripts"); + // Add Scripting Framework entries + Reference< browse::XBrowseNode > rootNode; + Reference< XComponentContext > xCtx; + try { - // Basics einsammeln - pSfxApp->EnterBasicCall(); - String aMacroName(' '); - aMacroName += pImp->m_sDlgMacros; - - // Zuerst AppBasic - BasicManager *pAppBasicMgr = pSfxApp->GetBasicManager(); - BOOL bInsert = TRUE; - - if ( bInsert ) - { - pAppBasicMgr->SetName( pSfxApp->GetName() ); - if ( pAppBasicMgr->GetLibCount() ) - { - // Nur einf"ugen, wenn Bibliotheken vorhanden - String aAppBasTitle( pImp->m_aHumanAppName ); - aAppBasTitle += aMacroName; - SvLBoxEntry *pEntry = InsertEntry( aAppBasTitle, 0 ); - SfxGroupInfo_Impl *pInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_BASICMGR, 0, pAppBasicMgr ); - pEntry->SetUserData( pInfo ); - pEntry->EnableChildsOnDemand( TRUE ); - } - } - - Reference< XModel > xDoc( lcl_getScriptableDocument_nothrow( m_xFrame ) ); - if ( xDoc.is() ) - { - BasicManager* pBasicMgr = ::basic::BasicManagerRepository::getDocumentBasicManager( xDoc ); - if ( pBasicMgr != pAppBasicMgr && pBasicMgr->GetLibCount() ) - { - String sDocTitle( ::comphelper::DocumentInfo::getDocumentTitle( xDoc ) ); - pBasicMgr->SetName( sDocTitle ); - - // Nur einf"ugen, wenn eigenes Basic mit Bibliotheken - SvLBoxEntry *pEntry = InsertEntry( sDocTitle.Append( aMacroName ), NULL ); - xDoc->acquire(); - SfxGroupInfo_Impl *pInfo = - new SfxGroupInfo_Impl( SFX_CFGGROUP_DOCBASICMGR, 0, xDoc.get() ); - pEntry->SetUserData( pInfo ); - pEntry->EnableChildsOnDemand( TRUE ); - } - } - - pSfxApp->LeaveBasicCall(); + Reference < beans::XPropertySet > xProps( + ::comphelper::getProcessServiceFactory(), UNO_QUERY_THROW ); + xCtx.set( xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DefaultContext" ))), UNO_QUERY_THROW ); + Reference< browse::XBrowseNodeFactory > xFac( xCtx->getValueByName( + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory") ) ), UNO_QUERY_THROW ); + rootNode.set( xFac->createView( browse::BrowseNodeFactoryViewTypes::MACROSELECTOR ) ); + } + catch( Exception& e ) + { + OSL_TRACE(" Caught some exception whilst retrieving browse nodes from factory... Exception: %s", + ::rtl::OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).pData->buffer ); + // TODO exception handling } - OSL_TRACE("** ** About to initialise SF Scripts"); - if ( bShowSF ) + + if ( rootNode.is() ) { - OSL_TRACE("** ** bShowSF"); - // Add Scripting Framework entries - Reference< browse::XBrowseNode > rootNode; - Reference< XComponentContext > xCtx; - try + if ( nMode ) { - Reference < beans::XPropertySet > xProps( - ::comphelper::getProcessServiceFactory(), UNO_QUERY_THROW ); - xCtx.set( xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DefaultContext" ))), UNO_QUERY_THROW ); - Reference< browse::XBrowseNodeFactory > xFac( xCtx->getValueByName( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/singletons/com.sun.star.script.browse.theBrowseNodeFactory") ) ), UNO_QUERY_THROW ); - rootNode.set( xFac->createView( browse::BrowseNodeFactoryViewTypes::MACROSELECTOR ) ); + //We call acquire on the XBrowseNode so that it does not + //get autodestructed and become invalid when accessed later. + rootNode->acquire(); + + SfxGroupInfo_Impl *pInfo = + new SfxGroupInfo_Impl( SFX_CFGGROUP_SCRIPTCONTAINER, 0, + static_cast<void *>(rootNode.get())); + + String aTitle(pImp->m_sDlgMacros); + SvLBoxEntry *pNewEntry = InsertEntry( aTitle, NULL ); + pNewEntry->SetUserData( pInfo ); + pNewEntry->EnableChildsOnDemand( sal_True ); + aArr.Insert( pInfo, aArr.Count() ); } - catch( Exception& e ) + else { - OSL_TRACE(" Caught some exception whilst retrieving browse nodes from factory... Exception: %s", - ::rtl::OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).pData->buffer ); - // TODO exception handling - } - + //We are only showing scripts not slot APIs so skip + //Root node and show location nodes + try { + if ( rootNode->hasChildNodes() ) + { + Sequence< Reference< browse::XBrowseNode > > children = + rootNode->getChildNodes(); + sal_Bool bIsRootNode = sal_False; - if ( rootNode.is() ) - { - if ( nMode ) - { - //We call acquire on the XBrowseNode so that it does not - //get autodestructed and become invalid when accessed later. - rootNode->acquire(); - - SfxGroupInfo_Impl *pInfo = - new SfxGroupInfo_Impl( SFX_CFGGROUP_SCRIPTCONTAINER, 0, - static_cast<void *>(rootNode.get())); - - String aTitle(pImp->m_sDlgMacros); - SvLBoxEntry *pNewEntry = InsertEntry( aTitle, NULL ); - pNewEntry->SetUserData( pInfo ); - pNewEntry->EnableChildsOnDemand( TRUE ); - aArr.Insert( pInfo, aArr.Count() ); - } - else - { - //We are only showing scripts not slot APIs so skip - //Root node and show location nodes - try { - if ( rootNode->hasChildNodes() ) + ::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") ); + ::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share") ); + if ( rootNode->getName().equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Root") ) ) ) { - Sequence< Reference< browse::XBrowseNode > > children = - rootNode->getChildNodes(); - BOOL bIsRootNode = FALSE; - - ::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") ); - ::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share") ); - if ( rootNode->getName().equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Root") ) ) ) - { - bIsRootNode = TRUE; - } + bIsRootNode = sal_True; + } - //To mimic current starbasic behaviour we - //need to make sure that only the current document - //is displayed in the config tree. Tests below - //set the bDisplay flag to FALSE if the current - //node is a first level child of the Root and is NOT - //either the current document, user or share - ::rtl::OUString currentDocTitle; - Reference< XModel > xDocument( lcl_getScriptableDocument_nothrow( m_xFrame ) ); - if ( xDocument.is() ) - { - currentDocTitle = ::comphelper::DocumentInfo::getDocumentTitle( xDocument ); - } + //To mimic current starbasic behaviour we + //need to make sure that only the current document + //is displayed in the config tree. Tests below + //set the bDisplay flag to FALSE if the current + //node is a first level child of the Root and is NOT + //either the current document, user or share + ::rtl::OUString currentDocTitle; + Reference< XModel > xDocument( lcl_getScriptableDocument_nothrow( m_xFrame ) ); + if ( xDocument.is() ) + { + currentDocTitle = ::comphelper::DocumentInfo::getDocumentTitle( xDocument ); + } - for ( sal_Int32 n = 0; n < children.getLength(); ++n ) + for ( sal_Int32 n = 0; n < children.getLength(); ++n ) + { + Reference< browse::XBrowseNode >& theChild = children[n]; + sal_Bool bDisplay = sal_True; + ::rtl::OUString uiName = theChild->getName(); + if ( bIsRootNode ) { - Reference< browse::XBrowseNode >& theChild = children[n]; - BOOL bDisplay = TRUE; - ::rtl::OUString uiName = theChild->getName(); - if ( bIsRootNode ) + if ( ! ((theChild->getName().equals( user ) || theChild->getName().equals( share ) || + theChild->getName().equals( currentDocTitle ) ) ) ) + { + bDisplay=sal_False; + } + else { - if ( ! ((theChild->getName().equals( user ) || theChild->getName().equals( share ) || - theChild->getName().equals( currentDocTitle ) ) ) ) + if ( uiName.equals( user ) ) { - bDisplay=FALSE; + uiName = pImp->m_sMyMacros; } - else + else if ( uiName.equals( share ) ) { - if ( uiName.equals( user ) ) - { - uiName = pImp->m_sMyMacros; - } - else if ( uiName.equals( share ) ) - { - uiName = pImp->m_sProdMacros; - } + uiName = pImp->m_sProdMacros; } } - if (children[n]->getType() != browse::BrowseNodeTypes::SCRIPT && bDisplay ) - { + } + if (children[n]->getType() != browse::BrowseNodeTypes::SCRIPT && bDisplay ) + { // We call acquire on the XBrowseNode so that it does not // get autodestructed and become invalid when accessed later. - theChild->acquire(); + theChild->acquire(); - SfxGroupInfo_Impl* pInfo = - new SfxGroupInfo_Impl(SFX_CFGGROUP_SCRIPTCONTAINER, - 0, static_cast<void *>( theChild.get())); + SfxGroupInfo_Impl* pInfo = + new SfxGroupInfo_Impl(SFX_CFGGROUP_SCRIPTCONTAINER, + 0, static_cast<void *>( theChild.get())); - Image aImage = GetImage( theChild, xCtx, bIsRootNode ); - SvLBoxEntry* pNewEntry = - InsertEntry( uiName, NULL); - SetExpandedEntryBmp( pNewEntry, aImage ); - SetCollapsedEntryBmp( pNewEntry, aImage ); + Image aImage = GetImage( theChild, xCtx, bIsRootNode ); + SvLBoxEntry* pNewEntry = + InsertEntry( uiName, NULL); + SetExpandedEntryBmp( pNewEntry, aImage ); + SetCollapsedEntryBmp( pNewEntry, aImage ); - pNewEntry->SetUserData( pInfo ); - aArr.Insert( pInfo, aArr.Count() ); + pNewEntry->SetUserData( pInfo ); + aArr.Insert( pInfo, aArr.Count() ); - if ( children[n]->hasChildNodes() ) - { - Sequence< Reference< browse::XBrowseNode > > grandchildren = - children[n]->getChildNodes(); + if ( children[n]->hasChildNodes() ) + { + Sequence< Reference< browse::XBrowseNode > > grandchildren = + children[n]->getChildNodes(); - for ( sal_Int32 m = 0; m < grandchildren.getLength(); ++m ) + for ( sal_Int32 m = 0; m < grandchildren.getLength(); ++m ) + { + if ( grandchildren[m]->getType() == browse::BrowseNodeTypes::CONTAINER ) { - if ( grandchildren[m]->getType() == browse::BrowseNodeTypes::CONTAINER ) - { - pNewEntry->EnableChildsOnDemand( TRUE ); - m = grandchildren.getLength(); - } + pNewEntry->EnableChildsOnDemand( sal_True ); + m = grandchildren.getLength(); } } } } } } - catch (RuntimeException&) { - // do nothing, the entry will not be displayed in the UI - } + } + catch (RuntimeException&) { + // do nothing, the entry will not be displayed in the UI } } } @@ -951,11 +751,11 @@ void SfxConfigGroupListBox_Impl::Init(const css::uno::Reference< css::lang::XMul SfxGroupInfo_Impl *pInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_STYLES, 0, 0 ); // TODO last parameter should contain user data aArr.Insert( pInfo, aArr.Count() ); pEntry->SetUserData( pInfo ); - pEntry->EnableChildsOnDemand( TRUE ); + pEntry->EnableChildsOnDemand( sal_True ); } MakeVisible( GetEntry( 0,0 ) ); - SetUpdateMode( TRUE ); + SetUpdateMode( sal_True ); } Image SfxConfigGroupListBox_Impl::GetImage( Reference< browse::XBrowseNode > node, @@ -1066,25 +866,6 @@ SfxConfigGroupListBox_Impl::getDocumentModel( Reference< XComponentContext >& xC return xModel; } -::rtl::OUString SfxConfigGroupListBox_Impl::parseLocationName( const ::rtl::OUString& location ) -{ - // strip out the last leaf of location name - // e.g. file://dir1/dir2/Blah.sxw - > Blah.sxw - ::rtl::OUString temp = location; - sal_Int32 lastSlashIndex = temp.lastIndexOf( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/" ) ) ); - - if ( ( lastSlashIndex + 1 ) < temp.getLength() ) - { - temp = temp.copy( lastSlashIndex + 1 ); - } - // maybe we should throw here!!! - else - { - OSL_TRACE("Something wrong with name, perhaps we should throw an exception"); - } - return temp; -} - //----------------------------------------------- ::rtl::OUString SfxConfigGroupListBox_Impl::MapCommand2UIName(const ::rtl::OUString& sCommand) { @@ -1122,14 +903,13 @@ void SfxConfigGroupListBox_Impl::GroupSelected() { SvLBoxEntry *pEntry = FirstSelected(); SfxGroupInfo_Impl *pInfo = (SfxGroupInfo_Impl*) pEntry->GetUserData(); - pFunctionListBox->SetUpdateMode(FALSE); + pFunctionListBox->SetUpdateMode(sal_False); pFunctionListBox->ClearAll(); if ( pInfo->nKind != SFX_CFGGROUP_FUNCTION && - pInfo->nKind != SFX_CFGGROUP_BASICMOD && pInfo->nKind != SFX_CFGGROUP_SCRIPTCONTAINER && pInfo->nKind != SFX_CFGGROUP_STYLES ) { - pFunctionListBox->SetUpdateMode(TRUE); + pFunctionListBox->SetUpdateMode(sal_True); return; } @@ -1137,7 +917,7 @@ void SfxConfigGroupListBox_Impl::GroupSelected() { case SFX_CFGGROUP_FUNCTION : { - USHORT nGroup = pInfo->nOrd; + sal_uInt16 nGroup = pInfo->nUniqueID; css::uno::Reference< css::frame::XDispatchInformationProvider > xProvider (m_xFrame, css::uno::UNO_QUERY_THROW); css::uno::Sequence< css::frame::DispatchInformation > lCommands = xProvider->getConfigurableDispatchInformation(nGroup); sal_Int32 c = lCommands.getLength(); @@ -1157,45 +937,6 @@ void SfxConfigGroupListBox_Impl::GroupSelected() break; } - case SFX_CFGGROUP_BASICMOD : - { - SvLBoxEntry *pLibEntry = GetParent( pEntry ); - SfxGroupInfo_Impl *pLibInfo = - (SfxGroupInfo_Impl*) pLibEntry->GetUserData(); - SvLBoxEntry *pBasEntry = GetParent( pLibEntry ); - SfxGroupInfo_Impl *pBasInfo = - (SfxGroupInfo_Impl*) pBasEntry->GetUserData(); - - StarBASIC *pLib = (StarBASIC*) pLibInfo->pObject; - Reference< XModel > xDoc; - if ( pBasInfo->nKind == SFX_CFGGROUP_DOCBASICMGR ) - xDoc = static_cast< XModel* >( pBasInfo->pObject ); - - SbModule *pMod = (SbModule*) pInfo->pObject; - for ( USHORT nMeth=0; nMeth < pMod->GetMethods()->Count(); ++nMeth ) - { - SbxMethod *pMeth = (SbxMethod*)pMod->GetMethods()->Get(nMeth); - SfxMacroInfoPtr pInf = new SfxMacroInfo( !xDoc.is(), - pLib->GetName(), - pMod->GetName(), - pMeth->GetName()); - if ( pMeth->GetInfo() ) - pInf->SetHelpText( pMeth->GetInfo()->GetComment() ); - USHORT nId = SFX_APP()->GetMacroConfig()->GetSlotId( pInf ); - if ( !nId ) - break; // Kein Slot mehr frei - - SvLBoxEntry* pFuncEntry = - pFunctionListBox->InsertEntry( pMeth->GetName(), NULL ); - SfxGroupInfo_Impl *pGrpInfo = - new SfxGroupInfo_Impl( SFX_CFGFUNCTION_MACRO, nId, pInf ); - pFunctionListBox->aArr.Insert( pGrpInfo, pFunctionListBox->aArr.Count() ); - pFuncEntry->SetUserData( pGrpInfo ); - } - - break; - } - case SFX_CFGGROUP_SCRIPTCONTAINER: { if ( !GetChildCount( pEntry ) ) @@ -1225,13 +966,8 @@ void SfxConfigGroupListBox_Impl::GroupSelected() xPropSet->getPropertyValue( String::CreateFromAscii( "URI" ) ); value >>= uri; - SfxMacroInfo* aInfo = new SfxMacroInfo( (String)uri ); - aInfo->SetHelpText( uri ); - SFX_APP()->GetMacroConfig()->GetSlotId( aInfo ); - - SfxGroupInfo_Impl* pGrpInfo = - new SfxGroupInfo_Impl(SFX_CFGFUNCTION_SCRIPT, - aInfo->GetSlotId(), aInfo); + String* pScriptURI = new String( uri ); + SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGFUNCTION_SCRIPT, 0, pScriptURI ); Image aImage = GetImage( children[n], Reference< XComponentContext >(), sal_False ); SvLBoxEntry* pNewEntry = @@ -1287,31 +1023,31 @@ void SfxConfigGroupListBox_Impl::GroupSelected() if ( pFunctionListBox->GetEntryCount() ) pFunctionListBox->Select( pFunctionListBox->GetEntry( 0, 0 ) ); - pFunctionListBox->SetUpdateMode(TRUE); + pFunctionListBox->SetUpdateMode(sal_True); } -BOOL SfxConfigGroupListBox_Impl::Expand( SvLBoxEntry* pParent ) +sal_Bool SfxConfigGroupListBox_Impl::Expand( SvLBoxEntry* pParent ) { - BOOL bRet = SvTreeListBox::Expand( pParent ); + sal_Bool bRet = SvTreeListBox::Expand( pParent ); if ( bRet ) { // Wieviele Entries k"onnen angezeigt werden ? - ULONG nEntries = GetOutputSizePixel().Height() / GetEntryHeight(); + sal_uLong nEntries = GetOutputSizePixel().Height() / GetEntryHeight(); // Wieviele Kinder sollen angezeigt werden ? - ULONG nChildCount = GetVisibleChildCount( pParent ); + sal_uLong nChildCount = GetVisibleChildCount( pParent ); // Passen alle Kinder und der parent gleichzeitig in die View ? if ( nChildCount+1 > nEntries ) { // Wenn nicht, wenigstens parent ganz nach oben schieben - MakeVisible( pParent, TRUE ); + MakeVisible( pParent, sal_True ); } else { // An welcher relativen ViewPosition steht der aufzuklappende parent SvLBoxEntry *pEntry = GetFirstEntryInView(); - ULONG nParentPos = 0; + sal_uLong nParentPos = 0; while ( pEntry && pEntry != pParent ) { ++nParentPos; @@ -1333,69 +1069,9 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) */ { SfxGroupInfo_Impl *pInfo = (SfxGroupInfo_Impl*) pEntry->GetUserData(); - pInfo->bWasOpened = TRUE; + pInfo->bWasOpened = sal_True; switch ( pInfo->nKind ) { - case SFX_CFGGROUP_BASICMGR : - case SFX_CFGGROUP_DOCBASICMGR : - { - if ( !GetChildCount( pEntry ) ) - { - // Erstmaliges "Offnen - BasicManager* pMgr( GetBasicManager( *pEntry ) ); - - SvLBoxEntry *pLibEntry = 0; - for ( USHORT nLib=0; nLib<pMgr->GetLibCount(); ++nLib ) - { - StarBASIC* pLib = pMgr->GetLib( nLib ); - pLibEntry = InsertEntry( pMgr->GetLibName( nLib ), pEntry ); - SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_BASICLIB, nLib, pLib ); - aArr.Insert( pGrpInfo, aArr.Count() ); - pLibEntry->SetUserData( pGrpInfo ); - pLibEntry->EnableChildsOnDemand( TRUE ); - } - } - - break; - } - - case SFX_CFGGROUP_BASICLIB : - { - if ( !GetChildCount( pEntry ) ) - { - // Erstmaliges "Offnen - StarBASIC *pLib = (StarBASIC*) pInfo->pObject; - if ( !pLib ) - { - // Lib mu\s nachgeladen werden - SvLBoxEntry *pParent = GetParent( pEntry ); - BasicManager *pMgr( GetBasicManager( *pParent ) ); - - if ( pMgr->LoadLib( pInfo->nOrd ) ) - pInfo->pObject = pLib = pMgr->GetLib( pInfo->nOrd ); - else - break; - } - - SvLBoxEntry *pModEntry = 0; - for ( USHORT nMod=0; nMod<pLib->GetModules()->Count(); ++nMod ) - { - SbModule* pMod = (SbModule*)pLib->GetModules()->Get( nMod ); - - BOOL bIsStarScript = FALSE; - BOOL bWantsStarScript = pImp->m_aScriptType.EqualsAscii("StarScript"); - if ( bIsStarScript != bWantsStarScript ) - continue; - pModEntry = InsertEntry( pMod->GetName(), pEntry ); - SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_BASICMOD, 0, pMod ); - aArr.Insert( pGrpInfo, aArr.Count() ); - pModEntry->SetUserData( pGrpInfo ); - } - } - - break; - } - case SFX_CFGGROUP_SCRIPTCONTAINER: { if ( !GetChildCount( pEntry ) ) @@ -1408,19 +1084,19 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) { Sequence< Reference< browse::XBrowseNode > > children = rootNode->getChildNodes(); - BOOL bIsRootNode = FALSE; + sal_Bool bIsRootNode = sal_False; ::rtl::OUString user( RTL_CONSTASCII_USTRINGPARAM("user") ); ::rtl::OUString share( RTL_CONSTASCII_USTRINGPARAM("share" )); if ( rootNode->getName().equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Root") ) ) ) { - bIsRootNode = TRUE; + bIsRootNode = sal_True; } /* To mimic current starbasic behaviour we need to make sure that only the current document is displayed in the config tree. Tests below - set the bDisplay flag to FALSE if the current + set the bDisplay flag to sal_False if the current node is a first level child of the Root and is NOT either the current document, user or share */ ::rtl::OUString currentDocTitle; @@ -1435,11 +1111,11 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) { Reference< browse::XBrowseNode >& theChild = children[n]; ::rtl::OUString aName( theChild->getName() ); - BOOL bDisplay = TRUE; + sal_Bool bDisplay = sal_True; if ( bIsRootNode ) { if ( !( (aName.equals(user) || aName.equals(share) || aName.equals(currentDocTitle) ) ) ) - bDisplay=FALSE; + bDisplay=sal_False; } if ( children[n].is() && children[n]->getType() != browse::BrowseNodeTypes::SCRIPT && bDisplay ) { @@ -1472,7 +1148,7 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) { if ( grandchildren[m]->getType() == browse::BrowseNodeTypes::CONTAINER ) { - pNewEntry->EnableChildsOnDemand( TRUE ); + pNewEntry->EnableChildsOnDemand( sal_True ); m = grandchildren.getLength(); } } @@ -1503,7 +1179,7 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_STYLES, 0, pFamily ); aArr.Insert( pGrpInfo, aArr.Count() ); pStyleEntry->SetUserData( pGrpInfo ); - pStyleEntry->EnableChildsOnDemand( FALSE ); + pStyleEntry->EnableChildsOnDemand( sal_False ); } } break; @@ -1515,10 +1191,6 @@ void SfxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) } } -void SfxConfigGroupListBox_Impl::AddAndSelect( const SfxStringItem* , const SfxStringItem* ) -{ -} - void SfxConfigGroupListBox_Impl::SelectMacro( const SfxMacroInfoItem *pItem ) { SelectMacro( pItem->GetBasicManager()->GetName(), @@ -1532,7 +1204,7 @@ void SfxConfigGroupListBox_Impl::SelectMacro( const String& rBasic, aBasicName += ' '; aBasicName += pImp->m_sMacros; String aLib, aModule, aMethod; - USHORT nCount = rMacro.GetTokenCount('.'); + sal_uInt16 nCount = rMacro.GetTokenCount('.'); aMethod = rMacro.GetToken( nCount-1, '.' ); if ( nCount > 2 ) { diff --git a/cui/source/customize/eventdlg.cxx b/cui/source/customize/eventdlg.cxx index 02383fc0b3bf..7b4c04edbae6 100644 --- a/cui/source/customize/eventdlg.cxx +++ b/cui/source/customize/eventdlg.cxx @@ -41,7 +41,6 @@ #include <sfx2/viewfrm.hxx> #include <sfx2/evntconf.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/minfitem.hxx> #include <sfx2/app.hxx> #include <sfx2/objsh.hxx> @@ -69,7 +68,7 @@ SvxEventConfigPage::SvxEventConfigPage( Window *pParent, const SfxItemSet& rSet, _SvxMacroTabPage( pParent, CUI_RES(RID_SVXPAGE_EVENTS), rSet ), aSaveInText( this, CUI_RES( TXT_SAVEIN ) ), aSaveInListBox( this, CUI_RES( LB_SAVEIN ) ), - bAppConfig ( TRUE ) + bAppConfig ( sal_True ) { mpImpl->pStrEvent = new String( CUI_RES( STR_EVENT )); mpImpl->pAssignedMacro = new String( CUI_RES( STR_ASSMACRO )); @@ -98,7 +97,7 @@ SvxEventConfigPage::SvxEventConfigPage( Window *pParent, const SfxItemSet& rSet, "com.sun.star.frame.GlobalEventBroadcaster" )) ), uno::UNO_QUERY ); - USHORT nPos(0); + sal_uInt16 nPos(0); if ( xSupplier.is() ) { m_xAppEvents = xSupplier->getEvents(); @@ -107,7 +106,7 @@ SvxEventConfigPage::SvxEventConfigPage( Window *pParent, const SfxItemSet& rSet, utl::ConfigManager::PRODUCTNAME ) >>= label; nPos = aSaveInListBox.InsertEntry( label ); aSaveInListBox.SetEntryData( nPos, new bool(true) ); - aSaveInListBox.SelectEntryPos( nPos, TRUE ); + aSaveInListBox.SelectEntryPos( nPos, sal_True ); } } @@ -163,10 +162,10 @@ void SvxEventConfigPage::ImplInitDocument() m_xDocumentModifiable = m_xDocumentModifiable.query( xModel ); OUString aTitle = ::comphelper::DocumentInfo::getDocumentTitle( xModel ); - USHORT nPos = aSaveInListBox.InsertEntry( aTitle ); + sal_uInt16 nPos = aSaveInListBox.InsertEntry( aTitle ); aSaveInListBox.SetEntryData( nPos, new bool(false) ); - aSaveInListBox.SelectEntryPos( nPos, TRUE ); + aSaveInListBox.SelectEntryPos( nPos, sal_True ); bAppConfig = false; } @@ -186,16 +185,16 @@ IMPL_LINK( SvxEventConfigPage, SelectHdl_Impl, ListBox *, pBox ) bool* bApp = (bool*) aSaveInListBox.GetEntryData( aSaveInListBox.GetSelectEntryPos()); - mpImpl->pEventLB->SetUpdateMode( FALSE ); + mpImpl->pEventLB->SetUpdateMode( sal_False ); bAppConfig = *bApp; if ( *bApp ) { - SetReadOnly( FALSE ); + SetReadOnly( sal_False ); _SvxMacroTabPage::DisplayAppEvents( true ); } else { - bool isReadonly = FALSE; + bool isReadonly = sal_False; uno::Reference< frame::XFramesSupplier > xFramesSupplier( ::comphelper::getProcessServiceFactory()->createInstance( @@ -222,13 +221,13 @@ IMPL_LINK( SvxEventConfigPage, SelectHdl_Impl, ListBox *, pBox ) _SvxMacroTabPage::DisplayAppEvents( false ); } - mpImpl->pEventLB->SetUpdateMode( TRUE ); - return TRUE; + mpImpl->pEventLB->SetUpdateMode( sal_True ); + return sal_True; } // ----------------------------------------------------------------------- -BOOL SvxEventConfigPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxEventConfigPage::FillItemSet( SfxItemSet& rSet ) { return _SvxMacroTabPage::FillItemSet( rSet ); } diff --git a/cui/source/customize/eventdlg.hxx b/cui/source/customize/eventdlg.hxx index c25fe2ae8d74..bbd839b7e2aa 100644 --- a/cui/source/customize/eventdlg.hxx +++ b/cui/source/customize/eventdlg.hxx @@ -49,7 +49,7 @@ class SvxEventConfigPage : public _SvxMacroTabPage ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > m_xDocumentEvents; ::com::sun::star::uno::Reference< ::com::sun::star::util::XModifiable > m_xDocumentModifiable; - BOOL bAppConfig; + sal_Bool bAppConfig; DECL_LINK( SelectHdl_Impl, ListBox* ); @@ -66,7 +66,7 @@ public: void LateInit( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _rxFrame ); protected: - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet& ); using _SvxMacroTabPage::Reset; diff --git a/cui/source/customize/eventdlg.src b/cui/source/customize/eventdlg.src index b121caca1420..c4ef082b286d 100644 --- a/cui/source/customize/eventdlg.src +++ b/cui/source/customize/eventdlg.src @@ -63,6 +63,7 @@ TabPage RID_SVXPAGE_EVENTS }; ListBox LB_SAVEIN { + HelpID = "cui:ListBox:RID_SVXPAGE_EVENTS:LB_SAVEIN"; Border = TRUE ; Pos = MAP_APPFONT ( 54 , 238 ) ; Size = MAP_APPFONT ( 132 , 53 ) ; @@ -76,6 +77,7 @@ TabPage RID_SVXPAGE_EVENTS }; PushButton PB_ASSIGN { + HelpID = "cui:PushButton:RID_SVXPAGE_EVENTS:PB_ASSIGN"; Pos = MAP_APPFONT ( 217 , ROW0A ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Disable = TRUE ; @@ -83,6 +85,7 @@ TabPage RID_SVXPAGE_EVENTS }; PushButton PB_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_EVENTS:PB_DELETE"; Pos = MAP_APPFONT ( 217 , ROW0A+RSC_CD_PUSHBUTTON_HEIGHT+12 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Disable = TRUE ; diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx index 3f26f09d9761..62731acc4b68 100644 --- a/cui/source/customize/macropg.cxx +++ b/cui/source/customize/macropg.cxx @@ -37,7 +37,6 @@ #include <tools/diagnose_ex.h> #include <sfx2/app.hxx> #include <sfx2/objsh.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/sfxdefs.hxx> #include <com/sun/star/container/NoSuchElementException.hpp> #include <com/sun/star/lang/IllegalArgumentException.hpp> @@ -71,11 +70,11 @@ _SvxMacroTabPage_Impl::_SvxMacroTabPage_Impl( const SfxItemSet& rAttrSet ) : pStrEvent( NULL ), pAssignedMacro( NULL ), pEventLB( NULL ), - bReadOnly( FALSE ), - bIDEDialogMode( FALSE ) + bReadOnly( sal_False ), + bIDEDialogMode( sal_False ) { const SfxPoolItem* pItem; - if ( SFX_ITEM_SET == rAttrSet.GetItemState( SID_ATTR_MACROITEM, FALSE, &pItem ) ) + if ( SFX_ITEM_SET == rAttrSet.GetItemState( SID_ATTR_MACROITEM, sal_False, &pItem ) ) bIDEDialogMode = ((const SfxBoolItem*)pItem)->GetValue(); } @@ -121,7 +120,7 @@ IMPL_LINK( _HeaderTabListBox, HeaderEndDrag_Impl, HeaderBar*, pBar ) if( !maHeaderBar.IsItemMode() ) { Size aSz; - USHORT _nTabs = maHeaderBar.GetItemCount(); + sal_uInt16 _nTabs = maHeaderBar.GetItemCount(); long nWidth = maHeaderBar.GetItemSize( ITEMID_EVENT ); long nBarWidth = maHeaderBar.GetSizePixel().Width(); @@ -132,7 +131,7 @@ IMPL_LINK( _HeaderTabListBox, HeaderEndDrag_Impl, HeaderBar*, pBar ) { long _nWidth, nTmpSz = 0; - for( USHORT i = 1 ; i < _nTabs ; ++i ) + for( sal_uInt16 i = 1 ; i < _nTabs ; ++i ) { _nWidth = maHeaderBar.GetItemSize( i ); aSz.Width() = _nWidth + nTmpSz; @@ -189,7 +188,7 @@ void _HeaderTabListBox::ConnectElements( void ) maListBox.InitHeaderBar( &maHeaderBar ); } -void _HeaderTabListBox::Show( BOOL bVisible, USHORT nFlags ) +void _HeaderTabListBox::Show( sal_Bool bVisible, sal_uInt16 nFlags ) { maListBox.Show( bVisible, nFlags ); maHeaderBar.Show( bVisible, nFlags ); @@ -204,7 +203,7 @@ void _HeaderTabListBox::Enable( bool bEnable, bool bChild ) // assign button ("Add Command") is enabled only if it is not read only // delete button ("Remove Command") is enabled if a current binding exists // and it is not read only -void _SvxMacroTabPage::EnableButtons( const String& /*rLangName*/ ) +void _SvxMacroTabPage::EnableButtons() { const SvLBoxEntry* pE = mpImpl->pEventLB->GetListBox().FirstSelected(); if ( pE ) @@ -329,7 +328,7 @@ void _SvxMacroTabPage::InitResources() // the following method is called when the user clicks OK // We use the contents of the hashes to replace the settings -BOOL _SvxMacroTabPage::FillItemSet( SfxItemSet& /*rSet*/ ) +sal_Bool _SvxMacroTabPage::FillItemSet( SfxItemSet& /*rSet*/ ) { try { @@ -380,7 +379,7 @@ BOOL _SvxMacroTabPage::FillItemSet( SfxItemSet& /*rSet*/ ) { } // what is the return value about?? - return FALSE; + return sal_False; } // the following method clears the bindings in the hashes for both doc & app @@ -427,12 +426,12 @@ void _SvxMacroTabPage::Reset() DisplayAppEvents(bAppEvents); } -void _SvxMacroTabPage::SetReadOnly( BOOL bSet ) +void _SvxMacroTabPage::SetReadOnly( sal_Bool bSet ) { mpImpl->bReadOnly = bSet; } -BOOL _SvxMacroTabPage::IsReadOnly() const +sal_Bool _SvxMacroTabPage::IsReadOnly() const { return mpImpl->bReadOnly; } @@ -445,13 +444,13 @@ class IconLBoxString : public SvLBoxString int m_nxImageOffset; public: - IconLBoxString( SvLBoxEntry* pEntry, USHORT nFlags, const String& sText, + IconLBoxString( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& sText, Image* pMacroImg, Image* pComponentImg ); - virtual void Paint(const Point& aPos, SvLBox& aDevice, USHORT nFlags, SvLBoxEntry* pEntry ); + virtual void Paint(const Point& aPos, SvLBox& aDevice, sal_uInt16 nFlags, SvLBoxEntry* pEntry ); }; -IconLBoxString::IconLBoxString( SvLBoxEntry* pEntry, USHORT nFlags, const String& sText, +IconLBoxString::IconLBoxString( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& sText, Image* pMacroImg, Image* pComponentImg ) : SvLBoxString( pEntry, nFlags, sText ) , m_pMacroImg( pMacroImg ) @@ -462,7 +461,7 @@ IconLBoxString::IconLBoxString( SvLBoxEntry* pEntry, USHORT nFlags, const String //=============================================== void IconLBoxString::Paint( const Point& aPos, SvLBox& aDevice, - USHORT /*nFlags*/, SvLBoxEntry* /*pEntry*/ ) + sal_uInt16 /*nFlags*/, SvLBoxEntry* /*pEntry*/ ) { String aTxt( GetText() ); if( aTxt.Len() ) @@ -500,7 +499,7 @@ void _SvxMacroTabPage::DisplayAppEvents( bool appEvents) bAppEvents = appEvents; SvHeaderTabListBox& rListBox = mpImpl->pEventLB->GetListBox(); - mpImpl->pEventLB->SetUpdateMode( FALSE ); + mpImpl->pEventLB->SetUpdateMode( sal_False ); rListBox.Clear(); SvLBoxEntry* pE = rListBox.GetEntry( 0 ); EventsHash* eventsHash; @@ -568,8 +567,8 @@ void _SvxMacroTabPage::DisplayAppEvents( bool appEvents) rListBox.MakeVisible( pE ); } - rListBox.SetUpdateMode( TRUE ); - EnableButtons( String() ); + rListBox.SetUpdateMode( sal_True ); + EnableButtons(); } // select event handler on the listbox @@ -578,7 +577,7 @@ IMPL_STATIC_LINK( _SvxMacroTabPage, SelectEvent_Impl, SvTabListBox*, EMPTYARG ) _SvxMacroTabPage_Impl* pImpl = pThis->mpImpl; SvHeaderTabListBox& rListBox = pImpl->pEventLB->GetListBox(); SvLBoxEntry* pE = rListBox.FirstSelected(); - ULONG nPos; + sal_uLong nPos; if( !pE || LISTBOX_ENTRY_NOTFOUND == ( nPos = rListBox.GetModel()->GetAbsPos( pE ) ) ) @@ -587,7 +586,7 @@ IMPL_STATIC_LINK( _SvxMacroTabPage, SelectEvent_Impl, SvTabListBox*, EMPTYARG ) return 0; } - pThis->EnableButtons( String() ); + pThis->EnableButtons(); return 0; } @@ -607,7 +606,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton* _SvxMacroTabPage_Impl* pImpl = pThis->mpImpl; SvHeaderTabListBox& rListBox = pImpl->pEventLB->GetListBox(); SvLBoxEntry* pE = rListBox.FirstSelected(); - ULONG nPos; + sal_uLong nPos; if( !pE || LISTBOX_ENTRY_NOTFOUND == ( nPos = rListBox.GetModel()->GetAbsPos( pE ) ) ) { @@ -615,7 +614,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton* return 0; } - const BOOL bAssEnabled = pBtn != pImpl->pDeletePB && pImpl->pAssignPB->IsEnabled(); + const sal_Bool bAssEnabled = pBtn != pImpl->pDeletePB && pImpl->pAssignPB->IsEnabled(); ::rtl::OUString* pEventName = (::rtl::OUString*)pE->GetUserData(); @@ -673,7 +672,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton* else if( bAssEnabled ) { // assign pressed - SvxScriptSelectorDialog* pDlg = new SvxScriptSelectorDialog( pThis, FALSE, pThis->GetFrame() ); + SvxScriptSelectorDialog* pDlg = new SvxScriptSelectorDialog( pThis, sal_False, pThis->GetFrame() ); if( pDlg ) { short ret = pDlg->Execute(); @@ -702,16 +701,16 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton* } // update the listbox entry - pImpl->pEventLB->SetUpdateMode( FALSE ); + pImpl->pEventLB->SetUpdateMode( sal_False ); pE->ReplaceItem( new IconLBoxString( pE, 0, sEventURL, pImpl->pMacroImg, pImpl->pComponentImg ), LB_MACROS_ITEMPOS ); rListBox.GetModel()->InvalidateEntry( pE ); rListBox.Select( pE ); rListBox.MakeVisible( pE ); - rListBox.SetUpdateMode( TRUE ); + rListBox.SetUpdateMode( sal_True ); - pThis->EnableButtons( String() ); + pThis->EnableButtons(); return 0; } @@ -749,7 +748,7 @@ void _SvxMacroTabPage::InitAndSetHandler( Reference< container::XNameReplace> xA mpImpl->pEventLB->GetListBox().SetEntryHeight( sal::static_int_cast< short >(nMinLineHeight) ); - mpImpl->pEventLB->Enable( TRUE ); + mpImpl->pEventLB->Enable( sal_True ); if(!m_xAppEvents.is()) { @@ -854,7 +853,7 @@ SvxMacroTabPage::SvxMacroTabPage( Window* pParent, const Reference< frame::XFram InitAndSetHandler( xNameReplace, Reference< container::XNameReplace>(0), Reference< util::XModifiable >(0)); DisplayAppEvents(true); SvHeaderTabListBox& rListBox = mpImpl->pEventLB->GetListBox(); - SvLBoxEntry* pE = rListBox.GetEntry( (ULONG)nSelectedIndex ); + SvLBoxEntry* pE = rListBox.GetEntry( (sal_uLong)nSelectedIndex ); if( pE ) rListBox.Select(pE); } diff --git a/cui/source/customize/macropg.src b/cui/source/customize/macropg.src index 248a612dbefe..6de18774547c 100644 --- a/cui/source/customize/macropg.src +++ b/cui/source/customize/macropg.src @@ -36,6 +36,7 @@ TabPage RID_SVXPAGE_MACROASSIGN { + HelpID = "cui:TabPage:RID_SVXPAGE_MACROASSIGN" ; Hide = TRUE ; OutputSize = TRUE ; SVLook = TRUE ; @@ -65,6 +66,7 @@ TabPage RID_SVXPAGE_MACROASSIGN }; PushButton PB_ASSIGN { + HelpID = "cui:PushButton:RID_SVXPAGE_MACROASSIGN:PB_ASSIGN"; Pos = MAP_APPFONT ( COL4 , ROW0A ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "M~acro..." ; @@ -73,6 +75,7 @@ TabPage RID_SVXPAGE_MACROASSIGN }; PushButton PB_ASSIGN_COMPONENT { + HelpID = "cui:PushButton:RID_SVXPAGE_MACROASSIGN:PB_ASSIGN_COMPONENT"; Pos = MAP_APPFONT ( COL4 , ROW2 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Disable = TRUE ; @@ -81,6 +84,7 @@ TabPage RID_SVXPAGE_MACROASSIGN }; PushButton PB_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_MACROASSIGN:PB_DELETE"; Pos = MAP_APPFONT ( COL4 , ROW5_REMOVE ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "~Remove" ; @@ -101,6 +105,7 @@ TabPage RID_SVXPAGE_MACROASSIGN ModalDialog RID_SVXDLG_ASSIGNCOMPONENT { + HelpID = "cui:ModalDialog:RID_SVXDLG_ASSIGNCOMPONENT"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( COMP_WIDTH , COMP_HEIGHT ) ; @@ -133,6 +138,7 @@ ModalDialog RID_SVXDLG_ASSIGNCOMPONENT }; Edit EDIT_METHOD { + HelpID = "cui:Edit:RID_SVXDLG_ASSIGNCOMPONENT:EDIT_METHOD"; Border = TRUE ; Pos = MAP_APPFONT ( COMP_COL0 , COMP_ROWEDIT ) ; Size = MAP_APPFONT ( COMP_EDIT_WIDTH , RSC_CD_TEXTBOX_HEIGHT ) ; diff --git a/cui/source/customize/macropg_impl.hxx b/cui/source/customize/macropg_impl.hxx index c6501e4b30a1..c79b91f50fff 100644 --- a/cui/source/customize/macropg_impl.hxx +++ b/cui/source/customize/macropg_impl.hxx @@ -44,8 +44,8 @@ public: String* pStrEvent; String* pAssignedMacro; _HeaderTabListBox* pEventLB; - BOOL bReadOnly; - BOOL bIDEDialogMode; + sal_Bool bReadOnly; + sal_Bool bIDEDialogMode; }; class AssignComponentDialog : public ModalDialog diff --git a/cui/source/customize/selector.cxx b/cui/source/customize/selector.cxx index 6fee34f67ca6..0900a1ff4847 100644 --- a/cui/source/customize/selector.cxx +++ b/cui/source/customize/selector.cxx @@ -38,7 +38,6 @@ #include <sfx2/app.hxx> #include <sfx2/msg.hxx> #include <sfx2/msgpool.hxx> -#include <sfx2/macrconf.hxx> #include <sfx2/minfitem.hxx> #include <sfx2/objsh.hxx> #include <sfx2/dispatch.hxx> @@ -89,7 +88,7 @@ SvxConfigFunctionListBox_Impl::SvxConfigFunctionListBox_Impl( Window* pParent, c , pCurEntry( 0 ) , m_pDraggingEntry( 0 ) { - SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); GetModel()->SetSortMode( SortAscending ); // Timer for the BallonHelp @@ -142,8 +141,8 @@ IMPL_LINK( SvxConfigFunctionListBox_Impl, TimerHdl, Timer*, EMPTYARG) void SvxConfigFunctionListBox_Impl::ClearAll() { - USHORT nCount = aArr.Count(); - for ( USHORT i=0; i<nCount; ++i ) + sal_uInt16 nCount = aArr.Count(); + for ( sal_uInt16 i=0; i<nCount; ++i ) { SvxGroupInfo_Impl *pData = aArr[i]; delete pData; @@ -153,42 +152,6 @@ void SvxConfigFunctionListBox_Impl::ClearAll() Clear(); } -SvLBoxEntry* SvxConfigFunctionListBox_Impl::GetEntry_Impl( const String& rName ) -{ - SvLBoxEntry *pEntry = First(); - while ( pEntry ) - { - if ( GetEntryText( pEntry ) == rName ) - return pEntry; - pEntry = Next( pEntry ); - } - - return NULL; -} - -SvLBoxEntry* SvxConfigFunctionListBox_Impl::GetEntry_Impl( USHORT nId ) -{ - SvLBoxEntry *pEntry = First(); - while ( pEntry ) - { - SvxGroupInfo_Impl *pData = (SvxGroupInfo_Impl*) pEntry->GetUserData(); - if ( pData && pData->nOrd == nId ) - return pEntry; - pEntry = Next( pEntry ); - } - - return NULL; -} - -USHORT SvxConfigFunctionListBox_Impl::GetId( SvLBoxEntry *pEntry ) -{ - SvxGroupInfo_Impl *pData = pEntry ? - (SvxGroupInfo_Impl*) pEntry->GetUserData() : 0; - if ( pData ) - return pData->nOrd; - return 0; -} - String SvxConfigFunctionListBox_Impl::GetHelpText( SvLBoxEntry *pEntry ) { // Information zum selektierten Entry aus den Userdaten holen @@ -257,7 +220,7 @@ SvxConfigGroupListBox_Impl::SvxConfigGroupListBox_Impl( m_xFrame.set( xFrame ); } - SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HASBUTTONS | WB_HASLINES | WB_HASLINESATROOT | WB_HASBUTTONSATROOT ); + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HASBUTTONS | WB_HASLINES | WB_HASLINESATROOT | WB_HASBUTTONSATROOT ); ImageList aNavigatorImages( SVX_RES( RID_SVXIMGLIST_FMEXPL ) ); @@ -275,8 +238,8 @@ SvxConfigGroupListBox_Impl::~SvxConfigGroupListBox_Impl() void SvxConfigGroupListBox_Impl::ClearAll() { - USHORT nCount = aArr.Count(); - for ( USHORT i=0; i<nCount; ++i ) + sal_uInt16 nCount = aArr.Count(); + for ( sal_uInt16 i=0; i<nCount; ++i ) { SvxGroupInfo_Impl *pData = aArr[i]; delete pData; @@ -353,12 +316,12 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows Sequence< Reference< browse::XBrowseNode > > children = _rxRootNode->getChildNodes(); - BOOL bIsRootNode = _rxRootNode->getName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Root")); + sal_Bool bIsRootNode = _rxRootNode->getName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Root")); /* To mimic current starbasic behaviour we need to make sure that only the current document is displayed in the config tree. Tests below - set the bDisplay flag to FALSE if the current + set the bDisplay flag to sal_False if the current node is a first level child of the Root and is NOT either the current document, user or share */ OUString sCurrentDocTitle; @@ -375,7 +338,7 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows if ( !theChild.is() ) continue; ::rtl::OUString sUIName = theChild->getName(); - BOOL bDisplay = TRUE; + sal_Bool bDisplay = sal_True; if ( bIsRootNode || ( m_bShowSlots && _pParentEntry && ( GetModel()->GetDepth( _pParentEntry ) == 0 ) ) @@ -395,7 +358,7 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows } else if ( !sUIName.equals( sCurrentDocTitle ) ) { - bDisplay = FALSE; + bDisplay = sal_False; } } @@ -423,7 +386,7 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows * way to determine if a basic lib had children * without having to ask for them (which forces * the library to be loaded */ - pNewEntry->EnableChildsOnDemand( TRUE ); + pNewEntry->EnableChildsOnDemand( sal_True ); } else { @@ -436,7 +399,7 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows { if ( grandchildren[m]->getType() == browse::BrowseNodeTypes::CONTAINER ) { - pNewEntry->EnableChildsOnDemand( TRUE ); + pNewEntry->EnableChildsOnDemand( sal_True ); break; } } @@ -452,7 +415,7 @@ void SvxConfigGroupListBox_Impl::fillScriptList( const Reference< browse::XBrows void SvxConfigGroupListBox_Impl::Init() { - SetUpdateMode(FALSE); + SetUpdateMode(sal_False); ClearAll(); Reference< XComponentContext > xContext; @@ -602,7 +565,7 @@ void SvxConfigGroupListBox_Impl::Init() SvLBoxEntry *pNewEntry = InsertEntry( aTitle, NULL ); pNewEntry->SetUserData( pInfo ); - pNewEntry->EnableChildsOnDemand( TRUE ); + pNewEntry->EnableChildsOnDemand( sal_True ); aArr.Insert( pInfo, aArr.Count() ); } else @@ -612,7 +575,7 @@ void SvxConfigGroupListBox_Impl::Init() } } MakeVisible( GetEntry( 0,0 ) ); - SetUpdateMode( TRUE ); + SetUpdateMode( sal_True ); } Image SvxConfigGroupListBox_Impl::GetImage( @@ -723,12 +686,12 @@ void SvxConfigGroupListBox_Impl::GroupSelected() { SvLBoxEntry *pEntry = FirstSelected(); SvxGroupInfo_Impl *pInfo = (SvxGroupInfo_Impl*) pEntry->GetUserData(); - pFunctionListBox->SetUpdateMode(FALSE); + pFunctionListBox->SetUpdateMode(sal_False); pFunctionListBox->ClearAll(); if ( pInfo->nKind != SVX_CFGGROUP_FUNCTION && pInfo->nKind != SVX_CFGGROUP_SCRIPTCONTAINER ) { - pFunctionListBox->SetUpdateMode(TRUE); + pFunctionListBox->SetUpdateMode(sal_True); return; } @@ -896,31 +859,31 @@ void SvxConfigGroupListBox_Impl::GroupSelected() if ( pFunctionListBox->GetEntryCount() ) pFunctionListBox->Select( pFunctionListBox->GetEntry( 0, 0 ) ); - pFunctionListBox->SetUpdateMode(TRUE); + pFunctionListBox->SetUpdateMode(sal_True); } -BOOL SvxConfigGroupListBox_Impl::Expand( SvLBoxEntry* pParent ) +sal_Bool SvxConfigGroupListBox_Impl::Expand( SvLBoxEntry* pParent ) { - BOOL bRet = SvTreeListBox::Expand( pParent ); + sal_Bool bRet = SvTreeListBox::Expand( pParent ); if ( bRet ) { // Wieviele Entries k"onnen angezeigt werden ? - ULONG nEntries = GetOutputSizePixel().Height() / GetEntryHeight(); + sal_uLong nEntries = GetOutputSizePixel().Height() / GetEntryHeight(); // Wieviele Kinder sollen angezeigt werden ? - ULONG nChildCount = GetVisibleChildCount( pParent ); + sal_uLong nChildCount = GetVisibleChildCount( pParent ); // Passen alle Kinder und der parent gleichzeitig in die View ? if ( nChildCount+1 > nEntries ) { // Wenn nicht, wenigstens parent ganz nach oben schieben - MakeVisible( pParent, TRUE ); + MakeVisible( pParent, sal_True ); } else { // An welcher relativen ViewPosition steht der aufzuklappende parent SvLBoxEntry *pEntry = GetFirstEntryInView(); - ULONG nParentPos = 0; + sal_uLong nParentPos = 0; while ( pEntry && pEntry != pParent ) { ++nParentPos; @@ -939,7 +902,7 @@ BOOL SvxConfigGroupListBox_Impl::Expand( SvLBoxEntry* pParent ) void SvxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) { SvxGroupInfo_Impl *pInfo = (SvxGroupInfo_Impl*) pEntry->GetUserData(); - pInfo->bWasOpened = TRUE; + pInfo->bWasOpened = sal_True; switch ( pInfo->nKind ) { case SVX_CFGGROUP_SCRIPTCONTAINER: @@ -966,7 +929,7 @@ void SvxConfigGroupListBox_Impl::RequestingChilds( SvLBoxEntry *pEntry ) */ SvxScriptSelectorDialog::SvxScriptSelectorDialog( - Window* pParent, BOOL bShowSlots, const Reference< frame::XFrame >& xFrame ) + Window* pParent, sal_Bool bShowSlots, const Reference< frame::XFrame >& xFrame ) : ModelessDialog( pParent, CUI_RES( RID_DLG_SCRIPTSELECTOR ) ), aDialogDescription( this, CUI_RES( TXT_SELECTOR_DIALOG_DESCRIPTION ) ), @@ -1022,7 +985,7 @@ void SvxScriptSelectorDialog::ResizeControls() Size s, news; long gap; - USHORT style = TEXT_DRAW_MULTILINE | TEXT_DRAW_TOP | + sal_uInt16 style = TEXT_DRAW_MULTILINE | TEXT_DRAW_TOP | TEXT_DRAW_LEFT | TEXT_DRAW_WORDBREAK; // get dimensions of dialog instructions control @@ -1115,12 +1078,12 @@ SvxScriptSelectorDialog::UpdateUI() aCommands.GetHelpText( aCommands.FirstSelected() ); aDescriptionText.SetText( rMessage ); - aOKButton.Enable( TRUE ); + aOKButton.Enable( sal_True ); } else { aDescriptionText.SetText( String() ); - aOKButton.Enable( FALSE ); + aOKButton.Enable( sal_False ); } } @@ -1130,7 +1093,7 @@ IMPL_LINK( SvxScriptSelectorDialog, ClickHdl, Button *, pButton ) { // If we are displaying Slot API commands then the dialog is being // run from Tools/Configure and we should not close it, just hide it - if ( m_bShowSlots == FALSE ) + if ( m_bShowSlots == sal_False ) { EndDialog( RET_CANCEL ); } @@ -1145,7 +1108,7 @@ IMPL_LINK( SvxScriptSelectorDialog, ClickHdl, Button *, pButton ) // If we are displaying Slot API commands then this the dialog is being // run from Tools/Configure and we should not close it - if ( m_bShowSlots == FALSE ) + if ( m_bShowSlots == sal_False ) { EndDialog( RET_OK ); } @@ -1177,12 +1140,6 @@ SvxScriptSelectorDialog::SetDialogDescription( const String& rDescription ) aDialogDescription.SetText( rDescription ); } -USHORT -SvxScriptSelectorDialog::GetSelectedId() -{ - return aCommands.GetId( aCommands.GetLastSelectedEntry() ); -} - String SvxScriptSelectorDialog::GetScriptURL() const { diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx index e18f2e3f13e1..b185e3191aa7 100644 --- a/cui/source/dialogs/SpellDialog.cxx +++ b/cui/source/dialogs/SpellDialog.cxx @@ -74,6 +74,8 @@ using namespace ::com::sun::star::uno; using namespace ::com::sun::star::beans; using namespace ::com::sun::star::linguistic2; +using ::rtl::OUString; + #define C2U(cChar) ::rtl::OUString::createFromAscii(cChar) // struct SpellDialog_Impl --------------------------------------------- @@ -83,19 +85,21 @@ struct SpellDialog_Impl }; // ----------------------------------------------------------------------- -#define SPELLUNDO_CHANGE_LANGUAGE (TEXTUNDO_USER + 1) -#define SPELLUNDO_CHANGE_TEXTENGINE (TEXTUNDO_USER + 2) -#define SPELLUNDO_CHANGE_NEXTERROR (TEXTUNDO_USER + 3) -#define SPELLUNDO_CHANGE_ADD_TO_DICTIONARY (TEXTUNDO_USER + 4) -#define SPELLUNDO_CHANGE_GROUP (TEXTUNDO_USER + 5) //undo list -#define SPELLUNDO_MOVE_ERROREND (TEXTUNDO_USER + 6) -#define SPELLUNDO_UNDO_EDIT_MODE (TEXTUNDO_USER + 7) -#define SPELLUNDO_ADD_IGNORE_RULE (TEXTUNDO_USER + 8) +#define SPELLUNDO_START 200 + +#define SPELLUNDO_CHANGE_LANGUAGE (SPELLUNDO_START + 1) +#define SPELLUNDO_CHANGE_TEXTENGINE (SPELLUNDO_START + 2) +#define SPELLUNDO_CHANGE_NEXTERROR (SPELLUNDO_START + 3) +#define SPELLUNDO_CHANGE_ADD_TO_DICTIONARY (SPELLUNDO_START + 4) +#define SPELLUNDO_CHANGE_GROUP (SPELLUNDO_START + 5) //undo list +#define SPELLUNDO_MOVE_ERROREND (SPELLUNDO_START + 6) +#define SPELLUNDO_UNDO_EDIT_MODE (SPELLUNDO_START + 7) +#define SPELLUNDO_ADD_IGNORE_RULE (SPELLUNDO_START + 8) namespace svx{ class SpellUndoAction_Impl : public SfxUndoAction { - USHORT m_nId; + sal_uInt16 m_nId; const Link& m_rActionLink; //undo of button enabling bool m_bEnableChangePB; @@ -114,7 +118,7 @@ class SpellUndoAction_Impl : public SfxUndoAction long m_nOffset; public: - SpellUndoAction_Impl(USHORT nId, const Link& rActionLink) : + SpellUndoAction_Impl(sal_uInt16 nId, const Link& rActionLink) : m_nId(nId), m_rActionLink( rActionLink), m_bEnableChangePB(false), @@ -130,7 +134,7 @@ public: ~SpellUndoAction_Impl(); virtual void Undo(); - virtual USHORT GetId() const; + virtual sal_uInt16 GetId() const; void SetEnableChangePB(){m_bEnableChangePB = true;} bool IsEnableChangePB(){return m_bEnableChangePB;} @@ -180,7 +184,7 @@ void SpellUndoAction_Impl::Undo() } //----------------------------------------------------------------------- -USHORT SpellUndoAction_Impl::GetId()const +sal_uInt16 SpellUndoAction_Impl::GetId()const { return m_nId; } @@ -297,7 +301,7 @@ void SpellDialog::Init_Impl() aLanguageLB.SetSelectHdl(LINK( this, SpellDialog, LanguageSelectHdl ) ); // initialize language ListBox - aLanguageLB.SetLanguageList( LANG_LIST_SPELL_USED, FALSE, FALSE, TRUE ); + aLanguageLB.SetLanguageList( LANG_LIST_SPELL_USED, sal_False, sal_False, sal_True ); // get current language UpdateBoxes_Impl(); @@ -409,7 +413,7 @@ void SpellDialog::SpellContinue_Impl(bool bUseSavedSentence, bool bIgnoreCurrent { //remove undo if a new sentence is active aSentenceED.ResetUndo(); - aUndoPB.Enable(FALSE); + aUndoPB.Enable(sal_False); } } } @@ -423,7 +427,7 @@ IMPL_STATIC_LINK( SpellDialog, InitHdl, SpellDialog *, EMPTYARG ) pThis->aAutoCorrPB.Show(pThis->rParent.HasAutoCorrection()); pThis->SpellContinue_Impl(); pThis->aSentenceED.ResetUndo(); - pThis->aUndoPB.Enable(FALSE); + pThis->aUndoPB.Enable(sal_False); pThis->LockFocusChanges(true); if( pThis->aChangePB.IsEnabled() ) @@ -611,7 +615,7 @@ IMPL_LINK( SpellDialog, ChangeHdl, Button *, EMPTYARG ) aSentenceED.ChangeMarkedWord(aString, GetSelectedLang_Impl()); SpellContinue_Impl(); bModified = false; - aSentenceED.UndoActionEnd( SPELLUNDO_CHANGE_GROUP ); + aSentenceED.UndoActionEnd(); } if(!aChangePB.IsEnabled()) aIgnorePB.GrabFocus(); @@ -652,7 +656,7 @@ IMPL_LINK( SpellDialog, ChangeAllHdl, Button *, EMPTYARG ) aSentenceED.ChangeMarkedWord(aString, eLang); SpellContinue_Impl(); bModified = false; - aSentenceED.UndoActionEnd( SPELLUNDO_CHANGE_GROUP ); + aSentenceED.UndoActionEnd(); return 1; } // ----------------------------------------------------------------------- @@ -697,7 +701,7 @@ IMPL_LINK( SpellDialog, IgnoreAllHdl, Button *, pButton ) SpellContinue_Impl(); bModified = false; - aSentenceED.UndoActionEnd( SPELLUNDO_CHANGE_GROUP ); + aSentenceED.UndoActionEnd(); return 1; } @@ -706,7 +710,7 @@ IMPL_LINK( SpellDialog, UndoHdl, Button*, EMPTYARG ) { aSentenceED.Undo(); if(!aSentenceED.GetUndoActionCount()) - aUndoPB.Enable(FALSE); + aUndoPB.Enable(sal_False); return 0; } @@ -718,14 +722,14 @@ IMPL_LINK( SpellDialog, DialogUndoHdl, SpellUndoAction_Impl*, pAction ) case SPELLUNDO_CHANGE_TEXTENGINE: { if(pAction->IsEnableChangePB()) - aChangePB.Enable(FALSE); + aChangePB.Enable(sal_False); if(pAction->IsEnableChangeAllPB()) - aChangeAllPB.Enable(FALSE); + aChangeAllPB.Enable(sal_False); } break; case SPELLUNDO_CHANGE_NEXTERROR: { - aSentenceED.MoveErrorMarkTo((USHORT)pAction->GetOldErrorStart(), (USHORT)pAction->GetOldErrorEnd(), false); + aSentenceED.MoveErrorMarkTo((sal_uInt16)pAction->GetOldErrorStart(), (sal_uInt16)pAction->GetOldErrorEnd(), false); if(pAction->IsErrorLanguageSelected()) { UpdateBoxes_Impl(); @@ -807,7 +811,7 @@ void SpellDialog::SetSelectedLang_Impl( LanguageType nLang ) LanguageType SpellDialog::GetSelectedLang_Impl() const { - INT16 nLang = aLanguageLB.GetSelectLanguage(); + sal_Int16 nLang = aLanguageLB.GetSelectLanguage(); return nLang; } @@ -905,7 +909,7 @@ void SpellDialog::SetTitle_Impl(LanguageType nLang) -----------------------------------------------------------------------*/ void SpellDialog::InitUserDicts() { - sal_uInt16 nLang = aLanguageLB.GetSelectLanguage(); + const LanguageType nLang = aLanguageLB.GetSelectLanguage(); const Reference< XDictionary > *pDic = 0; @@ -923,82 +927,89 @@ void SpellDialog::InitUserDicts() pImpl->aDics = xDicList->getDictionaries(); } - // Benutzerbuecher anzeigen + SvtLinguConfig aCfg; + const bool bHC = Application::GetSettings().GetStyleSettings().GetHighContrastMode(); + + // list suitable dictionaries + bool bEnable = false; const sal_Int32 nSize = pImpl->aDics.getLength(); pDic = pImpl->aDics.getConstArray(); - sal_Int32 i; delete aAddToDictMB.GetPopupMenu(); PopupMenu* pMenu = new PopupMenu; - for (i = 0; i < nSize; ++i ) + pMenu->SetMenuFlags(MENU_FLAG_NOAUTOMNEMONICS); + sal_uInt16 nItemId = 1; // menu items should be enumerated from 1 and not 0 + for (sal_Int32 i = 0; i < nSize; ++i) { - Reference< XDictionary > xDic( pDic[i], UNO_QUERY ); - if (!xDic.is() || SvxGetIgnoreAllList() == xDic) + uno::Reference< linguistic2::XDictionary > xDicTmp( pDic[i], uno::UNO_QUERY ); + if (!xDicTmp.is() || SvxGetIgnoreAllList() == xDicTmp) continue; - // add only active and not read-only dictionaries to list - // from which to choose from - Reference< frame::XStorable > xStor( xDic, UNO_QUERY ); - if ( xDic->isActive() && (!xStor.is() || !xStor->isReadonly()) ) + uno::Reference< frame::XStorable > xStor( xDicTmp, uno::UNO_QUERY ); + LanguageType nActLanguage = SvxLocaleToLanguage( xDicTmp->getLocale() ); + if( xDicTmp->isActive() + && xDicTmp->getDictionaryType() != linguistic2::DictionaryType_NEGATIVE + && (nLang == nActLanguage || LANGUAGE_NONE == nActLanguage ) + && (!xStor.is() || !xStor->isReadonly()) ) { - sal_Bool bNegativ = xDic->getDictionaryType() == DictionaryType_NEGATIVE; - pMenu->InsertItem( (USHORT)i + 1, ::GetDicInfoStr( xDic->getName(), - SvxLocaleToLanguage( xDic->getLocale() ), bNegativ ) ); - } - } - aAddToDictMB.SetPopupMenu(pMenu); - - aAddToDictMB.Disable(); + pMenu->InsertItem( nItemId, xDicTmp->getName() ); + bEnable = sal_True; - sal_uInt16 k; - for ( k = 0; k < pMenu->GetItemCount(); ++k ) - { - sal_uInt16 nId = pMenu->GetItemId(k) - 1; - sal_Bool bFound = sal_False; - - const sal_uInt16 nDicLang = SvxLocaleToLanguage( pDic[nId]->getLocale() ); - const sal_Bool bDicNegativ = - pDic[nId]->getDictionaryType() == DictionaryType_NEGATIVE; - // Stimmt die Sprache "uberein, dann enable - if ((nDicLang == nLang || nDicLang == LANGUAGE_NONE) && !bDicNegativ) - bFound = sal_True; + uno::Reference< lang::XServiceInfo > xSvcInfo( xDicTmp, uno::UNO_QUERY ); + if (xSvcInfo.is()) + { + OUString aDictionaryImageUrl( aCfg.GetSpellAndGrammarContextDictionaryImage( + xSvcInfo->getImplementationName(), bHC) ); + if (aDictionaryImageUrl.getLength() > 0) + { + Image aImage( lcl_GetImageFromPngUrl( aDictionaryImageUrl ) ); + pMenu->SetItemImage( nItemId, aImage ); + } + } - if (bFound) - { - aAddToDictMB.Enable(); - break; + ++nItemId; } } + aAddToDictMB.SetPopupMenu(pMenu); + aAddToDictMB.Enable( bEnable ); } //----------------------------------------------------------------------- IMPL_LINK(SpellDialog, AddToDictionaryHdl, MenuButton*, pButton ) { aSentenceED.UndoActionStart( SPELLUNDO_CHANGE_GROUP ); - USHORT nItem = pButton->GetCurItemId(); //GetErrorText() returns the current error even if the text is already //manually changed - String sNewWord= aSentenceED.GetErrorText(); + const String aNewWord= aSentenceED.GetErrorText(); + + sal_uInt16 nItemId = pButton->GetCurItemId(); + PopupMenu *pMenu = pButton->GetPopupMenu(); + String aDicName ( pMenu->GetItemText( nItemId ) ); + + uno::Reference< linguistic2::XDictionary > xDic; + uno::Reference< linguistic2::XDictionaryList > xDicList( SvxGetDictionaryList() ); + if (xDicList.is()) + xDic = xDicList->getDictionaryByName( aDicName ); - Reference< XDictionary > xDic( pImpl->aDics.getConstArray()[ nItem - 1 ], UNO_QUERY ); sal_Int16 nAddRes = DIC_ERR_UNKNOWN; if (xDic.is()) { - String sTmpTxt( sNewWord ); - sal_Bool bNegEntry = xDic->getDictionaryType() == DictionaryType_NEGATIVE; - nAddRes = linguistic::AddEntryToDic( xDic, sTmpTxt, bNegEntry, - ::rtl::OUString(), LANGUAGE_NONE ); + nAddRes = linguistic::AddEntryToDic( xDic, aNewWord, sal_False, OUString(), LANGUAGE_NONE ); + // save modified user-dictionary if it is persistent + uno::Reference< frame::XStorable > xSavDic( xDic, uno::UNO_QUERY ); + if (xSavDic.is()) + xSavDic->store(); - if(nAddRes == DIC_ERR_NONE) + if (nAddRes == DIC_ERR_NONE) { SpellUndoAction_Impl* pAction = new SpellUndoAction_Impl( SPELLUNDO_CHANGE_ADD_TO_DICTIONARY, aDialogUndoLink); - pAction->SetDictionary(xDic); - pAction->SetAddedWord(sTmpTxt); - aSentenceED.AddUndoAction(pAction); + pAction->SetDictionary( xDic ); + pAction->SetAddedWord( aNewWord ); + aSentenceED.AddUndoAction( pAction ); } // failed because there is already an entry? - if (DIC_ERR_NONE != nAddRes && xDic->getEntry( sTmpTxt ).is()) + if (DIC_ERR_NONE != nAddRes && xDic->getEntry( aNewWord ).is()) nAddRes = DIC_ERR_NONE; } if (DIC_ERR_NONE != nAddRes) @@ -1006,12 +1017,10 @@ IMPL_LINK(SpellDialog, AddToDictionaryHdl, MenuButton*, pButton ) SvxDicError( this, nAddRes ); return 0; // Nicht weitermachen } - // nach dem Aufnehmen ggf. '='-Zeichen entfernen - sNewWord.EraseAllChars( sal_Unicode( '=' ) ); // go on SpellContinue_Impl(); - aSentenceED.UndoActionEnd( SPELLUNDO_CHANGE_GROUP ); + aSentenceED.UndoActionEnd(); return 0; } @@ -1113,7 +1122,7 @@ void SpellDialog::InvalidateDialog() sal_Int16 i = 0; while(aDisableArr[i]) { - aDisableArr[i]->Enable(FALSE); + aDisableArr[i]->Enable(sal_False); i++; } SfxModelessDialog::Deactivate(); @@ -1178,7 +1187,7 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck) sServiceName = xNamed->getName(); SpellErrorDescription aDesc( false, aStart->xAlternatives->getWord(), aStart->xAlternatives->getLocale(), aStart->xAlternatives->getAlternatives(), 0, sServiceName); - aSentenceED.SetAttrib( SpellErrorAttrib(aDesc), 0, (USHORT) nStartPosition, (USHORT) nEndPosition ); + aSentenceED.SetAttrib( SpellErrorAttrib(aDesc), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); } else if(aStart->bIsGrammarError ) { @@ -1192,11 +1201,11 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck) &aStart->sDialogTitle, &aStart->aGrammarError.aFullComment, &aStart->aGrammarError.aRuleIdentifier ); - aSentenceED.SetAttrib( SpellErrorAttrib(aDesc), 0, (USHORT) nStartPosition, (USHORT) nEndPosition ); + aSentenceED.SetAttrib( SpellErrorAttrib(aDesc), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); } if(aStart->bIsField) - aSentenceED.SetAttrib( SpellBackgroundAttrib(COL_LIGHTGRAY), 0, (USHORT) nStartPosition, (USHORT) nEndPosition ); - aSentenceED.SetAttrib( SpellLanguageAttrib(aStart->eLanguage), 0, (USHORT) nStartPosition, (USHORT) nEndPosition ); + aSentenceED.SetAttrib( SpellBackgroundAttrib(COL_LIGHTGRAY), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); + aSentenceED.SetAttrib( SpellLanguageAttrib(aStart->eLanguage), 0, (sal_uInt16) nStartPosition, (sal_uInt16) nEndPosition ); nStartPosition = nEndPosition; } ++aStart; @@ -1205,7 +1214,7 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck) if(!bHasReplaced) aSentenceED.ClearModifyFlag(); aSentenceED.ResetUndo(); - aUndoPB.Enable(FALSE); + aUndoPB.Enable(sal_False); bRet = nStartPosition > 0; } return bRet; @@ -1496,7 +1505,7 @@ long SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt ) break; } //save the current paragraph - USHORT nCurrentLen = GetText().Len(); + sal_uInt16 nCurrentLen = GetText().Len(); if(nAction != ACTION_SELECTFIELD) pTextView->GetWindow()->KeyInput(rKeyEvt); else @@ -1517,8 +1526,8 @@ long SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt ) if(pErrorAttrLeft) { TextAttrib* pNewError = pErrorAttrLeft->GetAttr().Clone(); - USHORT nStart = pErrorAttrLeft->GetStart(); - USHORT nEnd = pErrorAttrLeft->GetEnd(); + sal_uInt16 nStart = pErrorAttrLeft->GetStart(); + sal_uInt16 nEnd = pErrorAttrLeft->GetEnd(); pTextEngine->RemoveAttrib( 0, *pErrorAttrLeft ); SetAttrib( *pNewError, 0, nStart, ++nEnd ); //only active errors move the mark @@ -1534,13 +1543,13 @@ long SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt ) else if(pErrorAttr) { //determine the change - USHORT nAddedChars = GetText().Len() - nCurrentLen; + sal_uInt16 nAddedChars = GetText().Len() - nCurrentLen; TextAttrib* pNewError = pErrorAttr->GetAttr().Clone(); - USHORT nStart = pErrorAttr->GetStart(); - USHORT nEnd = pErrorAttr->GetEnd(); + sal_uInt16 nStart = pErrorAttr->GetStart(); + sal_uInt16 nEnd = pErrorAttr->GetEnd(); pTextEngine->RemoveAttrib( 0, *pErrorAttr ); - nStart = nStart - (USHORT)nAddedChars; + nStart = nStart - (sal_uInt16)nAddedChars; SetAttrib( *pNewError, 0, nStart - nAddedChars, nEnd ); //only if the error is active the mark is moved here if(bIsErrorActive) @@ -1553,8 +1562,8 @@ long SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt ) if(pBackAttrLeft) { TextAttrib* pNewBack = pBackAttrLeft->GetAttr().Clone(); - USHORT _nStart = pBackAttrLeft->GetStart(); - USHORT _nEnd = pBackAttrLeft->GetEnd(); + sal_uInt16 _nStart = pBackAttrLeft->GetStart(); + sal_uInt16 _nEnd = pBackAttrLeft->GetEnd(); pTextEngine->RemoveAttrib( 0, *pBackAttrLeft ); SetAttrib( *pNewBack, 0, _nStart, _nEnd - nAddedChars); delete pNewBack; @@ -1603,14 +1612,14 @@ bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError ) if (bIgnoreCurrentError) m_aIgnoreErrorsAt.insert( m_nErrorStart ); ExtTextEngine* pTextEngine = GetTextEngine(); - USHORT nTextLen = pTextEngine->GetTextLen(0); + sal_uInt16 nTextLen = pTextEngine->GetTextLen(0); if(m_nErrorEnd >= nTextLen - 1) return false; //if it's not already modified the modified flag has to be reset at the and of the marking bool bModified = IsModified(); bool bRet = false; - const USHORT nOldErrorStart = m_nErrorStart; - const USHORT nOldErrorEnd = m_nErrorEnd; + const sal_uInt16 nOldErrorStart = m_nErrorStart; + const sal_uInt16 nOldErrorEnd = m_nErrorEnd; //create a cursor behind the end of the last error //- or at 0 at the start of the sentence @@ -1646,7 +1655,7 @@ bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError ) m_nErrorEnd = pNextError->GetEnd(); ChangeMarkedWord(xEntry->getReplacementText(), SvxLocaleToLanguage( pSpellErrorDescription->aLocale )); - aCursor.GetIndex() = aCursor.GetIndex() + (USHORT)(xEntry->getReplacementText().getLength()); + aCursor.GetIndex() = aCursor.GetIndex() + (sal_uInt16)(xEntry->getReplacementText().getLength()); } else break; @@ -1683,11 +1692,11 @@ bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError ) } //----------------------------------------------------------------------- -void SentenceEditWindow_Impl::MoveErrorMarkTo(USHORT nStart, USHORT nEnd, bool bGrammarError) +void SentenceEditWindow_Impl::MoveErrorMarkTo(sal_uInt16 nStart, sal_uInt16 nEnd, bool bGrammarError) { TextEngine* pTextEngine = GetTextEngine(); - pTextEngine->RemoveAttribs( 0, (USHORT)TEXTATTR_FONTCOLOR, TRUE ); - pTextEngine->RemoveAttribs( 0, (USHORT)TEXTATTR_FONTWEIGHT, TRUE ); + pTextEngine->RemoveAttribs( 0, (sal_uInt16)TEXTATTR_FONTCOLOR, sal_True ); + pTextEngine->RemoveAttribs( 0, (sal_uInt16)TEXTATTR_FONTWEIGHT, sal_True ); pTextEngine->SetAttrib( TextAttribFontWeight(WEIGHT_BOLD), 0, nStart, nEnd ); pTextEngine->SetAttrib( TextAttribFontColor(bGrammarError ? COL_LIGHTBLUE : COL_LIGHTRED), 0, nStart, nEnd ); m_nErrorStart = nStart; @@ -1702,7 +1711,7 @@ void SentenceEditWindow_Impl::ChangeMarkedWord(const String& rNewWord, LanguageT TextSelection aSel(TextPaM(0, m_nErrorStart), TextPaM(0, m_nErrorEnd)); //Remove spell errror attribute ExtTextEngine* pTextEngine = GetTextEngine(); - pTextEngine->UndoActionStart( TEXTUNDO_INSERT ); + pTextEngine->UndoActionStart(); const TextCharAttrib* pErrorAttrib = pTextEngine->FindCharAttrib( TextPaM(0, m_nErrorStart), TEXTATTR_SPELL_ERROR ); DBG_ASSERT(pErrorAttrib, "no error attribute found"); const SpellErrorDescription* pSpellErrorDescription = 0; @@ -1722,30 +1731,30 @@ void SentenceEditWindow_Impl::ChangeMarkedWord(const String& rNewWord, LanguageT const TextCharAttrib* pLangAttrib = pTextEngine->FindCharAttrib( TextPaM(0, m_nErrorEnd), TEXTATTR_SPELL_LANGUAGE ); - USHORT nTextLen = pTextEngine->GetTextLen( 0 ); + sal_uInt16 nTextLen = pTextEngine->GetTextLen( 0 ); if(pLangAttrib && !pLangAttrib->GetStart() && pLangAttrib->GetEnd() == nTextLen) { SpellLanguageAttrib aNewLangAttrib( static_cast<const SpellLanguageAttrib&>(pLangAttrib->GetAttr()).GetLanguage()); pTextEngine->RemoveAttrib(0, *pLangAttrib); - pTextEngine->SetAttrib( aNewLangAttrib, 0, (USHORT)(m_nErrorEnd + nDiffLen) , nTextLen ); + pTextEngine->SetAttrib( aNewLangAttrib, 0, (sal_uInt16)(m_nErrorEnd + nDiffLen) , nTextLen ); } } // undo expanded attributes! if( pBackAttrib && pBackAttrib->GetStart() < m_nErrorStart && pBackAttrib->GetEnd() == m_nErrorEnd + nDiffLen) { TextAttrib* pNewBackground = pBackAttrib->GetAttr().Clone(); - USHORT nStart = pBackAttrib->GetStart(); + sal_uInt16 nStart = pBackAttrib->GetStart(); pTextEngine->RemoveAttrib(0, *pBackAttrib); pTextEngine->SetAttrib(*pNewBackground, 0, nStart, m_nErrorStart); delete pNewBackground; } - pTextEngine->SetModified(TRUE); + pTextEngine->SetModified(sal_True); //adjust end position long nEndTemp = m_nErrorEnd; nEndTemp += nDiffLen; - m_nErrorEnd = (USHORT)nEndTemp; + m_nErrorEnd = (sal_uInt16)nEndTemp; SpellUndoAction_Impl* pAction = new SpellUndoAction_Impl( SPELLUNDO_MOVE_ERROREND, GetSpellDialog()->aDialogUndoLink); @@ -1754,7 +1763,7 @@ void SentenceEditWindow_Impl::ChangeMarkedWord(const String& rNewWord, LanguageT if(pSpellErrorDescription) SetAttrib( SpellErrorAttrib(*pSpellErrorDescription), 0, m_nErrorStart, m_nErrorEnd ); SetAttrib( SpellLanguageAttrib(eLanguage), 0, m_nErrorStart, m_nErrorEnd ); - pTextEngine->UndoActionEnd( TEXTUNDO_INSERT ); + pTextEngine->UndoActionEnd(); } //------------------------------------------------- @@ -1811,7 +1820,7 @@ void SentenceEditWindow_Impl::SetAlternatives( Reference< XSpellAlternatives> xA } //----------------------------------------------------------------------- -void SentenceEditWindow_Impl::SetAttrib( const TextAttrib& rAttr, ULONG nPara, USHORT nStart, USHORT nEnd ) +void SentenceEditWindow_Impl::SetAttrib( const TextAttrib& rAttr, sal_uLong nPara, sal_uInt16 nStart, sal_uInt16 nEnd ) { GetTextEngine()->SetAttrib(rAttr, nPara, nStart, nEnd); } @@ -1826,10 +1835,10 @@ void SentenceEditWindow_Impl::SetText( const String& rStr ) //----------------------------------------------------------------------- struct LanguagePosition_Impl { - USHORT nPosition; + sal_uInt16 nPosition; LanguageType eLanguage; - LanguagePosition_Impl(USHORT nPos, LanguageType eLang) : + LanguagePosition_Impl(sal_uInt16 nPos, LanguageType eLang) : nPosition(nPos), eLanguage(eLang) {} @@ -1837,7 +1846,7 @@ struct LanguagePosition_Impl typedef std::vector<LanguagePosition_Impl> LanguagePositions_Impl; void lcl_InsertBreakPosition_Impl( - LanguagePositions_Impl& rBreakPositions, USHORT nInsert, LanguageType eLanguage) + LanguagePositions_Impl& rBreakPositions, sal_uInt16 nInsert, LanguageType eLanguage) { LanguagePositions_Impl::iterator aStart = rBreakPositions.begin(); while(aStart != rBreakPositions.end()) @@ -1868,7 +1877,7 @@ svx::SpellPortions SentenceEditWindow_Impl::CreateSpellPortions( bool bSetIgnore { svx::SpellPortions aRet; ExtTextEngine* pTextEngine = GetTextEngine(); - const USHORT nTextLen = pTextEngine->GetTextLen(0); + const sal_uInt16 nTextLen = pTextEngine->GetTextLen(0); if(nTextLen) { TextPaM aCursor(0, 0); @@ -1914,7 +1923,7 @@ svx::SpellPortions SentenceEditWindow_Impl::CreateSpellPortions( bool bSetIgnore LanguagePositions_Impl::iterator aStart = aBreakPositions.begin(); //start should always be Null eLang = aStart->eLanguage; - USHORT nStart = aStart->nPosition; + sal_uInt16 nStart = aStart->nPosition; DBG_ASSERT(!nStart, "invalid start position - language attribute missing?"); ++aStart; @@ -1939,11 +1948,11 @@ svx::SpellPortions SentenceEditWindow_Impl::CreateSpellPortions( bool bSetIgnore // quick partly fix of #i71318. Correct fix needs to patch the TextEngine itself... // this one will only prevent text from disappearing. It may to not have the // correct language and will probably not spell checked... - ULONG nPara = pTextEngine->GetParagraphCount(); + sal_uLong nPara = pTextEngine->GetParagraphCount(); if (nPara > 1) { String aLeftOverText; - for (ULONG i = 1; i < nPara; ++i) + for (sal_uLong i = 1; i < nPara; ++i) { aLeftOverText.AppendAscii( "\x0a" ); // the manual line break... aLeftOverText += pTextEngine->GetText(i); @@ -1967,12 +1976,12 @@ svx::SpellPortions SentenceEditWindow_Impl::CreateSpellPortions( bool bSetIgnore //----------------------------------------------------------------------- void SentenceEditWindow_Impl::Undo() { - SfxUndoManager& rUndoMgr = GetTextEngine()->GetUndoManager(); + ::svl::IUndoManager& rUndoMgr = GetTextEngine()->GetUndoManager(); DBG_ASSERT(GetUndoActionCount(), "no undo actions available" ); if(!GetUndoActionCount()) return; bool bSaveUndoEdit = IsUndoEditMode(); - USHORT nId; + sal_uInt16 nId; //if the undo edit mode is active then undo all changes until the UNDO_EDIT_MODE action has been found do { @@ -1991,38 +2000,38 @@ void SentenceEditWindow_Impl::ResetUndo() } //----------------------------------------------------------------------- -void SentenceEditWindow_Impl::AddUndoAction( SfxUndoAction *pAction, BOOL bTryMerg ) +void SentenceEditWindow_Impl::AddUndoAction( SfxUndoAction *pAction, sal_Bool bTryMerg ) { - SfxUndoManager& rUndoMgr = GetTextEngine()->GetUndoManager(); + ::svl::IUndoManager& rUndoMgr = GetTextEngine()->GetUndoManager(); rUndoMgr.AddUndoAction(pAction, bTryMerg); GetSpellDialog()->aUndoPB.Enable(); } //----------------------------------------------------------------------- -USHORT SentenceEditWindow_Impl::GetUndoActionCount() +sal_uInt16 SentenceEditWindow_Impl::GetUndoActionCount() { return GetTextEngine()->GetUndoManager().GetUndoActionCount(); } //----------------------------------------------------------------------- -void SentenceEditWindow_Impl::UndoActionStart( USHORT nId ) +void SentenceEditWindow_Impl::UndoActionStart( sal_uInt16 nId ) { GetTextEngine()->UndoActionStart(nId); } //----------------------------------------------------------------------- -void SentenceEditWindow_Impl::UndoActionEnd( USHORT nId ) +void SentenceEditWindow_Impl::UndoActionEnd() { - GetTextEngine()->UndoActionEnd(nId); + GetTextEngine()->UndoActionEnd(); } //----------------------------------------------------------------------- void SentenceEditWindow_Impl::MoveErrorEnd(long nOffset) { if(nOffset > 0) - m_nErrorEnd = m_nErrorEnd - (USHORT)nOffset; + m_nErrorEnd = m_nErrorEnd - (sal_uInt16)nOffset; else - m_nErrorEnd = m_nErrorEnd -(USHORT)- nOffset; + m_nErrorEnd = m_nErrorEnd -(sal_uInt16)- nOffset; } //----------------------------------------------------------------------- @@ -2056,8 +2065,8 @@ void SentenceEditWindow_Impl::SetUndoEditMode(bool bSet) //remove error marks TextEngine* pTextEngine = GetTextEngine(); - pTextEngine->RemoveAttribs( 0, (USHORT)TEXTATTR_FONTCOLOR, TRUE ); - pTextEngine->RemoveAttribs( 0, (USHORT)TEXTATTR_FONTWEIGHT, TRUE ); + pTextEngine->RemoveAttribs( 0, (sal_uInt16)TEXTATTR_FONTCOLOR, sal_True ); + pTextEngine->RemoveAttribs( 0, (sal_uInt16)TEXTATTR_FONTWEIGHT, sal_True ); //put the appropriate action on the Undo-stack SpellUndoAction_Impl* pAction = new SpellUndoAction_Impl( diff --git a/cui/source/dialogs/SpellDialog.src b/cui/source/dialogs/SpellDialog.src index cc14ba6a9f4b..663b156b467a 100644 --- a/cui/source/dialogs/SpellDialog.src +++ b/cui/source/dialogs/SpellDialog.src @@ -61,6 +61,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK }; ListBox LB_LANGUAGE { + HelpID = "cui:ListBox:RID_SVXDLG_SPELLCHECK:LB_LANGUAGE"; Pos = MAP_APPFONT( 110, 6 ); Size = MAP_APPFONT( 93, 55 ); Border = TRUE; @@ -76,6 +77,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK MultiLineEdit ED_NEWWORD { + HelpID = "cui:MultiLineEdit:RID_SVXDLG_SPELLCHECK:ED_NEWWORD"; Pos = MAP_APPFONT( 6, 37 ); Size = MAP_APPFONT( 197, 48 ); Border = TRUE; @@ -91,6 +93,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK }; ListBox LB_SUGGESTION { + HelpID = "cui:ListBox:RID_SVXDLG_SPELLCHECK:LB_SUGGESTION"; Pos = MAP_APPFONT( 6, 99 ); Size = MAP_APPFONT( 197, 48 ); Border = TRUE; @@ -98,6 +101,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK CheckBox CB_CHECK_GRAMMAR { + HelpID = "cui:CheckBox:RID_SVXDLG_SPELLCHECK:CB_CHECK_GRAMMAR"; Pos = MAP_APPFONT( 6, 153 ); Size = MAP_APPFONT( 100, 10 ); Text [ en-US ] = "Check ~grammar" ; @@ -106,6 +110,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK PushButton PB_IGNORE { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_IGNORE"; Pos = MAP_APPFONT( 209, 37 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "~Ignore Once" ; @@ -113,12 +118,14 @@ ModelessDialog RID_SVXDLG_SPELLCHECK PushButton PB_IGNOREALL { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_IGNOREALL"; Pos = MAP_APPFONT( 209, 54 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "I~gnore All" ; }; PushButton PB_IGNORERULE { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_IGNORERULE"; Pos = MAP_APPFONT( 209, 54 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "I~gnore Rule" ; @@ -126,6 +133,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK }; MenuButton MB_ADDTODICT { + HelpID = "cui:MenuButton:RID_SVXDLG_SPELLCHECK:MB_ADDTODICT"; Pos = MAP_APPFONT( 209, 71 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "~Add" ; @@ -133,6 +141,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK PushButton PB_CHANGE { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_CHANGE"; Pos = MAP_APPFONT( 209, 99 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "~Change" ; @@ -141,12 +150,14 @@ ModelessDialog RID_SVXDLG_SPELLCHECK PushButton PB_CHANGEALL { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_CHANGEALL"; Pos = MAP_APPFONT( 209, 117 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "Change A~ll" ; }; PushButton PB_EXPLAIN { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_EXPLAIN"; Pos = MAP_APPFONT( 209, 117 ); Size = MAP_APPFONT( 55, 14 ); Hide = TRUE; @@ -154,6 +165,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK }; PushButton PB_AUTOCORR { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_AUTOCORR"; Pos = MAP_APPFONT( 209, 134 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "AutoCor~rect" ; @@ -172,12 +184,14 @@ ModelessDialog RID_SVXDLG_SPELLCHECK }; PushButton PB_OPTIONS { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_OPTIONS"; Pos = MAP_APPFONT( 87, 170 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "O~ptions..." ; }; PushButton PB_UNDO { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_UNDO"; Pos = MAP_APPFONT( 148, 170 ); Size = MAP_APPFONT( 55, 14 ); Text [ en-US ] = "~Undo" ; @@ -185,6 +199,7 @@ ModelessDialog RID_SVXDLG_SPELLCHECK PushButton PB_CLOSE { + HelpID = "cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_CLOSE"; Pos = MAP_APPFONT ( 209 , 170 ) ; Size = MAP_APPFONT ( 55 , 14 ) ; TabStop = TRUE ; diff --git a/cui/source/dialogs/about.cxx b/cui/source/dialogs/about.cxx new file mode 100644 index 000000000000..b530005f32b8 --- /dev/null +++ b/cui/source/dialogs/about.cxx @@ -0,0 +1,424 @@ +/************************************************************************* + * + * 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. + * + ************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +#include "precompiled_cui.hxx" + +// include --------------------------------------------------------------- + +#include <vcl/svapp.hxx> +#include <vcl/msgbox.hxx> +#include <tools/stream.hxx> +#include <tools/urlobj.hxx> +#include <rtl/bootstrap.hxx> +#include <unotools/configmgr.hxx> +#include <unotools/bootstrap.hxx> +#include <com/sun/star/uno/Any.h> +#include <vcl/graph.hxx> +#include <svtools/filter.hxx> +#include <sfx2/sfxuno.hxx> +#include "about.hxx" +#include <sfx2/sfxdefs.hxx> +#include <sfx2/app.hxx> +#include <sfx2/sfxcommands.h> +#include "about.hrc" +#include <dialmgr.hxx> +#include <svtools/svtools.hrc> + +// defines --------------------------------------------------------------- + +#define SCROLL_OFFSET 1 +#define SPACE_OFFSET 5 +#define SCROLL_TIMER 30 + +#define WELCOME_URL DEFINE_CONST_UNICODE( "http://www.openoffice.org/welcome/credits.html" ) + +// class AboutDialog ----------------------------------------------------- +static void layoutText( FixedInfo &rText, long &nY, long nTextWidth, Size a6Size ) +{ + Point aTextPos = rText.GetPosPixel(); + aTextPos.X() = a6Size.Width() * 2; + aTextPos.Y() = nY; + rText.SetPosPixel( aTextPos ); + + Size aTxtSiz = rText.GetSizePixel(); + aTxtSiz.Width() = nTextWidth; + Size aCalcSize = rText.CalcMinimumSize( nTextWidth ); + aTxtSiz.Height() = aCalcSize.Height(); + rText.SetSizePixel( aTxtSiz ); + + nY += aTxtSiz.Height(); +} + +String InitDevVersionStr() +{ + const String sCWSSchema( String::CreateFromAscii( "[CWS:" ) ); + rtl::OUString sDefault; + String sBuildId( utl::Bootstrap::getBuildIdData( sDefault ) ); + OSL_ENSURE( sBuildId.Len() > 0, "No BUILDID in bootstrap file" ); + if ( sBuildId.Len() > 0 && sBuildId.Search( sCWSSchema ) == STRING_NOTFOUND ) + { + // no cws part in brand buildid -> try basis buildid + rtl::OUString sBasisBuildId( DEFINE_CONST_OUSTRING( + "${$OOO_BASE_DIR/program/" SAL_CONFIGFILE("version") ":buildid}" ) ); + rtl::Bootstrap::expandMacros( sBasisBuildId ); + sal_Int32 nIndex = sBasisBuildId.indexOf( sCWSSchema ); + if ( nIndex != -1 ) + sBuildId += String( sBasisBuildId.copy( nIndex ) ); + } + + String sProductSource( utl::Bootstrap::getProductSource( sDefault ) ); + OSL_ENSURE( sProductSource.Len() > 0, "No ProductSource in bootstrap file" ); + + // the product source is something like "DEV300", where the + // build id is something like "300m12(Build:12345)". For better readability, + // strip the duplicate UPD ("300"). + if ( sProductSource.Len() ) + { + bool bMatchingUPD = + ( sProductSource.Len() >= 3 ) + && ( sBuildId.Len() >= 3 ) + && ( sProductSource.Copy( sProductSource.Len() - 3 ) == sBuildId.Copy( 0, 3 ) ); + OSL_ENSURE( bMatchingUPD, "BUILDID and ProductSource do not match in their UPD" ); + if ( bMatchingUPD ) + sProductSource = sProductSource.Copy( 0, sProductSource.Len() - 3 ); + + // prepend the product source + sBuildId.Insert( sProductSource, 0 ); + } + + // --> PB 2008-10-30 #i94693# + // if the build ids of the basis or ure layer are different from the build id + // of the brand layer then show them + rtl::OUString aBasisProductBuildId( DEFINE_CONST_OUSTRING( + "${$OOO_BASE_DIR/program/" SAL_CONFIGFILE("version") ":ProductBuildid}" ) ); + rtl::Bootstrap::expandMacros( aBasisProductBuildId ); + rtl::OUString aUREProductBuildId( DEFINE_CONST_OUSTRING( + "${$URE_BIN_DIR/" SAL_CONFIGFILE("version") ":ProductBuildid}" ) ); + rtl::Bootstrap::expandMacros( aUREProductBuildId ); + if ( sBuildId.Search( String( aBasisProductBuildId ) ) == STRING_NOTFOUND + || sBuildId.Search( String( aUREProductBuildId ) ) == STRING_NOTFOUND ) + { + String sTemp( '-' ); + sTemp += String( aBasisProductBuildId ); + sTemp += '-'; + sTemp += String( aUREProductBuildId ); + sBuildId.Insert( sTemp, sBuildId.Search( ')' ) ); + } + // <-- + + // the build id format is "milestone(build)[cwsname]". For readability, it would + // be nice to have some more spaces in there. + xub_StrLen nPos = 0; + if ( ( nPos = sBuildId.Search( sal_Unicode( '(' ) ) ) != STRING_NOTFOUND ) + sBuildId.Insert( sal_Unicode( ' ' ), nPos ); + if ( ( nPos = sBuildId.Search( sal_Unicode( '[' ) ) ) != STRING_NOTFOUND ) + sBuildId.Insert( sal_Unicode( ' ' ), nPos ); + return sBuildId; +} + +AboutDialog::AboutDialog( Window* pParent, const ResId& rId ) : + + SfxModalDialog ( pParent, rId ), + + aOKButton ( this, ResId( ABOUT_BTN_OK, *rId.GetResMgr() ) ), + aVersionText ( this, ResId( ABOUT_FTXT_VERSION, *rId.GetResMgr() ) ), + aCopyrightText ( this, ResId( ABOUT_FTXT_COPYRIGHT, *rId.GetResMgr() ) ), + aBuildData ( this ), + pDeveloperAry(0), + aAccelStr ( ResId( ABOUT_STR_ACCEL, *rId.GetResMgr() ) ), + aTimer (), + nOff ( 0 ), + m_nDeltaWidth ( 0 ), + m_nPendingScrolls( 0 ), + bNormal ( sal_True ) +{ + aDevVersionStr = InitDevVersionStr(); + + ::com::sun::star::lang::Locale aLocale; + ResMgr* pResMgr = ResMgr::SearchCreateResMgr( "about", aLocale ); + if ( pResMgr ) + { + aCopyrightTextStr = String( ResId( ABOUT_STR_COPYRIGHT, *pResMgr ) ); + pDeveloperAry = new ResStringArray( ResId( ABOUT_STR_DEVELOPER_ARY, *pResMgr ) ); + delete pResMgr; + } + + rtl::OUString sProduct; + utl::ConfigManager::GetDirectConfigProperty(utl::ConfigManager::PRODUCTNAME) >>= sProduct; + + // load image from module path + aAppLogo = SfxApplication::GetApplicationLogo(); + + // Transparenter Font + Font aFont = GetFont(); + aFont.SetTransparent( sal_True ); + SetFont( aFont ); + + // if necessary more info + String sVersion = aVersionText.GetText(); + sVersion.SearchAndReplaceAscii( "$(VER)", Application::GetDisplayName() ); + sVersion += '\n'; + sVersion += aDevVersionStr; + aVersionText.SetText( sVersion ); + + // Initialisierung fuer Aufruf Entwickler + if ( aAccelStr.Len() && ByteString(U2S(aAccelStr)).IsAlphaAscii() ) + { + Accelerator *pAccel = 0, *pPrevAccel = 0, *pFirstAccel = 0; + aAccelStr.ToUpperAscii(); + + for ( sal_uInt16 i = 0; i < aAccelStr.Len(); ++i ) + { + pPrevAccel = pAccel; + pAccel = new Accelerator; + aAccelList.Insert( pAccel, LIST_APPEND ); + sal_uInt16 nKey = aAccelStr.GetChar(i) - 'A' + KEY_A; + pAccel->InsertItem( 1, KeyCode( nKey, KEY_MOD1 ) ); + if ( i > 0 ) + pPrevAccel->SetAccel( 1, pAccel ); + if ( i == 0 ) + pFirstAccel = pAccel; + } + pAccel->SetSelectHdl( LINK( this, AboutDialog, AccelSelectHdl ) ); + GetpApp()->InsertAccel( pFirstAccel ); + } + + // set for background and text the correct system color + const StyleSettings& rSettings = GetSettings().GetStyleSettings(); + Color aWhiteCol( rSettings.GetWindowColor() ); + Wallpaper aWall( aWhiteCol ); + SetBackground( aWall ); + Font aNewFont( aCopyrightText.GetFont() ); + aNewFont.SetTransparent( sal_True ); + + aVersionText.SetFont( aNewFont ); + aCopyrightText.SetFont( aNewFont ); + + aVersionText.SetBackground(); + aCopyrightText.SetBackground(); + + Color aTextColor( rSettings.GetWindowTextColor() ); + aVersionText.SetControlForeground( aTextColor ); + aCopyrightText.SetControlForeground( aTextColor ); + aBuildData.SetBackground( aWall ); + + Font aSmallFont = rSettings.GetInfoFont(); + Size aSmaller = aNewFont.GetSize(); + aSmaller.Width() = (long) (aSmaller.Width() * 0.75); + aSmaller.Height() = (long) (aSmaller.Height() * 0.75); + aNewFont.SetSize( aSmaller ); + aBuildData.SetFont( aNewFont ); + aBuildData.SetBackground( aWall ); +#ifdef BUILD_VER_STRING + String aBuildString( DEFINE_CONST_UNICODE( BUILD_VER_STRING ) ); +#else + String aBuildString; +#endif + aBuildData.SetText( aBuildString ); + aBuildData.Show(); + + // determine size and position of the dialog & elements + Size aAppLogoSiz = aAppLogo.GetSizePixel(); + Size aOutSiz = GetOutputSizePixel(); + aOutSiz.Width() = aAppLogoSiz.Width(); + + Size a6Size = aVersionText.LogicToPixel( Size( 6, 6 ), MAP_APPFONT ); + long nY = aAppLogoSiz.Height() + ( a6Size.Height() * 2 ); + long nDlgMargin = a6Size.Width() * 4 ; + long nCtrlMargin = a6Size.Height() * 2; + long nTextWidth = aOutSiz.Width() - nDlgMargin; + + aCopyrightText.SetText( aCopyrightTextStr ); + + layoutText( aVersionText, nY, nTextWidth, a6Size ); + nY += nCtrlMargin; + + // OK-Button-Position (at the bottom and centered) + Size aOKSiz = aOKButton.GetSizePixel(); + Point aOKPnt = aOKButton.GetPosPixel(); + + // Multiline edit with Copyright-Text + Point aCopyPnt = aCopyrightText.GetPosPixel(); + Size aCopySize = aCopyrightText.GetSizePixel(); + aCopySize.Width() = nTextWidth; + aCopySize.Height() = aOutSiz.Height() - nY - ( aOKSiz.Height() * 2 ) - nCtrlMargin; + + aCopyPnt.X() = ( aOutSiz.Width() - aCopySize.Width() ) / 2; + aCopyPnt.Y() = nY; + aCopyrightText.SetPosSizePixel( aCopyPnt, aCopySize ); + + nY += aCopySize.Height() + nCtrlMargin; + aOKPnt.X() = ( aOutSiz.Width() - aOKSiz.Width() ) / 2; + aOKPnt.Y() = nY; + aOKButton.SetPosPixel( aOKPnt ); + + // Change the width of the dialog + SetOutputSizePixel( aOutSiz ); + + FreeResource(); + + SetHelpId( CMD_SID_ABOUT ); +} + +// ----------------------------------------------------------------------- + +AboutDialog::~AboutDialog() +{ + // L"oschen des Entwickleraufrufs + delete pDeveloperAry; + if ( aAccelList.Count() ) + { + GetpApp()->RemoveAccel( aAccelList.First() ); + Accelerator* pAccel = aAccelList.Last(); + + while ( pAccel ) + { + delete pAccel; + pAccel = aAccelList.Prev(); + } + } +} + +// ----------------------------------------------------------------------- + +IMPL_LINK( AboutDialog, TimerHdl, Timer *, pTimer ) +{ + (void)pTimer; //unused + ++m_nPendingScrolls; + Invalidate( INVALIDATE_NOERASE | INVALIDATE_NOCHILDREN ); + return 0; +} + +// ----------------------------------------------------------------------- + +IMPL_LINK( AboutDialog, AccelSelectHdl, Accelerator *, pAccelerator ) +{ +#ifdef YURI_DARIO + aCopyrightText.SetHelpText( DEFINE_CONST_UNICODE("Conoscere qualcuno ovunque egli sia, con cui comprendersi nonostante le distanze\n" + "e le differenze, puo' trasformare la terra in un giardino. baci Valeria") ); +#endif + + (void)pAccelerator; //unused + // init Timer + aTimer.SetTimeoutHdl( LINK( this, AboutDialog, TimerHdl ) ); + + // init scroll mode + nOff = GetOutputSizePixel().Height(); + MapMode aMapMode( MAP_PIXEL ); + SetMapMode( aMapMode ); + bNormal = sal_False; + + // start scroll Timer + aTimer.SetTimeout( SCROLL_TIMER ); + aTimer.Start(); + return 0; +} + +// ----------------------------------------------------------------------- + +sal_Bool AboutDialog::Close() +{ + // stop Timer and finish the dialog + aTimer.Stop(); + EndDialog( RET_OK ); + return( sal_False ); +} + +// ----------------------------------------------------------------------- + +void AboutDialog::Paint( const Rectangle& rRect ) +{ + SetClipRegion( rRect ); + + if ( bNormal ) // not in scroll mode + { + Point aPos( m_nDeltaWidth / 2, 0 ); + DrawImage( aPos, aAppLogo ); + return; + } + + // scroll the content + const int nDeltaY = -SCROLL_OFFSET * m_nPendingScrolls; + if( !nDeltaY ) + return; + nOff += nDeltaY; + Scroll( 0, nDeltaY, SCROLL_NOERASE ); + m_nPendingScrolls = 0; + + // draw the credits text + const Font aOrigFont = GetFont(); + const int nFullWidth = GetOutputSizePixel().Width(); + + int nY = nOff; + const int nDevCnt = static_cast<int>( pDeveloperAry->Count() ); + for( int i = 0; i < nDevCnt; ++i ) + { + if( nY >= rRect.Bottom() ) + break; + + int nPos2 = nY + GetTextHeight() + 3; + if( nPos2 >= rRect.Top() + nDeltaY ) + { + const String aStr = pDeveloperAry->GetString(i); + const long nVal = pDeveloperAry->GetValue(i); + + if ( nVal ) + { + // emphasize the headers + Font aFont = aOrigFont; + aFont.SetWeight( (FontWeight)nVal ); + SetFont( aFont ); + nPos2 = nY + GetTextHeight() + 3; + } + + // clear text background + Rectangle aEraseRect( Point(0,nY), Size( nFullWidth, nPos2-nY)); + Erase( aEraseRect ); + + // draw centered text + const long nTextWidth = GetTextWidth( aStr ); + long nX = (nFullWidth - 5 - nTextWidth) / 2; + if( nX < 0 ) + nX = SPACE_OFFSET; + const Point aPnt( nX, nY ); + DrawText( aPnt, aStr ); + + // restore the font if needed + if( nVal ) + SetFont( aOrigFont ); + } + nY = nPos2; + } + + // close dialog if the whole text has been scrolled + if ( nY <= 0 ) + { + bNormal = sal_True; + Close(); + } +} diff --git a/cui/source/dialogs/about.hrc b/cui/source/dialogs/about.hrc new file mode 100644 index 000000000000..9271e6c53faf --- /dev/null +++ b/cui/source/dialogs/about.hrc @@ -0,0 +1,34 @@ +/************************************************************************* + * + * 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. + * + ************************************************************************/ + +#include <sfx2/sfx.hrc> + +#define ABOUT_BTN_OK 1 +#define ABOUT_FTXT_VERSION 1 +#define ABOUT_STR_ACCEL 3 +#define ABOUT_FTXT_COPYRIGHT 4 + diff --git a/cui/source/dialogs/about.src b/cui/source/dialogs/about.src new file mode 100644 index 000000000000..18806c6ee76c --- /dev/null +++ b/cui/source/dialogs/about.src @@ -0,0 +1,67 @@ +/************************************************************************* + * + * 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. + * + ************************************************************************/ + +#include "about.hrc" + +ModalDialog RID_DEFAULTABOUT +{ + HelpID = "cui:ModalDialog:RID_DEFAULTABOUT"; + OutputSize = TRUE ; + Size = MAP_APPFONT ( 245 , 260 ) ; + Moveable = TRUE ; + SVLook = TRUE ; + Text [ x-comment ] = "PB: ; PB: only %PRODUCTNAME"; + Text [ en-US ] = "About %PRODUCTNAME" ; + OKButton ABOUT_BTN_OK + { + DefButton = TRUE ; + Pos = MAP_APPFONT ( 174 , 6 ) ; + Size = MAP_APPFONT ( 50 , 14 ) ; + }; + FixedText ABOUT_FTXT_VERSION + { + Pos = MAP_APPFONT ( 54 , 6 ) ; + Size = MAP_APPFONT ( 118 , 16 ) ; + WordBreak = TRUE ; + Text = "%PRODUCTNAME %ABOUTBOXPRODUCTVERSION %PRODUCTEXTENSION" ; + }; + MultiLineEdit ABOUT_FTXT_COPYRIGHT + { + HelpID = "cui:MultiLineEdit:RID_DEFAULTABOUT:ABOUT_FTXT_COPYRIGHT"; + Border = TRUE ; + Pos = MAP_APPFONT ( 54 , 25 ) ; + Size = MAP_APPFONT ( 168 , 51 ) ; + IgnoreTab = TRUE ; + ReadOnly = TRUE ; + AutoVScroll = TRUE ; + }; + String ABOUT_STR_ACCEL + { + Text = "SDT" ; + }; +}; + diff --git a/cui/source/dialogs/charmap.src b/cui/source/dialogs/charmap.src index 8dc5b3a3f857..8d7f655b179f 100644 --- a/cui/source/dialogs/charmap.src +++ b/cui/source/dialogs/charmap.src @@ -35,7 +35,7 @@ // RID_SVXDLG_CHARMAP ---------------------------------------------------- ModalDialog RID_SVXDLG_CHARMAP { - HelpId = SID_CHARMAP ; + HelpId = CMD_SID_CHARMAP ; SvLook = TRUE ; Text [ en-US ] = "Special Characters"; Size = MAP_APPFONT ( 297 , 153 ) ; @@ -60,6 +60,7 @@ ModalDialog RID_SVXDLG_CHARMAP }; ListBox LB_FONT { + HelpID = "cui:ListBox:RID_SVXDLG_CHARMAP:LB_FONT"; Pos = MAP_APPFONT ( 42 , 6 ) ; Size = MAP_APPFONT ( 70 , 58 ) ; Sort = TRUE ; @@ -74,6 +75,7 @@ ModalDialog RID_SVXDLG_CHARMAP }; ListBox LB_SUBSET { + HelpID = "cui:ListBox:RID_SVXDLG_CHARMAP:LB_SUBSET"; Pos = MAP_APPFONT ( 161 , 6 ) ; Size = MAP_APPFONT ( 63 , 68 ) ; Sort = FALSE ; @@ -128,6 +130,7 @@ ModalDialog RID_SVXDLG_CHARMAP }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXDLG_CHARMAP:BTN_DELETE"; Pos = MAP_APPFONT ( 242 , 63 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete"; diff --git a/cui/source/dialogs/commonlingui.cxx b/cui/source/dialogs/commonlingui.cxx index 99c7079a53eb..4f91a0ebd3a1 100644 --- a/cui/source/dialogs/commonlingui.cxx +++ b/cui/source/dialogs/commonlingui.cxx @@ -104,6 +104,7 @@ SvxCommonLinguisticControl::SvxCommonLinguisticControl( ModalDialog* _pParent ) ,aAuditBox ( this, CUI_RES( GB_AUDIT ) ) { FreeResource(); + aAktWord.SetAccessibleName(aWordText.GetText()); SetPosSizePixel( Point( 0, 0 ), _pParent->GetOutputSizePixel() ); Show(); } @@ -178,52 +179,6 @@ void SvxCommonLinguisticControl::InsertControlGroup( Window& _rFirstGroupWindow, // (FirstWindow, LastWindow) was no valid control group } -// ----------------------------------------------------------------------- -String SvxCommonLinguisticControl::GetNewEditWord() -{ - return aNewWordED.GetText(); -} - -// ----------------------------------------------------------------------- -void SvxCommonLinguisticControl::SetNewEditWord( const String& _rNew ) -{ - aNewWordED.SetText( _rNew ); -} - -//----------------------------------------------------------------------------- -void SvxCommonLinguisticControl::UpdateIgnoreHelp( ) -{ - - String aInfoStr( RTL_CONSTASCII_USTRINGPARAM( ": " ) ); - aInfoStr.Append( GetCurrentText() ); - - String aString = GetNonMnemonicString( aIgnoreAllBtn.GetText() ); - aString.Append( aInfoStr ); - aIgnoreAllBtn.SetQuickHelpText( aString ); - - aString = GetNonMnemonicString( aIgnoreBtn.GetText() ); - aString.Append( aInfoStr ); - aIgnoreBtn.SetQuickHelpText( aString ); -} - -//----------------------------------------------------------------------------- -void SvxCommonLinguisticControl::UpdateChangesHelp( const String& _rNewText ) -{ - String aInfoStr( RTL_CONSTASCII_USTRINGPARAM( ": " ) ); - aInfoStr.Append( GetCurrentText() ); - aInfoStr.Append( String( RTL_CONSTASCII_USTRINGPARAM( " -> " ) ) ); - aInfoStr.Append( _rNewText ); - // TODO: shouldn't this be part of the resources, for proper localization? - - String aString = GetNonMnemonicString( aChangeAllBtn.GetText() ); - aString.Append( aInfoStr ); - aChangeAllBtn.SetQuickHelpText( aString ); - - aString = GetNonMnemonicString( aChangeBtn.GetText() ); - aString.Append( aInfoStr ); - aChangeBtn.SetQuickHelpText( aString ); -} - //----------------------------------------------------------------------------- void SvxCommonLinguisticControl::Paint( const Rectangle& rRect ) { diff --git a/cui/source/dialogs/commonlingui.hxx b/cui/source/dialogs/commonlingui.hxx index 80edc1b73475..37e27b89658b 100644 --- a/cui/source/dialogs/commonlingui.hxx +++ b/cui/source/dialogs/commonlingui.hxx @@ -151,18 +151,6 @@ public: // returns the location (upper-left corner) of the group of action buttons inline Point GetActionButtonsLocation( ) const { return aIgnoreBtn.GetPosPixel(); } - - // updates the help texts for the "change" and "change all" buttons according to the currently - // entered texts - void UpdateChangesHelp( const String& _rNewText ); - inline void UpdateChangesHelp( ) { UpdateChangesHelp( GetWordInputControl().GetText() ); } - - // updates the help texts for the "ignore" and "always ignore" buttons according to the currently - // entered texts - void UpdateIgnoreHelp( ); - - String GetNewEditWord(); - void SetNewEditWord( const String& _rNew ); }; diff --git a/cui/source/dialogs/cuicharmap.cxx b/cui/source/dialogs/cuicharmap.cxx index 9ec9c84253b7..777851cce643 100644 --- a/cui/source/dialogs/cuicharmap.cxx +++ b/cui/source/dialogs/cuicharmap.cxx @@ -58,26 +58,26 @@ // class SvxCharacterMap ================================================= -SvxCharacterMap::SvxCharacterMap( Window* pParent, BOOL bOne, const SfxItemSet* pSet ) : +SvxCharacterMap::SvxCharacterMap( Window* pParent, sal_Bool bOne, const SfxItemSet* pSet ) : SfxModalDialog( pParent, CUI_RES( RID_SVXDLG_CHARMAP ) ), mpCharMapData( 0 ) { - SFX_ITEMSET_ARG( pSet, pItem, SfxBoolItem, FN_PARAM_1, FALSE ); + SFX_ITEMSET_ARG( pSet, pItem, SfxBoolItem, FN_PARAM_1, sal_False ); if ( pItem ) bOne = pItem->GetValue(); mpCharMapData = new SvxCharMapData( this, bOne, &CUI_MGR() ); - SFX_ITEMSET_ARG( pSet, pCharItem, SfxInt32Item, SID_ATTR_CHAR, FALSE ); + SFX_ITEMSET_ARG( pSet, pCharItem, SfxInt32Item, SID_ATTR_CHAR, sal_False ); if ( pCharItem ) SetChar( pCharItem->GetValue() ); - SFX_ITEMSET_ARG( pSet, pDisableItem, SfxBoolItem, FN_PARAM_2, FALSE ); + SFX_ITEMSET_ARG( pSet, pDisableItem, SfxBoolItem, FN_PARAM_2, sal_False ); if ( pDisableItem && pDisableItem->GetValue() ) DisableFontSelection(); - SFX_ITEMSET_ARG( pSet, pFontItem, SvxFontItem, SID_ATTR_CHAR_FONT, FALSE ); - SFX_ITEMSET_ARG( pSet, pFontNameItem, SfxStringItem, SID_FONT_NAME, FALSE ); + SFX_ITEMSET_ARG( pSet, pFontItem, SvxFontItem, SID_ATTR_CHAR_FONT, sal_False ); + SFX_ITEMSET_ARG( pSet, pFontNameItem, SfxStringItem, SID_FONT_NAME, sal_False ); if ( pFontItem ) { Font aFont( pFontItem->GetFamilyName(), pFontItem->GetStyleName(), GetCharFont().GetSize() ); @@ -169,7 +169,7 @@ short SvxCharacterMap::Execute() // class SvxShowText ===================================================== -SvxShowText::SvxShowText( Window* pParent, const ResId& rResId, BOOL bCenter ) +SvxShowText::SvxShowText( Window* pParent, const ResId& rResId, sal_Bool bCenter ) : Control( pParent, rResId ), mbCenter( bCenter) {} @@ -236,7 +236,7 @@ void SvxShowText::SetFont( const Font& rFont ) aFont.SetWeight( WEIGHT_NORMAL ); aFont.SetAlign( ALIGN_TOP ); aFont.SetSize( PixelToLogic( Size( 0, nWinHeight/2 ) ) ); - aFont.SetTransparent( TRUE ); + aFont.SetTransparent( sal_True ); Control::SetFont( aFont ); mnY = ( nWinHeight - GetTextHeight() ) / 2; @@ -258,7 +258,7 @@ SvxShowText::~SvxShowText() // class SvxCharacterMap ================================================= -SvxCharMapData::SvxCharMapData( SfxModalDialog* pDialog, BOOL bOne_, ResMgr* pResContext ) +SvxCharMapData::SvxCharMapData( SfxModalDialog* pDialog, sal_Bool bOne_, ResMgr* pResContext ) : mpDialog( pDialog ), aShowSet ( pDialog, ResId( CT_SHOWSET, *pResContext ) ), aShowText ( pDialog, ResId( CT_SHOWTEXT, *pResContext ) ), @@ -271,13 +271,13 @@ SvxCharMapData::SvxCharMapData( SfxModalDialog* pDialog, BOOL bOne_, ResMgr* pRe aSubsetText ( pDialog, ResId( FT_SUBSET, *pResContext ) ), aSubsetLB ( pDialog, ResId( LB_SUBSET, *pResContext ) ), aSymbolText ( pDialog, ResId( FT_SYMBOLE, *pResContext ) ), - aShowChar ( pDialog, ResId( CT_SHOWCHAR, *pResContext ), TRUE ), + aShowChar ( pDialog, ResId( CT_SHOWCHAR, *pResContext ), sal_True ), aCharCodeText ( pDialog, ResId( FT_CHARCODE, *pResContext ) ), bOne( bOne_ ), pSubsetMap( NULL ) { aFont = pDialog->GetFont(); - aFont.SetTransparent( TRUE ); + aFont.SetTransparent( sal_True ); aFont.SetFamily( FAMILY_DONTKNOW ); aFont.SetPitch( PITCH_DONTKNOW ); aFont.SetCharSet( RTL_TEXTENCODING_DONTKNOW ); @@ -301,8 +301,8 @@ SvxCharMapData::SvxCharMapData( SfxModalDialog* pDialog, BOOL bOne_, ResMgr* pRe if ( aFontName != aLastName ) { aLastName = aFontName; - USHORT nPos = aFontLB.InsertEntry( aFontName ); - aFontLB.SetEntryData( nPos, (void*)(ULONG)i ); + sal_uInt16 nPos = aFontLB.InsertEntry( aFontName ); + aFontLB.SetEntryData( nPos, (void*)(sal_uLong)i ); } } // the font may not be in the list => @@ -317,7 +317,7 @@ SvxCharMapData::SvxCharMapData( SfxModalDialog* pDialog, BOOL bOne_, ResMgr* pRe if ( aFontLB.GetEntryPos( aToken ) != LISTBOX_ENTRY_NOTFOUND ) { aDefStr = aToken; - bFound = TRUE; + bFound = sal_True; break; } } @@ -381,7 +381,7 @@ IMPL_LINK( SvxCharMapData, OKHdl, OKButton *, EMPTYARG ) rtl::OUString aOUStr( &cChar, 1 ); aShowText.SetText( aOUStr ); } - mpDialog->EndDialog( TRUE ); + mpDialog->EndDialog( sal_True ); return 0; } @@ -389,8 +389,8 @@ IMPL_LINK( SvxCharMapData, OKHdl, OKButton *, EMPTYARG ) IMPL_LINK( SvxCharMapData, FontSelectHdl, ListBox *, EMPTYARG ) { - USHORT nPos = aFontLB.GetSelectEntryPos(), - nFont = (USHORT)(ULONG)aFontLB.GetEntryData( nPos ); + sal_uInt16 nPos = aFontLB.GetSelectEntryPos(), + nFont = (sal_uInt16)(sal_uLong)aFontLB.GetEntryData( nPos ); aFont = mpDialog->GetDevFont( nFont ); aFont.SetWeight( WEIGHT_DONTKNOW ); aFont.SetItalic( ITALIC_NONE ); @@ -416,7 +416,7 @@ IMPL_LINK( SvxCharMapData, FontSelectHdl, ListBox *, EMPTYARG ) delete pSubsetMap; pSubsetMap = NULL; - BOOL bNeedSubset = (aFont.GetCharSet() != RTL_TEXTENCODING_SYMBOL); + sal_Bool bNeedSubset = (aFont.GetCharSet() != RTL_TEXTENCODING_SYMBOL); if( bNeedSubset ) { FontCharMap aFontCharMap; @@ -430,7 +430,7 @@ IMPL_LINK( SvxCharMapData, FontSelectHdl, ListBox *, EMPTYARG ) const Subset* s; while( NULL != (s = pSubsetMap->GetNextSubset( bFirst )) ) { - USHORT nPos_ = aSubsetLB.InsertEntry( s->GetName() ); + sal_uInt16 nPos_ = aSubsetLB.InsertEntry( s->GetName() ); aSubsetLB.SetEntryData( nPos_, (void*)s ); // NOTE: subset must live at least as long as the selected font if( bFirst ) @@ -438,7 +438,7 @@ IMPL_LINK( SvxCharMapData, FontSelectHdl, ListBox *, EMPTYARG ) bFirst = false; } if( aSubsetLB.GetEntryCount() <= 1 ) - bNeedSubset = FALSE; + bNeedSubset = sal_False; } aSubsetText.Show( bNeedSubset); @@ -451,7 +451,7 @@ IMPL_LINK( SvxCharMapData, FontSelectHdl, ListBox *, EMPTYARG ) IMPL_LINK( SvxCharMapData, SubsetSelectHdl, ListBox *, EMPTYARG ) { - USHORT nPos = aSubsetLB.GetSelectEntryPos(); + sal_uInt16 nPos = aSubsetLB.GetSelectEntryPos(); const Subset* pSubset = reinterpret_cast<const Subset*> (aSubsetLB.GetEntryData(nPos)); if( pSubset ) { @@ -466,7 +466,7 @@ IMPL_LINK( SvxCharMapData, SubsetSelectHdl, ListBox *, EMPTYARG ) IMPL_LINK( SvxCharMapData, CharDoubleClickHdl, Control *, EMPTYARG ) { - mpDialog->EndDialog( TRUE ); + mpDialog->EndDialog( sal_True ); return 0; } @@ -567,7 +567,7 @@ IMPL_LINK( SvxCharMapData, AssignHdl, PushButton *, EMPTYARG ) { const SfxItemSet* pOutSet = pDlg->GetOutputItemSet(); const SfxPoolItem* pItem; - if( SFX_ITEM_SET == pOutSet->GetItemState( SID_CHARMAP, FALSE, &pItem ) ) + if( SFX_ITEM_SET == pOutSet->GetItemState( SID_CHARMAP, sal_False, &pItem ) ) { // show assigned shortcut } diff --git a/cui/source/dialogs/cuifmsearch.cxx b/cui/source/dialogs/cuifmsearch.cxx index 7d38ea63ca8d..b4556cccdf3e 100644 --- a/cui/source/dialogs/cuifmsearch.cxx +++ b/cui/source/dialogs/cuifmsearch.cxx @@ -267,7 +267,7 @@ void FmSearchDialog::Init(const UniString& strVisibleFields, const UniString& sI // fill the listboxes // method of field comparison - USHORT nResIds[] = { + sal_uInt16 nResIds[] = { RID_STR_SEARCH_ANYWHERE, RID_STR_SEARCH_BEGINNING, RID_STR_SEARCH_END, @@ -278,7 +278,7 @@ void FmSearchDialog::Init(const UniString& strVisibleFields, const UniString& sI m_lbPosition.SelectEntryPos(MATCHING_ANYWHERE); // the field listbox - for (USHORT i=0; i<strVisibleFields.GetTokenCount(';'); ++i) + for (sal_uInt16 i=0; i<strVisibleFields.GetTokenCount(';'); ++i) m_lbField.InsertEntry(strVisibleFields.GetToken(i, ';')); @@ -420,7 +420,7 @@ IMPL_LINK(FmSearchDialog, OnClickedSpecialSettings, Button*, pButton ) aDlg->Execute(); - INT32 nFlags = aDlg->GetTransliterationFlags(); + sal_Int32 nFlags = aDlg->GetTransliterationFlags(); m_pSearchEngine->SetTransliterationFlags(nFlags); m_cbCase.Check(m_pSearchEngine->GetCaseSensitive()); diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx index bd5240e1e7c4..9b2c7cc52606 100644 --- a/cui/source/dialogs/cuigaldlg.cxx +++ b/cui/source/dialogs/cuigaldlg.cxx @@ -38,7 +38,6 @@ #include <svx/gallery1.hxx> #include <svx/galtheme.hxx> #include "cuigaldlg.hxx" -#include <svl/pickerhelper.hxx> #include "helpid.hrc" #include <unotools/syslocale.hxx> #include <cppuhelper/implbase1.hxx> @@ -53,6 +52,9 @@ #include <sfx2/sfxuno.hxx> #include "dialmgr.hxx" #include "gallery.hrc" +#include <svx/dialogs.hrc> +#include <svx/dialmgr.hxx> + // -------------- // - Namespaces - @@ -131,7 +133,7 @@ void SAL_CALL SearchThread::onTerminated() void SearchThread::ImplSearch( const INetURLObject& rStartURL, const ::std::vector< String >& rFormats, - BOOL bRecursive ) + sal_Bool bRecursive ) { { SolarMutexGuard aGuard; @@ -166,7 +168,7 @@ void SearchThread::ImplSearch( const INetURLObject& rStartURL, bFolder = sal_False; if( bRecursive && bFolder ) - ImplSearch( aFoundURL, rFormats, TRUE ); + ImplSearch( aFoundURL, rFormats, sal_True ); else { sal_Bool bDocument = xRow->getBoolean( 2 ); // property "IsDocument" @@ -196,7 +198,7 @@ void SearchThread::ImplSearch( const INetURLObject& rStartURL, ); mpBrowser->aLbxFound.InsertEntry( GetReducedString( aFoundURL, 50 ), - (USHORT) mpBrowser->aFoundList.size() - 1 ); + (sal_uInt16) mpBrowser->aFoundList.size() - 1 ); } } } @@ -296,9 +298,9 @@ void SAL_CALL TakeThread::run() { String aName; INetURLObject aURL; - USHORT nEntries; + sal_uInt16 nEntries; GalleryTheme* pThm = mpBrowser->GetXChgData()->pTheme; - USHORT nPos; + sal_uInt16 nPos; GalleryProgress* pStatusProgress; { @@ -308,7 +310,7 @@ void SAL_CALL TakeThread::run() pThm->LockBroadcaster(); } - for( USHORT i = 0; i < nEntries && schedule(); i++ ) + for( sal_uInt16 i = 0; i < nEntries && schedule(); i++ ) { // kompletten Filenamen aus FoundList holen if( mpBrowser->bTakeAll ) @@ -317,7 +319,7 @@ void SAL_CALL TakeThread::run() aURL = INetURLObject(*mpBrowser->aFoundList[ nPos = mpBrowser->aLbxFound.GetSelectEntryPos( i ) ]); // Position in Taken-Liste uebernehmen - mrTakenList.Insert( (void*) (ULONG)nPos, LIST_APPEND ); + mrTakenList.Insert( (void*) (sal_uLong)nPos, LIST_APPEND ); { SolarMutexGuard aGuard; @@ -386,12 +388,12 @@ IMPL_LINK( TakeProgress, CleanUpHdl, void*, EMPTYARG ) sal_uInt32 i, nCount; GetParent()->EnterWait(); - mpBrowser->aLbxFound.SetUpdateMode( FALSE ); + mpBrowser->aLbxFound.SetUpdateMode( sal_False ); mpBrowser->aLbxFound.SetNoSelection(); // mark all taken positions in aRemoveEntries for( i = 0UL, nCount = maTakenList.Count(); i < nCount; ++i ) - aRemoveEntries[ (ULONG) maTakenList.GetObject( i ) ] = true; + aRemoveEntries[ (sal_uLong) maTakenList.GetObject( i ) ] = true; maTakenList.Clear(); @@ -421,7 +423,7 @@ IMPL_LINK( TakeProgress, CleanUpHdl, void*, EMPTYARG ) aRemainingVector.clear(); - mpBrowser->aLbxFound.SetUpdateMode( TRUE ); + mpBrowser->aLbxFound.SetUpdateMode( sal_True ); mpBrowser->SelectFoundHdl( NULL ); GetParent()->LeaveWait(); @@ -564,7 +566,7 @@ GalleryIdDialog::GalleryIdDialog( Window* pParent, GalleryTheme* _pThm ) : GalleryTheme::InsertAllThemes( aLbResName ); - aLbResName.SelectEntryPos( (USHORT) pThm->GetId() ); + aLbResName.SelectEntryPos( (sal_uInt16) pThm->GetId() ); aLbResName.GrabFocus(); aBtnOk.SetClickHdl( LINK( this, GalleryIdDialog, ClickOkHdl ) ); @@ -575,10 +577,10 @@ GalleryIdDialog::GalleryIdDialog( Window* pParent, GalleryTheme* _pThm ) : IMPL_LINK( GalleryIdDialog, ClickOkHdl, void*, EMPTYARG ) { Gallery* pGal = pThm->GetParent(); - const ULONG nId = GetId(); - BOOL bDifferentThemeExists = FALSE; + const sal_uLong nId = GetId(); + sal_Bool bDifferentThemeExists = sal_False; - for( ULONG i = 0, nCount = pGal->GetThemeCount(); i < nCount && !bDifferentThemeExists; i++ ) + for( sal_uLong i = 0, nCount = pGal->GetThemeCount(); i < nCount && !bDifferentThemeExists; i++ ) { const GalleryThemeEntry* pInfo = pGal->GetThemeInfo( i ); @@ -593,7 +595,7 @@ IMPL_LINK( GalleryIdDialog, ClickOkHdl, void*, EMPTYARG ) InfoBox aBox( this, aStr ); aBox.Execute(); aLbResName.GrabFocus(); - bDifferentThemeExists = TRUE; + bDifferentThemeExists = sal_True; } } @@ -632,7 +634,7 @@ GalleryThemeProperties::GalleryThemeProperties( Window* pParent, ExchangeData* _ // ------------------------------------------------------------------------ -void GalleryThemeProperties::PageCreated( USHORT nId, SfxTabPage &rPage ) +void GalleryThemeProperties::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { if( RID_SVXTABPAGE_GALLERY_GENERAL == nId ) ( (TPGalleryThemeGeneral&) rPage ).SetXChgData( pData ); @@ -660,6 +662,11 @@ TPGalleryThemeGeneral::TPGalleryThemeGeneral( Window* pParent, const SfxItemSet& aFtMSShowChangeDate ( this, CUI_RES( FT_MS_SHOW_CHANGEDATE ) ) { FreeResource(); + + String aAccName(SVX_RES(RID_SVXSTR_GALLERY_THEMENAME)); + aEdtMSName.SetAccessibleName(aAccName); + aFiMSImage.SetAccessibleName(aAccName); + aEdtMSName.SetAccessibleRelationLabeledBy( &aFiMSImage ); } // ------------------------------------------------------------------------ @@ -672,8 +679,8 @@ void TPGalleryThemeGeneral::SetXChgData( ExchangeData* _pData ) String aOutStr( String::CreateFromInt32( pThm->GetObjectCount() ) ); String aObjStr( CUI_RES( RID_SVXSTR_GALLERYPROPS_OBJECT ) ); String aAccess; - String aType( CUI_RES( RID_SVXSTR_GALLERYPROPS_GALTHEME ) ); - BOOL bReadOnly = pThm->IsReadOnly() && !pThm->IsImported(); + String aType( SVX_RES( RID_SVXSTR_GALLERYPROPS_GALTHEME ) ); + sal_Bool bReadOnly = pThm->IsReadOnly() && !pThm->IsImported(); aEdtMSName.SetHelpId( HID_GALLERY_EDIT_MSNAME ); aEdtMSName.SetText( pThm->GetName() ); @@ -712,7 +719,7 @@ void TPGalleryThemeGeneral::SetXChgData( ExchangeData* _pData ) aFtMSShowChangeDate.SetText( aAccess ); // Image setzen - USHORT nId; + sal_uInt16 nId; if( pThm->IsImported() ) nId = RID_SVXBMP_THEME_IMPORTED_BIG; @@ -728,10 +735,10 @@ void TPGalleryThemeGeneral::SetXChgData( ExchangeData* _pData ) // ------------------------------------------------------------------------ -BOOL TPGalleryThemeGeneral::FillItemSet( SfxItemSet& /*rSet*/ ) +sal_Bool TPGalleryThemeGeneral::FillItemSet( SfxItemSet& /*rSet*/ ) { pData->aEditedTitle = aEdtMSName.GetText(); - return TRUE; + return sal_True; } // ------------------------------------------------------------------------ @@ -747,24 +754,27 @@ SfxTabPage* TPGalleryThemeGeneral::Create( Window* pParent, const SfxItemSet& rS TPGalleryThemeProperties::TPGalleryThemeProperties( Window* pWindow, const SfxItemSet& rSet ) : SfxTabPage ( pWindow, CUI_RES( RID_SVXTABPAGE_GALLERYTHEME_FILES ), rSet ), + aFtFileType ( this, CUI_RES(FT_FILETYPE ) ), + aCbbFileType ( this, CUI_RES(CBB_FILETYPE ) ), + aLbxFound ( this, CUI_RES(LBX_FOUND ) ), aBtnSearch ( this, CUI_RES(BTN_SEARCH ) ), aBtnTake ( this, CUI_RES(BTN_TAKE ) ), aBtnTakeAll ( this, CUI_RES(BTN_TAKEALL ) ), aCbxPreview ( this, CUI_RES(CBX_PREVIEW ) ), - aCbbFileType ( this, CUI_RES(CBB_FILETYPE ) ), - aLbxFound ( this, CUI_RES(LBX_FOUND ) ), - aFtFileType ( this, CUI_RES(FT_FILETYPE ) ), aWndPreview ( this, CUI_RES( WND_BRSPRV ) ), nCurFilterPos (0), nFirstExtFilterPos (0), - bEntriesFound (FALSE), - bInputAllowed (TRUE), - bSearchRecursive (FALSE), + bEntriesFound (sal_False), + bInputAllowed (sal_True), + bSearchRecursive (sal_False), xDialogListener ( new ::svt::DialogClosedListener() ) { FreeResource(); xDialogListener->SetDialogClosedLink( LINK( this, TPGalleryThemeProperties, DialogClosedHdl ) ); + aLbxFound.SetAccessibleName(String(SVX_RES(RID_SVXSTR_GALLERY_FILESFOUND))); + aWndPreview.SetAccessibleName(aCbxPreview.GetText()); + aLbxFound.SetAccessibleRelationLabeledBy(&aLbxFound); } // ------------------------------------------------------------------------ @@ -857,7 +867,7 @@ void TPGalleryThemeProperties::FillFilterList() FilterEntry* pFilterEntry; FilterEntry* pTestEntry; sal_uInt16 i, nKeyCount; - BOOL bInList; + sal_Bool bInList; // graphic filters for( i = 0, nKeyCount = pFilter->GetImportFormatCount(); i < nKeyCount; i++ ) @@ -865,12 +875,12 @@ void TPGalleryThemeProperties::FillFilterList() aExt = pFilter->GetImportFormatShortName( i ); aName = pFilter->GetImportFormatName( i ); pTestEntry = (FilterEntry*) aFilterEntryList.First(); - bInList = FALSE; + bInList = sal_False; String aExtensions; int j = 0; String sWildcard; - while( TRUE ) + while( sal_True ) { sWildcard = pFilter->GetImportWildcard( i, j++ ); if ( !sWildcard.Len() ) @@ -888,7 +898,7 @@ void TPGalleryThemeProperties::FillFilterList() { if ( pTestEntry->aFilterName == aExt ) { - bInList = TRUE; + bInList = sal_True; break; } pTestEntry = (FilterEntry*) aFilterEntryList.Next(); @@ -931,7 +941,7 @@ void TPGalleryThemeProperties::FillFilterList() { int j = 0; String sWildcard; - while( TRUE ) + while( sal_True ) { sWildcard = pFilter->GetImportWildcard( i, j++ ); if ( !sWildcard.Len() ) @@ -957,7 +967,7 @@ void TPGalleryThemeProperties::FillFilterList() } } -#if defined(WIN) || defined(WNT) +#if defined(WNT) if ( aExtensions.Len() > 240 ) aExtensions = DEFINE_CONST_UNICODE( "*.*" ); #endif @@ -1110,7 +1120,7 @@ void TPGalleryThemeProperties::DoPreview() if( aString != aPreviewString ) { INetURLObject _aURL( *aFoundList[ aLbxFound.GetEntryPos( aString ) ] ); - bInputAllowed = FALSE; + bInputAllowed = sal_False; if ( !aWndPreview.SetGraphic( _aURL ) ) { @@ -1125,7 +1135,7 @@ void TPGalleryThemeProperties::DoPreview() xMediaPlayer->start(); } - bInputAllowed = TRUE; + bInputAllowed = sal_True; aPreviewString = aString; } } @@ -1149,7 +1159,7 @@ IMPL_LINK( TPGalleryThemeProperties, ClickTakeHdl, void*, EMPTYARG ) } else { - bTakeAll = FALSE; + bTakeAll = sal_False; TakeFiles(); } } @@ -1164,7 +1174,7 @@ IMPL_LINK( TPGalleryThemeProperties, ClickTakeAllHdl, void *, EMPTYARG ) if( bInputAllowed ) { aPreviewTimer.Stop(); - bTakeAll = TRUE; + bTakeAll = sal_True; TakeFiles(); } @@ -1177,7 +1187,7 @@ IMPL_LINK( TPGalleryThemeProperties, SelectFoundHdl, void *, EMPTYARG ) { if( bInputAllowed ) { - BOOL bPreviewPossible = FALSE; + sal_Bool bPreviewPossible = sal_False; aPreviewTimer.Stop(); @@ -1186,7 +1196,7 @@ IMPL_LINK( TPGalleryThemeProperties, SelectFoundHdl, void *, EMPTYARG ) if( aLbxFound.GetSelectEntryCount() == 1 ) { aCbxPreview.Enable(); - bPreviewPossible = TRUE; + bPreviewPossible = sal_True; } else aCbxPreview.Disable(); @@ -1237,14 +1247,14 @@ IMPL_LINK( TPGalleryThemeProperties, EndSearchProgressHdl, SearchProgress *, EMP aLbxFound.SelectEntryPos( 0 ); aBtnTakeAll.Enable(); aCbxPreview.Enable(); - bEntriesFound = TRUE; + bEntriesFound = sal_True; } else { aLbxFound.InsertEntry( String( CUI_RES( RID_SVXSTR_GALLERY_NOFILES ) ) ); aBtnTakeAll.Disable(); aCbxPreview.Disable(); - bEntriesFound = FALSE; + bEntriesFound = sal_False; } return 0L; } diff --git a/cui/source/dialogs/cuigrfflt.cxx b/cui/source/dialogs/cuigrfflt.cxx index 82e95178a2bb..2e8caee8b188 100644 --- a/cui/source/dialogs/cuigrfflt.cxx +++ b/cui/source/dialogs/cuigrfflt.cxx @@ -93,10 +93,10 @@ GraphicFilterDialog::GraphicFilterDialog( Window* pParent, const ResId& rResId, mfScaleY ( 0.0 ), maSizePixel ( LogicToPixel( rGraphic.GetPrefSize(), rGraphic.GetPrefMapMode() ) ), maPreview ( this, CUI_RES( CTL_PREVIEW ) ), - maFlParameter ( this, CUI_RES( FL_PARAMETER ) ), maBtnOK ( this, CUI_RES( BTN_OK ) ), maBtnCancel ( this, CUI_RES( BTN_CANCEL ) ), - maBtnHelp ( this, CUI_RES( BTN_HELP ) ) + maBtnHelp ( this, CUI_RES( BTN_HELP ) ), + maFlParameter ( this, CUI_RES( FL_PARAMETER ) ) { const Size aPreviewSize( maPreview.GetOutputSizePixel() ); Size aGrfSize( maSizePixel ); @@ -170,7 +170,7 @@ IMPL_LINK( GraphicFilterDialog, ImplModifyHdl, void*, EMPTYARG ) // ---------------- GraphicFilterMosaic::GraphicFilterMosaic( Window* pParent, const Graphic& rGraphic, - USHORT nTileWidth, USHORT nTileHeight, BOOL bEnhanceEdges ) : + sal_uInt16 nTileWidth, sal_uInt16 nTileHeight, sal_Bool bEnhanceEdges ) : GraphicFilterDialog( pParent, CUI_RES( RID_SVX_GRFFILTER_DLG_MOSAIC ), rGraphic ), maFtWidth ( this, CUI_RES( DLG_FILTERMOSAIC_FT_WIDTH ) ), maMtrWidth ( this, CUI_RES( DLG_FILTERMOSAIC_MTR_WIDTH ) ), @@ -192,6 +192,12 @@ GraphicFilterMosaic::GraphicFilterMosaic( Window* pParent, const Graphic& rGraph maCbxEdges.SetToggleHdl( GetModifyHdl() ); maMtrWidth.GrabFocus(); + + maFtWidth.SetAccessibleRelationMemberOf(&maFlParameter); + maMtrWidth.SetAccessibleRelationMemberOf(&maFlParameter); + maFtHeight.SetAccessibleRelationMemberOf(&maFlParameter); + maMtrHeight.SetAccessibleRelationMemberOf(&maFlParameter); + maCbxEdges.SetAccessibleRelationMemberOf(&maFlParameter); } // ----------------------------------------------------------------------------- @@ -243,7 +249,7 @@ Graphic GraphicFilterMosaic::GetFilteredGraphic( const Graphic& rGraphic, // ------------------ GraphicFilterSolarize::GraphicFilterSolarize( Window* pParent, const Graphic& rGraphic, - BYTE cGreyThreshold, BOOL bInvert ) : + sal_uInt8 cGreyThreshold, sal_Bool bInvert ) : GraphicFilterDialog ( pParent, CUI_RES( RID_SVX_GRFFILTER_DLG_SOLARIZE ), rGraphic ), maFtThreshold ( this, CUI_RES( DLG_FILTERSOLARIZE_FT_THRESHOLD ) ), maMtrThreshold ( this, CUI_RES( DLG_FILTERSOLARIZE_MTR_THRESHOLD ) ), @@ -307,7 +313,7 @@ Graphic GraphicFilterSolarize::GetFilteredGraphic( const Graphic& rGraphic, // ---------------------- GraphicFilterSepia::GraphicFilterSepia( Window* pParent, const Graphic& rGraphic, - USHORT nSepiaPercent ) : + sal_uInt16 nSepiaPercent ) : GraphicFilterDialog ( pParent, CUI_RES( RID_SVX_GRFFILTER_DLG_SEPIA ), rGraphic ), maFtSepia ( this, CUI_RES( DLG_FILTERSEPIA_FT_SEPIA ) ), maMtrSepia ( this, CUI_RES( DLG_FILTERSEPIA_MTR_SEPIA ) ) @@ -357,7 +363,7 @@ Graphic GraphicFilterSepia::GetFilteredGraphic( const Graphic& rGraphic, // ----------------------- GraphicFilterPoster::GraphicFilterPoster( Window* pParent, const Graphic& rGraphic, - USHORT nPosterCount ) : + sal_uInt16 nPosterCount ) : GraphicFilterDialog ( pParent, CUI_RES( RID_SVX_GRFFILTER_DLG_POSTER ), rGraphic ), maFtPoster ( this, CUI_RES( DLG_FILTERPOSTER_FT_POSTER ) ), maNumPoster ( this, CUI_RES( DLG_FILTERPOSTER_NUM_POSTER ) ) @@ -383,7 +389,7 @@ Graphic GraphicFilterPoster::GetFilteredGraphic( const Graphic& rGraphic, double /*fScaleX*/, double /*fScaleY*/ ) { Graphic aRet; - const USHORT nPosterCount = GetPosterColorCount(); + const sal_uInt16 nPosterCount = GetPosterColorCount(); if( rGraphic.IsAnimated() ) { @@ -443,7 +449,7 @@ Graphic GraphicFilterEmboss::GetFilteredGraphic( const Graphic& rGraphic, double /*fScaleX*/, double /*fScaleY*/ ) { Graphic aRet; - USHORT nAzim, nElev; + sal_uInt16 nAzim, nElev; switch( maCtlLight.GetActualRP() ) { diff --git a/cui/source/dialogs/cuihyperdlg.cxx b/cui/source/dialogs/cuihyperdlg.cxx index 7c38c610b639..cc2cd69f53d7 100644 --- a/cui/source/dialogs/cuihyperdlg.cxx +++ b/cui/source/dialogs/cuihyperdlg.cxx @@ -46,7 +46,7 @@ using ::com::sun::star::frame::XFrame; //# # //######################################################################## -SvxHlinkCtrl::SvxHlinkCtrl( USHORT _nId, SfxBindings & rBindings, SvxHpLinkDlg* pDlg ) +SvxHlinkCtrl::SvxHlinkCtrl( sal_uInt16 _nId, SfxBindings & rBindings, SvxHpLinkDlg* pDlg ) : SfxControllerItem ( _nId, rBindings ) ,aOnlineForwarder ( SID_INTERNET_ONLINE , *this ) ,aRdOnlyForwarder ( SID_READONLY_MODE, *this ) @@ -54,7 +54,7 @@ SvxHlinkCtrl::SvxHlinkCtrl( USHORT _nId, SfxBindings & rBindings, SvxHpLinkDlg* pParent = pDlg; } -void SvxHlinkCtrl::StateChanged( USHORT nSID, SfxItemState eState, +void SvxHlinkCtrl::StateChanged( sal_uInt16 nSID, SfxItemState eState, const SfxPoolItem* pState ) { if ( eState == SFX_ITEM_AVAILABLE ) @@ -73,7 +73,7 @@ void SvxHlinkCtrl::StateChanged( USHORT nSID, SfxItemState eState, break; case SID_READONLY_MODE : { - pParent->SetReadOnlyMode( ( (SfxBoolItem*)pState)->GetValue() == TRUE ); + pParent->SetReadOnlyMode( ( (SfxBoolItem*)pState)->GetValue() == sal_True ); } break; } @@ -129,9 +129,6 @@ SvxHpLinkDlg::SvxHpLinkDlg (Window* pParent, SfxBindings* pBindings) pEntry = AddTabPage ( RID_SVXPAGE_HYPERLINK_NEWDOCUMENT, aStrTitle, aImage, SvxHyperlinkNewDocTp::Create ); pEntry->SetQuickHelpText( CUI_RESSTR( RID_SVXSTR_HYPERDLG_HLDOCNTP_HELP ) ); - // all tab pages set -> create mnemonics - // CreateIconTextAutoMnemonics(); #99671# not useful, because this is not what user expects when using mnemonics on the pages - // create itemset for tabpages mpItemSet = new SfxItemSet( SFX_APP()->GetPool(), SID_HYPERLINK_GETLINK, SID_HYPERLINK_SETLINK ); @@ -142,7 +139,7 @@ SvxHpLinkDlg::SvxHpLinkDlg (Window* pParent, SfxBindings* pBindings) SetInputSet (mpItemSet); // Init Dialog - Start (FALSE); + Start (sal_False); pBindings->Update( SID_READONLY_MODE ); @@ -169,12 +166,12 @@ SvxHpLinkDlg::~SvxHpLinkDlg () |* |************************************************************************/ -BOOL SvxHpLinkDlg::Close() +sal_Bool SvxHpLinkDlg::Close() { GetDispatcher()->Execute( SID_HYPERLINK_DIALOG, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD); - return TRUE; + return sal_True; } /************************************************************************* @@ -201,13 +198,13 @@ void SvxHpLinkDlg::Move() // Size of Extrawindow Size aExtraWndSize( pCurrentPage->GetSizeExtraWnd() ); - BOOL bDoInvalid ; + sal_Bool bDoInvalid ; if( aDlgPos.X()+(1.02*aDlgSize.Width())+aExtraWndSize.Width() > aWindowSize.Width() ) { if( aDlgPos.X() - ( 0.02*aDlgSize.Width() ) - aExtraWndSize.Width() < 0 ) { // Pos Extrawindow anywhere - bDoInvalid = pCurrentPage->MoveToExtraWnd( Point( 1, long(1.1*aDlgPos.Y()) ), TRUE ); + bDoInvalid = pCurrentPage->MoveToExtraWnd( Point( 1, long(1.1*aDlgPos.Y()) ), sal_True ); } else { @@ -281,9 +278,9 @@ IMPL_LINK ( SvxHpLinkDlg, ClickCloseHdl_Impl, void *, EMPTYARG ) |* |************************************************************************/ -USHORT SvxHpLinkDlg::SetPage ( SvxHyperlinkItem* pItem ) +sal_uInt16 SvxHpLinkDlg::SetPage ( SvxHyperlinkItem* pItem ) { - USHORT nPageId = RID_SVXPAGE_HYPERLINK_INTERNET; + sal_uInt16 nPageId = RID_SVXPAGE_HYPERLINK_INTERNET; String aStrURL ( pItem->GetURL() ); INetURLObject aURL ( aStrURL ); @@ -377,7 +374,7 @@ void SvxHpLinkDlg::SetReadOnlyMode( sal_Bool bRdOnly ) |* |************************************************************************/ -void SvxHpLinkDlg::PageCreated( USHORT /*nId*/, IconChoicePage& rPage ) +void SvxHpLinkDlg::PageCreated( sal_uInt16 /*nId*/, IconChoicePage& rPage ) { SvxHyperlinkTabPageBase& rHyperlinkPage = dynamic_cast< SvxHyperlinkTabPageBase& >( rPage ); Reference< XFrame > xDocumentFrame; diff --git a/cui/source/dialogs/cuiimapdlg.src b/cui/source/dialogs/cuiimapdlg.src index 9b60adf854ca..05475f880a3c 100644 --- a/cui/source/dialogs/cuiimapdlg.src +++ b/cui/source/dialogs/cuiimapdlg.src @@ -31,6 +31,7 @@ ModalDialog RID_SVXDLG_IMAPURL { + HelpID = "cui:ModalDialog:RID_SVXDLG_IMAPURL"; SVLook = TRUE ; OutputSize = TRUE ; Closeable = TRUE ; @@ -46,6 +47,7 @@ ModalDialog RID_SVXDLG_IMAPURL }; Edit EDT_URL { + HelpID = "cui:Edit:RID_SVXDLG_IMAPURL:EDT_URL"; Border = TRUE ; TabStop = TRUE ; Left = TRUE ; @@ -61,6 +63,7 @@ ModalDialog RID_SVXDLG_IMAPURL }; ComboBox CBB_TARGETS { + HelpID = "cui:ComboBox:RID_SVXDLG_IMAPURL:CBB_TARGETS"; Border = TRUE ; Sort = TRUE ; Pos = MAP_APPFONT ( 6 , 43 ) ; @@ -78,6 +81,7 @@ ModalDialog RID_SVXDLG_IMAPURL }; Edit EDT_NAME { + HelpID = "cui:Edit:RID_SVXDLG_IMAPURL:EDT_NAME"; Border = TRUE ; TabStop = TRUE ; Left = TRUE ; @@ -94,6 +98,7 @@ ModalDialog RID_SVXDLG_IMAPURL Edit EDT_URLDESCRIPTION { + HelpID = "cui:Edit:RID_SVXDLG_IMAPURL:EDT_URLDESCRIPTION"; Border = TRUE ; TabStop = TRUE ; Left = TRUE ; @@ -109,6 +114,7 @@ ModalDialog RID_SVXDLG_IMAPURL MultiLineEdit EDT_DESCRIPTION { + HelpID = "cui:MultiLineEdit:RID_SVXDLG_IMAPURL:EDT_DESCRIPTION"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 122 ) ; Size = MAP_APPFONT ( 202 , 34 ) ; diff --git a/cui/source/dialogs/cuitbxform.cxx b/cui/source/dialogs/cuitbxform.cxx index aa1fd6ab285f..2e14b9752ab0 100644 --- a/cui/source/dialogs/cuitbxform.cxx +++ b/cui/source/dialogs/cuitbxform.cxx @@ -56,7 +56,7 @@ FmInputRecordNoDialog::FmInputRecordNoDialog(Window * pParent) { m_aRecordNo.SetMin(1); m_aRecordNo.SetMax(0x7FFFFFFF); - m_aRecordNo.SetStrictFormat(TRUE); + m_aRecordNo.SetStrictFormat(sal_True); m_aRecordNo.SetDecimalDigits(0); FreeResource(); diff --git a/cui/source/dialogs/dlgname.cxx b/cui/source/dialogs/dlgname.cxx index e624b0ef2d5d..78cef105a297 100644 --- a/cui/source/dialogs/dlgname.cxx +++ b/cui/source/dialogs/dlgname.cxx @@ -210,7 +210,7 @@ IMPL_LINK_INLINE_END( SvxMessDialog, Button2Hdl, Button *, EMPTYARG ) /*************************************************************************/ -void SvxMessDialog::SetButtonText( USHORT nBtnId, const String& rNewTxt ) +void SvxMessDialog::SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt ) { switch ( nBtnId ) { diff --git a/cui/source/dialogs/dlgname.src b/cui/source/dialogs/dlgname.src index 1d72e877f230..291a50fbc47c 100644 --- a/cui/source/dialogs/dlgname.src +++ b/cui/source/dialogs/dlgname.src @@ -49,6 +49,7 @@ ModalDialog RID_SVXDLG_NAME }; Edit EDT_STRING { + HelpID = "cui:Edit:RID_SVXDLG_NAME:EDT_STRING"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 17 ) ; Size = MAP_APPFONT ( 112 , 12 ) ; @@ -96,6 +97,7 @@ ModalDialog RID_SVXDLG_OBJECT_NAME }; Edit NTD_EDT_NAME { + HelpID = "cui:Edit:RID_SVXDLG_OBJECT_NAME:NTD_EDT_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 14 ) ; Size = MAP_APPFONT ( 168 , 12 ) ; @@ -153,6 +155,7 @@ ModalDialog RID_SVXDLG_OBJECT_TITLE_DESC }; Edit NTD_EDT_TITLE { + HelpID = "cui:Edit:RID_SVXDLG_OBJECT_TITLE_DESC:NTD_EDT_TITLE"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 14 ) ; Size = MAP_APPFONT ( 168 , 12 ) ; @@ -169,6 +172,7 @@ ModalDialog RID_SVXDLG_OBJECT_TITLE_DESC }; MultiLineEdit NTD_EDT_DESC { + HelpID = "cui:MultiLineEdit:RID_SVXDLG_OBJECT_TITLE_DESC:NTD_EDT_DESC"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 41 ) ; Size = MAP_APPFONT ( 168 , (12 * 3) - 2 ) ; @@ -218,12 +222,14 @@ ModalDialog RID_SVXDLG_MESSBOX Moveable = TRUE ; PushButton BTN_1 { + HelpID = "cui:PushButton:RID_SVXDLG_MESSBOX:BTN_1"; Pos = MAP_APPFONT ( 25 , 44 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; }; PushButton BTN_2 { + HelpID = "cui:PushButton:RID_SVXDLG_MESSBOX:BTN_2"; Pos = MAP_APPFONT ( 78 , 44 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; diff --git a/cui/source/dialogs/fmsearch.src b/cui/source/dialogs/fmsearch.src index 186db5a48735..c705f42c5789 100644 --- a/cui/source/dialogs/fmsearch.src +++ b/cui/source/dialogs/fmsearch.src @@ -45,6 +45,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; RadioButton RB_SEARCHFORTEXT { + HelpID = "cui:RadioButton:RID_SVXDLG_SEARCHFORM:RB_SEARCHFORTEXT"; Pos = MAP_APPFONT( 12, 23 ); Size = MAP_APPFONT( 50, 10 ); Group = TRUE; @@ -52,12 +53,14 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; RadioButton RB_SEARCHFORNULL { + HelpID = "cui:RadioButton:RID_SVXDLG_SEARCHFORM:RB_SEARCHFORNULL"; Pos = MAP_APPFONT( 12, 36 ); Size = MAP_APPFONT( 207, 10 ); Text [ en-US ] = "Field content is ~NULL"; }; RadioButton RB_SEARCHFORNOTNULL { + HelpID = "cui:RadioButton:RID_SVXDLG_SEARCHFORM:RB_SEARCHFORNOTNULL"; Pos = MAP_APPFONT( 12, 49 ); Size = MAP_APPFONT( 207, 10 ); Text [ en-US ] = "Field content is not NU~LL"; @@ -86,6 +89,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; ListBox LB_FORM { + HelpID = "cui:ListBox:RID_SVXDLG_SEARCHFORM:LB_FORM"; Border = TRUE; Pos = MAP_APPFONT( 110, 76 ); Size = MAP_APPFONT( 109, 60 ); @@ -102,6 +106,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; RadioButton RB_SINGLEFIELD { + HelpID = "cui:RadioButton:RID_SVXDLG_SEARCHFORM:RB_SINGLEFIELD"; Pos = MAP_APPFONT( 24, 106 ); Size = MAP_APPFONT( 75, 10 ); Text [ en-US ] = "Single field"; @@ -204,6 +209,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; CheckBox CB_HALFFULLFORMS { + HelpID = "cui:CheckBox:RID_SVXDLG_SEARCHFORM:CB_HALFFULLFORMS"; Pos = MAP_APPFONT( 105, 209 ); Size = MAP_APPFONT( 85, 10 ); TabStop = TRUE ; @@ -211,6 +217,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; CheckBox CB_SOUNDSLIKECJK { + HelpID = "cui:CheckBox:RID_SVXDLG_SEARCHFORM:CB_SOUNDSLIKECJK"; Pos = MAP_APPFONT( 190, 209 ); Size = MAP_APPFONT( 84, 10 ); TabStop = TRUE ; @@ -218,6 +225,7 @@ ModalDialog RID_SVXDLG_SEARCHFORM }; PushButton PB_SOUNDSLIKESETTINGS { + HelpID = "cui:PushButton:RID_SVXDLG_SEARCHFORM:PB_SOUNDSLIKESETTINGS"; Pos = MAP_APPFONT( 275, 207 ); Size = MAP_APPFONT( 14, 14 ); TabStop = TRUE ; diff --git a/cui/source/dialogs/gallery.src b/cui/source/dialogs/gallery.src index db0d4bbf3973..b1c53e65c706 100644 --- a/cui/source/dialogs/gallery.src +++ b/cui/source/dialogs/gallery.src @@ -94,6 +94,7 @@ TabPage RID_SVXTABPAGE_GALLERY_GENERAL }; Edit EDT_MS_NAME { + HelpID = "cui:Edit:RID_SVXTABPAGE_GALLERY_GENERAL:EDT_MS_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 60 , 10 ) ; Size = MAP_APPFONT ( 194 , 12 ) ; @@ -174,6 +175,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; ComboBox CBB_FILETYPE { + HelpID = "cui:ComboBox:RID_SVXTABPAGE_GALLERYTHEME_FILES:CBB_FILETYPE"; Pos = MAP_APPFONT ( 57 , 6 ) ; Size = MAP_APPFONT ( 121 , 69 ) ; TabStop = TRUE ; @@ -183,6 +185,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; MultiListBox LBX_FOUND { + HelpID = "cui:MultiListBox:RID_SVXTABPAGE_GALLERYTHEME_FILES:LBX_FOUND"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 23 ) ; Size = MAP_APPFONT ( 172 , 156 ) ; @@ -191,6 +194,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; PushButton BTN_SEARCH { + HelpID = "cui:PushButton:RID_SVXTABPAGE_GALLERYTHEME_FILES:BTN_SEARCH"; Pos = MAP_APPFONT ( 184 , 6 ) ; Size = MAP_APPFONT ( 70 , 14 ) ; TabStop = TRUE ; @@ -198,6 +202,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; PushButton BTN_TAKE { + HelpID = "cui:PushButton:RID_SVXTABPAGE_GALLERYTHEME_FILES:BTN_TAKE"; Pos = MAP_APPFONT ( 184 , 24 ) ; Size = MAP_APPFONT ( 70 , 14 ) ; TabStop = TRUE ; @@ -205,6 +210,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; PushButton BTN_TAKEALL { + HelpID = "cui:PushButton:RID_SVXTABPAGE_GALLERYTHEME_FILES:BTN_TAKEALL"; Pos = MAP_APPFONT ( 184 , 42 ) ; Size = MAP_APPFONT ( 70 , 14 ) ; TabStop = TRUE ; @@ -212,6 +218,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; CheckBox CBX_PREVIEW { + HelpID = "cui:CheckBox:RID_SVXTABPAGE_GALLERYTHEME_FILES:CBX_PREVIEW"; Pos = MAP_APPFONT ( 184 , 76 ) ; Size = MAP_APPFONT ( 70 , 12 ) ; Text [ en-US ] = "Pr~eview" ; @@ -224,6 +231,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; PushButton BTN_MADDIN1 { + HelpID = "cui:PushButton:RID_SVXTABPAGE_GALLERYTHEME_FILES:BTN_MADDIN1"; Pos = MAP_APPFONT ( 220 , 63 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -231,6 +239,7 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES }; PushButton BTN_MADDIN2 { + HelpID = "cui:PushButton:RID_SVXTABPAGE_GALLERYTHEME_FILES:BTN_MADDIN2"; Pos = MAP_APPFONT ( 220 , 80 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -388,6 +397,7 @@ ModalDialog RID_SVXDLG_GALLERY_ACTUALIZE_PROGRESS ModalDialog RID_SVXDLG_GALLERY_THEMEID { + HelpID = "cui:ModalDialog:RID_SVXDLG_GALLERY_THEMEID"; OutputSize = TRUE ; Border = TRUE ; SVLook = TRUE ; @@ -415,6 +425,7 @@ ModalDialog RID_SVXDLG_GALLERY_THEMEID }; ListBox LB_RESNAME { + HelpID = "cui:ListBox:RID_SVXDLG_GALLERY_THEMEID:LB_RESNAME"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 100 , 60 ) ; @@ -437,10 +448,6 @@ String RID_SVXSTR_GALLERYPROPS_OBJECT { Text [ en-US ] = "Object;Objects" ; }; -String RID_SVXSTR_GALLERYPROPS_GALTHEME -{ - Text [ en-US ] = "Gallery Theme" ; -}; String RID_SVXSTR_GALLERY_READONLY { Text [ en-US ] = " (read-only)" ; diff --git a/cui/source/dialogs/grfflt.src b/cui/source/dialogs/grfflt.src index 76cf9ecc6f74..c13eaf373b2a 100644 --- a/cui/source/dialogs/grfflt.src +++ b/cui/source/dialogs/grfflt.src @@ -37,7 +37,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_MOSAIC { - HelpID = SID_GRFFILTER_MOSAIC; + HelpID = CMD_SID_GRFFILTER_MOSAIC; OutputSize = TRUE ; Moveable = TRUE ; SVLook = TRUE ; @@ -66,6 +66,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_MOSAIC #define MA_Y1 MA_Y0 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_CTRL_DESC_Y MetricField DLG_FILTERMOSAIC_MTR_WIDTH { + HelpID = "cui:MetricField:RID_SVX_GRFFILTER_DLG_MOSAIC:DLG_FILTERMOSAIC_MTR_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , MA_Y1 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -91,6 +92,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_MOSAIC #define MA_Y3 MA_Y2 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_CTRL_DESC_Y MetricField DLG_FILTERMOSAIC_MTR_HEIGHT { + HelpID = "cui:MetricField:RID_SVX_GRFFILTER_DLG_MOSAIC:DLG_FILTERMOSAIC_MTR_HEIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 12, MA_Y3 ) ; Size = MAP_APPFONT ( 35, 12 ) ; @@ -109,6 +111,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_MOSAIC #define MA_Y4 MA_Y3 + RSC_CD_TEXTBOX_HEIGHT + RSC_SP_CTRL_Y CheckBox DLG_FILTERMOSAIC_CBX_EDGES { + HelpID = "cui:CheckBox:RID_SVX_GRFFILTER_DLG_MOSAIC:DLG_FILTERMOSAIC_CBX_EDGES"; Pos = MAP_APPFONT ( 12, MA_Y4 ) ; Size = MAP_APPFONT ( 91, 12 ) ; TabStop = TRUE ; @@ -141,7 +144,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_MOSAIC ModalDialog RID_SVX_GRFFILTER_DLG_SOLARIZE { - HelpID = SID_GRFFILTER_SOLARIZE; + HelpID = CMD_SID_GRFFILTER_SOLARIZE; OutputSize = TRUE ; Moveable = TRUE ; SVLook = TRUE ; @@ -170,6 +173,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_SOLARIZE #define MA_Y6 MA_Y5 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_CTRL_DESC_Y MetricField DLG_FILTERSOLARIZE_MTR_THRESHOLD { + HelpID = "cui:MetricField:RID_SVX_GRFFILTER_DLG_SOLARIZE:DLG_FILTERSOLARIZE_MTR_THRESHOLD"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , MA_Y6 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -186,6 +190,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_SOLARIZE #define MA_Y7 MA_Y6 + RSC_CD_TEXTBOX_HEIGHT + RSC_SP_CTRL_GROUP_Y CheckBox DLG_FILTERSOLARIZE_CBX_INVERT { + HelpID = "cui:CheckBox:RID_SVX_GRFFILTER_DLG_SOLARIZE:DLG_FILTERSOLARIZE_CBX_INVERT"; Pos = MAP_APPFONT ( 12, 46 ) ; Size = MAP_APPFONT ( 77, 12 ) ; TabStop = TRUE ; @@ -218,7 +223,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_SOLARIZE ModalDialog RID_SVX_GRFFILTER_DLG_SEPIA { - HelpID = SID_GRFFILTER_SEPIA; + HelpID = CMD_SID_GRFFILTER_SEPIA; OutputSize = TRUE ; Moveable = TRUE ; SVLook = TRUE ; @@ -247,6 +252,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_SEPIA #define MA_Y9 MA_Y8 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_CTRL_DESC_Y MetricField DLG_FILTERSEPIA_MTR_SEPIA { + HelpID = "cui:MetricField:RID_SVX_GRFFILTER_DLG_SEPIA:DLG_FILTERSEPIA_MTR_SEPIA"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , MA_Y9 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -290,7 +296,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_SEPIA ModalDialog RID_SVX_GRFFILTER_DLG_POSTER { - HelpID = SID_GRFFILTER_POSTER; + HelpID = CMD_SID_GRFFILTER_POSTER; OutputSize = TRUE ; Moveable = TRUE ; SVLook = TRUE ; @@ -319,6 +325,7 @@ ModalDialog RID_SVX_GRFFILTER_DLG_POSTER #define MA_Y11 MA_Y10 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_CTRL_DESC_Y NumericField DLG_FILTERPOSTER_NUM_POSTER { + HelpID = "cui:NumericField:RID_SVX_GRFFILTER_DLG_POSTER:DLG_FILTERPOSTER_NUM_POSTER"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , MA_Y11 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -359,13 +366,14 @@ ModalDialog RID_SVX_GRFFILTER_DLG_POSTER TabPage RID_SVX_GRFFILTER_DLG_EMBOSS_TAB { + HelpID = "cui:TabPage:RID_SVX_GRFFILTER_DLG_EMBOSS_TAB"; Pos = MAP_APPFONT ( 0, 0 ) ; Size = MAP_APPFONT ( 0, 0 ) ; }; ModalDialog RID_SVX_GRFFILTER_DLG_EMBOSS { - HelpID = SID_GRFFILTER_EMBOSS; + HelpID = CMD_SID_GRFFILTER_EMBOSS; OutputSize = TRUE ; Moveable = TRUE ; SVLook = TRUE ; diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx index 01d01525bc1f..732613dcccb0 100644 --- a/cui/source/dialogs/hangulhanjadlg.cxx +++ b/cui/source/dialogs/hangulhanjadlg.cxx @@ -49,7 +49,7 @@ #include <comphelper/processfactory.hxx> #define HHC editeng::HangulHanjaConversion -#define LINE_CNT static_cast< USHORT >(2) +#define LINE_CNT static_cast< sal_uInt16 >(2) //............................................................................. namespace svx @@ -107,7 +107,7 @@ namespace svx PseudoRubyText( const String& _rPrimary, const String& _rSecondary, const RubyPosition _ePosition ); public: - void Paint( OutputDevice& _rDevice, const Rectangle& _rRect, USHORT _nTextStyle, + void Paint( OutputDevice& _rDevice, const Rectangle& _rRect, sal_uInt16 _nTextStyle, Rectangle* _pPrimaryLocation = NULL, Rectangle* _pSecondaryLocation = NULL, ::vcl::ControlLayoutData* _pLayoutData = NULL ); }; @@ -121,7 +121,7 @@ namespace svx } //------------------------------------------------------------------------- - void PseudoRubyText::Paint( OutputDevice& _rDevice, const Rectangle& _rRect, USHORT _nTextStyle, + void PseudoRubyText::Paint( OutputDevice& _rDevice, const Rectangle& _rRect, sal_uInt16 _nTextStyle, Rectangle* _pPrimaryLocation, Rectangle* _pSecondaryLocation, ::vcl::ControlLayoutData* _pLayoutData ) { bool bLayoutOnly = NULL != _pLayoutData; @@ -193,7 +193,7 @@ namespace svx // now draw the texts // as we already calculated the precise rectangles for the texts, we don't want to // use the alignment flags given - within it's rect, every text is centered - USHORT nDrawTextStyle( _nTextStyle ); + sal_uInt16 nDrawTextStyle( _nTextStyle ); nDrawTextStyle &= ~( TEXT_DRAW_RIGHT | TEXT_DRAW_LEFT | TEXT_DRAW_BOTTOM | TEXT_DRAW_TOP ); nDrawTextStyle |= TEXT_DRAW_CENTER | TEXT_DRAW_VCENTER; @@ -256,7 +256,7 @@ namespace svx ++aTextRect.Top(); --aTextRect.Bottom(); // calculate the text flags for the painting - USHORT nTextStyle = TEXT_DRAW_MNEMONIC; + sal_uInt16 nTextStyle = TEXT_DRAW_MNEMONIC; WinBits nStyle = GetStyle( ); // the horizontal alignment @@ -326,7 +326,7 @@ namespace svx { OutputDevice* pDev = rUDEvt.GetDevice(); Rectangle aRect = rUDEvt.GetRect(); - USHORT nItemId = rUDEvt.GetItemId(); + sal_uInt16 nItemId = rUDEvt.GetItemId(); String sText = *static_cast< String* >( GetItemData( nItemId ) ); pDev->DrawText( aRect, sText, TEXT_DRAW_CENTER | TEXT_DRAW_VCENTER ); @@ -334,7 +334,7 @@ namespace svx void SuggestionSet::ClearSet() { - USHORT i, nCount = GetItemCount(); + sal_uInt16 i, nCount = GetItemCount(); for ( i = 0; i < nCount; ++i ) delete static_cast< String* >( GetItemData(i) ); Clear(); @@ -430,7 +430,7 @@ namespace svx if( m_bDisplayListBox != bDisplayListBox ) { Control& rOldControl = implGetCurrentControl(); - BOOL bHasFocus = rOldControl.HasFocus(); + sal_Bool bHasFocus = rOldControl.HasFocus(); m_bDisplayListBox = bDisplayListBox; @@ -452,12 +452,12 @@ namespace svx m_bInSelectionUpdate = true; if(pControl==&m_aListBox) { - USHORT nPos = m_aListBox.GetSelectEntryPos(); + sal_uInt16 nPos = m_aListBox.GetSelectEntryPos(); m_aValueSet.SelectItem( nPos+1 ); //itemid == pos+1 (id 0 has special meaning) } else { - USHORT nPos = m_aValueSet.GetSelectItemId()-1; //itemid == pos+1 (id 0 has special meaning) + sal_uInt16 nPos = m_aValueSet.GetSelectItemId()-1; //itemid == pos+1 (id 0 has special meaning) m_aListBox.SelectEntryPos( nPos ); } m_bInSelectionUpdate = false; @@ -476,21 +476,21 @@ namespace svx } void SuggestionDisplay::InsertEntry( const XubString& rStr ) { - USHORT nItemId = m_aListBox.InsertEntry( rStr ) + 1; //itemid == pos+1 (id 0 has special meaning) + sal_uInt16 nItemId = m_aListBox.InsertEntry( rStr ) + 1; //itemid == pos+1 (id 0 has special meaning) m_aValueSet.InsertItem( nItemId ); String* pItemData = new String(rStr); m_aValueSet.SetItemData( nItemId, pItemData ); } - void SuggestionDisplay::SelectEntryPos( USHORT nPos ) + void SuggestionDisplay::SelectEntryPos( sal_uInt16 nPos ) { m_aListBox.SelectEntryPos( nPos ); m_aValueSet.SelectItem( nPos+1 ); //itemid == pos+1 (id 0 has special meaning) } - USHORT SuggestionDisplay::GetEntryCount() const + sal_uInt16 SuggestionDisplay::GetEntryCount() const { return m_aListBox.GetEntryCount(); } - XubString SuggestionDisplay::GetEntry( USHORT nPos ) const + XubString SuggestionDisplay::GetEntry( sal_uInt16 nPos ) const { return m_aListBox.GetEntry( nPos ); } @@ -675,12 +675,6 @@ namespace svx } //------------------------------------------------------------------------- - void HangulHanjaConversionDialog::SetOptionsHdl( const Link& _rHdl ) - { - m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eOptions, _rHdl ); - } - - //------------------------------------------------------------------------- void HangulHanjaConversionDialog::SetFindHdl( const Link& _rHdl ) { m_aFind.SetClickHdl( _rHdl ); @@ -745,9 +739,9 @@ namespace svx pOtherBox = &m_aHangulOnly; if (pBox && pOtherBox) { - BOOL bBoxChecked = pBox->IsChecked(); + sal_Bool bBoxChecked = pBox->IsChecked(); if (bBoxChecked) - pOtherBox->Check( FALSE ); + pOtherBox->Check( sal_False ); pOtherBox->Enable( !bBoxChecked ); } @@ -851,20 +845,15 @@ namespace svx } //------------------------------------------------------------------------- - sal_Bool HangulHanjaConversionDialog::GetByCharacter( ) const - { - return m_aReplaceByChar.IsChecked(); - } - //------------------------------------------------------------------------- void HangulHanjaConversionDialog::SetConversionDirectionState( sal_Bool _bTryBothDirections, HHC::ConversionDirection _ePrimaryConversionDirection ) { // default state: try both direction - m_aHangulOnly.Check( FALSE ); - m_aHangulOnly.Enable( TRUE ); - m_aHanjaOnly.Check( FALSE ); - m_aHanjaOnly.Enable( TRUE ); + m_aHangulOnly.Check( sal_False ); + m_aHangulOnly.Enable( sal_True ); + m_aHanjaOnly.Check( sal_False ); + m_aHanjaOnly.Enable( sal_True ); if (!_bTryBothDirections) { @@ -1103,7 +1092,7 @@ namespace svx IMPL_LINK( HangulHanjaOptionsDialog, DeleteDictHdl, void*, EMPTYARG ) { - USHORT nSelPos = m_aDictsLB.GetSelectEntryPos(); + sal_uInt16 nSelPos = m_aDictsLB.GetSelectEntryPos(); if( nSelPos != LISTBOX_ENTRY_NOTFOUND ) { Reference< XConversionDictionary > xDic( m_aDictList[ nSelPos ] ); @@ -1152,7 +1141,7 @@ namespace svx ,m_pCheckButtonData ( NULL ) ,m_xConversionDictionaryList( NULL ) { - m_aDictsLB.SetWindowBits( WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE ); + m_aDictsLB.SetStyle( m_aDictsLB.GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE ); m_aDictsLB.SetSelectionMode( SINGLE_SELECTION ); m_aDictsLB.SetHighlightRange(); m_aDictsLB.SetSelectHdl( LINK( this, HangulHanjaOptionsDialog, DictsLB_SelectHdl ) ); @@ -1479,8 +1468,8 @@ namespace svx { const KeyEvent* pKEvt = rNEvt.GetKeyEvent(); const KeyCode& rKeyCode = pKEvt->GetKeyCode(); - USHORT nMod = rKeyCode.GetModifier(); - USHORT nCode = rKeyCode.GetCode(); + sal_uInt16 nMod = rKeyCode.GetModifier(); + sal_uInt16 nCode = rKeyCode.GetCode(); if( nCode == KEY_TAB && ( !nMod || KEY_SHIFT == nMod ) ) { bool bUp = KEY_SHIFT == nMod; @@ -1863,7 +1852,7 @@ namespace svx aName = xDic->getName(); m_aBookLB.InsertEntry( aName ); } - m_aBookLB.SelectEntryPos( USHORT( _nSelDict ) ); + m_aBookLB.SelectEntryPos( sal_uInt16( _nSelDict ) ); FreeResource(); diff --git a/cui/source/dialogs/hangulhanjadlg.src b/cui/source/dialogs/hangulhanjadlg.src index 11e2fe415c38..d4736a491490 100644 --- a/cui/source/dialogs/hangulhanjadlg.src +++ b/cui/source/dialogs/hangulhanjadlg.src @@ -44,6 +44,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA PushButton PB_FIND { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA:PB_FIND"; Pos = MAP_APPFONT( 207, 23 ); Size = MAP_APPFONT( 30, 14 ); @@ -67,6 +68,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_SIMPLE_CONVERSION { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_SIMPLE_CONVERSION"; Pos = MAP_APPFONT( 51, 81 ); Size = MAP_APPFONT( 60, 8 ); @@ -77,6 +79,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANJA_HANGUL_BRACKETED { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_BRACKETED"; Pos = MAP_APPFONT( 114, 81 ); Size = MAP_APPFONT( 60, 8 ); @@ -85,6 +88,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANGUL_HANJA_BRACKETED { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_BRACKETED"; Pos = MAP_APPFONT( 177, 81 ); Size = MAP_APPFONT( 60, 8 ); @@ -93,6 +97,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANGUL_HANJA_ABOVE { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_ABOVE"; Pos = MAP_APPFONT( 51, 95 ); Size = MAP_APPFONT( 60, 16 ); @@ -102,6 +107,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANGUL_HANJA_BELOW { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_BELOW"; Pos = MAP_APPFONT( 114, 95 ); Size = MAP_APPFONT( 60, 16 ); @@ -111,6 +117,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANJA_HANGUL_ABOVE { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_ABOVE"; Pos = MAP_APPFONT( 56, 114 ); Size = MAP_APPFONT( 60, 16 ); @@ -120,6 +127,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA RadioButton RB_HANJA_HANGUL_BELOW { + HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_BELOW"; Pos = MAP_APPFONT( 114, 114 ); Size = MAP_APPFONT( 60, 16 ); @@ -137,6 +145,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA CheckBox CB_HANGUL_ONLY { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_HANGUL_ONLY"; Pos = MAP_APPFONT( 51, 134 ); Size = MAP_APPFONT( 60, 8 ); @@ -145,6 +154,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA CheckBox CB_HANJA_ONLY { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_HANJA_ONLY"; Pos = MAP_APPFONT( 114, 134 ); Size = MAP_APPFONT( 55, 8 ); @@ -159,6 +169,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA CheckBox CB_REPLACE_BY_CHARACTER { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_REPLACE_BY_CHARACTER"; Pos = MAP_APPFONT( 241, 81 ); Size = MAP_APPFONT( 55, 24 ); @@ -212,36 +223,42 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_OPT }; CheckBox CB_IGNOREPOST { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA_OPT:CB_IGNOREPOST"; Pos = MAP_APPFONT ( HHO_COL_1a, HHO_ROW_9 ) ; Size = MAP_APPFONT ( HHO_COL_6 - HHO_COL_1a , 12 ) ; Text[ en-US ] = "Ignore post-positional word"; }; CheckBox CB_SHOWRECENTLYFIRST { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA_OPT:CB_SHOWRECENTLYFIRST"; Pos = MAP_APPFONT ( HHO_COL_1a, HHO_ROW_11 ) ; Size = MAP_APPFONT ( HHO_COL_6 - HHO_COL_1a , 12 ) ; Text [ en-US ] = "Show recently used entries first"; }; CheckBox CB_AUTOREPLACEUNIQUE { + HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA_OPT:CB_AUTOREPLACEUNIQUE"; Pos = MAP_APPFONT ( HHO_COL_1a, HHO_ROW_12 ) ; Size = MAP_APPFONT ( HHO_COL_6 - HHO_COL_1a , 12 ) ; Text [ en-US ] = "Replace all unique entries automatically"; }; PushButton PB_HHO_NEW { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA_OPT:PB_HHO_NEW"; Pos = MAP_APPFONT ( HHO_COL_3 , HHO_ROW_2 ) ; Size = MAP_APPFONT ( HHO_COL_4 - HHO_COL_3 , 14 ) ; Text [ en-US ] = "New..."; }; PushButton PB_HHO_EDIT { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA_OPT:PB_HHO_EDIT"; Pos = MAP_APPFONT ( HHO_COL_3 , HHO_ROW_4 ) ; Size = MAP_APPFONT ( HHO_COL_4 - HHO_COL_3 , 14 ) ; Text [ en-US ] = "Edit..."; }; PushButton PB_HHO_DELETE { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA_OPT:PB_HHO_DELETE"; Pos = MAP_APPFONT ( HHO_COL_3 , HHO_ROW_6 ) ; Size = MAP_APPFONT ( HHO_COL_4 - HHO_COL_3 , 14 ) ; Text [ en-US ] = "Delete"; @@ -291,6 +308,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_NEWDICT }; Edit ED_DICTNAME { + HelpID = "cui:Edit:RID_SVX_MDLG_HANGULHANJA_NEWDICT:ED_DICTNAME"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 14 ) ; Size = MAP_APPFONT ( 90 , 12 ) ; @@ -340,6 +358,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; ListBox LB_BOOK { + HelpID = "cui:ListBox:RID_SVX_MDLG_HANGULHANJA_EDIT:LB_BOOK"; Pos = MAP_APPFONT ( HHE_COL_3 , HHE_ROW_1 ) ; Size = MAP_APPFONT ( HHE_COL_4 - HHE_COL_3 , 60 ) ; DropDown = TRUE; @@ -353,6 +372,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; ComboBox LB_ORIGINAL { + HelpID = "cui:ComboBox:RID_SVX_MDLG_HANGULHANJA_EDIT:LB_ORIGINAL"; Pos = MAP_APPFONT ( HHE_COL_1 , HHE_ROW_5 ) ; Size = MAP_APPFONT ( HHE_COL_4 - HHE_COL_1 , 60 ) ; DropDown = TRUE; @@ -366,6 +386,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; Edit ED_1 { + HelpID = "cui:Edit:RID_SVX_MDLG_HANGULHANJA_EDIT:ED_1"; Pos = MAP_APPFONT ( HHE_COL_1 , HHE_ROW_11 ) ; Size = MAP_APPFONT ( HHE_COL_3_1 - HHE_COL_1 , 12 ) ; Hide = False; @@ -373,6 +394,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; Edit ED_2 { + HelpID = "cui:Edit:RID_SVX_MDLG_HANGULHANJA_EDIT:ED_2"; Pos = MAP_APPFONT ( HHE_COL_1 , HHE_ROW_11 + 12 ) ; Size = MAP_APPFONT ( HHE_COL_3_1 - HHE_COL_1 , 12 ) ; Hide = False; @@ -380,6 +402,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; Edit ED_3 { + HelpID = "cui:Edit:RID_SVX_MDLG_HANGULHANJA_EDIT:ED_3"; Pos = MAP_APPFONT ( HHE_COL_1 , HHE_ROW_11 + 24 ) ; Size = MAP_APPFONT ( HHE_COL_3_1 - HHE_COL_1 , 12 ) ; Hide = False; @@ -387,6 +410,7 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; Edit ED_4 { + HelpID = "cui:Edit:RID_SVX_MDLG_HANGULHANJA_EDIT:ED_4"; Pos = MAP_APPFONT ( HHE_COL_1 , HHE_ROW_11 + 36 ) ; Size = MAP_APPFONT ( HHE_COL_3_1 - HHE_COL_1 , 12 ) ; Hide = False; @@ -401,12 +425,14 @@ ModalDialog RID_SVX_MDLG_HANGULHANJA_EDIT }; PushButton PB_HHE_NEW { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA_EDIT:PB_HHE_NEW"; Pos = MAP_APPFONT ( HHE_COL_5 , HHE_ROW_a1 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "New"; }; PushButton PB_HHE_DELETE { + HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA_EDIT:PB_HHE_DELETE"; Pos = MAP_APPFONT ( HHE_COL_5 , HHE_ROW_a3 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "Delete"; diff --git a/cui/source/dialogs/hldocntp.cxx b/cui/source/dialogs/hldocntp.cxx index 3d7942f4dadc..356416a61753 100644 --- a/cui/source/dialogs/hldocntp.cxx +++ b/cui/source/dialogs/hldocntp.cxx @@ -94,7 +94,7 @@ sal_Bool SvxHyperlinkNewDocTp::ImplGetURLObject( const String& rPath, const Stri } if ( bIsValidURL ) { - USHORT nPos = maLbDocTypes.GetSelectEntryPos(); + sal_uInt16 nPos = maLbDocTypes.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) aURLObject.SetExtension( ((DocumentTypeData*)maLbDocTypes.GetEntryData( nPos ))->aStrExt ); } @@ -121,7 +121,7 @@ SvxHyperlinkNewDocTp::SvxHyperlinkNewDocTp ( Window *pParent, const SfxItemSet& maLbDocTypes ( this, CUI_RES (LB_DOCUMENT_TYPES) ) { // Set HC bitmaps and disable display of bitmap names. - maBtCreate.EnableTextDisplay (FALSE); + maBtCreate.EnableTextDisplay (sal_False); InitStdControls(); FreeResource(); @@ -138,12 +138,15 @@ SvxHyperlinkNewDocTp::SvxHyperlinkNewDocTp ( Window *pParent, const SfxItemSet& maBtCreate.SetClickHdl ( LINK ( this, SvxHyperlinkNewDocTp, ClickNewHdl_Impl ) ); + maBtCreate.SetAccessibleRelationMemberOf( &maGrpNewDoc ); + maBtCreate.SetAccessibleRelationLabeledBy( &maFtPath ); + FillDocumentList (); } SvxHyperlinkNewDocTp::~SvxHyperlinkNewDocTp () { - for ( USHORT n=0; n<maLbDocTypes.GetEntryCount(); n++ ) + for ( sal_uInt16 n=0; n<maLbDocTypes.GetEntryCount(); n++ ) { DocumentTypeData* pTypeData = (DocumentTypeData*) maLbDocTypes.GetEntryData ( n ); @@ -169,37 +172,6 @@ void SvxHyperlinkNewDocTp::FillDlgFields ( String& /*aStrURL*/ ) #define INTERNETSHORTCUT_URL_TAG "URL" #define INTERNETSHORTCUT_ICONID_TAG "IconIndex" -void SvxHyperlinkNewDocTp::ReadURLFile( const String& rFile, String& rTitle, String& rURL, sal_Int32& rIconId, BOOL* pShowAsFolder ) -{ - // Open file - Config aCfg( rFile ); - aCfg.SetGroup( INTERNETSHORTCUT_ID_TAG ); - - // read URL - rURL = aCfg.ReadKey( ByteString( RTL_CONSTASCII_STRINGPARAM( INTERNETSHORTCUT_URL_TAG) ), RTL_TEXTENCODING_ASCII_US ); - SvtPathOptions aPathOpt; - rURL = aPathOpt.SubstituteVariable( rURL ); - - // read target - if ( pShowAsFolder ) - { - String aTemp( aCfg.ReadKey( ByteString( RTL_CONSTASCII_STRINGPARAM( INTERNETSHORTCUT_TARGET_TAG ) ), RTL_TEXTENCODING_ASCII_US ) ); - *pShowAsFolder = aTemp == String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( INTERNETSHORTCUT_FOLDER_TAG ) ); - } - - // read image-ID - String aStrIconId( aCfg.ReadKey( ByteString( RTL_CONSTASCII_STRINGPARAM( INTERNETSHORTCUT_ICONID_TAG ) ), RTL_TEXTENCODING_ASCII_US ) ); - rIconId = aStrIconId.ToInt32(); - - // read title - String aLangStr = aPathOpt.SubstituteVariable( DEFINE_CONST_UNICODE("$(vlang)") ); - ByteString aLang( aLangStr, RTL_TEXTENCODING_UTF8 ); - ByteString aGroup = INTERNETSHORTCUT_ID_TAG; - ( ( aGroup += '-' ) += aLang ) += ".W"; - aCfg.SetGroup( aGroup ); - rTitle = String( aCfg.ReadKey( INTERNETSHORTCUT_TITLE_TAG ), RTL_TEXTENCODING_UTF7 ); -} - void SvxHyperlinkNewDocTp::FillDocumentList () { EnterWait(); @@ -306,7 +278,7 @@ void SvxHyperlinkNewDocTp::SetInitFocus() |* \************************************************************************/ -BOOL SvxHyperlinkNewDocTp::AskApply() +sal_Bool SvxHyperlinkNewDocTp::AskApply() { INetURLObject aINetURLObject; sal_Bool bRet = ImplGetURLObject( maCbbPath.GetText(), maCbbPath.GetBaseURL(), aINetURLObject ); @@ -375,7 +347,7 @@ void SvxHyperlinkNewDocTp::DoApply () if ( aStrNewName != aEmptyStr ) { // get private-url - USHORT nPos = maLbDocTypes.GetSelectEntryPos(); + sal_uInt16 nPos = maLbDocTypes.GetSelectEntryPos(); if( nPos == LISTBOX_ENTRY_NOTFOUND ) nPos=0; String aStrDocName ( ( ( DocumentTypeData* ) @@ -454,14 +426,14 @@ IMPL_LINK ( SvxHyperlinkNewDocTp, ClickNewHdl_Impl, void *, EMPTYARG ) utl::LocalFileHelper::ConvertSystemPathToURL( aTempStrURL, maCbbPath.GetBaseURL(), aStrURL ); String aStrPath = aStrURL; - BOOL bZeroPath = ( aStrPath.Len() == 0 ); - BOOL bHandleFileName = bZeroPath; // when path has length of 0, then the rest should always be handled + sal_Bool bZeroPath = ( aStrPath.Len() == 0 ); + sal_Bool bHandleFileName = bZeroPath; // when path has length of 0, then the rest should always be handled // as file name, otherwise we do not yet know if( bZeroPath ) aStrPath = SvtPathOptions().GetWorkPath(); else if( !::utl::UCBContentHelper::IsFolder( aStrURL ) ) - bHandleFileName = TRUE; + bHandleFileName = sal_True; xFolderPicker->setDisplayDirectory( aStrPath ); DisableClose( sal_True ); @@ -492,7 +464,7 @@ IMPL_LINK ( SvxHyperlinkNewDocTp, ClickNewHdl_Impl, void *, EMPTYARG ) maLbDocTypes.GetSelectEntryPos() != LISTBOX_ENTRY_NOTFOUND ) { // get private-url - USHORT nPos = maLbDocTypes.GetSelectEntryPos(); + sal_uInt16 nPos = maLbDocTypes.GetSelectEntryPos(); aNewURL.setExtension( ( ( DocumentTypeData* ) maLbDocTypes.GetEntryData( nPos ) )->aStrExt ); } diff --git a/cui/source/dialogs/hldoctp.cxx b/cui/source/dialogs/hldoctp.cxx index 770736162f0b..63d96e8a0b75 100644 --- a/cui/source/dialogs/hldoctp.cxx +++ b/cui/source/dialogs/hldoctp.cxx @@ -59,11 +59,11 @@ SvxHyperlinkDocTp::SvxHyperlinkDocTp ( Window *pParent, const SfxItemSet& rItemS maFtURL ( this, CUI_RES (FT_URL) ), maFtFullURL ( this, CUI_RES (FT_FULL_URL) ), maBtBrowse ( this, CUI_RES (BTN_BROWSE) ), - mbMarkWndOpen ( FALSE ) + mbMarkWndOpen ( sal_False ) { // Disable display of bitmap names. - maBtBrowse.EnableTextDisplay (FALSE); - maBtFileopen.EnableTextDisplay (FALSE); + maBtBrowse.EnableTextDisplay (sal_False); + maBtFileopen.EnableTextDisplay (sal_False); InitStdControls(); FreeResource(); @@ -86,6 +86,10 @@ SvxHyperlinkDocTp::SvxHyperlinkDocTp ( Window *pParent, const SfxItemSet& rItemS maCbbPath.SetLoseFocusHdl( LINK ( this, SvxHyperlinkDocTp, LostFocusPathHdl_Impl ) ); + maBtBrowse.SetAccessibleRelationMemberOf( &maGrpTarget ); + maBtBrowse.SetAccessibleRelationLabeledBy( &maFtTarget ); + maBtFileopen.SetAccessibleRelationMemberOf( &maGrpDocument ); + maBtFileopen.SetAccessibleRelationLabeledBy( &maFtPath ); maTimer.SetTimeoutHdl ( LINK ( this, SvxHyperlinkDocTp, TimeoutHdl_Impl ) ); } diff --git a/cui/source/dialogs/hlinettp.cxx b/cui/source/dialogs/hlinettp.cxx index 4109846bff4c..77e4cc1d2531 100644 --- a/cui/source/dialogs/hlinettp.cxx +++ b/cui/source/dialogs/hlinettp.cxx @@ -59,18 +59,18 @@ SvxHyperlinkInternetTp::SvxHyperlinkInternetTp ( Window *pParent, maRbtLinktypTelnet ( this, CUI_RES (RB_LINKTYP_TELNET) ), maFtTarget ( this, CUI_RES (FT_TARGET_HTML) ), maCbbTarget ( this, INET_PROT_HTTP ), + maBtBrowse ( this, CUI_RES (BTN_BROWSE) ), maFtLogin ( this, CUI_RES (FT_LOGIN) ), maEdLogin ( this, CUI_RES (ED_LOGIN) ), + maBtTarget ( this, CUI_RES (BTN_TARGET) ), maFtPassword ( this, CUI_RES (FT_PASSWD) ), maEdPassword ( this, CUI_RES (ED_PASSWD) ), maCbAnonymous ( this, CUI_RES (CBX_ANONYMOUS) ), - maBtBrowse ( this, CUI_RES (BTN_BROWSE) ), - maBtTarget ( this, CUI_RES (BTN_TARGET) ), - mbMarkWndOpen ( FALSE ) + mbMarkWndOpen ( sal_False ) { // Disable display of bitmap names. - maBtBrowse.EnableTextDisplay (FALSE); - maBtTarget.EnableTextDisplay (FALSE); + maBtBrowse.EnableTextDisplay (sal_False); + maBtTarget.EnableTextDisplay (sal_False); InitStdControls(); FreeResource(); @@ -99,12 +99,12 @@ SvxHyperlinkInternetTp::SvxHyperlinkInternetTp ( Window *pParent, /////////////////////////////////////// // set defaults maRbtLinktypInternet.Check (); - maFtLogin.Show( FALSE ); - maFtPassword.Show( FALSE ); - maEdLogin.Show( FALSE ); - maEdPassword.Show( FALSE ); - maCbAnonymous.Show( FALSE ); - maBtTarget.Enable( FALSE ); + maFtLogin.Show( sal_False ); + maFtPassword.Show( sal_False ); + maEdLogin.Show( sal_False ); + maEdPassword.Show( sal_False ); + maCbAnonymous.Show( sal_False ); + maBtTarget.Enable( sal_False ); maBtBrowse.Enable( maStrStdDocURL != aEmptyStr ); /////////////////////////////////////// @@ -120,6 +120,13 @@ SvxHyperlinkInternetTp::SvxHyperlinkInternetTp ( Window *pParent, maCbbTarget.SetLoseFocusHdl ( LINK ( this, SvxHyperlinkInternetTp, LostFocusTargetHdl_Impl ) ); maCbbTarget.SetModifyHdl ( LINK ( this, SvxHyperlinkInternetTp, ModifiedTargetHdl_Impl ) ); maTimer.SetTimeoutHdl ( LINK ( this, SvxHyperlinkInternetTp, TimeoutHdl_Impl ) ); + + maFtTarget.SetAccessibleRelationMemberOf( &maGrpLinkTyp ); + maCbbTarget.SetAccessibleRelationMemberOf( &maGrpLinkTyp ); + maBtTarget.SetAccessibleRelationMemberOf( &maGrpLinkTyp ); + maBtTarget.SetAccessibleRelationLabeledBy( &maFtTarget ); + maBtBrowse.SetAccessibleRelationMemberOf( &maGrpLinkTyp ); + maBtBrowse.SetAccessibleRelationLabeledBy( &maFtTarget ); } SvxHyperlinkInternetTp::~SvxHyperlinkInternetTp () @@ -182,7 +189,7 @@ void SvxHyperlinkInternetTp::setFTPUser(const String& rUser, const String& rPass maFtPassword.Enable (); maEdLogin.Enable (); maEdPassword.Enable (); - maCbAnonymous.Check(FALSE); + maCbAnonymous.Check(sal_False); } /************************************************************************* @@ -300,11 +307,11 @@ void SvxHyperlinkInternetTp::SetScheme( const String& aScheme ) { //if aScheme is empty or unknown the default beaviour is like it where HTTP - BOOL bFTP = aScheme.SearchAscii( sFTPScheme ) == 0; - BOOL bTelnet = FALSE; + sal_Bool bFTP = aScheme.SearchAscii( sFTPScheme ) == 0; + sal_Bool bTelnet = sal_False; if( !bFTP ) bTelnet = aScheme.SearchAscii( sTelnetScheme ) == 0; - BOOL bInternet = !(bFTP || bTelnet); + sal_Bool bInternet = !(bFTP || bTelnet); //update protocol button selection: maRbtLinktypFTP.Check(bFTP); @@ -453,11 +460,11 @@ IMPL_LINK ( SvxHyperlinkInternetTp, ClickBrowseHdl_Impl, void *, EMPTYARG ) SfxStringItem aName( SID_FILE_NAME, maStrStdDocURL ); SfxStringItem aRefererItem( SID_REFERER, UniString::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "private:user" ) ) ); - SfxBoolItem aNewView( SID_OPEN_NEW_VIEW, TRUE ); - SfxBoolItem aSilent( SID_SILENT, TRUE ); - SfxBoolItem aReadOnly( SID_DOC_READONLY, TRUE ); + SfxBoolItem aNewView( SID_OPEN_NEW_VIEW, sal_True ); + SfxBoolItem aSilent( SID_SILENT, sal_True ); + SfxBoolItem aReadOnly( SID_DOC_READONLY, sal_True ); - SfxBoolItem aBrowse( SID_BROWSE, TRUE ); + SfxBoolItem aBrowse( SID_BROWSE, sal_True ); const SfxPoolItem *ppItems[] = { &aName, &aNewView, &aSilent, &aReadOnly, &aRefererItem, &aBrowse, NULL }; (((SvxHpLinkDlg*)mpDialog)->GetBindings())->Execute( SID_OPENDOC, ppItems, 0, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD ); @@ -523,7 +530,7 @@ void SvxHyperlinkInternetTp::SetMarkStr ( String& aStrMark ) |* |************************************************************************/ -void SvxHyperlinkInternetTp::SetOnlineMode( BOOL /*bEnable*/ ) +void SvxHyperlinkInternetTp::SetOnlineMode( sal_Bool /*bEnable*/ ) { // State of target-button in subject to the current url-string // ( Can't display any targets in an document, if there is no @@ -534,9 +541,9 @@ void SvxHyperlinkInternetTp::SetOnlineMode( BOOL /*bEnable*/ ) if( aStrCurrentTarget == aEmptyStr || aStrCurrentTarget.EqualsIgnoreCaseAscii( sHTTPScheme ) || aStrCurrentTarget.EqualsIgnoreCaseAscii( sHTTPSScheme ) ) - maBtTarget.Enable( FALSE ); + maBtTarget.Enable( sal_False ); else - maBtTarget.Enable( TRUE ); + maBtTarget.Enable( sal_True ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/dialogs/hlmailtp.cxx b/cui/source/dialogs/hlmailtp.cxx index 0a2f7af154d5..bc1ab0b41c61 100644 --- a/cui/source/dialogs/hlmailtp.cxx +++ b/cui/source/dialogs/hlmailtp.cxx @@ -61,7 +61,7 @@ SvxHyperlinkMailTp::SvxHyperlinkMailTp ( Window *pParent, const SfxItemSet& rIte maEdSubject ( this, CUI_RES (ED_SUBJECT) ) { // Disable display of bitmap names. - maBtAdrBook.EnableTextDisplay (FALSE); + maBtAdrBook.EnableTextDisplay (sal_False); InitStdControls(); FreeResource(); @@ -86,6 +86,9 @@ SvxHyperlinkMailTp::SvxHyperlinkMailTp ( Window *pParent, const SfxItemSet& rIte if ( !SvtModuleOptions().IsModuleInstalled( SvtModuleOptions::E_SDATABASE ) ) maBtAdrBook.Hide(); + + maBtAdrBook.SetAccessibleRelationMemberOf( &maGrpMailNews ); + maBtAdrBook.SetAccessibleRelationLabeledBy( &maFtReceiver ); } SvxHyperlinkMailTp::~SvxHyperlinkMailTp () @@ -209,7 +212,7 @@ void SvxHyperlinkMailTp::SetScheme( const String& aScheme ) //if aScheme is empty or unknown the default beaviour is like it where MAIL const sal_Char sNewsScheme[] = INET_NEWS_SCHEME; - BOOL bMail = aScheme.SearchAscii( sNewsScheme ) != 0; + sal_Bool bMail = aScheme.SearchAscii( sNewsScheme ) != 0; //update protocol button selection: maRbtMail.Check(bMail); diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx index a19309b4a7d7..e2f666a1e7cb 100644 --- a/cui/source/dialogs/hlmarkwn.cxx +++ b/cui/source/dialogs/hlmarkwn.cxx @@ -60,9 +60,9 @@ using namespace ::rtl; struct TargetData { OUString aUStrLinkname; - BOOL bIsTarget; + sal_Bool bIsTarget; - TargetData ( OUString aUStrLName, BOOL bTarget ) + TargetData ( OUString aUStrLName, sal_Bool bTarget ) : bIsTarget ( bTarget ) { if ( bIsTarget ) @@ -130,8 +130,8 @@ SvxHlinkDlgMarkWnd::SvxHlinkDlgMarkWnd( SvxHyperlinkTabPageBase *pParent ) maBtApply( this, CUI_RES (BT_APPLY) ), maBtClose( this, CUI_RES (BT_CLOSE) ), maLbTree ( this, CUI_RES (TLB_MARK) ), - mbUserMoved ( FALSE ), - mbFirst ( TRUE ), + mbUserMoved ( sal_False ), + mbFirst ( sal_True ), mpParent ( pParent ), mnError ( LERR_NOERROR ) { @@ -142,9 +142,12 @@ SvxHlinkDlgMarkWnd::SvxHlinkDlgMarkWnd( SvxHyperlinkTabPageBase *pParent ) maLbTree.SetDoubleClickHdl ( LINK ( this, SvxHlinkDlgMarkWnd, ClickApplyHdl_Impl ) ); // Tree-ListBox mit Linien versehen - maLbTree.SetWindowBits( WinBits( WB_TABSTOP | WB_BORDER | WB_HASLINES | + maLbTree.SetStyle( maLbTree.GetStyle() | WB_TABSTOP | WB_BORDER | WB_HASLINES | WB_HASBUTTONS | //WB_HASLINESATROOT | - WB_HSCROLL | WB_HASBUTTONSATROOT ) ); + WB_HSCROLL | WB_HASBUTTONSATROOT ); + + maLbTree.SetAccessibleName(String(CUI_RES(STR_MARK_TREE))); + } SvxHlinkDlgMarkWnd::~SvxHlinkDlgMarkWnd() @@ -158,9 +161,9 @@ SvxHlinkDlgMarkWnd::~SvxHlinkDlgMarkWnd() |* |************************************************************************/ -USHORT SvxHlinkDlgMarkWnd::SetError( USHORT nError) +sal_uInt16 SvxHlinkDlgMarkWnd::SetError( sal_uInt16 nError) { - USHORT nOldError = mnError; + sal_uInt16 nOldError = mnError; mnError = nError; if( mnError != LERR_NOERROR ) @@ -177,11 +180,11 @@ USHORT SvxHlinkDlgMarkWnd::SetError( USHORT nError) |* |************************************************************************/ -BOOL SvxHlinkDlgMarkWnd::MoveTo ( Point aNewPos ) +sal_Bool SvxHlinkDlgMarkWnd::MoveTo ( Point aNewPos ) { if ( !mbUserMoved ) { - BOOL bOldStatus = mbUserMoved; + sal_Bool bOldStatus = mbUserMoved; SetPosPixel ( aNewPos ); mbUserMoved = bOldStatus; } @@ -194,12 +197,12 @@ void SvxHlinkDlgMarkWnd::Move () Window::Move(); if ( IsReallyVisible() ) - mbUserMoved = TRUE; + mbUserMoved = sal_True; } -BOOL SvxHlinkDlgMarkWnd::ConnectToDialog( BOOL bDoit ) +sal_Bool SvxHlinkDlgMarkWnd::ConnectToDialog( sal_Bool bDoit ) { - BOOL bOldStatus = mbUserMoved; + sal_Bool bOldStatus = mbUserMoved; mbUserMoved = !bDoit; @@ -246,7 +249,7 @@ void SvxHlinkDlgMarkWnd::RefreshTree ( String aStrURL ) |* |************************************************************************/ -BOOL SvxHlinkDlgMarkWnd::RefreshFromDoc( OUString aURL ) +sal_Bool SvxHlinkDlgMarkWnd::RefreshFromDoc( OUString aURL ) { mnError = LERR_NOERROR; @@ -269,7 +272,7 @@ BOOL SvxHlinkDlgMarkWnd::RefreshFromDoc( OUString aURL ) { uno::Sequence< beans::PropertyValue > aArg(1); aArg.getArray()[0].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( "Hidden" )); - aArg.getArray()[0].Value <<= (sal_Bool) TRUE; + aArg.getArray()[0].Value <<= (sal_Bool) sal_True; xComp = xLoader->loadComponentFromURL( aURL, OUString(RTL_CONSTASCII_USTRINGPARAM( "_blank" )), 0, aArg ); } catch( const io::IOException& ) @@ -322,19 +325,19 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink { int nEntries=0; const uno::Sequence< OUString > aNames( xLinks->getElementNames() ); - const ULONG nLinks = aNames.getLength(); + const sal_uLong nLinks = aNames.getLength(); const OUString* pNames = aNames.getConstArray(); Color aMaskColor( COL_LIGHTMAGENTA ); const OUString aProp_LinkDisplayName( RTL_CONSTASCII_USTRINGPARAM( "LinkDisplayName" ) ); const OUString aProp_LinkTarget( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.document.LinkTarget" ) ); const OUString aProp_LinkDisplayBitmap( RTL_CONSTASCII_USTRINGPARAM( "LinkDisplayBitmap" ) ); - for( ULONG i = 0; i < nLinks; i++ ) + for( sal_uLong i = 0; i < nLinks; i++ ) { uno::Any aAny; OUString aLink( *pNames++ ); - BOOL bError = FALSE; + sal_Bool bError = sal_False; try { aAny = xLinks->getByName( aLink ); @@ -343,7 +346,7 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink { // if the name of the target was invalid (like empty headings) // no object can be provided - bError = TRUE; + bError = sal_True; } if(bError) continue; @@ -362,7 +365,7 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink // is it a target ? uno::Reference< lang::XServiceInfo > xSI( xTarget, uno::UNO_QUERY ); - BOOL bIsTarget = xSI->supportsService( aProp_LinkTarget ); + sal_Bool bIsTarget = xSI->supportsService( aProp_LinkTarget ); // create userdata TargetData *pData = new TargetData ( aLink, bIsTarget ); @@ -380,7 +383,7 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink pEntry = maLbTree.InsertEntry ( aStrDisplayname, aBmp, aBmp, pParentEntry, - FALSE, LIST_APPEND, + sal_False, LIST_APPEND, (void*)pData ); nEntries++; } @@ -389,7 +392,7 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink // insert Displayname into treelist without bitmaps pEntry = maLbTree.InsertEntry ( aStrDisplayname, pParentEntry, - FALSE, LIST_APPEND, + sal_False, LIST_APPEND, (void*)pData ); nEntries++; } @@ -399,7 +402,7 @@ int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLink // insert Displayname into treelist without bitmaps pEntry = maLbTree.InsertEntry ( aStrDisplayname, pParentEntry, - FALSE, LIST_APPEND, + sal_False, LIST_APPEND, (void*)pData ); nEntries++; } @@ -446,14 +449,14 @@ void SvxHlinkDlgMarkWnd::ClearTree() SvLBoxEntry* SvxHlinkDlgMarkWnd::FindEntry ( String aStrName ) { - BOOL bFound=FALSE; + sal_Bool bFound=sal_False; SvLBoxEntry* pEntry = maLbTree.First(); while ( pEntry && !bFound ) { TargetData* pUserData = ( TargetData * ) pEntry->GetUserData (); if ( aStrName == String( pUserData->aUStrLinkname ) ) - bFound = TRUE; + bFound = sal_True; else pEntry = maLbTree.Next( pEntry ); } diff --git a/cui/source/dialogs/hlmarkwn.hrc b/cui/source/dialogs/hlmarkwn.hrc index f9d03f14e91c..39c7b2d53d18 100644 --- a/cui/source/dialogs/hlmarkwn.hrc +++ b/cui/source/dialogs/hlmarkwn.hrc @@ -28,4 +28,7 @@ #define BT_APPLY 1 #define BT_CLOSE 2 #define TLB_MARK 3 +// IAccessibility2 implementation 2009. ------ +#define STR_MARK_TREE 5000 +// ------ IAccessibility2 implementation 2009. diff --git a/cui/source/dialogs/hlmarkwn.src b/cui/source/dialogs/hlmarkwn.src index ac0bba11e346..450afc36758f 100644 --- a/cui/source/dialogs/hlmarkwn.src +++ b/cui/source/dialogs/hlmarkwn.src @@ -76,3 +76,9 @@ String RID_SVXSTR_HYPDLG_ERR_LERR_DOCNOTOPEN { Text [ en-US ] = "Couldn't open the document." ; }; + +String STR_MARK_TREE +{ + Text [ en-US ] = "Mark Tree" ; +}; + diff --git a/cui/source/dialogs/hltpbase.cxx b/cui/source/dialogs/hltpbase.cxx index 0b4abd3a03f9..4088f56ec7a4 100644 --- a/cui/source/dialogs/hltpbase.cxx +++ b/cui/source/dialogs/hltpbase.cxx @@ -96,7 +96,7 @@ SvxFramesComboBox::~SvxFramesComboBox () |* |************************************************************************/ -SvxHyperURLBox::SvxHyperURLBox( Window* pParent, INetProtocol eSmart, BOOL bAddresses ) +SvxHyperURLBox::SvxHyperURLBox( Window* pParent, INetProtocol eSmart, sal_Bool bAddresses ) : SvtURLBox ( pParent, eSmart ), DropTargetHelper ( this ), mbAccessAddress (bAddresses) @@ -168,7 +168,7 @@ SvxHyperlinkTabPageBase::SvxHyperlinkTabPageBase ( Window *pParent, mpBtScript ( NULL ), mbIsCloseDisabled ( sal_False ), mpDialog ( pParent ), - mbStdControlsInit ( FALSE ), + mbStdControlsInit ( sal_False ), aEmptyStr() { // create bookmark-window @@ -227,10 +227,13 @@ void SvxHyperlinkTabPageBase::InitStdControls () mpBtScript = new ImageButton ( this, ResId (BTN_SCRIPT, *m_pResMgr) ); mpBtScript->SetClickHdl ( LINK ( this, SvxHyperlinkTabPageBase, ClickScriptHdl_Impl ) ); - mpBtScript->EnableTextDisplay (FALSE); + mpBtScript->EnableTextDisplay (sal_False); + + mpBtScript->SetAccessibleRelationMemberOf( mpGrpMore ); + mpBtScript->SetAccessibleRelationLabeledBy( mpFtForm ); } - mbStdControlsInit = TRUE; + mbStdControlsInit = sal_True; } /************************************************************************* @@ -239,12 +242,12 @@ void SvxHyperlinkTabPageBase::InitStdControls () |* \************************************************************************/ -BOOL SvxHyperlinkTabPageBase::MoveToExtraWnd( Point aNewPos, BOOL bDisConnectDlg ) +sal_Bool SvxHyperlinkTabPageBase::MoveToExtraWnd( Point aNewPos, sal_Bool bDisConnectDlg ) { - BOOL bReturn = mpMarkWnd->MoveTo ( aNewPos ); + sal_Bool bReturn = mpMarkWnd->MoveTo ( aNewPos ); if( bDisConnectDlg ) - mpMarkWnd->ConnectToDialog( FALSE ); + mpMarkWnd->ConnectToDialog( sal_False ); return ( !bReturn && IsMarkWndVisible() ); } @@ -277,7 +280,7 @@ void SvxHyperlinkTabPageBase::ShowMarkWnd () { // Pos Extrawindow anywhere MoveToExtraWnd( Point(10,10) ); // very unlikely - mpMarkWnd->ConnectToDialog( FALSE ); + mpMarkWnd->ConnectToDialog( sal_False ); } else { @@ -304,7 +307,7 @@ void SvxHyperlinkTabPageBase::ShowMarkWnd () void SvxHyperlinkTabPageBase::FillStandardDlgFields ( SvxHyperlinkItem* pHyperlinkItem ) { // Frame - USHORT nPos = mpCbbFrame->GetEntryPos ( pHyperlinkItem->GetTargetFrame() ); + sal_uInt16 nPos = mpCbbFrame->GetEntryPos ( pHyperlinkItem->GetTargetFrame() ); if ( nPos != LISTBOX_ENTRY_NOTFOUND) mpCbbFrame->SetText ( pHyperlinkItem->GetTargetFrame() ); @@ -356,10 +359,10 @@ void SvxHyperlinkTabPageBase::DoApply () |* \************************************************************************/ -BOOL SvxHyperlinkTabPageBase::AskApply () +sal_Bool SvxHyperlinkTabPageBase::AskApply () { // default-implementation - return TRUE; + return sal_True; } /************************************************************************* @@ -380,7 +383,7 @@ void SvxHyperlinkTabPageBase::SetMarkStr ( String& /*aStrMark*/ ) |* \************************************************************************/ -void SvxHyperlinkTabPageBase::SetOnlineMode( BOOL /*bEnable*/ ) +void SvxHyperlinkTabPageBase::SetOnlineMode( sal_Bool /*bEnable*/ ) { // default-implemtation : do nothing } @@ -402,7 +405,7 @@ void SvxHyperlinkTabPageBase::SetInitFocus() |* |************************************************************************/ -BOOL SvxHyperlinkTabPageBase::IsHTMLDoc() const +sal_Bool SvxHyperlinkTabPageBase::IsHTMLDoc() const { return ((SvxHpLinkDlg*)mpDialog)->IsHTMLDoc(); } @@ -447,9 +450,9 @@ IMPL_LINK ( SvxHyperlinkTabPageBase, ClickScriptHdl_Impl, void *, EMPTYARG ) because if no JAVA is installed an error box occurs and then it is possible to close the HyperLinkDlg before its child (MacroAssignDlg) -> GPF */ - BOOL bIsInputEnabled = GetParent()->IsInputEnabled(); + sal_Bool bIsInputEnabled = GetParent()->IsInputEnabled(); if ( bIsInputEnabled ) - GetParent()->EnableInput( FALSE ); + GetParent()->EnableInput( sal_False ); // <-- SfxMacroAssignDlg aDlg( this, mxDocumentFrame, *pItemSet ); @@ -467,7 +470,7 @@ IMPL_LINK ( SvxHyperlinkTabPageBase, ClickScriptHdl_Impl, void *, EMPTYARG ) SFX_EVENT_MOUSEOUT_OBJECT); if ( bIsInputEnabled ) - GetParent()->EnableInput( TRUE ); + GetParent()->EnableInput( sal_True ); // <-- // execute dlg DisableClose( sal_True ); @@ -477,7 +480,7 @@ IMPL_LINK ( SvxHyperlinkTabPageBase, ClickScriptHdl_Impl, void *, EMPTYARG ) { const SfxItemSet* pOutSet = aDlg.GetOutputItemSet(); const SfxPoolItem* pItem; - if( SFX_ITEM_SET == pOutSet->GetItemState( SID_ATTR_MACROITEM, FALSE, &pItem )) + if( SFX_ITEM_SET == pOutSet->GetItemState( SID_ATTR_MACROITEM, sal_False, &pItem )) { pHyperlinkItem->SetMacroTable( ((SvxMacroItem*)pItem)->GetMacroTable() ); } @@ -494,7 +497,7 @@ IMPL_LINK ( SvxHyperlinkTabPageBase, ClickScriptHdl_Impl, void *, EMPTYARG ) |* |************************************************************************/ -USHORT SvxHyperlinkTabPageBase::GetMacroEvents() +sal_uInt16 SvxHyperlinkTabPageBase::GetMacroEvents() { SvxHyperlinkItem *pHyperlinkItem = (SvxHyperlinkItem *) GetItemSet().GetItem (SID_HYPERLINK_GETLINK); @@ -516,9 +519,9 @@ SvxMacroTableDtor* SvxHyperlinkTabPageBase::GetMacroTable() |* |************************************************************************/ -BOOL SvxHyperlinkTabPageBase::FileExists( const INetURLObject& rURL ) +sal_Bool SvxHyperlinkTabPageBase::FileExists( const INetURLObject& rURL ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; if( rURL.GetFull().getLength() > 0 ) { @@ -597,7 +600,7 @@ void SvxHyperlinkTabPageBase::GetDataFromCommonFields( String& aStrName, aStrFrame = mpCbbFrame->GetText(); eMode = (SvxLinkInsertMode) (mpLbForm->GetSelectEntryPos()+1); if( IsHTMLDoc() ) - eMode = (SvxLinkInsertMode) ( UINT16(eMode) | HLINK_HTMLMODE ); + eMode = (SvxLinkInsertMode) ( sal_uInt16(eMode) | HLINK_HTMLMODE ); } /************************************************************************* @@ -634,7 +637,7 @@ void SvxHyperlinkTabPageBase::Reset( const SfxItemSet& rItemSet) |* |************************************************************************/ -BOOL SvxHyperlinkTabPageBase::FillItemSet( SfxItemSet& rOut) +sal_Bool SvxHyperlinkTabPageBase::FillItemSet( SfxItemSet& rOut) { String aStrURL, aStrName, aStrIntName, aStrFrame; SvxLinkInsertMode eMode; @@ -643,14 +646,14 @@ BOOL SvxHyperlinkTabPageBase::FillItemSet( SfxItemSet& rOut) if ( !aStrName.Len() ) //automatically create a visible name if the link is created without name aStrName = CreateUiNameFromURL(aStrURL); - USHORT nEvents = GetMacroEvents(); + sal_uInt16 nEvents = GetMacroEvents(); SvxMacroTableDtor* pTable = GetMacroTable(); SvxHyperlinkItem aItem( SID_HYPERLINK_SETLINK, aStrName, aStrURL, aStrFrame, aStrIntName, eMode, nEvents, pTable ); rOut.Put (aItem); - return TRUE; + return sal_True; } String SvxHyperlinkTabPageBase::CreateUiNameFromURL( const String& aStrURL ) @@ -717,7 +720,7 @@ int SvxHyperlinkTabPageBase::DeactivatePage( SfxItemSet* _pSet) GetCurentItemData ( aStrURL, aStrName, aStrIntName, aStrFrame, eMode); - USHORT nEvents = GetMacroEvents(); + sal_uInt16 nEvents = GetMacroEvents(); SvxMacroTableDtor* pTable = GetMacroTable(); if( _pSet ) @@ -730,12 +733,12 @@ int SvxHyperlinkTabPageBase::DeactivatePage( SfxItemSet* _pSet) return( LEAVE_PAGE ); } -BOOL SvxHyperlinkTabPageBase::ShouldOpenMarkWnd() +sal_Bool SvxHyperlinkTabPageBase::ShouldOpenMarkWnd() { - return FALSE; + return sal_False; } -void SvxHyperlinkTabPageBase::SetMarkWndShouldOpen(BOOL) +void SvxHyperlinkTabPageBase::SetMarkWndShouldOpen(sal_Bool) { } diff --git a/cui/source/dialogs/hyperdlg.src b/cui/source/dialogs/hyperdlg.src index 734cc181f9b3..66c9be97525d 100644 --- a/cui/source/dialogs/hyperdlg.src +++ b/cui/source/dialogs/hyperdlg.src @@ -56,18 +56,21 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; RadioButton RB_LINKTYP_INTERNET { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_INTERNET:RB_LINKTYP_INTERNET"; Pos = MAP_APPFONT( COL_2, 13 ); Size = MAP_APPFONT( 57, 10 ); Text [ en-US ] = "~Web"; }; RadioButton RB_LINKTYP_FTP { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_INTERNET:RB_LINKTYP_FTP"; Pos = MAP_APPFONT( 114 + COL_DIFF, 13 ); Size = MAP_APPFONT( 56 - COL_DIFF, 10 ); Text [ en-US ] = "~FTP"; }; RadioButton RB_LINKTYP_TELNET { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_INTERNET:RB_LINKTYP_TELNET"; Pos = MAP_APPFONT( 173, 13 ); Size = MAP_APPFONT( 56, 10 ); Text [ en-US ] = "~Telnet"; @@ -86,6 +89,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; Edit ED_LOGIN { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_INTERNET:ED_LOGIN"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 42 ) ; Size = MAP_APPFONT ( 80 - COL_DIFF , 12 ) ; @@ -98,6 +102,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; Edit ED_PASSWD { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_INTERNET:ED_PASSWD"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 59 ) ; Size = MAP_APPFONT ( 80 - COL_DIFF , 12 ) ; @@ -105,6 +110,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; CheckBox CBX_ANONYMOUS { + HelpID = "cui:CheckBox:RID_SVXPAGE_HYPERLINK_INTERNET:CBX_ANONYMOUS"; Pos = MAP_APPFONT ( COL_2 , 75 ) ; Size = MAP_APPFONT ( 89 - COL_DIFF , 10 ) ; TabStop = TRUE ; @@ -112,6 +118,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; ImageButton BTN_BROWSE { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_INTERNET:BTN_BROWSE"; Pos = MAP_APPFONT ( 235, 24 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -127,6 +134,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET ImageButton BTN_TARGET { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_INTERNET:BTN_TARGET"; Pos = MAP_APPFONT ( 235, 40+2 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -154,6 +162,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; ComboBox CB_FRAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_HYPERLINK_INTERNET:CB_FRAME"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 104 ) ; Size = MAP_APPFONT ( 66 - COL_DIFF , 60 ) ; @@ -169,6 +178,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; ListBox LB_FORM { + HelpID = "cui:ListBox:RID_SVXPAGE_HYPERLINK_INTERNET:LB_FORM"; Border = TRUE ; Pos = MAP_APPFONT ( 160 , 104 ) ; Size = MAP_APPFONT ( 70 , 60 ) ; @@ -190,6 +200,7 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; Edit ED_INDICATION { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_INTERNET:ED_INDICATION"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 122 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; @@ -202,12 +213,14 @@ TabPage RID_SVXPAGE_HYPERLINK_INTERNET }; Edit ED_TEXT { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_INTERNET:ED_TEXT"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 139 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; }; ImageButton BTN_SCRIPT { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_INTERNET:BTN_SCRIPT"; Pos = MAP_APPFONT ( 235, 103-1 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -245,12 +258,14 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; RadioButton RB_LINKTYP_MAIL { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_MAIL:RB_LINKTYP_MAIL"; Pos = MAP_APPFONT( COL_2, 13 ); Size = MAP_APPFONT( 56 - COL_DIFF, 10 ); Text [ en-US ] = "~E-mail"; }; RadioButton RB_LINKTYP_NEWS { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_MAIL:RB_LINKTYP_NEWS"; Pos = MAP_APPFONT( 113, 13 ); Size = MAP_APPFONT( 56, 10 ); Text [ en-US ] = "~News"; @@ -269,12 +284,14 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; Edit ED_SUBJECT { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_MAIL:ED_SUBJECT"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 42 ) ; Size = MAP_APPFONT ( 176 - COL_DIFF , 12 ) ; }; ImageButton BTN_ADRESSBOOK { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_MAIL:BTN_ADRESSBOOK"; Pos = MAP_APPFONT ( 235, 24 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -303,6 +320,7 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; ComboBox CB_FRAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_HYPERLINK_MAIL:CB_FRAME"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 104 ) ; Size = MAP_APPFONT ( 66 - COL_DIFF , 60 ) ; @@ -318,6 +336,7 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; ListBox LB_FORM { + HelpID = "cui:ListBox:RID_SVXPAGE_HYPERLINK_MAIL:LB_FORM"; Border = TRUE ; Pos = MAP_APPFONT ( 160 , 104 ) ; Size = MAP_APPFONT ( 70 , 60 ) ; @@ -339,6 +358,7 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; Edit ED_INDICATION { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_MAIL:ED_INDICATION"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 122 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; @@ -351,12 +371,14 @@ TabPage RID_SVXPAGE_HYPERLINK_MAIL }; Edit ED_TEXT { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_MAIL:ED_TEXT"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 139 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; }; ImageButton BTN_SCRIPT { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_MAIL:BTN_SCRIPT"; Pos = MAP_APPFONT ( 235, 103-1 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -399,6 +421,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; ImageButton BTN_FILEOPEN { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_DOCUMENT:BTN_FILEOPEN"; Pos = MAP_APPFONT ( 235, 14 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -424,6 +447,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; Edit ED_TARGET_DOC { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_DOCUMENT:ED_TARGET_DOC"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 52 ) ; Size = MAP_APPFONT ( 176 - COL_DIFF , 12 ) ; @@ -442,6 +466,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; ImageButton BTN_BROWSE { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_DOCUMENT:BTN_BROWSE"; Pos = MAP_APPFONT ( 235, 51 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -468,6 +493,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; ComboBox CB_FRAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_HYPERLINK_DOCUMENT:CB_FRAME"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 104 ) ; Size = MAP_APPFONT ( 66 - COL_DIFF , 60 ) ; @@ -483,6 +509,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; ListBox LB_FORM { + HelpID = "cui:ListBox:RID_SVXPAGE_HYPERLINK_DOCUMENT:LB_FORM"; Border = TRUE ; Pos = MAP_APPFONT ( 160 , 104 ) ; Size = MAP_APPFONT ( 70 , 60 ) ; @@ -504,6 +531,7 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; Edit ED_INDICATION { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_DOCUMENT:ED_INDICATION"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 122 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; @@ -516,12 +544,14 @@ TabPage RID_SVXPAGE_HYPERLINK_DOCUMENT }; Edit ED_TEXT { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_DOCUMENT:ED_TEXT"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 139 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; }; ImageButton BTN_SCRIPT { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_DOCUMENT:BTN_SCRIPT"; Pos = MAP_APPFONT ( 235, 103-1 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -558,12 +588,14 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; RadioButton RB_EDITNOW { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:RB_EDITNOW"; Pos = MAP_APPFONT( COL_2, 13 ); Size = MAP_APPFONT( 85 - COL_DIFF, 10 ); Text [ en-US ] = "Edit ~now"; }; RadioButton RB_EDITLATER { + HelpID = "cui:RadioButton:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:RB_EDITLATER"; Pos = MAP_APPFONT( 142, 13 ); Size = MAP_APPFONT( 84, 10 ); Text [ en-US ] = "Edit ~later"; @@ -576,6 +608,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; Edit ED_PATH_NEWDOC { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:ED_PATH_NEWDOC"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 25 ) ; Size = MAP_APPFONT ( 176 - COL_DIFF , 12 ) ; @@ -588,6 +621,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; ListBox LB_DOCUMENT_TYPES { + HelpID = "cui:ListBox:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:LB_DOCUMENT_TYPES"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 42 ) ; Size = MAP_APPFONT ( 176 - COL_DIFF , 40 ) ; @@ -596,6 +630,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; ImageButton BTN_CREATE { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:BTN_CREATE"; Pos = MAP_APPFONT ( 235, 24 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -623,6 +658,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; ComboBox CB_FRAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:CB_FRAME"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 104 ) ; Size = MAP_APPFONT ( 66 - COL_DIFF , 60 ) ; @@ -638,6 +674,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; ListBox LB_FORM { + HelpID = "cui:ListBox:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:LB_FORM"; Border = TRUE ; Pos = MAP_APPFONT ( 160 , 104 ) ; Size = MAP_APPFONT ( 70 , 60 ) ; @@ -659,6 +696,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; Edit ED_INDICATION { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:ED_INDICATION"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 122 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; @@ -671,12 +709,14 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT }; Edit ED_TEXT { + HelpID = "cui:Edit:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:ED_TEXT"; Border = TRUE ; Pos = MAP_APPFONT ( COL_2 , 139 ) ; Size = MAP_APPFONT ( 194 - COL_DIFF , 12 ) ; }; ImageButton BTN_SCRIPT { + HelpID = "cui:ImageButton:RID_SVXPAGE_HYPERLINK_NEWDOCUMENT:BTN_SCRIPT"; Pos = MAP_APPFONT ( 235, 103-1 ) ; Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_HEIGHT, HYPERDLG_IMGBUTTON_HEIGHT ); TabStop = TRUE ; @@ -697,7 +737,7 @@ TabPage RID_SVXPAGE_HYPERLINK_NEWDOCUMENT *************************************************************************/ ModalDialog RID_SVXDLG_NEWHYPERLINK { - HelpID = SID_HYPERLINK_DIALOG; + HelpID = CMD_SID_HYPERLINK_DIALOG; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 325 , 185 ) ; diff --git a/cui/source/dialogs/hyphen.hrc b/cui/source/dialogs/hyphen.hrc index f76e2aa75770..f76e2aa75770 100755..100644 --- a/cui/source/dialogs/hyphen.hrc +++ b/cui/source/dialogs/hyphen.hrc diff --git a/cui/source/dialogs/hyphen.src b/cui/source/dialogs/hyphen.src index 06547352b35d..f8bf26202bfa 100755..100644 --- a/cui/source/dialogs/hyphen.src +++ b/cui/source/dialogs/hyphen.src @@ -52,6 +52,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; Edit ED_WORD { + HelpID = "cui:Edit:RID_SVXDLG_HYPHENATE:ED_WORD"; BORDER = TRUE ; Pos = MAP_APPFONT ( 5 , 17 ) ; Size = MAP_APPFONT ( 132 , 12 ) ; @@ -60,6 +61,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; ImageButton BTN_LEFT { + HelpID = "cui:ImageButton:RID_SVXDLG_HYPHENATE:BTN_LEFT"; Pos = MAP_APPFONT ( 56 , 33 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TABSTOP = TRUE ; @@ -67,6 +69,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; ImageButton BTN_RIGHT { + HelpID = "cui:ImageButton:RID_SVXDLG_HYPHENATE:BTN_RIGHT"; Pos = MAP_APPFONT ( 75 , 33 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TABSTOP = TRUE ; @@ -82,6 +85,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; PushButton BTN_HYPH_CONTINUE { + HelpID = "cui:PushButton:RID_SVXDLG_HYPHENATE:BTN_HYPH_CONTINUE"; Pos = MAP_APPFONT ( 144 , 35 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Skip" ; @@ -89,6 +93,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; PushButton BTN_HYPH_DELETE { + HelpID = "cui:PushButton:RID_SVXDLG_HYPHENATE:BTN_HYPH_DELETE"; Pos = MAP_APPFONT ( 144 , 52 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Remove" ; @@ -107,6 +112,7 @@ ModalDialog RID_SVXDLG_HYPHENATE }; PushButton BTN_HYPH_ALL { + HelpID = "cui:PushButton:RID_SVXDLG_HYPHENATE:BTN_HYPH_ALL"; Pos = MAP_APPFONT ( 63 , 93 ) ; Size = MAP_APPFONT ( 74 , 14 ) ; Text [ en-US ] = "Hyphenate ~All" ; diff --git a/cui/source/dialogs/iconcdlg.cxx b/cui/source/dialogs/iconcdlg.cxx index ddeb7040bbdd..8adc57ddc7ba 100644 --- a/cui/source/dialogs/iconcdlg.cxx +++ b/cui/source/dialogs/iconcdlg.cxx @@ -55,7 +55,7 @@ int IconcDlgCmpUS_Impl( const void* p1, const void* p2 ) #endif #endif { - return *(USHORT*)p1 - *(USHORT*)p2; + return *(sal_uInt16*)p1 - *(sal_uInt16*)p2; } // some stuff for easier changes for SvtViewOptions @@ -93,9 +93,9 @@ IconChoicePage::IconChoicePage( Window *pParent, const ResId &rResId, const SfxItemSet &rAttrSet ) : TabPage ( pParent, rResId ), pSet ( &rAttrSet ), - bHasExchangeSupport ( FALSE ), + bHasExchangeSupport ( sal_False ), pDialog ( NULL ), - bStandard ( FALSE ) + bStandard ( sal_False ) { SetStyle ( GetStyle() | WB_DIALOGCONTROL | WB_HIDE ); } @@ -135,9 +135,9 @@ void IconChoicePage::FillUserData() // ----------------------------------------------------------------------- -BOOL IconChoicePage::IsReadOnly() const +sal_Bool IconChoicePage::IsReadOnly() const { - return FALSE; + return sal_False; } // ----------------------------------------------------------------------- @@ -149,56 +149,6 @@ sal_Bool IconChoicePage::QueryClose() /********************************************************************** | -| handling itemsets -| -\**********************************************************************/ - -const SfxPoolItem* IconChoicePage::GetItem( const SfxItemSet& rSet, - USHORT nSlot ) -{ - const SfxItemPool* pPool = rSet.GetPool(); - USHORT nWh = pPool->GetWhich( nSlot ); - const SfxPoolItem* pItem = 0; - rSet.GetItemState( nWh, TRUE, &pItem ); - - if ( !pItem && nWh != nSlot ) - pItem = &pPool->GetDefaultItem( nWh ); - - return pItem; -} - -// ----------------------------------------------------------------------- - -const SfxPoolItem* IconChoicePage::GetOldItem( const SfxItemSet& rSet, - USHORT nSlot ) -{ - const SfxItemSet& rOldSet = GetItemSet(); - USHORT nWh = GetWhich( nSlot ); - const SfxPoolItem* pItem = 0; - - if ( bStandard && rOldSet.GetParent() ) - pItem = GetItem( *rOldSet.GetParent(), nSlot ); - else if ( rSet.GetParent() && SFX_ITEM_DONTCARE == rSet.GetItemState( nWh ) ) - pItem = GetItem( *rSet.GetParent(), nSlot ); - else - pItem = GetItem( rOldSet, nSlot ); - - return pItem; -} - -// ----------------------------------------------------------------------- - -const SfxPoolItem* IconChoicePage::GetExchangeItem( const SfxItemSet& rSet, - USHORT nSlot ) -{ - if ( pDialog && !pDialog->IsInOK() && pDialog->GetExampleSet() ) - return GetItem( *pDialog->GetExampleSet(), nSlot ); - else - return GetOldItem( rSet, nSlot ); -} - -/********************************************************************** -| | window-methods | \**********************************************************************/ @@ -208,16 +158,16 @@ void IconChoicePage::ImplInitSettings() Window* pParent = GetParent(); if ( pParent->IsChildTransparentModeEnabled() && !IsControlBackground() ) { - EnableChildTransparentMode( TRUE ); + EnableChildTransparentMode( sal_True ); SetParentClipMode( PARENTCLIPMODE_NOCLIP ); - SetPaintTransparent( TRUE ); + SetPaintTransparent( sal_True ); SetBackground(); } else { - EnableChildTransparentMode( FALSE ); + EnableChildTransparentMode( sal_False ); SetParentClipMode( 0 ); - SetPaintTransparent( FALSE ); + SetPaintTransparent( sal_False ); if ( IsControlBackground() ) SetBackground( GetControlBackground() ); @@ -285,18 +235,18 @@ IconChoiceDialog::IconChoiceDialog ( Window* pParent, const ResId &rResId, pRanges ( NULL ), nResId ( rResId.GetId() ), - bHideResetBtn ( FALSE ), - bModal ( FALSE ), - bInOK ( FALSE ), - bModified ( FALSE ), - bItemsReset ( FALSE ) + bHideResetBtn ( sal_False ), + bModal ( sal_False ), + bInOK ( sal_False ), + bModified ( sal_False ), + bItemsReset ( sal_False ) { maIconCtrl.SetStyle (WB_3DLOOK | WB_ICON | WB_BORDER | WB_NOCOLUMNHEADER | WB_HIGHLIGHTFRAME | WB_NODRAGSELECTION | WB_TABSTOP | WB_CLIPCHILDREN ); SetCtrlPos ( meChoicePos ); maIconCtrl.SetClickHdl ( LINK ( this, IconChoiceDialog , ChosePageHdl_Impl ) ); maIconCtrl.Show(); - maIconCtrl.SetChoiceWithCursor ( TRUE ); + maIconCtrl.SetChoiceWithCursor ( sal_True ); maIconCtrl.SetSelectionMode( SINGLE_SELECTION ); maIconCtrl.SetHelpId( HID_ICCDIALOG_CHOICECTRL ); @@ -319,7 +269,7 @@ IconChoiceDialog::IconChoiceDialog ( Window* pParent, const ResId &rResId, aHelpBtn.Show(); aResetBtn.Show(); - SetPosSizeCtrls ( TRUE ); + SetPosSizeCtrls ( sal_True ); } // ----------------------------------------------------------------------- @@ -358,7 +308,7 @@ IconChoiceDialog ::~IconChoiceDialog () for ( ULONG i=0; i < maIconCtrl.GetEntryCount(); i++) { SvxIconChoiceCtrlEntry* pEntry = maIconCtrl.GetEntry ( i ); - USHORT* pUserData = (USHORT*) pEntry->GetUserData(); + sal_uInt16* pUserData = (sal_uInt16*) pEntry->GetUserData(); delete pUserData; } @@ -376,13 +326,13 @@ IconChoiceDialog ::~IconChoiceDialog () \**********************************************************************/ SvxIconChoiceCtrlEntry* IconChoiceDialog::AddTabPage( - USHORT nId, + sal_uInt16 nId, const String& rIconText, const Image& rChoiceIcon, CreatePage pCreateFunc /* != 0 */, GetPageRanges pRangesFunc /* darf 0 sein */, - BOOL bItemsOnDemand, - ULONG /*nPos*/ + sal_Bool bItemsOnDemand, + sal_uLong /*nPos*/ ) { IconChoicePageData* pData = new IconChoicePageData ( nId, pCreateFunc, @@ -393,7 +343,7 @@ SvxIconChoiceCtrlEntry* IconChoiceDialog::AddTabPage( pData->fnGetRanges = pRangesFunc; pData->bOnDemand = bItemsOnDemand; - USHORT *pId = new USHORT ( nId ); + sal_uInt16 *pId = new sal_uInt16 ( nId ); SvxIconChoiceCtrlEntry* pEntry = maIconCtrl.InsertEntry( rIconText, rChoiceIcon ); pEntry->SetUserData ( (void*) pId ); return pEntry; @@ -405,7 +355,7 @@ SvxIconChoiceCtrlEntry* IconChoiceDialog::AddTabPage( | \**********************************************************************/ -void IconChoiceDialog::RemoveTabPage( USHORT nId ) +void IconChoiceDialog::RemoveTabPage( sal_uInt16 nId ) { IconChoicePageData* pData = GetPageData ( nId ); @@ -442,17 +392,17 @@ void IconChoiceDialog::RemoveTabPage( USHORT nId ) } // remove Icon - BOOL bFound=FALSE; + bool bFound = FALSE; for ( ULONG i=0; i<maIconCtrl.GetEntryCount() && !bFound; i++) { SvxIconChoiceCtrlEntry* pEntry = maIconCtrl.GetEntry ( i ); - USHORT* pUserData = (USHORT*) pEntry->GetUserData(); + sal_uInt16* pUserData = (sal_uInt16*) pEntry->GetUserData(); if ( *pUserData == nId ) { delete pUserData; maIconCtrl.RemoveEntry ( pEntry ); - bFound = TRUE; + bFound = true; } } @@ -524,13 +474,6 @@ EIconChoicePos IconChoiceDialog::SetCtrlPos( const EIconChoicePos& rPos ) return eOldPos; } -void IconChoiceDialog::SetCtrlColor ( const Color& rColor ) -{ - Wallpaper aWallpaper ( rColor ); - maIconCtrl.SetBackground( aWallpaper ); - maIconCtrl.SetFontColorToBackground (); -} - /********************************************************************** | | Show / Hide page or button @@ -561,7 +504,7 @@ void IconChoiceDialog::RemoveResetButton() // ----------------------------------------------------------------------- -void IconChoiceDialog::ShowPage( USHORT nId ) +void IconChoiceDialog::ShowPage( sal_uInt16 nId ) { bool bInvalidate = GetCurPageId() != nId; SetCurPageId( nId ); @@ -591,7 +534,7 @@ void IconChoiceDialog::Resize() } } -void IconChoiceDialog::SetPosSizeCtrls ( BOOL bInit ) +void IconChoiceDialog::SetPosSizeCtrls ( sal_Bool bInit ) { const Point aCtrlOffset ( LogicToPixel( Point( CTRLS_OFFSET, CTRLS_OFFSET ), MAP_APPFONT ) ); Size aOutSize ( GetOutputSizePixel() ); @@ -692,7 +635,7 @@ void IconChoiceDialog::SetPosSizeCtrls ( BOOL bInit ) //////////////////////////////////////// // Buttons positionieren // - ULONG nXOffset=0; + sal_uLong nXOffset=0; if ( meChoicePos == PosRight ) nXOffset = aNewIconCtrlSize.Width()+(2*aCtrlOffset.X()); @@ -730,7 +673,7 @@ void IconChoiceDialog::SetPosSizeCtrls ( BOOL bInit ) Invalidate(); } -void IconChoiceDialog::SetPosSizePages ( USHORT nId ) +void IconChoiceDialog::SetPosSizePages ( sal_uInt16 nId ) { const Point aCtrlOffset ( LogicToPixel( Point( CTRLS_OFFSET, CTRLS_OFFSET ), MAP_APPFONT ) ); IconChoicePageData* pData = GetPageData ( nId ); @@ -786,13 +729,13 @@ void IconChoiceDialog::SetPosSizePages ( USHORT nId ) IMPL_LINK ( IconChoiceDialog , ChosePageHdl_Impl, void *, EMPTYARG ) { - ULONG nPos; + sal_uLong nPos; SvxIconChoiceCtrlEntry *pEntry = maIconCtrl.GetSelectedEntry ( nPos ); if ( !pEntry ) pEntry = maIconCtrl.GetCursor( ); - USHORT *pId = (USHORT*)pEntry->GetUserData (); + sal_uInt16 *pId = (sal_uInt16*)pEntry->GetUserData (); if( *pId != mnCurrentPageId ) { @@ -817,7 +760,7 @@ IMPL_LINK ( IconChoiceDialog , ChosePageHdl_Impl, void *, EMPTYARG ) IMPL_LINK( IconChoiceDialog, OkHdl, Button *, EMPTYARG ) { - bInOK = TRUE; + bInOK = sal_True; if ( OK_Impl() ) { @@ -910,7 +853,7 @@ void IconChoiceDialog::ActivatePageImpl () pData->pPage->Reset( *pSet ); } - pData->bRefresh = FALSE; + pData->bRefresh = sal_False; if ( pExampleSet ) pData->pPage->ActivatePage( *pExampleSet ); @@ -928,7 +871,7 @@ void IconChoiceDialog::ActivatePageImpl () // ----------------------------------------------------------------------- -BOOL IconChoiceDialog::DeActivatePageImpl () +sal_Bool IconChoiceDialog::DeActivatePageImpl () { IconChoicePageData *pData = GetPageData ( mnCurrentPageId ); @@ -980,17 +923,17 @@ BOOL IconChoiceDialog::DeActivatePageImpl () { IconChoicePageData* pObj = maPageList[ i ]; if ( pObj->pPage != pPage ) // eigene Page nicht mehr refreshen - pObj->bRefresh = TRUE; + pObj->bRefresh = sal_True; else - pObj->bRefresh = FALSE; + pObj->bRefresh = sal_False; } } } if ( nRet & IconChoicePage::LEAVE_PAGE ) - return TRUE; + return sal_True; else - return FALSE; + return sal_False; } // ----------------------------------------------------------------------- @@ -1017,7 +960,7 @@ void IconChoiceDialog::ResetPageImpl () | \**********************************************************************/ -const USHORT* IconChoiceDialog::GetInputRanges( const SfxItemPool& rPool ) +const sal_uInt16* IconChoiceDialog::GetInputRanges( const SfxItemPool& rPool ) { if ( pSet ) { @@ -1035,10 +978,10 @@ const USHORT* IconChoiceDialog::GetInputRanges( const SfxItemPool& rPool ) IconChoicePageData* pData = maPageList[ i ]; if ( pData->fnGetRanges ) { - const USHORT* pTmpRanges = (pData->fnGetRanges)(); - const USHORT* pIter = pTmpRanges; + const sal_uInt16* pTmpRanges = (pData->fnGetRanges)(); + const sal_uInt16* pIter = pTmpRanges; - USHORT nLen; + sal_uInt16 nLen; for( nLen = 0; *pIter; ++nLen, ++pIter ) ; aUS.Insert( pTmpRanges, nLen, aUS.Count() ); @@ -1061,14 +1004,14 @@ const USHORT* IconChoiceDialog::GetInputRanges( const SfxItemPool& rPool ) #if defined __SUNPRO_CC #pragma disable_warn #endif - qsort( (void*)aUS.GetData(), aUS.Count(), sizeof(USHORT), IconcDlgCmpUS_Impl ); + qsort( (void*)aUS.GetData(), aUS.Count(), sizeof(sal_uInt16), IconcDlgCmpUS_Impl ); #if defined __SUNPRO_CC #pragma enable_warn #endif } - pRanges = new USHORT[aUS.Count() + 1]; - memcpy(pRanges, aUS.GetData(), sizeof(USHORT) * aUS.Count()); + pRanges = new sal_uInt16[aUS.Count() + 1]; + memcpy(pRanges, aUS.GetData(), sizeof(sal_uInt16) * aUS.Count()); pRanges[aUS.Count()] = 0; return pRanges; @@ -1091,48 +1034,14 @@ void IconChoiceDialog::SetInputSet( const SfxItemSet* pInSet ) // ----------------------------------------------------------------------- -// Liefert die Pages, die ihre Sets onDemand liefern, das OutputItemSet. -const SfxItemSet* IconChoiceDialog::GetOutputItemSet ( USHORT nId ) -{ - IconChoicePageData * pData = GetPageData ( nId ); - DBG_ASSERT( pData, "TabPage nicht gefunden" ); - - if ( pData ) - { - if ( !pData->pPage ) - return NULL; - - if ( pData->bOnDemand ) - return &pData->pPage->GetItemSet(); - - return pOutSet; - } - - return NULL; -} - -// ----------------------------------------------------------------------- - -int IconChoiceDialog::FillOutputItemSet() -{ - int nRet = IconChoicePage::LEAVE_PAGE; - if ( OK_Impl() ) - Ok(); - else - nRet = IconChoicePage::KEEP_PAGE; - return nRet; -} - -// ----------------------------------------------------------------------- - -void IconChoiceDialog::PageCreated( USHORT /*nId*/, IconChoicePage& /*rPage*/ ) +void IconChoiceDialog::PageCreated( sal_uInt16 /*nId*/, IconChoicePage& /*rPage*/ ) { // not interested in } // ----------------------------------------------------------------------- -SfxItemSet* IconChoiceDialog::CreateInputItemSet( USHORT ) +SfxItemSet* IconChoiceDialog::CreateInputItemSet( sal_uInt16 ) { DBG_WARNINGFILE( "CreateInputItemSet nicht implementiert" ); @@ -1157,11 +1066,11 @@ short IconChoiceDialog::Execute() // ----------------------------------------------------------------------- -void IconChoiceDialog::Start( BOOL bShow ) +void IconChoiceDialog::Start( sal_Bool bShow ) { aCancelBtn.SetClickHdl( LINK( this, IconChoiceDialog, CancelHdl ) ); - bModal = FALSE; + bModal = sal_False; Start_Impl(); @@ -1192,7 +1101,7 @@ sal_Bool IconChoiceDialog::QueryClose() void IconChoiceDialog::Start_Impl() { Point aPos; - USHORT nActPage; + sal_uInt16 nActPage; if ( mnCurrentPageId == 0 || mnCurrentPageId == USHRT_MAX ) nActPage = maPageList.front()->nId; @@ -1208,7 +1117,7 @@ void IconChoiceDialog::Start_Impl() SetWindowState( ByteString( aTabDlgOpt.GetWindowState().getStr(), RTL_TEXTENCODING_ASCII_US ) ); // initiale TabPage aus Programm/Hilfe/Konfig - nActPage = (USHORT)aTabDlgOpt.GetPageID(); + nActPage = (sal_uInt16)aTabDlgOpt.GetPageID(); if ( USHRT_MAX != mnCurrentPageId ) nActPage = mnCurrentPageId; @@ -1240,7 +1149,7 @@ const SfxItemSet* IconChoiceDialog::GetRefreshedSet() | \**********************************************************************/ -IconChoicePageData* IconChoiceDialog::GetPageData ( USHORT nId ) +IconChoicePageData* IconChoiceDialog::GetPageData ( sal_uInt16 nId ) { IconChoicePageData *pRet = NULL; for ( size_t i=0; i < maPageList.size(); i++ ) @@ -1261,7 +1170,7 @@ IconChoicePageData* IconChoiceDialog::GetPageData ( USHORT nId ) | \**********************************************************************/ -BOOL IconChoiceDialog::OK_Impl() +sal_Bool IconChoiceDialog::OK_Impl() { IconChoicePage* pPage = GetPageData ( mnCurrentPageId )->pPage; @@ -1272,7 +1181,7 @@ BOOL IconChoiceDialog::OK_Impl() if ( pSet ) { SfxItemSet aTmp( *pSet->GetPool(), pSet->GetRanges() ); - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; if ( pPage->HasExchangeSupport() ) nRet = pPage->DeactivatePage( &aTmp ); @@ -1284,7 +1193,7 @@ BOOL IconChoiceDialog::OK_Impl() pOutSet->Put( aTmp ); } else if ( bRet ) - bModified |= TRUE; + bModified |= sal_True; } else nRet = pPage->DeactivatePage( NULL ); @@ -1298,16 +1207,16 @@ BOOL IconChoiceDialog::OK_Impl() short IconChoiceDialog::Ok() { - bInOK = TRUE; + bInOK = sal_True; if ( !pOutSet ) { if ( !pExampleSet && pSet ) - pOutSet = pSet->Clone( FALSE ); // ohne Items + pOutSet = pSet->Clone( sal_False ); // ohne Items else if ( pExampleSet ) pOutSet = new SfxItemSet( *pExampleSet ); } - BOOL _bModified = FALSE; + sal_Bool _bModified = sal_False; for ( size_t i = 0, nCount = maPageList.size(); i < nCount; ++i ) { @@ -1329,7 +1238,7 @@ short IconChoiceDialog::Ok() if ( pPage->FillItemSet( aTmp ) ) { - _bModified |= TRUE; + _bModified |= sal_True; pExampleSet->Put( aTmp ); pOutSet->Put( aTmp ); } @@ -1338,27 +1247,20 @@ short IconChoiceDialog::Ok() } if ( _bModified || ( pOutSet && pOutSet->Count() > 0 ) ) - _bModified |= TRUE; + _bModified |= sal_True; return _bModified ? RET_OK : RET_CANCEL; } // ----------------------------------------------------------------------- -BOOL IconChoiceDialog::IsInOK() const -{ - return bInOK; -} - -// ----------------------------------------------------------------------- - -void IconChoiceDialog::FocusOnIcon( USHORT nId ) +void IconChoiceDialog::FocusOnIcon( sal_uInt16 nId ) { // set focus to icon for the current visible page - for ( USHORT i=0; i<maIconCtrl.GetEntryCount(); i++) + for ( sal_uInt16 i=0; i<maIconCtrl.GetEntryCount(); i++) { SvxIconChoiceCtrlEntry* pEntry = maIconCtrl.GetEntry ( i ); - USHORT* pUserData = (USHORT*) pEntry->GetUserData(); + sal_uInt16* pUserData = (sal_uInt16*) pEntry->GetUserData(); if ( pUserData && *pUserData == nId ) { @@ -1368,11 +1270,5 @@ void IconChoiceDialog::FocusOnIcon( USHORT nId ) } } -// ----------------------------------------------------------------------- - -void IconChoiceDialog::CreateIconTextAutoMnemonics( void ) -{ - maIconCtrl.CreateAutoMnemonics(); -} -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
\ No newline at end of file diff --git a/cui/source/dialogs/insdlg.cxx b/cui/source/dialogs/insdlg.cxx index 041ef64e5d26..891761fcf368 100644 --- a/cui/source/dialogs/insdlg.cxx +++ b/cui/source/dialogs/insdlg.cxx @@ -94,9 +94,9 @@ static String impl_getSvtResString( sal_uInt32 nId ) return aRet; } -BOOL InsertObjectDialog_Impl::IsCreateNew() const +sal_Bool InsertObjectDialog_Impl::IsCreateNew() const { - return FALSE; + return sal_False; } uno::Reference< io::XInputStream > InsertObjectDialog_Impl::GetIconIfIconified( ::rtl::OUString* /*pGraphicMediaType*/ ) @@ -194,11 +194,6 @@ void SvInsertOleDlg::SelectDefault() aLbObjecttype.SelectEntryPos( 0 ); } -void SvInsertOleDlg::FillObjectServerList( SvObjectServerList* pList ) -{ - pList->FillInsertObjects(); -} - // ----------------------------------------------------------------------- SvInsertOleDlg::SvInsertOleDlg ( @@ -209,11 +204,11 @@ SvInsertOleDlg::SvInsertOleDlg : InsertObjectDialog_Impl( pParent, CUI_RES( MD_INSERT_OLEOBJECT ), xStorage ), aRbNewObject( this, CUI_RES( RB_NEW_OBJECT ) ), aRbObjectFromfile( this, CUI_RES( RB_OBJECT_FROMFILE ) ), + aGbObject( this, CUI_RES( GB_OBJECT ) ), aLbObjecttype( this, CUI_RES( LB_OBJECTTYPE ) ), aEdFilepath( this, CUI_RES( ED_FILEPATH ) ), aBtnFilepath( this, CUI_RES( BTN_FILEPATH ) ), aCbFilelink( this, CUI_RES( CB_FILELINK ) ), - aGbObject( this, CUI_RES( GB_OBJECT ) ), aOKButton1( this, CUI_RES( 1 ) ), aCancelButton1( this, CUI_RES( 1 ) ), aHelpButton1( this, CUI_RES( 1 ) ), @@ -227,8 +222,9 @@ SvInsertOleDlg::SvInsertOleDlg Link aLink( LINK( this, SvInsertOleDlg, RadioHdl ) ); aRbNewObject.SetClickHdl( aLink ); aRbObjectFromfile.SetClickHdl( aLink ); - aRbNewObject.Check( TRUE ); + aRbNewObject.Check( sal_True ); RadioHdl( NULL ); + aBtnFilepath.SetAccessibleRelationMemberOf(&aGbObject); } short SvInsertOleDlg::Execute() @@ -244,10 +240,10 @@ short SvInsertOleDlg::Execute() // fill listbox and select default ListBox& rBox = GetObjectTypes(); - rBox.SetUpdateMode( FALSE ); - for ( ULONG i = 0; i < m_pServers->Count(); i++ ) + rBox.SetUpdateMode( sal_False ); + for ( sal_uLong i = 0; i < m_pServers->Count(); i++ ) rBox.InsertEntry( (*m_pServers)[i].GetHumanName() ); - rBox.SetUpdateMode( TRUE ); + rBox.SetUpdateMode( sal_True ); SelectDefault(); ::rtl::OUString aName; @@ -255,8 +251,8 @@ short SvInsertOleDlg::Execute() if ( m_xStorage.is() && ( nRet = Dialog::Execute() ) == RET_OK ) { String aFileName; - BOOL bLink = FALSE; - BOOL bCreateNew = IsCreateNew(); + sal_Bool bLink = sal_False; + sal_Bool bCreateNew = IsCreateNew(); if ( bCreateNew ) { // create and insert new embedded object @@ -452,11 +448,11 @@ IMPL_LINK( SvInsertPlugInDialog, BrowseHdl, PushButton *, EMPTYARG ) SvInsertPlugInDialog::SvInsertPlugInDialog( Window* pParent, const uno::Reference < embed::XStorage >& xStorage ) : InsertObjectDialog_Impl( pParent, CUI_RES( MD_INSERT_OBJECT_PLUGIN ), xStorage ), + aGbFileurl( this, CUI_RES( GB_FILEURL ) ), aEdFileurl( this, CUI_RES( ED_FILEURL ) ), aBtnFileurl( this, CUI_RES( BTN_FILEURL ) ), - aGbFileurl( this, CUI_RES( GB_FILEURL ) ), - aEdPluginsOptions( this, CUI_RES( ED_PLUGINS_OPTIONS ) ), aGbPluginsOptions( this, CUI_RES( GB_PLUGINS_OPTIONS ) ), + aEdPluginsOptions( this, CUI_RES( ED_PLUGINS_OPTIONS ) ), aOKButton1( this, CUI_RES( 1 ) ), aCancelButton1( this, CUI_RES( 1 ) ), aHelpButton1( this, CUI_RES( 1 ) ), @@ -475,7 +471,7 @@ SvInsertPlugInDialog::~SvInsertPlugInDialog() static void Plugin_ImplFillCommandSequence( const String& aCommands, uno::Sequence< beans::PropertyValue >& aCommandSequence ) { - USHORT nEaten; + sal_uInt16 nEaten; SvCommandList aLst; aLst.AppendCommands( aCommands, &nEaten ); @@ -645,7 +641,7 @@ short SvInsertAppletDialog::Execute() m_aClass.Erase(); m_aCommands.Erase(); - BOOL bOK = FALSE; + sal_Bool bOK = sal_False; uno::Reference < beans::XPropertySet > xSet; if ( m_xObj.is() ) { @@ -672,7 +668,7 @@ short SvInsertAppletDialog::Execute() String aText( CUI_RES( STR_EDIT_APPLET ) ); SetText( aText ); - bOK = TRUE; + bOK = sal_True; } catch ( uno::Exception& ) { @@ -701,7 +697,7 @@ short SvInsertAppletDialog::Execute() { try { - BOOL bIPActive = m_xObj->getCurrentState() == embed::EmbedStates::INPLACE_ACTIVE; + sal_Bool bIPActive = m_xObj->getCurrentState() == embed::EmbedStates::INPLACE_ACTIVE; if ( bIPActive ) m_xObj->changeState( embed::EmbedStates::RUNNING ); @@ -742,22 +738,23 @@ SfxInsertFloatingFrameDialog::SfxInsertFloatingFrameDialog( Window *pParent, , aFTURL ( this, CUI_RES( FT_URL ) ) , aEDURL ( this, CUI_RES( ED_URL ) ) , aBTOpen ( this, CUI_RES(BT_FILEOPEN ) ) + + , aFLScrolling ( this, CUI_RES( GB_SCROLLING ) ) , aRBScrollingOn ( this, CUI_RES( RB_SCROLLINGON ) ) , aRBScrollingOff ( this, CUI_RES( RB_SCROLLINGOFF ) ) , aRBScrollingAuto ( this, CUI_RES( RB_SCROLLINGAUTO ) ) - , aFLScrolling ( this, CUI_RES( GB_SCROLLING ) ) , aFLSepLeft( this, CUI_RES( FL_SEP_LEFT ) ) + , aFLFrameBorder( this, CUI_RES( GB_BORDER ) ) , aRBFrameBorderOn ( this, CUI_RES( RB_FRMBORDER_ON ) ) , aRBFrameBorderOff ( this, CUI_RES( RB_FRMBORDER_OFF ) ) - , aFLFrameBorder( this, CUI_RES( GB_BORDER ) ) , aFLSepRight( this, CUI_RES( FL_SEP_RIGHT ) ) + , aFLMargin( this, CUI_RES( GB_MARGIN ) ) , aFTMarginWidth ( this, CUI_RES( FT_MARGINWIDTH ) ) , aNMMarginWidth ( this, CUI_RES( NM_MARGINWIDTH ) ) , aCBMarginWidthDefault( this, CUI_RES( CB_MARGINHEIGHTDEFAULT ) ) , aFTMarginHeight ( this, CUI_RES( FT_MARGINHEIGHT ) ) , aNMMarginHeight ( this, CUI_RES( NM_MARGINHEIGHT ) ) , aCBMarginHeightDefault( this, CUI_RES( CB_MARGINHEIGHTDEFAULT ) ) - , aFLMargin( this, CUI_RES( GB_MARGIN ) ) , aOKButton1( this, CUI_RES( 1 ) ) , aCancelButton1( this, CUI_RES( 1 ) ) , aHelpButton1( this, CUI_RES( 1 ) ) @@ -786,22 +783,25 @@ SfxInsertFloatingFrameDialog::SfxInsertFloatingFrameDialog( Window *pParent, con , aFTURL ( this, CUI_RES( FT_URL ) ) , aEDURL ( this, CUI_RES( ED_URL ) ) , aBTOpen ( this, CUI_RES(BT_FILEOPEN ) ) + + , aFLScrolling ( this, CUI_RES( GB_SCROLLING ) ) , aRBScrollingOn ( this, CUI_RES( RB_SCROLLINGON ) ) , aRBScrollingOff ( this, CUI_RES( RB_SCROLLINGOFF ) ) , aRBScrollingAuto ( this, CUI_RES( RB_SCROLLINGAUTO ) ) - , aFLScrolling ( this, CUI_RES( GB_SCROLLING ) ) + , aFLSepLeft( this, CUI_RES( FL_SEP_LEFT ) ) + , aFLFrameBorder( this, CUI_RES( GB_BORDER ) ) , aRBFrameBorderOn ( this, CUI_RES( RB_FRMBORDER_ON ) ) , aRBFrameBorderOff ( this, CUI_RES( RB_FRMBORDER_OFF ) ) - , aFLFrameBorder( this, CUI_RES( GB_BORDER ) ) + , aFLSepRight( this, CUI_RES( FL_SEP_RIGHT ) ) + , aFLMargin( this, CUI_RES( GB_MARGIN ) ) , aFTMarginWidth ( this, CUI_RES( FT_MARGINWIDTH ) ) , aNMMarginWidth ( this, CUI_RES( NM_MARGINWIDTH ) ) , aCBMarginWidthDefault( this, CUI_RES( CB_MARGINHEIGHTDEFAULT ) ) , aFTMarginHeight ( this, CUI_RES( FT_MARGINHEIGHT ) ) , aNMMarginHeight ( this, CUI_RES( NM_MARGINHEIGHT ) ) , aCBMarginHeightDefault( this, CUI_RES( CB_MARGINHEIGHTDEFAULT ) ) - , aFLMargin( this, CUI_RES( GB_MARGIN ) ) , aOKButton1( this, CUI_RES( 1 ) ) , aCancelButton1( this, CUI_RES( 1 ) ) , aHelpButton1( this, CUI_RES( 1 ) ) @@ -828,7 +828,7 @@ SfxInsertFloatingFrameDialog::SfxInsertFloatingFrameDialog( Window *pParent, con short SfxInsertFloatingFrameDialog::Execute() { short nRet = RET_OK; - BOOL bOK = FALSE; + sal_Bool bOK = sal_False; uno::Reference < beans::XPropertySet > xSet; if ( m_xObj.is() ) { @@ -851,10 +851,10 @@ short SfxInsertFloatingFrameDialog::Execute() if ( nSize == SIZE_NOT_SET ) { - aCBMarginWidthDefault.Check( TRUE ); + aCBMarginWidthDefault.Check( sal_True ); aNMMarginWidth.SetText( String::CreateFromInt32( DEFAULT_MARGIN_WIDTH ) ); - aFTMarginWidth.Enable( FALSE ); - aNMMarginWidth.Enable( FALSE ); + aFTMarginWidth.Enable( sal_False ); + aNMMarginWidth.Enable( sal_False ); } else aNMMarginWidth.SetText( String::CreateFromInt32( nSize ) ); @@ -864,17 +864,17 @@ short SfxInsertFloatingFrameDialog::Execute() if ( nSize == SIZE_NOT_SET ) { - aCBMarginHeightDefault.Check( TRUE ); + aCBMarginHeightDefault.Check( sal_True ); aNMMarginHeight.SetText( String::CreateFromInt32( DEFAULT_MARGIN_HEIGHT ) ); - aFTMarginHeight.Enable( FALSE ); - aNMMarginHeight.Enable( FALSE ); + aFTMarginHeight.Enable( sal_False ); + aNMMarginHeight.Enable( sal_False ); } else aNMMarginHeight.SetText( String::CreateFromInt32( nSize ) ); - BOOL bScrollOn = FALSE; - BOOL bScrollOff = FALSE; - BOOL bScrollAuto = FALSE; + sal_Bool bScrollOn = sal_False; + sal_Bool bScrollOff = sal_False; + sal_Bool bScrollAuto = sal_False; sal_Bool bSet = sal_False; aAny = xSet->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FrameIsAutoScroll") ) ); @@ -887,7 +887,7 @@ short SfxInsertFloatingFrameDialog::Execute() bScrollOff = !bSet; } else - bScrollAuto = TRUE; + bScrollAuto = sal_True; aRBScrollingOn.Check( bScrollOn ); aRBScrollingOff.Check( bScrollOff ); @@ -904,8 +904,8 @@ short SfxInsertFloatingFrameDialog::Execute() aRBFrameBorderOff.Check( !bSet ); } - SetUpdateMode( TRUE ); - bOK = TRUE; + SetUpdateMode( sal_True ); + bOK = sal_True; } catch ( uno::Exception& ) { @@ -945,7 +945,7 @@ short SfxInsertFloatingFrameDialog::Execute() { try { - BOOL bIPActive = m_xObj->getCurrentState() == embed::EmbedStates::INPLACE_ACTIVE; + sal_Bool bIPActive = m_xObj->getCurrentState() == embed::EmbedStates::INPLACE_ACTIVE; if ( bIPActive ) m_xObj->changeState( embed::EmbedStates::RUNNING ); diff --git a/cui/source/dialogs/insrc.cxx b/cui/source/dialogs/insrc.cxx index e6653d01b6b9..d514ef431254 100644 --- a/cui/source/dialogs/insrc.cxx +++ b/cui/source/dialogs/insrc.cxx @@ -42,7 +42,7 @@ sal_uInt16 SvxInsRowColDlg::getInsertCount() const return static_cast< sal_uInt16 >( aCountEdit.GetValue() ); } -SvxInsRowColDlg::SvxInsRowColDlg(Window* pParent, bool bCol, ULONG nHelpId ) +SvxInsRowColDlg::SvxInsRowColDlg(Window* pParent, bool bCol, const rtl::OString& sHelpId ) : ModalDialog( pParent, CUI_RES(DLG_INS_ROW_COL) ), aCount( this, CUI_RES( FT_COUNT ) ), aCountEdit( this, CUI_RES( ED_COUNT ) ), @@ -68,7 +68,7 @@ SvxInsRowColDlg::SvxInsRowColDlg(Window* pParent, bool bCol, ULONG nHelpId ) aTmp += aRow; } SetText( aTmp ); - SetHelpId( nHelpId ); + SetHelpId( sHelpId ); } short SvxInsRowColDlg::Execute(void) diff --git a/cui/source/dialogs/insrc.src b/cui/source/dialogs/insrc.src index 69f934a29049..f655620bcd54 100644 --- a/cui/source/dialogs/insrc.src +++ b/cui/source/dialogs/insrc.src @@ -31,6 +31,7 @@ ModalDialog DLG_INS_ROW_COL { + HelpID = "cui:ModalDialog:DLG_INS_ROW_COL"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 136 , 84 ) ; @@ -57,6 +58,7 @@ ModalDialog DLG_INS_ROW_COL }; RadioButton CB_POS_BEFORE { + HelpID = "cui:RadioButton:DLG_INS_ROW_COL:CB_POS_BEFORE"; Pos = MAP_APPFONT ( 12 , 49 ) ; Size = MAP_APPFONT ( 56 , 10 ) ; Text [ en-US ] = "~Before" ; @@ -64,6 +66,7 @@ ModalDialog DLG_INS_ROW_COL }; RadioButton CB_POS_AFTER { + HelpID = "cui:RadioButton:DLG_INS_ROW_COL:CB_POS_AFTER"; Pos = MAP_APPFONT ( 12 , 62 ) ; Size = MAP_APPFONT ( 56 , 10 ) ; Text [ en-US ] = "A~fter" ; @@ -72,6 +75,7 @@ ModalDialog DLG_INS_ROW_COL }; NumericField ED_COUNT { + HelpID = "cui:NumericField:DLG_INS_ROW_COL:ED_COUNT"; Border = TRUE ; Pos = MAP_APPFONT ( 44 , 14 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; diff --git a/cui/source/dialogs/linkdlg.cxx b/cui/source/dialogs/linkdlg.cxx index eb1fe3432895..9d9b2cece04d 100644 --- a/cui/source/dialogs/linkdlg.cxx +++ b/cui/source/dialogs/linkdlg.cxx @@ -72,27 +72,28 @@ static long nTabs[] = }; -SvBaseLinksDlg::SvBaseLinksDlg( Window * pParent, LinkManager* pMgr, BOOL bHtml ) +SvBaseLinksDlg::SvBaseLinksDlg( Window * pParent, LinkManager* pMgr, sal_Bool bHtml ) : ModalDialog( pParent, CUI_RES( MD_UPDATE_BASELINKS ) ), aFtFiles( this, CUI_RES( FT_FILES ) ), aFtLinks( this, CUI_RES( FT_LINKS ) ), aFtType( this, CUI_RES( FT_TYPE ) ), aFtStatus( this, CUI_RES( FT_STATUS ) ), - aCancelButton1( this, CUI_RES( 1 ) ), - aHelpButton1( this, CUI_RES( 1 ) ), - aPbUpdateNow( this, CUI_RES( PB_UPDATE_NOW ) ), - aPbOpenSource( this, CUI_RES( PB_OPEN_SOURCE ) ), - aPbChangeSource( this, CUI_RES( PB_CHANGE_SOURCE ) ), - aPbBreakLink( this, CUI_RES( PB_BREAK_LINK ) ), + aTbLinks( this, CUI_RES(TB_LINKS ) ), aFtFiles2( this, CUI_RES( FT_FILES2 ) ), + aFtFullFileName( this, CUI_RES( FT_FULL_FILE_NAME ) ), aFtSource2( this, CUI_RES( FT_SOURCE2 ) ), + aFtFullSourceName( this, CUI_RES( FT_FULL_SOURCE_NAME ) ), aFtType2( this, CUI_RES( FT_TYPE2 ) ), + aFtFullTypeName( this, CUI_RES( FT_FULL_TYPE_NAME ) ), aFtUpdate( this, CUI_RES( FT_UPDATE ) ), aRbAutomatic( this, CUI_RES( RB_AUTOMATIC ) ), aRbManual( this, CUI_RES( RB_MANUAL ) ), - aFtFullFileName( this, CUI_RES( FT_FULL_FILE_NAME ) ), - aFtFullSourceName( this, CUI_RES( FT_FULL_SOURCE_NAME ) ), - aFtFullTypeName( this, CUI_RES( FT_FULL_TYPE_NAME ) ), + aCancelButton1( this, CUI_RES( 1 ) ), + aHelpButton1( this, CUI_RES( 1 ) ), + aPbUpdateNow( this, CUI_RES( PB_UPDATE_NOW ) ), + aPbOpenSource( this, CUI_RES( PB_OPEN_SOURCE ) ), + aPbChangeSource( this, CUI_RES( PB_CHANGE_SOURCE ) ), + aPbBreakLink( this, CUI_RES( PB_BREAK_LINK ) ), aStrAutolink( CUI_RES( STR_AUTOLINK ) ), aStrManuallink( CUI_RES( STR_MANUALLINK ) ), aStrBrokenlink( CUI_RES( STR_BROKENLINK ) ), @@ -102,8 +103,7 @@ SvBaseLinksDlg::SvBaseLinksDlg( Window * pParent, LinkManager* pMgr, BOOL bHtml aStrCloselinkmsgMulti( CUI_RES( STR_CLOSELINKMSG_MULTI ) ), aStrWaitinglink( CUI_RES( STR_WAITINGLINK ) ), pLinkMgr( NULL ), - bHtmlMode(bHtml), - aTbLinks( this, CUI_RES(TB_LINKS ) ) + bHtmlMode(bHtml) { FreeResource(); @@ -115,6 +115,12 @@ SvBaseLinksDlg::SvBaseLinksDlg( Window * pParent, LinkManager* pMgr, BOOL bHtml // UpdateTimer fuer DDE-/Grf-Links, auf die gewarted wird aUpdateTimer.SetTimeoutHdl( LINK( this, SvBaseLinksDlg, UpdateWaitingHdl ) ); aUpdateTimer.SetTimeout( 1000 ); + //IAccessibility2 Implementation 2009----- + // Set the ZOrder, and accessible name to the dialog's title + aTbLinks.SetZOrder(0, WINDOW_ZORDER_FIRST); + aTbLinks.SetAccessibleName(this->GetText()); + aTbLinks.SetAccessibleRelationLabeledBy(&aFtFiles); + //-----IAccessibility2 Implementation 2009 OpenSource().Hide(); @@ -141,8 +147,8 @@ SvBaseLinksDlg::~SvBaseLinksDlg() *************************************************************************/ IMPL_LINK( SvBaseLinksDlg, LinksSelectHdl, SvTabListBox *, pSvTabListBox ) { - USHORT nSelectionCount = pSvTabListBox ? - (USHORT)pSvTabListBox->GetSelectionCount() : 0; + sal_uInt16 nSelectionCount = pSvTabListBox ? + (sal_uInt16)pSvTabListBox->GetSelectionCount() : 0; if(nSelectionCount > 1) { //bei Mehrfachselektion ggf. alte Eintraege deselektieren @@ -150,16 +156,16 @@ IMPL_LINK( SvBaseLinksDlg, LinksSelectHdl, SvTabListBox *, pSvTabListBox ) SvBaseLink* pLink = 0; pEntry = pSvTabListBox->GetHdlEntry(); pLink = (SvBaseLink*)pEntry->GetUserData(); - USHORT nObjectType = pLink->GetObjType(); + sal_uInt16 nObjectType = pLink->GetObjType(); if((OBJECT_CLIENT_FILE & nObjectType) != OBJECT_CLIENT_FILE) { - pSvTabListBox->SelectAll(FALSE); + pSvTabListBox->SelectAll(sal_False); pSvTabListBox->Select(pEntry); nSelectionCount = 1; } else { - for( USHORT i = 0; i < nSelectionCount; i++) + for( sal_uInt16 i = 0; i < nSelectionCount; i++) { pEntry = i == 0 ? pSvTabListBox->FirstSelected() : pSvTabListBox->NextSelected(pEntry); @@ -167,7 +173,7 @@ IMPL_LINK( SvBaseLinksDlg, LinksSelectHdl, SvTabListBox *, pSvTabListBox ) pLink = (SvBaseLink*)pEntry->GetUserData(); DBG_ASSERT(pLink, "Wo ist der Link?"); if( (OBJECT_CLIENT_FILE & pLink->GetObjType()) != OBJECT_CLIENT_FILE ) - pSvTabListBox->Select( pEntry, FALSE ); + pSvTabListBox->Select( pEntry, sal_False ); } } @@ -180,7 +186,7 @@ IMPL_LINK( SvBaseLinksDlg, LinksSelectHdl, SvTabListBox *, pSvTabListBox ) } else { - USHORT nPos; + sal_uInt16 nPos; SvBaseLink* pLink = GetSelEntry( &nPos ); if( !pLink ) return 0; @@ -232,7 +238,7 @@ IMPL_LINK_INLINE_START( SvBaseLinksDlg, AutomaticClickHdl, RadioButton *, pRadio { (void)pRadioButton; - USHORT nPos; + sal_uInt16 nPos; SvBaseLink* pLink = GetSelEntry( &nPos ); if( pLink && !( FILEOBJECT & pLink->GetObjType() ) && LINKUPDATE_ALWAYS != pLink->GetUpdateMode() ) @@ -245,7 +251,7 @@ IMPL_LINK_INLINE_START( SvBaseLinksDlg, ManualClickHdl, RadioButton *, pRadioBut { (void)pRadioButton; - USHORT nPos; + sal_uInt16 nPos; SvBaseLink* pLink = GetSelEntry( &nPos ); if( pLink && !( FILEOBJECT & pLink->GetObjType() ) && LINKUPDATE_ONCALL != pLink->GetUpdateMode()) @@ -257,17 +263,17 @@ IMPL_LINK_INLINE_END( SvBaseLinksDlg, ManualClickHdl, RadioButton *, pRadioButto IMPL_LINK( SvBaseLinksDlg, UpdateNowClickHdl, PushButton *, EMPTYARG ) { SvTabListBox& rListBox = Links(); - USHORT nSelCnt = (USHORT)rListBox.GetSelectionCount(); + sal_uInt16 nSelCnt = (sal_uInt16)rListBox.GetSelectionCount(); if( 255 < nSelCnt ) nSelCnt = 255; std::vector< SvBaseLink* > aLnkArr; - std::vector< USHORT > aPosArr; + std::vector< sal_uInt16 > aPosArr; SvLBoxEntry* pE = rListBox.FirstSelected(); while( pE ) { - USHORT nFndPos = (USHORT)rListBox.GetModel()->GetAbsPos( pE ); + sal_uInt16 nFndPos = (sal_uInt16)rListBox.GetModel()->GetAbsPos( pE ); if( LISTBOX_ENTRY_NOTFOUND != nFndPos ) { aLnkArr.push_back( static_cast< SvBaseLink* >( pE->GetUserData() ) ); @@ -278,17 +284,17 @@ IMPL_LINK( SvBaseLinksDlg, UpdateNowClickHdl, PushButton *, EMPTYARG ) if( !aLnkArr.empty() ) { - for( USHORT n = 0; n < aLnkArr.size(); ++n ) + for( sal_uInt16 n = 0; n < aLnkArr.size(); ++n ) { SvBaseLinkRef xLink = aLnkArr[ n ]; // suche erstmal im Array nach dem Eintrag - for( USHORT i = 0; i < pLinkMgr->GetLinks().Count(); ++i ) + for( sal_uInt16 i = 0; i < pLinkMgr->GetLinks().Count(); ++i ) if( &xLink == *pLinkMgr->GetLinks()[ i ] ) { - xLink->SetUseCache( FALSE ); + xLink->SetUseCache( sal_False ); SetType( *xLink, aPosArr[ n ], xLink->GetUpdateMode() ); - xLink->SetUseCache( TRUE ); + xLink->SetUseCache( sal_True ); break; } } @@ -319,7 +325,7 @@ IMPL_LINK( SvBaseLinksDlg, UpdateNowClickHdl, PushButton *, EMPTYARG ) { SvLBoxEntry* pSelEntry = rListBox.FirstSelected(); if( pE != pSelEntry ) - rListBox.Select( pSelEntry, FALSE ); + rListBox.Select( pSelEntry, sal_False ); rListBox.Select( pE ); rListBox.MakeVisible( pE ); } @@ -333,7 +339,7 @@ IMPL_LINK( SvBaseLinksDlg, ChangeSourceClickHdl, PushButton *, pPushButton ) { (void)pPushButton; - USHORT nSelectionCount = (USHORT)Links().GetSelectionCount(); + sal_uInt16 nSelectionCount = (sal_uInt16)Links().GetSelectionCount(); if(nSelectionCount > 1) { PathDialog aPathDlg( this ); @@ -354,7 +360,7 @@ IMPL_LINK( SvBaseLinksDlg, ChangeSourceClickHdl, PushButton *, pPushButton ) { String aPath = aPathDlg.GetPath(); - for( USHORT i = 0; i < nSelectionCount; i++) + for( sal_uInt16 i = 0; i < nSelectionCount; i++) { pEntry = i==0 ? Links().FirstSelected() : @@ -381,7 +387,7 @@ IMPL_LINK( SvBaseLinksDlg, ChangeSourceClickHdl, PushButton *, pPushButton ) } else { - USHORT nPos; + sal_uInt16 nPos; SvBaseLink* pLink = GetSelEntry( &nPos ); if ( pLink && (pLink->GetLinkSourceName().Len() != 0) ) pLink->Edit( this, LINK( this, SvBaseLinksDlg, EndEditHdl ) ); @@ -393,10 +399,10 @@ IMPL_LINK( SvBaseLinksDlg, BreakLinkClickHdl, PushButton *, pPushButton ) { (void)pPushButton; - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if(Links().GetSelectionCount() <= 1) { - USHORT nPos; + sal_uInt16 nPos; SvBaseLinkRef xLink = GetSelEntry( &nPos ); if( !xLink.Is() ) return 0; @@ -408,7 +414,7 @@ IMPL_LINK( SvBaseLinksDlg, BreakLinkClickHdl, PushButton *, pPushButton ) Links().GetModel()->Remove( Links().GetEntry( nPos ) ); // falls Object noch vorhanden, dann das schliessen - BOOL bNewLnkMgr = OBJECT_CLIENT_FILE == xLink->GetObjType(); + sal_Bool bNewLnkMgr = OBJECT_CLIENT_FILE == xLink->GetObjType(); // dem Link sagen, das er aufgeloest wird! xLink->Closed(); @@ -427,7 +433,7 @@ IMPL_LINK( SvBaseLinksDlg, BreakLinkClickHdl, PushButton *, pPushButton ) if( pEntry ) Links().SetCurEntry( pEntry ); } - bModified = TRUE; + bModified = sal_True; } } else @@ -447,7 +453,7 @@ IMPL_LINK( SvBaseLinksDlg, BreakLinkClickHdl, PushButton *, pPushButton ) pEntry = Links().NextSelected(pEntry); } Links().RemoveSelection(); - for( ULONG i = 0; i < aLinkList.Count(); i++ ) + for( sal_uLong i = 0; i < aLinkList.Count(); i++ ) { SvBaseLinkRef xLink = aLinkList.GetObject( i ); // dem Link sagen, das er aufgeloest wird! @@ -455,7 +461,7 @@ IMPL_LINK( SvBaseLinksDlg, BreakLinkClickHdl, PushButton *, pPushButton ) // falls einer vergessen hat sich auszutragen pLinkMgr->Remove( &xLink ); - bModified = TRUE; + bModified = sal_True; } //Danach alle selektierten Eintraege entfernen } @@ -485,8 +491,8 @@ IMPL_LINK( SvBaseLinksDlg, UpdateWaitingHdl, Timer*, pTimer ) { (void)pTimer; - Links().SetUpdateMode(FALSE); - for( ULONG nPos = Links().GetEntryCount(); nPos; ) + Links().SetUpdateMode(sal_False); + for( sal_uLong nPos = Links().GetEntryCount(); nPos; ) { SvLBoxEntry* pBox = Links().GetEntry( --nPos ); SvBaseLinkRef xLink( (SvBaseLink*)pBox->GetUserData() ); @@ -498,13 +504,13 @@ IMPL_LINK( SvBaseLinksDlg, UpdateWaitingHdl, Timer*, pTimer ) Links().SetEntryText( sCur, pBox, 3 ); } } - Links().SetUpdateMode(TRUE); + Links().SetUpdateMode(sal_True); return 0; } IMPL_LINK( SvBaseLinksDlg, EndEditHdl, sfx2::SvBaseLink*, _pLink ) { - USHORT nPos; + sal_uInt16 nPos; GetSelEntry( &nPos ); if( _pLink && _pLink->WasLastEditOK() ) @@ -513,23 +519,23 @@ IMPL_LINK( SvBaseLinksDlg, EndEditHdl, sfx2::SvBaseLink*, _pLink ) // also suche den Link im Manager, wenn der nicht mehr existiert, // dann setze fuelle die Liste komplett neu. Ansonsten braucht // nur der editierte Linkt aktualisiert werden. - BOOL bLinkFnd = FALSE; - for( USHORT n = pLinkMgr->GetLinks().Count(); n; ) + sal_Bool bLinkFnd = sal_False; + for( sal_uInt16 n = pLinkMgr->GetLinks().Count(); n; ) if( _pLink == &(*pLinkMgr->GetLinks()[ --n ]) ) { - bLinkFnd = TRUE; + bLinkFnd = sal_True; break; } if( bLinkFnd ) { - Links().SetUpdateMode(FALSE); + Links().SetUpdateMode(sal_False); Links().GetModel()->Remove( Links().GetEntry( nPos ) ); SvLBoxEntry* pToUnselect = Links().FirstSelected(); InsertEntry( *_pLink, nPos, sal_True ); if(pToUnselect) - Links().Select(pToUnselect, FALSE); - Links().SetUpdateMode(TRUE); + Links().Select(pToUnselect, sal_False); + Links().SetUpdateMode(sal_True); } else { @@ -568,7 +574,7 @@ void SvBaseLinksDlg::SetManager( LinkManager* pNewMgr ) if( pNewMgr ) // Update muss vor Clear gestoppt werden - Links().SetUpdateMode( FALSE ); + Links().SetUpdateMode( sal_False ); Links().Clear(); pLinkMgr = pNewMgr; @@ -576,7 +582,7 @@ void SvBaseLinksDlg::SetManager( LinkManager* pNewMgr ) if( pLinkMgr ) { SvBaseLinks& rLnks = (SvBaseLinks&)pLinkMgr->GetLinks(); - for( USHORT n = 0; n < rLnks.Count(); ++n ) + for( sal_uInt16 n = 0; n < rLnks.Count(); ++n ) { SvBaseLinkRef* pLinkRef = rLnks[ n ]; if( !pLinkRef->Is() ) @@ -596,13 +602,13 @@ void SvBaseLinksDlg::SetManager( LinkManager* pNewMgr ) Links().Select( pEntry ); LinksSelectHdl( 0 ); } - Links().SetUpdateMode( TRUE ); + Links().SetUpdateMode( sal_True ); Links().Invalidate(); } } -void SvBaseLinksDlg::InsertEntry( const SvBaseLink& rLink, USHORT nPos, sal_Bool bSelect ) +void SvBaseLinksDlg::InsertEntry( const SvBaseLink& rLink, sal_uInt16 nPos, sal_Bool bSelect ) { String aEntry, sFileNm, sLinkNm, sTypeNm, sFilter; @@ -640,12 +646,12 @@ void SvBaseLinksDlg::InsertEntry( const SvBaseLink& rLink, USHORT nPos, sal_Bool Links().Select(pE); } -SvBaseLink* SvBaseLinksDlg::GetSelEntry( USHORT* pPos ) +SvBaseLink* SvBaseLinksDlg::GetSelEntry( sal_uInt16* pPos ) { SvLBoxEntry* pE = Links().FirstSelected(); - USHORT nPos; + sal_uInt16 nPos; if( pE && LISTBOX_ENTRY_NOTFOUND != - ( nPos = (USHORT)Links().GetModel()->GetAbsPos( pE ) ) ) + ( nPos = (sal_uInt16)Links().GetModel()->GetAbsPos( pE ) ) ) { DBG_ASSERT( pE, "wo kommt der leere Eintrag her?" ); @@ -657,8 +663,8 @@ SvBaseLink* SvBaseLinksDlg::GetSelEntry( USHORT* pPos ) } void SvBaseLinksDlg::SetType( SvBaseLink& rLink, - USHORT nSelPos, - USHORT nType ) + sal_uInt16 nSelPos, + sal_uInt16 nType ) { rLink.SetUpdateMode( nType ); rLink.Update(); @@ -673,8 +679,8 @@ void SvBaseLinksDlg::SetActLink( SvBaseLink * pLink ) if( pLinkMgr ) { const SvBaseLinks& rLnks = pLinkMgr->GetLinks(); - USHORT nSelect = 0; - for( USHORT n = 0; n < rLnks.Count(); ++n ) + sal_uInt16 nSelect = 0; + for( sal_uInt16 n = 0; n < rLnks.Count(); ++n ) { SvBaseLinkRef* pLinkRef = rLnks[ n ]; // #109573# only visible links have been inserted into the TreeListBox, diff --git a/cui/source/dialogs/makefile.mk b/cui/source/dialogs/makefile.mk index 12239a1ac781..67bc5962cc10 100755..100644 --- a/cui/source/dialogs/makefile.mk +++ b/cui/source/dialogs/makefile.mk @@ -42,6 +42,7 @@ CFLAGS+= -DENABLE_LAYOUT=1 -I../$(PRJ)/layout/inc -I../$(PRJ)/layout/$(INPATH)/i SRS1NAME=dialogs SRC1FILES = \ + about.src \ charmap.src \ commonlingui.src \ cuiimapdlg.src \ @@ -72,6 +73,7 @@ SRC1FILES = \ SLOFILES+=\ + $(SLO)$/about.obj \ $(SLO)$/commonlingui.obj \ $(SLO)$/cuicharmap.obj \ $(SLO)$/cuifmsearch.obj \ diff --git a/cui/source/dialogs/multifil.cxx b/cui/source/dialogs/multifil.cxx index 4c34d9338fe8..bdae49e60979 100644 --- a/cui/source/dialogs/multifil.cxx +++ b/cui/source/dialogs/multifil.cxx @@ -74,13 +74,13 @@ IMPL_LINK( SvxMultiFileDialog, AddHdl_Impl, PushButton *, pBtn ) OSL_ENSURE( xID.is(), "AddHdl_Impl: invalid ID interface!" ); // ensure the content of files are valid - USHORT nCount = aPathLB.GetEntryCount(); - BOOL bDuplicated = FALSE; + sal_uInt16 nCount = aPathLB.GetEntryCount(); + sal_Bool bDuplicated = sal_False; try { if( nCount > 0 ) // start comparison { - USHORT i; + sal_uInt16 i; ::ucbhelper::Content & VContent = aContent; // temporary Content reference Reference< XContent > xVContent; Reference< XContentIdentifier > xVID; @@ -111,7 +111,7 @@ IMPL_LINK( SvxMultiFileDialog, AddHdl_Impl, PushButton *, pBtn ) { if ( 0 == xProvider->compareContentIds( xID, xVID ) ) { - bDuplicated = TRUE; + bDuplicated = sal_True; break; } } @@ -132,7 +132,7 @@ IMPL_LINK( SvxMultiFileDialog, AddHdl_Impl, PushButton *, pBtn ) } else { - USHORT nPos = aPathLB.InsertEntry( sInsFile, LISTBOX_APPEND ); + sal_uInt16 nPos = aPathLB.InsertEntry( sInsFile, LISTBOX_APPEND ); aPathLB.SetEntryData( nPos, (void*) new String( sInsFile ) ); } @@ -144,9 +144,9 @@ IMPL_LINK( SvxMultiFileDialog, AddHdl_Impl, PushButton *, pBtn ) IMPL_LINK( SvxMultiFileDialog, DelHdl_Impl, PushButton *, EMPTYARG ) { - USHORT nPos = aPathLB.GetSelectEntryPos(); + sal_uInt16 nPos = aPathLB.GetSelectEntryPos(); aPathLB.RemoveEntry( nPos ); - USHORT nCnt = aPathLB.GetEntryCount(); + sal_uInt16 nCnt = aPathLB.GetEntryCount(); if ( nCnt ) { @@ -161,7 +161,7 @@ IMPL_LINK( SvxMultiFileDialog, DelHdl_Impl, PushButton *, EMPTYARG ) // ----------------------------------------------------------------------- -SvxMultiFileDialog::SvxMultiFileDialog( Window* pParent, BOOL bEmptyAllowed ) : +SvxMultiFileDialog::SvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed ) : SvxMultiPathDialog( pParent, bEmptyAllowed ) diff --git a/cui/source/dialogs/multipat.cxx b/cui/source/dialogs/multipat.cxx index 030a88b617d8..3e763779b7c8 100644 --- a/cui/source/dialogs/multipat.cxx +++ b/cui/source/dialogs/multipat.cxx @@ -53,23 +53,23 @@ using namespace ::com::sun::star::uno; struct MultiPath_Impl { - BOOL bEmptyAllowed; - BOOL bIsClassPathMode; + sal_Bool bEmptyAllowed; + sal_Bool bIsClassPathMode; bool bIsRadioButtonMode; - MultiPath_Impl( BOOL bAllowed ) : - bEmptyAllowed( bAllowed ), bIsClassPathMode( FALSE ), bIsRadioButtonMode( false ) {} + MultiPath_Impl( sal_Bool bAllowed ) : + bEmptyAllowed( bAllowed ), bIsClassPathMode( sal_False ), bIsRadioButtonMode( false ) {} }; // class SvxMultiPathDialog ---------------------------------------------- IMPL_LINK( SvxMultiPathDialog, SelectHdl_Impl, void *, EMPTYARG ) { - ULONG nCount = pImpl->bIsRadioButtonMode ? aRadioLB.GetEntryCount() : aPathLB.GetEntryCount(); + sal_uLong nCount = pImpl->bIsRadioButtonMode ? aRadioLB.GetEntryCount() : aPathLB.GetEntryCount(); bool bIsSelected = pImpl->bIsRadioButtonMode ? aRadioLB.FirstSelected() != NULL : aPathLB.GetSelectEntryPos() != LISTBOX_ENTRY_NOTFOUND; - BOOL bEnable = ( pImpl->bEmptyAllowed || nCount > 1 ); + sal_Bool bEnable = ( pImpl->bEmptyAllowed || nCount > 1 ); aDelBtn.Enable( bEnable && bIsSelected ); return 0; } @@ -103,7 +103,7 @@ IMPL_LINK( SvxMultiPathDialog, AddHdl_Impl, PushButton *, EMPTYARG ) if ( pImpl->bIsRadioButtonMode ) { - ULONG nPos = aRadioLB.GetEntryPos( sInsPath, 1 ); + sal_uLong nPos = aRadioLB.GetEntryPos( sInsPath, 1 ); if ( 0xffffffff == nPos ) //See svtools/source/contnr/svtabbx.cxx SvTabListBox::GetEntryPos { String sNewEntry( '\t' ); @@ -129,7 +129,7 @@ IMPL_LINK( SvxMultiPathDialog, AddHdl_Impl, PushButton *, EMPTYARG ) } else { - USHORT nPos = aPathLB.InsertEntry( sInsPath, LISTBOX_APPEND ); + sal_uInt16 nPos = aPathLB.InsertEntry( sInsPath, LISTBOX_APPEND ); aPathLB.SetEntryData( nPos, (void*)new String( aURL ) ); } } @@ -147,9 +147,9 @@ IMPL_LINK( SvxMultiPathDialog, DelHdl_Impl, PushButton *, EMPTYARG ) SvLBoxEntry* pEntry = aRadioLB.FirstSelected(); delete (String*)pEntry->GetUserData(); bool bChecked = aRadioLB.GetCheckButtonState( pEntry ) == SV_BUTTON_CHECKED; - ULONG nPos = aRadioLB.GetEntryPos( pEntry ); + sal_uLong nPos = aRadioLB.GetEntryPos( pEntry ); aRadioLB.RemoveEntry( pEntry ); - ULONG nCnt = aRadioLB.GetEntryCount(); + sal_uLong nCnt = aRadioLB.GetEntryCount(); if ( nCnt ) { nCnt--; @@ -167,9 +167,9 @@ IMPL_LINK( SvxMultiPathDialog, DelHdl_Impl, PushButton *, EMPTYARG ) } else { - USHORT nPos = aPathLB.GetSelectEntryPos(); + sal_uInt16 nPos = aPathLB.GetSelectEntryPos(); aPathLB.RemoveEntry( nPos ); - USHORT nCnt = aPathLB.GetEntryCount(); + sal_uInt16 nCnt = aPathLB.GetEntryCount(); if ( nCnt ) { @@ -186,7 +186,7 @@ IMPL_LINK( SvxMultiPathDialog, DelHdl_Impl, PushButton *, EMPTYARG ) // ----------------------------------------------------------------------- -SvxMultiPathDialog::SvxMultiPathDialog( Window* pParent, BOOL bEmptyAllowed ) : +SvxMultiPathDialog::SvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed ) : ModalDialog( pParent, CUI_RES( RID_SVXDLG_MULTIPATH ) ), @@ -218,16 +218,19 @@ SvxMultiPathDialog::SvxMultiPathDialog( Window* pParent, BOOL bEmptyAllowed ) : aDelBtn.SetClickHdl( LINK( this, SvxMultiPathDialog, DelHdl_Impl ) ); SelectHdl_Impl( NULL ); + + aAddBtn.SetAccessibleRelationMemberOf(&aPathLB); + aDelBtn.SetAccessibleRelationMemberOf(&aPathLB); } // ----------------------------------------------------------------------- SvxMultiPathDialog::~SvxMultiPathDialog() { - USHORT nPos = aPathLB.GetEntryCount(); + sal_uInt16 nPos = aPathLB.GetEntryCount(); while ( nPos-- ) delete (String*)aPathLB.GetEntryData(nPos); - nPos = (USHORT)aRadioLB.GetEntryCount(); + nPos = (sal_uInt16)aRadioLB.GetEntryCount(); while ( nPos-- ) { SvLBoxEntry* pEntry = aRadioLB.GetEntry( nPos ); @@ -246,7 +249,7 @@ String SvxMultiPathDialog::GetPath() const if ( pImpl->bIsRadioButtonMode ) { String sWritable; - for ( USHORT i = 0; i < aRadioLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aRadioLB.GetEntryCount(); ++i ) { SvLBoxEntry* pEntry = aRadioLB.GetEntry(i); if ( aRadioLB.GetCheckButtonState( pEntry ) == SV_BUTTON_CHECKED ) @@ -264,7 +267,7 @@ String SvxMultiPathDialog::GetPath() const } else { - for ( USHORT i = 0; i < aPathLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aPathLB.GetEntryCount(); ++i ) { if ( sNewPath.Len() > 0 ) sNewPath += cDelim; @@ -279,9 +282,9 @@ String SvxMultiPathDialog::GetPath() const void SvxMultiPathDialog::SetPath( const String& rPath ) { sal_Unicode cDelim = pImpl->bIsClassPathMode ? CLASSPATH_DELIMITER : SVT_SEARCHPATH_DELIMITER; - USHORT nPos, nCount = rPath.GetTokenCount( cDelim ); + sal_uInt16 nPos, nCount = rPath.GetTokenCount( cDelim ); - for ( USHORT i = 0; i < nCount; ++i ) + for ( sal_uInt16 i = 0; i < nCount; ++i ) { String sPath = rPath.GetToken( i, cDelim ); String sSystemPath; @@ -323,7 +326,7 @@ void SvxMultiPathDialog::SetPath( const String& rPath ) void SvxMultiPathDialog::SetClassPathMode() { - pImpl->bIsClassPathMode = TRUE; + pImpl->bIsClassPathMode = sal_True; SetText( CUI_RES( RID_SVXSTR_ARCHIVE_TITLE )); aPathFL.SetText( CUI_RES( RID_SVXSTR_ARCHIVE_HEADLINE ) ); } diff --git a/cui/source/dialogs/multipat.src b/cui/source/dialogs/multipat.src index a43ab32bbbf6..59ea05308786 100644 --- a/cui/source/dialogs/multipat.src +++ b/cui/source/dialogs/multipat.src @@ -47,6 +47,7 @@ ModalDialog RID_SVXDLG_MULTIPATH }; ListBox LB_MULTIPATH { + HelpID = "cui:ListBox:RID_SVXDLG_MULTIPATH:LB_MULTIPATH"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 189 , 80 ) ; @@ -70,12 +71,14 @@ ModalDialog RID_SVXDLG_MULTIPATH }; PushButton BTN_ADD_MULTIPATH { + HelpID = "cui:PushButton:RID_SVXDLG_MULTIPATH:BTN_ADD_MULTIPATH"; Pos = MAP_APPFONT ( 204 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; }; PushButton BTN_DEL_MULTIPATH { + HelpID = "cui:PushButton:RID_SVXDLG_MULTIPATH:BTN_DEL_MULTIPATH"; Pos = MAP_APPFONT ( 204 , 31 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete" ; diff --git a/cui/source/dialogs/newtabledlg.src b/cui/source/dialogs/newtabledlg.src index 6d9bf1998810..aac42ff4b7ef 100644 --- a/cui/source/dialogs/newtabledlg.src +++ b/cui/source/dialogs/newtabledlg.src @@ -30,6 +30,7 @@ ModalDialog RID_SVX_NEWTABLE_DLG { + HelpID = "cui:ModalDialog:RID_SVX_NEWTABLE_DLG"; OutputSize = TRUE; SVLook = TRUE ; Moveable = TRUE ; @@ -44,6 +45,7 @@ ModalDialog RID_SVX_NEWTABLE_DLG }; NumericField NF_COLUMNS { + HelpID = "cui:NumericField:RID_SVX_NEWTABLE_DLG:NF_COLUMNS"; Border = TRUE ; Pos = MAP_APPFONT ( 80 , 6 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -63,6 +65,7 @@ ModalDialog RID_SVX_NEWTABLE_DLG }; NumericField NF_ROWS { + HelpID = "cui:NumericField:RID_SVX_NEWTABLE_DLG:NF_ROWS"; Border = TRUE ; Pos = MAP_APPFONT ( 80 , 6+15 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; diff --git a/cui/source/dialogs/passwdomdlg.cxx b/cui/source/dialogs/passwdomdlg.cxx index e4bd2dd52de7..1634739b0c2e 100644 --- a/cui/source/dialogs/passwdomdlg.cxx +++ b/cui/source/dialogs/passwdomdlg.cxx @@ -175,7 +175,7 @@ PasswordToOpenModifyDialog_Impl::PasswordToOpenModifyDialog_Impl( m_aMoreFewerOptionsBTN.Enable( bIsPasswordToModify ); if (!bIsPasswordToModify) - m_aMoreFewerOptionsBTN.Hide( TRUE ); + m_aMoreFewerOptionsBTN.Hide( sal_True ); } diff --git a/cui/source/dialogs/pastedlg.cxx b/cui/source/dialogs/pastedlg.cxx index 007ffa82762b..3d034664389c 100644 --- a/cui/source/dialogs/pastedlg.cxx +++ b/cui/source/dialogs/pastedlg.cxx @@ -52,10 +52,10 @@ SvPasteObjectDialog::SvPasteObjectDialog( Window* pParent ) aFtObjectSource( this, CUI_RES( FT_OBJECT_SOURCE ) ), aRbPaste( this, CUI_RES( RB_PASTE ) ), aRbPasteLink( this, CUI_RES( RB_PASTE_LINK ) ), - aLbInsertList( this, CUI_RES( LB_INSERT_LIST ) ), aCbDisplayAsIcon( this, CUI_RES( CB_DISPLAY_AS_ICON ) ), aPbChangeIcon( this, CUI_RES( PB_CHANGE_ICON ) ), aFlChoice( this, CUI_RES( FL_CHOICE ) ), + aLbInsertList( this, CUI_RES( LB_INSERT_LIST ) ), aOKButton1( this, CUI_RES( 1 ) ), aCancelButton1( this, CUI_RES( 1 ) ), aHelpButton1( this, CUI_RES( 1 ) ), @@ -73,6 +73,8 @@ SvPasteObjectDialog::SvPasteObjectDialog( Window* pParent ) ObjectLB().SetSelectHdl( LINK( this, SvPasteObjectDialog, SelectHdl ) ); ObjectLB().SetDoubleClickHdl( LINK( this, SvPasteObjectDialog, DoubleClickHdl ) ); SetDefault(); + + aLbInsertList.SetAccessibleName(aFlChoice.GetText()); } void SvPasteObjectDialog::SelectObject() @@ -105,8 +107,8 @@ IMPL_LINK_INLINE_END( SvPasteObjectDialog, DoubleClickHdl, ListBox *, pListBox ) void SvPasteObjectDialog::SetDefault() { - bLink = FALSE; - nAspect = (USHORT)::com::sun::star::embed::Aspects::MSOLE_CONTENT; + bLink = sal_False; + nAspect = (sal_uInt16)::com::sun::star::embed::Aspects::MSOLE_CONTENT; } SvPasteObjectDialog::~SvPasteObjectDialog() @@ -129,7 +131,7 @@ void SvPasteObjectDialog::Insert( SotFormatStringId nFormat, const String& rForm delete pStr; } -ULONG SvPasteObjectDialog::GetFormat( const TransferableDataHelper& rHelper, +sal_uLong SvPasteObjectDialog::GetFormat( const TransferableDataHelper& rHelper, const DataFlavorExVector* pFormats, const TransferableObjectDescriptor* ) { @@ -143,10 +145,10 @@ ULONG SvPasteObjectDialog::GetFormat( const TransferableDataHelper& rHelper, //Dialogbox erzeugen und fuellen String aSourceName, aTypeName; - ULONG nSelFormat = 0; + sal_uLong nSelFormat = 0; SvGlobalName aEmptyNm; - ObjectLB().SetUpdateMode( FALSE ); + ObjectLB().SetUpdateMode( sal_False ); DataFlavorExVector::iterator aIter( ((DataFlavorExVector&)*pFormats).begin() ), aEnd( ((DataFlavorExVector&)*pFormats).end() ); @@ -218,7 +220,7 @@ ULONG SvPasteObjectDialog::GetFormat( const TransferableDataHelper& rHelper, } } - ObjectLB().SetUpdateMode( TRUE ); + ObjectLB().SetUpdateMode( sal_True ); SelectObject(); if( aSourceName.Len() ) @@ -239,9 +241,9 @@ ULONG SvPasteObjectDialog::GetFormat( const TransferableDataHelper& rHelper, bLink = PasteLink().IsChecked(); if( AsIconBox().IsChecked() ) - nAspect = (USHORT)com::sun::star::embed::Aspects::MSOLE_ICON; + nAspect = (sal_uInt16)com::sun::star::embed::Aspects::MSOLE_ICON; - nSelFormat = (ULONG)ObjectLB().GetEntryData( ObjectLB().GetSelectEntryPos() ); + nSelFormat = (sal_uLong)ObjectLB().GetEntryData( ObjectLB().GetSelectEntryPos() ); } return nSelFormat; diff --git a/cui/source/dialogs/plfilter.cxx b/cui/source/dialogs/plfilter.cxx index e00ed70cc1a7..407a0c29d9bc 100644 --- a/cui/source/dialogs/plfilter.cxx +++ b/cui/source/dialogs/plfilter.cxx @@ -69,14 +69,14 @@ void fillNetscapePluginFilters( Sequence< rtl::OUString >& rPluginNames, Sequenc Sequence<PluginDescription > aDescriptions( xPMgr->getPluginDescriptions() ); const PluginDescription * pDescriptions = aDescriptions.getConstArray(); - for ( UINT32 nPos = aDescriptions.getLength(); nPos--; ) + for ( sal_uInt32 nPos = aDescriptions.getLength(); nPos--; ) { const PluginDescription & rDescr = pDescriptions[nPos]; StrSet& rTypes = aMap[ rDescr.Description ]; String aExtension( rDescr.Extension ); - for ( USHORT nCnt = aExtension.GetTokenCount( ';' ); nCnt--; ) + for ( sal_uInt16 nCnt = aExtension.GetTokenCount( ';' ); nCnt--; ) { // no default plugins anymore String aExt( aExtension.GetToken( nCnt, ';' ) ); @@ -119,7 +119,7 @@ void fillNetscapePluginFilters( Sequence< rtl::OUString >& rPluginNames, Sequenc } else ShowServiceNotAvailableError( NULL, - String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.plugin.PluginManager" ) ), TRUE ); + String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.plugin.PluginManager" ) ), sal_True ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx index 0255e3c9fc55..e16815ce84ef 100644 --- a/cui/source/dialogs/postdlg.cxx +++ b/cui/source/dialogs/postdlg.cxx @@ -52,7 +52,7 @@ // static ---------------------------------------------------------------- -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_ATTR_POSTIT_AUTHOR, SID_ATTR_POSTIT_TEXT, @@ -63,8 +63,8 @@ static USHORT pRanges[] = SvxPostItDialog::SvxPostItDialog( Window* pParent, const SfxItemSet& rCoreSet, - BOOL bPrevNext, - BOOL bRedline ) : + sal_Bool bPrevNext, + sal_Bool bRedline ) : SfxModalDialog( pParent, CUI_RES( RID_SVXDLG_POSTIT ) ), @@ -102,8 +102,8 @@ SvxPostItDialog::SvxPostItDialog( Window* pParent, aFont.SetWeight( WEIGHT_LIGHT ); aEditED.SetFont( aFont ); - BOOL bNew = TRUE; - USHORT nWhich = 0; + sal_Bool bNew = sal_True; + sal_uInt16 nWhich = 0; if ( !bPrevNext ) { @@ -114,9 +114,9 @@ SvxPostItDialog::SvxPostItDialog( Window* pParent, nWhich = rSet.GetPool()->GetWhich( SID_ATTR_POSTIT_AUTHOR ); String aAuthorStr, aDateStr, aTextStr; - if ( rSet.GetItemState( nWhich, TRUE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_True ) >= SFX_ITEM_AVAILABLE ) { - bNew = FALSE; + bNew = sal_False; const SvxPostItAuthorItem& rAuthor = (const SvxPostItAuthorItem&)rSet.Get( nWhich ); aAuthorStr = rAuthor.GetValue(); @@ -126,7 +126,7 @@ SvxPostItDialog::SvxPostItDialog( Window* pParent, nWhich = rSet.GetPool()->GetWhich( SID_ATTR_POSTIT_DATE ); - if ( rSet.GetItemState( nWhich, TRUE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_True ) >= SFX_ITEM_AVAILABLE ) { const SvxPostItDateItem& rDate = (const SvxPostItDateItem&)rSet.Get( nWhich ); @@ -140,7 +140,7 @@ SvxPostItDialog::SvxPostItDialog( Window* pParent, nWhich = rSet.GetPool()->GetWhich( SID_ATTR_POSTIT_TEXT ); - if ( rSet.GetItemState( nWhich, TRUE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_True ) >= SFX_ITEM_AVAILABLE ) { const SvxPostItTextItem& rText = (const SvxPostItTextItem&)rSet.Get( nWhich ); @@ -157,6 +157,10 @@ SvxPostItDialog::SvxPostItDialog( Window* pParent, SetText( CUI_RESSTR( STR_NOTIZ_INSERT ) ); FreeResource(); + + aEditED.SetAccessibleRelationLabeledBy(&aEditFT); + aEditED.SetAccessibleRelationMemberOf(&aPostItFL); + aAuthorBtn.SetAccessibleRelationMemberOf(&aPostItFL); } // ----------------------------------------------------------------------- @@ -179,14 +183,14 @@ void SvxPostItDialog::ShowLastAuthor(const String& rAuthor, const String& rDate) // ----------------------------------------------------------------------- -USHORT* SvxPostItDialog::GetRanges() +sal_uInt16* SvxPostItDialog::GetRanges() { return pRanges; } // ----------------------------------------------------------------------- -void SvxPostItDialog::EnableTravel(BOOL bNext, BOOL bPrev) +void SvxPostItDialog::EnableTravel(sal_Bool bNext, sal_Bool bPrev) { aPrevBtn.Enable(bPrev); aNextBtn.Enable(bNext); @@ -228,7 +232,7 @@ IMPL_LINK( SvxPostItDialog, Stamp, Button *, EMPTYARG ) } aStr += aLocaleWrapper.getDate(aDate); aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ", " ) ); - aStr += aLocaleWrapper.getTime(aTime, FALSE, FALSE); + aStr += aLocaleWrapper.getTime(aTime, sal_False, sal_False); aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( " ----\n" ) ); diff --git a/cui/source/dialogs/postdlg.src b/cui/source/dialogs/postdlg.src index 2a3dc5e98a00..9b652357296b 100644 --- a/cui/source/dialogs/postdlg.src +++ b/cui/source/dialogs/postdlg.src @@ -27,12 +27,13 @@ // include --------------------------------------------------------------- #include <cuires.hrc> #include "postdlg.hrc" +#include "helpid.hrc" #include <svx/dialogs.hrc> // for RID_SVXDLG_POSTIT // RID_SVXDLG_POSTIT ----------------------------------------------------- ModalDialog RID_SVXDLG_POSTIT { - HelpId = SID_POSTIT ; + HelpId = HID_POSTIT_DIALOG ; OutputSize = TRUE ; SvLook = TRUE ; Size = MAP_APPFONT ( 198 , 134 ) ; @@ -60,6 +61,7 @@ ModalDialog RID_SVXDLG_POSTIT }; MultiLineEdit ED_EDIT { + HelpID = "cui:MultiLineEdit:RID_SVXDLG_POSTIT:ED_EDIT"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 38 ) ; Size = MAP_APPFONT ( 123 , 72 ) ; @@ -92,12 +94,14 @@ ModalDialog RID_SVXDLG_POSTIT }; ImageButton BTN_PREV { + HelpID = "cui:ImageButton:RID_SVXDLG_POSTIT:BTN_PREV"; Pos = MAP_APPFONT ( 141 , 60 ) ; Size = MAP_APPFONT ( 24 , 14 ) ; Symbol = IMAGEBUTTON_ARROW_LEFT ; }; ImageButton BTN_NEXT { + HelpID = "cui:ImageButton:RID_SVXDLG_POSTIT:BTN_NEXT"; Pos = MAP_APPFONT ( 167 , 60 ) ; Size = MAP_APPFONT ( 24 , 14 ) ; Symbol = IMAGEBUTTON_ARROW_RIGHT ; @@ -110,6 +114,7 @@ ModalDialog RID_SVXDLG_POSTIT }; PushButton BTN_AUTHOR { + HelpID = "cui:PushButton:RID_SVXDLG_POSTIT:BTN_AUTHOR"; Pos = MAP_APPFONT ( 75 , 114 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "Author" ; diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx index 40b5ecaf20e1..182e5bb02d5d 100644 --- a/cui/source/dialogs/scriptdlg.cxx +++ b/cui/source/dialogs/scriptdlg.cxx @@ -92,7 +92,7 @@ SFTreeListBox::SFTreeListBox( Window* pParent, const ResId& rResId ) : FreeResource(); SetSelectionMode( SINGLE_SELECTION ); - SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_HASBUTTONS | WB_HASBUTTONSATROOT | WB_HIDESELECTION | WB_HASLINES | WB_HASLINESATROOT ); SetNodeDefaultImages(); @@ -159,7 +159,7 @@ void SFTreeListBox::deleteAllTree() void SFTreeListBox::Init( const ::rtl::OUString& language ) { - SetUpdateMode( FALSE ); + SetUpdateMode( sal_False ); deleteAllTree(); @@ -262,7 +262,7 @@ void SFTreeListBox::Init( const ::rtl::OUString& language ) 0, true, std::auto_ptr< SFEntry >(new SFEntry( OBJTYPE_SFROOT, langEntries, xDocumentModel )), factoryURL ); } - SetUpdateMode( TRUE ); + SetUpdateMode( sal_True ); } Reference< XInterface > @@ -358,18 +358,9 @@ void SFTreeListBox:: RequestSubEntries( SvLBoxEntry* pRootEntry, Reference< ::co } } -void SFTreeListBox::UpdateEntries() -{ -} - -SvLBoxEntry* SFTreeListBox::FindEntry( SvLBoxEntry* , const String& , BYTE ) -{ - return 0; -} - long SFTreeListBox::ExpandingHdl() { - return TRUE; + return sal_True; } void SFTreeListBox::ExpandAllTrees() @@ -377,7 +368,7 @@ void SFTreeListBox::ExpandAllTrees() } SvLBoxEntry * SFTreeListBox::insertEntry( - String const & rText, USHORT nBitmap, SvLBoxEntry * pParent, + String const & rText, sal_uInt16 nBitmap, SvLBoxEntry * pParent, bool bChildrenOnDemand, std::auto_ptr< SFEntry > aUserData, ::rtl::OUString factoryURL ) { SvLBoxEntry * p; @@ -396,7 +387,7 @@ SvLBoxEntry * SFTreeListBox::insertEntry( } SvLBoxEntry * SFTreeListBox::insertEntry( - String const & rText, USHORT nBitmap, SvLBoxEntry * pParent, + String const & rText, sal_uInt16 nBitmap, SvLBoxEntry * pParent, bool bChildrenOnDemand, std::auto_ptr< SFEntry > aUserData ) { Image aImage; @@ -449,7 +440,7 @@ void SFTreeListBox::ExpandedHdl() // ---------------------------------------------------------------------------- // InputDialog ------------------------------------------------------------ // ---------------------------------------------------------------------------- -InputDialog::InputDialog(Window * pParent, USHORT nMode ) +InputDialog::InputDialog(Window * pParent, sal_uInt16 nMode ) : ModalDialog( pParent, CUI_RES( RID_DLG_NEWLIB ) ), aText( this, CUI_RES( FT_NEWLIB ) ), aEdit( this, CUI_RES( ED_LIBNAME ) ), @@ -478,7 +469,7 @@ InputDialog::InputDialog(Window * pParent, USHORT nMode ) Size siz, newSiz; long gap; - USHORT style = TEXT_DRAW_MULTILINE | TEXT_DRAW_TOP | + sal_uInt16 style = TEXT_DRAW_MULTILINE | TEXT_DRAW_TOP | TEXT_DRAW_LEFT | TEXT_DRAW_WORDBREAK; // get dimensions of dialog instructions control @@ -592,10 +583,6 @@ short SvxScriptOrgDialog::Execute() return nRet; } -void SvxScriptOrgDialog::EnableButton( Button& , BOOL ) -{ -} - void SvxScriptOrgDialog::CheckButtons( Reference< browse::XBrowseNode >& node ) { if ( node.is() ) @@ -887,38 +874,6 @@ Reference< XModel > SvxScriptOrgDialog::getModel( SvLBoxEntry* pEntry ) return model; } -Reference< XInterface > -SvxScriptOrgDialog::getDocumentModel( Reference< XComponentContext >& xCtx, ::rtl::OUString& docName ) -{ - Reference< XInterface > xModel; - Reference< lang::XMultiComponentFactory > mcf = - xCtx->getServiceManager(); - Reference< frame::XDesktop > desktop ( - mcf->createInstanceWithContext( - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop") ), xCtx ), - UNO_QUERY ); - - Reference< container::XEnumerationAccess > componentsAccess = - desktop->getComponents(); - Reference< container::XEnumeration > components = - componentsAccess->createEnumeration(); - while (components->hasMoreElements()) - { - Reference< frame::XModel > model( - components->nextElement(), UNO_QUERY ); - if ( model.is() ) - { - ::rtl::OUString sTdocUrl = ::comphelper::DocumentInfo::getDocumentTitle( model ); - if( sTdocUrl.equals( docName ) ) - { - xModel = model; - break; - } - } - } - return xModel; -} - void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) { @@ -930,7 +885,7 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) { ::rtl::OUString aNewName; ::rtl::OUString aNewStdName; - USHORT nMode = INPUTMODE_NEWLIB; + sal_uInt16 nMode = INPUTMODE_NEWLIB; if( aScriptsBox.GetModel()->GetDepth( pEntry ) == 0 ) { aNewStdName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Library") ) ; @@ -942,8 +897,8 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) } //do we need L10N for this? ie somethng like: //String aNewStdName( ResId( STR_STDMODULENAME ) ); - BOOL bValid = FALSE; - USHORT i = 1; + sal_Bool bValid = sal_False; + sal_uInt16 i = 1; Sequence< Reference< browse::XBrowseNode > > childNodes; // no children => ok to create Parcel1 or Script1 without checking @@ -953,7 +908,7 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) { aNewName = aNewStdName; aNewName += String::CreateFromInt32( i ); - bValid = TRUE; + bValid = sal_True; } else { @@ -970,7 +925,7 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) { aNewName = aNewStdName; aNewName += String::CreateFromInt32( i ); - BOOL bFound = FALSE; + sal_Bool bFound = sal_False; if(childNodes.getLength() > 0 ) { ::rtl::OUString nodeName = childNodes[0]->getName(); @@ -982,7 +937,7 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) { if ( (aNewName+extn).equals( childNodes[index]->getName() ) ) { - bFound = TRUE; + bFound = sal_True; break; } } @@ -992,7 +947,7 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) } else { - bValid = TRUE; + bValid = sal_True; } } @@ -1004,12 +959,12 @@ void SvxScriptOrgDialog::createEntry( SvLBoxEntry* pEntry ) if ( xNewDlg->Execute() && xNewDlg->GetObjectName().Len() ) { ::rtl::OUString aUserSuppliedName = xNewDlg->GetObjectName(); - bValid = TRUE; + bValid = sal_True; for( sal_Int32 index = 0; index < childNodes.getLength(); index++ ) { if ( (aUserSuppliedName+extn).equals( childNodes[index]->getName() ) ) { - bValid = FALSE; + bValid = sal_False; String aError( m_createErrStr ); aError.Append( m_createDupStr ); ErrorBox aErrorBox( static_cast<Window*>(this), WB_OK | RET_OK, aError ); @@ -1119,18 +1074,18 @@ void SvxScriptOrgDialog::renameEntry( SvLBoxEntry* pEntry ) extn = aNewName.copy(extnPos); aNewName = aNewName.copy(0,extnPos); } - USHORT nMode = INPUTMODE_RENAME; + sal_uInt16 nMode = INPUTMODE_RENAME; std::auto_ptr< InputDialog > xNewDlg( new InputDialog( static_cast<Window*>(this), nMode ) ); xNewDlg->SetObjectName( aNewName ); - BOOL bValid; + sal_Bool bValid; do { if ( xNewDlg->Execute() && xNewDlg->GetObjectName().Len() ) { ::rtl::OUString aUserSuppliedName = xNewDlg->GetObjectName(); - bValid = TRUE; + bValid = sal_True; if( bValid ) aNewName = aUserSuppliedName; } @@ -1226,10 +1181,10 @@ void SvxScriptOrgDialog::deleteEntry( SvLBoxEntry* pEntry ) } -BOOL SvxScriptOrgDialog::getBoolProperty( Reference< beans::XPropertySet >& xProps, +sal_Bool SvxScriptOrgDialog::getBoolProperty( Reference< beans::XPropertySet >& xProps, ::rtl::OUString& propName ) { - BOOL result = false; + sal_Bool result = false; try { sal_Bool bTemp = sal_False; @@ -1299,7 +1254,7 @@ void SvxScriptOrgDialog::RestorePreviousSelection() if( aStoredEntry.Len() <= 0 ) return; SvLBoxEntry* pEntry = 0; - USHORT nIndex = 0; + sal_uInt16 nIndex = 0; while ( nIndex != STRING_NOTFOUND ) { String aTmp( aStoredEntry.GetToken( 0, ';', nIndex ) ); @@ -1322,28 +1277,6 @@ void SvxScriptOrgDialog::RestorePreviousSelection() aScriptsBox.SetCurEntry( pEntry ); } -BOOL SFTreeListBox::dialogSort1( Reference< browse::XBrowseNode > node1, - Reference< browse::XBrowseNode > node2 ) -{ - ::rtl::OUString userStr( RTL_CONSTASCII_USTRINGPARAM("user") ); - ::rtl::OUString shareStr( RTL_CONSTASCII_USTRINGPARAM("share") ); - if( node1->getName().equals( userStr ) ) - return true; - if( node2->getName().equals( userStr ) ) - return false; - if( node1->getName().equals( shareStr ) ) - return true; - if( node2->getName().equals( shareStr ) ) - return false; - return dialogSort2( node1, node2 ); -} - -BOOL SFTreeListBox::dialogSort2( Reference< browse::XBrowseNode > node1, - Reference< browse::XBrowseNode > node2 ) -{ - return ( node1->getName().compareTo( node2->getName() ) < 0 ); -} - ::rtl::OUString ReplaceString( const ::rtl::OUString& source, const ::rtl::OUString& token, diff --git a/cui/source/dialogs/scriptdlg.src b/cui/source/dialogs/scriptdlg.src index 5a551cede7ef..0c58be37e1b1 100644 --- a/cui/source/dialogs/scriptdlg.src +++ b/cui/source/dialogs/scriptdlg.src @@ -86,6 +86,7 @@ ModalDialog RID_DLG_SCRIPTORGANIZER PushButton SF_PB_RUN { + HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_RUN"; Pos = MAP_APPFONT ( 144 , 6 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; DefButton = TRUE; @@ -101,6 +102,7 @@ ModalDialog RID_DLG_SCRIPTORGANIZER PushButton SF_PB_CREATE { + HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_CREATE"; Size = MAP_APPFONT ( 60 , 14 ) ; Pos = MAP_APPFONT ( 144 , 60 ) ; Text [ en-US ] = "~Create..." ; @@ -108,6 +110,7 @@ ModalDialog RID_DLG_SCRIPTORGANIZER }; PushButton SF_PB_EDIT { + HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_EDIT"; Size = MAP_APPFONT ( 60 , 14 ) ; Pos = MAP_APPFONT ( 144 , 77 ) ; Text [ en-US ] = "~Edit" ; @@ -115,12 +118,14 @@ ModalDialog RID_DLG_SCRIPTORGANIZER }; PushButton SF_PB_RENAME { + HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_RENAME"; Pos = MAP_APPFONT ( 144 , 94 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "Rename..." ; }; PushButton SF_PB_DEL { + HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_DEL"; Pos = MAP_APPFONT ( 144 , 114 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -136,6 +141,7 @@ ModalDialog RID_DLG_SCRIPTORGANIZER }; ModalDialog RID_DLG_NEWLIB { + HelpID = "cui:ModalDialog:RID_DLG_NEWLIB"; Text [ en-US ] = "Create Library" ; Size = MAP_APPFONT ( 160 , 50 ) ; Moveable = TRUE ; @@ -162,6 +168,7 @@ ModalDialog RID_DLG_NEWLIB }; Edit ED_LIBNAME { + HelpID = "cui:Edit:RID_DLG_NEWLIB:ED_LIBNAME"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 59 ) ; Size = MAP_APPFONT ( 92 , 12 ) ; diff --git a/cui/source/dialogs/sdrcelldlg.cxx b/cui/source/dialogs/sdrcelldlg.cxx index 52b9f43bd0e8..99596c1123c7 100644 --- a/cui/source/dialogs/sdrcelldlg.cxx +++ b/cui/source/dialogs/sdrcelldlg.cxx @@ -57,7 +57,7 @@ SvxFormatCellsDialog::~SvxFormatCellsDialog() { } -void SvxFormatCellsDialog::PageCreated( USHORT nId, SfxTabPage &rPage ) +void SvxFormatCellsDialog::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { switch( nId ) { diff --git a/cui/source/dialogs/showcols.src b/cui/source/dialogs/showcols.src index a66622a2091a..8cede7ee380b 100644 --- a/cui/source/dialogs/showcols.src +++ b/cui/source/dialogs/showcols.src @@ -29,6 +29,7 @@ ModalDialog RID_SVX_DLG_SHOWGRIDCOLUMNS { + HelpID = "cui:ModalDialog:RID_SVX_DLG_SHOWGRIDCOLUMNS"; OutputSize = TRUE; SVLook = TRUE ; Size = MAP_APPFONT( 200, 117 ); @@ -45,6 +46,7 @@ ModalDialog RID_SVX_DLG_SHOWGRIDCOLUMNS ListBox 1 { + HelpID = "cui:ListBox:RID_SVX_DLG_SHOWGRIDCOLUMNS:1"; Border = TRUE; Pos = MAP_APPFONT( 6, 39 ); Size = MAP_APPFONT( 188, 55 ); diff --git a/cui/source/dialogs/splitcelldlg.cxx b/cui/source/dialogs/splitcelldlg.cxx index 81591e13317f..8b408bf71203 100644 --- a/cui/source/dialogs/splitcelldlg.cxx +++ b/cui/source/dialogs/splitcelldlg.cxx @@ -36,13 +36,13 @@ SvxSplitTableDlg::SvxSplitTableDlg( Window *pParent, bool bIsTableVertical, long nMaxVertical, long nMaxHorizontal ) : SvxStandardDialog(pParent, CUI_RES(RID_SVX_SPLITCELLDLG)) +, maCountFL(this, CUI_RES(FL_COUNT)) , maCountLbl(this, CUI_RES(FT_COUNT)) , maCountEdit(this, CUI_RES(ED_COUNT)) -, maCountFL(this, CUI_RES(FL_COUNT)) +, maDirFL(this, CUI_RES(FL_DIR)) , maHorzBox(this, CUI_RES(RB_HORZ)) , maVertBox(this, CUI_RES(RB_VERT)) , maPropCB(this, CUI_RES(CB_PROP)) -, maDirFL(this, CUI_RES(FL_DIR)) , maOKBtn(this, CUI_RES(BT_OK)) , maCancelBtn(this, CUI_RES(BT_CANCEL)) , maHelpBtn( this, CUI_RES( BT_HELP ) ) @@ -55,7 +55,7 @@ SvxSplitTableDlg::SvxSplitTableDlg( Window *pParent, bool bIsTableVertical, long maVertBox.SetClickHdl( LINK( this, SvxSplitTableDlg, ClickHdl )); if( mnMaxVertical < 2 ) - maVertBox.Enable(FALSE); + maVertBox.Enable(sal_False); //exchange the meaning of horizontal and vertical for vertical text if(bIsTableVertical) diff --git a/cui/source/dialogs/splitcelldlg.src b/cui/source/dialogs/splitcelldlg.src index 9f435e3169b7..6fb9a990aa38 100644 --- a/cui/source/dialogs/splitcelldlg.src +++ b/cui/source/dialogs/splitcelldlg.src @@ -30,6 +30,7 @@ ModalDialog RID_SVX_SPLITCELLDLG { + HelpID = "cui:ModalDialog:RID_SVX_SPLITCELLDLG"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 169 , 108 ) ; @@ -64,6 +65,7 @@ ModalDialog RID_SVX_SPLITCELLDLG }; NumericField ED_COUNT { + HelpID = "cui:NumericField:RID_SVX_SPLITCELLDLG:ED_COUNT"; Border = TRUE ; Pos = MAP_APPFONT ( 82 , 14 ) ; Size = MAP_APPFONT ( 21 , 12 ) ; @@ -85,6 +87,7 @@ ModalDialog RID_SVX_SPLITCELLDLG }; ImageRadioButton RB_HORZ { + HelpID = "cui:ImageRadioButton:RID_SVX_SPLITCELLDLG:RB_HORZ"; Pos = MAP_APPFONT ( 12 , 47 ) ; Size = MAP_APPFONT ( 90 , 18 ) ; Group = TRUE; @@ -98,12 +101,14 @@ ModalDialog RID_SVX_SPLITCELLDLG }; CheckBox CB_PROP { + HelpID = "cui:CheckBox:RID_SVX_SPLITCELLDLG:CB_PROP"; Pos = MAP_APPFONT ( 18 , 68 ) ; Size = MAP_APPFONT ( 91 , 12 ) ; Text [ en-US ] = "~Into equal proportions"; }; ImageRadioButton RB_VERT { + HelpID = "cui:ImageRadioButton:RID_SVX_SPLITCELLDLG:RB_VERT"; Pos = MAP_APPFONT ( 12 , 84 ) ; Size = MAP_APPFONT ( 90 , 18 ) ; Text [ en-US ] = "~Vertically" ; diff --git a/cui/source/dialogs/srchxtra.cxx b/cui/source/dialogs/srchxtra.cxx index c503061a1f44..4f8b83bc67f9 100644 --- a/cui/source/dialogs/srchxtra.cxx +++ b/cui/source/dialogs/srchxtra.cxx @@ -84,7 +84,7 @@ SvxSearchFormatDialog::~SvxSearchFormatDialog() // ----------------------------------------------------------------------- -void SvxSearchFormatDialog::PageCreated( USHORT nId, SfxTabPage& rPage ) +void SvxSearchFormatDialog::PageCreated( sal_uInt16 nId, SfxTabPage& rPage ) { switch ( nId ) { @@ -125,7 +125,7 @@ void SvxSearchFormatDialog::PageCreated( USHORT nId, SfxTabPage& rPage ) ( (SvxParaAlignTabPage&)rPage ).EnableJustifyExt(); break; case RID_SVXPAGE_BACKGROUND : - ( (SvxBackgroundTabPage&)rPage ).ShowParaControl(TRUE); + ( (SvxBackgroundTabPage&)rPage ).ShowParaControl(sal_True); break; } } @@ -134,7 +134,7 @@ void SvxSearchFormatDialog::PageCreated( USHORT nId, SfxTabPage& rPage ) SvxSearchAttributeDialog::SvxSearchAttributeDialog( Window* pParent, SearchAttrItemList& rLst, - const USHORT* pWhRanges ) : + const sal_uInt16* pWhRanges ) : ModalDialog( pParent, CUI_RES( RID_SVXDLG_SEARCHATTR ) ), @@ -149,7 +149,7 @@ SvxSearchAttributeDialog::SvxSearchAttributeDialog( Window* pParent, { FreeResource(); - aAttrLB.SetWindowBits( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); + aAttrLB.SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_SORT ); aAttrLB.GetModel()->SetSortMode( SortAscending ); aOKBtn.SetClickHdl( LINK( this, SvxSearchAttributeDialog, OKHdl ) ); @@ -161,21 +161,21 @@ SvxSearchAttributeDialog::SvxSearchAttributeDialog( Window* pParent, SfxItemPool& rPool = pSh->GetPool(); SfxItemSet aSet( rPool, pWhRanges ); SfxWhichIter aIter( aSet ); - USHORT nWhich = aIter.FirstWhich(); + sal_uInt16 nWhich = aIter.FirstWhich(); while ( nWhich ) { - USHORT nSlot = rPool.GetSlotId( nWhich ); + sal_uInt16 nSlot = rPool.GetSlotId( nWhich ); if ( nSlot >= SID_SVX_START ) { - BOOL bChecked = FALSE, bFound = FALSE; - for ( USHORT i = 0; !bFound && i < rList.Count(); ++i ) + sal_Bool bChecked = sal_False, bFound = sal_False; + for ( sal_uInt16 i = 0; !bFound && i < rList.Count(); ++i ) { if ( nSlot == rList[i].nSlot ) { - bFound = TRUE; + bFound = sal_True; if ( IsInvalidItem( rList[i].pItem ) ) - bChecked = TRUE; + bChecked = sal_True; } } @@ -194,7 +194,7 @@ SvxSearchAttributeDialog::SvxSearchAttributeDialog( Window* pParent, if ( pEntry ) { aAttrLB.SetCheckButtonState( pEntry, bChecked ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED ); - pEntry->SetUserData( (void*)(ULONG)nSlot ); + pEntry->SetUserData( (void*)(sal_uLong)nSlot ); } } nWhich = aIter.NextWhich(); @@ -211,12 +211,12 @@ IMPL_LINK( SvxSearchAttributeDialog, OKHdl, Button *, EMPTYARG ) SearchAttrItem aInvalidItem; aInvalidItem.pItem = (SfxPoolItem*)-1; - for ( USHORT i = 0; i < aAttrLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aAttrLB.GetEntryCount(); ++i ) { - USHORT nSlot = (USHORT)(ULONG)aAttrLB.GetEntryData(i); - BOOL bChecked = aAttrLB.IsChecked(i); + sal_uInt16 nSlot = (sal_uInt16)(sal_uLong)aAttrLB.GetEntryData(i); + sal_Bool bChecked = aAttrLB.IsChecked(i); - USHORT j; + sal_uInt16 j; for ( j = rList.Count(); j; ) { SearchAttrItem& rItem = rList[ --j ]; @@ -243,7 +243,7 @@ IMPL_LINK( SvxSearchAttributeDialog, OKHdl, Button *, EMPTYARG ) } // remove invalid items (pItem == NULL) - for ( USHORT n = rList.Count(); n; ) + for ( sal_uInt16 n = rList.Count(); n; ) if ( !rList[ --n ].pItem ) rList.Remove( n ); @@ -256,10 +256,10 @@ IMPL_LINK( SvxSearchAttributeDialog, OKHdl, Button *, EMPTYARG ) SvxSearchSimilarityDialog::SvxSearchSimilarityDialog ( Window* pParent, - BOOL bRelax, - USHORT nOther, - USHORT nShorter, - USHORT nLonger + sal_Bool bRelax, + sal_uInt16 nOther, + sal_uInt16 nShorter, + sal_uInt16 nLonger ) : ModalDialog( pParent, CUI_RES( RID_SVXDLG_SEARCHSIMILARITY ) ), diff --git a/cui/source/dialogs/srchxtra.src b/cui/source/dialogs/srchxtra.src index 04265a6d6726..8131b4e68a81 100644 --- a/cui/source/dialogs/srchxtra.src +++ b/cui/source/dialogs/srchxtra.src @@ -148,6 +148,7 @@ ModalDialog RID_SVXDLG_SEARCHSIMILARITY }; NumericField NF_OTHER { + HelpID = "cui:NumericField:RID_SVXDLG_SEARCHSIMILARITY:NF_OTHER"; Pos = MAP_APPFONT ( 86 , 14 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; Border = TRUE ; @@ -169,6 +170,7 @@ ModalDialog RID_SVXDLG_SEARCHSIMILARITY }; NumericField NF_LONGER { + HelpID = "cui:NumericField:RID_SVXDLG_SEARCHSIMILARITY:NF_LONGER"; Pos = MAP_APPFONT ( 86 , 28 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; Border = TRUE ; @@ -190,6 +192,7 @@ ModalDialog RID_SVXDLG_SEARCHSIMILARITY }; NumericField NF_SHORTER { + HelpID = "cui:NumericField:RID_SVXDLG_SEARCHSIMILARITY:NF_SHORTER"; Pos = MAP_APPFONT ( 86 , 44 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; Border = TRUE ; @@ -205,6 +208,7 @@ ModalDialog RID_SVXDLG_SEARCHSIMILARITY }; CheckBox CB_RELAX { + HelpID = "cui:CheckBox:RID_SVXDLG_SEARCHSIMILARITY:CB_RELAX"; Pos = MAP_APPFONT ( 12 , 60 ) ; Size = MAP_APPFONT ( 98 , 10 ) ; Text [ en-US ] = "~Combine" ; diff --git a/cui/source/dialogs/svuidlg.src b/cui/source/dialogs/svuidlg.src index 6a943a3530f2..7fe0fc886455 100644 --- a/cui/source/dialogs/svuidlg.src +++ b/cui/source/dialogs/svuidlg.src @@ -30,6 +30,7 @@ ModalDialog MD_PASTE_OBJECT { + HelpID = "cui:ModalDialog:MD_PASTE_OBJECT"; OutputSize = TRUE ; SVLook = TRUE ; Moveable = TRUE ; @@ -49,6 +50,7 @@ ModalDialog MD_PASTE_OBJECT }; RadioButton RB_PASTE { + HelpID = "cui:RadioButton:MD_PASTE_OBJECT:RB_PASTE"; Hide = TRUE ; Pos = MAP_APPFONT ( 12 , 48 ) ; Size = MAP_APPFONT ( 63 , 10 ) ; @@ -57,6 +59,7 @@ ModalDialog MD_PASTE_OBJECT }; RadioButton RB_PASTE_LINK { + HelpID = "cui:RadioButton:MD_PASTE_OBJECT:RB_PASTE_LINK"; Hide = TRUE ; Pos = MAP_APPFONT ( 78 , 48 ) ; Size = MAP_APPFONT ( 63 , 10 ) ; @@ -64,12 +67,14 @@ ModalDialog MD_PASTE_OBJECT }; ListBox LB_INSERT_LIST { + HelpID = "cui:ListBox:MD_PASTE_OBJECT:LB_INSERT_LIST"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 49 ) ; Size = MAP_APPFONT ( 202 , 74 ) ; }; CheckBox CB_DISPLAY_AS_ICON { + HelpID = "cui:CheckBox:MD_PASTE_OBJECT:CB_DISPLAY_AS_ICON"; Hide = TRUE ; Disable = TRUE ; Pos = MAP_APPFONT ( 150 , 62 ) ; @@ -78,6 +83,7 @@ ModalDialog MD_PASTE_OBJECT }; PushButton PB_CHANGE_ICON { + HelpID = "cui:PushButton:MD_PASTE_OBJECT:PB_CHANGE_ICON"; Hide = TRUE ; Pos = MAP_APPFONT ( 150 , 111 ) ; Size = MAP_APPFONT ( 64 , 14 ) ; @@ -112,6 +118,7 @@ ModalDialog MD_PASTE_OBJECT }; ModalDialog MD_UPDATE_BASELINKS { + HelpID = "cui:ModalDialog:MD_UPDATE_BASELINKS"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 337 , 166 ) ; @@ -154,24 +161,28 @@ ModalDialog MD_UPDATE_BASELINKS }; PushButton PB_UPDATE_NOW { + HelpID = "cui:PushButton:MD_UPDATE_BASELINKS:PB_UPDATE_NOW"; Pos = MAP_APPFONT ( 270 , 43 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Update" ; }; PushButton PB_OPEN_SOURCE { + HelpID = "cui:PushButton:MD_UPDATE_BASELINKS:PB_OPEN_SOURCE"; Pos = MAP_APPFONT ( 270 , 60 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Open" ; }; PushButton PB_CHANGE_SOURCE { + HelpID = "cui:PushButton:MD_UPDATE_BASELINKS:PB_CHANGE_SOURCE"; Pos = MAP_APPFONT ( 270 , 77 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Modify..." ; }; PushButton PB_BREAK_LINK { + HelpID = "cui:PushButton:MD_UPDATE_BASELINKS:PB_BREAK_LINK"; Pos = MAP_APPFONT ( 270 , 94 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Break Link" ; @@ -202,12 +213,14 @@ ModalDialog MD_UPDATE_BASELINKS }; RadioButton RB_AUTOMATIC { + HelpID = "cui:RadioButton:MD_UPDATE_BASELINKS:RB_AUTOMATIC"; Pos = MAP_APPFONT ( 70 , 150 ) ; Size = MAP_APPFONT ( 60 , 10 ) ; Text [ en-US ] = "~Automatic" ; }; RadioButton RB_MANUAL { + HelpID = "cui:RadioButton:MD_UPDATE_BASELINKS:RB_MANUAL"; Pos = MAP_APPFONT ( 133 , 150 ) ; Size = MAP_APPFONT ( 60 , 10 ) ; Text [ en-US ] = "Ma~nual" ; @@ -262,6 +275,7 @@ ModalDialog MD_UPDATE_BASELINKS }; ModalDialog MD_LINKEDIT { + HelpID = "cui:ModalDialog:MD_LINKEDIT"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 222 , 58 ) ; @@ -293,6 +307,7 @@ ModalDialog MD_LINKEDIT }; Edit ED_FULL_SOURCE_NAME { + HelpID = "cui:Edit:MD_LINKEDIT:ED_FULL_SOURCE_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 5 , 35 ) ; Size = MAP_APPFONT ( 155 , 12 ) ; @@ -301,42 +316,49 @@ ModalDialog MD_LINKEDIT }; ModalDialog MD_INSERT_OLEOBJECT { + HelpID = "cui:ModalDialog:MD_INSERT_OLEOBJECT"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 284 , 105 ) ; Moveable = TRUE ; RadioButton RB_NEW_OBJECT { + HelpID = "cui:RadioButton:MD_INSERT_OLEOBJECT:RB_NEW_OBJECT"; Pos = MAP_APPFONT ( 6 , 6 ) ; Size = MAP_APPFONT ( 81 , 10 ) ; Text [ en-US ] = "~Create new" ; }; RadioButton RB_OBJECT_FROMFILE { + HelpID = "cui:RadioButton:MD_INSERT_OLEOBJECT:RB_OBJECT_FROMFILE"; Pos = MAP_APPFONT ( 90 , 6 ) ; Size = MAP_APPFONT ( 81 , 10 ) ; Text [ en-US ] = "Create from ~file" ; }; ListBox LB_OBJECTTYPE { + HelpID = "cui:ListBox:MD_INSERT_OLEOBJECT:LB_OBJECTTYPE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 33 ) ; Size = MAP_APPFONT ( 204 , 60 ) ; }; Edit ED_FILEPATH { + HelpID = "cui:Edit:MD_INSERT_OLEOBJECT:ED_FILEPATH"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 33 ) ; Size = MAP_APPFONT ( 204 , 12 ) ; }; PushButton BTN_FILEPATH { + HelpID = "cui:PushButton:MD_INSERT_OLEOBJECT:BTN_FILEPATH"; Pos = MAP_APPFONT ( 166 , 48 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Search..." ; }; CheckBox CB_FILELINK { + HelpID = "cui:CheckBox:MD_INSERT_OLEOBJECT:CB_FILELINK"; Pos = MAP_APPFONT ( 12 , 48 ) ; Size = MAP_APPFONT ( 138 , 10 ) ; Text [ en-US ] = "~Link to file" ; @@ -374,18 +396,21 @@ ModalDialog MD_INSERT_OLEOBJECT }; ModalDialog MD_INSERT_OBJECT_PLUGIN { + HelpID = "cui:ModalDialog:MD_INSERT_OBJECT_PLUGIN"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 284 , 123 ) ; Moveable = TRUE ; Edit ED_FILEURL { + HelpID = "cui:Edit:MD_INSERT_OBJECT_PLUGIN:ED_FILEURL"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 204 , 12 ) ; }; PushButton BTN_FILEURL { + HelpID = "cui:PushButton:MD_INSERT_OBJECT_PLUGIN:BTN_FILEURL"; Pos = MAP_APPFONT ( 166 , 29 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Browse..." ; @@ -398,6 +423,7 @@ ModalDialog MD_INSERT_OBJECT_PLUGIN }; MultiLineEdit ED_PLUGINS_OPTIONS { + HelpID = "cui:MultiLineEdit:MD_INSERT_OBJECT_PLUGIN:ED_PLUGINS_OPTIONS"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 66 ) ; Size = MAP_APPFONT ( 204 , 45 ) ; @@ -430,6 +456,7 @@ ModalDialog MD_INSERT_OBJECT_PLUGIN }; ModalDialog MD_INSERT_OBJECT_APPLET { + HelpID = "cui:ModalDialog:MD_INSERT_OBJECT_APPLET"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 284 , 164 ) ; @@ -442,6 +469,7 @@ ModalDialog MD_INSERT_OBJECT_APPLET }; Edit ED_CLASSFILE { + HelpID = "cui:Edit:MD_INSERT_OBJECT_APPLET:ED_CLASSFILE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 27 ) ; Size = MAP_APPFONT ( 204 , 12 ) ; @@ -454,12 +482,14 @@ ModalDialog MD_INSERT_OBJECT_APPLET }; Edit ED_CLASSLOCATION { + HelpID = "cui:Edit:MD_INSERT_OBJECT_APPLET:ED_CLASSLOCATION"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 55 ) ; Size = MAP_APPFONT ( 204 , 12 ) ; }; PushButton BTN_CLASS { + HelpID = "cui:PushButton:MD_INSERT_OBJECT_APPLET:BTN_CLASS"; Pos = MAP_APPFONT ( 166 , 70 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Search..." ; @@ -472,6 +502,7 @@ ModalDialog MD_INSERT_OBJECT_APPLET }; MultiLineEdit ED_APPLET_OPTIONS { + HelpID = "cui:MultiLineEdit:MD_INSERT_OBJECT_APPLET:ED_APPLET_OPTIONS"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 107 ) ; Size = MAP_APPFONT ( 204 , 45 ) ; @@ -513,6 +544,7 @@ Control TB_LINKS ModalDialog MD_INSERT_OBJECT_IFRAME { + HelpID = "cui:ModalDialog:MD_INSERT_OBJECT_IFRAME"; Size = MAP_APPFONT ( 302 , 98 ) ; Hide = TRUE ; Moveable = TRUE ; @@ -543,6 +575,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; Edit ED_FRAMENAME { + HelpID = "cui:Edit:MD_INSERT_OBJECT_IFRAME:ED_FRAMENAME"; Border = TRUE ; Pos = MAP_APPFONT ( 45 , 6 ) ; Size = MAP_APPFONT ( 178 , 12 ) ; @@ -556,6 +589,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; Edit ED_URL { + HelpID = "cui:Edit:MD_INSERT_OBJECT_IFRAME:ED_URL"; Border = TRUE ; Pos = MAP_APPFONT ( 45 , 24 ) ; Size = MAP_APPFONT ( 178 , 12 ) ; @@ -563,6 +597,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; PushButton BT_FILEOPEN { + HelpID = "cui:PushButton:MD_INSERT_OBJECT_IFRAME:BT_FILEOPEN"; Pos = MAP_APPFONT ( 226 , 24 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; Text = "~..." ; @@ -570,6 +605,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; RadioButton RB_SCROLLINGON { + HelpID = "cui:RadioButton:MD_INSERT_OBJECT_IFRAME:RB_SCROLLINGON"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 53 ) ; Size = MAP_APPFONT ( 54 , 10 ) ; @@ -577,6 +613,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; RadioButton RB_SCROLLINGOFF { + HelpID = "cui:RadioButton:MD_INSERT_OBJECT_IFRAME:RB_SCROLLINGOFF"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 66 ) ; Size = MAP_APPFONT ( 54 , 10 ) ; @@ -584,6 +621,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; RadioButton RB_SCROLLINGAUTO { + HelpID = "cui:RadioButton:MD_INSERT_OBJECT_IFRAME:RB_SCROLLINGAUTO"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 79 ) ; Size = MAP_APPFONT ( 54 , 10 ) ; @@ -597,6 +635,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; RadioButton RB_FRMBORDER_ON { + HelpID = "cui:RadioButton:MD_INSERT_OBJECT_IFRAME:RB_FRMBORDER_ON"; TabStop = TRUE ; Pos = MAP_APPFONT ( 81 , 53 ) ; Size = MAP_APPFONT ( 42 , 10 ) ; @@ -604,6 +643,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; RadioButton RB_FRMBORDER_OFF { + HelpID = "cui:RadioButton:MD_INSERT_OBJECT_IFRAME:RB_FRMBORDER_OFF"; TabStop = TRUE ; Pos = MAP_APPFONT ( 81 , 66 ) ; Size = MAP_APPFONT ( 42 , 10 ) ; @@ -628,6 +668,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; NumericField NM_MARGINWIDTH { + HelpID = "cui:NumericField:MD_INSERT_OBJECT_IFRAME:NM_MARGINWIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 167 , 54 ) ; Size = MAP_APPFONT ( 20 , 12 ) ; @@ -641,6 +682,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; CheckBox CB_MARGINWIDTHDEFAULT { + HelpID = "cui:CheckBox:MD_INSERT_OBJECT_IFRAME:CB_MARGINWIDTHDEFAULT"; TabStop = TRUE ; Pos = MAP_APPFONT ( 190 , 56 ) ; Size = MAP_APPFONT ( 50 , 10 ) ; @@ -654,6 +696,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; NumericField NM_MARGINHEIGHT { + HelpID = "cui:NumericField:MD_INSERT_OBJECT_IFRAME:NM_MARGINHEIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 167 , 72 ) ; Size = MAP_APPFONT ( 20 , 12 ) ; @@ -667,6 +710,7 @@ ModalDialog MD_INSERT_OBJECT_IFRAME }; CheckBox CB_MARGINHEIGHTDEFAULT { + HelpID = "cui:CheckBox:MD_INSERT_OBJECT_IFRAME:CB_MARGINHEIGHTDEFAULT"; TabStop = TRUE ; Pos = MAP_APPFONT ( 190 , 74 ) ; Size = MAP_APPFONT ( 50 , 10 ) ; diff --git a/cui/source/dialogs/tbxform.src b/cui/source/dialogs/tbxform.src index 9e9d2fb6eb03..4d6b96445115 100644 --- a/cui/source/dialogs/tbxform.src +++ b/cui/source/dialogs/tbxform.src @@ -28,6 +28,7 @@ ModalDialog RID_SVX_DLG_INPUTRECORDNO { + HelpID = "cui:ModalDialog:RID_SVX_DLG_INPUTRECORDNO"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 130 , 45 ) ; @@ -43,6 +44,7 @@ ModalDialog RID_SVX_DLG_INPUTRECORDNO }; NumericField 1 { + HelpID = "cui:NumericField:RID_SVX_DLG_INPUTRECORDNO:1"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 6 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; diff --git a/cui/source/dialogs/thesdlg.cxx b/cui/source/dialogs/thesdlg.cxx index 6c28969d43f8..ddd77621f322 100644 --- a/cui/source/dialogs/thesdlg.cxx +++ b/cui/source/dialogs/thesdlg.cxx @@ -51,6 +51,7 @@ #include <i18npool/mslangid.hxx> #include <comphelper/processfactory.hxx> #include <osl/file.hxx> +#include <svl/lngmisc.hxx> #include <stack> #include <algorithm> @@ -64,35 +65,6 @@ using ::rtl::OUString; #define A2S(x) String::CreateFromAscii( x ) -// GetReplaceEditString ------------------------------- - -static void GetReplaceEditString( String &rText ) -{ - // The strings returned by the thesaurus saometimes have some - // explanation text put in between '(' and ')' or a trailing '*'. - // These parts should not be put in the ReplaceEdit Text that may get - // inserted into the document. Thus we strip them from the text. - - xub_StrLen nPos = rText.Search( sal_Unicode('(') ); - while (STRING_NOTFOUND != nPos) - { - xub_StrLen nEnd = rText.Search( sal_Unicode(')'), nPos ); - if (STRING_NOTFOUND != nEnd) - rText.Erase( nPos, nEnd-nPos+1 ); - else - break; - nPos = rText.Search( sal_Unicode('(') ); - } - - nPos = rText.Search( sal_Unicode('*') ); - if (STRING_NOTFOUND != nPos) - rText.Erase( nPos ); - - // remove any possible remaining ' ' that may confuse the thesaurus - // when it gets called with the text - rText.EraseLeadingAndTrailingChars( sal_Unicode(' ') ); -} - // class LookUpComboBox_Impl -------------------------------------------------- LookUpComboBox_Impl::LookUpComboBox_Impl( @@ -103,7 +75,7 @@ LookUpComboBox_Impl::LookUpComboBox_Impl( m_aModifyTimer.SetTimeoutHdl( LINK( this, LookUpComboBox_Impl, ModifyTimer_Hdl ) ); m_aModifyTimer.SetTimeout( 500 ); - EnableAutocomplete( FALSE ); + EnableAutocomplete( sal_False ); } LookUpComboBox_Impl::~LookUpComboBox_Impl() @@ -156,7 +128,7 @@ void ReplaceEdit_Impl::SetText( const XubString& rStr, const Selection& rNewSele AlternativesString_Impl::AlternativesString_Impl( ThesaurusAlternativesCtrl_Impl &rControl, - SvLBoxEntry* pEntry, USHORT nFlags, const String& rStr ) : + SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr ) : SvLBoxString( pEntry, nFlags, rStr ), m_rControlImpl( rControl ) @@ -165,7 +137,7 @@ AlternativesString_Impl::AlternativesString_Impl( void AlternativesString_Impl::Paint( const Point& rPos, - SvLBox& rDev, USHORT, + SvLBox& rDev, sal_uInt16, SvLBoxEntry* pEntry ) { AlternativesExtraData* pData = m_rControlImpl.GetExtraData( pEntry ); @@ -190,7 +162,7 @@ ThesaurusAlternativesCtrl_Impl::ThesaurusAlternativesCtrl_Impl( SvxCheckListBox( pParent, CUI_RES( CT_THES_ALTERNATIVES ) ), m_rDialogImpl( rImpl ) { - SetWindowBits( WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE ); + SetStyle( GetStyle() | WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE ); SetHighlightRange(); } @@ -358,7 +330,7 @@ bool SvxThesaurusDialog_Impl::UpdateAlternativesBox_Impl() const sal_Int32 nMeanings = aMeanings.getLength(); const uno::Reference< linguistic2::XMeaning > *pMeanings = aMeanings.getConstArray(); - m_pAlternativesCT->SetUpdateMode( FALSE ); + m_pAlternativesCT->SetUpdateMode( sal_False ); // clear old user data of control before creating new ones via AddEntry below m_pAlternativesCT->ClearExtraData(); @@ -378,7 +350,7 @@ bool SvxThesaurusDialog_Impl::UpdateAlternativesBox_Impl() m_pAlternativesCT->AddEntry( -1, pSynonyms[k], false ); } - m_pAlternativesCT->SetUpdateMode( TRUE ); + m_pAlternativesCT->SetUpdateMode( sal_True ); return nMeanings > 0; } @@ -407,7 +379,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, LanguageHdl_Impl, MenuButton *, pBtn ) PopupMenu *pMenu = aLangMBtn.GetPopupMenu(); if (pMenu && pBtn) { - USHORT nItem = pBtn->GetCurItemId(); + sal_uInt16 nItem = pBtn->GetCurItemId(); String aLangText( pMenu->GetItemText( nItem ) ); LanguageType nLang = SvtLanguageTable().GetType( aLangText ); DBG_ASSERT( nLang != LANGUAGE_NONE && nLang != LANGUAGE_DONTKNOW, "failed to get language" ); @@ -443,9 +415,9 @@ IMPL_LINK( SvxThesaurusDialog_Impl, WordSelectHdl_Impl, ComboBox *, pBox ) { if (pBox && !aWordCB.IsTravelSelect()) // act only upon return key and not when traveling with cursor keys { - USHORT nPos = pBox->GetSelectEntryPos(); + sal_uInt16 nPos = pBox->GetSelectEntryPos(); String aStr( pBox->GetEntry( nPos ) ); - GetReplaceEditString( aStr ); + aStr = linguistic::GetThesaurusReplaceText( aStr ); aWordCB.SetText( aStr ); LookUp_Impl(); } @@ -463,7 +435,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, AlternativesSelectHdl_Impl, SvxCheckListBox if (pData && !pData->IsHeader()) { aStr = pData->GetText(); - GetReplaceEditString( aStr ); + aStr = linguistic::GetThesaurusReplaceText( aStr ); } aReplaceEdit.SetText( aStr ); } @@ -480,7 +452,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, AlternativesDoubleClickHdl_Impl, SvxCheckLis if (pData && !pData->IsHeader()) { aStr = pData->GetText(); - GetReplaceEditString( aStr ); + aStr = linguistic::GetThesaurusReplaceText( aStr ); } aWordCB.SetText( aStr ); @@ -680,7 +652,7 @@ SvxThesaurusDialog::SvxThesaurusDialog( } std::sort( aLangVec.begin(), aLangVec.end() ); for (size_t i = 0; i < aLangVec.size(); ++i) - pMenu->InsertItem( (USHORT)i+1, aLangVec[i] ); // menu items should be enumerated from 1 and not 0 + pMenu->InsertItem( (sal_uInt16)i+1, aLangVec[i] ); // menu items should be enumerated from 1 and not 0 m_pImpl->aLangMBtn.SetPopupMenu( pMenu ); SetWindowTitle( nLanguage ); diff --git a/cui/source/dialogs/thesdlg.hrc b/cui/source/dialogs/thesdlg.hrc index aef4131db3e6..aef4131db3e6 100755..100644 --- a/cui/source/dialogs/thesdlg.hrc +++ b/cui/source/dialogs/thesdlg.hrc diff --git a/cui/source/dialogs/thesdlg.src b/cui/source/dialogs/thesdlg.src index ca0f69c4ef2a..67fdced0f137 100755..100644 --- a/cui/source/dialogs/thesdlg.src +++ b/cui/source/dialogs/thesdlg.src @@ -34,7 +34,7 @@ // RID_SVXDLG_THES ------------------------------------------------------- ModalDialog RID_SVXDLG_THESAURUS { - HelpId = SID_THESAURUS ; + HelpId = CMD_SID_THESAURUS ; OutputSize = TRUE ; Size = MAP_APPFONT ( 235, 230 ) ; Text [ en-US ] = "Thesaurus" ; @@ -50,6 +50,7 @@ ModalDialog RID_SVXDLG_THESAURUS ImageButton BTN_LEFT { + HelpID = "cui:ImageButton:RID_SVXDLG_THESAURUS:BTN_LEFT"; Pos = MAP_APPFONT ( 5 , 15 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; TABSTOP = TRUE ; @@ -64,12 +65,14 @@ ModalDialog RID_SVXDLG_THESAURUS }; ComboBox CB_WORD { + HelpID = "cui:ComboBox:RID_SVXDLG_THESAURUS:CB_WORD"; DropDown = TRUE ; Pos = MAP_APPFONT ( 24 , 16 ) ; Size = MAP_APPFONT ( 141 , 60 ) ; // have drop down space for several lines }; MenuButton MB_LANGUAGE { + HelpID = "cui:MenuButton:RID_SVXDLG_THESAURUS:MB_LANGUAGE"; Pos = MAP_APPFONT ( 170 , 16 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Language" ; @@ -100,6 +103,7 @@ ModalDialog RID_SVXDLG_THESAURUS }; Edit ED_REPL { + HelpID = "cui:Edit:RID_SVXDLG_THESAURUS:ED_REPL"; BORDER = TRUE ; Pos = MAP_APPFONT ( 5 , 184 ) ; Size = MAP_APPFONT ( 225 , 12 ) ; diff --git a/cui/source/dialogs/thesdlg_impl.hxx b/cui/source/dialogs/thesdlg_impl.hxx index d3b58ba31d1f..678b1257bf5f 100644 --- a/cui/source/dialogs/thesdlg_impl.hxx +++ b/cui/source/dialogs/thesdlg_impl.hxx @@ -132,9 +132,9 @@ class AlternativesString_Impl : public SvLBoxString public: AlternativesString_Impl( ThesaurusAlternativesCtrl_Impl &rControl, - SvLBoxEntry* pEntry, USHORT nFlags, const String& rStr ); + SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr ); - virtual void Paint( const Point& rPos, SvLBox& rDev, USHORT nFlags, SvLBoxEntry* pEntry); + virtual void Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry); }; diff --git a/cui/source/dialogs/zoom.cxx b/cui/source/dialogs/zoom.cxx index 42eda26ff2ff..89d0fa9f7483 100644 --- a/cui/source/dialogs/zoom.cxx +++ b/cui/source/dialogs/zoom.cxx @@ -56,30 +56,23 @@ // static ---------------------------------------------------------------- -static USHORT pRanges[] = -{ - SID_ATTR_ZOOM, - SID_ATTR_ZOOM, - 0 -}; - -#define SPECIAL_FACTOR ((USHORT)0xFFFF) +#define SPECIAL_FACTOR ((sal_uInt16)0xFFFF) // class SvxZoomDialog --------------------------------------------------- -USHORT SvxZoomDialog::GetFactor() const +sal_uInt16 SvxZoomDialog::GetFactor() const { if ( a100Btn.IsChecked() ) return 100; if ( aUserBtn.IsChecked() ) - return (USHORT)aUserEdit.GetValue(); + return (sal_uInt16)aUserEdit.GetValue(); else return SPECIAL_FACTOR; } // ----------------------------------------------------------------------- -void SvxZoomDialog::SetFactor( USHORT nNewFactor, USHORT nBtnId ) +void SvxZoomDialog::SetFactor( sal_uInt16 nNewFactor, sal_uInt16 nBtnId ) { aUserEdit.Disable(); @@ -122,30 +115,7 @@ void SvxZoomDialog::SetFactor( USHORT nNewFactor, USHORT nBtnId ) // ----------------------------------------------------------------------- -void SvxZoomDialog::SetButtonText( USHORT nBtnId, const String& rNewTxt ) -{ - switch ( nBtnId ) - { - case ZOOMBTN_OPTIMAL: // Optimal-Button - aOptimalBtn.SetText( rNewTxt ); - break; - - case ZOOMBTN_PAGEWIDTH: // Seitenbreite-Button - aPageWidthBtn.SetText( rNewTxt ); - break; - - case ZOOMBTN_WHOLEPAGE: // Ganze Seite-Button - aWholePageBtn.SetText( rNewTxt ); - break; - - default: - OSL_FAIL( "wrong button number" ); - } -} - -// ----------------------------------------------------------------------- - -void SvxZoomDialog::HideButton( USHORT nBtnId ) +void SvxZoomDialog::HideButton( sal_uInt16 nBtnId ) { switch ( nBtnId ) { @@ -168,7 +138,7 @@ void SvxZoomDialog::HideButton( USHORT nBtnId ) // ----------------------------------------------------------------------- -void SvxZoomDialog::SetLimits( USHORT nMin, USHORT nMax ) +void SvxZoomDialog::SetLimits( sal_uInt16 nMin, sal_uInt16 nMax ) { DBG_ASSERT( nMin < nMax, "invalid limits" ); aUserEdit.SetMin( nMin ); @@ -179,13 +149,6 @@ void SvxZoomDialog::SetLimits( USHORT nMin, USHORT nMax ) // ----------------------------------------------------------------------- -void SvxZoomDialog::SetSpinSize( USHORT nNewSpin ) -{ - aUserEdit.SetSpinSize( nNewSpin ); -} - -// ----------------------------------------------------------------------- - SvxZoomDialog::SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ) : SfxModalDialog( pParent, CUI_RES( RID_SVXDLG_ZOOM ) ), @@ -212,11 +175,11 @@ SvxZoomDialog::SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ) : rSet ( rCoreSet ), pOutSet ( NULL ), - bModified ( FALSE ) + bModified ( sal_False ) { #if ENABLE_LAYOUT - SetHelpId (SID_ATTR_ZOOM); + SetHelpId (".uno:Zoom"); #endif /* ENABLE_LAYOUT */ Link aLink = LINK( this, SvxZoomDialog, UserHdl ); a100Btn.SetClickHdl( aLink ); @@ -240,9 +203,9 @@ SvxZoomDialog::SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ) : aUserEdit.SetModifyHdl( LINK( this, SvxZoomDialog, SpinHdl ) ); // Default-Werte - USHORT nValue = 100; - USHORT nMin = 10; - USHORT nMax = 1000; + sal_uInt16 nValue = 100; + sal_uInt16 nMin = 10; + sal_uInt16 nMax = 1000; // ggf. erst den alten Wert besorgen const SfxUInt16Item* pOldUserItem = 0; @@ -265,15 +228,23 @@ SvxZoomDialog::SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ) : aUserEdit.SetLast( nMax ); aUserEdit.SetValue( nValue ); + aUserEdit.SetAccessibleRelationLabeledBy( &aUserBtn ); + aUserEdit.SetAccessibleName(aUserBtn.GetText()); + aColumnsEdit.SetAccessibleRelationLabeledBy(&aColumnsBtn); + aColumnsEdit.SetAccessibleName(aColumnsBtn.GetText()); + aColumnsEdit.SetAccessibleRelationMemberOf(&aColumnsBtn); + aBookModeChk.SetAccessibleRelationLabeledBy(&aColumnsBtn); + aBookModeChk.SetAccessibleRelationMemberOf(&aColumnsBtn); + const SfxPoolItem& rItem = rSet.Get( rSet.GetPool()->GetWhich( SID_ATTR_ZOOM ) ); if ( rItem.ISA(SvxZoomItem) ) { const SvxZoomItem& rZoomItem = (const SvxZoomItem&)rItem; - const USHORT nZoom = rZoomItem.GetValue(); + const sal_uInt16 nZoom = rZoomItem.GetValue(); const SvxZoomType eType = rZoomItem.GetType(); - const USHORT nValSet = rZoomItem.GetValueSet(); - USHORT nBtnId = 0; + const sal_uInt16 nValSet = rZoomItem.GetValueSet(); + sal_uInt16 nBtnId = 0; switch ( eType ) { @@ -304,14 +275,14 @@ SvxZoomDialog::SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ) : } else { - const USHORT nZoom = ( (const SfxUInt16Item&)rItem ).GetValue(); + const sal_uInt16 nZoom = ( (const SfxUInt16Item&)rItem ).GetValue(); SetFactor( nZoom ); } const SfxPoolItem* pViewLayoutItem = 0; - if ( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_VIEWLAYOUT, FALSE, &pViewLayoutItem ) ) + if ( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_VIEWLAYOUT, sal_False, &pViewLayoutItem ) ) { - const USHORT nColumns = static_cast<const SvxViewLayoutItem*>(pViewLayoutItem)->GetValue(); + const sal_uInt16 nColumns = static_cast<const SvxViewLayoutItem*>(pViewLayoutItem)->GetValue(); const bool bBookMode = static_cast<const SvxViewLayoutItem*>(pViewLayoutItem)->IsBookMode(); if ( 0 == nColumns ) @@ -368,16 +339,9 @@ SvxZoomDialog::~SvxZoomDialog() // ----------------------------------------------------------------------- -USHORT* SvxZoomDialog::GetRanges() -{ - return pRanges; -} - -// ----------------------------------------------------------------------- - IMPL_LINK( SvxZoomDialog, UserHdl, RadioButton *, pBtn ) { - bModified |= TRUE; + bModified |= sal_True; if ( pBtn == &aUserBtn ) { @@ -395,7 +359,7 @@ IMPL_LINK( SvxZoomDialog, SpinHdl, MetricField *, EMPTYARG ) { if ( !aUserBtn.IsChecked() ) return 0; - bModified |= TRUE; + bModified |= sal_True; return 0; } @@ -403,7 +367,7 @@ IMPL_LINK( SvxZoomDialog, SpinHdl, MetricField *, EMPTYARG ) IMPL_LINK( SvxZoomDialog, ViewLayoutUserHdl, RadioButton *, pBtn ) { - bModified |= TRUE; + bModified |= sal_True; if ( pBtn == &aAutomaticBtn ) { @@ -446,7 +410,7 @@ IMPL_LINK( SvxZoomDialog, ViewLayoutSpinHdl, MetricField *, pEdt ) aBookModeChk.Disable(); } - bModified |= TRUE; + bModified |= sal_True; return 0; } @@ -458,7 +422,7 @@ IMPL_LINK( SvxZoomDialog, ViewLayoutCheckHdl, CheckBox *, pChk ) if ( pChk == &aBookModeChk && !aColumnsBtn.IsChecked() ) return 0; - bModified |= TRUE; + bModified |= sal_True; return 0; } @@ -474,7 +438,7 @@ IMPL_LINK( SvxZoomDialog, OKHdl, Button *, pBtn ) if ( &aOKBtn == pBtn ) { - USHORT nFactor = GetFactor(); + sal_uInt16 nFactor = GetFactor(); if ( SPECIAL_FACTOR == nFactor ) { @@ -500,7 +464,7 @@ IMPL_LINK( SvxZoomDialog, OKHdl, Button *, pBtn ) } else if ( aColumnsBtn.IsChecked() ) { - aViewLayoutItem.SetValue( static_cast<USHORT>(aColumnsEdit.GetValue()) ); + aViewLayoutItem.SetValue( static_cast<sal_uInt16>(aColumnsEdit.GetValue()) ); aViewLayoutItem.SetBookMode( aBookModeChk.IsChecked() ); } } @@ -521,7 +485,7 @@ IMPL_LINK( SvxZoomDialog, OKHdl, Button *, pBtn ) if ( pSh ) pSh->PutItem( SfxUInt16Item( SID_ATTR_ZOOM_USER, - (UINT16)aUserEdit.GetValue() ) ); + (sal_uInt16)aUserEdit.GetValue() ) ); EndDialog( RET_OK ); } else diff --git a/cui/source/dialogs/zoom.src b/cui/source/dialogs/zoom.src index 67ca4ad3b957..f96323a36255 100644 --- a/cui/source/dialogs/zoom.src +++ b/cui/source/dialogs/zoom.src @@ -28,11 +28,12 @@ #include <cuires.hrc> #include "zoom.hrc" #include <svx/dialogs.hrc> // for RID_SVXDLG_ZOOM +#include "helpid.hrc" // RID_SVXDLG_ZOOM ------------------------------------------------------- ModalDialog RID_SVXDLG_ZOOM { - HelpId = SID_ATTR_ZOOM ; + HelpId = CMD_SID_ATTR_ZOOM; OutputSize = TRUE ; SvLook = TRUE ; Size = MAP_APPFONT ( 242 , 112 ) ; @@ -46,36 +47,42 @@ ModalDialog RID_SVXDLG_ZOOM }; RadioButton BTN_OPTIMAL { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_OPTIMAL"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 105 , 10 ) ; Text [ en-US ] = "~Optimal" ; }; RadioButton BTN_WHOLE_PAGE { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_WHOLE_PAGE"; Pos = MAP_APPFONT ( 12 , 27 ) ; Size = MAP_APPFONT ( 105 , 10 ) ; Text [ en-US ] = "~Fit width and height" ; }; RadioButton BTN_PAGE_WIDTH { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_PAGE_WIDTH"; Pos = MAP_APPFONT ( 12 , 40 ) ; Size = MAP_APPFONT ( 105, 10 ) ; Text [ en-US ] = "Fit ~width" ; }; RadioButton BTN_100 { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_100"; Pos = MAP_APPFONT ( 12 , 53 ) ; Size = MAP_APPFONT ( 105, 10 ) ; Text = "~100 %" ; }; RadioButton BTN_USER { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_USER"; Pos = MAP_APPFONT ( 12 , 67 ) ; Size = MAP_APPFONT ( 72 , 10 ) ; Text [ en-US ] = "~Variable" ; }; MetricField ED_USER { + HelpID = "cui:MetricField:RID_SVXDLG_ZOOM:ED_USER"; Pos = MAP_APPFONT ( 86 , 66 ) ; Size = MAP_APPFONT ( 32 , 12 ) ; Border = TRUE ; @@ -95,24 +102,28 @@ ModalDialog RID_SVXDLG_ZOOM }; RadioButton BTN_AUTOMATIC { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_AUTOMATIC"; Pos = MAP_APPFONT ( 130 , 14 ) ; Size = MAP_APPFONT ( 106 , 10 ) ; Text [ en-US ] = "~Automatic" ; }; RadioButton BTN_SINGLE { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_SINGLE"; Pos = MAP_APPFONT ( 130, 27 ) ; Size = MAP_APPFONT ( 106, 10 ) ; Text [ en-US ] = "~Single page" ; }; RadioButton BTN_COLUMNS { + HelpID = "cui:RadioButton:RID_SVXDLG_ZOOM:BTN_COLUMNS"; Pos = MAP_APPFONT ( 130, 41 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; Text [ en-US ] = "~Columns" ; }; MetricField ED_COLUMNS { + HelpID = "cui:MetricField:RID_SVXDLG_ZOOM:ED_COLUMNS"; Pos = MAP_APPFONT ( 209 , 40 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; Border = TRUE ; @@ -126,6 +137,7 @@ ModalDialog RID_SVXDLG_ZOOM }; CheckBox CHK_BOOK { + HelpID = "cui:CheckBox:RID_SVXDLG_ZOOM:CHK_BOOK"; Pos = MAP_APPFONT ( 136 , 55 ) ; Size = MAP_APPFONT ( 85 , 10 ) ; Text [ en-US ] = "~Book mode" ; diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx index 31cba6a36898..49163e6034fc 100644 --- a/cui/source/factory/dlgfact.cxx +++ b/cui/source/factory/dlgfact.cxx @@ -101,6 +101,8 @@ #include "passwdomdlg.hxx" #include "hyphen.hxx" #include "thesdlg.hxx" +#include "about.hxx" +#include "dialmgr.hxx" using namespace ::com::sun::star; using namespace ::com::sun::star::frame; @@ -201,7 +203,7 @@ IMPL_LINK( VclAbstractDialog2_Impl, EndDialogHdl, Dialog*, pDlg ) ////////////////////////////////////////////////////////////////////////// -void AbstractTabDialog_Impl::SetCurPageId( USHORT nId ) +void AbstractTabDialog_Impl::SetCurPageId( sal_uInt16 nId ) { pDlg->SetCurPageId( nId ); } @@ -211,7 +213,7 @@ const SfxItemSet* AbstractTabDialog_Impl::GetOutputItemSet() const return pDlg->GetOutputItemSet(); } -const USHORT* AbstractTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) +const sal_uInt16* AbstractTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) { return pDlg->GetInputRanges( pItem ); } @@ -391,7 +393,7 @@ Reference < com::sun::star::embed::XEmbeddedObject > AbstractInsertObjectDialog_ return pDlg->GetObject(); } -BOOL AbstractInsertObjectDialog_Impl::IsCreateNew() +sal_Bool AbstractInsertObjectDialog_Impl::IsCreateNew() { return pDlg->IsCreateNew(); } @@ -411,7 +413,7 @@ void AbstractPasteDialog_Impl::SetObjName( const SvGlobalName & rClass, const St pDlg->SetObjName( rClass, rObjName ); } -ULONG AbstractPasteDialog_Impl::GetFormat( const TransferableDataHelper& aHelper, +sal_uLong AbstractPasteDialog_Impl::GetFormat( const TransferableDataHelper& aHelper, const DataFlavorExVector* pFormats, const TransferableObjectDescriptor* pDesc ) { @@ -423,12 +425,12 @@ void AbstractFmShowColsDialog_Impl::SetColumns(const ::Reference< ::com::sun::s pDlg->SetColumns(xCols); } -void AbstractSvxZoomDialog_Impl::SetLimits( USHORT nMin, USHORT nMax ) +void AbstractSvxZoomDialog_Impl::SetLimits( sal_uInt16 nMin, sal_uInt16 nMax ) { pDlg->SetLimits( nMin, nMax ); } -void AbstractSvxZoomDialog_Impl::HideButton( USHORT nBtnId ) +void AbstractSvxZoomDialog_Impl::HideButton( sal_uInt16 nBtnId ) { pDlg->HideButton( nBtnId ); } @@ -512,7 +514,7 @@ String AbstractTitleDialog_Impl::GetTitle() const return pDlg->GetTitle(); } -ULONG AbstractGalleryIdDialog_Impl::GetId() const +sal_uLong AbstractGalleryIdDialog_Impl::GetId() const { return pDlg->GetId(); } @@ -552,7 +554,7 @@ String AbstractURLDlg_Impl::GetName() const return pDlg->GetName(); } -void AbstractSvxHlinkDlgMarkWnd_Impl::Hide( USHORT nFlags ) +void AbstractSvxHlinkDlgMarkWnd_Impl::Hide( sal_uInt16 nFlags ) { ((Window*)pDlg)->Hide( nFlags ); } @@ -567,22 +569,22 @@ Size AbstractSvxHlinkDlgMarkWnd_Impl::GetSizePixel() const return pDlg->GetSizePixel(); } -BOOL AbstractSvxHlinkDlgMarkWnd_Impl::IsVisible( ) const +sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::IsVisible( ) const { return (( Window* )pDlg)->IsVisible(); } -void AbstractSvxHlinkDlgMarkWnd_Impl::Invalidate( USHORT nFlags ) +void AbstractSvxHlinkDlgMarkWnd_Impl::Invalidate( sal_uInt16 nFlags ) { (( Window* )pDlg)->Invalidate(nFlags); } -BOOL AbstractSvxHlinkDlgMarkWnd_Impl::MoveTo( Point aNewPos )const +sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::MoveTo( Point aNewPos )const { return pDlg->MoveTo(aNewPos); } -BOOL AbstractSvxHlinkDlgMarkWnd_Impl::ConnectToDialog( BOOL bDoit )const +sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::ConnectToDialog( sal_Bool bDoit )const { return pDlg->ConnectToDialog(bDoit); } @@ -597,33 +599,33 @@ void AbstractSvxHlinkDlgMarkWnd_Impl::SelectEntry ( String aStrMark ) pDlg->SelectEntry(aStrMark); } -USHORT AbstractSvxHlinkDlgMarkWnd_Impl::SetError( USHORT nError) +sal_uInt16 AbstractSvxHlinkDlgMarkWnd_Impl::SetError( sal_uInt16 nError) { return pDlg->SetError(nError); } -USHORT AbstractSvxSearchSimilarityDialog_Impl::GetOther() +sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetOther() { return pDlg->GetOther(); } -USHORT AbstractSvxSearchSimilarityDialog_Impl::GetShorter() +sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetShorter() { return pDlg->GetShorter(); } -USHORT AbstractSvxSearchSimilarityDialog_Impl::GetLonger() +sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetLonger() { return pDlg-> GetLonger(); } -BOOL AbstractSvxSearchSimilarityDialog_Impl::IsRelaxed() +sal_Bool AbstractSvxSearchSimilarityDialog_Impl::IsRelaxed() { return pDlg-> IsRelaxed(); } // AbstractSvxTransformTabDialog implementations just forwards everything to the dialog -void AbstractSvxTransformTabDialog_Impl::SetCurPageId( USHORT nId ) +void AbstractSvxTransformTabDialog_Impl::SetCurPageId( sal_uInt16 nId ) { pDlg->SetCurPageId( nId ); } @@ -632,7 +634,7 @@ const SfxItemSet* AbstractSvxTransformTabDialog_Impl::GetOutputItemSet() const return pDlg->GetOutputItemSet(); } // -const USHORT* AbstractSvxTransformTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) +const sal_uInt16* AbstractSvxTransformTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) { return pDlg->GetInputRanges( pItem ); } @@ -656,7 +658,7 @@ void AbstractSvxTransformTabDialog_Impl::SetValidateFramePosLink( const Link& rL } // AbstractSvxCaptionDialog implementations just forwards everything to the dialog -void AbstractSvxCaptionDialog_Impl::SetCurPageId( USHORT nId ) +void AbstractSvxCaptionDialog_Impl::SetCurPageId( sal_uInt16 nId ) { pDlg->SetCurPageId( nId ); } @@ -665,7 +667,7 @@ const SfxItemSet* AbstractSvxCaptionDialog_Impl::GetOutputItemSet() const return pDlg->GetOutputItemSet(); } // -const USHORT* AbstractSvxCaptionDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) +const sal_uInt16* AbstractSvxCaptionDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) { return pDlg->GetInputRanges( pItem ); } @@ -688,7 +690,7 @@ void AbstractSvxCaptionDialog_Impl::SetValidateFramePosLink( const Link& rLink ) pDlg->SetValidateFramePosLink( rLink ); } -INT32 AbstractSvxJSearchOptionsDialog_Impl::GetTransliterationFlags() const +sal_Int32 AbstractSvxJSearchOptionsDialog_Impl::GetTransliterationFlags() const { return pDlg->GetTransliterationFlags(); } @@ -722,13 +724,13 @@ void AbstractSvxNameDialog_Impl::SetCheckNameHdl( const Link& rLink, bool bCheck else pDlg->SetCheckNameHdl( Link(), bCheckImmediately ); } -void AbstractSvxNameDialog_Impl::SetEditHelpId(ULONG nHelpId) +void AbstractSvxNameDialog_Impl::SetEditHelpId(const rtl::OString& aHelpId) { - pDlg->SetEditHelpId( nHelpId ); + pDlg->SetEditHelpId( aHelpId ); } -void AbstractSvxNameDialog_Impl::SetHelpId( ULONG nHelpId ) +void AbstractSvxNameDialog_Impl::SetHelpId( const rtl::OString& aHelpId ) { - pDlg->SetHelpId( nHelpId ); + pDlg->SetHelpId( aHelpId ); } void AbstractSvxNameDialog_Impl::SetText( const XubString& rStr ) { @@ -780,7 +782,7 @@ void AbstractSvxObjectTitleDescDialog_Impl::GetDescription(String& rDescription) pDlg->GetDescription(rDescription); } -void AbstractSvxMessDialog_Impl::SetButtonText( USHORT nBtnId, const String& rNewTxt ) +void AbstractSvxMessDialog_Impl::SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt ) { pDlg->SetButtonText( nBtnId, rNewTxt ); } @@ -840,9 +842,9 @@ void AbstractSvxMultiFileDialog_Impl::SetTitle( const String& rNewTitle ) pDlg->SetText( rNewTitle ); } -void AbstractSvxMultiFileDialog_Impl::SetHelpId( ULONG nHelpId ) +void AbstractSvxMultiFileDialog_Impl::SetHelpId( const rtl::OString& aHelpId ) { - pDlg->SetHelpId( nHelpId ); + pDlg->SetHelpId( aHelpId ); } Window * AbstractSvxHpLinkDlg_Impl::GetWindow() @@ -875,7 +877,7 @@ Graphic AbstractGraphicFilterDialog_Impl::GetFilteredGraphic( const Graphic& rGr } // AbstractSvxAreaTabDialog implementations just forwards everything to the dialog -void AbstractSvxAreaTabDialog_Impl::SetCurPageId( USHORT nId ) +void AbstractSvxAreaTabDialog_Impl::SetCurPageId( sal_uInt16 nId ) { pDlg->SetCurPageId( nId ); } @@ -885,7 +887,7 @@ const SfxItemSet* AbstractSvxAreaTabDialog_Impl::GetOutputItemSet() const return pDlg->GetOutputItemSet(); } -const USHORT* AbstractSvxAreaTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) +const sal_uInt16* AbstractSvxAreaTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem ) { return pDlg->GetInputRanges( pItem ); } @@ -917,7 +919,7 @@ const SfxItemSet* AbstractSvxPostItDialog_Impl::GetOutputItemSet() const { return pDlg->GetOutputItemSet(); } -void AbstractSvxPostItDialog_Impl::EnableTravel(BOOL bNext, BOOL bPrev) +void AbstractSvxPostItDialog_Impl::EnableTravel(sal_Bool bNext, sal_Bool bPrev) { pDlg->EnableTravel( bNext, bPrev ); } @@ -941,11 +943,11 @@ void AbstractSvxPostItDialog_Impl::HideAuthor() { pDlg->HideAuthor(); } -void AbstractSvxPostItDialog_Impl::SetReadonlyPostIt(BOOL bDisable) +void AbstractSvxPostItDialog_Impl::SetReadonlyPostIt(sal_Bool bDisable) { pDlg->SetReadonlyPostIt( bDisable ); } -BOOL AbstractSvxPostItDialog_Impl::IsOkEnabled() const +sal_Bool AbstractSvxPostItDialog_Impl::IsOkEnabled() const { return pDlg->IsOkEnabled(); } @@ -1001,6 +1003,11 @@ VclAbstractDialog* AbstractDialogFactory_Impl::CreateVclDialog( Window* pParent, Dialog* pDlg=NULL; switch ( nResId ) { + case RID_DEFAULTABOUT: + { + pDlg = new AboutDialog( pParent, CUI_RES( (sal_uInt16) nResId ) ); + break; + } case SID_OPTIONS_TREEDIALOG : case SID_OPTIONS_DATABASES : case SID_LANGUAGE_OPTIONS : @@ -1128,7 +1135,7 @@ SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTextTabDialog( Window* p // TabDialog that use functionality of the drawing layer and add AnchorTypes -- for SvxCaptionTabDialog AbstractSvxCaptionDialog* AbstractDialogFactory_Impl::CreateCaptionDialog( Window* pParent, const SdrView* pView, - USHORT nAnchorTypes ) + sal_uInt16 nAnchorTypes ) { SvxCaptionTabDialog* pDlg = new SvxCaptionTabDialog( pParent, pView, nAnchorTypes ); return new AbstractSvxCaptionDialog_Impl( pDlg ); @@ -1216,7 +1223,7 @@ AbstractDialogFactory_Impl::CreateScriptErrorDialog( AbstractScriptSelectorDialog* AbstractDialogFactory_Impl::CreateScriptSelectorDialog( - Window* pParent, BOOL bShowSlots, const Reference< frame::XFrame >& _rxFrame ) + Window* pParent, sal_Bool bShowSlots, const Reference< frame::XFrame >& _rxFrame ) { SvxScriptSelectorDialog* pDlg = NULL; @@ -1312,7 +1319,7 @@ SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( sal_uInt32 nResI switch ( nResId ) { case RID_SVXDLG_CHARMAP : - pDlg = new SvxCharacterMap( pParent, TRUE, pAttrSet ); + pDlg = new SvxCharacterMap( pParent, sal_True, pAttrSet ); break; default: break; @@ -1344,17 +1351,17 @@ SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabItemDialog( Window* p VclAbstractDialog* AbstractDialogFactory_Impl::CreateSvxSearchAttributeDialog( Window* pParent, SearchAttrItemList& rLst, - const USHORT* pWhRanges ) + const sal_uInt16* pWhRanges ) { Dialog* pDlg = new SvxSearchAttributeDialog( pParent, rLst, pWhRanges); return new VclAbstractDialog_Impl( pDlg ); } AbstractSvxSearchSimilarityDialog * AbstractDialogFactory_Impl::CreateSvxSearchSimilarityDialog( Window* pParent, - BOOL bRelax, - USHORT nOther, - USHORT nShorter, - USHORT nLonger) + sal_Bool bRelax, + sal_uInt16 nOther, + sal_uInt16 nShorter, + sal_uInt16 nLonger) { SvxSearchSimilarityDialog* pDlg = new SvxSearchSimilarityDialog( pParent, bRelax, nOther, nShorter, nLonger ); if ( pDlg ) @@ -1364,7 +1371,7 @@ AbstractSvxSearchSimilarityDialog * AbstractDialogFactory_Impl::CreateSvxSearchS SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxBorderBackgroundDlg( Window* pParent, const SfxItemSet& rCoreSet, - BOOL bEnableSelector) + sal_Bool bEnableSelector) { SfxTabDialog* pDlg = new SvxBorderBackgroundDlg( pParent, rCoreSet, bEnableSelector); return new AbstractTabDialog_Impl( pDlg ); @@ -1373,7 +1380,7 @@ SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxBorderBackgroundDlg( AbstractSvxTransformTabDialog* AbstractDialogFactory_Impl::CreateSvxTransformTabDialog( Window* pParent, const SfxItemSet* pAttr, const SdrView* pView, - USHORT nAnchorTypes ) + sal_uInt16 nAnchorTypes ) { SvxTransformTabDialog* pDlg = new SvxTransformTabDialog( pParent, pAttr,pView, nAnchorTypes); return new AbstractSvxTransformTabDialog_Impl( pDlg ); @@ -1413,7 +1420,7 @@ SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSchTransformTabDialog( W AbstractSvxJSearchOptionsDialog * AbstractDialogFactory_Impl::CreateSvxJSearchOptionsDialog( Window* pParent, const SfxItemSet& rOptionsSet, - INT32 nInitialFlags) + sal_Int32 nInitialFlags) { SvxJSearchOptionsDialog* pDlg = new SvxJSearchOptionsDialog( pParent, rOptionsSet, nInitialFlags ); return new AbstractSvxJSearchOptionsDialog_Impl( pDlg ); @@ -1499,13 +1506,13 @@ AbstractSvxMessDialog * AbstractDialogFactory_Impl::CreateSvxMessDialog( Window* return 0; } -AbstractSvxMultiPathDialog * AbstractDialogFactory_Impl::CreateSvxMultiPathDialog( Window* pParent, BOOL bEmptyAllowed ) +AbstractSvxMultiPathDialog * AbstractDialogFactory_Impl::CreateSvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed ) { SvxMultiPathDialog* pDlg = new SvxMultiPathDialog( pParent, bEmptyAllowed ); return new AbstractSvxMultiPathDialog_Impl( pDlg ); } -AbstractSvxMultiFileDialog * AbstractDialogFactory_Impl::CreateSvxMultiFileDialog( Window* pParent, BOOL bEmptyAllowed ) +AbstractSvxMultiFileDialog * AbstractDialogFactory_Impl::CreateSvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed ) { SvxMultiFileDialog* pDlg = new SvxMultiFileDialog( pParent, bEmptyAllowed ); return new AbstractSvxMultiFileDialog_Impl( pDlg ); @@ -1553,7 +1560,7 @@ AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterEmb AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterPosterSepia (Window* pParent, const Graphic& rGraphic, - USHORT nCount, + sal_uInt16 nCount, sal_uInt32 nResId) { GraphicFilterDialog* pDlg=NULL; @@ -1577,7 +1584,7 @@ AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterPos AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterSolarize (Window* pParent, //add for GraphicFilterSolarize const Graphic& rGraphic, - BYTE nGreyThreshold, BOOL bInvert, sal_uInt32 ) + sal_uInt8 nGreyThreshold, sal_Bool bInvert, sal_uInt32 ) { GraphicFilterDialog* pDlg = new GraphicFilterSolarize( pParent, rGraphic, nGreyThreshold, bInvert ); return new AbstractGraphicFilterDialog_Impl( pDlg ); @@ -1585,7 +1592,7 @@ AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterSol AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterMosaic (Window* pParent, //add for GraphicFilterMosaic const Graphic& rGraphic, - USHORT nTileWidth, USHORT nTileHeight, BOOL bEnhanceEdges, + sal_uInt16 nTileWidth, sal_uInt16 nTileHeight, sal_Bool bEnhanceEdges, sal_uInt32 nResId) { GraphicFilterDialog* pDlg=NULL; @@ -1615,7 +1622,7 @@ AbstractSvxAreaTabDialog* AbstractDialogFactory_Impl::CreateSvxAreaTabDialog( Wi SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxLineTabDialog( Window* pParent, const SfxItemSet* pAttr, //add forSvxLineTabDialog SdrModel* pModel, const SdrObject* pObj , - BOOL bHasObj) + sal_Bool bHasObj) { SfxTabDialog* pDlg = new SvxLineTabDialog( pParent, pAttr, pModel,pObj,bHasObj ); return new AbstractTabDialog_Impl( pDlg ); @@ -1637,7 +1644,7 @@ SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* pParent, pDlg = new SvxShortcutAssignDlg( pParent, _rxDocumentFrame, rAttr ); break; case RID_SVXDLG_CHARMAP : - pDlg = new SvxCharacterMap( pParent, TRUE, &rAttr ); + pDlg = new SvxCharacterMap( pParent, sal_True, &rAttr ); break; default: break; @@ -1685,7 +1692,7 @@ SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* pParent, AbstractSvxPostItDialog* AbstractDialogFactory_Impl::CreateSvxPostItDialog( Window* pParent, const SfxItemSet& rCoreSet, - BOOL bPrevNext, BOOL bRedline ) + sal_Bool bPrevNext, sal_Bool bRedline ) { SvxPostItDialog* pDlg = new SvxPostItDialog( pParent, rCoreSet, bPrevNext, bRedline ); return new AbstractSvxPostItDialog_Impl( pDlg ); @@ -1727,7 +1734,7 @@ VclAbstractDialog * AbstractDialogFactory_Impl::CreateSvxMacroAssignDlg( } // Factories for TabPages -CreateTabPage AbstractDialogFactory_Impl::GetTabPageCreatorFunc( USHORT nId ) +CreateTabPage AbstractDialogFactory_Impl::GetTabPageCreatorFunc( sal_uInt16 nId ) { switch ( nId ) { @@ -1813,7 +1820,7 @@ CreateSvxDistributePage AbstractDialogFactory_Impl::GetSvxDistributePageCreatorF return SvxDistributePage::Create; } -DialogGetRanges AbstractDialogFactory_Impl::GetDialogGetRangesFunc( USHORT nId ) +DialogGetRanges AbstractDialogFactory_Impl::GetDialogGetRangesFunc( sal_uInt16 nId ) { switch ( nId ) { @@ -1825,7 +1832,7 @@ DialogGetRanges AbstractDialogFactory_Impl::GetDialogGetRangesFunc( USHORT nId ) return 0; } -GetTabPageRanges AbstractDialogFactory_Impl::GetTabPageRangesFunc( USHORT nId ) +GetTabPageRanges AbstractDialogFactory_Impl::GetTabPageRangesFunc( sal_uInt16 nId ) { switch ( nId ) { @@ -1885,53 +1892,47 @@ GetTabPageRanges AbstractDialogFactory_Impl::GetTabPageRangesFunc( USHORT nId ) return 0; } -SfxAbstractInsertObjectDialog* AbstractDialogFactory_Impl::CreateInsertObjectDialog( Window* pParent, USHORT nSlotId, +SfxAbstractInsertObjectDialog* AbstractDialogFactory_Impl::CreateInsertObjectDialog( Window* pParent, const rtl::OUString& rCommand, const Reference < com::sun::star::embed::XStorage >& xStor, const SvObjectServerList* pList ) { InsertObjectDialog_Impl* pDlg=0; - switch ( nSlotId ) - { - case SID_INSERT_OBJECT : pDlg = new SvInsertOleDlg( pParent, xStor, pList ); break; - case SID_INSERT_PLUGIN : pDlg = new SvInsertPlugInDialog( pParent, xStor ); break; - case SID_INSERT_APPLET : pDlg = new SvInsertAppletDialog( pParent, xStor ); break; - case SID_INSERT_FLOATINGFRAME : pDlg = new SfxInsertFloatingFrameDialog( pParent, xStor ); break; - default: break; - } + if ( rCommand.equalsAscii(".uno:InsertObject" ) ) + pDlg = new SvInsertOleDlg( pParent, xStor, pList ); + else if ( rCommand.equalsAscii(".uno:InsertPlugin" ) ) + pDlg = new SvInsertPlugInDialog( pParent, xStor ); + else if ( rCommand.equalsAscii(".uno:InsertObjectFloatingFrame" ) ) + pDlg = new SfxInsertFloatingFrameDialog( pParent, xStor ); if ( pDlg ) { - pDlg->SetHelpId( nSlotId ); + pDlg->SetHelpId( rtl::OString( rCommand, rCommand.getLength(), RTL_TEXTENCODING_UTF8 ) ); return new AbstractInsertObjectDialog_Impl( pDlg ); } return 0; } -VclAbstractDialog* AbstractDialogFactory_Impl::CreateEditObjectDialog( Window* pParent, USHORT nSlotId, +VclAbstractDialog* AbstractDialogFactory_Impl::CreateEditObjectDialog( Window* pParent, const rtl::OUString& rCommand, const Reference < com::sun::star::embed::XEmbeddedObject >& xObj ) { InsertObjectDialog_Impl* pDlg=0; - switch ( nSlotId ) + if ( rCommand.equalsAscii(".uno:InsertObjectFloatingFrame" ) ) { - case SID_INSERT_APPLET : pDlg = new SvInsertAppletDialog( pParent, xObj ); break; - case SID_INSERT_FLOATINGFRAME : pDlg = new SfxInsertFloatingFrameDialog( pParent, xObj ); break; - default: break; - } - - if ( pDlg ) - { - pDlg->SetHelpId( nSlotId ); + pDlg = new SfxInsertFloatingFrameDialog( pParent, xObj ); + pDlg->SetHelpId( rtl::OString( rCommand, rCommand.getLength(), RTL_TEXTENCODING_UTF8 ) ); return new VclAbstractDialog_Impl( pDlg ); } return 0; } + + SfxAbstractPasteDialog* AbstractDialogFactory_Impl::CreatePasteDialog( Window* pParent ) { return new AbstractPasteDialog_Impl( new SvPasteObjectDialog( pParent ) ); } -SfxAbstractLinksDialog* AbstractDialogFactory_Impl::CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, BOOL bHTML, sfx2::SvBaseLink* p) +SfxAbstractLinksDialog* AbstractDialogFactory_Impl::CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, sal_Bool bHTML, sfx2::SvBaseLink* p) { SvBaseLinksDlg* pLinkDlg = new SvBaseLinksDlg( pParent, pMgr, bHTML ); if ( p ) @@ -1960,9 +1961,9 @@ VclAbstractDialog* AbstractDialogFactory_Impl::CreateOptionsDialog( return new VclAbstractDialog_Impl( new OfaTreeOptionsDialog( pParent, rExtensionId ) ); } -SvxAbstractInsRowColDlg* AbstractDialogFactory_Impl::CreateSvxInsRowColDlg( Window* pParent, bool bCol, ULONG nHelpId ) +SvxAbstractInsRowColDlg* AbstractDialogFactory_Impl::CreateSvxInsRowColDlg( Window* pParent, bool bCol, const rtl::OString& sHelpId ) { - return new SvxInsRowColDlg( pParent, bCol, nHelpId ); + return new SvxInsRowColDlg( pParent, bCol, sHelpId ); } AbstractPasswordToOpenModifyDialog * AbstractDialogFactory_Impl::CreatePasswordToOpenModifyDialog( diff --git a/cui/source/factory/dlgfact.hxx b/cui/source/factory/dlgfact.hxx index 3dd321a6769b..79cdbe7dad0b 100644 --- a/cui/source/factory/dlgfact.hxx +++ b/cui/source/factory/dlgfact.hxx @@ -133,9 +133,9 @@ class AbstractSfxDialog_Impl : public SfxAbstractDialog class AbstractTabDialog_Impl : public SfxAbstractTabDialog { DECL_ABSTDLG_BASE(AbstractTabDialog_Impl,SfxTabDialog) - virtual void SetCurPageId( USHORT nId ); + virtual void SetCurPageId( sal_uInt16 nId ); virtual const SfxItemSet* GetOutputItemSet() const; - virtual const USHORT* GetInputRanges( const SfxItemPool& pItem ); + virtual const sal_uInt16* GetInputRanges( const SfxItemPool& pItem ); virtual void SetInputSet( const SfxItemSet* pInSet ); //From class Window. virtual void SetText( const XubString& rStr ); @@ -215,8 +215,8 @@ class SvxZoomDialog; class AbstractSvxZoomDialog_Impl : public AbstractSvxZoomDialog { DECL_ABSTDLG_BASE(AbstractSvxZoomDialog_Impl,SvxZoomDialog) - virtual void SetLimits( USHORT nMin, USHORT nMax ); - virtual void HideButton( USHORT nBtnId ); + virtual void SetLimits( sal_uInt16 nMin, sal_uInt16 nMax ); + virtual void HideButton( sal_uInt16 nBtnId ); virtual const SfxItemSet* GetOutputItemSet() const ; }; @@ -235,7 +235,6 @@ class AbstractSpellDialog_Impl : public AbstractSpellDialog virtual SfxBindings& GetBindings(); }; //for SvxSpellDialog end - //for SearchProgress begin class SearchProgress; class AbstractSearchProgress_Impl : public AbstractSearchProgress @@ -290,7 +289,7 @@ class GalleryIdDialog; class AbstractGalleryIdDialog_Impl : public AbstractGalleryIdDialog { DECL_ABSTDLG_BASE(AbstractGalleryIdDialog_Impl,GalleryIdDialog) - virtual ULONG GetId() const ; + virtual sal_uLong GetId() const ; }; //for GalleryIdDialog end @@ -313,16 +312,16 @@ class SvxHlinkDlgMarkWnd; class AbstractSvxHlinkDlgMarkWnd_Impl : public AbstractSvxHlinkDlgMarkWnd { DECL_ABSTDLG_BASE(AbstractSvxHlinkDlgMarkWnd_Impl,SvxHlinkDlgMarkWnd) - virtual void Hide( USHORT nFlags = 0 ); - virtual BOOL IsVisible() const ; - virtual void Invalidate( USHORT nFlags = 0 ); + virtual void Hide( sal_uInt16 nFlags = 0 ); + virtual sal_Bool IsVisible() const ; + virtual void Invalidate( sal_uInt16 nFlags = 0 ); virtual void SetSizePixel( const Size& rNewSize ); virtual Size GetSizePixel() const; - virtual BOOL MoveTo ( Point aNewPos )const; - virtual BOOL ConnectToDialog( BOOL bDoit = TRUE )const; + virtual sal_Bool MoveTo ( Point aNewPos )const; + virtual sal_Bool ConnectToDialog( sal_Bool bDoit = sal_True )const; virtual void RefreshTree ( String aStrURL ) ; virtual void SelectEntry ( String aStrMark ); - virtual USHORT SetError( USHORT nError) ; + virtual sal_uInt16 SetError( sal_uInt16 nError) ; }; //for SvxHlinkDlgMarkWnd end @@ -332,10 +331,10 @@ class SvxSearchSimilarityDialog; class AbstractSvxSearchSimilarityDialog_Impl :public AbstractSvxSearchSimilarityDialog { DECL_ABSTDLG_BASE(AbstractSvxSearchSimilarityDialog_Impl,SvxSearchSimilarityDialog) - virtual USHORT GetOther(); - virtual USHORT GetShorter(); - virtual USHORT GetLonger(); - virtual BOOL IsRelaxed(); + virtual sal_uInt16 GetOther(); + virtual sal_uInt16 GetShorter(); + virtual sal_uInt16 GetLonger(); + virtual sal_Bool IsRelaxed(); }; //for SvxSearchSimilarityDialog end @@ -344,7 +343,7 @@ class SvxJSearchOptionsDialog; class AbstractSvxJSearchOptionsDialog_Impl :public AbstractSvxJSearchOptionsDialog { DECL_ABSTDLG_BASE(AbstractSvxJSearchOptionsDialog_Impl,SvxJSearchOptionsDialog) - virtual INT32 GetTransliterationFlags() const; + virtual sal_Int32 GetTransliterationFlags() const; }; //for SvxJSearchOptionsDialog end @@ -352,9 +351,9 @@ class AbstractSvxTransformTabDialog_Impl : public AbstractSvxTransformTabDialog { DECL_ABSTDLG_BASE(AbstractSvxTransformTabDialog_Impl,SvxTransformTabDialog) virtual void SetValidateFramePosLink( const Link& rLink ); - virtual void SetCurPageId( USHORT nId ); + virtual void SetCurPageId( sal_uInt16 nId ); virtual const SfxItemSet* GetOutputItemSet() const; - virtual const USHORT* GetInputRanges( const SfxItemPool& pItem ); + virtual const sal_uInt16* GetInputRanges( const SfxItemPool& pItem ); virtual void SetInputSet( const SfxItemSet* pInSet ); virtual void SetText( const XubString& rStr ); virtual String GetText() const; @@ -363,9 +362,9 @@ class AbstractSvxCaptionDialog_Impl : public AbstractSvxCaptionDialog { DECL_ABSTDLG_BASE(AbstractSvxCaptionDialog_Impl,SvxCaptionTabDialog) virtual void SetValidateFramePosLink( const Link& rLink ); - virtual void SetCurPageId( USHORT nId ); + virtual void SetCurPageId( sal_uInt16 nId ); virtual const SfxItemSet* GetOutputItemSet() const; - virtual const USHORT* GetInputRanges( const SfxItemPool& pItem ); + virtual const sal_uInt16* GetInputRanges( const SfxItemPool& pItem ); virtual void SetInputSet( const SfxItemSet* pInSet ); virtual void SetText( const XubString& rStr ); virtual String GetText() const; @@ -397,9 +396,9 @@ class AbstractSvxNameDialog_Impl :public AbstractSvxNameDialog DECL_ABSTDLG_BASE(AbstractSvxNameDialog_Impl,SvxNameDialog) virtual void GetName( String& rName ) ; virtual void SetCheckNameHdl( const Link& rLink, bool bCheckImmediately = false ) ; - virtual void SetEditHelpId(ULONG nHelpId) ; + virtual void SetEditHelpId(const rtl::OString&) ; //from class Window - virtual void SetHelpId( ULONG nHelpId ) ; + virtual void SetHelpId( const rtl::OString& ) ; virtual void SetText( const XubString& rStr ) ; private: Link aCheckNameHdl; @@ -439,7 +438,7 @@ class SvxMessDialog; class AbstractSvxMessDialog_Impl :public AbstractSvxMessDialog { DECL_ABSTDLG_BASE(AbstractSvxMessDialog_Impl,SvxMessDialog) - virtual void SetButtonText( USHORT nBtnId, const String& rNewTxt ); + virtual void SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt ); }; //for SvxMessDialog end @@ -469,7 +468,7 @@ class AbstractSvxMultiFileDialog_Impl :public AbstractSvxMultiFileDialog virtual void EnableRadioButtonMode(); virtual void SetTitle( const String& rNewTitle ); //From Class Window - virtual void SetHelpId( ULONG nHelpId ) ; + virtual void SetHelpId( const rtl::OString& ) ; }; //for SvxMultiFileDialog end @@ -509,9 +508,9 @@ class SvxAreaTabDialog; class AbstractSvxAreaTabDialog_Impl :public AbstractSvxAreaTabDialog { DECL_ABSTDLG_BASE(AbstractSvxAreaTabDialog_Impl,SvxAreaTabDialog) - virtual void SetCurPageId( USHORT nId ); + virtual void SetCurPageId( sal_uInt16 nId ); virtual const SfxItemSet* GetOutputItemSet() const; - virtual const USHORT* GetInputRanges( const SfxItemPool& pItem ); + virtual const sal_uInt16* GetInputRanges( const SfxItemPool& pItem ); virtual void SetInputSet( const SfxItemSet* pInSet ); //From class Window. virtual void SetText( const XubString& rStr ); @@ -525,7 +524,7 @@ class AbstractInsertObjectDialog_Impl : public SfxAbstractInsertObjectDialog DECL_ABSTDLG_BASE(AbstractInsertObjectDialog_Impl, InsertObjectDialog_Impl) virtual com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject > GetObject(); virtual ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetIconIfIconified( ::rtl::OUString* pGraphicMediaType ); - virtual BOOL IsCreateNew(); + virtual sal_Bool IsCreateNew(); }; class AbstractPasteDialog_Impl : public SfxAbstractPasteDialog @@ -534,7 +533,7 @@ public: DECL_ABSTDLG_BASE(AbstractPasteDialog_Impl, SvPasteObjectDialog ) virtual void Insert( SotFormatStringId nFormat, const String & rFormatName ); virtual void SetObjName( const SvGlobalName & rClass, const String & rObjName ); - virtual ULONG GetFormat( const TransferableDataHelper& aHelper, + virtual sal_uLong GetFormat( const TransferableDataHelper& aHelper, const DataFlavorExVector* pFormats=0, const TransferableObjectDescriptor* pDesc=0 ); }; @@ -555,14 +554,14 @@ class AbstractSvxPostItDialog_Impl :public AbstractSvxPostItDialog virtual const SfxItemSet* GetOutputItemSet() const; virtual void SetPrevHdl( const Link& rLink ) ; virtual void SetNextHdl( const Link& rLink ) ; - virtual void EnableTravel(BOOL bNext, BOOL bPrev) ; + virtual void EnableTravel(sal_Bool bNext, sal_Bool bPrev) ; virtual String GetNote() ; virtual void SetNote(const String& rTxt) ; virtual void ShowLastAuthor(const String& rAuthor, const String& rDate) ; virtual void DontChangeAuthor() ; virtual void HideAuthor() ; - virtual void SetReadonlyPostIt(BOOL bDisable) ; - virtual BOOL IsOkEnabled() const ; + virtual void SetReadonlyPostIt(sal_Bool bDisable) ; + virtual sal_Bool IsOkEnabled() const ; virtual Window * GetWindow(); private: Link aNextHdl; @@ -627,18 +626,18 @@ public: sal_uInt32 nResId); virtual AbstractSvxCaptionDialog* CreateCaptionDialog( Window* pParent, const SdrView* pView, - USHORT nAnchorTypes = 0 ); //add for SvxCaptionTabDialog + sal_uInt16 nAnchorTypes = 0 ); virtual AbstractSvxDistributeDialog* CreateSvxDistributeDialog(Window* pParent, const SfxItemSet& rAttr, SvxDistributeHorizontal eHor = SvxDistributeHorizontalNone, SvxDistributeVertical eVer = SvxDistributeVerticalNone); - virtual SfxAbstractInsertObjectDialog* CreateInsertObjectDialog( Window* pParent, USHORT nSlotId, + virtual SfxAbstractInsertObjectDialog* CreateInsertObjectDialog( Window* pParent, const rtl::OUString& rCommmand, const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& xStor, const SvObjectServerList* pList = 0 ); - virtual VclAbstractDialog* CreateEditObjectDialog( Window* pParent, USHORT nSlotId, + virtual VclAbstractDialog* CreateEditObjectDialog( Window* pParent, const rtl::OUString& rCommmand, const com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject >& xObj ); virtual SfxAbstractPasteDialog* CreatePasteDialog( Window* pParent ); - virtual SfxAbstractLinksDialog* CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, BOOL bHTML, sfx2::SvBaseLink* p=0 ); + virtual SfxAbstractLinksDialog* CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, sal_Bool bHTML, sfx2::SvBaseLink* p=0 ); virtual AbstractHangulHanjaConversionDialog * CreateHangulHanjaConversionDialog( Window* _pParent, //add for HangulHanjaConversionDialog editeng::HangulHanjaConversion::ConversionDirection _ePrimaryDirection ); @@ -655,11 +654,11 @@ public: const SfxItemSet& rCoreSet); virtual SfxAbstractTabDialog* CreateSvxBorderBackgroundDlg( Window* pParent, //add for SvxBorderBackgroundDlg const SfxItemSet& rCoreSet, - BOOL bEnableSelector = FALSE) ; + sal_Bool bEnableSelector = sal_False) ; virtual AbstractSvxTransformTabDialog* CreateSvxTransformTabDialog( Window* pParent, //add for SvxTransformTabDialog const SfxItemSet* pAttr, const SdrView* pView, - USHORT nAnchorTypes = 0) ; + sal_uInt16 nAnchorTypes = 0) ; virtual SfxAbstractTabDialog* CreateSchTransformTabDialog( Window* pParent, //add for SchTransformTabDialog const SfxItemSet* pAttr, const SdrView* pSdrView, @@ -690,15 +689,15 @@ public: virtual VclAbstractDialog* CreateSvxSearchAttributeDialog( Window* pParent, SearchAttrItemList& rLst, - const USHORT* pWhRanges); + const sal_uInt16* pWhRanges); virtual AbstractSvxSearchSimilarityDialog * CreateSvxSearchSimilarityDialog( Window* pParent, - BOOL bRelax, - USHORT nOther, - USHORT nShorter, - USHORT nLonger); //add for SvxSearchSimilarityDialog + sal_Bool bRelax, + sal_uInt16 nOther, + sal_uInt16 nShorter, + sal_uInt16 nLonger); //add for SvxSearchSimilarityDialog virtual AbstractSvxJSearchOptionsDialog * CreateSvxJSearchOptionsDialog( Window* pParent, const SfxItemSet& rOptionsSet, - INT32 nInitialFlags); + sal_Int32 nInitialFlags); virtual AbstractFmInputRecordNoDialog * CreateFmInputRecordNoDialog( Window* pParent ); virtual AbstractSvxNewDictionaryDialog* CreateSvxNewDictionaryDialog( Window* pParent, ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XSpellChecker1 > &xSpl, @@ -716,8 +715,8 @@ public: virtual AbstractSvxMessDialog * CreateSvxMessDialog( Window* pParent, sal_uInt32 nResId, const String& rText, const String& rDesc, Image* pImg = NULL ); //add for SvxMessDialog - virtual AbstractSvxMultiPathDialog * CreateSvxMultiPathDialog( Window* pParent, BOOL bEmptyAllowed = FALSE ); //add for SvxMultiPathDialog - virtual AbstractSvxMultiFileDialog * CreateSvxMultiFileDialog( Window* pParent, BOOL bEmptyAllowed = FALSE ); //add for SvxMultiFileDialog + virtual AbstractSvxMultiPathDialog * CreateSvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); //add for SvxMultiPathDialog + virtual AbstractSvxMultiFileDialog * CreateSvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); //add for SvxMultiFileDialog virtual AbstractSvxHpLinkDlg * CreateSvxHpLinkDlg (Window* pParent, //add for SvxHpLink SfxBindings* pBindings, sal_uInt32 nResId); @@ -731,14 +730,14 @@ public: RECT_POINT eLightSource, sal_uInt32 nResId); virtual AbstractGraphicFilterDialog * CreateGraphicFilterPosterSepia (Window* pParent, //add for GraphicFilterPoster & GraphicFilterSepia const Graphic& rGraphic, - USHORT nCount, + sal_uInt16 nCount, sal_uInt32 nResId); virtual AbstractGraphicFilterDialog * CreateGraphicFilterSolarize (Window* pParent, //add for GraphicFilterSolarize const Graphic& rGraphic, - BYTE nGreyThreshold, BOOL bInvert, sal_uInt32 nResId); + sal_uInt8 nGreyThreshold, sal_Bool bInvert, sal_uInt32 nResId); virtual AbstractGraphicFilterDialog * CreateGraphicFilterMosaic (Window* pParent, //add for GraphicFilterMosaic const Graphic& rGraphic, - USHORT nTileWidth, USHORT nTileHeight, BOOL bEnhanceEdges, sal_uInt32 nResId); + sal_uInt16 nTileWidth, sal_uInt16 nTileHeight, sal_Bool bEnhanceEdges, sal_uInt32 nResId); virtual AbstractSvxAreaTabDialog* CreateSvxAreaTabDialog( Window* pParent,//add for SvxAreaTabDialog const SfxItemSet* pAttr, SdrModel* pModel, @@ -746,23 +745,23 @@ public: virtual SfxAbstractTabDialog* CreateSvxLineTabDialog( Window* pParent, const SfxItemSet* pAttr, //add for SvxLineTabDialog SdrModel* pModel, const SdrObject* pObj = NULL, - BOOL bHasObj = TRUE ); + sal_Bool bHasObj = sal_True ); virtual AbstractSvxPostItDialog* CreateSvxPostItDialog( Window* pParent, //add for SvxPostItDialog const SfxItemSet& rCoreSet, - BOOL bPrevNext = FALSE, BOOL bRedline = FALSE ); + sal_Bool bPrevNext = sal_False, sal_Bool bRedline = sal_False ); // For TabPage - virtual CreateTabPage GetTabPageCreatorFunc( USHORT nId ); + virtual CreateTabPage GetTabPageCreatorFunc( sal_uInt16 nId ); virtual CreateSvxDistributePage GetSvxDistributePageCreatorFunc(); - virtual GetTabPageRanges GetTabPageRangesFunc( USHORT nId ); - virtual DialogGetRanges GetDialogGetRangesFunc( USHORT nId ); //add for SvxPostItDialog + virtual GetTabPageRanges GetTabPageRangesFunc( sal_uInt16 nId ); + virtual DialogGetRanges GetDialogGetRangesFunc( sal_uInt16 nId ); //add for SvxPostItDialog virtual VclAbstractDialog* CreateSvxScriptOrgDialog( Window* pParent, const String& rLanguage ); virtual AbstractScriptSelectorDialog* CreateScriptSelectorDialog( Window* pParent, - BOOL bShowSlots, + sal_Bool bShowSlots, const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _rxFrame ); @@ -786,7 +785,7 @@ public: virtual VclAbstractDialog* CreateOptionsDialog( Window* pParent, const rtl::OUString& rExtensionId, const rtl::OUString& rApplicationContext ); - virtual SvxAbstractInsRowColDlg* CreateSvxInsRowColDlg( Window* pParent, bool bCol, ULONG nHelpId ); + virtual SvxAbstractInsRowColDlg* CreateSvxInsRowColDlg( Window* pParent, bool bCol, const rtl::OString& sHelpId ); virtual AbstractPasswordToOpenModifyDialog * CreatePasswordToOpenModifyDialog( Window * pParent, sal_uInt16 nMinPasswdLen, sal_uInt16 nMaxPasswdLen, bool bIsPasswordToModify ); }; diff --git a/cui/source/inc/SpellDialog.hxx b/cui/source/inc/SpellDialog.hxx index 45cb973d3249..e9d39f679c0d 100644 --- a/cui/source/inc/SpellDialog.hxx +++ b/cui/source/inc/SpellDialog.hxx @@ -75,9 +75,9 @@ class SentenceEditWindow_Impl : public MultiLineEdit using MultiLineEdit::SetText; private: - std::set< USHORT > m_aIgnoreErrorsAt; - USHORT m_nErrorStart; - USHORT m_nErrorEnd; + std::set< sal_uInt16 > m_aIgnoreErrorsAt; + sal_uInt16 m_nErrorStart; + sal_uInt16 m_nErrorEnd; bool m_bIsUndoEditMode; Link m_aModifyLink; @@ -94,12 +94,12 @@ public: void SetModifyHdl(const Link& rLink) { m_aModifyLink = rLink;} - void SetAttrib( const TextAttrib& rAttr, ULONG nPara, USHORT nStart, USHORT nEnd ); + void SetAttrib( const TextAttrib& rAttr, sal_uLong nPara, sal_uInt16 nStart, sal_uInt16 nEnd ); void SetText( const String& rStr ); bool MarkNextError( bool bIgnoreCurrentError ); void ChangeMarkedWord(const String& rNewWord, LanguageType eLanguage); - void MoveErrorMarkTo(USHORT nErrorStart, USHORT nErrorEnd, bool bGrammar); + void MoveErrorMarkTo(sal_uInt16 nErrorStart, sal_uInt16 nErrorEnd, bool bGrammar); String GetErrorText() const; void RestoreCurrentError(); @@ -109,8 +109,8 @@ public: const SpellErrorDescription* GetAlternatives(); - void ResetModified() { GetTextEngine()->SetModified(FALSE); m_bIsUndoEditMode = false;} - BOOL IsModified() const { return GetTextEngine()->IsModified(); } + void ResetModified() { GetTextEngine()->SetModified(sal_False); m_bIsUndoEditMode = false;} + sal_Bool IsModified() const { return GetTextEngine()->IsModified(); } bool IsUndoEditMode() const { return m_bIsUndoEditMode;} void SetUndoEditMode(bool bSet); @@ -119,10 +119,10 @@ public: void ResetUndo(); void Undo(); - void AddUndoAction( SfxUndoAction *pAction, BOOL bTryMerg=FALSE ); - USHORT GetUndoActionCount(); - void UndoActionStart( USHORT nId ); - void UndoActionEnd( USHORT nId ); + void AddUndoAction( SfxUndoAction *pAction, sal_Bool bTryMerg=sal_False ); + sal_uInt16 GetUndoActionCount(); + void UndoActionStart( sal_uInt16 nId ); + void UndoActionEnd(); void MoveErrorEnd(long nOffset); diff --git a/cui/source/inc/about.hxx b/cui/source/inc/about.hxx new file mode 100644 index 000000000000..abf154c81ac5 --- /dev/null +++ b/cui/source/inc/about.hxx @@ -0,0 +1,83 @@ +/************************************************************************* + * + * 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. + * + ************************************************************************/ +#ifndef _ABOUT_HXX +#define _ABOUT_HXX + +// include --------------------------------------------------------------- + +#include <tools/resary.hxx> +#include <vcl/button.hxx> +#include <vcl/accel.hxx> +#include <svtools/svmedit.hxx> +#include <tools/list.hxx> +#include <svtools/stdctrl.hxx> +#include <sfx2/basedlgs.hxx> // SfxModalDialog + +DECLARE_LIST( AccelList, Accelerator* ) + +// class AboutDialog ----------------------------------------------------- + +class AboutDialog : public SfxModalDialog +{ +private: + OKButton aOKButton; + Image aAppLogo; + + FixedInfo aVersionText; + MultiLineEdit aCopyrightText; + FixedInfo aBuildData; + + ResStringArray* pDeveloperAry; + String aDevVersionStr; + String aAccelStr; + String aVersionData; + String aCopyrightTextStr; + + AccelList aAccelList; + + AutoTimer aTimer; + long nOff; + long m_nDeltaWidth; + int m_nPendingScrolls; + + sal_Bool bNormal; + +protected: + virtual sal_Bool Close(); + virtual void Paint( const Rectangle& ); + +public: + AboutDialog( Window* pParent, const ResId& nId ); + ~AboutDialog(); + + DECL_LINK( TimerHdl, Timer * ); + DECL_LINK( AccelSelectHdl, Accelerator * ); +}; + +#endif // #ifndef _ABOUT_HXX + + diff --git a/cui/source/inc/acccfg.hxx b/cui/source/inc/acccfg.hxx index 7d5ac47635d3..8935d1e726e6 100644 --- a/cui/source/inc/acccfg.hxx +++ b/cui/source/inc/acccfg.hxx @@ -87,7 +87,7 @@ public: m_pAccelConfigPage( pAccelConfigPage ) {} - void ReplaceEntry( USHORT nPos, const String &rStr ); + void ReplaceEntry( sal_uInt16 nPos, const String &rStr ); }; // class SfxAcceleratorConfigPage ---------------------------------------- @@ -104,7 +104,7 @@ struct TAccInfo , m_bIsConfigurable(sal_True ) , m_sCommand ( ) , m_aKey (aKey ) - // its important to set TRUE as default - + // its important to set sal_True as default - // because only fix entries will be disabled later ... {} @@ -181,9 +181,7 @@ private: String GetLabel4Command(const String& sCommand); void InitAccCfg(); - KeyCode MapPosToKeyCode( USHORT nPos ) const; - USHORT MapKeyCodeToPos( const KeyCode &rCode ) const; - String GetFunctionName( KeyFuncType eType ) const; + sal_uInt16 MapKeyCodeToPos( const KeyCode &rCode ) const; css::uno::Reference< css::frame::XModel > SearchForAlreadyLoadedDoc(const String& sName); void StartFileDialog( WinBits nBits, const String& rTitle ); @@ -196,13 +194,10 @@ public: SfxAcceleratorConfigPage( Window *pParent, const SfxItemSet& rItemSet ); virtual ~SfxAcceleratorConfigPage(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet& ); - void SelectMacro(const SfxMacroInfoItem*); void Apply(const css::uno::Reference< css::ui::XAcceleratorConfiguration >& pAccMgr); - void CopySource2Target(const css::uno::Reference< css::ui::XAcceleratorConfiguration >& xSourceAccMgr, - const css::uno::Reference< css::ui::XAcceleratorConfiguration >& xTargetAccMgr); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); }; @@ -216,8 +211,8 @@ public: SfxAcceleratorConfigListBox( Window *pParent, ResId &rResId ) : ListBox( pParent, rResId ) {} - void ReplaceEntry( USHORT nPos, const String &rStr ); - void ExpandEntry ( USHORT nPos, const String &rStr ); + void ReplaceEntry( sal_uInt16 nPos, const String &rStr ); + void ExpandEntry ( sal_uInt16 nPos, const String &rStr ); }; class SvxShortcutAssignDlg : public SfxSingleTabDialog diff --git a/cui/source/inc/align.hxx b/cui/source/inc/align.hxx index 6d005eba6774..3d39492b315b 100644 --- a/cui/source/inc/align.hxx +++ b/cui/source/inc/align.hxx @@ -32,7 +32,7 @@ #include <svx/orienthelper.hxx> #include <vcl/field.hxx> -#include <vcl/imagebtn.hxx> +#include <vcl/button.hxx> #include <vcl/fixed.hxx> #include <vcl/lstbox.hxx> #include <sfx2/tabdlg.hxx> @@ -53,7 +53,7 @@ public: virtual ~AlignmentTabPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); virtual BOOL FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); diff --git a/cui/source/inc/autocdlg.hxx b/cui/source/inc/autocdlg.hxx index 0338e23125ea..91e97c25eac9 100644 --- a/cui/source/inc/autocdlg.hxx +++ b/cui/source/inc/autocdlg.hxx @@ -54,7 +54,7 @@ public: OfaAutoCorrDlg(Window* pParent, const SfxItemSet *pSet ); - void EnableLanguage(BOOL bEnable) + void EnableLanguage(sal_Bool bEnable) { aLanguageFT.Enable(bEnable); aLanguageLB.Enable(bEnable);} @@ -86,14 +86,14 @@ class OfaACorrCheckListBox : public SvxSimpleTable OfaACorrCheckListBox(Window* pParent, const ResId& rResId ) : SvxSimpleTable( pParent, rResId ){} - inline void *GetUserData(ULONG nPos) { return GetEntry(nPos)->GetUserData(); } - inline void SetUserData(ULONG nPos, void *pData ) { GetEntry(nPos)->SetUserData(pData); } - inline ULONG GetSelectEntryPos() { return GetModel()->GetAbsPos(FirstSelected()); } + inline void *GetUserData(sal_uLong nPos) { return GetEntry(nPos)->GetUserData(); } + inline void SetUserData(sal_uLong nPos, void *pData ) { GetEntry(nPos)->SetUserData(pData); } + inline sal_uLong GetSelectEntryPos() { return GetModel()->GetAbsPos(FirstSelected()); } - BOOL IsChecked(ULONG nPos, USHORT nCol = 0); - void CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked); - SvButtonState GetCheckButtonState( SvLBoxEntry*, USHORT nCol ) const; - void SetCheckButtonState( SvLBoxEntry*, USHORT nCol, SvButtonState ); + sal_Bool IsChecked(sal_uLong nPos, sal_uInt16 nCol = 0); + void CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked); + SvButtonState GetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol ) const; + void SetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol, SvButtonState ); }; // class OfaAutocorrOptionsPage ------------------------------------------ @@ -124,7 +124,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); @@ -172,13 +172,13 @@ class OfaSwAutoFmtOptionsPage : public SfxTabPage Font aBulletFont; Font aByInputBulletFont; - USHORT nPercent; + sal_uInt16 nPercent; SvLBoxButtonData* pCheckButtonData; DECL_LINK(SelectHdl, OfaACorrCheckListBox*); DECL_LINK(EditHdl, PushButton*); - SvLBoxEntry* CreateEntry(String& rTxt, USHORT nCol); + SvLBoxEntry* CreateEntry(String& rTxt, sal_uInt16 nCol); OfaSwAutoFmtOptionsPage( Window* pParent, @@ -188,7 +188,7 @@ class OfaSwAutoFmtOptionsPage : public SfxTabPage public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); }; @@ -198,16 +198,16 @@ class OfaSwAutoFmtOptionsPage : public SfxTabPage class AutoCorrEdit : public Edit { Link aActionLink; - BOOL bSpaces; + sal_Bool bSpaces; public: AutoCorrEdit(Window* pParent, const ResId& rResId) : - Edit(pParent, rResId), bSpaces(FALSE){} + Edit(pParent, rResId), bSpaces(sal_False){} void SetActionHdl( const Link& rLink ) { aActionLink = rLink;} - void SetSpaces(BOOL bSet) + void SetSpaces(sal_Bool bSet) {bSpaces = bSet;} virtual void KeyInput( const KeyEvent& rKEvent ); @@ -243,16 +243,16 @@ private: CharClass* pCharClass; LanguageType eLang; - BOOL bHasSelectionText; - BOOL bFirstSelect:1; - BOOL bReplaceEditChanged:1; - BOOL bSWriter:1; + sal_Bool bHasSelectionText; + sal_Bool bFirstSelect:1; + sal_Bool bReplaceEditChanged:1; + sal_Bool bSWriter:1; DECL_LINK(SelectHdl, SvTabListBox*); DECL_LINK(NewDelHdl, PushButton*); DECL_LINK(ModifyHdl, Edit*); - void RefillReplaceBox(BOOL bFromReset, //Box mit neuer Sprache fuellen + void RefillReplaceBox(sal_Bool bFromReset, //Box mit neuer Sprache fuellen LanguageType eOldLanguage, LanguageType eNewLanguage); @@ -263,7 +263,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); virtual int DeactivatePage( SfxItemSet* pSet = 0 ); @@ -305,7 +305,7 @@ private: DECL_LINK(SelectHdl, ListBox*); DECL_LINK(ModifyHdl, Edit*); - void RefillReplaceBoxes(BOOL bFromReset, //Box filled with new language + void RefillReplaceBoxes(sal_Bool bFromReset, //Box filled with new language LanguageType eOldLanguage, LanguageType eNewLanguage); public: @@ -315,7 +315,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); virtual int DeactivatePage( SfxItemSet* pSet = 0 ); @@ -380,7 +380,7 @@ private: String ChangeStringExt_Impl( sal_UCS4 ); - SvLBoxEntry* CreateEntry(String& rTxt, USHORT nCol); + SvLBoxEntry* CreateEntry(String& rTxt, sal_uInt16 nCol); OfaQuoteTabPage( Window* pParent, const SfxItemSet& rSet ); public: @@ -389,7 +389,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); }; @@ -427,7 +427,7 @@ class OfaAutoCompleteTabPage : public SfxTabPage AutoCompleteMultiListBox aLBEntries; PushButton aPBEntries; SvStringsISortDtor* pAutoCmpltList; - USHORT nAutoCmpltListCnt; + sal_uInt16 nAutoCmpltListCnt; DECL_LINK( CheckHdl, CheckBox* ); @@ -439,7 +439,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); @@ -506,7 +506,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void ActivatePage( const SfxItemSet& ); }; diff --git a/cui/source/inc/backgrnd.hxx b/cui/source/inc/backgrnd.hxx index 2f9cb86a55a5..d3cc4e589439 100644 --- a/cui/source/inc/backgrnd.hxx +++ b/cui/source/inc/backgrnd.hxx @@ -62,17 +62,17 @@ class SvxBackgroundTabPage : public SvxTabPage using TabPage::DeactivatePage; public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); virtual void PointChanged( Window* pWindow, RECT_POINT eRP ); void ShowSelector(); // Shift-ListBox activation void ShowTblControl(); // for the Writer (cells/rows/tables) - void ShowParaControl(BOOL bCharOnly = FALSE); // for the Writer (paragraph/characters) - void EnableTransparency(BOOL bColor, BOOL bGraphic); + void ShowParaControl(sal_Bool bCharOnly = sal_False); // for the Writer (paragraph/characters) + void EnableTransparency(sal_Bool bColor, sal_Bool bGraphic); virtual void PageCreated (SfxAllItemSet aSet); protected: virtual int DeactivatePage( SfxItemSet* pSet = 0 ); @@ -81,7 +81,13 @@ private: SvxBackgroundTabPage( Window* pParent, const SfxItemSet& rCoreSet ); ~SvxBackgroundTabPage(); - // Background color ------------------------------------ + FixedText aSelectTxt; + ListBox aLbSelect; + const String aStrBrowse; + const String aStrUnlinked; + FixedText aTblDesc; + ListBox aTblLBox; + ListBox aParaLBox; Control aBorderWin; ValueSet aBackgroundColorSet; FixedLine aBackgroundColorBox; @@ -89,43 +95,33 @@ private: //color transparency FixedText aColTransFT; MetricField aColTransMF; + CheckBox aBtnPreview; // Background Bitmap ---------------------------------- + FixedLine aGbFile; PushButton aBtnBrowse; CheckBox aBtnLink; - CheckBox aBtnPreview; - FixedInfo aFtFile; - FixedLine aGbFile; + FixedLine aGbPosition; RadioButton aBtnPosition; RadioButton aBtnArea; RadioButton aBtnTile; SvxRectCtl aWndPosition; - FixedLine aGbPosition; + FixedInfo aFtFile; //transparency of graphics FixedLine aGraphTransFL; MetricField aGraphTransMF; BackgroundPreviewImpl* pPreviewWin2; - // Selector -------------------------------------------- - FixedText aSelectTxt; - ListBox aLbSelect; - const String aStrBrowse; - const String aStrUnlinked; // DDListBox for Writer ------------------------------- - - FixedText aTblDesc; - ListBox aTblLBox; - ListBox aParaLBox; - //------------------------------------------------------ Color aBgdColor; - USHORT nHtmlMode; - BOOL bAllowShowSelector : 1; - BOOL bIsGraphicValid : 1; - BOOL bLinkOnly : 1; - BOOL bResized : 1; - BOOL bColTransparency : 1; - BOOL bGraphTransparency : 1; + sal_uInt16 nHtmlMode; + sal_Bool bAllowShowSelector : 1; + sal_Bool bIsGraphicValid : 1; + sal_Bool bLinkOnly : 1; + sal_Bool bResized : 1; + sal_Bool bColTransparency : 1; + sal_Bool bGraphTransparency : 1; Graphic aBgdGraphic; String aBgdGraphicPath; String aBgdGraphicFilter; @@ -142,13 +138,13 @@ private: void FillColorValueSets_Impl(); void ShowColorUI_Impl(); void ShowBitmapUI_Impl(); - BOOL LoadLinkedGraphic_Impl(); + sal_Bool LoadLinkedGraphic_Impl(); void RaiseLoadError_Impl(); void SetGraphicPosition_Impl( SvxGraphicPosition ePos ); SvxGraphicPosition GetGraphicPosition_Impl(); void FillControls_Impl(const SvxBrushItem& rBgdAttr, const String& rUserData); - BOOL FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, USHORT nSlot); + sal_Bool FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, sal_uInt16 nSlot); void ResetFromWallpaperItem( const SfxItemSet& rSet ); DECL_LINK( LoadTimerHdl_Impl, Timer* ); diff --git a/cui/source/inc/bbdlg.hxx b/cui/source/inc/bbdlg.hxx index 0de4d99fa3a4..16274938ecaf 100644 --- a/cui/source/inc/bbdlg.hxx +++ b/cui/source/inc/bbdlg.hxx @@ -41,15 +41,15 @@ class SvxBorderBackgroundDlg: public SfxTabDialog public: SvxBorderBackgroundDlg( Window *pParent, const SfxItemSet& rCoreSet, - BOOL bEnableSelector = FALSE ); + sal_Bool bEnableSelector = sal_False ); ~SvxBorderBackgroundDlg(); protected: - virtual void PageCreated( USHORT nPageId, SfxTabPage& rTabPage ); + virtual void PageCreated( sal_uInt16 nPageId, SfxTabPage& rTabPage ); private: - BOOL bEnableBackgroundSelector; // for Border/Background + sal_Bool bEnableBackgroundSelector; // for Border/Background }; diff --git a/cui/source/inc/border.hxx b/cui/source/inc/border.hxx index aae0290453f2..19d97b6a8c32 100644 --- a/cui/source/inc/border.hxx +++ b/cui/source/inc/border.hxx @@ -53,9 +53,9 @@ class SvxBorderTabPage : public SfxTabPage public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rCoreAttrs ); + virtual sal_Bool FillItemSet( SfxItemSet& rCoreAttrs ); virtual void Reset( const SfxItemSet& ); void HideShadowControls(); @@ -123,7 +123,7 @@ private: bool mbBLTREnabled; /// true = Bottom-left to top-right border enabled. bool mbUseMarginItem; - static BOOL bSync; + static sal_Bool bSync; #ifdef _SVX_BORDER_CXX // Handler @@ -135,8 +135,8 @@ private: DECL_LINK( ModifyDistanceHdl_Impl, MetricField*); DECL_LINK( SyncHdl_Impl, CheckBox*); - USHORT GetPresetImageId( USHORT nValueSetIdx ) const; - USHORT GetPresetStringId( USHORT nValueSetIdx ) const; + sal_uInt16 GetPresetImageId( sal_uInt16 nValueSetIdx ) const; + sal_uInt16 GetPresetStringId( sal_uInt16 nValueSetIdx ) const; void FillPresetVS(); void FillShadowVS(); diff --git a/cui/source/inc/cfg.hxx b/cui/source/inc/cfg.hxx index 827721bd1496..dfcbc59da534 100644 --- a/cui/source/inc/cfg.hxx +++ b/cui/source/inc/cfg.hxx @@ -75,9 +75,7 @@ public: SvxConfigDialog( Window*, const SfxItemSet* ); ~SvxConfigDialog(); - void ActivateTabPage( USHORT ); - - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); virtual short Ok(); void SetFrame(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xFrame); @@ -123,7 +121,7 @@ public: const com::sun::star::uno::Reference < com::sun::star::uno::XInterface >& xManager ); - void SetModified( bool bValue = TRUE ) { bModified = bValue; } + void SetModified( bool bValue = sal_True ) { bModified = bValue; } bool IsModified( ) { return bModified; } bool IsReadOnly( ) { return bReadOnly; } @@ -222,7 +220,7 @@ public: // methods inherited from SaveInData SvxEntries* GetEntries(); void SetEntries( SvxEntries* ); - bool HasURL( const rtl::OUString& URL ) { (void)URL; return FALSE; } + bool HasURL( const rtl::OUString& URL ) { (void)URL; return sal_False; } bool HasSettings() { return m_xMenuSettings.is(); } void Reset(); bool Apply(); @@ -233,7 +231,7 @@ class SvxConfigEntry private: // common properties - USHORT nId; + sal_uInt16 nId; ::rtl::OUString aHelpText; ::rtl::OUString aLabel; ::rtl::OUString aCommand; @@ -258,26 +256,20 @@ private: public: - SvxConfigEntry( - const ::com::sun::star::uno::Sequence< - ::com::sun::star::beans::PropertyValue >& rProperties, - const ::com::sun::star::uno::Reference< - ::com::sun::star::container::XNameAccess >& rCommandToLabelMap ); - SvxConfigEntry( const ::rtl::OUString& rDisplayName, const ::rtl::OUString& rCommandURL, - bool bPopup = FALSE, - bool bParentData = FALSE ); + bool bPopup = sal_False, + bool bParentData = sal_False ); SvxConfigEntry() : nId( 0 ), - bPopUp( FALSE ), - bStrEdited( FALSE ), - bIsUserDefined( FALSE ), - bIsMain( FALSE ), - bIsParentData( FALSE ), - bIsVisible( TRUE ), + bPopUp( sal_False ), + bStrEdited( sal_False ), + bIsUserDefined( sal_False ), + bIsMain( sal_False ), + bIsParentData( sal_False ), + bIsVisible( sal_True ), nStyle( 0 ), pEntries( 0 ) {} @@ -288,7 +280,7 @@ public: void SetCommand( const String& rCmd ) { aCommand = rCmd; } const ::rtl::OUString& GetName() const { return aLabel; } - void SetName( const String& rStr ) { aLabel = rStr; bStrEdited = TRUE; } + void SetName( const String& rStr ) { aLabel = rStr; bStrEdited = sal_True; } bool HasChangedName() const { return bStrEdited; } const ::rtl::OUString& GetHelpText() ; @@ -297,10 +289,10 @@ public: const ::rtl::OUString& GetHelpURL() const { return aHelpURL; } void SetHelpURL( const String& rStr ) { aHelpURL = rStr; } - void SetPopup( bool bOn = TRUE ) { bPopUp = bOn; } + void SetPopup( bool bOn = sal_True ) { bPopUp = bOn; } bool IsPopup() const { return bPopUp; } - void SetUserDefined( bool bOn = TRUE ) { bIsUserDefined = bOn; } + void SetUserDefined( bool bOn = sal_True ) { bIsUserDefined = bOn; } bool IsUserDefined() const { return bIsUserDefined; } bool IsBinding() const { return !bPopUp; } @@ -310,10 +302,10 @@ public: void SetEntries( SvxEntries* entries ) { pEntries = entries; } bool HasEntries() const { return pEntries != NULL; } - void SetMain( bool bValue = TRUE ) { bIsMain = bValue; } + void SetMain( bool bValue = sal_True ) { bIsMain = bValue; } bool IsMain() { return bIsMain; } - void SetParentData( bool bValue = TRUE ) { bIsParentData = bValue; } + void SetParentData( bool bValue = sal_True ) { bIsParentData = bValue; } bool IsParentData() { return bIsParentData; } bool IsMovable(); @@ -337,11 +329,6 @@ public: sal_Int32 GetStyle() { return nStyle; } void SetStyle( sal_Int32 style ) { nStyle = style; } - - com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue > - GetProperties( - const ::com::sun::star::uno::Reference< - ::com::sun::star::container::XNameAccess >& rCommandToLabelMap ); }; class SvxMenuEntriesListBox : public SvTreeListBox @@ -358,13 +345,13 @@ public: virtual sal_Int8 AcceptDrop( const AcceptDropEvent& rEvt ); - virtual BOOL NotifyAcceptDrop( SvLBoxEntry* pEntry ); + virtual sal_Bool NotifyAcceptDrop( SvLBoxEntry* pEntry ); - virtual BOOL NotifyMoving( SvLBoxEntry*, SvLBoxEntry*, - SvLBoxEntry*&, ULONG& ); + virtual sal_Bool NotifyMoving( SvLBoxEntry*, SvLBoxEntry*, + SvLBoxEntry*&, sal_uLong& ); - virtual BOOL NotifyCopying( SvLBoxEntry*, SvLBoxEntry*, - SvLBoxEntry*&, ULONG&); + virtual sal_Bool NotifyCopying( SvLBoxEntry*, SvLBoxEntry*, + SvLBoxEntry*&, sal_uLong&); virtual DragDropMode NotifyStartDrag( TransferDataContainer&, SvLBoxEntry* ); @@ -457,13 +444,13 @@ protected: SvLBoxEntry* InsertEntry( SvxConfigEntry* pNewEntryData, SvLBoxEntry* pTarget = NULL, - bool bFront = FALSE ); + bool bFront = sal_False ); void AddSubMenusToUI( const String& rBaseTitle, SvxConfigEntry* pParentData ); SvLBoxEntry* InsertEntryIntoUI ( SvxConfigEntry* pNewEntryData, - ULONG nPos = LIST_APPEND ); + sal_uLong nPos = LIST_APPEND ); SvxEntries* FindParentForChild( SvxEntries* pParentEntries, SvxConfigEntry* pChildData ); @@ -477,15 +464,15 @@ public: SaveInData* GetSaveInData() { return pCurrentSaveInData; } SvLBoxEntry* AddFunction( SvLBoxEntry* pTarget = NULL, - bool bFront = FALSE, - bool bAllowDuplicates = FALSE ); + bool bFront = sal_False, + bool bAllowDuplicates = sal_False ); virtual void MoveEntry( bool bMoveUp ); bool MoveEntryData( SvLBoxEntry* pSourceEntry, SvLBoxEntry* pTargetEntry ); - BOOL FillItemSet( SfxItemSet& ); + sal_Bool FillItemSet( SfxItemSet& ); void Reset( const SfxItemSet& ); virtual bool DeleteSelectedContent() = 0; @@ -567,7 +554,7 @@ class SvxMainMenuOrganizerDialog : public ModalDialog public: SvxMainMenuOrganizerDialog ( Window*, SvxEntries*, - SvxConfigEntry*, bool bCreateMenu = FALSE ); + SvxConfigEntry*, bool bCreateMenu = sal_False ); ~SvxMainMenuOrganizerDialog (); @@ -608,11 +595,11 @@ public: Size GetCheckBoxPixelSize() const { return m_aCheckBoxImageSizePixel; } - virtual BOOL NotifyMoving( - SvLBoxEntry*, SvLBoxEntry*, SvLBoxEntry*&, ULONG& ); + virtual sal_Bool NotifyMoving( + SvLBoxEntry*, SvLBoxEntry*, SvLBoxEntry*&, sal_uLong& ); - virtual BOOL NotifyCopying( - SvLBoxEntry*, SvLBoxEntry*, SvLBoxEntry*&, ULONG&); + virtual sal_Bool NotifyCopying( + SvLBoxEntry*, SvLBoxEntry*, SvLBoxEntry*&, sal_uLong&); void KeyInput( const KeyEvent& rKeyEvent ); }; @@ -641,8 +628,8 @@ public: ~SvxToolbarConfigPage(); SvLBoxEntry* AddFunction( SvLBoxEntry* pTarget = NULL, - bool bFront = FALSE, - bool bAllowDuplicates = TRUE ); + bool bFront = sal_False, + bool bAllowDuplicates = sal_True ); void MoveEntry( bool bMoveUp ); @@ -693,7 +680,6 @@ public: void RestoreToolbar( SvxConfigEntry* pToolbar ); void RemoveToolbar( SvxConfigEntry* pToolbar ); void ApplyToolbar( SvxConfigEntry* pToolbar ); - void ReloadToolbar( const rtl::OUString& rURL ); rtl::OUString GetSystemUIName( const rtl::OUString& rResourceURL ); @@ -743,7 +729,7 @@ public: aBtnOK.Enable( rLink.Call( this ) > 0 ); } - void SetEditHelpId(ULONG nHelpId) {aEdtName.SetHelpId(nHelpId);} + void SetEditHelpId( const rtl::OString& aHelpId) {aEdtName.SetHelpId(aHelpId);} }; class SvxIconSelectorDialog : public ModalDialog @@ -816,7 +802,7 @@ public: const rtl::OUString& aMessage ); rtl::OUString ReplaceIconName( const rtl::OUString& ); - USHORT ShowDialog(); + sal_uInt16 ShowDialog(); }; //added for issue83555 class SvxIconChangeDialog : public ModalDialog diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx index dbab5bf29df7..b8937689dee3 100644 --- a/cui/source/inc/cfgutil.hxx +++ b/cui/source/inc/cfgutil.hxx @@ -51,7 +51,6 @@ class SfxSlotPool; class SfxStringItem; class SfxFontItem; class SfxMacroInfoItem; -class SfxMacroInfo; struct SfxStyleInfo_Impl; struct SfxStylesInfo_Impl; @@ -96,29 +95,27 @@ struct SfxStylesInfo_Impl static ::rtl::OUString generateCommand(const ::rtl::OUString& sFamily, const ::rtl::OUString& sStyle); }; -#define SFX_CFGGROUP_FUNCTION 1 -#define SFX_CFGGROUP_BASICMGR 2 -#define SFX_CFGGROUP_DOCBASICMGR 3 -#define SFX_CFGGROUP_BASICLIB 4 -#define SFX_CFGGROUP_BASICMOD 5 -#define SFX_CFGFUNCTION_MACRO 6 -#define SFX_CFGFUNCTION_SLOT 7 -#define SFX_CFGGROUP_SCRIPTCONTAINER 8 -#define SFX_CFGFUNCTION_SCRIPT 9 -#define SFX_CFGGROUP_STYLES 10 -#define SFX_CFGGROUP_SPECIALCHARACTERS 11 +#define SFX_CFGGROUP_FUNCTION 1 +#define SFX_CFGFUNCTION_SLOT 2 +#define SFX_CFGGROUP_SCRIPTCONTAINER 3 +#define SFX_CFGFUNCTION_SCRIPT 4 +#define SFX_CFGGROUP_STYLES 5 struct SfxGroupInfo_Impl { - USHORT nKind; - USHORT nOrd; + sal_uInt16 nKind; + sal_uInt16 nUniqueID; void* pObject; - BOOL bWasOpened; + sal_Bool bWasOpened; String sCommand; String sLabel; - SfxGroupInfo_Impl( USHORT n, USHORT nr, void* pObj = 0 ) : - nKind( n ), nOrd( nr ), pObject( pObj ), bWasOpened(FALSE) {} + SfxGroupInfo_Impl( sal_uInt16 n, sal_uInt16 nr, void* pObj = 0 ) : + nKind( n ), nUniqueID( nr ), pObject( pObj ), bWasOpened(sal_False) {} +}; + +struct CuiMacroInfo +{ }; typedef SfxGroupInfo_Impl* SfxGroupInfoPtr; @@ -140,15 +137,11 @@ public: ~SfxConfigFunctionListBox_Impl(); void ClearAll(); - SvLBoxEntry* GetEntry_Impl( USHORT nId ); - SvLBoxEntry* GetEntry_Impl( const String& ); - USHORT GetId( SvLBoxEntry *pEntry ); using Window::GetHelpText; String GetHelpText( SvLBoxEntry *pEntry ); - USHORT GetCurId() { return GetId( FirstSelected() ); } String GetCurCommand(); String GetCurLabel(); - SfxMacroInfo* GetMacroInfo(); + String GetSelectedScriptURI(); void FunctionSelected(); void SetStylesInfo(SfxStylesInfo_Impl* pStyles); }; @@ -159,9 +152,7 @@ class SfxConfigGroupListBox_Impl : public SvTreeListBox SvxConfigGroupBoxResource_Impl* pImp; SfxConfigFunctionListBox_Impl* pFunctionListBox; SfxGroupInfoArr_Impl aArr; - ULONG nMode; - BOOL bShowSF; // show Scripting Framework scripts - BOOL bShowBasic; // show Basic scripts + sal_uLong nMode; ::rtl::OUString m_sModuleLongName; css::uno::Reference< css::lang::XMultiServiceFactory > m_xSMGR; @@ -181,7 +172,6 @@ class SfxConfigGroupListBox_Impl : public SvTreeListBox ::rtl::OUString& docName ); - ::rtl::OUString parseLocationName( const ::rtl::OUString& location ); void InitModule(); void InitBasic(); @@ -194,12 +184,12 @@ class SfxConfigGroupListBox_Impl : public SvTreeListBox protected: virtual void RequestingChilds( SvLBoxEntry *pEntry); using SvListView::Expand; - virtual BOOL Expand( SvLBoxEntry* pParent ); + virtual sal_Bool Expand( SvLBoxEntry* pParent ); public: SfxConfigGroupListBox_Impl ( Window* pParent, const ResId&, - ULONG nConfigMode = 0 ); + sal_uLong nConfigMode = 0 ); ~SfxConfigGroupListBox_Impl(); void ClearAll(); @@ -208,14 +198,11 @@ public: const ::rtl::OUString& sModuleLongName); void SetFunctionListBox( SfxConfigFunctionListBox_Impl *pBox ) { pFunctionListBox = pBox; } - void Open( SvLBoxEntry*, BOOL ); + void Open( SvLBoxEntry*, sal_Bool ); void GroupSelected(); void SelectMacro( const SfxMacroInfoItem* ); - void AddAndSelect( const SfxStringItem*, const SfxStringItem* ); void SelectMacro( const String&, const String& ); String GetGroup(); - BasicManager* GetBasicManager( const SvLBoxEntry& _rEntry ); - void SetScriptType( const String& rScriptType ); void SetStylesInfo(SfxStylesInfo_Impl* pStyles); }; diff --git a/cui/source/inc/chardlg.hxx b/cui/source/inc/chardlg.hxx index dda5a8de47e4..5f88aa64fd3b 100644 --- a/cui/source/inc/chardlg.hxx +++ b/cui/source/inc/chardlg.hxx @@ -44,13 +44,13 @@ class FontList; // ----------------------------------------------------------------------- -#define DISABLE_CASEMAP ((USHORT)0x0001) -#define DISABLE_WORDLINE ((USHORT)0x0002) -#define DISABLE_BLINK ((USHORT)0x0004) -#define DISABLE_UNDERLINE_COLOR ((USHORT)0x0008) +#define DISABLE_CASEMAP ((sal_uInt16)0x0001) +#define DISABLE_WORDLINE ((sal_uInt16)0x0002) +#define DISABLE_BLINK ((sal_uInt16)0x0004) +#define DISABLE_UNDERLINE_COLOR ((sal_uInt16)0x0008) -#define DISABLE_LANGUAGE ((USHORT)0x0010) -#define DISABLE_HIDE_LANGUAGE ((USHORT)0x0020) +#define DISABLE_LANGUAGE ((sal_uInt16)0x0010) +#define DISABLE_HIDE_LANGUAGE ((sal_uInt16)0x0020) // class SvxCharBasePage ------------------------------------------------- @@ -60,18 +60,18 @@ protected: SvxFontPrevWindow m_aPreviewWin; FixedInfo m_aFontTypeFT; - BOOL m_bPreviewBackgroundToCharacter; + sal_Bool m_bPreviewBackgroundToCharacter; SvxCharBasePage( Window* pParent, const ResId& rResIdTabPage, const SfxItemSet&, - USHORT nResIdPrewievWin, USHORT nResIdFontTypeFT ); + sal_uInt16 nResIdPrewievWin, sal_uInt16 nResIdFontTypeFT ); virtual ~SvxCharBasePage(); - void SetPrevFontSize( const SfxItemSet& rSet, USHORT nSlot, SvxFont& rFont ); - void SetPrevFont( const SfxItemSet& rSet, USHORT nSlot, SvxFont& rFont ); - void SetPrevFontStyle( const SfxItemSet& rSet, USHORT nSlotPosture, USHORT nSlotWeight, SvxFont& rFont ); // posture/weight + void SetPrevFontSize( const SfxItemSet& rSet, sal_uInt16 nSlot, SvxFont& rFont ); + void SetPrevFont( const SfxItemSet& rSet, sal_uInt16 nSlot, SvxFont& rFont ); + void SetPrevFontStyle( const SfxItemSet& rSet, sal_uInt16 nSlotPosture, sal_uInt16 nSlotWeight, SvxFont& rFont ); // posture/weight void SetPrevFontWidthScale( const SfxItemSet& rSet ); - void SetPrevFontEscapement( BYTE nProp, BYTE nEscProp, short nEsc ); + void SetPrevFontEscapement( sal_uInt8 nProp, sal_uInt8 nEscProp, short nEsc ); inline SvxFont& GetPreviewFont(); inline SvxFont& GetPreviewCJKFont(); @@ -153,9 +153,8 @@ private: }; void Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp ); - BOOL FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp ); + sal_Bool FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp ); void ResetColor_Impl( const SfxItemSet& rSet ); - BOOL FillItemSetColor_Impl( SfxItemSet& rSet ); DECL_LINK( UpdateHdl_Impl, Timer* ); DECL_LINK( FontModifyHdl_Impl, void* ); @@ -172,10 +171,10 @@ public: ~SvxCharNamePage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); virtual void Reset( const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); void SetFontList( const SvxFontListItem& rItem ); void EnableRelativeMode(); @@ -183,7 +182,7 @@ public: // the writer uses SID_ATTR_BRUSH as font background void SetPreviewBackgroundToCharacter(); - void DisableControls( USHORT nDisable ); + void DisableControls( sal_uInt16 nDisable ); virtual void PageCreated (SfxAllItemSet aSet); }; @@ -234,7 +233,7 @@ private: FixedText m_aPositionFT; ListBox m_aPositionLB; - USHORT m_nHtmlMode; + sal_uInt16 m_nHtmlMode; String m_aTransparentColorName; @@ -244,7 +243,7 @@ private: void UpdatePreview_Impl(); void SetCaseMap_Impl( SvxCaseMap eCaseMap ); void ResetColor_Impl( const SfxItemSet& rSet ); - BOOL FillItemSetColor_Impl( SfxItemSet& rSet ); + sal_Bool FillItemSetColor_Impl( SfxItemSet& rSet ); DECL_LINK( SelectHdl_Impl, ListBox* ); DECL_LINK( CbClickHdl_Impl, CheckBox* ); @@ -259,12 +258,12 @@ public: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); virtual void Reset( const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); - void DisableControls( USHORT nDisable ); + void DisableControls( sal_uInt16 nDisable ); void EnableFlash(); // the writer uses SID_ATTR_BRUSH as font background void SetPreviewBackgroundToCharacter(); @@ -304,17 +303,17 @@ private: short m_nSuperEsc; short m_nSubEsc; - UINT16 m_nScaleWidthItemSetVal; - UINT16 m_nScaleWidthInitialVal; + sal_uInt16 m_nScaleWidthItemSetVal; + sal_uInt16 m_nScaleWidthInitialVal; - BYTE m_nSuperProp; - BYTE m_nSubProp; + sal_uInt8 m_nSuperProp; + sal_uInt8 m_nSubProp; SvxCharPositionPage( Window* pParent, const SfxItemSet& rSet ); void Initialize(); - void UpdatePreview_Impl( BYTE nProp, BYTE nEscProp, short nEsc ); - void SetEscapement_Impl( USHORT nEsc ); + void UpdatePreview_Impl( sal_uInt8 nProp, sal_uInt8 nEscProp, short nEsc ); + void SetEscapement_Impl( sal_uInt16 nEsc ); DECL_LINK( PositionHdl_Impl, RadioButton* ); DECL_LINK( RotationHdl_Impl, RadioButton* ); @@ -336,10 +335,10 @@ public: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); virtual void Reset( const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void FillUserData(); // the writer uses SID_ATTR_BRUSH as font background void SetPreviewBackgroundToCharacter(); @@ -360,15 +359,15 @@ private: FixedText m_aEndBracketFT; ListBox m_aEndBracketLB; - USHORT m_nStartBracketPosition; - USHORT m_nEndBracketPosition; + sal_uInt16 m_nStartBracketPosition; + sal_uInt16 m_nEndBracketPosition; SvxCharTwoLinesPage( Window* pParent, const SfxItemSet& rSet ); void UpdatePreview_Impl(); void Initialize(); void SelectCharacter( ListBox* pBox ); - void SetBracket( sal_Unicode cBracket, BOOL bStart ); + void SetBracket( sal_Unicode cBracket, sal_Bool bStart ); DECL_LINK( TwoLinesHdl_Impl, CheckBox* ); DECL_LINK( CharacterMapHdl_Impl, ListBox* ); @@ -382,10 +381,10 @@ public: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); virtual void Reset( const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); // the writer uses SID_ATTR_BRUSH as font background void SetPreviewBackgroundToCharacter(); virtual void PageCreated (SfxAllItemSet aSet); diff --git a/cui/source/inc/connect.hxx b/cui/source/inc/connect.hxx index eed7886fc6f1..00898a57c1f6 100644 --- a/cui/source/inc/connect.hxx +++ b/cui/source/inc/connect.hxx @@ -89,9 +89,9 @@ public: ~SvxConnectionPage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); void Construct(); diff --git a/cui/source/inc/cuicharmap.hxx b/cui/source/inc/cuicharmap.hxx index 9480141e1bb5..040c299b7c6a 100644 --- a/cui/source/inc/cuicharmap.hxx +++ b/cui/source/inc/cuicharmap.hxx @@ -61,7 +61,7 @@ class SvxShowText : public Control public: SvxShowText( Window* pParent, const ResId& rResId, - BOOL bCenter = FALSE ); + sal_Bool bCenter = sal_False ); ~SvxShowText(); void SetFont( const Font& rFont ); @@ -72,14 +72,14 @@ protected: private: long mnY; - BOOL mbCenter; + sal_Bool mbCenter; }; class SvxCharMapData { public: - SvxCharMapData( class SfxModalDialog* pDialog, BOOL bOne_, ResMgr* pResContext ); + SvxCharMapData( class SfxModalDialog* pDialog, sal_Bool bOne_, ResMgr* pResContext ); void SetCharFont( const Font& rFont ); @@ -101,7 +101,7 @@ friend class SvxCharacterMap; SvxShowText aShowChar; FixedText aCharCodeText; Font aFont; - BOOL bOne; + sal_Bool bOne; const SubsetMap* pSubsetMap; DECL_LINK( OKHdl, OKButton* ); @@ -121,7 +121,7 @@ private: SvxCharMapData* mpCharMapData; public: - SvxCharacterMap( Window* pParent, BOOL bOne=TRUE, const SfxItemSet* pSet=0 ); + SvxCharacterMap( Window* pParent, sal_Bool bOne=sal_True, const SfxItemSet* pSet=0 ); ~SvxCharacterMap(); void DisableFontSelection(); diff --git a/cui/source/inc/cuigaldlg.hxx b/cui/source/inc/cuigaldlg.hxx index 536c94f1b454..79a9b58f9350 100644 --- a/cui/source/inc/cuigaldlg.hxx +++ b/cui/source/inc/cuigaldlg.hxx @@ -84,7 +84,7 @@ private: void ImplSearch( const INetURLObject& rStartURL, const ::std::vector< String >& rFormats, - BOOL bRecursive ); + sal_Bool bRecursive ); virtual void SAL_CALL run(); virtual void SAL_CALL onTerminated(); @@ -245,7 +245,7 @@ public: GalleryIdDialog( Window* pParent, GalleryTheme* pThm ); ~GalleryIdDialog() {} - ULONG GetId() const { return aLbResName.GetSelectEntryPos(); } + sal_uLong GetId() const { return aLbResName.GetSelectEntryPos(); } }; // -------------------------- @@ -256,7 +256,7 @@ class GalleryThemeProperties : public SfxTabDialog { ExchangeData* pData; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); public: @@ -287,7 +287,7 @@ private: ExchangeData* pData; virtual void Reset( const SfxItemSet& ) {} - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); public: @@ -311,13 +311,13 @@ class TPGalleryThemeProperties : public SfxTabPage friend class TakeProgress; friend class TakeThread; + FixedText aFtFileType; + ComboBox aCbbFileType; + MultiListBox aLbxFound; PushButton aBtnSearch; PushButton aBtnTake; PushButton aBtnTakeAll; CheckBox aCbxPreview; - ComboBox aCbbFileType; - MultiListBox aLbxFound; - FixedText aFtFileType; GalleryPreview aWndPreview; ExchangeData* pData; @@ -327,19 +327,19 @@ class TPGalleryThemeProperties : public SfxTabPage String aLastFilterName; String aPreviewString; INetURLObject aURL; - USHORT nCurFilterPos; - USHORT nFirstExtFilterPos; - BOOL bEntriesFound; - BOOL bInputAllowed; - BOOL bTakeAll; - BOOL bSearchRecursive; + sal_uInt16 nCurFilterPos; + sal_uInt16 nFirstExtFilterPos; + sal_Bool bEntriesFound; + sal_Bool bInputAllowed; + sal_Bool bTakeAll; + sal_Bool bSearchRecursive; ::com::sun::star::uno::Reference< ::svt::DialogClosedListener > xDialogListener; ::com::sun::star::uno::Reference< ::com::sun::star::media::XPlayer > xMediaPlayer; ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XFolderPicker > xFolderPicker; virtual void Reset( const SfxItemSet& /*rSet*/ ) {} - virtual BOOL FillItemSet( SfxItemSet& /*rSet*/ ) { return TRUE; } + virtual sal_Bool FillItemSet( SfxItemSet& /*rSet*/ ) { return sal_True; } ::rtl::OUString addExtension( const ::rtl::OUString&, const ::rtl::OUString& ); void FillFilterList(); diff --git a/cui/source/inc/cuigrfflt.hxx b/cui/source/inc/cuigrfflt.hxx index 9fa35dd4dc87..0c6061068261 100644 --- a/cui/source/inc/cuigrfflt.hxx +++ b/cui/source/inc/cuigrfflt.hxx @@ -73,16 +73,16 @@ private: double mfScaleX; double mfScaleY; Size maSizePixel; - PreviewWindow maPreview; - FixedLine maFlParameter; - OKButton maBtnOK; - CancelButton maBtnCancel; - HelpButton maBtnHelp; DECL_LINK( ImplPreviewTimeoutHdl, Timer* pTimer ); DECL_LINK( ImplModifyHdl, void* p ); protected: + PreviewWindow maPreview; + OKButton maBtnOK; + CancelButton maBtnCancel; + HelpButton maBtnHelp; + FixedLine maFlParameter; const Link& GetModifyHdl() const { return maModifyHdl; } const Size& GetGraphicSizePixel() const { return maSizePixel; } @@ -112,13 +112,13 @@ private: public: GraphicFilterMosaic( Window* pParent, const Graphic& rGraphic, - USHORT nTileWidth, USHORT nTileHeight, BOOL bEnhanceEdges ); + sal_uInt16 nTileWidth, sal_uInt16 nTileHeight, sal_Bool bEnhanceEdges ); ~GraphicFilterMosaic(); virtual Graphic GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY ); long GetTileWidth() const { return static_cast<long>(maMtrWidth.GetValue()); } long GetTileHeight() const { return static_cast<long>(maMtrHeight.GetValue()); } - BOOL IsEnhanceEdges() const { return maCbxEdges.IsChecked(); } + sal_Bool IsEnhanceEdges() const { return maCbxEdges.IsChecked(); } }; // ------------------------- @@ -136,12 +136,12 @@ private: public: GraphicFilterSolarize( Window* pParent, const Graphic& rGraphic, - BYTE nGreyThreshold, BOOL bInvert ); + sal_uInt8 nGreyThreshold, sal_Bool bInvert ); ~GraphicFilterSolarize(); virtual Graphic GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY ); - BYTE GetGreyThreshold() const { return( (BYTE) FRound( maMtrThreshold.GetValue() * 2.55 ) ); } - BOOL IsInvert() const { return maCbxInvert.IsChecked(); } + sal_uInt8 GetGreyThreshold() const { return( (sal_uInt8) FRound( maMtrThreshold.GetValue() * 2.55 ) ); } + sal_Bool IsInvert() const { return maCbxInvert.IsChecked(); } }; // ---------------------- @@ -158,12 +158,12 @@ private: public: GraphicFilterSepia( Window* pParent, const Graphic& rGraphic, - USHORT nSepiaPercent ); + sal_uInt16 nSepiaPercent ); ~GraphicFilterSepia(); virtual Graphic GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY ); - USHORT GetSepiaPercent() const - { return sal::static_int_cast< USHORT >(maMtrSepia.GetValue()); } + sal_uInt16 GetSepiaPercent() const + { return sal::static_int_cast< sal_uInt16 >(maMtrSepia.GetValue()); } }; // ----------------------- @@ -180,11 +180,11 @@ private: public: GraphicFilterPoster( Window* pParent, const Graphic& rGraphic, - USHORT nPosterColorCount ); + sal_uInt16 nPosterColorCount ); ~GraphicFilterPoster(); virtual Graphic GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY ); - USHORT GetPosterColorCount() const { return( (USHORT) maNumPoster.GetValue() ); } + sal_uInt16 GetPosterColorCount() const { return( (sal_uInt16) maNumPoster.GetValue() ); } }; // ----------------------- diff --git a/cui/source/inc/cuihyperdlg.hxx b/cui/source/inc/cuihyperdlg.hxx index 3c2d1ebc10cf..86d930620e3e 100644 --- a/cui/source/inc/cuihyperdlg.hxx +++ b/cui/source/inc/cuihyperdlg.hxx @@ -55,9 +55,9 @@ private : SfxStatusForwarder aRdOnlyForwarder; public : - SvxHlinkCtrl( USHORT nId, SfxBindings & rBindings, SvxHpLinkDlg* pDlg); + SvxHlinkCtrl( sal_uInt16 nId, SfxBindings & rBindings, SvxHpLinkDlg* pDlg); - virtual void StateChanged( USHORT nSID, SfxItemState eState, + virtual void StateChanged( sal_uInt16 nSID, SfxItemState eState, const SfxPoolItem* pState ); }; @@ -92,19 +92,19 @@ private: DECL_LINK (ClickCloseHdl_Impl, void * ); protected: - virtual BOOL Close(); + virtual sal_Bool Close(); virtual void Move(); public: SvxHpLinkDlg (Window* pParent, SfxBindings* pBindings ); ~SvxHpLinkDlg (); - virtual void PageCreated( USHORT nId, IconChoicePage& rPage ); + virtual void PageCreated( sal_uInt16 nId, IconChoicePage& rPage ); - USHORT SetPage( SvxHyperlinkItem* pItem ); + sal_uInt16 SetPage( SvxHyperlinkItem* pItem ); void EnableInetBrowse( sal_Bool bEnable = sal_True ); void SetReadOnlyMode( sal_Bool bReadOnly = sal_False ); - inline BOOL IsHTMLDoc() const { return mbIsHTMLDoc; } + inline sal_Bool IsHTMLDoc() const { return mbIsHTMLDoc; } inline SfxBindings* GetBindings() const { return mpBindings; }; inline SfxDispatcher* GetDispatcher() const { return mpBindings->GetDispatcher(); } diff --git a/cui/source/inc/cuioptgenrl.hxx b/cui/source/inc/cuioptgenrl.hxx index e96e639c05ef..40466a3e6b0e 100644 --- a/cui/source/inc/cuioptgenrl.hxx +++ b/cui/source/inc/cuioptgenrl.hxx @@ -119,7 +119,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/inc/cuisrchdlg.hxx b/cui/source/inc/cuisrchdlg.hxx index 6f6718f55378..f1bf39764c55 100644 --- a/cui/source/inc/cuisrchdlg.hxx +++ b/cui/source/inc/cuisrchdlg.hxx @@ -51,7 +51,7 @@ class SvxJSearchOptionsPage; class SvxJSearchOptionsDialog : public SfxSingleTabDialog { - INT32 nInitialTlFlags; + sal_Int32 nInitialTlFlags; SvxJSearchOptionsPage *pPage; // disallow copy-constructor and assignment-operator for now @@ -61,14 +61,13 @@ class SvxJSearchOptionsDialog : public SfxSingleTabDialog public: SvxJSearchOptionsDialog( Window *pParent, const SfxItemSet& rOptionsSet, - INT32 nInitialFlags ); + sal_Int32 nInitialFlags ); virtual ~SvxJSearchOptionsDialog(); // Window virtual void Activate(); - INT32 GetTransliterationFlags() const; - void SetTransliterationFlags( INT32 nSettings ); + sal_Int32 GetTransliterationFlags() const; }; #endif diff --git a/cui/source/inc/cuitabarea.hxx b/cui/source/inc/cuitabarea.hxx index 25af5b0283b4..eee2bc172dfa 100644 --- a/cui/source/inc/cuitabarea.hxx +++ b/cui/source/inc/cuitabarea.hxx @@ -59,13 +59,13 @@ private: ChangeType mnGradientListState; ChangeType mnHatchingListState; - USHORT mnPageType; - USHORT mnDlgType; - USHORT mnPos; - BOOL mbAreaTP; - BOOL mbDeleteColorTable; + sal_uInt16 mnPageType; + sal_uInt16 mnDlgType; + sal_uInt16 mnPos; + sal_Bool mbAreaTP; + sal_Bool mbDeleteColorTable; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); protected: virtual short Ok(); @@ -102,7 +102,7 @@ public: XBitmapList* GetNewBitmapList() const { return mpNewBitmapList; } const XBitmapList* GetBitmapList() const { return mpBitmapList; } - void DontDeleteColorTable() { mbDeleteColorTable = FALSE; } + void DontDeleteColorTable() { mbDeleteColorTable = sal_False; } }; /************************************************************************* @@ -119,8 +119,8 @@ class SvxTransparenceTabPage : public SvxTabPage const SfxItemSet& rOutAttrs; RECT_POINT eRP; - UINT16 nPageType; - UINT16 nDlgType; + sal_uInt16 nPageType; + sal_uInt16 nDlgType; // main selection FixedLine aFlProp; @@ -150,7 +150,7 @@ class SvxTransparenceTabPage : public SvxTabPage // preview SvxXRectPreview aCtlBitmapPreview; SvxXRectPreview aCtlXRectPreview; - BOOL bBitmap; + sal_Bool bBitmap; XOutdevItemPool* pXPool; XFillAttrSetItem aXFillAttr; @@ -165,28 +165,28 @@ class SvxTransparenceTabPage : public SvxTabPage DECL_LINK(ModifiedTrgrHdl_Impl, void*); #endif - void ActivateLinear(BOOL bActivate); - void ActivateGradient(BOOL bActivate); + void ActivateLinear(sal_Bool bActivate); + void ActivateGradient(sal_Bool bActivate); void SetControlState_Impl(XGradientStyle eXGS); - BOOL InitPreview ( const SfxItemSet& rSet ); - void InvalidatePreview (BOOL bEnable = TRUE ); + sal_Bool InitPreview ( const SfxItemSet& rSet ); + void InvalidatePreview (sal_Bool bEnable = sal_True ); public: SvxTransparenceTabPage(Window* pParent, const SfxItemSet& rInAttrs); void Construct(); static SfxTabPage* Create(Window*, const SfxItemSet&); - static UINT16* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet(SfxItemSet&); + virtual sal_Bool FillItemSet(SfxItemSet&); virtual void Reset(const SfxItemSet&); virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet* pSet); virtual void PointChanged(Window* pWindow, RECT_POINT eRP); - void SetPageType(UINT16 nInType) { nPageType = nInType; } - void SetDlgType(UINT16 nInType) { nDlgType = nInType; } + void SetPageType(sal_uInt16 nInType) { nPageType = nInType; } + void SetDlgType(sal_uInt16 nInType) { nDlgType = nInType; } virtual void PageCreated (SfxAllItemSet aSet); }; @@ -253,11 +253,11 @@ private: ChangeType* pnGradientListState; ChangeType* pnHatchingListState; - UINT16 nPageType; - UINT16 nDlgType; - UINT16 nPos; + sal_uInt16 nPageType; + sal_uInt16 nDlgType; + sal_uInt16 nPos; - BOOL* pbAreaTP; + sal_Bool* pbAreaTP; XOutdevItemPool* pXPool; XFillAttrSetItem aXFillAttr; @@ -290,9 +290,9 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); virtual int DeactivatePage( SfxItemSet* pSet ); @@ -305,10 +305,10 @@ public: { pHatchingList = pHtchLst; } void SetBitmapList( XBitmapList* pBmpLst) { pBitmapList = pBmpLst; } - void SetPageType( UINT16 nInType ) { nPageType = nInType; } - void SetDlgType( UINT16 nInType ) { nDlgType = nInType; } - void SetPos( UINT16 nInPos ) { nPos = nInPos; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16 nInType ) { nPageType = nInType; } + void SetDlgType( sal_uInt16 nInType ) { nDlgType = nInType; } + void SetPos( sal_uInt16 nInPos ) { nPos = nInPos; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } virtual void PageCreated (SfxAllItemSet aSet); void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } void SetGrdChgd( ChangeType* pIn ) { pnGradientListState = pIn; } @@ -345,12 +345,12 @@ private: XColorTable* pColorTab; ChangeType* pnColorTableState; - UINT16 nPageType; - UINT16 nDlgType; - USHORT* pPos; - BOOL* pbAreaTP; + sal_uInt16 nPageType; + sal_uInt16 nDlgType; + sal_uInt16* pPos; + sal_Bool* pbAreaTP; - BOOL bDisable; + sal_Bool bDisable; XOutdevItemPool* pXPool; XFillAttrSetItem aXFillAttr; @@ -367,21 +367,21 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); virtual int DeactivatePage( SfxItemSet* pSet ); virtual void PointChanged( Window* pWindow, RECT_POINT eRP ); void SetColorTable( XColorTable* pColTab ) { pColorTab = pColTab; } - void SetPageType( UINT16 nInType ) { nPageType = nInType; } - void SetDlgType( UINT16 nInType ) { nDlgType = nInType; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16 nInType ) { nPageType = nInType; } + void SetDlgType( sal_uInt16 nInType ) { nDlgType = nInType; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } virtual void PageCreated (SfxAllItemSet aSet); - void DisablePage( BOOL bIn ) { bDisable = bIn; } + void DisablePage( sal_Bool bIn ) { bDisable = bIn; } }; /************************************************************************* @@ -428,10 +428,10 @@ private: ChangeType* pnGradientListState; ChangeType* pnColorTableState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPos; - BOOL* pbAreaTP; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPos; + sal_Bool* pbAreaTP; XOutdevItemPool* pXPool; XFillStyleItem aXFStyleItem; @@ -458,7 +458,7 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -468,10 +468,10 @@ public: void SetGradientList( XGradientList* pGrdLst) { pGradientList = pGrdLst; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPos( USHORT* pInPos ) { pPos = pInPos; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPos( sal_uInt16* pInPos ) { pPos = pInPos; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } void SetGrdChgd( ChangeType* pIn ) { pnGradientListState = pIn; } void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } @@ -515,10 +515,10 @@ private: ChangeType* pnHatchingListState; ChangeType* pnColorTableState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPos; - BOOL* pbAreaTP; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPos; + sal_Bool* pbAreaTP; XOutdevItemPool* pXPool; XFillStyleItem aXFStyleItem; @@ -546,7 +546,7 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -558,10 +558,10 @@ public: void SetHatchingList( XHatchList* pHtchLst) { pHatchingList = pHtchLst; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPos( USHORT* pInPos ) { pPos = pInPos; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPos( sal_uInt16* pInPos ) { pPos = pInPos; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } void SetHtchChgd( ChangeType* pIn ) { pnHatchingListState = pIn; } void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } @@ -607,12 +607,12 @@ private: ChangeType* pnBitmapListState; ChangeType* pnColorTableState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPos; - BOOL* pbAreaTP; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPos; + sal_Bool* pbAreaTP; - BOOL bBmpChanged; + sal_Bool bBmpChanged; XOutdevItemPool* pXPool; XFillStyleItem aXFStyleItem; @@ -640,7 +640,7 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -651,10 +651,10 @@ public: void SetColorTable( XColorTable* pColTab ) { pColorTab = pColTab; } void SetBitmapList( XBitmapList* pBmpLst) { pBitmapList = pBmpLst; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPos( USHORT* pInPos ) { pPos = pInPos; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPos( sal_uInt16* pInPos ) { pPos = pInPos; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } void SetBmpChgd( ChangeType* pIn ) { pnBitmapListState = pIn; } void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } @@ -717,11 +717,11 @@ private: XColorTable* pColorTab; ChangeType* pnColorTableState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPos; - BOOL* pbAreaTP; - BOOL bDeleteColorTable; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPos; + sal_Bool* pbAreaTP; + sal_Bool bDeleteColorTable; XOutdevItemPool* pXPool; XFillStyleItem aXFStyleItem; @@ -735,10 +735,10 @@ private: #ifdef _SVX_TPCOLOR_CXX void ConvertColorValues (Color& rColor, ColorModel eModell); - void RgbToCmyk_Impl( Color& rColor, USHORT& rK ); - void CmykToRgb_Impl( Color& rColor, const USHORT nKey ); - USHORT ColorToPercent_Impl( USHORT nColor ); - USHORT PercentToColor_Impl( USHORT nPercent ); + void RgbToCmyk_Impl( Color& rColor, sal_uInt16& rK ); + void CmykToRgb_Impl( Color& rColor, const sal_uInt16 nKey ); + sal_uInt16 ColorToPercent_Impl( sal_uInt16 nColor ); + sal_uInt16 PercentToColor_Impl( sal_uInt16 nPercent ); void FillValueSet_Impl( ValueSet& rVs ); //----------------------------------------------------------------------------------------------------- @@ -747,11 +747,11 @@ private: DECL_LINK( ClickDeleteHdl_Impl, void * ); // Button 'loeschen' DECL_LINK( ClickWorkOnHdl_Impl, void * ); // Button 'Bearbeiten' - DECL_LINK( SelectColorLBHdl_Impl, void * ); // Farbe aus Listbox auswhlen - DECL_LINK( SelectValSetHdl_Impl, void * ); // Farbe aus Farbpalette (links) auswhlen + DECL_LINK( SelectColorLBHdl_Impl, void * ); // Farbe aus Listbox ausw�hlen + DECL_LINK( SelectValSetHdl_Impl, void * ); // Farbe aus Farbpalette (links) ausw�hlen DECL_LINK( SelectColorModelHdl_Impl, void * ); // Auswahl Listbox 'Farbmodell' long ChangeColorHdl_Impl( void* p ); - DECL_LINK( ModifiedHdl_Impl, void * ); // Inhalt der Farbwerte-Felder wurde verndert + DECL_LINK( ModifiedHdl_Impl, void * ); // Inhalt der Farbwerte-Felder wurde ver�ndert DECL_LINK( ClickLoadHdl_Impl, void * ); // Button 'Farbtabelle laden' DECL_LINK( ClickSaveHdl_Impl, void * ); // Button 'Farbtabelle sichern' @@ -764,7 +764,7 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -772,14 +772,14 @@ public: void SetColorTable( XColorTable* pColTab ) { pColorTab = pColTab; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPos( USHORT* pInPos ) { pPos = pInPos; } - void SetAreaTP( BOOL* pIn ) { pbAreaTP = pIn; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPos( sal_uInt16* pInPos ) { pPos = pInPos; } + void SetAreaTP( sal_Bool* pIn ) { pbAreaTP = pIn; } void SetColorChgd( ChangeType* pIn ) { pnColorTableState = pIn; } - void SetDeleteColorTable( BOOL bIn ) { bDeleteColorTable = bIn; } + void SetDeleteColorTable( sal_Bool bIn ) { bDeleteColorTable = bIn; } virtual void FillUserData(); }; diff --git a/cui/source/inc/cuitabline.hxx b/cui/source/inc/cuitabline.hxx index 0f7fca4b6cba..fbdcf44a0862 100644 --- a/cui/source/inc/cuitabline.hxx +++ b/cui/source/inc/cuitabline.hxx @@ -50,21 +50,21 @@ private: XDashList* pNewDashList; XLineEndList* pLineEndList; XLineEndList* pNewLineEndList; - BOOL bObjSelected; + sal_Bool bObjSelected; ChangeType nLineEndListState; ChangeType nDashListState; ChangeType mnColorTableState; - USHORT nPageType; - USHORT nDlgType; - USHORT nPosDashLb; - USHORT nPosLineEndLb; - USHORT mnPos; - BOOL mbAreaTP; - BOOL mbDeleteColorTable; + sal_uInt16 nPageType; + sal_uInt16 nDlgType; + sal_uInt16 nPosDashLb; + sal_uInt16 nPosLineEndLb; + sal_uInt16 mnPos; + sal_Bool mbAreaTP; + sal_Bool mbDeleteColorTable; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); protected: virtual short Ok(); @@ -76,7 +76,7 @@ protected: public: SvxLineTabDialog( Window* pParent, const SfxItemSet* pAttr, SdrModel* pModel, const SdrObject* pObj = NULL, - BOOL bHasObj = TRUE ); + sal_Bool bHasObj = sal_True ); ~SvxLineTabDialog(); void SetNewDashList( XDashList* pInLst) @@ -105,6 +105,7 @@ class SvxLineTabPage : public SvxTabPage using TabPage::ActivatePage; using TabPage::DeactivatePage; private: + FixedLine aFlLine; FixedText aFtLineStyle; LineLB aLbLineStyle; FixedText aFtColor; @@ -113,19 +114,18 @@ private: MetricField aMtrLineWidth; FixedText aFtTransparent; MetricField aMtrTransparent; - FixedLine aFlLine; - FixedText aFtLineEndsStyle; + FixedLine aFlLineEnds; LineEndLB aLbStartStyle; - FixedText aFtLineEndsWidth; MetricField aMtrStartWidth; TriStateBox aTsbCenterStart; + FixedText aFtLineEndsStyle; LineEndLB aLbEndStyle; + FixedText aFtLineEndsWidth; MetricField aMtrEndWidth; TriStateBox aTsbCenterEnd; CheckBox aCbxSynchronize; - FixedLine aFlLineEnds; - SvxXLinePreview aCtlPreview; FixedLine aFLSeparator; + SvxXLinePreview aCtlPreview; // #116827# FixedLine maFLEdgeStyle; @@ -149,15 +149,15 @@ private: List aGrfNames; List aGrfBrushItems; String sNumCharFmtName; - BOOL bLastWidthModified; + sal_Bool bLastWidthModified; Size aSymbolLastSize; Graphic aSymbolGraphic; Size aSymbolSize; - BOOL bSymbols; + sal_Bool bSymbols; const SfxItemSet& rOutAttrs; RECT_POINT eRP; - BOOL bObjSelected; + sal_Bool bObjSelected; XOutdevItemPool* pXPool; XLineStyleItem aXLStyle; @@ -174,17 +174,17 @@ private: ChangeType* pnLineEndListState; ChangeType* pnDashListState; ChangeType* pnColorTableState; - UINT16 nPageType; - UINT16 nDlgType; - USHORT* pPosDashLb; - USHORT* pPosLineEndLb; + sal_uInt16 nPageType; + sal_uInt16 nDlgType; + sal_uInt16* pPosDashLb; + sal_uInt16* pPosLineEndLb; SfxMapUnit ePoolUnit; // #63083# - INT32 nActLineWidth; + sal_Int32 nActLineWidth; - //Handler fr Gallery-Popup-Menue-Button + Size + //Handler f�r Gallery-Popup-Menue-Button + Size DECL_LINK( GraphicHdl_Impl, MenuButton * ); DECL_LINK( MenuCreateHdl_Impl, MenuButton * ); DECL_STATIC_LINK( SvxLineTabPage, GraphicArrivedHdl_Impl, SvxBrushItem* ); @@ -201,13 +201,13 @@ private: // #116827# DECL_LINK( ChangeEdgeStyleHdl_Impl, void * ); - BOOL FillXLSet_Impl(); + sal_Bool FillXLSet_Impl(); #endif void FillListboxes(); public: - void ShowSymbolControls(BOOL bOn); + void ShowSymbolControls(sal_Bool bOn); SvxLineTabPage( Window* pParent, const SfxItemSet& rInAttrs ); virtual ~SvxLineTabPage(); @@ -215,9 +215,9 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet& ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -230,12 +230,12 @@ public: void SetColorTable( XColorTable* pColTab ) { pColorTab = pColTab; } void SetDashList( XDashList* pDshLst ) { pDashList = pDshLst; } void SetLineEndList( XLineEndList* pLneEndLst) { pLineEndList = pLneEndLst; } - void SetObjSelected( BOOL bHasObj ) { bObjSelected = bHasObj; } + void SetObjSelected( sal_Bool bHasObj ) { bObjSelected = bHasObj; } - void SetPageType( UINT16 nInType ) { nPageType = nInType; } - void SetDlgType( UINT16 nInType ) { nDlgType = nInType; } - void SetPosDashLb( USHORT* pInPos ) { pPosDashLb = pInPos; } - void SetPosLineEndLb( USHORT* pInPos ) { pPosLineEndLb = pInPos; } + void SetPageType( sal_uInt16 nInType ) { nPageType = nInType; } + void SetDlgType( sal_uInt16 nInType ) { nDlgType = nInType; } + void SetPosDashLb( sal_uInt16* pInPos ) { pPosDashLb = pInPos; } + void SetPosLineEndLb( sal_uInt16* pInPos ) { pPosLineEndLb = pInPos; } void SetLineEndChgd( ChangeType* pIn ) { pnLineEndListState = pIn; } void SetDashChgd( ChangeType* pIn ) { pnDashListState = pIn; } @@ -280,7 +280,7 @@ private: const SfxItemSet& rOutAttrs; XDash aDash; - BOOL bObjSelected; + sal_Bool bObjSelected; XOutdevItemPool* pXPool; XLineStyleItem aXLStyle; @@ -293,9 +293,9 @@ private: XDashList* pDashList; ChangeType* pnDashListState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPosDashLb; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPosDashLb; SfxMapUnit ePoolUnit; FieldUnit eFUnit; @@ -325,18 +325,18 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); virtual int DeactivatePage( SfxItemSet* pSet ); void SetDashList( XDashList* pDshLst ) { pDashList = pDshLst; } - void SetObjSelected( BOOL bHasObj ) { bObjSelected = bHasObj; } + void SetObjSelected( sal_Bool bHasObj ) { bObjSelected = bHasObj; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPosDashLb( USHORT* pInPos ) { pPosDashLb = pInPos; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPosDashLb( sal_uInt16* pInPos ) { pPosDashLb = pInPos; } void SetDashChgd( ChangeType* pIn ) { pnDashListState = pIn; } @@ -370,7 +370,7 @@ private: const SfxItemSet& rOutAttrs; const SdrObject* pPolyObj; - BOOL bObjSelected; + sal_Bool bObjSelected; XOutdevItemPool* pXPool; XLineStyleItem aXLStyle; @@ -382,9 +382,9 @@ private: XLineEndList* pLineEndList; ChangeType* pnLineEndListState; - USHORT* pPageType; - USHORT* pDlgType; - USHORT* pPosLineEndLb; + sal_uInt16* pPageType; + sal_uInt16* pDlgType; + sal_uInt16* pPosLineEndLb; #ifdef _SVX_TPLNEEND_CXX DECL_LINK( ClickAddHdl_Impl, void * ); @@ -405,7 +405,7 @@ public: void Construct(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -413,11 +413,11 @@ public: void SetLineEndList( XLineEndList* pInList ) { pLineEndList = pInList; } void SetPolyObj( const SdrObject* pObj ) { pPolyObj = pObj; } - void SetObjSelected( BOOL bHasObj ) { bObjSelected = bHasObj; } + void SetObjSelected( sal_Bool bHasObj ) { bObjSelected = bHasObj; } - void SetPageType( USHORT* pInType ) { pPageType = pInType; } - void SetDlgType( USHORT* pInType ) { pDlgType = pInType; } - void SetPosLineEndLb( USHORT* pInPos ) { pPosLineEndLb = pInPos; } + void SetPageType( sal_uInt16* pInType ) { pPageType = pInType; } + void SetDlgType( sal_uInt16* pInType ) { pDlgType = pInType; } + void SetPosLineEndLb( sal_uInt16* pInPos ) { pPosLineEndLb = pInPos; } void SetLineEndChgd( ChangeType* pIn ) { pnLineEndListState = pIn; } diff --git a/cui/source/inc/dbregister.hxx b/cui/source/inc/dbregister.hxx index 2ae0bd775304..65ebd9422e5f 100644 --- a/cui/source/inc/dbregister.hxx +++ b/cui/source/inc/dbregister.hxx @@ -63,8 +63,8 @@ namespace svx HeaderBar* pHeaderBar; ::svx::OptHeaderTabListBox* pPathBox; SvLBoxEntry* m_pCurEntry; - ULONG m_nOldCount; - BOOL m_bModified; + sal_uLong m_nOldCount; + sal_Bool m_bModified; #ifdef SVX_DBREGISTER_HXX DECL_LINK( NewHdl, void * ); @@ -96,13 +96,6 @@ namespace svx */ void openLinkDialog(const String& _sOldName,const String& _sOldLocation,SvLBoxEntry* _pEntry = NULL); - /** opens a file pciker to select a database file - @param _sLocation - If set, the file picker use it as default directory - @return - the location of the database file - */ - String getFileLocation(const String& _sLocation); #endif public: @@ -110,9 +103,9 @@ namespace svx virtual ~DbRegistrationOptionsPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); }; diff --git a/cui/source/inc/defdlgname.hxx b/cui/source/inc/defdlgname.hxx index 39913eaba94a..c3e2f198995e 100644 --- a/cui/source/inc/defdlgname.hxx +++ b/cui/source/inc/defdlgname.hxx @@ -30,8 +30,8 @@ // define ---------------------------------------------------------------- -#define MESS_BTN_1 ((USHORT)0) -#define MESS_BTN_2 ((USHORT)1) +#define MESS_BTN_1 ((sal_uInt16)0) +#define MESS_BTN_2 ((sal_uInt16)1) // const ----------------------------------------------------------------- diff --git a/cui/source/inc/dlgname.hxx b/cui/source/inc/dlgname.hxx index 01cb4fc078dc..75b5d0d8a70d 100644 --- a/cui/source/inc/dlgname.hxx +++ b/cui/source/inc/dlgname.hxx @@ -83,7 +83,7 @@ public: aBtnOK.Enable( rLink.Call( this ) > 0 ); } - void SetEditHelpId(ULONG nHelpId) {aEdtName.SetHelpId(nHelpId);} + void SetEditHelpId( const rtl::OString& aHelpId) {aEdtName.SetHelpId(aHelpId);} }; /////////////////////////////////////////////////////////////////////////////////////////////// @@ -187,7 +187,7 @@ public: SvxMessDialog( Window* pWindow, const String& rText, const String& rDesc, Image* pImg = NULL ); ~SvxMessDialog(); - void SetButtonText( USHORT nBtnId, const String& rNewTxt ); + void SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt ); }; diff --git a/cui/source/inc/dstribut.hxx b/cui/source/inc/dstribut.hxx index c26a3c82257d..08514f807bb2 100644 --- a/cui/source/inc/dstribut.hxx +++ b/cui/source/inc/dstribut.hxx @@ -71,8 +71,8 @@ public: static SfxTabPage* Create(Window*, const SfxItemSet&, SvxDistributeHorizontal eHor, SvxDistributeVertical eVer); - static UINT16* GetRanges(); - virtual BOOL FillItemSet(SfxItemSet&); + static sal_uInt16* GetRanges(); + virtual sal_Bool FillItemSet(SfxItemSet&); virtual void Reset(const SfxItemSet&); virtual void PointChanged(Window* pWindow, RECT_POINT eRP); diff --git a/cui/source/inc/gallery.hrc b/cui/source/inc/gallery.hrc index c9d6729be447..d813fa7c7f56 100644 --- a/cui/source/inc/gallery.hrc +++ b/cui/source/inc/gallery.hrc @@ -44,7 +44,6 @@ #define RID_SVXSTR_GALLERY_NOFILES (RID_CUI_GALLERY_START + 12) #define RID_SVXSTR_GALLERY_SEARCH (RID_CUI_GALLERY_START + 30) #define RID_SVXSTR_GALLERYPROPS_OBJECT (RID_CUI_GALLERY_START + 39) -#define RID_SVXSTR_GALLERYPROPS_GALTHEME (RID_CUI_GALLERY_START + 40) #define RID_SVXSTR_GALLERY_READONLY (RID_CUI_GALLERY_START + 43) #define RID_SVXSTR_GALLERY_ALLFILES (RID_CUI_GALLERY_START + 44) #define RID_SVXSTR_GALLERY_ID_EXISTS (RID_CUI_GALLERY_START + 81) diff --git a/cui/source/inc/grfpage.hxx b/cui/source/inc/grfpage.hxx index 769937bcc75f..9d53f2cc29db 100644 --- a/cui/source/inc/grfpage.hxx +++ b/cui/source/inc/grfpage.hxx @@ -101,9 +101,9 @@ class SvxGrfCropPage : public SfxTabPage const MetricField* pLastCropField; long nOldWidth; long nOldHeight; - BOOL bReset; - BOOL bInitialized; - BOOL bSetOrigSize; + sal_Bool bReset; + sal_Bool bInitialized; + sal_Bool bSetOrigSize; SvxGrfCropPage( Window *pParent, const SfxItemSet &rSet ); @@ -119,14 +119,14 @@ class SvxGrfCropPage : public SfxTabPage void CalcZoom(); void CalcMinMaxBorder(); - void GraphicHasChanged(BOOL bFound); + void GraphicHasChanged(sal_Bool bFound); virtual void ActivatePage(const SfxItemSet& rSet); Size GetGrfOrigSize( const Graphic& ) const; public: static SfxTabPage *Create( Window *pParent, const SfxItemSet &rSet ); - virtual BOOL FillItemSet( SfxItemSet &rSet ); + virtual sal_Bool FillItemSet( SfxItemSet &rSet ); virtual void Reset( const SfxItemSet &rSet ); virtual int DeactivatePage( SfxItemSet *pSet ); }; diff --git a/cui/source/inc/hangulhanjadlg.hxx b/cui/source/inc/hangulhanjadlg.hxx index 1771cbc192e3..94543a8c553a 100644 --- a/cui/source/inc/hangulhanjadlg.hxx +++ b/cui/source/inc/hangulhanjadlg.hxx @@ -76,11 +76,11 @@ namespace svx void Clear(); void InsertEntry( const XubString& rStr ); - void SelectEntryPos( USHORT nPos ); + void SelectEntryPos( sal_uInt16 nPos ); - USHORT GetEntryCount() const; + sal_uInt16 GetEntryCount() const; - XubString GetEntry( USHORT nPos ) const; + XubString GetEntry( sal_uInt16 nPos ) const; XubString GetSelectEntry() const; virtual void StateChanged( StateChangedType nStateChange ); @@ -153,7 +153,6 @@ namespace svx void SetIgnoreAllHdl( const Link& _rHdl ); void SetChangeHdl( const Link& _rHdl ); void SetChangeAllHdl( const Link& _rHdl ); - void SetOptionsHdl( const Link& _rHdl ); void SetClickByCharacterHdl( const Link& _rHdl ); void SetConversionFormatChangedHdl( const Link& _rHdl ); @@ -175,8 +174,6 @@ namespace svx editeng::HangulHanjaConversion::ConversionFormat GetConversionFormat( ) const; void SetByCharacter( sal_Bool _bByCharacter ); - sal_Bool GetByCharacter( ) const; - void SetConversionDirectionState( sal_Bool _bTryBothDirections, editeng::HangulHanjaConversion::ConversionDirection _ePrimaryConversionDirection ); // should text which does not match the primary conversion direction be ignored? diff --git a/cui/source/inc/headertablistbox.hxx b/cui/source/inc/headertablistbox.hxx index 426bd39e69b4..2eba0a088073 100644..100755 --- a/cui/source/inc/headertablistbox.hxx +++ b/cui/source/inc/headertablistbox.hxx @@ -51,7 +51,7 @@ public: void ConnectElements( void ); // should be called after all manipulations on elements are done // calcs real sizes depending on sizes of this - void Show( BOOL bVisible = TRUE, USHORT nFlags = 0 ); // same meaning as Windows::Show() + void Show( sal_Bool bVisible = sal_True, sal_uInt16 nFlags = 0 ); // same meaning as Windows::Show() void Enable( bool bEnable = true, bool bChild = true ); // same meaning as Windows::Enable() }; diff --git a/cui/source/inc/helpid.hrc b/cui/source/inc/helpid.hrc index 6607c5aee4db..dff73253b086 100755..100644 --- a/cui/source/inc/helpid.hrc +++ b/cui/source/inc/helpid.hrc @@ -28,373 +28,363 @@ #define _CUI_HELPID_HRC // include --------------------------------------------------------------- -#include <svl/solar.hrc> +#include <svx/svxcommands.h> +#include <sfx2/sfxcommands.h> // Help-Ids -------------------------------------------------------------- -#define HID_OPTIONS_COLOR (HID_CUI_START + 1) -#define HID_OPTIONS_SAVE (HID_CUI_START + 2) -#define HID_OPTIONS_PATH (HID_CUI_START + 3) -#define HID_OPTIONS_GENERAL (HID_CUI_START + 4) -#define HID_OPTIONS_LINGU (HID_CUI_START + 5) -#define HID_OPTIONS_SPELL (HID_CUI_START + 6) -#define HID_OPTIONS_DICT_NEW (HID_CUI_START + 7) -#define HID_OPTIONS_DICT_EDIT (HID_CUI_START + 8) -#define HID_OPTIONS_INET (HID_CUI_START + 9) -#define HID_OPTIONS_CHART_DEFCOLORS (HID_CUI_START + 10) -#define HID_OPTIONS_CTL (HID_CUI_START + 11) -#define HID_OPTIONS_PROXY (HID_CUI_START + 12) -#define HID_OPTIONS_SEARCH (HID_CUI_START + 13) -#define HID_OPTIONS_MAIL (HID_CUI_START + 14) -#define HID_OPTIONS_ASIAN_LAYOUT (HID_CUI_START + 15) -#define HID_CLB_EDIT_MODULES_DICS (HID_CUI_START + 16) -#define HID_CLB_EDIT_MODULES_MODULES (HID_CUI_START + 17) -#define HID_CLB_LINGU_MODULES (HID_CUI_START + 18) -#define HID_CLB_LINGU_OPTIONS (HID_CUI_START + 19) -#define HID_EDIT_MODULES (HID_CUI_START + 20) -#define HID_LNGDLG_NUM_PREBREAK (HID_CUI_START + 21) -#define HID_OPTIONS_COLORCONFIG (HID_CUI_START + 22) -#define HID_OPTIONS_COLORCONFIG_SAVE_SCHEME (HID_CUI_START + 23) -#define HID_OPTIONS_ACCESSIBILITYCONFIG (HID_CUI_START + 24) -#define HID_OPTIONS_COLORCONFIG_COLORLIST_WIN (HID_CUI_START + 25) -#define HID_OPTIONS_COLORCONFIG_NAME_SCHEME (HID_CUI_START + 26) -#define HID_OPTIONS_PATHS_SELECTFOLDER (HID_CUI_START + 27) -#define HID_OPTIONS_JAVA (HID_CUI_START + 28) -#define HID_OPTIONS_JAVA_LIST (HID_CUI_START + 29) -#define HID_OPTIONS_JAVA_PARAMETER (HID_CUI_START + 30) -#define HID_OPTIONS_JAVA_CLASSPATH (HID_CUI_START + 31) -#define HID_SVXPAGE_JSEARCH_OPTIONS (HID_CUI_START + 32) -#define HID_SVXDLG_FILTER_WARNING (HID_CUI_START + 33) -#define HID_SVX_OPTIONS_ONLINEUPDATE (HID_CUI_START + 34) -#define HID_DLG_SECURITY_OPTIONS (HID_CUI_START + 35) -#define HID_OFADLG_OPTIONS_TREE (HID_CUI_START + 36) -#define HID_OFA_CONNPOOL_DRIVERLIST (HID_CUI_START + 37) -#define UID_OFA_CONNPOOL_DRIVERLIST_BACK (HID_CUI_START + 38) -#define HID_OFA_FONT_SUBST_CLB (HID_CUI_START + 39) -#define HID_OFA_TP_MISC (HID_CUI_START + 40) -#define HID_OFA_TP_VIEW (HID_CUI_START + 41) -#define HID_OFA_TP_LANGUAGES (HID_CUI_START + 42) -#define HID_OFA_TP_MEMORY (HID_CUI_START + 43) -#define HID_DBPATH_CTL_PATH (HID_CUI_START + 44) -#define HID_DBPATH_HEADERBAR (HID_CUI_START + 45) -#define HID_OFAPAGE_SMARTTAG_OPTIONS (HID_CUI_START + 46) -#define HID_OFAPAGE_MSFLTR2_CLB (HID_CUI_START + 47) -#define HID_OPTPATH_CTL_PATH (HID_CUI_START + 48) -#define HID_OFADLG_TREELISTBOX (HID_CUI_START + 49) -#define HID_DLG_WEBCONNECTION_INFO (HID_CUI_START + 50) -#define HID_OPTIONS_DICT_EDIT_ENTRIES_LIST (HID_CUI_START + 51) -#define HID_OPTPATH_HEADERBAR (HID_CUI_START + 52) -#define HID_WARN_NAME_DUPLICATE (HID_CUI_START + 53) -#define HID_COLORPAGE_LISTBOX_START (HID_CUI_START + 54) -#define HID_COLORPAGE_DOCCOLOR_LB (HID_CUI_START + 54) -#define HID_COLORPAGE_DOCBOUNDARIES_LB (HID_CUI_START + 55) -#define HID_COLORPAGE_APPBACKGROUND_LB (HID_CUI_START + 56) -#define HID_COLORPAGE_OBJECTBOUNDARIES_LB (HID_CUI_START + 57) -#define HID_COLORPAGE_TABLEBOUNDARIES_LB (HID_CUI_START + 58) -#define HID_COLORPAGE_FONTCOLOR_LB (HID_CUI_START + 59) -#define HID_COLORPAGE_LINKS_LB (HID_CUI_START + 60) -#define HID_COLORPAGE_LINKSVISITED_LB (HID_CUI_START + 61) -#define HID_COLORPAGE_ANCHOR_LB (HID_CUI_START + 62) -#define HID_COLORPAGE_SPELL_LB (HID_CUI_START + 63) -#define HID_COLORPAGE_WRITERTEXTGRID_LB (HID_CUI_START + 64) -#define HID_COLORPAGE_WRITERFIELDSHADINGS_LB (HID_CUI_START + 65) -#define HID_COLORPAGE_WRITERIDXSHADINGS_LB (HID_CUI_START + 66) -#define HID_COLORPAGE_WRITERDIRECTCURSOR_LB (HID_CUI_START + 67) -#define HID_COLORPAGE_WRITERNOTESINDICATOR_LB (HID_CUI_START + 68) -#define HID_COLORPAGE_WRITERSCRIPTINDICATOR_LB (HID_CUI_START + 69) -#define HID_COLORPAGE_WRITERSECTIONBOUNDARIES_LB (HID_CUI_START + 70) -#define HID_COLORPAGE_WRITERPAGEBREAKS_LB (HID_CUI_START + 71) -#define HID_COLORPAGE_HTMLSGML_LB (HID_CUI_START + 72) -#define HID_COLORPAGE_HTMLCOMMENT_LB (HID_CUI_START + 73) -#define HID_COLORPAGE_HTMLKEYWORD_LB (HID_CUI_START + 74) -#define HID_COLORPAGE_HTMLUNKNOWN_LB (HID_CUI_START + 75) -#define HID_COLORPAGE_CALCGRID_LB (HID_CUI_START + 76) -#define HID_COLORPAGE_CALCPAGEBREAK_LB (HID_CUI_START + 77) -#define HID_COLORPAGE_CALCPAGEBREAKMANUAL_LB (HID_CUI_START + 78) -#define HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_LB (HID_CUI_START + 79) -#define HID_COLORPAGE_CALCDETECTIVE_LB (HID_CUI_START + 80) -#define HID_COLORPAGE_CALCDETECTIVEERROR_LB (HID_CUI_START + 81) -#define HID_COLORPAGE_CALCREFERENCE_LB (HID_CUI_START + 82) -#define HID_COLORPAGE_CALCNOTESBACKGROUND_LB (HID_CUI_START + 83) -#define HID_COLORPAGE_DRAWGRID_LB (HID_CUI_START + 84) -#define HID_COLORPAGE_DRAWDRAWING_LB (HID_CUI_START + 85) -#define HID_COLORPAGE_DRAWFILL_LB (HID_CUI_START + 86) -#define HID_COLORPAGE_BASICIDENTIFIER_LB (HID_CUI_START + 87) -#define HID_COLORPAGE_BASICCOMMENT_LB (HID_CUI_START + 88) -#define HID_COLORPAGE_BASICNUMBER_LB (HID_CUI_START + 89) -#define HID_COLORPAGE_BASICSTRING_LB (HID_CUI_START + 90) -#define HID_COLORPAGE_BASICOPERATOR_LB (HID_CUI_START + 91) -#define HID_COLORPAGE_BASICKEYWORD_LB (HID_CUI_START + 92) -#define HID_COLORPAGE_BASICERROR_LB (HID_CUI_START + 93) -#define HID_COLORPAGE_CHECKBOX_START (HID_CUI_START + 94) -#define HID_COLORPAGE_DOCCOLOR_CB (HID_CUI_START + 94) -#define HID_COLORPAGE_DOCBOUNDARIES_CB (HID_CUI_START + 95) -#define HID_COLORPAGE_APPBACKGROUND_CB (HID_CUI_START + 96) -#define HID_COLORPAGE_OBJECTBOUNDARIES_CB (HID_CUI_START + 97) -#define HID_COLORPAGE_TABLEBOUNDARIES_CB (HID_CUI_START + 98) -#define HID_COLORPAGE_FONTCOLOR_CB (HID_CUI_START + 99) -#define HID_COLORPAGE_LINKS_CB (HID_CUI_START + 100) -#define HID_COLORPAGE_LINKSVISITED_CB (HID_CUI_START + 101) -#define HID_COLORPAGE_ANCHOR_CB (HID_CUI_START + 102) -#define HID_COLORPAGE_SPELL_CB (HID_CUI_START + 103) -#define HID_COLORPAGE_WRITERTEXTGRID_CB (HID_CUI_START + 104) -#define HID_COLORPAGE_WRITERFIELDSHADINGS_CB (HID_CUI_START + 105) -#define HID_COLORPAGE_WRITERIDXSHADINGS_CB (HID_CUI_START + 106) -#define HID_COLORPAGE_WRITERDIRECTCURSOR_CB (HID_CUI_START + 107) -#define HID_COLORPAGE_WRITERNOTESINDICATOR_CB (HID_CUI_START + 108) -#define HID_COLORPAGE_WRITERSCRIPTINDICATOR_CB (HID_CUI_START + 109) -#define HID_COLORPAGE_WRITERSECTIONBOUNDARIES_CB (HID_CUI_START + 110) -#define HID_COLORPAGE_WRITERPAGEBREAKS_CB (HID_CUI_START + 111) -#define HID_COLORPAGE_HTMLSGML_CB (HID_CUI_START + 112) -#define HID_COLORPAGE_HTMLCOMMENT_CB (HID_CUI_START + 113) -#define HID_COLORPAGE_HTMLKEYWORD_CB (HID_CUI_START + 114) -#define HID_COLORPAGE_HTMLUNKNOWN_CB (HID_CUI_START + 115) -#define HID_COLORPAGE_CALCGRID_CB (HID_CUI_START + 116) -#define HID_COLORPAGE_CALCPAGEBREAK_CB (HID_CUI_START + 117) -#define HID_COLORPAGE_CALCPAGEBREAKMANUAL_CB (HID_CUI_START + 118) -#define HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_CB (HID_CUI_START + 119) -#define HID_COLORPAGE_CALCDETECTIVE_CB (HID_CUI_START + 120) -#define HID_COLORPAGE_CALCDETECTIVEERROR_CB (HID_CUI_START + 121) -#define HID_COLORPAGE_CALCREFERENCE_CB (HID_CUI_START + 122) -#define HID_COLORPAGE_CALCNOTESBACKGROUND_CB (HID_CUI_START + 123) -#define HID_COLORPAGE_DRAWGRID_CB (HID_CUI_START + 124) -#define HID_COLORPAGE_DRAWDRAWING_CB (HID_CUI_START + 125) -#define HID_COLORPAGE_DRAWFILL_CB (HID_CUI_START + 126) -#define HID_COLORPAGE_BASICIDENTIFIER_CB (HID_CUI_START + 127) -#define HID_COLORPAGE_BASICCOMMENT_CB (HID_CUI_START + 128) -#define HID_COLORPAGE_BASICNUMBER_CB (HID_CUI_START + 129) -#define HID_COLORPAGE_BASICSTRING_CB (HID_CUI_START + 130) -#define HID_COLORPAGE_BASICOPERATOR_CB (HID_CUI_START + 131) -#define HID_COLORPAGE_BASICKEYWORD_CB (HID_CUI_START + 132) -#define HID_COLORPAGE_BASICERROR_CB (HID_CUI_START + 133) -#define HID_NUMBERINGOPT_SEL_GRF_FROM_FILE (HID_CUI_START + 134) -#define HID_SVX_MACRO_LB_EVENT (HID_CUI_START + 135) -#define HID_SVX_CONFIG_EVENT (HID_CUI_START + 136) -#define HID_CONFIG_EVENT_OFFICE_BASED (HID_CUI_START + 137) -#define HID_CONFIG_EVENT_DOCUMENT_BASED (HID_CUI_START + 138) -#define HID_SELECTOR_DIALOG (HID_CUI_START + 139) -#define HID_SELECTOR_CATEGORIES (HID_CUI_START + 140) -#define HID_SVX_CONFIG_TOOLBAR (HID_CUI_START + 141) -#define HID_SVX_CONFIG_TOOLBAR_CONTENTS (HID_CUI_START + 142) -#define HID_SELECTOR_COMMANDS (HID_CUI_START + 143) -#define HID_GALLERY_EDIT_MSNAME (HID_CUI_START + 144) -#define HID_SVX_CONFIG_MENU (HID_CUI_START + 145) -#define HID_SVX_CONFIG_MENU_CONTENTS (HID_CUI_START + 146) -#define HID_GALLERY_NEWTHEME_FINDFILES (HID_CUI_START + 147) -#define HID_GALLERY_NEWTHEME_ADDFILES (HID_CUI_START + 148) -#define HID_HANGULDLG_BUTTON_OPTIONS (HID_CUI_START + 149) -#define HID_HANGULDLG_BUTTON_CLOSE (HID_CUI_START + 150) -#define HID_HANGULDLG_BUTTON_IGNORE (HID_CUI_START + 151) -#define HID_HANGULDLG_BUTTON_IGNOREALL (HID_CUI_START + 152) -#define HID_HANGULDLG_BUTTON_CHANGE (HID_CUI_START + 153) -#define HID_HANGULDLG_BUTTON_CHANGEALL (HID_CUI_START + 154) -#define HID_OFA_FONT_SUBSTITUTION (HID_CUI_START + 155) -#define HID_HANGULDLG_EDIT_NEWWORD (HID_CUI_START + 156) -#define HID_OFA_SUBST_APPLY (HID_CUI_START + 157) -#define HID_OFA_SUBST_DELETE (HID_CUI_START + 158) -#define HID_SPLDLG_BUTTON_CLOSE (HID_CUI_START + 159) -#define HID_SPLDLG_BUTTON_IGNORE (HID_CUI_START + 160) -#define HID_SPLDLG_BUTTON_IGNOREALL (HID_CUI_START + 161) -#define HID_SPLDLG_BUTTON_CHANGE (HID_CUI_START + 162) -#define HID_SPLDLG_BUTTON_CHANGEALL (HID_CUI_START + 163) -#define HID_SPLDLG_BUTTON_EXPLAIN (HID_CUI_START + 164) -#define HID_CHARMAP_CTL_SHOWSET (HID_CUI_START + 165) -#define HID_CHARMAP_CTL_SHOWTEXT (HID_CUI_START + 166) -#define HID_CHARMAP_CTL_SHOWCHAR (HID_CUI_START + 167) -#define HID_DLG_NAME (HID_CUI_START + 168) -#define HID_DLG_MESSBOX (HID_CUI_START + 169) -#define HID_HANGULDLG_SUGGESTIONS (HID_CUI_START + 170) -#define HID_HANGULDLG_SUGGESTIONS_GRID (HID_CUI_START + 171) -#define HID_HANGULDLG_SUGGESTIONS_LIST (HID_CUI_START + 172) -#define HID_DLG_OBJECT_NAME (HID_CUI_START + 173) -#define HID_DLG_OBJECT_TITLE_DESC (HID_CUI_START + 174) -#define HID_SVX_CONFIG_MENU_ORGANIZER (HID_CUI_START + 175) -#define HID_SVX_CONFIG_ICON_SELECTOR (HID_CUI_START + 176) -#define HID_SVX_CONFIG_NAME_SUBMENU (HID_CUI_START + 177) -#define HID_SVX_CONFIG_RENAME_MENU (HID_CUI_START + 178) -#define HID_SVX_CONFIG_RENAME_MENU_ITEM (HID_CUI_START + 179) -#define HID_SVX_CONFIG_RENAME_TOOLBAR (HID_CUI_START + 180) -#define HID_SVX_CONFIG_RENAME_TOOLBAR_ITEM (HID_CUI_START + 181) -#define HID_SVX_NEW_TOOLBAR (HID_CUI_START + 182) -#define HID_SVX_MODIFY_TOOLBAR (HID_CUI_START + 183) -#define HID_SVX_NEW_TOOLBAR_ITEM (HID_CUI_START + 184) -#define HID_SVX_CONFIG_MENU_LISTBOX (HID_CUI_START + 185) -#define HID_SVX_MODIFY_TOOLBAR_ITEM (HID_CUI_START + 186) -#define HID_SVX_SAVE_IN (HID_CUI_START + 187) -#define HID_OPTIONS_MULTIPATH_LIST (HID_CUI_START + 188) -#define HID_FM_DLG_SEARCH (HID_CUI_START + 189) -#define HID_SEARCH_TEXT (HID_CUI_START + 190) -#define HID_SEARCH_ALLFIELDS (HID_CUI_START + 191) -#define HID_GALLERY_PROPERTIES_GENERAL (HID_CUI_START + 192) -#define HID_SEARCH_FIELDSELECTION (HID_CUI_START + 193) -#define HID_SEARCH_POSITION (HID_CUI_START + 194) -#define HID_SEARCH_FORMATTER (HID_CUI_START + 195) -#define HID_SEARCH_CASE (HID_CUI_START + 196) -#define HID_SEARCH_BACKWARD (HID_CUI_START + 197) -#define HID_SEARCH_STARTOVER (HID_CUI_START + 198) -#define HID_SEARCH_WILDCARD (HID_CUI_START + 199) -#define HID_SEARCH_REGULAR (HID_CUI_START + 200) -#define HID_SEARCH_APPROX (HID_CUI_START + 201) -#define HID_SEARCH_APPROXSETTINGS (HID_CUI_START + 202) -#define HID_SEARCH_BTN_SEARCH (HID_CUI_START + 203) -#define HID_SEARCH_BTN_CLOSE (HID_CUI_START + 204) -#define HID_GALLERY_BROWSER (HID_CUI_START + 205) -#define HID_GALLERY_SEARCH (HID_CUI_START + 206) -#define HID_GALLERY_APPLY (HID_CUI_START + 207) -#define HID_SPLDLG_BUTTON_IGNORERULE (HID_CUI_START + 208) -#define HID_CONFIG_ACCEL (HID_CUI_START + 209) -#define HID_ACCELCONFIG_LISTBOX (HID_CUI_START + 210) -#define HID_CONFIGGROUP_ACC_LISTBOX (HID_CUI_START + 211) -#define HID_CONFIGFUNCTION_ACC_LISTBOX (HID_CUI_START + 212) -#define HID_MACRO_LB_EVENT (HID_CUI_START + 213) -#define HID_MACRO_GROUP (HID_CUI_START + 214) -#define HID_MACRO_MACROS (HID_CUI_START + 215) -#define HID_DIALOG_HANGULHANJA (HID_CUI_START + 216) -#define HID_HANGULHANJA_OPT_DLG (HID_CUI_START + 217) -#define HID_HANGULHANJA_NEWDICT_DLG (HID_CUI_START + 218) -#define HID_HANGULHANJA_EDIT_DLG (HID_CUI_START + 219) -#define HID_HANGULHANJA_OPT_DICTS_LB (HID_CUI_START + 220) -#define HID_MULTIPATH (HID_CUI_START + 221) -#define HID_SCRIPTORG_DIALOG (HID_CUI_START + 222) -#define HID_SCRIPTSBOX (HID_CUI_START + 223) -#define HID_SPELLCHECK (HID_CUI_START + 224) -#define HID_TPSIZE_CTRL (HID_CUI_START + 225) -#define HID_TPROTATION_CTRL1 (HID_CUI_START + 226) -#define HID_TPROTATION_CTRL2 (HID_CUI_START + 227) -#define HID_TRANS_ANGLE (HID_CUI_START + 228) -#define HID_TPPOSITION_CTRL (HID_CUI_START + 229) -#define HID_NUMBERFORMAT_LB_FORMAT (HID_CUI_START + 230) -#define HID_NUMBERFORMAT_WND_NUMBER_PREVIEW (HID_CUI_START + 231) -#define HID_TRANS_SLANT (HID_CUI_START + 232) -#define HID_TPHATCH_CTRL (HID_CUI_START + 233) -#define HID_SEARCHATTR_CTL_ATTR (HID_CUI_START + 234) -#define HID_NUMBERFORMAT_TBI_INFO (HID_CUI_START + 235) -#define HID_SEARCHATTR (HID_CUI_START + 236) -#define HID_ALIGNMENT_CTR_DIAL (HID_CUI_START + 237) -#define HID_ALIGNMENT_CTR_BORDER_LOCK (HID_CUI_START + 238) -#define HID_SEARCHSIMILARITY (HID_CUI_START + 239) -#define UID_SEARCH_RECORDSTATUS (HID_CUI_START + 240) -#define HID_OFAPAGE_AUTOCORR_CLB (HID_CUI_START + 241) -#define HID_AUTOCORR_LANGUAGE (HID_CUI_START + 242) -#define HID_OFAPAGE_AUTOFORMAT_CLB (HID_CUI_START + 243) -#define HID_TPCOLOR_RGB_1 (HID_CUI_START + 244) -#define HID_TPCOLOR_RGB_2 (HID_CUI_START + 245) -#define HID_TPCOLOR_RGB_3 (HID_CUI_START + 246) -#define HID_TPCOLOR_CMYK_1 (HID_CUI_START + 247) -#define HID_TPCOLOR_CMYK_2 (HID_CUI_START + 248) -#define HID_TPCOLOR_CMYK_3 (HID_CUI_START + 249) -#define HID_ALIGNMENT (HID_CUI_START + 250) -#define HID_OFAPAGE_AUTOCORR_OPTIONS (HID_CUI_START + 251) -#define HID_OFAPAGE_AUTOFMT_OPTIONS (HID_CUI_START + 252) -#define HID_OFAPAGE_AUTOCORR_REPLACE (HID_CUI_START + 253) -#define HID_OFACTL_AUTOCORR_REPLACE (HID_CUI_START + 254) -#define HID_OFAPAGE_AUTOCORR_EXCEPT (HID_CUI_START + 255) -#define HID_OFAPAGE_AUTOCORR_QUOTE (HID_CUI_START + 256) -#define HID_OFAPAGE_AUTOCOMPLETE_OPTIONS (HID_CUI_START + 257) -#define HID_BACKGROUND (HID_CUI_START + 258) -#define HID_BACKGROUND_CTL_BGDCOLORSET (HID_CUI_START + 259) -#define HID_BACKGROUND_CTL_POSITION (HID_CUI_START + 260) -#define HID_BORDER (HID_CUI_START + 261) -#define HID_BORDER_CTL_PRESETS (HID_CUI_START + 262) -#define HID_BORDER_CTL_SHADOWS (HID_CUI_START + 263) -#define HID_PAGE_CONNECTION (HID_CUI_START + 264) -#define HID_PAGE_CONNECTION_CTL_PREVIEW (HID_CUI_START + 265) -#define HID_PAGE_DISTRIBUTE (HID_CUI_START + 266) -#define HID_SVXPAGE_GRFCROP (HID_CUI_START + 267) -#define HID_CAPTION (HID_CUI_START + 268) -#define HID_CAPTION_CTL_TYPE (HID_CUI_START + 269) -#define HID_PAGE_MEASURE (HID_CUI_START + 270) -#define HID_MEASURE_CTL_POSITION (HID_CUI_START + 271) -#define HID_NUMBERFORMAT (HID_CUI_START + 272) -#define HID_NUMBERFORMAT_TBI_ADD (HID_CUI_START + 273) -#define HID_NUMBERFORMAT_TBI_REMOVE (HID_CUI_START + 274) -#define HID_FORMAT_PAGE (HID_CUI_START + 275) -#define HID_REDLINING_DLG (HID_CUI_START + 276) -#define HID_REDLINING_EDIT (HID_CUI_START + 277) -#define HID_REDLINING_PREV (HID_CUI_START + 278) -#define HID_REDLINING_NEXT (HID_CUI_START + 279) -#define HID_FORMAT_PARAGRAPH_STD (HID_CUI_START + 280) -#define HID_VALUESET_SINGLENUM (HID_CUI_START + 281) -#define HID_VALUESET_BULLET (HID_CUI_START + 282) -#define HID_VALUESET_NUM (HID_CUI_START + 283) -#define HID_VALUESET_NUMBMP (HID_CUI_START + 284) -#define HID_SVXPAGE_PICK_NUM (HID_CUI_START + 285) -#define HID_SVXPAGE_PICK_SINGLE_NUM (HID_CUI_START + 286) -#define HID_SVXPAGE_PICK_BMP (HID_CUI_START + 287) -#define HID_SVXPAGE_PICK_BULLET (HID_CUI_START + 288) -#define HID_SVXPAGE_NUM_OPTIONS (HID_CUI_START + 289) -#define HID_SVXPAGE_NUM_POSITION (HID_CUI_START + 290) -#define HID_MEASURE_CTL_PREVIEW (HID_CUI_START + 291) -#define HID_FORMAT_PARAGRAPH_EXT (HID_CUI_START + 292) -#define HID_FORMAT_PARAGRAPH_ALIGN (HID_CUI_START + 293) -#define HID_SVXPAGE_PARA_ASIAN (HID_CUI_START + 294) -#define HID_SVXPAGE_SWPOSSIZE (HID_CUI_START + 295) -#define HID_AREA_TRANSPARENCE (HID_CUI_START + 296) -#define HID_AREA_AREA (HID_CUI_START + 297) -#define HID_AREA_SHADOW (HID_CUI_START + 298) -#define HID_AREA_HATCH (HID_CUI_START + 299) -#define HID_AREA_BITMAP (HID_CUI_START + 300) -#define HID_TPSHADOW_CTRL (HID_CUI_START + 301) -#define HID_AREA_GRADIENT (HID_CUI_START + 302) -#define HID_LINE_ENDDEF (HID_CUI_START + 303) -#define HID_LINE_LINE (HID_CUI_START + 304) -#define HID_LINE_DEF (HID_CUI_START + 305) -#define HID_SPELLDLG_SETWORD (HID_CUI_START + 306) -#define HID_TABULATOR (HID_CUI_START + 307) -#define HID_PAGE_TEXTATTR (HID_CUI_START + 308) -#define HID_TEXTATTR_CTL_POSITION (HID_CUI_START + 309) -#define HID_TRANS_POSITION_SIZE (HID_CUI_START + 310) -#define HID_HYPHENATE (HID_CUI_START + 311) -#define HID_SVXPAGE_CHAR_NAME (HID_CUI_START + 312) -#define HID_SVXPAGE_CHAR_EFFECTS (HID_CUI_START + 313) -#define HID_SVXPAGE_CHAR_POSITION (HID_CUI_START + 314) -#define HID_HYPERLINK_INTERNET (HID_CUI_START + 315) -#define HID_HYPERLINK_MAIL (HID_CUI_START + 316) -#define HID_HYPERLINK_DOCUMENT (HID_CUI_START + 317) -#define HID_HYPERLINK_NEWDOCUMENT (HID_CUI_START + 318) -#define HID_HYPERLINK_MARKWND (HID_CUI_START + 319) -#define HID_ICCDIALOG_RESET_BTN (HID_CUI_START + 320) -#define HID_ICCDIALOG_CHOICECTRL (HID_CUI_START + 321) -#define HID_HYPERDLG_INET_PATH (HID_CUI_START + 322) -#define HID_HYPERDLG_MAIL_PATH (HID_CUI_START + 323) -#define HID_HYPERDLG_DOC_PATH (HID_CUI_START + 324) -#define HID_ICCDIALOG_OK_BTN (HID_CUI_START + 325) -#define HID_ICCDIALOG_CANCEL_BTN (HID_CUI_START + 326) -#define HID_HYPERLINK_MARKWND_APPLY (HID_CUI_START + 327) -#define HID_HYPERLINK_MARKWND_CLOSE (HID_CUI_START + 328) -#define HID_HYPERLINK_MARKWND_TREE (HID_CUI_START + 329) -#define HID_SVXPAGE_CHAR_TWOLINES (HID_CUI_START + 330) -#define HID_GRFFILTER_EMBOSS_LIGHT (HID_CUI_START + 331) -#define HID_PASTE_DLG (HID_CUI_START + 333) -#define HID_LINKDLG_TABLB (HID_CUI_START + 334) -#define HID_MACRO_HEADERTABLISTBOX (HID_CUI_START + 335) -#define HID_GALLERY_ENTER_TITLE (HID_CUI_START + 336) -#define HID_GALLERY_TITLE_EDIT (HID_CUI_START + 337) -#define HID_THES_LANGUAGE (HID_CUI_START + 338) -#define HID_OFAPAGE_QUOTE_SW_CLB (HID_CUI_START + 339) -#define HID_OFAPAGE_QUOTE_CLB (HID_CUI_START + 340) -#define HID_CT_THES_ALTERNATIVES (HID_CUI_START + 341) +#define HID_OPTIONS_COLOR "CUI_HID_OPTIONS_COLOR" +#define HID_OPTIONS_SAVE "CUI_HID_OPTIONS_SAVE" +#define HID_OPTIONS_PATH "CUI_HID_OPTIONS_PATH" +#define HID_OPTIONS_GENERAL "CUI_HID_OPTIONS_GENERAL" +#define HID_OPTIONS_LINGU "CUI_HID_OPTIONS_LINGU" +#define HID_OPTIONS_SPELL "CUI_HID_OPTIONS_SPELL" +#define HID_OPTIONS_DICT_NEW "CUI_HID_OPTIONS_DICT_NEW" +#define HID_OPTIONS_DICT_EDIT "CUI_HID_OPTIONS_DICT_EDIT" +#define HID_OPTIONS_INET "CUI_HID_OPTIONS_INET" +#define HID_OPTIONS_CHART_DEFCOLORS "CUI_HID_OPTIONS_CHART_DEFCOLORS" +#define HID_OPTIONS_CTL "CUI_HID_OPTIONS_CTL" +#define HID_OPTIONS_PROXY "CUI_HID_OPTIONS_PROXY" +#define HID_OPTIONS_SEARCH "CUI_HID_OPTIONS_SEARCH" +#define HID_OPTIONS_MAIL "CUI_HID_OPTIONS_MAIL" +#define HID_OPTIONS_ASIAN_LAYOUT "CUI_HID_OPTIONS_ASIAN_LAYOUT" +#define HID_CLB_EDIT_MODULES_DICS "CUI_HID_CLB_EDIT_MODULES_DICS" +#define HID_CLB_EDIT_MODULES_MODULES "CUI_HID_CLB_EDIT_MODULES_MODULES" +#define HID_CLB_LINGU_MODULES "CUI_HID_CLB_LINGU_MODULES" +#define HID_CLB_LINGU_OPTIONS "CUI_HID_CLB_LINGU_OPTIONS" +#define HID_EDIT_MODULES "CUI_HID_EDIT_MODULES" +#define HID_LNGDLG_NUM_PREBREAK "CUI_HID_LNGDLG_NUM_PREBREAK" +#define HID_OPTIONS_COLORCONFIG "CUI_HID_OPTIONS_COLORCONFIG" +#define HID_OPTIONS_COLORCONFIG_SAVE_SCHEME "CUI_HID_OPTIONS_COLORCONFIG_SAVE_SCHEME" +#define HID_OPTIONS_ACCESSIBILITYCONFIG "CUI_HID_OPTIONS_ACCESSIBILITYCONFIG" +#define HID_OPTIONS_COLORCONFIG_COLORLIST_WIN "CUI_HID_OPTIONS_COLORCONFIG_COLORLIST_WIN" +#define HID_OPTIONS_COLORCONFIG_NAME_SCHEME "CUI_HID_OPTIONS_COLORCONFIG_NAME_SCHEME" +#define HID_OPTIONS_PATHS_SELECTFOLDER "CUI_HID_OPTIONS_PATHS_SELECTFOLDER" +#define HID_OPTIONS_JAVA "CUI_HID_OPTIONS_JAVA" +#define HID_OPTIONS_JAVA_LIST "CUI_HID_OPTIONS_JAVA_LIST" +#define HID_OPTIONS_JAVA_PARAMETER "CUI_HID_OPTIONS_JAVA_PARAMETER" +#define HID_OPTIONS_JAVA_CLASSPATH "CUI_HID_OPTIONS_JAVA_CLASSPATH" +#define HID_SVXPAGE_JSEARCH_OPTIONS "CUI_HID_SVXPAGE_JSEARCH_OPTIONS" +#define HID_SVXDLG_FILTER_WARNING "CUI_HID_SVXDLG_FILTER_WARNING" +#define HID_SVX_OPTIONS_ONLINEUPDATE "CUI_HID_SVX_OPTIONS_ONLINEUPDATE" +#define HID_DLG_SECURITY_OPTIONS "CUI_HID_DLG_SECURITY_OPTIONS" +#define HID_OFADLG_OPTIONS_TREE "CUI_HID_OFADLG_OPTIONS_TREE" +#define HID_OFA_CONNPOOL_DRIVERLIST "CUI_HID_OFA_CONNPOOL_DRIVERLIST" +#define UID_OFA_CONNPOOL_DRIVERLIST_BACK "CUI_UID_OFA_CONNPOOL_DRIVERLIST_BACK" +#define HID_OFA_FONT_SUBST_CLB "CUI_HID_OFA_FONT_SUBST_CLB" +#define HID_OFA_TP_MISC "CUI_HID_OFA_TP_MISC" +#define HID_OFA_TP_VIEW "CUI_HID_OFA_TP_VIEW" +#define HID_OFA_TP_LANGUAGES "CUI_HID_OFA_TP_LANGUAGES" +#define HID_OFA_TP_MEMORY "CUI_HID_OFA_TP_MEMORY" +#define HID_DBPATH_CTL_PATH "CUI_HID_DBPATH_CTL_PATH" +#define HID_DBPATH_HEADERBAR "CUI_HID_DBPATH_HEADERBAR" +#define HID_OFAPAGE_SMARTTAG_OPTIONS "CUI_HID_OFAPAGE_SMARTTAG_OPTIONS" +#define HID_OFAPAGE_MSFLTR2_CLB "CUI_HID_OFAPAGE_MSFLTR2_CLB" +#define HID_OPTPATH_CTL_PATH "CUI_HID_OPTPATH_CTL_PATH" +#define HID_OFADLG_TREELISTBOX "CUI_HID_OFADLG_TREELISTBOX" +#define HID_DLG_WEBCONNECTION_INFO "CUI_HID_DLG_WEBCONNECTION_INFO" +#define HID_OPTIONS_DICT_EDIT_ENTRIES_LIST "CUI_HID_OPTIONS_DICT_EDIT_ENTRIES_LIST" +#define HID_OPTPATH_HEADERBAR "CUI_HID_OPTPATH_HEADERBAR" +#define HID_WARN_NAME_DUPLICATE "CUI_HID_WARN_NAME_DUPLICATE" +#define HID_COLORPAGE_LISTBOX_START "CUI_HID_COLORPAGE_LISTBOX_START" +#define HID_COLORPAGE_DOCCOLOR_LB "CUI_HID_COLORPAGE_DOCCOLOR_LB" +#define HID_COLORPAGE_DOCBOUNDARIES_LB "CUI_HID_COLORPAGE_DOCBOUNDARIES_LB" +#define HID_COLORPAGE_APPBACKGROUND_LB "CUI_HID_COLORPAGE_APPBACKGROUND_LB" +#define HID_COLORPAGE_OBJECTBOUNDARIES_LB "CUI_HID_COLORPAGE_OBJECTBOUNDARIES_LB" +#define HID_COLORPAGE_TABLEBOUNDARIES_LB "CUI_HID_COLORPAGE_TABLEBOUNDARIES_LB" +#define HID_COLORPAGE_FONTCOLOR_LB "CUI_HID_COLORPAGE_FONTCOLOR_LB" +#define HID_COLORPAGE_LINKS_LB "CUI_HID_COLORPAGE_LINKS_LB" +#define HID_COLORPAGE_LINKSVISITED_LB "CUI_HID_COLORPAGE_LINKSVISITED_LB" +#define HID_COLORPAGE_ANCHOR_LB "CUI_HID_COLORPAGE_ANCHOR_LB" +#define HID_COLORPAGE_SPELL_LB "CUI_HID_COLORPAGE_SPELL_LB" +#define HID_COLORPAGE_WRITERTEXTGRID_LB "CUI_HID_COLORPAGE_WRITERTEXTGRID_LB" +#define HID_COLORPAGE_WRITERFIELDSHADINGS_LB "CUI_HID_COLORPAGE_WRITERFIELDSHADINGS_LB" +#define HID_COLORPAGE_WRITERIDXSHADINGS_LB "CUI_HID_COLORPAGE_WRITERIDXSHADINGS_LB" +#define HID_COLORPAGE_WRITERDIRECTCURSOR_LB "CUI_HID_COLORPAGE_WRITERDIRECTCURSOR_LB" +#define HID_COLORPAGE_WRITERNOTESINDICATOR_LB "CUI_HID_COLORPAGE_WRITERNOTESINDICATOR_LB" +#define HID_COLORPAGE_WRITERSCRIPTINDICATOR_LB "CUI_HID_COLORPAGE_WRITERSCRIPTINDICATOR_LB" +#define HID_COLORPAGE_WRITERSECTIONBOUNDARIES_LB "CUI_HID_COLORPAGE_WRITERSECTIONBOUNDARIES_LB" +#define HID_COLORPAGE_WRITERPAGEBREAKS_LB "CUI_HID_COLORPAGE_WRITERPAGEBREAKS_LB" +#define HID_COLORPAGE_HTMLSGML_LB "CUI_HID_COLORPAGE_HTMLSGML_LB" +#define HID_COLORPAGE_HTMLCOMMENT_LB "CUI_HID_COLORPAGE_HTMLCOMMENT_LB" +#define HID_COLORPAGE_HTMLKEYWORD_LB "CUI_HID_COLORPAGE_HTMLKEYWORD_LB" +#define HID_COLORPAGE_HTMLUNKNOWN_LB "CUI_HID_COLORPAGE_HTMLUNKNOWN_LB" +#define HID_COLORPAGE_CALCGRID_LB "CUI_HID_COLORPAGE_CALCGRID_LB" +#define HID_COLORPAGE_CALCPAGEBREAK_LB "CUI_HID_COLORPAGE_CALCPAGEBREAK_LB" +#define HID_COLORPAGE_CALCPAGEBREAKMANUAL_LB "CUI_HID_COLORPAGE_CALCPAGEBREAKMANUAL_LB" +#define HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_LB "CUI_HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_LB" +#define HID_COLORPAGE_CALCDETECTIVE_LB "CUI_HID_COLORPAGE_CALCDETECTIVE_LB" +#define HID_COLORPAGE_CALCDETECTIVEERROR_LB "CUI_HID_COLORPAGE_CALCDETECTIVEERROR_LB" +#define HID_COLORPAGE_CALCREFERENCE_LB "CUI_HID_COLORPAGE_CALCREFERENCE_LB" +#define HID_COLORPAGE_CALCNOTESBACKGROUND_LB "CUI_HID_COLORPAGE_CALCNOTESBACKGROUND_LB" +#define HID_COLORPAGE_DRAWGRID_LB "CUI_HID_COLORPAGE_DRAWGRID_LB" +#define HID_COLORPAGE_DRAWDRAWING_LB "CUI_HID_COLORPAGE_DRAWDRAWING_LB" +#define HID_COLORPAGE_DRAWFILL_LB "CUI_HID_COLORPAGE_DRAWFILL_LB" +#define HID_COLORPAGE_BASICIDENTIFIER_LB "CUI_HID_COLORPAGE_BASICIDENTIFIER_LB" +#define HID_COLORPAGE_BASICCOMMENT_LB "CUI_HID_COLORPAGE_BASICCOMMENT_LB" +#define HID_COLORPAGE_BASICNUMBER_LB "CUI_HID_COLORPAGE_BASICNUMBER_LB" +#define HID_COLORPAGE_BASICSTRING_LB "CUI_HID_COLORPAGE_BASICSTRING_LB" +#define HID_COLORPAGE_BASICOPERATOR_LB "CUI_HID_COLORPAGE_BASICOPERATOR_LB" +#define HID_COLORPAGE_BASICKEYWORD_LB "CUI_HID_COLORPAGE_BASICKEYWORD_LB" +#define HID_COLORPAGE_BASICERROR_LB "CUI_HID_COLORPAGE_BASICERROR_LB" +#define HID_COLORPAGE_CHECKBOX_START "CUI_HID_COLORPAGE_CHECKBOX_START" +#define HID_COLORPAGE_DOCCOLOR_CB "CUI_HID_COLORPAGE_DOCCOLOR_CB" +#define HID_COLORPAGE_DOCBOUNDARIES_CB "CUI_HID_COLORPAGE_DOCBOUNDARIES_CB" +#define HID_COLORPAGE_APPBACKGROUND_CB "CUI_HID_COLORPAGE_APPBACKGROUND_CB" +#define HID_COLORPAGE_OBJECTBOUNDARIES_CB "CUI_HID_COLORPAGE_OBJECTBOUNDARIES_CB" +#define HID_COLORPAGE_TABLEBOUNDARIES_CB "CUI_HID_COLORPAGE_TABLEBOUNDARIES_CB" +#define HID_COLORPAGE_FONTCOLOR_CB "CUI_HID_COLORPAGE_FONTCOLOR_CB" +#define HID_COLORPAGE_LINKS_CB "CUI_HID_COLORPAGE_LINKS_CB" +#define HID_COLORPAGE_LINKSVISITED_CB "CUI_HID_COLORPAGE_LINKSVISITED_CB" +#define HID_COLORPAGE_ANCHOR_CB "CUI_HID_COLORPAGE_ANCHOR_CB" +#define HID_COLORPAGE_SPELL_CB "CUI_HID_COLORPAGE_SPELL_CB" +#define HID_COLORPAGE_WRITERTEXTGRID_CB "CUI_HID_COLORPAGE_WRITERTEXTGRID_CB" +#define HID_COLORPAGE_WRITERFIELDSHADINGS_CB "CUI_HID_COLORPAGE_WRITERFIELDSHADINGS_CB" +#define HID_COLORPAGE_WRITERIDXSHADINGS_CB "CUI_HID_COLORPAGE_WRITERIDXSHADINGS_CB" +#define HID_COLORPAGE_WRITERDIRECTCURSOR_CB "CUI_HID_COLORPAGE_WRITERDIRECTCURSOR_CB" +#define HID_COLORPAGE_WRITERNOTESINDICATOR_CB "CUI_HID_COLORPAGE_WRITERNOTESINDICATOR_CB" +#define HID_COLORPAGE_WRITERSCRIPTINDICATOR_CB "CUI_HID_COLORPAGE_WRITERSCRIPTINDICATOR_CB" +#define HID_COLORPAGE_WRITERSECTIONBOUNDARIES_CB "CUI_HID_COLORPAGE_WRITERSECTIONBOUNDARIES_CB" +#define HID_COLORPAGE_WRITERPAGEBREAKS_CB "CUI_HID_COLORPAGE_WRITERPAGEBREAKS_CB" +#define HID_COLORPAGE_HTMLSGML_CB "CUI_HID_COLORPAGE_HTMLSGML_CB" +#define HID_COLORPAGE_HTMLCOMMENT_CB "CUI_HID_COLORPAGE_HTMLCOMMENT_CB" +#define HID_COLORPAGE_HTMLKEYWORD_CB "CUI_HID_COLORPAGE_HTMLKEYWORD_CB" +#define HID_COLORPAGE_HTMLUNKNOWN_CB "CUI_HID_COLORPAGE_HTMLUNKNOWN_CB" +#define HID_COLORPAGE_CALCGRID_CB "CUI_HID_COLORPAGE_CALCGRID_CB" +#define HID_COLORPAGE_CALCPAGEBREAK_CB "CUI_HID_COLORPAGE_CALCPAGEBREAK_CB" +#define HID_COLORPAGE_CALCPAGEBREAKMANUAL_CB "CUI_HID_COLORPAGE_CALCPAGEBREAKMANUAL_CB" +#define HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_CB "CUI_HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_CB" +#define HID_COLORPAGE_CALCDETECTIVE_CB "CUI_HID_COLORPAGE_CALCDETECTIVE_CB" +#define HID_COLORPAGE_CALCDETECTIVEERROR_CB "CUI_HID_COLORPAGE_CALCDETECTIVEERROR_CB" +#define HID_COLORPAGE_CALCREFERENCE_CB "CUI_HID_COLORPAGE_CALCREFERENCE_CB" +#define HID_COLORPAGE_CALCNOTESBACKGROUND_CB "CUI_HID_COLORPAGE_CALCNOTESBACKGROUND_CB" +#define HID_COLORPAGE_DRAWGRID_CB "CUI_HID_COLORPAGE_DRAWGRID_CB" +#define HID_COLORPAGE_DRAWDRAWING_CB "CUI_HID_COLORPAGE_DRAWDRAWING_CB" +#define HID_COLORPAGE_DRAWFILL_CB "CUI_HID_COLORPAGE_DRAWFILL_CB" +#define HID_COLORPAGE_BASICIDENTIFIER_CB "CUI_HID_COLORPAGE_BASICIDENTIFIER_CB" +#define HID_COLORPAGE_BASICCOMMENT_CB "CUI_HID_COLORPAGE_BASICCOMMENT_CB" +#define HID_COLORPAGE_BASICNUMBER_CB "CUI_HID_COLORPAGE_BASICNUMBER_CB" +#define HID_COLORPAGE_BASICSTRING_CB "CUI_HID_COLORPAGE_BASICSTRING_CB" +#define HID_COLORPAGE_BASICOPERATOR_CB "CUI_HID_COLORPAGE_BASICOPERATOR_CB" +#define HID_COLORPAGE_BASICKEYWORD_CB "CUI_HID_COLORPAGE_BASICKEYWORD_CB" +#define HID_COLORPAGE_BASICERROR_CB "CUI_HID_COLORPAGE_BASICERROR_CB" +#define HID_NUMBERINGOPT_SEL_GRF_FROM_FILE "CUI_HID_NUMBERINGOPT_SEL_GRF_FROM_FILE" +#define HID_SVX_MACRO_LB_EVENT "CUI_HID_SVX_MACRO_LB_EVENT" +#define HID_SVX_CONFIG_EVENT "CUI_HID_SVX_CONFIG_EVENT" +#define HID_CONFIG_EVENT_OFFICE_BASED "CUI_HID_CONFIG_EVENT_OFFICE_BASED" +#define HID_CONFIG_EVENT_DOCUMENT_BASED "CUI_HID_CONFIG_EVENT_DOCUMENT_BASED" +#define HID_SELECTOR_DIALOG "CUI_HID_SELECTOR_DIALOG" +#define HID_SELECTOR_CATEGORIES "CUI_HID_SELECTOR_CATEGORIES" +#define HID_SVX_CONFIG_TOOLBAR "CUI_HID_SVX_CONFIG_TOOLBAR" +#define HID_SVX_CONFIG_TOOLBAR_CONTENTS "CUI_HID_SVX_CONFIG_TOOLBAR_CONTENTS" +#define HID_SELECTOR_COMMANDS "CUI_HID_SELECTOR_COMMANDS" +#define HID_GALLERY_EDIT_MSNAME "CUI_HID_GALLERY_EDIT_MSNAME" +#define HID_SVX_CONFIG_MENU "CUI_HID_SVX_CONFIG_MENU" +#define HID_SVX_CONFIG_MENU_CONTENTS "CUI_HID_SVX_CONFIG_MENU_CONTENTS" +#define HID_GALLERY_NEWTHEME_FINDFILES "CUI_HID_GALLERY_NEWTHEME_FINDFILES" +#define HID_GALLERY_NEWTHEME_ADDFILES "CUI_HID_GALLERY_NEWTHEME_ADDFILES" +#define HID_HANGULDLG_BUTTON_OPTIONS "CUI_HID_HANGULDLG_BUTTON_OPTIONS" +#define HID_HANGULDLG_BUTTON_CLOSE "CUI_HID_HANGULDLG_BUTTON_CLOSE" +#define HID_HANGULDLG_BUTTON_IGNORE "CUI_HID_HANGULDLG_BUTTON_IGNORE" +#define HID_HANGULDLG_BUTTON_IGNOREALL "CUI_HID_HANGULDLG_BUTTON_IGNOREALL" +#define HID_HANGULDLG_BUTTON_CHANGE "CUI_HID_HANGULDLG_BUTTON_CHANGE" +#define HID_HANGULDLG_BUTTON_CHANGEALL "CUI_HID_HANGULDLG_BUTTON_CHANGEALL" +#define HID_OFA_FONT_SUBSTITUTION "CUI_HID_OFA_FONT_SUBSTITUTION" +#define HID_HANGULDLG_EDIT_NEWWORD "CUI_HID_HANGULDLG_EDIT_NEWWORD" +#define HID_OFA_SUBST_APPLY "CUI_HID_OFA_SUBST_APPLY" +#define HID_OFA_SUBST_DELETE "CUI_HID_OFA_SUBST_DELETE" +#define HID_SPLDLG_BUTTON_CLOSE "CUI_HID_SPLDLG_BUTTON_CLOSE" +#define HID_SPLDLG_BUTTON_IGNORE "CUI_HID_SPLDLG_BUTTON_IGNORE" +#define HID_SPLDLG_BUTTON_IGNOREALL "CUI_HID_SPLDLG_BUTTON_IGNOREALL" +#define HID_SPLDLG_BUTTON_CHANGE "CUI_HID_SPLDLG_BUTTON_CHANGE" +#define HID_SPLDLG_BUTTON_CHANGEALL "CUI_HID_SPLDLG_BUTTON_CHANGEALL" +#define HID_SPLDLG_BUTTON_EXPLAIN "CUI_HID_SPLDLG_BUTTON_EXPLAIN" +#define HID_CHARMAP_CTL_SHOWSET "CUI_HID_CHARMAP_CTL_SHOWSET" +#define HID_CHARMAP_CTL_SHOWTEXT "CUI_HID_CHARMAP_CTL_SHOWTEXT" +#define HID_CHARMAP_CTL_SHOWCHAR "CUI_HID_CHARMAP_CTL_SHOWCHAR" +#define HID_DLG_NAME "CUI_HID_DLG_NAME" +#define HID_DLG_MESSBOX "CUI_HID_DLG_MESSBOX" +#define HID_HANGULDLG_SUGGESTIONS "CUI_HID_HANGULDLG_SUGGESTIONS" +#define HID_HANGULDLG_SUGGESTIONS_GRID "CUI_HID_HANGULDLG_SUGGESTIONS_GRID" +#define HID_HANGULDLG_SUGGESTIONS_LIST "CUI_HID_HANGULDLG_SUGGESTIONS_LIST" +#define HID_DLG_OBJECT_NAME "CUI_HID_DLG_OBJECT_NAME" +#define HID_DLG_OBJECT_TITLE_DESC "CUI_HID_DLG_OBJECT_TITLE_DESC" +#define HID_SVX_CONFIG_MENU_ORGANIZER "CUI_HID_SVX_CONFIG_MENU_ORGANIZER" +#define HID_SVX_CONFIG_ICON_SELECTOR "CUI_HID_SVX_CONFIG_ICON_SELECTOR" +#define HID_SVX_CONFIG_NAME_SUBMENU "CUI_HID_SVX_CONFIG_NAME_SUBMENU" +#define HID_SVX_CONFIG_RENAME_MENU "CUI_HID_SVX_CONFIG_RENAME_MENU" +#define HID_SVX_CONFIG_RENAME_MENU_ITEM "CUI_HID_SVX_CONFIG_RENAME_MENU_ITEM" +#define HID_SVX_CONFIG_RENAME_TOOLBAR "CUI_HID_SVX_CONFIG_RENAME_TOOLBAR" +#define HID_SVX_CONFIG_RENAME_TOOLBAR_ITEM "CUI_HID_SVX_CONFIG_RENAME_TOOLBAR_ITEM" +#define HID_SVX_NEW_TOOLBAR "CUI_HID_SVX_NEW_TOOLBAR" +#define HID_SVX_MODIFY_TOOLBAR "CUI_HID_SVX_MODIFY_TOOLBAR" +#define HID_SVX_NEW_TOOLBAR_ITEM "CUI_HID_SVX_NEW_TOOLBAR_ITEM" +#define HID_SVX_CONFIG_MENU_LISTBOX "CUI_HID_SVX_CONFIG_MENU_LISTBOX" +#define HID_SVX_MODIFY_TOOLBAR_ITEM "CUI_HID_SVX_MODIFY_TOOLBAR_ITEM" +#define HID_SVX_SAVE_IN "CUI_HID_SVX_SAVE_IN" +#define HID_OPTIONS_MULTIPATH_LIST "CUI_HID_OPTIONS_MULTIPATH_LIST" +#define HID_FM_DLG_SEARCH "CUI_HID_FM_DLG_SEARCH" +#define HID_SEARCH_TEXT "CUI_HID_SEARCH_TEXT" +#define HID_SEARCH_ALLFIELDS "CUI_HID_SEARCH_ALLFIELDS" +#define HID_GALLERY_PROPERTIES_GENERAL "CUI_HID_GALLERY_PROPERTIES_GENERAL" +#define HID_SEARCH_FIELDSELECTION "CUI_HID_SEARCH_FIELDSELECTION" +#define HID_SEARCH_POSITION "CUI_HID_SEARCH_POSITION" +#define HID_SEARCH_FORMATTER "CUI_HID_SEARCH_FORMATTER" +#define HID_SEARCH_CASE "CUI_HID_SEARCH_CASE" +#define HID_SEARCH_BACKWARD "CUI_HID_SEARCH_BACKWARD" +#define HID_SEARCH_STARTOVER "CUI_HID_SEARCH_STARTOVER" +#define HID_SEARCH_WILDCARD "CUI_HID_SEARCH_WILDCARD" +#define HID_SEARCH_REGULAR "CUI_HID_SEARCH_REGULAR" +#define HID_SEARCH_APPROX "CUI_HID_SEARCH_APPROX" +#define HID_SEARCH_APPROXSETTINGS "CUI_HID_SEARCH_APPROXSETTINGS" +#define HID_SEARCH_BTN_SEARCH "CUI_HID_SEARCH_BTN_SEARCH" +#define HID_SEARCH_BTN_CLOSE "CUI_HID_SEARCH_BTN_CLOSE" +#define HID_GALLERY_BROWSER "CUI_HID_GALLERY_BROWSER" +#define HID_GALLERY_SEARCH "CUI_HID_GALLERY_SEARCH" +#define HID_GALLERY_APPLY "CUI_HID_GALLERY_APPLY" +#define HID_SPLDLG_BUTTON_IGNORERULE "CUI_HID_SPLDLG_BUTTON_IGNORERULE" +#define HID_CONFIG_ACCEL "CUI_HID_CONFIG_ACCEL" +#define HID_ACCELCONFIG_LISTBOX "CUI_HID_ACCELCONFIG_LISTBOX" +#define HID_CONFIGGROUP_ACC_LISTBOX "CUI_HID_CONFIGGROUP_ACC_LISTBOX" +#define HID_CONFIGFUNCTION_ACC_LISTBOX "CUI_HID_CONFIGFUNCTION_ACC_LISTBOX" +#define HID_MACRO_LB_EVENT "CUI_HID_MACRO_LB_EVENT" +#define HID_MACRO_GROUP "CUI_HID_MACRO_GROUP" +#define HID_MACRO_MACROS "CUI_HID_MACRO_MACROS" +#define HID_DIALOG_HANGULHANJA "CUI_HID_DIALOG_HANGULHANJA" +#define HID_HANGULHANJA_OPT_DLG "CUI_HID_HANGULHANJA_OPT_DLG" +#define HID_HANGULHANJA_NEWDICT_DLG "CUI_HID_HANGULHANJA_NEWDICT_DLG" +#define HID_HANGULHANJA_EDIT_DLG "CUI_HID_HANGULHANJA_EDIT_DLG" +#define HID_HANGULHANJA_OPT_DICTS_LB "CUI_HID_HANGULHANJA_OPT_DICTS_LB" +#define HID_MULTIPATH "CUI_HID_MULTIPATH" +#define HID_SCRIPTORG_DIALOG "CUI_HID_SCRIPTORG_DIALOG" +#define HID_SCRIPTSBOX "CUI_HID_SCRIPTSBOX" +#define HID_SPELLCHECK "CUI_HID_SPELLCHECK" +#define HID_TPSIZE_CTRL "CUI_HID_TPSIZE_CTRL" +#define HID_TPROTATION_CTRL1 "CUI_HID_TPROTATION_CTRL1" +#define HID_TPROTATION_CTRL2 "CUI_HID_TPROTATION_CTRL2" +#define HID_TRANS_ANGLE "CUI_HID_TRANS_ANGLE" +#define HID_TPPOSITION_CTRL "CUI_HID_TPPOSITION_CTRL" +#define HID_NUMBERFORMAT_LB_FORMAT "CUI_HID_NUMBERFORMAT_LB_FORMAT" +#define HID_NUMBERFORMAT_WND_NUMBER_PREVIEW "CUI_HID_NUMBERFORMAT_WND_NUMBER_PREVIEW" +#define HID_TRANS_SLANT "CUI_HID_TRANS_SLANT" +#define HID_TPHATCH_CTRL "CUI_HID_TPHATCH_CTRL" +#define HID_SEARCHATTR_CTL_ATTR "CUI_HID_SEARCHATTR_CTL_ATTR" +#define HID_NUMBERFORMAT_TBI_INFO "CUI_HID_NUMBERFORMAT_TBI_INFO" +#define HID_SEARCHATTR "CUI_HID_SEARCHATTR" +#define HID_ALIGNMENT_CTR_DIAL "CUI_HID_ALIGNMENT_CTR_DIAL" +#define HID_ALIGNMENT_CTR_BORDER_LOCK "CUI_HID_ALIGNMENT_CTR_BORDER_LOCK" +#define HID_SEARCHSIMILARITY "CUI_HID_SEARCHSIMILARITY" +#define UID_SEARCH_RECORDSTATUS "CUI_UID_SEARCH_RECORDSTATUS" +#define HID_OFAPAGE_AUTOCORR_CLB "CUI_HID_OFAPAGE_AUTOCORR_CLB" +#define HID_AUTOCORR_LANGUAGE "CUI_HID_AUTOCORR_LANGUAGE" +#define HID_OFAPAGE_AUTOFORMAT_CLB "CUI_HID_OFAPAGE_AUTOFORMAT_CLB" +#define HID_TPCOLOR_RGB_1 "CUI_HID_TPCOLOR_RGB_1" +#define HID_TPCOLOR_RGB_2 "CUI_HID_TPCOLOR_RGB_2" +#define HID_TPCOLOR_RGB_3 "CUI_HID_TPCOLOR_RGB_3" +#define HID_TPCOLOR_CMYK_1 "CUI_HID_TPCOLOR_CMYK_1" +#define HID_TPCOLOR_CMYK_2 "CUI_HID_TPCOLOR_CMYK_2" +#define HID_TPCOLOR_CMYK_3 "CUI_HID_TPCOLOR_CMYK_3" +#define HID_ALIGNMENT "CUI_HID_ALIGNMENT" +#define HID_OFAPAGE_AUTOCORR_OPTIONS "CUI_HID_OFAPAGE_AUTOCORR_OPTIONS" +#define HID_OFAPAGE_AUTOFMT_OPTIONS "CUI_HID_OFAPAGE_AUTOFMT_OPTIONS" +#define HID_OFAPAGE_AUTOCORR_REPLACE "CUI_HID_OFAPAGE_AUTOCORR_REPLACE" +#define HID_OFACTL_AUTOCORR_REPLACE "CUI_HID_OFACTL_AUTOCORR_REPLACE" +#define HID_OFAPAGE_AUTOCORR_EXCEPT "CUI_HID_OFAPAGE_AUTOCORR_EXCEPT" +#define HID_OFAPAGE_AUTOCORR_QUOTE "CUI_HID_OFAPAGE_AUTOCORR_QUOTE" +#define HID_OFAPAGE_AUTOCOMPLETE_OPTIONS "CUI_HID_OFAPAGE_AUTOCOMPLETE_OPTIONS" +#define HID_BACKGROUND "CUI_HID_BACKGROUND" +#define HID_BACKGROUND_CTL_BGDCOLORSET "CUI_HID_BACKGROUND_CTL_BGDCOLORSET" +#define HID_BACKGROUND_CTL_POSITION "CUI_HID_BACKGROUND_CTL_POSITION" +#define HID_BORDER "CUI_HID_BORDER" +#define HID_BORDER_CTL_PRESETS "CUI_HID_BORDER_CTL_PRESETS" +#define HID_BORDER_CTL_SHADOWS "CUI_HID_BORDER_CTL_SHADOWS" +#define HID_PAGE_CONNECTION "CUI_HID_PAGE_CONNECTION" +#define HID_PAGE_CONNECTION_CTL_PREVIEW "CUI_HID_PAGE_CONNECTION_CTL_PREVIEW" +#define HID_PAGE_DISTRIBUTE "CUI_HID_PAGE_DISTRIBUTE" +#define HID_SVXPAGE_GRFCROP "CUI_HID_SVXPAGE_GRFCROP" +#define HID_CAPTION "CUI_HID_CAPTION" +#define HID_CAPTION_CTL_TYPE "CUI_HID_CAPTION_CTL_TYPE" +#define HID_PAGE_MEASURE "CUI_HID_PAGE_MEASURE" +#define HID_MEASURE_CTL_POSITION "CUI_HID_MEASURE_CTL_POSITION" +#define HID_NUMBERFORMAT "CUI_HID_NUMBERFORMAT" +#define HID_NUMBERFORMAT_TBI_ADD "CUI_HID_NUMBERFORMAT_TBI_ADD" +#define HID_NUMBERFORMAT_TBI_REMOVE "CUI_HID_NUMBERFORMAT_TBI_REMOVE" +#define HID_FORMAT_PAGE "CUI_HID_FORMAT_PAGE" +#define HID_REDLINING_DLG "CUI_HID_REDLINING_DLG" +#define HID_REDLINING_EDIT "CUI_HID_REDLINING_EDIT" +#define HID_REDLINING_PREV "CUI_HID_REDLINING_PREV" +#define HID_REDLINING_NEXT "CUI_HID_REDLINING_NEXT" +#define HID_FORMAT_PARAGRAPH_STD "CUI_HID_FORMAT_PARAGRAPH_STD" +#define HID_VALUESET_SINGLENUM "CUI_HID_VALUESET_SINGLENUM" +#define HID_VALUESET_BULLET "CUI_HID_VALUESET_BULLET" +#define HID_VALUESET_NUM "CUI_HID_VALUESET_NUM" +#define HID_VALUESET_NUMBMP "CUI_HID_VALUESET_NUMBMP" +#define HID_SVXPAGE_PICK_NUM "CUI_HID_SVXPAGE_PICK_NUM" +#define HID_SVXPAGE_PICK_SINGLE_NUM "CUI_HID_SVXPAGE_PICK_SINGLE_NUM" +#define HID_SVXPAGE_PICK_BMP "CUI_HID_SVXPAGE_PICK_BMP" +#define HID_SVXPAGE_PICK_BULLET "CUI_HID_SVXPAGE_PICK_BULLET" +#define HID_SVXPAGE_NUM_OPTIONS "CUI_HID_SVXPAGE_NUM_OPTIONS" +#define HID_SVXPAGE_NUM_POSITION "CUI_HID_SVXPAGE_NUM_POSITION" +#define HID_MEASURE_CTL_PREVIEW "CUI_HID_MEASURE_CTL_PREVIEW" +#define HID_FORMAT_PARAGRAPH_EXT "CUI_HID_FORMAT_PARAGRAPH_EXT" +#define HID_FORMAT_PARAGRAPH_ALIGN "CUI_HID_FORMAT_PARAGRAPH_ALIGN" +#define HID_SVXPAGE_PARA_ASIAN "CUI_HID_SVXPAGE_PARA_ASIAN" +#define HID_SVXPAGE_SWPOSSIZE "CUI_HID_SVXPAGE_SWPOSSIZE" +#define HID_AREA_TRANSPARENCE "CUI_HID_AREA_TRANSPARENCE" +#define HID_AREA_AREA "CUI_HID_AREA_AREA" +#define HID_AREA_SHADOW "CUI_HID_AREA_SHADOW" +#define HID_AREA_HATCH "CUI_HID_AREA_HATCH" +#define HID_AREA_BITMAP "CUI_HID_AREA_BITMAP" +#define HID_TPSHADOW_CTRL "CUI_HID_TPSHADOW_CTRL" +#define HID_AREA_GRADIENT "CUI_HID_AREA_GRADIENT" +#define HID_LINE_ENDDEF "CUI_HID_LINE_ENDDEF" +#define HID_LINE_LINE "CUI_HID_LINE_LINE" +#define HID_LINE_DEF "CUI_HID_LINE_DEF" +#define HID_SPELLDLG_SETWORD "CUI_HID_SPELLDLG_SETWORD" +#define HID_TABULATOR "CUI_HID_TABULATOR" +#define HID_PAGE_TEXTATTR "CUI_HID_PAGE_TEXTATTR" +#define HID_TEXTATTR_CTL_POSITION "CUI_HID_TEXTATTR_CTL_POSITION" +#define HID_TRANS_POSITION_SIZE "CUI_HID_TRANS_POSITION_SIZE" +#define HID_HYPHENATE "CUI_HID_HYPHENATE" +#define HID_SVXPAGE_CHAR_NAME "CUI_HID_SVXPAGE_CHAR_NAME" +#define HID_SVXPAGE_CHAR_EFFECTS "CUI_HID_SVXPAGE_CHAR_EFFECTS" +#define HID_SVXPAGE_CHAR_POSITION "CUI_HID_SVXPAGE_CHAR_POSITION" +#define HID_HYPERLINK_INTERNET "CUI_HID_HYPERLINK_INTERNET" +#define HID_HYPERLINK_MAIL "CUI_HID_HYPERLINK_MAIL" +#define HID_HYPERLINK_DOCUMENT "CUI_HID_HYPERLINK_DOCUMENT" +#define HID_HYPERLINK_NEWDOCUMENT "CUI_HID_HYPERLINK_NEWDOCUMENT" +#define HID_HYPERLINK_MARKWND "CUI_HID_HYPERLINK_MARKWND" +#define HID_ICCDIALOG_RESET_BTN "CUI_HID_ICCDIALOG_RESET_BTN" +#define HID_ICCDIALOG_CHOICECTRL "CUI_HID_ICCDIALOG_CHOICECTRL" +#define HID_HYPERDLG_INET_PATH "CUI_HID_HYPERDLG_INET_PATH" +#define HID_HYPERDLG_MAIL_PATH "CUI_HID_HYPERDLG_MAIL_PATH" +#define HID_HYPERDLG_DOC_PATH "CUI_HID_HYPERDLG_DOC_PATH" +#define HID_ICCDIALOG_OK_BTN "CUI_HID_ICCDIALOG_OK_BTN" +#define HID_ICCDIALOG_CANCEL_BTN "CUI_HID_ICCDIALOG_CANCEL_BTN" +#define HID_HYPERLINK_MARKWND_APPLY "CUI_HID_HYPERLINK_MARKWND_APPLY" +#define HID_HYPERLINK_MARKWND_CLOSE "CUI_HID_HYPERLINK_MARKWND_CLOSE" +#define HID_HYPERLINK_MARKWND_TREE "CUI_HID_HYPERLINK_MARKWND_TREE" +#define HID_SVXPAGE_CHAR_TWOLINES "CUI_HID_SVXPAGE_CHAR_TWOLINES" +#define HID_GRFFILTER_EMBOSS_LIGHT "CUI_HID_GRFFILTER_EMBOSS_LIGHT" +#define HID_PASTE_DLG "CUI_HID_PASTE_DLG" +#define HID_LINKDLG_TABLB "CUI_HID_LINKDLG_TABLB" +#define HID_MACRO_HEADERTABLISTBOX "CUI_HID_MACRO_HEADERTABLISTBOX" +#define HID_GALLERY_ENTER_TITLE "CUI_HID_GALLERY_ENTER_TITLE" +#define HID_GALLERY_TITLE_EDIT "CUI_HID_GALLERY_TITLE_EDIT" +#define HID_THES_LANGUAGE "CUI_HID_THES_LANGUAGE" +#define HID_OFAPAGE_QUOTE_SW_CLB "CUI_HID_OFAPAGE_QUOTE_SW_CLB" +#define HID_OFAPAGE_QUOTE_CLB "CUI_HID_OFAPAGE_QUOTE_CLB" +#define HID_POSTIT_DIALOG "CUI_HID_POSTIT_DIALOG" +#define HID_CT_THES_ALTERNATIVES "CUI_HID_CT_THES_ALTERNATIVES" -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY (HID_CUI_START + 342) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_OPEN (HID_CUI_START + 343) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_OPEN (HID_CUI_START + 344) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_MORE (HID_CUI_START + 345) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_FILE_READONLY (HID_CUI_START + 346) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_MODIFY (HID_CUI_START + 347) -#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_MODIFY (HID_CUI_START + 348) -#define HID_HYPERLINK_DIALOG (HID_CUI_START + 349) - -// please adjust ACT_SVX_HID_END2 below if you add entries here! - -// ----------------------------------------------------------------------- -// Overrun check --------------------------------------------------------- -// ----------------------------------------------------------------------- - -#define ACT_CUI_HID_END (HID_CUI_START + 349) - -#if ACT_CUI_HID_END > HID_CUI_END -#error Resource-Ueberlauf in #line, #file -#endif +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_OPEN "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_OPEN" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_OPEN "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_OPEN" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_MORE "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_MORE" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_FILE_READONLY "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_FILE_READONLY" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_MODIFY "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_PASSWORD_TO_MODIFY" +#define HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_MODIFY "CUI_HID_DLG_PASSWORD_TO_OPEN_MODIFY_CONFIRM_PASSWORD_TO_MODIFY" +#define HID_HYPERLINK_DIALOG "CUI_HID_HYPERLINK_DIALOG" #endif diff --git a/cui/source/inc/hldocntp.hxx b/cui/source/inc/hldocntp.hxx index a44363aeb105..c32d432d8a9b 100644 --- a/cui/source/inc/hldocntp.hxx +++ b/cui/source/inc/hldocntp.hxx @@ -53,8 +53,7 @@ private: DECL_LINK (ClickNewHdl_Impl , void * ); - Image GetImage( USHORT nId ); - void ReadURLFile( const String& rFile, String& rTitle, String& rURL, sal_Int32& rIconId, BOOL* pShowAsFolder); + Image GetImage( sal_uInt16 nId ); protected: void FillDlgFields ( String& aStrURL ); @@ -68,7 +67,7 @@ public: static IconChoicePage* Create( Window* pWindow, const SfxItemSet& rItemSet ); - virtual BOOL AskApply (); + virtual sal_Bool AskApply (); virtual void DoApply (); virtual void SetInitFocus(); diff --git a/cui/source/inc/hldoctp.hxx b/cui/source/inc/hldoctp.hxx index ff3fd1698714..1c7a7a155da8 100644 --- a/cui/source/inc/hldoctp.hxx +++ b/cui/source/inc/hldoctp.hxx @@ -53,7 +53,7 @@ private: String maStrURL; - BOOL mbMarkWndOpen; + sal_Bool mbMarkWndOpen; DECL_LINK (ClickFileopenHdl_Impl , void * ); DECL_LINK (ClickTargetHdl_Impl , void * ); @@ -75,8 +75,8 @@ protected: void GetCurentItemData ( String& aStrURL, String& aStrName, String& aStrIntName, String& aStrFrame, SvxLinkInsertMode& eMode ); - virtual BOOL ShouldOpenMarkWnd () {return mbMarkWndOpen;} - virtual void SetMarkWndShouldOpen (BOOL bOpen) {mbMarkWndOpen=bOpen;} + virtual sal_Bool ShouldOpenMarkWnd () {return mbMarkWndOpen;} + virtual void SetMarkWndShouldOpen (sal_Bool bOpen) {mbMarkWndOpen=bOpen;} String GetCurrentURL (); public: diff --git a/cui/source/inc/hlinettp.hxx b/cui/source/inc/hlinettp.hxx index ae784cd339ad..b803f01aaf1c 100644 --- a/cui/source/inc/hlinettp.hxx +++ b/cui/source/inc/hlinettp.hxx @@ -47,18 +47,18 @@ private: RadioButton maRbtLinktypTelnet; FixedText maFtTarget; SvxHyperURLBox maCbbTarget; + ImageButton maBtBrowse; FixedText maFtLogin; Edit maEdLogin; + ImageButton maBtTarget; FixedText maFtPassword; Edit maEdPassword; CheckBox maCbAnonymous; - ImageButton maBtBrowse; - ImageButton maBtTarget; String maStrOldUser; String maStrOldPassword; - BOOL mbMarkWndOpen; + sal_Bool mbMarkWndOpen; String maStrStdDocURL; @@ -89,8 +89,8 @@ protected: virtual void GetCurentItemData ( String& aStrURL, String& aStrName, String& aStrIntName, String& aStrFrame, SvxLinkInsertMode& eMode ); - virtual BOOL ShouldOpenMarkWnd () {return ( mbMarkWndOpen && maRbtLinktypInternet.IsChecked() );} - virtual void SetMarkWndShouldOpen (BOOL bOpen) {mbMarkWndOpen=bOpen;} + virtual sal_Bool ShouldOpenMarkWnd () {return ( mbMarkWndOpen && maRbtLinktypInternet.IsChecked() );} + virtual void SetMarkWndShouldOpen (sal_Bool bOpen) {mbMarkWndOpen=bOpen;} public: SvxHyperlinkInternetTp ( Window *pParent, const SfxItemSet& rItemSet); @@ -99,7 +99,7 @@ public: static IconChoicePage* Create( Window* pWindow, const SfxItemSet& rItemSet ); virtual void SetMarkStr ( String& aStrMark ); - virtual void SetOnlineMode( BOOL bEnable ); + virtual void SetOnlineMode( sal_Bool bEnable ); virtual void SetInitFocus(); }; diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx index e5691351a999..54fafdf2477d 100644 --- a/cui/source/inc/hlmarkwn.hxx +++ b/cui/source/inc/hlmarkwn.hxx @@ -71,17 +71,17 @@ private: PushButton maBtClose; SvxHlmarkTreeLBox maLbTree; - BOOL mbUserMoved; - BOOL mbFirst; + sal_Bool mbUserMoved; + sal_Bool mbFirst; SvxHyperlinkTabPageBase* mpParent; String maStrLastURL; - USHORT mnError; + sal_uInt16 mnError; protected: - BOOL RefreshFromDoc( ::rtl::OUString aURL ); + sal_Bool RefreshFromDoc( ::rtl::OUString aURL ); SvLBoxEntry* FindEntry ( String aStrName ); void ClearTree(); @@ -96,13 +96,13 @@ public: SvxHlinkDlgMarkWnd (SvxHyperlinkTabPageBase *pParent); ~SvxHlinkDlgMarkWnd(); - BOOL MoveTo ( Point aNewPos ); + sal_Bool MoveTo ( Point aNewPos ); void RefreshTree ( String aStrURL ); void SelectEntry ( String aStrMark ); - BOOL ConnectToDialog( BOOL bDoit = TRUE ); + sal_Bool ConnectToDialog( sal_Bool bDoit = sal_True ); - USHORT SetError( USHORT nError); + sal_uInt16 SetError( sal_uInt16 nError); }; diff --git a/cui/source/inc/hltpbase.hxx b/cui/source/inc/hltpbase.hxx index 3d6a84a144a7..0a3dbb237239 100644 --- a/cui/source/inc/hltpbase.hxx +++ b/cui/source/inc/hltpbase.hxx @@ -81,7 +81,7 @@ public: class SvxHyperURLBox : public SvtURLBox, public DropTargetHelper { private: - BOOL mbAccessAddress; + sal_Bool mbAccessAddress; protected: virtual sal_Int8 AcceptDrop( const AcceptDropEvent& rEvt ); @@ -93,7 +93,7 @@ protected: virtual long PreNotify( NotifyEvent& rNEvt ); public: - SvxHyperURLBox( Window* pParent, INetProtocol eSmart = INET_PROT_FILE, BOOL bAddresses = FALSE ); + SvxHyperURLBox( Window* pParent, INetProtocol eSmart = INET_PROT_FILE, sal_Bool bAddresses = sal_False ); }; @@ -125,7 +125,7 @@ private: protected: Window* mpDialog; - BOOL mbStdControlsInit; + sal_Bool mbStdControlsInit; String maStrInitURL; @@ -149,7 +149,7 @@ protected: String aEmptyStr; - BOOL FileExists( const INetURLObject& rURL ); + sal_Bool FileExists( const INetURLObject& rURL ); static String GetSchemeFromURL( String aStrURL ); inline void DisableClose( sal_Bool _bDisable ) { mbIsCloseDisabled = _bDisable; } @@ -168,27 +168,27 @@ public: mxDocumentFrame = rxDocumentFrame; } - virtual BOOL AskApply (); + virtual sal_Bool AskApply (); virtual void DoApply (); - virtual void SetOnlineMode( BOOL bEnable ); + virtual void SetOnlineMode( sal_Bool bEnable ); virtual void SetInitFocus(); virtual void SetMarkStr ( String& aStrMark ); virtual void Reset( const SfxItemSet& ); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void ActivatePage( const SfxItemSet& rItemSet ); virtual int DeactivatePage( SfxItemSet* pSet = 0 ); - BOOL IsMarkWndVisible () { return ((Window*)mpMarkWnd)->IsVisible(); } + sal_Bool IsMarkWndVisible () { return ((Window*)mpMarkWnd)->IsVisible(); } Size GetSizeExtraWnd () { return ( mpMarkWnd->GetSizePixel() ); } - BOOL MoveToExtraWnd ( Point aNewPos, BOOL bDisConnectDlg = FALSE ); + sal_Bool MoveToExtraWnd ( Point aNewPos, sal_Bool bDisConnectDlg = sal_False ); virtual void ActivatePage(); virtual void DeactivatePage(); virtual sal_Bool QueryClose(); protected: - virtual BOOL ShouldOpenMarkWnd(); - virtual void SetMarkWndShouldOpen(BOOL bOpen); + virtual sal_Bool ShouldOpenMarkWnd(); + virtual void SetMarkWndShouldOpen(sal_Bool bOpen); void ShowMarkWnd (); void HideMarkWnd () { ( ( Window* ) mpMarkWnd )->Hide(); } @@ -196,10 +196,10 @@ protected: SfxDispatcher* GetDispatcher() const; - USHORT GetMacroEvents(); + sal_uInt16 GetMacroEvents(); SvxMacroTableDtor* GetMacroTable(); - BOOL IsHTMLDoc() const; + sal_Bool IsHTMLDoc() const; }; #endif // _SVX_TABBASE_HYPERLINK_HXX diff --git a/cui/source/inc/iconcdlg.hxx b/cui/source/inc/iconcdlg.hxx index a65754f20ff5..d0ed14387a0b 100644 --- a/cui/source/inc/iconcdlg.hxx +++ b/cui/source/inc/iconcdlg.hxx @@ -51,7 +51,7 @@ class IconChoicePage; // Create-Function typedef IconChoicePage* (*CreatePage)(Window *pParent, const SfxItemSet &rAttrSet); -typedef USHORT* (*GetPageRanges)(); // liefert internationale Which-Wert +typedef sal_uInt16* (*GetPageRanges)(); // liefert internationale Which-Wert // position of iconchoicectrl enum EIconChoicePos { PosLeft, PosRight, PosTop, PosBottom }; @@ -64,21 +64,21 @@ enum EIconChoicePos { PosLeft, PosRight, PosTop, PosBottom }; struct IconChoicePageData { - USHORT nId; // Die ID + sal_uInt16 nId; // Die ID CreatePage fnCreatePage; // Pointer auf die Factory GetPageRanges fnGetRanges;// Pointer auf die Ranges-Funktion IconChoicePage* pPage; // die TabPage selber - BOOL bOnDemand; // Flag: ItemSet onDemand - BOOL bRefresh; // Flag: Seite mu\s neu initialisiert werden + sal_Bool bOnDemand; // Flag: ItemSet onDemand + sal_Bool bRefresh; // Flag: Seite mu\s neu initialisiert werden // Konstruktor - IconChoicePageData( USHORT Id, CreatePage fnPage, GetPageRanges fnRanges, BOOL bDemand ) + IconChoicePageData( sal_uInt16 Id, CreatePage fnPage, GetPageRanges fnRanges, sal_Bool bDemand ) : nId ( Id ), fnCreatePage ( fnPage ), fnGetRanges ( fnRanges ), pPage ( NULL ), bOnDemand ( bDemand ), - bRefresh ( FALSE ) + bRefresh ( sal_False ) {} }; @@ -96,9 +96,9 @@ class IconChoicePage : public TabPage private : const SfxItemSet* pSet; String aUserString; - BOOL bHasExchangeSupport; + sal_Bool bHasExchangeSupport; IconChoiceDialog* pDialog; - BOOL bStandard; + sal_Bool bStandard; void SetDialog( IconChoiceDialog* pNew ) { pDialog = pNew; } IconChoiceDialog* GetDialog() const { return pDialog; } @@ -110,21 +110,19 @@ private : protected : IconChoicePage( Window *pParent, const ResId &, const SfxItemSet &rAttrSet ); - USHORT GetSlot( USHORT nWhich ) const { return pSet->GetPool()->GetSlotId( nWhich ); } - USHORT GetWhich( USHORT nSlot ) const { return pSet->GetPool()->GetWhich( nSlot ); } - const SfxPoolItem* GetOldItem( const SfxItemSet& rSet, USHORT nSlot ); - const SfxPoolItem* GetExchangeItem( const SfxItemSet& rSet, USHORT nSlot ); + sal_uInt16 GetSlot( sal_uInt16 nWhich ) const { return pSet->GetPool()->GetSlotId( nWhich ); } + sal_uInt16 GetWhich( sal_uInt16 nSlot ) const { return pSet->GetPool()->GetWhich( nSlot ); } public : virtual ~IconChoicePage(); const SfxItemSet& GetItemSet() const { return *pSet; } - virtual BOOL FillItemSet( SfxItemSet& ) = 0; + virtual sal_Bool FillItemSet( SfxItemSet& ) = 0; virtual void Reset( const SfxItemSet& ) = 0; - BOOL HasExchangeSupport() const { return bHasExchangeSupport; } - void SetExchangeSupport( BOOL bNew = TRUE ) { bHasExchangeSupport = bNew; } + sal_Bool HasExchangeSupport() const { return bHasExchangeSupport; } + void SetExchangeSupport( sal_Bool bNew = sal_True ) { bHasExchangeSupport = bNew; } enum { KEEP_PAGE = 0x0000, // Fehlerbehandlung; Seite nicht wechseln @@ -141,11 +139,9 @@ public : void SetUserData(const String& rString) { aUserString = rString; } String GetUserData() { return aUserString; } virtual void FillUserData(); - virtual BOOL IsReadOnly() const; + virtual sal_Bool IsReadOnly() const; virtual sal_Bool QueryClose(); - static const SfxPoolItem* GetItem( const SfxItemSet& rSet, USHORT nSlot ); - void StateChanged( StateChangedType nType ); void DataChanged( const DataChangedEvent& rDCEvt ); }; @@ -166,7 +162,7 @@ private : SvtIconChoiceCtrl maIconCtrl; // DAS IconChoice-Control - USHORT mnCurrentPageId; // Id der aktuell sichtbaren Page + sal_uInt16 mnCurrentPageId; // Id der aktuell sichtbaren Page // Buttons OKButton aOKBtn; @@ -177,51 +173,50 @@ private : const SfxItemSet* pSet; SfxItemSet* pOutSet; SfxItemSet* pExampleSet; - USHORT* pRanges; + sal_uInt16* pRanges; sal_uInt32 nResId; - BOOL bHideResetBtn; - BOOL bModal; - BOOL bInOK; - BOOL bModified; - BOOL bItemsReset; + sal_Bool bHideResetBtn; + sal_Bool bModal; + sal_Bool bInOK; + sal_Bool bModified; + sal_Bool bItemsReset; DECL_LINK ( ChosePageHdl_Impl, void * ); DECL_LINK ( OkHdl, Button * ); DECL_LINK ( ResetHdl, Button * ); DECL_LINK ( CancelHdl, Button * ); - IconChoicePageData* GetPageData ( USHORT nId ); + IconChoicePageData* GetPageData ( sal_uInt16 nId ); void Start_Impl(); - BOOL OK_Impl(); + sal_Bool OK_Impl(); - void SetPosSizeCtrls ( BOOL bInit = FALSE ); - void SetPosSizePages ( USHORT nId ); + void SetPosSizeCtrls ( sal_Bool bInit = sal_False ); + void SetPosSizePages ( sal_uInt16 nId ); - void FocusOnIcon ( USHORT nId ); + void FocusOnIcon ( sal_uInt16 nId ); protected : void ShowPageImpl ( IconChoicePageData* pData ); void HidePageImpl ( IconChoicePageData* pData ); - virtual void PageCreated( USHORT nId, IconChoicePage& rPage ); - virtual SfxItemSet* CreateInputItemSet( USHORT nId ); + virtual void PageCreated( sal_uInt16 nId, IconChoicePage& rPage ); + virtual SfxItemSet* CreateInputItemSet( sal_uInt16 nId ); inline SfxItemSet* GetInputSetImpl() { return (SfxItemSet*)pSet; } - inline IconChoicePage* GetTabPage( USHORT nPageId ) + inline IconChoicePage* GetTabPage( sal_uInt16 nPageId ) { return ( GetPageData (nPageId)->pPage?GetPageData (nPageId)->pPage:NULL); } const SfxItemSet* GetRefreshedSet(); void ActivatePageImpl (); - BOOL DeActivatePageImpl (); + sal_Bool DeActivatePageImpl (); void ResetPageImpl (); short Ok(); - BOOL IsInOK() const; public : - // im Ctor knnte auch die Position des IconChoiceCtrl's gesetzt werden. + // im Ctor k�nnte auch die Position des IconChoiceCtrl's gesetzt werden. IconChoiceDialog ( Window* pParent, const ResId &rResId, const EIconChoicePos ePos = PosLeft, const SfxItemSet * pItemSet = 0 ); @@ -238,22 +233,19 @@ public : // SvxIconChoiceCtrlEntry* AddTabPage( - USHORT nId, const String& rIconText, const Image& rChoiceIcon, + sal_uInt16 nId, const String& rIconText, const Image& rChoiceIcon, const Image& rChoiceIconHC, CreatePage pCreateFunc /* != NULL */, GetPageRanges pRangesFunc = NULL /* NULL allowed*/, - BOOL bItemsOnDemand = FALSE, ULONG nPos = LIST_APPEND ); - - void RemoveTabPage( USHORT nId ); + sal_Bool bItemsOnDemand = sal_False, sal_uLong nPos = LIST_APPEND ); - void SetCurPageId( USHORT nId ) { mnCurrentPageId = nId; FocusOnIcon( nId ); } - USHORT GetCurPageId() const { return mnCurrentPageId; } - void ShowPage( USHORT nId ); + void SetCurPageId( sal_uInt16 nId ) { mnCurrentPageId = nId; FocusOnIcon( nId ); } + sal_uInt16 GetCurPageId() const { return mnCurrentPageId; } + void ShowPage( sal_uInt16 nId ); + void RemoveTabPage( sal_uInt16 nId ); // liefert ggf. per Map konvertierte lokale Slots - const USHORT* GetInputRanges( const SfxItemPool& ); + const sal_uInt16* GetInputRanges( const SfxItemPool& ); void SetInputSet( const SfxItemSet* pInSet ); const SfxItemSet* GetOutputItemSet() const { return pOutSet; } - const SfxItemSet* GetOutputItemSet( USHORT nId ); - int FillOutputItemSet(); const OKButton& GetOKButton() const { return aOKBtn; } OKButton& GetOKButton() { return aOKBtn; } @@ -262,18 +254,13 @@ public : const HelpButton& GetHelpButton() const { return aHelpBtn; } HelpButton& GetHelpButton() { return aHelpBtn; } - void RemoveResetButton(); - short Execute(); - void Start( BOOL bShow = TRUE ); + void Start( sal_Bool bShow = sal_True ); sal_Bool QueryClose(); const SfxItemSet* GetExampleSet() const { return pExampleSet; } - void SetCtrlColor ( const Color& rColor ); EIconChoicePos SetCtrlPos ( const EIconChoicePos& rPos ); - - void CreateIconTextAutoMnemonics( void ); }; #endif //_ICCDLG_HXX diff --git a/cui/source/inc/insdlg.hxx b/cui/source/inc/insdlg.hxx index e9e36d57e27e..8cbc141b8b88 100644 --- a/cui/source/inc/insdlg.hxx +++ b/cui/source/inc/insdlg.hxx @@ -56,18 +56,18 @@ public: com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject > GetObject() { return m_xObj; } virtual ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetIconIfIconified( ::rtl::OUString* pGraphicMediaType ); - virtual BOOL IsCreateNew() const; + virtual sal_Bool IsCreateNew() const; }; class SvInsertOleDlg : public InsertObjectDialog_Impl { RadioButton aRbNewObject; RadioButton aRbObjectFromfile; + FixedLine aGbObject; ListBox aLbObjecttype; Edit aEdFilepath; PushButton aBtnFilepath; CheckBox aCbFilelink; - FixedLine aGbObject; OKButton aOKButton1; CancelButton aCancelButton1; HelpButton aHelpButton1; @@ -85,12 +85,10 @@ class SvInsertOleDlg : public InsertObjectDialog_Impl ListBox& GetObjectTypes() { return aLbObjecttype; } String GetFilePath() const { return aEdFilepath.GetText(); } - BOOL IsLinked() const { return aCbFilelink.IsChecked(); } - BOOL IsCreateNew() const { return aRbNewObject.IsChecked(); } + sal_Bool IsLinked() const { return aCbFilelink.IsChecked(); } + sal_Bool IsCreateNew() const { return aRbNewObject.IsChecked(); } public: - static void FillObjectServerList( SvObjectServerList* ); - SvInsertOleDlg( Window* pParent, const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& xStorage, const SvObjectServerList* pServers = NULL ); @@ -105,11 +103,11 @@ public: class SvInsertPlugInDialog : public InsertObjectDialog_Impl { private: + FixedLine aGbFileurl; Edit aEdFileurl; PushButton aBtnFileurl; - FixedLine aGbFileurl; - MultiLineEdit aEdPluginsOptions; FixedLine aGbPluginsOptions; + MultiLineEdit aEdPluginsOptions; OKButton aOKButton1; CancelButton aCancelButton1; HelpButton aHelpButton1; @@ -176,24 +174,25 @@ private: Edit aEDURL; PushButton aBTOpen; + FixedLine aFLScrolling; RadioButton aRBScrollingOn; RadioButton aRBScrollingOff; RadioButton aRBScrollingAuto; - FixedLine aFLScrolling; + FixedLine aFLSepLeft; + FixedLine aFLFrameBorder; RadioButton aRBFrameBorderOn; RadioButton aRBFrameBorderOff; - FixedLine aFLFrameBorder; FixedLine aFLSepRight; + FixedLine aFLMargin; FixedText aFTMarginWidth; NumericField aNMMarginWidth; CheckBox aCBMarginWidthDefault; FixedText aFTMarginHeight; NumericField aNMMarginHeight; CheckBox aCBMarginHeightDefault; - FixedLine aFLMargin; OKButton aOKButton1; CancelButton aCancelButton1; diff --git a/cui/source/inc/insrc.hxx b/cui/source/inc/insrc.hxx index d85b8a7680a5..33e8efabeb70 100644 --- a/cui/source/inc/insrc.hxx +++ b/cui/source/inc/insrc.hxx @@ -57,7 +57,7 @@ class SvxInsRowColDlg : public SvxAbstractInsRowColDlg, public ModalDialog bool bColumn; public: - SvxInsRowColDlg( Window* pParent, bool bCol, ULONG nHelpId ); + SvxInsRowColDlg( Window* pParent, bool bCol, const rtl::OString& sHelpId ); virtual short Execute(void); diff --git a/cui/source/inc/internationaloptions.hxx b/cui/source/inc/internationaloptions.hxx index a4372d52ddbe..cd3205935dae 100644 --- a/cui/source/inc/internationaloptions.hxx +++ b/cui/source/inc/internationaloptions.hxx @@ -43,7 +43,7 @@ namespace offapp protected: InternationalOptionsPage( Window* _pParent, const SfxItemSet& _rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& _rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& _rSet ); virtual void Reset( const SfxItemSet& _rSet ); public: diff --git a/cui/source/inc/labdlg.hxx b/cui/source/inc/labdlg.hxx index e35a83144c82..14fbc1e82160 100644 --- a/cui/source/inc/labdlg.hxx +++ b/cui/source/inc/labdlg.hxx @@ -66,23 +66,23 @@ private: String aStrVertList; short nCaptionType; - BOOL bFixedAngle; - INT32 nFixedAngle; - INT32 nGap; + sal_Bool bFixedAngle; + sal_Int32 nFixedAngle; + sal_Int32 nGap; short nEscDir; - BOOL bEscRel; - INT32 nEscAbs; - INT32 nEscRel; - INT32 nLineLen; - BOOL bFitLineLen; + sal_Bool bEscRel; + sal_Int32 nEscAbs; + sal_Int32 nEscRel; + sal_Int32 nLineLen; + sal_Bool bFitLineLen; - USHORT nAnsatzRelPos; - USHORT nAnsatzTypePos; - USHORT nWinkelTypePos; + sal_uInt16 nAnsatzRelPos; + sal_uInt16 nAnsatzTypePos; + sal_uInt16 nWinkelTypePos; #ifdef _SVX_LABDLG_CXX - void SetupAnsatz_Impl( USHORT nType ); - void SetupType_Impl( USHORT nType ); + void SetupAnsatz_Impl( sal_uInt16 nType ); + void SetupType_Impl( sal_uInt16 nType ); DECL_LINK( AnsatzSelectHdl_Impl, ListBox * ); DECL_LINK( AnsatzRelSelectHdl_Impl, ListBox * ); DECL_LINK( LineOptHdl_Impl, Button * ); @@ -97,9 +97,9 @@ public: virtual ~SvxCaptionTabPage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); void Construct(); void SetView( const SdrView* pSdrView ) @@ -115,16 +115,16 @@ class SvxCaptionTabDialog : public SfxTabDialog { private: const SdrView* pView; - USHORT nAnchorCtrls; + sal_uInt16 nAnchorCtrls; Link aValidateLink; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); public: SvxCaptionTabDialog(Window* pParent, const SdrView* pView, - USHORT nAnchorTypes = 0 ); + sal_uInt16 nAnchorTypes = 0 ); ~SvxCaptionTabDialog(); diff --git a/cui/source/inc/linkdlg.hxx b/cui/source/inc/linkdlg.hxx index 64d248c65b02..e7d1d555c188 100644 --- a/cui/source/inc/linkdlg.hxx +++ b/cui/source/inc/linkdlg.hxx @@ -54,21 +54,22 @@ class SvBaseLinksDlg : public ModalDialog FixedText aFtLinks; FixedText aFtType; FixedText aFtStatus; - CancelButton aCancelButton1; - HelpButton aHelpButton1; - PushButton aPbUpdateNow; - PushButton aPbOpenSource; - PushButton aPbChangeSource; - PushButton aPbBreakLink; + SvTabListBox aTbLinks; FixedText aFtFiles2; + FixedText aFtFullFileName; FixedText aFtSource2; + FixedText aFtFullSourceName; FixedText aFtType2; + FixedText aFtFullTypeName; FixedText aFtUpdate; RadioButton aRbAutomatic; RadioButton aRbManual; - FixedText aFtFullFileName; - FixedText aFtFullSourceName; - FixedText aFtFullTypeName; + CancelButton aCancelButton1; + HelpButton aHelpButton1; + PushButton aPbUpdateNow; + PushButton aPbOpenSource; + PushButton aPbChangeSource; + PushButton aPbBreakLink; String aStrAutolink; String aStrManuallink; String aStrBrokenlink; @@ -78,8 +79,7 @@ class SvBaseLinksDlg : public ModalDialog String aStrCloselinkmsgMulti; String aStrWaitinglink; sfx2::LinkManager* pLinkMgr; - BOOL bHtmlMode; - SvTabListBox aTbLinks; + sal_Bool bHtmlMode; Timer aUpdateTimer; #if _SOLAR__PRIVATE @@ -93,10 +93,10 @@ class SvBaseLinksDlg : public ModalDialog DECL_LINK( BreakLinkClickHdl, PushButton * ); DECL_LINK( UpdateWaitingHdl, Timer * ); DECL_LINK( EndEditHdl, sfx2::SvBaseLink* ); - sfx2::SvBaseLink* GetSelEntry( USHORT* pPos ); + sfx2::SvBaseLink* GetSelEntry( sal_uInt16* pPos ); String ImplGetStateStr( const sfx2::SvBaseLink& ); - void SetType( sfx2::SvBaseLink& rLink, USHORT nPos, USHORT nType ); - void InsertEntry( const sfx2::SvBaseLink& rLink, USHORT nPos = LISTBOX_APPEND, sal_Bool bSelect = sal_False); + void SetType( sfx2::SvBaseLink& rLink, sal_uInt16 nPos, sal_uInt16 nType ); + void InsertEntry( const sfx2::SvBaseLink& rLink, sal_uInt16 nPos = LISTBOX_APPEND, sal_Bool bSelect = sal_False); #endif void StartUpdateTimer() { aUpdateTimer.Start(); } @@ -123,7 +123,7 @@ class SvBaseLinksDlg : public ModalDialog void SetManager( sfx2::LinkManager* ); public: - SvBaseLinksDlg( Window * pParent, sfx2::LinkManager*, BOOL bHtml = FALSE ); + SvBaseLinksDlg( Window * pParent, sfx2::LinkManager*, sal_Bool bHtml = sal_False ); ~SvBaseLinksDlg(); void SetActLink( sfx2::SvBaseLink * pLink ); }; diff --git a/cui/source/inc/macroass.hxx b/cui/source/inc/macroass.hxx index 7b8330f31db6..51e61932cad1 100644 --- a/cui/source/inc/macroass.hxx +++ b/cui/source/inc/macroass.hxx @@ -42,9 +42,6 @@ class SvTabListBox; class Edit; class String; -typedef SvStringsDtor* (*FNGetRangeHdl)( _SfxMacroTabPage*, const String& rLanguage ); -typedef SvStringsDtor* (*FNGetMacrosOfRangeHdl)( _SfxMacroTabPage*, const String& rLanguage, const String& rRange ); - class SfxConfigGroupListBox_Impl; class SfxConfigFunctionListBox_Impl; class _HeaderTabListBox; @@ -60,8 +57,6 @@ class _SfxMacroTabPage : public SfxTabPage DECL_DLLPRIVATE_STATIC_LINK( _SfxMacroTabPage, DoubleClickHdl_Impl, Control* ); DECL_DLLPRIVATE_STATIC_LINK( _SfxMacroTabPage, AssignDeleteHdl_Impl, PushButton * ); - DECL_DLLPRIVATE_STATIC_LINK( _SfxMacroTabPage, ChangeScriptHdl_Impl, RadioButton * ); - DECL_DLLPRIVATE_STATIC_LINK( _SfxMacroTabPage, GetFocus_Impl, Edit* ); DECL_DLLPRIVATE_STATIC_LINK( _SfxMacroTabPage, TimeOut_Impl, Timer* ); protected: @@ -72,34 +67,26 @@ protected: void InitAndSetHandler(); void FillEvents(); void FillMacroList(); - void EnableButtons( const String& rLanguage ); + void EnableButtons(); public: virtual ~_SfxMacroTabPage(); - void AddEvent( const String & rEventName, USHORT nEventId ); + void AddEvent( const String & rEventName, sal_uInt16 nEventId ); const SvxMacroTableDtor& GetMacroTbl() const; void SetMacroTbl( const SvxMacroTableDtor& rTbl ); void ClearMacroTbl(); - virtual void ScriptChanged( const String& rLanguage ); + virtual void ScriptChanged(); virtual void PageCreated (SfxAllItemSet aSet); - // zum setzen / abfragen der Links - void SetGetRangeLink( FNGetRangeHdl pFn ); - FNGetRangeHdl GetGetRangeLink() const; - void SetGetMacrosOfRangeLink( FNGetMacrosOfRangeHdl pFn ); - FNGetMacrosOfRangeHdl GetGetMacrosOfRangeLink() const; - // --------- Erben aus der Basis ------------- - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); - void SetReadOnly( BOOL bSet ); - BOOL IsReadOnly() const; - void SelectEvent( const String& rEventName, USHORT nEventId ); + sal_Bool IsReadOnly() const; }; inline const SvxMacroTableDtor& _SfxMacroTabPage::GetMacroTbl() const diff --git a/cui/source/inc/macropg.hxx b/cui/source/inc/macropg.hxx index 3f475dfe818c..98d128310286 100644 --- a/cui/source/inc/macropg.hxx +++ b/cui/source/inc/macropg.hxx @@ -47,9 +47,9 @@ typedef ::boost::unordered_map< ::rtl::OUString, ::std::pair< ::rtl::OUString, : struct EventDisplayName { const sal_Char* pAsciiEventName; - USHORT nEventResourceID; + sal_uInt16 nEventResourceID; EventDisplayName() : pAsciiEventName( NULL ), nEventResourceID(0) { } - EventDisplayName( const sal_Char* _pAsciiName, const USHORT _nResId ) + EventDisplayName( const sal_Char* _pAsciiName, const sal_uInt16 _nResId ) : pAsciiEventName( _pAsciiName ) , nEventResourceID( _nResId ) { @@ -89,7 +89,7 @@ protected: _SvxMacroTabPage( Window* pParent, const ResId& rId, const SfxItemSet& rItemSet ); - void EnableButtons( const String& rLanguage ); + void EnableButtons(); ::com::sun::star::uno::Any GetPropsByName( const ::rtl::OUString& eventName, EventsHash& eventsHash ); ::std::pair< ::rtl::OUString, ::rtl::OUString > GetPairFromAny( ::com::sun::star::uno::Any aAny ); @@ -99,14 +99,14 @@ public: void InitResources(); void InitAndSetHandler( ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > xAppEvents, ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > xDocEvents, ::com::sun::star::uno::Reference< ::com::sun::star::util::XModifiable > xModifiable ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); using SfxTabPage::Reset; virtual void Reset(); void DisplayAppEvents( bool appEvents); - void SetReadOnly( BOOL bSet ); - BOOL IsReadOnly() const; + void SetReadOnly( sal_Bool bSet ); + sal_Bool IsReadOnly() const; }; class SvxMacroTabPage : public _SvxMacroTabPage @@ -124,12 +124,12 @@ public: // class SvxMacroAssignDlg -------------------------------------------------- -typedef USHORT* (*GetTabPageRanges)(); // liefert internationale Which-Werte +typedef sal_uInt16* (*GetTabPageRanges)(); // liefert internationale Which-Werte class SvxMacroAssignSingleTabDialog : public SfxModalDialog { public: - SvxMacroAssignSingleTabDialog( Window* pParent, const SfxItemSet& rOptionsSet, USHORT nUniqueId ); + SvxMacroAssignSingleTabDialog( Window* pParent, const SfxItemSet& rOptionsSet, sal_uInt16 nUniqueId ); virtual ~SvxMacroAssignSingleTabDialog(); diff --git a/cui/source/inc/measure.hxx b/cui/source/inc/measure.hxx index 268b4d9dd301..1d7a561301b7 100644 --- a/cui/source/inc/measure.hxx +++ b/cui/source/inc/measure.hxx @@ -81,7 +81,7 @@ private: const SdrView* pView; SfxMapUnit eUnit; - BOOL bPositionModified; + sal_Bool bPositionModified; #ifdef _SVX_MEASURE_CXX void FillUnitLB(); @@ -96,9 +96,9 @@ public: ~SvxMeasurePage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void PointChanged( Window* pWindow, RECT_POINT eRP ); diff --git a/cui/source/inc/multifil.hxx b/cui/source/inc/multifil.hxx index 83f35568516c..21ae9e53946e 100644 --- a/cui/source/inc/multifil.hxx +++ b/cui/source/inc/multifil.hxx @@ -48,7 +48,7 @@ private: DECL_LINK( DelHdl_Impl, PushButton * ); public: - SvxMultiFileDialog( Window* pParent, BOOL bEmptyAllowed = FALSE ); + SvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); ~SvxMultiFileDialog(); String GetFiles() const { return SvxMultiPathDialog::GetPath(); } diff --git a/cui/source/inc/multipat.hxx b/cui/source/inc/multipat.hxx index 6a79ccbcecd7..ac4afbfceaf6 100644 --- a/cui/source/inc/multipat.hxx +++ b/cui/source/inc/multipat.hxx @@ -74,7 +74,7 @@ protected: DECL_LINK( CheckHdl_Impl, svx::SvxRadioButtonListBox * ); public: - SvxMultiPathDialog( Window* pParent, BOOL bEmptyAllowed = FALSE ); + SvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); ~SvxMultiPathDialog(); String GetPath() const; diff --git a/cui/source/inc/numfmt.hxx b/cui/source/inc/numfmt.hxx index fe49487d39d0..2e9d51d8d45f 100644 --- a/cui/source/inc/numfmt.hxx +++ b/cui/source/inc/numfmt.hxx @@ -55,7 +55,7 @@ private: String aPrevStr; Color aPrevCol; - void InitSettings( BOOL bForeground, BOOL bBackground ); + void InitSettings( sal_Bool bForeground, sal_Bool bBackground ); protected: virtual void Paint( const Rectangle& rRect ); @@ -87,9 +87,9 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual int DeactivatePage ( SfxItemSet* pSet = NULL ); @@ -98,7 +98,7 @@ public: { SetInfoItem( rItem ); } void SetOkHdl( const Link& rOkHandler ); - void HideLanguage(BOOL nFlag=TRUE); + void HideLanguage(sal_Bool nFlag=sal_True); virtual long PreNotify( NotifyEvent& rNEvt ); virtual void PageCreated (SfxAllItemSet aSet); private: @@ -112,14 +112,14 @@ private: FixedText aFtLanguage; SvxLanguageBox aLbLanguage; CheckBox aCbSourceFormat; - + SvxNumberPreviewImpl aWndPreview; + FixedLine aFlOptions; FixedText aFtDecimals; NumericField aEdDecimals; + CheckBox aBtnNegRed; FixedText aFtLeadZeroes; NumericField aEdLeadZeroes; - CheckBox aBtnNegRed; CheckBox aBtnThousand; - FixedLine aFlOptions; FixedText aFtEdFormat; Edit aEdFormat; @@ -131,15 +131,14 @@ private: Edit aEdComment; Timer aResetWinTimer; - SvxNumberPreviewImpl aWndPreview; SvxNumberInfoItem* pNumItem; SvxNumberFormatShell* pNumFmtShell; - ULONG nInitFormat; + sal_uLong nInitFormat; Link fnOkHdl; - BOOL bNumItemFlag; //Fuer Handling mit DocShell - BOOL bOneAreaFlag; + sal_Bool bNumItemFlag; //Fuer Handling mit DocShell + sal_Bool bOneAreaFlag; short nFixedCategory; long nCatHeight; @@ -156,16 +155,16 @@ private: void Init_Impl(); void FillCurrencyBox(); void FillFormatListBox_Impl( SvxDelStrgs& rEntries ); - void UpdateOptions_Impl( BOOL bCheckCatChange ); - void UpdateFormatListBox_Impl( USHORT bCat, BOOL bUpdateEdit ); + void UpdateOptions_Impl( sal_Bool bCheckCatChange ); + void UpdateFormatListBox_Impl( sal_uInt16 bCat, sal_Bool bUpdateEdit ); void DeleteEntryList_Impl( SvxDelStrgs& rEntries ); void Obstructing(); void EnableBySourceFormat_Impl(); - void SetCategory( USHORT nPos ); + void SetCategory( sal_uInt16 nPos ); String GetExpColorString( Color*& rpPreviewColor, const String& aFormatStr, short nTmpCatPos ); void MakePreviewText( const String& rFormat ); - void ChangePreviewText( USHORT nPos ); - void AddAutomaticLanguage_Impl(LanguageType eAutoLang, BOOL bSelect); + void ChangePreviewText( sal_uInt16 nPos ); + void AddAutomaticLanguage_Impl(LanguageType eAutoLang, sal_Bool bSelect); // Handler DECL_LINK( LostFocusHdl_Impl, Edit* pEd ); DECL_LINK( DoubleClickHdl_Impl, SvxFontListBox* pLb ); diff --git a/cui/source/inc/numpages.hxx b/cui/source/inc/numpages.hxx index c06924ec90ad..9604f22d7dde 100644 --- a/cui/source/inc/numpages.hxx +++ b/cui/source/inc/numpages.hxx @@ -81,12 +81,12 @@ class SvxSingleNumPickTabPage : public SfxTabPage SvxNumSettingsArr_Impl aNumSettingsArr; SvxNumRule* pActNum; SvxNumRule* pSaveNum; - USHORT nActNumLvl; - BOOL bModified : 1; - BOOL bPreset : 1; + sal_uInt16 nActNumLvl; + sal_Bool bModified : 1; + sal_Bool bPreset : 1; String sNumCharFmtName; - USHORT nNumItemId; + sal_uInt16 nNumItemId; protected: DECL_LINK( NumSelectHdl_Impl, ValueSet*); @@ -102,7 +102,7 @@ class SvxSingleNumPickTabPage : public SfxTabPage virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void SetNumCharFmtName(const String& rName){sNumCharFmtName = rName;} @@ -120,10 +120,10 @@ class SvxBulletPickTabPage : public SfxTabPage SvxNumValueSet* pExamplesVS; SvxNumRule* pActNum; SvxNumRule* pSaveNum; - USHORT nActNumLvl; - BOOL bModified : 1; - BOOL bPreset : 1; - USHORT nNumItemId; + sal_uInt16 nActNumLvl; + sal_Bool bModified : 1; + sal_Bool bPreset : 1; + sal_uInt16 nNumItemId; String sBulletCharFmtName; protected: @@ -139,7 +139,7 @@ class SvxBulletPickTabPage : public SfxTabPage virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void SetCharFmtName(const String& rName){sBulletCharFmtName = rName;} @@ -165,10 +165,10 @@ class SvxNumPickTabPage : public SfxTabPage SvxNumRule* pActNum; SvxNumRule* pSaveNum; - USHORT nActNumLvl; - USHORT nNumItemId; - BOOL bModified : 1; - BOOL bPreset : 1; + sal_uInt16 nActNumLvl; + sal_uInt16 nNumItemId; + sal_Bool bModified : 1; + sal_Bool bPreset : 1; protected: @@ -185,7 +185,7 @@ class SvxNumPickTabPage : public SfxTabPage virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void SetCharFmtNames(const String& rCharName, const String& rBulName) @@ -211,11 +211,11 @@ class SvxBitmapPickTabPage : public SfxTabPage SvxNumRule* pActNum; SvxNumRule* pSaveNum; - USHORT nActNumLvl; - USHORT nNumItemId; + sal_uInt16 nActNumLvl; + sal_uInt16 nNumItemId; SfxMapUnit eCoreUnit; - BOOL bModified : 1; - BOOL bPreset : 1; + sal_Bool bModified : 1; + sal_Bool bPreset : 1; protected: DECL_LINK( NumSelectHdl_Impl, ValueSet*); @@ -232,7 +232,7 @@ class SvxBitmapPickTabPage : public SfxTabPage virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void SetNumCharFmtName(const String& rName){sNumCharFmtName = rName;} @@ -292,25 +292,25 @@ class SvxNumOptionsTabPage : public SfxTabPage Size aInitSize[SVX_MAX_NUM]; - BOOL bLastWidthModified : 1; - BOOL bModified : 1; - BOOL bPreset : 1; - BOOL bAutomaticCharStyles: 1; - BOOL bHTMLMode : 1; - BOOL bMenuButtonInitialized : 1; + sal_Bool bLastWidthModified : 1; + sal_Bool bModified : 1; + sal_Bool bPreset : 1; + sal_Bool bAutomaticCharStyles: 1; + sal_Bool bHTMLMode : 1; + sal_Bool bMenuButtonInitialized : 1; List aGrfNames; Font aActBulletFont; String sBullet; String sStartWith; - BYTE nBullet; - USHORT nActNumLvl; - USHORT nNumItemId; + sal_uInt8 nBullet; + sal_uInt16 nActNumLvl; + sal_uInt16 nNumItemId; SfxMapUnit eCoreUnit; void InitControls(); - void SwitchNumberType( BYTE nType, BOOL bBmp = FALSE ); + void SwitchNumberType( sal_uInt8 nType, sal_Bool bBmp = sal_False ); void CheckForStartValue_Impl(sal_uInt16 nNumberingType); DECL_LINK( NumberTypeSelectHdl_Impl, ListBox * ); @@ -341,7 +341,7 @@ class SvxNumOptionsTabPage : public SfxTabPage virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void SetCharFmts(const String& rNumName, const String& rBulletName ) @@ -352,7 +352,7 @@ class SvxNumOptionsTabPage : public SfxTabPage void SetMetric(FieldUnit eSet); ListBox& GetCharFmtListBox() {return aCharFmtLB;} - void SetModified(BOOL bRepaint = TRUE); + void SetModified(sal_Bool bRepaint = sal_True); virtual void PageCreated(SfxAllItemSet aSet); }; @@ -401,13 +401,13 @@ class SvxNumPositionTabPage : public SfxTabPage SvxNumRule* pActNum; SvxNumRule* pSaveNum; - USHORT nActNumLvl; - USHORT nNumItemId; + sal_uInt16 nActNumLvl; + sal_uInt16 nNumItemId; SfxMapUnit eCoreUnit; - BOOL bModified : 1; - BOOL bPreset : 1; - BOOL bInInintControl : 1; //Modify-Fehler umgehen, soll ab 391 behoben sein + sal_Bool bModified : 1; + sal_Bool bPreset : 1; + sal_Bool bInInintControl : 1; //Modify-Fehler umgehen, soll ab 391 behoben sein bool bLabelAlignmentPosAndSpaceModeActive; void InitControls(); @@ -433,14 +433,14 @@ public: virtual void ActivatePage(const SfxItemSet& rSet); virtual int DeactivatePage(SfxItemSet *pSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); void SetMetric(FieldUnit eSet); - void SetModified(BOOL bRepaint = TRUE); + void SetModified(sal_Bool bRepaint = sal_True); virtual void PageCreated(SfxAllItemSet aSet); }; diff --git a/cui/source/inc/optasian.hxx b/cui/source/inc/optasian.hxx index ac558573f048..c526d23420a1 100644 --- a/cui/source/inc/optasian.hxx +++ b/cui/source/inc/optasian.hxx @@ -71,8 +71,8 @@ public: virtual ~SvxAsianLayoutPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - static UINT16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + static sal_uInt16* GetRanges(); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/inc/optdict.hxx b/cui/source/inc/optdict.hxx index ca1d0f395344..07d6308b534b 100644 --- a/cui/source/inc/optdict.hxx +++ b/cui/source/inc/optdict.hxx @@ -62,12 +62,12 @@ namespace linguistic2{ class SvxNewDictionaryDialog : public ModalDialog { private: + FixedLine aNewDictBox; FixedText aNameText; Edit aNameEdit; FixedText aLanguageText; SvxLanguageBox aLanguageLB; CheckBox aExceptBtn; - FixedLine aNewDictBox; OKButton aOKBtn; CancelButton aCancelBtn; HelpButton aHelpBtn; @@ -131,8 +131,8 @@ private: PushButton aDeletePB; FixedLine aEditDictsBox; - CancelButton aCloseBtn; HelpButton aHelpBtn; + CancelButton aCloseBtn; String sModify; String sNew; DecorationView aDecoView; @@ -147,7 +147,7 @@ private: long nWidth; sal_Bool bFirstSelect; sal_Bool bDoNothing; - BOOL bDicIsReadonly; + sal_Bool bDicIsReadonly; #ifdef _SVX_OPTDICT_CXX DECL_LINK( SelectBookHdl_Impl, ListBox * ); @@ -164,7 +164,7 @@ private: ::com::sun::star::linguistic2::XDictionary > &xDic ); void RemoveDictEntry(SvLBoxEntry* pEntry); - USHORT GetLBInsertPos(const String &rDicWord); + sal_uInt16 GetLBInsertPos(const String &rDicWord); #endif diff --git a/cui/source/inc/optimprove.hxx b/cui/source/inc/optimprove.hxx index 532a9fcc68d7..0666c78df0bd 100644 --- a/cui/source/inc/optimprove.hxx +++ b/cui/source/inc/optimprove.hxx @@ -37,14 +37,6 @@ #include <sfx2/basedlgs.hxx> #include <sfx2/tabdlg.hxx> -// class SvxEmptyPage ---------------------------------------------------- - -class SvxEmptyPage : public TabPage -{ -public: - SvxEmptyPage( Window* pParent ); -}; - // class SvxImprovementPage ---------------------------------------------- class SvxImprovementPage : public TabPage @@ -68,7 +60,7 @@ public: SvxImprovementPage( Window* pParent ); ~SvxImprovementPage(); - inline bool IsYesChecked() const { return m_aYesRB.IsChecked() != FALSE; } + inline bool IsYesChecked() const { return m_aYesRB.IsChecked() != sal_False; } inline String GetPageText() const { return GetText(); } inline String GetInvitationText() const { return m_aInvitationFT.GetText(); } @@ -106,7 +98,6 @@ public: virtual ~SvxImprovementOptionsPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static sal_uInt16* GetRanges(); virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); @@ -124,17 +115,6 @@ public: SvxImprovementDialog( Window* pParent, const String& rInfoURL ); }; -class SvxInfoWindow : public Window -{ -private: - FixedText m_aInfoText; - -public: - SvxInfoWindow( Window* pParent, const ResId& rResId ); - - void SetInfoText( const String& rText ); -}; - #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/inc/optlingu.hxx b/cui/source/inc/optlingu.hxx index 303ca2558ae3..3a13365397d0 100644 --- a/cui/source/inc/optlingu.hxx +++ b/cui/source/inc/optlingu.hxx @@ -87,7 +87,7 @@ class SvxEditModulesDlg : public ModalDialog SvLBoxButtonData* pCheckButtonData; - SvLBoxEntry* CreateEntry(String& rTxt, USHORT nCol); + SvLBoxEntry* CreateEntry(String& rTxt, sal_uInt16 nCol); #ifdef _SVX_OPTLINGU_CXX DECL_LINK( SelectHdl_Impl, SvxCheckListBox * ); @@ -150,10 +150,10 @@ private: SvxLinguData_Impl* pLinguData; SvxLinguTabPage( Window* pParent, const SfxItemSet& rCoreSet ); - SvLBoxEntry* CreateEntry(String& rTxt, USHORT nCol); + SvLBoxEntry* CreateEntry(String& rTxt, sal_uInt16 nCol); - void AddDicBoxEntry( const com::sun::star::uno::Reference< com::sun::star::linguistic2::XDictionary > &rxDic, USHORT nIdx ); - ULONG GetDicUserData( const com::sun::star::uno::Reference< com::sun::star::linguistic2::XDictionary > &rxDic, USHORT nIdx ); + void AddDicBoxEntry( const com::sun::star::uno::Reference< com::sun::star::linguistic2::XDictionary > &rxDic, sal_uInt16 nIdx ); + sal_uLong GetDicUserData( const com::sun::star::uno::Reference< com::sun::star::linguistic2::XDictionary > &rxDic, sal_uInt16 nIdx ); #ifdef _SVX_OPTLINGU_CXX DECL_LINK( SelectHdl_Impl, SvxCheckListBox * ); diff --git a/cui/source/inc/optpath.hxx b/cui/source/inc/optpath.hxx index ab72fe4a4773..2f9a428b9d37 100644 --- a/cui/source/inc/optpath.hxx +++ b/cui/source/inc/optpath.hxx @@ -89,9 +89,9 @@ private: DECL_LINK( DialogClosedHdl, ::com::sun::star::ui::dialogs::DialogClosedEvent* ); - void GetPathList( USHORT _nPathHandle, String& _rInternalPath, + void GetPathList( sal_uInt16 _nPathHandle, String& _rInternalPath, String& _rUserPath, String& _rWritablePath, sal_Bool& _rReadOnly ); - void SetPathList( USHORT _nPathHandle, + void SetPathList( sal_uInt16 _nPathHandle, const String& _rUserPath, const String& _rWritablePath ); #endif @@ -100,9 +100,9 @@ public: ~SvxPathTabPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); }; diff --git a/cui/source/inc/page.hxx b/cui/source/inc/page.hxx index e7f4506c4796..289dac171671 100644 --- a/cui/source/inc/page.hxx +++ b/cui/source/inc/page.hxx @@ -77,7 +77,7 @@ */ struct SvxPage_Impl; -typedef USHORT MarginPosition; +typedef sal_uInt16 MarginPosition; class SvxPageDescPage : public SfxTabPage { @@ -117,6 +117,7 @@ class SvxPageDescPage : public SfxTabPage FixedText aBottomMarginLbl; MetricField aBottomMarginEdit; + FixedLine aBottomSeparatorFl; // layout settings FixedLine aLayoutFL; FixedText aPageText; @@ -124,7 +125,6 @@ class SvxPageDescPage : public SfxTabPage FixedText aNumberFormatText; ListBox aNumberFormatBox; - FixedLine aBottomSeparatorFl; //Extras Calc FixedText aTblAlignFT; @@ -157,7 +157,7 @@ class SvxPageDescPage : public SfxTabPage long nLastBottomMargin; Size aMaxSize; - BOOL bLandscape; + sal_Bool bLandscape; bool bBorderModified; SvxModeType eMode; Paper ePaperStart; @@ -210,9 +210,9 @@ protected: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rOutSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rOutSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); diff --git a/cui/source/inc/paragrph.hxx b/cui/source/inc/paragrph.hxx index 7182d2b0d91a..6332e2e41b7e 100644 --- a/cui/source/inc/paragrph.hxx +++ b/cui/source/inc/paragrph.hxx @@ -66,6 +66,7 @@ class SvxStdParagraphTabPage: public SfxTabPage private: SvxStdParagraphTabPage( Window* pParent, const SfxItemSet& rSet ); + FixedLine aIndentFrm; // Einzug FixedText aLeftLabel; SvxRelativeField aLeftIndent; @@ -77,39 +78,38 @@ private: SvxRelativeField aFLineIndent; CheckBox aAutoCB; - FixedLine aIndentFrm; + FixedLine aDistFrm; // Abstaende FixedText aTopLabel; SvxRelativeField aTopDist; FixedText aBottomLabel; SvxRelativeField aBottomDist; - FixedLine aDistFrm; // Zeilenabstand + FixedLine aLineDistFrm; ListBox aLineDist; FixedText aLineDistAtLabel; MetricField aLineDistAtPercentBox; MetricField aLineDistAtMetricBox; - FixedLine aLineDistFrm; String sAbsDist; SvxParaPrevWindow aExampleWin; //Registerhaltigkeit - nur Writer - CheckBox aRegisterCB; FixedLine aRegisterFL; + CheckBox aRegisterCB; Edit* pActLineDistFld; long nAbst; long nWidth; long nMinFixDist; - BOOL bRelativeMode; - BOOL bNegativeIndents; + sal_Bool bRelativeMode; + sal_Bool bNegativeIndents; #ifdef _SVX_PARAGRPH_CXX void SetLineSpacing_Impl( const SvxLineSpacingItem& rAttr ); void Init_Impl(); - void UpdateExample_Impl( BOOL bAll = FALSE ); + void UpdateExample_Impl( sal_Bool bAll = sal_False ); DECL_LINK( LineDistHdl_Impl, ListBox* ); DECL_LINK( ModifyHdl_Impl, SvxRelativeField* ); @@ -123,14 +123,13 @@ public: DECL_LINK( ELRLoseFocusHdl, Edit* ); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); - void SetPageWidth( USHORT nPageWidth ); - void SetMaxDistance( USHORT nMaxDist ); + void SetPageWidth( sal_uInt16 nPageWidth ); void EnableRelativeMode(); void EnableRegisterMode(); void EnableAutoFirstLine(); @@ -174,7 +173,7 @@ class SvxParaAlignTabPage : public SfxTabPage DECL_LINK( LastLineHdl_Impl, ListBox* ); DECL_LINK( TextDirectionHdl_Impl, ListBox* ); - void UpdateExample_Impl( BOOL bAll = FALSE ); + void UpdateExample_Impl( sal_Bool bAll = sal_False ); #endif SvxParaAlignTabPage( Window* pParent, const SfxItemSet& rSet ); @@ -185,9 +184,9 @@ protected: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void EnableJustifyExt(); @@ -219,9 +218,9 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); void DisablePageBreak(); @@ -233,6 +232,7 @@ private: SvxExtParagraphTabPage( Window* pParent, const SfxItemSet& rSet ); // Silbentrennung + FixedLine aExtFL; TriStateBox aHyphenBox; FixedText aBeforeText; NumericField aExtHyphenBeforeBox; @@ -240,7 +240,6 @@ private: NumericField aExtHyphenAfterBox; FixedText aMaxHyphenLabel; NumericField aMaxHyphenEdit; - FixedLine aExtFL; // Seitenumbruch FixedLine aBreaksFL; @@ -269,9 +268,9 @@ private: NumericField aWidowRowNo; FixedText aWidowRowLabel; - BOOL bPageBreak; - BOOL bHtmlMode; - USHORT nStdPos; + sal_Bool bPageBreak; + sal_Bool bHtmlMode; + sal_uInt16 nStdPos; #ifdef _SVX_PARAGRPH_CXX DECL_LINK( PageBreakHdl_Impl, TriStateBox* ); @@ -307,9 +306,9 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/inc/pastedlg.hxx b/cui/source/inc/pastedlg.hxx index 924edae728a5..1e27ce912e80 100644 --- a/cui/source/inc/pastedlg.hxx +++ b/cui/source/inc/pastedlg.hxx @@ -53,10 +53,10 @@ class SvPasteObjectDialog : public ModalDialog FixedText aFtObjectSource; RadioButton aRbPaste; RadioButton aRbPasteLink; - ListBox aLbInsertList; CheckBox aCbDisplayAsIcon; PushButton aPbChangeIcon; FixedLine aFlChoice; + ListBox aLbInsertList; OKButton aOKButton1; CancelButton aCancelButton1; HelpButton aHelpButton1; @@ -64,8 +64,8 @@ class SvPasteObjectDialog : public ModalDialog Table aSupplementTable; SvGlobalName aObjClassName; String aObjName; - USHORT nAspect; - BOOL bLink; + sal_uInt16 nAspect; + sal_Bool bLink; ListBox& ObjectLB() { return aLbInsertList; } FixedText& ObjectSource() { return aFtObjectSource; } @@ -77,8 +77,8 @@ class SvPasteObjectDialog : public ModalDialog DECL_LINK( SelectHdl, ListBox * ); DECL_LINK( DoubleClickHdl, ListBox * ); void SetDefault(); - USHORT GetAspect() const { return nAspect; } - BOOL ShouldLink() const { return bLink; } + sal_uInt16 GetAspect() const { return nAspect; } + sal_Bool ShouldLink() const { return bLink; } public: SvPasteObjectDialog( Window* pParent ); @@ -86,7 +86,7 @@ public: void Insert( SotFormatStringId nFormat, const String & rFormatName ); void SetObjName( const SvGlobalName & rClass, const String & rObjName ); - ULONG GetFormat( const TransferableDataHelper& aHelper, + sal_uLong GetFormat( const TransferableDataHelper& aHelper, const DataFlavorExVector* pFormats=0, const TransferableObjectDescriptor* pDesc=0 ); }; diff --git a/cui/source/inc/postdlg.hxx b/cui/source/inc/postdlg.hxx index 4648fd3a0a0c..651b5328e460 100644 --- a/cui/source/inc/postdlg.hxx +++ b/cui/source/inc/postdlg.hxx @@ -31,7 +31,7 @@ // include --------------------------------------------------------------- #include <vcl/group.hxx> -#include <vcl/imagebtn.hxx> +#include <vcl/button.hxx> #include <vcl/edit.hxx> #include <svtools/stdctrl.hxx> #include <sfx2/basedlgs.hxx> @@ -56,10 +56,10 @@ class SvxPostItDialog : public SfxModalDialog { public: SvxPostItDialog( Window* pParent, const SfxItemSet& rCoreSet, - BOOL bPrevNext = FALSE, BOOL bRedline = FALSE ); + sal_Bool bPrevNext = sal_False, sal_Bool bRedline = sal_False ); ~SvxPostItDialog(); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); const SfxItemSet* GetOutputItemSet() const { return pOutSet; } Link GetPrevHdl() const { return aPrevHdlLink; } @@ -69,20 +69,20 @@ public: void SetNextHdl( const Link& rLink ) { aNextHdlLink = rLink; } - void EnableTravel(BOOL bNext, BOOL bPrev); + void EnableTravel(sal_Bool bNext, sal_Bool bPrev); inline String GetNote() { return aEditED.GetText(); } inline void SetNote(const String& rTxt) { aEditED.SetText(rTxt); } void ShowLastAuthor(const String& rAuthor, const String& rDate); - inline void DontChangeAuthor() { aAuthorBtn.Enable(FALSE); } + inline void DontChangeAuthor() { aAuthorBtn.Enable(sal_False); } inline void HideAuthor() { aAuthorBtn.Hide(); } - inline void SetReadonlyPostIt(BOOL bDisable) + inline void SetReadonlyPostIt(sal_Bool bDisable) { aOKBtn.Enable( !bDisable ); aEditED.SetReadOnly( bDisable ); aAuthorBtn.Enable( !bDisable ); } - inline BOOL IsOkEnabled() const { return aOKBtn.IsEnabled(); } + inline sal_Bool IsOkEnabled() const { return aOKBtn.IsEnabled(); } private: FixedLine aPostItFL; diff --git a/cui/source/inc/scriptdlg.hxx b/cui/source/inc/scriptdlg.hxx index 10c3408481e2..a4350685cba9 100644 --- a/cui/source/inc/scriptdlg.hxx +++ b/cui/source/inc/scriptdlg.hxx @@ -70,7 +70,7 @@ class SFTreeListBox : public SvTreeListBox { friend class SvxScriptOrgDialog; private: - USHORT nMode; + sal_uInt16 nMode; Image m_hdImage; Image m_libImage; Image m_macImage; @@ -88,13 +88,7 @@ protected: void ExpandTree( SvLBoxEntry* pRootEntry ); virtual void RequestingChilds( SvLBoxEntry* pParent ); virtual void ExpandedHdl(); - SvLBoxEntry* FindEntry( SvLBoxEntry* pParent, const String& rText, BYTE nType ); virtual long ExpandingHdl(); - static BOOL dialogSort1( com::sun::star::uno::Reference< com::sun::star::script::browse::XBrowseNode > node1, - com::sun::star::uno::Reference< com::sun::star::script::browse::XBrowseNode > node2 ); - static BOOL dialogSort2( com::sun::star::uno::Reference< com::sun::star::script::browse::XBrowseNode > node1, - com::sun::star::uno::Reference< com::sun::star::script::browse::XBrowseNode > node2 ); - public: void Init( const ::rtl::OUString& language ); void RequestSubEntries( SvLBoxEntry* pRootEntry, ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& node, @@ -102,18 +96,16 @@ public: SFTreeListBox( Window* pParent, const ResId& rRes ); ~SFTreeListBox(); - void UpdateEntries(); - void ExpandAllTrees(); - SvLBoxEntry * insertEntry(String const & rText, USHORT nBitmap, + SvLBoxEntry * insertEntry(String const & rText, sal_uInt16 nBitmap, SvLBoxEntry * pParent, bool bChildrenOnDemand, std::auto_ptr< SFEntry > aUserData, ::rtl::OUString factoryURL ); - SvLBoxEntry * insertEntry(String const & rText, USHORT nBitmap, + SvLBoxEntry * insertEntry(String const & rText, sal_uInt16 nBitmap, SvLBoxEntry * pParent, bool bChildrenOnDemand, std::auto_ptr< SFEntry > aUserData ); @@ -130,7 +122,7 @@ private: CancelButton aCancelButton; public: - InputDialog( Window * pParent, USHORT nMode ); + InputDialog( Window * pParent, sal_uInt16 nMode ); ~InputDialog(); String GetObjectName() const { return aEdit.GetText(); } @@ -140,21 +132,21 @@ public: class SFEntry { private: - BYTE nType; + sal_uInt8 nType; bool loaded; ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode > nodes; ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > model; SFEntry(){} public: - SFEntry( BYTE nT ) { nType = nT; loaded=false; } - SFEntry( BYTE nT, + SFEntry( sal_uInt8 nT ) { nType = nT; loaded=false; } + SFEntry( sal_uInt8 nT, const ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& entryNodes , const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel >& entryModel) { nType = nT; nodes = entryNodes; loaded=false; model = entryModel; } SFEntry( const SFEntry& r ) { nType = r.nType; nodes = r.nodes; loaded = r.loaded; } virtual ~SFEntry() {} ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode > GetNode() { return nodes ;} ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > GetModel() { return model ;}; - BYTE GetType() const { return nType; } + sal_uInt8 GetType() const { return nType; } bool isLoaded() const { return loaded; } void setLoaded() { loaded=true; } }; @@ -190,10 +182,9 @@ protected: DECL_LINK( MacroDoubleClickHdl, SvTreeListBox * ); DECL_LINK( ScriptSelectHdl, SvTreeListBox * ); DECL_LINK( ButtonHdl, Button * ); - BOOL getBoolProperty( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& xProps, ::rtl::OUString& propName ); + sal_Bool getBoolProperty( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& xProps, ::rtl::OUString& propName ); void CheckButtons( ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& node ); - ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > getDocumentModel( ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xCtx, ::rtl::OUString& docName ); void createEntry( SvLBoxEntry* pEntry ); void renameEntry( SvLBoxEntry* pEntry ); @@ -201,7 +192,6 @@ protected: ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode > getBrowseNode( SvLBoxEntry* pEntry ); ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > getModel( SvLBoxEntry* pEntry ); - void EnableButton( Button& rButton, BOOL bEnable ); String getListOfChildren( ::com::sun::star::uno::Reference< com::sun::star::script::browse::XBrowseNode > node, int depth ); void StoreCurrentSelection(); void RestorePreviousSelection(); diff --git a/cui/source/inc/sdrcelldlg.hxx b/cui/source/inc/sdrcelldlg.hxx index 645a45da7d61..d830d92d2744 100644 --- a/cui/source/inc/sdrcelldlg.hxx +++ b/cui/source/inc/sdrcelldlg.hxx @@ -55,7 +55,7 @@ public: SvxFormatCellsDialog( Window* pParent, const SfxItemSet* pAttr, SdrModel* pModel ); ~SvxFormatCellsDialog(); - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); }; diff --git a/cui/source/inc/selector.hxx b/cui/source/inc/selector.hxx index 7ca6dbeb3054..2959b0e7bfb6 100644 --- a/cui/source/inc/selector.hxx +++ b/cui/source/inc/selector.hxx @@ -51,41 +51,41 @@ struct SvxGroupInfo_Impl { - USHORT nKind; - USHORT nOrd; + sal_uInt16 nKind; + sal_uInt16 nOrd; ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode > xBrowseNode; ::rtl::OUString sURL; ::rtl::OUString sHelpText; - BOOL bWasOpened; + sal_Bool bWasOpened; - SvxGroupInfo_Impl( USHORT n, USHORT nr ) + SvxGroupInfo_Impl( sal_uInt16 n, sal_uInt16 nr ) :nKind( n ) ,nOrd( nr ) ,xBrowseNode() ,sURL() ,sHelpText() - ,bWasOpened(FALSE) + ,bWasOpened(sal_False) { } - SvxGroupInfo_Impl( USHORT n, USHORT nr, const ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& _rxNode ) + SvxGroupInfo_Impl( sal_uInt16 n, sal_uInt16 nr, const ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& _rxNode ) :nKind( n ) ,nOrd( nr ) ,xBrowseNode( _rxNode ) ,sURL() ,sHelpText() - ,bWasOpened(FALSE) + ,bWasOpened(sal_False) { } - SvxGroupInfo_Impl( USHORT n, USHORT nr, const ::rtl::OUString& _rURL, const ::rtl::OUString& _rHelpText ) + SvxGroupInfo_Impl( sal_uInt16 n, sal_uInt16 nr, const ::rtl::OUString& _rURL, const ::rtl::OUString& _rHelpText ) :nKind( n ) ,nOrd( nr ) ,xBrowseNode() ,sURL( _rURL ) ,sHelpText( _rHelpText ) - ,bWasOpened(FALSE) + ,bWasOpened(sal_False) { } }; @@ -116,13 +116,8 @@ public: SvxConfigFunctionListBox_Impl( Window*, const ResId& ); ~SvxConfigFunctionListBox_Impl(); void ClearAll(); - SvLBoxEntry* GetEntry_Impl( USHORT nId ); - SvLBoxEntry* GetEntry_Impl( const String& ); - USHORT GetId( SvLBoxEntry *pEntry ); String GetHelpText( SvLBoxEntry *pEntry ); using Window::GetHelpText; - USHORT GetCurId() - { return GetId( FirstSelected() ); } SvLBoxEntry* GetLastSelectedEntry(); void FunctionSelected(); @@ -175,7 +170,7 @@ private: protected: virtual void RequestingChilds( SvLBoxEntry *pEntry); - virtual BOOL Expand( SvLBoxEntry* pParent ); + virtual sal_Bool Expand( SvLBoxEntry* pParent ); using SvListView::Expand; public: @@ -189,7 +184,7 @@ public: ~SvxConfigGroupListBox_Impl(); void Init(); - void Open( SvLBoxEntry*, BOOL ); + void Open( SvLBoxEntry*, sal_Bool ); void ClearAll(); void GroupSelected(); @@ -213,7 +208,7 @@ class SvxScriptSelectorDialog : public ModelessDialog FixedLine aDescription; FixedText aDescriptionText; - BOOL m_bShowSlots; + sal_Bool m_bShowSlots; Link m_aAddHdl; DECL_LINK( ClickHdl, Button * ); @@ -227,7 +222,7 @@ public: SvxScriptSelectorDialog ( Window* pParent = NULL, - BOOL bShowSlots = FALSE, + sal_Bool bShowSlots = sal_False, const ::com::sun::star::uno::Reference < ::com::sun::star::frame::XFrame >& xFrame = 0 ); @@ -240,7 +235,6 @@ public: void SetImageProvider( ImageProvider* provider ) { aCategories.SetImageProvider( provider ); } - USHORT GetSelectedId(); String GetScriptURL() const; String GetSelectedDisplayName(); String GetSelectedHelpText(); diff --git a/cui/source/inc/splitcelldlg.hxx b/cui/source/inc/splitcelldlg.hxx index e451ddba36cc..497a0c3afed9 100644 --- a/cui/source/inc/splitcelldlg.hxx +++ b/cui/source/inc/splitcelldlg.hxx @@ -30,7 +30,7 @@ #include <vcl/fixed.hxx> #include <vcl/field.hxx> -#include <vcl/imagebtn.hxx> +#include <vcl/button.hxx> #include <vcl/button.hxx> #include <svx/stddlg.hxx> @@ -38,13 +38,13 @@ class SvxSplitTableDlg : public SvxAbstractSplittTableDialog, public SvxStandardDialog { + FixedLine maCountFL; FixedText maCountLbl; NumericField maCountEdit; - FixedLine maCountFL; + FixedLine maDirFL; ImageRadioButton maHorzBox; ImageRadioButton maVertBox; CheckBox maPropCB; - FixedLine maDirFL; OKButton maOKBtn; CancelButton maCancelBtn; HelpButton maHelpBtn; diff --git a/cui/source/inc/srchxtra.hxx b/cui/source/inc/srchxtra.hxx index bbb01fe9dbf2..72457dd9869f 100644 --- a/cui/source/inc/srchxtra.hxx +++ b/cui/source/inc/srchxtra.hxx @@ -46,7 +46,7 @@ public: ~SvxSearchFormatDialog(); protected: - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); private: FontList* pFontList; @@ -58,7 +58,7 @@ class SvxSearchAttributeDialog : public ModalDialog { public: SvxSearchAttributeDialog( Window* pParent, SearchAttrItemList& rLst, - const USHORT* pWhRanges ); + const sal_uInt16* pWhRanges ); private: FixedText aAttrFL; @@ -93,15 +93,15 @@ private: public: SvxSearchSimilarityDialog( Window* pParent, - BOOL bRelax, - USHORT nOther, - USHORT nShorter, - USHORT nLonger ); - - USHORT GetOther() { return (USHORT)aOtherFld.GetValue(); } - USHORT GetShorter() { return (USHORT)aShorterFld.GetValue(); } - USHORT GetLonger() { return (USHORT)aLongerFld.GetValue(); } - BOOL IsRelaxed() { return aRelaxBox.IsChecked(); } + sal_Bool bRelax, + sal_uInt16 nOther, + sal_uInt16 nShorter, + sal_uInt16 nLonger ); + + sal_uInt16 GetOther() { return (sal_uInt16)aOtherFld.GetValue(); } + sal_uInt16 GetShorter() { return (sal_uInt16)aShorterFld.GetValue(); } + sal_uInt16 GetLonger() { return (sal_uInt16)aLongerFld.GetValue(); } + sal_Bool IsRelaxed() { return aRelaxBox.IsChecked(); } }; diff --git a/cui/source/inc/tabstpge.hxx b/cui/source/inc/tabstpge.hxx index b6175bb0bf28..7fff39c09611 100644 --- a/cui/source/inc/tabstpge.hxx +++ b/cui/source/inc/tabstpge.hxx @@ -65,12 +65,12 @@ public: ~SvxTabulatorTabPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); - void DisableControls( const USHORT nFlag ); + void DisableControls( const sal_uInt16 nFlag ); protected: virtual int DeactivatePage( SfxItemSet* pSet = 0 ); @@ -79,10 +79,11 @@ private: SvxTabulatorTabPage( Window* pParent, const SfxItemSet& rSet ); // Tabulatoren und Positionen - MetricBox aTabBox; FixedLine aTabLabel; + MetricBox aTabBox; FixedLine aTabLabelVert; + FixedLine aTabTypeLabel; // TabType RadioButton aLeftTab; RadioButton aRightTab; @@ -96,8 +97,8 @@ private: FixedText aDezCharLabel; Edit aDezChar; - FixedLine aTabTypeLabel; + FixedLine aFillLabel; // Fuellzeichen RadioButton aNoFillChar; RadioButton aFillPoints; @@ -105,8 +106,6 @@ private: RadioButton aFillSolidLine; RadioButton aFillSpecial; Edit aFillChar; - FixedLine aFillLabel; - // Buttons PushButton aNewBtn; PushButton aDelAllBtn; @@ -117,10 +116,10 @@ private: SvxTabStopItem aNewTabs; long nDefDist; FieldUnit eDefUnit; - BOOL bCheck; + sal_Bool bCheck; #ifdef _SVX_TABSTPGE_CXX - void InitTabPos_Impl( USHORT nPos = 0 ); + void InitTabPos_Impl( sal_uInt16 nPos = 0 ); void SetFillAndTabType_Impl(); // Handler diff --git a/cui/source/inc/textanim.hxx b/cui/source/inc/textanim.hxx index b713c232aee5..92bb1b32d749 100644 --- a/cui/source/inc/textanim.hxx +++ b/cui/source/inc/textanim.hxx @@ -86,7 +86,7 @@ private: DECL_LINK( ClickDirectionHdl_Impl, ImageButton * ); void SelectDirection( SdrTextAniDirection nValue ); - USHORT GetSelectedDirection(); + sal_uInt16 GetSelectedDirection(); #endif public: @@ -95,9 +95,9 @@ public: ~SvxTextAnimationPage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); void Construct(); @@ -114,7 +114,7 @@ private: const SfxItemSet& rOutAttrs; const SdrView* pView; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); public: diff --git a/cui/source/inc/textattr.hxx b/cui/source/inc/textattr.hxx index 258477dc5a5e..acecce5c3ed5 100644 --- a/cui/source/inc/textattr.hxx +++ b/cui/source/inc/textattr.hxx @@ -76,12 +76,12 @@ private: const SfxItemSet& rOutAttrs; const SdrView* pView; - BOOL bAutoGrowSizeEnabled; - BOOL bContourEnabled; - BOOL bAutoGrowWidthEnabled; - BOOL bAutoGrowHeightEnabled; - BOOL bWordWrapTextEnabled; - BOOL bFitToSizeEnabled; + sal_Bool bAutoGrowSizeEnabled; + sal_Bool bContourEnabled; + sal_Bool bAutoGrowWidthEnabled; + sal_Bool bAutoGrowHeightEnabled; + sal_Bool bWordWrapTextEnabled; + sal_Bool bFitToSizeEnabled; #ifdef _SVX_TEXTATTR_CXX @@ -89,8 +89,8 @@ private: DECL_LINK( ClickHdl_Impl, void * ); #endif - /** Return whether the text direction is from left to right (</TRUE>) or - top to bottom (</FALSE>). + /** Return whether the text direction is from left to right (</sal_True>) or + top to bottom (</sal_False>). */ bool IsTextDirectionLeftToRight (void) const; @@ -99,9 +99,9 @@ public: ~SvxTextAttrPage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void PointChanged( Window* pWindow, RECT_POINT eRP ); diff --git a/cui/source/inc/transfrm.hxx b/cui/source/inc/transfrm.hxx index acb77178de36..4563e013703a 100644 --- a/cui/source/inc/transfrm.hxx +++ b/cui/source/inc/transfrm.hxx @@ -48,27 +48,27 @@ class SdrView; /** put this into the nAnchorTypes parameter of the SvxTransformTabDialog c'tor to disable the size controls */ -const USHORT SVX_OBJ_NORESIZE = 0x0100; +const sal_uInt16 SVX_OBJ_NORESIZE = 0x0100; /** put this into the nAnchorTypes parameter of the SvxTransformTabDialog c'tor to disable the protect controls */ -const USHORT SVX_OBJ_NOPROTECT = 0x0200; +const sal_uInt16 SVX_OBJ_NOPROTECT = 0x0200; class SvxTransformTabDialog : public SfxTabDialog { private: const SdrView* pView; - USHORT nAnchorCtrls; + sal_uInt16 nAnchorCtrls; Link aValidateLink; - virtual void PageCreated( USHORT nId, SfxTabPage &rPage ); + virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage ); public: SvxTransformTabDialog( Window* pParent, const SfxItemSet* pAttr, const SdrView* pView, - USHORT nAnchorTypes = 0); + sal_uInt16 nAnchorTypes = 0); ~SvxTransformTabDialog(); //link for the Writer to validate positions @@ -168,9 +168,9 @@ public: SvxPositionSizeTabPage( Window* pParent, const SfxItemSet& rInAttrs ); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -232,9 +232,9 @@ public: SvxAngleTabPage( Window* pParent, const SfxItemSet& rInAttrs ); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); @@ -279,9 +279,9 @@ public: SvxSlantTabPage( Window* pParent, const SfxItemSet& rInAttrs ); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual void ActivatePage( const SfxItemSet& rSet ); diff --git a/cui/source/inc/treeopt.hxx b/cui/source/inc/treeopt.hxx index bcd2904449ad..fcf2e8b34944 100644 --- a/cui/source/inc/treeopt.hxx +++ b/cui/source/inc/treeopt.hxx @@ -39,7 +39,7 @@ // static ---------------------------------------------------------------- -BOOL EnableSSO(); +sal_Bool EnableSSO(); CreateTabPage GetSSOCreator( void ); // class OfaOptionsTreeListBox ------------------------------------------- @@ -53,14 +53,14 @@ class OfaOptionsTreeListBox : public SvTreeListBox using SvListView::Collapse; private: - BOOL bInCollapse; + sal_Bool bInCollapse; public: OfaOptionsTreeListBox(Window* pParent, const ResId& rResId) : - SvTreeListBox( pParent, rResId ), bInCollapse(FALSE) {} + SvTreeListBox( pParent, rResId ), bInCollapse(sal_False) {} - virtual BOOL Collapse( SvLBoxEntry* pParent ); - BOOL IsInCollapse()const {return bInCollapse;} + virtual sal_Bool Collapse( SvLBoxEntry* pParent ); + sal_Bool IsInCollapse()const {return bInCollapse;} }; // struct OrderedEntry --------------------------------------------------- @@ -154,7 +154,7 @@ typedef ::std::vector< OptionsNode* > VectorOfNodes; struct LastPageSaver { - USHORT m_nLastPageId; + sal_uInt16 m_nLastPageId; rtl::OUString m_sLastPageURL_Tools; rtl::OUString m_sLastPageURL_ExtMgr; @@ -201,14 +201,14 @@ private: // for the ColorTabPage SfxItemSet* pColorPageItemSet; XColorTable* pColorTab; - USHORT nChangeType; - USHORT nUnknownType; - USHORT nUnknownPos; - BOOL bIsAreaTP; - - BOOL bForgetSelection; - BOOL bExternBrowserActive; - BOOL bImageResized; + sal_uInt16 nChangeType; + sal_uInt16 nUnknownType; + sal_uInt16 nUnknownPos; + sal_Bool bIsAreaTP; + + sal_Bool bForgetSelection; + sal_Bool bExternBrowserActive; + sal_Bool bImageResized; bool bInSelectHdl_Impl; bool bIsFromExtensionManager; @@ -222,8 +222,8 @@ private: static LastPageSaver* pLastPageSaver; - SfxItemSet* CreateItemSet( USHORT nId ); - void ApplyItemSet( USHORT nId, const SfxItemSet& rSet ); + SfxItemSet* CreateItemSet( sal_uInt16 nId ); + void ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet ); void InitTreeAndHandler(); void Initialize( const com::sun::star::uno::Reference< com::sun::star::frame::XFrame >& _xFrame ); void ResizeTreeLB( void ); // resizes dialog so that treelistbox has no horizontal scroll bar @@ -262,16 +262,16 @@ public: OfaTreeOptionsDialog( Window* pParent, const rtl::OUString& rExtensionId ); ~OfaTreeOptionsDialog(); - OptionsPageInfo* AddTabPage( USHORT nId, const String& rPageName, USHORT nGroup ); - USHORT AddGroup( const String& rGroupName, SfxShell* pCreateShell, - SfxModule* pCreateModule, USHORT nDialogId ); + OptionsPageInfo* AddTabPage( sal_uInt16 nId, const String& rPageName, sal_uInt16 nGroup ); + sal_uInt16 AddGroup( const String& rGroupName, SfxShell* pCreateShell, + SfxModule* pCreateModule, sal_uInt16 nDialogId ); void ActivateLastSelection(); - void ActivatePage( USHORT nResId ); + void ActivatePage( sal_uInt16 nResId ); void ActivatePage( const String& rPageURL ); void ApplyItemSets(); - USHORT GetColorChanged() const { return nChangeType; } + sal_uInt16 GetColorChanged() const { return nChangeType; } XColorTable* GetColorTable() { return pColorTab; } // helper functions to call the language settings TabPage from the SpellDialog @@ -335,12 +335,6 @@ private: public: ExtensionsTabPage( - Window* pParent, const ResId&, - const rtl::OUString& rPageURL, const rtl::OUString& rEvtHdl, - const com::sun::star::uno::Reference< - com::sun::star::awt::XContainerWindowProvider >& rProvider ); - - ExtensionsTabPage( Window* pParent, WinBits nStyle, const rtl::OUString& rPageURL, const rtl::OUString& rEvtHdl, const com::sun::star::uno::Reference< @@ -353,7 +347,6 @@ public: void ResetPage(); void SavePage(); - void HideWindow(); }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/inc/zoom.hxx b/cui/source/inc/zoom.hxx index 87fbb8a2f74d..c25f888f78b1 100644 --- a/cui/source/inc/zoom.hxx +++ b/cui/source/inc/zoom.hxx @@ -63,7 +63,7 @@ private: const SfxItemSet& rSet; SfxItemSet* pOutSet; - BOOL bModified; + sal_Bool bModified; #ifdef _SVX_ZOOM_CXX DECL_LINK( UserHdl, RadioButton* ); @@ -78,16 +78,13 @@ public: SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet ); ~SvxZoomDialog(); - static USHORT* GetRanges(); const SfxItemSet* GetOutputItemSet() const { return pOutSet; } - USHORT GetFactor() const; - void SetFactor( USHORT nNewFactor, USHORT nBtnId = 0 ); + sal_uInt16 GetFactor() const; + void SetFactor( sal_uInt16 nNewFactor, sal_uInt16 nBtnId = 0 ); - void SetButtonText( USHORT nBtnId, const String& aNewTxt ); - void HideButton( USHORT nBtnId ); - void SetLimits( USHORT nMin, USHORT nMax ); - void SetSpinSize( USHORT nNewSpin ); + void HideButton( sal_uInt16 nBtnId ); + void SetLimits( sal_uInt16 nMin, sal_uInt16 nMax ); }; #include <layout/layout-post.hxx> diff --git a/cui/source/options/cfgchart.cxx b/cui/source/options/cfgchart.cxx index 4d2cd38a60d7..4b449a0a16e7 100644 --- a/cui/source/options/cfgchart.cxx +++ b/cui/source/options/cfgchart.cxx @@ -161,7 +161,7 @@ bool SvxChartColorTable::operator==( const SvxChartColorTable & _rOther ) const SvxChartOptions::SvxChartOptions() : ::utl::ConfigItem( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Chart") ) ), - mbIsInitialized( FALSE ) + mbIsInitialized( sal_False ) { maPropertyNames.realloc( 1 ); maPropertyNames[ 0 ] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DefaultColor/Series") ); @@ -184,7 +184,7 @@ void SvxChartOptions::SetDefaultColors( const SvxChartColorTable& aCol ) SetModified(); } -BOOL SvxChartOptions::RetrieveOptions() +sal_Bool SvxChartOptions::RetrieveOptions() { // get sequence containing all properties @@ -225,9 +225,9 @@ BOOL SvxChartOptions::RetrieveOptions() maDefColors.append( XColorEntry( aCol, aName )); } - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } void SvxChartOptions::Commit() @@ -261,7 +261,7 @@ void SvxChartOptions::Notify( const com::sun::star::uno::Sequence< rtl::OUString // class SvxChartColorTableItem // -------------------- -SvxChartColorTableItem::SvxChartColorTableItem( USHORT nWhich_, const SvxChartColorTable& aTable ) : +SvxChartColorTableItem::SvxChartColorTableItem( sal_uInt16 nWhich_, const SvxChartColorTable& aTable ) : SfxPoolItem( nWhich_ ), m_aColorTable( aTable ) { diff --git a/cui/source/options/cfgchart.hxx b/cui/source/options/cfgchart.hxx index 6e9eaf40fa4d..2f348c632e1d 100644 --- a/cui/source/options/cfgchart.hxx +++ b/cui/source/options/cfgchart.hxx @@ -71,14 +71,14 @@ class SvxChartOptions : public ::utl::ConfigItem { private: SvxChartColorTable maDefColors; - BOOL mbIsInitialized; + sal_Bool mbIsInitialized; ::com::sun::star::uno::Sequence< ::rtl::OUString > maPropertyNames; inline ::com::sun::star::uno::Sequence< ::rtl::OUString > GetPropertyNames() const { return maPropertyNames; } - BOOL RetrieveOptions(); + sal_Bool RetrieveOptions(); public: SvxChartOptions(); @@ -98,7 +98,7 @@ class SvxChartColorTableItem : public SfxPoolItem { public: TYPEINFO(); - SvxChartColorTableItem( USHORT nWhich, const SvxChartColorTable& ); + SvxChartColorTableItem( sal_uInt16 nWhich, const SvxChartColorTable& ); SvxChartColorTableItem( const SvxChartColorTableItem& ); virtual SfxPoolItem* Clone( SfxItemPool *pPool = 0 ) const; diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx index fc29f3a71a72..988d8574c75a 100644 --- a/cui/source/options/connpooloptions.cxx +++ b/cui/source/options/connpooloptions.cxx @@ -63,7 +63,7 @@ namespace offapp virtual void Init(); void Update(const DriverPoolingSettings& _rSettings); - virtual String GetCellText( long nRow, USHORT nColId ) const; + virtual String GetCellText( long nRow, sal_uInt16 nColId ) const; // the handler will be called with a DriverPoolingSettings::const_iterator as parameter, // or NULL if no valid current row exists @@ -80,13 +80,13 @@ namespace offapp sal_Bool isModified() const; protected: - virtual void InitController( ::svt::CellControllerRef& rController, long nRow, USHORT nCol ); - virtual ::svt::CellController* GetController( long nRow, USHORT nCol ); + virtual void InitController( ::svt::CellControllerRef& rController, long nRow, sal_uInt16 nCol ); + virtual ::svt::CellController* GetController( long nRow, sal_uInt16 nCol ); - virtual void PaintCell( OutputDevice& rDev, const Rectangle& rRect, USHORT nColId ) const; + virtual void PaintCell( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColId ) const; - virtual BOOL SeekRow( long nRow ); - virtual BOOL SaveModified(); + virtual sal_Bool SeekRow( long nRow ); + virtual sal_Bool SaveModified(); virtual sal_Bool IsTabAllowed(sal_Bool _bForward) const; @@ -95,7 +95,7 @@ namespace offapp virtual void CursorMoved(); protected: - virtual sal_uInt32 GetTotalCellWidth(long nRow, USHORT nColId); + virtual sal_uInt32 GetTotalCellWidth(long nRow, sal_uInt16 nColId); private: @@ -213,7 +213,7 @@ namespace offapp } //-------------------------------------------------------------------- - sal_uInt32 DriverListControl::GetTotalCellWidth(long nRow, USHORT nColId) + sal_uInt32 DriverListControl::GetTotalCellWidth(long nRow, sal_uInt16 nColId) { return GetDataWindow().GetTextWidth(GetCellText(nRow, nColId)); } @@ -251,7 +251,7 @@ namespace offapp } //-------------------------------------------------------------------- - String DriverListControl::GetCellText( long nRow, USHORT nColId ) const + String DriverListControl::GetCellText( long nRow, sal_uInt16 nColId ) const { String sReturn; if (nRow > m_aSettings.size()) @@ -266,25 +266,25 @@ namespace offapp } //-------------------------------------------------------------------- - void DriverListControl::InitController( ::svt::CellControllerRef& rController, long nRow, USHORT nCol ) + void DriverListControl::InitController( ::svt::CellControllerRef& rController, long nRow, sal_uInt16 nCol ) { rController->GetWindow().SetText(GetCellText(nRow, nCol)); } //-------------------------------------------------------------------- - ::svt::CellController* DriverListControl::GetController( long /*nRow*/, USHORT /*nCol*/ ) + ::svt::CellController* DriverListControl::GetController( long /*nRow*/, sal_uInt16 /*nCol*/ ) { return NULL; } //-------------------------------------------------------------------- - BOOL DriverListControl::SaveModified() + sal_Bool DriverListControl::SaveModified() { - return TRUE; + return sal_True; } //-------------------------------------------------------------------- - BOOL DriverListControl::SeekRow( long _nRow ) + sal_Bool DriverListControl::SeekRow( long _nRow ) { DriverListControl_Base::SeekRow(_nRow); @@ -297,7 +297,7 @@ namespace offapp } //-------------------------------------------------------------------- - void DriverListControl::PaintCell( OutputDevice& rDev, const Rectangle& rRect, USHORT nColId ) const + void DriverListControl::PaintCell( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColId ) const { OSL_ENSURE(m_aSeekRow != m_aSettings.end(), "DriverListControl::PaintCell: invalid row!"); @@ -396,7 +396,7 @@ namespace offapp } //-------------------------------------------------------------------- - BOOL ConnectionPoolOptionsPage::FillItemSet(SfxItemSet& _rSet) + sal_Bool ConnectionPoolOptionsPage::FillItemSet(SfxItemSet& _rSet) { commitTimeoutField(); diff --git a/cui/source/options/connpooloptions.hxx b/cui/source/options/connpooloptions.hxx index 9b4e58255575..da749ca5df93 100644 --- a/cui/source/options/connpooloptions.hxx +++ b/cui/source/options/connpooloptions.hxx @@ -71,7 +71,7 @@ namespace offapp protected: virtual long Notify( NotifyEvent& _rNEvt ); - virtual BOOL FillItemSet(SfxItemSet& _rSet); + virtual sal_Bool FillItemSet(SfxItemSet& _rSet); virtual void Reset(const SfxItemSet& _rSet); virtual void ActivatePage( const SfxItemSet& _rSet); diff --git a/cui/source/options/connpooloptions.src b/cui/source/options/connpooloptions.src index 08e4f2043a40..89b45595b37a 100644 --- a/cui/source/options/connpooloptions.src +++ b/cui/source/options/connpooloptions.src @@ -35,7 +35,7 @@ TabPage RID_OFAPAGE_CONNPOOLOPTIONS { - // HelpId = ; + HelpID = "cui:TabPage:RID_OFAPAGE_CONNPOOLOPTIONS"; OutputSize = TRUE ; Size = MAP_APPFONT ( PAGE_SIZE_X, PAGE_SIZE_Y ) ; SVLook = TRUE ; @@ -49,6 +49,7 @@ TabPage RID_OFAPAGE_CONNPOOLOPTIONS }; CheckBox CB_POOL_CONNS { + HelpID = "cui:CheckBox:RID_OFAPAGE_CONNPOOLOPTIONS:CB_POOL_CONNS"; Pos = MAP_APPFONT( 7, 15 ); Size = MAP_APPFONT( PAGE_SIZE_X - 14, 10 ); Text [ en-US ] = "Connection pooling enabled"; @@ -80,6 +81,7 @@ TabPage RID_OFAPAGE_CONNPOOLOPTIONS }; CheckBox CB_DRIVERPOOLING { + HelpID = "cui:CheckBox:RID_OFAPAGE_CONNPOOLOPTIONS:CB_DRIVERPOOLING"; Pos = MAP_APPFONT( 17, 39 + LIST_SIZE_Y + 4 + 8 + 3 ); Size = MAP_APPFONT( PAGE_SIZE_X - 23, 10 ); Text [ en-US ] = "Enable pooling for this driver"; @@ -92,6 +94,7 @@ TabPage RID_OFAPAGE_CONNPOOLOPTIONS }; NumericField NF_TIMEOUT { + HelpID = "cui:NumericField:RID_OFAPAGE_CONNPOOLOPTIONS:NF_TIMEOUT"; Pos = MAP_APPFONT( 27 + 100 + 3, 39 + LIST_SIZE_Y + 4 + 8 + 3 + 10 + 3 ); Size = MAP_APPFONT( 40, 12 ); SvLook = TRUE; diff --git a/cui/source/options/connpoolsettings.cxx b/cui/source/options/connpoolsettings.cxx index a292401bad86..e8ed445374d1 100644 --- a/cui/source/options/connpoolsettings.cxx +++ b/cui/source/options/connpoolsettings.cxx @@ -37,13 +37,6 @@ namespace offapp //= DriverPooling //==================================================================== //-------------------------------------------------------------------- - DriverPooling::DriverPooling() - :bEnabled(sal_False) - ,nTimeoutSeconds(0) - { - } - - //-------------------------------------------------------------------- DriverPooling::DriverPooling( const String& _rName, sal_Bool _bEnabled, const sal_Int32 _nTimeout ) :sName(_rName) ,bEnabled(_bEnabled) diff --git a/cui/source/options/connpoolsettings.hxx b/cui/source/options/connpoolsettings.hxx index 1f53d207f2ab..f39eca8cae24 100644 --- a/cui/source/options/connpoolsettings.hxx +++ b/cui/source/options/connpoolsettings.hxx @@ -47,7 +47,6 @@ namespace offapp sal_Bool bEnabled; sal_Int32 nTimeoutSeconds; - DriverPooling(); DriverPooling( const String& _rName, sal_Bool _bEnabled, const sal_Int32 _nTimeout ); sal_Bool operator == (const DriverPooling& _rR) const; diff --git a/cui/source/options/cuisrchdlg.cxx b/cui/source/options/cuisrchdlg.cxx index 6d7f63b96093..c1f73e4a9e5e 100644 --- a/cui/source/options/cuisrchdlg.cxx +++ b/cui/source/options/cuisrchdlg.cxx @@ -62,14 +62,14 @@ SvxJSearchOptionsDialog::SvxJSearchOptionsDialog( Window *pParent, - const SfxItemSet& rOptionsSet, INT32 nInitialFlags ) : + const SfxItemSet& rOptionsSet, sal_Int32 nInitialFlags ) : SfxSingleTabDialog ( pParent, rOptionsSet, RID_SVXPAGE_JSEARCH_OPTIONS ), nInitialTlFlags( nInitialFlags ) { pPage = (SvxJSearchOptionsPage *) SvxJSearchOptionsPage::Create( this, rOptionsSet ); SetTabPage( pPage ); //! implicitly calls pPage->Reset(...)! - pPage->EnableSaveOptions( FALSE ); + pPage->EnableSaveOptions( sal_False ); } @@ -86,15 +86,10 @@ void SvxJSearchOptionsDialog::Activate() } -INT32 SvxJSearchOptionsDialog::GetTransliterationFlags() const +sal_Int32 SvxJSearchOptionsDialog::GetTransliterationFlags() const { return pPage->GetTransliterationFlags(); } -void SvxJSearchOptionsDialog::SetTransliterationFlags( INT32 nSettings ) -{ - pPage->SetTransliterationFlags( nSettings ); -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
\ No newline at end of file diff --git a/cui/source/options/dbregister.cxx b/cui/source/options/dbregister.cxx index a5ae42598841..8c8562527c51 100644 --- a/cui/source/options/dbregister.cxx +++ b/cui/source/options/dbregister.cxx @@ -126,7 +126,7 @@ DbRegistrationOptionsPage::DbRegistrationOptionsPage( Window* pParent, const Sfx pPathBox ( NULL ), m_pCurEntry ( NULL ), m_nOldCount ( 0 ), - m_bModified ( FALSE ) + m_bModified ( sal_False ) { m_aNew.SetClickHdl( LINK( this, DbRegistrationOptionsPage, NewHdl ) ); m_aEdit.SetClickHdl( LINK( this, DbRegistrationOptionsPage, EditHdl ) ); @@ -156,7 +156,7 @@ DbRegistrationOptionsPage::DbRegistrationOptionsPage( Window* pParent, const Sfx Size aHeadSize = pHeaderBar->GetSizePixel(); aPathCtrl.SetFocusControl( pPathBox ); - pPathBox->SetWindowBits( nBits ); + pPathBox->SetStyle( pPathBox->GetStyle()|nBits ); pPathBox->SetDoubleClickHdl( LINK( this, DbRegistrationOptionsPage, EditHdl ) ); pPathBox->SetSelectHdl( LINK( this, DbRegistrationOptionsPage, PathSelect_Impl ) ); pPathBox->SetSelectionMode( SINGLE_SELECTION ); @@ -183,7 +183,7 @@ DbRegistrationOptionsPage::~DbRegistrationOptionsPage() aPathCtrl.SetFocusControl( NULL ); pHeaderBar->Hide(); - for ( USHORT i = 0; i < pPathBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < pPathBox->GetEntryCount(); ++i ) delete static_cast< DatabaseRegistration* >( pPathBox->GetEntry(i)->GetUserData() ); delete pPathBox; delete pHeaderBar; @@ -199,13 +199,13 @@ SfxTabPage* DbRegistrationOptionsPage::Create( Window* pParent, // ----------------------------------------------------------------------- -BOOL DbRegistrationOptionsPage::FillItemSet( SfxItemSet& rCoreSet ) +sal_Bool DbRegistrationOptionsPage::FillItemSet( SfxItemSet& rCoreSet ) { // the settings for the single drivers sal_Bool bModified = sal_False; DatabaseRegistrations aRegistrations; - ULONG nCount = pPathBox->GetEntryCount(); - for ( ULONG i = 0; i < nCount; ++i ) + sal_uLong nCount = pPathBox->GetEntryCount(); + for ( sal_uLong i = 0; i < nCount; ++i ) { SvLBoxEntry* pEntry = pPathBox->GetEntry(i); DatabaseRegistration* pRegistration = static_cast< DatabaseRegistration* >( pEntry->GetUserData() ); @@ -253,7 +253,7 @@ void DbRegistrationOptionsPage::Reset( const SfxItemSet& rSet ) pHeaderBar->SetItemSize( ITEMID_TYPE, aUserData.GetToken(0).ToInt32() ); HeaderEndDrag_Impl( NULL ); // Sortierrichtung restaurieren - BOOL bUp = (BOOL)(USHORT)aUserData.GetToken(1).ToInt32(); + sal_Bool bUp = (sal_Bool)(sal_uInt16)aUserData.GetToken(1).ToInt32(); HeaderBarItemBits nBits = pHeaderBar->GetItemBits(ITEMID_TYPE); if ( bUp ) @@ -278,7 +278,7 @@ void DbRegistrationOptionsPage::FillUserData() String aUserData = String::CreateFromInt32( pHeaderBar->GetItemSize( ITEMID_TYPE ) ); aUserData += ';'; HeaderBarItemBits nBits = pHeaderBar->GetItemBits( ITEMID_TYPE ); - BOOL bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); + sal_Bool bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); aUserData += bUp ? '1' : '0'; SetUserData( aUserData ); } @@ -331,7 +331,7 @@ IMPL_LINK( DbRegistrationOptionsPage, HeaderSelect_Impl, HeaderBar*, pBar ) return 0; HeaderBarItemBits nBits = pHeaderBar->GetItemBits(ITEMID_TYPE); - BOOL bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); + sal_Bool bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); SvSortMode eMode = SortAscending; if ( bUp ) @@ -362,7 +362,7 @@ IMPL_LINK( DbRegistrationOptionsPage, HeaderEndDrag_Impl, HeaderBar*, pBar ) if ( !pHeaderBar->IsItemMode() ) { Size aSz; - USHORT nTabs = pHeaderBar->GetItemCount(); + sal_uInt16 nTabs = pHeaderBar->GetItemCount(); long nTmpSz = 0; long nWidth = pHeaderBar->GetItemSize(ITEMID_TYPE); long nBarWidth = pHeaderBar->GetSizePixel().Width(); @@ -372,7 +372,7 @@ IMPL_LINK( DbRegistrationOptionsPage, HeaderEndDrag_Impl, HeaderBar*, pBar ) else if ( ( nBarWidth - nWidth ) < TAB_WIDTH_MIN ) pHeaderBar->SetItemSize( ITEMID_TYPE, nBarWidth - TAB_WIDTH_MIN ); - for ( USHORT i = 1; i <= nTabs; ++i ) + for ( sal_uInt16 i = 1; i <= nTabs; ++i ) { long _nWidth = pHeaderBar->GetItemSize(i); aSz.Width() = _nWidth + nTmpSz; @@ -421,60 +421,6 @@ void DbRegistrationOptionsPage::insertNewEntry( const ::rtl::OUString& _sName,co } // ----------------------------------------------------------------------------- -String DbRegistrationOptionsPage::getFileLocation(const String& _sLocation) -{ - try - { - rtl::OUString aService( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.ui.dialogs.FilePicker" ) ); - Reference < XMultiServiceFactory > xFactory( ::comphelper::getProcessServiceFactory() ); - Reference < XFilePicker > xFilePicker( xFactory->createInstance( aService ), UNO_QUERY ); - OSL_ENSURE(xFilePicker.is() ,"Could create file picker service!"); - Reference < XFilterManager> xFilterManager(xFilePicker,UNO_QUERY); - static const String s_sDatabaseType = String::CreateFromAscii("StarOffice XML (Base)"); - const SfxFilter* pFilter = SfxFilter::GetFilterByName( s_sDatabaseType); - if ( pFilter ) - { - xFilterManager->appendFilter( pFilter->GetUIName(),pFilter->GetDefaultExtension()); - xFilterManager->setCurrentFilter(pFilter->GetUIName()); - } - - INetURLObject aURL( _sLocation, INET_PROT_FILE ); - xFilePicker->setMultiSelectionMode(sal_False); - xFilePicker->setDisplayDirectory( aURL.GetMainURL( INetURLObject::NO_DECODE ) ); - short nRet = xFilePicker->execute(); - - if ( ExecutableDialogResults::OK == nRet ) - { - - // old path is an URL? - INetURLObject aObj( _sLocation ); - bool bURL = ( aObj.GetProtocol() != INET_PROT_NOT_VALID ); - Sequence< ::rtl::OUString > aFiles = xFilePicker->getFiles(); - INetURLObject aNewObj( aFiles[0] ); - aNewObj.removeFinalSlash(); - - // then the new path also an URL else system path - String sNewLocation = bURL ? rtl::OUString(aFiles[0]) : aNewObj.getFSysPath( INetURLObject::FSYS_DETECT ); - - if ( -#ifdef UNX - // Unix is case sensitive - ( sNewLocation != _sLocation ) -#else - ( sNewLocation.CompareIgnoreCaseToAscii( _sLocation ) != COMPARE_EQUAL ) -#endif - ) - return sNewLocation; - } - } - catch( Exception& ) - { - DBG_ERRORFILE( "DbRegistrationOptionsPage::EditLocationHdl: exception from folder picker" ); - } - - return String(); -} -// ----------------------------------------------------------------------------- void DbRegistrationOptionsPage::openLinkDialog(const String& _sOldName,const String& _sOldLocation,SvLBoxEntry* _pEntry) { ODocumentLinkDialog aDlg(this,_pEntry == NULL); @@ -503,8 +449,8 @@ IMPL_LINK( DbRegistrationOptionsPage, NameValidator, String*, _pName ) { if ( _pName ) { - ULONG nCount = pPathBox->GetEntryCount(); - for ( ULONG i = 0; i < nCount; ++i ) + sal_uLong nCount = pPathBox->GetEntryCount(); + for ( sal_uLong i = 0; i < nCount; ++i ) { SvLBoxEntry* pEntry = pPathBox->GetEntry(i); if ( (!m_pCurEntry || m_pCurEntry != pEntry) && pPathBox->GetEntryText(pEntry,0) == *_pName ) diff --git a/cui/source/options/dbregister.src b/cui/source/options/dbregister.src index 6b2fb2fa5a33..e2ad56ceedd0 100644 --- a/cui/source/options/dbregister.src +++ b/cui/source/options/dbregister.src @@ -34,6 +34,7 @@ #define STD_MASKCOLOR Color { Red=0xffff; Green=0x0000; Blue=0xffff; } TabPage RID_SFXPAGE_DBREGISTER { + HelpId = "cui:TabPage:RID_SFXPAGE_DBREGISTER" ; OutputSize = TRUE ; SVLook = TRUE ; Hide = TRUE ; @@ -63,18 +64,21 @@ TabPage RID_SFXPAGE_DBREGISTER }; PushButton BTN_NEW { + HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_NEW"; Pos = MAP_APPFONT ( 47 , 165 ) ; Size = MAP_APPFONT ( 65 , 14 ) ; Text [ en-US ] = "~New..." ; }; PushButton BTN_EDIT { + HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_EDIT"; Pos = MAP_APPFONT ( 183 , 165 ) ; Size = MAP_APPFONT ( 65 , 14 ) ; Text [ en-US ] = "~Edit..." ; }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_DELETE"; Pos = MAP_APPFONT ( 115 , 165 ) ; Size = MAP_APPFONT ( 65 , 14 ) ; Text [ en-US ] = "~Delete" ; diff --git a/cui/source/options/doclinkdialog.src b/cui/source/options/doclinkdialog.src index f61f23092f37..f421afc56fe0 100644 --- a/cui/source/options/doclinkdialog.src +++ b/cui/source/options/doclinkdialog.src @@ -46,6 +46,7 @@ ModalDialog DLG_DOCUMENTLINK { + HelpID = "cui:ModalDialog:DLG_DOCUMENTLINK"; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( DIALOG_SIZE_X , DIALOG_SIZE_Y ) ; @@ -64,6 +65,7 @@ ModalDialog DLG_DOCUMENTLINK }; ComboBox CMB_URL { + HelpID = "cui:ComboBox:DLG_DOCUMENTLINK:CMB_URL"; Pos = MAP_APPFONT ( 6 , LINE_1_Y + OFFSET_Y + HEIGHT_LABEL - 3) ; Size = MAP_APPFONT ( DIALOG_SIZE_X - 3*LINE_1_Y - BUTTON_SIZE_X , HEIGHT_EDIT ) ; @@ -75,6 +77,7 @@ ModalDialog DLG_DOCUMENTLINK }; PushButton PB_BROWSEFILE { + HelpID = "cui:PushButton:DLG_DOCUMENTLINK:PB_BROWSEFILE"; Pos = MAP_APPFONT ( DIALOG_SIZE_X - BUTTON_SIZE_X - 6 , LINE_1_Y + OFFSET_Y + HEIGHT_LABEL - 4) ; Size = MAP_APPFONT ( BUTTON_SIZE_X, BUTTON_SIZE_Y ); Text [ en-US ] = "~Browse..."; @@ -90,6 +93,7 @@ ModalDialog DLG_DOCUMENTLINK }; Edit ET_NAME { + HelpID = "cui:Edit:DLG_DOCUMENTLINK:ET_NAME"; Pos = MAP_APPFONT ( 6, LINE_1_Y + 3*OFFSET_Y + 2*HEIGHT_LABEL + BUTTON_SIZE_Y - 6) ; Size = MAP_APPFONT ( DIALOG_SIZE_X - 3*LINE_1_Y - BUTTON_SIZE_X , HEIGHT_EDIT ) ; TabStop = TRUE ; diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx index 418f8c6009b9..87a150288035 100644 --- a/cui/source/options/fontsubs.cxx +++ b/cui/source/options/fontsubs.cxx @@ -84,7 +84,7 @@ SvxFontSubstTabPage::SvxFontSubstTabPage( Window* pParent, aTextColor = aCheckLB.GetTextColor(); - for(USHORT k = 0; k < aNewDelTBX.GetItemCount(); k++) + for(sal_uInt16 k = 0; k < aNewDelTBX.GetItemCount(); k++) aNewDelTBX.SetItemImage(aNewDelTBX.GetItemId(k), aImageList.GetImage(aNewDelTBX.GetItemId(k))); @@ -97,7 +97,7 @@ SvxFontSubstTabPage::SvxFontSubstTabPage( Window* pParent, aNewDelTBX.SetPosPixel( aNewPnt ); aCheckLB.SetHelpId(HID_OFA_FONT_SUBST_CLB); - aCheckLB.SetWindowBits(aCheckLB.GetStyle()|WB_HSCROLL|WB_VSCROLL); + aCheckLB.SetStyle(aCheckLB.GetStyle()|WB_HSCROLL|WB_VSCROLL); aCheckLB.SetSelectionMode(MULTIPLE_SELECTION); aCheckLB.SortByCol(2); @@ -144,7 +144,7 @@ SvxFontSubstTabPage::SvxFontSubstTabPage( Window* pParent, pBar->SetItemBits(1, nBits); pBar->SetItemBits(2, nBits); - USHORT nHeight; + sal_uInt16 nHeight; for(nHeight = 6; nHeight <= 16; nHeight++) aFontHeightLB.InsertEntry(String::CreateFromInt32(nHeight)); for(nHeight = 18; nHeight <= 28; nHeight+= 2) @@ -209,7 +209,7 @@ SfxTabPage* SvxFontSubstTabPage::Create( Window* pParent, /* */ /*********************************************************************/ -BOOL SvxFontSubstTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxFontSubstTabPage::FillItemSet( SfxItemSet& ) { pConfig->ClearSubstitutions();// remove all entries @@ -240,7 +240,7 @@ BOOL SvxFontSubstTabPage::FillItemSet( SfxItemSet& ) sFontName = aFontNameLB.GetSelectEntry(); pSourceViewConfig->SetFontName(sFontName); - return FALSE; + return sal_False; } /*********************************************************************/ @@ -250,7 +250,7 @@ BOOL SvxFontSubstTabPage::FillItemSet( SfxItemSet& ) void SvxFontSubstTabPage::Reset( const SfxItemSet& ) { - aCheckLB.SetUpdateMode(FALSE); + aCheckLB.SetUpdateMode(sal_False); aCheckLB.Clear(); FontList aFntLst( Application::GetDefaultDevice() ); @@ -273,7 +273,7 @@ void SvxFontSubstTabPage::Reset( const SfxItemSet& ) } CheckEnable(); - aCheckLB.SetUpdateMode(TRUE); + aCheckLB.SetUpdateMode(sal_True); //fill font name box first aNonPropFontsOnlyCB.Check(pSourceViewConfig->IsShowProportionalFontsOnly()); @@ -300,7 +300,7 @@ IMPL_LINK(SvxFontSubstTabPage, SelectHdl, Window*, pWin) SvLBoxEntry* pEntry; // nCol ist behaemmerterweise die nCol'te Textspalte, werden nicht gezaehlt! // Daher als Spalte "0". - ULONG nPos = aCheckLB.GetEntryPos(aFont1CB.GetText(), 0); + sal_uLong nPos = aCheckLB.GetEntryPos(aFont1CB.GetText(), 0); switch (aNewDelTBX.GetCurItemId()) { @@ -321,7 +321,7 @@ IMPL_LINK(SvxFontSubstTabPage, SelectHdl, Window*, pWin) pEntry = CreateEntry(sFont1, sFont2); aCheckLB.Insert(pEntry); } - aCheckLB.SelectAll(FALSE); + aCheckLB.SelectAll(sal_False); aCheckLB.Select(pEntry); } break; @@ -356,7 +356,7 @@ IMPL_LINK(SvxFontSubstTabPage, SelectHdl, Window*, pWin) if (pWin == &aFont1CB) { - ULONG nPos = aCheckLB.GetEntryPos(aFont1CB.GetText(), 0); + sal_uLong nPos = aCheckLB.GetEntryPos(aFont1CB.GetText(), 0); if (nPos != 0xffffffff) { @@ -364,7 +364,7 @@ IMPL_LINK(SvxFontSubstTabPage, SelectHdl, Window*, pWin) if (pEntry != aCheckLB.FirstSelected()) { - aCheckLB.SelectAll(FALSE); + aCheckLB.SelectAll(sal_False); aCheckLB.Select(pEntry); } } @@ -379,12 +379,12 @@ IMPL_LINK(SvxFontSubstTabPage, SelectHdl, Window*, pWin) IMPL_LINK(SvxFontSubstTabPage, NonPropFontsHdl, CheckBox*, pBox) { String sFontName = aFontNameLB.GetSelectEntry(); - BOOL bNonPropOnly = pBox->IsChecked(); + sal_Bool bNonPropOnly = pBox->IsChecked(); aFontNameLB.Clear(); FontList aFntLst( Application::GetDefaultDevice() ); aFontNameLB.InsertEntry(sAutomatic); - USHORT nFontCount = aFntLst.GetFontNameCount(); - for(USHORT nFont = 0; nFont < nFontCount; nFont++) + sal_uInt16 nFontCount = aFntLst.GetFontNameCount(); + for(sal_uInt16 nFont = 0; nFont < nFontCount; nFont++) { const FontInfo& rInfo = aFntLst.GetFontName( nFont ); if(!bNonPropOnly || rInfo.GetPitch() == PITCH_FIXED) @@ -396,11 +396,11 @@ IMPL_LINK(SvxFontSubstTabPage, NonPropFontsHdl, CheckBox*, pBox) void SvxFontSubstTabPage::CheckEnable() { - BOOL bEnableAll = aUseTableCB.IsChecked(); + sal_Bool bEnableAll = aUseTableCB.IsChecked(); if (bEnableAll) { - BOOL bApply, bDelete; + sal_Bool bApply, bDelete; SvLBoxEntry* pEntry = aCheckLB.FirstSelected(); @@ -410,15 +410,15 @@ void SvxFontSubstTabPage::CheckEnable() // Wegen OS/2-Optimierungsfehler (Bug #56267) etwas umstaendlicher: if (!aFont1CB.GetText().Len() || !aFont2CB.GetText().Len()) - bApply = FALSE; + bApply = sal_False; else if(aFont1CB.GetText() == aFont2CB.GetText()) - bApply = FALSE; + bApply = sal_False; else if(aCheckLB.GetEntryPos(sEntry) != 0xffffffff) - bApply = FALSE; + bApply = sal_False; else if(pEntry != 0 && aCheckLB.NextSelected(pEntry) != 0) - bApply = FALSE; + bApply = sal_False; else - bApply = TRUE; + bApply = sal_True; bDelete = pEntry != 0; @@ -443,7 +443,7 @@ void SvxFontSubstTabPage::CheckEnable() aCheckLB.DisableTable(); aCheckLB.SetTextColor(Color(COL_GRAY)); aCheckLB.Invalidate(); - aCheckLB.SelectAll(FALSE); + aCheckLB.SelectAll(sal_False); } } aNewDelTBX.Enable(bEnableAll); @@ -456,7 +456,7 @@ void SvxFontSubstTabPage::CheckEnable() void SvxFontSubstCheckListBox::SetTabs() { SvxSimpleTable::SetTabs(); - USHORT nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; + sal_uInt16 nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; SvLBoxTab* pTab = (SvLBoxTab*)aTabs.GetObject(1); pTab->nFlags &= ~nAdjust; @@ -472,8 +472,8 @@ void SvxFontSubstCheckListBox::KeyInput( const KeyEvent& rKEvt ) if(!rKEvt.GetKeyCode().GetModifier() && KEY_SPACE == rKEvt.GetKeyCode().GetCode()) { - ULONG nSelPos = GetModel()->GetAbsPos(GetCurEntry()); - USHORT nCol = GetCurrentTabPos() - 1; + sal_uLong nSelPos = GetModel()->GetAbsPos(GetCurEntry()); + sal_uInt16 nCol = GetCurrentTabPos() - 1; if ( nCol < 2 ) { CheckEntryPos( nSelPos, nCol, !IsChecked( nSelPos, nCol ) ); @@ -481,7 +481,7 @@ void SvxFontSubstCheckListBox::KeyInput( const KeyEvent& rKEvt ) } else { - USHORT nCheck = IsChecked(nSelPos, 1) ? 1 : 0; + sal_uInt16 nCheck = IsChecked(nSelPos, 1) ? 1 : 0; if(IsChecked(nSelPos, 0)) nCheck += 2; nCheck--; @@ -494,7 +494,7 @@ void SvxFontSubstCheckListBox::KeyInput( const KeyEvent& rKEvt ) SvxSimpleTable::KeyInput(rKEvt); } -void SvxFontSubstCheckListBox::CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked) +void SvxFontSubstCheckListBox::CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked) { if ( nPos < GetEntryCount() ) SetCheckButtonState( @@ -504,7 +504,7 @@ void SvxFontSubstCheckListBox::CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChec SvButtonState( SV_BUTTON_UNCHECKED ) ); } -void SvxFontSubstCheckListBox::CheckEntry(SvLBoxEntry* pEntry, USHORT nCol, BOOL bChecked) +void SvxFontSubstCheckListBox::CheckEntry(SvLBoxEntry* pEntry, sal_uInt16 nCol, sal_Bool bChecked) { if ( pEntry ) SetCheckButtonState( @@ -514,17 +514,17 @@ void SvxFontSubstCheckListBox::CheckEntry(SvLBoxEntry* pEntry, USHORT nCol, BOOL SvButtonState( SV_BUTTON_UNCHECKED ) ); } -BOOL SvxFontSubstCheckListBox::IsChecked(ULONG nPos, USHORT nCol) +sal_Bool SvxFontSubstCheckListBox::IsChecked(sal_uLong nPos, sal_uInt16 nCol) { return GetCheckButtonState( GetEntry(nPos), nCol ) == SV_BUTTON_CHECKED; } -BOOL SvxFontSubstCheckListBox::IsChecked(SvLBoxEntry* pEntry, USHORT nCol) +sal_Bool SvxFontSubstCheckListBox::IsChecked(SvLBoxEntry* pEntry, sal_uInt16 nCol) { return GetCheckButtonState( pEntry, nCol ) == SV_BUTTON_CHECKED; } -void SvxFontSubstCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, USHORT nCol, SvButtonState eState) +void SvxFontSubstCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, sal_uInt16 nCol, SvButtonState eState) { SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -549,7 +549,7 @@ void SvxFontSubstCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, USHORT } } -SvButtonState SvxFontSubstCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry, USHORT nCol ) const +SvButtonState SvxFontSubstCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry, sal_uInt16 nCol ) const { SvButtonState eState = SV_BUTTON_UNCHECKED; SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -557,7 +557,7 @@ SvButtonState SvxFontSubstCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry if (((SvLBoxItem*)pItem)->IsA() == SV_ITEM_ID_LBOXBUTTON) { - USHORT nButtonFlags = pItem->GetButtonFlags(); + sal_uInt16 nButtonFlags = pItem->GetButtonFlags(); eState = pCheckButtonData->ConvertToButtonState( nButtonFlags ); } diff --git a/cui/source/options/fontsubs.hxx b/cui/source/options/fontsubs.hxx index 153ad24de1f5..bfd30c36d23e 100644 --- a/cui/source/options/fontsubs.hxx +++ b/cui/source/options/fontsubs.hxx @@ -56,15 +56,15 @@ class SvxFontSubstCheckListBox : public SvxSimpleTable SvxFontSubstCheckListBox(Window* pParent, const ResId& rResId ) : SvxSimpleTable( pParent, rResId ){} - inline void *GetUserData(ULONG nPos) { return GetEntry(nPos)->GetUserData(); } - inline void SetUserData(ULONG nPos, void *pData ) { GetEntry(nPos)->SetUserData(pData); } - - BOOL IsChecked(ULONG nPos, USHORT nCol = 0); - BOOL IsChecked(SvLBoxEntry* pEntry, USHORT nCol = 0); - void CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked); - void CheckEntry(SvLBoxEntry* pEntry, USHORT nCol, BOOL bChecked); - SvButtonState GetCheckButtonState( SvLBoxEntry*, USHORT nCol ) const; - void SetCheckButtonState( SvLBoxEntry*, USHORT nCol, SvButtonState ); + inline void *GetUserData(sal_uLong nPos) { return GetEntry(nPos)->GetUserData(); } + inline void SetUserData(sal_uLong nPos, void *pData ) { GetEntry(nPos)->SetUserData(pData); } + + sal_Bool IsChecked(sal_uLong nPos, sal_uInt16 nCol = 0); + sal_Bool IsChecked(SvLBoxEntry* pEntry, sal_uInt16 nCol = 0); + void CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked); + void CheckEntry(SvLBoxEntry* pEntry, sal_uInt16 nCol, sal_Bool bChecked); + SvButtonState GetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol ) const; + void SetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol, SvButtonState ); }; // class SvxFontSubstTabPage ---------------------------------------------------- @@ -115,7 +115,7 @@ class SvxFontSubstTabPage : public SfxTabPage public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/fontsubs.src b/cui/source/options/fontsubs.src index 20ceb4af6adc..c0fdfff13bab 100644 --- a/cui/source/options/fontsubs.src +++ b/cui/source/options/fontsubs.src @@ -45,6 +45,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION Size = MAP_APPFONT ( 260 , 185 ) ; CheckBox CB_USETABLE { + HelpID = "cui:CheckBox:RID_SVX_FONT_SUBSTITUTION:CB_USETABLE"; Pos = MAP_APPFONT ( 6 , 6 ) ; Size = MAP_APPFONT ( 248 , 10 ) ; TabStop = TRUE ; @@ -59,6 +60,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION }; ComboBox CB_FONT1 { + HelpID = "cui:ComboBox:RID_SVX_FONT_SUBSTITUTION:CB_FONT1"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 33 ) ; Size = MAP_APPFONT ( 100 , 100 ) ; @@ -78,6 +80,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION }; ComboBox CB_FONT2 { + HelpID = "cui:ComboBox:RID_SVX_FONT_SUBSTITUTION:CB_FONT2"; Border = TRUE ; Pos = MAP_APPFONT ( 110 , 33 ) ; Size = MAP_APPFONT ( 100 , 100 ) ; @@ -141,6 +144,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION }; ListBox LB_FONTNAME { + HelpID = "cui:ListBox:RID_SVX_FONT_SUBSTITUTION:LB_FONTNAME"; Pos = MAP_APPFONT ( 65 , 140 ) ; Size = MAP_APPFONT ( 100 , 68 ) ; Border = TRUE ; @@ -149,6 +153,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION }; CheckBox CB_NONPROP { + HelpID = "cui:CheckBox:RID_SVX_FONT_SUBSTITUTION:CB_NONPROP"; Pos = MAP_APPFONT ( 65 , 155 ) ; Size = MAP_APPFONT ( 180 , 10 ) ; TabStop = TRUE ; @@ -162,6 +167,7 @@ TabPage RID_SVX_FONT_SUBSTITUTION }; ListBox LB_FONTHEIGHT { + HelpID = "cui:ListBox:RID_SVX_FONT_SUBSTITUTION:LB_FONTHEIGHT"; Pos = MAP_APPFONT ( 65 , 169 ) ; Size = MAP_APPFONT ( 30 , 68 ) ; Border = TRUE ; diff --git a/cui/source/options/internationaloptions.cxx b/cui/source/options/internationaloptions.cxx index c50db3641f03..bba058cdcd92 100644 --- a/cui/source/options/internationaloptions.cxx +++ b/cui/source/options/internationaloptions.cxx @@ -46,14 +46,14 @@ namespace offapp CheckBox m_aCB_ShtVwRight2Left; CheckBox m_aCB_ShtVwCurrentDocOnly; - BOOL m_bEnable_SheetView_Opt : 1; + sal_Bool m_bEnable_SheetView_Opt : 1; inline IMPL( Window* _pParent ); - inline void EnableOption_SheetView( BOOL _bEnable = TRUE ); - void ShowOption_SheetView( BOOL _bShow = TRUE ); + inline void EnableOption_SheetView( sal_Bool _bEnable = sal_True ); + void ShowOption_SheetView( sal_Bool _bShow = sal_True ); - BOOL FillItemSet( SfxItemSet& _rSet ); + sal_Bool FillItemSet( SfxItemSet& _rSet ); void Reset( const SfxItemSet& _rSet ); }; @@ -65,12 +65,12 @@ namespace offapp ,m_aCB_ShtVwRight2Left ( _pParent, CUI_RES( CB_SHTVW_RIGHT2LEFT ) ) ,m_aCB_ShtVwCurrentDocOnly ( _pParent, CUI_RES( CB_SHTVW_CURRENTDOCONLY ) ) - ,m_bEnable_SheetView_Opt ( FALSE ) + ,m_bEnable_SheetView_Opt ( sal_False ) { ShowOption_SheetView( m_bEnable_SheetView_Opt ); } - inline void InternationalOptionsPage::IMPL::EnableOption_SheetView( BOOL _bEnable ) + inline void InternationalOptionsPage::IMPL::EnableOption_SheetView( sal_Bool _bEnable ) { if( m_bEnable_SheetView_Opt != _bEnable ) { @@ -80,14 +80,14 @@ namespace offapp } } - void InternationalOptionsPage::IMPL::ShowOption_SheetView( BOOL _bShow ) + void InternationalOptionsPage::IMPL::ShowOption_SheetView( sal_Bool _bShow ) { m_aFL_SheetView.Show( _bShow ); m_aCB_ShtVwRight2Left.Show( _bShow ); m_aCB_ShtVwCurrentDocOnly.Show( _bShow ); } - BOOL InternationalOptionsPage::IMPL::FillItemSet( SfxItemSet& _rSet ) + sal_Bool InternationalOptionsPage::IMPL::FillItemSet( SfxItemSet& _rSet ) { DBG_ASSERT( _rSet.GetPool(), "-InternationalOptionsPage::FillItemSet(): no pool gives rums!" ); @@ -96,7 +96,7 @@ namespace offapp m_aRB_TxtDirLeft2Right.IsChecked() ), SID_ATTR_PARA_LEFT_TO_RIGHT ); - return TRUE; + return sal_True; } void InternationalOptionsPage::IMPL::Reset( const SfxItemSet& _rSet ) @@ -106,7 +106,7 @@ namespace offapp DBG_ASSERT( pLeft2RightItem, "+InternationalOptionsPage::Reset(): SID_ATTR_PARA_LEFT_TO_RIGHT not set!" ); - BOOL bLeft2Right = pLeft2RightItem? pLeft2RightItem->GetValue() : TRUE; + sal_Bool bLeft2Right = pLeft2RightItem? pLeft2RightItem->GetValue() : sal_True; m_aRB_TxtDirLeft2Right.Check( bLeft2Right ); } @@ -135,7 +135,7 @@ namespace offapp DELETEZ( m_pImpl ); } - BOOL InternationalOptionsPage::FillItemSet( SfxItemSet& _rSet ) + sal_Bool InternationalOptionsPage::FillItemSet( SfxItemSet& _rSet ) { return m_pImpl->FillItemSet( _rSet ); } diff --git a/cui/source/options/internationaloptions.src b/cui/source/options/internationaloptions.src index b07baaf47aa8..16509bf5d920 100644 --- a/cui/source/options/internationaloptions.src +++ b/cui/source/options/internationaloptions.src @@ -32,6 +32,7 @@ TabPage RID_OFA_TP_INTERNATIONAL { + HelpID = "cui:TabPage:RID_OFA_TP_INTERNATIONAL"; OutputSize = TRUE ; Size = MAP_APPFONT ( PAGE_SIZE_X, PAGE_SIZE_Y ) ; SVLook = TRUE ; @@ -46,6 +47,7 @@ TabPage RID_OFA_TP_INTERNATIONAL RadioButton RB_TXTDIR_LEFT2RIGHT { + HelpID = "cui:RadioButton:RID_OFA_TP_INTERNATIONAL:RB_TXTDIR_LEFT2RIGHT"; Pos = MAP_APPFONT( COL_1, ROW_1 ); Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_RB ); Group = TRUE; @@ -54,6 +56,7 @@ TabPage RID_OFA_TP_INTERNATIONAL RadioButton RB_TXTDIR_RIGHT2LEFT { + HelpID = "cui:RadioButton:RID_OFA_TP_INTERNATIONAL:RB_TXTDIR_RIGHT2LEFT"; Pos = MAP_APPFONT( COL_1, ROW_2 ); Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_RB ); Text [ en-US ] = "~Right-to-left"; @@ -68,6 +71,7 @@ TabPage RID_OFA_TP_INTERNATIONAL CheckBox CB_SHTVW_RIGHT2LEFT { + HelpID = "cui:CheckBox:RID_OFA_TP_INTERNATIONAL:CB_SHTVW_RIGHT2LEFT"; Pos = MAP_APPFONT( COL_1, ROW_4 ); Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_CB ); Text [ en-US ] = "Right-~to-left"; @@ -75,6 +79,7 @@ TabPage RID_OFA_TP_INTERNATIONAL CheckBox CB_SHTVW_CURRENTDOCONLY { + HelpID = "cui:CheckBox:RID_OFA_TP_INTERNATIONAL:CB_SHTVW_CURRENTDOCONLY"; Pos = MAP_APPFONT( COL_2, ROW_5 ); Size = MAP_APPFONT( WIDTH2END( COL_2 ), HEIGHT_CB ); Text [ en-US ] = "~Current document only"; diff --git a/cui/source/options/optHeaderTabListbox.cxx b/cui/source/options/optHeaderTabListbox.cxx index 28ecf2fa58fe..64a7f49ca096 100644 --- a/cui/source/options/optHeaderTabListbox.cxx +++ b/cui/source/options/optHeaderTabListbox.cxx @@ -37,15 +37,15 @@ namespace svx class OptLBoxString_Impl : public SvLBoxString { public: - OptLBoxString_Impl( SvLBoxEntry* pEntry, USHORT nFlags, const String& rTxt ) : + OptLBoxString_Impl( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rTxt ) : SvLBoxString( pEntry, nFlags, rTxt ) {} - virtual void Paint( const Point& rPos, SvLBox& rDev, USHORT nFlags, SvLBoxEntry* pEntry ); + virtual void Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry ); }; // ----------------------------------------------------------------------- -void OptLBoxString_Impl::Paint( const Point& rPos, SvLBox& rDev, USHORT, SvLBoxEntry* pEntry ) +void OptLBoxString_Impl::Paint( const Point& rPos, SvLBox& rDev, sal_uInt16, SvLBoxEntry* pEntry ) { Font aOldFont( rDev.GetFont() ); Font aFont( aOldFont ); @@ -70,9 +70,9 @@ void OptHeaderTabListBox::InitEntry( SvLBoxEntry* pEntry, const XubString& rTxt, SvLBoxButtonKind eButtonKind ) { SvTabListBox::InitEntry( pEntry, rTxt, rImg1, rImg2, eButtonKind ); - USHORT _nTabCount = TabCount(); + sal_uInt16 _nTabCount = TabCount(); - for ( USHORT nCol = 1; nCol < _nTabCount; ++nCol ) + for ( sal_uInt16 nCol = 1; nCol < _nTabCount; ++nCol ) { // alle Spalten mit eigener Klasse initialisieren (Spalte 0 == Bitmap) SvLBoxString* pCol = (SvLBoxString*)pEntry->GetItem( nCol ); diff --git a/cui/source/options/optaccessibility.cxx b/cui/source/options/optaccessibility.cxx index 2591ad7a63a5..275306b93acc 100644 --- a/cui/source/options/optaccessibility.cxx +++ b/cui/source/options/optaccessibility.cxx @@ -121,7 +121,7 @@ SfxTabPage* SvxAccessibilityOptionsTabPage::Create( Window* pParent, const SfxIt return new SvxAccessibilityOptionsTabPage(pParent, rAttrSet); } -BOOL SvxAccessibilityOptionsTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxAccessibilityOptionsTabPage::FillItemSet( SfxItemSet& ) { //aConfig.Set... from controls @@ -146,7 +146,7 @@ BOOL SvxAccessibilityOptionsTabPage::FillItemSet( SfxItemSet& ) Application::MergeSystemSettings( aAllSettings ); Application::SetSettings(aAllSettings); - return FALSE; + return sal_False; } void SvxAccessibilityOptionsTabPage::Reset( const SfxItemSet& ) diff --git a/cui/source/options/optaccessibility.hxx b/cui/source/options/optaccessibility.hxx index 3e3b0deafaba..83a42cf7ed6f 100644 --- a/cui/source/options/optaccessibility.hxx +++ b/cui/source/options/optaccessibility.hxx @@ -58,7 +58,7 @@ public: virtual ~SvxAccessibilityOptionsTabPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optaccessibility.src b/cui/source/options/optaccessibility.src index 8f2afb38f574..33849798347e 100644 --- a/cui/source/options/optaccessibility.src +++ b/cui/source/options/optaccessibility.src @@ -44,6 +44,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_ACCESSIBILITY_TOOL { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_ACCESSIBILITY_TOOL"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWA_1 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -52,6 +53,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_TEXTSELECTION { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_TEXTSELECTION"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWA_2 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -59,6 +61,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_ANIMATED_GRAPHICS { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_ANIMATED_GRAPHICS"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWA_3 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -66,6 +69,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_ANIMATED_TEXTS { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_ANIMATED_TEXTS"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWA_4 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -73,6 +77,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_TIPHELP { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_TIPHELP"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, OFFS_TEXTBOX_FIXEDTEXT( ROWA_5 ) ); Size = MAP_APPFONT( DIFF(COL2,COL3), RSC_CD_CHECKBOX_HEIGHT ); @@ -80,6 +85,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; NumericField NF_TIPHELP { + HelpID = "cui:NumericField:RID_SVXPAGE_ACCESSIBILITYCONFIG:NF_TIPHELP"; TabStop = TRUE ; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROWA_5 ); @@ -105,6 +111,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_AUTO_DETECT_HC { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_AUTO_DETECT_HC"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWB_1 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -112,6 +119,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_AUTOMATIC_FONT_COLOR { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_AUTOMATIC_FONT_COLOR"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWB_2 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); @@ -119,6 +127,7 @@ TabPage RID_SVXPAGE_ACCESSIBILITYCONFIG }; CheckBox CB_PAGE_PREVIEWS { + HelpID = "cui:CheckBox:RID_SVXPAGE_ACCESSIBILITYCONFIG:CB_PAGE_PREVIEWS"; TabStop = TRUE ; Pos = MAP_APPFONT( COL1, ROWB_3 ); Size = MAP_APPFONT( CB_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); diff --git a/cui/source/options/optasian.cxx b/cui/source/options/optasian.cxx index f04a50dc076f..d345cf8a7a88 100644 --- a/cui/source/options/optasian.cxx +++ b/cui/source/options/optasian.cxx @@ -163,7 +163,7 @@ SvxAsianLayoutPage::SvxAsianLayoutPage( Window* pParent, const SfxItemSet& rSet aStartED.SetModifyHdl(aLk); aEndED.SetModifyHdl(aLk); - aLanguageLB.SetLanguageList( LANG_LIST_FBD_CHARS, FALSE, FALSE ); + aLanguageLB.SetLanguageList( LANG_LIST_FBD_CHARS, sal_False, sal_False ); } SvxAsianLayoutPage::~SvxAsianLayoutPage() @@ -176,7 +176,7 @@ SfxTabPage* SvxAsianLayoutPage::Create( Window* pParent, const SfxItemSet& rAttr return new SvxAsianLayoutPage(pParent, rAttrSet); } -BOOL SvxAsianLayoutPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxAsianLayoutPage::FillItemSet( SfxItemSet& ) { if(aCharKerningRB.IsChecked() != aCharKerningRB.GetSavedValue()) { @@ -185,7 +185,7 @@ BOOL SvxAsianLayoutPage::FillItemSet( SfxItemSet& ) if(pImpl->xPrSetInfo.is() && pImpl->xPrSetInfo->hasPropertyByName(sPunct)) { Any aVal; - BOOL bVal = !aCharKerningRB.IsChecked(); + sal_Bool bVal = !aCharKerningRB.IsChecked(); aVal.setValue(&bVal, ::getBooleanCppuType()); pImpl->xPrSet->setPropertyValue(sPunct, aVal); } @@ -214,9 +214,9 @@ BOOL SvxAsianLayoutPage::FillItemSet( SfxItemSet& ) for( SvxForbiddenChars_Impl* pElem = pImpl->aChangedLanguagesTbl.First(); pElem; pElem = pImpl->aChangedLanguagesTbl.Next() ) { - ULONG nLang = pImpl->aChangedLanguagesTbl.GetKey( pElem ); + sal_uLong nLang = pImpl->aChangedLanguagesTbl.GetKey( pElem ); Locale aLocale; - SvxLanguageToLocale(aLocale, (USHORT)nLang ); + SvxLanguageToLocale(aLocale, (sal_uInt16)nLang ); if(pElem->bRemoved) pImpl->xForbidden->removeForbiddenCharacters( aLocale ); else if(pElem->pCharacters) @@ -230,7 +230,7 @@ BOOL SvxAsianLayoutPage::FillItemSet( SfxItemSet& ) } eLastUsedLanguageTypeForForbiddenCharacters = aLanguageLB.GetSelectLanguage(); - return FALSE; + return sal_False; } void SvxAsianLayoutPage::Reset( const SfxItemSet& ) @@ -273,20 +273,20 @@ void SvxAsianLayoutPage::Reset( const SfxItemSet& ) } else { - aStartEndGB.Enable(FALSE); - aLanguageFT.Enable(FALSE); - aLanguageLB.Enable(FALSE); - aStandardCB.Enable(FALSE); - aStartFT.Enable(FALSE); - aStartED.Enable(FALSE); - aEndFT.Enable(FALSE); - aEndED.Enable(FALSE); - aHintFT.Enable(FALSE); + aStartEndGB.Enable(sal_False); + aLanguageFT.Enable(sal_False); + aLanguageLB.Enable(sal_False); + aStandardCB.Enable(sal_False); + aStartFT.Enable(sal_False); + aStartED.Enable(sal_False); + aEndFT.Enable(sal_False); + aEndED.Enable(sal_False); + aHintFT.Enable(sal_False); } if(bKernWesternText) - aCharKerningRB.Check(TRUE); + aCharKerningRB.Check(sal_True); else - aCharPunctKerningRB.Check(TRUE); + aCharPunctKerningRB.Check(sal_True); switch(nCompress) { case 0 : aNoCompressionRB.Check(); break; @@ -337,7 +337,7 @@ IMPL_LINK(SvxAsianLayoutPage, LanguageHdl, SvxLanguageBox*, EMPTYARG ) SvxForbiddenChars_Impl* pElement = pImpl->getForbiddenCharacters(eSelectLanguage); if(pElement->bRemoved || !pElement->pCharacters) { - bAvail = FALSE; + bAvail = sal_False; } else { @@ -429,10 +429,10 @@ IMPL_LINK(SvxAsianLayoutPage, ModifyHdl, Edit*, pEdit) return 0; } -USHORT* SvxAsianLayoutPage::GetRanges() +sal_uInt16* SvxAsianLayoutPage::GetRanges() { //no items are used - static USHORT pAsianLayoutRanges[] = { 0 }; + static sal_uInt16 pAsianLayoutRanges[] = { 0 }; return pAsianLayoutRanges; } diff --git a/cui/source/options/optasian.src b/cui/source/options/optasian.src index 564294f8afc1..fee1826704b5 100644 --- a/cui/source/options/optasian.src +++ b/cui/source/options/optasian.src @@ -45,12 +45,14 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; RadioButton RB_CHAR_KERNING { + HelpID = "cui:RadioButton:RID_SVXPAGE_ASIAN_LAYOUT:RB_CHAR_KERNING"; Pos = MAP_APPFONT ( 12, 14 ) ; Size = MAP_APPFONT ( 200 , 10 ) ; Text [ en-US ] = "~Western characters only"; }; RadioButton RB_CHAR_PUNCT { + HelpID = "cui:RadioButton:RID_SVXPAGE_ASIAN_LAYOUT:RB_CHAR_PUNCT"; Pos = MAP_APPFONT ( 12, 27 ) ; Size = MAP_APPFONT ( 200 , 10 ) ; Text [ en-US ] = "Western ~text and Asian punctuation"; @@ -63,18 +65,21 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; RadioButton RB_NO_COMP { + HelpID = "cui:RadioButton:RID_SVXPAGE_ASIAN_LAYOUT:RB_NO_COMP"; Pos = MAP_APPFONT ( 12, 54 ) ; Size = MAP_APPFONT ( 200 , 10 ) ; Text [ en-US ] = "~No compression"; }; RadioButton RB_PUNCT_COMP { + HelpID = "cui:RadioButton:RID_SVXPAGE_ASIAN_LAYOUT:RB_PUNCT_COMP"; Pos = MAP_APPFONT ( 12, 67) ; Size = MAP_APPFONT ( 200 , 10 ) ; Text [ en-US ] = "~Compress punctuation only"; }; RadioButton RB_PUNCT_KANA_COMP { + HelpID = "cui:RadioButton:RID_SVXPAGE_ASIAN_LAYOUT:RB_PUNCT_KANA_COMP"; Pos = MAP_APPFONT ( 12, 80 ) ; Size = MAP_APPFONT ( 200 , 10 ) ; Text [ en-US ] = "Compress ~punctuation and Japanese Kana"; @@ -93,6 +98,7 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; ListBox LB_LANGUAGE { + HelpID = "cui:ListBox:RID_SVXPAGE_ASIAN_LAYOUT:LB_LANGUAGE"; Pos = MAP_APPFONT ( 95 , 107 ) ; Size = MAP_APPFONT ( 80 , 48 ) ; Border = TRUE ; @@ -100,6 +106,7 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; CheckBox CB_STANDARD { + HelpID = "cui:CheckBox:RID_SVXPAGE_ASIAN_LAYOUT:CB_STANDARD"; Pos = MAP_APPFONT ( 180, 109 ) ; Size = MAP_APPFONT ( 74 , 10 ) ; Text [ en-US ] = "~Default"; @@ -112,6 +119,7 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; Edit ED_START { + HelpID = "cui:Edit:RID_SVXPAGE_ASIAN_LAYOUT:ED_START"; Pos = MAP_APPFONT ( 95 , 123 ) ; Size = MAP_APPFONT ( 159 , 12 ) ; Border = TRUE ; @@ -124,6 +132,7 @@ TabPage RID_SVXPAGE_ASIAN_LAYOUT }; Edit ED_END { + HelpID = "cui:Edit:RID_SVXPAGE_ASIAN_LAYOUT:ED_END"; Pos = MAP_APPFONT ( 95 , 139 ) ; Size = MAP_APPFONT ( 159 , 12 ) ; Border = TRUE ; diff --git a/cui/source/options/optchart.cxx b/cui/source/options/optchart.cxx index 85a76459e917..ec1aa4bc7960 100644 --- a/cui/source/options/optchart.cxx +++ b/cui/source/options/optchart.cxx @@ -39,13 +39,13 @@ void ChartColorLB::FillBox( const SvxChartColorTable & rTab ) { long nCount = rTab.size(); - SetUpdateMode( FALSE ); + SetUpdateMode( sal_False ); for( long i = 0; i < nCount; i++ ) { Append( const_cast< XColorEntry * >( & rTab[ i ] )); } - SetUpdateMode( TRUE ); + SetUpdateMode( sal_True ); } @@ -79,7 +79,7 @@ SvxDefaultColorOptPage::SvxDefaultColorOptPage( Window* pParent, const SfxItemSe pColorTab = new XColorTable( SvtPathOptions().GetPalettePath() ); const SfxPoolItem* pItem = NULL; - if ( rInAttrs.GetItemState( SID_SCH_EDITOPTIONS, FALSE, &pItem ) == SFX_ITEM_SET ) + if ( rInAttrs.GetItemState( SID_SCH_EDITOPTIONS, sal_False, &pItem ) == SFX_ITEM_SET ) { pColorConfig = SAL_STATIC_CAST( SvxChartColorTableItem*, pItem->Clone() ); } @@ -122,12 +122,12 @@ SfxTabPage* SvxDefaultColorOptPage::Create( Window* pParent, const SfxItemSet& r return new SvxDefaultColorOptPage( pParent, rAttrs ); } -BOOL SvxDefaultColorOptPage::FillItemSet( SfxItemSet& rOutAttrs ) +sal_Bool SvxDefaultColorOptPage::FillItemSet( SfxItemSet& rOutAttrs ) { if( pColorConfig ) rOutAttrs.Put( *SAL_STATIC_CAST( SfxPoolItem*, pColorConfig )); - return TRUE; + return sal_True; } void SvxDefaultColorOptPage::Reset( const SfxItemSet& ) @@ -146,7 +146,7 @@ void SvxDefaultColorOptPage::FillColorBox() for( long i = 0; i < nCount; i++ ) { pColorEntry = pColorTab->GetColor( i ); - aValSetColorBox.InsertItem( (USHORT) i + 1, pColorEntry->GetColor(), pColorEntry->GetName() ); + aValSetColorBox.InsertItem( (sal_uInt16) i + 1, pColorEntry->GetColor(), pColorEntry->GetName() ); } } @@ -207,7 +207,7 @@ IMPL_LINK( SvxDefaultColorOptPage, ListClickedHdl, ChartColorLB*, pColorList ) } else { - aValSetColorBox.SelectItem( (USHORT)nIndex + 1 ); // ValueSet is 1-based + aValSetColorBox.SelectItem( (sal_uInt16)nIndex + 1 ); // ValueSet is 1-based } return 0L; @@ -218,7 +218,7 @@ IMPL_LINK( SvxDefaultColorOptPage, ListClickedHdl, ChartColorLB*, pColorList ) IMPL_LINK( SvxDefaultColorOptPage, BoxClickedHdl, ValueSet*, EMPTYARG ) { - USHORT nIdx = aLbChartColors.GetSelectEntryPos(); + sal_uInt16 nIdx = aLbChartColors.GetSelectEntryPos(); if( nIdx != LISTBOX_ENTRY_NOTFOUND ) { XColorEntry aEntry( aValSetColorBox.GetItemColor( aValSetColorBox.GetSelectItemId() ), diff --git a/cui/source/options/optchart.hxx b/cui/source/options/optchart.hxx index efbb14086588..d3f1b38a88f4 100644 --- a/cui/source/options/optchart.hxx +++ b/cui/source/options/optchart.hxx @@ -80,7 +80,7 @@ public: void Construct(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs ); - virtual BOOL FillItemSet( SfxItemSet& rOutAttrs ); + virtual sal_Bool FillItemSet( SfxItemSet& rOutAttrs ); virtual void Reset( const SfxItemSet& rInAttrs ); }; diff --git a/cui/source/options/optchart.src b/cui/source/options/optchart.src index 374828b329c1..af2d7444612a 100644 --- a/cui/source/options/optchart.src +++ b/cui/source/options/optchart.src @@ -46,6 +46,7 @@ TabPage RID_OPTPAGE_CHART_DEFCOLORS }; ListBox LB_CHART_COLOR_LIST { + HelpID = "cui:ListBox:RID_OPTPAGE_CHART_DEFCOLORS:LB_CHART_COLOR_LIST"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 15 ); Size = MAP_APPFONT ( 68 , 152 ); @@ -68,6 +69,7 @@ TabPage RID_OPTPAGE_CHART_DEFCOLORS }; PushButton PB_RESET_TO_DEFAULT { + HelpID = "cui:PushButton:RID_OPTPAGE_CHART_DEFCOLORS:PB_RESET_TO_DEFAULT"; Pos = MAP_APPFONT ( 204 , 165 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Default"; diff --git a/cui/source/options/optcolor.cxx b/cui/source/options/optcolor.cxx index 647c5e2c006f..7180cd6b241c 100644 --- a/cui/source/options/optcolor.cxx +++ b/cui/source/options/optcolor.cxx @@ -58,6 +58,94 @@ using namespace ::svtools; #define GROUP_BASIC 5 #define GROUP_SQL 6 +const char* aColorLBHids[] = +{ + HID_COLORPAGE_DOCCOLOR_LB, + HID_COLORPAGE_DOCBOUNDARIES_LB, + HID_COLORPAGE_APPBACKGROUND_LB, + HID_COLORPAGE_OBJECTBOUNDARIES_LB, + HID_COLORPAGE_TABLEBOUNDARIES_LB, + HID_COLORPAGE_FONTCOLOR_LB, + HID_COLORPAGE_LINKS_LB, + HID_COLORPAGE_LINKSVISITED_LB, + HID_COLORPAGE_ANCHOR_LB, + HID_COLORPAGE_SPELL_LB, + HID_COLORPAGE_WRITERTEXTGRID_LB, + HID_COLORPAGE_WRITERFIELDSHADINGS_LB, + HID_COLORPAGE_WRITERIDXSHADINGS_LB, + HID_COLORPAGE_WRITERDIRECTCURSOR_LB, + HID_COLORPAGE_WRITERNOTESINDICATOR_LB, + HID_COLORPAGE_WRITERSCRIPTINDICATOR_LB, + HID_COLORPAGE_WRITERSECTIONBOUNDARIES_LB, + HID_COLORPAGE_WRITERPAGEBREAKS_LB, + HID_COLORPAGE_HTMLSGML_LB, + HID_COLORPAGE_HTMLCOMMENT_LB, + HID_COLORPAGE_HTMLKEYWORD_LB, + HID_COLORPAGE_HTMLUNKNOWN_LB, + HID_COLORPAGE_CALCGRID_LB, + HID_COLORPAGE_CALCPAGEBREAK_LB, + HID_COLORPAGE_CALCPAGEBREAKMANUAL_LB, + HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_LB, + HID_COLORPAGE_CALCDETECTIVE_LB, + HID_COLORPAGE_CALCDETECTIVEERROR_LB, + HID_COLORPAGE_CALCREFERENCE_LB, + HID_COLORPAGE_CALCNOTESBACKGROUND_LB, + HID_COLORPAGE_DRAWGRID_LB, + HID_COLORPAGE_DRAWDRAWING_LB, + HID_COLORPAGE_DRAWFILL_LB, + HID_COLORPAGE_BASICIDENTIFIER_LB, + HID_COLORPAGE_BASICCOMMENT_LB, + HID_COLORPAGE_BASICNUMBER_LB, + HID_COLORPAGE_BASICSTRING_LB, + HID_COLORPAGE_BASICOPERATOR_LB, + HID_COLORPAGE_BASICKEYWORD_LB, + HID_COLORPAGE_BASICERROR_LB +}; + +const char* aColorCBHids[] = +{ + HID_COLORPAGE_DOCCOLOR_CB, + HID_COLORPAGE_DOCBOUNDARIES_CB, + HID_COLORPAGE_APPBACKGROUND_CB, + HID_COLORPAGE_OBJECTBOUNDARIES_CB, + HID_COLORPAGE_TABLEBOUNDARIES_CB, + HID_COLORPAGE_FONTCOLOR_CB, + HID_COLORPAGE_LINKS_CB, + HID_COLORPAGE_LINKSVISITED_CB, + HID_COLORPAGE_ANCHOR_CB, + HID_COLORPAGE_SPELL_CB, + HID_COLORPAGE_WRITERTEXTGRID_CB, + HID_COLORPAGE_WRITERFIELDSHADINGS_CB, + HID_COLORPAGE_WRITERIDXSHADINGS_CB, + HID_COLORPAGE_WRITERDIRECTCURSOR_CB, + HID_COLORPAGE_WRITERNOTESINDICATOR_CB, + HID_COLORPAGE_WRITERSCRIPTINDICATOR_CB, + HID_COLORPAGE_WRITERSECTIONBOUNDARIES_CB, + HID_COLORPAGE_WRITERPAGEBREAKS_CB, + HID_COLORPAGE_HTMLSGML_CB, + HID_COLORPAGE_HTMLCOMMENT_CB, + HID_COLORPAGE_HTMLKEYWORD_CB, + HID_COLORPAGE_HTMLUNKNOWN_CB, + HID_COLORPAGE_CALCGRID_CB, + HID_COLORPAGE_CALCPAGEBREAK_CB, + HID_COLORPAGE_CALCPAGEBREAKMANUAL_CB, + HID_COLORPAGE_CALCPAGEBREAKAUTOMATIC_CB, + HID_COLORPAGE_CALCDETECTIVE_CB, + HID_COLORPAGE_CALCDETECTIVEERROR_CB, + HID_COLORPAGE_CALCREFERENCE_CB, + HID_COLORPAGE_CALCNOTESBACKGROUND_CB, + HID_COLORPAGE_DRAWGRID_CB, + HID_COLORPAGE_DRAWDRAWING_CB, + HID_COLORPAGE_DRAWFILL_CB, + HID_COLORPAGE_BASICIDENTIFIER_CB, + HID_COLORPAGE_BASICCOMMENT_CB, + HID_COLORPAGE_BASICNUMBER_CB, + HID_COLORPAGE_BASICSTRING_CB, + HID_COLORPAGE_BASICOPERATOR_CB, + HID_COLORPAGE_BASICKEYWORD_CB, + HID_COLORPAGE_BASICERROR_CB +}; + class SvxExtFixedText_Impl : public FixedText { private: @@ -777,13 +865,13 @@ ColorConfigWindow_Impl::ColorConfigWindow_Impl(Window* pParent, const ResId& rRe } } Color aTextColor; - BOOL bSetTextColor = FALSE; + sal_Bool bSetTextColor = sal_False; //#104195# when the window color is the same as the text color it has to be changed Color aWinCol = rStyleSettings.GetWindowColor(); Color aRCheckCol = rStyleSettings.GetRadioCheckTextColor(); if(aWinCol == aRCheckCol ) { - bSetTextColor = TRUE; + bSetTextColor = sal_True; aRCheckCol.Invert(); //if inversion didn't work (gray) then it's set to black if(aRCheckCol == aWinCol) @@ -814,7 +902,7 @@ ColorConfigWindow_Impl::ColorConfigWindow_Impl(Window* pParent, const ResId& rRe else aCheckBoxes[i]->Hide(); aCheckBoxes[i]->SetBackground(aTransparentWall); - aCheckBoxes[i]->SetHelpId(HID_COLORPAGE_CHECKBOX_START + i); + aCheckBoxes[i]->SetHelpId( aColorCBHids[i] ); if(bSetTextColor) aCheckBoxes[i]->SetTextColor(aRCheckCol); } @@ -853,13 +941,17 @@ ColorConfigWindow_Impl::ColorConfigWindow_Impl(Window* pParent, const ResId& rRe XColorEntry* pEntry = aColorTable.GetColor(i); aColorBoxes[0]->InsertEntry( pEntry->GetColor(), pEntry->GetName() ); } - aColorBoxes[0]->SetHelpId(HID_COLORPAGE_LISTBOX_START); + + aColorBoxes[0]->SetHelpId( aColorLBHids[0] ); + + OSL_ENSURE( nCount < sal_Int32(sizeof(aColorLBHids)/sizeof(aColorLBHids[0])), "too few helpIDs for color listboxes" ); for( sal_Int32 i = 1; i < nCount; i++ ) { if(aColorBoxes[i]) { aColorBoxes[i]->CopyEntries( *aColorBoxes[0] ); - aColorBoxes[i]->SetHelpId(HID_COLORPAGE_LISTBOX_START + i); + if( i < sal_Int32(sizeof(aColorLBHids)/sizeof(aColorLBHids[0])) ) + aColorBoxes[i]->SetHelpId( aColorLBHids[i] ); } } } @@ -1023,11 +1115,11 @@ ColorConfigCtrl_Impl::ColorConfigCtrl_Impl( sal_Int32 nThirdWidth = aScrollWindow.aWindows[0]->GetPosPixel().X() - nFirstWidth - nSecondWidth; const WinBits nHeadBits = HIB_VCENTER | HIB_FIXED| HIB_FIXEDPOS; - aHeaderHB.InsertItem( 1, sOn, nFirstWidth, (USHORT)nHeadBits|HIB_CENTER); - aHeaderHB.InsertItem( 2, sUIElem, nSecondWidth, (USHORT)nHeadBits|HIB_LEFT); - aHeaderHB.InsertItem( 3, sColSetting, nThirdWidth, (USHORT)nHeadBits|HIB_LEFT); + aHeaderHB.InsertItem( 1, sOn, nFirstWidth, (sal_uInt16)nHeadBits|HIB_CENTER); + aHeaderHB.InsertItem( 2, sUIElem, nSecondWidth, (sal_uInt16)nHeadBits|HIB_LEFT); + aHeaderHB.InsertItem( 3, sColSetting, nThirdWidth, (sal_uInt16)nHeadBits|HIB_LEFT); aHeaderHB.InsertItem( 4, sPreview, - aHeaderHB.GetSizePixel().Width() - nFirstWidth - nSecondWidth - nThirdWidth, (USHORT)nHeadBits|HIB_LEFT); + aHeaderHB.GetSizePixel().Width() - nFirstWidth - nSecondWidth - nThirdWidth, (sal_uInt16)nHeadBits|HIB_LEFT); aHeaderHB.Show(); aVScroll.SetRangeMin(0); @@ -1095,7 +1187,7 @@ void ColorConfigCtrl_Impl::Update() if(ANCHOR == i) continue; const ColorConfigValue& rColorEntry = pColorConfig->GetColorValue(ColorConfigEntry(i)); - if(COL_AUTO == (UINT32)rColorEntry.nColor) + if(COL_AUTO == (sal_uInt32)rColorEntry.nColor) { if(aScrollWindow.aColorBoxes[i]) aScrollWindow.aColorBoxes[i]->SelectEntryPos(0); @@ -1153,7 +1245,7 @@ void ColorConfigCtrl_Impl::Update() sal_Bool lcl_MoveAndShow(Window* pWindow, long nOffset, long nMaxVisible, sal_Bool _bShow) { - sal_Bool bHide = TRUE; + sal_Bool bHide = sal_True; if(pWindow) { Point aPos = pWindow->GetPosPixel(); @@ -1167,7 +1259,7 @@ sal_Bool lcl_MoveAndShow(Window* pWindow, long nOffset, long nMaxVisible, sal_Bo } IMPL_LINK(ColorConfigCtrl_Impl, ScrollHdl, ScrollBar*, pScrollBar) { - aScrollWindow.SetUpdateMode(TRUE); + aScrollWindow.SetUpdateMode(sal_True); sal_Int16 i; long nOffset = aScrollWindow.aColorBoxes[1]->GetPosPixel().Y() - aScrollWindow.aColorBoxes[0]->GetPosPixel().Y(); nOffset *= (nScrollPos - pScrollBar->GetThumbPos()); @@ -1243,7 +1335,7 @@ IMPL_LINK(ColorConfigCtrl_Impl, ScrollHdl, ScrollBar*, pScrollBar) Point aPos = aScrollWindow.aChapters[i]->GetPosPixel(); aPos.Y() += nOffset; aScrollWindow.aChapters[i]->SetPosPixel(aPos); aPos = aScrollWindow.aChapterWins[i]->GetPosPixel(); aPos.Y() += nOffset; aScrollWindow.aChapterWins[i]->SetPosPixel(aPos); } - aScrollWindow.SetUpdateMode(TRUE); + aScrollWindow.SetUpdateMode(sal_True); return 0; } @@ -1252,7 +1344,7 @@ long ColorConfigCtrl_Impl::PreNotify( NotifyEvent& rNEvt ) if(rNEvt.GetType() == EVENT_COMMAND) { const CommandEvent* pCEvt = rNEvt.GetCommandEvent(); - USHORT nCmd = pCEvt->GetCommand(); + sal_uInt16 nCmd = pCEvt->GetCommand(); if( COMMAND_WHEEL == nCmd ) { Command(*pCEvt); @@ -1413,7 +1505,7 @@ SvxColorOptionsTabPage::SvxColorOptionsTabPage( aSaveSchemePB( this, CUI_RES( PB_SAVESCHEME) ), aDeleteSchemePB( this, CUI_RES( PB_DELETESCHEME ) ), aCustomColorsFL( this, CUI_RES( FL_CUSTOMCOLORS ) ), - bFillItemSetCalled(FALSE), + bFillItemSetCalled(sal_False), pColorConfig(0), pExtColorConfig(0), pColorConfigCT( new ColorConfigCtrl_Impl(this, CUI_RES( CT_COLORCONFIG ) )) @@ -1452,9 +1544,9 @@ SfxTabPage* SvxColorOptionsTabPage::Create( Window* pParent, const SfxItemSet& r return ( new SvxColorOptionsTabPage( pParent, rAttrSet ) ); } -BOOL SvxColorOptionsTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxColorOptionsTabPage::FillItemSet( SfxItemSet& ) { - bFillItemSetCalled = TRUE; + bFillItemSetCalled = sal_True; if(aColorSchemeLB.GetSavedValue() != aColorSchemeLB.GetSelectEntryPos()) { pColorConfig->SetModified(); @@ -1464,7 +1556,7 @@ BOOL SvxColorOptionsTabPage::FillItemSet( SfxItemSet& ) pColorConfig->Commit(); if(pExtColorConfig->IsModified()) pExtColorConfig->Commit(); - return TRUE; + return sal_True; } void SvxColorOptionsTabPage::Reset( const SfxItemSet& ) diff --git a/cui/source/options/optcolor.hxx b/cui/source/options/optcolor.hxx index b615d07f3c8f..6e44569ce8cc 100644 --- a/cui/source/options/optcolor.hxx +++ b/cui/source/options/optcolor.hxx @@ -50,7 +50,7 @@ class SvxColorOptionsTabPage : public SfxTabPage FixedLine aCustomColorsFL; - BOOL bFillItemSetCalled; + sal_Bool bFillItemSetCalled; svtools::EditableColorConfig* pColorConfig; svtools::EditableExtendedColorConfig* pExtColorConfig; @@ -67,7 +67,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual int DeactivatePage( SfxItemSet* pSet ); diff --git a/cui/source/options/optcolor.src b/cui/source/options/optcolor.src index a3640678b1d1..201495f5c1fa 100644 --- a/cui/source/options/optcolor.src +++ b/cui/source/options/optcolor.src @@ -52,6 +52,7 @@ TabPage RID_SVXPAGE_COLORCONFIG }; ListBox LB_COLORSCHEME { + HelpID = "cui:ListBox:RID_SVXPAGE_COLORCONFIG:LB_COLORSCHEME"; Pos = MAP_APPFONT ( 65 , 14 ) ; Size = MAP_APPFONT ( 77 , 58 ) ; Border = TRUE; @@ -60,12 +61,14 @@ TabPage RID_SVXPAGE_COLORCONFIG }; PushButton PB_SAVESCHEME { + HelpID = "cui:PushButton:RID_SVXPAGE_COLORCONFIG:PB_SAVESCHEME"; Pos = MAP_APPFONT ( 145, 13 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "Save..."; }; PushButton PB_DELETESCHEME { + HelpID = "cui:PushButton:RID_SVXPAGE_COLORCONFIG:PB_DELETESCHEME"; Pos = MAP_APPFONT ( 198 , 13 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "Delete"; @@ -150,6 +153,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_DOCBOUND { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_DOCBOUND"; CB_POS_SIZE( 2 ); Text [ en-US ] = "Text boundaries"; }; @@ -164,6 +168,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_OBJECTBOUNDARIES { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_OBJECTBOUNDARIES"; CB_POS_SIZE( 4 ); Text [ en-US ] = "Object boundaries"; }; @@ -171,6 +176,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_TABLEBOUNDARIES { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_TABLEBOUNDARIES"; CB_POS_SIZE( 5 ); Text [ en-US ] = "Table boundaries"; }; @@ -185,6 +191,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_LINKS { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_LINKS"; CB_POS_SIZE( 7 ); Text [ en-US ] = "Unvisited links"; }; @@ -192,6 +199,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_LINKSVISITED { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_LINKSVISITED"; CB_POS_SIZE( 8 ); Text [ en-US ] = "Visited links"; }; @@ -233,6 +241,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_WRITERFIELDSHADINGS { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_WRITERFIELDSHADINGS"; CB_POS_SIZE( 14 ); Text [ en-US ] = "Field shadings"; }; @@ -240,6 +249,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_WRITERIDXSHADINGS { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_WRITERIDXSHADINGS"; CB_POS_SIZE( 15 ); Text [ en-US ] = "Index and table shadings"; }; @@ -255,6 +265,7 @@ TabPage RID_SVXPAGE_COLORCONFIG CheckBox CB_WRITERSECTIONBOUNDARIES { + HelpID = "cui:CheckBox:RID_SVXPAGE_COLORCONFIG:CB_WRITERSECTIONBOUNDARIES"; CB_POS_SIZE( 17 ); Text [ en-US ] = "Section boundaries"; }; diff --git a/cui/source/options/optctl.cxx b/cui/source/options/optctl.cxx index 3b2b1111ee46..2589874d1270 100644 --- a/cui/source/options/optctl.cxx +++ b/cui/source/options/optctl.cxx @@ -81,48 +81,48 @@ SfxTabPage* SvxCTLOptionsPage::Create( Window* pParent, const SfxItemSet& rAttrS return new SvxCTLOptionsPage( pParent, rAttrSet ); } // ----------------------------------------------------------------------------- -BOOL SvxCTLOptionsPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxCTLOptionsPage::FillItemSet( SfxItemSet& ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; SvtCTLOptions aCTLOptions; // Sequence checking - BOOL bChecked = m_aSequenceCheckingCB.IsChecked(); + sal_Bool bChecked = m_aSequenceCheckingCB.IsChecked(); if ( bChecked != m_aSequenceCheckingCB.GetSavedValue() ) { aCTLOptions.SetCTLSequenceChecking( bChecked ); - bModified = TRUE; + bModified = sal_True; } bChecked = m_aRestrictedCB.IsChecked(); if( bChecked != m_aRestrictedCB.GetSavedValue() ) { aCTLOptions.SetCTLSequenceCheckingRestricted( bChecked ); - bModified = TRUE; + bModified = sal_True; } bChecked = m_aTypeReplaceCB.IsChecked(); if( bChecked != m_aTypeReplaceCB.GetSavedValue()) { aCTLOptions.SetCTLSequenceCheckingTypeAndReplace(bChecked); - bModified = TRUE; + bModified = sal_True; } - BOOL bLogicalChecked = m_aMovementLogicalRB.IsChecked(); - BOOL bVisualChecked = m_aMovementVisualRB.IsChecked(); + sal_Bool bLogicalChecked = m_aMovementLogicalRB.IsChecked(); + sal_Bool bVisualChecked = m_aMovementVisualRB.IsChecked(); if ( bLogicalChecked != m_aMovementLogicalRB.GetSavedValue() || bVisualChecked != m_aMovementVisualRB.GetSavedValue() ) { SvtCTLOptions::CursorMovement eMovement = bLogicalChecked ? SvtCTLOptions::MOVEMENT_LOGICAL : SvtCTLOptions::MOVEMENT_VISUAL; aCTLOptions.SetCTLCursorMovement( eMovement ); - bModified = TRUE; + bModified = sal_True; } - USHORT nPos = m_aNumeralsLB.GetSelectEntryPos(); + sal_uInt16 nPos = m_aNumeralsLB.GetSelectEntryPos(); if ( nPos != m_aNumeralsLB.GetSavedValue() ) { aCTLOptions.SetCTLTextNumerals( (SvtCTLOptions::TextNumerals)nPos ); - bModified = TRUE; + bModified = sal_True; } return bModified; @@ -151,7 +151,7 @@ void SvxCTLOptionsPage::Reset( const SfxItemSet& ) DBG_ERRORFILE( "SvxCTLOptionsPage::Reset(): invalid movement enum" ); } - USHORT nPos = (USHORT)aCTLOptions.GetCTLTextNumerals(); + sal_uInt16 nPos = (sal_uInt16)aCTLOptions.GetCTLTextNumerals(); DBG_ASSERT( nPos < m_aNumeralsLB.GetEntryCount(), "SvxCTLOptionsPage::Reset(): invalid numerals enum" ); m_aNumeralsLB.SelectEntryPos( nPos ); diff --git a/cui/source/options/optctl.hxx b/cui/source/options/optctl.hxx index a3b455478750..2645e0a85c82 100644 --- a/cui/source/options/optctl.hxx +++ b/cui/source/options/optctl.hxx @@ -61,7 +61,7 @@ public: virtual ~SvxCTLOptionsPage(); static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optctl.src b/cui/source/options/optctl.src index defc62c95011..a9207701fd52 100644 --- a/cui/source/options/optctl.src +++ b/cui/source/options/optctl.src @@ -47,18 +47,21 @@ TabPage RID_SVXPAGE_OPTIONS_CTL }; CheckBox CB_SEQUENCECHECKING { + HelpID = "cui:CheckBox:RID_SVXPAGE_OPTIONS_CTL:CB_SEQUENCECHECKING"; Pos = MAP_APPFONT ( 12, ROW_1 ) ; Size = MAP_APPFONT ( 236 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Use se~quence checking"; }; CheckBox CB_RESTRICTED { + HelpID = "cui:CheckBox:RID_SVXPAGE_OPTIONS_CTL:CB_RESTRICTED"; Pos = MAP_APPFONT ( 18, ROW_2 ); Size = MAP_APPFONT ( 236, RSC_CD_CHECKBOX_HEIGHT ); Text[ en-US ] = "Restricted"; }; CheckBox CB_TYPE_REPLACE { + HelpID = "cui:CheckBox:RID_SVXPAGE_OPTIONS_CTL:CB_TYPE_REPLACE"; Pos = MAP_APPFONT ( 18, ROW_2+RSC_CD_CHECKBOX_HEIGHT+RSC_SP_FLGR_SPACE_Y ); Size = MAP_APPFONT ( 236, RSC_CD_CHECKBOX_HEIGHT ); Text[ en-US ] = "~Type and replace"; @@ -77,12 +80,14 @@ TabPage RID_SVXPAGE_OPTIONS_CTL }; RadioButton RB_MOVEMENT_LOGICAL { + HelpID = "cui:RadioButton:RID_SVXPAGE_OPTIONS_CTL:RB_MOVEMENT_LOGICAL"; Pos = MAP_APPFONT ( 105, ROW_4 ) ; Size = MAP_APPFONT ( 69 , RSC_CD_RADIOBUTTON_HEIGHT ) ; Text [ en-US ] = "Lo~gical"; }; RadioButton RB_MOVEMENT_VISUAL { + HelpID = "cui:RadioButton:RID_SVXPAGE_OPTIONS_CTL:RB_MOVEMENT_VISUAL"; Pos = MAP_APPFONT ( 177, ROW_4 ) ; Size = MAP_APPFONT ( 69 , RSC_CD_RADIOBUTTON_HEIGHT ) ; Text [ en-US ] = "~Visual"; @@ -101,6 +106,7 @@ TabPage RID_SVXPAGE_OPTIONS_CTL }; ListBox LB_NUMERALS { + HelpID = "cui:ListBox:RID_SVXPAGE_OPTIONS_CTL:LB_NUMERALS"; Pos = MAP_APPFONT ( 105, ROW_7 ) ; Size = MAP_APPFONT ( 69 , 3*RSC_CD_DROPDOWN_HEIGHT ) ; DropDown = TRUE ; diff --git a/cui/source/options/optdict.cxx b/cui/source/options/optdict.cxx index 43a88bbe75b5..8eb8916e169d 100644 --- a/cui/source/options/optdict.cxx +++ b/cui/source/options/optdict.cxx @@ -99,12 +99,12 @@ SvxNewDictionaryDialog::SvxNewDictionaryDialog( Window* pParent, ModalDialog( pParent, CUI_RES( RID_SFXDLG_NEWDICT ) ), + aNewDictBox ( this, CUI_RES( GB_NEWDICT ) ), aNameText ( this, CUI_RES( FT_DICTNAME ) ), aNameEdit ( this, CUI_RES( ED_DICTNAME ) ), aLanguageText ( this, CUI_RES( FT_DICTLANG ) ), aLanguageLB ( this, CUI_RES( LB_DICTLANG ) ), aExceptBtn ( this, CUI_RES( BTN_EXCEPT ) ), - aNewDictBox ( this, CUI_RES( GB_NEWDICT ) ), aOKBtn ( this, CUI_RES( BTN_NEWDICT_OK ) ), aCancelBtn ( this, CUI_RES( BTN_NEWDICT_ESC ) ), aHelpBtn ( this, CUI_RES( BTN_NEWDICT_HLP ) ), @@ -116,9 +116,14 @@ SvxNewDictionaryDialog::SvxNewDictionaryDialog( Window* pParent, aOKBtn.SetClickHdl( LINK( this, SvxNewDictionaryDialog, OKHdl_Impl ) ); // Sprachen anzeigen - aLanguageLB.SetLanguageList( LANG_LIST_ALL, TRUE, TRUE ); + aLanguageLB.SetLanguageList( LANG_LIST_ALL, sal_True, sal_True ); aLanguageLB.SelectEntryPos(0); + aNameText.SetAccessibleRelationMemberOf( &aNewDictBox ); + aNameEdit.SetAccessibleRelationMemberOf( &aNewDictBox ); + aLanguageText.SetAccessibleRelationMemberOf( &aNewDictBox ); + aLanguageLB.SetAccessibleRelationMemberOf( &aNewDictBox ); + FreeResource(); } @@ -228,6 +233,7 @@ SvxEditDictionaryDialog::SvxEditDictionaryDialog( aAllDictsLB ( this, CUI_RES( LB_ALLDICTS ) ), aLangFT ( this, CUI_RES( FT_DICTLANG ) ), aLangLB ( this, CUI_RES( LB_DICTLANG ) ), + aWordFT ( this, CUI_RES( FT_WORD ) ), aWordED ( this, CUI_RES( ED_WORD ) ), aReplaceFT ( this, CUI_RES( FT_REPLACE ) ), @@ -236,8 +242,8 @@ SvxEditDictionaryDialog::SvxEditDictionaryDialog( aNewReplacePB ( this, CUI_RES( PB_NEW_REPLACE ) ), aDeletePB ( this, CUI_RES( PB_DELETE_REPLACE ) ), aEditDictsBox ( this, CUI_RES( GB_EDITDICTS ) ), - aCloseBtn ( this, CUI_RES( BTN_EDITCLOSE ) ), aHelpBtn ( this, CUI_RES( BTN_EDITHELP ) ), + aCloseBtn ( this, CUI_RES( BTN_EDITCLOSE ) ), sModify (CUI_RES(STR_MODIFY)), sNew (aNewReplacePB.GetText()), aDecoView ( this), @@ -254,7 +260,7 @@ SvxEditDictionaryDialog::SvxEditDictionaryDialog( aWordsLB.SetTabs(nStaticTabs); //! we use an algorithm of our own to insert elements sorted - aWordsLB.SetWindowBits(/*WB_SORT|*/WB_HSCROLL|WB_CLIPCHILDREN); + aWordsLB.SetStyle(aWordsLB.GetStyle()|/*WB_SORT|*/WB_HSCROLL|WB_CLIPCHILDREN); nWidth=aWordED.GetSizePixel().Width(); @@ -296,7 +302,7 @@ SvxEditDictionaryDialog::SvxEditDictionaryDialog( } } - aLangLB.SetLanguageList( LANG_LIST_ALL, TRUE, TRUE ); + aLangLB.SetLanguageList( LANG_LIST_ALL, sal_True, sal_True ); aReplaceED.SetSpaces(sal_True); aWordED.SetSpaces(sal_True); @@ -380,13 +386,13 @@ void SvxEditDictionaryDialog::SetLanguage_Impl( util::Language nLanguage ) aLangLB.SelectLanguage( nLanguage ); } -USHORT SvxEditDictionaryDialog::GetLBInsertPos(const String &rDicWord) +sal_uInt16 SvxEditDictionaryDialog::GetLBInsertPos(const String &rDicWord) { - USHORT nPos = USHRT_MAX; + sal_uInt16 nPos = USHRT_MAX; IntlWrapper aIntlWrapper( ::comphelper::getProcessServiceFactory(), Application::GetSettings().GetLocale() ); const CollatorWrapper* pCollator = aIntlWrapper.getCollator(); - USHORT j; + sal_uInt16 j; for( j = 0; j < aWordsLB.GetEntryCount(); j++ ) { SvLBoxEntry* pEntry = aWordsLB.GetEntry(j); @@ -451,7 +457,7 @@ IMPL_LINK( SvxEditDictionaryDialog, SelectLangHdl_Impl, ListBox *, EMPTYARG ) sal_uInt16 nDicPos = aAllDictsLB.GetSelectEntryPos(); sal_uInt16 nLang = aLangLB.GetSelectLanguage(); Reference< XDictionary > xDic( aDics.getConstArray()[ nDicPos ], UNO_QUERY ); - INT16 nOldLang = SvxLocaleToLanguage( xDic->getLocale() ); + sal_Int16 nOldLang = SvxLocaleToLanguage( xDic->getLocale() ); if ( nLang != nOldLang ) { @@ -533,7 +539,7 @@ void SvxEditDictionaryDialog::ShowWords_Impl( sal_uInt16 nId ) for (sal_Int32 i = 0; i < nCount; i++) { aStr = String(pEntry[i]->getDictionaryWord()); - USHORT nPos = GetLBInsertPos( aStr ); + sal_uInt16 nPos = GetLBInsertPos( aStr ); if(pEntry[i]->isNegative()) { aStr += '\t'; @@ -687,8 +693,8 @@ IMPL_LINK(SvxEditDictionaryDialog, ModifyHdl, Edit*, pEdt) xub_StrLen nWordLen=rEntry.Len(); const String& rRepString = aReplaceED.GetText(); - BOOL bEnableNewReplace = FALSE; - BOOL bEnableDelete = FALSE; + sal_Bool bEnableNewReplace = sal_False; + sal_Bool bEnableDelete = sal_False; String aNewReplaceText = sNew; if(pEdt == &aWordED) @@ -717,7 +723,7 @@ IMPL_LINK(SvxEditDictionaryDialog, ModifyHdl, Edit*, pEdt) if (CDE_SIMILAR == eCmpRes) { aNewReplaceText = sModify; - bEnableNewReplace = TRUE; + bEnableNewReplace = sal_True; } bFound= sal_True; break; @@ -732,7 +738,7 @@ IMPL_LINK(SvxEditDictionaryDialog, ModifyHdl, Edit*, pEdt) bTmpSelEntry=sal_True; aNewReplaceText = sNew; - bEnableNewReplace = TRUE; + bEnableNewReplace = sal_True; } } @@ -742,7 +748,7 @@ IMPL_LINK(SvxEditDictionaryDialog, ModifyHdl, Edit*, pEdt) pFirstSel = 0; aNewReplaceText = sNew; - bEnableNewReplace = TRUE; + bEnableNewReplace = sal_True; } bEnableDelete = CDE_DIFFERENT != eCmpRes; } @@ -764,13 +770,13 @@ IMPL_LINK(SvxEditDictionaryDialog, ModifyHdl, Edit*, pEdt) aReplaceText = aWordsLB.GetEntryText( pFirstSel, 1 ); aNewReplaceText = sModify; - bEnableDelete = TRUE; + bEnableDelete = sal_True; } - BOOL bIsChange = + sal_Bool bIsChange = CDE_EQUAL != cmpDicEntry_Impl(aWordED.GetText(), aWordText) || CDE_EQUAL != cmpDicEntry_Impl(aReplaceED.GetText(), aReplaceText); if (aWordED.GetText().Len() && bIsChange) - bEnableNewReplace = TRUE; + bEnableNewReplace = sal_True; } aNewReplacePB.SetText( aNewReplaceText ); diff --git a/cui/source/options/optdict.src b/cui/source/options/optdict.src index 1bb0826f6069..c31c95060a13 100644 --- a/cui/source/options/optdict.src +++ b/cui/source/options/optdict.src @@ -49,6 +49,7 @@ ModalDialog RID_SFXDLG_NEWDICT }; Edit ED_DICTNAME { + HelpID = "cui:Edit:RID_SFXDLG_NEWDICT:ED_DICTNAME"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 14 ) ; Size = MAP_APPFONT ( 90 , 12 ) ; @@ -63,6 +64,7 @@ ModalDialog RID_SFXDLG_NEWDICT }; ListBox LB_DICTLANG { + HelpID = "cui:ListBox:RID_SFXDLG_NEWDICT:LB_DICTLANG"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 30 ) ; Size = MAP_APPFONT ( 90 , 66 ) ; @@ -70,6 +72,7 @@ ModalDialog RID_SFXDLG_NEWDICT }; CheckBox BTN_EXCEPT { + HelpID = "cui:CheckBox:RID_SFXDLG_NEWDICT:BTN_EXCEPT"; Pos = MAP_APPFONT ( 12 , 44 ) ; Size = MAP_APPFONT ( 57 , 10 ) ; Text [ en-US ] = "~Exception (-)" ; @@ -118,6 +121,7 @@ ModalDialog RID_SFXDLG_EDITDICT }; ListBox LB_ALLDICTS { + HelpID = "cui:ListBox:RID_SFXDLG_EDITDICT:LB_ALLDICTS"; Border = TRUE ; Pos = MAP_APPFONT ( 82 , 9 ) ; Size = MAP_APPFONT ( 121 , 62 ) ; @@ -131,6 +135,7 @@ ModalDialog RID_SFXDLG_EDITDICT }; ListBox LB_DICTLANG { + HelpID = "cui:ListBox:RID_SFXDLG_EDITDICT:LB_DICTLANG"; Border = TRUE ; Pos = MAP_APPFONT ( 82 , 25 ) ; Size = MAP_APPFONT ( 121 , 66 ) ; @@ -152,6 +157,7 @@ ModalDialog RID_SFXDLG_EDITDICT }; Edit ED_WORD { + HelpID = "cui:Edit:RID_SFXDLG_EDITDICT:ED_WORD"; Pos = MAP_APPFONT ( 12 , 56 ) ; Size = MAP_APPFONT ( 71 , 12 ) ; Border = TRUE ; @@ -166,6 +172,7 @@ ModalDialog RID_SFXDLG_EDITDICT Edit ED_REPLACE { + HelpID = "cui:Edit:RID_SFXDLG_EDITDICT:ED_REPLACE"; Pos = MAP_APPFONT ( 83 , 56 ) ; Size = MAP_APPFONT ( 120 , 12 ) ; Border = TRUE ; @@ -174,6 +181,7 @@ ModalDialog RID_SFXDLG_EDITDICT PushButton PB_NEW_REPLACE { + HelpID = "cui:PushButton:RID_SFXDLG_EDITDICT:PB_NEW_REPLACE"; Pos = MAP_APPFONT ( 209 , 56 ) ; Size = MAP_APPFONT ( 55 , 12 ) ; TabStop = TRUE ; @@ -181,6 +189,7 @@ ModalDialog RID_SFXDLG_EDITDICT }; PushButton PB_DELETE_REPLACE { + HelpID = "cui:PushButton:RID_SFXDLG_EDITDICT:PB_DELETE_REPLACE"; Pos = MAP_APPFONT ( 209 , 71 ) ; Size = MAP_APPFONT ( 55 , 12 ) ; TabStop = TRUE ; diff --git a/cui/source/options/optfltr.cxx b/cui/source/options/optfltr.cxx index eb597b2ca700..a18c791b20c4 100644 --- a/cui/source/options/optfltr.cxx +++ b/cui/source/options/optfltr.cxx @@ -90,11 +90,11 @@ SfxTabPage* OfaMSFilterTabPage::Create( Window* pParent, return new OfaMSFilterTabPage( pParent, rAttrSet ); } -BOOL OfaMSFilterTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaMSFilterTabPage::FillItemSet( SfxItemSet& ) { SvtFilterOptions* pOpt = SvtFilterOptions::Get(); - BOOL bFlag; + sal_Bool bFlag; if( aWBasicCodeCB.GetSavedValue() != (bFlag = aWBasicCodeCB.IsChecked())) pOpt->SetLoadWordBasicCode( bFlag ); if( aWBasicWbctblCB.GetSavedValue() != (bFlag = aWBasicWbctblCB.IsChecked())) @@ -114,7 +114,7 @@ BOOL OfaMSFilterTabPage::FillItemSet( SfxItemSet& ) if( aPBasicStgCB.GetSavedValue() != (bFlag = aPBasicStgCB.IsChecked())) pOpt->SetLoadPPointBasicStorage( bFlag ); - return FALSE; + return sal_False; } void OfaMSFilterTabPage::Reset( const SfxItemSet& ) @@ -169,7 +169,7 @@ OfaMSFilterTabPage2::OfaMSFilterTabPage2( Window* pParent, HIB_CENTER | HIB_VCENTER | HIB_FIXEDPOS | HIB_FIXED ); aCheckLB.SetHelpId( HID_OFAPAGE_MSFLTR2_CLB ); - aCheckLB.SetWindowBits( WB_HSCROLL| WB_VSCROLL ); + aCheckLB.SetStyle( aCheckLB.GetStyle()|WB_HSCROLL| WB_VSCROLL ); } OfaMSFilterTabPage2::~OfaMSFilterTabPage2() @@ -183,14 +183,14 @@ SfxTabPage* OfaMSFilterTabPage2::Create( Window* pParent, return new OfaMSFilterTabPage2( pParent, rAttrSet ); } -BOOL OfaMSFilterTabPage2::FillItemSet( SfxItemSet& ) +sal_Bool OfaMSFilterTabPage2::FillItemSet( SfxItemSet& ) { SvtFilterOptions* pOpt = SvtFilterOptions::Get(); static struct ChkCBoxEntries{ MSFltrPg2_CheckBoxEntries eType; - BOOL (SvtFilterOptions:: *FnIs)() const; - void (SvtFilterOptions:: *FnSet)( BOOL bFlag ); + sal_Bool (SvtFilterOptions:: *FnIs)() const; + void (SvtFilterOptions:: *FnSet)( sal_Bool bFlag ); } aChkArr[] = { { Math, &SvtFilterOptions::IsMathType2Math, &SvtFilterOptions::SetMathType2Math }, @@ -211,18 +211,18 @@ BOOL OfaMSFilterTabPage2::FillItemSet( SfxItemSet& ) { InvalidCBEntry, 0, 0 } }; - BOOL bCheck, bFirst = TRUE; + sal_Bool bCheck, bFirst = sal_True; for( const ChkCBoxEntries* pArr = aChkArr; InvalidCBEntry != pArr->eType; ++pArr, bFirst = !bFirst ) { - USHORT nCol = bFirst ? 1 : 2; + sal_uInt16 nCol = bFirst ? 1 : 2; SvLBoxEntry* pEntry = GetEntry4Type( pArr->eType ); if( pEntry ) { SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem( nCol )); if( pItem && ((SvLBoxItem*)pItem)->IsA() == SV_ITEM_ID_LBOXBUTTON ) { - USHORT nButtonFlags = pItem->GetButtonFlags(); + sal_uInt16 nButtonFlags = pItem->GetButtonFlags(); bCheck = SV_BUTTON_CHECKED == pCheckButtonData->ConvertToButtonState( nButtonFlags ); @@ -232,14 +232,14 @@ BOOL OfaMSFilterTabPage2::FillItemSet( SfxItemSet& ) } } - return TRUE; + return sal_True; } void OfaMSFilterTabPage2::Reset( const SfxItemSet& ) { SvtFilterOptions* pOpt = SvtFilterOptions::Get(); - aCheckLB.SetUpdateMode(FALSE); + aCheckLB.SetUpdateMode(sal_False); aCheckLB.Clear(); SvtModuleOptions aModuleOpt; @@ -256,7 +256,7 @@ void OfaMSFilterTabPage2::Reset( const SfxItemSet& ) static struct ChkCBoxEntries{ MSFltrPg2_CheckBoxEntries eType; - BOOL (SvtFilterOptions:: *FnIs)() const; + sal_Bool (SvtFilterOptions:: *FnIs)() const; } aChkArr[] = { { Math, &SvtFilterOptions::IsMathType2Math }, { Math, &SvtFilterOptions::IsMath2MathType }, @@ -269,11 +269,11 @@ void OfaMSFilterTabPage2::Reset( const SfxItemSet& ) { InvalidCBEntry, NULL } }; - BOOL bFirst = TRUE; + sal_Bool bFirst = sal_True; for( const ChkCBoxEntries* pArr = aChkArr; InvalidCBEntry != pArr->eType; ++pArr, bFirst = !bFirst ) { - USHORT nCol = bFirst ? 1 : 2; + sal_uInt16 nCol = bFirst ? 1 : 2; SvLBoxEntry* pEntry = GetEntry4Type( static_cast< sal_IntPtr >( pArr->eType ) ); if( pEntry ) { @@ -288,7 +288,7 @@ void OfaMSFilterTabPage2::Reset( const SfxItemSet& ) } } } - aCheckLB.SetUpdateMode( TRUE ); + aCheckLB.SetUpdateMode( sal_True ); } void OfaMSFilterTabPage2::InsertEntry( const String& _rTxt, sal_IntPtr _nType ) @@ -324,7 +324,7 @@ SvLBoxEntry* OfaMSFilterTabPage2::GetEntry4Type( sal_IntPtr _nType ) const void OfaMSFilterTabPage2::MSFltrSimpleTable::SetTabs() { SvxSimpleTable::SetTabs(); - USHORT nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; + sal_uInt16 nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; if( aTabs.Count() > 1 ) { @@ -346,7 +346,7 @@ void OfaMSFilterTabPage2::MSFltrSimpleTable::HBarClick() } void OfaMSFilterTabPage2::MSFltrSimpleTable::SetCheckButtonState( - SvLBoxEntry* pEntry, USHORT nCol, SvButtonState eState) + SvLBoxEntry* pEntry, sal_uInt16 nCol, SvButtonState eState) { SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -372,7 +372,7 @@ void OfaMSFilterTabPage2::MSFltrSimpleTable::SetCheckButtonState( } SvButtonState OfaMSFilterTabPage2::MSFltrSimpleTable::GetCheckButtonState( - SvLBoxEntry* pEntry, USHORT nCol ) const + SvLBoxEntry* pEntry, sal_uInt16 nCol ) const { SvButtonState eState = SV_BUTTON_UNCHECKED; SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -380,14 +380,14 @@ SvButtonState OfaMSFilterTabPage2::MSFltrSimpleTable::GetCheckButtonState( if (((SvLBoxItem*)pItem)->IsA() == SV_ITEM_ID_LBOXBUTTON) { - USHORT nButtonFlags = pItem->GetButtonFlags(); + sal_uInt16 nButtonFlags = pItem->GetButtonFlags(); eState = pCheckButtonData->ConvertToButtonState( nButtonFlags ); } return eState; } -void OfaMSFilterTabPage2::MSFltrSimpleTable::CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked) +void OfaMSFilterTabPage2::MSFltrSimpleTable::CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked) { if ( nPos < GetEntryCount() ) SetCheckButtonState( @@ -402,8 +402,8 @@ void OfaMSFilterTabPage2::MSFltrSimpleTable::KeyInput( const KeyEvent& rKEvt ) if(!rKEvt.GetKeyCode().GetModifier() && KEY_SPACE == rKEvt.GetKeyCode().GetCode()) { - ULONG nSelPos = GetModel()->GetAbsPos(GetCurEntry()); - USHORT nCol = GetCurrentTabPos() - 1; + sal_uLong nSelPos = GetModel()->GetAbsPos(GetCurEntry()); + sal_uInt16 nCol = GetCurrentTabPos() - 1; if ( nCol < 2 ) { SvLBoxEntry* pEntry = GetEntry( nSelPos ); @@ -413,7 +413,7 @@ void OfaMSFilterTabPage2::MSFltrSimpleTable::KeyInput( const KeyEvent& rKEvt ) } else { - USHORT nCheck = GetCheckButtonState( GetEntry(nSelPos), 1 ) == SV_BUTTON_CHECKED ? 1 : 0; + sal_uInt16 nCheck = GetCheckButtonState( GetEntry(nSelPos), 1 ) == SV_BUTTON_CHECKED ? 1 : 0; if(GetCheckButtonState( GetEntry(nSelPos), 0 )) nCheck += 2; nCheck--; diff --git a/cui/source/options/optfltr.hxx b/cui/source/options/optfltr.hxx index 466ab25a2c54..f62f92d062b1 100644 --- a/cui/source/options/optfltr.hxx +++ b/cui/source/options/optfltr.hxx @@ -60,7 +60,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -72,9 +72,9 @@ class OfaMSFilterTabPage2 : public SfxTabPage using SvTreeListBox::SetCheckButtonState; using SvxSimpleTable::SetTabs; - void CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked); - SvButtonState GetCheckButtonState( SvLBoxEntry*, USHORT nCol ) const; - void SetCheckButtonState( SvLBoxEntry*, USHORT nCol, SvButtonState ); + void CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked); + SvButtonState GetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol ) const; + void SetCheckButtonState( SvLBoxEntry*, sal_uInt16 nCol, SvButtonState ); protected: virtual void SetTabs(); virtual void HBarClick(); @@ -104,7 +104,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optfltr.src b/cui/source/options/optfltr.src index b586bb454503..b43d034174e2 100644 --- a/cui/source/options/optfltr.src +++ b/cui/source/options/optfltr.src @@ -32,7 +32,7 @@ // RID_OFAPAGE_MSFILTEROPT ----------------------------------------------------- TabPage RID_OFAPAGE_MSFILTEROPT { - // HelpId = ; + HelpID = "cui:TabPage:RID_OFAPAGE_MSFILTEROPT"; OutputSize = TRUE ; Size = MAP_APPFONT ( 260 , 185 ) ; SVLook = TRUE ; @@ -46,6 +46,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_WBAS_CODE { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_WBAS_CODE"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -60,6 +61,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_WBAS_STG { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_WBAS_STG"; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -74,6 +76,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_EBAS_CODE { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_EBAS_CODE"; Pos = MAP_APPFONT ( 12 , 69 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -81,6 +84,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_EBAS_EXECTBL { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_EBAS_EXECTBL"; Pos = MAP_APPFONT ( 22 , 83 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -88,6 +92,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_EBAS_STG { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_EBAS_STG"; Pos = MAP_APPFONT ( 12 , 97 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -102,6 +107,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_PBAS_CODE { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_PBAS_CODE"; Pos = MAP_APPFONT ( 12 , 124 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -109,6 +115,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT }; CheckBox CB_PBAS_STG { + HelpID = "cui:CheckBox:RID_OFAPAGE_MSFILTEROPT:CB_PBAS_STG"; Pos = MAP_APPFONT ( 12 , 138 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -119,7 +126,7 @@ TabPage RID_OFAPAGE_MSFILTEROPT // RID_OFAPAGE_MSFILTEROPT2 ----------------------------------------------------- TabPage RID_OFAPAGE_MSFILTEROPT2 { - // HelpId = ; + HelpID = "cui:TabPage:RID_OFAPAGE_MSFILTEROPT2"; OutputSize = TRUE ; Size = MAP_APPFONT ( 260 , 185 ) ; SVLook = TRUE ; diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx index 138d67e30f39..19bd04500a76 100644 --- a/cui/source/options/optgdlg.cxx +++ b/cui/source/options/optgdlg.cxx @@ -342,7 +342,7 @@ OfaMiscTabPage::OfaMiscTabPage(Window* pParent, const SfxItemSet& rSet ) : "HighContrastWhite" }; - for ( USHORT i = 0; i < aHelpFormatLB.GetEntryCount(); i++ ) + for ( sal_uInt16 i = 0; i < aHelpFormatLB.GetEntryCount(); i++ ) { String* pData = new String( String::CreateFromAscii( aHelpFormatNames[i] ) ); aHelpFormatLB.SetEntryData( i, pData ); @@ -361,7 +361,7 @@ IMPL_LINK( OfaMiscTabPage, OnFileDlgToggled, CheckBox*, EMPTYARG ) OfaMiscTabPage::~OfaMiscTabPage() { - for(USHORT i = 0; i < aHelpFormatLB.GetEntryCount(); i++) + for(sal_uInt16 i = 0; i < aHelpFormatLB.GetEntryCount(); i++) { delete static_cast< String* >( aHelpFormatLB.GetEntryData(i) ); } @@ -376,12 +376,12 @@ SfxTabPage* OfaMiscTabPage::Create( Window* pParent, const SfxItemSet& rAttrSet // ----------------------------------------------------------------------- -BOOL OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; SvtHelpOptions aHelpOptions; - BOOL bChecked = aToolTipsCB.IsChecked(); + sal_Bool bChecked = aToolTipsCB.IsChecked(); if ( bChecked != aToolTipsCB.GetSavedValue() ) aHelpOptions.SetHelpTips( bChecked ); bChecked = ( aExtHelpCB.IsChecked() && aToolTipsCB.IsChecked() ); @@ -390,7 +390,7 @@ BOOL OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) bChecked = aHelpAgentCB.IsChecked(); if ( bChecked != aHelpAgentCB.GetSavedValue() ) aHelpOptions.SetHelpAgentAutoStartMode( bChecked ); - USHORT nHelpFormatPos = aHelpFormatLB.GetSelectEntryPos(); + sal_uInt16 nHelpFormatPos = aHelpFormatLB.GetSelectEntryPos(); if ( nHelpFormatPos != LISTBOX_ENTRY_NOTFOUND && nHelpFormatPos != aHelpFormatLB.GetSavedValue() ) { @@ -401,14 +401,14 @@ BOOL OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) { SvtMiscOptions aMiscOpt; aMiscOpt.SetUseSystemFileDialog( !aFileDlgCB.IsChecked() ); - bModified = TRUE; + bModified = sal_True; } if ( aPrintDlgCB.IsChecked() != aPrintDlgCB.GetSavedValue() ) { SvtMiscOptions aMiscOpt; aMiscOpt.SetUseSystemPrintDialog( !aPrintDlgCB.IsChecked() ); - bModified = TRUE; + bModified = sal_True; } if ( aODMADlgCB.IsChecked() != aODMADlgCB.GetSavedValue() ) @@ -422,7 +422,7 @@ BOOL OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) { SvtPrintWarningOptions aPrintOptions; aPrintOptions.SetModifyDocumentOnPrintingAllowed( aDocStatusCB.IsChecked() ); - bModified = TRUE; + bModified = sal_True; } if ( aSaveAlwaysCB.IsChecked() != aSaveAlwaysCB.GetSavedValue() ) @@ -441,10 +441,10 @@ BOOL OfaMiscTabPage::FillItemSet( SfxItemSet& rSet ) const SfxUInt16Item* pUInt16Item = PTR_CAST( SfxUInt16Item, GetOldItem( rSet, SID_ATTR_YEAR2000 ) ); - USHORT nNum = (USHORT)aYearValueField.GetText().ToInt32(); + sal_uInt16 nNum = (sal_uInt16)aYearValueField.GetText().ToInt32(); if ( pUInt16Item && pUInt16Item->GetValue() != nNum ) { - bModified = TRUE; + bModified = sal_True; rSet.Put( SfxUInt16Item( SID_ATTR_YEAR2000, nNum ) ); } @@ -460,7 +460,7 @@ void OfaMiscTabPage::Reset( const SfxItemSet& rSet ) aExtHelpCB.Check( aHelpOptions.IsHelpTips() && aHelpOptions.IsExtendedHelp() ); aHelpAgentCB.Check( aHelpOptions.IsHelpAgentAutoStartMode() ); String sStyleSheet = aHelpOptions.GetHelpStyleSheet(); - for ( USHORT i = 0; i < aHelpFormatLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aHelpFormatLB.GetEntryCount(); ++i ) { if ( *static_cast< String* >( aHelpFormatLB.GetEntryData(i) ) == sStyleSheet ) { @@ -493,17 +493,17 @@ void OfaMiscTabPage::Reset( const SfxItemSet& rSet ) aDocStatusCB.SaveValue(); const SfxPoolItem* pItem = NULL; - if ( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_YEAR2000, FALSE, &pItem ) ) + if ( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_YEAR2000, sal_False, &pItem ) ) { aYearValueField.SetValue( ((SfxUInt16Item*)pItem)->GetValue() ); TwoFigureConfigHdl( &aYearValueField ); } else { - aYearValueField.Enable(FALSE); - aTwoFigureFL.Enable(FALSE); - aInterpretFT.Enable(FALSE); - aToYearFT.Enable(FALSE); + aYearValueField.Enable(sal_False); + aTwoFigureFL.Enable(sal_False); + aInterpretFT.Enable(sal_False); + aToYearFT.Enable(sal_False); } } @@ -568,24 +568,24 @@ class CanvasSettings public: CanvasSettings(); - BOOL IsHardwareAccelerationEnabled() const; - BOOL IsHardwareAccelerationAvailable() const; - void EnabledHardwareAcceleration( BOOL _bEnabled ) const; + sal_Bool IsHardwareAccelerationEnabled() const; + sal_Bool IsHardwareAccelerationAvailable() const; + void EnabledHardwareAcceleration( sal_Bool _bEnabled ) const; private: typedef std::vector< std::pair<OUString,Sequence<OUString> > > ServiceVector; Reference<XNameAccess> mxForceFlagNameAccess; ServiceVector maAvailableImplementations; - mutable BOOL mbHWAccelAvailable; - mutable BOOL mbHWAccelChecked; + mutable sal_Bool mbHWAccelAvailable; + mutable sal_Bool mbHWAccelChecked; }; // ------------------------------------------------------------------- CanvasSettings::CanvasSettings() : mxForceFlagNameAccess(), - mbHWAccelAvailable(FALSE), - mbHWAccelChecked(FALSE) + mbHWAccelAvailable(sal_False), + mbHWAccelChecked(sal_False) { try { @@ -645,7 +645,7 @@ CanvasSettings::CanvasSettings() : } // ------------------------------------------------------------------- -BOOL CanvasSettings::IsHardwareAccelerationAvailable() const +sal_Bool CanvasSettings::IsHardwareAccelerationAvailable() const { if( !mbHWAccelChecked ) { @@ -691,7 +691,7 @@ BOOL CanvasSettings::IsHardwareAccelerationAvailable() const } // ------------------------------------------------------------------- -BOOL CanvasSettings::IsHardwareAccelerationEnabled() const +sal_Bool CanvasSettings::IsHardwareAccelerationEnabled() const { bool bForceLastEntry(false); if( !mxForceFlagNameAccess.is() ) @@ -704,7 +704,7 @@ BOOL CanvasSettings::IsHardwareAccelerationEnabled() const } // ------------------------------------------------------------------- -void CanvasSettings::EnabledHardwareAcceleration( BOOL _bEnabled ) const +void CanvasSettings::EnabledHardwareAcceleration( sal_Bool _bEnabled ) const { Reference< XNameReplace > xNameReplace( mxForceFlagNameAccess, UNO_QUERY ); @@ -832,8 +832,8 @@ OfaViewTabPage::OfaViewTabPage(Window* pParent, const SfxItemSet& rSet ) : if( ! Application::ValidateSystemFont() ) { - m_aSystemFont.Check( FALSE ); - m_aSystemFont.Enable( FALSE ); + m_aSystemFont.Check( sal_False ); + m_aSystemFont.Enable( sal_False ); } const StyleSettings& aStyleSettings = Application::GetSettings().GetStyleSettings(); @@ -843,8 +843,8 @@ OfaViewTabPage::OfaViewTabPage(Window* pParent, const SfxItemSet& rSet ) : { // do not check 0th item == auto; it is not a real theme aIconStyleItemId[0] = 0; - ULONG nItem = 1; - for ( ULONG n=0; ++n < STYLE_SYMBOLS_THEMES_MAX; ) + sal_uLong nItem = 1; + for ( sal_uLong n=0; ++n < STYLE_SYMBOLS_THEMES_MAX; ) { if ( aStyleSettings.CheckSymbolStyle( n ) ) { @@ -868,7 +868,7 @@ OfaViewTabPage::OfaViewTabPage(Window* pParent, const SfxItemSet& rSet ) : aAutoStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" (") ); // prefer the icon style set by the desktop native widgets modules - ULONG nAutoStyle = aStyleSettings.GetPreferredSymbolsStyle(); + sal_uLong nAutoStyle = aStyleSettings.GetPreferredSymbolsStyle(); // fallback to the statically defined values if ( nAutoStyle == STYLE_SYMBOLS_AUTO || !aIconStyleItemId[nAutoStyle] ) nAutoStyle = aStyleSettings.GetAutoSymbolsStyle(); @@ -918,18 +918,18 @@ SfxTabPage* OfaViewTabPage::Create( Window* pParent, const SfxItemSet& rAttrSet return new OfaViewTabPage(pParent, rAttrSet); } -BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaViewTabPage::FillItemSet( SfxItemSet& ) { SvtFontOptions aFontOpt; SvtMenuOptions aMenuOpt; SvtStartOptions aStartOpt; - BOOL bModified = FALSE; - BOOL bMenuOptModified = FALSE; + sal_Bool bModified = sal_False; + sal_Bool bMenuOptModified = sal_False; bool bRepaintWindows(false); SvtMiscOptions aMiscOptions; - UINT16 nSizeLB_NewSelection = aIconSizeLB.GetSelectEntryPos(); + sal_uInt16 nSizeLB_NewSelection = aIconSizeLB.GetSelectEntryPos(); if( nSizeLB_InitialSelection != nSizeLB_NewSelection ) { // from now on it's modified, even if via auto setting the same size was set as now selected in the LB @@ -945,12 +945,12 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) aMiscOptions.SetSymbolsSize( eSet ); } - UINT16 nStyleLB_NewSelection = aIconStyleLB.GetSelectEntryPos(); + sal_uInt16 nStyleLB_NewSelection = aIconStyleLB.GetSelectEntryPos(); if( nStyleLB_InitialSelection != nStyleLB_NewSelection ) { // find the style name in the aIconStyleItemId table // items from the non-installed icon themes were removed - for ( ULONG n=0; n < STYLE_SYMBOLS_THEMES_MAX; n++ ) + for ( sal_uLong n=0; n < STYLE_SYMBOLS_THEMES_MAX; n++ ) { if ( aIconStyleItemId[n] == nStyleLB_NewSelection ) { @@ -960,17 +960,17 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) } } - BOOL bAppearanceChanged = FALSE; + sal_Bool bAppearanceChanged = sal_False; // Screen Scaling - UINT16 nOldScale = pAppearanceCfg->GetScaleFactor(); - UINT16 nNewScale = (UINT16)aWindowSizeMF.GetValue(); + sal_uInt16 nOldScale = pAppearanceCfg->GetScaleFactor(); + sal_uInt16 nNewScale = (sal_uInt16)aWindowSizeMF.GetValue(); if ( nNewScale != nOldScale ) { pAppearanceCfg->SetScaleFactor(nNewScale); - bAppearanceChanged = TRUE; + bAppearanceChanged = sal_True; } // Mouse Snap Mode @@ -982,7 +982,7 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if ( eNewSnap != eOldSnap ) { pAppearanceCfg->SetSnapMode(eNewSnap ); - bAppearanceChanged = TRUE; + bAppearanceChanged = sal_True; } // Middle Mouse Button @@ -994,41 +994,41 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if ( eNewMiddleMouse != eOldMiddleMouse ) { pAppearanceCfg->SetMiddleMouseButton( eNewMiddleMouse ); - bAppearanceChanged = TRUE; + bAppearanceChanged = sal_True; } #if defined( UNX ) if ( aFontAntiAliasing.IsChecked() != aFontAntiAliasing.GetSavedValue() ) { pAppearanceCfg->SetFontAntiAliasing( aFontAntiAliasing.IsChecked() ); - bAppearanceChanged = TRUE; + bAppearanceChanged = sal_True; } if ( aAAPointLimit.GetValue() != aAAPointLimit.GetSavedValue().ToInt32() ) { pAppearanceCfg->SetFontAntialiasingMinPixelHeight( aAAPointLimit.GetValue() ); - bAppearanceChanged = TRUE; + bAppearanceChanged = sal_True; } #endif if ( aFontShowCB.IsChecked() != aFontShowCB.GetSavedValue() ) { aFontOpt.EnableFontWYSIWYG( aFontShowCB.IsChecked() ); - bModified = TRUE; + bModified = sal_True; } if(aMenuIconsLB.GetSelectEntryPos() != aMenuIconsLB.GetSavedValue()) { aMenuOpt.SetMenuIconsState( aMenuIconsLB.GetSelectEntryPos() == 0 ? 2 : aMenuIconsLB.GetSelectEntryPos() - 1); - bModified = TRUE; - bMenuOptModified = TRUE; - bAppearanceChanged = TRUE; + bModified = sal_True; + bMenuOptModified = sal_True; + bAppearanceChanged = sal_True; } if ( aFontHistoryCB.IsChecked() != aFontHistoryCB.GetSavedValue() ) { aFontOpt.EnableFontHistory( aFontHistoryCB.IsChecked() ); - bModified = TRUE; + bModified = sal_True; } // #i95644# if disabled, do not use value, see in ::Reset() @@ -1037,7 +1037,7 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if(aUseHardwareAccell.IsChecked() != aUseHardwareAccell.GetSavedValue()) { pCanvasSettings->EnabledHardwareAcceleration(aUseHardwareAccell.IsChecked()); - bModified = TRUE; + bModified = sal_True; } } @@ -1047,7 +1047,7 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if(aUseAntiAliase.IsChecked() != mpDrawinglayerOpt->IsAntiAliasing()) { mpDrawinglayerOpt->SetAntiAliasing(aUseAntiAliase.IsChecked()); - bModified = TRUE; + bModified = sal_True; bRepaintWindows = true; } } @@ -1061,7 +1061,7 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if(bNewSelection != (bool)mpDrawinglayerOpt->IsTransparentSelection()) { mpDrawinglayerOpt->SetTransparentSelection(maSelectionCB.IsChecked()); - bModified = TRUE; + bModified = sal_True; bRepaintWindows = true; } @@ -1070,7 +1070,7 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) if(nNewTransparence != mpDrawinglayerOpt->GetTransparentSelectionPercent()) { mpDrawinglayerOpt->SetTransparentSelectionPercent(nNewTransparence); - bModified = TRUE; + bModified = sal_True; bRepaintWindows = true; } } @@ -1080,8 +1080,8 @@ BOOL OfaViewTabPage::FillItemSet( SfxItemSet& ) m_aSystemFont.IsEnabled() ) { aAccessibilityOptions.SetIsSystemFont( m_aSystemFont.IsChecked() ); - bModified = TRUE; - bMenuOptModified = TRUE; + bModified = sal_True; + bMenuOptModified = sal_True; } if( bMenuOptModified ) @@ -1221,43 +1221,6 @@ void OfaViewTabPage::Reset( const SfxItemSet& ) #endif } -class LangConfigItem_Impl : public ConfigItem -{ - Any aValue; - OUString aPropertyName; -public: - LangConfigItem_Impl(const OUString& rTree, const OUString& rProperty); - ~LangConfigItem_Impl(); - - virtual void Commit(); - - const Any& GetValue() const {return aValue;} - void SetValue(Any& rValue) {aValue = rValue; SetModified();} -}; - -LangConfigItem_Impl::LangConfigItem_Impl( - const OUString& rTree, const OUString& rProperty) : - ConfigItem(rTree), - aPropertyName(rProperty) -{ - Sequence<OUString> aNames(1); - aNames.getArray()[0] = aPropertyName; - Sequence<Any> aValues = GetProperties(aNames); - aValue = aValues.getConstArray()[0]; -} - -LangConfigItem_Impl::~LangConfigItem_Impl() -{} - -void LangConfigItem_Impl::Commit() -{ - Sequence<OUString> aNames(1); - aNames.getArray()[0] = aPropertyName; - Sequence<Any> aValues(1); - aValues.getArray()[0] = aValue; - PutProperties(aNames, aValues); -} - struct LanguageConfig_Impl { SvtLanguageOptions aLanguageOptions; @@ -1349,9 +1312,9 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe aLang = MsLangId::convertIsoStringToLanguage(seqInstalledLanguages[i]); if (aLang != LANGUAGE_DONTKNOW) { - //USHORT p = aUserInterfaceLB.InsertLanguage(aLang); + //sal_uInt16 p = aUserInterfaceLB.InsertLanguage(aLang); String aLangStr( pLanguageTable->GetString( aLang ) ); - USHORT p = aUserInterfaceLB.InsertEntry(aLangStr); + sal_uInt16 p = aUserInterfaceLB.InsertEntry(aLangStr); aUserInterfaceLB.SetEntryData(p, (void*)(i+1)); } } @@ -1367,7 +1330,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe if (m_sUserLocaleValue.getLength() > 0) { sal_Int32 d = 0; - for (USHORT i=0; i < aUserInterfaceLB.GetEntryCount(); i++) + for (sal_uInt16 i=0; i < aUserInterfaceLB.GetEntryCount(); i++) { d = (sal_Int32)(sal_IntPtr)aUserInterfaceLB.GetEntryData(i); if ( d > 0 && seqInstalledLanguages.getLength() > d-1 && seqInstalledLanguages[d-1].equals(m_sUserLocaleValue)) @@ -1384,14 +1347,14 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe OSL_ENSURE(sal_False, aMsg.getStr()); } - aWesternLanguageLB.SetLanguageList( LANG_LIST_WESTERN | LANG_LIST_ONLY_KNOWN, TRUE, FALSE, TRUE ); + aWesternLanguageLB.SetLanguageList( LANG_LIST_WESTERN | LANG_LIST_ONLY_KNOWN, sal_True, sal_False, sal_True ); aWesternLanguageLB.InsertDefaultLanguage( ::com::sun::star::i18n::ScriptType::LATIN ); - aAsianLanguageLB.SetLanguageList( LANG_LIST_CJK | LANG_LIST_ONLY_KNOWN, TRUE, FALSE, TRUE ); + aAsianLanguageLB.SetLanguageList( LANG_LIST_CJK | LANG_LIST_ONLY_KNOWN, sal_True, sal_False, sal_True ); aAsianLanguageLB.InsertDefaultLanguage( ::com::sun::star::i18n::ScriptType::ASIAN ); - aComplexLanguageLB.SetLanguageList( LANG_LIST_CTL | LANG_LIST_ONLY_KNOWN, TRUE, FALSE, TRUE ); + aComplexLanguageLB.SetLanguageList( LANG_LIST_CTL | LANG_LIST_ONLY_KNOWN, sal_True, sal_False, sal_True ); aComplexLanguageLB.InsertDefaultLanguage( ::com::sun::star::i18n::ScriptType::COMPLEX ); - aLocaleSettingLB.SetLanguageList( LANG_LIST_ALL | LANG_LIST_ONLY_KNOWN, FALSE, FALSE, FALSE); + aLocaleSettingLB.SetLanguageList( LANG_LIST_ALL | LANG_LIST_ONLY_KNOWN, sal_False, sal_False, sal_False); aLocaleSettingLB.InsertDefaultLanguage( ::com::sun::star::i18n::ScriptType::WEAK ); const NfCurrencyTable& rCurrTab = SvNumberFormatter::GetTheCurrencyTable(); @@ -1403,9 +1366,9 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe aCurrencyLB.InsertEntry( aDefaultCurr ); // all currencies String aTwoSpace( RTL_CONSTASCII_USTRINGPARAM( " " ) ); - USHORT nCurrCount = rCurrTab.Count(); + sal_uInt16 nCurrCount = rCurrTab.Count(); // first entry is SYSTEM, skip it - for ( USHORT j=1; j < nCurrCount; ++j ) + for ( sal_uInt16 j=1; j < nCurrCount; ++j ) { const NfCurrencyEntry* pCurr = rCurrTab[j]; String aStr_( pCurr->GetBankSymbol() ); @@ -1414,7 +1377,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe aStr_ = ApplyLreOrRleEmbedding( aStr_ ); aStr_ += aTwoSpace; aStr_ += ApplyLreOrRleEmbedding( pLanguageTable->GetString( pCurr->GetLanguage() ) ); - USHORT nPos = aCurrencyLB.InsertEntry( aStr_ ); + sal_uInt16 nPos = aCurrencyLB.InsertEntry( aStr_ ); aCurrencyLB.SetEntryData( nPos, (void*) pCurr ); } delete pLanguageTable; @@ -1488,12 +1451,12 @@ void lcl_UpdateAndDelete(SfxVoidItem* pInvalidItems[], SfxBoolItem* pBoolItems[] } } -BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) { // lock configuration broadcasters so that we can coordinate the notifications - pLangConfig->aSysLocaleOptions.BlockBroadcasts( TRUE ); - pLangConfig->aLanguageOptions.BlockBroadcasts( TRUE ); - pLangConfig->aLinguConfig.BlockBroadcasts( TRUE ); + pLangConfig->aSysLocaleOptions.BlockBroadcasts( sal_True ); + pLangConfig->aLanguageOptions.BlockBroadcasts( sal_True ); + pLangConfig->aLinguConfig.BlockBroadcasts( sal_True ); /* * Sequence checking only matters when CTL support is enabled. @@ -1591,7 +1554,7 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) // this will happen after releasing the lock on the ConfigurationBroadcaster at // the end of this method pLangConfig->aSysLocaleOptions.SetLocaleConfigString( sNewLang ); - rSet.Put( SfxBoolItem( SID_OPT_LOCALE_CHANGED, TRUE ) ); + rSet.Put( SfxBoolItem( SID_OPT_LOCALE_CHANGED, sal_True ) ); sal_uInt16 nNewType = SvtLanguageOptions::GetScriptTypeOfLanguage( eNewLocale ); bool bNewCJK = ( nNewType & SCRIPTTYPE_ASIAN ) != 0; @@ -1604,7 +1567,7 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) // Configured currency, for example, USD-en-US or EUR-de-DE, or empty for locale default. OUString sOldCurr = pLangConfig->aSysLocaleOptions.GetCurrencyConfigString(); - USHORT nCurrPos = aCurrencyLB.GetSelectEntryPos(); + sal_uInt16 nCurrPos = aCurrencyLB.GetSelectEntryPos(); const NfCurrencyEntry* pCurr = (const NfCurrencyEntry*) aCurrencyLB.GetEntryData( nCurrPos ); OUString sNewCurr; @@ -1616,12 +1579,12 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) SfxObjectShell* pCurrentDocShell = SfxObjectShell::Current(); Reference< XPropertySet > xLinguProp( LinguMgr::GetLinguPropertySet(), UNO_QUERY ); - BOOL bCurrentDocCBChecked = aCurrentDocCB.IsChecked(); + sal_Bool bCurrentDocCBChecked = aCurrentDocCB.IsChecked(); if(aCurrentDocCB.IsEnabled()) bLanguageCurrentDoc_Impl = bCurrentDocCBChecked; - BOOL bCurrentDocCBChanged = bCurrentDocCBChecked != aCurrentDocCB.GetSavedValue(); + sal_Bool bCurrentDocCBChanged = bCurrentDocCBChecked != aCurrentDocCB.GetSavedValue(); - BOOL bValChanged = aWesternLanguageLB.GetSavedValue() != aWesternLanguageLB.GetSelectEntryPos(); + sal_Bool bValChanged = aWesternLanguageLB.GetSavedValue() != aWesternLanguageLB.GetSelectEntryPos(); if( (bCurrentDocCBChanged && !bCurrentDocCBChecked) || bValChanged) { LanguageType eSelectLang = aWesternLanguageLB.GetSelectLanguage(); @@ -1691,8 +1654,8 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) const sal_uInt16 STATE_COUNT = 2; SfxBoolItem* pBoolItems[STATE_COUNT]; - pBoolItems[0] = new SfxBoolItem(SID_VERTICALTEXT_STATE, FALSE); - pBoolItems[1] = new SfxBoolItem(SID_TEXT_FITTOSIZE_VERTICAL, FALSE); + pBoolItems[0] = new SfxBoolItem(SID_VERTICALTEXT_STATE, sal_False); + pBoolItems[1] = new SfxBoolItem(SID_TEXT_FITTOSIZE_VERTICAL, sal_False); SfxVoidItem* pInvalidItems[STATE_COUNT]; pInvalidItems[0] = new SfxVoidItem(SID_VERTICALTEXT_STATE); @@ -1707,7 +1670,7 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) const sal_uInt16 STATE_COUNT = 1; SfxBoolItem* pBoolItems[STATE_COUNT]; - pBoolItems[0] = new SfxBoolItem(SID_CTLFONT_STATE, FALSE); + pBoolItems[0] = new SfxBoolItem(SID_CTLFONT_STATE, sal_False); SfxVoidItem* pInvalidItems[STATE_COUNT]; pInvalidItems[0] = new SfxVoidItem(SID_CTLFONT_STATE); lcl_UpdateAndDelete(pInvalidItems, pBoolItems, STATE_COUNT); @@ -1719,11 +1682,11 @@ BOOL OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet ) // first release the lock on the ConfigurationBroadcaster for Locale changes // it seems that our code relies on the fact that before other changes like e.g. currency // are broadcasted locale changes have been done - pLangConfig->aSysLocaleOptions.BlockBroadcasts( FALSE ); - pLangConfig->aLanguageOptions.BlockBroadcasts( FALSE ); - pLangConfig->aLinguConfig.BlockBroadcasts( FALSE ); + pLangConfig->aSysLocaleOptions.BlockBroadcasts( sal_False ); + pLangConfig->aLanguageOptions.BlockBroadcasts( sal_False ); + pLangConfig->aLinguConfig.BlockBroadcasts( sal_False ); - return FALSE; + return sal_False; } //----------------------------------------------------------------------------- void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet ) @@ -1758,7 +1721,7 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet ) pCurr = SvNumberFormatter::GetCurrencyEntry( aAbbrev, eLang ); } // if pCurr==NULL the SYSTEM entry is selected - USHORT nPos = aCurrencyLB.GetEntryPos( (void*) pCurr ); + sal_uInt16 nPos = aCurrencyLB.GetEntryPos( (void*) pCurr ); aCurrencyLB.SelectEntryPos( nPos ); bReadonly = pLangConfig->aSysLocaleOptions.IsReadOnly(SvtSysLocaleOptions::E_CURRENCY); aCurrencyLB.Enable(!bReadonly); @@ -1771,7 +1734,7 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet ) LanguageType eCurLangCTL = LANGUAGE_NONE; SfxObjectShell* pCurrentDocShell = SfxObjectShell::Current(); //collect the configuration values first - aCurrentDocCB.Enable(FALSE); + aCurrentDocCB.Enable(sal_False); // Any aWestLang; Any aCJKLang; @@ -1800,24 +1763,24 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet ) //overwrite them by the values provided by the DocShell if(pCurrentDocShell) { - aCurrentDocCB.Enable(TRUE); + aCurrentDocCB.Enable(sal_True); aCurrentDocCB.Check(bLanguageCurrentDoc_Impl); const SfxPoolItem* pLang; - if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_LANGUAGE, FALSE, &pLang)) + if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_LANGUAGE, sal_False, &pLang)) { LanguageType eTempCurLang = ((const SvxLanguageItem*)pLang)->GetValue(); if (MsLangId::resolveSystemLanguageByScriptType(eCurLang, ::com::sun::star::i18n::ScriptType::LATIN) != eTempCurLang) eCurLang = eTempCurLang; } - if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_CHAR_CJK_LANGUAGE, FALSE, &pLang)) + if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_CHAR_CJK_LANGUAGE, sal_False, &pLang)) { LanguageType eTempCurLang = ((const SvxLanguageItem*)pLang)->GetValue(); if (MsLangId::resolveSystemLanguageByScriptType(eCurLangCJK, ::com::sun::star::i18n::ScriptType::ASIAN) != eTempCurLang) eCurLangCJK = eTempCurLang; } - if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_CHAR_CTL_LANGUAGE, FALSE, &pLang)) + if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_CHAR_CTL_LANGUAGE, sal_False, &pLang)) { LanguageType eTempCurLang = ((const SvxLanguageItem*)pLang)->GetValue(); if (MsLangId::resolveSystemLanguageByScriptType(eCurLangCTL, ::com::sun::star::i18n::ScriptType::COMPLEX) != eTempCurLang) @@ -1864,11 +1827,11 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet ) // check the box "For the current document only" // set the focus to the Western Language box const SfxPoolItem* pLang = 0; - if ( SFX_ITEM_SET == rSet.GetItemState(SID_SET_DOCUMENT_LANGUAGE, FALSE, &pLang ) &&( (const SfxBoolItem*)pLang)->GetValue() == TRUE ) + if ( SFX_ITEM_SET == rSet.GetItemState(SID_SET_DOCUMENT_LANGUAGE, sal_False, &pLang ) &&( (const SfxBoolItem*)pLang)->GetValue() == sal_True ) { aWesternLanguageLB.GrabFocus(); - aCurrentDocCB.Enable(TRUE); - aCurrentDocCB.Check(TRUE); + aCurrentDocCB.Enable(sal_True); + aCurrentDocCB.Check(sal_True); } } @@ -1910,7 +1873,7 @@ namespace void lcl_checkLanguageCheckBox(CheckBox& _rCB,sal_Bool _bNewValue,sal_Bool _bOldValue) { if ( _bNewValue ) - _rCB.Check(TRUE); + _rCB.Check(sal_True); else _rCB.Check( _bOldValue ); // #i15082# do not call SaveValue() in running dialog... @@ -1940,7 +1903,7 @@ IMPL_LINK( OfaLanguagesTabPage, LocaleSettingHdl, SvxLanguageBox*, pBox ) SupportHdl( &aAsianSupportCB ); } - USHORT nPos; + sal_uInt16 nPos; if ( eLang == LANGUAGE_SYSTEM ) nPos = aCurrencyLB.GetEntryPos( (void*) NULL ); else diff --git a/cui/source/options/optgdlg.hxx b/cui/source/options/optgdlg.hxx index 6db4f285414d..d875100a7236 100644 --- a/cui/source/options/optgdlg.hxx +++ b/cui/source/options/optgdlg.hxx @@ -91,7 +91,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -139,13 +139,13 @@ private: CheckBox maSelectionCB; MetricField maSelectionMF; - UINT16 nSizeLB_InitialSelection; - UINT16 nStyleLB_InitialSelection; - BOOL bSfxSymbolsAuto; + sal_uInt16 nSizeLB_InitialSelection; + sal_uInt16 nStyleLB_InitialSelection; + sal_Bool bSfxSymbolsAuto; // item ID for the given icon theme // might be zero when the theme is not installed and the item is removed - ULONG aIconStyleItemId[STYLE_SYMBOLS_THEMES_MAX]; + sal_uLong aIconStyleItemId[STYLE_SYMBOLS_THEMES_MAX]; SvtTabAppearanceCfg* pAppearanceCfg; CanvasSettings* pCanvasSettings; SvtOptionsDrawinglayer* mpDrawinglayerOpt; @@ -162,7 +162,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -215,7 +215,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; #endif // #ifndef _OFA_OPTGDLG_HXX diff --git a/cui/source/options/optgdlg.src b/cui/source/options/optgdlg.src index 1d5971ccad32..1f26e3e982d6 100644 --- a/cui/source/options/optgdlg.src +++ b/cui/source/options/optgdlg.src @@ -50,12 +50,14 @@ TabPage OFA_TP_MISC }; CheckBox CB_TOOLTIP { + HelpID = "cui:CheckBox:OFA_TP_MISC:CB_TOOLTIP"; Pos = MAP_APPFONT( COL1, ROW1 ); Size = MAP_APPFONT( COL3 - COL1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "~Tips"; }; CheckBox CB_EXTHELP { + HelpID = "cui:CheckBox:OFA_TP_MISC:CB_EXTHELP"; Pos = MAP_APPFONT( COL3, ROW1 ); Size = MAP_APPFONT( WHOLE_WIDTH - COL3, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "~Extended tips"; @@ -69,6 +71,7 @@ TabPage OFA_TP_MISC }; ListBox LB_HELPFORMAT { + HelpID = "cui:ListBox:OFA_TP_MISC:LB_HELPFORMAT"; Pos = MAP_APPFONT( COL3, ROW2 ); Size = MAP_APPFONT( WHOLE_WIDTH - COL4, 50 ); DropDown = TRUE ; @@ -86,12 +89,14 @@ TabPage OFA_TP_MISC #endif CheckBox CB_HELPAGENT { + HelpID = "cui:CheckBox:OFA_TP_MISC:CB_HELPAGENT"; Pos = MAP_APPFONT( COL1, ROW3 ); Size = MAP_APPFONT( COL3 - COL1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "~Help Agent"; }; PushButton PB_HELPAGENT_RESET { + HelpID = "cui:PushButton:OFA_TP_MISC:PB_HELPAGENT_RESET"; Pos = MAP_APPFONT( COL3, ROW3 ); Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH + 20, RSC_CD_PUSHBUTTON_HEIGHT ); Text [ en-US ] = "~Reset Help Agent"; @@ -110,6 +115,7 @@ TabPage OFA_TP_MISC }; CheckBox CB_FILEDLG { + HelpID = "cui:CheckBox:OFA_TP_MISC:CB_FILEDLG"; Pos = MAP_APPFONT( COL1, ROW5 ); Size = MAP_APPFONT( WHOLE_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "~Use %PRODUCTNAME dialogs"; @@ -141,6 +147,7 @@ TabPage OFA_TP_MISC }; CheckBox CB_DOCSTATUS { + HelpID = "cui:CheckBox:OFA_TP_MISC:CB_DOCSTATUS"; Pos = MAP_APPFONT( COL1, ROW10 ); Size = MAP_APPFONT( WHOLE_WIDTH - COL1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "~Printing sets \"document modified\" status"; @@ -165,6 +172,7 @@ TabPage OFA_TP_MISC }; NumericField NF_YEARVALUE { + HelpID = "cui:NumericField:OFA_TP_MISC:NF_YEARVALUE"; Border = TRUE ; Pos = MAP_APPFONT( COL4, ROW13 ); Size = MAP_APPFONT( EDIT_WIDTH, RSC_CD_TEXTBOX_HEIGHT ); @@ -213,6 +221,7 @@ TabPage OFA_TP_VIEW }; MetricField MF_WINDOWSIZE { + HelpID = "cui:MetricField:OFA_TP_VIEW:MF_WINDOWSIZE"; Pos = MAP_APPFONT ( 95 , ROW_MF_SCALING ) ; Size = MAP_APPFONT ( 31 , 12 ) ; Border = TRUE ; @@ -241,6 +250,7 @@ TabPage OFA_TP_VIEW }; ListBox LB_ICONSIZE { + HelpID = "cui:ListBox:OFA_TP_VIEW:LB_ICONSIZE"; Pos = MAP_APPFONT ( 12 , ROW_LB_ICONSIZESTYLE ) ; Size = MAP_APPFONT ( 45 , 60 ) ; DropDown = TRUE ; @@ -255,6 +265,7 @@ TabPage OFA_TP_VIEW }; ListBox LB_ICONSTYLE { + HelpID = "cui:ListBox:OFA_TP_VIEW:LB_ICONSTYLE"; Pos = MAP_APPFONT ( 61 , ROW_LB_ICONSIZESTYLE ) ; Size = MAP_APPFONT ( 65 , 70 ) ; DropDown = TRUE ; @@ -275,6 +286,7 @@ TabPage OFA_TP_VIEW }; CheckBox CB_SYSTEM_FONT { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_SYSTEM_FONT"; TabStop = TRUE ; Pos = MAP_APPFONT( 12, ROW_CB_SYSTEM_FONT ); Size = MAP_APPFONT( 114, 16 ); @@ -284,6 +296,7 @@ TabPage OFA_TP_VIEW CheckBox CB_FONTANTIALIASING { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_FONTANTIALIASING"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , ROW_CB_FONTANTIALIASING ) ; Size = MAP_APPFONT ( 110 , RSC_CD_CHECKBOX_HEIGHT ) ; @@ -297,6 +310,7 @@ TabPage OFA_TP_VIEW }; NumericField NF_AA_POINTLIMIT { + HelpID = "cui:NumericField:OFA_TP_VIEW:NF_AA_POINTLIMIT"; Border = TRUE ; Pos = MAP_APPFONT ( 46, ROW_NF_AA_POINTLIMIT ) ; Size = MAP_APPFONT ( 30 , 12 ) ; @@ -326,6 +340,7 @@ TabPage OFA_TP_VIEW }; ListBox LB_MENU_ICONS { + HelpID = "cui:ListBox:OFA_TP_VIEW:LB_MENU_ICONS"; Pos = MAP_APPFONT ( 12 , ROW_LB_MENU_ICONS ) ; Size = MAP_APPFONT ( 114 , 60 ) ; DropDown = TRUE ; @@ -346,12 +361,14 @@ TabPage OFA_TP_VIEW }; CheckBox CB_FONT_SHOW { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_FONT_SHOW"; Pos = MAP_APPFONT ( 12, ROW_CB_FONT_SHOW ) ; Size = MAP_APPFONT ( 118 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Show p~review of fonts" ; }; CheckBox CB_FONT_HISTORY { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_FONT_HISTORY"; Pos = MAP_APPFONT ( 12, ROW_CB_FONT_HISTORY ) ; Size = MAP_APPFONT ( 118 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Show font h~istory" ; @@ -365,6 +382,7 @@ TabPage OFA_TP_VIEW CheckBox CB_USE_HARDACCELL { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_USE_HARDACCELL"; Pos = MAP_APPFONT ( 139, ROW_CB_USE_HARDACCELL ) ; Size = MAP_APPFONT ( 118 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Use hardware acceleration" ; @@ -372,6 +390,7 @@ TabPage OFA_TP_VIEW CheckBox CB_USE_ANTIALIASE { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_USE_ANTIALIASE"; Pos = MAP_APPFONT ( 139, ROW_CB_USE_ANTIALIASE ) ; Size = MAP_APPFONT ( 118 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Use Anti-Aliasing" ; @@ -391,6 +410,7 @@ TabPage OFA_TP_VIEW }; ListBox LB_MOUSEPOS { + HelpID = "cui:ListBox:OFA_TP_VIEW:LB_MOUSEPOS"; Pos = MAP_APPFONT ( 139, ROW_LB_MOUSEPOS ) ; Size = MAP_APPFONT ( 114 , 60 ) ; DropDown = TRUE ; @@ -411,6 +431,7 @@ TabPage OFA_TP_VIEW }; ListBox LB_MOUSEMIDDLE { + HelpID = "cui:ListBox:OFA_TP_VIEW:LB_MOUSEMIDDLE"; Pos = MAP_APPFONT ( 139, ROW_LB_MOUSEMIDDLE ) ; Size = MAP_APPFONT ( 114 , 60 ) ; DropDown = TRUE ; @@ -434,6 +455,7 @@ TabPage OFA_TP_VIEW CheckBox CB_SELECTION { + HelpID = "cui:CheckBox:OFA_TP_VIEW:CB_SELECTION"; Pos = MAP_APPFONT ( 139, ROW_CB_SELECTION + (((12 - RSC_CD_CHECKBOX_HEIGHT) / 2) + 1)) ; Size = MAP_APPFONT ( 118 - 34 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Transparency" ; @@ -441,6 +463,7 @@ TabPage OFA_TP_VIEW MetricField MF_SELECTION { + HelpID = "cui:MetricField:OFA_TP_VIEW:MF_SELECTION"; Pos = MAP_APPFONT ( 139 + (95 - 12), ROW_CB_SELECTION ) ; Size = MAP_APPFONT ( 31 , 12 ) ; Border = TRUE ; @@ -485,6 +508,7 @@ TabPage OFA_TP_LANGUAGES }; ListBox LB_USERINTERFACE { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_USERINTERFACE"; Pos = MAP_APPFONT ( 123 , 14 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -506,6 +530,7 @@ TabPage OFA_TP_LANGUAGES }; ListBox LB_LOCALESETTING { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_LOCALESETTING"; Pos = MAP_APPFONT ( 123 , 30 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -521,6 +546,7 @@ TabPage OFA_TP_LANGUAGES }; CheckBox CB_DECIMALSEPARATOR { + HelpID = "cui:CheckBox:OFA_TP_LANGUAGES:CB_DECIMALSEPARATOR"; Pos = MAP_APPFONT ( 123 , 46) ; Size = MAP_APPFONT ( 125 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "~Same as locale setting ( %1 )"; @@ -539,6 +565,7 @@ TabPage OFA_TP_LANGUAGES }; ListBox LB_CURRENCY { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_CURRENCY"; Pos = MAP_APPFONT ( 123 , 59 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -567,6 +594,7 @@ TabPage OFA_TP_LANGUAGES ListBox LB_WEST_LANG { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_WEST_LANG"; Pos = MAP_APPFONT ( 123 , 88 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -588,6 +616,7 @@ TabPage OFA_TP_LANGUAGES }; ListBox LB_ASIAN_LANG { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_ASIAN_LANG"; Pos = MAP_APPFONT ( 123 , 104 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -609,6 +638,7 @@ TabPage OFA_TP_LANGUAGES }; ListBox LB_COMPLEX_LANG { + HelpID = "cui:ListBox:OFA_TP_LANGUAGES:LB_COMPLEX_LANG"; Pos = MAP_APPFONT ( 123 , 120 ) ; Size = MAP_APPFONT ( 125 , 60 ) ; DropDown = TRUE ; @@ -618,6 +648,7 @@ TabPage OFA_TP_LANGUAGES }; CheckBox CB_CURRENT_DOC { + HelpID = "cui:CheckBox:OFA_TP_LANGUAGES:CB_CURRENT_DOC"; Pos = MAP_APPFONT ( 123 , 135 ) ; Size = MAP_APPFONT ( 125 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "For the current document only"; @@ -636,6 +667,7 @@ TabPage OFA_TP_LANGUAGES }; CheckBox CB_ASIANSUPPORT { + HelpID = "cui:CheckBox:OFA_TP_LANGUAGES:CB_ASIANSUPPORT"; Pos = MAP_APPFONT ( 12 , 158 ) ; Size = MAP_APPFONT ( 236 ,RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "E~nabled for Asian languages"; @@ -648,6 +680,7 @@ TabPage OFA_TP_LANGUAGES }; CheckBox CB_CTLSUPPORT { + HelpID = "cui:CheckBox:OFA_TP_LANGUAGES:CB_CTLSUPPORT"; Pos = MAP_APPFONT ( 12 , 173 ) ; Size = MAP_APPFONT ( 236 , RSC_CD_CHECKBOX_HEIGHT ) ; Text [ en-US ] = "Ena~bled for complex text layout (CTL)"; diff --git a/cui/source/options/optgenrl.cxx b/cui/source/options/optgenrl.cxx index c66b571632c4..75fbb3933b3d 100644 --- a/cui/source/options/optgenrl.cxx +++ b/cui/source/options/optgenrl.cxx @@ -50,43 +50,24 @@ struct GeneralTabPage_Impl { - BOOL mbStreetEnabled; - BOOL mbPLZEnabled; - BOOL mbCityEnabled; - BOOL mbUsCityEnabled; - BOOL mbUsZipEnabled; + sal_Bool mbStreetEnabled; + sal_Bool mbPLZEnabled; + sal_Bool mbCityEnabled; + sal_Bool mbUsCityEnabled; + sal_Bool mbUsZipEnabled; String maQueryStr; GeneralTabPage_Impl() : - mbStreetEnabled ( FALSE ), - mbPLZEnabled ( FALSE ), - mbCityEnabled ( FALSE ), - mbUsCityEnabled ( FALSE ), - mbUsZipEnabled ( FALSE ) {} + mbStreetEnabled ( sal_False ), + mbPLZEnabled ( sal_False ), + mbCityEnabled ( sal_False ), + mbUsCityEnabled ( sal_False ), + mbUsZipEnabled ( sal_False ) {} }; // ----------------------------------------------------------------------- -// kommt aus adritem.cxx -//copy from adritem.cxx, since it will leave in svx. -String ConvertToStore_Impl( const String& rText ) -{ - String sRet; - USHORT i = 0; - - while ( i < rText.Len() ) - { - if ( rText.GetChar(i) == '\\' || rText.GetChar(i) == '#' ) - sRet += '\\'; - sRet += rText.GetChar(i++); - } - return sRet; -} - - -// ----------------------------------------------------------------------- - SvxGeneralTabPage::SvxGeneralTabPage( Window* pParent, const SfxItemSet& rCoreSet ) : SfxTabPage( pParent, CUI_RES(RID_SFXPAGE_GENERAL), rCoreSet ), @@ -261,7 +242,7 @@ SfxTabPage* SvxGeneralTabPage::Create( Window* pParent, const SfxItemSet& rAttrS //------------------------------------------------------------------------ -BOOL SvxGeneralTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxGeneralTabPage::FillItemSet( SfxItemSet& ) { // Eingaben trimmen (f"uhrende und nachfolgende Leerzeichen entfernen) aCompanyEdit.SetText( TRIM(aCompanyEdit.GetText()) ); @@ -282,13 +263,13 @@ BOOL SvxGeneralTabPage::FillItemSet( SfxItemSet& ) aFaxEdit.SetText( TRIM(aFaxEdit.GetText()) ); aEmailEdit.SetText( TRIM(aEmailEdit.GetText()) ); - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; bModified |= GetAddress_Impl(); SvtSaveOptions aSaveOpt; if ( aUseDataCB.IsChecked() != aSaveOpt.IsUseUserData() ) { aSaveOpt.SetUseUserData( aUseDataCB.IsChecked() ); - bModified |= TRUE; + bModified |= sal_True; } return bModified; } @@ -299,10 +280,10 @@ void SvxGeneralTabPage::Reset( const SfxItemSet& rSet ) { SetAddress_Impl(); - USHORT nWhich = GetWhich( SID_FIELD_GRABFOCUS ); + sal_uInt16 nWhich = GetWhich( SID_FIELD_GRABFOCUS ); if ( rSet.GetItemState( nWhich ) == SFX_ITEM_SET ) { - USHORT nField = ( (SfxUInt16Item&)rSet.Get( nWhich ) ).GetValue(); + sal_uInt16 nField = ( (SfxUInt16Item&)rSet.Get( nWhich ) ).GetValue(); switch ( nField ) { @@ -361,7 +342,7 @@ IMPL_LINK( SvxGeneralTabPage, ModifyHdl_Impl, Edit *, pEdit ) break; } - USHORT nPos = ( pEdit == &aFirstName ) ? 0 : 1; + sal_uInt16 nPos = ( pEdit == &aFirstName ) ? 0 : 1; String aTxt = pEdit->GetText(); sal_Unicode cChar = ( aTxt.Len() > 0 ) ? aTxt.GetChar(0) : ' '; aShortStr.SetChar( nPos, cChar ); @@ -375,7 +356,7 @@ IMPL_LINK( SvxGeneralTabPage, ModifyHdl_Impl, Edit *, pEdit ) sal_Bool SvxGeneralTabPage::GetAddress_Impl() { - BOOL bRet = + sal_Bool bRet = ( aCompanyEdit.GetSavedValue() != aCompanyEdit.GetText() || aFirstName.GetSavedValue() != aFirstName.GetText() || aFatherName.GetSavedValue() != aFatherName.GetText() || @@ -397,7 +378,7 @@ sal_Bool SvxGeneralTabPage::GetAddress_Impl() aEmailEdit.GetSavedValue() != aEmailEdit.GetText() ); LanguageType eLang = Application::GetSettings().GetUILanguage(); - BOOL bUS = ( LANGUAGE_ENGLISH_US == eLang ); + sal_Bool bUS = ( LANGUAGE_ENGLISH_US == eLang ); SvtUserOptions aUserOpt; aUserOpt.SetCompany(aCompanyEdit.GetText()); @@ -433,7 +414,7 @@ sal_Bool SvxGeneralTabPage::GetAddress_Impl() void SvxGeneralTabPage::SetAddress_Impl() { LanguageType eLang = Application::GetSettings().GetUILanguage(); - BOOL bUS = ( LANGUAGE_ENGLISH_US == eLang ); + sal_Bool bUS = ( LANGUAGE_ENGLISH_US == eLang ); SvtUserOptions aUserOpt; aCompanyEdit.SetText( aUserOpt.GetCompany() ); if ( aUserOpt.IsTokenReadonly( USER_OPT_COMPANY ) ) diff --git a/cui/source/options/optgenrl.src b/cui/source/options/optgenrl.src index 6f5fff55892d..bc5721024c1a 100644 --- a/cui/source/options/optgenrl.src +++ b/cui/source/options/optgenrl.src @@ -52,6 +52,7 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_COMPANY { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_COMPANY"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 0 ) ) ; Size = MAP_APPFONT ( RIGHT-MID , LINEH ) ; @@ -81,6 +82,7 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_FATHERNAME { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_FATHERNAME"; Border = TRUE ; Hide = TRUE; Pos = MAP_APPFONT ( MID , LINE ( 1 ) ) ; @@ -88,18 +90,21 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_FIRSTNAME { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_FIRSTNAME"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 1 ) ) ; Size = MAP_APPFONT ( NAMELEN-8 , LINEH ) ; }; Edit ED_NAME { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( MID+NAMELEN-8+HSPACE , LINE ( 1 ) ) ; Size = MAP_APPFONT ( NAMELEN-8 , LINEH ) ; }; Edit ED_SHORTNAME { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_SHORTNAME"; Border = TRUE ; Pos = MAP_APPFONT ( MID+2* ( NAMELEN-8+HSPACE ) , LINE ( 1 ) ) ; Size = MAP_APPFONT ( RIGHT- ( MID+2* ( NAMELEN-8+HSPACE ) ) , LINEH ) ; @@ -121,12 +126,14 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_STREET { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_STREET"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 2 ) ) ; Size = MAP_APPFONT ( RIGHT-MID , LINEH ) ; }; Edit ED_APARTMENTNR { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_APARTMENTNR"; Border = TRUE ; Hide = TRUE; Pos = MAP_APPFONT ( MID , LINE ( 2 ) ) ; @@ -141,30 +148,35 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_PLZ { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_PLZ"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 3 ) ) ; Size = MAP_APPFONT ( 24 , LINEH ) ; }; Edit ED_CITY { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_CITY"; Border = TRUE ; Pos = MAP_APPFONT ( MID + 24 + HSPACE , LINE ( 3 ) ) ; Size = MAP_APPFONT ( RIGHT - ( MID + 24 + HSPACE ) , LINEH ) ; }; Edit ED_US_CITY { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_US_CITY"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 3 ) ) ; Size = MAP_APPFONT ( 90 , LINEH ) ; }; Edit ED_US_STATE { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_US_STATE"; Border = TRUE ; Pos = MAP_APPFONT ( MID + 90 + HSPACE, LINE ( 3 ) ) ; Size = MAP_APPFONT ( 30 , LINEH ) ; }; Edit ED_US_ZIPCODE { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_US_ZIPCODE"; Border = TRUE ; Pos = MAP_APPFONT ( MID + 90 + HSPACE + 30 + HSPACE, LINE ( 3 ) ) ; Size = MAP_APPFONT ( RIGHT - ( MID + 90 + HSPACE + 30 + HSPACE ) , LINEH ) ; @@ -178,6 +190,7 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_COUNTRY { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_COUNTRY"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 4 ) ) ; Size = MAP_APPFONT ( RIGHT - MID , LINEH ) ; @@ -191,12 +204,14 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_TITLE { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_TITLE"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 5 ) ) ; Size = MAP_APPFONT ( NAMELEN-1 , LINEH ) ; }; Edit ED_POSITION { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_POSITION"; Border = TRUE ; Pos = MAP_APPFONT ( MID+NAMELEN-1+HSPACE , LINE ( 5 ) ) ; Size = MAP_APPFONT ( RIGHT- ( MID+NAMELEN-1+HSPACE ) , LINEH ) ; @@ -210,12 +225,14 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_TELPRIVAT { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_TELPRIVAT"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 6 ) ) ; Size = MAP_APPFONT ( NAMELEN-1 , LINEH ) ; }; Edit ED_TELCOMPANY { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_TELCOMPANY"; Border = TRUE ; Pos = MAP_APPFONT ( MID+NAMELEN-1+HSPACE , LINE ( 6 ) ) ; Size = MAP_APPFONT ( RIGHT- ( MID+NAMELEN-1+HSPACE ) , LINEH ) ; @@ -229,12 +246,14 @@ TabPage RID_SFXPAGE_GENERAL }; Edit ED_FAX { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_FAX"; Border = TRUE ; Pos = MAP_APPFONT ( MID , LINE ( 7 ) ) ; Size = MAP_APPFONT ( NAMELEN-1 , LINEH ) ; }; Edit ED_EMAIL { + HelpID = "cui:Edit:RID_SFXPAGE_GENERAL:ED_EMAIL"; Border = TRUE ; Pos = MAP_APPFONT ( MID+NAMELEN-1+HSPACE , LINE ( 7 ) ) ; Size = MAP_APPFONT ( RIGHT- ( MID+NAMELEN-1+HSPACE ) , LINEH ) ; @@ -247,6 +266,7 @@ TabPage RID_SFXPAGE_GENERAL }; CheckBox CB_USEDATA { + HelpID = "cui:CheckBox:RID_SFXPAGE_GENERAL:CB_USEDATA"; Pos = MAP_APPFONT ( 6 , 122 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Hide = TRUE; diff --git a/cui/source/options/opthtml.cxx b/cui/source/options/opthtml.cxx index 226fb8e7988f..8dcdb124e088 100644 --- a/cui/source/options/opthtml.cxx +++ b/cui/source/options/opthtml.cxx @@ -38,7 +38,7 @@ #include <sal/macros.h> // Umwandlung der Modi zu den Positionen in der Listbox -const USHORT aPosToExportArr[] = +const sal_uInt16 aPosToExportArr[] = { HTML_CFG_HTML32, HTML_CFG_MSIE_40, @@ -48,7 +48,7 @@ const USHORT aPosToExportArr[] = //#define DEPRECATED_ENTRY 0xFFFF -const USHORT aExportToPosArr[] = +const sal_uInt16 aExportToPosArr[] = { 0, //HTML 3.2 1, //MS Internet Explorer 4.0 @@ -122,23 +122,23 @@ SfxTabPage* OfaHtmlTabPage::Create( Window* pParent, return new OfaHtmlTabPage(pParent, rAttrSet); } -BOOL OfaHtmlTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaHtmlTabPage::FillItemSet( SfxItemSet& ) { SvxHtmlOptions* pHtmlOpt = SvxHtmlOptions::Get(); if(aSize1NF.GetSavedValue() != aSize1NF.GetText()) - pHtmlOpt->SetFontSize(0, (USHORT)aSize1NF.GetValue()); + pHtmlOpt->SetFontSize(0, (sal_uInt16)aSize1NF.GetValue()); if(aSize2NF.GetSavedValue() != aSize2NF.GetText()) - pHtmlOpt->SetFontSize(1, (USHORT)aSize2NF.GetValue()); + pHtmlOpt->SetFontSize(1, (sal_uInt16)aSize2NF.GetValue()); if(aSize3NF.GetSavedValue() != aSize3NF.GetText()) - pHtmlOpt->SetFontSize(2, (USHORT)aSize3NF.GetValue()); + pHtmlOpt->SetFontSize(2, (sal_uInt16)aSize3NF.GetValue()); if(aSize4NF.GetSavedValue() != aSize4NF.GetText()) - pHtmlOpt->SetFontSize(3, (USHORT)aSize4NF.GetValue()); + pHtmlOpt->SetFontSize(3, (sal_uInt16)aSize4NF.GetValue()); if(aSize5NF.GetSavedValue() != aSize5NF.GetText()) - pHtmlOpt->SetFontSize(4, (USHORT)aSize5NF.GetValue()); + pHtmlOpt->SetFontSize(4, (sal_uInt16)aSize5NF.GetValue()); if(aSize6NF.GetSavedValue() != aSize6NF.GetText()) - pHtmlOpt->SetFontSize(5, (USHORT)aSize6NF.GetValue()); + pHtmlOpt->SetFontSize(5, (sal_uInt16)aSize6NF.GetValue()); if(aSize7NF.GetSavedValue() != aSize7NF.GetText()) - pHtmlOpt->SetFontSize(6, (USHORT)aSize7NF.GetValue()); + pHtmlOpt->SetFontSize(6, (sal_uInt16)aSize7NF.GetValue()); if(aNumbersEnglishUSCB.IsChecked() != aNumbersEnglishUSCB.GetSavedValue()) pHtmlOpt->SetNumbersEnglishUS(aNumbersEnglishUSCB.IsChecked()); @@ -167,7 +167,7 @@ BOOL OfaHtmlTabPage::FillItemSet( SfxItemSet& ) if( aCharSetLB.GetSelectTextEncoding() != pHtmlOpt->GetTextEncoding() ) pHtmlOpt->SetTextEncoding( aCharSetLB.GetSelectTextEncoding() ); - return FALSE; + return sal_False; } void OfaHtmlTabPage::Reset( const SfxItemSet& ) @@ -183,10 +183,10 @@ void OfaHtmlTabPage::Reset( const SfxItemSet& ) aNumbersEnglishUSCB.Check(pHtmlOpt->IsNumbersEnglishUS()); aUnknownTagCB.Check(pHtmlOpt->IsImportUnknown()); aIgnoreFontNamesCB.Check(pHtmlOpt->IsIgnoreFontFamily()); - USHORT nExport = pHtmlOpt->GetExportMode(); + sal_uInt16 nExport = pHtmlOpt->GetExportMode(); if( nExport >= SAL_N_ELEMENTS( aExportToPosArr ) ) nExport = 4; // default for bad config entry is NS 4.0 - USHORT nPosArr = aExportToPosArr[ nExport ]; + sal_uInt16 nPosArr = aExportToPosArr[ nExport ]; // if( nPosArr == DEPRECATED_ENTRY ) // nPosArr = aExportToPosArr[ 4 ]; // again: NS 4.0 is default aExportLB.SelectEntryPos( nPosArr ); @@ -222,15 +222,15 @@ void OfaHtmlTabPage::Reset( const SfxItemSet& ) IMPL_LINK(OfaHtmlTabPage, ExportHdl_Impl, ListBox*, pBox) { - USHORT nExport = aPosToExportArr[ pBox->GetSelectEntryPos() ]; + sal_uInt16 nExport = aPosToExportArr[ pBox->GetSelectEntryPos() ]; switch( nExport ) { case HTML_CFG_MSIE_40: case HTML_CFG_NS40 : case HTML_CFG_WRITER : - aPrintExtensionCB.Enable(TRUE); + aPrintExtensionCB.Enable(sal_True); break; - default: aPrintExtensionCB.Enable(FALSE); + default: aPrintExtensionCB.Enable(sal_False); } return 0; diff --git a/cui/source/options/opthtml.hxx b/cui/source/options/opthtml.hxx index 7785398741d8..52d67ce873ea 100644 --- a/cui/source/options/opthtml.hxx +++ b/cui/source/options/opthtml.hxx @@ -78,7 +78,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/opthtml.src b/cui/source/options/opthtml.src index 60db286b192d..5de010b58948 100644 --- a/cui/source/options/opthtml.src +++ b/cui/source/options/opthtml.src @@ -32,7 +32,7 @@ // RID_OFAPAGE_HTMLOPT ----------------------------------------------------- TabPage RID_OFAPAGE_HTMLOPT { - // HelpId = ; + HelpID = "cui:TabPage:RID_OFAPAGE_HTMLOPT"; OutputSize = TRUE ; Size = MAP_APPFONT ( 260 , 185 ) ; SVLook = TRUE ; @@ -45,6 +45,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE1 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE1"; Pos = MAP_APPFONT ( 45 , 14 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -67,6 +68,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE2 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE2"; Pos = MAP_APPFONT ( 45 , 30 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -89,6 +91,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE3 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE3"; Pos = MAP_APPFONT ( 45 , 46 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -111,6 +114,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE4 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE4"; Pos = MAP_APPFONT ( 45 , 62 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -133,6 +137,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE5 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE5"; Pos = MAP_APPFONT ( 45 , 78 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -155,6 +160,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE6 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE6"; Pos = MAP_APPFONT ( 45 , 94 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -177,6 +183,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; NumericField NF_SIZE7 { + HelpID = "cui:NumericField:RID_OFAPAGE_HTMLOPT:NF_SIZE7"; Pos = MAP_APPFONT ( 45 , 110 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; Border = TRUE ; @@ -205,6 +212,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; CheckBox CB_NUMBERS_ENGLISH_US { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_NUMBERS_ENGLISH_US"; Pos = MAP_APPFONT ( 93 , 14 ) ; Size = MAP_APPFONT ( 161 , 10 ) ; TabStop = TRUE ; @@ -212,6 +220,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; CheckBox CB_UNKNOWN_TAGS { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_UNKNOWN_TAGS"; Pos = MAP_APPFONT ( 93 , 28 ) ; Size = MAP_APPFONT ( 155 , 10 ) ; TabStop = TRUE ; @@ -219,6 +228,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; CheckBox CB_IGNORE_FONTNAMES { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_IGNORE_FONTNAMES"; Pos = MAP_APPFONT ( 93 , 42 ) ; Size = MAP_APPFONT ( 155 , 10 ) ; TabStop = TRUE ; @@ -232,6 +242,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; ListBox LB_EXPORT { + HelpID = "cui:ListBox:RID_OFAPAGE_HTMLOPT:LB_EXPORT"; Pos = MAP_APPFONT ( 93 , 69 ) ; Size = MAP_APPFONT ( 155 , 50 ) ; Border = TRUE ; @@ -246,24 +257,28 @@ TabPage RID_OFAPAGE_HTMLOPT }; CheckBox CB_STARBASIC { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_STARBASIC"; Pos = MAP_APPFONT ( 93 , 88 ) ; Size = MAP_APPFONT ( 155 , 10 ) ; Text = "%PRODUCTNAME ~Basic" ; }; CheckBox CB_STARBASIC_WARNING { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_STARBASIC_WARNING"; Pos = MAP_APPFONT ( 99 , 102 ) ; Size = MAP_APPFONT ( 149 , 10 ) ; Text [ en-US ] = "Display ~warning"; }; CheckBox CB_PRINT_EXTENSION { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_PRINT_EXTENSION"; Pos = MAP_APPFONT ( 93 , 116 ) ; Size = MAP_APPFONT ( 155 , 10 ) ; Text [ en-US ] = "~Print layout" ; }; CheckBox CB_LOCAL_GRF { + HelpID = "cui:CheckBox:RID_OFAPAGE_HTMLOPT:CB_LOCAL_GRF"; Pos = MAP_APPFONT ( 93 , 130 ) ; Size = MAP_APPFONT ( 155 , 10 ) ; Text [ en-US ] = "~Copy local graphics to Internet" ; @@ -277,6 +292,7 @@ TabPage RID_OFAPAGE_HTMLOPT }; ListBox LB_CHARSET { + HelpID = "cui:ListBox:RID_OFAPAGE_HTMLOPT:LB_CHARSET"; Pos = MAP_APPFONT ( 162 , 143 ) ; Size = MAP_APPFONT ( 86 , 61 ) ; TabStop = TRUE ; diff --git a/cui/source/options/optimprove.cxx b/cui/source/options/optimprove.cxx index c45a0c299209..b5f550f5475c 100644 --- a/cui/source/options/optimprove.cxx +++ b/cui/source/options/optimprove.cxx @@ -196,31 +196,4 @@ IMPL_LINK( SvxImprovementDialog, HandleOK, OKButton*, EMPTYARG ) return 0; } -// class SvxInfoWindow --------------------------------------------------- - -SvxInfoWindow::SvxInfoWindow( Window* pParent, const ResId& rResId ) : - Window( pParent, rResId ), - m_aInfoText( this ) -{ - m_aInfoText.SetPosSizePixel( Point( 10, 10 ), Size( 150, 10 ) ); - - const StyleSettings& rSettings = GetSettings().GetStyleSettings(); - Wallpaper aWall( rSettings.GetWindowColor() ); - SetBackground( aWall ); - Font aNewFont( m_aInfoText.GetFont() ); - aNewFont.SetTransparent( TRUE ); - m_aInfoText.SetFont( aNewFont ); - m_aInfoText.SetBackground( aWall ); - m_aInfoText.SetControlForeground( rSettings.GetWindowTextColor() ); -} - -void SvxInfoWindow::SetInfoText( const String& rText ) -{ - m_aInfoText.SetText( rText ); - Size aSize = m_aInfoText.CalcMinimumSize(); - Size aWinSize = GetSizePixel(); - Point aPos( ( aWinSize.Width() - aSize.Width() ) / 2, ( aWinSize.Height() - aSize.Height() ) / 2 ); - m_aInfoText.SetPosSizePixel( aPos, aSize ); -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
\ No newline at end of file diff --git a/cui/source/options/optimprove.src b/cui/source/options/optimprove.src index c389b38cddfa..523dc8545ca9 100644 --- a/cui/source/options/optimprove.src +++ b/cui/source/options/optimprove.src @@ -34,7 +34,7 @@ TabPage RID_SVXPAGE_IMPROVEMENT { - //!HelpId = HID_OPTIONS_IMPROVEMENT ; + HelpId = "cui:TabPage:RID_SVXPAGE_IMPROVEMENT" ; OutputSize = TRUE ; SVLook = TRUE ; Hide = TRUE ; @@ -55,6 +55,7 @@ TabPage RID_SVXPAGE_IMPROVEMENT }; RadioButton RB_YES { + HelpID = "cui:RadioButton:RID_SVXPAGE_IMPROVEMENT:RB_YES"; Pos = MAP_APPFONT ( 12 , 92 ) ; Size = MAP_APPFONT ( 215 , 10 ) ; Check = TRUE ; @@ -62,6 +63,7 @@ TabPage RID_SVXPAGE_IMPROVEMENT }; RadioButton RB_NO { + HelpID = "cui:RadioButton:RID_SVXPAGE_IMPROVEMENT:RB_NO"; Pos = MAP_APPFONT ( 12 , 105 ) ; Size = MAP_APPFONT ( 215 , 10 ) ; Text [ en-US ] = "~No, I do not wish to participate" ; @@ -105,6 +107,7 @@ TabPage RID_SVXPAGE_IMPROVEMENT }; PushButton PB_SHOWDATA { + HelpID = "cui:PushButton:RID_SVXPAGE_IMPROVEMENT:PB_SHOWDATA"; Pos = MAP_APPFONT ( 12 , 161 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "~Show Data" ; diff --git a/cui/source/options/optimprove2.cxx b/cui/source/options/optimprove2.cxx index 5bb7c1592061..132247d6f81d 100644 --- a/cui/source/options/optimprove2.cxx +++ b/cui/source/options/optimprove2.cxx @@ -50,6 +50,7 @@ #include <comphelper/synchronousdispatch.hxx> #include <comphelper/uieventslogger.hxx> #include <tools/testtoolloader.hxx> +#include <osl/file.hxx> #define C2S(s) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(s)) @@ -59,14 +60,16 @@ namespace uno = ::com::sun::star::uno; namespace util = ::com::sun::star::util; using namespace com::sun::star::system; -// class SvxEmptyPage ---------------------------------------------------- - -SvxEmptyPage::SvxEmptyPage( Window* pParent ) : - - TabPage( pParent, CUI_RES( RID_SVXPAGE_IMPROVEMENT ) ) +namespace { - FreeResource(); + bool lcl_doesLogfileExist(const ::rtl::OUString& sLogPath) + { + ::rtl::OUString sLogFile( sLogPath ); + sLogFile += C2S("/Current.csv"); + ::osl::File aLogFile(sLogFile); + return aLogFile.open(osl_File_OpenFlag_Read) == ::osl::FileBase::E_None; + } } // class SvxImprovementOptionsPage --------------------------------------- @@ -151,7 +154,10 @@ IMPL_LINK( SvxImprovementOptionsPage, HandleShowData, PushButton*, EMPTYARG ) uno::Reference< lang::XComponent > xDoc = ::comphelper::SynchronousDispatch::dispatch( xDesktop, sLogFile, C2S("_default"), 0, aArgs ); if ( xDoc.is() ) + { + dynamic_cast<Dialog*>(GetParent())->EndDialog( RET_CANCEL ); return 1; + } } return 0; @@ -162,11 +168,6 @@ SfxTabPage* SvxImprovementOptionsPage::Create( Window* pParent, const SfxItemSet return new SvxImprovementOptionsPage( pParent, rSet ); } -sal_uInt16* SvxImprovementOptionsPage::GetRanges() -{ - return NULL; -} - sal_Bool SvxImprovementOptionsPage::FillItemSet( SfxItemSet& /*rSet*/ ) { uno::Reference< lang::XMultiServiceFactory > xSMGR = ::comphelper::getProcessServiceFactory(); @@ -180,7 +181,7 @@ sal_Bool SvxImprovementOptionsPage::FillItemSet( SfxItemSet& /*rSet*/ ) ::comphelper::ConfigurationHelper::writeRelativeKey( xConfig, C2S("Participation"), C2S("ShowedInvitation"), uno::makeAny( true ) ); ::comphelper::ConfigurationHelper::writeRelativeKey( - xConfig, C2S("Participation"), C2S("InvitationAccepted"), uno::makeAny( m_aYesRB.IsChecked() != FALSE ) ); + xConfig, C2S("Participation"), C2S("InvitationAccepted"), uno::makeAny( m_aYesRB.IsChecked() != sal_False ) ); ::comphelper::ConfigurationHelper::flush( xConfig ); // TODO: refactor ::comphelper::UiEventsLogger::reinit(); @@ -257,11 +258,13 @@ void SvxImprovementOptionsPage::Reset( const SfxItemSet& /*rSet*/ ) if ( xSubst.is() ) sPath = xSubst->substituteVariables( sPath, sal_False ); m_sLogPath = sPath; + m_aShowDataPB.Enable(lcl_doesLogfileExist(m_sLogPath)); } } } catch( uno::Exception& ) { + m_aShowDataPB.Enable(false); } } diff --git a/cui/source/options/optinet2.cxx b/cui/source/options/optinet2.cxx index f94ea15edf0a..87979ed9b402 100644 --- a/cui/source/options/optinet2.cxx +++ b/cui/source/options/optinet2.cxx @@ -134,43 +134,19 @@ const char* SEARCHENGINE_GROUP = "SearchEngines-$(vlang)"; // ----------------------------------------------------------------------- -String lcl_MakeTabEntry(const SfxFilter* pFilter) -{ - String sEntry(pFilter->GetMimeType()); - sEntry += '\t'; - sEntry += pFilter->GetWildcard().GetWildCard(); - sEntry += '\t'; - sEntry += pFilter->GetName(); -#if defined(OS2) - sEntry += '\t'; - sEntry += pFilter->GetTypeName(); -#endif - return sEntry; -} - -// ----------------------------------------------------------------------- - -BOOL IsJavaInstalled_Impl( /*!!!SfxIniManager* pIniMgr*/ ) -{ - BOOL bRet = FALSE; - return bRet; -} - -// ----------------------------------------------------------------------- - void SvxNoSpaceEdit::KeyInput( const KeyEvent& rKEvent ) { if ( bOnlyNumeric ) { const KeyCode& rKeyCode = rKEvent.GetKeyCode(); - USHORT nGroup = rKeyCode.GetGroup(); - USHORT nKey = rKeyCode.GetCode(); - BOOL bValid = ( KEYGROUP_NUM == nGroup || KEYGROUP_CURSOR == nGroup || + sal_uInt16 nGroup = rKeyCode.GetGroup(); + sal_uInt16 nKey = rKeyCode.GetCode(); + sal_Bool bValid = ( KEYGROUP_NUM == nGroup || KEYGROUP_CURSOR == nGroup || ( KEYGROUP_MISC == nGroup && ( nKey < KEY_ADD || nKey > KEY_EQUAL ) ) ); if ( !bValid && ( rKeyCode.IsMod1() && ( KEY_A == nKey || KEY_C == nKey || KEY_V == nKey || KEY_X == nKey || KEY_Z == nKey ) ) ) // Erase, Copy, Paste, Select All und Undo soll funktionieren - bValid = TRUE; + bValid = sal_True; if ( bValid ) Edit::KeyInput(rKEvent); @@ -211,17 +187,17 @@ SvxProxyTabPage::SvxProxyTabPage(Window* pParent, const SfxItemSet& rSet ) : aHttpProxyFT (this, CUI_RES( FT_HTTP_PROXY )), aHttpProxyED (this, CUI_RES( ED_HTTP_PROXY )), aHttpPortFT (this, CUI_RES( FT_HTTP_PORT )), - aHttpPortED (this, CUI_RES( ED_HTTP_PORT ), TRUE), + aHttpPortED (this, CUI_RES( ED_HTTP_PORT ), sal_True), aHttpsProxyFT (this, CUI_RES( FT_HTTPS_PROXY )), aHttpsProxyED (this, CUI_RES( ED_HTTPS_PROXY )), aHttpsPortFT (this, CUI_RES( FT_HTTPS_PORT )), - aHttpsPortED (this, CUI_RES( ED_HTTPS_PORT ), TRUE), + aHttpsPortED (this, CUI_RES( ED_HTTPS_PORT ), sal_True), aFtpProxyFT (this, CUI_RES( FT_FTP_PROXY )), aFtpProxyED (this, CUI_RES( ED_FTP_PROXY )), aFtpPortFT (this, CUI_RES( FT_FTP_PORT )), - aFtpPortED (this, CUI_RES( ED_FTP_PORT ), TRUE), + aFtpPortED (this, CUI_RES( ED_FTP_PORT ), sal_True), aNoProxyForFT (this, CUI_RES( FT_NOPROXYFOR )), aNoProxyForED (this, CUI_RES( ED_NOPROXYFOR )), @@ -300,7 +276,7 @@ void SvxProxyTabPage::ReadConfigData_Impl() if( xNameAccess->getByName(aProxyModePN) >>= nIntValue ) { - aProxyModeLB.SelectEntryPos( (USHORT) nIntValue ); + aProxyModeLB.SelectEntryPos( (sal_uInt16) nIntValue ); } if( xNameAccess->getByName(aHttpProxyPN) >>= aStringValue ) @@ -462,74 +438,74 @@ void SvxProxyTabPage::Reset(const SfxItemSet&) EnableControls_Impl( aProxyModeLB.GetSelectEntryPos() == 2 ); } -BOOL SvxProxyTabPage::FillItemSet(SfxItemSet& ) +sal_Bool SvxProxyTabPage::FillItemSet(SfxItemSet& ) { - BOOL bModified=FALSE; + sal_Bool bModified=sal_False; try { Reference< beans::XPropertySet > xPropertySet(m_xConfigurationUpdateAccess, UNO_QUERY_THROW ); - USHORT nSelPos = aProxyModeLB.GetSelectEntryPos(); + sal_uInt16 nSelPos = aProxyModeLB.GetSelectEntryPos(); if(aProxyModeLB.GetSavedValue() != nSelPos) { if( nSelPos == 1 ) { RestoreConfigDefaults_Impl(); - return TRUE; + return sal_True; } xPropertySet->setPropertyValue(aProxyModePN, makeAny((sal_Int32) nSelPos)); - bModified = TRUE; + bModified = sal_True; } if(aHttpProxyED.GetSavedValue() != aHttpProxyED.GetText()) { xPropertySet->setPropertyValue( aHttpProxyPN, makeAny(rtl::OUString(aHttpProxyED.GetText()))); - bModified = TRUE; + bModified = sal_True; } if ( aHttpPortED.GetSavedValue() != aHttpPortED.GetText() ) { xPropertySet->setPropertyValue( aHttpPortPN, makeAny(aHttpPortED.GetText().ToInt32())); - bModified = TRUE; + bModified = sal_True; } if(aHttpsProxyED.GetSavedValue() != aHttpsProxyED.GetText()) { xPropertySet->setPropertyValue( aHttpsProxyPN, makeAny(rtl::OUString(aHttpsProxyED.GetText()))); - bModified = TRUE; + bModified = sal_True; } if ( aHttpsPortED.GetSavedValue() != aHttpsPortED.GetText() ) { xPropertySet->setPropertyValue( aHttpsPortPN, makeAny(aHttpsPortED.GetText().ToInt32())); - bModified = TRUE; + bModified = sal_True; } if(aFtpProxyED.GetSavedValue() != aFtpProxyED.GetText()) { xPropertySet->setPropertyValue( aFtpProxyPN, makeAny( rtl::OUString(aFtpProxyED.GetText()))); - bModified = TRUE; + bModified = sal_True; } if ( aFtpPortED.GetSavedValue() != aFtpPortED.GetText() ) { xPropertySet->setPropertyValue( aFtpPortPN, makeAny(aFtpPortED.GetText().ToInt32())); - bModified = TRUE; + bModified = sal_True; } if ( aNoProxyForED.GetSavedValue() != aNoProxyForED.GetText() ) { xPropertySet->setPropertyValue( aNoProxyDescPN, makeAny( rtl::OUString(aNoProxyForED.GetText()))); - bModified = TRUE; + bModified = sal_True; } Reference< util::XChangesBatch > xChangesBatch(m_xConfigurationUpdateAccess, UNO_QUERY_THROW); @@ -609,7 +585,7 @@ void SvxProxyTabPage::ArrangeControls_Impl() } } -void SvxProxyTabPage::EnableControls_Impl(BOOL bEnable) +void SvxProxyTabPage::EnableControls_Impl(sal_Bool bEnable) { aHttpProxyFT.Enable(bEnable); aHttpProxyED.Enable(bEnable); @@ -635,7 +611,7 @@ void SvxProxyTabPage::EnableControls_Impl(BOOL bEnable) IMPL_LINK( SvxProxyTabPage, ProxyHdl_Impl, ListBox *, pBox ) { - USHORT nPos = pBox->GetSelectEntryPos(); + sal_uInt16 nPos = pBox->GetSelectEntryPos(); // Restore original system values if( nPos == 1 ) @@ -759,11 +735,11 @@ void SvxSearchTabPage::Reset( const SfxItemSet& ) // ----------------------------------------------------------------------- -BOOL SvxSearchTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxSearchTabPage::FillItemSet( SfxItemSet& ) { if(aSearchConfig.IsModified()) aSearchConfig.Commit(); - return TRUE; + return sal_True; } /*--------------------------------------------------------------------*/ @@ -785,21 +761,21 @@ int SvxSearchTabPage::DeactivatePage( SfxItemSet* _pSet ) // ----------------------------------------------------------------------- -BOOL SvxSearchTabPage::ConfirmLeave( const String& rStringSelection) +sal_Bool SvxSearchTabPage::ConfirmLeave( const String& rStringSelection) { if(aChangePB.IsEnabled()) { QueryBox aQuery(this, WB_YES_NO_CANCEL|WB_DEF_YES, sModifyMsg); - USHORT nRet = aQuery.Execute(); + sal_uInt16 nRet = aQuery.Execute(); if(RET_CANCEL == nRet) { if(rStringSelection.Len()) aSearchLB.SelectEntry(sLastSelectedEntry); - return FALSE; + return sal_False; } else if(RET_YES == nRet) { - USHORT nEntryPos = aSearchLB.GetEntryPos( aSearchNameED.GetText() ); + sal_uInt16 nEntryPos = aSearchLB.GetEntryPos( aSearchNameED.GetText() ); if ( nEntryPos != LISTBOX_ENTRY_NOTFOUND ) aSearchLB.SelectEntryPos(nEntryPos); else @@ -810,19 +786,19 @@ BOOL SvxSearchTabPage::ConfirmLeave( const String& rStringSelection) } else if(RET_NO == nRet) { - aChangePB.Enable(FALSE); - aAddPB.Enable(FALSE); + aChangePB.Enable(sal_False); + aAddPB.Enable(sal_False); SearchEntryHdl_Impl(&aSearchLB); } } if(aAddPB.IsEnabled()) { QueryBox aQuery(this, WB_YES_NO_CANCEL|WB_DEF_YES, sModifyMsg); - USHORT nRet = aQuery.Execute(); + sal_uInt16 nRet = aQuery.Execute(); if(RET_CANCEL == nRet) { aSearchLB.SetNoSelection(); - return FALSE; + return sal_False; } else if(RET_YES == nRet) { @@ -833,13 +809,13 @@ BOOL SvxSearchTabPage::ConfirmLeave( const String& rStringSelection) } else if(RET_NO == nRet) { - aAddPB.Enable(FALSE); - aChangePB.Enable(FALSE); + aAddPB.Enable(sal_False); + aChangePB.Enable(sal_False); NewSearchHdl_Impl(0); } } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------- @@ -897,7 +873,7 @@ IMPL_LINK( SvxSearchTabPage, NewSearchHdl_Impl, PushButton *, EMPTYARG ) aSearchNameED.SetText( String() ); aSearchLB.SetNoSelection(); aCurrentSrchData = SvxSearchEngineData(); - aAndRB.Check( TRUE ); + aAndRB.Check( sal_True ); SearchEntryHdl_Impl( &aSearchLB ); SearchPartHdl_Impl( &aAndRB ); return 0; @@ -907,8 +883,8 @@ IMPL_LINK( SvxSearchTabPage, NewSearchHdl_Impl, PushButton *, EMPTYARG ) IMPL_LINK( SvxSearchTabPage, AddSearchHdl_Impl, PushButton *, EMPTYARG ) { - aAddPB.Enable(FALSE); - aChangePB.Enable(FALSE); + aAddPB.Enable(sal_False); + aChangePB.Enable(sal_False); aCurrentSrchData.sEngineName = aSearchNameED.GetText(); aSearchConfig.SetData(aCurrentSrchData); aSearchLB.InsertEntry( aCurrentSrchData.sEngineName ); @@ -921,9 +897,9 @@ IMPL_LINK( SvxSearchTabPage, AddSearchHdl_Impl, PushButton *, EMPTYARG ) IMPL_LINK( SvxSearchTabPage, ChangeSearchHdl_Impl, PushButton *, EMPTYARG ) { - aChangePB.Enable(FALSE); - aAddPB.Enable(FALSE); - USHORT nPos = aSearchLB.GetSelectEntryPos(); + aChangePB.Enable(sal_False); + aAddPB.Enable(sal_False); + sal_uInt16 nPos = aSearchLB.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { String sEngine = aSearchLB.GetSelectEntry(); @@ -934,7 +910,7 @@ IMPL_LINK( SvxSearchTabPage, ChangeSearchHdl_Impl, PushButton *, EMPTYARG ) } else { - SetUpdateMode(FALSE); + SetUpdateMode(sal_False); String sEntry = aSearchNameED.GetText(); // im AddHdl wird sLastSelectedEntry umgesetzt String sTemp(sLastSelectedEntry); @@ -943,7 +919,7 @@ IMPL_LINK( SvxSearchTabPage, ChangeSearchHdl_Impl, PushButton *, EMPTYARG ) DeleteSearchHdl_Impl(0); aSearchLB.SelectEntry(sEntry); SearchEntryHdl_Impl(&aSearchLB); - SetUpdateMode(TRUE); + SetUpdateMode(sal_True); } return 0; } @@ -952,8 +928,8 @@ IMPL_LINK( SvxSearchTabPage, ChangeSearchHdl_Impl, PushButton *, EMPTYARG ) IMPL_LINK( SvxSearchTabPage, DeleteSearchHdl_Impl, PushButton *, EMPTYARG) { - aChangePB.Enable(FALSE); - USHORT nPos = aSearchLB.GetSelectEntryPos(); + aChangePB.Enable(sal_False); + sal_uInt16 nPos = aSearchLB.GetSelectEntryPos(); DBG_ASSERT(nPos != LISTBOX_ENTRY_NOTFOUND, "kein Eintrag selektiert!"); aSearchConfig.RemoveData(aSearchLB.GetSelectEntry()); aSearchLB.RemoveEntry(nPos); @@ -966,7 +942,7 @@ IMPL_LINK( SvxSearchTabPage, DeleteSearchHdl_Impl, PushButton *, EMPTYARG) IMPL_LINK( SvxSearchTabPage, SearchEntryHdl_Impl, ListBox*, pBox ) { - USHORT nEntryPos = pBox->GetSelectEntryPos(); + sal_uInt16 nEntryPos = pBox->GetSelectEntryPos(); if ( nEntryPos != LISTBOX_ENTRY_NOTFOUND ) { String sSelection(pBox->GetSelectEntry()); @@ -986,18 +962,18 @@ IMPL_LINK( SvxSearchTabPage, SearchEntryHdl_Impl, ListBox*, pBox ) aSeparatorED.SetText( bAnd ? pData->sAndSeparator : bOr ? pData->sOrSeparator : pData->sExactSeparator); aPostFixED.SetText(bAnd ? pData->sAndSuffix : bOr ? pData->sOrSuffix : pData->sExactSuffix ); sal_Int32 nCase = bAnd ? pData->nAndCaseMatch : bOr ? pData->nOrCaseMatch : pData->nExactCaseMatch; - aCaseED.SelectEntryPos( (USHORT)nCase ); + aCaseED.SelectEntryPos( (sal_uInt16)nCase ); aCurrentSrchData = *pData; } aDeletePB.Enable(); } else { - aDeletePB.Enable(FALSE); + aDeletePB.Enable(sal_False); sLastSelectedEntry.Erase(); } - aChangePB.Enable(FALSE); - aAddPB.Enable(FALSE); + aChangePB.Enable(sal_False); + aAddPB.Enable(sal_False); return 0; } @@ -1007,11 +983,11 @@ IMPL_LINK( SvxSearchTabPage, SearchModifyHdl_Impl, SvxNoSpaceEdit*, pEdit ) { if ( pEdit == &aSearchNameED ) { - BOOL bTextLen = ( 0 != pEdit->GetText().Len() ); - BOOL bFound = FALSE; + sal_Bool bTextLen = ( 0 != pEdit->GetText().Len() ); + sal_Bool bFound = sal_False; if ( bTextLen ) { - USHORT nEntryPos = aSearchLB.GetEntryPos( pEdit->GetText() ); + sal_uInt16 nEntryPos = aSearchLB.GetEntryPos( pEdit->GetText() ); bFound = ( nEntryPos != LISTBOX_ENTRY_NOTFOUND ); if ( bFound ) aSearchLB.SelectEntryPos(nEntryPos); @@ -1063,51 +1039,16 @@ IMPL_LINK( SvxSearchTabPage, SearchPartHdl_Impl, RadioButton *, EMPTYARG ) aSeparatorED.SetText( bAnd ? aCurrentSrchData.sAndSeparator : bOr ? aCurrentSrchData.sOrSeparator : aCurrentSrchData.sExactSeparator); aPostFixED.SetText(bAnd ? aCurrentSrchData.sAndSuffix : bOr ? aCurrentSrchData.sOrSuffix : aCurrentSrchData.sExactSuffix ); sal_Int32 nCase = bAnd ? aCurrentSrchData.nAndCaseMatch : bOr ? aCurrentSrchData.nOrCaseMatch : aCurrentSrchData.nExactCaseMatch; - aCaseED.SelectEntryPos( (USHORT)nCase ); + aCaseED.SelectEntryPos( (sal_uInt16)nCase ); return 0; } -// class JavaScriptDisableQueryBox_Impl -------------------------------------- - -class JavaScriptDisableQueryBox_Impl : public ModalDialog -{ -private: - FixedImage aImage; - FixedText aWarningFT; - CheckBox aDisableCB; - OKButton aYesBtn; - CancelButton aNoBtn; - -public: - JavaScriptDisableQueryBox_Impl( Window* pParent ); - - BOOL IsWarningDisabled() const { return aDisableCB.IsChecked(); } -}; - -JavaScriptDisableQueryBox_Impl::JavaScriptDisableQueryBox_Impl( Window* pParent ) : - - ModalDialog( pParent, CUI_RES( RID_SVXDLG_OPT_JAVASCRIPT_DISABLE ) ), - - aImage ( this, CUI_RES( IMG_JSCPT_WARNING ) ), - aWarningFT ( this, CUI_RES( FT_JSCPT_WARNING ) ), - aDisableCB ( this, CUI_RES( CB_JSCPT_DISABLE ) ), - aYesBtn ( this, CUI_RES( BTN_JSCPT_YES ) ), - aNoBtn ( this, CUI_RES( BTN_JSCPT_NO ) ) - -{ - FreeResource(); - - aYesBtn.SetText( Button::GetStandardText( BUTTON_YES ) ); - aNoBtn.SetText( Button::GetStandardText( BUTTON_NO ) ); - aImage.SetImage( WarningBox::GetStandardImage() ); -} - //#98647#---------------------------------------------- void SvxScriptExecListBox::RequestHelp( const HelpEvent& rHEvt ) { // try to show tips just like as on toolbars - USHORT nPos=LISTBOX_ENTRY_NOTFOUND; - USHORT nTop = GetTopEntry(); - USHORT nCount = GetDisplayLineCount(); // Attention: Not GetLineCount() + sal_uInt16 nPos=LISTBOX_ENTRY_NOTFOUND; + sal_uInt16 nTop = GetTopEntry(); + sal_uInt16 nCount = GetDisplayLineCount(); // Attention: Not GetLineCount() Point aPt = ScreenToOutputPixel( rHEvt.GetMousePosPixel() ); Rectangle aItemRect; if( nCount > 0 ) // if there're some entries, find it. @@ -1211,37 +1152,37 @@ IMPL_LINK( SvxSecurityTabPage, SavePasswordHdl, void*, EMPTYARG ) xMasterPasswd->removeMasterPassword(); if ( xMasterPasswd->changeMasterPassword( Reference< task::XInteractionHandler >() ) ) { - maMasterPasswordPB.Enable( TRUE ); - maMasterPasswordCB.Check( TRUE ); - maMasterPasswordCB.Enable( TRUE ); - maMasterPasswordFI.Enable( TRUE ); - maShowConnectionsPB.Enable( TRUE ); + maMasterPasswordPB.Enable( sal_True ); + maMasterPasswordCB.Check( sal_True ); + maMasterPasswordCB.Enable( sal_True ); + maMasterPasswordFI.Enable( sal_True ); + maShowConnectionsPB.Enable( sal_True ); } else { xMasterPasswd->allowPersistentStoring( bOldValue ); - maSavePasswordsCB.Check( FALSE ); + maSavePasswordsCB.Check( sal_False ); } } else { QueryBox aQuery( this, WB_YES_NO|WB_DEF_NO, msPasswordStoringDeactivateStr ); - USHORT nRet = aQuery.Execute(); + sal_uInt16 nRet = aQuery.Execute(); if( RET_YES == nRet ) { xMasterPasswd->allowPersistentStoring( sal_False ); - maMasterPasswordCB.Check( TRUE ); - maMasterPasswordPB.Enable( FALSE ); - maMasterPasswordCB.Enable( FALSE ); - maMasterPasswordFI.Enable( FALSE ); - maShowConnectionsPB.Enable( FALSE ); + maMasterPasswordCB.Check( sal_True ); + maMasterPasswordPB.Enable( sal_False ); + maMasterPasswordCB.Enable( sal_False ); + maMasterPasswordFI.Enable( sal_False ); + maShowConnectionsPB.Enable( sal_False ); } else { - maSavePasswordsCB.Check( TRUE ); - maMasterPasswordPB.Enable( TRUE ); - maShowConnectionsPB.Enable( TRUE ); + maSavePasswordsCB.Check( sal_True ); + maMasterPasswordPB.Enable( sal_True ); + maShowConnectionsPB.Enable( sal_True ); } } } @@ -1284,28 +1225,28 @@ IMPL_LINK( SvxSecurityTabPage, MasterPasswordCBHdl, void*, EMPTYARG ) { if ( xMasterPasswd->isPersistentStoringAllowed() && xMasterPasswd->changeMasterPassword( Reference< task::XInteractionHandler >() ) ) { - maMasterPasswordPB.Enable( TRUE ); - maMasterPasswordFI.Enable( TRUE ); + maMasterPasswordPB.Enable( sal_True ); + maMasterPasswordFI.Enable( sal_True ); } else { - maMasterPasswordCB.Check( FALSE ); - maMasterPasswordPB.Enable( TRUE ); - maMasterPasswordFI.Enable( TRUE ); + maMasterPasswordCB.Check( sal_False ); + maMasterPasswordPB.Enable( sal_True ); + maMasterPasswordFI.Enable( sal_True ); } } else { if ( xMasterPasswd->isPersistentStoringAllowed() && xMasterPasswd->useDefaultMasterPassword( Reference< task::XInteractionHandler >() ) ) { - maMasterPasswordPB.Enable( FALSE ); - maMasterPasswordFI.Enable( FALSE ); + maMasterPasswordPB.Enable( sal_False ); + maMasterPasswordFI.Enable( sal_False ); } else { - maMasterPasswordCB.Check( TRUE ); - maMasterPasswordPB.Enable( TRUE ); - maShowConnectionsPB.Enable( TRUE ); + maMasterPasswordCB.Check( sal_True ); + maMasterPasswordPB.Enable( sal_True ); + maShowConnectionsPB.Enable( sal_True ); } } } @@ -1420,11 +1361,11 @@ void SvxSecurityTabPage::InitControls() } } - maMasterPasswordPB.Enable( FALSE ); - maMasterPasswordCB.Enable( FALSE ); - maMasterPasswordCB.Check( TRUE ); - maMasterPasswordFI.Enable( FALSE ); - maShowConnectionsPB.Enable( FALSE ); + maMasterPasswordPB.Enable( sal_False ); + maMasterPasswordCB.Enable( sal_False ); + maMasterPasswordCB.Check( sal_True ); + maMasterPasswordFI.Enable( sal_False ); + maShowConnectionsPB.Enable( sal_False ); // initialize the password saving checkbox try @@ -1436,24 +1377,24 @@ void SvxSecurityTabPage::InitControls() if ( xMasterPasswd->isPersistentStoringAllowed() ) { - maMasterPasswordCB.Enable( TRUE ); - maShowConnectionsPB.Enable( TRUE ); - maSavePasswordsCB.Check( TRUE ); + maMasterPasswordCB.Enable( sal_True ); + maShowConnectionsPB.Enable( sal_True ); + maSavePasswordsCB.Check( sal_True ); Reference< task::XMasterPasswordHandling2 > xMasterPasswd2( xMasterPasswd, UNO_QUERY ); if ( xMasterPasswd2.is() && xMasterPasswd2->isDefaultMasterPasswordUsed() ) - maMasterPasswordCB.Check( FALSE ); + maMasterPasswordCB.Check( sal_False ); else { - maMasterPasswordPB.Enable( TRUE ); - maMasterPasswordCB.Check( TRUE ); - maMasterPasswordFI.Enable( TRUE ); + maMasterPasswordPB.Enable( sal_True ); + maMasterPasswordCB.Check( sal_True ); + maMasterPasswordFI.Enable( sal_True ); } } } catch( Exception& ) { - maSavePasswordsCB.Enable( FALSE ); + maSavePasswordsCB.Enable( sal_False ); } @@ -1477,16 +1418,6 @@ int SvxSecurityTabPage::DeactivatePage( SfxItemSet* _pSet ) namespace { - bool EnableAndSet( const SvtSecurityOptions& _rOpt, SvtSecurityOptions::EOption _eOpt, - CheckBox& _rCtrl, FixedImage& _rImg ) - { - bool b = _rOpt.IsOptionEnabled( _eOpt ); - _rCtrl.Enable( b ); - _rImg.Show( !b ); - _rCtrl.Check( _rOpt.IsOptionSet( _eOpt ) ); - return b; - } - bool CheckAndSave( SvtSecurityOptions& _rOpt, SvtSecurityOptions::EOption _eOpt, const bool _bIsChecked, bool& _rModfied ) { bool bModified = false; @@ -1504,7 +1435,7 @@ namespace } } -BOOL SvxSecurityTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxSecurityTabPage::FillItemSet( SfxItemSet& ) { bool bModified = false; @@ -1549,10 +1480,10 @@ SfxTabPage* MozPluginTabPage::Create( Window* pParent, { return new MozPluginTabPage( pParent, rAttrSet ); } -BOOL MozPluginTabPage::FillItemSet( SfxItemSet& ) +sal_Bool MozPluginTabPage::FillItemSet( SfxItemSet& ) { - BOOL hasInstall = isInstalled(); - BOOL hasChecked = aWBasicCodeCB.IsChecked(); + sal_Bool hasInstall = isInstalled(); + sal_Bool hasChecked = aWBasicCodeCB.IsChecked(); if(hasInstall && (!hasChecked)){ //try to uninstall uninstallPlugin(); @@ -1564,7 +1495,7 @@ BOOL MozPluginTabPage::FillItemSet( SfxItemSet& ) else{ // do nothing } - return TRUE; + return sal_True; } void MozPluginTabPage::Reset( const SfxItemSet& ) { @@ -1595,7 +1526,7 @@ inline bool getDllURL(rtl::OString * path) return true; } -BOOL MozPluginTabPage::isInstalled() +sal_Bool MozPluginTabPage::isInstalled() { #ifdef UNIX // get the real file referred by .so lnk file @@ -1631,7 +1562,7 @@ BOOL MozPluginTabPage::isInstalled() #endif #ifdef WNT // get the value from registry - BOOL ret = true; + sal_Bool ret = true; ::rtl::OString tempString; char realFilePath[NPP_PATH_MAX] = {0}; if (!getDllURL(&tempString)){ @@ -1646,7 +1577,7 @@ BOOL MozPluginTabPage::isInstalled() #endif } -BOOL MozPluginTabPage::installPlugin() +sal_Bool MozPluginTabPage::installPlugin() { #ifdef UNIX // get the real file referred by .so lnk file @@ -1695,7 +1626,7 @@ BOOL MozPluginTabPage::installPlugin() #endif } -BOOL MozPluginTabPage::uninstallPlugin() +sal_Bool MozPluginTabPage::uninstallPlugin() { #ifdef UNIX // get the real file referred by .so lnk file @@ -1878,26 +1809,26 @@ SfxTabPage* SvxEMailTabPage::Create( Window* pParent, const SfxItemSet& rAttrSe /* -------------------------------------------------------------------------*/ -BOOL SvxEMailTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxEMailTabPage::FillItemSet( SfxItemSet& ) { - BOOL bMailModified = FALSE; + sal_Bool bMailModified = sal_False; if(!pImpl->aMailConfig.bROProgram && aMailerURLED.GetSavedValue() != aMailerURLED.GetText()) { pImpl->aMailConfig.sProgram = aMailerURLED.GetText(); - bMailModified = TRUE; + bMailModified = sal_True; } if ( bMailModified ) pImpl->aMailConfig.Commit(); - return FALSE; + return sal_False; } /* -------------------------------------------------------------------------*/ void SvxEMailTabPage::Reset( const SfxItemSet& ) { - aMailerURLED.Enable(TRUE ); - aMailerURLPB.Enable(TRUE ); + aMailerURLED.Enable(sal_True ); + aMailerURLPB.Enable(sal_True ); if(pImpl->aMailConfig.bROProgram) aMailerURLFI.Show(); diff --git a/cui/source/options/optinet2.hxx b/cui/source/options/optinet2.hxx index 8a6c62637624..a7f7816d2e0e 100644 --- a/cui/source/options/optinet2.hxx +++ b/cui/source/options/optinet2.hxx @@ -71,10 +71,10 @@ namespace uno = ::com::sun::star::uno; class SvxNoSpaceEdit : public Edit { private: - BOOL bOnlyNumeric; + sal_Bool bOnlyNumeric; public: - SvxNoSpaceEdit(Window* pParent, ResId rResId, BOOL bNum = FALSE ) : + SvxNoSpaceEdit(Window* pParent, ResId rResId, sal_Bool bNum = sal_False ) : Edit( pParent, rResId ), bOnlyNumeric( bNum ) {} virtual void KeyInput( const KeyEvent& rKEvent ); @@ -129,7 +129,7 @@ private: #ifdef _SVX_OPTINET2_CXX void ArrangeControls_Impl(); - void EnableControls_Impl(BOOL bEnable); + void EnableControls_Impl(sal_Bool bEnable); void ReadConfigData_Impl(); void ReadConfigDefaults_Impl(); void RestoreConfigDefaults_Impl(); @@ -143,7 +143,7 @@ private: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -200,14 +200,14 @@ private: virtual void ActivatePage( const SfxItemSet& rSet ); virtual int DeactivatePage( SfxItemSet* pSet = 0 ); - BOOL ConfirmLeave( const String& rStringSelection ); + sal_Bool ConfirmLeave( const String& rStringSelection ); SvxSearchTabPage( Window* pParent, const SfxItemSet& rSet ); virtual ~SvxSearchTabPage(); public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -274,7 +274,7 @@ protected: public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -283,9 +283,9 @@ class MozPluginTabPage : public SfxTabPage FixedLine aMSWordGB; CheckBox aWBasicCodeCB; - BOOL isInstalled(void); - BOOL installPlugin(void); - BOOL uninstallPlugin(void); + sal_Bool isInstalled(void); + sal_Bool installPlugin(void); + sal_Bool uninstallPlugin(void); MozPluginTabPage( Window* pParent, const SfxItemSet& rSet ); virtual ~MozPluginTabPage(); @@ -295,7 +295,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; @@ -328,7 +328,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optinet2.src b/cui/source/options/optinet2.src index fbf2146c390e..ad77c8d33bd9 100755..100644 --- a/cui/source/options/optinet2.src +++ b/cui/source/options/optinet2.src @@ -39,6 +39,7 @@ TabPage RID_SVXPAGE_INET_MOZPLUGIN { + HelpID = "cui:TabPage:RID_SVXPAGE_INET_MOZPLUGIN"; OutputSize = TRUE ; Size = MAP_APPFONT ( 260 , 185 ) ; SVLook = TRUE ; @@ -52,6 +53,7 @@ TabPage RID_SVXPAGE_INET_MOZPLUGIN }; CheckBox CB_MOZPLUGIN_CODE { + HelpID = "cui:CheckBox:RID_SVXPAGE_INET_MOZPLUGIN:CB_MOZPLUGIN_CODE"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -83,6 +85,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; ListBox LB_PROXYMODE { + HelpID = "cui:ListBox:RID_SVXPAGE_INET_PROXY:LB_PROXYMODE"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 11 ) ; Size = MAP_APPFONT ( 49 , 48 ) ; Border = TRUE ; @@ -106,6 +109,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_HTTP_PROXY { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_HTTP_PROXY"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 27 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -124,6 +128,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_HTTP_PORT { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_HTTP_PORT"; Pos = MAP_APPFONT ( ED_PORT_COL , GB_TYPES_TOP + 27 ) ; Size = MAP_APPFONT ( ED_PORT_WIDTH , 12 ) ; Border = TRUE ; @@ -137,6 +142,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_HTTPS_PROXY { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_HTTPS_PROXY"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 43 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -150,6 +156,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_HTTPS_PORT { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_HTTPS_PORT"; Pos = MAP_APPFONT ( ED_PORT_COL , GB_TYPES_TOP + 43 ) ; Size = MAP_APPFONT ( ED_PORT_WIDTH , 12 ) ; Border = TRUE ; @@ -163,6 +170,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_FTP_PROXY { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_FTP_PROXY"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 59 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -176,6 +184,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_FTP_PORT { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_FTP_PORT"; Pos = MAP_APPFONT ( ED_PORT_COL , GB_TYPES_TOP + 59 ) ; Size = MAP_APPFONT ( ED_PORT_WIDTH , 12 ) ; Border = TRUE ; @@ -188,6 +197,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_SOCKS_PROXY { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_SOCKS_PROXY"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 75 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -201,6 +211,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_SOCKS_PORT { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_SOCKS_PORT"; Pos = MAP_APPFONT ( ED_PORT_COL , GB_TYPES_TOP + 75 ) ; Size = MAP_APPFONT ( ED_PORT_WIDTH , 12 ) ; Border = TRUE ; @@ -213,6 +224,7 @@ TabPage RID_SVXPAGE_INET_PROXY }; Edit ED_NOPROXYFOR { + HelpID = "cui:Edit:RID_SVXPAGE_INET_PROXY:ED_NOPROXYFOR"; Pos = MAP_APPFONT ( 65 , GB_TYPES_TOP + 91 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -231,18 +243,21 @@ TabPage RID_SVXPAGE_INET_PROXY }; RadioButton RB_DNS_AUTO { + HelpID = "cui:RadioButton:RID_SVXPAGE_INET_PROXY:RB_DNS_AUTO"; Pos = MAP_APPFONT( 12, 111 ); Size = MAP_APPFONT( 236, 10 ); Text [ en-US ] = "~Automatic" ; }; RadioButton RB_DNS_MANUAL { + HelpID = "cui:RadioButton:RID_SVXPAGE_INET_PROXY:RB_DNS_MANUAL"; Pos = MAP_APPFONT( 12, 124 ); Size = MAP_APPFONT( 75, 10 ); Text [ en-US ] = "~Manual" ; }; PatternField ED_DNS { + HelpID = "cui:PatternField:RID_SVXPAGE_INET_PROXY:ED_DNS"; Pos = MAP_APPFONT( 90, 126 ); Size = MAP_APPFONT( 66, 12 ); Border = TRUE ; @@ -283,6 +298,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; ListBox LB_SEARCH { + HelpID = "cui:ListBox:RID_SVXPAGE_INET_SEARCH:LB_SEARCH"; Pos = MAP_APPFONT ( 12 , GB_SEARCH_TOP + 11 ) ; Size = MAP_APPFONT ( 39 , 120 ) ; Border = TRUE ; @@ -299,6 +315,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; Edit ED_SEARCH_NAME { + HelpID = "cui:Edit:RID_SVXPAGE_INET_SEARCH:ED_SEARCH_NAME"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 11 ) ; Size = MAP_APPFONT ( 125 , 12 ) ; Border = TRUE ; @@ -311,6 +328,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; RadioButton RB_AND { + HelpID = "cui:RadioButton:RID_SVXPAGE_INET_SEARCH:RB_AND"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 26 ) ; Size = MAP_APPFONT ( 125 , 10 ) ; Check = TRUE ; @@ -318,12 +336,14 @@ TabPage RID_SVXPAGE_INET_SEARCH }; RadioButton RB_OR { + HelpID = "cui:RadioButton:RID_SVXPAGE_INET_SEARCH:RB_OR"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 39 ) ; Size = MAP_APPFONT ( 125 , 10 ) ; Text [ en-US ] = "~Or" ; }; RadioButton RB_EXACT { + HelpID = "cui:RadioButton:RID_SVXPAGE_INET_SEARCH:RB_EXACT"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 52 ) ; Size = MAP_APPFONT ( 125 , 10 ) ; Text [ en-US ] = "E~xact" ; @@ -336,6 +356,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; Edit ED_URL { + HelpID = "cui:Edit:RID_SVXPAGE_INET_SEARCH:ED_URL"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 65 ) ; Size = MAP_APPFONT ( 125 , 12 ) ; Border = TRUE ; @@ -348,6 +369,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; Edit ED_POSTFIX { + HelpID = "cui:Edit:RID_SVXPAGE_INET_SEARCH:ED_POSTFIX"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 80 ) ; Size = MAP_APPFONT ( 125 , 12 ) ; Border = TRUE ; @@ -360,6 +382,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; Edit ED_SEPARATOR { + HelpID = "cui:Edit:RID_SVXPAGE_INET_SEARCH:ED_SEPARATOR"; Pos = MAP_APPFONT ( EDIT_START_XPOS , GB_SEARCH_TOP + 95 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; Border = TRUE ; @@ -372,6 +395,7 @@ TabPage RID_SVXPAGE_INET_SEARCH }; ListBox ED_CASE { + HelpID = "cui:ListBox:RID_SVXPAGE_INET_SEARCH:ED_CASE"; Pos = MAP_APPFONT ( EDIT_START_XPOS, GB_SEARCH_TOP + 110 ) ; Size = MAP_APPFONT ( 42 , 48 ) ; Border = TRUE ; @@ -385,24 +409,28 @@ TabPage RID_SVXPAGE_INET_SEARCH }; PushButton PB_NEW { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SEARCH:PB_NEW"; Pos = MAP_APPFONT ( 39 , GB_SEARCH_TOP + 131 + 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "N~ew"; }; PushButton PB_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SEARCH:PB_ADD"; Pos = MAP_APPFONT ( 92 , GB_SEARCH_TOP + 131 + 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add" ; }; PushButton PB_CHANGE { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SEARCH:PB_CHANGE"; Pos = MAP_APPFONT ( 145 , GB_SEARCH_TOP + 131 + 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify" ; }; PushButton PB_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SEARCH:PB_DELETE"; Pos = MAP_APPFONT ( 198 , GB_SEARCH_TOP + 131 + 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete" ; @@ -422,6 +450,7 @@ TabPage RID_SVXPAGE_INET_SEARCH TabPage RID_SVXPAGE_INET_SECURITY { + HelpID = "cui:TabPage:RID_SVXPAGE_INET_SECURITY"; OutputSize = TRUE ; Size = MAP_APPFONT( TP_WIDTH , TP_HEIGHT ); SVLook = TRUE; @@ -442,6 +471,7 @@ TabPage RID_SVXPAGE_INET_SECURITY }; PushButton PB_SEC_SECURITYOPTIONS { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SECURITY:PB_SEC_SECURITYOPTIONS"; Pos = MAP_APPFONT( COL_3, ROW_2a ); Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); Text [ en-US ] = "Options..."; @@ -454,6 +484,7 @@ TabPage RID_SVXPAGE_INET_SECURITY }; CheckBox CB_SEC_SAVEPASSWORDS { + HelpID = "cui:CheckBox:RID_SVXPAGE_INET_SECURITY:CB_SEC_SAVEPASSWORDS"; Pos = MAP_APPFONT( COL_1, ROW_3 - 4 ); Size = MAP_APPFONT( COL_2-COL_1, 16 ); Wordbreak = TRUE; @@ -461,12 +492,14 @@ TabPage RID_SVXPAGE_INET_SECURITY }; PushButton PB_SEC_CONNECTIONS { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SECURITY:PB_SEC_CONNECTIONS"; Pos = MAP_APPFONT( COL_3, ROW_3-1 ); Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); Text [ en-US ] = "Connections..."; }; CheckBox CB_SEC_MASTERPASSWORD { + HelpID = "cui:CheckBox:RID_SVXPAGE_INET_SECURITY:CB_SEC_MASTERPASSWORD"; Pos = MAP_APPFONT( COL_1a, ROW_4 ); Size = MAP_APPFONT( COL_2-COL_1a, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "Protected by a master password (recommended)"; @@ -480,6 +513,7 @@ TabPage RID_SVXPAGE_INET_SECURITY }; PushButton PB_SEC_MASTERPASSWORD { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SECURITY:PB_SEC_MASTERPASSWORD"; Pos = MAP_APPFONT( COL_3, ROW_4a ); Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); Text [ en-US ] = "Master Password..."; @@ -499,6 +533,7 @@ TabPage RID_SVXPAGE_INET_SECURITY }; PushButton PB_SEC_MACROSEC { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_SECURITY:PB_SEC_MACROSEC"; Pos = MAP_APPFONT( COL_3, ROW_6-2 ); Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); Text [ en-US ] = "Macro Security..."; @@ -519,6 +554,7 @@ ErrorBox RID_SVXERR_OPT_PROXYPORTS ModalDialog RID_SVXDLG_OPT_JAVASCRIPT_DISABLE { + HelpID = "cui:ModalDialog:RID_SVXDLG_OPT_JAVASCRIPT_DISABLE"; OutputSize = TRUE; Size = MAP_APPFONT( 150, 81 ); Moveable = TRUE; @@ -537,6 +573,7 @@ ModalDialog RID_SVXDLG_OPT_JAVASCRIPT_DISABLE }; CheckBox CB_JSCPT_DISABLE { + HelpID = "cui:CheckBox:RID_SVXDLG_OPT_JAVASCRIPT_DISABLE:CB_JSCPT_DISABLE"; Pos = MAP_APPFONT( 39, 45 ); Size = MAP_APPFONT( 195, 12 ); Hide = TRUE; @@ -587,6 +624,7 @@ TabPage RID_SVXPAGE_INET_MAIL Edit ED_MAILERURL { + HelpID = "cui:Edit:RID_SVXPAGE_INET_MAIL:ED_MAILERURL"; Pos = MAP_APPFONT ( 60 , 18 ) ; Size = MAP_APPFONT ( 171 , 12 ) ; Border = TRUE; @@ -594,6 +632,7 @@ TabPage RID_SVXPAGE_INET_MAIL PushButton PB_MAILERURL { + HelpID = "cui:PushButton:RID_SVXPAGE_INET_MAIL:PB_MAILERURL"; Pos = MAP_APPFONT ( 234 , 17 ) ; Size = MAP_APPFONT ( 14 , 14 ) ; Text = "..." ; diff --git a/cui/source/options/optjava.cxx b/cui/source/options/optjava.cxx index f0cad8367ca6..14f122cfe78f 100644 --- a/cui/source/options/optjava.cxx +++ b/cui/source/options/optjava.cxx @@ -63,46 +63,6 @@ using namespace ::com::sun::star::ucb; using namespace ::com::sun::star::ui::dialogs; using namespace ::com::sun::star::uno; -// class SvxJavaTable ---------------------------------------------------- - -SvxJavaTable::SvxJavaTable( Window* _pParent, const ResId& _rId ) : - - SvxSimpleTable( _pParent, _rId ) - -{ -} - -SvxJavaTable::~SvxJavaTable() -{ -} - -void SvxJavaTable::SetTabs() -{ - SvxSimpleTable::SetTabs(); -} - -void SvxJavaTable::MouseButtonUp( const MouseEvent& _rMEvt ) -{ - m_aCurMousePoint = _rMEvt.GetPosPixel(); - SvxSimpleTable::MouseButtonUp( _rMEvt ); -} - -void SvxJavaTable::KeyInput( const KeyEvent& rKEvt ) -{ - if ( !rKEvt.GetKeyCode().GetModifier() && KEY_SPACE == rKEvt.GetKeyCode().GetCode() ) - { - SvLBoxEntry* pEntry = FirstSelected(); - if ( GetCheckButtonState( pEntry ) == SV_BUTTON_UNCHECKED ) - { - SetCheckButtonState( pEntry, SV_BUTTON_CHECKED ); - GetCheckButtonHdl().Call( NULL ); - return ; - } - } - - SvxSimpleTable::KeyInput( rKEvt ); -} - // ----------------------------------------------------------------------- bool areListsEqual( const Sequence< ::rtl::OUString >& rListA, const Sequence< ::rtl::OUString >& rListB ) @@ -236,7 +196,7 @@ SvxJavaOptionsPage::~SvxJavaOptionsPage() IMPL_LINK( SvxJavaOptionsPage, EnableHdl_Impl, CheckBox *, EMPTYARG ) { - BOOL bEnable = m_aJavaEnableCB.IsChecked(); + sal_Bool bEnable = m_aJavaEnableCB.IsChecked(); m_aJavaFoundLabel.Enable( bEnable ); m_aJavaPathText.Enable( bEnable ); m_aAddBtn.Enable( bEnable ); @@ -538,7 +498,7 @@ void SvxJavaOptionsPage::AddJRE( JavaInfo* _pInfo ) void SvxJavaOptionsPage::HandleCheckEntry( SvLBoxEntry* _pEntry ) { - m_aJavaList.Select( _pEntry, TRUE ); + m_aJavaList.Select( _pEntry, sal_True ); SvButtonState eState = m_aJavaList.GetCheckButtonState( _pEntry ); if ( SV_BUTTON_CHECKED == eState ) @@ -636,9 +596,9 @@ SfxTabPage* SvxJavaOptionsPage::Create( Window* pParent, const SfxItemSet& rAttr // ----------------------------------------------------------------------- -BOOL SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) +sal_Bool SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; javaFrameworkError eErr = JFW_E_NONE; if ( m_pParamDlg ) { @@ -654,7 +614,7 @@ BOOL SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) "SvxJavaOptionsPage::FillItemSet(): error in jfw_setVMParameters" ); pParamArrIter = pParamArr; rtl_freeMemory( pParamArr ); - bModified = TRUE; + bModified = sal_True; } if ( m_pPathDlg ) @@ -665,17 +625,17 @@ BOOL SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) eErr = jfw_setUserClassPath( sPath.pData ); DBG_ASSERT( JFW_E_NONE == eErr, "SvxJavaOptionsPage::FillItemSet(): error in jfw_setUserClassPath" ); - bModified = TRUE; + bModified = sal_True; } } - ULONG nCount = m_aJavaList.GetEntryCount(); - for ( ULONG i = 0; i < nCount; ++i ) + sal_uLong nCount = m_aJavaList.GetEntryCount(); + for ( sal_uLong i = 0; i < nCount; ++i ) { if ( m_aJavaList.GetCheckButtonState( m_aJavaList.GetEntry(i) ) == SV_BUTTON_CHECKED ) { JavaInfo* pInfo = NULL; - if ( i < static_cast< ULONG >( m_nInfoSize ) ) + if ( i < static_cast< sal_uLong >( m_nInfoSize ) ) pInfo = m_parJavaInfo[i]; else pInfo = m_aAddedInfos[ i - m_nInfoSize ]; @@ -700,7 +660,7 @@ BOOL SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) eErr = jfw_setSelectedJRE( pInfo ); DBG_ASSERT( JFW_E_NONE == eErr, "SvxJavaOptionsPage::FillItemSet(): error in jfw_setSelectedJRE" ); - bModified = TRUE; + bModified = sal_True; } } jfw_freeJavaInfo( pSelectedJava ); @@ -717,7 +677,7 @@ BOOL SvxJavaOptionsPage::FillItemSet( SfxItemSet& /*rCoreSet*/ ) eErr = jfw_setEnabled( m_aJavaEnableCB.IsChecked() ); DBG_ASSERT( JFW_E_NONE == eErr, "SvxJavaOptionsPage::FillItemSet(): error in jfw_setEnabled" ); - bModified = TRUE; + bModified = sal_True; } return bModified; @@ -802,7 +762,7 @@ IMPL_LINK( SvxJavaParameterDlg, AssignHdl_Impl, PushButton *, EMPTYARG ) String sParam = STRIM( m_aParameterEdit.GetText() ); if ( sParam.Len() > 0 ) { - USHORT nPos = m_aAssignedList.GetEntryPos( sParam ); + sal_uInt16 nPos = m_aAssignedList.GetEntryPos( sParam ); if ( LISTBOX_ENTRY_NOTFOUND == nPos ) nPos = m_aAssignedList.InsertEntry( sParam ); m_aAssignedList.SelectEntryPos( nPos ); @@ -826,7 +786,7 @@ IMPL_LINK( SvxJavaParameterDlg, SelectHdl_Impl, ListBox *, EMPTYARG ) IMPL_LINK( SvxJavaParameterDlg, DblClickHdl_Impl, ListBox *, EMPTYARG ) { - USHORT nPos = m_aAssignedList.GetSelectEntryPos(); + sal_uInt16 nPos = m_aAssignedList.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) m_aParameterEdit.SetText( m_aAssignedList.GetEntry( nPos ) ); return 0; @@ -836,11 +796,11 @@ IMPL_LINK( SvxJavaParameterDlg, DblClickHdl_Impl, ListBox *, EMPTYARG ) IMPL_LINK( SvxJavaParameterDlg, RemoveHdl_Impl, PushButton *, EMPTYARG ) { - USHORT nPos = m_aAssignedList.GetSelectEntryPos(); + sal_uInt16 nPos = m_aAssignedList.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { m_aAssignedList.RemoveEntry( nPos ); - USHORT nCount = m_aAssignedList.GetEntryCount(); + sal_uInt16 nCount = m_aAssignedList.GetEntryCount(); if ( nCount ) { if ( nPos >= nCount ) @@ -866,10 +826,10 @@ short SvxJavaParameterDlg::Execute() Sequence< ::rtl::OUString > SvxJavaParameterDlg::GetParameters() const { - USHORT nCount = m_aAssignedList.GetEntryCount(); + sal_uInt16 nCount = m_aAssignedList.GetEntryCount(); Sequence< ::rtl::OUString > aParamList( nCount ); ::rtl::OUString* pArray = aParamList.getArray(); - for ( USHORT i = 0; i < nCount; ++i ) + for ( sal_uInt16 i = 0; i < nCount; ++i ) pArray[i] = ::rtl::OUString( m_aAssignedList.GetEntry(i) ); return aParamList; } @@ -879,7 +839,7 @@ Sequence< ::rtl::OUString > SvxJavaParameterDlg::GetParameters() const void SvxJavaParameterDlg::SetParameters( Sequence< ::rtl::OUString >& rParams ) { m_aAssignedList.Clear(); - ULONG i, nCount = rParams.getLength(); + sal_uLong i, nCount = rParams.getLength(); const ::rtl::OUString* pArray = rParams.getConstArray(); for ( i = 0; i < nCount; ++i ) { @@ -944,7 +904,7 @@ SvxJavaClassPathDlg::SvxJavaClassPathDlg( Window* pParent ) : SvxJavaClassPathDlg::~SvxJavaClassPathDlg() { - USHORT i, nCount = m_aPathList.GetEntryCount(); + sal_uInt16 i, nCount = m_aPathList.GetEntryCount(); for ( i = 0; i < nCount; ++i ) delete static_cast< String* >( m_aPathList.GetEntryData(i) ); } @@ -972,7 +932,7 @@ IMPL_LINK( SvxJavaClassPathDlg, AddArchiveHdl_Impl, PushButton *, EMPTYARG ) String sFile = aURL.getFSysPath( INetURLObject::FSYS_DETECT ); if ( !IsPathDuplicate( sURL ) ) { - USHORT nPos = m_aPathList.InsertEntry( sFile, SvFileInformationManager::GetImage( aURL, false ) ); + sal_uInt16 nPos = m_aPathList.InsertEntry( sFile, SvFileInformationManager::GetImage( aURL, false ) ); m_aPathList.SelectEntryPos( nPos ); } else @@ -1010,7 +970,7 @@ IMPL_LINK( SvxJavaClassPathDlg, AddPathHdl_Impl, PushButton *, EMPTYARG ) String sNewFolder = aURL.getFSysPath( INetURLObject::FSYS_DETECT ); if ( !IsPathDuplicate( sFolderURL ) ) { - USHORT nPos = m_aPathList.InsertEntry( sNewFolder, SvFileInformationManager::GetImage( aURL, false ) ); + sal_uInt16 nPos = m_aPathList.InsertEntry( sNewFolder, SvFileInformationManager::GetImage( aURL, false ) ); m_aPathList.SelectEntryPos( nPos ); } else @@ -1028,11 +988,11 @@ IMPL_LINK( SvxJavaClassPathDlg, AddPathHdl_Impl, PushButton *, EMPTYARG ) IMPL_LINK( SvxJavaClassPathDlg, RemoveHdl_Impl, PushButton *, EMPTYARG ) { - USHORT nPos = m_aPathList.GetSelectEntryPos(); + sal_uInt16 nPos = m_aPathList.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { m_aPathList.RemoveEntry( nPos ); - USHORT nCount = m_aPathList.GetEntryCount(); + sal_uInt16 nCount = m_aPathList.GetEntryCount(); if ( nCount ) { if ( nPos >= nCount ) @@ -1059,8 +1019,8 @@ bool SvxJavaClassPathDlg::IsPathDuplicate( const String& _rPath ) { bool bRet = false; INetURLObject aFileObj( _rPath ); - USHORT nCount = m_aPathList.GetEntryCount(); - for ( USHORT i = 0; i < nCount; ++i ) + sal_uInt16 nCount = m_aPathList.GetEntryCount(); + for ( sal_uInt16 i = 0; i < nCount; ++i ) { INetURLObject aOtherObj( m_aPathList.GetEntry(i), INetURLObject::FSYS_DETECT ); if ( aOtherObj == aFileObj ) @@ -1078,8 +1038,8 @@ bool SvxJavaClassPathDlg::IsPathDuplicate( const String& _rPath ) String SvxJavaClassPathDlg::GetClassPath() const { String sPath; - USHORT nCount = m_aPathList.GetEntryCount(); - for ( USHORT i = 0; i < nCount; ++i ) + sal_uInt16 nCount = m_aPathList.GetEntryCount(); + for ( sal_uInt16 i = 0; i < nCount; ++i ) { if ( sPath.Len() > 0 ) sPath += CLASSPATH_DELIMITER; diff --git a/cui/source/options/optjava.hxx b/cui/source/options/optjava.hxx index ac03588b9697..2c9681a29ce8 100644 --- a/cui/source/options/optjava.hxx +++ b/cui/source/options/optjava.hxx @@ -48,27 +48,6 @@ typedef struct _JavaInfo JavaInfo; class SvxJavaParameterDlg; class SvxJavaClassPathDlg; -// class SvxJavaTable ---------------------------------------------------- - -class SvxJavaTable : public SvxSimpleTable -{ - using SvxSimpleTable::SetTabs; -private: - Point m_aCurMousePoint; - -protected: - virtual void SetTabs(); - virtual void MouseButtonUp( const MouseEvent& _rMEvt ); - virtual void KeyInput( const KeyEvent& rKEvt ); - -public: - SvxJavaTable( Window* _pParent, const ResId& _rId ); - ~SvxJavaTable(); - - - inline Point GetCurMousePoint() { return m_aCurMousePoint; } -}; - // class SvxJavaOptionsPage ---------------------------------------------- class SvxJavaOptionsPage : public SfxTabPage @@ -126,7 +105,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); }; diff --git a/cui/source/options/optjava.src b/cui/source/options/optjava.src index 0d55fd6f64f8..db052d1c5fd8 100644 --- a/cui/source/options/optjava.src +++ b/cui/source/options/optjava.src @@ -50,6 +50,7 @@ TabPage RID_SVXPAGE_OPTIONS_JAVA }; CheckBox CB_JAVA_ENABLE { + HelpID = "cui:CheckBox:RID_SVXPAGE_OPTIONS_JAVA:CB_JAVA_ENABLE"; Pos = MAP_APPFONT ( 12, 14 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Text [ en-US ] = "~Use a Java runtime environment" ; @@ -75,18 +76,21 @@ TabPage RID_SVXPAGE_OPTIONS_JAVA }; PushButton PB_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_OPTIONS_JAVA:PB_ADD"; Pos = MAP_APPFONT ( 204 , 38 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; }; PushButton PB_PARAMETER { + HelpID = "cui:PushButton:RID_SVXPAGE_OPTIONS_JAVA:PB_PARAMETER"; Pos = MAP_APPFONT ( 204 , 55 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Parameters..." ; }; PushButton PB_CLASSPATH { + HelpID = "cui:PushButton:RID_SVXPAGE_OPTIONS_JAVA:PB_CLASSPATH"; Pos = MAP_APPFONT ( 204 , 72 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Class Path..." ; @@ -135,12 +139,14 @@ ModalDialog RID_SVXDLG_JAVA_PARAMETER }; Edit ED_PARAMETER { + HelpID = "cui:Edit:RID_SVXDLG_JAVA_PARAMETER:ED_PARAMETER"; Pos = MAP_APPFONT ( 6 , 15 ) ; Size = MAP_APPFONT ( 202 , 12 ) ; Border = TRUE ; }; PushButton PB_ASSIGN { + HelpID = "cui:PushButton:RID_SVXDLG_JAVA_PARAMETER:PB_ASSIGN"; Pos = MAP_APPFONT ( 214 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Assign" ; @@ -153,6 +159,7 @@ ModalDialog RID_SVXDLG_JAVA_PARAMETER }; ListBox LB_ASSIGNED { + HelpID = "cui:ListBox:RID_SVXDLG_JAVA_PARAMETER:LB_ASSIGNED"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 42 ) ; Size = MAP_APPFONT ( 202 , 53 ) ; @@ -166,6 +173,7 @@ ModalDialog RID_SVXDLG_JAVA_PARAMETER }; PushButton PB_REMOVE { + HelpID = "cui:PushButton:RID_SVXDLG_JAVA_PARAMETER:PB_REMOVE"; Pos = MAP_APPFONT ( 214 , 42 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Remove" ; @@ -211,6 +219,7 @@ ModalDialog RID_SVXDLG_JAVA_CLASSPATH }; ListBox LB_PATH { + HelpID = "cui:ListBox:RID_SVXDLG_JAVA_CLASSPATH:LB_PATH"; Pos = MAP_APPFONT ( 6 , 14 ) ; Size = MAP_APPFONT ( 172 , 72 ) ; Border = TRUE ; @@ -218,18 +227,21 @@ ModalDialog RID_SVXDLG_JAVA_CLASSPATH }; PushButton PB_ADDARCHIVE { + HelpID = "cui:PushButton:RID_SVXDLG_JAVA_CLASSPATH:PB_ADDARCHIVE"; Pos = MAP_APPFONT ( 184 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add Archive..." ; }; PushButton PB_ADDPATH { + HelpID = "cui:PushButton:RID_SVXDLG_JAVA_CLASSPATH:PB_ADDPATH"; Pos = MAP_APPFONT ( 184 , 31 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "Add ~Folder" ; }; PushButton PB_REMOVE_PATH { + HelpID = "cui:PushButton:RID_SVXDLG_JAVA_CLASSPATH:PB_REMOVE_PATH"; Pos = MAP_APPFONT ( 184 , 48 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Remove" ; diff --git a/cui/source/options/optjsearch.cxx b/cui/source/options/optjsearch.cxx index 6de0b37a187d..900d7445fae3 100644 --- a/cui/source/options/optjsearch.cxx +++ b/cui/source/options/optjsearch.cxx @@ -64,7 +64,7 @@ SvxJSearchOptionsPage::SvxJSearchOptionsPage( Window* pParent, const SfxItemSet& aIgnoreMiddleDot ( this, CUI_RES( CB_IGNORE_MIDDLE_DOT ) ) { FreeResource(); - bSaveOptions = TRUE; + bSaveOptions = sal_True; nTransliterationFlags = 0x00000000; } @@ -80,9 +80,9 @@ SfxTabPage* SvxJSearchOptionsPage::Create( Window* pParent, const SfxItemSet& r } -void SvxJSearchOptionsPage::SetTransliterationFlags( INT32 nSettings ) +void SvxJSearchOptionsPage::SetTransliterationFlags( sal_Int32 nSettings ) { - BOOL bVal = 0 != (nSettings & TransliterationModules_IGNORE_CASE); + sal_Bool bVal = 0 != (nSettings & TransliterationModules_IGNORE_CASE); aMatchCase .Check( bVal ); //! treat as equal uppercase/lowercase bVal = 0 != (nSettings & TransliterationModules_IGNORE_WIDTH); aMatchFullHalfWidth .Check( bVal ); @@ -125,9 +125,9 @@ void SvxJSearchOptionsPage::SetTransliterationFlags( INT32 nSettings ) } -INT32 SvxJSearchOptionsPage::GetTransliterationFlags_Impl() +sal_Int32 SvxJSearchOptionsPage::GetTransliterationFlags_Impl() { - INT32 nTmp = 0; + sal_Int32 nTmp = 0; if (aMatchCase.IsChecked()) //! treat as equal uppercase/lowercase nTmp |= TransliterationModules_IGNORE_CASE; if (aMatchFullHalfWidth.IsChecked()) @@ -223,153 +223,153 @@ void SvxJSearchOptionsPage::Reset( const SfxItemSet& ) } -BOOL SvxJSearchOptionsPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxJSearchOptionsPage::FillItemSet( SfxItemSet& ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; - INT32 nOldVal = nTransliterationFlags; + sal_Int32 nOldVal = nTransliterationFlags; nTransliterationFlags = GetTransliterationFlags_Impl(); bModified = nOldVal != nTransliterationFlags; if (!IsSaveOptions()) return bModified; - bModified = FALSE; + bModified = sal_False; SvtSearchOptions aOpt; - BOOL bNewVal, bChanged; + sal_Bool bNewVal, bChanged; bNewVal = aMatchCase.IsChecked(); //! treat as equal uppercase/lowercase bChanged = bNewVal != aMatchCase.GetSavedValue(); if (bChanged) { aOpt.SetMatchCase(!bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchFullHalfWidth.IsChecked(); bChanged = bNewVal != aMatchFullHalfWidth.GetSavedValue(); if (bChanged) { aOpt.SetMatchFullHalfWidthForms( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchHiraganaKatakana.IsChecked(); bChanged = bNewVal != aMatchHiraganaKatakana.GetSavedValue(); if (bChanged) { aOpt.SetMatchHiraganaKatakana( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchContractions.IsChecked(); bChanged = bNewVal != aMatchContractions.GetSavedValue(); if (bChanged) { aOpt.SetMatchContractions( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchMinusDashChoon.IsChecked(); bChanged = bNewVal != aMatchMinusDashChoon.GetSavedValue(); if (bChanged) { aOpt.SetMatchMinusDashChoon( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchRepeatCharMarks.IsChecked(); bChanged = bNewVal != aMatchRepeatCharMarks.GetSavedValue(); if (bChanged) { aOpt.SetMatchRepeatCharMarks( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchVariantFormKanji.IsChecked(); bChanged = bNewVal != aMatchVariantFormKanji.GetSavedValue(); if (bChanged) { aOpt.SetMatchVariantFormKanji( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchOldKanaForms.IsChecked(); bChanged = bNewVal != aMatchOldKanaForms.GetSavedValue(); if (bChanged) { aOpt.SetMatchOldKanaForms( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchDiziDuzu.IsChecked(); bChanged = bNewVal != aMatchDiziDuzu.GetSavedValue(); if (bChanged) { aOpt.SetMatchDiziDuzu( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchBavaHafa.IsChecked(); bChanged = bNewVal != aMatchBavaHafa.GetSavedValue(); if (bChanged) { aOpt.SetMatchBavaHafa( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchTsithichiDhizi.IsChecked(); bChanged = bNewVal != aMatchTsithichiDhizi.GetSavedValue(); if (bChanged) { aOpt.SetMatchTsithichiDhizi( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchHyuiyuByuvyu.IsChecked(); bChanged = bNewVal != aMatchHyuiyuByuvyu.GetSavedValue(); if (bChanged) { aOpt.SetMatchHyuiyuByuvyu( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchSesheZeje.IsChecked(); bChanged = bNewVal != aMatchSesheZeje.GetSavedValue(); if (bChanged) { aOpt.SetMatchSesheZeje( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchIaiya.IsChecked(); bChanged = bNewVal != aMatchIaiya.GetSavedValue(); if (bChanged) { aOpt.SetMatchIaiya( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchKiku.IsChecked(); bChanged = bNewVal != aMatchKiku.GetSavedValue(); if (bChanged) { aOpt.SetMatchKiku( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aIgnorePunctuation.IsChecked(); bChanged = bNewVal != aIgnorePunctuation.GetSavedValue(); if (bChanged) { aOpt.SetIgnorePunctuation( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aIgnoreWhitespace.IsChecked(); bChanged = bNewVal != aIgnoreWhitespace.GetSavedValue(); if (bChanged) { aOpt.SetIgnoreWhitespace( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aMatchProlongedSoundMark.IsChecked(); bChanged = bNewVal != aMatchProlongedSoundMark.GetSavedValue(); if (bChanged) { aOpt.SetIgnoreProlongedSoundMark( bNewVal ); - bModified = TRUE; + bModified = sal_True; } bNewVal = aIgnoreMiddleDot.IsChecked(); bChanged = bNewVal != aIgnoreMiddleDot.GetSavedValue(); if (bChanged) { aOpt.SetIgnoreMiddleDot( bNewVal ); - bModified = TRUE; + bModified = sal_True; } return bModified; diff --git a/cui/source/options/optjsearch.hxx b/cui/source/options/optjsearch.hxx index 5ec12621cd40..e8d5a7845aa7 100644 --- a/cui/source/options/optjsearch.hxx +++ b/cui/source/options/optjsearch.hxx @@ -63,10 +63,10 @@ private: CheckBox aIgnoreWhitespace; CheckBox aIgnoreMiddleDot; - INT32 nTransliterationFlags; - BOOL bSaveOptions; + sal_Int32 nTransliterationFlags; + sal_Bool bSaveOptions; - INT32 GetTransliterationFlags_Impl(); + sal_Int32 GetTransliterationFlags_Impl(); protected: SvxJSearchOptionsPage( Window* pParent, const SfxItemSet& rSet ); @@ -77,13 +77,13 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); - BOOL IsSaveOptions() const { return bSaveOptions; } - void EnableSaveOptions( BOOL bVal ) { bSaveOptions = bVal; } + sal_Bool IsSaveOptions() const { return bSaveOptions; } + void EnableSaveOptions( sal_Bool bVal ) { bSaveOptions = bVal; } - INT32 GetTransliterationFlags() const { return nTransliterationFlags; } - void SetTransliterationFlags( INT32 nSettings ); + sal_Int32 GetTransliterationFlags() const { return nTransliterationFlags; } + void SetTransliterationFlags( sal_Int32 nSettings ); }; ////////////////////////////////////////////////////////////////////// diff --git a/cui/source/options/optjsearch.src b/cui/source/options/optjsearch.src index 98963647e9c4..463e68881e4c 100644 --- a/cui/source/options/optjsearch.src +++ b/cui/source/options/optjsearch.src @@ -45,96 +45,112 @@ TabPage RID_SVXPAGE_JSEARCH_OPTIONS }; CheckBox CB_MATCH_CASE { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_CASE"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~uppercase/lowercase"; }; CheckBox CB_MATCH_FULL_HALF_WIDTH { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_FULL_HALF_WIDTH"; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~full-width/half-width forms"; }; CheckBox CB_MATCH_HIRAGANA_KATAKANA { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_HIRAGANA_KATAKANA"; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~hiragana/katakana"; }; CheckBox CB_MATCH_CONTRACTIONS { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_CONTRACTIONS"; Pos = MAP_APPFONT ( 12 , 56 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~contractions (yo-on, sokuon)"; }; CheckBox CB_MATCH_MINUS_DASH_CHOON { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_MINUS_DASH_CHOON"; Pos = MAP_APPFONT ( 12 , 70 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~minus/dash/cho-on"; }; CheckBox CB_MATCH_REPEAT_CHAR_MARKS { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_REPEAT_CHAR_MARKS"; Pos = MAP_APPFONT ( 12 , 84 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "'re~peat character' marks"; }; CheckBox CB_MATCH_VARIANT_FORM_KANJI { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_VARIANT_FORM_KANJI"; Pos = MAP_APPFONT ( 12 , 98 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~variant-form kanji (itaiji)"; }; CheckBox CB_MATCH_OLD_KANA_FORMS { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_OLD_KANA_FORMS"; Pos = MAP_APPFONT ( 12 , 112) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~old Kana forms"; }; CheckBox CB_MATCH_DIZI_DUZU { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_DIZI_DUZU"; Pos = MAP_APPFONT ( 136 , 14 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~di/zi, du/zu"; }; CheckBox CB_MATCH_BAVA_HAFA { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_BAVA_HAFA"; Pos = MAP_APPFONT ( 136 , 28 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~ba/va, ha/fa"; }; CheckBox CB_MATCH_TSITHICHI_DHIZI { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_TSITHICHI_DHIZI"; Pos = MAP_APPFONT ( 136 , 42 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~tsi/thi/chi, dhi/zi"; }; CheckBox CB_MATCH_HYUFYU_BYUVYU { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_HYUFYU_BYUVYU"; Pos = MAP_APPFONT ( 136 , 56 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "h~yu/fyu, byu/vyu"; }; CheckBox CB_MATCH_SESHE_ZEJE { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_SESHE_ZEJE"; Pos = MAP_APPFONT ( 136 , 70 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~se/she, ze/je"; }; CheckBox CB_MATCH_IAIYA { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_IAIYA"; Pos = MAP_APPFONT ( 136 , 84 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~ia/iya (piano/piyano)"; }; CheckBox CB_MATCH_KIKU { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_KIKU"; Pos = MAP_APPFONT ( 136 , 98 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~ki/ku (tekisuto/tekusuto)"; }; CheckBox CB_MATCH_PROLONGED_SOUNDMARK { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_MATCH_PROLONGED_SOUNDMARK"; Pos = MAP_APPFONT ( 136 , 112 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "Prolon~ged vowels (ka-/kaa)"; @@ -147,18 +163,21 @@ TabPage RID_SVXPAGE_JSEARCH_OPTIONS }; CheckBox CB_IGNORE_PUNCTUATION { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_IGNORE_PUNCTUATION"; Pos = MAP_APPFONT ( 12 , 139 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "Pu~nctuation characters"; }; CheckBox CB_IGNORE_WHITESPACES { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_IGNORE_WHITESPACES"; Pos = MAP_APPFONT ( 12 , 153 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "~Whitespace characters"; }; CheckBox CB_IGNORE_MIDDLE_DOT { + HelpID = "cui:CheckBox:RID_SVXPAGE_JSEARCH_OPTIONS:CB_IGNORE_MIDDLE_DOT"; Pos = MAP_APPFONT ( 136 , 139 ) ; Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "Midd~le dots"; diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx index caa0f8c66776..49899f3c62ae 100644 --- a/cui/source/options/optlingu.cxx +++ b/cui/source/options/optlingu.cxx @@ -103,13 +103,13 @@ static const sal_Char cThes[] = SN_THESAURUS; // static ---------------------------------------------------------------- -static Sequence< INT16 > lcl_LocaleSeqToLangSeq( const Sequence< Locale > &rSeq ) +static Sequence< sal_Int16 > lcl_LocaleSeqToLangSeq( const Sequence< Locale > &rSeq ) { - INT32 nLen = rSeq.getLength(); - Sequence< INT16 > aRes( nLen ); - INT16 *pRes = aRes.getArray(); + sal_Int32 nLen = rSeq.getLength(); + Sequence< sal_Int16 > aRes( nLen ); + sal_Int16 *pRes = aRes.getArray(); const Locale *pSeq = rSeq.getConstArray(); - for (INT32 i = 0; i < nLen; ++i) + for (sal_Int32 i = 0; i < nLen; ++i) { pRes[i] = SvxLocaleToLanguage( pSeq[i] ); } @@ -117,25 +117,25 @@ static Sequence< INT16 > lcl_LocaleSeqToLangSeq( const Sequence< Locale > &rSeq } -static BOOL lcl_SeqHasLang( const Sequence< INT16 > &rSeq, INT16 nLang ) +static sal_Bool lcl_SeqHasLang( const Sequence< sal_Int16 > &rSeq, sal_Int16 nLang ) { - INT32 nLen = rSeq.getLength(); - const INT16 *pLang = rSeq.getConstArray(); - INT32 nPos = -1; - for (INT32 i = 0; i < nLen && nPos < 0; ++i) + sal_Int32 nLen = rSeq.getLength(); + const sal_Int16 *pLang = rSeq.getConstArray(); + sal_Int32 nPos = -1; + for (sal_Int32 i = 0; i < nLen && nPos < 0; ++i) { if (nLang == pLang[i]) nPos = i; } - return nPos < 0 ? FALSE : TRUE; + return nPos < 0 ? sal_False : sal_True; } -static INT32 lcl_SeqGetEntryPos( +static sal_Int32 lcl_SeqGetEntryPos( const Sequence< OUString > &rSeq, const OUString &rEntry ) { - INT32 i; - INT32 nLen = rSeq.getLength(); + sal_Int32 i; + sal_Int32 nLen = rSeq.getLength(); const OUString *pItem = rSeq.getConstArray(); for (i = 0; i < nLen; ++i) { @@ -206,21 +206,21 @@ sal_Bool KillFile_Impl( const String& rURL ) // c: 1 -> checked 0 -> unchecked // n: index -#define TYPE_SPELL (BYTE)1 -#define TYPE_GRAMMAR (BYTE)2 -#define TYPE_HYPH (BYTE)3 -#define TYPE_THES (BYTE)4 +#define TYPE_SPELL (sal_uInt8)1 +#define TYPE_GRAMMAR (sal_uInt8)2 +#define TYPE_HYPH (sal_uInt8)3 +#define TYPE_THES (sal_uInt8)4 class ModuleUserData_Impl { - BOOL bParent; - BOOL bIsChecked; - BYTE nType; - BYTE nIndex; + sal_Bool bParent; + sal_Bool bIsChecked; + sal_uInt8 nType; + sal_uInt8 nIndex; String sImplName; public: - ModuleUserData_Impl( String sImpName, BOOL bIsParent, BOOL bChecked, BYTE nSetType, BYTE nSetIndex ) : + ModuleUserData_Impl( String sImpName, sal_Bool bIsParent, sal_Bool bChecked, sal_uInt8 nSetType, sal_uInt8 nSetIndex ) : bParent(bIsParent), bIsChecked(bChecked), nType(nSetType), @@ -228,11 +228,11 @@ public: sImplName(sImpName) { } - BOOL IsParent() const {return bParent;} - BYTE GetType() const {return nType;} - BOOL IsChecked() const {return bIsChecked;} - BYTE GetIndex() const {return nIndex;} - void SetIndex(BYTE nSet) {nIndex = nSet;} + sal_Bool IsParent() const {return bParent;} + sal_uInt8 GetType() const {return nType;} + sal_Bool IsChecked() const {return bIsChecked;} + sal_uInt8 GetIndex() const {return nIndex;} + void SetIndex(sal_uInt8 nSet) {nIndex = nSet;} const String& GetImplName() const {return sImplName;} }; @@ -242,45 +242,45 @@ public: // class DicUserData { - ULONG nVal; + sal_uLong nVal; public: - DicUserData( ULONG nUserData ) : nVal( nUserData ) {} - DicUserData( USHORT nEID, - BOOL bChecked, BOOL bEditable, BOOL bDeletable ); + DicUserData( sal_uLong nUserData ) : nVal( nUserData ) {} + DicUserData( sal_uInt16 nEID, + sal_Bool bChecked, sal_Bool bEditable, sal_Bool bDeletable ); - ULONG GetUserData() const { return nVal; } - USHORT GetEntryId() const { return (USHORT)(nVal >> 16); } - BOOL IsChecked() const { return (BOOL)(nVal >> 8) & 0x01; } - BOOL IsEditable() const { return (BOOL)(nVal >> 9) & 0x01; } - BOOL IsDeletable() const { return (BOOL)(nVal >> 10) & 0x01; } + sal_uLong GetUserData() const { return nVal; } + sal_uInt16 GetEntryId() const { return (sal_uInt16)(nVal >> 16); } + sal_Bool IsChecked() const { return (sal_Bool)(nVal >> 8) & 0x01; } + sal_Bool IsEditable() const { return (sal_Bool)(nVal >> 9) & 0x01; } + sal_Bool IsDeletable() const { return (sal_Bool)(nVal >> 10) & 0x01; } - void SetChecked( BOOL bVal ); + void SetChecked( sal_Bool bVal ); }; DicUserData::DicUserData( - USHORT nEID, - BOOL bChecked, BOOL bEditable, BOOL bDeletable ) + sal_uInt16 nEID, + sal_Bool bChecked, sal_Bool bEditable, sal_Bool bDeletable ) { DBG_ASSERT( nEID < 65000, "Entry Id out of range" ); - nVal = ((ULONG)(0xFFFF & nEID) << 16) | - ((ULONG)(bChecked ? 1 : 0) << 8) | - ((ULONG)(bEditable ? 1 : 0) << 9) | - ((ULONG)(bDeletable ? 1 : 0) << 10); + nVal = ((sal_uLong)(0xFFFF & nEID) << 16) | + ((sal_uLong)(bChecked ? 1 : 0) << 8) | + ((sal_uLong)(bEditable ? 1 : 0) << 9) | + ((sal_uLong)(bDeletable ? 1 : 0) << 10); } -void DicUserData::SetChecked( BOOL bVal ) +void DicUserData::SetChecked( sal_Bool bVal ) { nVal &= ~(1UL << 8); - nVal |= (ULONG)(bVal ? 1 : 0) << 8; + nVal |= (sal_uLong)(bVal ? 1 : 0) << 8; } // class BrwString_Impl ------------------------------------------------- -void lcl_SetCheckButton( SvLBoxEntry* pEntry, BOOL bCheck ) +void lcl_SetCheckButton( SvLBoxEntry* pEntry, sal_Bool bCheck ) { SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetFirstItem(SV_ITEM_ID_LBOXBUTTON)); @@ -299,14 +299,14 @@ class BrwStringDic_Impl : public SvLBoxString { public: - BrwStringDic_Impl( SvLBoxEntry* pEntry, USHORT nFlags, + BrwStringDic_Impl( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr ) : SvLBoxString( pEntry, nFlags, rStr ) {} - virtual void Paint( const Point& rPos, SvLBox& rDev, USHORT nFlags, + virtual void Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry); }; -void BrwStringDic_Impl::Paint( const Point& rPos, SvLBox& rDev, USHORT, +void BrwStringDic_Impl::Paint( const Point& rPos, SvLBox& rDev, sal_uInt16, SvLBoxEntry* pEntry ) { ModuleUserData_Impl* pData = (ModuleUserData_Impl*)pEntry->GetUserData(); @@ -400,52 +400,52 @@ static inline String lcl_GetPropertyName( EID_OPTIONS eEntryId ) class OptionsUserData { - ULONG nVal; + sal_uLong nVal; void SetModified(); public: - OptionsUserData( ULONG nUserData ) : nVal( nUserData ) {} - OptionsUserData( USHORT nEID, - BOOL bHasNV, USHORT nNumVal, - BOOL bCheckable, BOOL bChecked ); - - ULONG GetUserData() const { return nVal; } - USHORT GetEntryId() const { return (USHORT)(nVal >> 16); } - BOOL HasNumericValue() const { return (BOOL)(nVal >> 10) & 0x01; } - USHORT GetNumericValue() const { return (USHORT)(nVal & 0xFF); } - BOOL IsChecked() const { return (BOOL)(nVal >> 8) & 0x01; } - BOOL IsCheckable() const { return (BOOL)(nVal >> 9) & 0x01; } - BOOL IsModified() const { return (BOOL)(nVal >> 11) & 0x01; } - - void SetChecked( BOOL bVal ); - void SetNumericValue( BYTE nNumVal ); + OptionsUserData( sal_uLong nUserData ) : nVal( nUserData ) {} + OptionsUserData( sal_uInt16 nEID, + sal_Bool bHasNV, sal_uInt16 nNumVal, + sal_Bool bCheckable, sal_Bool bChecked ); + + sal_uLong GetUserData() const { return nVal; } + sal_uInt16 GetEntryId() const { return (sal_uInt16)(nVal >> 16); } + sal_Bool HasNumericValue() const { return (sal_Bool)(nVal >> 10) & 0x01; } + sal_uInt16 GetNumericValue() const { return (sal_uInt16)(nVal & 0xFF); } + sal_Bool IsChecked() const { return (sal_Bool)(nVal >> 8) & 0x01; } + sal_Bool IsCheckable() const { return (sal_Bool)(nVal >> 9) & 0x01; } + sal_Bool IsModified() const { return (sal_Bool)(nVal >> 11) & 0x01; } + + void SetChecked( sal_Bool bVal ); + void SetNumericValue( sal_uInt8 nNumVal ); }; -OptionsUserData::OptionsUserData( USHORT nEID, - BOOL bHasNV, USHORT nNumVal, - BOOL bCheckable, BOOL bChecked ) +OptionsUserData::OptionsUserData( sal_uInt16 nEID, + sal_Bool bHasNV, sal_uInt16 nNumVal, + sal_Bool bCheckable, sal_Bool bChecked ) { DBG_ASSERT( nEID < 65000, "Entry Id out of range" ); DBG_ASSERT( nNumVal < 256, "value out of range" ); - nVal = ((ULONG)(0xFFFF & nEID) << 16) | - ((ULONG)(bHasNV ? 1 : 0) << 10) | - ((ULONG)(bCheckable ? 1 : 0) << 9) | - ((ULONG)(bChecked ? 1 : 0) << 8) | - ((ULONG)(0xFF & nNumVal)); + nVal = ((sal_uLong)(0xFFFF & nEID) << 16) | + ((sal_uLong)(bHasNV ? 1 : 0) << 10) | + ((sal_uLong)(bCheckable ? 1 : 0) << 9) | + ((sal_uLong)(bChecked ? 1 : 0) << 8) | + ((sal_uLong)(0xFF & nNumVal)); } -void OptionsUserData::SetChecked( BOOL bVal ) +void OptionsUserData::SetChecked( sal_Bool bVal ) { if (IsCheckable() && (IsChecked() != bVal)) { nVal &= ~(1UL << 8); - nVal |= (ULONG)(bVal ? 1 : 0) << 8; + nVal |= (sal_uLong)(bVal ? 1 : 0) << 8; SetModified(); } } -void OptionsUserData::SetNumericValue( BYTE nNumVal ) +void OptionsUserData::SetNumericValue( sal_uInt8 nNumVal ) { if (HasNumericValue() && (GetNumericValue() != nNumVal)) { @@ -457,7 +457,7 @@ void OptionsUserData::SetNumericValue( BYTE nNumVal ) void OptionsUserData::SetModified() { - nVal |= (ULONG)1 << 11; + nVal |= (sal_uLong)1 << 11; } // class BrwString_Impl ------------------------------------------------- @@ -466,14 +466,14 @@ class BrwString_Impl : public SvLBoxString { public: - BrwString_Impl( SvLBoxEntry* pEntry, USHORT nFlags, + BrwString_Impl( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr ) : SvLBoxString( pEntry, nFlags, rStr ) {} - virtual void Paint( const Point& rPos, SvLBox& rDev, USHORT nFlags, + virtual void Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry); }; -void BrwString_Impl::Paint( const Point& rPos, SvLBox& rDev, USHORT, +void BrwString_Impl::Paint( const Point& rPos, SvLBox& rDev, sal_uInt16, SvLBoxEntry* pEntry ) { Point aPos(rPos); @@ -488,7 +488,7 @@ void BrwString_Impl::Paint( const Point& rPos, SvLBox& rDev, USHORT, aFont.SetWeight( WEIGHT_BOLD ); //??? das untere byte aus dem user data in string wandeln - OptionsUserData aData( (ULONG) pEntry->GetUserData() ); + OptionsUserData aData( (sal_uLong) pEntry->GetUserData() ); if(aData.HasNumericValue()) { String sTxt( ' ' ); @@ -514,13 +514,13 @@ struct ServiceInfo_Impl uno::Reference< XHyphenator > xHyph; uno::Reference< XThesaurus > xThes; uno::Reference< XProofreader > xGrammar; - BOOL bConfigured; + sal_Bool bConfigured; ServiceInfo_Impl() : bConfigured(sal_False) {} }; typedef std::vector< ServiceInfo_Impl > ServiceInfoArr; -typedef std::map< INT16 /*LanguageType*/, Sequence< OUString > > LangImplNameTable; +typedef std::map< sal_Int16 /*LanguageType*/, Sequence< OUString > > LangImplNameTable; // SvxLinguData_Impl ---------------------------------------------------- @@ -529,7 +529,7 @@ class SvxLinguData_Impl { //contains services and implementation names sorted by implementation names ServiceInfoArr aDisplayServiceArr; - ULONG nDisplayServices; + sal_uLong nDisplayServices; Sequence< Locale > aAllServiceLocales; LangImplNameTable aCfgSpellTable; @@ -541,7 +541,7 @@ class SvxLinguData_Impl sal_Bool AddRemove( Sequence< OUString > &rConfigured, - const OUString &rImplName, BOOL bAdd ); + const OUString &rImplName, sal_Bool bAdd ); public: SvxLinguData_Impl(); @@ -553,7 +553,7 @@ public: uno::Reference<XLinguServiceManager> & GetManager() { return xLinguSrvcMgr; } void SetChecked( const Sequence< OUString > &rConfiguredServices ); - void Reconfigure( const OUString &rDisplayName, BOOL bEnable ); + void Reconfigure( const OUString &rDisplayName, sal_Bool bEnable ); const Sequence<Locale> & GetAllSupportedLocales() const { return aAllServiceLocales; } @@ -569,8 +569,8 @@ public: const ServiceInfoArr & GetDisplayServiceArray() const { return aDisplayServiceArr; } ServiceInfoArr & GetDisplayServiceArray() { return aDisplayServiceArr; } - const ULONG & GetDisplayServiceCount() const { return nDisplayServices; } - void SetDisplayServiceCount( ULONG nVal ) { nDisplayServices = nVal; } + const sal_uLong & GetDisplayServiceCount() const { return nDisplayServices; } + void SetDisplayServiceCount( sal_uLong nVal ) { nDisplayServices = nVal; } // returns the list of service implementation names for the specified // language and service (TYPE_SPELL, TYPE_HYPH, TYPE_THES) sorted in @@ -579,18 +579,18 @@ public: // I.e. the ones available but not configured in arbitrary order). // They available ones may contain names that do not(!) support that // language. - Sequence< OUString > GetSortedImplNames( INT16 nLang, BYTE nType ); + Sequence< OUString > GetSortedImplNames( sal_Int16 nLang, sal_uInt8 nType ); ServiceInfo_Impl * GetInfoByImplName( const OUString &rSvcImplName ); }; -INT32 lcl_SeqGetIndex( const Sequence< OUString > &rSeq, const OUString &rTxt ) +sal_Int32 lcl_SeqGetIndex( const Sequence< OUString > &rSeq, const OUString &rTxt ) { - INT32 nRes = -1; - INT32 nLen = rSeq.getLength(); + sal_Int32 nRes = -1; + sal_Int32 nLen = rSeq.getLength(); const OUString *pString = rSeq.getConstArray(); - for (INT32 i = 0; i < nLen && nRes == -1; ++i) + for (sal_Int32 i = 0; i < nLen && nRes == -1; ++i) { if (pString[i] == rTxt) nRes = i; @@ -599,7 +599,7 @@ INT32 lcl_SeqGetIndex( const Sequence< OUString > &rSeq, const OUString &rTxt ) } -Sequence< OUString > SvxLinguData_Impl::GetSortedImplNames( INT16 nLang, BYTE nType ) +Sequence< OUString > SvxLinguData_Impl::GetSortedImplNames( sal_Int16 nLang, sal_uInt8 nType ) { LangImplNameTable *pTable = 0; switch (nType) @@ -612,13 +612,13 @@ Sequence< OUString > SvxLinguData_Impl::GetSortedImplNames( INT16 nLang, BYTE nT Sequence< OUString > aRes; if (pTable->count( nLang )) aRes = (*pTable)[ nLang ]; // add configured services - INT32 nIdx = aRes.getLength(); - DBG_ASSERT( (INT32) nDisplayServices >= nIdx, "size mismatch" ); + sal_Int32 nIdx = aRes.getLength(); + DBG_ASSERT( (sal_Int32) nDisplayServices >= nIdx, "size mismatch" ); aRes.realloc( nDisplayServices ); OUString *pRes = aRes.getArray(); // add not configured services - for (INT32 i = 0; i < (INT32) nDisplayServices; ++i) + for (sal_Int32 i = 0; i < (sal_Int32) nDisplayServices; ++i) { const ServiceInfo_Impl &rInfo = aDisplayServiceArr[ i ]; OUString aImplName; @@ -648,7 +648,7 @@ Sequence< OUString > SvxLinguData_Impl::GetSortedImplNames( INT16 nLang, BYTE nT ServiceInfo_Impl * SvxLinguData_Impl::GetInfoByImplName( const OUString &rSvcImplName ) { ServiceInfo_Impl* pInfo = 0; - for (ULONG i = 0; i < nDisplayServices && !pInfo; ++i) + for (sal_uLong i = 0; i < nDisplayServices && !pInfo; ++i) { ServiceInfo_Impl &rTmp = aDisplayServiceArr[ i ]; if (rTmp.sSpellImplName == rSvcImplName || @@ -695,13 +695,13 @@ void lcl_MergeDisplayArray( SvxLinguData_Impl &rData, const ServiceInfo_Impl &rToAdd ) { - ULONG nCnt = 0; + sal_uLong nCnt = 0; ServiceInfoArr &rSvcInfoArr = rData.GetDisplayServiceArray(); - ULONG nEntries = rData.GetDisplayServiceCount(); + sal_uLong nEntries = rData.GetDisplayServiceCount(); ServiceInfo_Impl* pEntry; - for (ULONG i = 0; i < nEntries; ++i) + for (sal_uLong i = 0; i < nEntries; ++i) { pEntry = &rSvcInfoArr[i]; if (pEntry && pEntry->sDisplayName == rToAdd.sDisplayName) @@ -864,7 +864,7 @@ SvxLinguData_Impl::SvxLinguData_Impl() : const Locale* pAllLocales = aAllServiceLocales.getConstArray(); for(sal_Int32 nLocale = 0; nLocale < aAllServiceLocales.getLength(); nLocale++) { - INT16 nLang = SvxLocaleToLanguage( pAllLocales[nLocale] ); + sal_Int16 nLang = SvxLocaleToLanguage( pAllLocales[nLocale] ); aCfgSvcs = xLinguSrvcMgr->getConfiguredServices(C2U(cSpell), pAllLocales[nLocale]); SetChecked( aCfgSvcs ); @@ -926,7 +926,7 @@ void SvxLinguData_Impl::SetChecked(const Sequence<OUString>& rConfiguredServices for(sal_Int32 n = 0; n < rConfiguredServices.getLength(); n++) { ServiceInfo_Impl* pEntry; - for (ULONG i = 0; i < nDisplayServices; ++i) + for (sal_uLong i = 0; i < nDisplayServices; ++i) { pEntry = &aDisplayServiceArr[i]; if (pEntry && !pEntry->bConfigured) @@ -948,12 +948,12 @@ void SvxLinguData_Impl::SetChecked(const Sequence<OUString>& rConfiguredServices sal_Bool SvxLinguData_Impl::AddRemove( Sequence< OUString > &rConfigured, - const OUString &rImplName, BOOL bAdd ) + const OUString &rImplName, sal_Bool bAdd ) { sal_Bool bRet = sal_False; // modified? - INT32 nEntries = rConfigured.getLength(); - INT32 nPos = lcl_SeqGetEntryPos(rConfigured, rImplName); + sal_Int32 nEntries = rConfigured.getLength(); + sal_Int32 nPos = lcl_SeqGetEntryPos(rConfigured, rImplName); if (bAdd && nPos < 0) // add new entry { rConfigured.realloc( ++nEntries ); @@ -965,7 +965,7 @@ sal_Bool SvxLinguData_Impl::AddRemove( else if (!bAdd && nPos >= 0) // remove existing entry { OUString *pConfigured = rConfigured.getArray(); - for (INT32 i = nPos; i < nEntries - 1; ++i) + for (sal_Int32 i = nPos; i < nEntries - 1; ++i) pConfigured[i] = pConfigured[i + 1]; rConfigured.realloc(--nEntries); bRet = sal_True; @@ -975,13 +975,13 @@ sal_Bool SvxLinguData_Impl::AddRemove( } -void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable ) +void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, sal_Bool bEnable ) { DBG_ASSERT( rDisplayName.getLength(), "empty DisplayName" ); ServiceInfo_Impl *pInfo = 0; ServiceInfo_Impl *pTmp = 0; - for (ULONG i = 0; i < nDisplayServices; ++i) + for (sal_uLong i = 0; i < nDisplayServices; ++i) { pTmp = &aDisplayServiceArr[i]; if (pTmp && pTmp->sDisplayName == rDisplayName) @@ -997,8 +997,8 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable Sequence< Locale > aLocales; const Locale *pLocale = 0; - INT32 nLocales = 0; - INT32 i; + sal_Int32 nLocales = 0; + sal_Int32 i; // update configured spellchecker entries if (pInfo->xSpell.is()) @@ -1008,7 +1008,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable nLocales = aLocales.getLength(); for (i = 0; i < nLocales; ++i) { - INT16 nLang = SvxLocaleToLanguage( pLocale[i] ); + sal_Int16 nLang = SvxLocaleToLanguage( pLocale[i] ); if (!aCfgSpellTable.count( nLang ) && bEnable) aCfgSpellTable[ nLang ] = Sequence< OUString >(); if (aCfgSpellTable.count( nLang )) @@ -1024,7 +1024,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable nLocales = aLocales.getLength(); for (i = 0; i < nLocales; ++i) { - INT16 nLang = SvxLocaleToLanguage( pLocale[i] ); + sal_Int16 nLang = SvxLocaleToLanguage( pLocale[i] ); if (!aCfgGrammarTable.count( nLang ) && bEnable) aCfgGrammarTable[ nLang ] = Sequence< OUString >(); if (aCfgGrammarTable.count( nLang )) @@ -1040,7 +1040,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable nLocales = aLocales.getLength(); for (i = 0; i < nLocales; ++i) { - INT16 nLang = SvxLocaleToLanguage( pLocale[i] ); + sal_Int16 nLang = SvxLocaleToLanguage( pLocale[i] ); if (!aCfgHyphTable.count( nLang ) && bEnable) aCfgHyphTable[ nLang ] = Sequence< OUString >(); if (aCfgHyphTable.count( nLang )) @@ -1056,7 +1056,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, BOOL bEnable nLocales = aLocales.getLength(); for (i = 0; i < nLocales; ++i) { - INT16 nLang = SvxLocaleToLanguage( pLocale[i] ); + sal_Int16 nLang = SvxLocaleToLanguage( pLocale[i] ); if (!aCfgThesTable.count( nLang ) && bEnable) aCfgThesTable[ nLang ] = Sequence< OUString >(); if (aCfgThesTable.count( nLang )) @@ -1107,7 +1107,7 @@ SvxLinguTabPage::SvxLinguTabPage( Window* pParent, { pCheckButtonData = NULL; - aLinguModulesCLB.SetWindowBits( WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); + aLinguModulesCLB.SetStyle( aLinguModulesCLB.GetStyle()|WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); aLinguModulesCLB.SetHelpId(HID_CLB_LINGU_MODULES ); aLinguModulesCLB.SetHighlightRange(); aLinguModulesCLB.SetSelectHdl( LINK( this, SvxLinguTabPage, SelectHdl_Impl )); @@ -1117,7 +1117,7 @@ SvxLinguTabPage::SvxLinguTabPage( Window* pParent, aLinguModulesEditPB.SetClickHdl( LINK( this, SvxLinguTabPage, ClickHdl_Impl )); aLinguOptionsEditPB.SetClickHdl( LINK( this, SvxLinguTabPage, ClickHdl_Impl )); - aLinguDicsCLB.SetWindowBits( WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); + aLinguDicsCLB.SetStyle( aLinguDicsCLB.GetStyle()|WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); aLinguDicsCLB.SetHelpId(HID_CLB_EDIT_MODULES_DICS ); aLinguDicsCLB.SetHighlightRange(); aLinguDicsCLB.SetSelectHdl( LINK( this, SvxLinguTabPage, SelectHdl_Impl )); @@ -1127,7 +1127,7 @@ SvxLinguTabPage::SvxLinguTabPage( Window* pParent, aLinguDicsEditPB.SetClickHdl( LINK( this, SvxLinguTabPage, ClickHdl_Impl )); aLinguDicsDelPB.SetClickHdl( LINK( this, SvxLinguTabPage, ClickHdl_Impl )); - aLinguOptionsCLB.SetWindowBits( WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); + aLinguOptionsCLB.SetStyle( aLinguOptionsCLB.GetStyle()|WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); aLinguOptionsCLB.SetHelpId(HID_CLB_LINGU_OPTIONS ); aLinguOptionsCLB.SetHighlightRange(); aLinguOptionsCLB.SetSelectHdl( LINK( this, SvxLinguTabPage, SelectHdl_Impl )); @@ -1143,6 +1143,13 @@ SvxLinguTabPage::SvxLinguTabPage( Window* pParent, else aMoreDictsLink.Hide(); + String sAccessibleNameModuleEdit( CUI_RES( STR_LINGU_MODULES_EDIT ) ); + String sAccessibleNameDicsEdit ( CUI_RES( STR_LINGU_DICS_EDIT_DIC ) ); + String sAccessibleNameOptionEdit( CUI_RES( STR_LINGU_OPTIONS_EDIT ) ); + + aLinguModulesEditPB.SetAccessibleName(sAccessibleNameModuleEdit); + aLinguDicsEditPB.SetAccessibleName(sAccessibleNameDicsEdit); + aLinguOptionsEditPB.SetAccessibleName(sAccessibleNameOptionEdit); // force recalculation of hash value used for checking the need of updating // because new dictionaries might be installed / downloaded. @@ -1217,7 +1224,7 @@ SfxTabPage* SvxLinguTabPage::Create( Window* pParent, //------------------------------------------------------------------------ -Any lcl_Bool2Any(BOOL bVal) +Any lcl_Bool2Any(sal_Bool bVal) { Any aRet(&bVal, ::getBooleanCppuType()); return aRet; @@ -1247,7 +1254,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) const LangImplNameTable *pTable = &pLinguData->GetSpellTable(); for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt) { - INT16 nLang = aIt->first; + sal_Int16 nLang = aIt->first; const Sequence< OUString > aImplNames( aIt->second ); #if OSL_DEBUG_LEVEL > 1 const OUString *pTmpStr; @@ -1263,7 +1270,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) pTable = &pLinguData->GetGrammarTable(); for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt) { - INT16 nLang = aIt->first; + sal_Int16 nLang = aIt->first; const Sequence< OUString > aImplNames( aIt->second ); #if OSL_DEBUG_LEVEL > 1 const OUString *pTmpStr; @@ -1279,7 +1286,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) pTable = &pLinguData->GetHyphTable(); for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt) { - INT16 nLang = aIt->first; + sal_Int16 nLang = aIt->first; const Sequence< OUString > aImplNames( aIt->second ); #if OSL_DEBUG_LEVEL > 1 const OUString *pTmpStr; @@ -1295,7 +1302,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) pTable = &pLinguData->GetThesTable(); for (aIt = pTable->begin(); aIt != pTable->end(); ++aIt) { - INT16 nLang = aIt->first; + sal_Int16 nLang = aIt->first; const Sequence< OUString > aImplNames( aIt->second ); #if OSL_DEBUG_LEVEL > 1 const OUString *pTmpStr; @@ -1313,11 +1320,11 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) // activate dictionaries according to checkbox state // Sequence< OUString > aActiveDics; - INT32 nActiveDics = 0; - ULONG nEntries = aLinguDicsCLB.GetEntryCount(); - for (ULONG i = 0; i < nEntries; ++i) + sal_Int32 nActiveDics = 0; + sal_uLong nEntries = aLinguDicsCLB.GetEntryCount(); + for (sal_uLong i = 0; i < nEntries; ++i) { - INT32 nDics = aDics.getLength(); + sal_Int32 nDics = aDics.getLength(); aActiveDics.realloc( nDics ); OUString *pActiveDic = aActiveDics.getArray(); @@ -1325,15 +1332,15 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) SvLBoxEntry *pEntry = aLinguDicsCLB.GetEntry( i ); if (pEntry) { - DicUserData aData( (ULONG)pEntry->GetUserData() ); + DicUserData aData( (sal_uLong)pEntry->GetUserData() ); if (aData.GetEntryId() < nDics) { - BOOL bChecked = aLinguDicsCLB.IsChecked( (USHORT) i ); + sal_Bool bChecked = aLinguDicsCLB.IsChecked( (sal_uInt16) i ); uno::Reference< XDictionary > xDic( aDics.getConstArray()[ i ] ); if (xDic.is()) { if (SvxGetIgnoreAllList() == xDic) - bChecked = TRUE; + bChecked = sal_True; xDic->setActive( bChecked ); if (bChecked) @@ -1354,22 +1361,22 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) nEntries = aLinguOptionsCLB.GetEntryCount(); - for (USHORT j = 0; j < nEntries; ++j) + for (sal_uInt16 j = 0; j < nEntries; ++j) { SvLBoxEntry *pEntry = aLinguOptionsCLB.GetEntry( j ); - OptionsUserData aData( (ULONG)pEntry->GetUserData() ); + OptionsUserData aData( (sal_uLong)pEntry->GetUserData() ); String aPropName( lcl_GetPropertyName( (EID_OPTIONS) aData.GetEntryId() ) ); Any aAny; if (aData.IsCheckable()) { - BOOL bChecked = aLinguOptionsCLB.IsChecked( j ); + sal_Bool bChecked = aLinguOptionsCLB.IsChecked( j ); aAny <<= bChecked; } else if (aData.HasNumericValue()) { - INT16 nVal = aData.GetNumericValue(); + sal_Int16 nVal = aData.GetNumericValue(); aAny <<= nVal; } @@ -1378,26 +1385,26 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) aLngCfg.SetProperty( aPropName, aAny ); } - SvLBoxEntry *pPreBreakEntry = aLinguOptionsCLB.GetEntry( (USHORT) EID_NUM_PRE_BREAK ); - SvLBoxEntry *pPostBreakEntry = aLinguOptionsCLB.GetEntry( (USHORT) EID_NUM_POST_BREAK ); + SvLBoxEntry *pPreBreakEntry = aLinguOptionsCLB.GetEntry( (sal_uInt16) EID_NUM_PRE_BREAK ); + SvLBoxEntry *pPostBreakEntry = aLinguOptionsCLB.GetEntry( (sal_uInt16) EID_NUM_POST_BREAK ); DBG_ASSERT( pPreBreakEntry, "NULL Pointer" ); DBG_ASSERT( pPostBreakEntry, "NULL Pointer" ); if (pPreBreakEntry && pPostBreakEntry) { - OptionsUserData aPreBreakData( (ULONG)pPreBreakEntry->GetUserData() ); - OptionsUserData aPostBreakData( (ULONG)pPostBreakEntry->GetUserData() ); + OptionsUserData aPreBreakData( (sal_uLong)pPreBreakEntry->GetUserData() ); + OptionsUserData aPostBreakData( (sal_uLong)pPostBreakEntry->GetUserData() ); if ( aPreBreakData.IsModified() || aPostBreakData.IsModified() ) { SfxHyphenRegionItem aHyp( GetWhich( SID_ATTR_HYPHENREGION ) ); - aHyp.GetMinLead() = (UINT8) aPreBreakData.GetNumericValue(); - aHyp.GetMinTrail() = (UINT8) aPostBreakData.GetNumericValue(); + aHyp.GetMinLead() = (sal_uInt8) aPreBreakData.GetNumericValue(); + aHyp.GetMinTrail() = (sal_uInt8) aPostBreakData.GetNumericValue(); rCoreSet.Put( aHyp ); } } // automatic spell checking - BOOL bNewAutoCheck = aLinguOptionsCLB.IsChecked( (USHORT) EID_SPELL_AUTO ); + sal_Bool bNewAutoCheck = aLinguOptionsCLB.IsChecked( (sal_uInt16) EID_SPELL_AUTO ); const SfxPoolItem* pOld = GetOldItem( rCoreSet, SID_AUTOSPELL_CHECK ); if ( !pOld || ( (SfxBoolItem*)pOld )->GetValue() != bNewAutoCheck ) { @@ -1411,17 +1418,17 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet ) // ---------------------------------------------------------------------- -ULONG SvxLinguTabPage::GetDicUserData( const uno::Reference< XDictionary > &rxDic, USHORT nIdx ) +sal_uLong SvxLinguTabPage::GetDicUserData( const uno::Reference< XDictionary > &rxDic, sal_uInt16 nIdx ) { - ULONG nRes = 0; + sal_uLong nRes = 0; DBG_ASSERT( rxDic.is(), "dictionary not supplied" ); if (rxDic.is()) { uno::Reference< frame::XStorable > xStor( rxDic, UNO_QUERY ); - BOOL bChecked = rxDic->isActive(); - BOOL bEditable = !xStor.is() || !xStor->isReadonly(); - BOOL bDeletable = bEditable; + sal_Bool bChecked = rxDic->isActive(); + sal_Bool bEditable = !xStor.is() || !xStor->isReadonly(); + sal_Bool bDeletable = bEditable; nRes = DicUserData( nIdx, bChecked, bEditable, bDeletable ).GetUserData(); @@ -1432,14 +1439,14 @@ ULONG SvxLinguTabPage::GetDicUserData( const uno::Reference< XDictionary > &rxDi void SvxLinguTabPage::AddDicBoxEntry( const uno::Reference< XDictionary > &rxDic, - USHORT nIdx ) + sal_uInt16 nIdx ) { - aLinguDicsCLB.SetUpdateMode(FALSE); + aLinguDicsCLB.SetUpdateMode(sal_False); String aTxt( ::GetDicInfoStr( rxDic->getName(), SvxLocaleToLanguage( rxDic->getLocale() ), DictionaryType_NEGATIVE == rxDic->getDictionaryType() ) ); - aLinguDicsCLB.InsertEntry( aTxt, (USHORT)LISTBOX_APPEND ); // append at end + aLinguDicsCLB.InsertEntry( aTxt, (sal_uInt16)LISTBOX_APPEND ); // append at end SvLBoxEntry* pEntry = aLinguDicsCLB.GetEntry( aLinguDicsCLB.GetEntryCount() - 1 ); DBG_ASSERT( pEntry, "failed to add entry" ); if (pEntry) @@ -1449,26 +1456,26 @@ void SvxLinguTabPage::AddDicBoxEntry( lcl_SetCheckButton( pEntry, aData.IsChecked() ); } - aLinguDicsCLB.SetUpdateMode(TRUE); + aLinguDicsCLB.SetUpdateMode(sal_True); } // ---------------------------------------------------------------------- void SvxLinguTabPage::UpdateDicBox_Impl() { - aLinguDicsCLB.SetUpdateMode(FALSE); + aLinguDicsCLB.SetUpdateMode(sal_False); aLinguDicsCLB.Clear(); - INT32 nDics = aDics.getLength(); + sal_Int32 nDics = aDics.getLength(); const uno::Reference< XDictionary > *pDic = aDics.getConstArray(); - for (INT32 i = 0; i < nDics; ++i) + for (sal_Int32 i = 0; i < nDics; ++i) { const uno::Reference< XDictionary > &rDic = pDic[i]; if (rDic.is()) - AddDicBoxEntry( rDic, (USHORT)i ); + AddDicBoxEntry( rDic, (sal_uInt16)i ); } - aLinguDicsCLB.SetUpdateMode(TRUE); + aLinguDicsCLB.SetUpdateMode(sal_True); } // ---------------------------------------------------------------------- @@ -1478,14 +1485,14 @@ void SvxLinguTabPage::UpdateModulesBox_Impl() if (pLinguData) { const ServiceInfoArr &rAllDispSrvcArr = pLinguData->GetDisplayServiceArray(); - const ULONG nDispSrvcCount = pLinguData->GetDisplayServiceCount(); + const sal_uLong nDispSrvcCount = pLinguData->GetDisplayServiceCount(); aLinguModulesCLB.Clear(); - for (USHORT i = 0; i < nDispSrvcCount; ++i) + for (sal_uInt16 i = 0; i < nDispSrvcCount; ++i) { const ServiceInfo_Impl &rInfo = rAllDispSrvcArr[i]; - aLinguModulesCLB.InsertEntry( rInfo.sDisplayName, (USHORT)LISTBOX_APPEND ); + aLinguModulesCLB.InsertEntry( rInfo.sDisplayName, (sal_uInt16)LISTBOX_APPEND ); SvLBoxEntry* pEntry = aLinguModulesCLB.GetEntry(i); pEntry->SetUserData( (void *) &rInfo ); aLinguModulesCLB.CheckEntryPos( i, rInfo.bConfigured ); @@ -1513,103 +1520,103 @@ void SvxLinguTabPage::Reset( const SfxItemSet& rSet ) SvtLinguConfig aLngCfg; - aLinguOptionsCLB.SetUpdateMode(FALSE); + aLinguOptionsCLB.SetUpdateMode(sal_False); aLinguOptionsCLB.Clear(); SvLBoxTreeList *pModel = aLinguOptionsCLB.GetModel(); SvLBoxEntry* pEntry = NULL; - INT16 nVal = 0; - BOOL bVal = FALSE; - ULONG nUserData = 0; + sal_Int16 nVal = 0; + sal_Bool bVal = sal_False; + sal_uLong nUserData = 0; pEntry = CreateEntry( sSpellAuto, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_SPELL_AUTO) ) >>= bVal; const SfxPoolItem* pItem = GetItem( rSet, SID_AUTOSPELL_CHECK ); if (pItem) bVal = ((SfxBoolItem *) pItem)->GetValue(); - nUserData = OptionsUserData( EID_SPELL_AUTO, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_SPELL_AUTO, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sGrammarAuto, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_GRAMMAR_AUTO) ) >>= bVal; - nUserData = OptionsUserData( EID_GRAMMAR_AUTO, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_GRAMMAR_AUTO, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sCapitalWords, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_SPELL_UPPER_CASE) ) >>= bVal; - nUserData = OptionsUserData( EID_CAPITAL_WORDS, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_CAPITAL_WORDS, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sWordsWithDigits, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_SPELL_WITH_DIGITS) ) >>= bVal; - nUserData = OptionsUserData( EID_WORDS_WITH_DIGITS, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_WORDS_WITH_DIGITS, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sCapitalization, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_SPELL_CAPITALIZATION) ) >>= bVal; - nUserData = OptionsUserData( EID_CAPITALIZATION, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_CAPITALIZATION, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sSpellSpecial, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_SPELL_SPECIAL) ) >>= bVal; - nUserData = OptionsUserData( EID_SPELL_SPECIAL, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_SPELL_SPECIAL, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sNumMinWordlen, CBCOL_SECOND ); aLngCfg.GetProperty( C2U(UPN_HYPH_MIN_WORD_LENGTH) ) >>= nVal; - nUserData = OptionsUserData( EID_NUM_MIN_WORDLEN, TRUE, (USHORT)nVal, FALSE, FALSE).GetUserData(); + nUserData = OptionsUserData( EID_NUM_MIN_WORDLEN, sal_True, (sal_uInt16)nVal, sal_False, sal_False).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); const SfxHyphenRegionItem *pHyp = NULL; - USHORT nWhich = GetWhich( SID_ATTR_HYPHENREGION ); - if ( rSet.GetItemState( nWhich, FALSE ) == SFX_ITEM_SET ) + sal_uInt16 nWhich = GetWhich( SID_ATTR_HYPHENREGION ); + if ( rSet.GetItemState( nWhich, sal_False ) == SFX_ITEM_SET ) pHyp = &( (const SfxHyphenRegionItem &) rSet.Get( nWhich ) ); pEntry = CreateEntry( sNumPreBreak, CBCOL_SECOND ); aLngCfg.GetProperty( C2U(UPN_HYPH_MIN_LEADING) ) >>= nVal; if (pHyp) - nVal = (INT16) pHyp->GetMinLead(); - nUserData = OptionsUserData( EID_NUM_PRE_BREAK, TRUE, (USHORT)nVal, FALSE, FALSE).GetUserData(); + nVal = (sal_Int16) pHyp->GetMinLead(); + nUserData = OptionsUserData( EID_NUM_PRE_BREAK, sal_True, (sal_uInt16)nVal, sal_False, sal_False).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); pEntry = CreateEntry( sNumPostBreak, CBCOL_SECOND ); aLngCfg.GetProperty( C2U(UPN_HYPH_MIN_TRAILING) ) >>= nVal; if (pHyp) - nVal = (INT16) pHyp->GetMinTrail(); - nUserData = OptionsUserData( EID_NUM_POST_BREAK, TRUE, (USHORT)nVal, FALSE, FALSE).GetUserData(); + nVal = (sal_Int16) pHyp->GetMinTrail(); + nUserData = OptionsUserData( EID_NUM_POST_BREAK, sal_True, (sal_uInt16)nVal, sal_False, sal_False).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); pEntry = CreateEntry( sHyphAuto, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_HYPH_AUTO) ) >>= bVal; - nUserData = OptionsUserData( EID_HYPH_AUTO, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_HYPH_AUTO, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); pEntry = CreateEntry( sHyphSpecial, CBCOL_FIRST ); aLngCfg.GetProperty( C2U(UPN_IS_HYPH_SPECIAL) ) >>= bVal; - nUserData = OptionsUserData( EID_HYPH_SPECIAL, FALSE, 0, TRUE, bVal).GetUserData(); + nUserData = OptionsUserData( EID_HYPH_SPECIAL, sal_False, 0, sal_True, bVal).GetUserData(); pEntry->SetUserData( (void *)nUserData ); pModel->Insert( pEntry ); lcl_SetCheckButton( pEntry, bVal ); - aLinguOptionsCLB.SetUpdateMode(TRUE); + aLinguOptionsCLB.SetUpdateMode(sal_True); } // ----------------------------------------------------------------------- @@ -1655,7 +1662,7 @@ IMPL_LINK( SvxLinguTabPage, BoxCheckButtonHdl_Impl, SvTreeListBox *, pBox ) if (pBox == &aLinguModulesCLB) { DBG_ASSERT( pLinguData, "NULL pointer, LinguData missing" ); - USHORT nPos = aLinguModulesCLB.GetSelectEntryPos(); + sal_uInt16 nPos = aLinguModulesCLB.GetSelectEntryPos(); if (nPos != LISTBOX_ENTRY_NOTFOUND && pLinguData) { pLinguData->Reconfigure( aLinguModulesCLB.GetText( nPos ), @@ -1664,7 +1671,7 @@ IMPL_LINK( SvxLinguTabPage, BoxCheckButtonHdl_Impl, SvTreeListBox *, pBox ) } else if (pBox == &aLinguDicsCLB) { - USHORT nPos = aLinguDicsCLB.GetSelectEntryPos(); + sal_uInt16 nPos = aLinguDicsCLB.GetSelectEntryPos(); if (nPos != LISTBOX_ENTRY_NOTFOUND) { const uno::Reference< XDictionary > &rDic = aDics.getConstArray()[ nPos ]; @@ -1672,7 +1679,7 @@ IMPL_LINK( SvxLinguTabPage, BoxCheckButtonHdl_Impl, SvTreeListBox *, pBox ) { SvLBoxEntry* pEntry = aLinguDicsCLB.GetEntry( nPos ); if (pEntry) - lcl_SetCheckButton( pEntry, TRUE ); + lcl_SetCheckButton( pEntry, sal_True ); } } } @@ -1694,14 +1701,14 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) *pLinguData = aOldLinguData; // evaluate new status of 'bConfigured' flag - ULONG nLen = pLinguData->GetDisplayServiceCount(); - for (ULONG i = 0; i < nLen; ++i) - pLinguData->GetDisplayServiceArray()[i].bConfigured = FALSE; + sal_uLong nLen = pLinguData->GetDisplayServiceCount(); + for (sal_uLong i = 0; i < nLen; ++i) + pLinguData->GetDisplayServiceArray()[i].bConfigured = sal_False; const Locale* pAllLocales = pLinguData->GetAllSupportedLocales().getConstArray(); - INT32 nLocales = pLinguData->GetAllSupportedLocales().getLength(); - for (INT32 k = 0; k < nLocales; ++k) + sal_Int32 nLocales = pLinguData->GetAllSupportedLocales().getLength(); + for (sal_Int32 k = 0; k < nLocales; ++k) { - INT16 nLang = SvxLocaleToLanguage( pAllLocales[k] ); + sal_Int16 nLang = SvxLocaleToLanguage( pAllLocales[k] ); if (pLinguData->GetSpellTable().count( nLang )) pLinguData->SetChecked( pLinguData->GetSpellTable()[ nLang ] ); if (pLinguData->GetGrammarTable().count( nLang )) @@ -1729,12 +1736,12 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) if ( xNewDic.is() ) { // add new dics to the end - INT32 nLen = aDics.getLength(); + sal_Int32 nLen = aDics.getLength(); aDics.realloc( nLen + 1 ); aDics.getArray()[ nLen ] = xNewDic; - AddDicBoxEntry( xNewDic, (USHORT) nLen ); + AddDicBoxEntry( xNewDic, (sal_uInt16) nLen ); } delete aDlg; } @@ -1744,9 +1751,9 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) SvLBoxEntry *pEntry = aLinguDicsCLB.GetCurEntry(); if (pEntry) { - DicUserData aData( (ULONG) pEntry->GetUserData() ); - USHORT nDicPos = aData.GetEntryId(); - INT32 nDics = aDics.getLength(); + DicUserData aData( (sal_uLong) pEntry->GetUserData() ); + sal_uInt16 nDicPos = aData.GetEntryId(); + sal_Int32 nDics = aDics.getLength(); if (nDicPos < nDics) { uno::Reference< XDictionary > xDic; @@ -1775,9 +1782,9 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) SvLBoxEntry *pEntry = aLinguDicsCLB.GetCurEntry(); if (pEntry) { - DicUserData aData( (ULONG) pEntry->GetUserData() ); - USHORT nDicPos = aData.GetEntryId(); - INT32 nDics = aDics.getLength(); + DicUserData aData( (sal_uLong) pEntry->GetUserData() ); + sal_uInt16 nDicPos = aData.GetEntryId(); + sal_Int32 nDics = aDics.getLength(); if (nDicPos < nDics) { uno::Reference< XDictionary > xDic; @@ -1807,17 +1814,17 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) aDics.getArray()[ nDicPos ] = 0; // remove entry from checklistbox - ULONG nCnt = aLinguDicsCLB.GetEntryCount(); - for (ULONG i = 0; i < nCnt; ++i) + sal_uLong nCnt = aLinguDicsCLB.GetEntryCount(); + for (sal_uLong i = 0; i < nCnt; ++i) { SvLBoxEntry *pDicEntry = aLinguDicsCLB.GetEntry( i ); DBG_ASSERT( pDicEntry, "missing entry" ); if (pDicEntry) { - DicUserData aDicData( (ULONG) pDicEntry->GetUserData() ); + DicUserData aDicData( (sal_uLong) pDicEntry->GetUserData() ); if (aDicData.GetEntryId() == nDicPos ) { - aLinguDicsCLB.RemoveEntry( (USHORT) i ); + aLinguDicsCLB.RemoveEntry( (sal_uInt16) i ); break; } } @@ -1835,7 +1842,7 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) DBG_ASSERT( pEntry, "no entry selected" ); if (pEntry) { - OptionsUserData aData( (ULONG)pEntry->GetUserData() ); + OptionsUserData aData( (sal_uLong)pEntry->GetUserData() ); if(aData.HasNumericValue()) { int nRID = -1; @@ -1855,7 +1862,7 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn ) long nVal = static_cast<long>(aDlg.GetNumericFld().GetValue()); if (-1 != nVal && aData.GetNumericValue() != nVal) { - aData.SetNumericValue( (BYTE)nVal ); //! sets IsModified ! + aData.SetNumericValue( (sal_uInt8)nVal ); //! sets IsModified ! pEntry->SetUserData( (void *) aData.GetUserData() ); aLinguOptionsCLB.Invalidate(); } @@ -1883,7 +1890,7 @@ IMPL_LINK( SvxLinguTabPage, SelectHdl_Impl, SvxCheckListBox *, pBox ) SvLBoxEntry *pEntry = pBox->GetCurEntry(); if (pEntry) { - DicUserData aData( (ULONG) pEntry->GetUserData() ); + DicUserData aData( (sal_uLong) pEntry->GetUserData() ); // always allow to edit (i.e. at least view the content of the dictionary) aLinguDicsEditPB.Enable( true/*aData.IsEditable()*/ ); @@ -1895,7 +1902,7 @@ IMPL_LINK( SvxLinguTabPage, SelectHdl_Impl, SvxCheckListBox *, pBox ) SvLBoxEntry *pEntry = pBox->GetCurEntry(); if (pEntry) { - OptionsUserData aData( (ULONG) pEntry->GetUserData() ); + OptionsUserData aData( (sal_uLong) pEntry->GetUserData() ); aLinguOptionsEditPB.Enable( aData.HasNumericValue() ); } } @@ -1909,7 +1916,7 @@ IMPL_LINK( SvxLinguTabPage, SelectHdl_Impl, SvxCheckListBox *, pBox ) // ----------------------------------------------------------------------- -SvLBoxEntry* SvxLinguTabPage::CreateEntry( String& rTxt, USHORT nCol ) +SvLBoxEntry* SvxLinguTabPage::CreateEntry( String& rTxt, sal_uInt16 nCol ) { SvLBoxEntry* pEntry = new SvLBoxEntry; @@ -1988,7 +1995,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData) ModalDialog( pParent, CUI_RES(RID_SVXDLG_EDIT_MODULES ) ), aModulesFL ( this, CUI_RES( FL_EDIT_MODULES_OPTIONS ) ), aLanguageFT ( this, CUI_RES( FT_EDIT_MODULES_LANGUAGE ) ), - aLanguageLB ( this, CUI_RES( LB_EDIT_MODULES_LANGUAGE ), FALSE ), + aLanguageLB ( this, CUI_RES( LB_EDIT_MODULES_LANGUAGE ), sal_False ), aModulesCLB ( this, CUI_RES( CLB_EDIT_MODULES_MODULES ) ), aPrioUpPB ( this, CUI_RES( PB_EDIT_MODULES_PRIO_UP ) ), aPrioDownPB ( this, CUI_RES( PB_EDIT_MODULES_PRIO_DOWN ) ), @@ -2008,7 +2015,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData) pDefaultLinguData = new SvxLinguData_Impl( rLinguData ); - aModulesCLB.SetWindowBits( WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); + aModulesCLB.SetStyle( aModulesCLB.GetStyle()|WB_CLIPCHILDREN|WB_HSCROLL|WB_FORCE_MAKEVISIBLE ); aModulesCLB.SetHighlightRange(); aModulesCLB.SetHelpId(HID_CLB_EDIT_MODULES_MODULES ); aModulesCLB.SetSelectHdl( LINK( this, SvxEditModulesDlg, SelectHdl_Impl )); @@ -2019,8 +2026,8 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData) aPrioDownPB.SetClickHdl( LINK( this, SvxEditModulesDlg, UpDownHdl_Impl )); aBackPB .SetClickHdl( LINK( this, SvxEditModulesDlg, BackHdl_Impl )); // in case of not installed language modules - aPrioUpPB .Enable( FALSE ); - aPrioDownPB.Enable( FALSE ); + aPrioUpPB .Enable( sal_False ); + aPrioDownPB.Enable( sal_False ); if ( SvtExtendedSecurityOptions().GetOpenHyperlinkMode() != SvtExtendedSecurityOptions::OPEN_NEVER ) @@ -2041,7 +2048,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData) // //fill language box // - Sequence< INT16 > aAvailLang; + Sequence< sal_Int16 > aAvailLang; uno::Reference< XAvailableLocales > xAvail( rLinguData.GetManager(), UNO_QUERY ); if (xAvail.is()) { @@ -2053,7 +2060,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData) aLanguageLB.Clear(); for(long i = 0; i < rLoc.getLength(); i++) { - INT16 nLang = SvxLocaleToLanguage( pLocales[i] ); + sal_Int16 nLang = SvxLocaleToLanguage( pLocales[i] ); aLanguageLB.InsertLanguage( nLang, lcl_SeqHasLang( aAvailLang, nLang ) ); } LanguageType eSysLang = MsLangId::getSystemLanguage(); @@ -2072,7 +2079,7 @@ SvxEditModulesDlg::~SvxEditModulesDlg() } -SvLBoxEntry* SvxEditModulesDlg::CreateEntry( String& rTxt, USHORT nCol ) +SvLBoxEntry* SvxEditModulesDlg::CreateEntry( String& rTxt, sal_uInt16 nCol ) { SvLBoxEntry* pEntry = new SvLBoxEntry; if( !pCheckButtonData ) @@ -2104,7 +2111,7 @@ IMPL_LINK( SvxEditModulesDlg, SelectHdl_Impl, SvxCheckListBox *, pBox ) ModuleUserData_Impl* pData = (ModuleUserData_Impl*)pEntry->GetUserData(); if(!pData->IsParent() && pData->GetType() != TYPE_HYPH) { - USHORT nCurPos = pBox->GetSelectEntryPos(); + sal_uInt16 nCurPos = pBox->GetSelectEntryPos(); if(nCurPos < pBox->GetEntryCount() - 1) { bDisableDown = ((ModuleUserData_Impl*)pBox-> @@ -2148,7 +2155,7 @@ IMPL_LINK( SvxEditModulesDlg, BoxCheckButtonHdl_Impl, SvTreeListBox *, pBox ) pData->GetType() == TYPE_HYPH && pEntry != pCurEntry) { - lcl_SetCheckButton( pEntry, FALSE ); + lcl_SetCheckButton( pEntry, sal_False ); pBox->InvalidateEntry( pEntry ); } pEntry = pBox->Next( pEntry ); @@ -2158,7 +2165,7 @@ IMPL_LINK( SvxEditModulesDlg, BoxCheckButtonHdl_Impl, SvTreeListBox *, pBox ) return 0; } -OUString lcl_GetServiceName(BYTE nType) +OUString lcl_GetServiceName(sal_uInt8 nType) { switch(nType) { @@ -2184,12 +2191,12 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) // save old probably changed settings // before switching to new language entries - INT16 nLang = SvxLocaleToLanguage( aLastLocale ); + sal_Int16 nLang = SvxLocaleToLanguage( aLastLocale ); sal_Int32 nStart = 0, nLocalIndex = 0; Sequence< OUString > aChange; - sal_Bool bChanged = FALSE; - for(USHORT i = 0; i < aModulesCLB.GetEntryCount(); i++) + sal_Bool bChanged = sal_False; + for(sal_uInt16 i = 0; i < aModulesCLB.GetEntryCount(); i++) { SvLBoxEntry *pEntry = aModulesCLB.GetEntry(i); ModuleUserData_Impl* pData = (ModuleUserData_Impl*)pEntry->GetUserData(); @@ -2198,7 +2205,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) if(bChanged) { LangImplNameTable *pTable = 0; - BYTE nType = pData->GetType(); + sal_uInt8 nType = pData->GetType(); switch (nType - 1) { case TYPE_SPELL : pTable = &rLinguData.GetSpellTable(); break; @@ -2214,7 +2221,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } nLocalIndex = nStart = 0; aChange.realloc(aModulesCLB.GetEntryCount()); - bChanged = FALSE; + bChanged = sal_False; } else { @@ -2234,7 +2241,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } } - for(ULONG i = 0; i < aModulesCLB.GetEntryCount(); i++) + for(sal_uLong i = 0; i < aModulesCLB.GetEntryCount(); i++) delete (ModuleUserData_Impl*)aModulesCLB.GetEntry(i)->GetUserData(); // @@ -2243,7 +2250,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) aModulesCLB.Clear(); if(LANGUAGE_DONTKNOW != eCurLanguage) { - ULONG n; + sal_uLong n; ServiceInfo_Impl* pInfo; // @@ -2251,18 +2258,18 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) // SvLBoxEntry* pEntry = CreateEntry( sSpell, CBCOL_SECOND ); ModuleUserData_Impl* pUserData = new ModuleUserData_Impl( - String(), TRUE, FALSE, TYPE_SPELL, 0 ); + String(), sal_True, sal_False, TYPE_SPELL, 0 ); pEntry->SetUserData( (void *)pUserData ); pModel->Insert( pEntry ); Sequence< OUString > aNames( rLinguData.GetSortedImplNames( eCurLanguage, TYPE_SPELL ) ); const OUString *pName = aNames.getConstArray(); - ULONG nNames = (ULONG) aNames.getLength(); + sal_uLong nNames = (sal_uLong) aNames.getLength(); sal_Int32 nLocalIndex = 0; // index relative to parent for (n = 0; n < nNames; ++n) { OUString aImplName; - BOOL bIsSuppLang = FALSE; + sal_Bool bIsSuppLang = sal_False; pInfo = rLinguData.GetInfoByImplName( pName[n] ); if (pInfo) @@ -2284,8 +2291,8 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } const bool bCheck = bHasLang && lcl_SeqGetEntryPos( rTable[ eCurLanguage ], aImplName ) >= 0; lcl_SetCheckButton( pNewEntry, bCheck ); - pUserData = new ModuleUserData_Impl( aImplName, FALSE, - bCheck, TYPE_SPELL, (BYTE)nLocalIndex++ ); + pUserData = new ModuleUserData_Impl( aImplName, sal_False, + bCheck, TYPE_SPELL, (sal_uInt8)nLocalIndex++ ); pNewEntry->SetUserData( (void *)pUserData ); pModel->Insert( pNewEntry ); } @@ -2295,18 +2302,18 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) // grammar checker entries // pEntry = CreateEntry( sGrammar, CBCOL_SECOND ); - pUserData = new ModuleUserData_Impl( String(), TRUE, FALSE, TYPE_GRAMMAR, 0 ); + pUserData = new ModuleUserData_Impl( String(), sal_True, sal_False, TYPE_GRAMMAR, 0 ); pEntry->SetUserData( (void *)pUserData ); pModel->Insert( pEntry ); aNames = rLinguData.GetSortedImplNames( eCurLanguage, TYPE_GRAMMAR ); pName = aNames.getConstArray(); - nNames = (ULONG) aNames.getLength(); + nNames = (sal_uLong) aNames.getLength(); nLocalIndex = 0; for (n = 0; n < nNames; ++n) { OUString aImplName; - BOOL bIsSuppLang = FALSE; + sal_Bool bIsSuppLang = sal_False; pInfo = rLinguData.GetInfoByImplName( pName[n] ); if (pInfo) @@ -2328,8 +2335,8 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } const bool bCheck = bHasLang && lcl_SeqGetEntryPos( rTable[ eCurLanguage ], aImplName ) >= 0; lcl_SetCheckButton( pNewEntry, bCheck ); - pUserData = new ModuleUserData_Impl( aImplName, FALSE, - bCheck, TYPE_GRAMMAR, (BYTE)nLocalIndex++ ); + pUserData = new ModuleUserData_Impl( aImplName, sal_False, + bCheck, TYPE_GRAMMAR, (sal_uInt8)nLocalIndex++ ); pNewEntry->SetUserData( (void *)pUserData ); pModel->Insert( pNewEntry ); } @@ -2339,18 +2346,18 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) // hyphenator entries // pEntry = CreateEntry( sHyph, CBCOL_SECOND ); - pUserData = new ModuleUserData_Impl( String(), TRUE, FALSE, TYPE_HYPH, 0 ); + pUserData = new ModuleUserData_Impl( String(), sal_True, sal_False, TYPE_HYPH, 0 ); pEntry->SetUserData( (void *)pUserData ); pModel->Insert( pEntry ); aNames = rLinguData.GetSortedImplNames( eCurLanguage, TYPE_HYPH ); pName = aNames.getConstArray(); - nNames = (ULONG) aNames.getLength(); + nNames = (sal_uLong) aNames.getLength(); nLocalIndex = 0; for (n = 0; n < nNames; ++n) { OUString aImplName; - BOOL bIsSuppLang = FALSE; + sal_Bool bIsSuppLang = sal_False; pInfo = rLinguData.GetInfoByImplName( pName[n] ); if (pInfo) @@ -2372,8 +2379,8 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } const bool bCheck = bHasLang && lcl_SeqGetEntryPos( rTable[ eCurLanguage ], aImplName ) >= 0; lcl_SetCheckButton( pNewEntry, bCheck ); - pUserData = new ModuleUserData_Impl( aImplName, FALSE, - bCheck, TYPE_HYPH, (BYTE)nLocalIndex++ ); + pUserData = new ModuleUserData_Impl( aImplName, sal_False, + bCheck, TYPE_HYPH, (sal_uInt8)nLocalIndex++ ); pNewEntry->SetUserData( (void *)pUserData ); pModel->Insert( pNewEntry ); } @@ -2383,18 +2390,18 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) // thesaurus entries // pEntry = CreateEntry( sThes, CBCOL_SECOND ); - pUserData = new ModuleUserData_Impl( String(), TRUE, FALSE, TYPE_THES, 0 ); + pUserData = new ModuleUserData_Impl( String(), sal_True, sal_False, TYPE_THES, 0 ); pEntry->SetUserData( (void *)pUserData ); pModel->Insert( pEntry ); aNames = rLinguData.GetSortedImplNames( eCurLanguage, TYPE_THES ); pName = aNames.getConstArray(); - nNames = (ULONG) aNames.getLength(); + nNames = (sal_uLong) aNames.getLength(); nLocalIndex = 0; for (n = 0; n < nNames; ++n) { OUString aImplName; - BOOL bIsSuppLang = FALSE; + sal_Bool bIsSuppLang = sal_False; pInfo = rLinguData.GetInfoByImplName( pName[n] ); if (pInfo) @@ -2416,8 +2423,8 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) } const bool bCheck = bHasLang && lcl_SeqGetEntryPos( rTable[ eCurLanguage ], aImplName ) >= 0; lcl_SetCheckButton( pNewEntry, bCheck ); - pUserData = new ModuleUserData_Impl( aImplName, FALSE, - bCheck, TYPE_THES, (BYTE)nLocalIndex++ ); + pUserData = new ModuleUserData_Impl( aImplName, sal_False, + bCheck, TYPE_THES, (sal_uInt8)nLocalIndex++ ); pNewEntry->SetUserData( (void *)pUserData ); pModel->Insert( pNewEntry ); } @@ -2431,28 +2438,28 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox ) IMPL_LINK( SvxEditModulesDlg, UpDownHdl_Impl, PushButton *, pBtn ) { sal_Bool bUp = &aPrioUpPB == pBtn; - USHORT nCurPos = aModulesCLB.GetSelectEntryPos(); + sal_uInt16 nCurPos = aModulesCLB.GetSelectEntryPos(); SvLBoxEntry* pEntry; if (nCurPos != LISTBOX_ENTRY_NOTFOUND && 0 != (pEntry = aModulesCLB.GetEntry(nCurPos))) { - aModulesCLB.SetUpdateMode(FALSE); + aModulesCLB.SetUpdateMode(sal_False); SvLBoxTreeList *pModel = aModulesCLB.GetModel(); ModuleUserData_Impl* pData = (ModuleUserData_Impl*)pEntry->GetUserData(); String aStr(aModulesCLB.GetEntryText(pEntry)); SvLBoxEntry* pToInsert = CreateEntry( aStr, CBCOL_FIRST ); pToInsert->SetUserData( (void *)pData); - BOOL bIsChecked = aModulesCLB.IsChecked(nCurPos); + sal_Bool bIsChecked = aModulesCLB.IsChecked(nCurPos); pModel->Remove(pEntry); - USHORT nDestPos = bUp ? nCurPos - 1 : nCurPos + 1; + sal_uInt16 nDestPos = bUp ? nCurPos - 1 : nCurPos + 1; pModel->Insert(pToInsert, nDestPos); aModulesCLB.CheckEntryPos(nDestPos, bIsChecked ); aModulesCLB.SelectEntryPos(nDestPos ); SelectHdl_Impl(&aModulesCLB); - aModulesCLB.SetUpdateMode(TRUE); + aModulesCLB.SetUpdateMode(sal_True); } return 0; } diff --git a/cui/source/options/optlingu.hrc b/cui/source/options/optlingu.hrc index 6a73b7321235..824e2236e9c6 100644 --- a/cui/source/options/optlingu.hrc +++ b/cui/source/options/optlingu.hrc @@ -85,4 +85,8 @@ #define CLB_EDIT_MODULES_MODULES 320 #define FT_EDIT_MODULES_NEWDICTSLINK 321 #define FL_EDIT_MODULES_BUTTONS 322 - +// IAccessibility2 implementation 2009. ------ +#define STR_LINGU_MODULES_EDIT 323 +#define STR_LINGU_DICS_EDIT_DIC 324 +#define STR_LINGU_OPTIONS_EDIT 325 +// ------ IAccessibility2 implementation 2009. diff --git a/cui/source/options/optlingu.src b/cui/source/options/optlingu.src index be0378f171e8..1187295b2ac3 100644..100755 --- a/cui/source/options/optlingu.src +++ b/cui/source/options/optlingu.src @@ -59,6 +59,7 @@ ModalDialog RID_SVXDLG_EDIT_MODULES }; ListBox LB_EDIT_MODULES_LANGUAGE { + HelpID = "cui:ListBox:RID_SVXDLG_EDIT_MODULES:LB_EDIT_MODULES_LANGUAGE"; Border = TRUE ; Pos = MAP_APPFONT ( 83 , 14 ) ; Size = MAP_APPFONT ( 95 , 80 ) ; @@ -74,6 +75,7 @@ ModalDialog RID_SVXDLG_EDIT_MODULES }; PushButton PB_EDIT_MODULES_PRIO_UP { + HelpID = "cui:PushButton:RID_SVXDLG_EDIT_MODULES:PB_EDIT_MODULES_PRIO_UP"; Pos = MAP_APPFONT ( 184 , 32 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; TabStop = TRUE ; @@ -81,6 +83,7 @@ ModalDialog RID_SVXDLG_EDIT_MODULES }; PushButton PB_EDIT_MODULES_PRIO_DOWN { + HelpID = "cui:PushButton:RID_SVXDLG_EDIT_MODULES:PB_EDIT_MODULES_PRIO_DOWN"; Pos = MAP_APPFONT ( 184 , 49 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; TabStop = TRUE ; @@ -88,6 +91,7 @@ ModalDialog RID_SVXDLG_EDIT_MODULES }; PushButton PB_EDIT_MODULES_PRIO_BACK { + HelpID = "cui:PushButton:RID_SVXDLG_EDIT_MODULES:PB_EDIT_MODULES_PRIO_BACK"; Pos = MAP_APPFONT ( 184 , 66 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; TabStop = TRUE ; @@ -164,6 +168,7 @@ ModalDialog RID_SVXDLG_LNG_ED_NUM_PREBREAK }; NumericField ED_PREBREAK { + HelpID = "cui:NumericField:RID_SVXDLG_LNG_ED_NUM_PREBREAK:ED_PREBREAK"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 14 ) ; Size = MAP_APPFONT ( 31 , 12 ) ; @@ -220,6 +225,7 @@ TabPage RID_SFXPAGE_LINGU }; PushButton PB_LINGU_MODULES_EDIT { + HelpID = "cui:PushButton:RID_SFXPAGE_LINGU:PB_LINGU_MODULES_EDIT"; Pos = MAP_APPFONT ( 198 , 25 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -241,6 +247,7 @@ TabPage RID_SFXPAGE_LINGU }; PushButton PB_LINGU_DICS_NEW_DIC { + HelpID = "cui:PushButton:RID_SFXPAGE_LINGU:PB_LINGU_DICS_NEW_DIC"; Pos = MAP_APPFONT ( 198 , 70 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -248,6 +255,7 @@ TabPage RID_SFXPAGE_LINGU }; PushButton PB_LINGU_DICS_EDIT_DIC { + HelpID = "cui:PushButton:RID_SFXPAGE_LINGU:PB_LINGU_DICS_EDIT_DIC"; Pos = MAP_APPFONT ( 198 , 87 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -255,6 +263,7 @@ TabPage RID_SFXPAGE_LINGU }; PushButton PB_LINGU_DICS_DEL_DIC { + HelpID = "cui:PushButton:RID_SFXPAGE_LINGU:PB_LINGU_DICS_DEL_DIC"; Pos = MAP_APPFONT ( 198 , 104 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -276,6 +285,7 @@ TabPage RID_SFXPAGE_LINGU }; PushButton PB_LINGU_OPTIONS_EDIT { + HelpID = "cui:PushButton:RID_SFXPAGE_LINGU:PB_LINGU_OPTIONS_EDIT"; Pos = MAP_APPFONT ( 198 , 133 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -334,6 +344,19 @@ TabPage RID_SFXPAGE_LINGU { Text [ en-US ] = "Hyphenate special regions"; }; + String STR_LINGU_MODULES_EDIT + { + Text [ en-US ] = "Edit Available language modules"; + }; + String STR_LINGU_DICS_EDIT_DIC + { + Text [ en-US ] = "Edit User-defined dictionaries"; + }; + String STR_LINGU_OPTIONS_EDIT + { + Text [ en-US ] = "Edit Options"; + }; + // ------ IAccessibility2 implementation 2009. }; // end: TabPage RID_SFXPAGE_LINGU @@ -344,11 +367,4 @@ QueryBox RID_SFXQB_DELDICT DefButton = WB_DEF_NO ; Message [ en-US ] = "Do you want to delete the dictionary?" ; }; - // RID_SFXQB_DEL_IGNORELIST ---------------------------------------------- -QueryBox RID_SFXQB_DEL_IGNORELIST -{ - Buttons = WB_YES_NO ; - DefButton = WB_DEF_NO ; - Message [ en-US ] = "Do you want to delete the ignore list?" ; -}; // ******************************************************************* EOF diff --git a/cui/source/options/optmemory.cxx b/cui/source/options/optmemory.cxx index 1ef0a8237ffb..beb0d062d60e 100644 --- a/cui/source/options/optmemory.cxx +++ b/cui/source/options/optmemory.cxx @@ -177,15 +177,15 @@ SfxTabPage* OfaMemoryOptionsPage::Create( Window* pParent, const SfxItemSet& rAt // ----------------------------------------------------------------------- -BOOL OfaMemoryOptionsPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool OfaMemoryOptionsPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; SvtCacheOptions aCacheOptions; // Undo-Schritte if ( aUndoEdit.GetText() != aUndoEdit.GetSavedValue() ) - SvtUndoOptions().SetUndoCount((UINT16)aUndoEdit.GetValue()); + SvtUndoOptions().SetUndoCount((sal_uInt16)aUndoEdit.GetValue()); // GraphicCache aCacheOptions.SetGraphicManagerTotalCacheSize( GetNfGraphicCacheVal() ); @@ -199,7 +199,7 @@ BOOL OfaMemoryOptionsPage::FillItemSet( SfxItemSet& rSet ) GraphicManager& rGrfMgr = aDummyObject.GetGraphicManager(); rGrfMgr.SetMaxCacheSize( aCacheOptions.GetGraphicManagerTotalCacheSize() ); - rGrfMgr.SetMaxObjCacheSize( aCacheOptions.GetGraphicManagerObjectCacheSize(), TRUE ); + rGrfMgr.SetMaxObjCacheSize( aCacheOptions.GetGraphicManagerObjectCacheSize(), sal_True ); rGrfMgr.SetCacheTimeout( aCacheOptions.GetGraphicManagerObjectReleaseTime() ); // OLECache @@ -209,7 +209,7 @@ BOOL OfaMemoryOptionsPage::FillItemSet( SfxItemSet& rSet ) if( aQuickLaunchCB.IsChecked() != aQuickLaunchCB.GetSavedValue()) { rSet.Put(SfxBoolItem(SID_ATTR_QUICKLAUNCHER, aQuickLaunchCB.IsChecked())); - bModified = TRUE; + bModified = sal_True; } return bModified; @@ -232,7 +232,7 @@ void OfaMemoryOptionsPage::Reset( const SfxItemSet& rSet ) SetNfGraphicObjectCacheVal( Min( static_cast<sal_Int32>(GetNfGraphicCacheVal()), aCacheOptions.GetGraphicManagerObjectCacheSize() ) ); sal_Int32 nTime = aCacheOptions.GetGraphicManagerObjectReleaseTime(); - Time aTime( (USHORT)( nTime / 3600 ), (USHORT)( ( nTime % 3600 ) / 60 ), (USHORT)( ( nTime % 3600 ) % 60 ) ); + Time aTime( (sal_uInt16)( nTime / 3600 ), (sal_uInt16)( ( nTime % 3600 ) / 60 ), (sal_uInt16)( ( nTime % 3600 ) % 60 ) ); aTfGraphicObjectTime.SetTime( aTime ); GraphicCacheConfigHdl( &aNfGraphicCache ); @@ -240,7 +240,7 @@ void OfaMemoryOptionsPage::Reset( const SfxItemSet& rSet ) // OLECache aNfOLECache.SetValue( Max( aCacheOptions.GetWriterOLE_Objects(), aCacheOptions.GetDrawingEngineOLE_Objects() ) ); - SfxItemState eState = rSet.GetItemState( SID_ATTR_QUICKLAUNCHER, FALSE, &pItem ); + SfxItemState eState = rSet.GetItemState( SID_ATTR_QUICKLAUNCHER, sal_False, &pItem ); if ( SFX_ITEM_SET == eState ) aQuickLaunchCB.Check( ( (SfxBoolItem*)pItem )->GetValue() ); else if ( SFX_ITEM_DISABLED == eState ) diff --git a/cui/source/options/optmemory.hxx b/cui/source/options/optmemory.hxx index 8068ab53aaca..6b9c11000b1a 100644 --- a/cui/source/options/optmemory.hxx +++ b/cui/source/options/optmemory.hxx @@ -82,7 +82,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optmemory.src b/cui/source/options/optmemory.src index 557fa6a8d960..5c95cbb53aa6 100644 --- a/cui/source/options/optmemory.src +++ b/cui/source/options/optmemory.src @@ -51,6 +51,7 @@ TabPage OFA_TP_MEMORY }; NumericField ED_UNDO { + HelpID = "cui:NumericField:OFA_TP_MEMORY:ED_UNDO"; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROW1 ); Size = MAP_APPFONT( WIDTH2, RSC_CD_TEXTBOX_HEIGHT ); @@ -80,6 +81,7 @@ TabPage OFA_TP_MEMORY }; NumericField NF_GRAPHICCACHE { + HelpID = "cui:NumericField:OFA_TP_MEMORY:NF_GRAPHICCACHE"; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROW3 ); Size = MAP_APPFONT( WIDTH2, RSC_CD_TEXTBOX_HEIGHT ); @@ -103,6 +105,7 @@ TabPage OFA_TP_MEMORY }; NumericField NF_GRAPHICOBJECTCACHE { + HelpID = "cui:NumericField:OFA_TP_MEMORY:NF_GRAPHICOBJECTCACHE"; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROW4 ); Size = MAP_APPFONT( WIDTH2, RSC_CD_TEXTBOX_HEIGHT ); @@ -127,6 +130,7 @@ TabPage OFA_TP_MEMORY }; TimeField TF_GRAPHICOBJECTTIME { + HelpID = "cui:TimeField:OFA_TP_MEMORY:TF_GRAPHICOBJECTTIME"; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROW5 ); Size = MAP_APPFONT( WIDTH2, RSC_CD_TEXTBOX_HEIGHT ); @@ -179,6 +183,7 @@ TabPage OFA_TP_MEMORY }; NumericField NF_OLECACHE { + HelpID = "cui:NumericField:OFA_TP_MEMORY:NF_OLECACHE"; Border = TRUE ; Pos = MAP_APPFONT( COL3, ROW7 ); Size = MAP_APPFONT( WIDTH2, RSC_CD_TEXTBOX_HEIGHT ); @@ -195,6 +200,7 @@ TabPage OFA_TP_MEMORY }; CheckBox CB_QUICKLAUNCH { + HelpID = "cui:CheckBox:OFA_TP_MEMORY:CB_QUICKLAUNCH"; Pos = MAP_APPFONT( COL1, ROW9 ); Size = MAP_APPFONT( WHOLE_WIDTH - COL1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "Load %PRODUCTNAME during system start-up"; diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx index 1737d4ac685c..a3a30c1e13db 100644 --- a/cui/source/options/optpath.cxx +++ b/cui/source/options/optpath.cxx @@ -33,7 +33,6 @@ #include <vcl/msgbox.hxx> #include <sfx2/filedlghelper.hxx> #include <sfx2/app.hxx> -#include <svl/pickerhelper.hxx> #include <svl/aeitem.hxx> #include <svtools/svtabbx.hxx> #include <svtools/filedlg.hxx> @@ -105,18 +104,18 @@ struct OptPath_Impl struct PathUserData_Impl { - USHORT nRealId; + sal_uInt16 nRealId; SfxItemState eState; String sUserPath; String sWritablePath; - PathUserData_Impl( USHORT nId ) : + PathUserData_Impl( sal_uInt16 nId ) : nRealId( nId ), eState( SFX_ITEM_UNKNOWN ) {} }; struct Handle2CfgNameMapping_Impl { - USHORT m_nHandle; + sal_uInt16 m_nHandle; const char* m_pCfgName; }; @@ -137,10 +136,10 @@ static Handle2CfgNameMapping_Impl const Hdl2CfgMap_Impl[] = { USHRT_MAX, NULL } }; -static String getCfgName_Impl( USHORT _nHandle ) +static String getCfgName_Impl( sal_uInt16 _nHandle ) { String sCfgName; - USHORT nIndex = 0; + sal_uInt16 nIndex = 0; while ( Hdl2CfgMap_Impl[ nIndex ].m_nHandle != USHRT_MAX ) { if ( Hdl2CfgMap_Impl[ nIndex ].m_nHandle == _nHandle ) @@ -160,9 +159,9 @@ static String getCfgName_Impl( USHORT _nHandle ) String Convert_Impl( const String& rValue ) { char cDelim = MULTIPATH_DELIMITER; - USHORT nCount = rValue.GetTokenCount( cDelim ); + sal_uInt16 nCount = rValue.GetTokenCount( cDelim ); String aReturn; - for ( USHORT i=0; i<nCount ; ++i ) + for ( sal_uInt16 i=0; i<nCount ; ++i ) { String aValue = rValue.GetToken( i, cDelim ); INetURLObject aObj( aValue ); @@ -190,7 +189,7 @@ long SvxControlFocusHelper::Notify( NotifyEvent& rNEvt ) // functions ------------------------------------------------------------- -BOOL IsMultiPath_Impl( const USHORT nIndex ) +sal_Bool IsMultiPath_Impl( const sal_uInt16 nIndex ) { #if OSL_DEBUG_LEVEL > 1 return ( SvtPathOptions::PATH_AUTOCORRECT == nIndex || @@ -252,7 +251,6 @@ SvxPathTabPage::SvxPathTabPage( Window* pParent, const SfxItemSet& rSet ) : WinBits nBits = WB_SORT | WB_HSCROLL | WB_CLIPCHILDREN | WB_TABSTOP; pPathBox = new svx::OptHeaderTabListBox( &aPathCtrl, nBits ); aPathCtrl.SetFocusControl( pPathBox ); - pPathBox->SetWindowBits( nBits ); pPathBox->SetDoubleClickHdl( aLink ); pPathBox->SetSelectHdl( LINK( this, SvxPathTabPage, PathSelect_Impl ) ); pPathBox->SetSelectionMode( MULTIPLE_SELECTION ); @@ -279,7 +277,7 @@ SvxPathTabPage::~SvxPathTabPage() aPathCtrl.SetFocusControl( NULL ); pHeaderBar->Hide(); - for ( USHORT i = 0; i < pPathBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < pPathBox->GetEntryCount(); ++i ) delete (PathUserData_Impl*)pPathBox->GetEntry(i)->GetUserData(); delete pPathBox; delete pHeaderBar; @@ -296,17 +294,17 @@ SfxTabPage* SvxPathTabPage::Create( Window* pParent, // ----------------------------------------------------------------------- -BOOL SvxPathTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxPathTabPage::FillItemSet( SfxItemSet& ) { SvtPathOptions aPathOpt; - for ( USHORT i = 0; i < pPathBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < pPathBox->GetEntryCount(); ++i ) { PathUserData_Impl* pPathImpl = (PathUserData_Impl*)pPathBox->GetEntry(i)->GetUserData(); - USHORT nRealId = pPathImpl->nRealId; + sal_uInt16 nRealId = pPathImpl->nRealId; if ( pPathImpl->eState == SFX_ITEM_SET ) SetPathList( nRealId, pPathImpl->sUserPath, pPathImpl->sWritablePath ); } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------- @@ -316,7 +314,7 @@ void SvxPathTabPage::Reset( const SfxItemSet& ) pPathBox->Clear(); SvtPathOptions aPathOpt; //! deprecated - for( USHORT i = 0; i <= (USHORT)SvtPathOptions::PATH_WORK; ++i ) + for( sal_uInt16 i = 0; i <= (sal_uInt16)SvtPathOptions::PATH_WORK; ++i ) { // only writer uses autotext if ( i == SvtPathOptions::PATH_AUTOTEXT @@ -369,7 +367,7 @@ void SvxPathTabPage::Reset( const SfxItemSet& ) pHeaderBar->SetItemSize( ITEMID_TYPE, aUserData.GetToken(0).ToInt32() ); HeaderEndDrag_Impl( NULL ); // Sortierrichtung restaurieren - BOOL bUp = (BOOL)(USHORT)aUserData.GetToken(1).ToInt32(); + sal_Bool bUp = (sal_Bool)(sal_uInt16)aUserData.GetToken(1).ToInt32(); HeaderBarItemBits nBits = pHeaderBar->GetItemBits(ITEMID_TYPE); if ( bUp ) @@ -395,7 +393,7 @@ void SvxPathTabPage::FillUserData() String aUserData = String::CreateFromInt32( pHeaderBar->GetItemSize( ITEMID_TYPE ) ); aUserData += ';'; HeaderBarItemBits nBits = pHeaderBar->GetItemBits( ITEMID_TYPE ); - BOOL bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); + sal_Bool bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); aUserData += bUp ? '1' : '0'; SetUserData( aUserData ); } @@ -404,14 +402,14 @@ void SvxPathTabPage::FillUserData() IMPL_LINK( SvxPathTabPage, PathSelect_Impl, svx::OptHeaderTabListBox *, EMPTYARG ) { - USHORT nSelCount = 0; + sal_uInt16 nSelCount = 0; SvLBoxEntry* pEntry = pPathBox->FirstSelected(); //the entry image indicates whether the path is write protected Image aEntryImage; if(pEntry) aEntryImage = pPathBox->GetCollapsedEntryBmp( pEntry ); - BOOL bEnable = !aEntryImage; + sal_Bool bEnable = !aEntryImage; while ( pEntry && ( nSelCount < 2 ) ) { nSelCount++; @@ -439,14 +437,14 @@ IMPL_LINK( SvxPathTabPage, StandardHdl_Impl, PushButton *, EMPTYARG ) sal_Bool bReadOnly = sal_False; GetPathList( pPathImpl->nRealId, sInternal, sUser, sWritable, bReadOnly ); - USHORT i; - USHORT nOldCount = aOldPath.GetTokenCount( MULTIPATH_DELIMITER ); - USHORT nIntCount = sInternal.GetTokenCount( MULTIPATH_DELIMITER ); + sal_uInt16 i; + sal_uInt16 nOldCount = aOldPath.GetTokenCount( MULTIPATH_DELIMITER ); + sal_uInt16 nIntCount = sInternal.GetTokenCount( MULTIPATH_DELIMITER ); for ( i = 0; i < nOldCount; ++i ) { bool bFound = false; String sOnePath = aOldPath.GetToken( i, MULTIPATH_DELIMITER ); - for ( USHORT j = 0; !bFound && j < nIntCount; ++j ) + for ( sal_uInt16 j = 0; !bFound && j < nIntCount; ++j ) { if ( sInternal.GetToken( i, MULTIPATH_DELIMITER ) == sOnePath ) bFound = true; @@ -496,7 +494,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const String& _rFolder ) GetPathList( pPathImpl->nRealId, sInternal, sUser, sWritable, bReadOnly ); sUser = pPathImpl->sUserPath; sWritable = pPathImpl->sWritablePath; - USHORT nPos = pPathImpl->nRealId; + sal_uInt16 nPos = pPathImpl->nRealId; // old path is an URL? INetURLObject aObj( sWritable ); @@ -519,7 +517,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const String& _rFolder ) if ( bChanged ) { pPathBox->SetEntryText( Convert_Impl( sNewPathStr ), pEntry, 1 ); - nPos = (USHORT)pPathBox->GetModel()->GetAbsPos( pEntry ); + nPos = (sal_uInt16)pPathBox->GetModel()->GetAbsPos( pEntry ); pPathImpl = (PathUserData_Impl*)pPathBox->GetEntry(nPos)->GetUserData(); pPathImpl->eState = SFX_ITEM_SET; pPathImpl->sWritablePath = sNewPathStr; @@ -551,7 +549,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const String& _rFolder ) IMPL_LINK( SvxPathTabPage, PathHdl_Impl, PushButton *, EMPTYARG ) { SvLBoxEntry* pEntry = pPathBox->GetCurEntry(); - USHORT nPos = ( pEntry != NULL ) ? ( (PathUserData_Impl*)pEntry->GetUserData() )->nRealId : 0; + sal_uInt16 nPos = ( pEntry != NULL ) ? ( (PathUserData_Impl*)pEntry->GetUserData() )->nRealId : 0; String sInternal, sUser, sWritable; if ( pEntry ) { @@ -593,10 +591,10 @@ IMPL_LINK( SvxPathTabPage, PathHdl_Impl, PushButton *, EMPTYARG ) String sFullPath; String sNewPath = pMultiDlg->GetPath(); char cDelim = MULTIPATH_DELIMITER; - USHORT nCount = sNewPath.GetTokenCount( cDelim ); + sal_uInt16 nCount = sNewPath.GetTokenCount( cDelim ); if ( nCount > 0 ) { - USHORT i = 0; + sal_uInt16 i = 0; for ( ; i < nCount - 1; ++i ) { if ( sUser.Len() > 0 ) @@ -631,8 +629,6 @@ IMPL_LINK( SvxPathTabPage, PathHdl_Impl, PushButton *, EMPTYARG ) xFolderPicker = ::com::sun::star::uno::Reference< XFolderPicker >( xFactory->createInstance( aService ), UNO_QUERY ); -// svt::SetDialogHelpId( xFolderPicker, HID_OPTIONS_PATHS_SELECTFOLDER ); - INetURLObject aURL( sWritable, INET_PROT_FILE ); xFolderPicker->setDisplayDirectory( aURL.GetMainURL( INetURLObject::NO_DECODE ) ); @@ -665,7 +661,7 @@ IMPL_LINK( SvxPathTabPage, HeaderSelect_Impl, HeaderBar*, pBar ) return 0; HeaderBarItemBits nBits = pHeaderBar->GetItemBits(ITEMID_TYPE); - BOOL bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); + sal_Bool bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); SvSortMode eMode = SortAscending; if ( bUp ) @@ -696,7 +692,7 @@ IMPL_LINK( SvxPathTabPage, HeaderEndDrag_Impl, HeaderBar*, pBar ) if ( !pHeaderBar->IsItemMode() ) { Size aSz; - USHORT nTabs = pHeaderBar->GetItemCount(); + sal_uInt16 nTabs = pHeaderBar->GetItemCount(); long nTmpSz = 0; long nWidth = pHeaderBar->GetItemSize(ITEMID_TYPE); long nBarWidth = pHeaderBar->GetSizePixel().Width(); @@ -706,7 +702,7 @@ IMPL_LINK( SvxPathTabPage, HeaderEndDrag_Impl, HeaderBar*, pBar ) else if ( ( nBarWidth - nWidth ) < TAB_WIDTH_MIN ) pHeaderBar->SetItemSize( ITEMID_TYPE, nBarWidth - TAB_WIDTH_MIN ); - for ( USHORT i = 1; i <= nTabs; ++i ) + for ( sal_uInt16 i = 1; i <= nTabs; ++i ) { long _nWidth = pHeaderBar->GetItemSize(i); aSz.Width() = _nWidth + nTmpSz; @@ -734,7 +730,7 @@ IMPL_LINK( SvxPathTabPage, DialogClosedHdl, DialogClosedEvent*, pEvt ) // ----------------------------------------------------------------------- void SvxPathTabPage::GetPathList( - USHORT _nPathHandle, String& _rInternalPath, + sal_uInt16 _nPathHandle, String& _rInternalPath, String& _rUserPath, String& _rWritablePath, sal_Bool& _rReadOnly ) { String sCfgName = getCfgName_Impl( _nPathHandle ); @@ -810,7 +806,7 @@ void SvxPathTabPage::GetPathList( // ----------------------------------------------------------------------- void SvxPathTabPage::SetPathList( - USHORT _nPathHandle, const String& _rUserPath, const String& _rWritablePath ) + sal_uInt16 _nPathHandle, const String& _rUserPath, const String& _rWritablePath ) { String sCfgName = getCfgName_Impl( _nPathHandle ); @@ -829,10 +825,10 @@ void SvxPathTabPage::SetPathList( { // save user paths char cDelim = MULTIPATH_DELIMITER; - USHORT nCount = _rUserPath.GetTokenCount( cDelim ); + sal_uInt16 nCount = _rUserPath.GetTokenCount( cDelim ); Sequence< ::rtl::OUString > aPathSeq( nCount ); ::rtl::OUString* pArray = aPathSeq.getArray(); - for ( USHORT i = 0; i < nCount; ++i ) + for ( sal_uInt16 i = 0; i < nCount; ++i ) pArray[i] = ::rtl::OUString( _rUserPath.GetToken( i, cDelim ) ); String sProp( sCfgName ); sProp += POSTFIX_USER; diff --git a/cui/source/options/optpath.src b/cui/source/options/optpath.src index 7114f90b8de9..c6400a2246ba 100644 --- a/cui/source/options/optpath.src +++ b/cui/source/options/optpath.src @@ -65,12 +65,14 @@ TabPage RID_SFXPAGE_PATH }; PushButton BTN_PATH { + HelpID = "cui:PushButton:RID_SFXPAGE_PATH:BTN_PATH"; Pos = MAP_APPFONT ( 183 , 165 ) ; Size = MAP_APPFONT ( 65 , 14 ) ; Text [ en-US ] = "~Edit..." ; }; PushButton BTN_STANDARD { + HelpID = "cui:PushButton:RID_SFXPAGE_PATH:BTN_STANDARD"; Pos = MAP_APPFONT ( 115 , 165 ) ; Size = MAP_APPFONT ( 65 , 14 ) ; Text [ en-US ] = "~Default" ; diff --git a/cui/source/options/optsave.cxx b/cui/source/options/optsave.cxx index 625f9f6fed90..c0747362a64d 100644 --- a/cui/source/options/optsave.cxx +++ b/cui/source/options/optsave.cxx @@ -68,40 +68,9 @@ using rtl::OUString; #define C2S(cChar) String( RTL_CONSTASCII_USTRINGPARAM(cChar) ) #define CFG_PAGE_AND_GROUP C2S("General"), C2S("LoadSave") // !! you have to update these index, if you changed the list of the child windows !! -#define WININDEX_AUTOSAVE ((USHORT)6) -#define WININDEX_SAVEURL_RELFSYS ((USHORT)9) +#define WININDEX_AUTOSAVE ((sal_uInt16)6) +#define WININDEX_SAVEURL_RELFSYS ((sal_uInt16)9) -// -------------------- -------------------------------------------------- -class FilterWarningDialog_Impl : public ModalDialog -{ - OKButton aOk; - CancelButton aCancel; - FixedImage aImage; - FixedInfo aFilterWarningFT; - - public: - FilterWarningDialog_Impl(Window* pParent); - - void SetFilterName(const String& rFilterUIName); -}; -// ---------------------------------------------------------------------- -FilterWarningDialog_Impl::FilterWarningDialog_Impl(Window* pParent) : - ModalDialog(pParent, CUI_RES( RID_SVXDLG_FILTER_WARNING ) ), - aOk( this, CUI_RES(PB_OK )), - aCancel( this, CUI_RES(PB_CANCEL )), - aImage( this, CUI_RES(IMG_WARNING )), - aFilterWarningFT( this, CUI_RES(FT_FILTER_WARNING )) -{ - FreeResource(); - aImage.SetImage(WarningBox::GetStandardImage()); -} -// ---------------------------------------------------------------------- -void FilterWarningDialog_Impl::SetFilterName(const String& rFilterUIName) -{ - String sTmp(aFilterWarningFT.GetText()); - sTmp.SearchAndReplaceAscii("%1", rFilterUIName); - aFilterWarningFT.SetText(sTmp); -} // ---------------------------------------------------------------------- struct SvxSaveTabPage_Impl @@ -259,26 +228,12 @@ SfxTabPage* SfxSaveTabPage::Create( Window* pParent, return ( new SfxSaveTabPage( pParent, rAttrSet ) ); } -OUString lcl_ExtractUIName(const Sequence<PropertyValue> rProperties) -{ - OUString sRet; - const PropertyValue* pProperties = rProperties.getConstArray(); - for(int nProp = 0; nProp < rProperties.getLength(); nProp++) - { - if(!pProperties[nProp].Name.compareToAscii("UIName")) - { - pProperties[nProp].Value >>= sRet; - break; - } - } - return sRet; -} // ----------------------------------------------------------------------- void SfxSaveTabPage::DetectHiddenControls() { long nDelta = 0; // the index of the first child window which perhaps have to move upwards - USHORT nWinIndex = WININDEX_SAVEURL_RELFSYS; + sal_uInt16 nWinIndex = WININDEX_SAVEURL_RELFSYS; SvtOptionsDialogOptions aOptionsDlgOpt; if ( aOptionsDlgOpt.IsOptionHidden( C2S("Backup"), CFG_PAGE_AND_GROUP ) ) @@ -305,7 +260,7 @@ void SfxSaveTabPage::DetectHiddenControls() if ( nDelta > 0 ) { - USHORT i, nChildCount = GetChildCount(); + sal_uInt16 i, nChildCount = GetChildCount(); for ( i = nWinIndex; i < nChildCount; ++i ) { Window* pWin = GetChild(i); @@ -316,9 +271,9 @@ void SfxSaveTabPage::DetectHiddenControls() } } // ----------------------------------------------------------------------- -BOOL SfxSaveTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SfxSaveTabPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; SvtSaveOptions aSaveOpt; if(aLoadUserSettingsCB.IsChecked() != aLoadUserSettingsCB.GetSavedValue()) { @@ -338,54 +293,54 @@ BOOL SfxSaveTabPage::FillItemSet( SfxItemSet& rSet ) { rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_DOCINFO ), aDocInfoCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aBackupCB.IsEnabled() && aBackupCB.IsChecked() != aBackupCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_BACKUP ), aBackupCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aSizeOptimizationCB.IsChecked() != aSizeOptimizationCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_PRETTYPRINTING ), !aSizeOptimizationCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aAutoSaveCB.IsChecked() != aAutoSaveCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_AUTOSAVE ), aAutoSaveCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aWarnAlienFormatCB.IsChecked() != aWarnAlienFormatCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_WARNALIENFORMAT ), aWarnAlienFormatCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aAutoSaveEdit.GetText() != aAutoSaveEdit.GetSavedValue() ) { rSet.Put( SfxUInt16Item( GetWhich( SID_ATTR_AUTOSAVEMINUTE ), - (UINT16)aAutoSaveEdit.GetValue() ) ); - bModified |= TRUE; + (sal_uInt16)aAutoSaveEdit.GetValue() ) ); + bModified |= sal_True; } // relativ speichern if ( aRelativeFsysCB.IsChecked() != aRelativeFsysCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_SAVEREL_FSYS ), aRelativeFsysCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } if ( aRelativeInetCB.IsChecked() != aRelativeInetCB.GetSavedValue() ) { rSet.Put( SfxBoolItem( GetWhich( SID_SAVEREL_INET ), aRelativeInetCB.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; } SvtModuleOptions aModuleOpt; @@ -476,7 +431,7 @@ void SfxSaveTabPage::Reset( const SfxItemSet& ) Reference< XContainerQuery > xQuery(pImpl->xFact, UNO_QUERY); if(xQuery.is()) { - for(USHORT n = 0; n < aDocTypeLB.GetEntryCount(); n++) + for(sal_uInt16 n = 0; n < aDocTypeLB.GetEntryCount(); n++) { long nData = (long) aDocTypeLB.GetEntryData(n); OUString sCommand; @@ -543,7 +498,7 @@ void SfxSaveTabPage::Reset( const SfxItemSet& ) aDocInfoCB.Check(aSaveOpt.IsDocInfoSave()); aBackupCB.Check(aSaveOpt.IsBackup()); - BOOL bBackupRO = aSaveOpt.IsReadOnly(SvtSaveOptions::E_BACKUP); + sal_Bool bBackupRO = aSaveOpt.IsReadOnly(SvtSaveOptions::E_BACKUP); aBackupCB.Enable(!bBackupRO); aBackupFI.Show(bBackupRO); @@ -628,7 +583,7 @@ OUString lcl_ExtracUIName(const Sequence<PropertyValue> rProperties) IMPL_LINK( SfxSaveTabPage, FilterHdl_Impl, ListBox *, pBox ) { - USHORT nCurPos = aDocTypeLB.GetSelectEntryPos(); + sal_uInt16 nCurPos = aDocTypeLB.GetSelectEntryPos(); long nData = -1; if(nCurPos < APP_COUNT) @@ -656,7 +611,7 @@ IMPL_LINK( SfxSaveTabPage, FilterHdl_Impl, ListBox *, pBox ) OUString sSelect; for(int i = 0; i < pImpl->aUIFilterArr[nData].getLength(); i++) { - USHORT nEntryPos = aSaveAsLB.InsertEntry(pUIFilters[i]); + sal_uInt16 nEntryPos = aSaveAsLB.InsertEntry(pUIFilters[i]); if ( pImpl->aODFArr[nData][i] ) aSaveAsLB.SetEntryData( nEntryPos, (void*)pImpl ); if(pFilters[i] == pImpl->aDefaultArr[nData]) @@ -695,7 +650,7 @@ IMPL_LINK( SfxSaveTabPage, ODFVersionHdl_Impl, ListBox *, EMPTYARG ) if ( bShown ) { bool bHasODFFormat = false; - USHORT i = 0, nCount = aSaveAsLB.GetEntryCount(); + sal_uInt16 i = 0, nCount = aSaveAsLB.GetEntryCount(); for ( ; i < nCount; ++ i ) { if ( aSaveAsLB.GetEntryData(i) != NULL ) diff --git a/cui/source/options/optsave.hxx b/cui/source/options/optsave.hxx index 6f6d424fde4a..509221cd66f5 100644 --- a/cui/source/options/optsave.hxx +++ b/cui/source/options/optsave.hxx @@ -97,7 +97,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rAttrSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); }; diff --git a/cui/source/options/optsave.src b/cui/source/options/optsave.src index 39ffea74e988..91c301c27375 100644 --- a/cui/source/options/optsave.src +++ b/cui/source/options/optsave.src @@ -51,12 +51,14 @@ TabPage RID_SFXPAGE_SAVE }; CheckBox CB_LOAD_SETTINGS { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:CB_LOAD_SETTINGS"; Pos = MAP_APPFONT ( 12 , 11 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "Load user-specific settings with the document"; }; CheckBox CB_LOAD_DOCPRINTER { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:CB_LOAD_DOCPRINTER"; Pos = MAP_APPFONT ( 12 , 22 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "Load printer settings with the document"; @@ -69,6 +71,7 @@ TabPage RID_SFXPAGE_SAVE }; CheckBox BTN_DOCINFO { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_DOCINFO"; Pos = MAP_APPFONT ( 12 , 41 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "~Edit document properties before saving" ; @@ -82,18 +85,21 @@ TabPage RID_SFXPAGE_SAVE }; CheckBox BTN_BACKUP { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_BACKUP"; Pos = MAP_APPFONT ( 12 , 52 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "Al~ways create backup copy" ; }; CheckBox BTN_AUTOSAVE { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_AUTOSAVE"; Pos = MAP_APPFONT ( 12 , 63 ) ; Size = MAP_APPFONT ( 193 , 10 ) ; Text [ en-US ] = "Save ~AutoRecovery information every" ; }; NumericField ED_AUTOSAVE { + HelpID = "cui:NumericField:RID_SFXPAGE_SAVE:ED_AUTOSAVE"; Border = TRUE ; Pos = MAP_APPFONT ( 210 , 61 ) ; Size = MAP_APPFONT ( 21 , 12 ) ; @@ -116,12 +122,14 @@ TabPage RID_SFXPAGE_SAVE }; CheckBox BTN_RELATIVE_FSYS { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_RELATIVE_FSYS"; Pos = MAP_APPFONT ( 12 , 74 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "Save URLs relative to file system" ; }; CheckBox BTN_RELATIVE_INET { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_RELATIVE_INET"; Pos = MAP_APPFONT ( 12 , 85 ) ; Size = MAP_APPFONT ( 248 , 10 ) ; Text [ en-US ] = "Save URLs relative to internet" ; @@ -140,6 +148,7 @@ TabPage RID_SFXPAGE_SAVE }; ListBox LB_ODF_VERSION { + HelpID = "cui:ListBox:RID_SFXPAGE_SAVE:LB_ODF_VERSION"; Pos = MAP_APPFONT ( 136 , 105 ) ; Size = MAP_APPFONT ( 108 , 58 ) ; Border = TRUE; @@ -153,12 +162,14 @@ TabPage RID_SFXPAGE_SAVE }; CheckBox BTN_NOPRETTYPRINTING { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_NOPRETTYPRINTING"; Pos = MAP_APPFONT ( 12 , 120 ) ; Size = MAP_APPFONT ( 248 , 10 ) ; Text [ en-US ] = "Size optimization for ODF format" ; }; CheckBox BTN_WARNALIENFORMAT { + HelpID = "cui:CheckBox:RID_SFXPAGE_SAVE:BTN_WARNALIENFORMAT"; Pos = MAP_APPFONT ( 12 , 131 ) ; Size = MAP_APPFONT ( 248 , 10 ) ; Text [ en-US ] = "Warn when not saving in ODF or default format" ; @@ -177,6 +188,7 @@ TabPage RID_SFXPAGE_SAVE }; ListBox LB_APP { + HelpID = "cui:ListBox:RID_SFXPAGE_SAVE:LB_APP"; Pos = MAP_APPFONT ( 12 , 153 ) ; Size = MAP_APPFONT ( 108 , 58 ) ; Border = TRUE; @@ -200,6 +212,7 @@ TabPage RID_SFXPAGE_SAVE }; ListBox LB_FILTER { + HelpID = "cui:ListBox:RID_SFXPAGE_SAVE:LB_FILTER"; Pos = MAP_APPFONT ( 136 , 153 ) ; Size = MAP_APPFONT ( 108 , 58 ) ; Border = TRUE; diff --git a/cui/source/options/optspell.src b/cui/source/options/optspell.src index 93957d9d79eb..80a9e974017d 100644 --- a/cui/source/options/optspell.src +++ b/cui/source/options/optspell.src @@ -39,6 +39,7 @@ TabPage RID_SFXPAGE_SPELL Text [ en-US ] = "Spellcheck" ; PushButton BTN_BOOK { + HelpID = "cui:PushButton:RID_SFXPAGE_SPELL:BTN_BOOK"; Pos = MAP_APPFONT ( 128 , 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Edit..." ; @@ -46,6 +47,7 @@ TabPage RID_SFXPAGE_SPELL }; MultiListBox LB_BOOK { + HelpID = "cui:MultiListBox:RID_SFXPAGE_SPELL:LB_BOOK"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 103 , 47 ) ; @@ -60,6 +62,7 @@ TabPage RID_SFXPAGE_SPELL }; CheckBox BTN_CAPS { + HelpID = "cui:CheckBox:RID_SFXPAGE_SPELL:BTN_CAPS"; Pos = MAP_APPFONT ( 12 , 82 ) ; Size = MAP_APPFONT ( 103 , 10 ) ; Text [ en-US ] = "~Capital words" ; @@ -67,6 +70,7 @@ TabPage RID_SFXPAGE_SPELL }; CheckBox BTN_NUMS { + HelpID = "cui:CheckBox:RID_SFXPAGE_SPELL:BTN_NUMS"; Pos = MAP_APPFONT ( 12 , 95 ) ; Size = MAP_APPFONT ( 103 , 10 ) ; Text [ en-US ] = "~Words with numbers " ; @@ -74,6 +78,7 @@ TabPage RID_SFXPAGE_SPELL }; CheckBox BTN_UPLOW { + HelpID = "cui:CheckBox:RID_SFXPAGE_SPELL:BTN_UPLOW"; Pos = MAP_APPFONT ( 12 , 108 ) ; Size = MAP_APPFONT ( 103 , 10 ) ; Text [ en-US ] = "~Case sensitive " ; diff --git a/cui/source/options/optupdt.cxx b/cui/source/options/optupdt.cxx index 696d5863e005..adcca4524532 100644 --- a/cui/source/options/optupdt.cxx +++ b/cui/source/options/optupdt.cxx @@ -185,48 +185,48 @@ SvxOnlineUpdateTabPage::Create( Window* pParent, const SfxItemSet& rAttrSet ) // ----------------------------------------------------------------------- -BOOL SvxOnlineUpdateTabPage::FillItemSet( SfxItemSet& ) +sal_Bool SvxOnlineUpdateTabPage::FillItemSet( SfxItemSet& ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; sal_Bool bValue; sal_Int64 nValue; if( m_aAutoCheckCheckBox.GetSavedValue() != m_aAutoCheckCheckBox.IsChecked() ) { - bValue = (TRUE == m_aAutoCheckCheckBox.IsChecked()); + bValue = (sal_True == m_aAutoCheckCheckBox.IsChecked()); m_xUpdateAccess->replaceByName( UNISTRING("AutoCheckEnabled"), uno::makeAny( bValue ) ); - bModified = TRUE; + bModified = sal_True; } nValue = 0; - if( TRUE == m_aEveryDayButton.IsChecked() ) + if( sal_True == m_aEveryDayButton.IsChecked() ) { - if( FALSE == m_aEveryDayButton.GetSavedValue() ) + if( sal_False == m_aEveryDayButton.GetSavedValue() ) nValue = 86400; } - else if( TRUE == m_aEveryWeekButton.IsChecked() ) + else if( sal_True == m_aEveryWeekButton.IsChecked() ) { - if( FALSE == m_aEveryWeekButton.GetSavedValue() ) + if( sal_False == m_aEveryWeekButton.GetSavedValue() ) nValue = 604800; } - else if( TRUE == m_aEveryMonthButton.IsChecked() ) + else if( sal_True == m_aEveryMonthButton.IsChecked() ) { - if( FALSE == m_aEveryMonthButton.GetSavedValue() ) + if( sal_False == m_aEveryMonthButton.GetSavedValue() ) nValue = 2592000; } if( nValue > 0 ) { m_xUpdateAccess->replaceByName( UNISTRING("CheckInterval"), uno::makeAny( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( m_aAutoDownloadCheckBox.GetSavedValue() != m_aAutoDownloadCheckBox.IsChecked() ) { - bValue = (TRUE == m_aAutoDownloadCheckBox.IsChecked()); + bValue = (sal_True == m_aAutoDownloadCheckBox.IsChecked()); m_xUpdateAccess->replaceByName( UNISTRING("AutoDownloadEnabled"), uno::makeAny( bValue ) ); - bModified = TRUE; + bModified = sal_True; } rtl::OUString sValue, aURL; @@ -236,7 +236,7 @@ BOOL SvxOnlineUpdateTabPage::FillItemSet( SfxItemSet& ) ( ! aURL.equals( sValue ) ) ) { m_xUpdateAccess->replaceByName( UNISTRING("DownloadDestination"), uno::makeAny( aURL ) ); - bModified = TRUE; + bModified = sal_True; } uno::Reference< util::XChangesBatch > xChangesBatch(m_xUpdateAccess, uno::UNO_QUERY); @@ -275,9 +275,9 @@ void SvxOnlineUpdateTabPage::Reset( const SfxItemSet& ) m_xUpdateAccess->getByName( UNISTRING("AutoDownloadEnabled") ) >>= bValue; m_aAutoDownloadCheckBox.Check(bValue); - m_aDestPathLabel.Enable(TRUE); - m_aDestPath.Enable(TRUE); - m_aChangePathButton.Enable(TRUE); + m_aDestPathLabel.Enable(sal_True); + m_aDestPath.Enable(sal_True); + m_aChangePathButton.Enable(sal_True); rtl::OUString sValue, aPath; m_xUpdateAccess->getByName( UNISTRING("DownloadDestination") ) >>= sValue; @@ -298,7 +298,7 @@ void SvxOnlineUpdateTabPage::FillUserData() IMPL_LINK( SvxOnlineUpdateTabPage, AutoCheckHdl_Impl, CheckBox *, pBox ) { - BOOL bEnabled = pBox->IsChecked(); + sal_Bool bEnabled = pBox->IsChecked(); m_aEveryDayButton.Enable(bEnabled); m_aEveryWeekButton.Enable(bEnabled); diff --git a/cui/source/options/optupdt.hxx b/cui/source/options/optupdt.hxx index 516b83e08b4c..c9846d5931b7 100644 --- a/cui/source/options/optupdt.hxx +++ b/cui/source/options/optupdt.hxx @@ -70,7 +70,7 @@ public: static SfxTabPage* Create( Window* pParent, const SfxItemSet& rSet ); - virtual BOOL FillItemSet( SfxItemSet& rSet ); + virtual sal_Bool FillItemSet( SfxItemSet& rSet ); virtual void Reset( const SfxItemSet& rSet ); virtual void FillUserData(); }; diff --git a/cui/source/options/optupdt.src b/cui/source/options/optupdt.src index 094e23c2e60a..6b271b91c71c 100644 --- a/cui/source/options/optupdt.src +++ b/cui/source/options/optupdt.src @@ -47,24 +47,28 @@ TabPage RID_SVXPAGE_ONLINEUPDATE }; CheckBox CB_AUTOCHECK { + HelpID = "cui:CheckBox:RID_SVXPAGE_ONLINEUPDATE:CB_AUTOCHECK"; Pos = MAP_APPFONT ( 12, 14 ) ; Size = MAP_APPFONT ( 210, 10 ) ; Text [ en-US ] = "~Check for updates automatically" ; }; RadioButton RB_EVERYDAY { + HelpID = "cui:RadioButton:RID_SVXPAGE_ONLINEUPDATE:RB_EVERYDAY"; Pos = MAP_APPFONT ( 18, 27 ) ; Size = MAP_APPFONT ( 160, 10 ) ; Text [ en-US ] = "Every Da~y" ; }; RadioButton RB_EVERYWEEK { + HelpID = "cui:RadioButton:RID_SVXPAGE_ONLINEUPDATE:RB_EVERYWEEK"; Pos = MAP_APPFONT ( 18, 40 ) ; Size = MAP_APPFONT ( 160, 10 ) ; Text [ en-US ] = "Every ~Week" ; }; RadioButton RB_EVERYMONTH { + HelpID = "cui:RadioButton:RID_SVXPAGE_ONLINEUPDATE:RB_EVERYMONTH"; Pos = MAP_APPFONT ( 18, 53 ) ; Size = MAP_APPFONT ( 160, 10 ) ; Text [ en-US ] = "Every ~Month" ; @@ -77,12 +81,14 @@ TabPage RID_SVXPAGE_ONLINEUPDATE }; PushButton PB_CHECKNOW { + HelpID = "cui:PushButton:RID_SVXPAGE_ONLINEUPDATE:PB_CHECKNOW"; Pos = MAP_APPFONT ( 12, 82 ) ; Size = MAP_APPFONT ( 50, 14 ) ; Text [ en-US ] = "Check ~now" ; }; CheckBox CB_AUTODOWNLOAD { + HelpID = "cui:CheckBox:RID_SVXPAGE_ONLINEUPDATE:CB_AUTODOWNLOAD"; Pos = MAP_APPFONT ( 12, 130 ) ; Size = MAP_APPFONT ( 160, 10 ) ; Text [ en-US ] = "~Download updates automatically" ; @@ -100,6 +106,7 @@ TabPage RID_SVXPAGE_ONLINEUPDATE }; PushButton PB_CHANGEPATH { + HelpID = "cui:PushButton:RID_SVXPAGE_ONLINEUPDATE:PB_CHANGEPATH"; Pos = MAP_APPFONT ( 162, 151 ) ; Size = MAP_APPFONT ( 50, 14 ) ; Text [ en-US ] = "Ch~ange..." ; diff --git a/cui/source/options/radiobtnbox.cxx b/cui/source/options/radiobtnbox.cxx index 67d8d2190496..06c0352864c0 100644 --- a/cui/source/options/radiobtnbox.cxx +++ b/cui/source/options/radiobtnbox.cxx @@ -51,7 +51,7 @@ void SvxRadioButtonListBox::SetTabs() { SvxSimpleTable::SetTabs(); /* - USHORT nAdjust = SV_LBOXTAB_ADJUST_RIGHT | SV_LBOXTAB_ADJUST_LEFT | + sal_uInt16 nAdjust = SV_LBOXTAB_ADJUST_RIGHT | SV_LBOXTAB_ADJUST_LEFT | SV_LBOXTAB_ADJUST_CENTER | SV_LBOXTAB_ADJUST_NUMERIC | SV_LBOXTAB_FORCE; if ( aTabs.Count() > 0 ) { @@ -86,7 +86,7 @@ void SvxRadioButtonListBox::KeyInput( const KeyEvent& rKEvt ) void SvxRadioButtonListBox::HandleEntryChecked( SvLBoxEntry* _pEntry ) { - Select( _pEntry, TRUE ); + Select( _pEntry, sal_True ); SvButtonState eState = GetCheckButtonState( _pEntry ); if ( SV_BUTTON_CHECKED == eState ) diff --git a/cui/source/options/sdbcdriverenum.cxx b/cui/source/options/sdbcdriverenum.cxx index 966bddd88acc..86e4ec494426 100644 --- a/cui/source/options/sdbcdriverenum.cxx +++ b/cui/source/options/sdbcdriverenum.cxx @@ -114,13 +114,6 @@ namespace offapp { return m_pImpl->getDriverImplNames().end(); } - - //-------------------------------------------------------------------- - sal_Int32 ODriverEnumeration::size() const throw() - { - return m_pImpl->getDriverImplNames().size(); - } - //........................................................................ } // namespace offapp //........................................................................ diff --git a/cui/source/options/sdbcdriverenum.hxx b/cui/source/options/sdbcdriverenum.hxx index 1b57ba0bef9c..d590c8217ed1 100644 --- a/cui/source/options/sdbcdriverenum.hxx +++ b/cui/source/options/sdbcdriverenum.hxx @@ -65,7 +65,6 @@ namespace offapp const_iterator begin() const throw(); const_iterator end() const throw(); - sal_Int32 size() const throw(); }; //........................................................................ diff --git a/cui/source/options/securityoptions.hxx b/cui/source/options/securityoptions.hxx index dd833da0cf8f..5c91d3f375c5 100644 --- a/cui/source/options/securityoptions.hxx +++ b/cui/source/options/securityoptions.hxx @@ -75,13 +75,13 @@ namespace svx SecurityOptionsDialog( Window* pParent, SvtSecurityOptions* pOptions ); ~SecurityOptionsDialog(); - inline bool IsSaveOrSendDocsChecked() const { return m_aSaveOrSendDocsCB.IsChecked() != FALSE; } - inline bool IsSignDocsChecked() const { return m_aSignDocsCB.IsChecked() != FALSE; } - inline bool IsPrintDocsChecked() const { return m_aPrintDocsCB.IsChecked() != FALSE; } - inline bool IsCreatePdfChecked() const { return m_aCreatePdfCB.IsChecked() != FALSE; } - inline bool IsRemovePersInfoChecked() const { return m_aRemovePersInfoCB.IsChecked() != FALSE; } - inline bool IsRecommPasswdChecked() const { return m_aRecommPasswdCB.IsChecked() != FALSE; } - inline bool IsCtrlHyperlinkChecked() const { return m_aCtrlHyperlinkCB.IsChecked() != FALSE; } + inline bool IsSaveOrSendDocsChecked() const { return m_aSaveOrSendDocsCB.IsChecked() != sal_False; } + inline bool IsSignDocsChecked() const { return m_aSignDocsCB.IsChecked() != sal_False; } + inline bool IsPrintDocsChecked() const { return m_aPrintDocsCB.IsChecked() != sal_False; } + inline bool IsCreatePdfChecked() const { return m_aCreatePdfCB.IsChecked() != sal_False; } + inline bool IsRemovePersInfoChecked() const { return m_aRemovePersInfoCB.IsChecked() != sal_False; } + inline bool IsRecommPasswdChecked() const { return m_aRecommPasswdCB.IsChecked() != sal_False; } + inline bool IsCtrlHyperlinkChecked() const { return m_aCtrlHyperlinkCB.IsChecked() != sal_False; } }; //........................................................................ diff --git a/cui/source/options/securityoptions.src b/cui/source/options/securityoptions.src index de7d7b23dc37..4e946bfbfd9a 100644 --- a/cui/source/options/securityoptions.src +++ b/cui/source/options/securityoptions.src @@ -61,6 +61,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_SAVESENDDOCS { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_SAVESENDDOCS"; Pos = MAP_APPFONT( COL_2, ROW_2 ); Size = MAP_APPFONT( CHECKBOX_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "When saving or sending"; @@ -72,6 +73,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_SIGNDOCS { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_SIGNDOCS"; Pos = MAP_APPFONT( COL_2 + CHECKBOX_WIDTH + RSC_SP_CTRL_X, ROW_2 ); Size = MAP_APPFONT( CHECKBOX_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "When signing"; @@ -83,6 +85,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_PRINTDOCS { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_PRINTDOCS"; Pos = MAP_APPFONT( COL_2, ROW_3 ); Size = MAP_APPFONT( CHECKBOX_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "When printing"; @@ -94,6 +97,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_CREATEPDF { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_CREATEPDF"; Pos = MAP_APPFONT( COL_2 + CHECKBOX_WIDTH + RSC_SP_CTRL_X, ROW_3 ); Size = MAP_APPFONT( CHECKBOX_WIDTH, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "When creating PDF files"; @@ -111,6 +115,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_REMOVEINFO { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_REMOVEINFO"; Pos = MAP_APPFONT( COL_1, ROW_5 ); Size = MAP_APPFONT( COL_3-COL_1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "Remove personal information on saving"; @@ -122,6 +127,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_RECOMMENDPWD { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_RECOMMENDPWD"; Pos = MAP_APPFONT( COL_1, ROW_6 ); Size = MAP_APPFONT( COL_3-COL_1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "Recommend password protection on saving"; @@ -133,6 +139,7 @@ ModalDialog RID_SVXDLG_SECURITY_OPTIONS }; CheckBox CB_CTRLHYPERLINK { + HelpID = "cui:CheckBox:RID_SVXDLG_SECURITY_OPTIONS:CB_CTRLHYPERLINK"; Pos = MAP_APPFONT( COL_1, ROW_7 ); Size = MAP_APPFONT( COL_3-COL_1, RSC_CD_CHECKBOX_HEIGHT ); Text [ en-US ] = "Ctrl-click required to follow hyperlinks"; diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx index 5af0beee0230..0953fe83b921 100644 --- a/cui/source/options/treeopt.cxx +++ b/cui/source/options/treeopt.cxx @@ -183,7 +183,7 @@ struct ModuleToGroupNameMap_Impl { const char* m_pModule; String m_sGroupName; - USHORT m_nNodeId; + sal_uInt16 m_nNodeId; }; static OfaPageResource* pPageRes = NULL; @@ -208,7 +208,7 @@ static ModuleToGroupNameMap_Impl ModuleMap[] = static void setGroupName( const rtl::OUString& rModule, const String& rGroupName ) { - USHORT nIndex = 0; + sal_uInt16 nIndex = 0; while ( ModuleMap[ nIndex ].m_pModule ) { rtl::OUString sTemp = @@ -225,7 +225,7 @@ static void setGroupName( const rtl::OUString& rModule, const String& rGroupName static String getGroupName( const rtl::OUString& rModule, bool bForced ) { String sGroupName; - USHORT nIndex = 0; + sal_uInt16 nIndex = 0; while ( ModuleMap[ nIndex ].m_pModule ) { rtl::OUString sTemp = @@ -263,14 +263,14 @@ static String getGroupName( const rtl::OUString& rModule, bool bForced ) static void deleteGroupNames() { - USHORT nIndex = 0; + sal_uInt16 nIndex = 0; while ( ModuleMap[ nIndex ].m_pModule ) ModuleMap[ nIndex++ ].m_sGroupName = String::EmptyString(); } -static USHORT getGroupNodeId( const rtl::OUString& rModule ) +static sal_uInt16 getGroupNodeId( const rtl::OUString& rModule ) { - USHORT nNodeId = 0xFFFF, nIndex = 0; + sal_uInt16 nNodeId = 0xFFFF, nIndex = 0; while ( ModuleMap[ nIndex ].m_pModule ) { rtl::OUString sTemp = @@ -375,7 +375,7 @@ struct OptionsMapping_Impl { const char* m_pGroupName; const char* m_pPageName; - USHORT m_nPageId; + sal_uInt16 m_nPageId; }; static OptionsMapping_Impl const OptionsMap_Impl[] = @@ -465,11 +465,11 @@ static OptionsMapping_Impl const OptionsMap_Impl[] = { NULL, NULL, 0 } }; -static sal_Bool lcl_getStringFromID( USHORT _nPageId, String& _rGroupName, String& _rPageName ) +static sal_Bool lcl_getStringFromID( sal_uInt16 _nPageId, String& _rGroupName, String& _rPageName ) { sal_Bool bRet = sal_False; - USHORT nIdx = 0; + sal_uInt16 nIdx = 0; while ( OptionsMap_Impl[nIdx].m_pGroupName != NULL ) { if ( _nPageId == OptionsMap_Impl[nIdx].m_nPageId ) @@ -486,7 +486,7 @@ static sal_Bool lcl_getStringFromID( USHORT _nPageId, String& _rGroupName, Strin return bRet; } -static sal_Bool lcl_isOptionHidden( USHORT _nPageId, const SvtOptionsDialogOptions& _rOptOptions ) +static sal_Bool lcl_isOptionHidden( sal_uInt16 _nPageId, const SvtOptionsDialogOptions& _rOptOptions ) { sal_Bool bIsHidden = sal_False; String sGroupName, sPageName; @@ -584,6 +584,8 @@ OfaTreeOptionsDialog::OfaTreeOptionsDialog( ResizeTreeLB(); if (bActivateLastSelection) ActivateLastSelection(); + + aTreeLB.SetAccessibleName(GetDisplayText()); } // Ctor() with ExtensionId ----------------------------------------------- @@ -834,28 +836,16 @@ void OfaTreeOptionsDialog::ApplyItemSets() void OfaTreeOptionsDialog::InitTreeAndHandler() { aTreeLB.SetNodeDefaultImages(); + aPageImages = ImageList( CUI_RES( RID_IMGLIST_TREEOPT ) ); - ResMgr* pIsoRes = ResMgr::CreateResMgr( "iso" ); - if ( !pIsoRes ) - { - // Fallback: Use ooo resource file - pIsoRes = ResMgr::CreateResMgr("ooo"); - } - - //! ResMgr* pIsoRes = SFX_APP()->GetLabelResManager(); - ResId aImgLstRes( RID_IMGLIST_TREEOPT, *pIsoRes ); - aImgLstRes.SetRT( RSC_IMAGELIST ); - if ( pIsoRes->IsAvailable( aImgLstRes ) ) - aPageImages = ImageList( ResId( RID_IMGLIST_TREEOPT, *pIsoRes ) ); - delete pIsoRes; aTreeLB.SetHelpId( HID_OFADLG_TREELISTBOX ); - aTreeLB.SetWindowBits( WB_HASBUTTONS | WB_HASBUTTONSATROOT | + aTreeLB.SetStyle( aTreeLB.GetStyle()|WB_HASBUTTONS | WB_HASBUTTONSATROOT | WB_HASLINES | WB_HASLINESATROOT | - WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE ); + WB_CLIPCHILDREN | WB_HSCROLL | WB_FORCE_MAKEVISIBLE | WB_QUICK_SEARCH ); aTreeLB.SetSpaceBetweenEntries( 0 ); aTreeLB.SetSelectionMode( SINGLE_SELECTION ); - aTreeLB.SetSublistOpenWithLeftRight( TRUE ); + aTreeLB.SetSublistOpenWithLeftRight( sal_True ); aTreeLB.SetExpandedHdl( LINK( this, OfaTreeOptionsDialog, ExpandedHdl_Impl ) ); aTreeLB.SetSelectHdl( LINK( this, OfaTreeOptionsDialog, ShowPageHdl_Impl ) ); aBackPB.SetClickHdl( LINK( this, OfaTreeOptionsDialog, BackHdl_Impl ) ); @@ -1405,7 +1395,7 @@ OfaPageResource::OfaPageResource() : FreeResource(); } -BOOL EnableSSO( void ) +sal_Bool EnableSSO( void ) { // SSO must be enabled if the configuration manager bootstrap settings // are configured as follows ... @@ -1434,7 +1424,7 @@ BOOL EnableSSO( void ) theBootstrap.getFrom( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CFG_BackendService") ), theBackendServiceTypeValue ); - BOOL bSSOEnabled = + sal_Bool bSSOEnabled = ( theOfflineValue == theDefaultOfflineValue && ( theServerTypeValue.getLength() == 0 || theServerTypeValue == rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("uno") ) ) && @@ -1443,7 +1433,7 @@ BOOL EnableSSO( void ) "com.sun.star.comp.configuration.backend.LdapSingleBackend") ) ); if ( bSSOEnabled && GetSSOCreator() == 0 ) { - bSSOEnabled = FALSE; + bSSOEnabled = sal_False; } return bSSOEnabled; } @@ -1500,10 +1490,10 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId ) if( SFX_ITEM_AVAILABLE <= pDispatch->QueryState( SID_ATTR_YEAR2000, pItem ) ) pRet->Put( SfxUInt16Item( SID_ATTR_YEAR2000, ((const SfxUInt16Item*)pItem)->GetValue() ) ); else - pRet->Put( SfxUInt16Item( SID_ATTR_YEAR2000, (USHORT)aMisc.GetYear2000() ) ); + pRet->Put( SfxUInt16Item( SID_ATTR_YEAR2000, (sal_uInt16)aMisc.GetYear2000() ) ); } else - pRet->Put( SfxUInt16Item( SID_ATTR_YEAR2000, (USHORT)aMisc.GetYear2000() ) ); + pRet->Put( SfxUInt16Item( SID_ATTR_YEAR2000, (sal_uInt16)aMisc.GetYear2000() ) ); // Sonstiges - Tabulator @@ -1635,7 +1625,7 @@ void OfaTreeOptionsDialog::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet // ------------------------------------------------------------------------- // Year2000 auswerten // ------------------------------------------------------------------------- - USHORT nY2K = USHRT_MAX; + sal_uInt16 nY2K = USHRT_MAX; if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_YEAR2000, sal_False, &pItem ) ) nY2K = ((const SfxUInt16Item*)pItem)->GetValue(); if( USHRT_MAX != nY2K ) @@ -1822,7 +1812,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame ) sal_uInt16 i, nPageId; // %PRODUCTNAME options - BOOL isSSOEnabled = EnableSSO(); + sal_Bool isSSOEnabled = EnableSSO(); if ( !lcl_isOptionHidden( SID_GENERAL_OPTIONS, aOptionsDlgOpt ) ) { ResStringArray& rGeneralArray = aDlgResource.GetGeneralArray(); @@ -2004,7 +1994,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame ) SfxModule* pScMod = ( *( SfxModule** ) GetAppData( SHL_CALC ) ); setGroupName( C2U("Calc"), rCalcArray.GetString(0) ); nGroup = AddGroup( rCalcArray.GetString( 0 ), pScMod, pScMod, SID_SC_EDITOPTIONS ); - const USHORT nCount = static_cast< const USHORT >( rCalcArray.Count() ); + const sal_uInt16 nCount = static_cast< const sal_uInt16 >( rCalcArray.Count() ); for ( i = 1; i < nCount; ++i ) { nPageId = (sal_uInt16)rCalcArray.GetValue(i); @@ -2031,7 +2021,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame ) setGroupName( C2U("Impress"), rImpressArray.GetString(0) ); nGroup = AddGroup( rImpressArray.GetString( 0 ), pSdMod, pSdMod, SID_SD_EDITOPTIONS ); const sal_Bool bCTL = aLanguageOptions.IsCTLFontEnabled(); - const USHORT nCount = static_cast< const USHORT >( rImpressArray.Count() ); + const sal_uInt16 nCount = static_cast< const sal_uInt16 >( rImpressArray.Count() ); for ( i = 1; i < nCount; ++i ) { nPageId = (sal_uInt16)rImpressArray.GetValue(i); @@ -2055,7 +2045,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame ) setGroupName( C2U("Draw"), rDrawArray.GetString(0) ); nGroup = AddGroup( rDrawArray.GetString( 0 ), pSdMod, pSdMod, SID_SD_GRAPHIC_OPTIONS ); const sal_Bool bCTL = aLanguageOptions.IsCTLFontEnabled(); - const USHORT nCount = static_cast< const USHORT >( rDrawArray.Count() ); + const sal_uInt16 nCount = static_cast< const sal_uInt16 >( rDrawArray.Count() ); for ( i = 1; i < nCount; ++i ) { nPageId = (sal_uInt16)rDrawArray.GetValue(i); @@ -2190,7 +2180,7 @@ void OfaTreeOptionsDialog::ResizeTreeLB( void ) const long nMax = aHiddenGB.GetSizePixel().Width() * 42 / 100; // don't ask where 42 comes from... but it looks / feels ok ;-) long nDelta = 50; // min. - USHORT nDepth = 0; + sal_uInt16 nDepth = 0; const long nIndent0 = PixelToLogic( Size( 28, 0 ) ).Width(); const long nIndent1 = PixelToLogic( Size( 52, 0 ) ).Width(); @@ -2535,10 +2525,10 @@ void OfaTreeOptionsDialog::LoadNodes( } } -USHORT lcl_getGroupId( const rtl::OUString& rGroupName, const SvTreeListBox& rTreeLB ) +sal_uInt16 lcl_getGroupId( const rtl::OUString& rGroupName, const SvTreeListBox& rTreeLB ) { String sGroupName( rGroupName ); - USHORT nRet = 0; + sal_uInt16 nRet = 0; SvLBoxEntry* pEntry = rTreeLB.First(); while( pEntry ) { @@ -2558,10 +2548,10 @@ USHORT lcl_getGroupId( const rtl::OUString& rGroupName, const SvTreeListBox& rTr void lcl_insertLeaf( OfaTreeOptionsDialog* pDlg, OptionsNode* pNode, OptionsLeaf* pLeaf, const SvTreeListBox& rTreeLB ) { - USHORT nGrpId = lcl_getGroupId( pNode->m_sLabel, rTreeLB ); + sal_uInt16 nGrpId = lcl_getGroupId( pNode->m_sLabel, rTreeLB ); if ( USHRT_MAX == nGrpId ) { - USHORT nNodeGrpId = getGroupNodeId( pNode->m_sId ); + sal_uInt16 nNodeGrpId = getGroupNodeId( pNode->m_sId ); nGrpId = pDlg->AddGroup( pNode->m_sLabel, NULL, NULL, nNodeGrpId ); if ( pNode->m_sPageURL.getLength() > 0 ) { @@ -2650,22 +2640,6 @@ short OfaTreeOptionsDialog::Execute() // class ExtensionsTabPage ----------------------------------------------- ExtensionsTabPage::ExtensionsTabPage( - Window* pParent, const ResId& rResId, const rtl::OUString& rPageURL, - const rtl::OUString& rEvtHdl, const Reference< awt::XContainerWindowProvider >& rProvider ) : - - TabPage( pParent, rResId ), - - m_sPageURL ( rPageURL ), - m_sEventHdl ( rEvtHdl ), - m_xWinProvider ( rProvider ), - m_bIsWindowHidden ( false ) - -{ -} - -// ----------------------------------------------------------------------- - -ExtensionsTabPage::ExtensionsTabPage( Window* pParent, WinBits nStyle, const rtl::OUString& rPageURL, const rtl::OUString& rEvtHdl, const Reference< awt::XContainerWindowProvider >& rProvider ) : @@ -2804,15 +2778,4 @@ void ExtensionsTabPage::SavePage() DispatchAction( C2U("ok") ); } -// ----------------------------------------------------------------------- - -void ExtensionsTabPage::HideWindow() -{ - if ( !m_bIsWindowHidden && m_xPage.is() ) - { - m_xPage->setVisible( sal_False ); - m_bIsWindowHidden = true; - } -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
\ No newline at end of file diff --git a/cui/source/options/treeopt.src b/cui/source/options/treeopt.src index cb9c3767baa4..a2be7386d1e9 100644 --- a/cui/source/options/treeopt.src +++ b/cui/source/options/treeopt.src @@ -63,6 +63,7 @@ ModalDialog RID_OFADLG_OPTIONS_TREE }; PushButton PB_BACK { + HelpID = "cui:PushButton:RID_OFADLG_OPTIONS_TREE:PB_BACK"; Pos = MAP_APPFONT ( COL_10, ROW_3 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; TabStop = TRUE ; @@ -307,47 +308,37 @@ String RID_RIDER_SLL_PERSONAL Text [ en-US ] = "Personal certificates" ; }; -// ******************************************************************* EOF - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +#define MASK_COL MaskColor = Color { Red = 0xFF00; Green = 0x0000; Blue = 0xFF00; } ; +#define IMGLST_IDLST \ + IdList = { \ + SID_GENERAL_OPTIONS; \ + SID_LANGUAGE_OPTIONS; \ + SID_INET_DLG; \ + SID_SW_EDITOPTIONS; \ + SID_SW_ONLINEOPTIONS; \ + SID_SC_EDITOPTIONS; \ + SID_SD_EDITOPTIONS; \ + SID_SD_GRAPHIC_OPTIONS; \ + SID_SM_EDITOPTIONS; \ + SID_SCH_EDITOPTIONS; \ + SID_SB_STARBASEOPTIONS; \ + SID_FILTER_DLG; \ + }; \ + IdCount = { \ + 12; \ + }; +ImageList RID_IMGLIST_TREEOPT +{ + Prefix = "tr"; + MASK_COL + IMGLST_IDLST +}; +ImageList RID_IMGLIST_TREEOPT_HC +{ + Prefix = "trh"; + MASK_COL + IMGLST_IDLST +}; diff --git a/cui/source/options/webconninfo.cxx b/cui/source/options/webconninfo.cxx index 296c1e5ecc06..dcd2afa7140b 100644 --- a/cui/source/options/webconninfo.cxx +++ b/cui/source/options/webconninfo.cxx @@ -51,10 +51,10 @@ namespace svx PasswordTable::PasswordTable( Window* pParent, const ResId& rResId ) : SvxSimpleTable( pParent, rResId ) { - SetWindowBits( GetStyle() | WB_NOINITIALSELECTION ); + SetStyle( GetStyle() | WB_NOINITIALSELECTION ); } -void PasswordTable::InsertHeaderItem( USHORT nColumn, const String& rText, HeaderBarItemBits nBits ) +void PasswordTable::InsertHeaderItem( sal_uInt16 nColumn, const String& rText, HeaderBarItemBits nBits ) { GetTheHeaderBar()->InsertItem( nColumn, rText, 0, nBits ); } @@ -66,11 +66,11 @@ void PasswordTable::ResetTabs() void PasswordTable::Resort( bool bForced ) { - USHORT nColumn = GetSelectedCol(); + sal_uInt16 nColumn = GetSelectedCol(); if ( 0 == nColumn || bForced ) // only the first column is sorted { HeaderBarItemBits nBits = GetTheHeaderBar()->GetItemBits(1); - BOOL bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); + sal_Bool bUp = ( ( nBits & HIB_UPARROW ) == HIB_UPARROW ); SvSortMode eMode = SortAscending; if ( bUp ) @@ -160,8 +160,8 @@ WebConnectionInfoDialog::WebConnectionInfoDialog( Window* pParent ) : m_aChangeBtn.SetClickHdl( LINK( this, WebConnectionInfoDialog, ChangePasswordHdl ) ); m_aPasswordsLB.SetSelectHdl( LINK( this, WebConnectionInfoDialog, EntrySelectedHdl ) ); - m_aRemoveBtn.Enable( FALSE ); - m_aChangeBtn.Enable( FALSE ); + m_aRemoveBtn.Enable( sal_False ); + m_aChangeBtn.Enable( sal_False ); HeaderBarClickedHdl( NULL ); } @@ -310,10 +310,8 @@ IMPL_LINK( WebConnectionInfoDialog, ChangePasswordHdl, PushButton*, EMPTYARG ) ::rtl::OUString aURL = m_aPasswordsLB.GetEntryText( pEntry, 0 ); ::rtl::OUString aUserName = m_aPasswordsLB.GetEntryText( pEntry, 1 ); - ::comphelper::DocPasswordRequest* pPasswordRequest - = new ::comphelper::DocPasswordRequest( - ::comphelper::DocPasswordRequestType_STANDARD, - task::PasswordRequestMode_PASSWORD_CREATE, aURL ); + ::comphelper::SimplePasswordRequest* pPasswordRequest + = new ::comphelper::SimplePasswordRequest( task::PasswordRequestMode_PASSWORD_CREATE ); uno::Reference< task::XInteractionRequest > rRequest( pPasswordRequest ); uno::Reference< task::XInteractionHandler > xInteractionHandler( @@ -351,12 +349,12 @@ IMPL_LINK( WebConnectionInfoDialog, EntrySelectedHdl, void*, EMPTYARG ) SvLBoxEntry* pEntry = m_aPasswordsLB.GetCurEntry(); if ( !pEntry ) { - m_aRemoveBtn.Enable( FALSE ); - m_aChangeBtn.Enable( FALSE ); + m_aRemoveBtn.Enable( sal_False ); + m_aChangeBtn.Enable( sal_False ); } else { - m_aRemoveBtn.Enable( TRUE ); + m_aRemoveBtn.Enable( sal_True ); // url container entries (-> use system credentials) have // no password diff --git a/cui/source/options/webconninfo.hxx b/cui/source/options/webconninfo.hxx index bf2b0003922d..b5ad4a3777ba 100644 --- a/cui/source/options/webconninfo.hxx +++ b/cui/source/options/webconninfo.hxx @@ -44,7 +44,7 @@ namespace svx public: PasswordTable( Window* pParent, const ResId& rResId ); - void InsertHeaderItem( USHORT nColumn, const String& rText, HeaderBarItemBits nBits ); + void InsertHeaderItem( sal_uInt16 nColumn, const String& rText, HeaderBarItemBits nBits ); void ResetTabs(); void Resort( bool bForced ); }; diff --git a/cui/source/options/webconninfo.src b/cui/source/options/webconninfo.src index 68560c1ecaa7..86c3a52509f6 100644 --- a/cui/source/options/webconninfo.src +++ b/cui/source/options/webconninfo.src @@ -56,18 +56,21 @@ ModalDialog RID_SVXDLG_WEBCONNECTION_INFO }; PushButton PB_REMOVE { + HelpID = "cui:PushButton:RID_SVXDLG_WEBCONNECTION_INFO:PB_REMOVE"; Pos = MAP_APPFONT ( COL_0 , ROW_3 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "Remove"; }; PushButton PB_REMOVEALL { + HelpID = "cui:PushButton:RID_SVXDLG_WEBCONNECTION_INFO:PB_REMOVEALL"; Pos = MAP_APPFONT ( COL_1 , ROW_3 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "Remove All"; }; PushButton PB_CHANGE { + HelpID = "cui:PushButton:RID_SVXDLG_WEBCONNECTION_INFO:PB_CHANGE"; Pos = MAP_APPFONT ( COL_C , ROW_3 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Text [ en-US ] = "Change Password..."; diff --git a/cui/source/tabpages/align.cxx b/cui/source/tabpages/align.cxx index 1dd8ad177119..be1deaafa3f6 100644 --- a/cui/source/tabpages/align.cxx +++ b/cui/source/tabpages/align.cxx @@ -58,7 +58,7 @@ namespace svx { // horizontal alignment ------------------------------------------------------- -typedef sfx::ValueItemWrapper< SvxHorJustifyItem, SvxCellHorJustify, USHORT > HorJustItemWrapper; +typedef sfx::ValueItemWrapper< SvxHorJustifyItem, SvxCellHorJustify, sal_uInt16 > HorJustItemWrapper; typedef sfx::ListBoxConnection< HorJustItemWrapper > HorJustConnection; static const HorJustConnection::MapEntryType s_pHorJustMap[] = @@ -75,7 +75,7 @@ static const HorJustConnection::MapEntryType s_pHorJustMap[] = // vertical alignment --------------------------------------------------------- -typedef sfx::ValueItemWrapper< SvxVerJustifyItem, SvxCellVerJustify, USHORT > VerJustItemWrapper; +typedef sfx::ValueItemWrapper< SvxVerJustifyItem, SvxCellVerJustify, sal_uInt16 > VerJustItemWrapper; typedef sfx::ListBoxConnection< VerJustItemWrapper > VerJustConnection; static const VerJustConnection::MapEntryType s_pVerJustMap[] = @@ -91,7 +91,7 @@ static const VerJustConnection::MapEntryType s_pVerJustMap[] = // cell rotate mode ----------------------------------------------------------- -typedef sfx::ValueItemWrapper< SvxRotateModeItem, SvxRotateMode, USHORT > RotateModeItemWrapper; +typedef sfx::ValueItemWrapper< SvxRotateModeItem, SvxRotateMode, sal_uInt16 > RotateModeItemWrapper; typedef sfx::ValueSetConnection< RotateModeItemWrapper > RotateModeConnection; static const RotateModeConnection::MapEntryType s_pRotateModeMap[] = @@ -104,7 +104,7 @@ static const RotateModeConnection::MapEntryType s_pRotateModeMap[] = // ============================================================================ -static USHORT s_pRanges[] = +static sal_uInt16 s_pRanges[] = { SID_ATTR_ALIGN_HOR_JUSTIFY,SID_ATTR_ALIGN_VER_JUSTIFY, SID_ATTR_ALIGN_STACKED,SID_ATTR_ALIGN_LINEBREAK, @@ -241,6 +241,10 @@ AlignmentTabPage::AlignmentTabPage( Window* pParent, const SfxItemSet& rCoreAttr AddItemConnection( new sfx::CheckBoxConnection( SID_ATTR_ALIGN_SHRINKTOFIT, maBtnShrink, sfx::ITEMCONN_HIDE_UNKNOWN ) ); AddItemConnection( new sfx::DummyItemConnection( SID_ATTR_FRAMEDIRECTION, maFtFrameDir, sfx::ITEMCONN_HIDE_UNKNOWN ) ); AddItemConnection( new FrameDirListBoxConnection( SID_ATTR_FRAMEDIRECTION, maLbFrameDir, sfx::ITEMCONN_HIDE_UNKNOWN ) ); + + maLbHorAlign.SetAccessibleRelationMemberOf( &maFlAlignment ); + maEdIndent.SetAccessibleRelationMemberOf( &maFlAlignment ); + maLbVerAlign.SetAccessibleRelationMemberOf( &maFlAlignment ); } AlignmentTabPage::~AlignmentTabPage() @@ -252,7 +256,7 @@ SfxTabPage* AlignmentTabPage::Create( Window* pParent, const SfxItemSet& rAttrSe return new AlignmentTabPage( pParent, rAttrSet ); } -USHORT* AlignmentTabPage::GetRanges() +sal_uInt16* AlignmentTabPage::GetRanges() { return s_pRanges; } @@ -317,7 +321,7 @@ void AlignmentTabPage::DataChanged( const DataChangedEvent& rDCEvt ) void AlignmentTabPage::InitVsRefEgde() { // remember selection - is deleted in call to ValueSet::Clear() - USHORT nSel = maVsRefEdge.GetSelectItemId(); + sal_uInt16 nSel = maVsRefEdge.GetSelectItemId(); ResId aResId( IL_LOCK_BMPS, CUI_MGR() ); ImageList aImageList( aResId ); @@ -338,7 +342,7 @@ void AlignmentTabPage::InitVsRefEgde() void AlignmentTabPage::UpdateEnableControls() { - USHORT nHorAlign = maLbHorAlign.GetSelectEntryPos(); + sal_uInt16 nHorAlign = maLbHorAlign.GetSelectEntryPos(); bool bHorLeft = (nHorAlign == ALIGNDLG_HORALIGN_LEFT); bool bHorBlock = (nHorAlign == ALIGNDLG_HORALIGN_BLOCK); bool bHorFill = (nHorAlign == ALIGNDLG_HORALIGN_FILL); diff --git a/cui/source/tabpages/align.src b/cui/source/tabpages/align.src index d0e8f16b591e..05d4b39d6767 100644 --- a/cui/source/tabpages/align.src +++ b/cui/source/tabpages/align.src @@ -57,6 +57,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; ListBox LB_HORALIGN { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGNMENT:LB_HORALIGN"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 25 ); Size = MAP_APPFONT ( 100 , 60 ); @@ -81,6 +82,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; MetricField ED_INDENT { + HelpID = "cui:MetricField:RID_SVXPAGE_ALIGNMENT:ED_INDENT"; Border = TRUE ; Pos = MAP_APPFONT ( 118 , 25 ) ; Size = MAP_APPFONT ( 36 , 12 ) ; @@ -99,6 +101,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; ListBox LB_VERALIGN { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGNMENT:LB_VERALIGN"; Border = TRUE; Pos = MAP_APPFONT ( 160 , 25 ); Size = MAP_APPFONT ( 88 , 60 ); @@ -122,6 +125,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; TriStateBox BTN_TXTSTACKED { + HelpID = "cui:TriStateBox:RID_SVXPAGE_ALIGNMENT:BTN_TXTSTACKED"; Pos = MAP_APPFONT ( 133 , 54 ) ; Size = MAP_APPFONT ( 115 , 10 ) ; TabStop = TRUE ; @@ -142,6 +146,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; NumericField NF_DEGREES { + HelpID = "cui:NumericField:RID_SVXPAGE_ALIGNMENT:NF_DEGREES"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 65 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -168,6 +173,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; TriStateBox BTN_ASIAN_VERTICAL { + HelpID = "cui:TriStateBox:RID_SVXPAGE_ALIGNMENT:BTN_ASIAN_VERTICAL"; Pos = MAP_APPFONT ( 143 , 68 ) ; Size = MAP_APPFONT ( 105 , 10 ) ; TabStop = TRUE ; @@ -181,18 +187,21 @@ TabPage RID_SVXPAGE_ALIGNMENT }; TriStateBox BTN_WRAP { + HelpID = "cui:TriStateBox:RID_SVXPAGE_ALIGNMENT:BTN_WRAP"; Pos = MAP_APPFONT ( 12 , 126 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "~Wrap text automatically" ; }; TriStateBox BTN_HYPH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_ALIGNMENT:BTN_HYPH"; Pos = MAP_APPFONT ( 22 , 139 ) ; Size = MAP_APPFONT ( 226 , 10 ) ; Text [ en-US ] = "Hyphenation ~active"; }; TriStateBox BTN_SHRINK { + HelpID = "cui:TriStateBox:RID_SVXPAGE_ALIGNMENT:BTN_SHRINK"; Pos = MAP_APPFONT( 12, 152 ); Size = MAP_APPFONT( 236, 10 ); Text [ en-US ] = "~Shrink to fit cell size"; @@ -205,6 +214,7 @@ TabPage RID_SVXPAGE_ALIGNMENT }; ListBox LB_FRAMEDIR { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGNMENT:LB_FRAMEDIR"; Pos = MAP_APPFONT( 78 , 168 ); Size = MAP_APPFONT( 170 , 50 ); Border = TRUE; diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx index fd68e1e1f557..4eb25d799bc1 100644 --- a/cui/source/tabpages/autocdlg.cxx +++ b/cui/source/tabpages/autocdlg.cxx @@ -84,18 +84,18 @@ OfaAutoCorrDlg::OfaAutoCorrDlg(Window* pParent, const SfxItemSet* _pSet ) : aLanguageFT( this, CUI_RES(FT_LANG )), aLanguageLB( this, CUI_RES(LB_LANG )) { - BOOL bShowSWOptions = FALSE; - BOOL bOpenSmartTagOptions = FALSE; + sal_Bool bShowSWOptions = sal_False; + sal_Bool bOpenSmartTagOptions = sal_False; if ( _pSet ) { - SFX_ITEMSET_ARG( _pSet, pItem, SfxBoolItem, SID_AUTO_CORRECT_DLG, FALSE ); + SFX_ITEMSET_ARG( _pSet, pItem, SfxBoolItem, SID_AUTO_CORRECT_DLG, sal_False ); if ( pItem && pItem->GetValue() ) - bShowSWOptions = TRUE; + bShowSWOptions = sal_True; - SFX_ITEMSET_ARG( _pSet, pItem2, SfxBoolItem, SID_OPEN_SMARTTAGOPTIONS, FALSE ); + SFX_ITEMSET_ARG( _pSet, pItem2, SfxBoolItem, SID_OPEN_SMARTTAGOPTIONS, sal_False ); if ( pItem2 && pItem2->GetValue() ) - bOpenSmartTagOptions = TRUE; + bOpenSmartTagOptions = sal_True; } aLanguageFT.SetZOrder(0, WINDOW_ZORDER_FIRST); @@ -136,9 +136,9 @@ OfaAutoCorrDlg::OfaAutoCorrDlg(Window* pParent, const SfxItemSet* _pSet ) : if( SvtLanguageOptions().IsCTLFontEnabled() ) nLangList |= LANG_LIST_CTL; - aLanguageLB.SetLanguageList( nLangList, TRUE, TRUE ); + aLanguageLB.SetLanguageList( nLangList, sal_True, sal_True ); aLanguageLB.SelectLanguage( LANGUAGE_NONE ); - USHORT nPos = aLanguageLB.GetSelectEntryPos(); + sal_uInt16 nPos = aLanguageLB.GetSelectEntryPos(); DBG_ASSERT( LISTBOX_ENTRY_NOTFOUND != nPos, "listbox entry missing" ); aLanguageLB.SetEntryData( nPos, (void*)(long) LANGUAGE_DONTKNOW ); @@ -163,34 +163,34 @@ OfaAutoCorrDlg::OfaAutoCorrDlg(Window* pParent, const SfxItemSet* _pSet ) : SetCurPageId( RID_OFAPAGE_SMARTTAG_OPTIONS ); } -BOOL lcl_FindEntry( ListBox& rLB, const String& rEntry, +sal_Bool lcl_FindEntry( ListBox& rLB, const String& rEntry, CollatorWrapper& rCmpClass ) { - USHORT nCount = rLB.GetEntryCount(); - USHORT nSelPos = rLB.GetSelectEntryPos(); - USHORT i; + sal_uInt16 nCount = rLB.GetEntryCount(); + sal_uInt16 nSelPos = rLB.GetSelectEntryPos(); + sal_uInt16 i; for(i = 0; i < nCount; i++) { if( 0 == rCmpClass.compareString(rEntry, rLB.GetEntry(i) )) { - rLB.SelectEntryPos(i, TRUE); - return TRUE; + rLB.SelectEntryPos(i, sal_True); + return sal_True; } } if(LISTBOX_ENTRY_NOTFOUND != nSelPos) - rLB.SelectEntryPos(nSelPos, FALSE); - return FALSE; + rLB.SelectEntryPos(nSelPos, sal_False); + return sal_False; } IMPL_LINK(OfaAutoCorrDlg, SelectLanguageHdl, ListBox*, pBox) { - USHORT nPos = pBox->GetSelectEntryPos(); + sal_uInt16 nPos = pBox->GetSelectEntryPos(); void* pVoid = pBox->GetEntryData(nPos); LanguageType eNewLang = (LanguageType)(long)pVoid; //alte Einstellungen speichern und neu fuellen if(eNewLang != eLastDialogLanguage) { - USHORT nPageId = GetCurPageId(); + sal_uInt16 nPageId = GetCurPageId(); if(RID_OFAPAGE_AUTOCORR_REPLACE == nPageId) ((OfaAutocorrReplacePage*)GetTabPage( nPageId ))->SetLanguage(eNewLang); else if(RID_OFAPAGE_AUTOCORR_EXCEPT == nPageId) @@ -228,12 +228,12 @@ SfxTabPage* OfaAutocorrOptionsPage::Create( Window* pParent, return new OfaAutocorrOptionsPage(pParent, rSet); } -BOOL OfaAutocorrOptionsPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaAutocorrOptionsPage::FillItemSet( SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); long nFlags = pAutoCorrect->GetFlags(); - USHORT nPos = 0; + sal_uInt16 nPos = 0; pAutoCorrect->SetAutoCorrFlag(Autocorrect, aCheckLB.IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(CptlSttWrd, aCheckLB.IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(CptlSttSntnc, aCheckLB.IsChecked(nPos++)); @@ -243,7 +243,7 @@ BOOL OfaAutocorrOptionsPage::FillItemSet( SfxItemSet& ) pAutoCorrect->SetAutoCorrFlag(IgnoreDoubleSpace, aCheckLB.IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(CorrectCapsLock, aCheckLB.IsChecked(nPos++)); - BOOL bReturn = nFlags != pAutoCorrect->GetFlags(); + sal_Bool bReturn = nFlags != pAutoCorrect->GetFlags(); if(bReturn ) { SvxAutoCorrCfg* pCfg = SvxAutoCorrCfg::Get(); @@ -255,7 +255,7 @@ BOOL OfaAutocorrOptionsPage::FillItemSet( SfxItemSet& ) void OfaAutocorrOptionsPage::ActivatePage( const SfxItemSet& ) { - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(FALSE); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(sal_False); } void OfaAutocorrOptionsPage::Reset( const SfxItemSet& ) @@ -263,7 +263,7 @@ void OfaAutocorrOptionsPage::Reset( const SfxItemSet& ) SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); const long nFlags = pAutoCorrect->GetFlags(); - aCheckLB.SetUpdateMode(FALSE); + aCheckLB.SetUpdateMode(sal_False); aCheckLB.Clear(); aCheckLB.InsertEntry(sInput); @@ -275,7 +275,7 @@ void OfaAutocorrOptionsPage::Reset( const SfxItemSet& ) aCheckLB.InsertEntry(sNoDblSpaces); aCheckLB.InsertEntry(sAccidentalCaps); - USHORT nPos = 0; + sal_uInt16 nPos = 0; aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & Autocorrect) ); aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & CptlSttWrd) ); aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & CptlSttSntnc) ); @@ -285,7 +285,7 @@ void OfaAutocorrOptionsPage::Reset( const SfxItemSet& ) aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & IgnoreDoubleSpace) ); aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & CorrectCapsLock) ); - aCheckLB.SetUpdateMode(TRUE); + aCheckLB.SetUpdateMode(sal_True); } /*********************************************************************/ @@ -341,10 +341,10 @@ class OfaImpBrwString : public SvLBoxString { public: - OfaImpBrwString( SvLBoxEntry* pEntry, USHORT nFlags, + OfaImpBrwString( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr ) : SvLBoxString(pEntry,nFlags,rStr){} - virtual void Paint( const Point& rPos, SvLBox& rDev, USHORT nFlags, + virtual void Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry); }; @@ -353,7 +353,7 @@ public: /*********************************************************************/ -void OfaImpBrwString::Paint( const Point& rPos, SvLBox& rDev, USHORT /*nFlags*/, +void OfaImpBrwString::Paint( const Point& rPos, SvLBox& rDev, sal_uInt16 /*nFlags*/, SvLBoxEntry* pEntry ) { rDev.DrawText( rPos, GetText() ); @@ -372,8 +372,8 @@ void OfaImpBrwString::Paint( const Point& rPos, SvLBox& rDev, USHORT /*nFlags*/, } aFont.SetWeight( WEIGHT_BOLD ); - BOOL bFett = TRUE; - USHORT nPos = 0; + sal_Bool bFett = sal_True; + sal_uInt16 nPos = 0; do { String sTxt( pUserData->pString->GetToken( 0, 1, nPos )); @@ -463,7 +463,7 @@ OfaSwAutoFmtOptionsPage::OfaSwAutoFmtOptionsPage( Window* pParent, SvtSysLocale aSysLcl; aCheckLB.SetHelpId(HID_OFAPAGE_AUTOFORMAT_CLB); - aCheckLB.SetWindowBits(WB_HSCROLL| WB_VSCROLL); + aCheckLB.SetStyle(aCheckLB.GetStyle()|WB_HSCROLL| WB_VSCROLL); aCheckLB.SetSelectHdl(LINK(this, OfaSwAutoFmtOptionsPage, SelectHdl)); aCheckLB.SetDoubleClickHdl(LINK(this, OfaSwAutoFmtOptionsPage, EditHdl)); @@ -488,7 +488,7 @@ OfaSwAutoFmtOptionsPage::OfaSwAutoFmtOptionsPage( Window* pParent, /* */ /*********************************************************************/ -SvLBoxEntry* OfaSwAutoFmtOptionsPage::CreateEntry(String& rTxt, USHORT nCol) +SvLBoxEntry* OfaSwAutoFmtOptionsPage::CreateEntry(String& rTxt, sal_uInt16 nCol) { SvLBoxEntry* pEntry = new SvLBoxEntry; @@ -542,14 +542,14 @@ SfxTabPage* OfaSwAutoFmtOptionsPage::Create( Window* pParent, /* */ /*********************************************************************/ -BOOL OfaSwAutoFmtOptionsPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaSwAutoFmtOptionsPage::FillItemSet( SfxItemSet& ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); long nFlags = pAutoCorrect->GetFlags(); - BOOL bCheck = aCheckLB.IsChecked(USE_REPLACE_TABLE, CBCOL_FIRST); + sal_Bool bCheck = aCheckLB.IsChecked(USE_REPLACE_TABLE, CBCOL_FIRST); bModified |= pOpt->bAutoCorrect != bCheck; pOpt->bAutoCorrect = bCheck; pAutoCorrect->SetAutoCorrFlag(Autocorrect, @@ -610,7 +610,7 @@ BOOL OfaSwAutoFmtOptionsPage::FillItemSet( SfxItemSet& ) bModified |= pOpt->bRightMargin != bCheck; pOpt->bRightMargin = bCheck; bModified |= nPercent != pOpt->nRightMargin; - pOpt->nRightMargin = (BYTE)nPercent; + pOpt->nRightMargin = (sal_uInt8)nPercent; bCheck = aCheckLB.IsChecked(APPLY_NUMBERING, CBCOL_SECOND); bModified |= pOpt->bSetNumRule != bCheck; @@ -655,12 +655,12 @@ BOOL OfaSwAutoFmtOptionsPage::FillItemSet( SfxItemSet& ) pCfg->Commit(); } - return TRUE; + return sal_True; } void OfaSwAutoFmtOptionsPage::ActivatePage( const SfxItemSet& ) { - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(FALSE); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(sal_False); } /*********************************************************************/ @@ -674,7 +674,7 @@ void OfaSwAutoFmtOptionsPage::Reset( const SfxItemSet& ) SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); const long nFlags = pAutoCorrect->GetFlags(); - aCheckLB.SetUpdateMode(FALSE); + aCheckLB.SetUpdateMode(sal_False); aCheckLB.Clear(); // Die folgenden Eintraege muessen in der selben Reihenfolge, wie im @@ -745,7 +745,7 @@ void OfaSwAutoFmtOptionsPage::Reset( const SfxItemSet& ) aCheckLB.CheckEntryPos( CREATE_TABLE, CBCOL_SECOND, pOpt->bCreateTable ); aCheckLB.CheckEntryPos( REPLACE_STYLES, CBCOL_SECOND, pOpt->bReplaceStyles ); - aCheckLB.SetUpdateMode(TRUE); + aCheckLB.SetUpdateMode(sal_True); } /*********************************************************************/ @@ -764,7 +764,7 @@ IMPL_LINK(OfaSwAutoFmtOptionsPage, SelectHdl, OfaACorrCheckListBox*, pBox) IMPL_LINK(OfaSwAutoFmtOptionsPage, EditHdl, PushButton*, EMPTYARG) { - ULONG nSelEntryPos = aCheckLB.GetSelectEntryPos(); + sal_uLong nSelEntryPos = aCheckLB.GetSelectEntryPos(); if( nSelEntryPos == REPLACE_BULLETS || nSelEntryPos == APPLY_NUMBERING) { @@ -790,7 +790,7 @@ IMPL_LINK(OfaSwAutoFmtOptionsPage, EditHdl, PushButton*, EMPTYARG) aDlg.GetPrcntFld().SetValue(nPercent); if(RET_OK == aDlg.Execute()) { - nPercent = (USHORT)aDlg.GetPrcntFld().GetValue(); + nPercent = (sal_uInt16)aDlg.GetPrcntFld().GetValue(); sMargin = ' '; sMargin += String::CreateFromInt32( nPercent ); sMargin += '%'; @@ -807,7 +807,7 @@ IMPL_LINK(OfaSwAutoFmtOptionsPage, EditHdl, PushButton*, EMPTYARG) void OfaACorrCheckListBox::SetTabs() { SvxSimpleTable::SetTabs(); - USHORT nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; + sal_uInt16 nAdjust = SV_LBOXTAB_ADJUST_RIGHT|SV_LBOXTAB_ADJUST_LEFT|SV_LBOXTAB_ADJUST_CENTER|SV_LBOXTAB_ADJUST_NUMERIC|SV_LBOXTAB_FORCE; if( aTabs.Count() > 1 ) { @@ -827,7 +827,7 @@ void OfaACorrCheckListBox::SetTabs() /* */ /*********************************************************************/ -void OfaACorrCheckListBox::CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked) +void OfaACorrCheckListBox::CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, sal_Bool bChecked) { if ( nPos < GetEntryCount() ) SetCheckButtonState( @@ -841,7 +841,7 @@ void OfaACorrCheckListBox::CheckEntryPos(ULONG nPos, USHORT nCol, BOOL bChecked) /* */ /*********************************************************************/ -BOOL OfaACorrCheckListBox::IsChecked(ULONG nPos, USHORT nCol) +sal_Bool OfaACorrCheckListBox::IsChecked(sal_uLong nPos, sal_uInt16 nCol) { return GetCheckButtonState( GetEntry(nPos), nCol ) == SV_BUTTON_CHECKED; } @@ -850,7 +850,7 @@ BOOL OfaACorrCheckListBox::IsChecked(ULONG nPos, USHORT nCol) /* */ /*********************************************************************/ -void OfaACorrCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, USHORT nCol, SvButtonState eState) +void OfaACorrCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, sal_uInt16 nCol, SvButtonState eState) { SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -879,7 +879,7 @@ void OfaACorrCheckListBox::SetCheckButtonState( SvLBoxEntry* pEntry, USHORT nCol /* */ /*********************************************************************/ -SvButtonState OfaACorrCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry, USHORT nCol ) const +SvButtonState OfaACorrCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry, sal_uInt16 nCol ) const { SvButtonState eState = SV_BUTTON_UNCHECKED; SvLBoxButton* pItem = (SvLBoxButton*)(pEntry->GetItem(nCol + 1)); @@ -887,7 +887,7 @@ SvButtonState OfaACorrCheckListBox::GetCheckButtonState( SvLBoxEntry* pEntry, US if (((SvLBoxItem*)pItem)->IsA() == SV_ITEM_ID_LBOXBUTTON) { - USHORT nButtonFlags = pItem->GetButtonFlags(); + sal_uInt16 nButtonFlags = pItem->GetButtonFlags(); eState = pCheckButtonData->ConvertToButtonState( nButtonFlags ); } @@ -904,8 +904,8 @@ void OfaACorrCheckListBox::KeyInput( const KeyEvent& rKEvt ) if(!rKEvt.GetKeyCode().GetModifier() && KEY_SPACE == rKEvt.GetKeyCode().GetCode()) { - ULONG nSelPos = GetSelectEntryPos(); - USHORT nCol = GetCurrentTabPos() - 1; + sal_uLong nSelPos = GetSelectEntryPos(); + sal_uInt16 nCol = GetCurrentTabPos() - 1; if ( nCol < 2 ) { CheckEntryPos( nSelPos, nCol, !IsChecked( nSelPos, nCol ) ); @@ -913,7 +913,7 @@ void OfaACorrCheckListBox::KeyInput( const KeyEvent& rKEvt ) } else { - USHORT nCheck = IsChecked(nSelPos, 1) ? 1 : 0; + sal_uInt16 nCheck = IsChecked(nSelPos, 1) ? 1 : 0; if(IsChecked(nSelPos, 0)) nCheck += 2; nCheck--; @@ -963,10 +963,10 @@ OfaAutocorrReplacePage::OfaAutocorrReplacePage( Window* pParent, sNew(aNewReplacePB.GetText()), pFormatText(0), eLang(eLastDialogLanguage), - bHasSelectionText(FALSE), - bFirstSelect(TRUE), - bReplaceEditChanged(FALSE), - bSWriter(TRUE) + bHasSelectionText(sal_False), + bFirstSelect(sal_True), + bReplaceEditChanged(sal_False), + bSWriter(sal_True) { FreeResource(); SfxModule *pMod = *(SfxModule**)GetAppData(SHL_WRITER); @@ -980,7 +980,7 @@ OfaAutocorrReplacePage::OfaAutocorrReplacePage( Window* pParent, static long nTabs[] = { 2 /* Tab-Count */, 1, 61 }; aReplaceTLB.SetTabs( &nTabs[0], MAP_APPFONT ); - aReplaceTLB.SetWindowBits(WB_HSCROLL|WB_CLIPCHILDREN); + aReplaceTLB.SetStyle(aReplaceTLB.GetStyle()|WB_HSCROLL|WB_CLIPCHILDREN); aReplaceTLB.SetSelectHdl(LINK(this, OfaAutocorrReplacePage, SelectHdl)); aNewReplacePB.SetClickHdl( LINK(this, OfaAutocorrReplacePage, NewDelHdl)); aDeleteReplacePB.SetClickHdl(LINK(this, OfaAutocorrReplacePage, NewDelHdl)); @@ -989,8 +989,8 @@ OfaAutocorrReplacePage::OfaAutocorrReplacePage( Window* pParent, aShortED.SetActionHdl(LINK(this, OfaAutocorrReplacePage, NewDelHdl)); aReplaceED.SetActionHdl(LINK(this, OfaAutocorrReplacePage, NewDelHdl)); - aReplaceED.SetSpaces(TRUE); - aShortED.SetSpaces(TRUE); + aReplaceED.SetSpaces(sal_True); + aShortED.SetSpaces(sal_True); aShortED.SetMaxTextLen(30); } @@ -1012,7 +1012,7 @@ void OfaAutocorrReplacePage::ActivatePage( const SfxItemSet& ) { if(eLang != eLastDialogLanguage) SetLanguage(eLastDialogLanguage); - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(TRUE); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(sal_True); } int OfaAutocorrReplacePage::DeactivatePage( SfxItemSet* ) @@ -1020,7 +1020,7 @@ int OfaAutocorrReplacePage::DeactivatePage( SfxItemSet* ) return LEAVE_PAGE; } -BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) +sal_Bool OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); DoubleStringArrayPtr pDoubleStringArray = aDoubleStringTable.Last(); @@ -1030,19 +1030,19 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) if(eCurLang != eLang) // die aktuelle Sprache wird weiter hinten behandelt { SvxAutocorrWordList* pWordList = pAutoCorrect->LoadAutocorrWordList(eCurLang); - USHORT nWordListCount = pWordList->Count(); - USHORT nDoubleStringArrayCount = pDoubleStringArray->Count(); - USHORT nPos = nDoubleStringArrayCount; - USHORT nLastPos = nPos; + sal_uInt16 nWordListCount = pWordList->Count(); + sal_uInt16 nDoubleStringArrayCount = pDoubleStringArray->Count(); + sal_uInt16 nPos = nDoubleStringArrayCount; + sal_uInt16 nLastPos = nPos; // 1. Durchlauf: Eintraege loeschen oder veraendern: - for( USHORT nWordListPos = nWordListCount; nWordListPos; nWordListPos-- ) + for( sal_uInt16 nWordListPos = nWordListCount; nWordListPos; nWordListPos-- ) { SvxAutocorrWordPtr pWordPtr = pWordList->GetObject(nWordListPos - 1); String sEntry(pWordPtr->GetShort()); // formatierter Text steht nur im Writer - BOOL bFound = !bSWriter && !pWordPtr->IsTextOnly(); + sal_Bool bFound = !bSWriter && !pWordPtr->IsTextOnly(); while(!bFound && nPos) { DoubleString* pDouble = pDoubleStringArray->GetObject( nPos - 1); @@ -1051,7 +1051,7 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) sEntry, pDouble->sShort )) { nLastPos = nPos - 1; - bFound = TRUE; + bFound = sal_True; if( !(pWordPtr->IsTextOnly() == (0 == pDouble->pUserData) && 0 == pCompareClass->compareString( pWordPtr->GetLong(), pDouble->sLong ) ) ) @@ -1070,7 +1070,7 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) } } nDoubleStringArrayCount = pDoubleStringArray->Count(); - for(USHORT nDoubleStringArrayPos = 0; nDoubleStringArrayPos < nDoubleStringArrayCount; nDoubleStringArrayPos++ ) + for(sal_uInt16 nDoubleStringArrayPos = 0; nDoubleStringArrayPos < nDoubleStringArrayCount; nDoubleStringArrayPos++ ) { //jetzt sollte es nur noch neue Eintraege geben DoubleString* pDouble = pDoubleStringArray->GetObject( nDoubleStringArrayPos ); @@ -1091,21 +1091,21 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) aDoubleStringTable.Clear(); // jetzt noch die aktuelle Selektion SvxAutocorrWordList* pWordList = pAutoCorrect->LoadAutocorrWordList(eLang); - USHORT nWordListCount = pWordList->Count(); - USHORT nListBoxCount = (USHORT)aReplaceTLB.GetEntryCount(); + sal_uInt16 nWordListCount = pWordList->Count(); + sal_uInt16 nListBoxCount = (sal_uInt16)aReplaceTLB.GetEntryCount(); - aReplaceTLB.SetUpdateMode(FALSE); - USHORT nListBoxPos = nListBoxCount; - USHORT nLastListBoxPos = nListBoxPos; + aReplaceTLB.SetUpdateMode(sal_False); + sal_uInt16 nListBoxPos = nListBoxCount; + sal_uInt16 nLastListBoxPos = nListBoxPos; // 1. Durchlauf: Eintraege loeschen oder veraendern: - USHORT i; + sal_uInt16 i; for( i = nWordListCount; i; i-- ) { SvxAutocorrWordPtr pWordPtr = pWordList->GetObject(i- 1); String sEntry(pWordPtr->GetShort()); // formatierter Text steht nur im Writer - BOOL bFound = !bSWriter && !pWordPtr->IsTextOnly(); + sal_Bool bFound = !bSWriter && !pWordPtr->IsTextOnly(); while(!bFound && nListBoxPos) { SvLBoxEntry* pEntry = aReplaceTLB.GetEntry( nListBoxPos - 1); @@ -1113,7 +1113,7 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) aReplaceTLB.GetEntryText(pEntry, 0))) { nLastListBoxPos = nListBoxPos - 1; - bFound = TRUE; + bFound = sal_True; String sLong = aReplaceTLB.GetEntryText(pEntry, 1); if( !(pWordPtr->IsTextOnly() == (0 == pEntry->GetUserData()) && 0 == pCompareClass->compareString( @@ -1134,7 +1134,7 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) } } - nListBoxCount = (USHORT)aReplaceTLB.GetEntryCount(); + nListBoxCount = (sal_uInt16)aReplaceTLB.GetEntryCount(); for(i = 0; i < nListBoxCount; i++ ) { //jetzt sollte es nur noch neue Eintraege geben @@ -1149,10 +1149,10 @@ BOOL OfaAutocorrReplacePage::FillItemSet( SfxItemSet& ) } } - return FALSE; + return sal_False; } -void OfaAutocorrReplacePage::RefillReplaceBox(BOOL bFromReset, +void OfaAutocorrReplacePage::RefillReplaceBox(sal_Bool bFromReset, LanguageType eOldLanguage, LanguageType eNewLanguage) { @@ -1164,17 +1164,17 @@ void OfaAutocorrReplacePage::RefillReplaceBox(BOOL bFromReset, DoubleStringArray* pArray = 0; if(aDoubleStringTable.IsKeyValid(eOldLanguage)) { - pArray = aDoubleStringTable.Seek(ULONG(eOldLanguage)); + pArray = aDoubleStringTable.Seek(sal_uLong(eOldLanguage)); pArray->DeleteAndDestroy(0, pArray->Count()); } else { pArray = new DoubleStringArray; - aDoubleStringTable.Insert(ULONG(eOldLanguage), pArray); + aDoubleStringTable.Insert(sal_uLong(eOldLanguage), pArray); } - USHORT nListBoxCount = (USHORT)aReplaceTLB.GetEntryCount(); - USHORT i; + sal_uInt16 nListBoxCount = (sal_uInt16)aReplaceTLB.GetEntryCount(); + sal_uInt16 i; for(i = 0; i < nListBoxCount; i++) { DoubleString* pDouble = new DoubleString(); @@ -1197,11 +1197,11 @@ void OfaAutocorrReplacePage::RefillReplaceBox(BOOL bFromReset, if(aDoubleStringTable.IsKeyValid(eLang)) { - DoubleStringArray* pArray = aDoubleStringTable.Seek(ULONG(eNewLanguage)); - for(USHORT i = 0; i < pArray->Count(); i++) + DoubleStringArray* pArray = aDoubleStringTable.Seek(sal_uLong(eNewLanguage)); + for(sal_uInt16 i = 0; i < pArray->Count(); i++) { DoubleString* pDouble = pArray->GetObject(i); - BOOL bTextOnly = 0 == pDouble->pUserData; + sal_Bool bTextOnly = 0 == pDouble->pUserData; // formatierter Text wird nur im Writer angeboten if(bSWriter || bTextOnly) { @@ -1224,10 +1224,10 @@ void OfaAutocorrReplacePage::RefillReplaceBox(BOOL bFromReset, SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); SvxAutocorrWordList* pWordList = pAutoCorrect->LoadAutocorrWordList(eLang); - for(USHORT i = 0; i < pWordList->Count(); i++) + for(sal_uInt16 i = 0; i < pWordList->Count(); i++) { SvxAutocorrWordPtr pWordPtr = pWordList->GetObject(i); - BOOL bTextOnly = pWordPtr->IsTextOnly(); + sal_Bool bTextOnly = pWordPtr->IsTextOnly(); // formatierter Text wird nur im Writer angeboten if(bSWriter || bTextOnly) { @@ -1244,27 +1244,27 @@ void OfaAutocorrReplacePage::RefillReplaceBox(BOOL bFromReset, pFormatText->Insert(new String(pWordPtr->GetShort())); } } - aNewReplacePB.Enable(FALSE); - aDeleteReplacePB.Enable(FALSE); + aNewReplacePB.Enable(sal_False); + aDeleteReplacePB.Enable(sal_False); } SfxViewShell* pViewShell = SfxViewShell::Current(); - if( pViewShell && pViewShell->HasSelection( TRUE ) ) + if( pViewShell && pViewShell->HasSelection( sal_True ) ) { - bHasSelectionText = TRUE; + bHasSelectionText = sal_True; const String sSelection( pViewShell->GetSelectionText() ); aReplaceED.SetText( sSelection ); aTextOnlyCB.Check( !bSWriter ); aTextOnlyCB.Enable( bSWriter && sSelection.Len() ); } else - aTextOnlyCB.Enable( FALSE ); + aTextOnlyCB.Enable( sal_False ); } void OfaAutocorrReplacePage::Reset( const SfxItemSet& ) { - RefillReplaceBox(TRUE, eLang, eLang); + RefillReplaceBox(sal_True, eLang, eLang); aShortED.GrabFocus(); } @@ -1273,7 +1273,7 @@ void OfaAutocorrReplacePage::SetLanguage(LanguageType eSet) //save old settings an refill if(eSet != eLang) { - RefillReplaceBox(FALSE, eLang, eSet); + RefillReplaceBox(sal_False, eLang, eSet); eLastDialogLanguage = eSet; delete pCompareClass; delete pCharClass; @@ -1294,7 +1294,7 @@ IMPL_LINK(OfaAutocorrReplacePage, SelectHdl, SvTabListBox*, pBox) String sTmpShort(pBox->GetEntryText(pEntry, 0)); // wird der Text ueber den ModifyHdl gesetzt, dann steht der Cursor sonst immer am Wortanfang, // obwohl man gerade hier editiert - BOOL bSameContent = 0 == pCompareClass->compareString( + sal_Bool bSameContent = 0 == pCompareClass->compareString( sTmpShort, aShortED.GetText() ); Selection aSel = aShortED.GetSelection(); if(aShortED.GetText() != sTmpShort) @@ -1309,9 +1309,9 @@ IMPL_LINK(OfaAutocorrReplacePage, SelectHdl, SvTabListBox*, pBox) aTextOnlyCB.Check(0 == pEntry->GetUserData()); } else - bFirstSelect = FALSE; + bFirstSelect = sal_False; - aNewReplacePB.Enable(FALSE); + aNewReplacePB.Enable(sal_False); aDeleteReplacePB.Enable(); return 0; }; @@ -1336,18 +1336,18 @@ IMPL_LINK(OfaAutocorrReplacePage, NewDelHdl, PushButton*, pBtn) if(sEntry.Len() && ( aReplaceED.GetText().Len() || ( bHasSelectionText && bSWriter ) )) { - aReplaceTLB.SetUpdateMode(FALSE); - USHORT nPos = USHRT_MAX; + aReplaceTLB.SetUpdateMode(sal_False); + sal_uInt16 nPos = USHRT_MAX; sEntry += '\t'; sEntry += aReplaceED.GetText(); if(_pNewEntry) { - nPos = (USHORT)aReplaceTLB.GetModel()->GetAbsPos(_pNewEntry); + nPos = (sal_uInt16)aReplaceTLB.GetModel()->GetAbsPos(_pNewEntry); aReplaceTLB.GetModel()->Remove(_pNewEntry); } else { - USHORT j; + sal_uInt16 j; for( j = 0; j < aReplaceTLB.GetEntryCount(); j++ ) { SvLBoxEntry* pReplaceEntry = aReplaceTLB.GetEntry(j); @@ -1365,7 +1365,7 @@ IMPL_LINK(OfaAutocorrReplacePage, NewDelHdl, PushButton*, pBtn) pInsEntry->SetUserData(&bHasSelectionText); // neuer formatierter Text aReplaceTLB.MakeVisible( pInsEntry ); - aReplaceTLB.SetUpdateMode(TRUE); + aReplaceTLB.SetUpdateMode(sal_True); // falls der Request aus dem ReplaceEdit kam, dann Focus in das ShortEdit setzen if(aReplaceED.HasFocus()) aShortED.GrabFocus(); @@ -1385,7 +1385,7 @@ IMPL_LINK(OfaAutocorrReplacePage, NewDelHdl, PushButton*, pBtn) IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt) { SvLBoxEntry* pFirstSel = aReplaceTLB.FirstSelected(); - BOOL bShort = pEdt == &aShortED; + sal_Bool bShort = pEdt == &aShortED; const String rEntry = pEdt->GetText(); const String rRepString = aReplaceED.GetText(); String aWordStr( pCharClass->lower( rEntry )); @@ -1394,21 +1394,21 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt) { if(rEntry.Len()) { - BOOL bFound = FALSE; - BOOL bTmpSelEntry=FALSE; + sal_Bool bFound = sal_False; + sal_Bool bTmpSelEntry=sal_False; - for(USHORT i = 0; i < aReplaceTLB.GetEntryCount(); i++) + for(sal_uInt16 i = 0; i < aReplaceTLB.GetEntryCount(); i++) { SvLBoxEntry* pEntry = aReplaceTLB.GetEntry( i ); String aTestStr=aReplaceTLB.GetEntryText(pEntry, 0); if( 0 == pCompareClass->compareString(rEntry, aTestStr )) { if(rRepString.Len()) - bFirstSelect = TRUE; + bFirstSelect = sal_True; aReplaceTLB.SetCurEntry(pEntry); pFirstSel = pEntry; aNewReplacePB.SetText(sModify); - bFound= TRUE; + bFound= sal_True; break; } else @@ -1417,17 +1417,17 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt) if(aTestStr.Search(aWordStr)==0 && !bTmpSelEntry) { aReplaceTLB.MakeVisible(pEntry); - bTmpSelEntry=TRUE; + bTmpSelEntry=sal_True; } } } if(!bFound) { - aReplaceTLB.SelectAll(FALSE); + aReplaceTLB.SelectAll(sal_False); pFirstSel = 0; aNewReplacePB.SetText(sNew); if(bReplaceEditChanged) - aTextOnlyCB.Enable(FALSE); + aTextOnlyCB.Enable(sal_False); } aDeleteReplacePB.Enable(bFound); } @@ -1440,7 +1440,7 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt) } else if(!bShort) { - bReplaceEditChanged = TRUE; + bReplaceEditChanged = sal_True; if(pFirstSel) { aNewReplacePB.SetText(sModify); @@ -1448,17 +1448,17 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, Edit*, pEdt) } const String& rShortTxt = aShortED.GetText(); - BOOL bEnableNew = rShortTxt.Len() && + sal_Bool bEnableNew = rShortTxt.Len() && ( rRepString.Len() || ( bHasSelectionText && bSWriter )) && ( !pFirstSel || rRepString != aReplaceTLB.GetEntryText( pFirstSel, 1 ) ); if(bEnableNew && pFormatText) { - for(USHORT i = 0; i < pFormatText->Count(); i++) + for(sal_uInt16 i = 0; i < pFormatText->Count(); i++) if(*pFormatText->GetObject(i) == rShortTxt) { - bEnableNew = FALSE; + bEnableNew = sal_False; break; } } @@ -1478,12 +1478,12 @@ struct StringsArrays }; typedef StringsArrays* StringsArraysPtr; -BOOL lcl_FindInArray(SvStringsDtor& rStrings, const String& rString) +sal_Bool lcl_FindInArray(SvStringsDtor& rStrings, const String& rString) { - for(USHORT i = 0; i < rStrings.Count(); i++) + for(sal_uInt16 i = 0; i < rStrings.Count(); i++) if(rString == *rStrings.GetObject(i)) - return TRUE; - return FALSE; + return sal_True; + return sal_False; } void lcl_ClearTable(StringsTable& rTable) @@ -1514,6 +1514,11 @@ OfaAutocorrExceptPage::OfaAutocorrExceptPage( Window* pParent, aAutoCapsCB (this, CUI_RES(CB_AUTOCAPS )), eLang(eLastDialogLanguage) { + aNewAbbrevPB.SetAccessibleName(String(CUI_RES(STR_PB_NEWABBREV) ) ); + aDelAbbrevPB.SetAccessibleName(String(CUI_RES(STR_PB_DELABBREV) ) ); + aNewDoublePB.SetAccessibleName(String(CUI_RES(STR_PB_NEWDOUBLECAPS) ) ); + aDelDoublePB.SetAccessibleName(String(CUI_RES(STR_PB_DELDOUBLECAPS) ) ); + FreeResource(); ::com::sun::star::lang::Locale aLcl( SvxCreateLocale(eLastDialogLanguage )); @@ -1534,6 +1539,10 @@ OfaAutocorrExceptPage::OfaAutocorrExceptPage( Window* pParent, aAbbrevED.SetActionHdl(LINK(this, OfaAutocorrExceptPage, NewDelHdl)); aDoubleCapsED.SetActionHdl(LINK(this, OfaAutocorrExceptPage, NewDelHdl)); + aNewAbbrevPB.SetAccessibleRelationMemberOf(&aAbbrevFL); + aDelAbbrevPB.SetAccessibleRelationMemberOf(&aAbbrevFL); + aNewDoublePB.SetAccessibleRelationMemberOf(&aDoubleCapsFL); + aDelDoublePB.SetAccessibleRelationMemberOf(&aDoubleCapsFL); } OfaAutocorrExceptPage::~OfaAutocorrExceptPage() @@ -1552,7 +1561,7 @@ void OfaAutocorrExceptPage::ActivatePage( const SfxItemSet& ) { if(eLang != eLastDialogLanguage) SetLanguage(eLastDialogLanguage); - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(TRUE); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(sal_True); } int OfaAutocorrExceptPage::DeactivatePage( SfxItemSet* ) @@ -1560,7 +1569,7 @@ int OfaAutocorrExceptPage::DeactivatePage( SfxItemSet* ) return LEAVE_PAGE; } -BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); StringsArraysPtr pArrays = aStringsTable.Last(); @@ -1573,8 +1582,8 @@ BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) if(pWrdList) { - USHORT nCount = pWrdList->Count(); - USHORT i; + sal_uInt16 nCount = pWrdList->Count(); + sal_uInt16 i; for( i = nCount; i; ) { String* pString = pWrdList->GetObject( --i ); @@ -1596,8 +1605,8 @@ BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) if(pCplList) { - USHORT nCount = pCplList->Count(); - USHORT i; + sal_uInt16 nCount = pCplList->Count(); + sal_uInt16 i; for( i = nCount; i; ) { String* pString = pCplList->GetObject( --i ); @@ -1622,8 +1631,8 @@ BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) if(pWrdList) { - USHORT nCount = pWrdList->Count(); - USHORT i; + sal_uInt16 nCount = pWrdList->Count(); + sal_uInt16 i; for( i = nCount; i; ) { String* pString = pWrdList->GetObject( --i ); @@ -1644,8 +1653,8 @@ BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) if(pCplList) { - USHORT nCount = pCplList->Count(); - USHORT i; + sal_uInt16 nCount = pCplList->Count(); + sal_uInt16 i; for( i = nCount; i; ) { String* pString = pCplList->GetObject( --i ); @@ -1665,7 +1674,7 @@ BOOL OfaAutocorrExceptPage::FillItemSet( SfxItemSet& ) pAutoCorrect->SetAutoCorrFlag( SaveWordCplSttLst, aAutoAbbrevCB.IsChecked()); if(aAutoCapsCB.IsChecked() != aAutoCapsCB.GetSavedValue()) pAutoCorrect->SetAutoCorrFlag( SaveWordWrdSttLst, aAutoCapsCB.IsChecked()); - return FALSE; + return sal_False; } void OfaAutocorrExceptPage::SetLanguage(LanguageType eSet) @@ -1673,7 +1682,7 @@ void OfaAutocorrExceptPage::SetLanguage(LanguageType eSet) if(eLang != eSet) { //alte Einstellungen speichern und neu fuellen - RefillReplaceBoxes(FALSE, eLang, eSet); + RefillReplaceBoxes(sal_False, eLang, eSet); eLastDialogLanguage = eSet; delete pCompareClass; pCompareClass = new CollatorWrapper( GetProcessFact() ); @@ -1685,7 +1694,7 @@ void OfaAutocorrExceptPage::SetLanguage(LanguageType eSet) } } -void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, +void OfaAutocorrExceptPage::RefillReplaceBoxes(sal_Bool bFromReset, LanguageType eOldLanguage, LanguageType eNewLanguage) { @@ -1697,7 +1706,7 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, StringsArraysPtr pArrays = 0; if(aStringsTable.IsKeyValid(eOldLanguage)) { - pArrays = aStringsTable.Seek(ULONG(eOldLanguage)); + pArrays = aStringsTable.Seek(sal_uLong(eOldLanguage)); pArrays->aAbbrevStrings.DeleteAndDestroy( 0, pArrays->aAbbrevStrings.Count()); pArrays->aDoubleCapsStrings.DeleteAndDestroy( @@ -1706,10 +1715,10 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, else { pArrays = new StringsArrays; - aStringsTable.Insert(ULONG(eOldLanguage), pArrays); + aStringsTable.Insert(sal_uLong(eOldLanguage), pArrays); } - USHORT i; + sal_uInt16 i; for(i = 0; i < aAbbrevLB.GetEntryCount(); i++) { pArrays->aAbbrevStrings.Insert( @@ -1730,8 +1739,8 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, if(aStringsTable.IsKeyValid(eLang)) { - StringsArraysPtr pArrays = aStringsTable.Seek(ULONG(eLang)); - USHORT i; + StringsArraysPtr pArrays = aStringsTable.Seek(sal_uLong(eLang)); + sal_uInt16 i; for(i = 0; i < pArrays->aAbbrevStrings.Count(); i++ ) { aAbbrevLB.InsertEntry(*pArrays->aAbbrevStrings.GetObject(i)); @@ -1746,7 +1755,7 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); const SvStringsISortDtor* pCplList = pAutoCorrect->GetCplSttExceptList(eLang); const SvStringsISortDtor* pWrdList = pAutoCorrect->GetWrdSttExceptList(eLang); - USHORT i; + sal_uInt16 i; for( i = 0; i < pCplList->Count(); i++ ) { aAbbrevLB.InsertEntry(*pCplList->GetObject(i)); @@ -1761,7 +1770,7 @@ void OfaAutocorrExceptPage::RefillReplaceBoxes(BOOL bFromReset, void OfaAutocorrExceptPage::Reset( const SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); - RefillReplaceBoxes(TRUE, eLang, eLang); + RefillReplaceBoxes(sal_True, eLang, eLang); aAutoAbbrevCB. Check( pAutoCorrect->IsAutoCorrFlag( SaveWordCplSttLst )); aAutoCapsCB. Check( pAutoCorrect->IsAutoCorrFlag( SaveWordWrdSttLst )); aAutoAbbrevCB.SaveValue(); @@ -1800,13 +1809,13 @@ IMPL_LINK(OfaAutocorrExceptPage, SelectHdl, ListBox*, pBox) if(pBox == &aAbbrevLB) { aAbbrevED.SetText(pBox->GetSelectEntry()); - aNewAbbrevPB.Enable(FALSE); + aNewAbbrevPB.Enable(sal_False); aDelAbbrevPB.Enable(); } else { aDoubleCapsED.SetText(pBox->GetSelectEntry()); - aNewDoublePB.Enable(FALSE); + aNewDoublePB.Enable(sal_False); aDelDoublePB.Enable(); } return 0; @@ -1814,12 +1823,12 @@ IMPL_LINK(OfaAutocorrExceptPage, SelectHdl, ListBox*, pBox) IMPL_LINK(OfaAutocorrExceptPage, ModifyHdl, Edit*, pEdt) { -// BOOL bSame = pEdt->GetText() == ->GetSelectEntry(); +// sal_Bool bSame = pEdt->GetText() == ->GetSelectEntry(); const String& sEntry = pEdt->GetText(); - BOOL bEntryLen = 0!= sEntry.Len(); + sal_Bool bEntryLen = 0!= sEntry.Len(); if(pEdt == &aAbbrevED) { - BOOL bSame = lcl_FindEntry(aAbbrevLB, sEntry, *pCompareClass); + sal_Bool bSame = lcl_FindEntry(aAbbrevLB, sEntry, *pCompareClass); if(bSame && sEntry != aAbbrevLB.GetSelectEntry()) pEdt->SetText(aAbbrevLB.GetSelectEntry()); aNewAbbrevPB.Enable(!bSame && bEntryLen); @@ -1827,7 +1836,7 @@ IMPL_LINK(OfaAutocorrExceptPage, ModifyHdl, Edit*, pEdt) } else { - BOOL bSame = lcl_FindEntry(aDoubleCapsLB, sEntry, *pCompareClass); + sal_Bool bSame = lcl_FindEntry(aDoubleCapsLB, sEntry, *pCompareClass); if(bSame && sEntry != aDoubleCapsLB.GetSelectEntry()) pEdt->SetText(aDoubleCapsLB.GetSelectEntry()); aNewDoublePB.Enable(!bSame && bEntryLen); @@ -1839,7 +1848,7 @@ IMPL_LINK(OfaAutocorrExceptPage, ModifyHdl, Edit*, pEdt) void AutoCorrEdit::KeyInput( const KeyEvent& rKEvt ) { const KeyCode aKeyCode = rKEvt.GetKeyCode(); - const USHORT nModifier = aKeyCode.GetModifier(); + const sal_uInt16 nModifier = aKeyCode.GetModifier(); if( aKeyCode.GetCode() == KEY_RETURN ) { //wird bei Enter nichts getan, dann doch die Basisklasse rufen @@ -1857,7 +1866,7 @@ enum OfaQuoteOptions REPLACE_1ST }; -SvLBoxEntry* OfaQuoteTabPage::CreateEntry(String& rTxt, USHORT nCol) +SvLBoxEntry* OfaQuoteTabPage::CreateEntry(String& rTxt, sal_uInt16 nCol) { SvLBoxEntry* pEntry = new SvLBoxEntry; @@ -1920,16 +1929,23 @@ OfaQuoteTabPage::OfaQuoteTabPage( Window* pParent, const SfxItemSet& rSet ) : sStandard(CUI_RES(ST_STANDARD)) { + aSglStandardPB.SetAccessibleName(String(CUI_RES(STR_PB_SGL_STD) ) ); + aDblStandardPB.SetAccessibleName(String(CUI_RES(STR_PB_DBL_STD) ) ); + aStartQuotePB.SetAccessibleName( String(CUI_RES(STR_PB_DBL_START) )); + aEndQuotePB.SetAccessibleName(String(CUI_RES(STR_PB_DBL_END) )); + aSglStartQuotePB.SetAccessibleName(String(CUI_RES(STR_PB_SGL_START) )); + aSglEndQuotePB.SetAccessibleName(String(CUI_RES(STR_PB_SGL_END) ) ); + FreeResource(); - BOOL bShowSWOptions = FALSE; + sal_Bool bShowSWOptions = sal_False; aCheckLB.SetHelpId( HID_OFAPAGE_QUOTE_CLB ); aSwCheckLB.SetHelpId( HID_OFAPAGE_QUOTE_SW_CLB ); - SFX_ITEMSET_ARG( &rSet, pItem, SfxBoolItem, SID_AUTO_CORRECT_DLG, FALSE ); + SFX_ITEMSET_ARG( &rSet, pItem, SfxBoolItem, SID_AUTO_CORRECT_DLG, sal_False ); if ( pItem && pItem->GetValue() ) - bShowSWOptions = TRUE; + bShowSWOptions = sal_True; if ( bShowSWOptions ) { @@ -1938,7 +1954,7 @@ OfaQuoteTabPage::OfaQuoteTabPage( Window* pParent, const SfxItemSet& rSet ) : 3, 0, 20, 40 }; - aSwCheckLB.SetWindowBits(WB_HSCROLL| WB_VSCROLL); + aSwCheckLB.SetStyle(aSwCheckLB.GetStyle() | WB_HSCROLL| WB_VSCROLL); aSwCheckLB.SvxSimpleTable::SetTabs(aStaticTabs); String sHeader( sHeader1 ); @@ -1947,7 +1963,7 @@ OfaQuoteTabPage::OfaQuoteTabPage( Window* pParent, const SfxItemSet& rSet ) : sHeader += '\t'; aSwCheckLB.InsertHeaderEntry( sHeader, HEADERBAR_APPEND, HIB_CENTER | HIB_VCENTER | HIB_FIXEDPOS | HIB_FIXED); - aCheckLB.Hide( TRUE ); + aCheckLB.Hide( sal_True ); } else { @@ -1961,6 +1977,16 @@ OfaQuoteTabPage::OfaQuoteTabPage( Window* pParent, const SfxItemSet& rSet ) : aDblStandardPB.SetClickHdl(LINK(this, OfaQuoteTabPage, StdQuoteHdl)); aSglStandardPB.SetClickHdl(LINK(this, OfaQuoteTabPage, StdQuoteHdl)); + aSglStartQuotePB.SetAccessibleRelationLabeledBy( &aSglStartQuoteFT ); + aSglEndQuotePB.SetAccessibleRelationLabeledBy( &aSglEndQuoteFT ); + aSglStartQuotePB.SetAccessibleRelationMemberOf( &aSingleFL ); + aSglEndQuotePB.SetAccessibleRelationMemberOf( &aSingleFL ); + aStartQuotePB.SetAccessibleRelationLabeledBy( &aStartQuoteFT ); + aEndQuotePB.SetAccessibleRelationLabeledBy( &aEndQuoteFT ); + aStartQuotePB.SetAccessibleRelationMemberOf( &aDoubleFL ); + aEndQuotePB.SetAccessibleRelationMemberOf( &aDoubleFL ); + aSglStandardPB.SetAccessibleRelationMemberOf(&aSingleFL); + aDblStandardPB.SetAccessibleRelationMemberOf(&aDoubleFL); } OfaQuoteTabPage::~OfaQuoteTabPage() @@ -1974,7 +2000,7 @@ SfxTabPage* OfaQuoteTabPage::Create( Window* pParent, return new OfaQuoteTabPage(pParent, rAttrSet); } -BOOL OfaQuoteTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaQuoteTabPage::FillItemSet( SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); @@ -1982,17 +2008,17 @@ BOOL OfaQuoteTabPage::FillItemSet( SfxItemSet& ) if ( aCheckLB.IsVisible( ) ) { - USHORT nPos = 0; + sal_uInt16 nPos = 0; pAutoCorrect->SetAutoCorrFlag(AddNonBrkSpace, aCheckLB.IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(ChgOrdinalNumber, aCheckLB.IsChecked(nPos++)); } - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if ( aSwCheckLB.IsVisible( ) ) { SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); - BOOL bCheck = aSwCheckLB.IsChecked(ADD_NONBRK_SPACE, CBCOL_FIRST); + sal_Bool bCheck = aSwCheckLB.IsChecked(ADD_NONBRK_SPACE, CBCOL_FIRST); bModified |= pOpt->bAddNonBrkSpace != bCheck; pOpt->bAddNonBrkSpace = bCheck; pAutoCorrect->SetAutoCorrFlag(AddNonBrkSpace, @@ -2007,28 +2033,28 @@ BOOL OfaQuoteTabPage::FillItemSet( SfxItemSet& ) pAutoCorrect->SetAutoCorrFlag(ChgQuotes, aTypoCB.IsChecked()); pAutoCorrect->SetAutoCorrFlag(ChgSglQuotes, aSingleTypoCB.IsChecked()); - BOOL bReturn = nFlags != pAutoCorrect->GetFlags(); + sal_Bool bReturn = nFlags != pAutoCorrect->GetFlags(); if(cStartQuote != pAutoCorrect->GetStartDoubleQuote()) { - bReturn = TRUE; + bReturn = sal_True; sal_Unicode cUCS2 = static_cast<sal_Unicode>(cStartQuote); //TODO pAutoCorrect->SetStartDoubleQuote(cUCS2); } if(cEndQuote != pAutoCorrect->GetEndDoubleQuote()) { - bReturn = TRUE; + bReturn = sal_True; sal_Unicode cUCS2 = static_cast<sal_Unicode>(cEndQuote); //TODO pAutoCorrect->SetEndDoubleQuote(cUCS2); } if(cSglStartQuote != pAutoCorrect->GetStartSingleQuote()) { - bReturn = TRUE; + bReturn = sal_True; sal_Unicode cUCS2 = static_cast<sal_Unicode>(cSglStartQuote); //TODO pAutoCorrect->SetStartSingleQuote(cUCS2); } if(cSglEndQuote != pAutoCorrect->GetEndSingleQuote()) { - bReturn = TRUE; + bReturn = sal_True; sal_Unicode cUCS2 = static_cast<sal_Unicode>(cSglEndQuote); //TODO pAutoCorrect->SetEndSingleQuote(cUCS2); } @@ -2044,7 +2070,7 @@ BOOL OfaQuoteTabPage::FillItemSet( SfxItemSet& ) void OfaQuoteTabPage::ActivatePage( const SfxItemSet& ) { - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(FALSE); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage(sal_False); } void OfaQuoteTabPage::Reset( const SfxItemSet& ) @@ -2057,7 +2083,7 @@ void OfaQuoteTabPage::Reset( const SfxItemSet& ) { SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); - aSwCheckLB.SetUpdateMode( FALSE ); + aSwCheckLB.SetUpdateMode( sal_False ); aSwCheckLB.Clear(); aSwCheckLB.GetModel()->Insert(CreateEntry(sNonBrkSpace, CBCOL_BOTH )); @@ -2068,23 +2094,23 @@ void OfaQuoteTabPage::Reset( const SfxItemSet& ) aSwCheckLB.CheckEntryPos( REPLACE_1ST, CBCOL_FIRST, pOpt->bChgOrdinalNumber ); aSwCheckLB.CheckEntryPos( REPLACE_1ST, CBCOL_SECOND, 0 != (nFlags & ChgOrdinalNumber) ); - aSwCheckLB.SetUpdateMode( TRUE ); + aSwCheckLB.SetUpdateMode( sal_True ); } // Initialize the non Sw options if ( aCheckLB.IsVisible( ) ) { - aCheckLB.SetUpdateMode( FALSE ); + aCheckLB.SetUpdateMode( sal_False ); aCheckLB.Clear( ); aCheckLB.InsertEntry( sNonBrkSpace ); aCheckLB.InsertEntry( sOrdinal ); - USHORT nPos = 0; + sal_uInt16 nPos = 0; aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & AddNonBrkSpace) ); aCheckLB.CheckEntryPos( nPos++, 0 != (nFlags & ChgOrdinalNumber) ); - aCheckLB.SetUpdateMode( TRUE ); + aCheckLB.SetUpdateMode( sal_True ); } // Initialize the quote stuffs @@ -2112,7 +2138,7 @@ void OfaQuoteTabPage::Reset( const SfxItemSet& ) IMPL_LINK( OfaQuoteTabPage, QuoteHdl, PushButton*, pBtn ) { - USHORT nMode = SGL_START; + sal_uInt16 nMode = SGL_START; if(pBtn == &aSglEndQuotePB) nMode = SGL_END; else if(pBtn == &aStartQuotePB) @@ -2120,7 +2146,7 @@ IMPL_LINK( OfaQuoteTabPage, QuoteHdl, PushButton*, pBtn ) else if(pBtn == &aEndQuotePB) nMode = DBL_END; // Zeichenauswahl-Dialog starten - SvxCharacterMap* pMap = new SvxCharacterMap( this, TRUE ); + SvxCharacterMap* pMap = new SvxCharacterMap( this, sal_True ); pMap->SetCharFont( OutputDevice::GetDefaultFont(DEFAULTFONT_LATIN_TEXT, LANGUAGE_ENGLISH_US, DEFAULTFONT_FLAGS_ONLYONE, 0 )); pMap->SetText(nMode < SGL_END ? sStartQuoteDlg : sEndQuoteDlg ); @@ -2132,22 +2158,22 @@ IMPL_LINK( OfaQuoteTabPage, QuoteHdl, PushButton*, pBtn ) case SGL_START: cDlg = cSglStartQuote; if(cDlg == 0) - cDlg = pAutoCorrect->GetQuote('\'',TRUE,eLang); + cDlg = pAutoCorrect->GetQuote('\'', sal_True, eLang); break; case SGL_END: cDlg = cSglEndQuote; if(cDlg == 0) - cDlg = pAutoCorrect->GetQuote('\'',FALSE,eLang); + cDlg = pAutoCorrect->GetQuote('\'', sal_False, eLang); break; case DBL_START: cDlg = cStartQuote; if(cDlg == 0) - cDlg = pAutoCorrect->GetQuote('\"',TRUE,eLang); + cDlg = pAutoCorrect->GetQuote('\"', sal_True, eLang); break; case DBL_END: cDlg = cEndQuote; if(cDlg == 0) - cDlg = pAutoCorrect->GetQuote('\"',FALSE,eLang); + cDlg = pAutoCorrect->GetQuote('\"', sal_False, eLang); break; default: OSL_FAIL("svx::OfaQuoteTabPage::QuoteHdl(), how to initialize cDlg?" ); @@ -2254,7 +2280,7 @@ OfaAutoCompleteTabPage::OfaAutoCompleteTabPage( Window* pParent, FreeResource(); // the defined KEYs - static const USHORT aKeyCodes[] = { + static const sal_uInt16 aKeyCodes[] = { KEY_END, KEY_RETURN, KEY_SPACE, @@ -2263,11 +2289,11 @@ OfaAutoCompleteTabPage::OfaAutoCompleteTabPage( Window* pParent, 0 }; - for( const USHORT* pKeys = aKeyCodes; *pKeys; ++pKeys ) + for( const sal_uInt16* pKeys = aKeyCodes; *pKeys; ++pKeys ) { KeyCode aKCode( *pKeys ); - USHORT nPos = aDCBExpandKey.InsertEntry( aKCode.GetName() ); - aDCBExpandKey.SetEntryData( nPos, (void*)(ULONG)*pKeys ); + sal_uInt16 nPos = aDCBExpandKey.InsertEntry( aKCode.GetName() ); + aDCBExpandKey.SetEntryData( nPos, (void*)(sal_uLong)*pKeys ); if( KEY_RETURN == *pKeys ) // default to RETURN aDCBExpandKey.SelectEntryPos( nPos ); } @@ -2275,6 +2301,7 @@ OfaAutoCompleteTabPage::OfaAutoCompleteTabPage( Window* pParent, aPBEntries.SetClickHdl(LINK(this, OfaAutoCompleteTabPage, DeleteHdl)); aCBActiv.SetToggleHdl(LINK(this, OfaAutoCompleteTabPage, CheckHdl)); aCBCollect.SetToggleHdl(LINK(this, OfaAutoCompleteTabPage, CheckHdl)); + aLBEntries.SetAccessibleRelationLabeledBy(&aLBEntries); } OfaAutoCompleteTabPage::~OfaAutoCompleteTabPage() @@ -2287,12 +2314,12 @@ SfxTabPage* OfaAutoCompleteTabPage::Create( Window* pParent, return new OfaAutoCompleteTabPage( pParent, rSet ); } -BOOL OfaAutoCompleteTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaAutoCompleteTabPage::FillItemSet( SfxItemSet& ) { - BOOL bModified = FALSE, bCheck; + sal_Bool bModified = sal_False, bCheck; SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); - USHORT nVal; + sal_uInt16 nVal; bCheck = aCBActiv.IsChecked(); bModified |= pOpt->bAutoCompleteWords != bCheck; @@ -2310,25 +2337,25 @@ BOOL OfaAutoCompleteTabPage::FillItemSet( SfxItemSet& ) bModified |= pOpt->bAutoCmpltShowAsTip != bCheck; pOpt->bAutoCmpltShowAsTip = bCheck; - nVal = (USHORT)aNFMinWordlen.GetValue(); + nVal = (sal_uInt16)aNFMinWordlen.GetValue(); bModified |= nVal != pOpt->nAutoCmpltWordLen; pOpt->nAutoCmpltWordLen = nVal; - nVal = (USHORT)aNFMaxEntries.GetValue(); + nVal = (sal_uInt16)aNFMaxEntries.GetValue(); bModified |= nVal != pOpt->nAutoCmpltListLen; pOpt->nAutoCmpltListLen = nVal; nVal = aDCBExpandKey.GetSelectEntryPos(); if( nVal < aDCBExpandKey.GetEntryCount() ) { - ULONG nKey = (ULONG)aDCBExpandKey.GetEntryData( nVal ); + sal_uLong nKey = (sal_uLong)aDCBExpandKey.GetEntryData( nVal ); bModified |= nKey != pOpt->nAutoCmpltExpandKey; - pOpt->nAutoCmpltExpandKey = (USHORT)nKey; + pOpt->nAutoCmpltExpandKey = (sal_uInt16)nKey; } if( pAutoCmpltList && nAutoCmpltListCnt != aLBEntries.GetEntryCount() ) { - bModified = TRUE; + bModified = sal_True; pOpt->pAutoCmpltList = pAutoCmpltList; } if( bModified ) @@ -2337,7 +2364,7 @@ BOOL OfaAutoCompleteTabPage::FillItemSet( SfxItemSet& ) pCfg->SetModified(); pCfg->Commit(); } - return TRUE; + return sal_True; } void OfaAutoCompleteTabPage::Reset( const SfxItemSet& ) @@ -2356,9 +2383,9 @@ void OfaAutoCompleteTabPage::Reset( const SfxItemSet& ) // select the specific KeyCode: { - ULONG nKey = pOpt->nAutoCmpltExpandKey; - for( USHORT n = 0, nCnt = aDCBExpandKey.GetEntryCount(); n < nCnt; ++n ) - if( nKey == (ULONG)aDCBExpandKey.GetEntryData( n )) + sal_uLong nKey = pOpt->nAutoCmpltExpandKey; + for( sal_uInt16 n = 0, nCnt = aDCBExpandKey.GetEntryCount(); n < nCnt; ++n ) + if( nKey == (sal_uLong)aDCBExpandKey.GetEntryData( n )) { aDCBExpandKey.SelectEntryPos( n ); break; @@ -2370,10 +2397,10 @@ void OfaAutoCompleteTabPage::Reset( const SfxItemSet& ) pAutoCmpltList = (SvStringsISortDtor*)pOpt->pAutoCmpltList; pOpt->pAutoCmpltList = 0; nAutoCmpltListCnt = pAutoCmpltList->Count(); - for( USHORT n = 0; n < nAutoCmpltListCnt; ++n ) + for( sal_uInt16 n = 0; n < nAutoCmpltListCnt; ++n ) { const StringPtr pStr = pAutoCmpltList->GetObject( n ); - USHORT nPos = aLBEntries.InsertEntry( *pStr ); + sal_uInt16 nPos = aLBEntries.InsertEntry( *pStr ); aLBEntries.SetEntryData( nPos, (void*)pStr ); } } @@ -2389,15 +2416,15 @@ void OfaAutoCompleteTabPage::Reset( const SfxItemSet& ) void OfaAutoCompleteTabPage::ActivatePage( const SfxItemSet& ) { - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage( FALSE ); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage( sal_False ); } IMPL_LINK( OfaAutoCompleteTabPage, DeleteHdl, PushButton*, EMPTYARG ) { - USHORT nSelCnt = pAutoCmpltList ? aLBEntries.GetSelectEntryCount() : 0; + sal_uInt16 nSelCnt = pAutoCmpltList ? aLBEntries.GetSelectEntryCount() : 0; while( nSelCnt ) { - USHORT nPos = aLBEntries.GetSelectEntryPos( --nSelCnt ); + sal_uInt16 nPos = aLBEntries.GetSelectEntryPos( --nSelCnt ); const StringPtr pStr = (StringPtr)aLBEntries.GetEntryData( nPos ); aLBEntries.RemoveEntry( nPos ); nPos = pAutoCmpltList->GetPos( pStr ); @@ -2409,7 +2436,7 @@ IMPL_LINK( OfaAutoCompleteTabPage, DeleteHdl, PushButton*, EMPTYARG ) IMPL_LINK( OfaAutoCompleteTabPage, CheckHdl, CheckBox*, pBox ) { - BOOL bEnable = pBox->IsChecked(); + sal_Bool bEnable = pBox->IsChecked(); if( pBox == &aCBActiv ) { aCBAppendSpace.Enable( bEnable ); @@ -2424,7 +2451,7 @@ IMPL_LINK( OfaAutoCompleteTabPage, CheckHdl, CheckBox*, pBox ) void OfaAutoCompleteTabPage::CopyToClipboard() const { - USHORT nSelCnt = aLBEntries.GetSelectEntryCount(); + sal_uInt16 nSelCnt = aLBEntries.GetSelectEntryCount(); if( pAutoCmpltList && nSelCnt ) { TransferDataContainer* pCntnr = new TransferDataContainer; @@ -2441,7 +2468,7 @@ void OfaAutoCompleteTabPage::CopyToClipboard() const rtl_TextEncoding nEncode = gsl_getSystemTextEncoding(); - for( USHORT n = 0; n < nSelCnt; ++n ) + for( sal_uInt16 n = 0; n < nSelCnt; ++n ) { sData += ByteString( aLBEntries.GetSelectEntry( n ), nEncode ); sData += pLineEnd; @@ -2491,7 +2518,7 @@ OfaSmartTagOptionsTabPage::OfaSmartTagOptionsTabPage( Window* pParent, FreeResource(); // some options for the list box: - m_aSmartTagTypesLB.SetWindowBits( m_aSmartTagTypesLB.GetStyle() | WB_HSCROLL | WB_HIDESELECTION ); + m_aSmartTagTypesLB.SetStyle( m_aSmartTagTypesLB.GetStyle() | WB_HSCROLL | WB_HIDESELECTION ); m_aSmartTagTypesLB.SetHighlightRange(); // set the handlers: @@ -2530,8 +2557,8 @@ struct ImplSmartTagLBUserData */ void OfaSmartTagOptionsTabPage::ClearListBox() { - const ULONG nCount = m_aSmartTagTypesLB.GetEntryCount(); - for ( USHORT i = 0; i < nCount; ++i ) + const sal_uLong nCount = m_aSmartTagTypesLB.GetEntryCount(); + for ( sal_uInt16 i = 0; i < nCount; ++i ) { const SvLBoxEntry* pEntry = m_aSmartTagTypesLB.GetEntry(i); const ImplSmartTagLBUserData* pUserData = static_cast< ImplSmartTagLBUserData* >(pEntry->GetUserData()); @@ -2589,7 +2616,7 @@ void OfaSmartTagOptionsTabPage::FillListBox( const SmartTagMgr& rSmartTagMgr ) */ IMPL_LINK( OfaSmartTagOptionsTabPage, ClickHdl, PushButton*, EMPTYARG ) { - const USHORT nPos = m_aSmartTagTypesLB.GetSelectEntryPos(); + const sal_uInt16 nPos = m_aSmartTagTypesLB.GetSelectEntryPos(); const SvLBoxEntry* pEntry = m_aSmartTagTypesLB.GetEntry(nPos); const ImplSmartTagLBUserData* pUserData = static_cast< ImplSmartTagLBUserData* >(pEntry->GetUserData()); uno::Reference< smarttags::XSmartTagRecognizer > xRec = pUserData->mxRec; @@ -2606,7 +2633,7 @@ IMPL_LINK( OfaSmartTagOptionsTabPage, ClickHdl, PushButton*, EMPTYARG ) */ IMPL_LINK( OfaSmartTagOptionsTabPage, CheckHdl, CheckBox*, EMPTYARG ) { - const BOOL bEnable = m_aMainCB.IsChecked(); + const sal_Bool bEnable = m_aMainCB.IsChecked(); m_aSmartTagTypesLB.Enable( bEnable ); m_aSmartTagTypesLB.Invalidate(); m_aPropertiesPB.Enable( false ); @@ -2628,7 +2655,7 @@ IMPL_LINK(OfaSmartTagOptionsTabPage, SelectHdl, SvxCheckListBox*, EMPTYARG) if ( m_aSmartTagTypesLB.GetEntryCount() < 1 ) return 0; - const USHORT nPos = m_aSmartTagTypesLB.GetSelectEntryPos(); + const sal_uInt16 nPos = m_aSmartTagTypesLB.GetSelectEntryPos(); const SvLBoxEntry* pEntry = m_aSmartTagTypesLB.GetEntry(nPos); const ImplSmartTagLBUserData* pUserData = static_cast< ImplSmartTagLBUserData* >(pEntry->GetUserData()); uno::Reference< smarttags::XSmartTagRecognizer > xRec = pUserData->mxRec; @@ -2645,7 +2672,7 @@ IMPL_LINK(OfaSmartTagOptionsTabPage, SelectHdl, SvxCheckListBox*, EMPTYARG) /** Propagates the current settings to the smart tag manager. */ -BOOL OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& ) +sal_Bool OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& ) { SvxAutoCorrect* pAutoCorrect = SvxAutoCorrCfg::Get()->GetAutoCorrect(); SvxSwAutoFmtFlags *pOpt = &pAutoCorrect->GetSwFlags(); @@ -2653,19 +2680,19 @@ BOOL OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& ) // robust! if ( !pSmartTagMgr ) - return FALSE; + return sal_False; - BOOL bModifiedSmartTagTypes = FALSE; + sal_Bool bModifiedSmartTagTypes = sal_False; std::vector< rtl::OUString > aDisabledSmartTagTypes; - const ULONG nCount = m_aSmartTagTypesLB.GetEntryCount(); + const sal_uLong nCount = m_aSmartTagTypesLB.GetEntryCount(); - for ( USHORT i = 0; i < nCount; ++i ) + for ( sal_uInt16 i = 0; i < nCount; ++i ) { const SvLBoxEntry* pEntry = m_aSmartTagTypesLB.GetEntry(i); const ImplSmartTagLBUserData* pUserData = static_cast< ImplSmartTagLBUserData* >(pEntry->GetUserData()); - const BOOL bChecked = m_aSmartTagTypesLB.IsChecked(i); - const BOOL bIsCurrentlyEnabled = pSmartTagMgr->IsSmartTagTypeEnabled( pUserData->maSmartTagType ); + const sal_Bool bChecked = m_aSmartTagTypesLB.IsChecked(i); + const sal_Bool bIsCurrentlyEnabled = pSmartTagMgr->IsSmartTagTypeEnabled( pUserData->maSmartTagType ); bModifiedSmartTagTypes = bModifiedSmartTagTypes || ( !bChecked != !bIsCurrentlyEnabled ); @@ -2675,7 +2702,7 @@ BOOL OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& ) delete pUserData; } - const BOOL bModifiedRecognize = ( !m_aMainCB.IsChecked() != !pSmartTagMgr->IsLabelTextWithSmartTags() ); + const sal_Bool bModifiedRecognize = ( !m_aMainCB.IsChecked() != !pSmartTagMgr->IsLabelTextWithSmartTags() ); if ( bModifiedSmartTagTypes || bModifiedRecognize ) { bool bLabelTextWithSmartTags = m_aMainCB.IsChecked() ? true : false; @@ -2683,7 +2710,7 @@ BOOL OfaSmartTagOptionsTabPage::FillItemSet( SfxItemSet& ) bModifiedSmartTagTypes ? &aDisabledSmartTagTypes : 0 ); } - return TRUE; + return sal_True; } /** Sets the controls based on the current settings at SmartTagMgr. @@ -2706,7 +2733,7 @@ void OfaSmartTagOptionsTabPage::Reset( const SfxItemSet& ) void OfaSmartTagOptionsTabPage::ActivatePage( const SfxItemSet& ) { - ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage( FALSE ); + ((OfaAutoCorrDlg*)GetTabDialog())->EnableLanguage( sal_False ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/cui/source/tabpages/autocdlg.hrc b/cui/source/tabpages/autocdlg.hrc index 7a747939b4d5..61ea73eb03de 100644 --- a/cui/source/tabpages/autocdlg.hrc +++ b/cui/source/tabpages/autocdlg.hrc @@ -155,6 +155,18 @@ #define FT_SMARTTAGS 221 #define LB_SMARTTAGS 222 #define PB_SMARTTAGS 223 +//IAccessibility2 Implementation 2009----- +#define STR_PB_NEWABBREV 224 +#define STR_PB_DELABBREV 225 +#define STR_PB_NEWDOUBLECAPS 226 +#define STR_PB_DELDOUBLECAPS 227 +#define STR_PB_SGL_STD 228 +#define STR_PB_DBL_STD 229 +#define STR_PB_SGL_START 230 +#define STR_PB_DBL_START 231 +#define STR_PB_SGL_END 232 +#define STR_PB_DBL_END 233 +//-----IAccessibility2 Implementation 2009 #endif diff --git a/cui/source/tabpages/autocdlg.src b/cui/source/tabpages/autocdlg.src index c863435f1476..e9b4769b8caf 100644 --- a/cui/source/tabpages/autocdlg.src +++ b/cui/source/tabpages/autocdlg.src @@ -177,6 +177,7 @@ TabPage RID_OFAPAGE_AUTOFMT_APPLY }; PushButton PB_EDIT { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOFMT_APPLY:PB_EDIT"; Pos = MAP_APPFONT ( 6 , 162 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Edit..." ; @@ -249,7 +250,7 @@ TabPage RID_OFAPAGE_AUTOFMT_APPLY ModalDialog RID_OFADLG_PRCNT_SET { - HelpID = SID_AUTOFORMAT ; + HelpID = CMD_SID_AUTOFORMAT ; OutputSize = TRUE ; SVLook = TRUE ; Size = MAP_APPFONT ( 155 , 43 ) ; @@ -275,6 +276,7 @@ ModalDialog RID_OFADLG_PRCNT_SET }; MetricField ED_RIGHT_MARGIN { + HelpID = "cui:MetricField:RID_OFADLG_PRCNT_SET:ED_RIGHT_MARGIN"; Border = TRUE ; Pos = MAP_APPFONT ( 7 , 14 ) ; Size = MAP_APPFONT ( 31 , 12 ) ; @@ -314,6 +316,7 @@ TabPage RID_OFAPAGE_AUTOCORR_REPLACE }; Edit ED_SHORT { + HelpID = "cui:Edit:RID_OFAPAGE_AUTOCORR_REPLACE:ED_SHORT"; Pos = MAP_APPFONT ( 7 , 13 ) ; Size = MAP_APPFONT ( 60 , 12 ) ; Border = TRUE ; @@ -328,6 +331,7 @@ TabPage RID_OFAPAGE_AUTOCORR_REPLACE }; Edit ED_REPLACE { + HelpID = "cui:Edit:RID_OFAPAGE_AUTOCORR_REPLACE:ED_REPLACE"; Pos = MAP_APPFONT ( 71 , 13 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; Border = TRUE ; @@ -335,6 +339,7 @@ TabPage RID_OFAPAGE_AUTOCORR_REPLACE }; CheckBox CB_TEXT_ONLY { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCORR_REPLACE:CB_TEXT_ONLY"; Pos = MAP_APPFONT ( 140 , 3 ) ; Size = MAP_APPFONT ( 108 , 10 ) ; TabStop = TRUE ; @@ -342,6 +347,7 @@ TabPage RID_OFAPAGE_AUTOCORR_REPLACE }; PushButton PB_NEW_REPLACE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_REPLACE:PB_NEW_REPLACE"; Pos = MAP_APPFONT ( 198 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -349,6 +355,7 @@ TabPage RID_OFAPAGE_AUTOCORR_REPLACE }; PushButton PB_DELETE_REPLACE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_REPLACE:PB_DELETE_REPLACE"; Pos = MAP_APPFONT ( 198 , 32 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -387,6 +394,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; Edit ED_ABBREV { + HelpID = "cui:Edit:RID_OFAPAGE_AUTOCORR_EXCEPT:ED_ABBREV"; Pos = MAP_APPFONT ( 7 , 14 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; TabStop = TRUE ; @@ -394,6 +402,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; ListBox LB_ABBREV { + HelpID = "cui:ListBox:RID_OFAPAGE_AUTOCORR_EXCEPT:LB_ABBREV"; Pos = MAP_APPFONT ( 7 , 30 ) ; Size = MAP_APPFONT ( 123 , 58 ) ; TabStop = TRUE ; @@ -403,6 +412,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; PushButton PB_NEWABBREV { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_EXCEPT:PB_NEWABBREV"; Pos = MAP_APPFONT ( 198 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -411,6 +421,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; PushButton PB_DELABBREV { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_EXCEPT:PB_DELABBREV"; Pos = MAP_APPFONT ( 198 , 31 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -419,6 +430,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; CheckBox CB_AUTOABBREV { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCORR_EXCEPT:CB_AUTOABBREV"; Pos = MAP_APPFONT ( 137 , 78 ) ; Size = MAP_APPFONT ( 111 , 10 ) ; Text [ en-US ] = "~AutoInclude"; @@ -433,6 +445,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; Edit ED_DOUBLE_CAPS { + HelpID = "cui:Edit:RID_OFAPAGE_AUTOCORR_EXCEPT:ED_DOUBLE_CAPS"; Pos = MAP_APPFONT ( 7 , 105 ) ; Size = MAP_APPFONT ( 123 , 12 ) ; TabStop = TRUE ; @@ -440,6 +453,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; ListBox LB_DOUBLE_CAPS { + HelpID = "cui:ListBox:RID_OFAPAGE_AUTOCORR_EXCEPT:LB_DOUBLE_CAPS"; Pos = MAP_APPFONT ( 7 , 120 ) ; Size = MAP_APPFONT ( 123 , 59 ) ; TabStop = TRUE ; @@ -449,6 +463,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; PushButton PB_NEWDOUBLECAPS { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_EXCEPT:PB_NEWDOUBLECAPS"; Pos = MAP_APPFONT ( 198 , 105 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Disable = TRUE ; @@ -456,6 +471,7 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; PushButton PB_DELDOUBLECAPS { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_EXCEPT:PB_DELDOUBLECAPS"; Pos = MAP_APPFONT ( 198 , 122 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Disable = TRUE ; @@ -463,11 +479,52 @@ TabPage RID_OFAPAGE_AUTOCORR_EXCEPT }; CheckBox CB_AUTOCAPS { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCORR_EXCEPT:CB_AUTOCAPS"; Pos = MAP_APPFONT ( 137 , 169 ) ; Size = MAP_APPFONT ( 111 , 10 ) ; Text [ en-US ] = "A~utoInclude"; Text [ en-US ] = "A~utoInclude" ; }; + String STR_PB_NEWABBREV + { + Text [ en-US ] = "New abbreviations" ; + }; + String STR_PB_DELABBREV + { + Text [ en-US ] = "Delete abbreviations" ; + }; + String STR_PB_NEWDOUBLECAPS + { + Text [ en-US ] = "New words with two initial capitals" ; + }; + String STR_PB_DELDOUBLECAPS + { + Text [ en-US ] = "Delete words with two initial capitals" ; + }; + String STR_PB_SGL_STD + { + Text [ en-US ] = "Single quotes default" ; + }; + String STR_PB_DBL_STD + { + Text [ en-US ] = "Double quotes default" ; + }; + String STR_PB_SGL_START + { + Text [ en-US ] = "Start quote of single quotes" ; + }; + String STR_PB_DBL_START + { + Text [ en-US ] = "Start quote of double quotes" ; + }; + String STR_PB_SGL_END + { + Text [ en-US ] = "End quote of single quotes" ; + }; + String STR_PB_DBL_END + { + Text [ en-US ] = "End quote of double quotes" ; + }; }; /**************************************************************************/ /* */ @@ -511,8 +568,9 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE Size = MAP_APPFONT ( 122 , 8 ) ; Text [ en-US ] = "Single quotes" ; }; - Checkbox CB_SGL_TYPO + CheckBox CB_SGL_TYPO { + HelpId = "cui:CheckBox:RID_OFAPAGE_AUTOCORR_QUOTE:CB_SGL_TYPO"; Pos = MAP_APPFONT ( 7 , 101 ) ; Size = MAP_APPFONT ( 86 , 10 ) ; Text [ en-US ] = "Repla~ce" ; @@ -525,6 +583,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_SGL_STARTQUOTE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_SGL_STARTQUOTE"; Pos = MAP_APPFONT ( 10 , 125 ) ; Size = MAP_APPFONT ( 12 , 12 ) ; Text = "\'" ; @@ -543,6 +602,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_SGL_ENDQUOTE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_SGL_ENDQUOTE"; Pos = MAP_APPFONT ( 10 , 151 ) ; Size = MAP_APPFONT ( 12 , 12 ) ; Text = "\'" ; @@ -555,6 +615,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_SGL_STD { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_SGL_STD"; Pos = MAP_APPFONT ( 7 , 167 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -568,6 +629,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; CheckBox CB_TYPO { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCORR_QUOTE:CB_TYPO"; Pos = MAP_APPFONT ( 137 , 101 ) ; Size = MAP_APPFONT ( 86 , 10 ) ; TabStop = TRUE ; @@ -581,6 +643,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_STARTQUOTE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_STARTQUOTE"; Pos = MAP_APPFONT ( 140 , 125 ) ; Size = MAP_APPFONT ( 12 , 12 ) ; Text = "\"" ; @@ -599,6 +662,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_ENDQUOTE { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_ENDQUOTE"; Pos = MAP_APPFONT ( 140 , 151 ) ; Size = MAP_APPFONT ( 12 , 12 ) ; Text = "\"" ; @@ -611,6 +675,7 @@ TabPage RID_OFAPAGE_AUTOCORR_QUOTE }; PushButton PB_DBL_STD { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCORR_QUOTE:PB_DBL_STD"; Pos = MAP_APPFONT ( 137 , 167 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; @@ -644,30 +709,35 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS Hide = TRUE ; CheckBox CB_ACTIV { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:CB_ACTIV"; Pos = MAP_APPFONT( 4, 3 ); Size = MAP_APPFONT( 116, 10 ); Text [ en-US ] = "Enable word ~completion"; }; CheckBox CB_APPEND_SPACE { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:CB_APPEND_SPACE"; Pos = MAP_APPFONT( 10, 17 ); Size = MAP_APPFONT( 110, 10 ); Text [ en-US ] = "~Append space"; }; CheckBox CB_AS_TIP { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:CB_AS_TIP"; Pos = MAP_APPFONT( 10, 31 ); Size = MAP_APPFONT( 110, 10 ); Text [ en-US ] = "~Show as tip"; }; CheckBox CB_COLLECT { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:CB_COLLECT"; Pos = MAP_APPFONT( 4, 45 ); Size = MAP_APPFONT( 116, 10 ); Text [ en-US ] = "C~ollect words"; }; CheckBox CB_REMOVE_LIST { + HelpID = "cui:CheckBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:CB_REMOVE_LIST"; Pos = MAP_APPFONT( 10, 59 ); Size = MAP_APPFONT( 110, 40 ); WordBreak = TRUE; @@ -681,6 +751,7 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS }; ListBox DCB_EXPAND_KEY { + HelpID = "cui:ListBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:DCB_EXPAND_KEY"; Pos = MAP_APPFONT( 4, 113 ); Size = MAP_APPFONT( 116, 60 ); TabStop = TRUE; @@ -696,6 +767,7 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS }; NumericField NF_MIN_WORDLEN { + HelpID = "cui:NumericField:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:NF_MIN_WORDLEN"; Border = TRUE; Pos = MAP_APPFONT( 4, 140 ); Size = MAP_APPFONT( 30, 12 ); @@ -718,6 +790,7 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS }; NumericField NF_MAX_ENTRIES { + HelpID = "cui:NumericField:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:NF_MAX_ENTRIES"; Border = TRUE; Pos = MAP_APPFONT( 4, 167 ); Size = MAP_APPFONT( 30, 12 ); @@ -734,6 +807,7 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS }; MultiListBox LB_ENTRIES { + HelpID = "cui:MultiListBox:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:LB_ENTRIES"; Pos = MAP_APPFONT( 127, 3 ); Size = MAP_APPFONT( 121, 158 ); TabStop = TRUE; @@ -744,6 +818,7 @@ TabPage RID_OFAPAGE_AUTOCOMPLETE_OPTIONS }; PushButton PB_ENTRIES { + HelpID = "cui:PushButton:RID_OFAPAGE_AUTOCOMPLETE_OPTIONS:PB_ENTRIES"; Pos = MAP_APPFONT( 127, 165 ); Size = MAP_APPFONT( 121, 14 ); TabStop = TRUE ; @@ -769,6 +844,7 @@ TabPage RID_OFAPAGE_SMARTTAG_OPTIONS CheckBox CB_SMARTTAGS { + HelpID = "cui:CheckBox:RID_OFAPAGE_SMARTTAG_OPTIONS:CB_SMARTTAGS"; Pos = MAP_APPFONT( 4, 3 ); Size = MAP_APPFONT( 116, 10 ); Text [ en-US ] = "Label text with smart tags"; @@ -791,6 +867,7 @@ TabPage RID_OFAPAGE_SMARTTAG_OPTIONS PushButton PB_SMARTTAGS { + HelpID = "cui:PushButton:RID_OFAPAGE_SMARTTAG_OPTIONS:PB_SMARTTAGS"; Pos = MAP_APPFONT ( 188 , 25 ) ; Size = MAP_APPFONT ( 60 , 14 ) ; Text [ en-US ] = "Properties..."; diff --git a/cui/source/tabpages/backgrnd.cxx b/cui/source/tabpages/backgrnd.cxx index 9225f1c4f679..409d53016e5d 100644 --- a/cui/source/tabpages/backgrnd.cxx +++ b/cui/source/tabpages/backgrnd.cxx @@ -67,7 +67,7 @@ using namespace ::com::sun::star; // static ---------------------------------------------------------------- -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_VIEW_FLD_PIC, SID_VIEW_FLD_PIC, SID_ATTR_BRUSH, SID_ATTR_BRUSH, @@ -80,10 +80,10 @@ struct SvxBackgroundTable_Impl SvxBrushItem* pCellBrush; SvxBrushItem* pRowBrush; SvxBrushItem* pTableBrush; - USHORT nCellWhich; - USHORT nRowWhich; - USHORT nTableWhich; - USHORT nActPos; + sal_uInt16 nCellWhich; + sal_uInt16 nRowWhich; + sal_uInt16 nTableWhich; + sal_uInt16 nActPos; SvxBackgroundTable_Impl() : pCellBrush(NULL), pRowBrush(NULL), pTableBrush(NULL), @@ -95,7 +95,7 @@ struct SvxBackgroundPara_Impl SvxBrushItem* pParaBrush; SvxBrushItem* pCharBrush; - USHORT nActPos; + sal_uInt16 nActPos; SvxBackgroundPara_Impl() : pParaBrush(NULL), pCharBrush(NULL) {} @@ -104,18 +104,18 @@ struct SvxBackgroundPara_Impl struct SvxBackgroundPage_Impl { Timer* pLoadTimer; - BOOL bIsImportDlgInExecute; + sal_Bool bIsImportDlgInExecute; SvxBackgroundPage_Impl() : - pLoadTimer(NULL), bIsImportDlgInExecute(FALSE) {} + pLoadTimer(NULL), bIsImportDlgInExecute(sal_False) {} }; -inline BYTE lcl_PercentToTransparency(long nPercent) +inline sal_uInt8 lcl_PercentToTransparency(long nPercent) { //0xff must not be returned! - return BYTE(nPercent ? (50 + 0xfe * nPercent) / 100 : 0); + return sal_uInt8(nPercent ? (50 + 0xfe * nPercent) / 100 : 0); } -inline BYTE lcl_TransparencyToPercent(BYTE nTrans) +inline sal_uInt8 lcl_TransparencyToPercent(sal_uInt8 nTrans) { return (nTrans * 100 + 127) / 254; } @@ -127,11 +127,11 @@ void lcl_SetTransparency(SvxBrushItem& rBrush, long nTransparency) } //------------------------------------------------------------------------- -USHORT GetItemId_Impl( ValueSet& rValueSet, const Color& rCol ) +sal_uInt16 GetItemId_Impl( ValueSet& rValueSet, const Color& rCol ) { - BOOL bFound = FALSE; - USHORT nCount = rValueSet.GetItemCount(); - USHORT n = 1; + sal_Bool bFound = sal_False; + sal_uInt16 nCount = rValueSet.GetItemCount(); + sal_uInt16 n = 1; while ( !bFound && n <= nCount ) { @@ -158,7 +158,7 @@ class BackgroundPreviewImpl : public Window { public: BackgroundPreviewImpl( Window* pParent, - const ResId& rResId, BOOL bIsBmpPreview ); + const ResId& rResId, sal_Bool bIsBmpPreview ); ~BackgroundPreviewImpl(); void NotifyChange( const Color& rColor ); @@ -169,12 +169,12 @@ protected: virtual void DataChanged( const DataChangedEvent& rDCEvt ); private: - const BOOL bIsBmp; + const sal_Bool bIsBmp; Bitmap* pBitmap; Point aDrawPos; Size aDrawSize; Rectangle aDrawRect; - BYTE nTransparency; + sal_uInt8 nTransparency; }; //----------------------------------------------------------------------- @@ -183,7 +183,7 @@ BackgroundPreviewImpl::BackgroundPreviewImpl ( Window* pParent, const ResId& rResId, - BOOL bIsBmpPreview + sal_Bool bIsBmpPreview ) : Window( pParent, rResId ), @@ -315,41 +315,43 @@ SvxBackgroundTabPage::SvxBackgroundTabPage( Window* pParent, SvxTabPage( pParent, CUI_RES( RID_SVXPAGE_BACKGROUND ), rCoreSet ), + aSelectTxt ( this, CUI_RES( FT_SELECTOR ) ), + aLbSelect ( this, CUI_RES( LB_SELECTOR ) ), + aStrBrowse ( CUI_RES( STR_BROWSE ) ), + aStrUnlinked ( CUI_RES( STR_UNLINKED ) ), + aTblDesc ( this, CUI_RES( FT_TBL_DESC ) ), + aTblLBox ( this, CUI_RES( LB_TBL_BOX ) ), + aParaLBox ( this, CUI_RES( LB_PARA_BOX ) ), + aBorderWin ( this, CUI_RES(CT_BORDER) ), aBackgroundColorSet ( &aBorderWin, CUI_RES( SET_BGDCOLOR ) ), aBackgroundColorBox ( this, CUI_RES( GB_BGDCOLOR ) ), - pPreviewWin1 ( new BackgroundPreviewImpl( - this, CUI_RES( WIN_PREVIEW1 ), FALSE ) ), + pPreviewWin1 ( new BackgroundPreviewImpl( this, CUI_RES( WIN_PREVIEW1 ), sal_False ) ), + aColTransFT ( this, CUI_RES( FT_COL_TRANS ) ), aColTransMF ( this, CUI_RES( MF_COL_TRANS ) ), - aBtnBrowse ( this, CUI_RES( BTN_BROWSE ) ), - aBtnLink ( this, CUI_RES( BTN_LINK ) ), aBtnPreview ( this, CUI_RES( BTN_PREVIEW ) ), - aFtFile ( this, CUI_RES( FT_FILE ) ), aGbFile ( this, CUI_RES( GB_FILE ) ), + aBtnBrowse ( this, CUI_RES( BTN_BROWSE ) ), + aBtnLink ( this, CUI_RES( BTN_LINK ) ), + aGbPosition ( this, CUI_RES( GB_POSITION ) ), aBtnPosition ( this, CUI_RES( BTN_POSITION ) ), aBtnArea ( this, CUI_RES( BTN_AREA ) ), aBtnTile ( this, CUI_RES( BTN_TILE ) ), aWndPosition ( this, CUI_RES( WND_POSITION ), RP_MM ), - aGbPosition ( this, CUI_RES( GB_POSITION ) ), + aFtFile ( this, CUI_RES( FT_FILE ) ), aGraphTransFL ( this, CUI_RES( FL_GRAPH_TRANS ) ), aGraphTransMF ( this, CUI_RES( MF_GRAPH_TRANS ) ), pPreviewWin2 ( new BackgroundPreviewImpl( - this, CUI_RES( WIN_PREVIEW2 ), TRUE ) ), - aSelectTxt ( this, CUI_RES( FT_SELECTOR ) ), - aLbSelect ( this, CUI_RES( LB_SELECTOR ) ), - aStrBrowse ( CUI_RES( STR_BROWSE ) ), - aStrUnlinked ( CUI_RES( STR_UNLINKED ) ), - aTblDesc ( this, CUI_RES( FT_TBL_DESC ) ), - aTblLBox ( this, CUI_RES( LB_TBL_BOX ) ), - aParaLBox ( this, CUI_RES( LB_PARA_BOX ) ), + this, CUI_RES( WIN_PREVIEW2 ), sal_True ) ), + nHtmlMode ( 0 ), - bAllowShowSelector ( TRUE ), - bIsGraphicValid ( FALSE ), - bLinkOnly ( FALSE ), - bResized ( FALSE ), - bColTransparency ( FALSE ), - bGraphTransparency ( FALSE ), + bAllowShowSelector ( sal_True ), + bIsGraphicValid ( sal_False ), + bLinkOnly ( sal_False ), + bResized ( sal_False ), + bColTransparency ( sal_False ), + bGraphTransparency ( sal_False ), pPageImpl ( new SvxBackgroundPage_Impl ), pImportDlg ( NULL ), @@ -363,7 +365,7 @@ SvxBackgroundTabPage::SvxBackgroundTabPage( Window* pParent, const SfxPoolItem* pItem; SfxObjectShell* pShell; - if ( SFX_ITEM_SET == rCoreSet.GetItemState( SID_HTML_MODE, FALSE, &pItem ) + if ( SFX_ITEM_SET == rCoreSet.GetItemState( SID_HTML_MODE, sal_False, &pItem ) || ( 0 != ( pShell = SfxObjectShell::Current()) && 0 != ( pItem = pShell->GetItem( SID_HTML_MODE ) ) ) ) { @@ -374,6 +376,11 @@ SvxBackgroundTabPage::SvxBackgroundTabPage( Window* pParent, aBackgroundColorSet.SetSelectHdl( HDL(BackgroundColorHdl_Impl) ); FreeResource(); + + aBtnBrowse.SetAccessibleRelationMemberOf(&aGbFile); + aWndPosition.SetAccessibleRelationMemberOf(&aGbPosition); + aWndPosition.SetAccessibleRelationLabeledBy(&aBtnPosition); + aBackgroundColorSet.SetAccessibleRelationLabeledBy(&aBackgroundColorBox); } //------------------------------------------------------------------------ @@ -404,7 +411,7 @@ SvxBackgroundTabPage::~SvxBackgroundTabPage() //------------------------------------------------------------------------ -USHORT* SvxBackgroundTabPage::GetRanges() +sal_uInt16* SvxBackgroundTabPage::GetRanges() /* [Beschreibung] @@ -437,7 +444,7 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) // es muss aber im rSet vorhanden sein! // const SfxPoolItem* pX = GetOldItem( rSet, SID_VIEW_FLD_PIC ); // if( pX && pX->ISA(SfxWallpaperItem)) - if(SFX_ITEM_AVAILABLE <= rSet.GetItemState(GetWhich(SID_VIEW_FLD_PIC), FALSE)) + if(SFX_ITEM_AVAILABLE <= rSet.GetItemState(GetWhich(SID_VIEW_FLD_PIC), sal_False)) { ResetFromWallpaperItem( rSet ); return; @@ -448,17 +455,17 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) aBtnPreview.Check( aUserData.Len() && sal_Unicode('1') == aUserData.GetChar( 0 ) ); // nach Reset kein ShowSelector() mehr aufrufen d"urfen - bAllowShowSelector = FALSE; + bAllowShowSelector = sal_False; // Input-BrushItem besorgen und auswerten const SvxBrushItem* pBgdAttr = NULL; - USHORT nSlot = SID_ATTR_BRUSH; + sal_uInt16 nSlot = SID_ATTR_BRUSH; const SfxPoolItem* pItem; - USHORT nDestValue = USHRT_MAX; + sal_uInt16 nDestValue = USHRT_MAX; if ( SFX_ITEM_SET == rSet.GetItemState( SID_BACKGRND_DESTINATION, - FALSE, &pItem ) ) + sal_False, &pItem ) ) { nDestValue = ((const SfxUInt16Item*)pItem)->GetValue(); aTblLBox.SelectEntryPos(nDestValue); @@ -477,11 +484,11 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) } } else if( SFX_ITEM_SET == rSet.GetItemState( - SID_PARA_BACKGRND_DESTINATION, FALSE, &pItem ) ) + SID_PARA_BACKGRND_DESTINATION, sal_False, &pItem ) ) { nDestValue = ((const SfxUInt16Item*)pItem)->GetValue(); // ist gerade Zeichen aktiviert? - USHORT nParaSel = aParaLBox.GetSelectEntryPos(); + sal_uInt16 nParaSel = aParaLBox.GetSelectEntryPos(); if(1 == nParaSel) { // dann war das ein "Standard" - Aufruf @@ -502,9 +509,9 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) //#111173# the destination item is missing when the parent style has been changed if(USHRT_MAX == nDestValue && (aParaLBox.IsVisible()||aTblLBox.IsVisible())) nDestValue = 0; - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nWhich = GetWhich( nSlot ); - if ( rSet.GetItemState( nWhich, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_False ) >= SFX_ITEM_AVAILABLE ) pBgdAttr = (const SvxBrushItem*)&( rSet.Get( nWhich ) ); aBtnTile.Check(); @@ -531,7 +538,7 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) { if(aTblLBox.IsVisible()) { - USHORT nValue = aTblLBox.GetSelectEntryPos(); + sal_uInt16 nValue = aTblLBox.GetSelectEntryPos(); if ( pTableBck_Impl ) { @@ -545,21 +552,21 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) pTableBck_Impl->nActPos = nValue; nWhich = GetWhich( SID_ATTR_BRUSH ); - if ( rSet.GetItemState( nWhich, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_False ) >= SFX_ITEM_AVAILABLE ) { pBgdAttr = (const SvxBrushItem*)&( rSet.Get( nWhich ) ); pTableBck_Impl->pCellBrush = new SvxBrushItem(*pBgdAttr); } pTableBck_Impl->nCellWhich = nWhich; - if ( rSet.GetItemState( SID_ATTR_BRUSH_ROW, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( SID_ATTR_BRUSH_ROW, sal_False ) >= SFX_ITEM_AVAILABLE ) { pBgdAttr = (const SvxBrushItem*)&( rSet.Get( SID_ATTR_BRUSH_ROW ) ); pTableBck_Impl->pRowBrush = new SvxBrushItem(*pBgdAttr); } pTableBck_Impl->nRowWhich = SID_ATTR_BRUSH_ROW; - if ( rSet.GetItemState( SID_ATTR_BRUSH_TABLE, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( SID_ATTR_BRUSH_TABLE, sal_False ) >= SFX_ITEM_AVAILABLE ) { pBgdAttr = (const SvxBrushItem*)&( rSet.Get( SID_ATTR_BRUSH_TABLE ) ); pTableBck_Impl->pTableBrush = new SvxBrushItem(*pBgdAttr); @@ -571,7 +578,7 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) } else { - USHORT nValue = aParaLBox.GetSelectEntryPos(); + sal_uInt16 nValue = aParaLBox.GetSelectEntryPos(); if ( pParaBck_Impl ) { @@ -584,16 +591,16 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) pParaBck_Impl->nActPos = nValue; nWhich = GetWhich( SID_ATTR_BRUSH ); - if ( rSet.GetItemState( nWhich, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_False ) >= SFX_ITEM_AVAILABLE ) { pBgdAttr = (const SvxBrushItem*)&( rSet.Get( nWhich ) ); pParaBck_Impl->pParaBrush = new SvxBrushItem(*pBgdAttr); } nWhich = GetWhich( SID_ATTR_BRUSH_CHAR ); - rSet.GetItemState( nWhich, TRUE ); - rSet.GetItemState( nWhich, FALSE ); - if ( rSet.GetItemState( nWhich, TRUE ) > SFX_ITEM_AVAILABLE ) + rSet.GetItemState( nWhich, sal_True ); + rSet.GetItemState( nWhich, sal_False ); + if ( rSet.GetItemState( nWhich, sal_True ) > SFX_ITEM_AVAILABLE ) { pBgdAttr = (const SvxBrushItem*)&( rSet.Get( nWhich ) ); pParaBck_Impl->pCharBrush = new SvxBrushItem(*pBgdAttr); @@ -619,6 +626,7 @@ void SvxBackgroundTabPage::Reset( const SfxItemSet& rSet ) aPos.Y() = nY; pPreviewWin1->SetPosPixel(aPos); aBackgroundColorBox.Hide(); + aBackgroundColorSet.SetAccessibleRelationLabeledBy(&aBackgroundColorSet); } } } @@ -633,12 +641,12 @@ void SvxBackgroundTabPage::ResetFromWallpaperItem( const SfxItemSet& rSet ) // Input-BrushItem besorgen und auswerten const SvxBrushItem* pBgdAttr = NULL; - USHORT nSlot = SID_VIEW_FLD_PIC; - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nSlot = SID_VIEW_FLD_PIC; + sal_uInt16 nWhich = GetWhich( nSlot ); SvxBrushItem* pTemp = 0; const CntWallpaperItem* pItem = 0; - if ( rSet.GetItemState( nWhich, FALSE ) >= SFX_ITEM_AVAILABLE ) + if ( rSet.GetItemState( nWhich, sal_False ) >= SFX_ITEM_AVAILABLE ) { pItem = (const CntWallpaperItem*)&rSet.Get( nWhich ); pTemp = new SvxBrushItem( *pItem, nWhich ); @@ -654,7 +662,7 @@ void SvxBackgroundTabPage::ResetFromWallpaperItem( const SfxItemSet& rSet ) if( aBgdColor != pBgdAttr->GetColor() ) { aBgdColor = pBgdAttr->GetColor(); - USHORT nCol = GetItemId_Impl( aBackgroundColorSet, aBgdColor ); + sal_uInt16 nCol = GetItemId_Impl( aBackgroundColorSet, aBgdColor ); aBackgroundColorSet.SelectItem( nCol ); pPreviewWin1->NotifyChange( aBgdColor ); } @@ -670,10 +678,10 @@ void SvxBackgroundTabPage::ResetFromWallpaperItem( const SfxItemSet& rSet ) } // We now have always a link to the background - bLinkOnly = TRUE; - aBtnLink.Check( TRUE ); - aBtnLink.Show( FALSE ); -// if( !pItem || !pItem->GetWallpaper(FALSE).IsBitmap() ) + bLinkOnly = sal_True; + aBtnLink.Check( sal_True ); + aBtnLink.Show( sal_False ); +// if( !pItem || !pItem->GetWallpaper(sal_False).IsBitmap() ) // aBtnLink.Check(); delete pTemp; @@ -699,7 +707,7 @@ void SvxBackgroundTabPage::FillUserData() //------------------------------------------------------------------------ -BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) +sal_Bool SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) { if ( pPageImpl->pLoadTimer && pPageImpl->pLoadTimer->IsActive() ) { @@ -711,11 +719,11 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) // const SfxPoolItem* pX = GetOldItem( rCoreSet, SID_VIEW_FLD_PIC ); // if( pX && pX->ISA(SfxWallpaperItem)) - if(SFX_ITEM_AVAILABLE <= rCoreSet.GetItemState(GetWhich(SID_VIEW_FLD_PIC), FALSE)) + if(SFX_ITEM_AVAILABLE <= rCoreSet.GetItemState(GetWhich(SID_VIEW_FLD_PIC), sal_False)) return FillItemSetWithWallpaperItem( rCoreSet, SID_VIEW_FLD_PIC ); - BOOL bModified = FALSE; - USHORT nSlot = SID_ATTR_BRUSH; + sal_Bool bModified = sal_False; + sal_uInt16 nSlot = SID_ATTR_BRUSH; if ( aTblLBox.IsVisible() ) { @@ -744,18 +752,18 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) break; } } - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nWhich = GetWhich( nSlot ); const SfxPoolItem* pOld = GetOldItem( rCoreSet, nSlot ); - SfxItemState eOldItemState = rCoreSet.GetItemState(nSlot, FALSE); + SfxItemState eOldItemState = rCoreSet.GetItemState(nSlot, sal_False); const SfxItemSet& rOldSet = GetItemSet(); - BOOL bGraphTransparencyChanged = bGraphTransparency && (aGraphTransMF.GetText() != aGraphTransMF.GetSavedValue()); + sal_Bool bGraphTransparencyChanged = bGraphTransparency && (aGraphTransMF.GetText() != aGraphTransMF.GetSavedValue()); if ( pOld ) { const SvxBrushItem& rOldItem = (const SvxBrushItem&)*pOld; SvxGraphicPosition eOldPos = rOldItem.GetGraphicPos(); - const BOOL bIsBrush = ( 0 == aLbSelect.GetSelectEntryPos() ); + const sal_Bool bIsBrush = ( 0 == aLbSelect.GetSelectEntryPos() ); // transparency has to be set if enabled, the color not already set to "No fill" and if( bColTransparency && @@ -774,10 +782,10 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) if ( rOldItem.GetColor() != aBgdColor || (SFX_ITEM_AVAILABLE >= eOldItemState && !aBackgroundColorSet.IsNoSelection())) { - bModified = TRUE; + bModified = sal_True; rCoreSet.Put( SvxBrushItem( aBgdColor, nWhich ) ); } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) rCoreSet.ClearItem( nWhich ); } else @@ -785,8 +793,8 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) // Bitmap-Behandlung: SvxGraphicPosition eNewPos = GetGraphicPosition_Impl(); - const BOOL bIsLink = aBtnLink.IsChecked(); - const BOOL bWasLink = (NULL != rOldItem.GetGraphicLink() ); + const sal_Bool bIsLink = aBtnLink.IsChecked(); + const sal_Bool bWasLink = (NULL != rOldItem.GetGraphicLink() ); if ( !bIsLink && !bIsGraphicValid ) @@ -801,7 +809,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) != aBgdGraphic.GetBitmap() ) ) { - bModified = TRUE; + bModified = sal_True; SvxBrushItem aTmpBrush(nWhich); if ( bIsLink ) @@ -819,7 +827,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) rCoreSet.Put(aTmpBrush); } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) rCoreSet.ClearItem( nWhich ); } } @@ -860,7 +868,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) else if ( SID_ATTR_BRUSH_CHAR == nSlot && aBgdColor != Color( COL_WHITE ) ) { rCoreSet.Put( SvxBrushItem( aBgdColor, nWhich ) ); - bModified = TRUE; + bModified = sal_True; } if( aTblLBox.IsVisible() ) @@ -874,7 +882,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) if ( *pTableBck_Impl->pCellBrush != *pOldCell ) { rCoreSet.Put( *pTableBck_Impl->pCellBrush ); - bModified |= TRUE; + bModified |= sal_True; } } @@ -886,7 +894,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) if ( *pTableBck_Impl->pRowBrush != *pOldRow ) { rCoreSet.Put( *pTableBck_Impl->pRowBrush ); - bModified |= TRUE; + bModified |= sal_True; } } @@ -898,7 +906,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) if ( *pTableBck_Impl->pTableBrush != *pOldTable ) { rCoreSet.Put( *pTableBck_Impl->pTableBrush ); - bModified |= TRUE; + bModified |= sal_True; } } @@ -906,7 +914,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) { rCoreSet.Put( SfxUInt16Item( SID_BACKGRND_DESTINATION, aTblLBox.GetSelectEntryPos() ) ); - bModified |= TRUE; + bModified |= sal_True; } } else if(aParaLBox.GetData() == &aParaLBox) @@ -920,7 +928,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) if ( *pParaBck_Impl->pParaBrush != *pOldPara ) { rCoreSet.Put( *pParaBck_Impl->pParaBrush ); - bModified |= TRUE; + bModified |= sal_True; } } @@ -936,7 +944,7 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) *pParaBck_Impl->pCharBrush != SvxBrushItem(SID_ATTR_BRUSH_CHAR))) { rCoreSet.Put( *pParaBck_Impl->pCharBrush ); - bModified |= TRUE; + bModified |= sal_True; } } @@ -944,23 +952,23 @@ BOOL SvxBackgroundTabPage::FillItemSet( SfxItemSet& rCoreSet ) { rCoreSet.Put( SfxUInt16Item( SID_BACKGRND_DESTINATION, aParaLBox.GetSelectEntryPos() ) ); - bModified |= TRUE; + bModified |= sal_True; } } return bModified; } -BOOL SvxBackgroundTabPage::FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, USHORT nSlot) +sal_Bool SvxBackgroundTabPage::FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, sal_uInt16 nSlot) { - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nWhich = GetWhich( nSlot ); const SfxPoolItem* pOld = GetOldItem( rCoreSet, nSlot ); const SfxItemSet& rOldSet = GetItemSet(); DBG_ASSERT(pOld,"FillItemSetWithWallpaperItem: Item not found"); SvxBrushItem rOldItem( (const CntWallpaperItem&)*pOld, nWhich ); SvxGraphicPosition eOldPos = rOldItem.GetGraphicPos(); - const BOOL bIsBrush = ( 0 == aLbSelect.GetSelectEntryPos() ); - BOOL bModified = FALSE; + const sal_Bool bIsBrush = ( 0 == aLbSelect.GetSelectEntryPos() ); + sal_Bool bModified = sal_False; if ( ( (GPOS_NONE == eOldPos) && bIsBrush ) || ( (GPOS_NONE != eOldPos) && !bIsBrush ) ) // Brush <-> Bitmap gewechselt? @@ -972,12 +980,12 @@ BOOL SvxBackgroundTabPage::FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, U // Brush-Behandlung: if ( rOldItem.GetColor() != aBgdColor ) { - bModified = TRUE; + bModified = sal_True; CntWallpaperItem aItem( nWhich ); aItem.SetColor( aBgdColor ); rCoreSet.Put( aItem ); } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) rCoreSet.ClearItem( nWhich ); } else @@ -990,16 +998,16 @@ BOOL SvxBackgroundTabPage::FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, U int bBrushChanged = ( rOldItem.GetColor() != aBgdColor ); if( bBitmapChanged || bBrushChanged ) { - bModified = TRUE; + bModified = sal_True; CntWallpaperItem aItem( nWhich ); WallpaperStyle eWallStyle = SvxBrushItem::GraphicPos2WallpaperStyle(eNewPos); - aItem.SetStyle( sal::static_int_cast< USHORT >( eWallStyle ) ); + aItem.SetStyle( sal::static_int_cast< sal_uInt16 >( eWallStyle ) ); aItem.SetColor( aBgdColor ); aItem.SetBitmapURL( aBgdGraphicPath ); rCoreSet.Put( aItem ); } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) rCoreSet.ClearItem( nWhich ); } } @@ -1015,13 +1023,13 @@ BOOL SvxBackgroundTabPage::FillItemSetWithWallpaperItem( SfxItemSet& rCoreSet, U { WallpaperStyle eWallStyle = SvxBrushItem::GraphicPos2WallpaperStyle( GetGraphicPosition_Impl() ); - aItem.SetStyle( sal::static_int_cast< USHORT >( eWallStyle ) ); + aItem.SetStyle( sal::static_int_cast< sal_uInt16 >( eWallStyle ) ); aItem.SetColor( aBgdColor ); aItem.SetBitmapURL( aBgdGraphicPath ); rCoreSet.Put( aItem ); } - bModified = TRUE; + bModified = sal_True; } return bModified; } @@ -1074,13 +1082,13 @@ void SvxBackgroundTabPage::ShowSelector() pPageImpl->pLoadTimer->SetTimeoutHdl( LINK( this, SvxBackgroundTabPage, LoadTimerHdl_Impl ) ); - bAllowShowSelector = FALSE; + bAllowShowSelector = sal_False; if(nHtmlMode & HTMLMODE_ON) { if(!(nHtmlMode & HTMLMODE_GRAPH_POS)) - aBtnPosition.Enable(FALSE); - aBtnArea.Enable(FALSE); + aBtnPosition.Enable(sal_False); + aBtnArea.Enable(sal_False); } } } @@ -1103,9 +1111,9 @@ void SvxBackgroundTabPage::RaiseLoadError_Impl() //------------------------------------------------------------------------ -BOOL SvxBackgroundTabPage::LoadLinkedGraphic_Impl() +sal_Bool SvxBackgroundTabPage::LoadLinkedGraphic_Impl() { - BOOL bResult = ( aBgdGraphicPath.Len() > 0 ) && + sal_Bool bResult = ( aBgdGraphicPath.Len() > 0 ) && ( GRFILTER_OK == GraphicFilter::LoadGraphic( aBgdGraphicPath, aBgdGraphicFilter, aBgdGraphic ) ); @@ -1134,7 +1142,7 @@ void SvxBackgroundTabPage::FillColorValueSets_Impl() if ( !pColorTable ) { - bOwn = TRUE; + bOwn = sal_True; pColorTable = new XColorTable( SvtPathOptions().GetPalettePath() ); } @@ -1148,6 +1156,7 @@ void SvxBackgroundTabPage::FillColorValueSets_Impl() WinBits nBits = ( aBackgroundColorSet.GetStyle() | WB_ITEMBORDER | WB_NAMEFIELD | WB_NONEFIELD ); aBackgroundColorSet.SetText( SVX_RESSTR( RID_SVXSTR_TRANSPARENT ) ); aBackgroundColorSet.SetStyle( nBits ); + aBackgroundColorSet.SetAccessibleName(aBackgroundColorBox.GetText()); for ( i = 0; i < nCount; i++ ) { pEntry = pColorTable->GetColor(i); @@ -1207,8 +1216,8 @@ void SvxBackgroundTabPage::ShowColorUI_Impl() aWndPosition.Hide(); aGbPosition.Hide(); pPreviewWin2->Hide(); - aGraphTransFL.Show(FALSE); - aGraphTransMF.Show(FALSE); + aGraphTransFL.Show(sal_False); + aGraphTransMF.Show(sal_False); if(bColTransparency) { aColTransFT.Show(); @@ -1255,8 +1264,8 @@ void SvxBackgroundTabPage::ShowBitmapUI_Impl() aGraphTransFL.Show(); aGraphTransMF.Show(); } - aColTransFT.Show(FALSE); - aColTransMF.Show(FALSE); + aColTransFT.Show(sal_False); + aColTransMF.Show(sal_False); } } @@ -1353,11 +1362,11 @@ IMPL_LINK( SvxBackgroundTabPage, BackgroundColorHdl_Impl, ValueSet*, EMPTYARG ) Handler, called when color selection is changed */ { - USHORT nItemId = aBackgroundColorSet.GetSelectItemId(); + sal_uInt16 nItemId = aBackgroundColorSet.GetSelectItemId(); Color aColor = nItemId ? ( aBackgroundColorSet.GetItemColor( nItemId ) ) : Color( COL_TRANSPARENT ); aBgdColor = aColor; pPreviewWin1->NotifyChange( aBgdColor ); - BOOL bEnableTransp = aBgdColor.GetTransparency() < 0xff; + sal_Bool bEnableTransp = aBgdColor.GetTransparency() < 0xff; aColTransFT.Enable(bEnableTransp); aColTransMF.Enable(bEnableTransp); return 0; @@ -1375,7 +1384,7 @@ IMPL_LINK( SvxBackgroundTabPage, SelectHdl_Impl, ListBox*, EMPTYARG ) else { ShowBitmapUI_Impl(); - aParaLBox.Enable(FALSE);// Zeichenhintergrund kann keine Bitmap sein + aParaLBox.Enable(sal_False);// Zeichenhintergrund kann keine Bitmap sein } return 0; } @@ -1457,16 +1466,16 @@ IMPL_LINK( SvxBackgroundTabPage, BrowseHdl_Impl, PushButton* , EMPTYARG ) { if ( pPageImpl->pLoadTimer->IsActive() ) return 0; - BOOL bHtml = 0 != ( nHtmlMode & HTMLMODE_ON ); + sal_Bool bHtml = 0 != ( nHtmlMode & HTMLMODE_ON ); pImportDlg = new SvxOpenGraphicDialog( aStrBrowse ); if ( bHtml || bLinkOnly ) pImportDlg->EnableLink(sal_False); pImportDlg->SetPath( aBgdGraphicPath, aBtnLink.IsChecked() ); - pPageImpl->bIsImportDlgInExecute = TRUE; + pPageImpl->bIsImportDlgInExecute = sal_True; short nErr = pImportDlg->Execute(); - pPageImpl->bIsImportDlgInExecute = FALSE; + pPageImpl->bIsImportDlgInExecute = sal_False; if( !nErr ) { @@ -1476,7 +1485,7 @@ IMPL_LINK( SvxBackgroundTabPage, BrowseHdl_Impl, PushButton* , EMPTYARG ) // dann die Vorschau aktivieren, damit der Anwender sieht, // welche Grafik er ausgew"ahlt hat if ( !aBtnLink.IsChecked() && !aBtnPreview.IsChecked() ) - aBtnPreview.Check( TRUE ); + aBtnPreview.Check( sal_True ); // timer-verz"ogertes Laden der Grafik pPageImpl->pLoadTimer->Start(); } @@ -1510,7 +1519,7 @@ IMPL_LINK( SvxBackgroundTabPage, LoadTimerHdl_Impl, Timer* , pTimer ) // neue Datei gew"ahlt aBgdGraphicPath = pImportDlg->GetPath(); aBgdGraphicFilter = pImportDlg->GetCurrentFilter(); - BOOL bLink = ( nHtmlMode & HTMLMODE_ON ) || bLinkOnly ? TRUE : pImportDlg->IsAsLink(); + sal_Bool bLink = ( nHtmlMode & HTMLMODE_ON ) || bLinkOnly ? sal_True : pImportDlg->IsAsLink(); aBtnLink.Check( bLink ); aBtnLink.Enable(); @@ -1518,17 +1527,17 @@ IMPL_LINK( SvxBackgroundTabPage, LoadTimerHdl_Impl, Timer* , pTimer ) { if( !pImportDlg->GetGraphic(aBgdGraphic) ) { - bIsGraphicValid = TRUE; + bIsGraphicValid = sal_True; } else { aBgdGraphicFilter.Erase(); aBgdGraphicPath.Erase(); - bIsGraphicValid = FALSE; + bIsGraphicValid = sal_False; } } else - bIsGraphicValid = FALSE; // Grafik erst beim Preview-Click laden + bIsGraphicValid = sal_False; // Grafik erst beim Preview-Click laden if ( aBtnPreview.IsChecked() && bIsGraphicValid ) { @@ -1558,7 +1567,7 @@ void SvxBackgroundTabPage::ShowTblControl() //----------------------------------------------------------------------- -void SvxBackgroundTabPage::ShowParaControl(BOOL bCharOnly) +void SvxBackgroundTabPage::ShowParaControl(sal_Bool bCharOnly) { aParaLBox.SetSelectHdl(HDL(ParaDestinationHdl_Impl)); aParaLBox.SelectEntryPos(0); @@ -1573,11 +1582,11 @@ void SvxBackgroundTabPage::ShowParaControl(BOOL bCharOnly) IMPL_LINK( SvxBackgroundTabPage, TblDestinationHdl_Impl, ListBox*, pBox ) { - USHORT nSelPos = pBox->GetSelectEntryPos(); + sal_uInt16 nSelPos = pBox->GetSelectEntryPos(); if( pTableBck_Impl && pTableBck_Impl->nActPos != nSelPos) { SvxBrushItem** pActItem = new (SvxBrushItem*); - USHORT nWhich = 0; + sal_uInt16 nWhich = 0; switch(pTableBck_Impl->nActPos) { case TBL_DEST_CELL: @@ -1603,7 +1612,7 @@ IMPL_LINK( SvxBackgroundTabPage, TblDestinationHdl_Impl, ListBox*, pBox ) else { SvxGraphicPosition eNewPos = GetGraphicPosition_Impl(); - const BOOL bIsLink = aBtnLink.IsChecked(); + const sal_Bool bIsLink = aBtnLink.IsChecked(); if ( !bIsLink && !bIsGraphicValid ) bIsGraphicValid = LoadLinkedGraphic_Impl(); @@ -1652,7 +1661,7 @@ IMPL_LINK( SvxBackgroundTabPage, TblDestinationHdl_Impl, ListBox*, pBox ) IMPL_LINK( SvxBackgroundTabPage, ParaDestinationHdl_Impl, ListBox*, pBox ) { - USHORT nSelPos = pBox->GetSelectEntryPos(); + sal_uInt16 nSelPos = pBox->GetSelectEntryPos(); if( pParaBck_Impl && pParaBck_Impl->nActPos != nSelPos) { SvxBrushItem** pActItem = new (SvxBrushItem*); @@ -1668,13 +1677,13 @@ IMPL_LINK( SvxBackgroundTabPage, ParaDestinationHdl_Impl, ListBox*, pBox ) pParaBck_Impl->nActPos = nSelPos; if(0 == aLbSelect.GetSelectEntryPos()) // Brush ausgewaehlt { - USHORT nWhich = (*pActItem)->Which(); + sal_uInt16 nWhich = (*pActItem)->Which(); **pActItem = SvxBrushItem( aBgdColor, nWhich ); } else { SvxGraphicPosition eNewPos = GetGraphicPosition_Impl(); - const BOOL bIsLink = aBtnLink.IsChecked(); + const sal_Bool bIsLink = aBtnLink.IsChecked(); if ( !bIsLink && !bIsGraphicValid ) bIsGraphicValid = LoadLinkedGraphic_Impl(); @@ -1698,7 +1707,7 @@ IMPL_LINK( SvxBackgroundTabPage, ParaDestinationHdl_Impl, ListBox*, pBox ) case PARA_DEST_CHAR: { *pActItem = pParaBck_Impl->pCharBrush; - aLbSelect.Enable(FALSE); + aLbSelect.Enable(sal_False); } break; } @@ -1720,7 +1729,7 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, { aColTransMF.SetValue(lcl_TransparencyToPercent(rColor.GetTransparency())); aColTransMF.SaveValue(); - BOOL bEnableTransp = rColor.GetTransparency() < 0xff; + sal_Bool bEnableTransp = rColor.GetTransparency() < 0xff; aColTransFT.Enable(bEnableTransp); aColTransMF.Enable(bEnableTransp); //the default setting should be "no transparency" @@ -1735,7 +1744,7 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, Color aTrColor( COL_TRANSPARENT ); aBgdColor = rColor; - USHORT nCol = ( aTrColor != aBgdColor ) ? + sal_uInt16 nCol = ( aTrColor != aBgdColor ) ? GetItemId_Impl( aBackgroundColorSet, aBgdColor ) : 0; if( aTrColor != aBgdColor && nCol == 0) @@ -1754,8 +1763,8 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, aBgdGraphicPath.Erase(); if ( !rUserData.Len() ) - aBtnPreview.Check( FALSE ); - aBtnLink.Check( FALSE ); + aBtnPreview.Check( sal_False ); + aBtnLink.Check( sal_False ); aBtnLink.Disable(); pPreviewWin2->NotifyChange( NULL ); SetGraphicPosition_Impl( GPOS_TILED ); // Kacheln als Default @@ -1776,13 +1785,13 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, DBG_ASSERT( aObj.GetProtocol() != INET_PROT_NOT_VALID, "Invalid URL!" ); #endif aBgdGraphicPath = *pStrLink; - aBtnLink.Check( TRUE ); + aBtnLink.Check( sal_True ); aBtnLink.Enable(); } else { aBgdGraphicPath.Erase(); - aBtnLink.Check( FALSE ); + aBtnLink.Check( sal_False ); aBtnLink.Disable(); } @@ -1815,7 +1824,7 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, else if ( pGraphic ) { aBgdGraphic = *pGraphic; - bIsGraphicValid = TRUE; + bIsGraphicValid = sal_True; if ( !rUserData.Len() ) aBtnPreview.Check(); @@ -1823,10 +1832,10 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, else { RaiseLoadError_Impl(); - bIsGraphicValid = FALSE; + bIsGraphicValid = sal_False; if ( !rUserData.Len() ) - aBtnPreview.Check( FALSE ); + aBtnPreview.Check( sal_False ); } } @@ -1842,7 +1851,7 @@ void SvxBackgroundTabPage::FillControls_Impl( const SvxBrushItem& rBgdAttr, } } -void SvxBackgroundTabPage::EnableTransparency(BOOL bColor, BOOL bGraphic) +void SvxBackgroundTabPage::EnableTransparency(sal_Bool bColor, sal_Bool bGraphic) { bColTransparency = bColor; bGraphTransparency = bGraphic; @@ -1869,7 +1878,7 @@ void SvxBackgroundTabPage::PageCreated (SfxAllItemSet aSet) SFX_ITEMSET_ARG (&aSet,pFlagItem,SfxUInt32Item,SID_FLAG_TYPE,sal_False); if (pFlagItem) { - UINT32 nFlags=pFlagItem->GetValue(); + sal_uInt32 nFlags=pFlagItem->GetValue(); if ( ( nFlags & SVX_SHOW_TBLCTL ) == SVX_SHOW_TBLCTL ) ShowTblControl(); if ( ( nFlags & SVX_SHOW_PARACTL ) == SVX_SHOW_PARACTL ) @@ -1877,7 +1886,7 @@ void SvxBackgroundTabPage::PageCreated (SfxAllItemSet aSet) if ( ( nFlags & SVX_SHOW_SELECTOR ) == SVX_SHOW_SELECTOR ) ShowSelector(); if ( ( nFlags & SVX_ENABLE_TRANSPARENCY ) == SVX_ENABLE_TRANSPARENCY ) - EnableTransparency(TRUE, TRUE); + EnableTransparency(sal_True, sal_True); } } diff --git a/cui/source/tabpages/backgrnd.src b/cui/source/tabpages/backgrnd.src index 49f2124f8b88..bbf7970fbb65 100644 --- a/cui/source/tabpages/backgrnd.src +++ b/cui/source/tabpages/backgrnd.src @@ -54,6 +54,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; ListBox LB_SELECTOR { + HelpID = "cui:ListBox:RID_SVXPAGE_BACKGROUND:LB_SELECTOR"; Hide = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 33 , 3 ) ; @@ -75,6 +76,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; ListBox LB_TBL_BOX { + HelpID = "cui:ListBox:RID_SVXPAGE_BACKGROUND:LB_TBL_BOX"; Hide = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 172 , 3 ) ; @@ -89,6 +91,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; ListBox LB_PARA_BOX { + HelpID = "cui:ListBox:RID_SVXPAGE_BACKGROUND:LB_PARA_BOX"; Hide = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 172 , 3 ) ; @@ -139,6 +142,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; MetricField MF_COL_TRANS { + HelpID = "cui:MetricField:RID_SVXPAGE_BACKGROUND:MF_COL_TRANS"; Hide = TRUE ; Pos = MAP_APPFONT ( 218 , 74 + RSC_SP_CTRL_Y ) ; Size = MAP_APPFONT ( 30 , 12) ; @@ -164,6 +168,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; PushButton BTN_BROWSE { + HelpID = "cui:PushButton:RID_SVXPAGE_BACKGROUND:BTN_BROWSE"; Hide = TRUE ; Pos = MAP_APPFONT ( 6 + RSC_SP_FLGR_INNERBORDER_LEFT , 23 + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP ) ; Size = MAP_APPFONT ( 60 , 14 ) ; @@ -171,6 +176,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; CheckBox BTN_LINK { + HelpID = "cui:CheckBox:RID_SVXPAGE_BACKGROUND:BTN_LINK"; Hide = TRUE ; Pos = MAP_APPFONT ( 6 + RSC_SP_FLGR_INNERBORDER_LEFT + 60 + 2*RSC_SP_CTRL_X, 23 + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP + 3 ) ; Size = MAP_APPFONT ( 78 , 10 ) ; @@ -192,6 +198,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; RadioButton BTN_POSITION { + HelpID = "cui:RadioButton:RID_SVXPAGE_BACKGROUND:BTN_POSITION"; Hide = TRUE ; Pos = MAP_APPFONT ( 12 , 89 ) ; Size = MAP_APPFONT ( 49 , 10 ) ; @@ -199,6 +206,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; RadioButton BTN_AREA { + HelpID = "cui:RadioButton:RID_SVXPAGE_BACKGROUND:BTN_AREA"; Hide = TRUE ; Pos = MAP_APPFONT ( 12 , 103 ) ; Size = MAP_APPFONT ( 49 , 10 ) ; @@ -206,6 +214,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; RadioButton BTN_TILE { + HelpID = "cui:RadioButton:RID_SVXPAGE_BACKGROUND:BTN_TILE"; Hide = TRUE ; Pos = MAP_APPFONT ( 12 , 117 ) ; Size = MAP_APPFONT ( 49 , 10 ) ; @@ -229,6 +238,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; MetricField MF_GRAPH_TRANS { + HelpID = "cui:MetricField:RID_SVXPAGE_BACKGROUND:MF_GRAPH_TRANS"; Hide = TRUE ; Pos = MAP_APPFONT ( 12 , 168 ) ; Size = MAP_APPFONT ( 30 , 12) ; @@ -252,6 +262,7 @@ TabPage RID_SVXPAGE_BACKGROUND }; CheckBox BTN_PREVIEW { + HelpID = "cui:CheckBox:RID_SVXPAGE_BACKGROUND:BTN_PREVIEW"; Pos = MAP_APPFONT ( 170 , 23 + 4 + 139 + RSC_SP_CTRL_GROUP_Y ) ; Size = MAP_APPFONT ( 141 , 10 ) ; Text [ en-US ] = "Pre~view" ; diff --git a/cui/source/tabpages/bbdlg.cxx b/cui/source/tabpages/bbdlg.cxx index af6197312dbd..3133b2fb7638 100644 --- a/cui/source/tabpages/bbdlg.cxx +++ b/cui/source/tabpages/bbdlg.cxx @@ -41,7 +41,7 @@ SvxBorderBackgroundDlg::SvxBorderBackgroundDlg( Window *pParent, const SfxItemSet& rCoreSet, - BOOL bEnableSelector ) : + sal_Bool bEnableSelector ) : SfxTabDialog( pParent, CUI_RES( RID_SVXDLG_BBDLG ), &rCoreSet ), bEnableBackgroundSelector( bEnableSelector ) @@ -59,7 +59,7 @@ SvxBorderBackgroundDlg::~SvxBorderBackgroundDlg() // ----------------------------------------------------------------------- -void SvxBorderBackgroundDlg::PageCreated( USHORT nPageId, SfxTabPage& rTabPage ) +void SvxBorderBackgroundDlg::PageCreated( sal_uInt16 nPageId, SfxTabPage& rTabPage ) { // Umschalten zwischen Farbe/Grafik ermoeglichen: diff --git a/cui/source/tabpages/border.cxx b/cui/source/tabpages/border.cxx index 7ca9e34b9098..cc239df13481 100644 --- a/cui/source/tabpages/border.cxx +++ b/cui/source/tabpages/border.cxx @@ -74,7 +74,7 @@ // static ---------------------------------------------------------------- -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_ATTR_BORDER_INNER, SID_ATTR_BORDER_SHADOW, SID_ATTR_ALIGN_MARGIN, SID_ATTR_ALIGN_MARGIN, @@ -84,7 +84,7 @@ static USHORT pRanges[] = 0 }; -BOOL SvxBorderTabPage::bSync = TRUE; +sal_Bool SvxBorderTabPage::bSync = sal_True; //------------------------------------------------------------------------ @@ -154,17 +154,6 @@ Color TpBorderRGBColor( ColorData aColorData ) } // ----------------------------------------------------------------------- - -Color TpBorderRGBColor( const Color& rColor ) -{ - Color aRGBColor( rColor.GetRed(), - rColor.GetGreen(), - rColor.GetBlue() ); - - return( aRGBColor ); -} - -// ----------------------------------------------------------------------- void lcl_SetDecimalDigitsTo1(MetricField& rField) { sal_Int64 nMin = rField.Denormalize( rField.GetMin( FUNIT_TWIP ) ); @@ -230,7 +219,7 @@ SvxBorderTabPage::SvxBorderTabPage( Window* pParent, /* Use SvxMarginItem instead of margins from SvxBoxItem, if present. -> Remember this state in mbUseMarginItem, because other special handling is needed across various functions... */ - mbUseMarginItem = rCoreAttrs.GetItemState(GetWhich(SID_ATTR_ALIGN_MARGIN),TRUE) != SFX_ITEM_UNKNOWN; + mbUseMarginItem = rCoreAttrs.GetItemState(GetWhich(SID_ATTR_ALIGN_MARGIN),sal_True) != SFX_ITEM_UNKNOWN; // Metrik einstellen FieldUnit eFUnit = GetModuleFieldUnit( rCoreAttrs ); @@ -271,10 +260,10 @@ SvxBorderTabPage::SvxBorderTabPage( Window* pParent, SetFieldUnit( aEdShadowSize, eFUnit ); - USHORT nWhich = GetWhich( SID_ATTR_BORDER_INNER, sal_False ); - BOOL bIsDontCare = TRUE; + sal_uInt16 nWhich = GetWhich( SID_ATTR_BORDER_INNER, sal_False ); + sal_Bool bIsDontCare = sal_True; - if ( rCoreAttrs.GetItemState( nWhich, TRUE ) >= SFX_ITEM_AVAILABLE ) + if ( rCoreAttrs.GetItemState( nWhich, sal_True ) >= SFX_ITEM_AVAILABLE ) { // Absatz oder Tabelle const SvxBoxInfoItem* pBoxInfo = @@ -366,14 +355,14 @@ SvxBorderTabPage::SvxBorderTabPage( Window* pParent, if ( pColorTable ) { // fuellen der Linienfarben-Box - aLbLineColor.SetUpdateMode( FALSE ); + aLbLineColor.SetUpdateMode( sal_False ); for ( long i = 0; i < pColorTable->Count(); ++i ) { XColorEntry* pEntry = pColorTable->GetColor(i); aLbLineColor.InsertEntry( pEntry->GetColor(), pEntry->GetName() ); } - aLbLineColor.SetUpdateMode( TRUE ); + aLbLineColor.SetUpdateMode( sal_True ); // dann nur noch in die Schattenfarben-Box kopieren aLbShadowColor.CopyEntries( aLbLineColor ); } @@ -411,7 +400,7 @@ SvxBorderTabPage::~SvxBorderTabPage() // ----------------------------------------------------------------------- -USHORT* SvxBorderTabPage::GetRanges() +sal_uInt16* SvxBorderTabPage::GetRanges() { return pRanges; } @@ -445,7 +434,7 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) const SvxBoxItem* pBoxItem; const SvxBoxInfoItem* pBoxInfoItem; - USHORT nWhichBox = GetWhich(SID_ATTR_BORDER_OUTER); + sal_uInt16 nWhichBox = GetWhich(SID_ATTR_BORDER_OUTER); SfxMapUnit eCoreUnit; pBoxItem = (const SvxBoxItem*)GetItem( rSet, SID_ATTR_BORDER_OUTER ); @@ -488,9 +477,9 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) if ( pBoxInfoItem->IsDist() ) { - if( rSet.GetItemState( nWhichBox, TRUE ) >= SFX_ITEM_DEFAULT ) + if( rSet.GetItemState( nWhichBox, sal_True ) >= SFX_ITEM_DEFAULT ) { - BOOL bIsAnyBorderVisible = aFrameSel.IsAnyBorderVisible(); + sal_Bool bIsAnyBorderVisible = aFrameSel.IsAnyBorderVisible(); if( !bIsAnyBorderVisible || !pBoxInfoItem->IsMinDist() ) { aLeftMF.SetMin( 0 ); @@ -519,7 +508,7 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) // or it is null with an active border line // no automatic changes should be made const long nDefDist = bIsAnyBorderVisible ? pBoxInfoItem->GetDefDist() : 0; - BOOL bDiffDist = (nDefDist != nLeftDist || + sal_Bool bDiffDist = (nDefDist != nLeftDist || nDefDist != nRightDist || nDefDist != nTopDist || nDefDist != nBottomDist); @@ -559,7 +548,7 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) //------------------------------------------------------------- { // Do all visible lines show the same line widths? - USHORT nPrim, nDist, nSecn; + sal_uInt16 nPrim, nDist, nSecn; SvxBorderStyle nStyle; bool bWidthEq = aFrameSel.GetVisibleWidth( nPrim, nDist, nSecn, nStyle ); if( bWidthEq ) @@ -573,7 +562,7 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) if( !bColorEq ) aColor.SetColor( COL_BLACK ); - USHORT nSelPos = aLbLineColor.GetEntryPos( aColor ); + sal_uInt16 nSelPos = aLbLineColor.GetEntryPos( aColor ); if( nSelPos == LISTBOX_ENTRY_NOTFOUND ) nSelPos = aLbLineColor.InsertEntry( aColor, SVX_RESSTR( RID_SVXSTR_COLOR_USER ) ); @@ -589,7 +578,7 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) SelColHdl_Impl( &aLbLineColor ); } - BOOL bEnable = aWndShadows.GetSelectItemId() > 1 ; + sal_Bool bEnable = aWndShadows.GetSelectItemId() > 1 ; aFtShadowSize.Enable(bEnable); aEdShadowSize.Enable(bEnable); aFtShadowColor.Enable(bEnable); @@ -607,11 +596,11 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) const SfxPoolItem* pItem; SfxObjectShell* pShell; - if(SFX_ITEM_SET == rSet.GetItemState(SID_HTML_MODE, FALSE, &pItem) || + if(SFX_ITEM_SET == rSet.GetItemState(SID_HTML_MODE, sal_False, &pItem) || ( 0 != (pShell = SfxObjectShell::Current()) && 0 != (pItem = pShell->GetItem(SID_HTML_MODE)))) { - USHORT nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue(); + sal_uInt16 nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue(); if(nHtmlMode & HTMLMODE_ON) { //Im Html-Mode gibt es keinen Schatten und nur komplette Umrandungen @@ -623,14 +612,14 @@ void SvxBorderTabPage::Reset( const SfxItemSet& rSet ) aLbShadowColor.Disable(); aFlShadow .Disable(); - USHORT nLBCount = aLbLineStyle.GetEntryCount(); + sal_uInt16 nLBCount = aLbLineStyle.GetEntryCount(); // ist es ein Absatzdialog, dann alle Linien fuer // Sw-Export, sonst ist die Page nicht da if(!(mbHorEnabled || mbVerEnabled) && 0 == (nHtmlMode & HTMLMODE_FULL_ABS_POS) && SFX_ITEM_AVAILABLE > rSet.GetItemState(GetWhich( SID_ATTR_PARA_LINESPACE ))) { - for( USHORT i = nLBCount - 1; i > LINESTYLE_HTML_MAX; --i) + for( sal_uInt16 i = nLBCount - 1; i > LINESTYLE_HTML_MAX; --i) aLbLineStyle.RemoveEntry(i); } @@ -662,13 +651,13 @@ int SvxBorderTabPage::DeactivatePage( SfxItemSet* _pSet ) #define IS_DONT_CARE(a) ((a).GetState() == svx::FRAMESTATE_DONTCARE ) -BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) +sal_Bool SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) { bool bAttrsChanged = SfxTabPage::FillItemSet( rCoreAttrs ); - BOOL bPut = TRUE; - USHORT nBoxWhich = GetWhich( SID_ATTR_BORDER_OUTER ); - USHORT nBoxInfoWhich = rCoreAttrs.GetPool()->GetWhich( SID_ATTR_BORDER_INNER, sal_False ); + sal_Bool bPut = sal_True; + sal_uInt16 nBoxWhich = GetWhich( SID_ATTR_BORDER_OUTER ); + sal_uInt16 nBoxInfoWhich = rCoreAttrs.GetPool()->GetWhich( SID_ATTR_BORDER_INNER, sal_False ); const SfxItemSet& rOldSet = GetItemSet(); SvxBoxItem aBoxItem ( nBoxWhich ); SvxBoxInfoItem aBoxInfoItem ( nBoxInfoWhich ); @@ -680,7 +669,7 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) //------------------ // Umrandung aussen: //------------------ - typedef ::std::pair<svx::FrameBorderType,USHORT> TBorderPair; + typedef ::std::pair<svx::FrameBorderType,sal_uInt16> TBorderPair; TBorderPair eTypes1[] = { TBorderPair(svx::FRAMEBORDER_TOP,BOX_LINE_TOP), TBorderPair(svx::FRAMEBORDER_BOTTOM,BOX_LINE_BOTTOM), @@ -710,7 +699,7 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) if( aLeftMF.IsVisible() ) { // #i40405# enable distance controls for next dialog call - aBoxInfoItem.SetDist( TRUE ); + aBoxInfoItem.SetDist( sal_True ); if( !mbUseMarginItem ) { @@ -741,10 +730,10 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) (pOldBoxInfoItem && !pOldBoxInfoItem->IsValid(VALID_DISTANCE)) ) { - aBoxItem.SetDistance( (USHORT)GetCoreValue( aLeftMF, eCoreUnit ), BOX_LINE_LEFT ); - aBoxItem.SetDistance( (USHORT)GetCoreValue( aRightMF, eCoreUnit ), BOX_LINE_RIGHT ); - aBoxItem.SetDistance( (USHORT)GetCoreValue( aTopMF, eCoreUnit ), BOX_LINE_TOP ); - aBoxItem.SetDistance( (USHORT)GetCoreValue( aBottomMF, eCoreUnit ), BOX_LINE_BOTTOM); + aBoxItem.SetDistance( (sal_uInt16)GetCoreValue( aLeftMF, eCoreUnit ), BOX_LINE_LEFT ); + aBoxItem.SetDistance( (sal_uInt16)GetCoreValue( aRightMF, eCoreUnit ), BOX_LINE_RIGHT ); + aBoxItem.SetDistance( (sal_uInt16)GetCoreValue( aTopMF, eCoreUnit ), BOX_LINE_TOP ); + aBoxItem.SetDistance( (sal_uInt16)GetCoreValue( aBottomMF, eCoreUnit ), BOX_LINE_BOTTOM); } else { @@ -753,10 +742,10 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) aBoxItem.SetDistance(pOldBoxItem->GetDistance(BOX_LINE_TOP ), BOX_LINE_TOP); aBoxItem.SetDistance(pOldBoxItem->GetDistance(BOX_LINE_BOTTOM), BOX_LINE_BOTTOM); } - aBoxInfoItem.SetValid( VALID_DISTANCE, TRUE ); + aBoxInfoItem.SetValid( VALID_DISTANCE, sal_True ); } else - aBoxInfoItem.SetValid( VALID_DISTANCE, FALSE ); + aBoxInfoItem.SetValid( VALID_DISTANCE, sal_False ); } } } @@ -774,13 +763,13 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) // // Put oder Clear der Umrandung? // - bPut = TRUE; + bPut = sal_True; - if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nBoxWhich, FALSE )) + if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nBoxWhich, sal_False )) { bPut = aBoxItem != (const SvxBoxItem&)(rOldSet.Get(nBoxWhich)) ? sal_True : sal_False; } - if( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nBoxInfoWhich, FALSE ) ) + if( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nBoxInfoWhich, sal_False ) ) { const SvxBoxInfoItem& rOldBoxInfo = (const SvxBoxInfoItem&) rOldSet.Get(nBoxInfoWhich); @@ -795,14 +784,14 @@ BOOL SvxBorderTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) if ( !pOldBoxItem || !( *pOldBoxItem == aBoxItem ) ) { rCoreAttrs.Put( aBoxItem ); - bAttrsChanged |= TRUE; + bAttrsChanged |= sal_True; } pOld = GetOldItem( rCoreAttrs, SID_ATTR_BORDER_INNER, sal_False ); if ( !pOld || !( *(const SvxBoxInfoItem*)pOld == aBoxInfoItem ) ) { rCoreAttrs.Put( aBoxInfoItem ); - bAttrsChanged |= TRUE; + bAttrsChanged |= sal_True; } } else @@ -866,7 +855,7 @@ IMPL_LINK( SvxBorderTabPage, SelPreHdl_Impl, void *, EMPTYARG ) aFrameSel.DeselectAllBorders(); // Using image ID to find correct line in table above. - USHORT nLine = GetPresetImageId( aWndPresets.GetSelectItemId() ) - 1; + sal_uInt16 nLine = GetPresetImageId( aWndPresets.GetSelectItemId() ) - 1; // Apply all styles from the table for( int nBorder = 0; nBorder < svx::FRAMEBORDERTYPE_COUNT; ++nBorder ) @@ -903,7 +892,7 @@ IMPL_LINK( SvxBorderTabPage, SelPreHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxBorderTabPage, SelSdwHdl_Impl, void *, EMPTYARG ) { - BOOL bEnable = aWndShadows.GetSelectItemId() > 1; + sal_Bool bEnable = aWndShadows.GetSelectItemId() > 1; aFtShadowSize.Enable(bEnable); aEdShadowSize.Enable(bEnable); aFtShadowColor.Enable(bEnable); @@ -949,9 +938,9 @@ IMPL_LINK( SvxBorderTabPage, SelStyleHdl_Impl, ListBox *, pLb ) { if ( pLb == &aLbLineStyle ) aFrameSel.SetStyleToSelection( - static_cast< USHORT >( aLbLineStyle.GetSelectEntryLine1() / 100 ), - static_cast< USHORT >( aLbLineStyle.GetSelectEntryDistance() / 100 ), - static_cast< USHORT >( aLbLineStyle.GetSelectEntryLine2() / 100 ), + static_cast< sal_uInt16 >( aLbLineStyle.GetSelectEntryLine1() / 100 ), + static_cast< sal_uInt16 >( aLbLineStyle.GetSelectEntryDistance() / 100 ), + static_cast< sal_uInt16 >( aLbLineStyle.GetSelectEntryLine2() / 100 ), lcl_getBorderStyle( aLbLineStyle.GetSelectEntryStyle() ) ); return 0; @@ -962,17 +951,17 @@ IMPL_LINK( SvxBorderTabPage, SelStyleHdl_Impl, ListBox *, pLb ) // ============================================================================ // number of preset images to show -const USHORT SVX_BORDER_PRESET_COUNT = 5; +const sal_uInt16 SVX_BORDER_PRESET_COUNT = 5; // number of shadow images to show -const USHORT SVX_BORDER_SHADOW_COUNT = 5; +const sal_uInt16 SVX_BORDER_SHADOW_COUNT = 5; // ---------------------------------------------------------------------------- -USHORT SvxBorderTabPage::GetPresetImageId( USHORT nValueSetIdx ) const +sal_uInt16 SvxBorderTabPage::GetPresetImageId( sal_uInt16 nValueSetIdx ) const { // table with all sets of predefined border styles - static const USHORT ppnImgIds[][ SVX_BORDER_PRESET_COUNT ] = + static const sal_uInt16 ppnImgIds[][ SVX_BORDER_PRESET_COUNT ] = { // simple cell without diagonal frame borders { IID_PRE_CELL_NONE, IID_PRE_CELL_ALL, IID_PRE_CELL_LR, IID_PRE_CELL_TB, IID_PRE_CELL_L }, @@ -1002,10 +991,10 @@ USHORT SvxBorderTabPage::GetPresetImageId( USHORT nValueSetIdx ) const return ppnImgIds[ nLine ][ nValueSetIdx - 1 ]; } -USHORT SvxBorderTabPage::GetPresetStringId( USHORT nValueSetIdx ) const +sal_uInt16 SvxBorderTabPage::GetPresetStringId( sal_uInt16 nValueSetIdx ) const { // string resource IDs for each image (in order of the IID_PRE_* image IDs) - static const USHORT pnStrIds[] = + static const sal_uInt16 pnStrIds[] = { RID_SVXSTR_TABLE_PRESET_NONE, RID_SVXSTR_PARA_PRESET_ALL, @@ -1048,7 +1037,7 @@ void SvxBorderTabPage::FillPresetVS() aWndPresets.SetSizePixel( aWndPresets.CalcWindowSizePixel( aImgSize ) ); // insert images and help texts - for( USHORT nVSIdx = 1; nVSIdx <= SVX_BORDER_PRESET_COUNT; ++nVSIdx ) + for( sal_uInt16 nVSIdx = 1; nVSIdx <= SVX_BORDER_PRESET_COUNT; ++nVSIdx ) { aWndPresets.InsertItem( nVSIdx ); aWndPresets.SetItemImage( nVSIdx, rImgList.GetImage( GetPresetImageId( nVSIdx ) ) ); @@ -1073,14 +1062,14 @@ void SvxBorderTabPage::FillShadowVS() aWndShadows.SetSizePixel( aWndShadows.CalcWindowSizePixel( aImgSize ) ); // image resource IDs - static const USHORT pnImgIds[ SVX_BORDER_SHADOW_COUNT ] = + static const sal_uInt16 pnImgIds[ SVX_BORDER_SHADOW_COUNT ] = { IID_SHADOWNONE, IID_SHADOW_BOT_RIGHT, IID_SHADOW_TOP_RIGHT, IID_SHADOW_BOT_LEFT, IID_SHADOW_TOP_LEFT }; // string resource IDs for each image - static const USHORT pnStrIds[ SVX_BORDER_SHADOW_COUNT ] = + static const sal_uInt16 pnStrIds[ SVX_BORDER_SHADOW_COUNT ] = { RID_SVXSTR_SHADOW_STYLE_NONE, RID_SVXSTR_SHADOW_STYLE_BOTTOMRIGHT, RID_SVXSTR_SHADOW_STYLE_TOPRIGHT, RID_SVXSTR_SHADOW_STYLE_BOTTOMLEFT, RID_SVXSTR_SHADOW_STYLE_TOPLEFT }; // insert images and help texts - for( USHORT nVSIdx = 1; nVSIdx <= SVX_BORDER_SHADOW_COUNT; ++nVSIdx ) + for( sal_uInt16 nVSIdx = 1; nVSIdx <= SVX_BORDER_SHADOW_COUNT; ++nVSIdx ) { aWndShadows.InsertItem( nVSIdx ); aWndShadows.SetItemImage( nVSIdx, rImgList.GetImage( pnImgIds[ nVSIdx - 1 ] ) ); @@ -1140,9 +1129,9 @@ IMPL_LINK( SvxBorderTabPage, LinesChanged_Impl, void*, EMPTYARG ) { if(!mbUseMarginItem && aLeftMF.IsVisible()) { - BOOL bLineSet = aFrameSel.IsAnyBorderVisible(); - BOOL bMinAllowed = 0 != (nSWMode & (SW_BORDER_MODE_FRAME|SW_BORDER_MODE_TABLE)); - BOOL bSpaceModified = aLeftMF .IsModified()|| + sal_Bool bLineSet = aFrameSel.IsAnyBorderVisible(); + sal_Bool bMinAllowed = 0 != (nSWMode & (SW_BORDER_MODE_FRAME|SW_BORDER_MODE_TABLE)); + sal_Bool bSpaceModified = aLeftMF .IsModified()|| aRightMF .IsModified()|| aTopMF .IsModified()|| aBottomMF.IsModified(); @@ -1183,7 +1172,7 @@ IMPL_LINK( SvxBorderTabPage, LinesChanged_Impl, void*, EMPTYARG ) } } //fuer Tabellen ist alles erlaubt - USHORT nValid = VALID_TOP|VALID_BOTTOM|VALID_LEFT|VALID_RIGHT; + sal_uInt16 nValid = VALID_TOP|VALID_BOTTOM|VALID_LEFT|VALID_RIGHT; //fuer Rahmen und Absatz wird das Edit disabled, wenn keine Border gesetzt ist if(nSWMode & (SW_BORDER_MODE_FRAME|SW_BORDER_MODE_PARA)) diff --git a/cui/source/tabpages/border.src b/cui/source/tabpages/border.src index 583302898e15..10f6e327ff5b 100644 --- a/cui/source/tabpages/border.src +++ b/cui/source/tabpages/border.src @@ -93,6 +93,7 @@ TabPage RID_SVXPAGE_BORDER }; ListBox LB_LINESTYLE { + HelpID = "cui:ListBox:RID_SVXPAGE_BORDER:LB_LINESTYLE"; Border = TRUE ; Pos = MAP_APPFONT ( 88 , 25 ) ; Size = MAP_APPFONT ( 74 , 66 ) ; @@ -105,6 +106,7 @@ TabPage RID_SVXPAGE_BORDER }; ListBox LB_LINECOLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_BORDER:LB_LINECOLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 88 , 106 ) ; Size = MAP_APPFONT ( 74 , 68 ) ; @@ -125,6 +127,7 @@ TabPage RID_SVXPAGE_BORDER }; MetricField MF_LEFT { + HelpID = "cui:MetricField:RID_SVXPAGE_BORDER:MF_LEFT"; Border = TRUE ; Pos = MAP_APPFONT ( 213 , 14 ) ; Size = MAP_APPFONT ( 38 , 12 ) ; @@ -146,6 +149,7 @@ TabPage RID_SVXPAGE_BORDER }; MetricField MF_RIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_BORDER:MF_RIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 213 , 30 ) ; Size = MAP_APPFONT ( 38 , 12 ) ; @@ -167,6 +171,7 @@ TabPage RID_SVXPAGE_BORDER }; MetricField MF_TOP { + HelpID = "cui:MetricField:RID_SVXPAGE_BORDER:MF_TOP"; Border = TRUE ; Pos = MAP_APPFONT ( 213 , 46 ) ; Size = MAP_APPFONT ( 38 , 12 ) ; @@ -188,6 +193,7 @@ TabPage RID_SVXPAGE_BORDER }; MetricField MF_BOTTOM { + HelpID = "cui:MetricField:RID_SVXPAGE_BORDER:MF_BOTTOM"; Border = TRUE ; Pos = MAP_APPFONT ( 213 , 62 ) ; Size = MAP_APPFONT ( 38 , 12 ) ; @@ -203,6 +209,7 @@ TabPage RID_SVXPAGE_BORDER }; CheckBox CB_SYNC { + HelpID = "cui:CheckBox:RID_SVXPAGE_BORDER:CB_SYNC"; Pos = MAP_APPFONT ( 177 , 78 ) ; Size = MAP_APPFONT ( 74 , 10 ) ; Text [ en-US ] = "Synchronize"; @@ -236,6 +243,7 @@ TabPage RID_SVXPAGE_BORDER }; MetricField ED_SHADOWSIZE { + HelpID = "cui:MetricField:RID_SVXPAGE_BORDER:ED_SHADOWSIZE"; Border = TRUE ; Pos = MAP_APPFONT ( 88 , 144 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -257,6 +265,7 @@ TabPage RID_SVXPAGE_BORDER }; ListBox LB_SHADOWCOLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_BORDER:LB_SHADOWCOLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 177 , 144 ) ; Size = MAP_APPFONT ( 74 , 68 ) ; @@ -278,6 +287,7 @@ TabPage RID_SVXPAGE_BORDER }; CheckBox CB_MERGEWITHNEXT { + HelpID = "cui:CheckBox:RID_SVXPAGE_BORDER:CB_MERGEWITHNEXT"; Pos = MAP_APPFONT ( 12 , 173 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Hide = TRUE; @@ -285,6 +295,7 @@ TabPage RID_SVXPAGE_BORDER }; CheckBox CB_MERGEADJACENTBORDERS { + HelpID = "cui:CheckBox:RID_SVXPAGE_BORDER:CB_MERGEADJACENTBORDERS"; Pos = MAP_APPFONT ( 12 , 173 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Hide = TRUE; diff --git a/cui/source/tabpages/borderconn.cxx b/cui/source/tabpages/borderconn.cxx index 707af534a6df..04ecaa58e3da 100644 --- a/cui/source/tabpages/borderconn.cxx +++ b/cui/source/tabpages/borderconn.cxx @@ -49,7 +49,7 @@ of the tab page. class LineItemWrapper : public sfx::SingleItemWrapper< SvxLineItem, const SvxBorderLine* > { public: - inline explicit LineItemWrapper( USHORT nSlot ) : SingleItemWrapperType( nSlot ) {} + inline explicit LineItemWrapper( sal_uInt16 nSlot ) : SingleItemWrapperType( nSlot ) {} virtual const SvxBorderLine* GetItemValue( const SvxLineItem& rItem ) const { return rItem.GetLine(); } @@ -275,19 +275,12 @@ ShadowConnection::ShadowConnection( const SfxItemSet& rItemSet, // ============================================================================ // ============================================================================ -sfx::ItemConnectionBase* CreateFrameLineConnection( USHORT nSlot, +sfx::ItemConnectionBase* CreateFrameLineConnection( sal_uInt16 nSlot, FrameSelector& rFrameSel, FrameBorderType eBorder, sfx::ItemConnFlags nFlags ) { return new FrameLineConnection( nSlot, new FrameSelectorWrapper( rFrameSel, eBorder ), nFlags ); } -sfx::ItemConnectionBase* CreateFrameBoxConnection( USHORT /*nBoxSlot*/, USHORT /*nBoxInfoSlot*/, - FrameSelector& /*rFrameSel*/, FrameBorderType /*eBorder*/, sfx::ItemConnFlags /*nFlags*/ ) -{ - DBG_ERRORFILE( "svx::CreateFrameBoxConnection - not implemented" ); - return 0; -} - sfx::ItemConnectionBase* CreateMarginConnection( const SfxItemSet& rItemSet, MetricField& rMfLeft, MetricField& rMfRight, MetricField& rMfTop, MetricField& rMfBottom, diff --git a/cui/source/tabpages/borderconn.hxx b/cui/source/tabpages/borderconn.hxx index 76071f904a6d..8e6b7c11d917 100644 --- a/cui/source/tabpages/borderconn.hxx +++ b/cui/source/tabpages/borderconn.hxx @@ -45,14 +45,7 @@ class FrameSelector; /** Creates an item connection object that connects an SvxLineItem with an svx::FrameSelector control. */ -sfx::ItemConnectionBase* CreateFrameLineConnection( USHORT nSlot, - FrameSelector& rFrameSel, FrameBorderType eBorder, - sfx::ItemConnFlags nFlags = sfx::ITEMCONN_DEFAULT ); - -/** Creates an item connection object that connects an SvxBoxItem and an - SvxBoxInfoItem with an svx::FrameSelector control. */ -sfx::ItemConnectionBase* CreateFrameBoxConnection( - USHORT nBoxSlot, USHORT nBoxInfoSlot, +sfx::ItemConnectionBase* CreateFrameLineConnection( sal_uInt16 nSlot, FrameSelector& rFrameSel, FrameBorderType eBorder, sfx::ItemConnFlags nFlags = sfx::ITEMCONN_DEFAULT ); diff --git a/cui/source/tabpages/chardlg.cxx b/cui/source/tabpages/chardlg.cxx index c41dad92b704..a02cacd281de 100644 --- a/cui/source/tabpages/chardlg.cxx +++ b/cui/source/tabpages/chardlg.cxx @@ -101,7 +101,7 @@ using namespace ::com::sun::star; // static ---------------------------------------------------------------- -static USHORT pNameRanges[] = +static sal_uInt16 pNameRanges[] = { SID_ATTR_CHAR_FONT, SID_ATTR_CHAR_WEIGHT, @@ -118,7 +118,7 @@ static USHORT pNameRanges[] = 0 }; -static USHORT pEffectsRanges[] = +static sal_uInt16 pEffectsRanges[] = { SID_ATTR_CHAR_SHADOWED, SID_ATTR_CHAR_UNDERLINE, @@ -139,7 +139,7 @@ static USHORT pEffectsRanges[] = 0 }; -static USHORT pPositionRanges[] = +static sal_uInt16 pPositionRanges[] = { SID_ATTR_CHAR_KERNING, SID_ATTR_CHAR_KERNING, @@ -154,7 +154,7 @@ static USHORT pPositionRanges[] = 0 }; -static USHORT pTwoLinesRanges[] = +static sal_uInt16 pTwoLinesRanges[] = { SID_ATTR_CHAR_TWO_LINES, SID_ATTR_CHAR_TWO_LINES, @@ -163,7 +163,7 @@ static USHORT pTwoLinesRanges[] = // C-Funktion ------------------------------------------------------------ -inline BOOL StateToAttr( TriState aState ) +inline sal_Bool StateToAttr( TriState aState ) { return ( STATE_CHECK == aState ); } @@ -191,11 +191,11 @@ inline SvxFont& SvxCharBasePage::GetPreviewCTLFont() // ----------------------------------------------------------------------- SvxCharBasePage::SvxCharBasePage( Window* pParent, const ResId& rResId, const SfxItemSet& rItemset, - USHORT nResIdPrewievWin, USHORT nResIdFontTypeFT ): + sal_uInt16 nResIdPrewievWin, sal_uInt16 nResIdFontTypeFT ): SfxTabPage( pParent, rResId, rItemset ), m_aPreviewWin( this, ResId( nResIdPrewievWin, *rResId.GetResMgr() ) ), m_aFontTypeFT( this, ResId( nResIdFontTypeFT, *rResId.GetResMgr() ) ), - m_bPreviewBackgroundToCharacter( FALSE ) + m_bPreviewBackgroundToCharacter( sal_False ) { } @@ -213,7 +213,7 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) SvxFont& rFont = GetPreviewFont(); SvxFont& rCJKFont = GetPreviewCJKFont(); SvxFont& rCTLFont = GetPreviewCTLFont(); - USHORT nWhich; + sal_uInt16 nWhich; nWhich = GetWhich( SID_CHAR_DLG_PREVIEW_STRING ); if( ISITEMSET ) @@ -322,7 +322,7 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) if( ISITEMSET ) { const SvxContourItem& rItem = ( SvxContourItem& ) rSet.Get( nWhich ); - BOOL bOutline = rItem.GetValue(); + sal_Bool bOutline = rItem.GetValue(); rFont.SetOutline( bOutline ); rCJKFont.SetOutline( bOutline ); rCTLFont.SetOutline( bOutline ); @@ -333,14 +333,14 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) if( ISITEMSET ) { const SvxShadowedItem& rItem = ( SvxShadowedItem& ) rSet.Get( nWhich ); - BOOL bShadow = rItem.GetValue(); + sal_Bool bShadow = rItem.GetValue(); rFont.SetShadow( bShadow ); rCJKFont.SetShadow( bShadow ); rCTLFont.SetShadow( bShadow ); } // Background - BOOL bTransparent; + sal_Bool bTransparent; nWhich = GetWhich( m_bPreviewBackgroundToCharacter ? SID_ATTR_BRUSH : SID_ATTR_BRUSH_CHAR ); if( ISITEMSET ) { @@ -352,7 +352,7 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) rCTLFont.SetFillColor( rColor ); } else - bTransparent = TRUE; + bTransparent = sal_True; rFont.SetTransparent( bTransparent ); rCJKFont.SetTransparent( bTransparent ); @@ -413,9 +413,9 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) // Escapement nWhich = GetWhich( SID_ATTR_CHAR_ESCAPEMENT ); - const BYTE nProp = 100; + const sal_uInt8 nProp = 100; short nEsc; - BYTE nEscProp; + sal_uInt8 nEscProp; if( ISITEMSET ) { const SvxEscapementItem& rItem = ( SvxEscapementItem& ) rSet.Get( nWhich ); @@ -443,9 +443,9 @@ void SvxCharBasePage::ActivatePage( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -void SvxCharBasePage::SetPrevFontSize( const SfxItemSet& rSet, USHORT nSlot, SvxFont& rFont ) +void SvxCharBasePage::SetPrevFontSize( const SfxItemSet& rSet, sal_uInt16 nSlot, SvxFont& rFont ) { - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nWhich = GetWhich( nSlot ); long nH; if( rSet.GetItemState( nWhich ) >= SFX_ITEM_SET ) { @@ -461,9 +461,9 @@ void SvxCharBasePage::SetPrevFontSize( const SfxItemSet& rSet, USHORT nSlot, Svx // ----------------------------------------------------------------------- -void SvxCharBasePage::SetPrevFont( const SfxItemSet& rSet, USHORT nSlot, SvxFont& rFont ) +void SvxCharBasePage::SetPrevFont( const SfxItemSet& rSet, sal_uInt16 nSlot, SvxFont& rFont ) { - USHORT nWhich = GetWhich( nSlot ); + sal_uInt16 nWhich = GetWhich( nSlot ); if( ISITEMSET ) { const SvxFontItem& rFontItem = ( SvxFontItem& ) rSet.Get( nWhich ); @@ -477,9 +477,9 @@ void SvxCharBasePage::SetPrevFont( const SfxItemSet& rSet, USHORT nSlot, SvxFont // ----------------------------------------------------------------------- -void SvxCharBasePage::SetPrevFontStyle( const SfxItemSet& rSet, USHORT nPosture, USHORT nWeight, SvxFont& rFont ) +void SvxCharBasePage::SetPrevFontStyle( const SfxItemSet& rSet, sal_uInt16 nPosture, sal_uInt16 nWeight, SvxFont& rFont ) { - USHORT nWhich = GetWhich( nPosture ); + sal_uInt16 nWhich = GetWhich( nPosture ); if( ISITEMSET ) { const SvxPostureItem& rItem = ( SvxPostureItem& ) rSet.Get( nWhich ); @@ -498,7 +498,7 @@ void SvxCharBasePage::SetPrevFontStyle( const SfxItemSet& rSet, USHORT nPosture, void SvxCharBasePage::SetPrevFontWidthScale( const SfxItemSet& rSet ) { - USHORT nWhich = GetWhich( SID_ATTR_CHAR_SCALEWIDTH ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_SCALEWIDTH ); if( ISITEMSET ) { const SvxCharScaleWidthItem& rItem = ( SvxCharScaleWidthItem& ) rSet.Get( nWhich ); @@ -511,7 +511,7 @@ void SvxCharBasePage::SetPrevFontWidthScale( const SfxItemSet& rSet ) namespace { // ----------------------------------------------------------------------- - void setPrevFontEscapement(SvxFont& _rFont,BYTE nProp, BYTE nEscProp, short nEsc ) + void setPrevFontEscapement(SvxFont& _rFont,sal_uInt8 nProp, sal_uInt8 nEscProp, short nEsc ) { _rFont.SetPropr( nProp ); _rFont.SetProprRel( nEscProp ); @@ -522,7 +522,7 @@ namespace } // ----------------------------------------------------------------------- -void SvxCharBasePage::SetPrevFontEscapement( BYTE nProp, BYTE nEscProp, short nEsc ) +void SvxCharBasePage::SetPrevFontEscapement( sal_uInt8 nProp, sal_uInt8 nEscProp, short nEsc ) { setPrevFontEscapement(GetPreviewFont(),nProp,nEscProp,nEsc); setPrevFontEscapement(GetPreviewCJKFont(),nProp,nEscProp,nEsc); @@ -538,16 +538,16 @@ struct SvxCharNamePage_Impl String m_aNoStyleText; String m_aTransparentText; const FontList* m_pFontList; - USHORT m_nExtraEntryPos; - BOOL m_bMustDelete; - BOOL m_bInSearchMode; + sal_uInt16 m_nExtraEntryPos; + sal_Bool m_bMustDelete; + sal_Bool m_bInSearchMode; SvxCharNamePage_Impl() : m_pFontList ( NULL ), m_nExtraEntryPos( LISTBOX_ENTRY_NOTFOUND ), - m_bMustDelete ( FALSE ), - m_bInSearchMode ( FALSE ) + m_bMustDelete ( sal_False ), + m_bInSearchMode ( sal_False ) { m_aUpdateTimer.SetTimeout( 350 ); @@ -682,9 +682,9 @@ SvxCharNamePage::SvxCharNamePage( Window* pParent, const SfxItemSet& rInSet ) : FreeResource(); - m_pWestFontLanguageLB->SetLanguageList( LANG_LIST_WESTERN, TRUE, FALSE, TRUE ); - m_pEastFontLanguageLB->SetLanguageList( LANG_LIST_CJK, TRUE, FALSE, TRUE ); - m_pCTLFontLanguageLB->SetLanguageList( LANG_LIST_CTL, TRUE, FALSE, TRUE ); + m_pWestFontLanguageLB->SetLanguageList( LANG_LIST_WESTERN, sal_True, sal_False, sal_True ); + m_pEastFontLanguageLB->SetLanguageList( LANG_LIST_CJK, sal_True, sal_False, sal_True ); + m_pCTLFontLanguageLB->SetLanguageList( LANG_LIST_CTL, sal_True, sal_False, sal_True ); Initialize(); } @@ -757,7 +757,7 @@ void SvxCharNamePage::Initialize() bKillTable = true; } - m_pColorLB->SetUpdateMode( FALSE ); + m_pColorLB->SetUpdateMode( sal_False ); { SfxPoolItem* pDummy; @@ -773,7 +773,7 @@ void SvxCharNamePage::Initialize() m_pColorLB->InsertEntry( pEntry->GetColor(), pEntry->GetName() ); } - m_pColorLB->SetUpdateMode( TRUE ); + m_pColorLB->SetUpdateMode( sal_True ); if ( bKillTable ) delete pColorTable; @@ -816,14 +816,14 @@ const FontList* SvxCharNamePage::GetFontList() const DBG_ASSERT(NULL != ( (SvxFontListItem*)pItem )->GetFontList(), "Where is the font list?"); m_pImpl->m_pFontList = static_cast<const SvxFontListItem*>(pItem )->GetFontList()->Clone(); - m_pImpl->m_bMustDelete = TRUE; + m_pImpl->m_bMustDelete = sal_True; } } if(!m_pImpl->m_pFontList) { m_pImpl->m_pFontList = new FontList( Application::GetDefaultDevice() ); - m_pImpl->m_bMustDelete = TRUE; + m_pImpl->m_bMustDelete = sal_True; } } @@ -839,14 +839,14 @@ namespace const FontStyleBox* _pFontStyleLB, const FontSizeBox* _pFontSizeLB, const FontList* _pFontList, - USHORT _nFontWhich, - USHORT _nFontHeightWhich) + sal_uInt16 _nFontWhich, + sal_uInt16 _nFontHeightWhich) { Size aSize = _rFont.GetSize(); aSize.Width() = 0; FontInfo aFontInfo; String sFontName(_pFontNameLB->GetText()); - BOOL bFontAvailable = _pFontList->IsAvailable( sFontName ); + sal_Bool bFontAvailable = _pFontList->IsAvailable( sFontName ); if(bFontAvailable || _pFontNameLB->GetSavedValue() != sFontName) aFontInfo = _pFontList->Get( sFontName, _pFontStyleLB->GetText() ); else @@ -1008,7 +1008,7 @@ void SvxCharNamePage::Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp FontSizeBox* pSizeBox = NULL; FixedText* pLangFT = NULL; SvxLanguageBox* pLangBox = NULL; - USHORT nWhich = 0; + sal_uInt16 nWhich = 0; switch ( eLangGrp ) { @@ -1141,7 +1141,7 @@ void SvxCharNamePage::Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp if( rItem.GetProp() != 100 || SFX_MAPUNIT_RELATIVE != rItem.GetPropUnit() ) { - BOOL bPtRel = SFX_MAPUNIT_POINT == rItem.GetPropUnit(); + sal_Bool bPtRel = SFX_MAPUNIT_POINT == rItem.GetPropUnit(); pSizeBox->SetPtRelative( bPtRel ); pSizeBox->SetValue( bPtRel ? ((short)rItem.GetProp()) * 10 : rItem.GetProp() ); } @@ -1214,16 +1214,16 @@ void SvxCharNamePage::Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp // ----------------------------------------------------------------------- -BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp ) +sal_Bool SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; FontNameBox* pNameBox = NULL; FontStyleBox* pStyleBox = NULL; FontSizeBox* pSizeBox = NULL; SvxLanguageBox* pLangBox = NULL; - USHORT nWhich = 0; - USHORT nSlot = 0; + sal_uInt16 nWhich = 0; + sal_uInt16 nSlot = 0; switch ( eLangGrp ) { @@ -1263,7 +1263,7 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp const String& rFontName = pNameBox->GetText(); const FontList* pFontList = GetFontList(); String aStyleBoxText =pStyleBox->GetText(); - USHORT nEntryPos = pStyleBox->GetEntryPos( aStyleBoxText ); + sal_uInt16 nEntryPos = pStyleBox->GetEntryPos( aStyleBoxText ); if ( nEntryPos >= m_pImpl->m_nExtraEntryPos ) aStyleBoxText.Erase(); FontInfo aInfo( pFontList->Get( rFontName, aStyleBoxText ) ); @@ -1283,7 +1283,7 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp bChanged = !pNameBox->GetSavedValue().Len(); if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && ( (SvxFontItem*)pItem )->GetFamilyName() != aFontItem.GetFamilyName() ) bChanged = true; @@ -1292,11 +1292,11 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp rSet.Put( aFontItem ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) rSet.ClearItem( nWhich ); - bChanged = TRUE; + bChanged = sal_True; switch ( eLangGrp ) { case Western : nSlot = SID_ATTR_CHAR_WEIGHT; break; @@ -1328,9 +1328,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp } if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && ( (SvxWeightItem*)pItem )->GetValue() != aWeightItem.GetValue() ) - bChanged = TRUE; + bChanged = true; if ( nEntryPos >= m_pImpl->m_nExtraEntryPos ) bChanged = ( nEntryPos == m_pImpl->m_nExtraEntryPos ); @@ -1340,9 +1340,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp if ( bChanged && aText.Len() ) { rSet.Put( aWeightItem ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -1364,7 +1364,7 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp const SvxPostureItem& rItem = *( (const SvxPostureItem*)pOld ); if ( rItem.GetValue() == aPostureItem.GetValue() ) - bChanged = FALSE; + bChanged = false; } if ( !bChanged ) @@ -1373,11 +1373,11 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp if ( m_pImpl->m_bInSearchMode && bChanged && aInfo.GetItalic() == ITALIC_NONE && aInfo.GetWeight() != WEIGHT_NORMAL ) - bChanged = FALSE; + bChanged = false; } if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && ( (SvxPostureItem*)pItem )->GetValue() != aPostureItem.GetValue() ) bChanged = true; @@ -1387,9 +1387,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp if ( bChanged && aText.Len() ) { rSet.Put( aPostureItem ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; // FontSize @@ -1417,11 +1417,11 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp bChanged = ( nSize != nSavedSize ); if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET ) + pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET ) { float fSize = (float)nSize / 10; long nVal = CalcToUnit( fSize, rSet.GetPool()->GetMetric( nWhich ) ); - if ( ( (SvxFontHeightItem*)pItem )->GetHeight() != (UINT32)nVal ) + if ( ( (SvxFontHeightItem*)pItem )->GetHeight() != (sal_uInt32)nVal ) bChanged = true; } @@ -1437,9 +1437,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp SvxFontHeightItem aHeight( 240, 100, nWhich ); if ( pSizeBox->IsPtRelative() ) - aHeight.SetHeight( rOldItem.GetHeight(), (USHORT)( nSize / 10 ), SFX_MAPUNIT_POINT, eUnit ); + aHeight.SetHeight( rOldItem.GetHeight(), (sal_uInt16)( nSize / 10 ), SFX_MAPUNIT_POINT, eUnit ); else - aHeight.SetHeight( rOldItem.GetHeight(), (USHORT)nSize, SFX_MAPUNIT_RELATIVE ); + aHeight.SetHeight( rOldItem.GetHeight(), (sal_uInt16)nSize, SFX_MAPUNIT_RELATIVE ); rSet.Put( aHeight ); } else @@ -1447,9 +1447,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp float fSize = (float)nSize / 10; rSet.Put( SvxFontHeightItem( CalcToUnit( fSize, eUnit ), 100, nWhich ) ); } - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -1461,15 +1461,15 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp } nWhich = GetWhich( nSlot ); pOld = GetOldItem( rSet, nSlot ); - USHORT nLangPos = pLangBox->GetSelectEntryPos(); - LanguageType eLangType = (LanguageType)(ULONG)pLangBox->GetEntryData( nLangPos ); + sal_uInt16 nLangPos = pLangBox->GetSelectEntryPos(); + LanguageType eLangType = (LanguageType)(sal_uLong)pLangBox->GetEntryData( nLangPos ); if ( pOld ) { const SvxLanguageItem& rItem = *( (const SvxLanguageItem*)pOld ); if ( nLangPos == LISTBOX_ENTRY_NOTFOUND || eLangType == (LanguageType)rItem.GetValue() ) - bChanged = FALSE; + bChanged = false; } if ( !bChanged ) @@ -1478,9 +1478,9 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp if ( bChanged && nLangPos != LISTBOX_ENTRY_NOTFOUND ) { rSet.Put( SvxLanguageItem( eLangType, nWhich ) ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; return bModified; @@ -1490,7 +1490,7 @@ BOOL SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp void SvxCharNamePage::ResetColor_Impl( const SfxItemSet& rSet ) { - USHORT nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); SfxItemState eState = rSet.GetItemState( nWhich ); switch ( eState ) @@ -1520,7 +1520,7 @@ void SvxCharNamePage::ResetColor_Impl( const SfxItemSet& rSet ) rCJKFont.SetColor( aColor.GetColor() == COL_AUTO ? Color(COL_BLACK) : aColor ); rCTLFont.SetColor( aColor.GetColor() == COL_AUTO ? Color(COL_BLACK) : aColor ); m_aPreviewWin.Invalidate(); - USHORT nSelPos = m_pColorLB->GetEntryPos( aColor ); + sal_uInt16 nSelPos = m_pColorLB->GetEntryPos( aColor ); if ( nSelPos == LISTBOX_ENTRY_NOTFOUND && aColor == Color( COL_TRANSPARENT ) ) nSelPos = m_pColorLB->GetEntryPos( m_pImpl->m_aTransparentText ); @@ -1542,47 +1542,6 @@ void SvxCharNamePage::ResetColor_Impl( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharNamePage::FillItemSetColor_Impl( SfxItemSet& rSet ) -{ - USHORT nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); - const SvxColorItem* pOld = (const SvxColorItem*)GetOldItem( rSet, SID_ATTR_CHAR_COLOR ); - const SvxColorItem* pItem = NULL; - BOOL bChanged = TRUE; - const SfxItemSet* pExampleSet = GetTabDialog() ? GetTabDialog()->GetExampleSet() : NULL; - const SfxItemSet& rOldSet = GetItemSet(); - - Color aSelectedColor; - if ( m_pColorLB->GetSelectEntry() == m_pImpl->m_aTransparentText ) - aSelectedColor = Color( COL_TRANSPARENT ); - else - aSelectedColor = m_pColorLB->GetSelectEntryColor(); - - if ( pOld && pOld->GetValue() == aSelectedColor ) - bChanged = FALSE; - - if ( !bChanged ) - bChanged = ( m_pColorLB->GetSavedValue() == LISTBOX_ENTRY_NOTFOUND ); - - if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, (const SfxPoolItem**)&pItem ) == SFX_ITEM_SET && - ( (SvxColorItem*)pItem )->GetValue() != aSelectedColor ) - bChanged = TRUE; - - BOOL bModified = FALSE; - - if ( bChanged && m_pColorLB->GetSelectEntryPos() != LISTBOX_ENTRY_NOTFOUND ) - { - rSet.Put( SvxColorItem( aSelectedColor, nWhich ) ); - bModified = TRUE; - } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) - CLEARTITEM; - - return bModified; -} - -// ----------------------------------------------------------------------- - IMPL_LINK( SvxCharNamePage, UpdateHdl_Impl, Timer*, EMPTYARG ) { UpdatePreview_Impl(); @@ -1649,7 +1608,7 @@ SfxTabPage* SvxCharNamePage::Create( Window* pParent, const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -USHORT* SvxCharNamePage::GetRanges() +sal_uInt16* SvxCharNamePage::GetRanges() { return pNameRanges; } @@ -1670,12 +1629,11 @@ void SvxCharNamePage::Reset( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharNamePage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxCharNamePage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FillItemSet_Impl( rSet, Western ); + sal_Bool bModified = FillItemSet_Impl( rSet, Western ); bModified |= FillItemSet_Impl( rSet, Asian ); bModified |= FillItemSet_Impl( rSet, Ctl ); -//! bModified |= FillItemSetColor_Impl( rSet ); return bModified; } @@ -1688,13 +1646,13 @@ void SvxCharNamePage::SetFontList( const SvxFontListItem& rItem ) delete m_pImpl->m_pFontList; } m_pImpl->m_pFontList = rItem.GetFontList()->Clone(); - m_pImpl->m_bMustDelete = TRUE; + m_pImpl->m_bMustDelete = sal_True; } // ----------------------------------------------------------------------- namespace { - void enableRelativeMode( SvxCharNamePage* _pPage, FontSizeBox* _pFontSizeLB, USHORT _nHeightWhich ) + void enableRelativeMode( SvxCharNamePage* _pPage, FontSizeBox* _pFontSizeLB, sal_uInt16 _nHeightWhich ) { _pFontSizeLB->EnableRelativeMode( 5, 995, 5 ); // min 5%, max 995%, step 5 @@ -1724,10 +1682,10 @@ void SvxCharNamePage::EnableRelativeMode() void SvxCharNamePage::EnableSearchMode() { - m_pImpl->m_bInSearchMode = TRUE; + m_pImpl->m_bInSearchMode = sal_True; } // ----------------------------------------------------------------------- -void SvxCharNamePage::DisableControls( USHORT nDisable ) +void SvxCharNamePage::DisableControls( sal_uInt16 nDisable ) { if ( DISABLE_LANGUAGE & nDisable ) { @@ -1767,7 +1725,7 @@ void SvxCharNamePage::PageCreated (SfxAllItemSet aSet) if (pFlagItem) { - UINT32 nFlags=pFlagItem->GetValue(); + sal_uInt32 nFlags=pFlagItem->GetValue(); if ( ( nFlags & SVX_RELATIVE_MODE ) == SVX_RELATIVE_MODE ) EnableRelativeMode(); if ( ( nFlags & SVX_PREVIEW_CHARACTER ) == SVX_PREVIEW_CHARACTER ) @@ -1837,7 +1795,7 @@ void SvxCharEffectsPage::Initialize() // HTML-Mode const SfxPoolItem* pItem; SfxObjectShell* pShell; - if ( SFX_ITEM_SET == GetItemSet().GetItemState( SID_HTML_MODE, FALSE, &pItem ) || + if ( SFX_ITEM_SET == GetItemSet().GetItemState( SID_HTML_MODE, sal_False, &pItem ) || ( NULL != ( pShell = SfxObjectShell::Current() ) && NULL != ( pItem = pShell->GetItem( SID_HTML_MODE ) ) ) ) { @@ -1867,9 +1825,9 @@ void SvxCharEffectsPage::Initialize() bKillTable = true; } - m_aUnderlineColorLB.SetUpdateMode( FALSE ); - m_aOverlineColorLB.SetUpdateMode( FALSE ); - m_aFontColorLB.SetUpdateMode( FALSE ); + m_aUnderlineColorLB.SetUpdateMode( sal_False ); + m_aOverlineColorLB.SetUpdateMode( sal_False ); + m_aFontColorLB.SetUpdateMode( sal_False ); { SfxPoolItem* pDummy; @@ -1890,9 +1848,9 @@ void SvxCharEffectsPage::Initialize() m_aFontColorLB.InsertEntry( pEntry->GetColor(), pEntry->GetName() ); } - m_aUnderlineColorLB.SetUpdateMode( TRUE ); - m_aOverlineColorLB.SetUpdateMode( TRUE ); - m_aFontColorLB.SetUpdateMode( TRUE ); + m_aUnderlineColorLB.SetUpdateMode( sal_True ); + m_aOverlineColorLB.SetUpdateMode( sal_True ); + m_aFontColorLB.SetUpdateMode( sal_True ); m_aFontColorLB.SetSelectHdl( LINK( this, SvxCharEffectsPage, ColorBoxSelectHdl_Impl ) ); if ( bKillTable ) @@ -1944,12 +1902,12 @@ void SvxCharEffectsPage::UpdatePreview_Impl() SvxFont& rCJKFont = GetPreviewCJKFont(); SvxFont& rCTLFont = GetPreviewCTLFont(); - USHORT nPos = m_aUnderlineLB.GetSelectEntryPos(); - FontUnderline eUnderline = (FontUnderline)(ULONG)m_aUnderlineLB.GetEntryData( nPos ); + sal_uInt16 nPos = m_aUnderlineLB.GetSelectEntryPos(); + FontUnderline eUnderline = (FontUnderline)(sal_uLong)m_aUnderlineLB.GetEntryData( nPos ); nPos = m_aOverlineLB.GetSelectEntryPos(); - FontUnderline eOverline = (FontUnderline)(ULONG)m_aOverlineLB.GetEntryData( nPos ); + FontUnderline eOverline = (FontUnderline)(sal_uLong)m_aOverlineLB.GetEntryData( nPos ); nPos = m_aStrikeoutLB.GetSelectEntryPos(); - FontStrikeout eStrikeout = (FontStrikeout)(ULONG)m_aStrikeoutLB.GetEntryData( nPos ); + FontStrikeout eStrikeout = (FontStrikeout)(sal_uLong)m_aStrikeoutLB.GetEntryData( nPos ); rFont.SetUnderline( eUnderline ); rCJKFont.SetUnderline( eUnderline ); rCTLFont.SetUnderline( eUnderline ); @@ -1963,14 +1921,14 @@ void SvxCharEffectsPage::UpdatePreview_Impl() rCTLFont.SetStrikeout( eStrikeout ); nPos = m_aPositionLB.GetSelectEntryPos(); - BOOL bUnder = ( CHRDLG_POSITION_UNDER == (ULONG)m_aPositionLB.GetEntryData( nPos ) ); + sal_Bool bUnder = ( CHRDLG_POSITION_UNDER == (sal_uLong)m_aPositionLB.GetEntryData( nPos ) ); FontEmphasisMark eMark = (FontEmphasisMark)m_aEmphasisLB.GetSelectEntryPos(); eMark |= bUnder ? EMPHASISMARK_POS_BELOW : EMPHASISMARK_POS_ABOVE; rFont.SetEmphasisMark( eMark ); rCJKFont.SetEmphasisMark( eMark ); rCTLFont.SetEmphasisMark( eMark ); - USHORT nRelief = m_aReliefLB.GetSelectEntryPos(); + sal_uInt16 nRelief = m_aReliefLB.GetSelectEntryPos(); if(LISTBOX_ENTRY_NOTFOUND != nRelief) { rFont.SetRelief( (FontRelief)nRelief ); @@ -1986,7 +1944,7 @@ void SvxCharEffectsPage::UpdatePreview_Impl() rCJKFont.SetShadow( rFont.IsShadow() ); rCTLFont.SetShadow( rFont.IsShadow() ); - USHORT nCapsPos = m_aEffects2LB.GetSelectEntryPos(); + sal_uInt16 nCapsPos = m_aEffects2LB.GetSelectEntryPos(); if ( nCapsPos != LISTBOX_ENTRY_NOTFOUND ) { rFont.SetCaseMap( (SvxCaseMap)nCapsPos ); @@ -1995,7 +1953,7 @@ void SvxCharEffectsPage::UpdatePreview_Impl() rCTLFont.SetCaseMap( static_cast<SvxCaseMap>( nCapsPos == SVX_CASEMAP_KAPITAELCHEN ? SVX_CASEMAP_NOT_MAPPED : (SvxCaseMap)nCapsPos) ); } - BOOL bWordLine = m_aIndividualWordsBtn.IsChecked(); + sal_Bool bWordLine = m_aIndividualWordsBtn.IsChecked(); rFont.SetWordLineMode( bWordLine ); rCJKFont.SetWordLineMode( bWordLine ); rCTLFont.SetWordLineMode( bWordLine ); @@ -2009,7 +1967,7 @@ void SvxCharEffectsPage::SetCaseMap_Impl( SvxCaseMap eCaseMap ) { if ( SVX_CASEMAP_END > eCaseMap ) m_aEffects2LB.SelectEntryPos( - sal::static_int_cast< USHORT >( eCaseMap ) ); + sal::static_int_cast< sal_uInt16 >( eCaseMap ) ); else { m_aEffects2LB.SetNoSelection(); @@ -2023,7 +1981,7 @@ void SvxCharEffectsPage::SetCaseMap_Impl( SvxCaseMap eCaseMap ) void SvxCharEffectsPage::ResetColor_Impl( const SfxItemSet& rSet ) { - USHORT nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); SfxItemState eState = rSet.GetItemState( nWhich ); switch ( eState ) @@ -2057,7 +2015,7 @@ void SvxCharEffectsPage::ResetColor_Impl( const SfxItemSet& rSet ) rCTLFont.SetColor( aColor.GetColor() == COL_AUTO ? Color(COL_BLACK) : aColor ); m_aPreviewWin.Invalidate(); - USHORT nSelPos = m_aFontColorLB.GetEntryPos( aColor ); + sal_uInt16 nSelPos = m_aFontColorLB.GetEntryPos( aColor ); if ( nSelPos == LISTBOX_ENTRY_NOTFOUND && aColor == Color( COL_TRANSPARENT ) ) nSelPos = m_aFontColorLB.GetEntryPos( m_aTransparentColorName ); @@ -2079,12 +2037,12 @@ void SvxCharEffectsPage::ResetColor_Impl( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharEffectsPage::FillItemSetColor_Impl( SfxItemSet& rSet ) +sal_Bool SvxCharEffectsPage::FillItemSetColor_Impl( SfxItemSet& rSet ) { - USHORT nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_COLOR ); const SvxColorItem* pOld = (const SvxColorItem*)GetOldItem( rSet, SID_ATTR_CHAR_COLOR ); const SvxColorItem* pItem = NULL; - BOOL bChanged = TRUE; + sal_Bool bChanged = sal_True; const SfxItemSet* pExampleSet = GetTabDialog() ? GetTabDialog()->GetExampleSet() : NULL; const SfxItemSet& rOldSet = GetItemSet(); @@ -2095,24 +2053,24 @@ BOOL SvxCharEffectsPage::FillItemSetColor_Impl( SfxItemSet& rSet ) aSelectedColor = m_aFontColorLB.GetSelectEntryColor(); if ( pOld && pOld->GetValue() == aSelectedColor ) - bChanged = FALSE; + bChanged = sal_False; if ( !bChanged ) bChanged = ( m_aFontColorLB.GetSavedValue() == LISTBOX_ENTRY_NOTFOUND ); if ( !bChanged && pExampleSet && - pExampleSet->GetItemState( nWhich, FALSE, (const SfxPoolItem**)&pItem ) == SFX_ITEM_SET && + pExampleSet->GetItemState( nWhich, sal_False, (const SfxPoolItem**)&pItem ) == SFX_ITEM_SET && ( (SvxColorItem*)pItem )->GetValue() != aSelectedColor ) - bChanged = TRUE; + bChanged = sal_True; - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if ( bChanged && m_aFontColorLB.GetSelectEntryPos() != LISTBOX_ENTRY_NOTFOUND ) { rSet.Put( SvxColorItem( aSelectedColor, nWhich ) ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; return bModified; @@ -2124,24 +2082,24 @@ IMPL_LINK( SvxCharEffectsPage, SelectHdl_Impl, ListBox*, pBox ) { if ( &m_aEmphasisLB == pBox ) { - USHORT nEPos = m_aEmphasisLB.GetSelectEntryPos(); - BOOL bEnable = ( nEPos > 0 && nEPos != LISTBOX_ENTRY_NOTFOUND ); + sal_uInt16 nEPos = m_aEmphasisLB.GetSelectEntryPos(); + sal_Bool bEnable = ( nEPos > 0 && nEPos != LISTBOX_ENTRY_NOTFOUND ); m_aPositionFT.Enable( bEnable ); m_aPositionLB.Enable( bEnable ); } else if( &m_aReliefLB == pBox) { - BOOL bEnable = ( pBox->GetSelectEntryPos() == 0 ); + sal_Bool bEnable = ( pBox->GetSelectEntryPos() == 0 ); m_aOutlineBtn.Enable( bEnable ); m_aShadowBtn.Enable( bEnable ); } else if ( &m_aPositionLB != pBox ) { - USHORT nUPos = m_aUnderlineLB.GetSelectEntryPos(), + sal_uInt16 nUPos = m_aUnderlineLB.GetSelectEntryPos(), nOPos = m_aOverlineLB.GetSelectEntryPos(), nSPos = m_aStrikeoutLB.GetSelectEntryPos(); - BOOL bUEnable = ( nUPos > 0 && nUPos != LISTBOX_ENTRY_NOTFOUND ); - BOOL bOEnable = ( nOPos > 0 && nOPos != LISTBOX_ENTRY_NOTFOUND ); + sal_Bool bUEnable = ( nUPos > 0 && nUPos != LISTBOX_ENTRY_NOTFOUND ); + sal_Bool bOEnable = ( nOPos > 0 && nOPos != LISTBOX_ENTRY_NOTFOUND ); m_aUnderlineColorFT.Enable( bUEnable ); m_aUnderlineColorLB.Enable( bUEnable ); m_aOverlineColorFT.Enable( bOEnable ); @@ -2219,7 +2177,7 @@ SfxTabPage* SvxCharEffectsPage::Create( Window* pParent, const SfxItemSet& rSet // ----------------------------------------------------------------------- -USHORT* SvxCharEffectsPage::GetRanges() +sal_uInt16* SvxCharEffectsPage::GetRanges() { return pEffectsRanges; } @@ -2232,10 +2190,10 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) SvxFont& rCJKFont = GetPreviewCJKFont(); SvxFont& rCTLFont = GetPreviewCTLFont(); - BOOL bEnable = FALSE; + sal_Bool bEnable = sal_False; // Underline - USHORT nWhich = GetWhich( SID_ATTR_CHAR_UNDERLINE ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_UNDERLINE ); rFont.SetUnderline( UNDERLINE_NONE ); rCJKFont.SetUnderline( UNDERLINE_NONE ); rCTLFont.SetUnderline( UNDERLINE_NONE ); @@ -2257,9 +2215,9 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) if ( eUnderline != UNDERLINE_NONE ) { - for ( USHORT i = 0; i < m_aUnderlineLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < m_aUnderlineLB.GetEntryCount(); ++i ) { - if ( (FontUnderline)(ULONG)m_aUnderlineLB.GetEntryData(i) == eUnderline ) + if ( (FontUnderline)(sal_uLong)m_aUnderlineLB.GetEntryData(i) == eUnderline ) { m_aUnderlineLB.SelectEntryPos(i); bEnable = TRUE; @@ -2268,7 +2226,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) } Color aColor = rItem.GetColor(); - USHORT nPos = m_aUnderlineColorLB.GetEntryPos( aColor ); + sal_uInt16 nPos = m_aUnderlineColorLB.GetEntryPos( aColor ); if ( LISTBOX_ENTRY_NOTFOUND != nPos ) m_aUnderlineColorLB.SelectEntryPos( nPos ); @@ -2314,9 +2272,9 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) if ( eOverline != UNDERLINE_NONE ) { - for ( USHORT i = 0; i < m_aOverlineLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < m_aOverlineLB.GetEntryCount(); ++i ) { - if ( (FontUnderline)(ULONG)m_aOverlineLB.GetEntryData(i) == eOverline ) + if ( (FontUnderline)(sal_uLong)m_aOverlineLB.GetEntryData(i) == eOverline ) { m_aOverlineLB.SelectEntryPos(i); bEnable = TRUE; @@ -2325,7 +2283,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) } Color aColor = rItem.GetColor(); - USHORT nPos = m_aOverlineColorLB.GetEntryPos( aColor ); + sal_uInt16 nPos = m_aOverlineColorLB.GetEntryPos( aColor ); if ( LISTBOX_ENTRY_NOTFOUND != nPos ) m_aOverlineColorLB.SelectEntryPos( nPos ); @@ -2371,9 +2329,9 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) if ( eStrikeout != STRIKEOUT_NONE ) { - for ( USHORT i = 0; i < m_aStrikeoutLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < m_aStrikeoutLB.GetEntryCount(); ++i ) { - if ( (FontStrikeout)(ULONG)m_aStrikeoutLB.GetEntryData(i) == eStrikeout ) + if ( (FontStrikeout)(sal_uLong)m_aStrikeoutLB.GetEntryData(i) == eStrikeout ) { m_aStrikeoutLB.SelectEntryPos(i); bEnable = TRUE; @@ -2427,15 +2385,15 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) rCJKFont.SetEmphasisMark( eMark ); rCTLFont.SetEmphasisMark( eMark ); - m_aEmphasisLB.SelectEntryPos( (USHORT)( eMark & EMPHASISMARK_STYLE ) ); + m_aEmphasisLB.SelectEntryPos( (sal_uInt16)( eMark & EMPHASISMARK_STYLE ) ); eMark &= ~EMPHASISMARK_STYLE; - ULONG nEntryData = ( eMark == EMPHASISMARK_POS_ABOVE ) + sal_uLong nEntryData = ( eMark == EMPHASISMARK_POS_ABOVE ) ? CHRDLG_POSITION_OVER : ( eMark == EMPHASISMARK_POS_BELOW ) ? CHRDLG_POSITION_UNDER : 0; - for ( USHORT i = 0; i < m_aPositionLB.GetEntryCount(); i++ ) + for ( sal_uInt16 i = 0; i < m_aPositionLB.GetEntryCount(); i++ ) { - if ( nEntryData == (ULONG)m_aPositionLB.GetEntryData(i) ) + if ( nEntryData == (sal_uLong)m_aPositionLB.GetEntryData(i) ) { m_aPositionLB.SelectEntryPos(i); break; @@ -2556,7 +2514,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) { const SvxContourItem& rItem = (SvxContourItem&)rSet.Get( nWhich ); m_aOutlineBtn.SetState( (TriState)rItem.GetValue() ); - m_aOutlineBtn.EnableTriState( FALSE ); + m_aOutlineBtn.EnableTriState( sal_False ); break; } } @@ -2585,7 +2543,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) { const SvxShadowedItem& rItem = (SvxShadowedItem&)rSet.Get( nWhich ); m_aShadowBtn.SetState( (TriState)rItem.GetValue() ); - m_aShadowBtn.EnableTriState( FALSE ); + m_aShadowBtn.EnableTriState( sal_False ); break; } } @@ -2614,7 +2572,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) { const SvxBlinkItem& rItem = (SvxBlinkItem&)rSet.Get( nWhich ); m_aBlinkingBtn.SetState( (TriState)rItem.GetValue() ); - m_aBlinkingBtn.EnableTriState( FALSE ); + m_aBlinkingBtn.EnableTriState( sal_False ); break; } } @@ -2642,7 +2600,7 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) { const SvxCharHiddenItem& rItem = (SvxCharHiddenItem&)rSet.Get( nWhich ); m_aHiddenBtn.SetState( (TriState)rItem.GetValue() ); - m_aHiddenBtn.EnableTriState( FALSE ); + m_aHiddenBtn.EnableTriState( sal_False ); break; } } @@ -2673,18 +2631,18 @@ void SvxCharEffectsPage::Reset( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) { const SfxPoolItem* pOld = 0; const SfxItemSet& rOldSet = GetItemSet(); - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; bool bChanged = true; // Underline - USHORT nWhich = GetWhich( SID_ATTR_CHAR_UNDERLINE ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_UNDERLINE ); pOld = GetOldItem( rSet, SID_ATTR_CHAR_UNDERLINE ); - USHORT nPos = m_aUnderlineLB.GetSelectEntryPos(); - FontUnderline eUnder = (FontUnderline)(ULONG)m_aUnderlineLB.GetEntryData( nPos ); + sal_uInt16 nPos = m_aUnderlineLB.GetSelectEntryPos(); + FontUnderline eUnder = (FontUnderline)(sal_uLong)m_aUnderlineLB.GetEntryData( nPos ); if ( pOld ) { @@ -2692,8 +2650,8 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) //! item-state in the 'rOldSet' will be invalid. In this case //! changing the underline style will be allowed if a style is //! selected in the listbox. - BOOL bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && - SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, TRUE ); + sal_Bool bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && + SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, sal_True ); const SvxUnderlineItem& rItem = *( (const SvxUnderlineItem*)pOld ); if ( (FontUnderline)rItem.GetValue() == eUnder && @@ -2709,7 +2667,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( aNewItem ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2718,7 +2676,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) nWhich = GetWhich( SID_ATTR_CHAR_OVERLINE ); pOld = GetOldItem( rSet, SID_ATTR_CHAR_OVERLINE ); nPos = m_aOverlineLB.GetSelectEntryPos(); - FontUnderline eOver = (FontUnderline)(ULONG)m_aOverlineLB.GetEntryData( nPos ); + FontUnderline eOver = (FontUnderline)(sal_uLong)m_aOverlineLB.GetEntryData( nPos ); if ( pOld ) { @@ -2726,8 +2684,8 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) //! item-state in the 'rOldSet' will be invalid. In this case //! changing the underline style will be allowed if a style is //! selected in the listbox. - BOOL bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && - SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, TRUE ); + sal_Bool bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && + SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, sal_True ); const SvxOverlineItem& rItem = *( (const SvxOverlineItem*)pOld ); if ( (FontUnderline)rItem.GetValue() == eOver && @@ -2743,7 +2701,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( aNewItem ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2752,7 +2710,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) nWhich = GetWhich( SID_ATTR_CHAR_STRIKEOUT ); pOld = GetOldItem( rSet, SID_ATTR_CHAR_STRIKEOUT ); nPos = m_aStrikeoutLB.GetSelectEntryPos(); - FontStrikeout eStrike = (FontStrikeout)(ULONG)m_aStrikeoutLB.GetEntryData( nPos ); + FontStrikeout eStrike = (FontStrikeout)(sal_uLong)m_aStrikeoutLB.GetEntryData( nPos ); if ( pOld ) { @@ -2760,8 +2718,8 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) //! item-state in the 'rOldSet' will be invalid. In this case //! changing the strikeout style will be allowed if a style is //! selected in the listbox. - BOOL bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && - SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, TRUE ); + sal_Bool bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && + SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, sal_True ); const SvxCrossedOutItem& rItem = *( (const SvxCrossedOutItem*)pOld ); if ( !m_aStrikeoutLB.IsEnabled() @@ -2774,7 +2732,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxCrossedOutItem( eStrike, nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2799,7 +2757,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxWordLineModeItem( m_aIndividualWordsBtn.IsChecked(), nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2807,12 +2765,12 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) // Emphasis nWhich = GetWhich( SID_ATTR_CHAR_EMPHASISMARK ); pOld = GetOldItem( rSet, SID_ATTR_CHAR_EMPHASISMARK ); - USHORT nMarkPos = m_aEmphasisLB.GetSelectEntryPos(); - USHORT nPosPos = m_aPositionLB.GetSelectEntryPos(); + sal_uInt16 nMarkPos = m_aEmphasisLB.GetSelectEntryPos(); + sal_uInt16 nPosPos = m_aPositionLB.GetSelectEntryPos(); FontEmphasisMark eMark = (FontEmphasisMark)nMarkPos; if ( m_aPositionLB.IsEnabled() ) { - eMark |= ( CHRDLG_POSITION_UNDER == (ULONG)m_aPositionLB.GetEntryData( nPosPos ) ) + eMark |= ( CHRDLG_POSITION_UNDER == (sal_uLong)m_aPositionLB.GetEntryData( nPosPos ) ) ? EMPHASISMARK_POS_BELOW : EMPHASISMARK_POS_ABOVE; } @@ -2835,7 +2793,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxEmphasisMarkItem( eMark, nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2845,7 +2803,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) pOld = GetOldItem( rSet, SID_ATTR_CHAR_CASEMAP ); SvxCaseMap eCaseMap = SVX_CASEMAP_NOT_MAPPED; bool bChecked = false; - USHORT nCapsPos = m_aEffects2LB.GetSelectEntryPos(); + sal_uInt16 nCapsPos = m_aEffects2LB.GetSelectEntryPos(); if ( nCapsPos != LISTBOX_ENTRY_NOTFOUND ) { eCaseMap = (SvxCaseMap)nCapsPos; @@ -2858,8 +2816,8 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) //! item-state in the 'rOldSet' will be invalid. In this case //! changing the effect style will be allowed if a style is //! selected in the listbox. - BOOL bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && - SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, TRUE ); + sal_Bool bAllowChg = LISTBOX_ENTRY_NOTFOUND != nPos && + SFX_ITEM_DEFAULT > rOldSet.GetItemState( nWhich, sal_True ); const SvxCaseMapItem& rItem = *( (const SvxCaseMapItem*)pOld ); if ( (SvxCaseMap)rItem.GetValue() == eCaseMap && !bAllowChg ) @@ -2871,7 +2829,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxCaseMapItem( eCaseMap, nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2899,7 +2857,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) bChanged = false; } - if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && !StateToAttr( eState ) && ( (SvxContourItem*)pItem )->GetValue() ) bChanged = true; @@ -2908,7 +2866,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxContourItem( StateToAttr( eState ), nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2925,16 +2883,16 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) bChanged = false; } - if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && !StateToAttr( eState ) && ( (SvxShadowedItem*)pItem )->GetValue() ) bChanged = true; if ( bChanged && eState != STATE_DONTKNOW ) { rSet.Put( SvxShadowedItem( StateToAttr( eState ), nWhich ) ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bChanged = true; @@ -2951,7 +2909,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) bChanged = false; } - if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && !StateToAttr( eState ) && ( (SvxBlinkItem*)pItem )->GetValue() ) bChanged = true; @@ -2960,7 +2918,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxBlinkItem( StateToAttr( eState ), nWhich ) ); bModified = true; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; // Hidden @@ -2976,16 +2934,16 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) bChanged = false; } - if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, FALSE, &pItem ) == SFX_ITEM_SET && + if ( !bChanged && pExampleSet && pExampleSet->GetItemState( nWhich, sal_False, &pItem ) == SFX_ITEM_SET && !StateToAttr( eState ) && ( (SvxCharHiddenItem*)pItem )->GetValue() ) bChanged = true; if ( bChanged && eState != STATE_DONTKNOW ) { rSet.Put( SvxCharHiddenItem( StateToAttr( eState ), nWhich ) ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; bModified |= FillItemSetColor_Impl( rSet ); @@ -2993,7 +2951,7 @@ BOOL SvxCharEffectsPage::FillItemSet( SfxItemSet& rSet ) return bModified; } -void SvxCharEffectsPage::DisableControls( USHORT nDisable ) +void SvxCharEffectsPage::DisableControls( sal_uInt16 nDisable ) { if ( ( DISABLE_CASEMAP & nDisable ) == DISABLE_CASEMAP ) { @@ -3027,7 +2985,7 @@ void SvxCharEffectsPage::EnableFlash() // ----------------------------------------------------------------------- void SvxCharEffectsPage::SetPreviewBackgroundToCharacter() { - m_bPreviewBackgroundToCharacter = TRUE; + m_bPreviewBackgroundToCharacter = sal_True; } // ----------------------------------------------------------------------- @@ -3040,7 +2998,7 @@ void SvxCharEffectsPage::PageCreated (SfxAllItemSet aSet) if (pFlagItem) { - UINT32 nFlags=pFlagItem->GetValue(); + sal_uInt32 nFlags=pFlagItem->GetValue(); if ( ( nFlags & SVX_ENABLE_FLASH ) == SVX_ENABLE_FLASH ) EnableFlash(); if ( ( nFlags & SVX_PREVIEW_CHARACTER ) == SVX_PREVIEW_CHARACTER ) @@ -3082,8 +3040,8 @@ SvxCharPositionPage::SvxCharPositionPage( Window* pParent, const SfxItemSet& rIn m_nSubEsc ( (short)DFLT_ESC_SUB ), m_nScaleWidthItemSetVal ( 100 ), m_nScaleWidthInitialVal ( 100 ), - m_nSuperProp ( (BYTE)DFLT_ESC_PROP ), - m_nSubProp ( (BYTE)DFLT_ESC_PROP ) + m_nSuperProp ( (sal_uInt8)DFLT_ESC_PROP ), + m_nSubProp ( (sal_uInt8)DFLT_ESC_PROP ) { FreeResource(); Initialize(); @@ -3133,14 +3091,14 @@ void SvxCharPositionPage::Initialize() // ----------------------------------------------------------------------- -void SvxCharPositionPage::UpdatePreview_Impl( BYTE nProp, BYTE nEscProp, short nEsc ) +void SvxCharPositionPage::UpdatePreview_Impl( sal_uInt8 nProp, sal_uInt8 nEscProp, short nEsc ) { SetPrevFontEscapement( nProp, nEscProp, nEsc ); } // ----------------------------------------------------------------------- -void SvxCharPositionPage::SetEscapement_Impl( USHORT nEsc ) +void SvxCharPositionPage::SetEscapement_Impl( sal_uInt16 nEsc ) { SvxEscapementItem aEscItm( (SvxEscapement)nEsc, SID_ATTR_CHAR_ESCAPEMENT ); @@ -3190,7 +3148,7 @@ void SvxCharPositionPage::SetEscapement_Impl( USHORT nEsc ) IMPL_LINK( SvxCharPositionPage, PositionHdl_Impl, RadioButton*, pBtn ) { - USHORT nEsc = SVX_ESCAPEMENT_OFF; // also when pBtn == NULL + sal_uInt16 nEsc = SVX_ESCAPEMENT_OFF; // also when pBtn == NULL if ( &m_aHighPosBtn == pBtn ) nEsc = SVX_ESCAPEMENT_SUPERSCRIPT; @@ -3205,9 +3163,9 @@ IMPL_LINK( SvxCharPositionPage, PositionHdl_Impl, RadioButton*, pBtn ) IMPL_LINK( SvxCharPositionPage, RotationHdl_Impl, RadioButton*, pBtn ) { - BOOL bEnable = FALSE; + sal_Bool bEnable = sal_False; if (&m_a90degRB == pBtn || &m_a270degRB == pBtn) - bEnable = TRUE; + bEnable = sal_True; else OSL_ENSURE( &m_a0degRB == pBtn, "unexpected button" ); m_aFitToLineCB.Enable( bEnable ); @@ -3218,7 +3176,7 @@ IMPL_LINK( SvxCharPositionPage, RotationHdl_Impl, RadioButton*, pBtn ) IMPL_LINK( SvxCharPositionPage, FontModifyHdl_Impl, MetricField*, EMPTYARG ) { - BYTE nEscProp = (BYTE)m_aFontSizeEdit.GetValue(); + sal_uInt8 nEscProp = (sal_uInt8)m_aFontSizeEdit.GetValue(); short nEsc = (short)m_aHighLowEdit.GetValue(); nEsc *= m_aLowPosBtn.IsChecked() ? -1 : 1; UpdatePreview_Impl( 100, nEscProp, nEsc ); @@ -3247,7 +3205,7 @@ IMPL_LINK( SvxCharPositionPage, FitToLineHdl_Impl, CheckBox*, pBox ) { if ( &m_aFitToLineCB == pBox) { - UINT16 nVal = m_nScaleWidthInitialVal; + sal_uInt16 nVal = m_nScaleWidthInitialVal; if (m_aFitToLineCB.IsChecked()) nVal = m_nScaleWidthItemSetVal; m_aScaleWidthMF.SetValue( nVal ); @@ -3342,9 +3300,9 @@ IMPL_LINK( SvxCharPositionPage, LoseFocusHdl_Impl, MetricField*, pField ) else if ( &m_aFontSizeEdit == pField ) { if ( bLow ) - m_nSubProp = (BYTE)m_aFontSizeEdit.GetValue(); + m_nSubProp = (sal_uInt8)m_aFontSizeEdit.GetValue(); else - m_nSuperProp = (BYTE)m_aFontSizeEdit.GetValue(); + m_nSuperProp = (sal_uInt8)m_aFontSizeEdit.GetValue(); } return 0; } @@ -3353,7 +3311,7 @@ IMPL_LINK( SvxCharPositionPage, LoseFocusHdl_Impl, MetricField*, pField ) IMPL_LINK( SvxCharPositionPage, ScaleWidthModifyHdl_Impl, MetricField*, EMPTYARG ) { - m_aPreviewWin.SetFontWidthScale( USHORT( m_aScaleWidthMF.GetValue() ) ); + m_aPreviewWin.SetFontWidthScale( sal_uInt16( m_aScaleWidthMF.GetValue() ) ); return 0; } @@ -3394,7 +3352,7 @@ SfxTabPage* SvxCharPositionPage::Create( Window* pParent, const SfxItemSet& rSet // ----------------------------------------------------------------------- -USHORT* SvxCharPositionPage::GetRanges() +sal_uInt16* SvxCharPositionPage::GetRanges() { return pPositionRanges; } @@ -3408,13 +3366,13 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) { m_nSuperEsc = (short)sUser.GetToken( 0 ).ToInt32(); m_nSubEsc = (short)sUser.GetToken( 1 ).ToInt32(); - m_nSuperProp = (BYTE)sUser.GetToken( 2 ).ToInt32(); - m_nSubProp = (BYTE)sUser.GetToken( 3 ).ToInt32(); + m_nSuperProp = (sal_uInt8)sUser.GetToken( 2 ).ToInt32(); + m_nSubProp = (sal_uInt8)sUser.GetToken( 3 ).ToInt32(); } short nEsc = 0; - BYTE nEscProp = 100; - BYTE nProp = 100; + sal_uInt8 nEscProp = 100; + sal_uInt8 nProp = 100; m_aHighLowFT.Disable(); m_aHighLowEdit.Disable(); @@ -3424,7 +3382,7 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) SvxFont& rFont = GetPreviewFont(); SvxFont& rCJKFont = GetPreviewCJKFont(); SvxFont& rCTLFont = GetPreviewCTLFont(); - USHORT nWhich = GetWhich( SID_ATTR_CHAR_ESCAPEMENT ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_ESCAPEMENT ); if ( rSet.GetItemState( nWhich ) >= SFX_ITEM_DEFAULT ) { @@ -3445,7 +3403,7 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) if ( nEsc > 0 ) { nFac = 1; - m_aHighPosBtn.Check( TRUE ); + m_aHighPosBtn.Check( sal_True ); if ( nEsc == DFLT_ESC_AUTO_SUPER ) { nEsc = DFLT_ESC_SUPER; @@ -3455,7 +3413,7 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) else { nFac = -1; - m_aLowPosBtn.Check( TRUE ); + m_aLowPosBtn.Check( sal_True ); if ( nEsc == DFLT_ESC_AUTO_SUB ) { nEsc = DFLT_ESC_SUB; @@ -3477,8 +3435,8 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) } else { - m_aNormalPosBtn.Check( TRUE ); - m_aHighLowRB.Check( TRUE ); + m_aNormalPosBtn.Check( sal_True ); + m_aHighLowRB.Check( sal_True ); PositionHdl_Impl( NULL ); } //the height has to be set after the handler is called to keep the value also if the escapement is zero @@ -3486,9 +3444,9 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) } else { - m_aHighPosBtn.Check( FALSE ); - m_aNormalPosBtn.Check( FALSE ); - m_aLowPosBtn.Check( FALSE ); + m_aHighPosBtn.Check( sal_False ); + m_aNormalPosBtn.Check( sal_False ); + m_aLowPosBtn.Check( sal_False ); } // BspFont setzen @@ -3546,7 +3504,7 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) m_aPairKerningBtn.Check( rItem.GetValue() ); } else - m_aPairKerningBtn.Check( FALSE ); + m_aPairKerningBtn.Check( sal_False ); // Scale Width nWhich = GetWhich( SID_ATTR_CHAR_SCALEWIDTH ); @@ -3604,13 +3562,13 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) const SvxCharRotateItem& rItem = (SvxCharRotateItem&) rSet.Get( nWhich ); if (rItem.IsBottomToTop()) - m_a90degRB.Check( TRUE ); + m_a90degRB.Check( sal_True ); else if (rItem.IsTopToBotton()) - m_a270degRB.Check( TRUE ); + m_a270degRB.Check( sal_True ); else { DBG_ASSERT( 0 == rItem.GetValue(), "incorrect value" ); - m_a0degRB.Check( TRUE ); + m_a0degRB.Check( sal_True ); } m_aFitToLineCB.Check( rItem.IsFitToLine() ); } @@ -3618,14 +3576,14 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) { if( eState == SFX_ITEM_DONTCARE ) { - m_a0degRB.Check( FALSE ); - m_a90degRB.Check( FALSE ); - m_a270degRB.Check( FALSE ); + m_a0degRB.Check( sal_False ); + m_a90degRB.Check( sal_False ); + m_a270degRB.Check( sal_False ); } else - m_a0degRB.Check( TRUE ); + m_a0degRB.Check( sal_True ); - m_aFitToLineCB.Check( FALSE ); + m_aFitToLineCB.Check( sal_False ); } m_aFitToLineCB.SetClickHdl( aOldLink ); m_aFitToLineCB.Enable( !m_a0degRB.IsChecked() ); @@ -3651,16 +3609,16 @@ void SvxCharPositionPage::Reset( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) { // Position (hoch, normal oder tief) const SfxItemSet& rOldSet = GetItemSet(); - BOOL bModified = FALSE, bChanged = TRUE; - USHORT nWhich = GetWhich( SID_ATTR_CHAR_ESCAPEMENT ); + sal_Bool bModified = sal_False, bChanged = sal_True; + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_ESCAPEMENT ); const SfxPoolItem* pOld = GetOldItem( rSet, SID_ATTR_CHAR_ESCAPEMENT ); const bool bHigh = m_aHighPosBtn.IsChecked(); short nEsc; - BYTE nEscProp; + sal_uInt8 nEscProp; if ( bHigh || m_aLowPosBtn.IsChecked() ) { @@ -3671,7 +3629,7 @@ BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) nEsc = (short)m_aHighLowEdit.Denormalize( m_aHighLowEdit.GetValue() ); nEsc *= bHigh ? 1 : -1; } - nEscProp = (BYTE)m_aFontSizeEdit.Denormalize( m_aFontSizeEdit.GetValue() ); + nEscProp = (sal_uInt8)m_aFontSizeEdit.Denormalize( m_aFontSizeEdit.GetValue() ); } else { @@ -3683,28 +3641,28 @@ BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) { const SvxEscapementItem& rItem = *( (const SvxEscapementItem*)pOld ); if ( rItem.GetEsc() == nEsc && rItem.GetProp() == nEscProp ) - bChanged = FALSE; + bChanged = sal_False; } if ( !bChanged && !m_aHighPosBtn.GetSavedValue() && !m_aNormalPosBtn.GetSavedValue() && !m_aLowPosBtn.GetSavedValue() ) - bChanged = TRUE; + bChanged = sal_True; if ( bChanged && ( m_aHighPosBtn.IsChecked() || m_aNormalPosBtn.IsChecked() || m_aLowPosBtn.IsChecked() ) ) { rSet.Put( SvxEscapementItem( nEsc, nEscProp, nWhich ) ); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; - bChanged = TRUE; + bChanged = sal_True; // Kerning nWhich = GetWhich( SID_ATTR_CHAR_KERNING ); pOld = GetOldItem( rSet, SID_ATTR_CHAR_KERNING ); - USHORT nPos = m_aKerningLB.GetSelectEntryPos(); + sal_uInt16 nPos = m_aKerningLB.GetSelectEntryPos(); short nKerning = 0; SfxMapUnit eUnit = rSet.GetPool()->GetMetric( nWhich ); @@ -3722,23 +3680,23 @@ BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) { const SvxKerningItem& rItem = *( (const SvxKerningItem*)pOld ); if ( rItem.GetValue() == nKerning ) - bChanged = FALSE; + bChanged = sal_False; } if ( !bChanged && ( m_aKerningLB.GetSavedValue() == LISTBOX_ENTRY_NOTFOUND || ( !m_aKerningEdit.GetSavedValue().Len() && m_aKerningEdit.IsEnabled() ) ) ) - bChanged = TRUE; + bChanged = sal_True; if ( bChanged && nPos != LISTBOX_ENTRY_NOTFOUND ) { rSet.Put( SvxKerningItem( nKerning, nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; - bChanged = TRUE; + bChanged = sal_True; // Pair-Kerning nWhich = GetWhich( SID_ATTR_CHAR_AUTOKERN ); @@ -3748,17 +3706,17 @@ BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxAutoKernItem( m_aPairKerningBtn.IsChecked(), nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; // Scale Width nWhich = GetWhich( SID_ATTR_CHAR_SCALEWIDTH ); if ( m_aScaleWidthMF.GetText() != m_aScaleWidthMF.GetSavedValue() ) { - rSet.Put( SvxCharScaleWidthItem( (USHORT)m_aScaleWidthMF.GetValue(), nWhich ) ); + rSet.Put( SvxCharScaleWidthItem( (sal_uInt16)m_aScaleWidthMF.GetValue(), nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; // Rotation @@ -3776,7 +3734,7 @@ BOOL SvxCharPositionPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( aItem ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; return bModified; @@ -3801,7 +3759,7 @@ void SvxCharPositionPage::FillUserData() // ----------------------------------------------------------------------- void SvxCharPositionPage::SetPreviewBackgroundToCharacter() { - m_bPreviewBackgroundToCharacter = TRUE; + m_bPreviewBackgroundToCharacter = sal_True; } // ----------------------------------------------------------------------- void SvxCharPositionPage::PageCreated (SfxAllItemSet aSet) @@ -3809,7 +3767,7 @@ void SvxCharPositionPage::PageCreated (SfxAllItemSet aSet) SFX_ITEMSET_ARG (&aSet,pFlagItem,SfxUInt32Item,SID_FLAG_TYPE,sal_False); if (pFlagItem) { - UINT32 nFlags=pFlagItem->GetValue(); + sal_uInt32 nFlags=pFlagItem->GetValue(); if ( ( nFlags & SVX_PREVIEW_CHARACTER ) == SVX_PREVIEW_CHARACTER ) SetPreviewBackgroundToCharacter(); } @@ -3846,7 +3804,7 @@ void SvxCharTwoLinesPage::Initialize() aSize.Height() = m_aEndBracketLB.CalcSize( 1, 6 ).Height(); m_aEndBracketLB.SetSizePixel( aSize ); - m_aTwoLinesBtn.Check( FALSE ); + m_aTwoLinesBtn.Check( sal_False ); TwoLinesHdl_Impl( NULL ); m_aTwoLinesBtn.SetClickHdl( LINK( this, SvxCharTwoLinesPage, TwoLinesHdl_Impl ) ); @@ -3891,25 +3849,25 @@ void SvxCharTwoLinesPage::SelectCharacter( ListBox* pBox ) // ----------------------------------------------------------------------- -void SvxCharTwoLinesPage::SetBracket( sal_Unicode cBracket, BOOL bStart ) +void SvxCharTwoLinesPage::SetBracket( sal_Unicode cBracket, sal_Bool bStart ) { - USHORT nEntryPos = 0; + sal_uInt16 nEntryPos = 0; ListBox* pBox = bStart ? &m_aStartBracketLB : &m_aEndBracketLB; if ( 0 == cBracket ) pBox->SelectEntryPos(0); else { bool bFound = FALSE; - for ( USHORT i = 1; i < pBox->GetEntryCount(); ++i ) + for ( sal_uInt16 i = 1; i < pBox->GetEntryCount(); ++i ) { - if ( (ULONG)pBox->GetEntryData(i) != CHRDLG_ENCLOSE_SPECIAL_CHAR ) + if ( (sal_uLong)pBox->GetEntryData(i) != CHRDLG_ENCLOSE_SPECIAL_CHAR ) { const sal_Unicode cChar = pBox->GetEntry(i).GetChar(0); if ( cChar == cBracket ) { pBox->SelectEntryPos(i); nEntryPos = i; - bFound = TRUE; + bFound = sal_True; break; } } @@ -3931,7 +3889,7 @@ void SvxCharTwoLinesPage::SetBracket( sal_Unicode cBracket, BOOL bStart ) IMPL_LINK( SvxCharTwoLinesPage, TwoLinesHdl_Impl, CheckBox*, EMPTYARG ) { - BOOL bChecked = m_aTwoLinesBtn.IsChecked(); + sal_Bool bChecked = m_aTwoLinesBtn.IsChecked(); m_aStartBracketFT.Enable( bChecked ); m_aStartBracketLB.Enable( bChecked ); m_aEndBracketFT.Enable( bChecked ); @@ -3945,8 +3903,8 @@ IMPL_LINK( SvxCharTwoLinesPage, TwoLinesHdl_Impl, CheckBox*, EMPTYARG ) IMPL_LINK( SvxCharTwoLinesPage, CharacterMapHdl_Impl, ListBox*, pBox ) { - USHORT nPos = pBox->GetSelectEntryPos(); - if ( CHRDLG_ENCLOSE_SPECIAL_CHAR == (ULONG)pBox->GetEntryData( nPos ) ) + sal_uInt16 nPos = pBox->GetSelectEntryPos(); + if ( CHRDLG_ENCLOSE_SPECIAL_CHAR == (sal_uLong)pBox->GetEntryData( nPos ) ) SelectCharacter( pBox ); else { @@ -3985,7 +3943,7 @@ SfxTabPage* SvxCharTwoLinesPage::Create( Window* pParent, const SfxItemSet& rSet // ----------------------------------------------------------------------- -USHORT* SvxCharTwoLinesPage::GetRanges() +sal_uInt16* SvxCharTwoLinesPage::GetRanges() { return pTwoLinesRanges; } @@ -3994,8 +3952,8 @@ USHORT* SvxCharTwoLinesPage::GetRanges() void SvxCharTwoLinesPage::Reset( const SfxItemSet& rSet ) { - m_aTwoLinesBtn.Check( FALSE ); - USHORT nWhich = GetWhich( SID_ATTR_CHAR_TWO_LINES ); + m_aTwoLinesBtn.Check( sal_False ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_TWO_LINES ); SfxItemState eState = rSet.GetItemState( nWhich ); if ( eState >= SFX_ITEM_DONTCARE ) @@ -4005,8 +3963,8 @@ void SvxCharTwoLinesPage::Reset( const SfxItemSet& rSet ) if ( rItem.GetValue() ) { - SetBracket( rItem.GetStartBracket(), TRUE ); - SetBracket( rItem.GetEndBracket(), FALSE ); + SetBracket( rItem.GetStartBracket(), sal_True ); + SetBracket( rItem.GetEndBracket(), sal_False ); } } TwoLinesHdl_Impl( NULL ); @@ -4016,11 +3974,11 @@ void SvxCharTwoLinesPage::Reset( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -BOOL SvxCharTwoLinesPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxCharTwoLinesPage::FillItemSet( SfxItemSet& rSet ) { const SfxItemSet& rOldSet = GetItemSet(); - BOOL bModified = FALSE, bChanged = TRUE; - USHORT nWhich = GetWhich( SID_ATTR_CHAR_TWO_LINES ); + sal_Bool bModified = sal_False, bChanged = sal_True; + sal_uInt16 nWhich = GetWhich( SID_ATTR_CHAR_TWO_LINES ); const SfxPoolItem* pOld = GetOldItem( rSet, SID_ATTR_CHAR_TWO_LINES ); sal_Bool bOn = m_aTwoLinesBtn.IsChecked(); sal_Unicode cStart = ( bOn && m_aStartBracketLB.GetSelectEntryPos() > 0 ) @@ -4033,7 +3991,7 @@ BOOL SvxCharTwoLinesPage::FillItemSet( SfxItemSet& rSet ) const SvxTwoLinesItem& rItem = *( (const SvxTwoLinesItem*)pOld ); if ( rItem.GetValue() == bOn && ( !bOn || ( rItem.GetStartBracket() == cStart && rItem.GetEndBracket() == cEnd ) ) ) - bChanged = FALSE; + bChanged = sal_False; } if ( bChanged ) @@ -4041,7 +3999,7 @@ BOOL SvxCharTwoLinesPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( SvxTwoLinesItem( bOn, cStart, cEnd, nWhich ) ); bModified = TRUE; } - else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich, sal_False ) ) CLEARTITEM; return bModified; @@ -4060,7 +4018,7 @@ void SvxCharTwoLinesPage::UpdatePreview_Impl() // ----------------------------------------------------------------------- void SvxCharTwoLinesPage::SetPreviewBackgroundToCharacter() { - m_bPreviewBackgroundToCharacter = TRUE; + m_bPreviewBackgroundToCharacter = sal_True; } // ----------------------------------------------------------------------- @@ -4069,7 +4027,7 @@ void SvxCharTwoLinesPage::PageCreated (SfxAllItemSet aSet) SFX_ITEMSET_ARG (&aSet,pFlagItem,SfxUInt32Item,SID_FLAG_TYPE,sal_False); if (pFlagItem) { - UINT32 nFlags=pFlagItem->GetValue(); + sal_uInt32 nFlags=pFlagItem->GetValue(); if ( ( nFlags & SVX_PREVIEW_CHARACTER ) == SVX_PREVIEW_CHARACTER ) SetPreviewBackgroundToCharacter(); } diff --git a/cui/source/tabpages/chardlg.src b/cui/source/tabpages/chardlg.src index 0d3960fd219c..abf9edcbd1eb 100644 --- a/cui/source/tabpages/chardlg.src +++ b/cui/source/tabpages/chardlg.src @@ -56,6 +56,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_WEST_NAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_NAME"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 25 ); Size = MAP_APPFONT ( 80 , 72 ); @@ -64,6 +65,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_WEST_NAME_NOCJK { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_NAME_NOCJK"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 17 ); Size = MAP_APPFONT ( 112 , 71 ); @@ -82,6 +84,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_WEST_STYLE { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_STYLE"; Border = TRUE; Pos = MAP_APPFONT ( 96 , 25 ); Size = MAP_APPFONT ( 40 , 48 ); @@ -97,6 +100,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_WEST_STYLE_NOCJK { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_STYLE_NOCJK"; Border = TRUE; Pos = MAP_APPFONT ( 130 , 17 ); Size = MAP_APPFONT ( 72 , 71 ); @@ -124,6 +128,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; MetricBox LB_WEST_SIZE { + HelpID = "cui:MetricBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_SIZE"; Border = TRUE; Pos = MAP_APPFONT ( 140 , 25 ); Size = MAP_APPFONT ( 38 , 72 ); @@ -132,6 +137,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; MetricBox LB_WEST_SIZE_NOCJK { + HelpID = "cui:MetricBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_SIZE_NOCJK"; Border = TRUE; Pos = MAP_APPFONT ( 208 , 17 ); Size = MAP_APPFONT ( 40 , 71 ); @@ -152,6 +158,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ListBox LB_WEST_LANG { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_LANG"; Border = TRUE; Pos = MAP_APPFONT ( 182 , 25 ); Size = MAP_APPFONT ( 66 , 72 ); @@ -161,6 +168,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ListBox LB_WEST_LANG_NOCJK { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_NAME:LB_WEST_LANG_NOCJK"; Border = TRUE; Pos = MAP_APPFONT ( 130 , 105 ); Size = MAP_APPFONT ( 72 , 72 ); @@ -181,6 +189,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_EAST_NAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_EAST_NAME"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 65 ); Size = MAP_APPFONT ( 80 , 72 ); @@ -194,6 +203,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_EAST_STYLE { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_EAST_STYLE"; Border = TRUE; Pos = MAP_APPFONT ( 96 , 65 ); Size = MAP_APPFONT ( 40 , 48 ); @@ -215,6 +225,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; MetricBox LB_EAST_SIZE { + HelpID = "cui:MetricBox:RID_SVXPAGE_CHAR_NAME:LB_EAST_SIZE"; Border = TRUE; Pos = MAP_APPFONT ( 140 , 65 ); Size = MAP_APPFONT ( 38 , 72 ); @@ -229,6 +240,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ListBox LB_EAST_LANG { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_NAME:LB_EAST_LANG"; Border = TRUE; Pos = MAP_APPFONT ( 182 , 65 ); Size = MAP_APPFONT ( 66 , 72 ); @@ -249,6 +261,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_CTL_NAME { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_CTL_NAME"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 105 ); Size = MAP_APPFONT ( 80 , 72 ); @@ -262,6 +275,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ComboBox LB_CTL_STYLE { + HelpID = "cui:ComboBox:RID_SVXPAGE_CHAR_NAME:LB_CTL_STYLE"; Border = TRUE; Pos = MAP_APPFONT ( 96 , 105 ); Size = MAP_APPFONT ( 40 , 48 ); @@ -283,6 +297,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; MetricBox LB_CTL_SIZE { + HelpID = "cui:MetricBox:RID_SVXPAGE_CHAR_NAME:LB_CTL_SIZE"; Border = TRUE; Pos = MAP_APPFONT ( 140 , 105 ); Size = MAP_APPFONT ( 38 , 72 ); @@ -297,6 +312,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ListBox LB_CTL_LANG { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_NAME:LB_CTL_LANG"; Border = TRUE; Pos = MAP_APPFONT ( 182 , 105 ); Size = MAP_APPFONT ( 66 , 72 ); @@ -331,6 +347,7 @@ TabPage RID_SVXPAGE_CHAR_NAME }; ListBox LB_COLOR2 { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_NAME:LB_COLOR2"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 105 ); Size = MAP_APPFONT ( 58 , 100 ); @@ -378,6 +395,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_FONTCOLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_FONTCOLOR"; Border = TRUE; Pos = MAP_APPFONT ( 10 , 15 ); Size = MAP_APPFONT ( 82 , 72 ); @@ -392,6 +410,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_EFFECTS2 { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_EFFECTS2"; Pos = MAP_APPFONT ( 10 , 44 ) ; Size = MAP_APPFONT ( 82 , 56 ) ; DropDown = TRUE; @@ -412,6 +431,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_RELIEF { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_RELIEF"; Pos = MAP_APPFONT ( 10 , 73 ) ; Size = MAP_APPFONT ( 82 , 56 ) ; DropDown = TRUE; @@ -424,18 +444,21 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; TriStateBox CB_OUTLINE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_CHAR_EFFECTS:CB_OUTLINE"; Pos = MAP_APPFONT ( 10 , 93 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Text [ en-US ] = "Out~line" ; }; TriStateBox CB_SHADOW { + HelpID = "cui:TriStateBox:RID_SVXPAGE_CHAR_EFFECTS:CB_SHADOW"; Pos = MAP_APPFONT ( 10 , 107 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Text [ en-US ] = "Sha~dow" ; }; TriStateBox CB_BLINKING { + HelpID = "cui:TriStateBox:RID_SVXPAGE_CHAR_EFFECTS:CB_BLINKING"; Pos = MAP_APPFONT ( 10 , 121 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Hide = TRUE; @@ -443,6 +466,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; TriStateBox CB_CHARHIDDEN { + HelpID = "cui:TriStateBox:RID_SVXPAGE_CHAR_EFFECTS:CB_CHARHIDDEN"; Pos = MAP_APPFONT ( 10 , 135 ) ; Size = MAP_APPFONT ( 82 , 10 ) ; Text [ en-US ] = "H~idden" ; @@ -461,6 +485,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_OVERLINE { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_OVERLINE"; Border = TRUE; Pos = MAP_APPFONT ( 110 , 15 ); Size = MAP_APPFONT ( 68 , 72 ); @@ -495,6 +520,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_OVERLINE_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_OVERLINE_COLOR"; Border = TRUE; Pos = MAP_APPFONT ( 184 , 15 ); Size = MAP_APPFONT ( 68 , 100 ); @@ -509,6 +535,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_STRIKEOUT { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_STRIKEOUT"; Border = TRUE; Pos = MAP_APPFONT ( 110 , 44 ); Size = MAP_APPFONT ( 68 , 72 ); @@ -532,6 +559,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_UNDERLINE { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_UNDERLINE"; Border = TRUE; Pos = MAP_APPFONT ( 110 , 73 ); Size = MAP_APPFONT ( 68 , 72 ); @@ -566,6 +594,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_UNDERLINE_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_UNDERLINE_COLOR"; Border = TRUE; Pos = MAP_APPFONT ( 184 , 73 ); Size = MAP_APPFONT ( 68 , 100 ); @@ -574,6 +603,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; CheckBox CB_INDIVIDUALWORDS { + HelpID = "cui:CheckBox:RID_SVXPAGE_CHAR_EFFECTS:CB_INDIVIDUALWORDS"; Pos = MAP_APPFONT ( 110 , 93 ); Size = MAP_APPFONT ( 68 , 10 ); TabStop = TRUE; @@ -592,6 +622,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_EMPHASIS { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_EMPHASIS"; Border = TRUE; Pos = MAP_APPFONT ( 110 , 128 ); Size = MAP_APPFONT ( 68 , 72 ); @@ -614,6 +645,7 @@ TabPage RID_SVXPAGE_CHAR_EFFECTS }; ListBox LB_POSITION { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_EFFECTS:LB_POSITION"; Border = TRUE; Pos = MAP_APPFONT ( 184 , 128 ); Size = MAP_APPFONT ( 68 , 48 ); @@ -688,6 +720,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_HIGHPOS { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_HIGHPOS"; Pos = MAP_APPFONT ( 12 , 16 ); Size = MAP_APPFONT ( 58 , 10 ); Text [ en-US ] = "Superscript" ; @@ -695,6 +728,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_NORMALPOS { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_NORMALPOS"; Pos = MAP_APPFONT ( 12 , 30 ); Size = MAP_APPFONT ( 58 , 10 ); Text [ en-US ] = "Normal" ; @@ -702,6 +736,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_LOWPOS { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_LOWPOS"; Pos = MAP_APPFONT ( 12 , 44 ); Size = MAP_APPFONT ( 58 , 10 ); Text [ en-US ] = "Subscript" ; @@ -715,6 +750,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; MetricField ED_HIGHLOW { + HelpID = "cui:MetricField:RID_SVXPAGE_CHAR_POSITION:ED_HIGHLOW"; Border = TRUE; Pos = MAP_APPFONT ( 136 , 14 ); Size = MAP_APPFONT ( 30 , 12 ); @@ -731,6 +767,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; CheckBox CB_HIGHLOW { + HelpID = "cui:CheckBox:RID_SVXPAGE_CHAR_POSITION:CB_HIGHLOW"; Pos = MAP_APPFONT ( 172 , 16 ); Size = MAP_APPFONT ( 76 , 10 ); Text [ en-US ] = "A~utomatic" ; @@ -744,6 +781,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; MetricField ED_FONTSIZE { + HelpID = "cui:MetricField:RID_SVXPAGE_CHAR_POSITION:ED_FONTSIZE"; Border = TRUE; Pos = MAP_APPFONT ( 136 , 30 ); Size = MAP_APPFONT ( 30 , 12 ); @@ -772,6 +810,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_0_DEG { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_0_DEG"; Pos = MAP_APPFONT ( 12 , 70 ); Size = MAP_APPFONT ( 46 , 10 ); TabStop = TRUE; @@ -779,6 +818,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_90_DEG { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_90_DEG"; Pos = MAP_APPFONT ( 62 , 70 ); Size = MAP_APPFONT ( 46 , 10 ); TabStop = TRUE; @@ -786,6 +826,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; RadioButton RB_270_DEG { + HelpID = "cui:RadioButton:RID_SVXPAGE_CHAR_POSITION:RB_270_DEG"; Pos = MAP_APPFONT ( 112 , 70 ); Size = MAP_APPFONT ( 46 , 10 ); TabStop = TRUE; @@ -793,6 +834,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; CheckBox CB_FIT_TO_LINE { + HelpID = "cui:CheckBox:RID_SVXPAGE_CHAR_POSITION:CB_FIT_TO_LINE"; Pos = MAP_APPFONT ( 162 , 70 ); Size = MAP_APPFONT ( 86 , 10 ); TabStop = TRUE; @@ -806,6 +848,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; MetricField MF_SCALE_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_CHAR_POSITION:MF_SCALE_WIDTH"; Border = TRUE; Pos = MAP_APPFONT ( 94 , 84 ); Size = MAP_APPFONT ( 30 , 12 ); @@ -828,6 +871,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; ListBox LB_KERNING2 { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_POSITION:LB_KERNING2"; Border = TRUE; Pos = MAP_APPFONT ( 12 , 111 ); Size = MAP_APPFONT ( 72 , 48 ) ; @@ -848,6 +892,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; MetricField ED_KERNING2 { + HelpID = "cui:MetricField:RID_SVXPAGE_CHAR_POSITION:ED_KERNING2"; Border = TRUE; Pos = MAP_APPFONT ( 112 , 111 ); Size = MAP_APPFONT ( 40 , 12 ); @@ -861,6 +906,7 @@ TabPage RID_SVXPAGE_CHAR_POSITION }; CheckBox CB_PAIRKERNING { + HelpID = "cui:CheckBox:RID_SVXPAGE_CHAR_POSITION:CB_PAIRKERNING"; Pos = MAP_APPFONT ( 156 , 113 ); Size = MAP_APPFONT ( 92 , 10 ); Text [ en-US ] = "~Pair kerning" ; @@ -895,6 +941,7 @@ TabPage RID_SVXPAGE_CHAR_TWOLINES }; CheckBox CB_TWOLINES { + HelpID = "cui:CheckBox:RID_SVXPAGE_CHAR_TWOLINES:CB_TWOLINES"; Pos = MAP_APPFONT ( 12 , 14 ); Size = MAP_APPFONT ( 236 , 10 ); Text [ en-US ] = "~Write in double lines" ; @@ -914,6 +961,7 @@ TabPage RID_SVXPAGE_CHAR_TWOLINES }; ListBox ED_STARTBRACKET { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_TWOLINES:ED_STARTBRACKET"; Pos = MAP_APPFONT ( 12 , 52 ); Size = MAP_APPFONT ( 90 , 72 ); TabStop = TRUE; @@ -936,6 +984,7 @@ TabPage RID_SVXPAGE_CHAR_TWOLINES }; ListBox ED_ENDBRACKET { + HelpID = "cui:ListBox:RID_SVXPAGE_CHAR_TWOLINES:ED_ENDBRACKET"; Pos = MAP_APPFONT ( 108 , 52 ); Size = MAP_APPFONT ( 90 , 72 ); TabStop = TRUE; diff --git a/cui/source/tabpages/connect.cxx b/cui/source/tabpages/connect.cxx index 5c447b2fc147..f20b636b0570 100644 --- a/cui/source/tabpages/connect.cxx +++ b/cui/source/tabpages/connect.cxx @@ -47,9 +47,10 @@ #include <dialmgr.hxx> #include "svx/dlgutil.hxx" +#include "paragrph.hrc" #include <cuires.hrc> -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SDRATTR_EDGE_FIRST, SDRATTR_EDGE_LAST, @@ -122,6 +123,8 @@ SvxConnectionPage::SvxConnectionPage( Window* pWindow, const SfxItemSet& rInAttr { FreeResource(); + aCtlPreview.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + SfxItemPool* pPool = rOutAttrs.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); eUnit = pPool->GetMetric( SDRATTR_EDGENODE1HORZDIST ); @@ -285,23 +288,23 @@ void SvxConnectionPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_EDGELINEDELTAANZ ); if( pItem ) { - UINT16 nValue = ( ( const SdrEdgeLineDeltaAnzItem* )pItem )->GetValue(); + sal_uInt16 nValue = ( ( const SdrEdgeLineDeltaAnzItem* )pItem )->GetValue(); if( nValue <= 2 ) { - aFtLine3.Enable( FALSE ); - aMtrFldLine3.Enable( FALSE ); + aFtLine3.Enable( sal_False ); + aMtrFldLine3.Enable( sal_False ); aMtrFldLine3.SetEmptyFieldValue(); } if( nValue <= 1 ) { - aFtLine2.Enable( FALSE ); - aMtrFldLine2.Enable( FALSE ); + aFtLine2.Enable( sal_False ); + aMtrFldLine2.Enable( sal_False ); aMtrFldLine2.SetEmptyFieldValue(); } if( nValue == 0 ) { - aFtLine1.Enable( FALSE ); - aMtrFldLine1.Enable( FALSE ); + aFtLine1.Enable( sal_False ); + aMtrFldLine1.Enable( sal_False ); aMtrFldLine1.SetEmptyFieldValue(); } } @@ -313,7 +316,7 @@ void SvxConnectionPage::Reset( const SfxItemSet& rAttrs ) if( pItem ) { SdrEdgeKind nValue = ( ( const SdrEdgeKindItem* )pItem )->GetValue(); - aLbType.SelectEntryPos( sal::static_int_cast< USHORT >(nValue) ); + aLbType.SelectEntryPos( sal::static_int_cast< sal_uInt16 >(nValue) ); } else aLbType.SetNoSelection(); @@ -326,68 +329,68 @@ void SvxConnectionPage::Reset( const SfxItemSet& rAttrs ) |* \************************************************************************/ -BOOL SvxConnectionPage::FillItemSet( SfxItemSet& rAttrs) +sal_Bool SvxConnectionPage::FillItemSet( SfxItemSet& rAttrs) { - BOOL bModified = FALSE; - INT32 nValue; + sal_Bool bModified = sal_False; + sal_Int32 nValue; if( aMtrFldHorz1.GetText() != aMtrFldHorz1.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHorz1, eUnit ); rAttrs.Put( SdrEdgeNode1HorzDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldHorz2.GetText() != aMtrFldHorz2.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHorz2, eUnit ); rAttrs.Put( SdrEdgeNode2HorzDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldVert1.GetText() != aMtrFldVert1.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldVert1, eUnit ); rAttrs.Put( SdrEdgeNode1VertDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldVert2.GetText() != aMtrFldVert2.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldVert2, eUnit ); rAttrs.Put( SdrEdgeNode2VertDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldLine1.GetText() != aMtrFldLine1.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldLine1, eUnit ); rAttrs.Put( SdrEdgeLine1DeltaItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldLine2.GetText() != aMtrFldLine2.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldLine2, eUnit ); rAttrs.Put( SdrEdgeLine2DeltaItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldLine3.GetText() != aMtrFldLine3.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldLine3, eUnit ); rAttrs.Put( SdrEdgeLine3DeltaItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } - USHORT nPos = aLbType.GetSelectEntryPos(); + sal_uInt16 nPos = aLbType.GetSelectEntryPos(); if( nPos != aLbType.GetSavedValue() ) { if( nPos != LISTBOX_ENTRY_NOTFOUND ) { rAttrs.Put( SdrEdgeKindItem( (SdrEdgeKind) nPos ) ); - bModified = TRUE; + bModified = sal_True; } } @@ -426,7 +429,7 @@ SfxTabPage* SvxConnectionPage::Create( Window* pWindow, |* \************************************************************************/ -USHORT* SvxConnectionPage::GetRanges() +sal_uInt16* SvxConnectionPage::GetRanges() { return( pRanges ); } @@ -441,50 +444,50 @@ IMPL_LINK( SvxConnectionPage, ChangeAttrHdl_Impl, void *, p ) { if( p == &aMtrFldHorz1 ) { - INT32 nValue = GetCoreValue( aMtrFldHorz1, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHorz1, eUnit ); aAttrSet.Put( SdrEdgeNode1HorzDistItem( nValue ) ); } if( p == &aMtrFldHorz2 ) { - INT32 nValue = GetCoreValue( aMtrFldHorz2, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHorz2, eUnit ); aAttrSet.Put( SdrEdgeNode2HorzDistItem( nValue ) ); } if( p == &aMtrFldVert1 ) { - INT32 nValue = GetCoreValue( aMtrFldVert1, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldVert1, eUnit ); aAttrSet.Put( SdrEdgeNode1VertDistItem( nValue ) ); } if( p == &aMtrFldVert2 ) { - INT32 nValue = GetCoreValue( aMtrFldVert2, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldVert2, eUnit ); aAttrSet.Put( SdrEdgeNode2VertDistItem( nValue ) ); } if( p == &aMtrFldLine1 ) { - INT32 nValue = GetCoreValue( aMtrFldLine1, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldLine1, eUnit ); aAttrSet.Put( SdrEdgeLine1DeltaItem( nValue ) ); } if( p == &aMtrFldLine2 ) { - INT32 nValue = GetCoreValue( aMtrFldLine2, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldLine2, eUnit ); aAttrSet.Put( SdrEdgeLine2DeltaItem( nValue ) ); } if( p == &aMtrFldLine3 ) { - INT32 nValue = GetCoreValue( aMtrFldLine3, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldLine3, eUnit ); aAttrSet.Put( SdrEdgeLine3DeltaItem( nValue ) ); } if( p == &aLbType ) { - USHORT nPos = aLbType.GetSelectEntryPos(); + sal_uInt16 nPos = aLbType.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { aAttrSet.Put( SdrEdgeKindItem( (SdrEdgeKind) nPos ) ); @@ -496,7 +499,7 @@ IMPL_LINK( SvxConnectionPage, ChangeAttrHdl_Impl, void *, p ) if( p == &aLbType ) { // Anzahl der Linienversaetze ermitteln - USHORT nCount = aCtlPreview.GetLineDeltaAnz(); + sal_uInt16 nCount = aCtlPreview.GetLineDeltaAnz(); aFtLine3.Enable( nCount > 2 ); aMtrFldLine3.Enable( nCount > 2 ); @@ -541,10 +544,10 @@ void SvxConnectionPage::FillTypeLB() if( pItem ) { const SdrEdgeKindItem* pEdgeKindItem = (const SdrEdgeKindItem*) pItem; - USHORT nCount = pEdgeKindItem->GetValueCount(); + sal_uInt16 nCount = pEdgeKindItem->GetValueCount(); String aStr; - for( USHORT i = 0; i < nCount; i++ ) + for( sal_uInt16 i = 0; i < nCount; i++ ) { aStr = pEdgeKindItem->GetValueTextByPos( i ); aLbType.InsertEntry( aStr ); diff --git a/cui/source/tabpages/connect.src b/cui/source/tabpages/connect.src index 64623b0cee25..d2fe0796bb26 100644 --- a/cui/source/tabpages/connect.src +++ b/cui/source/tabpages/connect.src @@ -49,6 +49,7 @@ TabPage RID_SVXPAGE_CONNECTION }; ListBox LB_TYPE { + HelpID = "cui:ListBox:RID_SVXPAGE_CONNECTION:LB_TYPE"; Border = TRUE ; Pos = MAP_APPFONT ( 37 , 6 ) ; Size = MAP_APPFONT ( 83 , 54 ) ; @@ -69,6 +70,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_LINE_1 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_LINE_1"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 35 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -91,6 +93,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_LINE_2 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_LINE_2"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 51 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -113,6 +116,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_LINE_3 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_LINE_3"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 67 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -141,6 +145,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_HORZ_1 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_HORZ_1"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 96 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -163,6 +168,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_HORZ_2 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_HORZ_2"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 128 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -185,6 +191,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_VERT_1 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_VERT_1"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 112 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; @@ -207,6 +214,7 @@ TabPage RID_SVXPAGE_CONNECTION }; MetricField MTR_FLD_VERT_2 { + HelpID = "cui:MetricField:RID_SVXPAGE_CONNECTION:MTR_FLD_VERT_2"; Border = TRUE ; Pos = MAP_APPFONT ( 79 , 144 ) ; Size = MAP_APPFONT ( 41 , 12 ) ; diff --git a/cui/source/tabpages/dstribut.cxx b/cui/source/tabpages/dstribut.cxx index 72b1bf4d6b8d..37788da81f22 100644 --- a/cui/source/tabpages/dstribut.cxx +++ b/cui/source/tabpages/dstribut.cxx @@ -35,7 +35,7 @@ #include <dialmgr.hxx> #include <tools/shl.hxx> -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SDRATTR_MEASURE_FIRST, SDRATTR_MEASURE_LAST, @@ -137,7 +137,7 @@ SfxTabPage* SvxDistributePage::Create(Window* pWindow, const SfxItemSet& rAttrs, |* \************************************************************************/ -UINT16* SvxDistributePage::GetRanges() +sal_uInt16* SvxDistributePage::GetRanges() { return(pRanges); } @@ -160,34 +160,34 @@ void SvxDistributePage::PointChanged(Window* /*pWindow*/, RECT_POINT /*eRP*/) void SvxDistributePage::Reset(const SfxItemSet& ) { - maBtnHorNone.SetState(FALSE); - maBtnHorLeft.SetState(FALSE); - maBtnHorCenter.SetState(FALSE); - maBtnHorDistance.SetState(FALSE); - maBtnHorRight.SetState(FALSE); + maBtnHorNone.SetState(sal_False); + maBtnHorLeft.SetState(sal_False); + maBtnHorCenter.SetState(sal_False); + maBtnHorDistance.SetState(sal_False); + maBtnHorRight.SetState(sal_False); switch(meDistributeHor) { - case SvxDistributeHorizontalNone : maBtnHorNone.SetState(TRUE); break; - case SvxDistributeHorizontalLeft : maBtnHorLeft.SetState(TRUE); break; - case SvxDistributeHorizontalCenter : maBtnHorCenter.SetState(TRUE); break; - case SvxDistributeHorizontalDistance : maBtnHorDistance.SetState(TRUE); break; + case SvxDistributeHorizontalNone : maBtnHorNone.SetState(sal_True); break; + case SvxDistributeHorizontalLeft : maBtnHorLeft.SetState(sal_True); break; + case SvxDistributeHorizontalCenter : maBtnHorCenter.SetState(sal_True); break; + case SvxDistributeHorizontalDistance : maBtnHorDistance.SetState(sal_True); break; case SvxDistributeHorizontalRight : maBtnHorRight.SetState(TRUE); break; } - maBtnVerNone.SetState(FALSE); - maBtnVerTop.SetState(FALSE); - maBtnVerCenter.SetState(FALSE); - maBtnVerDistance.SetState(FALSE); - maBtnVerBottom.SetState(FALSE); + maBtnVerNone.SetState(sal_False); + maBtnVerTop.SetState(sal_False); + maBtnVerCenter.SetState(sal_False); + maBtnVerDistance.SetState(sal_False); + maBtnVerBottom.SetState(sal_False); switch(meDistributeVer) { - case SvxDistributeVerticalNone : maBtnVerNone.SetState(TRUE); break; - case SvxDistributeVerticalTop : maBtnVerTop.SetState(TRUE); break; - case SvxDistributeVerticalCenter : maBtnVerCenter.SetState(TRUE); break; - case SvxDistributeVerticalDistance : maBtnVerDistance.SetState(TRUE); break; - case SvxDistributeVerticalBottom : maBtnVerBottom.SetState(TRUE); break; + case SvxDistributeVerticalNone : maBtnVerNone.SetState(sal_True); break; + case SvxDistributeVerticalTop : maBtnVerTop.SetState(sal_True); break; + case SvxDistributeVerticalCenter : maBtnVerCenter.SetState(sal_True); break; + case SvxDistributeVerticalDistance : maBtnVerDistance.SetState(sal_True); break; + case SvxDistributeVerticalBottom : maBtnVerBottom.SetState(sal_True); break; } } @@ -197,7 +197,7 @@ void SvxDistributePage::Reset(const SfxItemSet& ) |* \************************************************************************/ -BOOL SvxDistributePage::FillItemSet( SfxItemSet& ) +sal_Bool SvxDistributePage::FillItemSet( SfxItemSet& ) { SvxDistributeHorizontal eDistributeHor(SvxDistributeHorizontalNone); SvxDistributeVertical eDistributeVer(SvxDistributeVerticalNone); @@ -224,10 +224,10 @@ BOOL SvxDistributePage::FillItemSet( SfxItemSet& ) { meDistributeHor = eDistributeHor; meDistributeVer = eDistributeVer; - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } diff --git a/cui/source/tabpages/dstribut.src b/cui/source/tabpages/dstribut.src index 30746cbc72bc..ed5108c90d6a 100644 --- a/cui/source/tabpages/dstribut.src +++ b/cui/source/tabpages/dstribut.src @@ -49,6 +49,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_HOR_NONE { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_HOR_NONE"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 48 , 10 ) ; Text [ en-US ] = "~None" ; @@ -56,6 +57,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_HOR_LEFT { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_HOR_LEFT"; Pos = MAP_APPFONT ( 56 , 26 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Left" ; @@ -63,6 +65,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_HOR_CENTER { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_HOR_CENTER"; Pos = MAP_APPFONT ( 105 , 26 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Center" ; @@ -70,6 +73,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_HOR_DISTANCE { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_HOR_DISTANCE"; Pos = MAP_APPFONT ( 154 , 26 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Spacing" ; @@ -77,6 +81,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_HOR_RIGHT { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_HOR_RIGHT"; Pos = MAP_APPFONT ( 203 , 26 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Right" ; @@ -131,6 +136,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_VER_NONE { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_VER_NONE"; Pos = MAP_APPFONT ( 12 , 53 ) ; Size = MAP_APPFONT ( 46 , 10 ) ; Text [ en-US ] = "N~one" ; @@ -138,6 +144,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_VER_TOP { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_VER_TOP"; Pos = MAP_APPFONT ( 56 , 65 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Top" ; @@ -145,6 +152,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_VER_CENTER { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_VER_CENTER"; Pos = MAP_APPFONT ( 105 , 65 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "C~enter" ; @@ -152,6 +160,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_VER_DISTANCE { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_VER_DISTANCE"; Pos = MAP_APPFONT ( 154 , 65 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "S~pacing" ; @@ -159,6 +168,7 @@ TabPage RID_SVXPAGE_DISTRIBUTE RadioButton BTN_VER_BOTTOM { + HelpID = "cui:RadioButton:RID_SVXPAGE_DISTRIBUTE:BTN_VER_BOTTOM"; Pos = MAP_APPFONT ( 203 , 65 ) ; Size = MAP_APPFONT ( 45 , 10 ) ; Text [ en-US ] = "~Bottom" ; diff --git a/cui/source/tabpages/grfpage.cxx b/cui/source/tabpages/grfpage.cxx index 2269ecfe051f..435345baeda2 100644 --- a/cui/source/tabpages/grfpage.cxx +++ b/cui/source/tabpages/grfpage.cxx @@ -80,8 +80,8 @@ SvxGrfCropPage::SvxGrfCropPage ( Window *pParent, const SfxItemSet &rSet ) aOrigSizePB( this, CUI_RES( PB_ORGSIZE )), aExampleWN( this, CUI_RES( WN_BSP )), pLastCropField(0), - bInitialized(FALSE), - bSetOrigSize(FALSE) + bInitialized(sal_False), + bSetOrigSize(sal_False) { FreeResource(); @@ -132,6 +132,8 @@ SvxGrfCropPage::SvxGrfCropPage ( Window *pParent, const SfxItemSet &rSet ) aTimer.SetTimeoutHdl(LINK(this, SvxGrfCropPage, Timeout)); aTimer.SetTimeout( 1500 ); + + aOrigSizePB.SetAccessibleRelationLabeledBy( &aOrigSizeFT ); } SvxGrfCropPage::~SvxGrfCropPage() @@ -150,7 +152,7 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) const SfxItemPool& rPool = *rSet.GetPool(); if(SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( - SID_ATTR_GRAF_KEEP_ZOOM ), TRUE, &pItem )) + SID_ATTR_GRAF_KEEP_ZOOM ), sal_True, &pItem )) { if( ((const SfxBoolItem*)pItem)->GetValue() ) aZoomConstRB.Check(); @@ -159,8 +161,8 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) aZoomConstRB.SaveValue(); } - USHORT nW = rPool.GetWhich( SID_ATTR_GRAF_CROP ); - if( SFX_ITEM_SET == rSet.GetItemState( nW, TRUE, &pItem)) + sal_uInt16 nW = rPool.GetWhich( SID_ATTR_GRAF_CROP ); + if( SFX_ITEM_SET == rSet.GetItemState( nW, sal_True, &pItem)) { FieldUnit eUnit = MapToFieldUnit( rSet.GetPool()->GetMetric( nW )); @@ -185,7 +187,7 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) } nW = rPool.GetWhich( SID_ATTR_PAGE_SIZE ); - if ( SFX_ITEM_SET == rSet.GetItemState( nW, FALSE, &pItem ) ) + if ( SFX_ITEM_SET == rSet.GetItemState( nW, sal_False, &pItem ) ) { // Orientation und Size aus dem PageItem FieldUnit eUnit = MapToFieldUnit( rSet.GetPool()->GetMetric( nW )); @@ -208,8 +210,8 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) MapMode( (MapUnit)rSet.GetPool()->GetMetric( nW ) ) ); } - BOOL bFound = FALSE; - if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_GRAPHIC, FALSE, &pItem ) ) + sal_Bool bFound = sal_False; + if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_GRAPHIC, sal_False, &pItem ) ) { const Graphic* pGrf = ((SvxBrushItem*)pItem)->GetGraphic(); if( pGrf ) @@ -221,26 +223,26 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) aExampleWN.SetGraphic( *pGrf ); aExampleWN.SetFrameSize( aOrigSize ); - bFound = TRUE; + bFound = sal_True; if( ((SvxBrushItem*)pItem)->GetGraphicLink() ) aGraphicName = *((SvxBrushItem*)pItem)->GetGraphicLink(); } } GraphicHasChanged( bFound ); - bReset = TRUE; + bReset = sal_True; ActivatePage( rSet ); - bReset = FALSE; + bReset = sal_False; } -BOOL SvxGrfCropPage::FillItemSet(SfxItemSet &rSet) +sal_Bool SvxGrfCropPage::FillItemSet(SfxItemSet &rSet) { const SfxItemPool& rPool = *rSet.GetPool(); - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if( aWidthMF.GetSavedValue() != aWidthMF.GetText() || aHeightMF.GetSavedValue() != aHeightMF.GetText() ) { - USHORT nW = rPool.GetWhich( SID_ATTR_GRAF_FRMSIZE ); + sal_uInt16 nW = rPool.GetWhich( SID_ATTR_GRAF_FRMSIZE ); FieldUnit eUnit = MapToFieldUnit( rSet.GetPool()->GetMetric( nW )); SvxSizeItem aSz( nW ); @@ -250,7 +252,7 @@ BOOL SvxGrfCropPage::FillItemSet(SfxItemSet &rSet) const SfxItemSet* pExSet = GetTabDialog() ? GetTabDialog()->GetExampleSet() : NULL; const SfxPoolItem* pItem = 0; if( pExSet && SFX_ITEM_SET == - pExSet->GetItemState( nW, FALSE, &pItem ) ) + pExSet->GetItemState( nW, sal_False, &pItem ) ) aSz = *(const SvxSizeItem*)pItem; else aSz = (const SvxSizeItem&)GetItemSet().Get( nW ); @@ -275,7 +277,7 @@ BOOL SvxGrfCropPage::FillItemSet(SfxItemSet &rSet) if( aLeftMF.IsModified() || aRightMF.IsModified() || aTopMF.IsModified() || aBottomMF.IsModified() ) { - USHORT nW = rPool.GetWhich( SID_ATTR_GRAF_CROP ); + sal_uInt16 nW = rPool.GetWhich( SID_ATTR_GRAF_CROP ); FieldUnit eUnit = MapToFieldUnit( rSet.GetPool()->GetMetric( nW )); SvxGrfCrop* pNew = (SvxGrfCrop*)rSet.Get( nW ).Clone(); @@ -293,7 +295,7 @@ BOOL SvxGrfCropPage::FillItemSet(SfxItemSet &rSet) SID_ATTR_GRAF_KEEP_ZOOM), aZoomConstRB.IsChecked() ) ); } - bInitialized = FALSE; + bInitialized = sal_False; return bModified; } @@ -305,12 +307,12 @@ void SvxGrfCropPage::ActivatePage(const SfxItemSet& rSet) DBG_ASSERT( pPool, "Wo ist der Pool" ); #endif - bSetOrigSize = FALSE; + bSetOrigSize = sal_False; // Size Size aSize; const SfxPoolItem* pItem; - if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_FRMSIZE, FALSE, &pItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_FRMSIZE, sal_False, &pItem ) ) aSize = ((const SvxSizeItem*)pItem)->GetSize(); nOldWidth = aSize.Width(); @@ -344,9 +346,9 @@ void SvxGrfCropPage::ActivatePage(const SfxItemSet& rSet) aHeightMF.SetValue(nHeight, FUNIT_TWIP); } aHeightMF.SaveValue(); - bInitialized = TRUE; + bInitialized = sal_True; - if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_GRAPHIC, FALSE, &pItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_GRAPHIC, sal_False, &pItem ) ) { const SvxBrushItem& rBrush = *(SvxBrushItem*)pItem; if( rBrush.GetGraphicLink() && @@ -363,7 +365,7 @@ void SvxGrfCropPage::ActivatePage(const SfxItemSet& rSet) CalcMinMaxBorder(); } else - GraphicHasChanged( FALSE ); + GraphicHasChanged( sal_False ); } CalcZoom(); @@ -373,7 +375,7 @@ int SvxGrfCropPage::DeactivatePage(SfxItemSet *_pSet) { if ( _pSet ) FillItemSet( *_pSet ); - return TRUE; + return sal_True; } /*-------------------------------------------------------------------- @@ -428,7 +430,7 @@ IMPL_LINK( SvxGrfCropPage, SizeHdl, MetricField *, pField ) lcl_GetValue(aRightMF, eUnit) ); if(!nWidth) nWidth++; - USHORT nZoom = (USHORT)( aSize.Width() * 100L / nWidth); + sal_uInt16 nZoom = (sal_uInt16)( aSize.Width() * 100L / nWidth); aWidthZoomMF.SetValue(nZoom); } else @@ -438,7 +440,7 @@ IMPL_LINK( SvxGrfCropPage, SizeHdl, MetricField *, pField ) lcl_GetValue(aBottomMF, eUnit)); if(!nHeight) nHeight++; - USHORT nZoom = (USHORT)( aSize.Height() * 100L/ nHeight); + sal_uInt16 nZoom = (sal_uInt16)( aSize.Height() * 100L/ nHeight); aHeightZoomMF.SetValue(nZoom); } @@ -456,7 +458,7 @@ IMPL_LINK( SvxGrfCropPage, CropHdl, const MetricField *, pField ) FieldUnit eUnit = MapToFieldUnit( pPool->GetMetric( pPool->GetWhich( SID_ATTR_GRAF_CROP ) ) ); - BOOL bZoom = aZoomConstRB.IsChecked(); + sal_Bool bZoom = aZoomConstRB.IsChecked(); if( pField == &aLeftMF || pField == &aRightMF ) { long nLeft = lcl_GetValue( aLeftMF, eUnit ); @@ -543,7 +545,7 @@ IMPL_LINK( SvxGrfCropPage, OrigSizeHdl, PushButton *, EMPTYARG ) aHeightMF.SetValue( aHeightMF.Normalize( nHeight ), eUnit ); aWidthZoomMF.SetValue(100); aHeightZoomMF.SetValue(100); - bSetOrigSize = TRUE; + bSetOrigSize = sal_True; return 0; } /*-------------------------------------------------------------------- @@ -563,13 +565,13 @@ void SvxGrfCropPage::CalcZoom() lcl_GetValue( aRightMF, eUnit ); long nULBorders = lcl_GetValue( aTopMF, eUnit ) + lcl_GetValue( aBottomMF, eUnit ); - USHORT nZoom = 0; + sal_uInt16 nZoom = 0; long nDen; if( (nDen = aOrigSize.Width() - nLRBorders) > 0) - nZoom = (USHORT)((( nWidth * 1000L / nDen )+5)/10); + nZoom = (sal_uInt16)((( nWidth * 1000L / nDen )+5)/10); aWidthZoomMF.SetValue(nZoom); if( (nDen = aOrigSize.Height() - nULBorders) > 0) - nZoom = (USHORT)((( nHeight * 1000L / nDen )+5)/10); + nZoom = (sal_uInt16)((( nHeight * 1000L / nDen )+5)/10); else nZoom = 0; aHeightZoomMF.SetValue(nZoom); @@ -608,7 +610,7 @@ void SvxGrfCropPage::CalcMinMaxBorder() FixedText mit der Originalgroesse fuellen --------------------------------------------------------------------*/ -void SvxGrfCropPage::GraphicHasChanged( BOOL bFound ) +void SvxGrfCropPage::GraphicHasChanged( sal_Bool bFound ) { if( bFound ) { diff --git a/cui/source/tabpages/grfpage.src b/cui/source/tabpages/grfpage.src index 74b9e8e5cda0..085e92f2d0c0 100644 --- a/cui/source/tabpages/grfpage.src +++ b/cui/source/tabpages/grfpage.src @@ -58,6 +58,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_LEFT { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_LEFT"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 42 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -83,6 +84,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_RIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_RIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 58 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -106,6 +108,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_TOP { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_TOP"; Border = TRUE ; Pos = MAP_APPFONT ( 124 , 42 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -131,6 +134,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_BOTTOM { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_BOTTOM"; Border = TRUE ; Pos = MAP_APPFONT ( 124 , 58 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -148,12 +152,14 @@ TabPage RID_SVXPAGE_GRFCROP }; RadioButton RB_SIZECONST { + HelpID = "cui:RadioButton:RID_SVXPAGE_GRFCROP:RB_SIZECONST"; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 152 , 10 ) ; Text [ en-US ] = "Keep image si~ze" ; }; RadioButton RB_ZOOMCONST { + HelpID = "cui:RadioButton:RID_SVXPAGE_GRFCROP:RB_ZOOMCONST"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 152 , 10 ) ; Check = TRUE ; @@ -180,6 +186,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_WIDTHZOOM { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_WIDTHZOOM"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 87 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -207,6 +214,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_HEIGHTZOOM { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_HEIGHTZOOM"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 103 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -239,6 +247,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 132 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -264,6 +273,7 @@ TabPage RID_SVXPAGE_GRFCROP }; MetricField MF_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_GRFCROP:MF_HEIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 148 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -286,6 +296,7 @@ TabPage RID_SVXPAGE_GRFCROP }; PushButton PB_ORGSIZE { + HelpID = "cui:PushButton:RID_SVXPAGE_GRFCROP:PB_ORGSIZE"; Pos = MAP_APPFONT ( 176 , 143 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; TabStop = TRUE ; diff --git a/cui/source/tabpages/labdlg.cxx b/cui/source/tabpages/labdlg.cxx index 411e5f53257b..7177dcfb716d 100644 --- a/cui/source/tabpages/labdlg.cxx +++ b/cui/source/tabpages/labdlg.cxx @@ -63,7 +63,7 @@ // static ---------------------------------------------------------------- -static USHORT pCaptionRanges[] = +static sal_uInt16 pCaptionRanges[] = { SDRATTR_CAPTIONTYPE, SDRATTR_CAPTIONFIXEDANGLE, @@ -164,7 +164,7 @@ void SvxCaptionTabPage::Construct() // ----------------------------------------------------------------------- -BOOL SvxCaptionTabPage::FillItemSet( SfxItemSet& _rOutAttrs) +sal_Bool SvxCaptionTabPage::FillItemSet( SfxItemSet& _rOutAttrs) { SfxItemPool* pPool = _rOutAttrs.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); @@ -231,7 +231,7 @@ BOOL SvxCaptionTabPage::FillItemSet( SfxItemSet& _rOutAttrs) //NYI-------------die Winkel muessen noch hier rein!!! XXX---------------------- - return( TRUE ); + return( sal_True ); } // ----------------------------------------------------------------------- @@ -259,7 +259,7 @@ void SvxCaptionTabPage::Reset( const SfxItemSet& ) SfxItemPool* pPool = rOutAttrs.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); - USHORT nWhich; + sal_uInt16 nWhich; SfxMapUnit eUnit; //------- Winkel ---------- @@ -383,14 +383,14 @@ SfxTabPage* SvxCaptionTabPage::Create( Window* pWindow, //------------------------------------------------------------------------ -USHORT* SvxCaptionTabPage::GetRanges() +sal_uInt16* SvxCaptionTabPage::GetRanges() { return( pCaptionRanges ); } //------------------------------------------------------------------------ -void SvxCaptionTabPage::SetupAnsatz_Impl( USHORT nType ) +void SvxCaptionTabPage::SetupAnsatz_Impl( sal_uInt16 nType ) { xub_StrLen nCnt=0, nIdx=0; @@ -507,7 +507,7 @@ IMPL_LINK_INLINE_END( SvxCaptionTabPage, SelectCaptTypeHdl_Impl, void *, EMPTYAR //------------------------------------------------------------------------ -void SvxCaptionTabPage::SetupType_Impl( USHORT nType ) +void SvxCaptionTabPage::SetupType_Impl( sal_uInt16 nType ) { switch( nType-1 ) { @@ -568,7 +568,7 @@ void SvxCaptionTabPage::FillValueSet() //======================================================================== -SvxCaptionTabDialog::SvxCaptionTabDialog(Window* pParent, const SdrView* pSdrView, USHORT nAnchorTypes) +SvxCaptionTabDialog::SvxCaptionTabDialog(Window* pParent, const SdrView* pSdrView, sal_uInt16 nAnchorTypes) : SfxTabDialog( pParent, CUI_RES( RID_SVXDLG_CAPTION ) ), pView ( pSdrView ), nAnchorCtrls(nAnchorTypes) @@ -602,7 +602,7 @@ SvxCaptionTabDialog::~SvxCaptionTabDialog() // ----------------------------------------------------------------------- -void SvxCaptionTabDialog::PageCreated( USHORT nId, SfxTabPage &rPage ) +void SvxCaptionTabDialog::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { switch( nId ) { diff --git a/cui/source/tabpages/labdlg.src b/cui/source/tabpages/labdlg.src index 36fb0f52d108..b096b01c0137 100644 --- a/cui/source/tabpages/labdlg.src +++ b/cui/source/tabpages/labdlg.src @@ -53,6 +53,7 @@ TabPage RID_SVXPAGE_CAPTION }; MetricField MF_ABSTAND { + HelpID = "cui:MetricField:RID_SVXPAGE_CAPTION:MF_ABSTAND"; Border = TRUE ; Pos = MAP_APPFONT ( 50 , 51 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -73,6 +74,7 @@ TabPage RID_SVXPAGE_CAPTION }; ListBox LB_WINKEL { + HelpID = "cui:ListBox:RID_SVXPAGE_CAPTION:LB_WINKEL"; Border = TRUE ; Pos = MAP_APPFONT ( 143 , 51 ) ; Size = MAP_APPFONT ( 50 , 60 ) ; @@ -96,6 +98,7 @@ TabPage RID_SVXPAGE_CAPTION }; ListBox LB_ANSATZ { + HelpID = "cui:ListBox:RID_SVXPAGE_CAPTION:LB_ANSATZ"; Border = TRUE ; Pos = MAP_APPFONT ( 50 , 67 ) ; Size = MAP_APPFONT ( 50 , 60 ) ; @@ -119,6 +122,7 @@ TabPage RID_SVXPAGE_CAPTION }; MetricField MF_ANSATZ { + HelpID = "cui:MetricField:RID_SVXPAGE_CAPTION:MF_ANSATZ"; Border = TRUE ; Pos = MAP_APPFONT ( 143 , 67 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -139,6 +143,7 @@ TabPage RID_SVXPAGE_CAPTION }; ListBox LB_ANSATZ_REL { + HelpID = "cui:ListBox:RID_SVXPAGE_CAPTION:LB_ANSATZ_REL"; Border = TRUE ; Pos = MAP_APPFONT ( 143 , 67 ) ; Size = MAP_APPFONT ( 50 , 60 ) ; @@ -153,6 +158,7 @@ TabPage RID_SVXPAGE_CAPTION }; MetricField MF_LAENGE { + HelpID = "cui:MetricField:RID_SVXPAGE_CAPTION:MF_LAENGE"; Border = TRUE ; Pos = MAP_APPFONT ( 50 , 83 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -167,6 +173,7 @@ TabPage RID_SVXPAGE_CAPTION }; CheckBox CB_LAENGE { + HelpID = "cui:CheckBox:RID_SVXPAGE_CAPTION:CB_LAENGE"; Pos = MAP_APPFONT ( 106 , 84 ) ; Size = MAP_APPFONT ( 50 , 10 ) ; TabStop = TRUE ; diff --git a/cui/source/tabpages/macroass.cxx b/cui/source/tabpages/macroass.cxx index fe8107ef8b85..2084b64da970 100644 --- a/cui/source/tabpages/macroass.cxx +++ b/cui/source/tabpages/macroass.cxx @@ -41,10 +41,11 @@ #include <svtools/svmedit.hxx> #include "cfgutil.hxx" #include <sfx2/app.hxx> +#include <sfx2/evntconf.hxx> #include <sfx2/objsh.hxx> #include "macroass.hrc" #include "cuires.hrc" -#include <sfx2/macrconf.hxx> +#include <vcl/fixed.hxx> #include "headertablistbox.hxx" using ::com::sun::star::uno::Reference; @@ -61,7 +62,6 @@ public: PushButton* pDeletePB; String* pStrEvent; String* pAssignedMacro; - ListBox* pScriptTypeLB; _HeaderTabListBox* pEventLB; SfxConfigGroupListBox_Impl* pGroupLB; FixedText* pFT_MacroLBLabel; @@ -69,12 +69,10 @@ public: FixedText* pMacroFT; String* pMacroStr; - FNGetRangeHdl fnGetRange; - FNGetMacrosOfRangeHdl fnGetMacroOfRange; - BOOL bReadOnly; + sal_Bool bReadOnly; Timer maFillGroupTimer; - BOOL bGotEvents; + sal_Bool bGotEvents; }; _SfxMacroTabPage_Impl::_SfxMacroTabPage_Impl( void ) : @@ -82,17 +80,14 @@ _SfxMacroTabPage_Impl::_SfxMacroTabPage_Impl( void ) : pDeletePB( NULL ), pStrEvent( NULL ), pAssignedMacro( NULL ), - pScriptTypeLB( NULL ), pEventLB( NULL ), pGroupLB( NULL ), pFT_MacroLBLabel( NULL ), pMacroLB( NULL ), pMacroFT( NULL ), pMacroStr( NULL ), - fnGetRange( NULL ), - fnGetMacroOfRange( NULL ), - bReadOnly( FALSE ), - bGotEvents( FALSE ) + bReadOnly( sal_False ), + bGotEvents( sal_False ) { } @@ -102,7 +97,6 @@ _SfxMacroTabPage_Impl::~_SfxMacroTabPage_Impl() delete pDeletePB; delete pStrEvent; delete pAssignedMacro; - delete pScriptTypeLB; delete pEventLB; delete pGroupLB; delete pMacroLB; @@ -112,10 +106,7 @@ _SfxMacroTabPage_Impl::~_SfxMacroTabPage_Impl() } -SvStringsDtor* _ImpGetRangeHdl( _SfxMacroTabPage*, const String& rLanguage ); -SvStringsDtor* _ImpGetMacrosOfRangeHdl( _SfxMacroTabPage*, const String& rLanguage, const String& rRange ); - -static USHORT aPageRg[] = { +static sal_uInt16 aPageRg[] = { SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, 0 }; @@ -137,13 +128,13 @@ static long nTabs[] = #define LB_EVENTS_ITEMPOS 1 #define LB_MACROS_ITEMPOS 2 -String ConvertToUIName_Impl( SvxMacro *pMacro, const String& /*rLanguage*/ ) +String ConvertToUIName_Impl( SvxMacro *pMacro ) { String aName( pMacro->GetMacName() ); String aEntry; if ( ! pMacro->GetLanguage().EqualsAscii("JavaScript") ) { - USHORT nCount = aName.GetTokenCount('.'); + sal_uInt16 nCount = aName.GetTokenCount('.'); aEntry = aName.GetToken( nCount-1, '.' ); if ( nCount > 2 ) { @@ -159,36 +150,24 @@ String ConvertToUIName_Impl( SvxMacro *pMacro, const String& /*rLanguage*/ ) return aName; } -void _SfxMacroTabPage::EnableButtons( const String& rLangName ) +void _SfxMacroTabPage::EnableButtons() { // Solange die Eventbox leer ist, nichts tun const SvLBoxEntry* pE = mpImpl->pEventLB->GetListBox().FirstSelected(); if ( pE ) { // Gebundenes Macro holen - const SvxMacro* pM = aTbl.Get( (USHORT)(ULONG) pE->GetUserData() ); + const SvxMacro* pM = aTbl.Get( (sal_uInt16)(sal_uLong) pE->GetUserData() ); mpImpl->pDeletePB->Enable( 0 != pM && !mpImpl->bReadOnly ); - // Bei gleichem ScriptType Zuweisung nur, wenn Macro sich - // ge"andert hat; bei verschiedenem ScriptType, wenn Script nicht leer String sEventMacro; sEventMacro = ((SvLBoxString*)pE->GetItem( LB_MACROS_ITEMPOS ))->GetText(); - if ( rLangName.EqualsAscii("JavaScript") ) - { - OSL_FAIL( "_SfxMacroTabPage::EnableButtons(): this is not an up to date usage!" ); - } - else - { - SfxMacroInfo* pInfo = mpImpl->pMacroLB->GetMacroInfo(); - String sSelMacro; - if ( pInfo ) - sSelMacro = pInfo->GetMacroName(); - if( pM && rLangName != pM->GetLanguage() ) - mpImpl->pAssignPB->Enable( pInfo != 0 && !mpImpl->bReadOnly ); - else - mpImpl->pAssignPB->Enable( pInfo && !mpImpl->bReadOnly && !sSelMacro.EqualsIgnoreCaseAscii( sEventMacro ) ); - } + + String sScriptURI = mpImpl->pMacroLB->GetSelectedScriptURI(); + mpImpl->pAssignPB->Enable( !mpImpl->bReadOnly && !sScriptURI.EqualsIgnoreCaseAscii( sEventMacro ) ); } + else + mpImpl->pAssignPB->Enable( sal_False ); } _SfxMacroTabPage::_SfxMacroTabPage( Window* pParent, const ResId& rResId, const SfxItemSet& rAttrSet ) @@ -196,8 +175,6 @@ _SfxMacroTabPage::_SfxMacroTabPage( Window* pParent, const ResId& rResId, const { mpImpl = new _SfxMacroTabPage_Impl; - mpImpl->fnGetRange = &_ImpGetRangeHdl; - mpImpl->fnGetMacroOfRange = &_ImpGetMacrosOfRangeHdl; } _SfxMacroTabPage::~_SfxMacroTabPage() @@ -205,7 +182,7 @@ _SfxMacroTabPage::~_SfxMacroTabPage() DELETEZ( mpImpl ); } -void _SfxMacroTabPage::AddEvent( const String & rEventName, USHORT nEventId ) +void _SfxMacroTabPage::AddEvent( const String & rEventName, sal_uInt16 nEventId ) { String sTmp( rEventName ); sTmp += '\t'; @@ -214,7 +191,7 @@ void _SfxMacroTabPage::AddEvent( const String & rEventName, USHORT nEventId ) SvxMacro* pM = aTbl.Get( nEventId ); if( pM ) { - String sNew( ConvertToUIName_Impl( pM, mpImpl->pScriptTypeLB->GetSelectEntry() ) ); + String sNew( ConvertToUIName_Impl( pM ) ); sTmp += sNew; } @@ -222,60 +199,39 @@ void _SfxMacroTabPage::AddEvent( const String & rEventName, USHORT nEventId ) pE->SetUserData( reinterpret_cast< void* >( sal::static_int_cast< sal_IntPtr >( nEventId )) ); } -void _SfxMacroTabPage::ScriptChanged( const String& aLangName ) +void _SfxMacroTabPage::ScriptChanged() { // neue Bereiche und deren Funktionen besorgen { - mpImpl->pGroupLB->SetScriptType( aLangName ); mpImpl->pGroupLB->Show(); mpImpl->pMacroLB->Show(); mpImpl->pMacroFT->SetText( *mpImpl->pMacroStr ); } - EnableButtons( aLangName ); -} - -void _SfxMacroTabPage::SetGetRangeLink( FNGetRangeHdl pFn ) -{ - mpImpl->fnGetRange = pFn; -} - -FNGetRangeHdl _SfxMacroTabPage::GetGetRangeLink() const -{ - return mpImpl->fnGetRange; -} - -void _SfxMacroTabPage::SetGetMacrosOfRangeLink( FNGetMacrosOfRangeHdl pFn ) -{ - mpImpl->fnGetMacroOfRange = pFn; -} - -FNGetMacrosOfRangeHdl _SfxMacroTabPage::GetGetMacrosOfRangeLink() const -{ - return mpImpl->fnGetMacroOfRange; + EnableButtons(); } -BOOL _SfxMacroTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool _SfxMacroTabPage::FillItemSet( SfxItemSet& rSet ) { SvxMacroItem aItem( GetWhich( aPageRg[0] ) ); ((SvxMacroTableDtor&)aItem.GetMacroTable()) = aTbl; const SfxPoolItem* pItem; - if( SFX_ITEM_SET != GetItemSet().GetItemState( aItem.Which(), TRUE, &pItem ) + if( SFX_ITEM_SET != GetItemSet().GetItemState( aItem.Which(), sal_True, &pItem ) || aItem != *(SvxMacroItem*)pItem ) { rSet.Put( aItem ); - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } void _SfxMacroTabPage::PageCreated (SfxAllItemSet aSet) { const SfxPoolItem* pEventsItem; - if( !mpImpl->bGotEvents && SFX_ITEM_SET == aSet.GetItemState( SID_EVENTCONFIG, TRUE, &pEventsItem ) ) + if( !mpImpl->bGotEvents && SFX_ITEM_SET == aSet.GetItemState( SID_EVENTCONFIG, sal_True, &pEventsItem ) ) { - mpImpl->bGotEvents = TRUE; + mpImpl->bGotEvents = sal_True; const SfxEventNamesList& rList = ((SfxEventNamesItem*)pEventsItem)->GetEvents(); for ( size_t nNo = 0, nCnt = rList.size(); nNo < nCnt; ++nNo ) { @@ -288,13 +244,13 @@ void _SfxMacroTabPage::PageCreated (SfxAllItemSet aSet) void _SfxMacroTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; - if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( aPageRg[0] ), TRUE, &pItem )) + if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( aPageRg[0] ), sal_True, &pItem )) aTbl = ((SvxMacroItem*)pItem)->GetMacroTable(); const SfxPoolItem* pEventsItem; - if( !mpImpl->bGotEvents && SFX_ITEM_SET == rSet.GetItemState( SID_EVENTCONFIG, TRUE, &pEventsItem ) ) + if( !mpImpl->bGotEvents && SFX_ITEM_SET == rSet.GetItemState( SID_EVENTCONFIG, sal_True, &pEventsItem ) ) { - mpImpl->bGotEvents = TRUE; + mpImpl->bGotEvents = sal_True; const SfxEventNamesList& rList = ((SfxEventNamesItem*)pEventsItem)->GetEvents(); for ( size_t nNo = 0, nCnt = rList.size(); nNo < nCnt; ++nNo ) { @@ -311,12 +267,7 @@ void _SfxMacroTabPage::Reset( const SfxItemSet& rSet ) rListBox.SetCurEntry( pE ); } -void _SfxMacroTabPage::SetReadOnly( BOOL bSet ) -{ - mpImpl->bReadOnly = bSet; -} - -BOOL _SfxMacroTabPage::IsReadOnly() const +sal_Bool _SfxMacroTabPage::IsReadOnly() const { return mpImpl->bReadOnly; } @@ -326,7 +277,7 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, SelectEvent_Impl, SvTabListBox*, EMPTYARG ) _SfxMacroTabPage_Impl* pImpl = pThis->mpImpl; SvHeaderTabListBox& rListBox = pImpl->pEventLB->GetListBox(); SvLBoxEntry* pE = rListBox.FirstSelected(); - ULONG nPos; + sal_uLong nPos; if( !pE || LISTBOX_ENTRY_NOTFOUND == ( nPos = rListBox.GetModel()->GetAbsPos( pE ) ) ) { @@ -334,24 +285,8 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, SelectEvent_Impl, SvTabListBox*, EMPTYARG ) return 0; } - USHORT nEventId = (USHORT)(ULONG)pE->GetUserData(); - String aLanguage = pImpl->pScriptTypeLB->GetSelectEntry(); - - const SvxMacro* pM = pThis->aTbl.Get( nEventId ); - if( pM ) - { - if( aLanguage != pM->GetLanguage() ) - { - pImpl->pScriptTypeLB->SelectEntry( pM->GetLanguage() ); - pThis->ScriptChanged( pM->GetLanguage() ); - } - else - { - DBG_ASSERT( !aLanguage.EqualsAscii("JavaScript"), "_SfxMacroTabPage, SelectEvent_Impl(): outdated use!" ); - } - } - - pThis->EnableButtons( aLanguage ); + pThis->ScriptChanged(); + pThis->EnableButtons(); return 0; } @@ -359,26 +294,14 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, SelectGroup_Impl, ListBox*, EMPTYARG ) { _SfxMacroTabPage_Impl* pImpl = pThis->mpImpl; String sSel( pImpl->pGroupLB->GetGroup() ); - String aLanguage = pImpl->pScriptTypeLB->GetSelectEntry(); - if( !aLanguage.EqualsAscii( "JavaScript" ) ) - { - pImpl->pGroupLB->GroupSelected(); - SfxMacroInfo* pMacro = pImpl->pMacroLB->GetMacroInfo(); - String aLabelText; - if( pMacro ) - { - aLabelText = pImpl->maStaticMacroLBLabel; - aLabelText += pMacro->GetModuleName(); - } - else - { - // Wenn dort ein Macro drin ist, wurde es selektiert und der - // AssignButton schon in SelectMacro richtig enabled - pImpl->pAssignPB->Enable( FALSE ); - } - - pImpl->pFT_MacroLBLabel->SetText( aLabelText ); - } + pImpl->pGroupLB->GroupSelected(); + const String sScriptURI = pImpl->pMacroLB->GetSelectedScriptURI(); + String aLabelText; + if( sScriptURI.Len() > 0 ) + aLabelText = pImpl->maStaticMacroLBLabel; + pImpl->pFT_MacroLBLabel->SetText( aLabelText ); + + pThis->EnableButtons(); return 0; } @@ -386,13 +309,7 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, SelectMacro_Impl, ListBox*, EMPTYARG ) { _SfxMacroTabPage_Impl* pImpl = pThis->mpImpl; pImpl->pMacroLB->FunctionSelected(); - pThis->EnableButtons( pImpl->pScriptTypeLB->GetSelectEntry() ); - return 0; -} - -IMPL_STATIC_LINK( _SfxMacroTabPage, GetFocus_Impl, Edit*, EMPTYARG ) -{ - pThis->EnableButtons( DEFINE_CONST_UNICODE("JavaScript") ); + pThis->EnableButtons(); return 0; } @@ -401,7 +318,7 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, AssignDeleteHdl_Impl, PushButton*, pBtn ) _SfxMacroTabPage_Impl* pImpl = pThis->mpImpl; SvHeaderTabListBox& rListBox = pImpl->pEventLB->GetListBox(); SvLBoxEntry* pE = rListBox.FirstSelected(); - ULONG nPos; + sal_uLong nPos; if( !pE || LISTBOX_ENTRY_NOTFOUND == ( nPos = rListBox.GetModel()->GetAbsPos( pE ) ) ) { @@ -409,58 +326,38 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, AssignDeleteHdl_Impl, PushButton*, pBtn ) return 0; } - const BOOL bAssEnabled = pBtn != pImpl->pDeletePB && pImpl->pAssignPB->IsEnabled(); + const sal_Bool bAssEnabled = pBtn != pImpl->pDeletePB && pImpl->pAssignPB->IsEnabled(); // aus der Tabelle entfernen - USHORT nEvent = (USHORT)(ULONG)pE->GetUserData(); + sal_uInt16 nEvent = (sal_uInt16)(sal_uLong)pE->GetUserData(); SvxMacro *pRemoveMacro = pThis->aTbl.Remove( nEvent ); delete pRemoveMacro; - String aLanguage = pImpl->pScriptTypeLB->GetSelectEntry(); - String sNew; + String sScriptURI; if( bAssEnabled ) { - String sGroup; - String sMacro; - String aEntryText( sNew ); - DBG_ASSERT( !aLanguage.EqualsAscii("JavaScript"), "_SfxMacroTabPage, AssignDeleteHdl_Impl(): outdated use!" ); - - SfxMacroInfo* pMacro = pImpl->pMacroLB->GetMacroInfo(); - sMacro = pMacro->GetQualifiedName(); - sGroup = pImpl->pGroupLB->GetGroup(); - sNew = pMacro->GetMacroName(); - - if( sMacro.CompareToAscii( "vnd.sun.star.script:", 20 ) == COMPARE_EQUAL ) + sScriptURI = pImpl->pMacroLB->GetSelectedScriptURI(); + if( sScriptURI.CompareToAscii( "vnd.sun.star.script:", 20 ) == COMPARE_EQUAL ) { - OSL_TRACE("ASSIGN_DELETE: Its a script"); pThis->aTbl.Insert( - nEvent, new SvxMacro( sMacro, String::CreateFromAscii("Script") ) ); + nEvent, new SvxMacro( sScriptURI, String::CreateFromAscii( SVX_MACRO_LANGUAGE_SF ) ) ); } else { - OSL_TRACE("ASSIGN_DELETE: Its a basic macro"); - String sBasicName/*(SfxResId(STR_BASICNAME))*/; - if ( aLanguage == sBasicName ) - pThis->aTbl.Insert( nEvent, new SvxMacro( sMacro, sGroup, STARBASIC ) ); - else - pThis->aTbl.Insert( nEvent, new SvxMacro( sMacro, aLanguage ) ); + OSL_ENSURE( false, "_SfxMacroTabPage::AssignDeleteHdl_Impl: this branch is *not* dead? (out of interest: tell fs, please!)" ); + pThis->aTbl.Insert( + nEvent, new SvxMacro( sScriptURI, String::CreateFromAscii( SVX_MACRO_LANGUAGE_STARBASIC ) ) ); } } - pImpl->pEventLB->SetUpdateMode( FALSE ); - pE->ReplaceItem( new SvLBoxString( pE, 0, sNew ), LB_MACROS_ITEMPOS ); + pImpl->pEventLB->SetUpdateMode( sal_False ); + pE->ReplaceItem( new SvLBoxString( pE, 0, sScriptURI ), LB_MACROS_ITEMPOS ); rListBox.GetModel()->InvalidateEntry( pE ); rListBox.Select( pE ); rListBox.MakeVisible( pE ); - rListBox.SetUpdateMode( TRUE ); - - pThis->EnableButtons( aLanguage ); - return 0; -} + rListBox.SetUpdateMode( sal_True ); -IMPL_STATIC_LINK( _SfxMacroTabPage, ChangeScriptHdl_Impl, RadioButton*, EMPTYARG ) -{ - pThis->ScriptChanged( pThis->mpImpl->pScriptTypeLB->GetSelectEntry() ); + pThis->EnableButtons(); return 0; } @@ -472,12 +369,12 @@ IMPL_STATIC_LINK( _SfxMacroTabPage, TimeOut_Impl, Timer*, EMPTYARG ) if ( pTabDlg ) { pTabDlg->EnterWait(); - pTabDlg->EnableInput( FALSE ); + pTabDlg->EnableInput( sal_False ); } pThis->FillMacroList(); if ( pTabDlg ) { - pTabDlg->EnableInput( TRUE ); + pTabDlg->EnableInput( sal_True ); pTabDlg->LeaveWait(); } return 0; @@ -498,8 +395,6 @@ void _SfxMacroTabPage::InitAndSetHandler() mpImpl->pGroupLB->SetSelectHdl( STATIC_LINK( this, _SfxMacroTabPage, SelectGroup_Impl )); mpImpl->pMacroLB->SetSelectHdl( STATIC_LINK( this, _SfxMacroTabPage, SelectMacro_Impl )); - mpImpl->pScriptTypeLB->SetSelectHdl( STATIC_LINK( this, _SfxMacroTabPage, ChangeScriptHdl_Impl )); - rListBox.SetSelectionMode( SINGLE_SELECTION ); rListBox.SetTabs( &nTabs[0], MAP_APPFONT ); Size aSize( nTabs[ 2 ], 0 ); @@ -511,14 +406,9 @@ void _SfxMacroTabPage::InitAndSetHandler() mpImpl->pEventLB->Show(); mpImpl->pEventLB->ConnectElements(); - mpImpl->pEventLB->Enable( TRUE ); - mpImpl->pGroupLB->Enable( TRUE ); - mpImpl->pMacroLB->Enable( TRUE ); - - mpImpl->pScriptTypeLB->SetDropDownLineCount( 3 ); - String sBasicName/*(SfxResId(STR_BASICNAME))*/; - mpImpl->pScriptTypeLB->InsertEntry( sBasicName ); - mpImpl->pScriptTypeLB->SelectEntry( sBasicName ); + mpImpl->pEventLB->Enable( sal_True ); + mpImpl->pGroupLB->Enable( sal_True ); + mpImpl->pMacroLB->Enable( sal_True ); mpImpl->pGroupLB->SetFunctionListBox( mpImpl->pMacroLB ); @@ -529,33 +419,21 @@ void _SfxMacroTabPage::InitAndSetHandler() void _SfxMacroTabPage::FillMacroList() { - String aLanguage = mpImpl->pScriptTypeLB->GetSelectEntry(); - if( ! aLanguage.EqualsAscii("JavaScript") ) - { - // 2 Listboxen - SvStringsDtor* pArr = (*mpImpl->fnGetRange)( this, String(/*SfxResId(STR_BASICNAME)*/) ); - if( pArr ) - { - mpImpl->pGroupLB->Init( - ::com::sun::star::uno::Reference< - ::com::sun::star::lang::XMultiServiceFactory >(), - GetFrame(), - ::rtl::OUString() ); - - delete pArr; - } - } + mpImpl->pGroupLB->Init( + ::com::sun::star::uno::Reference< + ::com::sun::star::lang::XMultiServiceFactory >(), + GetFrame(), + ::rtl::OUString() ); } void _SfxMacroTabPage::FillEvents() { SvHeaderTabListBox& rListBox = mpImpl->pEventLB->GetListBox(); - String aLanguage = mpImpl->pScriptTypeLB->GetSelectEntry(); - ULONG nEntryCnt = rListBox.GetEntryCount(); + sal_uLong nEntryCnt = rListBox.GetEntryCount(); // Events aus der Tabelle holen und die EventListBox entsprechen fuellen - for( ULONG n = 0 ; n < nEntryCnt ; ++n ) + for( sal_uLong n = 0 ; n < nEntryCnt ; ++n ) { SvLBoxEntry* pE = rListBox.GetEntry( n ); if( pE ) @@ -565,9 +443,9 @@ void _SfxMacroTabPage::FillEvents() String sOld( pLItem->GetText() ); String sNew; - USHORT nEventId = ( USHORT ) ( ULONG ) pE->GetUserData(); + sal_uInt16 nEventId = ( sal_uInt16 ) ( sal_uLong ) pE->GetUserData(); if( aTbl.IsKeyValid( nEventId ) ) - sNew = ConvertToUIName_Impl( aTbl.Get( nEventId ), aLanguage ); + sNew = ConvertToUIName_Impl( aTbl.Get( nEventId ) ); if( sOld != sNew ) { @@ -578,96 +456,6 @@ void _SfxMacroTabPage::FillEvents() } } -void _SfxMacroTabPage::SelectEvent( const String & /*rEventName*/, USHORT nEventId ) -{ - SvHeaderTabListBox& rListBox = mpImpl->pEventLB->GetListBox(); - ULONG nEntryCnt = rListBox.GetEntryCount(); - - for( ULONG n = 0 ; n < nEntryCnt ; ++n ) - { - SvLBoxEntry* pE = rListBox.GetEntry( n ); - if( pE && ( USHORT ) ( ULONG ) pE->GetUserData() == nEventId ) - { - rListBox.SetCurEntry( pE ); - rListBox.MakeVisible( pE ); - break; - } - } -} - - -SvStringsDtor* _ImpGetRangeHdl( _SfxMacroTabPage* /*pTbPg*/, const String& rLanguage ) -{ - SvStringsDtor* pNew = new SvStringsDtor; - SfxApplication* pSfxApp = SFX_APP(); - - if ( !rLanguage.EqualsAscii("JavaScript") ) - { - pSfxApp->EnterBasicCall(); - - // AppBasic einf"ugen - String* pNewEntry = new String( pSfxApp->GetName() ); - pNew->Insert( pNewEntry, pNew->Count() ); - - // Aktuelles Dokument - SfxObjectShell* pDoc = SfxObjectShell::Current(); - if ( pDoc ) - { - String aTitle = pDoc->GetTitle(); - - // Hack f"ur Aufruf aus der Basic-IDE : das Basic ermitteln, das - // gerade bearbeitet wird - - String aAppName(DEFINE_CONST_UNICODE("BASIC - ")); - USHORT nLen = aAppName.Len(); - if ( aTitle.CompareIgnoreCaseToAscii( aAppName, nLen ) == COMPARE_EQUAL ) - { - // Basic-Namensprefix entfernen - aTitle.Erase( 0, nLen ); - USHORT nIndex=0, nCount=aTitle.GetTokenCount('.'); - if ( nCount > 1 ) - { - // Namen der Library entfernen - aTitle.GetToken( nCount-2, '.', nIndex ); - aTitle.Erase( nIndex-1 ); - } - - // Wenn das App-Basic gerade in der Basic-IDE bearbeitet wird, kein - // Dokument verwenden - pDoc = SfxObjectShell::GetFirst(); - while( pDoc ) - { - if ( aTitle == pDoc->GetTitle() ) - break; - pDoc = SfxObjectShell::GetNext( *pDoc ); - } - } - - if ( pDoc && pDoc->GetBasicManager() != SFX_APP()->GetBasicManager() && - pDoc->GetBasicManager()->GetLibCount() ) - { - pNewEntry = new String( aTitle ); - pNew->Insert( pNewEntry, pNew->Count() ); - } - } - - pSfxApp->LeaveBasicCall(); - } - - return pNew; -} - -// besorgen der Funktionen eines Bereiches -SvStringsDtor* _ImpGetMacrosOfRangeHdl( - _SfxMacroTabPage* /*pTbPg*/, - const String& /*rLanguage*/, - const String& /*rRange*/ ) -{ - SvStringsDtor* pNew = new SvStringsDtor; - return pNew; -} - - SfxMacroTabPage::SfxMacroTabPage( Window* pParent, const ResId& rResId, const Reference< XFrame >& rxDocumentFrame, const SfxItemSet& rSet ) : _SfxMacroTabPage( pParent, rResId, rSet ) { @@ -676,8 +464,6 @@ SfxMacroTabPage::SfxMacroTabPage( Window* pParent, const ResId& rResId, const Re mpImpl->pEventLB = new _HeaderTabListBox( this, CUI_RES( LB_EVENT ) ); mpImpl->pAssignPB = new PushButton( this, CUI_RES( PB_ASSIGN ) ); mpImpl->pDeletePB = new PushButton( this, CUI_RES( PB_DELETE ) ); - mpImpl->pScriptTypeLB = new ListBox(this, CUI_RES( LB_SCRIPTTYPE ) ); - mpImpl->pScriptTypeLB->Hide(); mpImpl->pMacroFT = new FixedText( this, CUI_RES( FT_MACRO ) ); mpImpl->pGroupLB = new SfxConfigGroupListBox_Impl( this, CUI_RES( LB_GROUP ) ); mpImpl->pFT_MacroLBLabel = new FixedText( this, CUI_RES( FT_LABEL4LB_MACROS ) ); @@ -691,7 +477,7 @@ SfxMacroTabPage::SfxMacroTabPage( Window* pParent, const ResId& rResId, const Re InitAndSetHandler(); - ScriptChanged( String( /*SfxResId(STR_BASICNAME)*/ ) ); + ScriptChanged(); } SfxTabPage* SfxMacroTabPage::Create( Window* pParent, const SfxItemSet& rAttrSet ) diff --git a/cui/source/tabpages/macroass.hrc b/cui/source/tabpages/macroass.hrc index 614711e1981e..73292a7f1b0e 100644 --- a/cui/source/tabpages/macroass.hrc +++ b/cui/source/tabpages/macroass.hrc @@ -38,7 +38,7 @@ #define FT_MACRO 5 #define LB_GROUP 6 #define LB_MACROS 7 -#define LB_SCRIPTTYPE 8 + // FREE #define FT_LABEL4LB_MACROS 9 #define STR_JAVASCRIPT 10 #define STR_MACROS 11 diff --git a/cui/source/tabpages/macroass.src b/cui/source/tabpages/macroass.src index 36c4a9115105..b5269c81ae3d 100644 --- a/cui/source/tabpages/macroass.src +++ b/cui/source/tabpages/macroass.src @@ -32,6 +32,7 @@ TabPage RID_SVXPAGE_EVENTASSIGN { + HelpID = "cui:TabPage:RID_SVXPAGE_EVENTASSIGN"; Hide = TRUE ; SVLook = TRUE ; DialogControl = TRUE ; @@ -77,7 +78,7 @@ TabPage RID_SVXPAGE_EVENTASSIGN Pos = MAP_APPFONT ( COL2 , ROW7 ) ; Size = MAP_APPFONT ( WIDTH1 , RSC_CD_FIXEDTEXT_HEIGHT + HEIGHT_EXTRA7 ) ; WordBreak = TRUE; - Text [ en-US ] = "~Existing macros in:\n" ; + Text [ en-US ] = "~Existing macros\n" ; }; Control LB_MACROS { @@ -89,6 +90,7 @@ TabPage RID_SVXPAGE_EVENTASSIGN }; PushButton PB_ASSIGN { + HelpID = "cui:PushButton:RID_SVXPAGE_EVENTASSIGN:PB_ASSIGN"; Pos = MAP_APPFONT ( COL4 , ROW0 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Disable = TRUE ; @@ -97,22 +99,13 @@ TabPage RID_SVXPAGE_EVENTASSIGN }; PushButton PB_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_EVENTASSIGN:PB_DELETE"; Pos = MAP_APPFONT ( COL4 , ROW2 ) ; Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ) ; Disable = TRUE ; TabStop = TRUE ; Text [ en-US ] = "~Remove" ; }; - ListBox LB_SCRIPTTYPE - { - Pos = MAP_APPFONT ( COL4 , ROW4 ) ; - Size = MAP_APPFONT ( RSC_CD_PUSHBUTTON_WIDTH , 60 ) ; - // en-US was missing - Text [ en-US ] = "~Scripting Language" ; - TabStop = TRUE ; - Disable = FALSE ; - DropDown = TRUE ; - }; String STR_MACROS { Text [ en-US ] = "Macros" ; diff --git a/cui/source/tabpages/measure.cxx b/cui/source/tabpages/measure.cxx index 68dc7d5fb193..27743a3b1819 100644 --- a/cui/source/tabpages/measure.cxx +++ b/cui/source/tabpages/measure.cxx @@ -50,7 +50,7 @@ #include <sfx2/request.hxx> #include "svx/ofaitem.hxx" -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SDRATTR_MEASURE_FIRST, SDRATTR_MEASURE_LAST, @@ -126,8 +126,9 @@ SvxMeasurePage::SvxMeasurePage( Window* pWindow, const SfxItemSet& rInAttrs ) : aAttrSet ( *rInAttrs.GetPool() ), pView( 0 ), - bPositionModified ( FALSE ) + bPositionModified ( sal_False ) { + aCtlPreview.SetAccessibleName(aCtlPreview.GetHelpText()); FillUnitLB(); FreeResource(); @@ -166,6 +167,9 @@ SvxMeasurePage::SvxMeasurePage( Window* pWindow, const SfxItemSet& rInAttrs ) : aTsbParallel.SetClickHdl( aLink ); aTsbShowUnit.SetClickHdl( aLink ); aLbUnit.SetSelectHdl( aLink ); + aLbUnit.SetAccessibleName(GetNonMnemonicString(aTsbShowUnit.GetText())); + aCtlPosition.SetAccessibleRelationMemberOf( &aFlLabel ); + aLbUnit.SetAccessibleRelationLabeledBy( &aTsbShowUnit ); } /************************************************************************* @@ -271,7 +275,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) { aTsbBelowRefEdge.SetState( ( ( const SdrMeasureBelowRefEdgeItem& )rAttrs.Get( SDRATTR_MEASUREBELOWREFEDGE ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbBelowRefEdge.EnableTriState( FALSE ); + aTsbBelowRefEdge.EnableTriState( sal_False ); } else { @@ -285,7 +289,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_MEASUREDECIMALPLACES ); if( pItem ) { - INT16 nValue = ( ( const SdrMeasureDecimalPlacesItem* )pItem )->GetValue(); + sal_Int16 nValue = ( ( const SdrMeasureDecimalPlacesItem* )pItem )->GetValue(); aMtrFldDecimalPlaces.SetValue( nValue ); } else @@ -300,7 +304,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) { aTsbParallel.SetState( ( ( const SdrMeasureTextRota90Item& )rAttrs.Get( SDRATTR_MEASURETEXTROTA90 ) ). GetValue() ? STATE_NOCHECK : STATE_CHECK ); - aTsbParallel.EnableTriState( FALSE ); + aTsbParallel.EnableTriState( sal_False ); } else { @@ -313,7 +317,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) { aTsbShowUnit.SetState( ( ( const SdrMeasureShowUnitItem& )rAttrs.Get( SDRATTR_MEASURESHOWUNIT ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbShowUnit.EnableTriState( FALSE ); + aTsbShowUnit.EnableTriState( sal_False ); } else { @@ -327,7 +331,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) long nFieldUnit = (long) ( ( const SdrMeasureUnitItem& )rAttrs. Get( SDRATTR_MEASUREUNIT ) ).GetValue(); - for( USHORT i = 0; i < aLbUnit.GetEntryCount(); ++i ) + for( sal_uInt16 i = 0; i < aLbUnit.GetEntryCount(); ++i ) { if ( (long)aLbUnit.GetEntryData( i ) == nFieldUnit ) { @@ -350,8 +354,8 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) { if ( rAttrs.GetItemState( SDRATTR_MEASURETEXTHPOS ) != SFX_ITEM_DONTCARE ) { - aTsbAutoPosV.EnableTriState( FALSE ); - aTsbAutoPosH.EnableTriState( FALSE ); + aTsbAutoPosV.EnableTriState( sal_False ); + aTsbAutoPosH.EnableTriState( sal_False ); SdrMeasureTextHPos eHPos = (SdrMeasureTextHPos) ( ( const SdrMeasureTextHPosItem& )rAttrs.Get( SDRATTR_MEASURETEXTHPOS ) ).GetValue(); @@ -429,7 +433,7 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) ChangeAttrHdl_Impl( &aTsbShowUnit ); aCtlPreview.SetAttributes( rAttrs ); - bPositionModified = FALSE; + bPositionModified = sal_False; } /************************************************************************* @@ -438,86 +442,86 @@ void SvxMeasurePage::Reset( const SfxItemSet& rAttrs ) |* \************************************************************************/ -BOOL SvxMeasurePage::FillItemSet( SfxItemSet& rAttrs) +sal_Bool SvxMeasurePage::FillItemSet( SfxItemSet& rAttrs) { - BOOL bModified = FALSE; - INT32 nValue; + sal_Bool bModified = sal_False; + sal_Int32 nValue; TriState eState; if( aMtrFldLineDist.GetText() != aMtrFldLineDist.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldLineDist, eUnit ); rAttrs.Put( SdrMeasureLineDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldHelplineOverhang.GetText() != aMtrFldHelplineOverhang.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHelplineOverhang, eUnit ); rAttrs.Put( SdrMeasureHelplineOverhangItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldHelplineDist.GetText() != aMtrFldHelplineDist.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHelplineDist, eUnit ); rAttrs.Put( SdrMeasureHelplineDistItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldHelpline1Len.GetText() != aMtrFldHelpline1Len.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHelpline1Len, eUnit ); rAttrs.Put( SdrMeasureHelpline1LenItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( aMtrFldHelpline2Len.GetText() != aMtrFldHelpline2Len.GetSavedValue() ) { nValue = GetCoreValue( aMtrFldHelpline2Len, eUnit ); rAttrs.Put( SdrMeasureHelpline2LenItem( nValue ) ); - bModified = TRUE; + bModified = sal_True; } eState = aTsbBelowRefEdge.GetState(); if( eState != aTsbBelowRefEdge.GetSavedValue() ) { - rAttrs.Put( SdrMeasureBelowRefEdgeItem( (BOOL) STATE_CHECK == eState ) ); - bModified = TRUE; + rAttrs.Put( SdrMeasureBelowRefEdgeItem( (sal_Bool) STATE_CHECK == eState ) ); + bModified = sal_True; } if( aMtrFldDecimalPlaces.GetText() != aMtrFldDecimalPlaces.GetSavedValue() ) { - nValue = static_cast<INT32>(aMtrFldDecimalPlaces.GetValue()); + nValue = static_cast<sal_Int32>(aMtrFldDecimalPlaces.GetValue()); rAttrs.Put( SdrMeasureDecimalPlacesItem( - sal::static_int_cast< INT16 >( nValue ) ) ); - bModified = TRUE; + sal::static_int_cast< sal_Int16 >( nValue ) ) ); + bModified = sal_True; } eState = aTsbParallel.GetState(); if( eState != aTsbParallel.GetSavedValue() ) { - rAttrs.Put( SdrMeasureTextRota90Item( (BOOL) STATE_NOCHECK == eState ) ); - bModified = TRUE; + rAttrs.Put( SdrMeasureTextRota90Item( (sal_Bool) STATE_NOCHECK == eState ) ); + bModified = sal_True; } eState = aTsbShowUnit.GetState(); if( eState != aTsbShowUnit.GetSavedValue() ) { - rAttrs.Put( SdrMeasureShowUnitItem( (BOOL) STATE_CHECK == eState ) ); - bModified = TRUE; + rAttrs.Put( SdrMeasureShowUnitItem( (sal_Bool) STATE_CHECK == eState ) ); + bModified = sal_True; } - USHORT nPos = aLbUnit.GetSelectEntryPos(); + sal_uInt16 nPos = aLbUnit.GetSelectEntryPos(); if( nPos != aLbUnit.GetSavedValue() ) { if( nPos != LISTBOX_ENTRY_NOTFOUND ) { - USHORT nFieldUnit = (USHORT)(long)aLbUnit.GetEntryData( nPos ); + sal_uInt16 nFieldUnit = (sal_uInt16)(long)aLbUnit.GetEntryData( nPos ); FieldUnit _eUnit = (FieldUnit) nFieldUnit; rAttrs.Put( SdrMeasureUnitItem( _eUnit ) ); - bModified = TRUE; + bModified = sal_True; } } @@ -563,13 +567,13 @@ BOOL SvxMeasurePage::FillItemSet( SfxItemSet& rAttrs) if( eOldVPos != eVPos ) { rAttrs.Put( SdrMeasureTextVPosItem( eVPos ) ); - bModified = TRUE; + bModified = sal_True; } } else { rAttrs.Put( SdrMeasureTextVPosItem( eVPos ) ); - bModified = TRUE; + bModified = sal_True; } if ( rAttrs.GetItemState( SDRATTR_MEASURETEXTHPOS ) != SFX_ITEM_DONTCARE ) @@ -579,13 +583,13 @@ BOOL SvxMeasurePage::FillItemSet( SfxItemSet& rAttrs) if( eOldHPos != eHPos ) { rAttrs.Put( SdrMeasureTextHPosItem( eHPos ) ); - bModified = TRUE; + bModified = sal_True; } } else { rAttrs.Put( SdrMeasureTextHPosItem( eHPos ) ); - bModified = TRUE; + bModified = sal_True; } } @@ -625,7 +629,7 @@ SfxTabPage* SvxMeasurePage::Create( Window* pWindow, |* \************************************************************************/ -USHORT* SvxMeasurePage::GetRanges() +sal_uInt16* SvxMeasurePage::GetRanges() { return( pRanges ); } @@ -707,31 +711,31 @@ IMPL_LINK( SvxMeasurePage, ChangeAttrHdl_Impl, void *, p ) if( p == &aMtrFldLineDist ) { - INT32 nValue = GetCoreValue( aMtrFldLineDist, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldLineDist, eUnit ); aAttrSet.Put( SdrMeasureLineDistItem( nValue ) ); } if( p == &aMtrFldHelplineOverhang ) { - INT32 nValue = GetCoreValue( aMtrFldHelplineOverhang, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHelplineOverhang, eUnit ); aAttrSet.Put( SdrMeasureHelplineOverhangItem( nValue) ); } if( p == &aMtrFldHelplineDist ) { - INT32 nValue = GetCoreValue( aMtrFldHelplineDist, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHelplineDist, eUnit ); aAttrSet.Put( SdrMeasureHelplineDistItem( nValue) ); } if( p == &aMtrFldHelpline1Len ) { - INT32 nValue = GetCoreValue( aMtrFldHelpline1Len, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHelpline1Len, eUnit ); aAttrSet.Put( SdrMeasureHelpline1LenItem( nValue ) ); } if( p == &aMtrFldHelpline2Len ) { - INT32 nValue = GetCoreValue( aMtrFldHelpline2Len, eUnit ); + sal_Int32 nValue = GetCoreValue( aMtrFldHelpline2Len, eUnit ); aAttrSet.Put( SdrMeasureHelpline2LenItem( nValue ) ); } @@ -739,12 +743,12 @@ IMPL_LINK( SvxMeasurePage, ChangeAttrHdl_Impl, void *, p ) { TriState eState = aTsbBelowRefEdge.GetState(); if( eState != STATE_DONTKNOW ) - aAttrSet.Put( SdrMeasureBelowRefEdgeItem( (BOOL) STATE_CHECK == eState ) ); + aAttrSet.Put( SdrMeasureBelowRefEdgeItem( (sal_Bool) STATE_CHECK == eState ) ); } if( p == &aMtrFldDecimalPlaces ) { - INT16 nValue = sal::static_int_cast< INT16 >( + sal_Int16 nValue = sal::static_int_cast< sal_Int16 >( aMtrFldDecimalPlaces.GetValue() ); aAttrSet.Put( SdrMeasureDecimalPlacesItem( nValue ) ); } @@ -753,22 +757,22 @@ IMPL_LINK( SvxMeasurePage, ChangeAttrHdl_Impl, void *, p ) { TriState eState = aTsbParallel.GetState(); if( eState != STATE_DONTKNOW ) - aAttrSet.Put( SdrMeasureTextRota90Item( (BOOL) !STATE_CHECK == eState ) ); + aAttrSet.Put( SdrMeasureTextRota90Item( (sal_Bool) !STATE_CHECK == eState ) ); } if( p == &aTsbShowUnit ) { TriState eState = aTsbShowUnit.GetState(); if( eState != STATE_DONTKNOW ) - aAttrSet.Put( SdrMeasureShowUnitItem( (BOOL) STATE_CHECK == eState ) ); + aAttrSet.Put( SdrMeasureShowUnitItem( (sal_Bool) STATE_CHECK == eState ) ); } if( p == &aLbUnit ) { - USHORT nPos = aLbUnit.GetSelectEntryPos(); + sal_uInt16 nPos = aLbUnit.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { - USHORT nFieldUnit = (USHORT)(long)aLbUnit.GetEntryData( nPos ); + sal_uInt16 nFieldUnit = (sal_uInt16)(long)aLbUnit.GetEntryData( nPos ); FieldUnit _eUnit = (FieldUnit) nFieldUnit; aAttrSet.Put( SdrMeasureUnitItem( _eUnit ) ); } @@ -776,7 +780,7 @@ IMPL_LINK( SvxMeasurePage, ChangeAttrHdl_Impl, void *, p ) if( p == &aTsbAutoPosV || p == &aTsbAutoPosH || p == &aCtlPosition ) { - bPositionModified = TRUE; + bPositionModified = sal_True; // Position RECT_POINT eRP = aCtlPosition.GetActualRP(); @@ -846,10 +850,10 @@ void SvxMeasurePage::FillUnitLB() long nUnit = FUNIT_NONE; String aStrMetric( CUI_RES( STR_MEASURE_AUTOMATIC ) ); - USHORT nPos = aLbUnit.InsertEntry( aStrMetric ); + sal_uInt16 nPos = aLbUnit.InsertEntry( aStrMetric ); aLbUnit.SetEntryData( nPos, (void*)nUnit ); - for( USHORT i = 0; i < aMetricArr.Count(); ++i ) + for( sal_uInt16 i = 0; i < aMetricArr.Count(); ++i ) { aStrMetric = aMetricArr.GetStringByPos( i ); nUnit = aMetricArr.GetValue( i ); diff --git a/cui/source/tabpages/measure.src b/cui/source/tabpages/measure.src index 79c46b13079b..f01c2765ce0e 100644 --- a/cui/source/tabpages/measure.src +++ b/cui/source/tabpages/measure.src @@ -55,6 +55,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_LINE_DIST { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_LINE_DIST"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 14 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -77,6 +78,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_FLD_HELPLINE_OVERHANG { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_FLD_HELPLINE_OVERHANG"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 30 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -99,6 +101,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_FLD_HELPLINE_DIST { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_FLD_HELPLINE_DIST"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 46 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -121,6 +124,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_FLD_HELPLINE1_LEN { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_FLD_HELPLINE1_LEN"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 62 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -143,6 +147,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_FLD_HELPLINE2_LEN { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_FLD_HELPLINE2_LEN"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 78 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -159,6 +164,7 @@ TabPage RID_SVXPAGE_MEASURE }; TriStateBox TSB_BELOW_REF_EDGE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_MEASURE:TSB_BELOW_REF_EDGE"; Pos = MAP_APPFONT ( 12 , 96 ) ; Size = MAP_APPFONT ( 108 , 10 ) ; TabStop = TRUE ; @@ -173,6 +179,7 @@ TabPage RID_SVXPAGE_MEASURE }; MetricField MTR_FLD_DECIMALPLACES { + HelpID = "cui:MetricField:RID_SVXPAGE_MEASURE:MTR_FLD_DECIMALPLACES"; Border = TRUE ; Pos = MAP_APPFONT ( 78 , 110 ) ; Size = MAP_APPFONT ( 42 , 12 ) ; @@ -213,6 +220,7 @@ TabPage RID_SVXPAGE_MEASURE }; TriStateBox TSB_AUTOPOSV { + HelpID = "cui:TriStateBox:RID_SVXPAGE_MEASURE:TSB_AUTOPOSV"; Pos = MAP_APPFONT ( 154 , 54 ) ; Size = MAP_APPFONT ( 101 , 10 ) ; TabStop = TRUE ; @@ -220,6 +228,7 @@ TabPage RID_SVXPAGE_MEASURE }; TriStateBox TSB_AUTOPOSH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_MEASURE:TSB_AUTOPOSH"; Pos = MAP_APPFONT ( 154 , 68 ) ; Size = MAP_APPFONT ( 101 , 10 ) ; TabStop = TRUE ; @@ -227,6 +236,7 @@ TabPage RID_SVXPAGE_MEASURE }; TriStateBox TSB_PARALLEL { + HelpID = "cui:TriStateBox:RID_SVXPAGE_MEASURE:TSB_PARALLEL"; Pos = MAP_APPFONT ( 138 , 82 ) ; Size = MAP_APPFONT ( 110 , 10 ) ; TabStop = TRUE ; @@ -234,6 +244,7 @@ TabPage RID_SVXPAGE_MEASURE }; TriStateBox TSB_SHOW_UNIT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_MEASURE:TSB_SHOW_UNIT"; Pos = MAP_APPFONT ( 138 , 96 ) ; Size = MAP_APPFONT ( 64+40 , 10 ) ; TabStop = TRUE ; @@ -241,6 +252,7 @@ TabPage RID_SVXPAGE_MEASURE }; ListBox LB_UNIT { + HelpID = "cui:ListBox:RID_SVXPAGE_MEASURE:LB_UNIT"; Border = TRUE ; Pos = MAP_APPFONT ( 154 , 110 ) ; Size = MAP_APPFONT ( 60 , 80+35 ) ; diff --git a/cui/source/tabpages/numfmt.cxx b/cui/source/tabpages/numfmt.cxx index 6578599ee104..2fa12f871019 100644 --- a/cui/source/tabpages/numfmt.cxx +++ b/cui/source/tabpages/numfmt.cxx @@ -58,7 +58,7 @@ // static ---------------------------------------------------------------- -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_ATTR_NUMBERFORMAT_VALUE, SID_ATTR_NUMBERFORMAT_INFO, @@ -88,10 +88,10 @@ SvxNumberPreviewImpl::SvxNumberPreviewImpl( Window* pParent, const ResId& rResId { Font aFont( GetFont() ); - aFont.SetTransparent( TRUE ); + aFont.SetTransparent( sal_True ); aFont.SetColor( Application::GetSettings().GetStyleSettings().GetFieldColor() ); SetFont( aFont ); - InitSettings( TRUE, TRUE ); + InitSettings( sal_True, sal_True ); SetBorderStyle( WINDOW_BORDER_MONO ); } @@ -157,7 +157,7 @@ void SvxNumberPreviewImpl::Paint( const Rectangle& ) // ----------------------------------------------------------------------- -void SvxNumberPreviewImpl::InitSettings( BOOL bForeground, BOOL bBackground ) +void SvxNumberPreviewImpl::InitSettings( sal_Bool bForeground, sal_Bool bBackground ) { const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings(); @@ -186,9 +186,9 @@ void SvxNumberPreviewImpl::InitSettings( BOOL bForeground, BOOL bBackground ) void SvxNumberPreviewImpl::StateChanged( StateChangedType nType ) { if ( nType == STATE_CHANGE_CONTROLFOREGROUND ) - InitSettings( TRUE, FALSE ); + InitSettings( sal_True, sal_False ); else if ( nType == STATE_CHANGE_CONTROLBACKGROUND ) - InitSettings( FALSE, TRUE ); + InitSettings( sal_False, sal_True ); Window::StateChanged( nType ); } @@ -200,7 +200,7 @@ void SvxNumberPreviewImpl::DataChanged( const DataChangedEvent& rDCEvt ) Window::DataChanged( rDCEvt ); if ( ( rDCEvt.GetType() == DATACHANGED_SETTINGS ) && ( rDCEvt.GetFlags() & SETTINGS_STYLE ) ) - InitSettings( TRUE, TRUE ); + InitSettings( sal_True, sal_True ); } // class SvxNumberFormatTabPage ------------------------------------------ @@ -240,15 +240,20 @@ SvxNumberFormatTabPage::SvxNumberFormatTabPage( Window* pParent, aLbCurrency ( this, CUI_RES( LB_CURRENCY) ), aLbFormat ( this, CUI_RES( LB_FORMAT ) ), aFtLanguage ( this, CUI_RES( FT_LANGUAGE ) ), - aLbLanguage ( this, CUI_RES( LB_LANGUAGE ), FALSE ), + aLbLanguage ( this, CUI_RES( LB_LANGUAGE ), sal_False ), aCbSourceFormat ( this, CUI_RES( CB_SOURCEFORMAT ) ), +#if ENABLE_LAYOUT + aWndPreview ( LAYOUT_THIS_WINDOW(this), CUI_RES_PLAIN( WND_NUMBER_PREVIEW ) ), +#else + aWndPreview ( this, CUI_RES_PLAIN( WND_NUMBER_PREVIEW ) ), +#endif + aFlOptions ( this, CUI_RES( FL_OPTIONS ) ), aFtDecimals ( this, CUI_RES( FT_DECIMALS ) ), aEdDecimals ( this, CUI_RES( ED_DECIMALS ) ), + aBtnNegRed ( this, CUI_RES( BTN_NEGRED ) ), aFtLeadZeroes ( this, CUI_RES( FT_LEADZEROES ) ), aEdLeadZeroes ( this, CUI_RES( ED_LEADZEROES ) ), - aBtnNegRed ( this, CUI_RES( BTN_NEGRED ) ), aBtnThousand ( this, CUI_RES( BTN_THOUSAND ) ), - aFlOptions ( this, CUI_RES( FL_OPTIONS ) ), aFtEdFormat ( this, CUI_RES( FT_EDFORMAT ) ), aEdFormat ( this, CUI_RES( ED_FORMAT ) ), @@ -258,11 +263,6 @@ SvxNumberFormatTabPage::SvxNumberFormatTabPage( Window* pParent, aFtComment ( this, CUI_RES( FT_COMMENT ) ), aEdComment ( this, CUI_RES( ED_COMMENT ) ), -#if ENABLE_LAYOUT - aWndPreview ( LAYOUT_THIS_WINDOW(this), CUI_RES_PLAIN( WND_NUMBER_PREVIEW ) ), -#else - aWndPreview ( this, CUI_RES_PLAIN( WND_NUMBER_PREVIEW ) ), -#endif pNumItem ( NULL ), pNumFmtShell ( NULL ), nInitFormat ( ULONG_MAX ), @@ -290,8 +290,8 @@ void SvxNumberFormatTabPage::Init_Impl() { ImageList aIconList( CUI_RES_PLAIN ( IL_ICON ) ); - bNumItemFlag=TRUE; - bOneAreaFlag=FALSE; + bNumItemFlag=sal_True; + bOneAreaFlag=sal_False; nCatHeight=aLbCategory.GetSizePixel().Height(); @@ -304,15 +304,15 @@ void SvxNumberFormatTabPage::Init_Impl() aIbRemove. SetModeImage( aIconList.GetImage( IID_REMOVE ) ); aIbInfo. SetModeImage( aIconList.GetImage( IID_INFO ) ); - aIbAdd.Enable(FALSE ); - aIbRemove.Enable(FALSE ); - aIbInfo.Enable(FALSE ); + aIbAdd.Enable(sal_False ); + aIbRemove.Enable(sal_False ); + aIbInfo.Enable(sal_False ); aEdComment.SetText(aLbCategory.GetEntry(1)); //String fuer Benutzerdefiniert //holen aEdComment.Hide(); - aCbSourceFormat.Check( FALSE ); + aCbSourceFormat.Check( sal_False ); aCbSourceFormat.Disable(); aCbSourceFormat.Hide(); @@ -356,6 +356,13 @@ void SvxNumberFormatTabPage::Init_Impl() { aLbLanguage.InsertLanguage( xLang[i] ); } + + aIbAdd.SetAccessibleRelationLabeledBy( &aFtEdFormat ); + aIbInfo.SetAccessibleRelationLabeledBy( &aFtEdFormat ); + aIbRemove.SetAccessibleRelationLabeledBy( &aFtEdFormat ); + aIbAdd.SetAccessibleRelationMemberOf( &aIbAdd ); + aIbInfo.SetAccessibleRelationMemberOf( &aIbInfo ); + aIbRemove.SetAccessibleRelationMemberOf( &aIbRemove ); } /************************************************************************* @@ -369,7 +376,7 @@ void SvxNumberFormatTabPage::Init_Impl() #* #************************************************************************/ -USHORT* SvxNumberFormatTabPage::GetRanges() +sal_uInt16* SvxNumberFormatTabPage::GetRanges() { return pRanges; } @@ -411,8 +418,8 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) const SfxPoolItem* pItem = NULL; const SfxBoolItem* pAutoEntryAttr = NULL; - USHORT nCatLbSelPos = 0; - USHORT nFmtLbSelPos = 0; + sal_uInt16 nCatLbSelPos = 0; + sal_uInt16 nFmtLbSelPos = 0; LanguageType eLangType = LANGUAGE_DONTKNOW; SvxDelStrgs aFmtEntryList; SvxNumberValueType eValType = SVX_VALUE_TYPE_UNDEFINED; @@ -421,7 +428,7 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) SfxItemState eState = SFX_ITEM_DONTCARE; - eState = rSet.GetItemState( GetWhich( SID_ATTR_NUMBERFORMAT_NOLANGUAGE ),TRUE,&pItem); + eState = rSet.GetItemState( GetWhich( SID_ATTR_NUMBERFORMAT_NOLANGUAGE ),sal_True,&pItem); if(eState==SFX_ITEM_SET) { @@ -434,28 +441,28 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) } else { - HideLanguage(FALSE); + HideLanguage(sal_False); } } - eState = rSet.GetItemState( GetWhich( SID_ATTR_NUMBERFORMAT_INFO ),TRUE,&pItem); + eState = rSet.GetItemState( GetWhich( SID_ATTR_NUMBERFORMAT_INFO ),sal_True,&pItem); if(eState==SFX_ITEM_SET) { if(pNumItem==NULL) { - bNumItemFlag=TRUE; + bNumItemFlag=sal_True; pNumItem= (SvxNumberInfoItem *) pItem->Clone(); } else { - bNumItemFlag=FALSE; + bNumItemFlag=sal_False; } } else { - bNumItemFlag=FALSE; + bNumItemFlag=sal_False; } @@ -481,13 +488,13 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) if ( pBoolItem ) aCbSourceFormat.Check( pBoolItem->GetValue() ); else - aCbSourceFormat.Check( FALSE ); + aCbSourceFormat.Check( sal_False ); aCbSourceFormat.Enable(); aCbSourceFormat.Show(); } else { - BOOL bInit = FALSE; // set to TRUE for debug test + sal_Bool bInit = sal_False; // set to sal_True for debug test aCbSourceFormat.Check( bInit ); aCbSourceFormat.Enable( bInit ); aCbSourceFormat.Show( bInit ); @@ -551,7 +558,7 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) pNumFmtShell->GetInitSettings( nCatLbSelPos, eLangType, nFmtLbSelPos, aFmtEntryList, aPrevString, pDummy ); - aLbCurrency.SelectEntryPos((USHORT)pNumFmtShell->GetCurrencySymbol()); + aLbCurrency.SelectEntryPos((sal_uInt16)pNumFmtShell->GetCurrencySymbol()); nFixedCategory=nCatLbSelPos; if(bOneAreaFlag) @@ -580,7 +587,7 @@ void SvxNumberFormatTabPage::Reset( const SfxItemSet& rSet ) aLbLanguage.SelectLanguage( eLangType ); if(pAutoEntryAttr) AddAutomaticLanguage_Impl(eLangType, pAutoEntryAttr->GetValue()); - UpdateFormatListBox_Impl(FALSE,TRUE); + UpdateFormatListBox_Impl(sal_False,sal_True); //! This spoils everything because it rematches currency formats based on //! the selected aLbCurrency entry instead of the current format. @@ -624,9 +631,9 @@ void SvxNumberFormatTabPage::Obstructing() aFtLanguage .Disable(); aLbLanguage .Disable(); - aIbAdd.Enable(FALSE ); - aIbRemove.Enable(FALSE ); - aIbInfo.Enable(FALSE ); + aIbAdd.Enable(sal_False ); + aIbRemove.Enable(sal_False ); + aIbInfo.Enable(sal_False ); aBtnNegRed .Disable(); aBtnThousand .Disable(); @@ -637,8 +644,8 @@ void SvxNumberFormatTabPage::Obstructing() aFlOptions .Disable(); aEdDecimals .SetText( String() ); aEdLeadZeroes .SetText( String() ); - aBtnNegRed .Check( FALSE ); - aBtnThousand .Check( FALSE ); + aBtnNegRed .Check( sal_False ); + aBtnThousand .Check( sal_False ); aWndPreview .NotifyChange( String() ); aLbCategory .SelectEntryPos( 0 ); @@ -657,7 +664,7 @@ void SvxNumberFormatTabPage::Obstructing() #************************************************************************/ void SvxNumberFormatTabPage::EnableBySourceFormat_Impl() { - BOOL bEnable = !aCbSourceFormat.IsChecked(); + sal_Bool bEnable = !aCbSourceFormat.IsChecked(); if ( !bEnable ) aCbSourceFormat.GrabFocus(); aFtCategory .Enable( bEnable ); @@ -691,12 +698,12 @@ void SvxNumberFormatTabPage::EnableBySourceFormat_Impl() #* #* Klasse: SvxNumberFormatTabPage #* Funktion: Versteckt die Spracheinstellung: -#* Input: BOOL nFlag +#* Input: sal_Bool nFlag #* Output: --- #* #************************************************************************/ -void SvxNumberFormatTabPage::HideLanguage(BOOL nFlag) +void SvxNumberFormatTabPage::HideLanguage(sal_Bool nFlag) { Size aSize=aLbCategory.GetSizePixel(); @@ -728,14 +735,14 @@ void SvxNumberFormatTabPage::HideLanguage(BOOL nFlag) #* #************************************************************************/ -BOOL SvxNumberFormatTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) +sal_Bool SvxNumberFormatTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) { - BOOL bDataChanged = aFtLanguage.IsEnabled() || aCbSourceFormat.IsEnabled(); + sal_Bool bDataChanged = aFtLanguage.IsEnabled() || aCbSourceFormat.IsEnabled(); if ( bDataChanged ) { const SfxItemSet& rMyItemSet = GetItemSet(); - USHORT nWhich = GetWhich( SID_ATTR_NUMBERFORMAT_VALUE ); - SfxItemState eItemState = rMyItemSet.GetItemState( nWhich, FALSE ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_NUMBERFORMAT_VALUE ); + SfxItemState eItemState = rMyItemSet.GetItemState( nWhich, sal_False ); // OK chosen - Is format code input entered already taken over? // If not, simulate Add. Upon syntax error ignore input and prevent Put. @@ -784,7 +791,7 @@ BOOL SvxNumberFormatTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) pNumFmtShell->GetUpdateData( pDelArr, nDelCount ); pNumItem->SetDelFormatArray( pDelArr, nDelCount ); - if(bNumItemFlag==TRUE) + if(bNumItemFlag==sal_True) { rCoreAttrs.Put( *pNumItem ); } @@ -806,14 +813,14 @@ BOOL SvxNumberFormatTabPage::FillItemSet( SfxItemSet& rCoreAttrs ) // -------------------------------------------- if ( aCbSourceFormat.IsEnabled() ) { - USHORT _nWhich = GetWhich( SID_ATTR_NUMBERFORMAT_SOURCE ); - SfxItemState _eItemState = rMyItemSet.GetItemState( _nWhich, FALSE ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_NUMBERFORMAT_SOURCE ); + SfxItemState _eItemState = rMyItemSet.GetItemState( _nWhich, sal_False ); const SfxBoolItem* pBoolItem = (const SfxBoolItem*) GetItem( rMyItemSet, SID_ATTR_NUMBERFORMAT_SOURCE ); - BOOL bOld = (pBoolItem ? pBoolItem->GetValue() : FALSE); + sal_Bool bOld = (pBoolItem ? pBoolItem->GetValue() : sal_False); rCoreAttrs.Put( SfxBoolItem( _nWhich, aCbSourceFormat.IsChecked() ) ); if ( !bDataChanged ) - bDataChanged = (bOld != (BOOL) aCbSourceFormat.IsChecked() || + bDataChanged = (bOld != (sal_Bool) aCbSourceFormat.IsChecked() || _eItemState != SFX_ITEM_SET); } @@ -851,14 +858,14 @@ void SvxNumberFormatTabPage::FillFormatListBox_Impl( SvxDelStrgs& rEntries ) String aTmpString; String aTmpCatString; Font aFont=aLbCategory.GetFont(); - USHORT i = 0; + sal_uInt16 i = 0; short nTmpCatPos; short aPrivCat; aLbFormat.Clear(); - aLbFormat.SetUpdateMode( FALSE ); + aLbFormat.SetUpdateMode( sal_False ); - USHORT nCount = rEntries.Count(); + sal_uInt16 nCount = rEntries.Count(); if(nCount<1) return; @@ -910,7 +917,7 @@ void SvxNumberFormatTabPage::FillFormatListBox_Impl( SvxDelStrgs& rEntries ) } } } - aLbFormat.SetUpdateMode( TRUE ); + aLbFormat.SetUpdateMode( sal_True ); DeleteEntryList_Impl(rEntries); } @@ -928,7 +935,7 @@ void SvxNumberFormatTabPage::FillFormatListBox_Impl( SvxDelStrgs& rEntries ) void SvxNumberFormatTabPage::DeleteEntryList_Impl( SvxDelStrgs& rEntries ) { - USHORT nCount = rEntries.Count(); + sal_uInt16 nCount = rEntries.Count(); rEntries.DeleteAndDestroy(0,nCount); } @@ -945,17 +952,17 @@ void SvxNumberFormatTabPage::DeleteEntryList_Impl( SvxDelStrgs& rEntries ) #* #************************************************************************/ -void SvxNumberFormatTabPage::UpdateOptions_Impl( BOOL bCheckCatChange /*= FALSE*/ ) +void SvxNumberFormatTabPage::UpdateOptions_Impl( sal_Bool bCheckCatChange /*= sal_False*/ ) { SvxDelStrgs aEntryList; String theFormat = aEdFormat.GetText(); - USHORT nCurCategory = aLbCategory.GetSelectEntryPos(); - USHORT nCategory = nCurCategory; - USHORT nDecimals = 0; - USHORT nZeroes = 0; - BOOL bNegRed = FALSE; - BOOL bThousand = FALSE; - USHORT nCurrencyPos =aLbCurrency.GetSelectEntryPos(); + sal_uInt16 nCurCategory = aLbCategory.GetSelectEntryPos(); + sal_uInt16 nCategory = nCurCategory; + sal_uInt16 nDecimals = 0; + sal_uInt16 nZeroes = 0; + sal_Bool bNegRed = sal_False; + sal_Bool bThousand = sal_False; + sal_uInt16 nCurrencyPos =aLbCurrency.GetSelectEntryPos(); if(bOneAreaFlag) nCurCategory=nFixedCategory; @@ -965,15 +972,15 @@ void SvxNumberFormatTabPage::UpdateOptions_Impl( BOOL bCheckCatChange /*= FALSE* bThousand, bNegRed, nDecimals, nZeroes, nCategory ); - BOOL bDoIt=FALSE; + sal_Bool bDoIt=sal_False; if(nCategory==CAT_CURRENCY) { - USHORT nTstPos=pNumFmtShell->FindCurrencyFormat(theFormat); - if(nCurrencyPos!=nTstPos && nTstPos!=(USHORT)-1) + sal_uInt16 nTstPos=pNumFmtShell->FindCurrencyFormat(theFormat); + if(nCurrencyPos!=nTstPos && nTstPos!=(sal_uInt16)-1) { aLbCurrency.SelectEntryPos(nTstPos); pNumFmtShell->SetCurrencySymbol(nTstPos); - bDoIt=TRUE; + bDoIt=sal_True; } } @@ -988,7 +995,7 @@ void SvxNumberFormatTabPage::UpdateOptions_Impl( BOOL bCheckCatChange /*= FALSE* else SetCategory(nCategory ); - UpdateFormatListBox_Impl( TRUE, FALSE ); + UpdateFormatListBox_Impl( sal_True, sal_False ); } } else if ( aLbFormat.GetEntryCount() > 0 ) @@ -1040,8 +1047,8 @@ void SvxNumberFormatTabPage::UpdateOptions_Impl( BOOL bCheckCatChange /*= FALSE* aBtnThousand .Disable(); aEdDecimals .SetText( UniString::CreateFromInt32( 0 ) ); aEdLeadZeroes .SetText( UniString::CreateFromInt32( 0 ) ); - aBtnNegRed .Check( FALSE ); - aBtnThousand .Check( FALSE ); + aBtnNegRed .Check( sal_False ); + aBtnThousand .Check( sal_False ); } } @@ -1061,8 +1068,8 @@ void SvxNumberFormatTabPage::UpdateOptions_Impl( BOOL bCheckCatChange /*= FALSE* void SvxNumberFormatTabPage::UpdateFormatListBox_Impl ( - USHORT bCat, // Category oder Land/Sprache ListBox? - BOOL bUpdateEdit // Format-Edit aktualisieren? + sal_uInt16 bCat, // Category oder Land/Sprache ListBox? + sal_Bool bUpdateEdit // Format-Edit aktualisieren? ) { SvxDelStrgs aEntryList; @@ -1138,7 +1145,7 @@ void SvxNumberFormatTabPage::UpdateFormatListBox_Impl aFtComment.SetText(aLbCategory.GetEntry(1)); } } - ChangePreviewText( (USHORT)nFmtLbSelPos ); + ChangePreviewText( (sal_uInt16)nFmtLbSelPos ); } } @@ -1147,7 +1154,7 @@ void SvxNumberFormatTabPage::UpdateFormatListBox_Impl FillFormatListBox_Impl( aEntryList ); if(nFmtLbSelPos != SELPOS_NONE) { - aLbFormat.SelectEntryPos( (USHORT)nFmtLbSelPos ); + aLbFormat.SelectEntryPos( (sal_uInt16)nFmtLbSelPos ); aFtComment.SetText(pNumFmtShell->GetComment4Entry(nFmtLbSelPos)); if(pNumFmtShell->GetUserDefined4Entry(nFmtLbSelPos)) @@ -1234,9 +1241,9 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) if (aLbFormat.GetSelectEntryPos () == LISTBOX_ENTRY_NOTFOUND) #else /* !ENABLE_LAYOUT */ // Current category may be UserDefined with no format entries defined. - // And yes, aLbFormat is a SvxFontListBox with ULONG list positions, + // And yes, aLbFormat is a SvxFontListBox with sal_uLong list positions, // implementation returns a LIST_APPEND if empty, comparison with - // USHORT LISTBOX_ENTRY_NOTFOUND wouldn't match. + // sal_uInt16 LISTBOX_ENTRY_NOTFOUND wouldn't match. if ( aLbFormat.GetSelectEntryPos() == LIST_APPEND ) #endif /* !ENABLE_LAYOUT */ pLb = &aLbCategory; // continue with the current category selected @@ -1255,7 +1262,7 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) nTmpCatPos=aLbCategory.GetSelectEntryPos(); } - USHORT nCurrencyPos=LISTBOX_ENTRY_NOTFOUND ; + sal_uInt16 nCurrencyPos=LISTBOX_ENTRY_NOTFOUND ; if(nTmpCatPos==CAT_CURRENCY && (ListBox *)pLb == &aLbCurrency ) { @@ -1267,7 +1274,7 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) // Format-ListBox ---------------------------------------------------- if ( (SvxFontListBox *)pLb == &aLbFormat ) { - USHORT nSelPos = (USHORT) aLbFormat.GetSelectEntryPos(); + sal_uInt16 nSelPos = (sal_uInt16) aLbFormat.GetSelectEntryPos(); String aFormat = aLbFormat.GetSelectEntry(); String aComment; SvxDelStrgs aEntryList; @@ -1295,21 +1302,21 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) if ( pNumFmtShell->FindEntry( aFormat) ) { - aIbAdd.Enable(FALSE ); - BOOL bIsUserDef=pNumFmtShell->IsUserDefined( aFormat ); + aIbAdd.Enable(sal_False ); + sal_Bool bIsUserDef=pNumFmtShell->IsUserDefined( aFormat ); aIbRemove.Enable(bIsUserDef); aIbInfo.Enable(bIsUserDef); } else { - aIbAdd.Enable(TRUE ); - aIbInfo.Enable(TRUE ); - aIbRemove.Enable(FALSE ); + aIbAdd.Enable(sal_True ); + aIbInfo.Enable(sal_True ); + aIbRemove.Enable(sal_False ); aFtComment.SetText(aEdComment.GetText()); } - UpdateOptions_Impl( FALSE ); + UpdateOptions_Impl( sal_False ); return 0; } @@ -1318,9 +1325,9 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) // Kategorie-ListBox ------------------------------------------------- if ( pLb == &aLbCategory || pLb == &aLbCurrency) { - UpdateFormatListBox_Impl( TRUE, TRUE ); + UpdateFormatListBox_Impl( sal_True, sal_True ); EditHdl_Impl( NULL ); - UpdateOptions_Impl( FALSE ); + UpdateOptions_Impl( sal_False ); return 0; } @@ -1329,7 +1336,7 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) // Sprache/Land-ListBox ---------------------------------------------- if ( pLb == &aLbLanguage ) { - UpdateFormatListBox_Impl( FALSE, TRUE ); + UpdateFormatListBox_Impl( sal_False, sal_True ); EditHdl_Impl( &aEdFormat ); return 0; @@ -1353,12 +1360,12 @@ IMPL_LINK( SvxNumberFormatTabPage, SelFormatHdl_Impl, void *, pLb ) IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) { - BOOL bAdded = FALSE; - BOOL bDeleted = FALSE; - ULONG nReturn = 0; - const ULONG nReturnChanged = 0x1; // THE boolean return value - const ULONG nReturnAdded = 0x2; // temp: format added - const ULONG nReturnOneArea = 0x4; // temp: one area but category changed => ignored + sal_Bool bAdded = sal_False; + sal_Bool bDeleted = sal_False; + sal_uLong nReturn = 0; + const sal_uLong nReturnChanged = 0x1; // THE boolean return value + const sal_uLong nReturnAdded = 0x2; // temp: format added + const sal_uLong nReturnOneArea = 0x4; // temp: one area but category changed => ignored if(pIB==&aIbAdd) { // Also called from FillItemSet() if a temporary currency format has @@ -1366,7 +1373,7 @@ IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) String aFormat = aEdFormat.GetText(); SvxDelStrgs aEntryList; SvxDelStrgs a2EntryList; - USHORT nCatLbSelPos = 0; + sal_uInt16 nCatLbSelPos = 0; short nFmtLbSelPos = SELPOS_NONE; xub_StrLen nErrPos=0; @@ -1389,7 +1396,7 @@ IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) { if(nCatLbSelPos==CAT_CURRENCY) { - aLbCurrency.SelectEntryPos((USHORT)pNumFmtShell->GetCurrencySymbol()); + aLbCurrency.SelectEntryPos((sal_uInt16)pNumFmtShell->GetCurrencySymbol()); } if(bOneAreaFlag && (nFixedCategory!=nCatLbSelPos)) @@ -1425,12 +1432,12 @@ IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) pNumFmtShell->SetComment4Entry(nFmtLbSelPos, String()); } - aLbFormat.SelectEntryPos( (USHORT)nFmtLbSelPos ); + aLbFormat.SelectEntryPos( (sal_uInt16)nFmtLbSelPos ); aEdFormat.SetText( aFormat ); aEdComment.SetText(aLbCategory.GetEntry(1)); //String fuer Benutzerdefiniert //holen - ChangePreviewText( (USHORT)nFmtLbSelPos ); + ChangePreviewText( (sal_uInt16)nFmtLbSelPos ); } } } @@ -1446,7 +1453,7 @@ IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) { String aFormat = aEdFormat.GetText(); SvxDelStrgs aEntryList; - USHORT nCatLbSelPos = 0; + sal_uInt16 nCatLbSelPos = 0; short nFmtLbSelPos = SELPOS_NONE; bDeleted = pNumFmtShell->RemoveFormat( aFormat, @@ -1471,9 +1478,9 @@ IMPL_LINK( SvxNumberFormatTabPage, ClickHdl_Impl, ImageButton*, pIB) else SetCategory(nCatLbSelPos ); - aLbFormat.SelectEntryPos( (USHORT)nFmtLbSelPos ); + aLbFormat.SelectEntryPos( (sal_uInt16)nFmtLbSelPos ); aEdFormat.SetText( aFormat ); - ChangePreviewText( (USHORT)nFmtLbSelPos ); + ChangePreviewText( (sal_uInt16)nFmtLbSelPos ); } else { @@ -1523,9 +1530,9 @@ IMPL_LINK( SvxNumberFormatTabPage, EditHdl_Impl, Edit*, pEdFormat ) if ( aEdFormat.GetText().Len() == 0 ) { - aIbAdd.Enable(FALSE ); - aIbRemove.Enable(FALSE ); - aIbInfo.Enable(FALSE ); + aIbAdd.Enable(sal_False ); + aIbRemove.Enable(sal_False ); + aIbInfo.Enable(sal_False ); aFtComment.SetText(String()); } else @@ -1535,30 +1542,30 @@ IMPL_LINK( SvxNumberFormatTabPage, EditHdl_Impl, Edit*, pEdFormat ) if ( pNumFmtShell->FindEntry( aFormat, &nCurKey ) ) { - aIbAdd.Enable(FALSE ); - BOOL bUserDef=pNumFmtShell->IsUserDefined( aFormat ); + aIbAdd.Enable(sal_False ); + sal_Bool bUserDef=pNumFmtShell->IsUserDefined( aFormat ); aIbRemove.Enable(bUserDef); aIbInfo.Enable(bUserDef); if(bUserDef) { - USHORT nTmpCurPos=pNumFmtShell->FindCurrencyFormat(aFormat ); + sal_uInt16 nTmpCurPos=pNumFmtShell->FindCurrencyFormat(aFormat ); - if(nTmpCurPos!=(USHORT)-1) + if(nTmpCurPos!=(sal_uInt16)-1) aLbCurrency.SelectEntryPos(nTmpCurPos); } short nPosi=pNumFmtShell->GetListPos4Entry(aFormat); if(nPosi>=0) - aLbFormat.SelectEntryPos( (USHORT)nPosi); + aLbFormat.SelectEntryPos( (sal_uInt16)nPosi); } else { - aIbAdd.Enable(TRUE ); - aIbInfo.Enable(TRUE); - aIbRemove.Enable(FALSE ); + aIbAdd.Enable(sal_True ); + aIbInfo.Enable(sal_True); + aIbRemove.Enable(sal_False ); aFtComment.SetText(aEdComment.GetText()); @@ -1568,7 +1575,7 @@ IMPL_LINK( SvxNumberFormatTabPage, EditHdl_Impl, Edit*, pEdFormat ) if ( pEdFormat ) { pNumFmtShell->SetCurNumFmtKey( nCurKey ); - UpdateOptions_Impl( TRUE ); + UpdateOptions_Impl( sal_True ); } return 0; @@ -1594,29 +1601,29 @@ IMPL_LINK( SvxNumberFormatTabPage, OptHdl_Impl, void *, pOptCtrl ) || ((CheckBox*) pOptCtrl == &aBtnThousand) ) { String aFormat; - BOOL bThousand = aBtnThousand.IsEnabled() + sal_Bool bThousand = aBtnThousand.IsEnabled() && aBtnThousand.IsChecked(); - BOOL bNegRed = aBtnNegRed.IsEnabled() + sal_Bool bNegRed = aBtnNegRed.IsEnabled() && aBtnNegRed.IsChecked(); - USHORT nPrecision = (aEdDecimals.IsEnabled()) - ? (USHORT)aEdDecimals.GetValue() - : (USHORT)0; - USHORT nLeadZeroes = (aEdLeadZeroes.IsEnabled()) - ? (USHORT)aEdLeadZeroes.GetValue() - : (USHORT)0; + sal_uInt16 nPrecision = (aEdDecimals.IsEnabled()) + ? (sal_uInt16)aEdDecimals.GetValue() + : (sal_uInt16)0; + sal_uInt16 nLeadZeroes = (aEdLeadZeroes.IsEnabled()) + ? (sal_uInt16)aEdLeadZeroes.GetValue() + : (sal_uInt16)0; pNumFmtShell->MakeFormat( aFormat, bThousand, bNegRed, nPrecision, nLeadZeroes, - (USHORT)aLbFormat.GetSelectEntryPos() ); + (sal_uInt16)aLbFormat.GetSelectEntryPos() ); aEdFormat.SetText( aFormat ); MakePreviewText( aFormat ); if ( pNumFmtShell->FindEntry( aFormat ) ) { - aIbAdd.Enable(FALSE ); - BOOL bUserDef=pNumFmtShell->IsUserDefined( aFormat ); + aIbAdd.Enable(sal_False ); + sal_Bool bUserDef=pNumFmtShell->IsUserDefined( aFormat ); aIbRemove.Enable(bUserDef); aIbInfo.Enable(bUserDef); EditHdl_Impl( &aEdFormat); @@ -1659,7 +1666,7 @@ IMPL_LINK( SvxNumberFormatTabPage, LostFocusHdl_Impl, Edit *, pEd) aFtComment.Show(); if(!aIbAdd.IsEnabled()) { - USHORT nSelPos = (USHORT) aLbFormat.GetSelectEntryPos(); + sal_uInt16 nSelPos = (sal_uInt16) aLbFormat.GetSelectEntryPos(); pNumFmtShell->SetComment4Entry(nSelPos, aEdComment.GetText()); aEdComment.SetText(aLbCategory.GetEntry(1)); //String fuer Benutzerdefiniert @@ -1719,7 +1726,7 @@ void SvxNumberFormatTabPage::MakePreviewText( const String& rFormat ) aWndPreview.NotifyChange( aPreviewString, pPreviewColor ); } -void SvxNumberFormatTabPage::ChangePreviewText( USHORT nPos ) +void SvxNumberFormatTabPage::ChangePreviewText( sal_uInt16 nPos ) { String aPreviewString; Color* pPreviewColor = NULL; @@ -1764,11 +1771,11 @@ void SvxNumberFormatTabPage::FillCurrencyBox() SvStringsDtor aList; NfShCurrencyEntries rEntries; XubString* pEntry = NULL; - USHORT nSelPos=0; + sal_uInt16 nSelPos=0; pNumFmtShell->GetCurrencySymbols( aList, &nSelPos); - for(USHORT i=1;i<aList.Count();i++) + for(sal_uInt16 i=1;i<aList.Count();i++) { pEntry=aList[i]; aLbCurrency.InsertEntry( *pEntry); @@ -1776,12 +1783,12 @@ void SvxNumberFormatTabPage::FillCurrencyBox() aLbCurrency.SelectEntryPos(nSelPos); } -void SvxNumberFormatTabPage::SetCategory(USHORT nPos) +void SvxNumberFormatTabPage::SetCategory(sal_uInt16 nPos) { - USHORT nCurCategory = aLbCategory.GetSelectEntryPos(); + sal_uInt16 nCurCategory = aLbCategory.GetSelectEntryPos(); Point aPos=aLbFormat.GetPosPixel(); Size aSize=aLbFormat.GetSizePixel(); - USHORT nTmpCatPos; + sal_uInt16 nTmpCatPos; if(bOneAreaFlag) { @@ -1816,11 +1823,11 @@ void SvxNumberFormatTabPage::SetCategory(USHORT nPos) which marks a certain language as automatically detected Additionally the "Default" language is removed */ -void SvxNumberFormatTabPage::AddAutomaticLanguage_Impl(LanguageType eAutoLang, BOOL bSelect) +void SvxNumberFormatTabPage::AddAutomaticLanguage_Impl(LanguageType eAutoLang, sal_Bool bSelect) { aLbLanguage.RemoveLanguage(LANGUAGE_SYSTEM); - USHORT nPos = aLbLanguage.InsertEntry(sAutomaticEntry); - aLbLanguage.SetEntryData(nPos, (void*)(ULONG)eAutoLang); + sal_uInt16 nPos = aLbLanguage.InsertEntry(sAutomaticEntry); + aLbLanguage.SetEntryData(nPos, (void*)(sal_uLong)eAutoLang); if(bSelect) aLbLanguage.SelectEntryPos(nPos); } diff --git a/cui/source/tabpages/numfmt.src b/cui/source/tabpages/numfmt.src index 7eea452f88f5..867f93c7e753 100644 --- a/cui/source/tabpages/numfmt.src +++ b/cui/source/tabpages/numfmt.src @@ -45,6 +45,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; ListBox LB_CATEGORY { + HelpID = "cui:ListBox:RID_SVXPAGE_NUMBERFORMAT:LB_CATEGORY"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 14 ) ; Size = MAP_APPFONT ( 70 , 71 ) ; @@ -72,6 +73,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; Edit ED_FORMAT { + HelpID = "cui:Edit:RID_SVXPAGE_NUMBERFORMAT:ED_FORMAT"; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 147 ) ; Size = MAP_APPFONT ( 200 , 12 ) ; @@ -85,6 +87,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; Edit ED_COMMENT { + HelpID = "cui:Edit:RID_SVXPAGE_NUMBERFORMAT:ED_COMMENT"; Hide = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 6 , 163 ) ; @@ -99,6 +102,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT ListBox LB_CURRENCY { + HelpID = "cui:ListBox:RID_SVXPAGE_NUMBERFORMAT:LB_CURRENCY"; Border = TRUE ; Pos = MAP_APPFONT ( 82 , 14 ) ; Size = MAP_APPFONT ( 90 , 71 ) ; @@ -127,6 +131,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; NumericField ED_DECIMALS { + HelpID = "cui:NumericField:RID_SVXPAGE_NUMBERFORMAT:ED_DECIMALS"; Border = TRUE ; Pos = MAP_APPFONT ( 84 , 102 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; @@ -146,6 +151,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; NumericField ED_LEADZEROES { + HelpID = "cui:NumericField:RID_SVXPAGE_NUMBERFORMAT:ED_LEADZEROES"; Border = TRUE ; Pos = MAP_APPFONT ( 84 , 118 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; @@ -159,12 +165,14 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; CheckBox BTN_NEGRED { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUMBERFORMAT:BTN_NEGRED"; Pos = MAP_APPFONT ( 133 , 104 ) ; Size = MAP_APPFONT ( 100 , 10 ) ; Text [ en-US ] = "~Negative numbers red" ; }; CheckBox BTN_THOUSAND { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUMBERFORMAT:BTN_THOUSAND"; Pos = MAP_APPFONT ( 133 , 120 ) ; Size = MAP_APPFONT ( 100 , 10 ) ; Text [ en-US ] = "~Thousands separator" ; @@ -183,6 +191,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; ListBox LB_LANGUAGE { + HelpID = "cui:ListBox:RID_SVXPAGE_NUMBERFORMAT:LB_LANGUAGE"; Border = TRUE ; Sort = TRUE ; Pos = MAP_APPFONT ( 178 , 14 ) ; @@ -191,6 +200,7 @@ TabPage RID_SVXPAGE_NUMBERFORMAT }; CheckBox CB_SOURCEFORMAT { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUMBERFORMAT:CB_SOURCEFORMAT"; Pos = MAP_APPFONT ( 178 , 42 ) ; Size = MAP_APPFONT ( 76 , 10 ) ; Text [ en-US ] = "So~urce format" ; diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx index 66288342415b..1f912e608ba9 100644 --- a/cui/source/tabpages/numpages.cxx +++ b/cui/source/tabpages/numpages.cxx @@ -103,7 +103,7 @@ SV_IMPL_PTRARR(SvxNumSettingsArr_Impl,SvxNumSettings_ImplPtr); #define MAX_BMP_WIDTH 16 #define MAX_BMP_HEIGHT 16 -static BOOL bLastRelative = FALSE; +static sal_Bool bLastRelative = sal_False; static const sal_Char cNumberingType[] = "NumberingType"; static const sal_Char cValue[] = "Value"; static const sal_Char cParentNumbering[] = "ParentNumbering"; @@ -169,11 +169,11 @@ static sal_Char const aNumChar[] = }; // Ist eins der maskierten Formate gesetzt? -BOOL lcl_IsNumFmtSet(SvxNumRule* pNum, USHORT nLevelMask) +sal_Bool lcl_IsNumFmtSet(SvxNumRule* pNum, sal_uInt16 nLevelMask) { - BOOL bRet = FALSE; - USHORT nMask = 1; - for( USHORT i = 0; i < SVX_MAX_NUM && !bRet; i++ ) + sal_Bool bRet = sal_False; + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < SVX_MAX_NUM && !bRet; i++ ) { if(nLevelMask & nMask) bRet |= 0 != pNum->Get( i ); @@ -184,7 +184,7 @@ BOOL lcl_IsNumFmtSet(SvxNumRule* pNum, USHORT nLevelMask) Font& lcl_GetDefaultBulletFont() { - static BOOL bInit = 0; + static sal_Bool bInit = 0; static Font aDefBulletFont( UniString::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "StarSymbol" ) ), String(), Size( 0, 14 ) ); @@ -194,8 +194,8 @@ Font& lcl_GetDefaultBulletFont() aDefBulletFont.SetFamily( FAMILY_DONTKNOW ); aDefBulletFont.SetPitch( PITCH_DONTKNOW ); aDefBulletFont.SetWeight( WEIGHT_DONTKNOW ); - aDefBulletFont.SetTransparent( TRUE ); - bInit = TRUE; + aDefBulletFont.SetTransparent( sal_True ); + bInit = sal_True; } return aDefBulletFont; } @@ -215,8 +215,8 @@ SvxSingleNumPickTabPage::SvxSingleNumPickTabPage(Window* pParent, pActNum(0), pSaveNum(0), nActNumLvl( USHRT_MAX ), - bModified(FALSE), - bPreset(FALSE), + bModified(sal_False), + bPreset(sal_False), nNumItemId(SID_ATTR_NUMBERING_RULE) { FreeResource(); @@ -268,7 +268,7 @@ SfxTabPage* SvxSingleNumPickTabPage::Create( Window* pParent, return new SvxSingleNumPickTabPage(pParent, rAttrSet); } -BOOL SvxSingleNumPickTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxSingleNumPickTabPage::FillItemSet( SfxItemSet& rSet ) { if( (bPreset || bModified) && pSaveNum) { @@ -283,17 +283,17 @@ BOOL SvxSingleNumPickTabPage::FillItemSet( SfxItemSet& rSet ) void SvxSingleNumPickTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; - bPreset = FALSE; - BOOL bIsPreset = FALSE; + bPreset = sal_False; + sal_Bool bIsPreset = sal_False; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bIsPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nActNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -308,18 +308,18 @@ void SvxSingleNumPickTabPage::ActivatePage(const SfxItemSet& rSet) { pExamplesVS->SelectItem(1); NumSelectHdl_Impl(pExamplesVS); - bPreset = TRUE; + bPreset = sal_True; } bPreset |= bIsPreset; - bModified = FALSE; + bModified = sal_False; } int SvxSingleNumPickTabPage::DeactivatePage(SfxItemSet *_pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } void SvxSingleNumPickTabPage::Reset( const SfxItemSet& rSet ) @@ -327,15 +327,15 @@ void SvxSingleNumPickTabPage::Reset( const SfxItemSet& rSet ) const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } } @@ -353,9 +353,9 @@ IMPL_LINK(SvxSingleNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) { if(pActNum) { - bPreset = FALSE; - bModified = TRUE; - USHORT nIdx = pExamplesVS->GetSelectItemId() - 1; + bPreset = sal_False; + bModified = sal_True; + sal_uInt16 nIdx = pExamplesVS->GetSelectItemId() - 1; DBG_ASSERT(aNumSettingsArr.Count() > nIdx, "wrong index"); if(aNumSettingsArr.Count() <= nIdx) return 0; @@ -364,8 +364,8 @@ IMPL_LINK(SvxSingleNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) const sal_Unicode cLocalPrefix = _pSet->sPrefix.getLength() ? _pSet->sPrefix.getStr()[0] : 0; const sal_Unicode cLocalSuffix = _pSet->sSuffix.getLength() ? _pSet->sSuffix.getStr()[0] : 0; - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -408,8 +408,8 @@ SvxBulletPickTabPage::SvxBulletPickTabPage(Window* pParent, pActNum(0), pSaveNum(0), nActNumLvl( USHRT_MAX ), - bModified(FALSE), - bPreset(FALSE), + bModified(sal_False), + bPreset(sal_False), nNumItemId(SID_ATTR_NUMBERING_RULE) { FreeResource(); @@ -433,7 +433,7 @@ SfxTabPage* SvxBulletPickTabPage::Create( Window* pParent, return new SvxBulletPickTabPage(pParent, rAttrSet); } -BOOL SvxBulletPickTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxBulletPickTabPage::FillItemSet( SfxItemSet& rSet ) { if( (bPreset || bModified) && pActNum) { @@ -447,17 +447,17 @@ BOOL SvxBulletPickTabPage::FillItemSet( SfxItemSet& rSet ) void SvxBulletPickTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; - bPreset = FALSE; - BOOL bIsPreset = FALSE; + bPreset = sal_False; + sal_Bool bIsPreset = sal_False; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bIsPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nActNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -472,32 +472,32 @@ void SvxBulletPickTabPage::ActivatePage(const SfxItemSet& rSet) { pExamplesVS->SelectItem(1); NumSelectHdl_Impl(pExamplesVS); - bPreset = TRUE; + bPreset = sal_True; } bPreset |= bIsPreset; - bModified = FALSE; + bModified = sal_False; } int SvxBulletPickTabPage::DeactivatePage(SfxItemSet *_pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } void SvxBulletPickTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } @@ -516,13 +516,13 @@ IMPL_LINK(SvxBulletPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) { if(pActNum) { - bPreset = FALSE; - bModified = TRUE; + bPreset = sal_False; + bModified = sal_True; sal_Unicode cChar = aBulletTypes[pExamplesVS->GetSelectItemId() - 1]; Font& rActBulletFont = lcl_GetDefaultBulletFont(); - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -573,8 +573,8 @@ SvxNumPickTabPage::SvxNumPickTabPage(Window* pParent, pSaveNum(0), nActNumLvl( USHRT_MAX ), nNumItemId(SID_ATTR_NUMBERING_RULE), - bModified(FALSE), - bPreset(FALSE) + bModified(sal_False), + bPreset(sal_False) { FreeResource(); @@ -633,7 +633,7 @@ SfxTabPage* SvxNumPickTabPage::Create( Window* pParent, return new SvxNumPickTabPage(pParent, rAttrSet); } -BOOL SvxNumPickTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxNumPickTabPage::FillItemSet( SfxItemSet& rSet ) { if( (bPreset || bModified) && pActNum) { @@ -647,17 +647,17 @@ BOOL SvxNumPickTabPage::FillItemSet( SfxItemSet& rSet ) void SvxNumPickTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; - bPreset = FALSE; - BOOL bIsPreset = FALSE; + bPreset = sal_False; + sal_Bool bIsPreset = sal_False; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bIsPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nActNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -672,32 +672,32 @@ void SvxNumPickTabPage::ActivatePage(const SfxItemSet& rSet) { pExamplesVS->SelectItem(1); NumSelectHdl_Impl(pExamplesVS); - bPreset = TRUE; + bPreset = sal_True; } bPreset |= bIsPreset; - bModified = FALSE; + bModified = sal_False; } int SvxNumPickTabPage::DeactivatePage(SfxItemSet *_pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } void SvxNumPickTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } @@ -718,8 +718,8 @@ IMPL_LINK(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) { if(pActNum) { - bPreset = FALSE; - bModified = TRUE; + bPreset = sal_False; + bModified = sal_True; const FontList* pList = 0; @@ -727,7 +727,7 @@ IMPL_LINK(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) Font& rActBulletFont = lcl_GetDefaultBulletFont(); SvxNumSettings_ImplPtr pLevelSettings = 0; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(rItemArr.Count() > i) pLevelSettings = rItemArr[i]; @@ -735,7 +735,7 @@ IMPL_LINK(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) break; SvxNumberFormat aFmt(pActNum->GetLevel(i)); aFmt.SetNumberingType( pLevelSettings->nNumberType ); - USHORT nUpperLevelOrChar = (USHORT)pLevelSettings->nParentNumbering; + sal_uInt16 nUpperLevelOrChar = (sal_uInt16)pLevelSettings->nParentNumbering; if(aFmt.GetNumberingType() == SVX_NUM_CHAR_SPECIAL) { if( pLevelSettings->sBulletFont.getLength() && @@ -767,7 +767,7 @@ IMPL_LINK(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) aCreateFont.SetFamily( FAMILY_DONTKNOW ); aCreateFont.SetPitch( PITCH_DONTKNOW ); aCreateFont.SetWeight( WEIGHT_DONTKNOW ); - aCreateFont.SetTransparent( TRUE ); + aCreateFont.SetTransparent( sal_True ); aFmt.SetBulletFont( &aCreateFont ); } } @@ -783,7 +783,7 @@ IMPL_LINK(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) } else { - aFmt.SetIncludeUpperLevels(sal::static_int_cast< BYTE >(0 != nUpperLevelOrChar ? pActNum->GetLevelCount() : 0)); + aFmt.SetIncludeUpperLevels(sal::static_int_cast< sal_uInt8 >(0 != nUpperLevelOrChar ? pActNum->GetLevelCount() : 0)); aFmt.SetCharFmtName(sNumCharFmtName); // #62069# // #92724# aFmt.SetBulletRelSize(100); @@ -814,26 +814,6 @@ void SvxNumPickTabPage::PageCreated(SfxAllItemSet aSet) SetCharFmtNames( pNumCharFmt->GetValue(),pBulletCharFmt->GetValue()); } -void lcl_PaintLevel(OutputDevice* pVDev, sal_Int16 nNumberingType, - const OUString& rBulletChar, const OUString& rText, const OUString& rFontName, - Point& rLeft, Font& rRuleFont, const Font& rTextFont) -{ - - if(NumberingType::CHAR_SPECIAL == nNumberingType ) - { - rRuleFont.SetStyleName(rFontName); - pVDev->SetFont(rRuleFont); - pVDev->DrawText(rLeft, rBulletChar); - rLeft.X() += pVDev->GetTextWidth(rBulletChar); - } - else - { - pVDev->SetFont(rTextFont); - pVDev->DrawText(rLeft, rText); - rLeft.X() += pVDev->GetTextWidth(rText); - } -} - SvxBitmapPickTabPage::SvxBitmapPickTabPage(Window* pParent, const SfxItemSet& rSet) : @@ -846,8 +826,8 @@ SvxBitmapPickTabPage::SvxBitmapPickTabPage(Window* pParent, pSaveNum(0), nActNumLvl( USHRT_MAX ), nNumItemId(SID_ATTR_NUMBERING_RULE), - bModified(FALSE), - bPreset(FALSE) + bModified(sal_False), + bPreset(sal_False) { FreeResource(); SetExchangeSupport(); @@ -859,7 +839,7 @@ SvxBitmapPickTabPage::SvxBitmapPickTabPage(Window* pParent, // Grafiknamen ermitteln GalleryExplorer::FillObjList(GALLERY_THEME_BULLETS, aGrfNames); pExamplesVS->SetHelpId(HID_VALUESET_NUMBMP ); - for(USHORT i = 0; i < aGrfNames.Count(); i++) + for(sal_uInt16 i = 0; i < aGrfNames.Count(); i++) { pExamplesVS->InsertItem( i + 1, i); String* pGrfNm = (String*) aGrfNames.GetObject(i); @@ -878,6 +858,7 @@ SvxBitmapPickTabPage::SvxBitmapPickTabPage(Window* pParent, pExamplesVS->Format(); } + pExamplesVS->SetAccessibleRelationMemberOf( &aValuesFL ); } SvxBitmapPickTabPage::~SvxBitmapPickTabPage() @@ -902,17 +883,17 @@ SfxTabPage* SvxBitmapPickTabPage::Create( Window* pParent, void SvxBitmapPickTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; - bPreset = FALSE; - BOOL bIsPreset = FALSE; + bPreset = sal_False; + sal_Bool bIsPreset = sal_False; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bIsPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nActNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -928,24 +909,24 @@ void SvxBitmapPickTabPage::ActivatePage(const SfxItemSet& rSet) { pExamplesVS->SelectItem(1); NumSelectHdl_Impl(pExamplesVS); - bPreset = TRUE; + bPreset = sal_True; } bPreset |= bIsPreset; - bModified = FALSE; + bModified = sal_False; } int SvxBitmapPickTabPage::DeactivatePage(SfxItemSet *_pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } -BOOL SvxBitmapPickTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxBitmapPickTabPage::FillItemSet( SfxItemSet& rSet ) { if ( !aGrfNames.Count() ) { - return FALSE; + return sal_False; } if( (bPreset || bModified) && pActNum) { @@ -961,15 +942,15 @@ void SvxBitmapPickTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } @@ -984,13 +965,13 @@ void SvxBitmapPickTabPage::Reset( const SfxItemSet& rSet ) *pActNum = *pSaveNum; if(!pActNum->IsFeatureSupported(NUM_ENABLE_LINKED_BMP)) { - aLinkedCB.Check(FALSE); - aLinkedCB.Enable(FALSE); + aLinkedCB.Check(sal_False); + aLinkedCB.Enable(sal_False); } else if(!pActNum->IsFeatureSupported(NUM_ENABLE_EMBEDDED_BMP)) { - aLinkedCB.Check(TRUE); - aLinkedCB.Enable(FALSE); + aLinkedCB.Check(sal_True); + aLinkedCB.Enable(sal_False); } } @@ -998,20 +979,20 @@ IMPL_LINK(SvxBitmapPickTabPage, NumSelectHdl_Impl, ValueSet*, EMPTYARG) { if(pActNum) { - bPreset = FALSE; - bModified = TRUE; - USHORT nIdx = pExamplesVS->GetSelectItemId() - 1; + bPreset = sal_False; + bModified = sal_True; + sal_uInt16 nIdx = pExamplesVS->GetSelectItemId() - 1; String* pGrfName = 0; if(aGrfNames.Count() > nIdx) pGrfName = (String*)aGrfNames.GetObject(nIdx); - USHORT nMask = 1; + sal_uInt16 nMask = 1; String aEmptyStr; - USHORT nSetNumberingType = SVX_NUM_BITMAP; + sal_uInt16 nSetNumberingType = SVX_NUM_BITMAP; if(aLinkedCB.IsChecked()) nSetNumberingType |= LINK_TOKEN; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -1100,12 +1081,12 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, pPreviewWIN( new SvxNumberingPreview(this, CUI_RES(WIN_PREVIEW ))), pActNum(0), pSaveNum(0), - bLastWidthModified(FALSE), - bModified(FALSE), - bPreset(FALSE), - bAutomaticCharStyles(TRUE), - bHTMLMode(FALSE), - bMenuButtonInitialized(FALSE), + bLastWidthModified(sal_False), + bModified(sal_False), + bPreset(sal_False), + bAutomaticCharStyles(sal_True), + bHTMLMode(sal_False), + bMenuButtonInitialized(sal_False), sBullet(CUI_RES(STR_BULLET)), nBullet(0xff), nActNumLvl(USHRT_MAX), @@ -1140,10 +1121,12 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, aBitmapMB.GetPopupMenu()->SetPopupMenu( MN_GALLERY, pPopup ); pPopup->InsertItem( NUM_NO_GRAPHIC, String(CUI_RES(ST_POPUP_EMPTY_ENTRY)) ); - pPopup->EnableItem( NUM_NO_GRAPHIC, FALSE ); + pPopup->EnableItem( NUM_NO_GRAPHIC, sal_False ); eCoreUnit = rSet.GetPool()->GetMetric(rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE)); + aBitmapMB.SetAccessibleRelationLabeledBy( &aBitmapFT ); + FreeResource(); //get advanced numbering types from the component @@ -1153,12 +1136,12 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, // Extended numbering schemes present in the resource but not offered by // the i18n framework per configuration must be removed from the listbox. // Watch out for the ugly 0x88/*SVX_NUM_BITMAP|0x80*/ to not remove that. - const USHORT nDontRemove = 0xffff; - ::std::vector< USHORT> aRemove( aFmtLB.GetEntryCount(), nDontRemove); + const sal_uInt16 nDontRemove = 0xffff; + ::std::vector< sal_uInt16> aRemove( aFmtLB.GetEntryCount(), nDontRemove); for (size_t i=0; i<aRemove.size(); ++i) { - USHORT nEntryData = (USHORT)(ULONG)aFmtLB.GetEntryData( - sal::static_int_cast< USHORT >(i)); + sal_uInt16 nEntryData = (sal_uInt16)(sal_uLong)aFmtLB.GetEntryData( + sal::static_int_cast< sal_uInt16 >(i)); if (nEntryData > NumberingType::CHARS_LOWER_LETTER_N && nEntryData != (SVX_NUM_BITMAP | 0x80)) aRemove[i] = nEntryData; @@ -1173,10 +1156,10 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, if(nCurrent > NumberingType::CHARS_LOWER_LETTER_N) { sal_Bool bInsert = sal_True; - for(USHORT nEntry = 0; nEntry < aFmtLB.GetEntryCount(); nEntry++) + for(sal_uInt16 nEntry = 0; nEntry < aFmtLB.GetEntryCount(); nEntry++) { - USHORT nEntryData = (USHORT)(ULONG)aFmtLB.GetEntryData(nEntry); - if(nEntryData == (USHORT) nCurrent) + sal_uInt16 nEntryData = (sal_uInt16)(sal_uLong)aFmtLB.GetEntryData(nEntry); + if(nEntryData == (sal_uInt16) nCurrent) { bInsert = sal_False; aRemove[nEntry] = nDontRemove; @@ -1186,8 +1169,8 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, if(bInsert) { OUString aIdent = xInfo->getNumberingIdentifier( nCurrent ); - USHORT nPos = aFmtLB.InsertEntry(aIdent); - aFmtLB.SetEntryData(nPos,(void*)(ULONG)nCurrent); + sal_uInt16 nPos = aFmtLB.InsertEntry(aIdent); + aFmtLB.SetEntryData(nPos,(void*)(sal_uLong)nCurrent); } } } @@ -1196,10 +1179,14 @@ SvxNumOptionsTabPage::SvxNumOptionsTabPage(Window* pParent, { if (aRemove[i] != nDontRemove) { - USHORT nPos = aFmtLB.GetEntryPos( (void*)(ULONG)aRemove[i]); + sal_uInt16 nPos = aFmtLB.GetEntryPos( (void*)(sal_uLong)aRemove[i]); aFmtLB.RemoveEntry( nPos); } } + + aBulletPB.SetAccessibleRelationMemberOf(&aFormatFL); + aBulletPB.SetAccessibleRelationLabeledBy(&aStartFT); + aBulletPB.SetAccessibleName(aStartFT.GetText()); } SvxNumOptionsTabPage::~SvxNumOptionsTabPage() @@ -1237,15 +1224,15 @@ void SvxNumOptionsTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); - UINT16 nTmpNumLvl = USHRT_MAX; + sal_uInt16 nTmpNumLvl = USHRT_MAX; if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nTmpNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -1256,18 +1243,18 @@ void SvxNumOptionsTabPage::ActivatePage(const SfxItemSet& rSet) nActNumLvl != nTmpNumLvl) { nActNumLvl = nTmpNumLvl; - USHORT nMask = 1; - aLevelLB.SetUpdateMode(FALSE); + sal_uInt16 nMask = 1; + aLevelLB.SetUpdateMode(sal_False); aLevelLB.SetNoSelection(); aLevelLB.SelectEntryPos( pActNum->GetLevelCount(), nActNumLvl == USHRT_MAX); if(nActNumLvl != USHRT_MAX) - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) - aLevelLB.SelectEntryPos( i, TRUE); + aLevelLB.SelectEntryPos( i, sal_True); nMask <<= 1 ; } - aLevelLB.SetUpdateMode(TRUE); + aLevelLB.SetUpdateMode(sal_True); *pActNum = *pSaveNum; InitControls(); } @@ -1278,17 +1265,17 @@ int SvxNumOptionsTabPage::DeactivatePage(SfxItemSet * _pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } -BOOL SvxNumOptionsTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxNumOptionsTabPage::FillItemSet( SfxItemSet& rSet ) { rSet.Put(SfxUInt16Item(SID_PARAM_CUR_NUM_LEVEL, nActNumLvl)); if(bModified && pActNum) { *pSaveNum = *pActNum; rSet.Put(SvxNumBulletItem( *pSaveNum ), nNumItemId); - rSet.Put(SfxBoolItem(SID_PARAM_NUM_PRESET, FALSE)); + rSet.Put(SfxBoolItem(SID_PARAM_NUM_PRESET, sal_False)); } return bModified; }; @@ -1297,15 +1284,15 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } @@ -1317,7 +1304,7 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) // Ebenen einfuegen if(!aLevelLB.GetEntryCount()) { - for(USHORT i = 1; i <= pSaveNum->GetLevelCount(); i++) + for(sal_uInt16 i = 1; i <= pSaveNum->GetLevelCount(); i++) aLevelLB.InsertEntry( UniString::CreateFromInt32(i)); if(pSaveNum->GetLevelCount() > 1) { @@ -1332,21 +1319,21 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) else aLevelLB.SelectEntryPos(aLevelLB.GetEntryCount() - 1); - USHORT nMask = 1; - aLevelLB.SetUpdateMode(FALSE); + sal_uInt16 nMask = 1; + aLevelLB.SetUpdateMode(sal_False); aLevelLB.SetNoSelection(); if(nActNumLvl == USHRT_MAX) { - aLevelLB.SelectEntryPos( pSaveNum->GetLevelCount(), TRUE); + aLevelLB.SelectEntryPos( pSaveNum->GetLevelCount(), sal_True); } else - for(USHORT i = 0; i < pSaveNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pSaveNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) - aLevelLB.SelectEntryPos( i, TRUE); + aLevelLB.SelectEntryPos( i, sal_True); nMask <<= 1 ; } - aLevelLB.SetUpdateMode(TRUE); + aLevelLB.SetUpdateMode(sal_True); if(!pActNum) pActNum = new SvxNumRule(*pSaveNum); @@ -1388,21 +1375,21 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) } SfxObjectShell* pShell; - if ( SFX_ITEM_SET == rSet.GetItemState( SID_HTML_MODE, FALSE, &pItem ) + if ( SFX_ITEM_SET == rSet.GetItemState( SID_HTML_MODE, sal_False, &pItem ) || ( 0 != ( pShell = SfxObjectShell::Current()) && 0 != ( pItem = pShell->GetItem( SID_HTML_MODE ) ) ) ) { - USHORT nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue(); + sal_uInt16 nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue(); bHTMLMode = 0 != (nHtmlMode&HTMLMODE_ON); } - BOOL bCharFmt = pActNum->IsFeatureSupported(NUM_CHAR_STYLE); + sal_Bool bCharFmt = pActNum->IsFeatureSupported(NUM_CHAR_STYLE); aCharFmtFT.Show(bCharFmt); aCharFmtLB.Show(bCharFmt); - BOOL bContinuous = pActNum->IsFeatureSupported(NUM_CONTINUOUS); + sal_Bool bContinuous = pActNum->IsFeatureSupported(NUM_CONTINUOUS); - BOOL bAllLevel = bContinuous && !bHTMLMode; + sal_Bool bAllLevel = bContinuous && !bHTMLMode; aAllLevelFT.Show(bAllLevel); aAllLevelNF.Show(bAllLevel); @@ -1413,10 +1400,10 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) //remove types that are unsupported by Draw/Impress if(!bContinuous) { - USHORT nFmtCount = aFmtLB.GetEntryCount(); - for(USHORT i = nFmtCount; i; i--) + sal_uInt16 nFmtCount = aFmtLB.GetEntryCount(); + for(sal_uInt16 i = nFmtCount; i; i--) { - USHORT nEntryData = (USHORT)(ULONG)aFmtLB.GetEntryData(i - 1); + sal_uInt16 nEntryData = (sal_uInt16)(sal_uLong)aFmtLB.GetEntryData(i - 1); if(/*SVX_NUM_NUMBER_NONE == nEntryData ||*/ ((SVX_NUM_BITMAP|LINK_TOKEN) == nEntryData)) aFmtLB.RemoveEntry(i - 1); @@ -1426,14 +1413,14 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) if(!pActNum->IsFeatureSupported(NUM_ENABLE_LINKED_BMP)) { long nData = SVX_NUM_BITMAP|LINK_TOKEN; - USHORT nPos = aFmtLB.GetEntryPos((void*)nData); + sal_uInt16 nPos = aFmtLB.GetEntryPos((void*)nData); if(LISTBOX_ENTRY_NOTFOUND != nPos) aFmtLB.RemoveEntry(nPos); } else if(!pActNum->IsFeatureSupported(NUM_ENABLE_EMBEDDED_BMP)) { long nData = SVX_NUM_BITMAP; - USHORT nPos = aFmtLB.GetEntryPos((void*)nData); + sal_uInt16 nPos = aFmtLB.GetEntryPos((void*)nData); if(LISTBOX_ENTRY_NOTFOUND != nPos) aFmtLB.RemoveEntry(nPos); } @@ -1451,48 +1438,48 @@ void SvxNumOptionsTabPage::Reset( const SfxItemSet& rSet ) //Alle arten der numerischen Aufzaehlungen loeschen if(pActNum->IsFeatureSupported(NUM_NO_NUMBERS)) { - USHORT nFmtCount = aFmtLB.GetEntryCount(); - for(USHORT i = nFmtCount; i; i--) + sal_uInt16 nFmtCount = aFmtLB.GetEntryCount(); + for(sal_uInt16 i = nFmtCount; i; i--) { - USHORT nEntryData = (USHORT)(ULONG)aFmtLB.GetEntryData(i - 1); + sal_uInt16 nEntryData = (sal_uInt16)(sal_uLong)aFmtLB.GetEntryData(i - 1); if( /*nEntryData >= SVX_NUM_CHARS_UPPER_LETTER &&*/ nEntryData <= SVX_NUM_NUMBER_NONE) aFmtLB.RemoveEntry(i - 1); } } InitControls(); - bModified = FALSE; + bModified = sal_False; } void SvxNumOptionsTabPage::InitControls() { - BOOL bShowBullet = TRUE; - BOOL bShowBitmap = TRUE; - BOOL bSameType = TRUE; - BOOL bSameStart = TRUE; - BOOL bSamePrefix = TRUE; - BOOL bSameSuffix = TRUE; - BOOL bAllLevel = TRUE; - BOOL bSameCharFmt = TRUE; - BOOL bSameVOrient = TRUE; - BOOL bSameSize = TRUE; - BOOL bSameBulColor = TRUE; - BOOL bSameBulRelSize= TRUE; - BOOL bSameAdjust = TRUE; + sal_Bool bShowBullet = sal_True; + sal_Bool bShowBitmap = sal_True; + sal_Bool bSameType = sal_True; + sal_Bool bSameStart = sal_True; + sal_Bool bSamePrefix = sal_True; + sal_Bool bSameSuffix = sal_True; + sal_Bool bAllLevel = sal_True; + sal_Bool bSameCharFmt = sal_True; + sal_Bool bSameVOrient = sal_True; + sal_Bool bSameSize = sal_True; + sal_Bool bSameBulColor = sal_True; + sal_Bool bSameBulRelSize= sal_True; + sal_Bool bSameAdjust = sal_True; const SvxNumberFormat* aNumFmtArr[SVX_MAX_NUM]; String sFirstCharFmt; sal_Int16 eFirstOrient = text::VertOrientation::NONE; Size aFirstSize(0,0); - USHORT nMask = 1; - USHORT nLvl = USHRT_MAX; - USHORT nHighestLevel = 0; + sal_uInt16 nMask = 1; + sal_uInt16 nLvl = USHRT_MAX; + sal_uInt16 nHighestLevel = 0; String aEmptyStr; - BOOL bBullColor = pActNum->IsFeatureSupported(NUM_BULLET_COLOR); - BOOL bBullRelSize = pActNum->IsFeatureSupported(NUM_BULLET_REL_SIZE); - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_Bool bBullColor = pActNum->IsFeatureSupported(NUM_BULLET_COLOR); + sal_Bool bBullRelSize = pActNum->IsFeatureSupported(NUM_BULLET_REL_SIZE); + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -1539,7 +1526,7 @@ void SvxNumOptionsTabPage::InitControls() aOrientLB.SetNoSelection(); else aOrientLB.SelectEntryPos( - sal::static_int_cast< USHORT >(eFirstOrient - 1)); + sal::static_int_cast< sal_uInt16 >(eFirstOrient - 1)); // kein text::VertOrientation::NONE if(bSameSize) @@ -1556,7 +1543,7 @@ void SvxNumOptionsTabPage::InitControls() if(bSameType) { - USHORT nLBData = (USHORT) aNumFmtArr[nLvl]->GetNumberingType(); + sal_uInt16 nLBData = (sal_uInt16) aNumFmtArr[nLvl]->GetNumberingType(); aFmtLB.SelectEntryPos(aFmtLB.GetEntryPos( (void*)sal::static_int_cast<sal_uIntPtr>( nLBData ) )); } else @@ -1574,7 +1561,7 @@ void SvxNumOptionsTabPage::InitControls() } if(bSameAdjust) { - USHORT nPos = 1; // zentriert + sal_uInt16 nPos = 1; // zentriert if(aNumFmtArr[nLvl]->GetNumAdjust() == SVX_ADJUST_LEFT) nPos = 0; else if(aNumFmtArr[nLvl]->GetNumAdjust() == SVX_ADJUST_RIGHT) @@ -1640,14 +1627,14 @@ void SvxNumOptionsTabPage::InitControls() } // 0 - Nummer; 1 - Bullet; 2 - Bitmap -void SvxNumOptionsTabPage::SwitchNumberType( BYTE nType, BOOL ) +void SvxNumOptionsTabPage::SwitchNumberType( sal_uInt8 nType, sal_Bool ) { if(nBullet == nType) return; nBullet = nType; - BOOL bBitmap = FALSE; - BOOL bBullet = FALSE; - BOOL bEnableBitmap = FALSE; + sal_Bool bBitmap = sal_False; + sal_Bool bBullet = sal_False; + sal_Bool bEnableBitmap = sal_False; if(nType == SHOW_NUMBERING) { // Label umschalten, alten Text merken @@ -1658,27 +1645,27 @@ void SvxNumOptionsTabPage::SwitchNumberType( BYTE nType, BOOL ) { // Label umschalten, alten Text merken aStartFT.SetText(sBullet); - bBullet = TRUE; + bBullet = sal_True; } else { - bBitmap = TRUE; - bEnableBitmap = TRUE; + bBitmap = sal_True; + bEnableBitmap = sal_True; } - BOOL bNumeric = !(bBitmap||bBullet); + sal_Bool bNumeric = !(bBitmap||bBullet); aPrefixFT.Show(bNumeric); aPrefixED.Show(bNumeric); aSuffixFT.Show(bNumeric); aSuffixED.Show(bNumeric); - BOOL bCharFmt = pActNum->IsFeatureSupported(NUM_CHAR_STYLE); + sal_Bool bCharFmt = pActNum->IsFeatureSupported(NUM_CHAR_STYLE); aCharFmtFT.Show(!bBitmap && bCharFmt); aCharFmtLB.Show(!bBitmap && bCharFmt); // das ist eigentlich Missbrauch, da fuer die vollst. Numerierung kein // eigenes Flag existiert - BOOL bAllLevelFeature = pActNum->IsFeatureSupported(NUM_CONTINUOUS); - BOOL bAllLevel = bNumeric && bAllLevelFeature && !bHTMLMode; + sal_Bool bAllLevelFeature = pActNum->IsFeatureSupported(NUM_CONTINUOUS); + sal_Bool bAllLevel = bNumeric && bAllLevelFeature && !bHTMLMode; aAllLevelFT.Show(bAllLevel); aAllLevelNF.Show(bAllLevel); @@ -1686,10 +1673,10 @@ void SvxNumOptionsTabPage::SwitchNumberType( BYTE nType, BOOL ) aStartED.Show(!(bBullet||bBitmap)); aBulletPB.Show(bBullet); - BOOL bBullColor = pActNum->IsFeatureSupported(NUM_BULLET_COLOR); + sal_Bool bBullColor = pActNum->IsFeatureSupported(NUM_BULLET_COLOR); aBulColorFT.Show( !bBitmap && bBullColor ); aBulColLB.Show( !bBitmap && bBullColor ); - BOOL bBullResSize = pActNum->IsFeatureSupported(NUM_BULLET_REL_SIZE); + sal_Bool bBullResSize = pActNum->IsFeatureSupported(NUM_BULLET_REL_SIZE); aBulRelSizeFT.Show( !bBitmap && bBullResSize ); aBulRelSizeMF.Show( !bBitmap && bBullResSize ); @@ -1717,33 +1704,33 @@ void SvxNumOptionsTabPage::SwitchNumberType( BYTE nType, BOOL ) IMPL_LINK( SvxNumOptionsTabPage, LevelHdl_Impl, ListBox *, pBox ) { - USHORT nSaveNumLvl = nActNumLvl; + sal_uInt16 nSaveNumLvl = nActNumLvl; nActNumLvl = 0; if(pBox->IsEntryPosSelected( pActNum->GetLevelCount() ) && (pBox->GetSelectEntryCount() == 1 || nSaveNumLvl != 0xffff)) { nActNumLvl = 0xFFFF; - pBox->SetUpdateMode(FALSE); - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) - pBox->SelectEntryPos( i, FALSE ); - pBox->SetUpdateMode(TRUE); + pBox->SetUpdateMode(sal_False); + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) + pBox->SelectEntryPos( i, sal_False ); + pBox->SetUpdateMode(sal_True); } else if(pBox->GetSelectEntryCount()) { - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) { if(pBox->IsEntryPosSelected( i )) nActNumLvl |= nMask; nMask <<= 1; } - pBox->SelectEntryPos( pActNum->GetLevelCount(), FALSE ); + pBox->SelectEntryPos( pActNum->GetLevelCount(), sal_False ); } else { nActNumLvl = nSaveNumLvl; - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) { if(nActNumLvl & nMask) { @@ -1765,15 +1752,15 @@ IMPL_LINK( SvxNumOptionsTabPage, PreviewInvalidateHdl_Impl, Timer*, EMPTYARG ) IMPL_LINK( SvxNumOptionsTabPage, AllLevelHdl_Impl, NumericField*, pBox ) { - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { - USHORT nMask = 1; - for(USHORT e = 0; e < pActNum->GetLevelCount(); e++) + sal_uInt16 nMask = 1; + for(sal_uInt16 e = 0; e < pActNum->GetLevelCount(); e++) { if(nActNumLvl & nMask) { SvxNumberFormat aNumFmt(pActNum->GetLevel(e)); - aNumFmt.SetIncludeUpperLevels((BYTE) std::min(pBox->GetValue(), sal_Int64(e + 1)) ); + aNumFmt.SetIncludeUpperLevels((sal_uInt8) std::min(pBox->GetValue(), sal_Int64(e + 1)) ); pActNum->SetLevel(e, aNumFmt); } nMask <<= 1; @@ -1786,34 +1773,34 @@ IMPL_LINK( SvxNumOptionsTabPage, AllLevelHdl_Impl, NumericField*, pBox ) IMPL_LINK( SvxNumOptionsTabPage, NumberTypeSelectHdl_Impl, ListBox *, pBox ) { String sSelectStyle; - BOOL bShowOrient = FALSE; - BOOL bBmp = FALSE; + sal_Bool bShowOrient = sal_False; + sal_Bool bBmp = sal_False; String aEmptyStr; - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { SvxNumberFormat aNumFmt(pActNum->GetLevel(i)); // PAGEDESC gibt es nicht - USHORT nNumType = (USHORT)(ULONG)pBox->GetEntryData(pBox->GetSelectEntryPos()); + sal_uInt16 nNumType = (sal_uInt16)(sal_uLong)pBox->GetEntryData(pBox->GetSelectEntryPos()); aNumFmt.SetNumberingType((sal_Int16)nNumType); sal_uInt16 nNumberingType = aNumFmt.GetNumberingType(); if(SVX_NUM_BITMAP == (nNumberingType&(~LINK_TOKEN))) { bBmp |= 0 != aNumFmt.GetBrush(); - aNumFmt.SetIncludeUpperLevels( FALSE ); + aNumFmt.SetIncludeUpperLevels( sal_False ); aNumFmt.SetSuffix( aEmptyStr ); aNumFmt.SetPrefix( aEmptyStr ); if(!bBmp) aNumFmt.SetGraphic(aEmptyStr); pActNum->SetLevel(i, aNumFmt); SwitchNumberType(SHOW_BITMAP, bBmp ); - bShowOrient = TRUE; + bShowOrient = sal_True; } else if( SVX_NUM_CHAR_SPECIAL == nNumberingType ) { - aNumFmt.SetIncludeUpperLevels( FALSE ); + aNumFmt.SetIncludeUpperLevels( sal_False ); aNumFmt.SetSuffix( aEmptyStr ); aNumFmt.SetPrefix( aEmptyStr ); if( !aNumFmt.GetBulletFont() ) @@ -1845,7 +1832,7 @@ IMPL_LINK( SvxNumOptionsTabPage, NumberTypeSelectHdl_Impl, ListBox *, pBox ) } nMask <<= 1; } - BOOL bAllLevelFeature = pActNum->IsFeatureSupported(NUM_CONTINUOUS); + sal_Bool bAllLevelFeature = pActNum->IsFeatureSupported(NUM_CONTINUOUS); if(bShowOrient && bAllLevelFeature) { aOrientFT.Show(); @@ -1861,15 +1848,15 @@ IMPL_LINK( SvxNumOptionsTabPage, NumberTypeSelectHdl_Impl, ListBox *, pBox ) { aCharFmtLB.SelectEntry(sSelectStyle); CharFmtHdl_Impl(&aCharFmtLB); - bAutomaticCharStyles = TRUE; + bAutomaticCharStyles = sal_True; } return 0; } void SvxNumOptionsTabPage::CheckForStartValue_Impl(sal_uInt16 nNumberingType) { - BOOL bIsNull = aStartED.GetValue() == 0; - BOOL bNoZeroAllowed = nNumberingType < SVX_NUM_ARABIC || + sal_Bool bIsNull = aStartED.GetValue() == 0; + sal_Bool bNoZeroAllowed = nNumberingType < SVX_NUM_ARABIC || SVX_NUM_CHARS_UPPER_LETTER_N == nNumberingType || SVX_NUM_CHARS_LOWER_LETTER_N == nNumberingType; aStartED.SetMin(bNoZeroAllowed ? 1 : 0); @@ -1879,11 +1866,11 @@ void SvxNumOptionsTabPage::CheckForStartValue_Impl(sal_uInt16 nNumberingType) IMPL_LINK( SvxNumOptionsTabPage, OrientHdl_Impl, ListBox *, pBox ) { - USHORT nPos = pBox->GetSelectEntryPos(); + sal_uInt16 nPos = pBox->GetSelectEntryPos(); nPos ++; // kein VERT_NONE - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -1899,22 +1886,22 @@ IMPL_LINK( SvxNumOptionsTabPage, OrientHdl_Impl, ListBox *, pBox ) } nMask <<= 1; } - SetModified(FALSE); + SetModified(sal_False); return 0; } IMPL_LINK( SvxNumOptionsTabPage, SameLevelHdl_Impl, CheckBox *, pBox ) { - BOOL bSet = pBox->IsChecked(); + sal_Bool bSet = pBox->IsChecked(); pActNum->SetContinuousNumbering(bSet); - BOOL bRepaint = FALSE; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_Bool bRepaint = sal_False; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { SvxNumberFormat aNumFmt(pActNum->GetLevel(i)); if(aNumFmt.GetNumberingType() != SVX_NUM_NUMBER_NONE) { - bRepaint = TRUE; + bRepaint = sal_True; break; } } @@ -1927,8 +1914,8 @@ IMPL_LINK( SvxNumOptionsTabPage, BulColorHdl_Impl, ColorListBox*, pBox ) { Color nSetColor = pBox->GetSelectEntryColor(); - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -1944,10 +1931,10 @@ IMPL_LINK( SvxNumOptionsTabPage, BulColorHdl_Impl, ColorListBox*, pBox ) IMPL_LINK( SvxNumOptionsTabPage, BulRelSizeHdl_Impl, MetricField *, pField) { - USHORT nRelSize = (USHORT)pField->GetValue(); + sal_uInt16 nRelSize = (sal_uInt16)pField->GetValue(); - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -1963,7 +1950,7 @@ IMPL_LINK( SvxNumOptionsTabPage, BulRelSizeHdl_Impl, MetricField *, pField) IMPL_LINK( SvxNumOptionsTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { - USHORT nItemId = pButton->GetCurItemId(); + sal_uInt16 nItemId = pButton->GetCurItemId(); String aGrfName; Size aSize; sal_Bool bSucc(sal_False); @@ -2000,8 +1987,8 @@ IMPL_LINK( SvxNumOptionsTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { aSize = OutputDevice::LogicToLogic(aSize, MAP_100TH_MM, (MapUnit)eCoreUnit); - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -2040,7 +2027,7 @@ IMPL_LINK( SvxNumOptionsTabPage, PopupActivateHdl_Impl, Menu *, EMPTYARG ) { if(!bMenuButtonInitialized) { - bMenuButtonInitialized = TRUE; + bMenuButtonInitialized = sal_True; EnterWait(); PopupMenu* pPopup = aBitmapMB.GetPopupMenu()->GetPopupMenu( MN_GALLERY ); GalleryExplorer::FillObjList(GALLERY_THEME_BULLETS, aGrfNames); @@ -2050,7 +2037,7 @@ IMPL_LINK( SvxNumOptionsTabPage, PopupActivateHdl_Impl, Menu *, EMPTYARG ) String aEmptyStr; GalleryExplorer::BeginLocking(GALLERY_THEME_BULLETS); - for(USHORT i = 0; i < aGrfNames.Count(); i++) + for(sal_uInt16 i = 0; i < aGrfNames.Count(); i++) { Graphic aGraphic; String sGrfName = *(const String*)aGrfNames.GetObject(i); @@ -2064,7 +2051,7 @@ IMPL_LINK( SvxNumOptionsTabPage, PopupActivateHdl_Impl, Menu *, EMPTYARG ) if(aSize.Width() > MAX_BMP_WIDTH || aSize.Height() > MAX_BMP_HEIGHT) { - BOOL bWidth = aSize.Width() > aSize.Height(); + sal_Bool bWidth = aSize.Width() > aSize.Height(); double nScale = bWidth ? (double)MAX_BMP_WIDTH / (double)aSize.Width(): (double)MAX_BMP_HEIGHT / (double)aSize.Height(); @@ -2090,14 +2077,14 @@ IMPL_LINK( SvxNumOptionsTabPage, PopupActivateHdl_Impl, Menu *, EMPTYARG ) IMPL_LINK( SvxNumOptionsTabPage, BulletHdl_Impl, Button *, EMPTYARG ) { - SvxCharacterMap* pMap = new SvxCharacterMap( this, TRUE ); + SvxCharacterMap* pMap = new SvxCharacterMap( this, sal_True ); - USHORT nMask = 1; + sal_uInt16 nMask = 1; const Font* pFmtFont = 0; - BOOL bSameBullet = TRUE; + sal_Bool bSameBullet = sal_True; sal_Unicode cBullet = 0; - BOOL bFirst = TRUE; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_Bool bFirst = sal_True; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -2108,12 +2095,12 @@ IMPL_LINK( SvxNumOptionsTabPage, BulletHdl_Impl, Button *, EMPTYARG ) } else if(rCurFmt.GetBulletChar() != cBullet ) { - bSameBullet = FALSE; + bSameBullet = sal_False; break; } if(!pFmtFont) pFmtFont = rCurFmt.GetBulletFont(); - bFirst = FALSE; + bFirst = sal_False; } nMask <<= 1; @@ -2130,8 +2117,8 @@ IMPL_LINK( SvxNumOptionsTabPage, BulletHdl_Impl, Button *, EMPTYARG ) // Font Numrules umstellen aActBulletFont = pMap->GetCharFont(); - USHORT _nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 _nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & _nMask) { @@ -2151,9 +2138,9 @@ IMPL_LINK( SvxNumOptionsTabPage, BulletHdl_Impl, Button *, EMPTYARG ) IMPL_LINK( SvxNumOptionsTabPage, SizeHdl_Impl, MetricField *, pField) { - BOOL bWidth = pField == &aWidthMF; + sal_Bool bWidth = pField == &aWidthMF; bLastWidthModified = bWidth; - BOOL bRatio = aRatioCB.IsChecked(); + sal_Bool bRatio = aRatioCB.IsChecked(); long nWidthVal = static_cast<long>(aWidthMF.Denormalize(aWidthMF.GetValue(FUNIT_100TH_MM))); long nHeightVal = static_cast<long>(aHeightMF.Denormalize(aHeightMF.GetValue(FUNIT_100TH_MM))); nWidthVal = OutputDevice::LogicToLogic( nWidthVal , @@ -2162,9 +2149,9 @@ IMPL_LINK( SvxNumOptionsTabPage, SizeHdl_Impl, MetricField *, pField) MAP_100TH_MM, (MapUnit)eCoreUnit); double fSizeRatio; - BOOL bRepaint = FALSE; - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_Bool bRepaint = sal_False; + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -2206,7 +2193,7 @@ IMPL_LINK( SvxNumOptionsTabPage, SizeHdl_Impl, MetricField *, pField) const SvxBrushItem* pBrushItem = aNumFmt.GetBrush(); sal_Int16 eOrient = aNumFmt.GetVertOrient(); if(aSize != aSaveSize) - bRepaint = TRUE; + bRepaint = sal_True; aNumFmt.SetGraphicBrush( pBrushItem, &aSize, &eOrient ); pActNum->SetLevel(i, aNumFmt); } @@ -2231,12 +2218,12 @@ IMPL_LINK( SvxNumOptionsTabPage, RatioHdl_Impl, CheckBox *, pBox ) IMPL_LINK( SvxNumOptionsTabPage, CharFmtHdl_Impl, ListBox *, EMPTYARG ) { - bAutomaticCharStyles = FALSE; - USHORT nEntryPos = aCharFmtLB.GetSelectEntryPos(); + bAutomaticCharStyles = sal_False; + sal_uInt16 nEntryPos = aCharFmtLB.GetSelectEntryPos(); String sEntry = aCharFmtLB.GetSelectEntry(); - USHORT nMask = 1; + sal_uInt16 nMask = 1; String aEmptyStr; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -2252,18 +2239,18 @@ IMPL_LINK( SvxNumOptionsTabPage, CharFmtHdl_Impl, ListBox *, EMPTYARG ) } nMask <<= 1; } - SetModified(FALSE); + SetModified(sal_False); return 0; }; IMPL_LINK( SvxNumOptionsTabPage, EditModifyHdl_Impl, Edit *, pEdit ) { - BOOL bPrefix = pEdit == &aPrefixED; - BOOL bSuffix = pEdit == &aSuffixED; - BOOL bStart = pEdit == &aStartED; - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_Bool bPrefix = pEdit == &aPrefixED; + sal_Bool bSuffix = pEdit == &aSuffixED; + sal_Bool bStart = pEdit == &aStartED; + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -2273,10 +2260,10 @@ IMPL_LINK( SvxNumOptionsTabPage, EditModifyHdl_Impl, Edit *, pEdit ) else if(bSuffix) aNumFmt.SetSuffix( aSuffixED.GetText() ); else if(bStart) - aNumFmt.SetStart( (USHORT)aStartED.GetValue() ); + aNumFmt.SetStart( (sal_uInt16)aStartED.GetValue() ); else //align { - USHORT nPos = aAlignLB.GetSelectEntryPos(); + sal_uInt16 nPos = aAlignLB.GetSelectEntryPos(); SvxAdjust eAdjust = SVX_ADJUST_CENTER; if(nPos == 0) eAdjust = SVX_ADJUST_LEFT; @@ -2293,11 +2280,11 @@ IMPL_LINK( SvxNumOptionsTabPage, EditModifyHdl_Impl, Edit *, pEdit ) return 0; } -USHORT lcl_DrawGraphic(VirtualDevice* pVDev, const SvxNumberFormat &rFmt, USHORT nXStart, - USHORT nYStart, USHORT nDivision) +sal_uInt16 lcl_DrawGraphic(VirtualDevice* pVDev, const SvxNumberFormat &rFmt, sal_uInt16 nXStart, + sal_uInt16 nYStart, sal_uInt16 nDivision) { const SvxBrushItem* pBrushItem = rFmt.GetBrush(); - USHORT nRet = 0; + sal_uInt16 nRet = 0; if(pBrushItem) { const Graphic* pGrf = pBrushItem->GetGraphic(); @@ -2305,7 +2292,7 @@ USHORT lcl_DrawGraphic(VirtualDevice* pVDev, const SvxNumberFormat &rFmt, USHORT { Size aGSize( rFmt.GetGraphicSize() ); aGSize.Width() /= nDivision; - nRet = (USHORT)aGSize.Width(); + nRet = (sal_uInt16)aGSize.Width(); aGSize.Height() /= nDivision; pGrf->Draw( pVDev, Point(nXStart,nYStart), pVDev->PixelToLogic( aGSize ) ); @@ -2315,9 +2302,9 @@ USHORT lcl_DrawGraphic(VirtualDevice* pVDev, const SvxNumberFormat &rFmt, USHORT } -USHORT lcl_DrawBullet(VirtualDevice* pVDev, - const SvxNumberFormat& rFmt, USHORT nXStart, - USHORT nYStart, const Size& rSize) +sal_uInt16 lcl_DrawBullet(VirtualDevice* pVDev, + const SvxNumberFormat& rFmt, sal_uInt16 nXStart, + sal_uInt16 nYStart, const Size& rSize) { Font aTmpFont(pVDev->GetFont()); @@ -2332,7 +2319,7 @@ USHORT lcl_DrawBullet(VirtualDevice* pVDev, if(!aTmpSize.Height()) aTmpSize.Height() = 1; aFont.SetSize(aTmpSize); - aFont.SetTransparent(TRUE); + aFont.SetTransparent(sal_True); Color aBulletColor = rFmt.GetBulletColor(); if(aBulletColor.GetColor() == COL_AUTO) aBulletColor = Color(pVDev->GetFillColor().IsDark() ? COL_WHITE : COL_BLACK); @@ -2344,7 +2331,7 @@ USHORT lcl_DrawBullet(VirtualDevice* pVDev, long nY = nYStart; nY -= ((aTmpSize.Height() - rSize.Height())/ 2); pVDev->DrawText( Point(nXStart, nY), aText ); - USHORT nRet = (USHORT)pVDev->GetTextWidth(aText); + sal_uInt16 nRet = (sal_uInt16)pVDev->GetTextWidth(aText); pVDev->SetFont(aTmpFont); return nRet; @@ -2374,10 +2361,10 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) if(pActNum) { - USHORT nWidthRelation; + sal_uInt16 nWidthRelation; if(nPageWidth) { - nWidthRelation = USHORT (nPageWidth / aSize.Width()); + nWidthRelation = sal_uInt16 (nPageWidth / aSize.Width()); if(bPosition) nWidthRelation = nWidthRelation * 2 / 3; else @@ -2387,50 +2374,50 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) nWidthRelation = 30; // Kapiteldialog //Hoehe pro Ebene - USHORT nXStep = sal::static_int_cast< USHORT >(aSize.Width() / (3 * pActNum->GetLevelCount())); + sal_uInt16 nXStep = sal::static_int_cast< sal_uInt16 >(aSize.Width() / (3 * pActNum->GetLevelCount())); if(pActNum->GetLevelCount() < 10) nXStep /= 2; - USHORT nYStart = 4; + sal_uInt16 nYStart = 4; // fuer ein einziges Level darf nicht die gesamte Hoehe benutzt werden - USHORT nYStep = sal::static_int_cast< USHORT >((aSize.Height() - 6)/ (pActNum->GetLevelCount() > 1 ? pActNum->GetLevelCount() : 5)); + sal_uInt16 nYStep = sal::static_int_cast< sal_uInt16 >((aSize.Height() - 6)/ (pActNum->GetLevelCount() > 1 ? pActNum->GetLevelCount() : 5)); aStdFont = OutputDevice::GetDefaultFont( DEFAULTFONT_UI_SANS, MsLangId::getSystemLanguage(), DEFAULTFONT_FLAGS_ONLYONE); aStdFont.SetColor(aTextColor); aStdFont.SetFillColor(aBackColor); - USHORT nFontHeight = nYStep * 6 / 10; + sal_uInt16 nFontHeight = nYStep * 6 / 10; if(bPosition) nFontHeight = nYStep * 15 / 10; aStdFont.SetSize(Size( 0, nFontHeight )); - SvxNodeNum aNum( (BYTE)0 ); - USHORT nPreNum = pActNum->GetLevel(0).GetStart(); + SvxNodeNum aNum( (sal_uInt8)0 ); + sal_uInt16 nPreNum = pActNum->GetLevel(0).GetStart(); if(bPosition) { - USHORT nLineHeight = nFontHeight * 8 / 7; - BYTE nStart = 0; + sal_uInt16 nLineHeight = nFontHeight * 8 / 7; + sal_uInt8 nStart = 0; while( !(nActLevel & (1<<nStart)) ) { nStart++; } if(nStart) nStart--; - BYTE nEnd = std::min( (BYTE)(nStart + 3), (BYTE)pActNum->GetLevelCount() ); - for( BYTE nLevel = nStart; nLevel < nEnd; ++nLevel ) + sal_uInt8 nEnd = std::min( (sal_uInt8)(nStart + 3), (sal_uInt8)pActNum->GetLevelCount() ); + for( sal_uInt8 nLevel = nStart; nLevel < nEnd; ++nLevel ) { const SvxNumberFormat &rFmt = pActNum->GetLevel(nLevel); aNum.GetLevelVal()[ nLevel ] = rFmt.GetStart(); - USHORT nXStart( 0 ); + sal_uInt16 nXStart( 0 ); short nTextOffset( 0 ); - USHORT nNumberXPos( 0 ); + sal_uInt16 nNumberXPos( 0 ); if ( rFmt.GetPositionAndSpaceMode() == SvxNumberFormat::LABEL_WIDTH_AND_POSITION ) { nXStart = rFmt.GetAbsLSpace() / nWidthRelation; nTextOffset = rFmt.GetCharTextDistance() / nWidthRelation; nNumberXPos = nXStart; - USHORT nFirstLineOffset = (-rFmt.GetFirstLineOffset()) / nWidthRelation; + sal_uInt16 nFirstLineOffset = (-rFmt.GetFirstLineOffset()) / nWidthRelation; if(nFirstLineOffset <= nNumberXPos) nNumberXPos = nNumberXPos - nFirstLineOffset; @@ -2451,11 +2438,11 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) } else { - nNumberXPos = static_cast<USHORT>( nTmpNumberXPos ); + nNumberXPos = static_cast<sal_uInt16>( nTmpNumberXPos ); } } - USHORT nBulletWidth = 0; + sal_uInt16 nBulletWidth = 0; if( SVX_NUM_BITMAP == (rFmt.GetNumberingType() &(~LINK_TOKEN))) { nBulletWidth = rFmt.IsShowSymbol() ? lcl_DrawGraphic(pVDev, rFmt, @@ -2485,7 +2472,7 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) pVDev->SetFont(aColorFont); pVDev->DrawText( Point(nNumberXPos, nYStart), aText ); pVDev->SetFont(aSaveFont); - nBulletWidth = (USHORT)pVDev->GetTextWidth(aText); + nBulletWidth = (sal_uInt16)pVDev->GetTextWidth(aText); nPreNum++; } if ( rFmt.GetPositionAndSpaceMode() == SvxNumberFormat::LABEL_ALIGNMENT && @@ -2494,10 +2481,10 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) pVDev->SetFont(aStdFont); String aText(' '); pVDev->DrawText( Point(nNumberXPos, nYStart), aText ); - nBulletWidth = nBulletWidth + (USHORT)pVDev->GetTextWidth(aText); + nBulletWidth = nBulletWidth + (sal_uInt16)pVDev->GetTextWidth(aText); } - USHORT nTextXPos( 0 ); + sal_uInt16 nTextXPos( 0 ); if ( rFmt.GetPositionAndSpaceMode() == SvxNumberFormat::LABEL_WIDTH_AND_POSITION ) { nTextXPos = nXStart; @@ -2512,7 +2499,7 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) { case SvxNumberFormat::LISTTAB: { - nTextXPos = static_cast<USHORT>( + nTextXPos = static_cast<sal_uInt16>( rFmt.GetListtabPos() / nWidthRelation ); if ( nTextXPos < nNumberXPos + nBulletWidth ) { @@ -2528,7 +2515,7 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) break; } - nXStart = static_cast<USHORT>( rFmt.GetIndentAt() / nWidthRelation ); + nXStart = static_cast<sal_uInt16>( rFmt.GetIndentAt() / nWidthRelation ); } Rectangle aRect1(Point(nTextXPos, nYStart + nFontHeight / 2), Size(aSize.Width() / 2, 2)); @@ -2552,12 +2539,12 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) if(aBlackColor == aBackColor) aBlackColor.Invert(); - for( BYTE nLevel = 0; nLevel < pActNum->GetLevelCount(); + for( sal_uInt8 nLevel = 0; nLevel < pActNum->GetLevelCount(); ++nLevel, nYStart = nYStart + nYStep ) { const SvxNumberFormat &rFmt = pActNum->GetLevel(nLevel); aNum.GetLevelVal()[ nLevel ] = rFmt.GetStart(); - USHORT nXStart( 0 ); + sal_uInt16 nXStart( 0 ); if ( rFmt.GetPositionAndSpaceMode() == SvxNumberFormat::LABEL_WIDTH_AND_POSITION ) { nXStart = rFmt.GetAbsLSpace() / nWidthRelation; @@ -2573,12 +2560,12 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) } else { - nXStart = static_cast<USHORT>(nTmpXStart); + nXStart = static_cast<sal_uInt16>(nTmpXStart); } } nXStart /= 2; nXStart += 2; - USHORT nTextOffset = 2 * nXStep; + sal_uInt16 nTextOffset = 2 * nXStep; if( SVX_NUM_BITMAP == (rFmt.GetNumberingType()&(~LINK_TOKEN)) ) { if(rFmt.IsShowSymbol()) @@ -2611,7 +2598,7 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ ) String aText(pActNum->MakeNumString( aNum )); pVDev->DrawText( Point(nXStart, nYStart), aText ); pVDev->SetFont(aStdFont); - nTextOffset = (USHORT)pVDev->GetTextWidth(aText); + nTextOffset = (sal_uInt16)pVDev->GetTextWidth(aText); nTextOffset = nTextOffset + nXStep; nPreNum++; } @@ -2682,7 +2669,7 @@ SvxNumPositionTabPage::SvxNumPositionTabPage(Window* pParent, nNumItemId(SID_ATTR_NUMBERING_RULE), bModified(false), bPreset(false), - bInInintControl(FALSE), + bInInintControl(sal_False), bLabelAlignmentPosAndSpaceModeActive( false ) { FreeResource(); @@ -2692,7 +2679,7 @@ SvxNumPositionTabPage::SvxNumPositionTabPage(Window* pParent, aRelativeCB.Check(); aAlignLB.SetSelectHdl(LINK(this, SvxNumPositionTabPage, EditModifyHdl_Impl)); aAlign2LB.SetSelectHdl(LINK(this, SvxNumPositionTabPage, EditModifyHdl_Impl)); - for ( USHORT i = 0; i < aAlignLB.GetEntryCount(); ++i ) + for ( sal_uInt16 i = 0; i < aAlignLB.GetEntryCount(); ++i ) { aAlign2LB.InsertEntry( aAlignLB.GetEntry( i ) ); } @@ -2749,6 +2736,8 @@ SvxNumPositionTabPage::SvxNumPositionTabPage(Window* pParent, pDebugFixedText->SetPosSizePixel(aPos, aSize); pDebugFixedText->SetText( UniString::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "Das ist ein Debug-Text" ) ) ); #endif + + aStandardPB.SetAccessibleRelationMemberOf(&aPositionFL); } SvxNumPositionTabPage::~SvxNumPositionTabPage() @@ -2792,7 +2781,7 @@ void lcl_PrintDebugOutput(FixedText& rFixed, const SvxNumberFormat& rNumFmt) void SvxNumPositionTabPage::InitControls() { - bInInintControl = TRUE; + bInInintControl = sal_True; const bool bRelative = !bLabelAlignmentPosAndSpaceModeActive && aRelativeCB.IsEnabled() && aRelativeCB.IsChecked(); const bool bSingleSelection = aLevelLB.GetSelectEntryCount() == 1 && @@ -2815,11 +2804,11 @@ void SvxNumPositionTabPage::InitControls() bool bSameIndentAt = bLabelAlignmentPosAndSpaceModeActive; const SvxNumberFormat* aNumFmtArr[SVX_MAX_NUM]; - USHORT nMask = 1; - USHORT nLvl = USHRT_MAX; + sal_uInt16 nMask = 1; + sal_uInt16 nLvl = USHRT_MAX; long nFirstBorderText = 0; long nFirstBorderTextRelative = -1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { aNumFmtArr[i] = &pActNum->GetLevel(i); if(nActNumLvl & nMask) @@ -2911,7 +2900,7 @@ void SvxNumPositionTabPage::InitControls() if(bSameAdjust) { - USHORT nPos = 1; // zentriert + sal_uInt16 nPos = 1; // zentriert if(aNumFmtArr[nLvl]->GetNumAdjust() == SVX_ADJUST_LEFT) nPos = 0; else if(aNumFmtArr[nLvl]->GetNumAdjust() == SVX_ADJUST_RIGHT) @@ -2927,7 +2916,7 @@ void SvxNumPositionTabPage::InitControls() if ( bSameLabelFollowedBy ) { - USHORT nPos = 0; // LISTTAB + sal_uInt16 nPos = 0; // LISTTAB if ( aNumFmtArr[nLvl]->GetLabelFollowedBy() == SvxNumberFormat::SPACE ) { nPos = 1; @@ -2986,22 +2975,22 @@ void SvxNumPositionTabPage::InitControls() if ( bSetDistEmpty ) aDistBorderMF.SetText(aEmptyStr); - bInInintControl = FALSE; + bInInintControl = sal_False; } void SvxNumPositionTabPage::ActivatePage(const SfxItemSet& rSet) { const SfxPoolItem* pItem; - UINT16 nTmpNumLvl = USHRT_MAX; + sal_uInt16 nTmpNumLvl = USHRT_MAX; const SfxItemSet* pExampleSet = GetTabDialog()->GetExampleSet(); if(pExampleSet) { - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_NUM_PRESET, sal_False, &pItem)) bPreset = ((const SfxBoolItem*)pItem)->GetValue(); - if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, FALSE, &pItem)) + if(SFX_ITEM_SET == pExampleSet->GetItemState(SID_PARAM_CUR_NUM_LEVEL, sal_False, &pItem)) nTmpNumLvl = ((const SfxUInt16Item*)pItem)->GetValue(); } - if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, FALSE, &pItem)) + if(SFX_ITEM_SET == rSet.GetItemState(nNumItemId, sal_False, &pItem)) { delete pSaveNum; pSaveNum = new SvxNumRule(*((SvxNumBulletItem*)pItem)->GetNumRule()); @@ -3012,19 +3001,19 @@ void SvxNumPositionTabPage::ActivatePage(const SfxItemSet& rSet) { *pActNum = *pSaveNum; nActNumLvl = nTmpNumLvl; - USHORT nMask = 1; - aLevelLB.SetUpdateMode(FALSE); + sal_uInt16 nMask = 1; + aLevelLB.SetUpdateMode(sal_False); aLevelLB.SetNoSelection(); aLevelLB.SelectEntryPos( pActNum->GetLevelCount(), nActNumLvl == USHRT_MAX); if(nActNumLvl != USHRT_MAX) - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) - aLevelLB.SelectEntryPos( i, TRUE); + aLevelLB.SelectEntryPos( i, sal_True); nMask <<= 1 ; } aRelativeCB.Enable(nActNumLvl != 1); - aLevelLB.SetUpdateMode(TRUE); + aLevelLB.SetUpdateMode(sal_True); InitPosAndSpaceMode(); ShowControlsDependingOnPosAndSpaceMode(); @@ -3039,10 +3028,10 @@ int SvxNumPositionTabPage::DeactivatePage(SfxItemSet *_pSet) { if(_pSet) FillItemSet(*_pSet); - return TRUE; + return sal_True; } -BOOL SvxNumPositionTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxNumPositionTabPage::FillItemSet( SfxItemSet& rSet ) { rSet.Put(SfxUInt16Item(SID_PARAM_CUR_NUM_LEVEL, nActNumLvl)); @@ -3050,7 +3039,7 @@ BOOL SvxNumPositionTabPage::FillItemSet( SfxItemSet& rSet ) { *pSaveNum = *pActNum; rSet.Put(SvxNumBulletItem( *pSaveNum ), nNumItemId); - rSet.Put(SfxBoolItem(SID_PARAM_NUM_PRESET, FALSE)); + rSet.Put(SfxBoolItem(SID_PARAM_NUM_PRESET, sal_False)); } return bModified; } @@ -3059,15 +3048,15 @@ void SvxNumPositionTabPage::Reset( const SfxItemSet& rSet ) { const SfxPoolItem* pItem; //im Draw gibt es das Item als WhichId, im Writer nur als SlotId - SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, FALSE, &pItem); + SfxItemState eState = rSet.GetItemState(SID_ATTR_NUMBERING_RULE, sal_False, &pItem); if(eState != SFX_ITEM_SET) { nNumItemId = rSet.GetPool()->GetWhich(SID_ATTR_NUMBERING_RULE); - eState = rSet.GetItemState(nNumItemId, FALSE, &pItem); + eState = rSet.GetItemState(nNumItemId, sal_False, &pItem); if( eState != SFX_ITEM_SET ) { - pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, TRUE ) ); + pItem = &static_cast< const SvxNumBulletItem& >( rSet.Get( nNumItemId, sal_True ) ); eState = SFX_ITEM_SET; } @@ -3079,7 +3068,7 @@ void SvxNumPositionTabPage::Reset( const SfxItemSet& rSet ) // Ebenen einfuegen if(!aLevelLB.GetEntryCount()) { - for(USHORT i = 1; i <= pSaveNum->GetLevelCount(); i++) + for(sal_uInt16 i = 1; i <= pSaveNum->GetLevelCount(); i++) aLevelLB.InsertEntry(UniString::CreateFromInt32(i)); if(pSaveNum->GetLevelCount() > 1) { @@ -3093,21 +3082,21 @@ void SvxNumPositionTabPage::Reset( const SfxItemSet& rSet ) } else aLevelLB.SelectEntryPos(aLevelLB.GetEntryCount() - 1); - USHORT nMask = 1; - aLevelLB.SetUpdateMode(FALSE); + sal_uInt16 nMask = 1; + aLevelLB.SetUpdateMode(sal_False); aLevelLB.SetNoSelection(); if(nActNumLvl == USHRT_MAX) { - aLevelLB.SelectEntryPos( pSaveNum->GetLevelCount(), TRUE); + aLevelLB.SelectEntryPos( pSaveNum->GetLevelCount(), sal_True); } else - for(USHORT i = 0; i < pSaveNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pSaveNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) - aLevelLB.SelectEntryPos( i, TRUE); + aLevelLB.SelectEntryPos( i, sal_True); nMask <<= 1; } - aLevelLB.SetUpdateMode(TRUE); + aLevelLB.SetUpdateMode(sal_True); if(!pActNum) pActNum = new SvxNumRule(*pSaveNum); @@ -3119,7 +3108,7 @@ void SvxNumPositionTabPage::Reset( const SfxItemSet& rSet ) ShowControlsDependingOnPosAndSpaceMode(); InitControls(); - bModified = FALSE; + bModified = sal_False; } void SvxNumPositionTabPage::InitPosAndSpaceMode() @@ -3133,8 +3122,8 @@ void SvxNumPositionTabPage::InitPosAndSpaceMode() SvxNumberFormat::SvxNumPositionAndSpaceMode ePosAndSpaceMode = SvxNumberFormat::LABEL_ALIGNMENT; - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); ++i ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); ++i ) { if(nActNumLvl & nMask) { @@ -3205,14 +3194,14 @@ void SvxNumPositionTabPage::SetMetric(FieldUnit eMetric) IMPL_LINK( SvxNumPositionTabPage, EditModifyHdl_Impl, Edit *, EMPTYARG ) { - USHORT nMask = 1; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { SvxNumberFormat aNumFmt(pActNum->GetLevel(i)); - const USHORT nPos = aAlignLB.IsVisible() + const sal_uInt16 nPos = aAlignLB.IsVisible() ? aAlignLB.GetSelectEntryPos() : aAlign2LB.GetSelectEntryPos(); SvxAdjust eAdjust = SVX_ADJUST_CENTER; @@ -3231,33 +3220,33 @@ IMPL_LINK( SvxNumPositionTabPage, EditModifyHdl_Impl, Edit *, EMPTYARG ) IMPL_LINK( SvxNumPositionTabPage, LevelHdl_Impl, ListBox *, pBox ) { - USHORT nSaveNumLvl = nActNumLvl; + sal_uInt16 nSaveNumLvl = nActNumLvl; nActNumLvl = 0; if(pBox->IsEntryPosSelected( pActNum->GetLevelCount() ) && (pBox->GetSelectEntryCount() == 1 || nSaveNumLvl != 0xffff)) { nActNumLvl = 0xFFFF; - pBox->SetUpdateMode(FALSE); - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) - pBox->SelectEntryPos( i, FALSE ); - pBox->SetUpdateMode(TRUE); + pBox->SetUpdateMode(sal_False); + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) + pBox->SelectEntryPos( i, sal_False ); + pBox->SetUpdateMode(sal_True); } else if(pBox->GetSelectEntryCount()) { - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) { if(pBox->IsEntryPosSelected( i )) nActNumLvl |= nMask; nMask <<= 1; } - pBox->SelectEntryPos( pActNum->GetLevelCount(), FALSE ); + pBox->SelectEntryPos( pActNum->GetLevelCount(), sal_False ); } else { nActNumLvl = nSaveNumLvl; - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); i++ ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++ ) { if(nActNumLvl & nMask) { @@ -3280,11 +3269,11 @@ IMPL_LINK( SvxNumPositionTabPage, DistanceHdl_Impl, MetricField *, pFld ) if(bInInintControl) return 0; long nValue = GetCoreValue(*pFld, eCoreUnit); - USHORT nMask = 1; + sal_uInt16 nMask = 1; #if OSL_DEBUG_LEVEL > 1 - BOOL bFirst = TRUE; + sal_Bool bFirst = sal_True; #endif - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -3297,7 +3286,7 @@ IMPL_LINK( SvxNumPositionTabPage, DistanceHdl_Impl, MetricField *, pFld ) if(0 == i) { long nTmp = aNumFmt.GetFirstLineOffset(); - aNumFmt.SetAbsLSpace( USHORT(nValue - nTmp)); + aNumFmt.SetAbsLSpace( sal_uInt16(nValue - nTmp)); } else { @@ -3305,7 +3294,7 @@ IMPL_LINK( SvxNumPositionTabPage, DistanceHdl_Impl, MetricField *, pFld ) pActNum->GetLevel( i - 1 ).GetFirstLineOffset() - pActNum->GetLevel( i ).GetFirstLineOffset(); - aNumFmt.SetAbsLSpace( USHORT(nValue + nTmp)); + aNumFmt.SetAbsLSpace( sal_uInt16(nValue + nTmp)); } } else @@ -3322,14 +3311,14 @@ IMPL_LINK( SvxNumPositionTabPage, DistanceHdl_Impl, MetricField *, pFld ) //jetzt muss mit dem FirstLineOffset auch der AbsLSpace veraendert werden long nDiff = nValue + aNumFmt.GetFirstLineOffset(); long nAbsLSpace = aNumFmt.GetAbsLSpace(); - aNumFmt.SetAbsLSpace(USHORT(nAbsLSpace + nDiff)); + aNumFmt.SetAbsLSpace(sal_uInt16(nAbsLSpace + nDiff)); aNumFmt.SetFirstLineOffset( -(short)nValue ); } #if OSL_DEBUG_LEVEL > 1 if(bFirst) lcl_PrintDebugOutput(*pDebugFixedText, aNumFmt); - bFirst = FALSE; + bFirst = sal_False; #endif pActNum->SetLevel( i, aNumFmt ); } @@ -3348,16 +3337,16 @@ IMPL_LINK( SvxNumPositionTabPage, DistanceHdl_Impl, MetricField *, pFld ) IMPL_LINK( SvxNumPositionTabPage, RelativeHdl_Impl, CheckBox *, pBox ) { - BOOL bOn = pBox->IsChecked(); - BOOL bSingleSelection = aLevelLB.GetSelectEntryCount() == 1 && USHRT_MAX != nActNumLvl; - BOOL bSetValue = FALSE; + sal_Bool bOn = pBox->IsChecked(); + sal_Bool bSingleSelection = aLevelLB.GetSelectEntryCount() == 1 && USHRT_MAX != nActNumLvl; + sal_Bool bSetValue = sal_False; long nValue = 0; if(bOn || bSingleSelection) { - USHORT nMask = 1; - BOOL bFirst = TRUE; - bSetValue = TRUE; - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + sal_uInt16 nMask = 1; + sal_Bool bFirst = sal_True; + bSetValue = sal_True; + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -3372,7 +3361,7 @@ IMPL_LINK( SvxNumPositionTabPage, RelativeHdl_Impl, CheckBox *, pBox ) bSetValue = nValue == (rNumFmt.GetAbsLSpace() + rNumFmt.GetFirstLineOffset()) - (pActNum->GetLevel(i - 1).GetAbsLSpace() + pActNum->GetLevel(i - 1).GetFirstLineOffset()); - bFirst = FALSE; + bFirst = sal_False; } nMask <<= 1; } @@ -3395,7 +3384,7 @@ IMPL_LINK( SvxNumPositionTabPage, LabelFollowedByHdl_Impl, ListBox*, EMPTYARG ) SvxNumberFormat::SvxNumLabelFollowedBy eLabelFollowedBy = SvxNumberFormat::LISTTAB; { - const USHORT nPos = aLabelFollowedByLB.GetSelectEntryPos(); + const sal_uInt16 nPos = aLabelFollowedByLB.GetSelectEntryPos(); if ( nPos == 1 ) { eLabelFollowedBy = SvxNumberFormat::SPACE; @@ -3408,9 +3397,9 @@ IMPL_LINK( SvxNumPositionTabPage, LabelFollowedByHdl_Impl, ListBox*, EMPTYARG ) // set value at the chosen list levels bool bSameListtabPos = true; - USHORT nFirstLvl = USHRT_MAX; - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); ++i ) + sal_uInt16 nFirstLvl = USHRT_MAX; + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); ++i ) { if ( nActNumLvl & nMask ) { @@ -3455,8 +3444,8 @@ IMPL_LINK( SvxNumPositionTabPage, ListtabPosHdl_Impl, MetricField*, pFld ) const long nValue = GetCoreValue( *pFld, eCoreUnit ); // set value at the chosen list levels - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); ++i ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); ++i ) { if ( nActNumLvl & nMask ) { @@ -3481,8 +3470,8 @@ IMPL_LINK( SvxNumPositionTabPage, AlignAtHdl_Impl, MetricField*, pFld ) const long nValue = GetCoreValue( *pFld, eCoreUnit ); // set value at the chosen list levels - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); ++i ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); ++i ) { if ( nActNumLvl & nMask ) { @@ -3508,8 +3497,8 @@ IMPL_LINK( SvxNumPositionTabPage, IndentAtHdl_Impl, MetricField*, pFld ) const long nValue = GetCoreValue( *pFld, eCoreUnit ); // set value at the chosen list levels - USHORT nMask = 1; - for( USHORT i = 0; i < pActNum->GetLevelCount(); ++i ) + sal_uInt16 nMask = 1; + for( sal_uInt16 i = 0; i < pActNum->GetLevelCount(); ++i ) { if ( nActNumLvl & nMask ) { @@ -3534,13 +3523,13 @@ IMPL_LINK( SvxNumPositionTabPage, IndentAtHdl_Impl, MetricField*, pFld ) IMPL_LINK( SvxNumPositionTabPage, StandardHdl_Impl, PushButton *, EMPTYARG ) { - USHORT nMask = 1; + sal_uInt16 nMask = 1; SvxNumRule aTmpNumRule( pActNum->GetFeatureFlags(), pActNum->GetLevelCount(), pActNum->IsContinuousNumbering(), SVX_RULETYPE_NUMBERING, pActNum->GetLevel( 0 ).GetPositionAndSpaceMode() ); - for(USHORT i = 0; i < pActNum->GetLevelCount(); i++) + for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++) { if(nActNumLvl & nMask) { @@ -3572,9 +3561,9 @@ IMPL_LINK( SvxNumPositionTabPage, StandardHdl_Impl, PushButton *, EMPTYARG ) return 0; } -void SvxNumPositionTabPage::SetModified(BOOL bRepaint) +void SvxNumPositionTabPage::SetModified(sal_Bool bRepaint) { - bModified = TRUE; + bModified = sal_True; if(bRepaint) { pPreviewWIN->SetLevel(nActNumLvl); @@ -3582,9 +3571,9 @@ void SvxNumPositionTabPage::SetModified(BOOL bRepaint) } } -void SvxNumOptionsTabPage::SetModified(BOOL bRepaint) +void SvxNumOptionsTabPage::SetModified(sal_Bool bRepaint) { - bModified = TRUE; + bModified = sal_True; if(bRepaint) { pPreviewWIN->SetLevel(nActNumLvl); diff --git a/cui/source/tabpages/numpages.src b/cui/source/tabpages/numpages.src index 323b5cdd6ba6..e66e3dc2dd98 100644 --- a/cui/source/tabpages/numpages.src +++ b/cui/source/tabpages/numpages.src @@ -128,6 +128,7 @@ TabPage RID_SVXPAGE_PICK_BMP }; CheckBox CB_LINKED { + HelpID = "cui:CheckBox:RID_SVXPAGE_PICK_BMP:CB_LINKED"; Pos = MAP_APPFONT ( 9 , 169 ) ; Size = MAP_APPFONT ( 100 , 10 ) ; TabStop = TRUE ; @@ -161,6 +162,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; MultiListBox LB_LEVEL { + HelpID = "cui:MultiListBox:RID_SVXPAGE_NUM_OPTIONS:LB_LEVEL"; Pos = MAP_APPFONT ( 12 , 25 ) ; Size = MAP_APPFONT ( 26 , 154 ) ; TabStop = TRUE ; @@ -182,6 +184,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; ListBox LB_FMT { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_OPTIONS:LB_FMT"; Pos = MAP_APPFONT ( 103 , 25 ) ; Size = MAP_APPFONT ( 67 , 72 ) ; TabStop = TRUE ; @@ -225,6 +228,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; Edit ED_PREFIX { + HelpID = "cui:Edit:RID_SVXPAGE_NUM_OPTIONS:ED_PREFIX"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 41 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; @@ -241,6 +245,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; Edit ED_SUFFIX { + HelpID = "cui:Edit:RID_SVXPAGE_NUM_OPTIONS:ED_SUFFIX"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 57 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; @@ -256,6 +261,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; ListBox LB_CHARFMT { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_OPTIONS:LB_CHARFMT"; TabStop = TRUE ; DropDown = TRUE ; Pos = MAP_APPFONT ( 103 , 73 ) ; @@ -270,6 +276,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; ListBox LB_BUL_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_OPTIONS:LB_BUL_COLOR"; TabStop = TRUE ; DropDown = TRUE ; Pos = MAP_APPFONT ( 103 , 73 ) ; @@ -285,6 +292,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; MetricField MF_BUL_REL_SIZE { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_OPTIONS:MF_BUL_REL_SIZE"; Pos = MAP_APPFONT ( 103 , 89 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; Border = TRUE ; @@ -307,6 +315,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; NumericField NF_ALL_LEVEL { + HelpID = "cui:NumericField:RID_SVXPAGE_NUM_OPTIONS:NF_ALL_LEVEL"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 89 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; @@ -329,6 +338,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; NumericField ED_START { + HelpID = "cui:NumericField:RID_SVXPAGE_NUM_OPTIONS:ED_START"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 105 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; @@ -351,6 +361,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; ListBox LB_ALIGN { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_OPTIONS:LB_ALIGN"; Pos = MAP_APPFONT ( 103 , 133 ) ; Size = MAP_APPFONT ( 40 , 40 ) ; TabStop = TRUE ; @@ -369,6 +380,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; PushButton PB_BULLET { + HelpID = "cui:PushButton:RID_SVXPAGE_NUM_OPTIONS:PB_BULLET"; Hide = TRUE ; Pos = MAP_APPFONT ( 103 , 105 ) ; Size = MAP_APPFONT ( 12 , 12 ) ; @@ -384,6 +396,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; MenuButton MB_BITMAP { + HelpID = "cui:MenuButton:RID_SVXPAGE_NUM_OPTIONS:MB_BITMAP"; Hide = TRUE ; Pos = MAP_APPFONT ( 103 , 41 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; @@ -416,6 +429,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; MetricField MF_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_OPTIONS:MF_WIDTH"; Pos = MAP_APPFONT ( 103 , 59 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; Border = TRUE ; @@ -442,6 +456,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; MetricField MF_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_OPTIONS:MF_HEIGHT"; Pos = MAP_APPFONT ( 103 , 75 ) ; Size = MAP_APPFONT ( 67 , 12 ) ; Border = TRUE ; @@ -461,6 +476,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; CheckBox CB_RATIO { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUM_OPTIONS:CB_RATIO"; Hide = TRUE ; Pos = MAP_APPFONT ( 50 , 91 ) ; Size = MAP_APPFONT ( 100 , 10 ) ; @@ -475,6 +491,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; ListBox LB_ORIENT { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_OPTIONS:LB_ORIENT"; Hide = TRUE ; Pos = MAP_APPFONT ( 103 , 103 ) ; Size = MAP_APPFONT ( 67 , 72 ) ; @@ -502,6 +519,7 @@ TabPage RID_SVXPAGE_NUM_OPTIONS }; CheckBox CB_SAME_LEVEL { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUM_OPTIONS:CB_SAME_LEVEL"; Pos = MAP_APPFONT ( 53 , 167 ) ; Size = MAP_APPFONT ( 114 , 10 ) ; Text [ en-US ] = "~Consecutive numbering" ; @@ -537,6 +555,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MultiListBox LB_LEVEL { + HelpID = "cui:MultiListBox:RID_SVXPAGE_NUM_POSITION:LB_LEVEL"; Pos = MAP_APPFONT ( 12 , 25 ) ; Size = MAP_APPFONT ( 26 , 154 ) ; TabStop = TRUE ; @@ -559,6 +578,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_BORDERDIST { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_BORDERDIST"; Pos = MAP_APPFONT ( 198 , 25 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Border = TRUE ; @@ -577,6 +597,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; CheckBox CB_RELATIVE { + HelpID = "cui:CheckBox:RID_SVXPAGE_NUM_POSITION:CB_RELATIVE"; Pos = MAP_APPFONT ( 198 , 41 ) ; Size = MAP_APPFONT ( 52 , 10 ) ; Text [ en-US ] = "Relati~ve" ; @@ -589,6 +610,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_INDENT { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_INDENT"; Pos = MAP_APPFONT ( 198 , 57 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Border = TRUE ; @@ -613,6 +635,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_NUMDIST { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_NUMDIST"; Pos = MAP_APPFONT ( 198 , 73 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Left = TRUE ; @@ -637,6 +660,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; ListBox LB_ALIGN { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_POSITION:LB_ALIGN"; Pos = MAP_APPFONT ( 198 , 89 ) ; Size = MAP_APPFONT ( 40 , 40 ) ; TabStop = TRUE ; @@ -656,6 +680,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; ListBox LB_LABEL_FOLLOWED_BY { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_POSITION:LB_LABEL_FOLLOWED_BY"; Pos = MAP_APPFONT ( 198 , 25 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; TabStop = TRUE ; @@ -676,6 +701,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_LISTTAB { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_LISTTAB"; Pos = MAP_APPFONT ( 198 , 41 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Border = TRUE ; @@ -699,6 +725,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; ListBox LB_ALIGN_2 { + HelpID = "cui:ListBox:RID_SVXPAGE_NUM_POSITION:LB_ALIGN_2"; Pos = MAP_APPFONT ( 198 , 57 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; TabStop = TRUE ; @@ -712,6 +739,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_ALIGNED_AT { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_ALIGNED_AT"; Pos = MAP_APPFONT ( 198 , 73 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Left = TRUE ; @@ -736,6 +764,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; MetricField MF_INDENT_AT { + HelpID = "cui:MetricField:RID_SVXPAGE_NUM_POSITION:MF_INDENT_AT"; Pos = MAP_APPFONT ( 198 , 89 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; Left = TRUE ; @@ -754,6 +783,7 @@ TabPage RID_SVXPAGE_NUM_POSITION }; PushButton PB_STANDARD { + HelpID = "cui:PushButton:RID_SVXPAGE_NUM_POSITION:PB_STANDARD"; Pos = MAP_APPFONT ( 198 , 165 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "Default" ; diff --git a/cui/source/tabpages/page.cxx b/cui/source/tabpages/page.cxx index 46d5da8355bb..aa5d75239b65 100644 --- a/cui/source/tabpages/page.cxx +++ b/cui/source/tabpages/page.cxx @@ -127,7 +127,7 @@ static const long MINBODY = 284; // 0,5cm in twips aufgerundet //static const long PRINT_OFFSET = 17; // 0,03cm in twips abgerundet static const long PRINT_OFFSET = 0; // why was this ever set to 17 ? it led to wrong right and bottom margins. -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_ATTR_BORDER_OUTER, SID_ATTR_BORDER_SHADOW, @@ -140,7 +140,7 @@ static USHORT pRanges[] = // ------- Mapping Seitenlayout ------------------------------------------ -USHORT aArr[] = +sal_uInt16 aArr[] = { SVX_PAGE_ALL, SVX_PAGE_MIRROR, @@ -150,9 +150,9 @@ USHORT aArr[] = // ----------------------------------------------------------------------- -USHORT PageUsageToPos_Impl( USHORT nUsage ) +sal_uInt16 PageUsageToPos_Impl( sal_uInt16 nUsage ) { - for ( USHORT i = 0; i < SAL_N_ELEMENTS(aArr); ++i ) + for ( sal_uInt16 i = 0; i < SAL_N_ELEMENTS(aArr); ++i ) if ( aArr[i] == ( nUsage & 0x000f ) ) return i; return SVX_PAGE_ALL; @@ -160,7 +160,7 @@ USHORT PageUsageToPos_Impl( USHORT nUsage ) // ----------------------------------------------------------------------- -USHORT PosToPageUsage_Impl( USHORT nPos ) +sal_uInt16 PosToPageUsage_Impl( sal_uInt16 nPos ) { if ( nPos >= SAL_N_ELEMENTS(aArr) ) return 0; @@ -186,7 +186,7 @@ long ConvertLong_Impl( const long nIn, SfxMapUnit eUnit ) return OutputDevice::LogicToLogic( nIn, (MapUnit)eUnit, MAP_TWIP ); } -BOOL IsEqualSize_Impl( const SvxSizeItem* pSize, const Size& rSize ) +sal_Bool IsEqualSize_Impl( const SvxSizeItem* pSize, const Size& rSize ) { if ( pSize ) { @@ -196,7 +196,7 @@ BOOL IsEqualSize_Impl( const SvxSizeItem* pSize, const Size& rSize ) return ( nDiffW < 10 && nDiffH < 10 ); } else - return FALSE; + return sal_False; } // ----------------------------------------------------------------------- @@ -224,7 +224,7 @@ struct SvxPage_Impl // gibt den Bereich der Which-Werte zur"uck -USHORT* SvxPageDescPage::GetRanges() +sal_uInt16* SvxPageDescPage::GetRanges() { return pRanges; } @@ -266,13 +266,12 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) : aTopMarginEdit ( this, CUI_RES( ED_TOP_MARGIN ) ), aBottomMarginLbl ( this, CUI_RES( FT_BOTTOM_MARGIN ) ), aBottomMarginEdit ( this, CUI_RES( ED_BOTTOM_MARGIN ) ), - + aBottomSeparatorFl ( this, CUI_RES( FL_BOTTOM_SEP ) ), aLayoutFL ( this, CUI_RES( FL_LAYOUT ) ), aPageText ( this, CUI_RES( FT_PAGELAYOUT ) ), aLayoutBox ( this, CUI_RES( LB_LAYOUT ) ), aNumberFormatText ( this, CUI_RES( FT_NUMBER_FORMAT ) ), aNumberFormatBox ( this, CUI_RES( LB_NUMBER_FORMAT ) ), - aBottomSeparatorFl ( this, CUI_RES( FL_BOTTOM_SEP ) ), aTblAlignFT ( this, CUI_RES( FT_TBL_ALIGN ) ), aHorzBox ( this, CUI_RES( CB_HORZ ) ), aVertBox ( this, CUI_RES( CB_VERT ) ), @@ -285,16 +284,16 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) : aOutsideText ( CUI_RES( STR_OUTSIDE ) ), aPrintRangeQueryText( CUI_RES( STR_QUERY_PRINTRANGE ) ), - bLandscape ( FALSE ), + bLandscape ( sal_False ), eMode ( SVX_PAGE_MODE_STANDARD ), ePaperStart ( PAPER_A3 ), ePaperEnd ( PAPER_ENV_DL ), pImpl ( new SvxPage_Impl ) { - bBorderModified = FALSE; + bBorderModified = sal_False; FreeResource(); - aBspWin.EnableRTL( FALSE ); + aBspWin.EnableRTL( sal_False ); // diese Page braucht ExchangeSupport SetExchangeSupport(); @@ -306,7 +305,7 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) : const SfxPoolItem* pItem; SfxObjectShell* pShell; - if(SFX_ITEM_SET == rAttr.GetItemState(SID_HTML_MODE, FALSE, &pItem) || + if(SFX_ITEM_SET == rAttr.GetItemState(SID_HTML_MODE, sal_False, &pItem) || ( 0 != (pShell = SfxObjectShell::Current()) && 0 != (pItem = pShell->GetItem(SID_HTML_MODE)))) bWeb = 0 != (((const SfxUInt16Item*)pItem)->GetValue() & HTMLMODE_ON); @@ -323,9 +322,10 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) : if( !bWeb ) { if( bCJK ) + { aTextFlowBox.InsertEntryValue( CUI_RESSTR( RID_SVXSTR_PAGEDIR_RTL_VERT ), FRMDIR_VERT_TOP_RIGHT ); -// if( ... ) // aTextFlowBox.InsertEntryValue( CUI_RESSTR( RID_SVXSTR_PAGEDIR_LTR_VERT ), FRMDIR_VERT_TOP_LEFT ); + } } // #109989# show the text direction box in Writer/Web too, but only, if HTML export mode is not HTML3.2. @@ -414,6 +414,9 @@ SvxPageDescPage::SvxPageDescPage( Window* pParent, const SfxItemSet& rAttr ) : aTopMarginEdit.SetLast(aDrawinglayerOpt.GetMaximumPaperTopMargin()); aBottomMarginEdit.SetMax(aDrawinglayerOpt.GetMaximumPaperBottomMargin()); aBottomMarginEdit.SetLast(aDrawinglayerOpt.GetMaximumPaperBottomMargin()); + + aPortraitBtn.SetAccessibleRelationMemberOf(&aOrientationFT); + aLandscapeBtn.SetAccessibleRelationMemberOf(&aOrientationFT); } // ----------------------------------------------------------------------- @@ -482,10 +485,10 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) const SvxLRSpaceItem& rLRSpace = (const SvxLRSpaceItem&)*pItem; SetMetricValue( aLeftMarginEdit, rLRSpace.GetLeft(), eUnit ); aBspWin.SetLeft( - (USHORT)ConvertLong_Impl( (long)rLRSpace.GetLeft(), eUnit ) ); + (sal_uInt16)ConvertLong_Impl( (long)rLRSpace.GetLeft(), eUnit ) ); SetMetricValue( aRightMarginEdit, rLRSpace.GetRight(), eUnit ); aBspWin.SetRight( - (USHORT)ConvertLong_Impl( (long)rLRSpace.GetRight(), eUnit ) ); + (sal_uInt16)ConvertLong_Impl( (long)rLRSpace.GetRight(), eUnit ) ); } // R"ander (Oben/Unten) einstellen @@ -496,16 +499,16 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) const SvxULSpaceItem& rULSpace = (const SvxULSpaceItem&)*pItem; SetMetricValue( aTopMarginEdit, rULSpace.GetUpper(), eUnit ); aBspWin.SetTop( - (USHORT)ConvertLong_Impl( (long)rULSpace.GetUpper(), eUnit ) ); + (sal_uInt16)ConvertLong_Impl( (long)rULSpace.GetUpper(), eUnit ) ); SetMetricValue( aBottomMarginEdit, rULSpace.GetLower(), eUnit ); aBspWin.SetBottom( - (USHORT)ConvertLong_Impl( (long)rULSpace.GetLower(), eUnit ) ); + (sal_uInt16)ConvertLong_Impl( (long)rULSpace.GetLower(), eUnit ) ); } // allgemeine Seitendaten SvxNumType eNumType = SVX_ARABIC; bLandscape = ( pImpl->mpDefPrinter->GetOrientation() == ORIENTATION_LANDSCAPE ); - USHORT nUse = (USHORT)SVX_PAGE_ALL; + sal_uInt16 nUse = (sal_uInt16)SVX_PAGE_ALL; pItem = GetItem( rSet, SID_ATTR_PAGE ); if ( pItem ) @@ -522,11 +525,11 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) LayoutHdl_Impl( 0 ); // Numerierungsart der Seitenvorlage einstellen - aNumberFormatBox.SelectEntryPos( sal::static_int_cast< USHORT >(eNumType) ); + aNumberFormatBox.SelectEntryPos( sal::static_int_cast< sal_uInt16 >(eNumType) ); // Aktueller Papierschacht aPaperTrayBox.Clear(); - BYTE nPaperBin = PAPERBIN_PRINTER_SETTINGS; + sal_uInt8 nPaperBin = PAPERBIN_PRINTER_SETTINGS; pItem = GetItem( rSet, SID_ATTR_PAGE_PAPERBIN ); if ( pItem ) @@ -542,10 +545,10 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) if ( PAPERBIN_PRINTER_SETTINGS == nPaperBin ) aBinName = EE_RESSTR( RID_SVXSTR_PAPERBIN_SETTINGS ); else - aBinName = pImpl->mpDefPrinter->GetPaperBinName( (USHORT)nPaperBin ); + aBinName = pImpl->mpDefPrinter->GetPaperBinName( (sal_uInt16)nPaperBin ); - USHORT nEntryPos = aPaperTrayBox.InsertEntry( aBinName ); - aPaperTrayBox.SetEntryData( nEntryPos, (void*)(ULONG)nPaperBin ); + sal_uInt16 nEntryPos = aPaperTrayBox.InsertEntry( aBinName ); + aPaperTrayBox.SetEntryData( nEntryPos, (void*)(sal_uLong)nPaperBin ); aPaperTrayBox.SelectEntry( aBinName ); // Size rausholen @@ -558,14 +561,14 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) bool bOrientationSupport = pImpl->mpDefPrinter->HasSupport( SUPPORT_SET_ORIENTATION ); #ifdef OS2 - // unter OS/2 wird bei HasSupport() immer TRUE returned + // unter OS/2 wird bei HasSupport() immer sal_True returned // aber nur als Dummy, deshalb FALSE - bOrientationSupport = FALSE; + bOrientationSupport = sal_False; #endif if ( !bOrientationSupport && aPaperSize.Width() > aPaperSize.Height() ) - bLandscape = TRUE; + bLandscape = sal_True; aLandscapeBtn.Check( bLandscape ); aPortraitBtn.Check( !bLandscape ); @@ -578,7 +581,7 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) Swap( aPaperSize ); // Actual Paper Format - Paper ePaper = SvxPaperInfo::GetSvxPaper( aPaperSize, MAP_100TH_MM, TRUE ); + Paper ePaper = SvxPaperInfo::GetSvxPaper( aPaperSize, MAP_100TH_MM, sal_True ); if ( PAPER_USER != ePaper ) aPaperSize = SvxPaperInfo::GetPaperSize( ePaper, MAP_100TH_MM ); @@ -591,8 +594,8 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) SetMetricValue( aPaperWidthEdit, aPaperSize.Width(), SFX_MAPUNIT_100TH_MM ); aPaperSizeBox.Clear(); - USHORT nActPos = LISTBOX_ENTRY_NOTFOUND; - USHORT nAryId = RID_SVXSTRARY_PAPERSIZE_STD; + sal_uInt16 nActPos = LISTBOX_ENTRY_NOTFOUND; + sal_uInt16 nAryId = RID_SVXSTRARY_PAPERSIZE_STD; if ( ePaperStart != PAPER_A3 ) nAryId = RID_SVXSTRARY_PAPERSIZE_DRAW; @@ -603,8 +606,8 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) { String aStr = aPaperAry.GetString(i); Paper eSize = (Paper)aPaperAry.GetValue(i); - USHORT nPos = aPaperSizeBox.InsertEntry( aStr ); - aPaperSizeBox.SetEntryData( nPos, (void*)(ULONG)eSize ); + sal_uInt16 nPos = aPaperSizeBox.InsertEntry( aStr ); + aPaperSizeBox.SetEntryData( nPos, (void*)(sal_uLong)eSize ); if ( eSize == ePaper ) nActPos = nPos; @@ -626,15 +629,15 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) // Horizontale Ausrichtung pItem = GetItem( rSet, SID_ATTR_PAGE_EXT1 ); aHorzBox.Check( pItem ? ( (const SfxBoolItem*)pItem )->GetValue() - : FALSE ); + : sal_False ); // Vertikale Ausrichtung pItem = GetItem( rSet, SID_ATTR_PAGE_EXT2 ); aVertBox.Check( pItem ? ( (const SfxBoolItem*)pItem )->GetValue() - : FALSE ); + : sal_False ); // Beispiel-Fenster auf Tabelle setzen - aBspWin.SetTable( TRUE ); + aBspWin.SetTable( sal_True ); aBspWin.SetHorz( aHorzBox.IsChecked() ); aBspWin.SetVert( aVertBox.IsChecked() ); @@ -647,7 +650,7 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) aAdaptBox.Show(); pItem = GetItem( rSet, SID_ATTR_PAGE_EXT1 ); aAdaptBox.Check( pItem ? - ( (const SfxBoolItem*)pItem )->GetValue() : FALSE ); + ( (const SfxBoolItem*)pItem )->GetValue() : sal_False ); //!!! hidden, weil von StarDraw nicht implementiert aLayoutBox.Hide(); @@ -668,8 +671,8 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) InitHeadFoot_Impl( rSet ); // R"ander auf Hoch/Quer updaten, dann Beispiel updaten - bBorderModified = FALSE; - SwapFirstValues_Impl( FALSE ); + bBorderModified = sal_False; + SwapFirstValues_Impl( sal_False ); UpdateExample_Impl(); // Alte Werte sichern @@ -707,7 +710,7 @@ void SvxPageDescPage::Reset( const SfxItemSet& rSet ) } SfxItemState eState = rSet.GetItemState( GetWhich( SID_ATTR_FRAMEDIRECTION ), - TRUE, &pItem ); + sal_True, &pItem ); if( SFX_ITEM_UNKNOWN != eState ) { sal_uInt32 nVal = SFX_ITEM_SET == eState @@ -729,13 +732,13 @@ void SvxPageDescPage::FillUserData() // ----------------------------------------------------------------------- -BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; const SfxItemSet& rOldSet = GetItemSet(); SfxItemPool* pPool = rOldSet.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); - USHORT nWhich = GetWhich( SID_ATTR_LRSPACE ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_LRSPACE ); SfxMapUnit eUnit = pPool->GetMetric( nWhich ); const SfxPoolItem* pOld = 0; @@ -748,14 +751,14 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( aLeftMarginEdit.GetText() != aLeftMarginEdit.GetSavedValue() ) { - aMargin.SetLeft( (USHORT)GetCoreValue( aLeftMarginEdit, eUnit ) ); - bModified |= TRUE; + aMargin.SetLeft( (sal_uInt16)GetCoreValue( aLeftMarginEdit, eUnit ) ); + bModified |= sal_True; } if ( aRightMarginEdit.GetText() != aRightMarginEdit.GetSavedValue() ) { - aMargin.SetRight( (USHORT)GetCoreValue( aRightMarginEdit, eUnit ) ); - bModified |= TRUE; + aMargin.SetRight( (sal_uInt16)GetCoreValue( aRightMarginEdit, eUnit ) ); + bModified |= sal_True; } // Linken und rechten Rand setzen @@ -766,21 +769,21 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || !( *(const SvxLRSpaceItem*)pOld == aMargin ) ) rSet.Put( aMargin ); else - bModified = FALSE; + bModified = sal_False; } - BOOL bMod = FALSE; + sal_Bool bMod = sal_False; if ( aTopMarginEdit.GetText() != aTopMarginEdit.GetSavedValue() ) { - aTopMargin.SetUpper( (USHORT)GetCoreValue( aTopMarginEdit, eUnit ) ); - bMod |= TRUE; + aTopMargin.SetUpper( (sal_uInt16)GetCoreValue( aTopMarginEdit, eUnit ) ); + bMod |= sal_True; } if ( aBottomMarginEdit.GetText() != aBottomMarginEdit.GetSavedValue() ) { - aTopMargin.SetLower( (USHORT)GetCoreValue( aBottomMarginEdit, eUnit ) ); - bMod |= TRUE; + aTopMargin.SetLower( (sal_uInt16)GetCoreValue( aBottomMarginEdit, eUnit ) ); + bMod |= sal_True; } // unteren oberen Rand setzen @@ -791,27 +794,27 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || !( *(const SvxULSpaceItem*)pOld == aTopMargin ) ) { - bModified |= TRUE; + bModified |= sal_True; rSet.Put( aTopMargin ); } } // Druckerschacht nWhich = GetWhich( SID_ATTR_PAGE_PAPERBIN ); - USHORT nPos = aPaperTrayBox.GetSelectEntryPos(); - USHORT nBin = (USHORT)(ULONG)aPaperTrayBox.GetEntryData( nPos ); + sal_uInt16 nPos = aPaperTrayBox.GetSelectEntryPos(); + sal_uInt16 nBin = (sal_uInt16)(sal_uLong)aPaperTrayBox.GetEntryData( nPos ); pOld = GetOldItem( rSet, SID_ATTR_PAGE_PAPERBIN ); if ( !pOld || ( (const SvxPaperBinItem*)pOld )->GetValue() != nBin ) { - rSet.Put( SvxPaperBinItem( nWhich, (BYTE)nBin ) ); - bModified |= TRUE; + rSet.Put( SvxPaperBinItem( nWhich, (sal_uInt8)nBin ) ); + bModified |= sal_True; } nPos = aPaperSizeBox.GetSelectEntryPos(); - Paper ePaper = (Paper)(ULONG)aPaperSizeBox.GetEntryData( nPos ); - const USHORT nOld = aPaperSizeBox.GetSavedValue(); - BOOL bChecked = aLandscapeBtn.IsChecked(); + Paper ePaper = (Paper)(sal_uLong)aPaperSizeBox.GetEntryData( nPos ); + const sal_uInt16 nOld = aPaperSizeBox.GetSavedValue(); + sal_Bool bChecked = aLandscapeBtn.IsChecked(); if ( PAPER_USER == ePaper ) { @@ -827,7 +830,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || ( (const SvxSizeItem*)pOld )->GetSize() != aSize ) { rSet.Put( SvxSizeItem( GetWhich(SID_ATTR_PAGE_SIZE), aSize ) ); - bModified |= TRUE; + bModified |= sal_True; } } } @@ -845,7 +848,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || ( (const SvxSizeItem*)pOld )->GetSize() != aSize ) { rSet.Put( SvxSizeItem( GetWhich(SID_ATTR_PAGE_SIZE), aSize ) ); - bModified |= TRUE; + bModified |= sal_True; } } } @@ -862,7 +865,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( bChecked != aLandscapeBtn.GetSavedValue() ) { aPage.SetLandscape(bChecked); - bMod |= TRUE; + bMod |= sal_True; } // Einstellen der Numerierungsart der Seite @@ -871,7 +874,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( nPos != aNumberFormatBox.GetSavedValue() ) { aPage.SetNumType( (SvxNumType)nPos ); - bMod |= TRUE; + bMod |= sal_True; } if ( bMod ) @@ -881,7 +884,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || !( *(const SvxPageItem*)pOld == aPage ) ) { rSet.Put( aPage ); - bModified |= TRUE; + bModified |= sal_True; } } else if ( SFX_ITEM_DEFAULT == rOldSet.GetItemState( nWhich ) ) @@ -900,7 +903,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) SfxBoolItem aHorz( GetWhich( SID_ATTR_PAGE_EXT1 ), aHorzBox.IsChecked() ); rSet.Put( aHorz ); - bModified |= TRUE; + bModified |= sal_True; } if ( aVertBox.IsChecked() != aVertBox.GetSavedValue() ) @@ -908,7 +911,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) SfxBoolItem aVert( GetWhich( SID_ATTR_PAGE_EXT2 ), aVertBox.IsChecked() ); rSet.Put( aVert ); - bModified |= TRUE; + bModified |= sal_True; } break; } @@ -918,7 +921,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) // immer putten, damit Draw das auswerten kann rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_PAGE_EXT1 ), aAdaptBox.IsChecked() ) ); - bModified |= TRUE; + bModified |= sal_True; break; } default: ;//prevent warning @@ -930,13 +933,13 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) { const SfxBoolItem& rRegItem = (const SfxBoolItem&)rOldSet.Get(SID_SWREGISTER_MODE); SfxBoolItem* pRegItem = (SfxBoolItem*)rRegItem.Clone(); - BOOL bCheck = aRegisterCB.IsChecked(); + sal_Bool bCheck = aRegisterCB.IsChecked(); pRegItem->SetValue(bCheck); rSet.Put(*pRegItem); - bModified |= TRUE; + bModified |= sal_True; if(bCheck) { - bModified |= TRUE; + bModified |= sal_True; rSet.Put(SfxStringItem(SID_SWREGISTER_COLLECTION, aRegisterLB.GetSelectEntry())); } @@ -947,7 +950,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) if( aTextFlowBox.IsVisible() && (eDirection != aTextFlowBox.GetSavedValue()) ) { rSet.Put( SvxFrameDirectionItem( eDirection, GetWhich( SID_ATTR_FRAMEDIRECTION ) ) ); - bModified = TRUE; + bModified = sal_True; } return bModified; @@ -958,7 +961,7 @@ BOOL SvxPageDescPage::FillItemSet( SfxItemSet& rSet ) IMPL_LINK( SvxPageDescPage, LayoutHdl_Impl, ListBox *, EMPTYARG ) { // innen au\sen umschalten - const USHORT nPos = PosToPageUsage_Impl( aLayoutBox.GetSelectEntryPos() ); + const sal_uInt16 nPos = PosToPageUsage_Impl( aLayoutBox.GetSelectEntryPos() ); if ( nPos == SVX_PAGE_MIRROR ) { @@ -990,16 +993,16 @@ IMPL_LINK( SvxPageDescPage, PaperBinHdl_Impl, ListBox *, EMPTYARG ) // Schacht-Box initialisieren String aOldName = aPaperTrayBox.GetSelectEntry(); - aPaperTrayBox.SetUpdateMode( FALSE ); + aPaperTrayBox.SetUpdateMode( sal_False ); aPaperTrayBox.Clear(); - USHORT nEntryPos = aPaperTrayBox.InsertEntry( + sal_uInt16 nEntryPos = aPaperTrayBox.InsertEntry( EE_RESSTR( RID_SVXSTR_PAPERBIN_SETTINGS ) ); aPaperTrayBox.SetEntryData( nEntryPos, - (void*)(ULONG)PAPERBIN_PRINTER_SETTINGS ); + (void*)(sal_uLong)PAPERBIN_PRINTER_SETTINGS ); String aPaperBin( EditResId( RID_SVXSTR_PAPERBIN ) ); - USHORT nBinCount = pImpl->mpDefPrinter->GetPaperBinCount(); + sal_uInt16 nBinCount = pImpl->mpDefPrinter->GetPaperBinCount(); - for ( USHORT i = 0; i < nBinCount; ++i ) + for ( sal_uInt16 i = 0; i < nBinCount; ++i ) { String aName = pImpl->mpDefPrinter->GetPaperBinName(i); @@ -1010,10 +1013,10 @@ IMPL_LINK( SvxPageDescPage, PaperBinHdl_Impl, ListBox *, EMPTYARG ) aName.Append( UniString::CreateFromInt32( i+1 ) ); } nEntryPos = aPaperTrayBox.InsertEntry( aName ); - aPaperTrayBox.SetEntryData( nEntryPos, (void*)(ULONG)i ); + aPaperTrayBox.SetEntryData( nEntryPos, (void*)(sal_uLong)i ); } aPaperTrayBox.SelectEntry( aOldName ); - aPaperTrayBox.SetUpdateMode( TRUE ); + aPaperTrayBox.SetUpdateMode( sal_True ); return 0; } @@ -1022,8 +1025,8 @@ IMPL_LINK( SvxPageDescPage, PaperBinHdl_Impl, ListBox *, EMPTYARG ) IMPL_LINK( SvxPageDescPage, PaperSizeSelect_Impl, ListBox *, pBox ) { - const USHORT nPos = pBox->GetSelectEntryPos(); - Paper ePaper = (Paper)(ULONG)aPaperSizeBox.GetEntryData( nPos ); + const sal_uInt16 nPos = pBox->GetSelectEntryPos(); + Paper ePaper = (Paper)(sal_uLong)aPaperSizeBox.GetEntryData( nPos ); if ( ePaper != PAPER_USER ) { @@ -1051,7 +1054,7 @@ IMPL_LINK( SvxPageDescPage, PaperSizeSelect_Impl, ListBox *, pBox ) { // Draw: bei Papierformat soll der Rand 1cm betragen long nTmp = 0; - BOOL bScreen = ( PAPER_SCREEN == ePaper ); + sal_Bool bScreen = ( PAPER_SCREEN == ePaper ); if ( !bScreen ) // bei Bildschirm keinen Rand @@ -1096,16 +1099,16 @@ IMPL_LINK( SvxPageDescPage, PaperSizeSelect_Impl, ListBox *, pBox ) IMPL_LINK( SvxPageDescPage, PaperSizeModify_Impl, Edit *, EMPTYARG ) { - USHORT nWhich = GetWhich( SID_ATTR_LRSPACE ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_LRSPACE ); SfxMapUnit eUnit = GetItemSet().GetPool()->GetMetric( nWhich ); Size aSize( GetCoreValue( aPaperWidthEdit, eUnit ), GetCoreValue( aPaperHeightEdit, eUnit ) ); - Paper ePaper = SvxPaperInfo::GetSvxPaper( aSize, (MapUnit)eUnit, TRUE ); - USHORT nEntryCount = aPaperSizeBox.GetEntryCount(); + Paper ePaper = SvxPaperInfo::GetSvxPaper( aSize, (MapUnit)eUnit, sal_True ); + sal_uInt16 nEntryCount = aPaperSizeBox.GetEntryCount(); - for ( USHORT i = 0; i < nEntryCount; ++i ) + for ( sal_uInt16 i = 0; i < nEntryCount; ++i ) { - Paper eTmp = (Paper)(ULONG)aPaperSizeBox.GetEntryData(i); + Paper eTmp = (Paper)(sal_uLong)aPaperSizeBox.GetEntryData(i); if ( eTmp == ePaper ) { @@ -1221,7 +1224,7 @@ void SvxPageDescPage::SwapFirstValues_Impl( bool bSet ) IMPL_LINK_INLINE_START( SvxPageDescPage, BorderModify_Impl, MetricField *, EMPTYARG ) { if ( !bBorderModified ) - bBorderModified = TRUE; + bBorderModified = sal_True; UpdateExample_Impl(); return 0; } @@ -1254,12 +1257,12 @@ void SvxPageDescPage::UpdateExample_Impl( bool bResetbackground ) void SvxPageDescPage::ResetBackground_Impl( const SfxItemSet& rSet ) { - USHORT nWhich = GetWhich( SID_ATTR_PAGE_HEADERSET ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_PAGE_HEADERSET ); - if ( rSet.GetItemState( nWhich, FALSE ) == SFX_ITEM_SET ) + if ( rSet.GetItemState( nWhich, sal_False ) == SFX_ITEM_SET ) { const SvxSetItem& rSetItem = - (const SvxSetItem&)rSet.Get( nWhich, FALSE ); + (const SvxSetItem&)rSet.Get( nWhich, sal_False ); const SfxItemSet& rTmpSet = rSetItem.GetItemSet(); const SfxBoolItem& rOn = (const SfxBoolItem&)rTmpSet.Get( GetWhich( SID_ATTR_PAGE_ON ) ); @@ -1287,10 +1290,10 @@ void SvxPageDescPage::ResetBackground_Impl( const SfxItemSet& rSet ) nWhich = GetWhich( SID_ATTR_PAGE_FOOTERSET ); - if ( rSet.GetItemState( nWhich, FALSE ) == SFX_ITEM_SET ) + if ( rSet.GetItemState( nWhich, sal_False ) == SFX_ITEM_SET ) { const SvxSetItem& rSetItem = - (const SvxSetItem&)rSet.Get( nWhich, FALSE ); + (const SvxSetItem&)rSet.Get( nWhich, sal_False ); const SfxItemSet& rTmpSet = rSetItem.GetItemSet(); const SfxBoolItem& rOn = (const SfxBoolItem&)rTmpSet.Get( GetWhich( SID_ATTR_PAGE_ON ) ); @@ -1354,7 +1357,7 @@ void SvxPageDescPage::InitHeadFoot_Impl( const SfxItemSet& rSet ) if ( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_PAGE_HEADERSET ), - FALSE, (const SfxPoolItem**)&pSetItem ) ) + sal_False, (const SfxPoolItem**)&pSetItem ) ) { const SfxItemSet& rHeaderSet = pSetItem->GetItemSet(); const SfxBoolItem& rHeaderOn = @@ -1373,13 +1376,13 @@ void SvxPageDescPage::InitHeadFoot_Impl( const SfxItemSet& rSet ) rHeaderSet.Get( GetWhich( SID_ATTR_LRSPACE ) ); aBspWin.SetHdLeft( rLR.GetLeft() ); aBspWin.SetHdRight( rLR.GetRight() ); - aBspWin.SetHeader( TRUE ); + aBspWin.SetHeader( sal_True ); } else - aBspWin.SetHeader( FALSE ); + aBspWin.SetHeader( sal_False ); // im Beispiel Hintergrund und Umrandung anzeigen - USHORT nWhich = GetWhich( SID_ATTR_BRUSH ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_BRUSH ); if ( rHeaderSet.GetItemState( nWhich ) >= SFX_ITEM_AVAILABLE ) { @@ -1401,7 +1404,7 @@ void SvxPageDescPage::InitHeadFoot_Impl( const SfxItemSet& rSet ) if ( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_PAGE_FOOTERSET ), - FALSE, (const SfxPoolItem**)&pSetItem ) ) + sal_False, (const SfxPoolItem**)&pSetItem ) ) { const SfxItemSet& rFooterSet = pSetItem->GetItemSet(); const SfxBoolItem& rFooterOn = @@ -1420,13 +1423,13 @@ void SvxPageDescPage::InitHeadFoot_Impl( const SfxItemSet& rSet ) rFooterSet.Get( GetWhich( SID_ATTR_LRSPACE ) ); aBspWin.SetFtLeft( rLR.GetLeft() ); aBspWin.SetFtRight( rLR.GetRight() ); - aBspWin.SetFooter( TRUE ); + aBspWin.SetFooter( sal_True ); } else - aBspWin.SetFooter( FALSE ); + aBspWin.SetFooter( sal_False ); // im Beispiel Hintergrund und Umrandung anzeigen - USHORT nWhich = GetWhich( SID_ATTR_BRUSH ); + sal_uInt16 nWhich = GetWhich( SID_ATTR_BRUSH ); if ( rFooterSet.GetItemState( nWhich ) >= SFX_ITEM_AVAILABLE ) { @@ -1461,8 +1464,8 @@ int SvxPageDescPage::DeactivatePage( SfxItemSet* _pSet ) // Abfrage, ob die Seitenr"ander ausserhalb des Druckbereichs liegen // Wenn nicht, dann den Anwender fragen, ob sie "ubernommen werden sollen. // Wenn nicht, dann auf der TabPage bleiben. - USHORT nPos = aPaperSizeBox.GetSelectEntryPos(); - Paper ePaper = (Paper)(ULONG)aPaperSizeBox.GetEntryData( nPos ); + sal_uInt16 nPos = aPaperSizeBox.GetSelectEntryPos(); + Paper ePaper = (Paper)(sal_uLong)aPaperSizeBox.GetEntryData( nPos ); if ( ePaper != PAPER_SCREEN && IsMarginOutOfRange() ) { @@ -1494,7 +1497,7 @@ int SvxPageDescPage::DeactivatePage( SfxItemSet* _pSet ) FillItemSet( *_pSet ); // ggf. hoch/quer putten - USHORT nWh = GetWhich( SID_ATTR_PAGE_SIZE ); + sal_uInt16 nWh = GetWhich( SID_ATTR_PAGE_SIZE ); SfxMapUnit eUnit = GetItemSet().GetPool()->GetMetric( nWh ); Size aSize( GetCoreValue( aPaperWidthEdit, eUnit ), GetCoreValue( aPaperHeightEdit, eUnit ) ); @@ -1642,7 +1645,7 @@ IMPL_LINK_INLINE_END( SvxPageDescPage, CenterHdl_Impl, CheckBox *, EMPTYARG ) void SvxPageDescPage::SetCollectionList(const List* pList) { sStandardRegister = *(String*)pList->GetObject(0); - for( USHORT i = 1; i < pList->Count(); i++ ) + for( sal_uInt16 i = 1; i < pList->Count(); i++ ) { aRegisterLB.InsertEntry(*(String*)pList->GetObject(i)); } @@ -1657,10 +1660,10 @@ void SvxPageDescPage::SetCollectionList(const List* pList) IMPL_LINK( SvxPageDescPage, RegisterModify, CheckBox*, pBox ) { - BOOL bEnable = FALSE; + sal_Bool bEnable = sal_False; if(pBox->IsChecked()) { - bEnable = TRUE; + bEnable = sal_True; if(USHRT_MAX == aRegisterLB.GetSelectEntryPos()) aRegisterLB.SelectEntry(sStandardRegister); } diff --git a/cui/source/tabpages/page.h b/cui/source/tabpages/page.h index 733ef66a0aab..6d5821fdc5ea 100644 --- a/cui/source/tabpages/page.h +++ b/cui/source/tabpages/page.h @@ -30,6 +30,11 @@ // define ---------------------------------------------------------------- +//!! the values of the following defines must correspond to the array position +//!! of the respective paper size in the file i18npool/source/paper/paper.cxx +//!! There are enums for them in i18npool/inc/i18npool/paper.hxx but unfortunately +//!! the resource compiler does not understand enums, thus the enum values need +//!! to be duplicated here for use in the src file. #define PAPERSIZE_A0 0 #define PAPERSIZE_A1 1 #define PAPERSIZE_A2 2 @@ -67,6 +72,7 @@ #define PAPERSIZE_B4_JIS 34 #define PAPERSIZE_B5_JIS 35 #define PAPERSIZE_B6_JIS 36 +#define PAPERSIZE_A6 56 #endif diff --git a/cui/source/tabpages/page.src b/cui/source/tabpages/page.src index c96b43a5a966..2618b0b9389a 100644 --- a/cui/source/tabpages/page.src +++ b/cui/source/tabpages/page.src @@ -54,6 +54,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_PAPER_SIZE { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_PAPER_SIZE"; Pos = MAP_APPFONT ( 50 , 14 ) ; Size = MAP_APPFONT ( 50 , 64 ) ; DropDown = TRUE ; @@ -68,6 +69,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_PAPER_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_PAPER_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 50, 30 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -89,6 +91,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_PAPER_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_PAPER_HEIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 50 , 46 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -109,6 +112,7 @@ TabPage RID_SVXPAGE_PAGE }; RadioButton RB_PORTRAIT { + HelpID = "cui:RadioButton:RID_SVXPAGE_PAGE:RB_PORTRAIT"; Pos = MAP_APPFONT ( 50 , 62 ) ; Size = MAP_APPFONT ( 53 , 10 ) ; Check = TRUE ; @@ -116,6 +120,7 @@ TabPage RID_SVXPAGE_PAGE }; RadioButton RB_LANDSCAPE { + HelpID = "cui:RadioButton:RID_SVXPAGE_PAGE:RB_LANDSCAPE"; Pos = MAP_APPFONT ( 50 , 74 ) ; Size = MAP_APPFONT ( 53 , 10 ) ; Text [ en-US ] = "L~andscape"; @@ -136,6 +141,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_TEXT_FLOW { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_TEXT_FLOW"; Border = TRUE ; Pos = MAP_APPFONT ( 165 , 58 ) ; Size = MAP_APPFONT ( 83 , 50 ) ; @@ -152,6 +158,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_PAPER_TRAY { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_PAPER_TRAY"; Pos = MAP_APPFONT ( 165 , 72 ) ; Size = MAP_APPFONT ( 83 , 50 ) ; DropDown = TRUE ; @@ -172,6 +179,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_LEFT_MARGIN { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_LEFT_MARGIN"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 101 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -193,6 +201,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_RIGHT_MARGIN { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_RIGHT_MARGIN"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 117 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -214,6 +223,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_TOP_MARGIN { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_TOP_MARGIN"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 133 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -235,6 +245,7 @@ TabPage RID_SVXPAGE_PAGE }; MetricField ED_BOTTOM_MARGIN { + HelpID = "cui:MetricField:RID_SVXPAGE_PAGE:ED_BOTTOM_MARGIN"; Border = TRUE ; Pos = MAP_APPFONT ( 55 , 149 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -267,6 +278,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_LAYOUT { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_LAYOUT"; Border = TRUE ; Pos = MAP_APPFONT ( 170, 101 ) ; Size = MAP_APPFONT ( 78 , 44 ) ; @@ -287,6 +299,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_NUMBER_FORMAT { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_NUMBER_FORMAT"; Border = TRUE ; Pos = MAP_APPFONT ( 170 , 117 ) ; Size = MAP_APPFONT ( 78 , 64 ) ; @@ -310,6 +323,7 @@ TabPage RID_SVXPAGE_PAGE }; CheckBox CB_HORZ { + HelpID = "cui:CheckBox:RID_SVXPAGE_PAGE:CB_HORZ"; Hide = TRUE ; Pos = MAP_APPFONT ( 175 , 133 ) ; Size = MAP_APPFONT ( 73 , 10 ) ; @@ -317,6 +331,7 @@ TabPage RID_SVXPAGE_PAGE }; CheckBox CB_VERT { + HelpID = "cui:CheckBox:RID_SVXPAGE_PAGE:CB_VERT"; Hide = TRUE ; Pos = MAP_APPFONT ( 175 , 147 ) ; Size = MAP_APPFONT ( 73 , 10 ) ; @@ -324,6 +339,7 @@ TabPage RID_SVXPAGE_PAGE }; CheckBox CB_ADAPT { + HelpID = "cui:CheckBox:RID_SVXPAGE_PAGE:CB_ADAPT"; Hide = TRUE ; Pos = MAP_APPFONT ( 113 , 133 ) ; Size = MAP_APPFONT ( 135 , 10 ) ; @@ -332,6 +348,7 @@ TabPage RID_SVXPAGE_PAGE /* Registerhaltigkeit (fuer SW) */ CheckBox CB_REGISTER { + HelpID = "cui:CheckBox:RID_SVXPAGE_PAGE:CB_REGISTER"; Pos = MAP_APPFONT ( 113 , 133 ) ; Size = MAP_APPFONT ( 135 , 10 ) ; Hide = TRUE ; @@ -346,6 +363,7 @@ TabPage RID_SVXPAGE_PAGE }; ListBox LB_REGISTER { + HelpID = "cui:ListBox:RID_SVXPAGE_PAGE:LB_REGISTER"; Pos = MAP_APPFONT ( 122 , 157 ) ; Size = MAP_APPFONT ( 126 , 50 ) ; DropDown = TRUE ; @@ -371,6 +389,7 @@ StringArray RID_SVXSTRARY_PAPERSIZE_STD { ItemList [ en-US ] = { + < "A6" ; PAPERSIZE_A6 ; > ; < "A5" ; PAPERSIZE_A5 ; > ; < "A4" ; PAPERSIZE_A4 ; > ; < "A3" ; PAPERSIZE_A3 ; > ; @@ -405,6 +424,7 @@ StringArray RID_SVXSTRARY_PAPERSIZE_DRAW { ItemList [ en-US ] = { + < "A6" ; PAPERSIZE_A6 ; > ; < "A5" ; PAPERSIZE_A5 ; > ; < "A4" ; PAPERSIZE_A4 ; > ; < "A3" ; PAPERSIZE_A3 ; > ; diff --git a/cui/source/tabpages/paragrph.cxx b/cui/source/tabpages/paragrph.cxx index afabe8b31d02..e0c26d5d42f5 100644 --- a/cui/source/tabpages/paragrph.cxx +++ b/cui/source/tabpages/paragrph.cxx @@ -64,7 +64,7 @@ // static ---------------------------------------------------------------- -static USHORT pStdRanges[] = +static sal_uInt16 pStdRanges[] = { SID_ATTR_PARA_LINESPACE, // 10033 SID_ATTR_PARA_LINESPACE, @@ -75,14 +75,14 @@ static USHORT pStdRanges[] = 0 }; -static USHORT pAlignRanges[] = +static sal_uInt16 pAlignRanges[] = { SID_ATTR_PARA_ADJUST, // 10027 SID_ATTR_PARA_ADJUST, 0 }; -static USHORT pExtRanges[] = +static sal_uInt16 pExtRanges[] = { SID_ATTR_PARA_PAGEBREAK, // 10037 - SID_ATTR_PARA_WIDOWS, // 10041 @@ -137,21 +137,21 @@ void SetLineSpace_Impl( SvxLineSpacingItem& rLineSpace, case LLINESPACE_PROP: rLineSpace.GetLineSpaceRule() = SVX_LINE_SPACE_AUTO; - rLineSpace.SetPropLineSpace( (BYTE)lValue ); + rLineSpace.SetPropLineSpace( (sal_uInt8)lValue ); break; case LLINESPACE_MIN: - rLineSpace.SetLineHeight( (USHORT)lValue ); + rLineSpace.SetLineHeight( (sal_uInt16)lValue ); rLineSpace.GetInterLineSpaceRule() = SVX_INTER_LINE_SPACE_OFF; break; case LLINESPACE_DURCH: rLineSpace.GetLineSpaceRule() = SVX_LINE_SPACE_AUTO; - rLineSpace.SetInterLineSpace( (USHORT)lValue ); + rLineSpace.SetInterLineSpace( (sal_uInt16)lValue ); break; case LLINESPACE_FIX: - rLineSpace.SetLineHeight((USHORT)lValue); + rLineSpace.SetLineHeight((sal_uInt16)lValue); rLineSpace.GetLineSpaceRule() = SVX_LINE_SPACE_FIX; rLineSpace.GetInterLineSpaceRule() = SVX_INTER_LINE_SPACE_OFF; break; @@ -159,12 +159,12 @@ void SetLineSpace_Impl( SvxLineSpacingItem& rLineSpace, } -USHORT GetHtmlMode_Impl(const SfxItemSet& rSet) +sal_uInt16 GetHtmlMode_Impl(const SfxItemSet& rSet) { - USHORT nHtmlMode = 0; + sal_uInt16 nHtmlMode = 0; const SfxPoolItem* pItem = 0; SfxObjectShell* pShell; - if(SFX_ITEM_SET == rSet.GetItemState(SID_HTML_MODE, FALSE, &pItem) || + if(SFX_ITEM_SET == rSet.GetItemState(SID_HTML_MODE, sal_False, &pItem) || ( 0 != (pShell = SfxObjectShell::Current()) && 0 != (pItem = pShell->GetItem(SID_HTML_MODE)))) { @@ -225,16 +225,16 @@ SfxTabPage* SvxStdParagraphTabPage::Create( Window* pParent, // ----------------------------------------------------------------------- -BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) +sal_Bool SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) { SfxItemState eState = SFX_ITEM_UNKNOWN; const SfxPoolItem* pOld = 0; SfxItemPool* pPool = rOutSet.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); - BOOL bModified = FALSE; - USHORT nWhich; - USHORT nPos = aLineDist.GetSelectEntryPos(); + sal_Bool bModified = sal_False; + sal_uInt16 nWhich; + sal_uInt16 nPos = aLineDist.GetSelectEntryPos(); if ( LISTBOX_ENTRY_NOTFOUND != nPos && ( nPos != aLineDist.GetSavedValue() || @@ -278,7 +278,7 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) SFX_ITEM_DONTCARE == eState ) { rOutSet.Put( aSpacing ); - bModified = TRUE; + bModified = sal_True; } } @@ -298,21 +298,21 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) if ( aTopDist.IsRelative() ) aMargin.SetUpper( rOldItem.GetUpper(), - (USHORT)aTopDist.GetValue() ); + (sal_uInt16)aTopDist.GetValue() ); else - aMargin.SetUpper( (USHORT)GetCoreValue( aTopDist, eUnit ) ); + aMargin.SetUpper( (sal_uInt16)GetCoreValue( aTopDist, eUnit ) ); if ( aBottomDist.IsRelative() ) aMargin.SetLower( rOldItem.GetLower(), - (USHORT)aBottomDist.GetValue() ); + (sal_uInt16)aBottomDist.GetValue() ); else - aMargin.SetLower( (USHORT)GetCoreValue( aBottomDist, eUnit ) ); + aMargin.SetLower( (sal_uInt16)GetCoreValue( aBottomDist, eUnit ) ); } else { - aMargin.SetUpper( (USHORT)GetCoreValue( aTopDist, eUnit ) ); - aMargin.SetLower( (USHORT)GetCoreValue( aBottomDist, eUnit ) ); + aMargin.SetUpper( (sal_uInt16)GetCoreValue( aTopDist, eUnit ) ); + aMargin.SetLower( (sal_uInt16)GetCoreValue( aBottomDist, eUnit ) ); } eState = GetItemSet().GetItemState( nWhich ); @@ -320,7 +320,7 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) SFX_ITEM_DONTCARE == eState ) { rOutSet.Put( aMargin ); - bModified = TRUE; + bModified = sal_True; } } bool bNullTab = false; @@ -344,29 +344,29 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) if ( aLeftIndent.IsRelative() ) aMargin.SetTxtLeft( rOldItem.GetTxtLeft(), - (USHORT)aLeftIndent.GetValue() ); + (sal_uInt16)aLeftIndent.GetValue() ); else aMargin.SetTxtLeft( GetCoreValue( aLeftIndent, eUnit ) ); if ( aRightIndent.IsRelative() ) aMargin.SetRight( rOldItem.GetRight(), - (USHORT)aRightIndent.GetValue() ); + (sal_uInt16)aRightIndent.GetValue() ); else aMargin.SetRight( GetCoreValue( aRightIndent, eUnit ) ); if ( aFLineIndent.IsRelative() ) aMargin.SetTxtFirstLineOfst( rOldItem.GetTxtFirstLineOfst(), - (USHORT)aFLineIndent.GetValue() ); + (sal_uInt16)aFLineIndent.GetValue() ); else aMargin.SetTxtFirstLineOfst( - (USHORT)GetCoreValue( aFLineIndent, eUnit ) ); + (sal_uInt16)GetCoreValue( aFLineIndent, eUnit ) ); } else { aMargin.SetTxtLeft( GetCoreValue( aLeftIndent, eUnit ) ); aMargin.SetRight( GetCoreValue( aRightIndent, eUnit ) ); aMargin.SetTxtFirstLineOfst( - (USHORT)GetCoreValue( aFLineIndent, eUnit ) ); + (sal_uInt16)GetCoreValue( aFLineIndent, eUnit ) ); } aMargin.SetAutoFirst(aAutoCB.IsChecked()); if ( aMargin.GetTxtFirstLineOfst() < 0 ) @@ -377,7 +377,7 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) SFX_ITEM_DONTCARE == eState ) { rOutSet.Put( aMargin ); - bModified = TRUE; + bModified = sal_True; } } @@ -388,7 +388,7 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) { // negativer Erstzeileneinzug -> ggf. Null Default-Tabstop setzen - USHORT _nWhich = GetWhich( SID_ATTR_TABSTOP ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_TABSTOP ); const SfxItemSet& rInSet = GetItemSet(); if ( rInSet.GetItemState( _nWhich ) >= SFX_ITEM_AVAILABLE ) @@ -407,16 +407,16 @@ BOOL SvxStdParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) const SfxBoolItem* pBoolItem = (SfxBoolItem*)GetOldItem( rOutSet, SID_ATTR_PARA_REGISTER); SfxBoolItem* pRegItem = (SfxBoolItem*)pBoolItem->Clone(); - USHORT _nWhich = GetWhich( SID_ATTR_PARA_REGISTER ); - BOOL bSet = pRegItem->GetValue(); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_PARA_REGISTER ); + sal_Bool bSet = pRegItem->GetValue(); if(aRegisterCB.IsChecked() != bSet ) { pRegItem->SetValue(!bSet); rOutSet.Put(*pRegItem); - bModified = TRUE; + bModified = sal_True; } - else if ( SFX_ITEM_DEFAULT == GetItemSet().GetItemState( _nWhich, FALSE ) ) + else if ( SFX_ITEM_DEFAULT == GetItemSet().GetItemState( _nWhich, sal_False ) ) rOutSet.ClearItem(_nWhich); delete pRegItem; } @@ -435,7 +435,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) // Metrik einstellen FieldUnit eFUnit = GetModuleFieldUnit( rSet ); - BOOL bApplyCharUnit = GetApplyCharUnit( rSet ); + sal_Bool bApplyCharUnit = GetApplyCharUnit( rSet ); SvtCJKOptions aCJKOptions; if(aCJKOptions.IsAsianTypographyEnabled() && bApplyCharUnit ) @@ -457,7 +457,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) SetFieldUnit( aLineDistAtMetricBox, eFUnit ); } - USHORT _nWhich = GetWhich( SID_ATTR_LRSPACE ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_LRSPACE ); SfxItemState eItemState = rSet.GetItemState( _nWhich ); if ( eItemState >= SFX_ITEM_AVAILABLE ) @@ -471,7 +471,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rOldItem.GetPropLeft() != 100 ) { - aLeftIndent.SetRelative( TRUE ); + aLeftIndent.SetRelative( sal_True ); aLeftIndent.SetValue( rOldItem.GetPropLeft() ); } else @@ -483,7 +483,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rOldItem.GetPropRight() != 100 ) { - aRightIndent.SetRelative( TRUE ); + aRightIndent.SetRelative( sal_True ); aRightIndent.SetValue( rOldItem.GetPropRight() ); } else @@ -495,7 +495,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rOldItem.GetPropTxtFirstLineOfst() != 100 ) { - aFLineIndent.SetRelative( TRUE ); + aFLineIndent.SetRelative( sal_True ); aFLineIndent.SetValue( rOldItem.GetPropTxtFirstLineOfst() ); } else @@ -541,7 +541,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rOldItem.GetPropUpper() != 100 ) { - aTopDist.SetRelative( TRUE ); + aTopDist.SetRelative( sal_True ); aTopDist.SetValue( rOldItem.GetPropUpper() ); } else @@ -556,7 +556,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rOldItem.GetPropLower() != 100 ) { - aBottomDist.SetRelative( TRUE ); + aBottomDist.SetRelative( sal_True ); aBottomDist.SetValue( rOldItem.GetPropLower() ); } else @@ -598,7 +598,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( eItemState >= SFX_ITEM_AVAILABLE ) aRegisterCB.Check( ((const SfxBoolItem &)rSet.Get( _nWhich )).GetValue()); aRegisterCB.SaveValue(); - USHORT nHtmlMode = GetHtmlMode_Impl(rSet); + sal_uInt16 nHtmlMode = GetHtmlMode_Impl(rSet); if(nHtmlMode & HTMLMODE_ON) { aRegisterCB.Hide(); @@ -634,7 +634,7 @@ void SvxStdParagraphTabPage::EnableRelativeMode() aRightIndent.EnableRelativeMode( 0, 999 ); aTopDist.EnableRelativeMode( 0, 999 ); aBottomDist.EnableRelativeMode( 0, 999 ); - bRelativeMode = TRUE; + bRelativeMode = sal_True; } // ----------------------------------------------------------------------- @@ -655,6 +655,7 @@ SvxStdParagraphTabPage::SvxStdParagraphTabPage( Window* pParent, SfxTabPage( pParent, CUI_RES( RID_SVXPAGE_STD_PARAGRAPH ), rAttr ), + aIndentFrm ( this, CUI_RES( FL_INDENT ) ), aLeftLabel ( this, CUI_RES( FT_LEFTINDENT ) ), aLeftIndent ( this, CUI_RES( ED_LEFTINDENT ) ), aRightLabel ( this, CUI_RES( FT_RIGHTINDENT ) ), @@ -663,28 +664,28 @@ SvxStdParagraphTabPage::SvxStdParagraphTabPage( Window* pParent, aFLineLabel ( this, CUI_RES( FT_FLINEINDENT ) ), aFLineIndent ( this, CUI_RES( ED_FLINEINDENT ) ), aAutoCB ( this, CUI_RES( CB_AUTO ) ), - aIndentFrm ( this, CUI_RES( FL_INDENT ) ), + aDistFrm ( this, CUI_RES( FL_DIST ) ), aTopLabel ( this, CUI_RES( FT_TOPDIST ) ), aTopDist ( this, CUI_RES( ED_TOPDIST ) ), aBottomLabel ( this, CUI_RES( FT_BOTTOMDIST ) ), aBottomDist ( this, CUI_RES( ED_BOTTOMDIST ) ), - aDistFrm ( this, CUI_RES( FL_DIST ) ), + + aLineDistFrm ( this, CUI_RES( FL_LINEDIST ) ), aLineDist ( this, CUI_RES( LB_LINEDIST ) ), aLineDistAtLabel ( this, CUI_RES( FT_LINEDIST ) ), aLineDistAtPercentBox ( this, CUI_RES( ED_LINEDISTPERCENT ) ), aLineDistAtMetricBox ( this, CUI_RES( ED_LINEDISTMETRIC ) ), - aLineDistFrm ( this, CUI_RES( FL_LINEDIST ) ), sAbsDist ( CUI_RES(ST_LINEDIST_ABS) ), aExampleWin ( this, CUI_RES( WN_EXAMPLE ) ), - aRegisterCB ( this, CUI_RES( CB_REGISTER ) ), aRegisterFL ( this, CUI_RES( FL_REGISTER ) ), + aRegisterCB ( this, CUI_RES( CB_REGISTER ) ), pActLineDistFld ( &aLineDistAtPercentBox ), nAbst ( MAX_DURCH ), nWidth ( 11905 /*567 * 50*/ ), nMinFixDist(0L), - bRelativeMode ( FALSE ), - bNegativeIndents(FALSE) + bRelativeMode ( sal_False ), + bNegativeIndents(sal_False) { // diese Page braucht ExchangeSupport @@ -694,6 +695,9 @@ SvxStdParagraphTabPage::SvxStdParagraphTabPage( Window* pParent, FreeResource(); Init_Impl(); aFLineIndent.SetMin(-9999); // wird default auf 0 gesetzt + + aExampleWin.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + } @@ -705,12 +709,12 @@ void SvxStdParagraphTabPage::EnableNegativeMode() aRightIndent.SetMin(-9999); aRightIndent.EnableNegativeMode(); aLeftIndent.EnableNegativeMode(); - bNegativeIndents = TRUE; + bNegativeIndents = sal_True; } // ----------------------------------------------------------------------- -USHORT* SvxStdParagraphTabPage::GetRanges() +sal_uInt16* SvxStdParagraphTabPage::GetRanges() { return pStdRanges; } @@ -795,8 +799,8 @@ IMPL_LINK( SvxStdParagraphTabPage, LineDistHdl_Impl, ListBox *, pBox ) case LLINESPACE_1: case LLINESPACE_15: case LLINESPACE_2: - aLineDistAtLabel.Enable(FALSE); - pActLineDistFld->Enable(FALSE); + aLineDistAtLabel.Enable(sal_False); + pActLineDistFld->Enable(sal_False); pActLineDistFld->SetText( String() ); break; @@ -862,7 +866,7 @@ IMPL_LINK( SvxStdParagraphTabPage, LineDistHdl_Impl, ListBox *, pBox ) } break; } - UpdateExample_Impl( TRUE ); + UpdateExample_Impl( sal_True ); return 0; } @@ -908,7 +912,7 @@ void SvxStdParagraphTabPage::Init_Impl() // ----------------------------------------------------------------------- -void SvxStdParagraphTabPage::UpdateExample_Impl( BOOL bAll ) +void SvxStdParagraphTabPage::UpdateExample_Impl( sal_Bool bAll ) { aExampleWin.SetFirstLineOfst( (short)aFLineIndent.Denormalize( aFLineIndent.GetValue( FUNIT_TWIP ) ) ); @@ -917,13 +921,13 @@ void SvxStdParagraphTabPage::UpdateExample_Impl( BOOL bAll ) aExampleWin.SetRightMargin( static_cast<long>(aRightIndent.Denormalize( aRightIndent.GetValue( FUNIT_TWIP ) ) ) ); aExampleWin.SetUpper( - (USHORT)aTopDist.Denormalize( aTopDist.GetValue( FUNIT_TWIP ) ) ); + (sal_uInt16)aTopDist.Denormalize( aTopDist.GetValue( FUNIT_TWIP ) ) ); aExampleWin.SetLower( - (USHORT)aBottomDist.Denormalize( aBottomDist.GetValue( FUNIT_TWIP ) ) ); + (sal_uInt16)aBottomDist.Denormalize( aBottomDist.GetValue( FUNIT_TWIP ) ) ); - USHORT nPos = aLineDist.GetSelectEntryPos(); + sal_uInt16 nPos = aLineDist.GetSelectEntryPos(); switch ( nPos ) { @@ -935,7 +939,7 @@ void SvxStdParagraphTabPage::UpdateExample_Impl( BOOL bAll ) case LLINESPACE_PROP: aExampleWin.SetLineSpace( (SvxPrevLineSpace)nPos, - (USHORT)aLineDistAtPercentBox.Denormalize( + (sal_uInt16)aLineDistAtPercentBox.Denormalize( aLineDistAtPercentBox.GetValue() ) ); break; @@ -943,7 +947,7 @@ void SvxStdParagraphTabPage::UpdateExample_Impl( BOOL bAll ) case LLINESPACE_DURCH: case LLINESPACE_FIX: aExampleWin.SetLineSpace( (SvxPrevLineSpace)nPos, - (USHORT)GetCoreValue( aLineDistAtMetricBox, SFX_MAPUNIT_TWIP ) ); + (sal_uInt16)GetCoreValue( aLineDistAtMetricBox, SFX_MAPUNIT_TWIP ) ); break; } aExampleWin.Draw( bAll ); @@ -959,22 +963,17 @@ void SvxStdParagraphTabPage::EnableRegisterMode() IMPL_LINK( SvxStdParagraphTabPage, AutoHdl_Impl, CheckBox*, pBox ) { - BOOL bEnable = !pBox->IsChecked(); + sal_Bool bEnable = !pBox->IsChecked(); aFLineLabel .Enable(bEnable); aFLineIndent.Enable(bEnable); return 0; } -void SvxStdParagraphTabPage::SetPageWidth( USHORT nPageWidth ) +void SvxStdParagraphTabPage::SetPageWidth( sal_uInt16 nPageWidth ) { nWidth = nPageWidth; } -void SvxStdParagraphTabPage::SetMaxDistance( USHORT nMaxDist ) -{ - nAbst = nMaxDist; -} - void SvxStdParagraphTabPage::EnableAutoFirstLine() { @@ -1057,7 +1056,7 @@ SvxParaAlignTabPage::SvxParaAlignTabPage( Window* pParent, const SfxItemSet& rSe aTextDirectionLB ( this, CUI_RES( LB_TEXTDIRECTION )) { SvtLanguageOptions aLangOptions; - USHORT nLastLinePos = LASTLINEPOS_DEFAULT; + sal_uInt16 nLastLinePos = LASTLINEPOS_DEFAULT; if ( aLangOptions.IsAsianTypographyEnabled() ) { @@ -1087,7 +1086,7 @@ SvxParaAlignTabPage::SvxParaAlignTabPage( Window* pParent, const SfxItemSet& rSe aLastLineLB.SetSelectHdl( LINK( this, SvxParaAlignTabPage, LastLineHdl_Impl ) ); aTextDirectionLB.SetSelectHdl( LINK( this, SvxParaAlignTabPage, TextDirectionHdl_Impl ) ); - USHORT nHtmlMode = GetHtmlMode_Impl(rSet); + sal_uInt16 nHtmlMode = GetHtmlMode_Impl(rSet); if(!(nHtmlMode & HTMLMODE_ON) || (0 != (nHtmlMode & HTMLMODE_SOME_STYLES)) ) { if( aLangOptions.IsCTLFontEnabled() ) @@ -1101,6 +1100,9 @@ SvxParaAlignTabPage::SvxParaAlignTabPage( Window* pParent, const SfxItemSet& rSe aTextDirectionLB.Show(); } } + + aExampleWin.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + } SvxParaAlignTabPage::~SvxParaAlignTabPage() @@ -1119,15 +1121,15 @@ SfxTabPage* SvxParaAlignTabPage::Create( Window* pParent, const SfxItemSet& rSet return new SvxParaAlignTabPage(pParent, rSet); } -USHORT* SvxParaAlignTabPage::GetRanges() +sal_uInt16* SvxParaAlignTabPage::GetRanges() { return pAlignRanges; } -BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) +sal_Bool SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; bool bAdj = false, bChecked = false; SvxAdjust eAdjust = SVX_ADJUST_LEFT; @@ -1158,7 +1160,7 @@ BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) aLastLineLB.GetSelectEntryPos() != aLastLineLB.GetSavedValue(); bChecked = true; } - USHORT _nWhich = GetWhich( SID_ATTR_PARA_ADJUST ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_PARA_ADJUST ); if ( bAdj ) { @@ -1166,7 +1168,7 @@ BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) (const SvxAdjustItem*)GetOldItem( rOutSet, SID_ATTR_PARA_ADJUST ); SvxAdjust eOneWord = aExpandCB.IsChecked() ? SVX_ADJUST_BLOCK : SVX_ADJUST_LEFT; - USHORT nLBPos = aLastLineLB.GetSelectEntryPos(); + sal_uInt16 nLBPos = aLastLineLB.GetSelectEntryPos(); SvxAdjust eLastBlock = SVX_ADJUST_LEFT; if ( 1 == nLBPos ) @@ -1195,12 +1197,12 @@ BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) if(aSnapToGridCB.IsChecked() != aSnapToGridCB.GetSavedValue()) { rOutSet.Put(SvxParaGridItem(aSnapToGridCB.IsChecked(), GetWhich( SID_ATTR_PARA_SNAPTOGRID ))); - bModified = TRUE; + bModified = sal_True; } if(aVertAlignLB.GetSavedValue() != aVertAlignLB.GetSelectEntryPos()) { rOutSet.Put(SvxParaVertAlignItem(aVertAlignLB.GetSelectEntryPos(), GetWhich( SID_PARA_VERTALIGN ))); - bModified = TRUE; + bModified = sal_True; } if( aTextDirectionLB.IsVisible() ) @@ -1209,7 +1211,7 @@ BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) if( eDir != aTextDirectionLB.GetSavedValue() ) { rOutSet.Put( SvxFrameDirectionItem( eDir, GetWhich( SID_ATTR_FRAMEDIRECTION ) ) ); - bModified = TRUE; + bModified = sal_True; } } @@ -1218,10 +1220,10 @@ BOOL SvxParaAlignTabPage::FillItemSet( SfxItemSet& rOutSet ) void SvxParaAlignTabPage::Reset( const SfxItemSet& rSet ) { - USHORT _nWhich = GetWhich( SID_ATTR_PARA_ADJUST ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_PARA_ADJUST ); SfxItemState eItemState = rSet.GetItemState( _nWhich ); - USHORT nLBSelect = 0; + sal_uInt16 nLBSelect = 0; if ( eItemState >= SFX_ITEM_AVAILABLE ) { const SvxAdjustItem& rAdj = (const SvxAdjustItem&)rSet.Get( _nWhich ); @@ -1237,7 +1239,7 @@ void SvxParaAlignTabPage::Reset( const SfxItemSet& rSet ) case SVX_ADJUST_BLOCK: aJustify.Check(); break; default: ; //prevent warning } - BOOL bEnable = aJustify.IsChecked(); + sal_Bool bEnable = aJustify.IsChecked(); aLastLineFT.Enable(bEnable); aLastLineLB.Enable(bEnable); aExpandCB .Enable(bEnable); @@ -1255,14 +1257,14 @@ void SvxParaAlignTabPage::Reset( const SfxItemSet& rSet ) } else { - aLeft.Check( FALSE ); - aRight.Check( FALSE ); - aCenter.Check( FALSE ); - aJustify.Check( FALSE ); + aLeft.Check( sal_False ); + aRight.Check( sal_False ); + aCenter.Check( sal_False ); + aJustify.Check( sal_False ); } aLastLineLB.SelectEntryPos(nLBSelect); - USHORT nHtmlMode = GetHtmlMode_Impl(rSet); + sal_uInt16 nHtmlMode = GetHtmlMode_Impl(rSet); if(nHtmlMode & HTMLMODE_ON) { aLastLineLB.Hide(); @@ -1270,7 +1272,7 @@ void SvxParaAlignTabPage::Reset( const SfxItemSet& rSet ) aExpandCB.Hide(); if(!(nHtmlMode & (HTMLMODE_FULL_STYLES|HTMLMODE_FIRSTLINE)) ) aJustify.Disable(); - aSnapToGridCB.Show(FALSE); + aSnapToGridCB.Show(sal_False); } _nWhich = GetWhich(SID_ATTR_PARA_SNAPTOGRID); eItemState = rSet.GetItemState( _nWhich ); @@ -1311,22 +1313,22 @@ void SvxParaAlignTabPage::Reset( const SfxItemSet& rSet ) aLastLineLB.SaveValue(); aExpandCB.SaveValue(); - UpdateExample_Impl(TRUE); + UpdateExample_Impl(sal_True); } IMPL_LINK( SvxParaAlignTabPage, AlignHdl_Impl, RadioButton*, EMPTYARG ) { - BOOL bJustify = aJustify.IsChecked(); + sal_Bool bJustify = aJustify.IsChecked(); aLastLineFT.Enable(bJustify); aLastLineLB.Enable(bJustify); aExpandCB.Enable(bJustify); - UpdateExample_Impl(FALSE); + UpdateExample_Impl(sal_False); return 0; } IMPL_LINK( SvxParaAlignTabPage, LastLineHdl_Impl, ListBox*, EMPTYARG ) { - UpdateExample_Impl(FALSE); + UpdateExample_Impl(sal_False); return 0; } @@ -1336,8 +1338,8 @@ IMPL_LINK( SvxParaAlignTabPage, TextDirectionHdl_Impl, ListBox*, EMPTYARG ) switch ( eDir ) { // check the default alignment for this text direction - case FRMDIR_HORI_LEFT_TOP : aLeft.Check( TRUE ); break; - case FRMDIR_HORI_RIGHT_TOP : aRight.Check( TRUE ); break; + case FRMDIR_HORI_LEFT_TOP : aLeft.Check( sal_True ); break; + case FRMDIR_HORI_RIGHT_TOP : aRight.Check( sal_True ); break; case FRMDIR_ENVIRONMENT : /* do nothing */ break; default: { @@ -1348,7 +1350,7 @@ IMPL_LINK( SvxParaAlignTabPage, TextDirectionHdl_Impl, ListBox*, EMPTYARG ) return 0; } -void SvxParaAlignTabPage::UpdateExample_Impl( BOOL bAll ) +void SvxParaAlignTabPage::UpdateExample_Impl( sal_Bool bAll ) { if ( aLeft.IsChecked() ) aExampleWin.SetAdjust( SVX_ADJUST_LEFT ); @@ -1360,7 +1362,7 @@ void SvxParaAlignTabPage::UpdateExample_Impl( BOOL bAll ) { aExampleWin.SetAdjust( SVX_ADJUST_BLOCK ); SvxAdjust eLastBlock = SVX_ADJUST_LEFT; - USHORT nLBPos = aLastLineLB.GetSelectEntryPos(); + sal_uInt16 nLBPos = aLastLineLB.GetSelectEntryPos(); if(nLBPos == 1) eLastBlock = SVX_ADJUST_CENTER; else if(nLBPos == 2) @@ -1399,10 +1401,10 @@ SfxTabPage* SvxExtParagraphTabPage::Create( Window* pParent, // ----------------------------------------------------------------------- -BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) +sal_Bool SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) { - BOOL bModified = FALSE; - USHORT _nWhich = GetWhich( SID_ATTR_PARA_HYPHENZONE ); + sal_Bool bModified = sal_False; + sal_uInt16 _nWhich = GetWhich( SID_ATTR_PARA_HYPHENZONE ); const TriState eHyphenState = aHyphenBox.GetState(); const SfxPoolItem* pOld = GetOldItem( rOutSet, SID_ATTR_PARA_HYPHENZONE ); @@ -1417,31 +1419,31 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) if ( eHyphenState == STATE_CHECK ) { - aHyphen.GetMinLead() = (BYTE)aExtHyphenBeforeBox.GetValue(); - aHyphen.GetMinTrail() = (BYTE)aExtHyphenAfterBox.GetValue(); + aHyphen.GetMinLead() = (sal_uInt8)aExtHyphenBeforeBox.GetValue(); + aHyphen.GetMinTrail() = (sal_uInt8)aExtHyphenAfterBox.GetValue(); } - aHyphen.GetMaxHyphens() = (BYTE)aMaxHyphenEdit.GetValue(); + aHyphen.GetMaxHyphens() = (sal_uInt8)aMaxHyphenEdit.GetValue(); if ( !pOld || !( *(SvxHyphenZoneItem*)pOld == aHyphen ) || eHyphenState != aHyphenBox.GetSavedValue()) { rOutSet.Put( aHyphen ); - bModified = TRUE; + bModified = sal_True; } } if (aPagenumEdit.IsEnabled() && aPagenumEdit.IsValueModified()) { SfxUInt16Item aPageNum( SID_ATTR_PARA_PAGENUM, - (USHORT)aPagenumEdit.GetValue() ); + (sal_uInt16)aPagenumEdit.GetValue() ); pOld = GetOldItem( rOutSet, SID_ATTR_PARA_PAGENUM ); if ( !pOld || ( (const SfxUInt16Item*)pOld )->GetValue() != aPageNum.GetValue() ) { rOutSet.Put( aPageNum ); - bModified = TRUE; + bModified = sal_True; } } @@ -1465,8 +1467,8 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) if ( !pOld || ( (const SvxPageModelItem*)pOld )->GetValue() != sPage ) { - rOutSet.Put( SvxPageModelItem( sPage, FALSE, _nWhich ) ); - bModified = TRUE; + rOutSet.Put( SvxPageModelItem( sPage, sal_False, _nWhich ) ); + bModified = sal_True; } else bIsPageModel = false; @@ -1474,7 +1476,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) else if(STATE_CHECK == eState && aApplyCollBtn.IsEnabled()) bIsPageModel = true; else - rOutSet.Put( SvxPageModelItem( sPage, FALSE, _nWhich ) ); + rOutSet.Put( SvxPageModelItem( sPage, sal_False, _nWhich ) ); _nWhich = GetWhich( SID_ATTR_PARA_PAGEBREAK ); @@ -1484,7 +1486,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) else { eState = aPageBreakBox.GetState(); - SfxItemState eModelState = GetItemSet().GetItemState(SID_ATTR_PARA_MODEL, FALSE); + SfxItemState eModelState = GetItemSet().GetItemState(SID_ATTR_PARA_MODEL, sal_False); if ( (eModelState == SFX_ITEM_SET && STATE_CHECK == aPageBreakBox.GetState()) || eState != aPageBreakBox.GetSavedValue() || @@ -1499,7 +1501,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) { case STATE_CHECK: { - BOOL bBefore = aBreakPositionLB.GetSelectEntryPos() == 0; + sal_Bool bBefore = aBreakPositionLB.GetSelectEntryPos() == 0; if ( aBreakTypeLB.GetSelectEntryPos() == 0 ) { @@ -1528,7 +1530,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) if ( eState != aPageBreakBox.GetSavedValue() || !pOld || !( *(const SvxFmtBreakItem*)pOld == aBreak ) ) { - bModified = TRUE; + bModified = sal_True; rOutSet.Put( aBreak ); } } @@ -1547,7 +1549,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) ( eState == STATE_NOCHECK ) ) { rOutSet.Put( SvxFmtSplitItem( eState == STATE_NOCHECK, _nWhich ) ); - bModified = TRUE; + bModified = sal_True; } } @@ -1561,7 +1563,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) // hat sich der Status geaendert, muss immer geputtet werden rOutSet.Put( SvxFmtKeepItem( eState == STATE_CHECK, _nWhich ) ); - bModified = TRUE; + bModified = sal_True; } // Witwen und Waisen @@ -1572,13 +1574,13 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) aWidowRowNo.IsValueModified() ) { SvxWidowsItem rItem( eState == STATE_CHECK ? - (BYTE)aWidowRowNo.GetValue() : 0, _nWhich ); + (sal_uInt8)aWidowRowNo.GetValue() : 0, _nWhich ); pOld = GetOldItem( rOutSet, SID_ATTR_PARA_WIDOWS ); if ( eState != aWidowBox.GetSavedValue() || !pOld || !( *(const SvxWidowsItem*)pOld == rItem ) ) { rOutSet.Put( rItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -1589,7 +1591,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) aOrphanRowNo.IsValueModified() ) { SvxOrphansItem rItem( eState == STATE_CHECK ? - (BYTE)aOrphanRowNo.GetValue() : 0, _nWhich ); + (sal_uInt8)aOrphanRowNo.GetValue() : 0, _nWhich ); pOld = GetOldItem( rOutSet, SID_ATTR_PARA_ORPHANS ); if ( eState != aOrphanBox.GetSavedValue() || @@ -1597,7 +1599,7 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) !( *(const SvxOrphansItem*)pOld == rItem ) ) { rOutSet.Put( rItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -1608,16 +1610,16 @@ BOOL SvxExtParagraphTabPage::FillItemSet( SfxItemSet& rOutSet ) void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { - USHORT _nWhich = GetWhich( SID_ATTR_PARA_HYPHENZONE ); + sal_uInt16 _nWhich = GetWhich( SID_ATTR_PARA_HYPHENZONE ); SfxItemState eItemState = rSet.GetItemState( _nWhich ); - BOOL bItemAvailable = eItemState >= SFX_ITEM_AVAILABLE; - BOOL bIsHyphen = FALSE; + sal_Bool bItemAvailable = eItemState >= SFX_ITEM_AVAILABLE; + sal_Bool bIsHyphen = sal_False; if( !bHtmlMode && bItemAvailable ) { const SvxHyphenZoneItem& rHyphen = (const SvxHyphenZoneItem&)rSet.Get( _nWhich ); - aHyphenBox.EnableTriState( FALSE ); + aHyphenBox.EnableTriState( sal_False ); bIsHyphen = rHyphen.IsHyphen(); aHyphenBox.SetState( bIsHyphen ? STATE_CHECK : STATE_NOCHECK ); @@ -1630,7 +1632,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { aHyphenBox.SetState( STATE_DONTKNOW ); } - BOOL bEnable = bItemAvailable && bIsHyphen; + sal_Bool bEnable = bItemAvailable && bIsHyphen; aExtHyphenBeforeBox.Enable(bEnable); aExtHyphenAfterBox.Enable(bEnable); aBeforeText.Enable(bEnable); @@ -1642,7 +1644,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( rSet.GetItemState(_nWhich) >= SFX_ITEM_AVAILABLE ) { - const USHORT nPageNum = + const sal_uInt16 nPageNum = ( (const SfxUInt16Item&)rSet.Get( _nWhich ) ).GetValue(); aPagenumEdit.SetValue( nPageNum ); } @@ -1651,12 +1653,12 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { // zuerst PageModel behandeln _nWhich = GetWhich( SID_ATTR_PARA_MODEL ); - BOOL bIsPageModel = FALSE; + sal_Bool bIsPageModel = sal_False; eItemState = rSet.GetItemState( _nWhich ); if ( eItemState >= SFX_ITEM_SET ) { - aApplyCollBtn.EnableTriState( FALSE ); + aApplyCollBtn.EnableTriState( sal_False ); const SvxPageModelItem& rModel = (const SvxPageModelItem&)rSet.Get( _nWhich ); @@ -1667,10 +1669,10 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { aApplyCollBox.SelectEntry( aStr ); aApplyCollBtn.SetState( STATE_CHECK ); - bIsPageModel = TRUE; + bIsPageModel = sal_True; aPageBreakBox.Enable(); - aPageBreakBox.EnableTriState( FALSE ); + aPageBreakBox.EnableTriState( sal_False ); aBreakTypeFT.Enable(); aBreakTypeLB.Enable(); aBreakPositionFT.Enable(); @@ -1691,16 +1693,16 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) } else if ( SFX_ITEM_DONTCARE == eItemState ) { - aApplyCollBtn.EnableTriState( TRUE ); + aApplyCollBtn.EnableTriState( sal_True ); aApplyCollBtn.SetState( STATE_DONTKNOW ); aApplyCollBox.SetNoSelection(); } else { - aApplyCollBtn.Enable(FALSE); - aApplyCollBox.Enable(FALSE); - aPagenumEdit.Enable(FALSE); - aPagenumText.Enable(FALSE); + aApplyCollBtn.Enable(sal_False); + aApplyCollBox.Enable(sal_False); + aPagenumEdit.Enable(sal_False); + aPagenumText.Enable(sal_False); } if ( !bIsPageModel ) @@ -1718,7 +1720,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) // PageBreak nicht ueber CTRL-RETURN, // dann kann CheckBox frei gegeben werden aPageBreakBox.Enable(); - aPageBreakBox.EnableTriState( FALSE ); + aPageBreakBox.EnableTriState( sal_False ); aBreakTypeFT.Enable(); aBreakTypeLB.Enable(); aBreakPositionFT.Enable(); @@ -1726,7 +1728,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) aPageBreakBox.SetState( STATE_CHECK ); - BOOL _bEnable = eBreak != SVX_BREAK_NONE && + sal_Bool _bEnable = eBreak != SVX_BREAK_NONE && eBreak != SVX_BREAK_COLUMN_BEFORE && eBreak != SVX_BREAK_COLUMN_AFTER; aApplyCollBtn.Enable(_bEnable); @@ -1739,8 +1741,8 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( eBreak == SVX_BREAK_NONE ) aPageBreakBox.SetState( STATE_NOCHECK ); - USHORT nType = 0; // selection position in break type ListBox : Page - USHORT nPosition = 0; // selection position in break position ListBox : Before + sal_uInt16 nType = 0; // selection position in break type ListBox : Page + sal_uInt16 nPosition = 0; // selection position in break position ListBox : Before switch ( eBreak ) { case SVX_BREAK_PAGE_BEFORE: @@ -1764,11 +1766,11 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) aPageBreakBox.SetState( STATE_DONTKNOW ); else { - aPageBreakBox.Enable(FALSE); - aBreakTypeFT.Enable(FALSE); - aBreakTypeLB.Enable(FALSE); - aBreakPositionFT.Enable(FALSE); - aBreakPositionLB.Enable(FALSE); + aPageBreakBox.Enable(sal_False); + aBreakTypeFT.Enable(sal_False); + aBreakTypeLB.Enable(sal_False); + aBreakPositionFT.Enable(sal_False); + aBreakPositionLB.Enable(sal_False); } } @@ -1781,7 +1783,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) if ( eItemState >= SFX_ITEM_AVAILABLE ) { - aKeepParaBox.EnableTriState( FALSE ); + aKeepParaBox.EnableTriState( sal_False ); const SvxFmtKeepItem& rKeep = (const SvxFmtKeepItem&)rSet.Get( _nWhich ); @@ -1793,7 +1795,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) else if ( SFX_ITEM_DONTCARE == eItemState ) aKeepParaBox.SetState( STATE_DONTKNOW ); else - aKeepParaBox.Enable(FALSE); + aKeepParaBox.Enable(sal_False); _nWhich = GetWhich( SID_ATTR_PARA_SPLIT ); eItemState = rSet.GetItemState( _nWhich ); @@ -1802,7 +1804,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { const SvxFmtSplitItem& rSplit = (const SvxFmtSplitItem&)rSet.Get( _nWhich ); - aKeepTogetherBox.EnableTriState( FALSE ); + aKeepTogetherBox.EnableTriState( sal_False ); if ( !rSplit.GetValue() ) aKeepTogetherBox.SetState( STATE_CHECK ); @@ -1819,10 +1821,10 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { const SvxWidowsItem& rWidow = (const SvxWidowsItem&)rSet.Get( _nWhich ); - aWidowBox.EnableTriState( FALSE ); - const USHORT nLines = rWidow.GetValue(); + aWidowBox.EnableTriState( sal_False ); + const sal_uInt16 nLines = rWidow.GetValue(); - BOOL _bEnable = nLines > 0; + sal_Bool _bEnable = nLines > 0; aWidowRowNo.SetValue( aWidowRowNo.Normalize( nLines ) ); aWidowBox.SetState( _bEnable ? STATE_CHECK : STATE_NOCHECK); aWidowRowNo.Enable(_bEnable); @@ -1832,7 +1834,7 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) else if ( SFX_ITEM_DONTCARE == eTmpState ) aWidowBox.SetState( STATE_DONTKNOW ); else - aWidowBox.Enable(FALSE); + aWidowBox.Enable(sal_False); aOrphanBox.Enable(); _nWhich = GetWhich( SID_ATTR_PARA_ORPHANS ); @@ -1842,10 +1844,10 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) { const SvxOrphansItem& rOrphan = (const SvxOrphansItem&)rSet.Get( _nWhich ); - const USHORT nLines = rOrphan.GetValue(); - aOrphanBox.EnableTriState( FALSE ); + const sal_uInt16 nLines = rOrphan.GetValue(); + aOrphanBox.EnableTriState( sal_False ); - BOOL _bEnable = nLines > 0; + sal_Bool _bEnable = nLines > 0; aOrphanBox.SetState( _bEnable ? STATE_CHECK : STATE_NOCHECK); aOrphanRowNo.SetValue( aOrphanRowNo.Normalize( nLines ) ); aOrphanRowNo.Enable(_bEnable); @@ -1855,13 +1857,13 @@ void SvxExtParagraphTabPage::Reset( const SfxItemSet& rSet ) else if ( SFX_ITEM_DONTCARE == eTmpState ) aOrphanBox.SetState( STATE_DONTKNOW ); else - aOrphanBox.Enable(FALSE); + aOrphanBox.Enable(sal_False); } } else if ( SFX_ITEM_DONTCARE == eItemState ) aKeepTogetherBox.SetState( STATE_DONTKNOW ); else - aKeepTogetherBox.Enable(FALSE); + aKeepTogetherBox.Enable(sal_False); // damit alles richt enabled wird KeepTogetherHdl_Impl( 0 ); @@ -1897,14 +1899,14 @@ int SvxExtParagraphTabPage::DeactivatePage( SfxItemSet* _pSet ) void SvxExtParagraphTabPage::DisablePageBreak() { - bPageBreak = FALSE; - aPageBreakBox.Enable(FALSE); + bPageBreak = sal_False; + aPageBreakBox.Enable(sal_False); aBreakTypeLB.RemoveEntry(0); - aBreakPositionFT.Enable(FALSE); - aBreakPositionLB.Enable(FALSE); - aApplyCollBtn.Enable(FALSE); - aApplyCollBox.Enable(FALSE); - aPagenumEdit.Enable(FALSE); + aBreakPositionFT.Enable(sal_False); + aBreakPositionLB.Enable(sal_False); + aApplyCollBtn.Enable(sal_False); + aApplyCollBox.Enable(sal_False); + aPagenumEdit.Enable(sal_False); } // ----------------------------------------------------------------------- @@ -1913,6 +1915,7 @@ SvxExtParagraphTabPage::SvxExtParagraphTabPage( Window* pParent, const SfxItemSe SfxTabPage( pParent, CUI_RES( RID_SVXPAGE_EXT_PARAGRAPH ), rAttr ), + aExtFL ( this, CUI_RES( FL_HYPHEN ) ), aHyphenBox ( this, CUI_RES( BTN_HYPHEN ) ), aBeforeText ( this, CUI_RES( FT_HYPHENBEFORE ) ), aExtHyphenBeforeBox ( this, CUI_RES( ED_HYPHENBEFORE ) ), @@ -1920,7 +1923,6 @@ SvxExtParagraphTabPage::SvxExtParagraphTabPage( Window* pParent, const SfxItemSe aExtHyphenAfterBox ( this, CUI_RES( ED_HYPHENAFTER ) ), aMaxHyphenLabel ( this, CUI_RES( FT_MAXHYPH ) ), aMaxHyphenEdit ( this, CUI_RES( ED_MAXHYPH ) ), - aExtFL ( this, CUI_RES( FL_HYPHEN ) ), aBreaksFL ( this, CUI_RES( FL_BREAKS ) ), aPageBreakBox ( this, CUI_RES( BTN_PAGEBREAK ) ), aBreakTypeFT ( this, CUI_RES( FT_BREAKTYPE )), @@ -1940,12 +1942,17 @@ SvxExtParagraphTabPage::SvxExtParagraphTabPage( Window* pParent, const SfxItemSe aWidowBox ( this, CUI_RES( BTN_WIDOWS ) ), aWidowRowNo ( this, CUI_RES( ED_WIDOWS ) ), aWidowRowLabel ( this, CUI_RES( FT_WIDOWS ) ), - bPageBreak ( TRUE ), - bHtmlMode ( FALSE ), + bPageBreak ( sal_True ), + bHtmlMode ( sal_False ), nStdPos ( 0 ) { FreeResource(); + aApplyCollBox.SetAccessibleRelationLabeledBy(&aApplyCollBtn); + aApplyCollBox.SetAccessibleName(String(CUI_RES(STR_PAGE_STYLE))); + aOrphanRowNo.SetAccessibleRelationLabeledBy(&aOrphanBox); + aWidowRowNo.SetAccessibleRelationLabeledBy(&aWidowBox); + // diese Page braucht ExchangeSupport SetExchangeSupport(); @@ -1977,20 +1984,20 @@ SvxExtParagraphTabPage::SvxExtParagraphTabPage( Window* pParent, const SfxItemSe nStdPos = aApplyCollBox.GetEntryPos( aStdName ); } - USHORT nHtmlMode = GetHtmlMode_Impl( rAttr ); + sal_uInt16 nHtmlMode = GetHtmlMode_Impl( rAttr ); if ( nHtmlMode & HTMLMODE_ON ) { - bHtmlMode = TRUE; - aHyphenBox .Enable(FALSE); - aBeforeText .Enable(FALSE); - aExtHyphenBeforeBox .Enable(FALSE); - aAfterText .Enable(FALSE); - aExtHyphenAfterBox .Enable(FALSE); - aMaxHyphenLabel .Enable(FALSE); - aMaxHyphenEdit .Enable(FALSE); - aExtFL .Enable(FALSE); - aPagenumText .Enable(FALSE); - aPagenumEdit .Enable(FALSE); + bHtmlMode = sal_True; + aHyphenBox .Enable(sal_False); + aBeforeText .Enable(sal_False); + aExtHyphenBeforeBox .Enable(sal_False); + aAfterText .Enable(sal_False); + aExtHyphenAfterBox .Enable(sal_False); + aMaxHyphenLabel .Enable(sal_False); + aMaxHyphenEdit .Enable(sal_False); + aExtFL .Enable(sal_False); + aPagenumText .Enable(sal_False); + aPagenumEdit .Enable(sal_False); // no column break in HTML aBreakTypeLB.RemoveEntry(1); } @@ -2004,7 +2011,7 @@ SvxExtParagraphTabPage::~SvxExtParagraphTabPage() // ----------------------------------------------------------------------- -USHORT* SvxExtParagraphTabPage::GetRanges() +sal_uInt16* SvxExtParagraphTabPage::GetRanges() { return pExtRanges; } @@ -2026,7 +2033,7 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakHdl_Impl, TriStateBox *, EMPTYARG ) { aApplyCollBtn.Enable(); - BOOL bEnable = STATE_CHECK == aApplyCollBtn.GetState() && + sal_Bool bEnable = STATE_CHECK == aApplyCollBtn.GetState() && aApplyCollBox.GetEntryCount(); aApplyCollBox.Enable(bEnable); if(!bHtmlMode) @@ -2040,14 +2047,14 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakHdl_Impl, TriStateBox *, EMPTYARG ) case STATE_NOCHECK: case STATE_DONTKNOW: aApplyCollBtn.SetState( STATE_NOCHECK ); - aApplyCollBtn.Enable(FALSE); - aApplyCollBox.Enable(FALSE); - aPagenumText.Enable(FALSE); - aPagenumEdit.Enable(FALSE); - aBreakTypeFT.Enable(FALSE); - aBreakTypeLB.Enable(FALSE); - aBreakPositionFT.Enable(FALSE); - aBreakPositionLB.Enable(FALSE); + aApplyCollBtn.Enable(sal_False); + aApplyCollBox.Enable(sal_False); + aPagenumText.Enable(sal_False); + aPagenumEdit.Enable(sal_False); + aBreakTypeFT.Enable(sal_False); + aBreakTypeLB.Enable(sal_False); + aBreakPositionFT.Enable(sal_False); + aBreakPositionLB.Enable(sal_False); break; } return 0; @@ -2057,7 +2064,7 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakHdl_Impl, TriStateBox *, EMPTYARG ) IMPL_LINK( SvxExtParagraphTabPage, KeepTogetherHdl_Impl, TriStateBox *, EMPTYARG ) { - BOOL bEnable = aKeepTogetherBox.GetState() == STATE_NOCHECK; + sal_Bool bEnable = aKeepTogetherBox.GetState() == STATE_NOCHECK; aWidowBox.Enable(bEnable); aOrphanBox.Enable(bEnable); @@ -2073,7 +2080,7 @@ IMPL_LINK( SvxExtParagraphTabPage, WidowHdl_Impl, TriStateBox *, EMPTYARG ) case STATE_CHECK: aWidowRowNo.Enable(); aWidowRowLabel.Enable(); - aKeepTogetherBox.Enable(FALSE); + aKeepTogetherBox.Enable(sal_False); break; case STATE_NOCHECK: @@ -2082,8 +2089,8 @@ IMPL_LINK( SvxExtParagraphTabPage, WidowHdl_Impl, TriStateBox *, EMPTYARG ) // kein break case STATE_DONTKNOW: - aWidowRowNo.Enable(FALSE); - aWidowRowLabel.Enable(FALSE); + aWidowRowNo.Enable(sal_False); + aWidowRowLabel.Enable(sal_False); break; } return 0; @@ -2098,7 +2105,7 @@ IMPL_LINK( SvxExtParagraphTabPage, OrphanHdl_Impl, TriStateBox *, EMPTYARG ) case STATE_CHECK: aOrphanRowNo.Enable(); aOrphanRowLabel.Enable(); - aKeepTogetherBox.Enable(FALSE); + aKeepTogetherBox.Enable(sal_False); break; case STATE_NOCHECK: @@ -2107,8 +2114,8 @@ IMPL_LINK( SvxExtParagraphTabPage, OrphanHdl_Impl, TriStateBox *, EMPTYARG ) // kein break case STATE_DONTKNOW: - aOrphanRowNo.Enable(FALSE); - aOrphanRowLabel.Enable(FALSE); + aOrphanRowNo.Enable(sal_False); + aOrphanRowLabel.Enable(sal_False); break; } return 0; @@ -2119,7 +2126,7 @@ IMPL_LINK( SvxExtParagraphTabPage, OrphanHdl_Impl, TriStateBox *, EMPTYARG ) IMPL_LINK( SvxExtParagraphTabPage, HyphenClickHdl_Impl, TriStateBox *, EMPTYARG ) { - BOOL bEnable = aHyphenBox.GetState() == STATE_CHECK; + sal_Bool bEnable = aHyphenBox.GetState() == STATE_CHECK; aBeforeText.Enable(bEnable); aExtHyphenBeforeBox.Enable(bEnable); aAfterText.Enable(bEnable); @@ -2135,11 +2142,11 @@ IMPL_LINK( SvxExtParagraphTabPage, HyphenClickHdl_Impl, TriStateBox *, EMPTYARG IMPL_LINK( SvxExtParagraphTabPage, ApplyCollClickHdl_Impl, TriStateBox *, EMPTYARG ) { - BOOL bEnable = FALSE; + sal_Bool bEnable = sal_False; if ( aApplyCollBtn.GetState() == STATE_CHECK && aApplyCollBox.GetEntryCount() ) { - bEnable = TRUE; + bEnable = sal_True; aApplyCollBox.SelectEntryPos( nStdPos ); } else @@ -2163,7 +2170,7 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakPosHdl_Impl, ListBox *, pListBox ) { aApplyCollBtn.Enable(); - BOOL bEnable = aApplyCollBtn.GetState() == STATE_CHECK && + sal_Bool bEnable = aApplyCollBtn.GetState() == STATE_CHECK && aApplyCollBox.GetEntryCount(); aApplyCollBox.Enable(bEnable); @@ -2176,10 +2183,10 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakPosHdl_Impl, ListBox *, pListBox ) else if ( 1 == pListBox->GetSelectEntryPos() ) { aApplyCollBtn.SetState( STATE_NOCHECK ); - aApplyCollBtn.Enable(FALSE); - aApplyCollBox.Enable(FALSE); - aPagenumText.Enable(FALSE); - aPagenumEdit.Enable(FALSE); + aApplyCollBtn.Enable(sal_False); + aApplyCollBox.Enable(sal_False); + aPagenumText.Enable(sal_False); + aPagenumEdit.Enable(sal_False); } return 0; } @@ -2189,14 +2196,14 @@ IMPL_LINK( SvxExtParagraphTabPage, PageBreakPosHdl_Impl, ListBox *, pListBox ) IMPL_LINK( SvxExtParagraphTabPage, PageBreakTypeHdl_Impl, ListBox *, pListBox ) { //column break or break break after - USHORT nBreakPos = aBreakPositionLB.GetSelectEntryPos(); + sal_uInt16 nBreakPos = aBreakPositionLB.GetSelectEntryPos(); if ( pListBox->GetSelectEntryPos() == 1 || 1 == nBreakPos) { aApplyCollBtn.SetState( STATE_NOCHECK ); - aApplyCollBtn.Enable(FALSE); - aApplyCollBox.Enable(FALSE); - aPagenumText.Enable(FALSE); - aPagenumEdit.Enable(FALSE); + aApplyCollBtn.Enable(sal_False); + aApplyCollBox.Enable(sal_False); + aPagenumText.Enable(sal_False); + aPagenumEdit.Enable(sal_False); } else PageBreakPosHdl_Impl( &aBreakPositionLB ); @@ -2242,9 +2249,9 @@ SfxTabPage* SvxAsianTabPage::Create( Window* pParent, const SfxItemSet& rSet return new SvxAsianTabPage(pParent, rSet); } -USHORT* SvxAsianTabPage::GetRanges() +sal_uInt16* SvxAsianTabPage::GetRanges() { - static USHORT pRanges[] = + static sal_uInt16 pRanges[] = { SID_ATTR_PARA_SCRIPTSPACE, SID_ATTR_PARA_FORBIDDEN_RULES, 0 @@ -2252,9 +2259,9 @@ USHORT* SvxAsianTabPage::GetRanges() return pRanges; } -BOOL SvxAsianTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxAsianTabPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; SfxItemPool* pPool = rSet.GetPool(); if(aScriptSpaceCB.IsChecked() != aScriptSpaceCB.GetSavedValue()) { @@ -2263,7 +2270,7 @@ BOOL SvxAsianTabPage::FillItemSet( SfxItemSet& rSet ) pNewItem->SetValue(aScriptSpaceCB.IsChecked()); rSet.Put(*pNewItem); delete pNewItem; - bRet = TRUE; + bRet = sal_True; } if(aHangingPunctCB.IsChecked() != aHangingPunctCB.GetSavedValue()) { @@ -2272,7 +2279,7 @@ BOOL SvxAsianTabPage::FillItemSet( SfxItemSet& rSet ) pNewItem->SetValue(aHangingPunctCB.IsChecked()); rSet.Put(*pNewItem); delete pNewItem; - bRet = TRUE; + bRet = sal_True; } if(aForbiddenRulesCB.IsChecked() != aForbiddenRulesCB.GetSavedValue()) { @@ -2281,20 +2288,20 @@ BOOL SvxAsianTabPage::FillItemSet( SfxItemSet& rSet ) pNewItem->SetValue(aForbiddenRulesCB.IsChecked()); rSet.Put(*pNewItem); delete pNewItem; - bRet = TRUE; + bRet = sal_True; } return bRet; } -void lcl_SetBox(const SfxItemSet& rSet, USHORT nSlotId, TriStateBox& rBox) +void lcl_SetBox(const SfxItemSet& rSet, sal_uInt16 nSlotId, TriStateBox& rBox) { - USHORT _nWhich = rSet.GetPool()->GetWhich(nSlotId); - SfxItemState eState = rSet.GetItemState(_nWhich, TRUE); + sal_uInt16 _nWhich = rSet.GetPool()->GetWhich(nSlotId); + SfxItemState eState = rSet.GetItemState(_nWhich, sal_True); if(!eState || eState == SFX_ITEM_DISABLED ) - rBox.Enable(FALSE); + rBox.Enable(sal_False); else if(eState >= SFX_ITEM_AVAILABLE) { - rBox.EnableTriState( FALSE ); + rBox.EnableTriState( sal_False ); rBox.Check(((const SfxBoolItem&)rSet.Get(_nWhich)).GetValue()); } else @@ -2314,7 +2321,7 @@ void SvxAsianTabPage::Reset( const SfxItemSet& rSet ) IMPL_LINK( SvxAsianTabPage, ClickHdl_Impl, TriStateBox*, pBox ) { - pBox->EnableTriState( FALSE ); + pBox->EnableTriState( sal_False ); return 0; } diff --git a/cui/source/tabpages/paragrph.hrc b/cui/source/tabpages/paragrph.hrc index 8a14407a9cd0..c6158a22ceda 100644 --- a/cui/source/tabpages/paragrph.hrc +++ b/cui/source/tabpages/paragrph.hrc @@ -117,5 +117,9 @@ #define CB_AS_SCRIPT_SPACE 7 +//IAccessibility2 Implementation 2009----- +#define STR_EXAMPLE 5010 +#define STR_PAGE_STYLE 5011 +//-----IAccessibility2 Implementation 2009 #endif diff --git a/cui/source/tabpages/paragrph.src b/cui/source/tabpages/paragrph.src index db0f85e035d6..b5659ca76f1c 100644 --- a/cui/source/tabpages/paragrph.src +++ b/cui/source/tabpages/paragrph.src @@ -46,6 +46,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_LEFTINDENT { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_LEFTINDENT"; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 14 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -68,6 +69,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_RIGHTINDENT { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_RIGHTINDENT"; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 30 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -90,6 +92,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_FLINEINDENT { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_FLINEINDENT"; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 46 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -107,6 +110,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; CheckBox CB_AUTO { + HelpID = "cui:CheckBox:RID_SVXPAGE_STD_PARAGRAPH:CB_AUTO"; Pos = MAP_APPFONT ( 12 , 61 ) ; Size = MAP_APPFONT ( 120 , 10 ) ; Hide = TRUE ; @@ -127,6 +131,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_TOPDIST { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_TOPDIST"; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 88 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -149,6 +154,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_BOTTOMDIST { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_BOTTOMDIST"; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 104 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -170,6 +176,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; ListBox LB_LINEDIST { + HelpID = "cui:ListBox:RID_SVXPAGE_STD_PARAGRAPH:LB_LINEDIST"; Pos = MAP_APPFONT ( 12 , 133 ) ; Size = MAP_APPFONT ( 55 , 72 ) ; DropDown = TRUE ; @@ -197,6 +204,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_LINEDISTPERCENT { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_LINEDISTPERCENT"; Disable = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 135 , 133 ) ; @@ -216,6 +224,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; MetricField ED_LINEDISTMETRIC { + HelpID = "cui:MetricField:RID_SVXPAGE_STD_PARAGRAPH:ED_LINEDISTMETRIC"; Disable = TRUE ; Border = TRUE ; Hide = TRUE ; @@ -245,6 +254,7 @@ TabPage RID_SVXPAGE_STD_PARAGRAPH }; CheckBox CB_REGISTER { + HelpID = "cui:CheckBox:RID_SVXPAGE_STD_PARAGRAPH:CB_REGISTER"; Pos = MAP_APPFONT ( 12 , 162 ) ; Size = MAP_APPFONT ( 120 , 10 ) ; Hide = TRUE ; @@ -275,6 +285,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; RadioButton BTN_LEFTALIGN { + HelpID = "cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_LEFTALIGN"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 161 , 10 ) ; Text [ en-US ] = "~Left" ; @@ -282,18 +293,21 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; RadioButton BTN_RIGHTALIGN { + HelpID = "cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_RIGHTALIGN"; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 161 , 10 ) ; Text [ en-US ] = "Righ~t" ; }; RadioButton BTN_CENTERALIGN { + HelpID = "cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_CENTERALIGN"; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 161 , 10 ) ; Text [ en-US ] = "~Center" ; }; RadioButton BTN_JUSTIFYALIGN { + HelpID = "cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_JUSTIFYALIGN"; Pos = MAP_APPFONT ( 12 , 56 ) ; Size = MAP_APPFONT ( 161 , 10 ) ; Text [ en-US ] = "Justified" ; @@ -315,6 +329,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; ListBox LB_LASTLINE { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGN_PARAGRAPH:LB_LASTLINE"; Pos = MAP_APPFONT ( 105 , 70 ) ; Size = MAP_APPFONT ( 70 , 50 ) ; DropDown = TRUE ; @@ -329,6 +344,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; CheckBox CB_EXPAND { + HelpID = "cui:CheckBox:RID_SVXPAGE_ALIGN_PARAGRAPH:CB_EXPAND"; Pos = MAP_APPFONT ( 20 , 86 ) ; Size = MAP_APPFONT ( 153 , 10 ) ; Hide = TRUE ; @@ -336,6 +352,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; CheckBox CB_SNAP { + HelpID = "cui:CheckBox:RID_SVXPAGE_ALIGN_PARAGRAPH:CB_SNAP"; Pos = MAP_APPFONT ( 20 , 100 ) ; Size = MAP_APPFONT ( 153 , 10 ) ; Hide = TRUE ; @@ -363,6 +380,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; ListBox LB_VERTALIGN { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGN_PARAGRAPH:LB_VERTALIGN"; Pos = MAP_APPFONT ( 105 , 133 ) ; Size = MAP_APPFONT ( 70 , 50 ) ; DropDown = TRUE ; @@ -392,6 +410,7 @@ TabPage RID_SVXPAGE_ALIGN_PARAGRAPH }; ListBox LB_TEXTDIRECTION { + HelpID = "cui:ListBox:RID_SVXPAGE_ALIGN_PARAGRAPH:LB_TEXTDIRECTION"; Border = TRUE ; Pos = MAP_APPFONT ( 105 , 165 ) ; Size = MAP_APPFONT ( 146 , 50 ) ; @@ -408,12 +427,14 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH Size = MAP_APPFONT ( 260 , 185 ) ; TriStateBox BTN_HYPHEN { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_HYPHEN"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "A~utomatically" ; }; NumericField ED_HYPHENBEFORE { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_HYPHENBEFORE"; Disable = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 21 , 26 ) ; @@ -438,6 +459,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; NumericField ED_HYPHENAFTER { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_HYPHENAFTER"; Disable = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 21 , 41 ) ; @@ -469,6 +491,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; NumericField ED_MAXHYPH { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_MAXHYPH"; Border = TRUE ; Pos = MAP_APPFONT ( 21 , 55 ) ; Size = MAP_APPFONT ( 24 , 12 ) ; @@ -501,6 +524,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; TriStateBox BTN_PAGEBREAK { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_PAGEBREAK"; // Disable = TRUE; Pos = MAP_APPFONT ( 12 , 86 ) ; Size = MAP_APPFONT ( 61 , 10 ) ; @@ -515,6 +539,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; ListBox LB_BREAKTYPE { + HelpID = "cui:ListBox:RID_SVXPAGE_EXT_PARAGRAPH:LB_BREAKTYPE"; Border = TRUE ; Pos = MAP_APPFONT ( 98 , 84 ) ; Size = MAP_APPFONT ( 61 , 50 ) ; @@ -534,6 +559,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; ListBox LB_BREAKPOSITION { + HelpID = "cui:ListBox:RID_SVXPAGE_EXT_PARAGRAPH:LB_BREAKPOSITION"; Border = TRUE ; Pos = MAP_APPFONT ( 211 , 84 ) ; Size = MAP_APPFONT ( 40 , 50 ) ; @@ -546,6 +572,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; TriStateBox BTN_PAGECOLL { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_PAGECOLL"; // Disable = TRUE; Pos = MAP_APPFONT (21 , 100 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; @@ -554,6 +581,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; ListBox LB_PAGECOLL { + HelpID = "cui:ListBox:RID_SVXPAGE_EXT_PARAGRAPH:LB_PAGECOLL"; // Disable = TRUE; Pos = MAP_APPFONT ( 98 , 98 ) ; Size = MAP_APPFONT ( 61 , 50 ) ; @@ -569,6 +597,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; NumericField ED_PAGENUM { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_PAGENUM"; Border = TRUE ; Pos = MAP_APPFONT ( 211 , 98 ) ; Size = MAP_APPFONT ( 26 , 12 ) ; @@ -583,6 +612,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; TriStateBox BTN_KEEPTOGETHER { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_KEEPTOGETHER"; Pos = MAP_APPFONT ( 12 , 127 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "~Do not split paragraph" ; @@ -590,12 +620,14 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; TriStateBox CB_KEEPTOGETHER { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:CB_KEEPTOGETHER"; Pos = MAP_APPFONT ( 12, 141 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; Text [ en-US ] = "~Keep with next paragraph" ; }; TriStateBox BTN_ORPHANS { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_ORPHANS"; Disable = TRUE ; Pos = MAP_APPFONT ( 12 , 155 ) ; Size = MAP_APPFONT ( 120 , 10 ) ; @@ -604,6 +636,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; NumericField ED_ORPHANS { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_ORPHANS"; Disable = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 134 , 153 ) ; @@ -628,6 +661,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; TriStateBox BTN_WIDOWS { + HelpID = "cui:TriStateBox:RID_SVXPAGE_EXT_PARAGRAPH:BTN_WIDOWS"; Disable = TRUE ; Pos = MAP_APPFONT ( 12 , 169 ) ; Size = MAP_APPFONT ( 120 , 10 ) ; @@ -636,6 +670,7 @@ TabPage RID_SVXPAGE_EXT_PARAGRAPH }; NumericField ED_WIDOWS { + HelpID = "cui:NumericField:RID_SVXPAGE_EXT_PARAGRAPH:ED_WIDOWS"; Disable = TRUE ; Border = TRUE ; Pos = MAP_APPFONT ( 134 , 167 ) ; @@ -675,57 +710,33 @@ TabPage RID_SVXPAGE_PARA_ASIAN }; TriStateBox CB_AS_FORBIDDEN { + HelpID = "cui:TriStateBox:RID_SVXPAGE_PARA_ASIAN:CB_AS_FORBIDDEN"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Text [ en-US ] = "Apply list of forbidden characters to the beginning and end of lines"; }; TriStateBox CB_AS_HANG_PUNC { + HelpID = "cui:TriStateBox:RID_SVXPAGE_PARA_ASIAN:CB_AS_HANG_PUNC"; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Text [ en-US ] = "Allow hanging punctuation"; }; TriStateBox CB_AS_SCRIPT_SPACE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_PARA_ASIAN:CB_AS_SCRIPT_SPACE"; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 242 , 10 ) ; Text [ en-US ] = "Apply spacing between Asian, Latin and Complex text"; }; }; -// ********************************************************************** EOF - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +String STR_EXAMPLE +{ + Text [ en-US ] = "Example" ; +}; +String STR_PAGE_STYLE +{ + Text [ en-US ] = "Page Style" ; +}; diff --git a/cui/source/tabpages/swpossizetabpage.cxx b/cui/source/tabpages/swpossizetabpage.cxx index 7a53da94b26c..2d08dede00ce 100644 --- a/cui/source/tabpages/swpossizetabpage.cxx +++ b/cui/source/tabpages/swpossizetabpage.cxx @@ -55,14 +55,14 @@ struct FrmMap SvxSwFramePosString::StringId eStrId; SvxSwFramePosString::StringId eMirrorStrId; short nAlign; - ULONG nLBRelations; + sal_uLong nLBRelations; }; struct RelationMap { SvxSwFramePosString::StringId eStrId; SvxSwFramePosString::StringId eMirrorStrId; - ULONG nLBRelation; + sal_uLong nLBRelation; short nRelation; }; struct StringIdPair_Impl @@ -418,7 +418,7 @@ std::size_t lcl_GetFrmMapCount(const FrmMap* pMap) } SvxSwFramePosString::StringId lcl_ChangeResIdToVerticalOrRTL( - SvxSwFramePosString::StringId eStringId, BOOL bVertical, BOOL bRTL) + SvxSwFramePosString::StringId eStringId, sal_Bool bVertical, sal_Bool bRTL) { //special handling of STR_FROMLEFT if(SwFPos::FROMLEFT == eStringId) @@ -453,7 +453,7 @@ SvxSwFramePosString::StringId lcl_ChangeResIdToVerticalOrRTL( {SwFPos::REL_FRM_TOP, SwFPos::REL_FRM_LEFT }, {SwFPos::REL_FRM_BOTTOM, SwFPos::REL_FRM_RIGHT } }; - USHORT nIndex; + sal_uInt16 nIndex; for(nIndex = 0; nIndex < SAL_N_ELEMENTS(aHoriIds); ++nIndex) { if(aHoriIds[nIndex].eHori == eStringId) @@ -476,9 +476,9 @@ SvxSwFramePosString::StringId lcl_ChangeResIdToVerticalOrRTL( } // #i22341# - helper method in order to determine all possible // listbox relations in a relation map for a given relation -ULONG lcl_GetLBRelationsForRelations( const USHORT _nRel ) +sal_uLong lcl_GetLBRelationsForRelations( const sal_uInt16 _nRel ) { - ULONG nLBRelations = 0L; + sal_uLong nLBRelations = 0L; for ( sal_uInt16 nRelMapPos = 0; nRelMapPos < SAL_N_ELEMENTS(aRelationMap); ++nRelMapPos ) { @@ -493,11 +493,11 @@ ULONG lcl_GetLBRelationsForRelations( const USHORT _nRel ) // #i22341# - helper method on order to determine all possible // listbox relations in a relation map for a given string ID -ULONG lcl_GetLBRelationsForStrID( const FrmMap* _pMap, +sal_uLong lcl_GetLBRelationsForStrID( const FrmMap* _pMap, const SvxSwFramePosString::StringId _eStrId, const bool _bUseMirrorStr ) { - ULONG nLBRelations = 0L; + sal_uLong nLBRelations = 0L; std::size_t nRelMapSize = lcl_GetFrmMapCount( _pMap ); for ( std::size_t nRelMapPos = 0; nRelMapPos < nRelMapSize; ++nRelMapPos ) @@ -577,10 +577,10 @@ SvxSwPosSizeTabPage::SvxSwPosSizeTabPage( Window* pParent, const SfxItemSet& rIn { FreeResource(); FieldUnit eDlgUnit = GetModuleFieldUnit( rInAttrs ); - SetFieldUnit( m_aHoriByMF, eDlgUnit, TRUE ); - SetFieldUnit( m_aVertByMF, eDlgUnit, TRUE ); - SetFieldUnit( m_aWidthMF , eDlgUnit, TRUE ); - SetFieldUnit( m_aHeightMF, eDlgUnit, TRUE ); + SetFieldUnit( m_aHoriByMF, eDlgUnit, sal_True ); + SetFieldUnit( m_aVertByMF, eDlgUnit, sal_True ); + SetFieldUnit( m_aWidthMF , eDlgUnit, sal_True ); + SetFieldUnit( m_aHeightMF, eDlgUnit, sal_True ); SetExchangeSupport(); @@ -623,9 +623,9 @@ SfxTabPage* SvxSwPosSizeTabPage::Create( Window* pParent, const SfxItemSet& rSet return new SvxSwPosSizeTabPage(pParent, rSet); } -USHORT* SvxSwPosSizeTabPage::GetRanges() +sal_uInt16* SvxSwPosSizeTabPage::GetRanges() { - static USHORT pSwPosRanges[] = + static sal_uInt16 pSwPosRanges[] = { SID_ATTR_TRANSFORM_POS_X, SID_ATTR_TRANSFORM_POS_Y, @@ -652,15 +652,15 @@ USHORT* SvxSwPosSizeTabPage::GetRanges() return pSwPosRanges; } -BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) +sal_Bool SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) { bool bAnchorChanged = false; short nAnchor = GetAnchorType(&bAnchorChanged); - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if(bAnchorChanged) { rSet.Put(SfxInt16Item(SID_ATTR_TRANSFORM_ANCHOR, nAnchor)); - bModified |= TRUE; + bModified |= sal_True; } if ( m_aPositionCB.GetState() != m_aPositionCB.GetSavedValue() ) { @@ -669,8 +669,8 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) else rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_PROTECT_POS ), - m_aPositionCB.GetState() == STATE_CHECK ? TRUE : FALSE ) ); - bModified |= TRUE; + m_aPositionCB.GetState() == STATE_CHECK ? sal_True : sal_False ) ); + bModified |= sal_True; } if ( m_aSizeCB.GetState() != m_aSizeCB.GetSavedValue() ) @@ -680,8 +680,8 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) else rSet.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_PROTECT_SIZE ), - m_aSizeCB.GetState() == STATE_CHECK ? TRUE : FALSE ) ); - bModified |= TRUE; + m_aSizeCB.GetState() == STATE_CHECK ? sal_True : sal_False ) ); + bModified |= sal_True; } const SfxItemSet& rOldSet = GetItemSet(); @@ -708,7 +708,7 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) rSet.Put( SfxInt32Item( GetWhich( SID_ATTR_TRANSFORM_POS_X ), nHoriByPos ) ); rSet.Put( SfxInt32Item( GetWhich( SID_ATTR_TRANSFORM_POS_Y ), nVertByPos ) ); - bModified |= TRUE; + bModified |= sal_True; } } else @@ -722,7 +722,7 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) const SfxInt32Item& rHoriPosition = static_cast<const SfxInt32Item&>(rOldSet.Get( SID_ATTR_TRANSFORM_HORI_POSITION)) ; - USHORT nMapPos = GetMapPos(m_pHMap, m_aHoriLB); + sal_uInt16 nMapPos = GetMapPos(m_pHMap, m_aHoriLB); short nAlign = GetAlignment(m_pHMap, nMapPos, m_aHoriLB, m_aHoriToLB); short nRel = GetRelation(m_pHMap, m_aHoriToLB); const long nHoriByPos = @@ -737,7 +737,7 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) rSet.Put(SfxInt16Item(SID_ATTR_TRANSFORM_HORI_RELATION, nRel)); if(m_aHoriByMF.IsEnabled()) rSet.Put(SfxInt32Item(SID_ATTR_TRANSFORM_HORI_POSITION, nHoriByPos)); - bModified |= TRUE; + bModified |= sal_True; } } if(m_aHoriMirrorCB.IsEnabled() && m_aHoriMirrorCB.IsChecked() != m_aHoriMirrorCB.GetSavedValue()) @@ -752,7 +752,7 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) const SfxInt32Item& rVertPosition = static_cast<const SfxInt32Item&>(rOldSet.Get( SID_ATTR_TRANSFORM_VERT_POSITION)); - USHORT nMapPos = GetMapPos(m_pVMap, m_aVertLB); + sal_uInt16 nMapPos = GetMapPos(m_pVMap, m_aVertLB); short nAlign = GetAlignment(m_pVMap, nMapPos, m_aVertLB, m_aVertToLB); short nRel = GetRelation(m_pVMap, m_aVertToLB); // #i34055# - convert vertical position for @@ -772,7 +772,7 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) rSet.Put(SfxInt16Item(SID_ATTR_TRANSFORM_VERT_RELATION, nRel)); if(m_aVertByMF.IsEnabled()) rSet.Put(SfxInt32Item(SID_ATTR_TRANSFORM_VERT_POSITION, nVertByPos)); - bModified |= TRUE; + bModified |= sal_True; } } @@ -796,13 +796,13 @@ BOOL SvxSwPosSizeTabPage::FillItemSet( SfxItemSet& rSet) sal_uInt32 nWidth = static_cast<sal_uInt32>(m_aWidthMF.Denormalize(m_aWidthMF.GetValue(FUNIT_TWIP))); sal_uInt32 nHeight = static_cast<sal_uInt32>(m_aHeightMF.Denormalize(m_aHeightMF.GetValue(FUNIT_TWIP))); rSet.Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_WIDTH ), - (UINT32) nWidth ) ); + (sal_uInt32) nWidth ) ); rSet.Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_HEIGHT ), - (UINT32) nHeight ) ); + (sal_uInt32) nHeight ) ); //this item is required by SdrEditView::SetGeoAttrToMarked() rSet.Put( SfxAllEnumItem( GetWhich( SID_ATTR_TRANSFORM_SIZE_POINT ), RP_LT ) ); - bModified |= TRUE; + bModified |= sal_True; } return bModified; @@ -833,11 +833,11 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) } if(bInvalidateAnchor) { - m_aToPageRB.Enable( FALSE ); - m_aToParaRB.Enable( FALSE ); - m_aToCharRB.Enable( FALSE ); - m_aAsCharRB.Enable( FALSE ); - m_aToFrameRB.Enable( FALSE ); + m_aToPageRB.Enable( sal_False ); + m_aToParaRB.Enable( sal_False ); + m_aToCharRB.Enable( sal_False ); + m_aAsCharRB.Enable( sal_False ); + m_aToFrameRB.Enable( sal_False ); } pItem = GetItem( rSet, SID_ATTR_TRANSFORM_PROTECT_POS ); @@ -845,7 +845,7 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) { sal_Bool bProtected = ( ( const SfxBoolItem* )pItem )->GetValue(); m_aPositionCB.SetState( bProtected ? STATE_CHECK : STATE_NOCHECK ); - m_aPositionCB.EnableTriState( FALSE ); + m_aPositionCB.EnableTriState( sal_False ); m_aSizeCB.Enable( !bProtected ); } else @@ -861,7 +861,7 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) { m_aSizeCB.SetState( ( (const SfxBoolItem*)pItem )->GetValue() ? STATE_CHECK : STATE_NOCHECK ); - m_aSizeCB.EnableTriState( FALSE ); + m_aSizeCB.EnableTriState( sal_False ); } else m_aSizeCB.SetState( STATE_DONTKNOW ); @@ -897,8 +897,8 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) { if( 0 == (m_nHtmlMode & HTMLMODE_FULL_ABS_POS)) { - m_aHeightFT .Enable( FALSE ); - m_aHeightMF .Enable( FALSE ); + m_aHeightFT .Enable( sal_False ); + m_aHeightMF .Enable( sal_False ); } if( 0 == (m_nHtmlMode & HTMLMODE_SOME_ABS_POS)) { @@ -906,12 +906,12 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) { m_aToParaRB.Check(); } - m_aToPageRB.Enable(FALSE); + m_aToPageRB.Enable(sal_False); } - m_aHoriMirrorCB.Show(FALSE); - m_aKeepRatioCB.Enable(FALSE); + m_aHoriMirrorCB.Show(sal_False); + m_aKeepRatioCB.Enable(sal_False); // #i18732# - hide checkbox in HTML mode - m_aFollowCB.Show(FALSE); + m_aFollowCB.Show(sal_False); } else { @@ -924,12 +924,12 @@ void SvxSwPosSizeTabPage::Reset( const SfxItemSet& rSet) } pItem = GetItem( rSet, SID_ATTR_TRANSFORM_WIDTH ); - sal_Int32 nWidth = Max( pItem ? ( static_cast<const SfxUInt32Item*>(pItem)->GetValue()) : 0, (UINT32)1 ); + sal_Int32 nWidth = Max( pItem ? ( static_cast<const SfxUInt32Item*>(pItem)->GetValue()) : 0, (sal_uInt32)1 ); m_aWidthMF.SetValue(m_aWidthMF.Normalize(nWidth), FUNIT_TWIP); pItem = GetItem( rSet, SID_ATTR_TRANSFORM_HEIGHT ); - sal_Int32 nHeight = Max( pItem ? ( static_cast<const SfxUInt32Item*>(pItem)->GetValue()) : 0, (UINT32)1 ); + sal_Int32 nHeight = Max( pItem ? ( static_cast<const SfxUInt32Item*>(pItem)->GetValue()) : 0, (sal_uInt32)1 ); m_aHeightMF.SetValue(m_aHeightMF.Normalize(nHeight), FUNIT_TWIP); m_fWidthHeightRatio = nHeight ? double(nWidth) / double(nHeight) : 1.0; @@ -990,12 +990,12 @@ int SvxSwPosSizeTabPage::DeactivatePage( SfxItemSet* _pSet ) return( LEAVE_PAGE ); } -void SvxSwPosSizeTabPage::EnableAnchorTypes(USHORT nAnchorEnable) +void SvxSwPosSizeTabPage::EnableAnchorTypes(sal_uInt16 nAnchorEnable) { if((nAnchorEnable & SVX_OBJ_AT_FLY)) m_aToFrameRB.Show(); if(!(nAnchorEnable & SVX_OBJ_PAGE)) - m_aToPageRB.Enable(FALSE); + m_aToPageRB.Enable(sal_False); } short SvxSwPosSizeTabPage::GetAnchorType(bool* pbHasChanged) @@ -1056,9 +1056,9 @@ IMPL_LINK( SvxSwPosSizeTabPage, RangeModifyHdl, Edit *, EMPTYARG ) if ( m_pHMap ) { // Ausrichtung Horizontal - USHORT nMapPos = GetMapPos(m_pHMap, m_aHoriToLB); - USHORT nAlign = GetAlignment(m_pHMap, nMapPos, m_aHoriLB, m_aHoriToLB); - USHORT nRel = GetRelation(m_pHMap, m_aHoriToLB); + sal_uInt16 nMapPos = GetMapPos(m_pHMap, m_aHoriToLB); + sal_uInt16 nAlign = GetAlignment(m_pHMap, nMapPos, m_aHoriLB, m_aHoriToLB); + sal_uInt16 nRel = GetRelation(m_pHMap, m_aHoriToLB); aVal.nHoriOrient = (short)nAlign; aVal.nHRelOrient = (short)nRel; @@ -1069,9 +1069,9 @@ IMPL_LINK( SvxSwPosSizeTabPage, RangeModifyHdl, Edit *, EMPTYARG ) if ( m_pVMap ) { // Ausrichtung Vertikal - USHORT nMapPos = GetMapPos(m_pVMap, m_aVertLB); - USHORT nAlign = GetAlignment(m_pVMap, nMapPos, m_aVertLB, m_aVertToLB); - USHORT nRel = GetRelation(m_pVMap, m_aVertToLB); + sal_uInt16 nMapPos = GetMapPos(m_pVMap, m_aVertLB); + sal_uInt16 nAlign = GetAlignment(m_pVMap, nMapPos, m_aVertLB, m_aVertToLB); + sal_uInt16 nRel = GetRelation(m_pVMap, m_aVertToLB); aVal.nVertOrient = (short)nAlign; aVal.nVRelOrient = (short)nRel; @@ -1155,20 +1155,20 @@ IMPL_LINK( SvxSwPosSizeTabPage, MirrorHdl, CheckBox *, EMPTYARG ) IMPL_LINK( SvxSwPosSizeTabPage, RelHdl, ListBox *, pLB ) { - BOOL bHori = pLB == &m_aHoriToLB; + sal_Bool bHori = pLB == &m_aHoriToLB; UpdateExample(); if (bHori) - m_bAtHoriPosModified = TRUE; + m_bAtHoriPosModified = sal_True; else - m_bAtVertPosModified = TRUE; + m_bAtVertPosModified = sal_True; if(m_bHtmlMode && TextContentAnchorType_AT_CHARACTER == GetAnchorType()) // wieder Sonderbehandlung { if(bHori) { - USHORT nRel = GetRelation(m_pHMap, m_aHoriToLB); + sal_uInt16 nRel = GetRelation(m_pHMap, m_aHoriToLB); if(RelOrientation::PRINT_AREA == nRel && 0 == m_aVertLB.GetSelectEntryPos()) { m_aVertLB.SelectEntryPos(1); @@ -1188,24 +1188,24 @@ IMPL_LINK( SvxSwPosSizeTabPage, RelHdl, ListBox *, pLB ) IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) { - BOOL bHori = pLB == &m_aHoriLB; + sal_Bool bHori = pLB == &m_aHoriLB; ListBox *pRelLB = bHori ? &m_aHoriToLB : &m_aVertToLB; FixedText *pRelFT = bHori ? &m_aHoriToFT : &m_aVertToFT; FrmMap *pMap = bHori ? m_pHMap : m_pVMap; - USHORT nMapPos = GetMapPos(pMap, *pLB); - USHORT nAlign = GetAlignment(pMap, nMapPos, *pLB, *pRelLB); + sal_uInt16 nMapPos = GetMapPos(pMap, *pLB); + sal_uInt16 nAlign = GetAlignment(pMap, nMapPos, *pLB, *pRelLB); if (bHori) { - BOOL bEnable = HoriOrientation::NONE == nAlign; + sal_Bool bEnable = HoriOrientation::NONE == nAlign; m_aHoriByMF.Enable( bEnable ); m_aHoriByFT.Enable( bEnable ); } else { - BOOL bEnable = VertOrientation::NONE == nAlign; + sal_Bool bEnable = VertOrientation::NONE == nAlign; m_aVertByMF.Enable( bEnable ); m_aVertByFT.Enable( bEnable ); } @@ -1228,15 +1228,15 @@ IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) UpdateExample(); if (bHori) - m_bAtHoriPosModified = TRUE; + m_bAtHoriPosModified = sal_True; else - m_bAtVertPosModified = TRUE; + m_bAtVertPosModified = sal_True; // Sonderbehandlung fuer HTML-Mode mit horz-vert-Abhaengigkeiten if(m_bHtmlMode && m_nHtmlMode & HTMLMODE_SOME_ABS_POS && TextContentAnchorType_AT_CHARACTER == GetAnchorType()) { - BOOL bSet = FALSE; + sal_Bool bSet = sal_False; if(bHori) { // rechts ist nur unterhalb erlaubt - von links nur oben @@ -1248,17 +1248,17 @@ IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) m_aVertLB.SelectEntryPos(1); else m_aVertLB.SelectEntryPos(0); - bSet = TRUE; + bSet = sal_True; } else if(HoriOrientation::LEFT == nAlign && 1 == m_aVertLB.GetSelectEntryPos()) { m_aVertLB.SelectEntryPos(0); - bSet = TRUE; + bSet = sal_True; } else if(HoriOrientation::NONE == nAlign && 1 == m_aVertLB.GetSelectEntryPos()) { m_aVertLB.SelectEntryPos(0); - bSet = TRUE; + bSet = sal_True; } if(bSet) PosHdl(&m_aVertLB); @@ -1270,7 +1270,7 @@ IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) if(1 == m_aHoriLB.GetSelectEntryPos()) { m_aHoriLB.SelectEntryPos(0); - bSet = TRUE; + bSet = sal_True; } m_aHoriToLB.SelectEntryPos(1); } @@ -1279,7 +1279,7 @@ IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) if(2 == m_aHoriLB.GetSelectEntryPos()) { m_aHoriLB.SelectEntryPos(0); - bSet = TRUE; + bSet = sal_True; } m_aHoriToLB.SelectEntryPos(0) ; } @@ -1322,7 +1322,7 @@ IMPL_LINK( SvxSwPosSizeTabPage, ProtectHdl, TriStateBox *, EMPTYARG) short SvxSwPosSizeTabPage::GetRelation(FrmMap *, ListBox &rRelationLB) { short nRel = 0; - USHORT nPos = rRelationLB.GetSelectEntryPos(); + sal_uInt16 nPos = rRelationLB.GetSelectEntryPos(); if (nPos != LISTBOX_ENTRY_NOTFOUND) { @@ -1333,7 +1333,7 @@ short SvxSwPosSizeTabPage::GetRelation(FrmMap *, ListBox &rRelationLB) return nRel; } -short SvxSwPosSizeTabPage::GetAlignment(FrmMap *pMap, USHORT nMapPos, ListBox &/*rAlignLB*/, ListBox &rRelationLB) +short SvxSwPosSizeTabPage::GetAlignment(FrmMap *pMap, sal_uInt16 nMapPos, ListBox &/*rAlignLB*/, ListBox &rRelationLB) { short nAlign = 0; @@ -1344,7 +1344,7 @@ short SvxSwPosSizeTabPage::GetAlignment(FrmMap *pMap, USHORT nMapPos, ListBox &/ { if (rRelationLB.GetSelectEntryPos() != LISTBOX_ENTRY_NOTFOUND) { - ULONG nRel = ((RelationMap *)rRelationLB.GetEntryData(rRelationLB.GetSelectEntryPos()))->nLBRelation; + sal_uLong nRel = ((RelationMap *)rRelationLB.GetEntryData(rRelationLB.GetSelectEntryPos()))->nLBRelation; std::size_t nMapCount = ::lcl_GetFrmMapCount(pMap); SvxSwFramePosString::StringId eStrId = pMap[nMapPos].eStrId; @@ -1352,7 +1352,7 @@ short SvxSwPosSizeTabPage::GetAlignment(FrmMap *pMap, USHORT nMapPos, ListBox &/ { if (pMap[i].eStrId == eStrId) { - ULONG nLBRelations = pMap[i].nLBRelations; + sal_uLong nLBRelations = pMap[i].nLBRelations; if (nLBRelations & nRel) { nAlign = pMap[i].nAlign; @@ -1368,10 +1368,10 @@ short SvxSwPosSizeTabPage::GetAlignment(FrmMap *pMap, USHORT nMapPos, ListBox &/ return nAlign; } -USHORT SvxSwPosSizeTabPage::GetMapPos(FrmMap *pMap, ListBox &rAlignLB) +sal_uInt16 SvxSwPosSizeTabPage::GetMapPos(FrmMap *pMap, ListBox &rAlignLB) { - USHORT nMapPos = 0; - USHORT nLBSelPos = rAlignLB.GetSelectEntryPos(); + sal_uInt16 nMapPos = 0; + sal_uInt16 nLBSelPos = rAlignLB.GetSelectEntryPos(); if (nLBSelPos != LISTBOX_ENTRY_NOTFOUND) { @@ -1388,7 +1388,7 @@ USHORT SvxSwPosSizeTabPage::GetMapPos(FrmMap *pMap, ListBox &rAlignLB) if (sEntry == sSelEntry) { - nMapPos = sal::static_int_cast< USHORT >(i); + nMapPos = sal::static_int_cast< sal_uInt16 >(i); break; } } @@ -1401,14 +1401,14 @@ USHORT SvxSwPosSizeTabPage::GetMapPos(FrmMap *pMap, ListBox &rAlignLB) } void SvxSwPosSizeTabPage::InitPos(short nAnchor, - USHORT nH, - USHORT nHRel, - USHORT nV, - USHORT nVRel, + sal_uInt16 nH, + sal_uInt16 nHRel, + sal_uInt16 nV, + sal_uInt16 nVRel, long nX, long nY) { - USHORT nPos = m_aVertLB.GetSelectEntryPos(); + sal_uInt16 nPos = m_aVertLB.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND && m_pVMap ) { m_nOldV = m_pVMap[nPos].nAlign; @@ -1427,7 +1427,7 @@ void SvxSwPosSizeTabPage::InitPos(short nAnchor, m_nOldHRel = ((RelationMap *)m_aHoriToLB.GetEntryData(nPos))->nRelation; } - BOOL bEnable = TRUE; + sal_Bool bEnable = sal_True; if( m_bIsMultiSelection ) { m_pVMap = aVMultiSelectionMap; @@ -1475,7 +1475,7 @@ void SvxSwPosSizeTabPage::InitPos(short nAnchor, { m_pVMap = m_bHtmlMode ? aVAsCharHtmlMap : aVAsCharMap; m_pHMap = 0; - bEnable = FALSE; + bEnable = sal_False; } m_aHoriLB.Enable( bEnable ); m_aHoriFT.Enable( bEnable ); @@ -1488,7 +1488,7 @@ void SvxSwPosSizeTabPage::InitPos(short nAnchor, nHRel = m_nOldHRel; } // #i22341# - pass <nHRel> as 3rd parameter to method <FillPosLB> - USHORT nMapPos = FillPosLB(m_pHMap, nH, nHRel, m_aHoriLB); + sal_uInt16 nMapPos = FillPosLB(m_pHMap, nH, nHRel, m_aHoriLB); FillRelLB(m_pHMap, nMapPos, nH, nHRel, m_aHoriToLB, m_aHoriToFT); // Vertikal @@ -1552,10 +1552,10 @@ void SvxSwPosSizeTabPage::InitPos(short nAnchor, void SvxSwPosSizeTabPage::UpdateExample() { - USHORT nPos = m_aHoriLB.GetSelectEntryPos(); + sal_uInt16 nPos = m_aHoriLB.GetSelectEntryPos(); if ( m_pHMap && nPos != LISTBOX_ENTRY_NOTFOUND ) { - USHORT nMapPos = GetMapPos(m_pHMap, m_aHoriLB); + sal_uInt16 nMapPos = GetMapPos(m_pHMap, m_aHoriLB); short nAlign = GetAlignment(m_pHMap, nMapPos, m_aHoriLB, m_aHoriToLB); short nRel = GetRelation(m_pHMap, m_aHoriToLB); @@ -1566,9 +1566,9 @@ void SvxSwPosSizeTabPage::UpdateExample() nPos = m_aVertLB.GetSelectEntryPos(); if ( m_pVMap && nPos != LISTBOX_ENTRY_NOTFOUND ) { - USHORT nMapPos = GetMapPos(m_pVMap, m_aVertLB); - USHORT nAlign = GetAlignment(m_pVMap, nMapPos, m_aVertLB, m_aVertToLB); - USHORT nRel = GetRelation(m_pVMap, m_aVertToLB); + sal_uInt16 nMapPos = GetMapPos(m_pVMap, m_aVertLB); + sal_uInt16 nAlign = GetAlignment(m_pVMap, nMapPos, m_aVertLB, m_aVertToLB); + sal_uInt16 nRel = GetRelation(m_pVMap, m_aVertToLB); m_aExampleWN.SetVAlign(nAlign); m_aExampleWN.SetVertRel(nRel); @@ -1583,11 +1583,11 @@ void SvxSwPosSizeTabPage::UpdateExample() m_aExampleWN.Invalidate(); } -ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign, - USHORT nRel, ListBox &rLB, FixedText &rFT) +sal_uLong SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, sal_uInt16 nMapPos, sal_uInt16 nAlign, + sal_uInt16 nRel, ListBox &rLB, FixedText &rFT) { String sSelEntry; - ULONG nLBRelations = 0; + sal_uLong nLBRelations = 0; std::size_t nMapCount = ::lcl_GetFrmMapCount(pMap); rLB.Clear(); @@ -1597,7 +1597,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign if (pMap == aVAsCharHtmlMap || pMap == aVAsCharMap) { String sOldEntry(rLB.GetSelectEntry()); - USHORT nRelCount = SAL_N_ELEMENTS(aAsCharRelationMap); + sal_uInt16 nRelCount = SAL_N_ELEMENTS(aAsCharRelationMap); SvxSwFramePosString::StringId eStrId = pMap[nMapPos].eStrId; for (std::size_t _nMapPos = 0; _nMapPos < nMapCount; _nMapPos++) @@ -1605,7 +1605,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign if (pMap[_nMapPos].eStrId == eStrId) { nLBRelations = pMap[_nMapPos].nLBRelations; - for (USHORT nRelPos = 0; nRelPos < nRelCount; nRelPos++) + for (sal_uInt16 nRelPos = 0; nRelPos < nRelCount; nRelPos++) { if (nLBRelations & aAsCharRelationMap[nRelPos].nLBRelation) { @@ -1613,7 +1613,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign sStrId1 = lcl_ChangeResIdToVerticalOrRTL(sStrId1, m_bIsVerticalFrame, m_bIsInRightToLeft); String sEntry = m_aFramePosString.GetString(sStrId1); - USHORT nPos = rLB.InsertEntry(sEntry); + sal_uInt16 nPos = rLB.InsertEntry(sEntry); rLB.SetEntryData(nPos, &aAsCharRelationMap[nRelPos]); if (pMap[_nMapPos].nAlign == nAlign) sSelEntry = sEntry; @@ -1630,7 +1630,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign if (!rLB.GetSelectEntryCount()) { - for (USHORT i = 0; i < rLB.GetEntryCount(); i++) + for (sal_uInt16 i = 0; i < rLB.GetEntryCount(); i++) { RelationMap *pEntry = (RelationMap *)rLB.GetEntryData(i); if (pEntry->nLBRelation == LB_REL_CHAR) // Default @@ -1644,7 +1644,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign } else { - USHORT nRelCount = SAL_N_ELEMENTS(aRelationMap); + sal_uInt16 nRelCount = SAL_N_ELEMENTS(aRelationMap); // #i22341# - special handling for map <aVCharMap>, // because its ambigous in its <eStrId>/<eMirrorStrId>. @@ -1661,18 +1661,18 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign nLBRelations = pMap[nMapPos].nLBRelations; } - for (ULONG nBit = 1; nBit < 0x80000000; nBit <<= 1) + for (sal_uLong nBit = 1; nBit < 0x80000000; nBit <<= 1) { if (nLBRelations & nBit) { - for (USHORT nRelPos = 0; nRelPos < nRelCount; nRelPos++) + for (sal_uInt16 nRelPos = 0; nRelPos < nRelCount; nRelPos++) { if (aRelationMap[nRelPos].nLBRelation == nBit) { SvxSwFramePosString::StringId sStrId1 = m_aHoriMirrorCB.IsChecked() ? aRelationMap[nRelPos].eMirrorStrId : aRelationMap[nRelPos].eStrId; sStrId1 = lcl_ChangeResIdToVerticalOrRTL(sStrId1, m_bIsVerticalFrame, m_bIsInRightToLeft); String sEntry = m_aFramePosString.GetString(sStrId1); - USHORT nPos = rLB.InsertEntry(sEntry); + sal_uInt16 nPos = rLB.InsertEntry(sEntry); rLB.SetEntryData(nPos, &aRelationMap[nRelPos]); if (!sSelEntry.Len() && aRelationMap[nRelPos].nRelation == nRel) sSelEntry = sEntry; @@ -1705,7 +1705,7 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign break; } - for (USHORT i = 0; i < rLB.GetEntryCount(); i++) + for (sal_uInt16 i = 0; i < rLB.GetEntryCount(); i++) { RelationMap *pEntry = (RelationMap *)rLB.GetEntryData(i); if (pEntry->nRelation == nRel) @@ -1729,9 +1729,9 @@ ULONG SvxSwPosSizeTabPage::FillRelLB(FrmMap *pMap, USHORT nMapPos, USHORT nAlign return nLBRelations; } -USHORT SvxSwPosSizeTabPage::FillPosLB(FrmMap *_pMap, - USHORT _nAlign, - const USHORT _nRel, +sal_uInt16 SvxSwPosSizeTabPage::FillPosLB(FrmMap *_pMap, + sal_uInt16 _nAlign, + const sal_uInt16 _nRel, ListBox &_rLB) { String sSelEntry, sOldEntry; @@ -1741,7 +1741,7 @@ USHORT SvxSwPosSizeTabPage::FillPosLB(FrmMap *_pMap, // #i22341# - determine all possible listbox relations for // given relation for map <aVCharMap> - const ULONG nLBRelations = (_pMap != aVCharMap) + const sal_uLong nLBRelations = (_pMap != aVCharMap) ? 0L : ::lcl_GetLBRelationsForRelations( _nRel ); @@ -1807,27 +1807,27 @@ void SvxSwPosSizeTabPage::SetView( const SdrView* pSdrView ) if( m_aAnchorPos != Point(0,0) ) // -> Writer { - for( USHORT i = 1; i < rMarkList.GetMarkCount(); i++ ) + for( sal_uInt16 i = 1; i < rMarkList.GetMarkCount(); i++ ) { pObj = rMarkList.GetMark( i )->GetMarkedSdrObj(); if( m_aAnchorPos != pObj->GetAnchorPos() ) { // different anchor positions -> disable positioning - m_aPositionFL.Enable(FALSE); - m_aHoriFT.Enable(FALSE); - m_aHoriLB.Enable(FALSE); - m_aHoriByFT.Enable(FALSE); - m_aHoriByMF.Enable(FALSE); - m_aHoriToFT.Enable(FALSE); - m_aHoriToLB.Enable(FALSE); - m_aHoriMirrorCB.Enable(FALSE); - m_aVertFT.Enable(FALSE); - m_aVertLB.Enable(FALSE); - m_aVertByFT.Enable(FALSE); - m_aVertByMF.Enable(FALSE); - m_aVertToFT.Enable(FALSE); - m_aVertToLB.Enable(FALSE); - m_aFollowCB.Enable(FALSE); + m_aPositionFL.Enable(sal_False); + m_aHoriFT.Enable(sal_False); + m_aHoriLB.Enable(sal_False); + m_aHoriByFT.Enable(sal_False); + m_aHoriByMF.Enable(sal_False); + m_aHoriToFT.Enable(sal_False); + m_aHoriToLB.Enable(sal_False); + m_aHoriMirrorCB.Enable(sal_False); + m_aVertFT.Enable(sal_False); + m_aVertLB.Enable(sal_False); + m_aVertByFT.Enable(sal_False); + m_aVertByMF.Enable(sal_False); + m_aVertToFT.Enable(sal_False); + m_aVertToLB.Enable(sal_False); + m_aFollowCB.Enable(sal_False); m_aHoriByMF.SetText(String()); m_aVertByMF.SetText(String()); diff --git a/cui/source/tabpages/swpossizetabpage.hxx b/cui/source/tabpages/swpossizetabpage.hxx index 200c261a4408..76a197705cff 100644 --- a/cui/source/tabpages/swpossizetabpage.hxx +++ b/cui/source/tabpages/swpossizetabpage.hxx @@ -103,7 +103,7 @@ class SvxSwPosSizeTabPage : public SfxTabPage short m_nOldVRel; double m_fWidthHeightRatio; //width-to-height ratio to support the KeepRatio button - USHORT m_nHtmlMode; + sal_uInt16 m_nHtmlMode; bool m_bHtmlMode; bool m_bAtHoriPosModified; bool m_bAtVertPosModified; @@ -122,15 +122,15 @@ class SvxSwPosSizeTabPage : public SfxTabPage DECL_LINK( ModifyHdl, Edit * ); DECL_LINK( ProtectHdl, TriStateBox *); - void InitPos(short nAnchorType, USHORT nH, USHORT nHRel, - USHORT nV, USHORT nVRel, + void InitPos(short nAnchorType, sal_uInt16 nH, sal_uInt16 nHRel, + sal_uInt16 nV, sal_uInt16 nVRel, long nX, long nY); - USHORT GetMapPos(FrmMap *pMap, ListBox &rAlignLB); - short GetAlignment(FrmMap *pMap, USHORT nMapPos, ListBox &rAlignLB, ListBox &rRelationLB); + sal_uInt16 GetMapPos(FrmMap *pMap, ListBox &rAlignLB); + short GetAlignment(FrmMap *pMap, sal_uInt16 nMapPos, ListBox &rAlignLB, ListBox &rRelationLB); short GetRelation(FrmMap *pMap, ListBox &rRelationLB); short GetAnchorType(bool* pbHasChanged = 0); - ULONG FillRelLB(FrmMap *pMap, USHORT nLBSelPos, USHORT nAlign, USHORT nRel, ListBox &rLB, FixedText &rFT); - USHORT FillPosLB(FrmMap *pMap, USHORT nAlign, const USHORT _nRel, ListBox &rLB); + sal_uLong FillRelLB(FrmMap *pMap, sal_uInt16 nLBSelPos, sal_uInt16 nAlign, sal_uInt16 nRel, ListBox &rLB, FixedText &rFT); + sal_uInt16 FillPosLB(FrmMap *pMap, sal_uInt16 nAlign, const sal_uInt16 _nRel, ListBox &rLB); void UpdateExample(); @@ -139,14 +139,14 @@ public: ~SvxSwPosSizeTabPage(); static SfxTabPage* Create( Window*, const SfxItemSet& ); - static USHORT* GetRanges(); + static sal_uInt16* GetRanges(); - virtual BOOL FillItemSet( SfxItemSet& ); + virtual sal_Bool FillItemSet( SfxItemSet& ); virtual void Reset( const SfxItemSet & ); virtual int DeactivatePage( SfxItemSet* pSet ); - void EnableAnchorTypes(USHORT nAnchorEnable); + void EnableAnchorTypes(sal_uInt16 nAnchorEnable); void SetValidateFramePosLink( const Link& rLink ) {m_aValidateLink = rLink;} diff --git a/cui/source/tabpages/swpossizetabpage.src b/cui/source/tabpages/swpossizetabpage.src index c5fd8e8816e9..f22227ac8061 100644 --- a/cui/source/tabpages/swpossizetabpage.src +++ b/cui/source/tabpages/swpossizetabpage.src @@ -52,6 +52,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; MetricField MF_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_SWPOSSIZE:MF_WIDTH"; Pos = MAP_APPFONT ( 59 , 14 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; Border = TRUE ; @@ -77,6 +78,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; MetricField MF_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_SWPOSSIZE:MF_HEIGHT"; Pos = MAP_APPFONT ( 59 , 30 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; Border = TRUE ; @@ -95,6 +97,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; CheckBox CB_KEEPRATIO { + HelpID = "cui:CheckBox:RID_SVXPAGE_SWPOSSIZE:CB_KEEPRATIO"; Pos = MAP_APPFONT ( 12 , 45 ) ; Size = MAP_APPFONT ( 95 , 10 ) ; TabStop = TRUE ; @@ -114,30 +117,35 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; RadioButton RB_TOPAGE { + HelpID = "cui:RadioButton:RID_SVXPAGE_SWPOSSIZE:RB_TOPAGE"; Pos = MAP_APPFONT ( 122 , 14 ) ; Size = MAP_APPFONT ( 70 , 10 ) ; Text [ en-US ] = "To ~page"; }; RadioButton RB_TOPARA { + HelpID = "cui:RadioButton:RID_SVXPAGE_SWPOSSIZE:RB_TOPARA"; Pos = MAP_APPFONT ( 122 , 28 ) ; Size = MAP_APPFONT ( 70 , 10 ) ; Text [ en-US ] = "To paragrap~h"; }; RadioButton RB_TOCHAR { + HelpID = "cui:RadioButton:RID_SVXPAGE_SWPOSSIZE:RB_TOCHAR"; Pos = MAP_APPFONT ( 122 , 42 ) ; Size = MAP_APPFONT ( 70 , 10 ) ; Text [ en-US ] = "To cha~racter"; }; RadioButton RB_ASCHAR { + HelpID = "cui:RadioButton:RID_SVXPAGE_SWPOSSIZE:RB_ASCHAR"; Pos = MAP_APPFONT ( 122 , 56 ) ; Size = MAP_APPFONT ( 70 , 10 ) ; Text [ en-US ] = "~As character" ; }; RadioButton RB_TOFRAME { + HelpID = "cui:RadioButton:RID_SVXPAGE_SWPOSSIZE:RB_TOFRAME"; Hide = TRUE; Pos = MAP_APPFONT ( 122 , 70 ) ; Size = MAP_APPFONT ( 70 , 10 ) ; @@ -156,6 +164,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; TriStateBox CB_POSITION { + HelpID = "cui:TriStateBox:RID_SVXPAGE_SWPOSSIZE:CB_POSITION"; Pos = MAP_APPFONT ( 12 , 97 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; TabStop = TRUE ; @@ -163,6 +172,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; TriStateBox CB_SIZE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_SWPOSSIZE:CB_SIZE"; Pos = MAP_APPFONT ( 122 , 97 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; TabStop = TRUE ; @@ -183,6 +193,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; ListBox LB_HORI { + HelpID = "cui:ListBox:RID_SVXPAGE_SWPOSSIZE:LB_HORI"; Pos = MAP_APPFONT ( 49 , 124 ) ; Size = MAP_APPFONT ( 50 , 60 ) ; TabStop = TRUE ; @@ -197,6 +208,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; MetricField MF_HORIBY { + HelpID = "cui:MetricField:RID_SVXPAGE_SWPOSSIZE:MF_HORIBY"; Border = TRUE ; Pos = MAP_APPFONT ( 123 , 124 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -221,6 +233,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; ListBox LB_HORITO { + HelpID = "cui:ListBox:RID_SVXPAGE_SWPOSSIZE:LB_HORITO"; Pos = MAP_APPFONT ( 183 , 124 ) ; Size = MAP_APPFONT ( 65 , 60 ) ; TabStop = TRUE ; @@ -228,6 +241,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; CheckBox CB_HORIMIRROR { + HelpID = "cui:CheckBox:RID_SVXPAGE_SWPOSSIZE:CB_HORIMIRROR"; Pos = MAP_APPFONT ( 12 , 139 ) ; Size = MAP_APPFONT ( 236 , 10 ) ; TabStop = TRUE ; @@ -242,6 +256,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; ListBox LB_VERT { + HelpID = "cui:ListBox:RID_SVXPAGE_SWPOSSIZE:LB_VERT"; Pos = MAP_APPFONT ( 49 , 153 ) ; Size = MAP_APPFONT ( 50 , 60 ) ; TabStop = TRUE ; @@ -256,6 +271,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; MetricField MF_VERTBY { + HelpID = "cui:MetricField:RID_SVXPAGE_SWPOSSIZE:MF_VERTBY"; Border = TRUE ; Pos = MAP_APPFONT ( 123 , 153 ) ; Size = MAP_APPFONT ( 35 , 12 ) ; @@ -280,6 +296,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; ListBox LB_VERTTO { + HelpID = "cui:ListBox:RID_SVXPAGE_SWPOSSIZE:LB_VERTTO"; Pos = MAP_APPFONT ( 183 , 153 ) ; Size = MAP_APPFONT ( 65 , 60 ) ; TabStop = TRUE ; @@ -287,6 +304,7 @@ TabPage RID_SVXPAGE_SWPOSSIZE }; CheckBox CB_FOLLOW { + HelpID = "cui:CheckBox:RID_SVXPAGE_SWPOSSIZE:CB_FOLLOW"; Pos = MAP_APPFONT ( 12 , 168 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; TabStop = TRUE ; diff --git a/cui/source/tabpages/tabarea.cxx b/cui/source/tabpages/tabarea.cxx index 36b1f3a38de2..95491d5382ad 100644 --- a/cui/source/tabpages/tabarea.cxx +++ b/cui/source/tabpages/tabarea.cxx @@ -84,7 +84,7 @@ SvxAreaTabDialog::SvxAreaTabDialog mnDlgType( 0 ), mnPos( 0 ), mbAreaTP( sal_False ), - mbDeleteColorTable( TRUE ) + mbDeleteColorTable( sal_True ) { FreeResource(); @@ -240,7 +240,7 @@ short SvxAreaTabDialog::Ok() SavePalettes(); // Es wird RET_OK zurueckgeliefert, wenn wenigstens eine - // TabPage in FillItemSet() TRUE zurueckliefert. Dieses + // TabPage in FillItemSet() sal_True zurueckliefert. Dieses // geschieht z.Z. standardmaessig. return( SfxTabDialog::Ok() ); } @@ -258,7 +258,7 @@ IMPL_LINK_INLINE_END( SvxAreaTabDialog, CancelHdlImpl, void *, p ) // ----------------------------------------------------------------------- -void SvxAreaTabDialog::PageCreated( USHORT nId, SfxTabPage &rPage ) +void SvxAreaTabDialog::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { switch( nId ) { diff --git a/cui/source/tabpages/tabarea.hrc b/cui/source/tabpages/tabarea.hrc index 10fe10f1495d..8e2f9b4344c2 100644 --- a/cui/source/tabpages/tabarea.hrc +++ b/cui/source/tabpages/tabarea.hrc @@ -185,3 +185,7 @@ #define IMG_LOAD_H 23 #define IMG_SAVE_H 24 +// IAccessibility2 implementation 2009 ------ +#define STR_CUI_COLORMODEL 5030 +#define STR_LB_HATCHINGSTYLE 5031 +// ------ IAccessibility2 implementation 2009. diff --git a/cui/source/tabpages/tabarea.src b/cui/source/tabpages/tabarea.src index 11be9e726a2b..4fd3db7c8996 100644 --- a/cui/source/tabpages/tabarea.src +++ b/cui/source/tabpages/tabarea.src @@ -51,18 +51,21 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; RadioButton RBT_TRANS_OFF { + HelpID = "cui:RadioButton:RID_SVXPAGE_TRANSPARENCE:RBT_TRANS_OFF"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 110 , 10 ) ; Text [ en-US ] = "~No transparency"; }; RadioButton RBT_TRANS_LINEAR { + HelpID = "cui:RadioButton:RID_SVXPAGE_TRANSPARENCE:RBT_TRANS_LINEAR"; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 60 , 10 ) ; Text [ en-US ] = "~Transparency"; }; MetricField MTR_TRANSPARENT { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRANSPARENT"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 26 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -78,6 +81,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; RadioButton RBT_TRANS_GRADIENT { + HelpID = "cui:RadioButton:RID_SVXPAGE_TRANSPARENCE:RBT_TRANS_GRADIENT"; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 110 , 10 ) ; Text [ en-US ] = "Gradient"; @@ -90,6 +94,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; ListBox LB_TRGR_GRADIENT_TYPES { + HelpID = "cui:ListBox:RID_SVXPAGE_TRANSPARENCE:LB_TRGR_GRADIENT_TYPES"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 54 ) ; Size = MAP_APPFONT ( 53 , 63 ) ; @@ -113,6 +118,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_CENTER_X { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_CENTER_X"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 70 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -134,6 +140,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_CENTER_Y { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_CENTER_Y"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 86 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -155,6 +162,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_ANGLE { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_ANGLE"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 102 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -175,6 +183,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_BORDER { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_BORDER"; Border = TRUE ; Pos = MAP_APPFONT ( 66 + TRANS_GRAD_OFFSET_X, 54 + TRANS_GRAD_OFFSET_Y) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -196,6 +205,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_START_VALUE { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_START_VALUE"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 134 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -217,6 +227,7 @@ TabPage RID_SVXPAGE_TRANSPARENCE }; MetricField MTR_TRGR_END_VALUE { + HelpID = "cui:MetricField:RID_SVXPAGE_TRANSPARENCE:MTR_TRGR_END_VALUE"; Border = TRUE ; Pos = MAP_APPFONT ( 72 , 150 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -261,6 +272,7 @@ TabPage RID_SVXPAGE_AREA }; ListBox LB_AREA_TYPE { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_AREA_TYPE"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 108 , 60 ) ; DropDown = TRUE; @@ -278,6 +290,7 @@ TabPage RID_SVXPAGE_AREA ListBox LB_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 30 ) ; Size = MAP_APPFONT ( 108 , 103 ) ; @@ -285,6 +298,7 @@ TabPage RID_SVXPAGE_AREA }; ListBox LB_GRADIENT { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_GRADIENT"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 30 ) ; Size = MAP_APPFONT ( 108 , 103 ) ; @@ -292,6 +306,7 @@ TabPage RID_SVXPAGE_AREA }; ListBox LB_HATCHING { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_HATCHING"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 30 ) ; Size = MAP_APPFONT ( 108 , 103 ) ; @@ -299,6 +314,7 @@ TabPage RID_SVXPAGE_AREA }; ListBox LB_BITMAP { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_BITMAP"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 30 ) ; Size = MAP_APPFONT ( 108 , 103 ) ; @@ -331,6 +347,7 @@ TabPage RID_SVXPAGE_AREA }; TriStateBox TSB_STEPCOUNT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_AREA:TSB_STEPCOUNT"; Pos = MAP_APPFONT ( 138 , 15 ) ; Size = MAP_APPFONT ( 68 , 10 ) ; TabStop = TRUE ; @@ -338,6 +355,7 @@ TabPage RID_SVXPAGE_AREA }; NumericField NUM_FLD_STEPCOUNT { + HelpID = "cui:NumericField:RID_SVXPAGE_AREA:NUM_FLD_STEPCOUNT"; Border = TRUE ; Pos = MAP_APPFONT ( 208 , 14 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -355,6 +373,7 @@ TabPage RID_SVXPAGE_AREA CheckBox CB_HATCHBCKGRD { + HelpID = "cui:CheckBox:RID_SVXPAGE_AREA:CB_HATCHBCKGRD"; Pos = MAP_APPFONT ( 132 , 3 ) ; Size = MAP_APPFONT ( 122 , 10 ) ; TabStop = TRUE ; @@ -362,6 +381,7 @@ TabPage RID_SVXPAGE_AREA }; ListBox LB_HATCHBCKGRDCOLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_AREA:LB_HATCHBCKGRDCOLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 141 , 16 ) ; Size = MAP_APPFONT ( 70 , 100 ) ; @@ -380,6 +400,7 @@ TabPage RID_SVXPAGE_AREA }; TriStateBox TSB_ORIGINAL { + HelpID = "cui:TriStateBox:RID_SVXPAGE_AREA:TSB_ORIGINAL"; Pos = MAP_APPFONT ( 138 , 15 ) ; Size = MAP_APPFONT ( 48 , 10 ) ; TabStop = TRUE ; @@ -387,6 +408,7 @@ TabPage RID_SVXPAGE_AREA }; TriStateBox TSB_SCALE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_AREA:TSB_SCALE"; Pos = MAP_APPFONT ( 138 , 30 ) ; Size = MAP_APPFONT ( 48 , 10 ) ; TabStop = TRUE ; @@ -400,6 +422,7 @@ TabPage RID_SVXPAGE_AREA }; MetricField MTR_FLD_X_SIZE { + HelpID = "cui:MetricField:RID_SVXPAGE_AREA:MTR_FLD_X_SIZE"; Border = TRUE ; Pos = MAP_APPFONT ( 212 , 14 ) ; Size = MAP_APPFONT ( 36 , 12 ) ; @@ -424,6 +447,7 @@ TabPage RID_SVXPAGE_AREA }; MetricField MTR_FLD_Y_SIZE { + HelpID = "cui:MetricField:RID_SVXPAGE_AREA:MTR_FLD_Y_SIZE"; Border = TRUE ; Pos = MAP_APPFONT ( 212 , 29 ) ; Size = MAP_APPFONT ( 36 , 12 ) ; @@ -469,6 +493,7 @@ TabPage RID_SVXPAGE_AREA }; MetricField MTR_FLD_X_OFFSET { + HelpID = "cui:MetricField:RID_SVXPAGE_AREA:MTR_FLD_X_OFFSET"; Border = TRUE ; Pos = MAP_APPFONT ( 219 , 87 ) ; Size = MAP_APPFONT ( 29 , 12 ) ; @@ -484,6 +509,7 @@ TabPage RID_SVXPAGE_AREA }; MetricField MTR_FLD_Y_OFFSET { + HelpID = "cui:MetricField:RID_SVXPAGE_AREA:MTR_FLD_Y_OFFSET"; Border = TRUE ; Pos = MAP_APPFONT ( 219 , 102 ) ; Size = MAP_APPFONT ( 29 , 12 ) ; @@ -499,6 +525,7 @@ TabPage RID_SVXPAGE_AREA }; TriStateBox TSB_TILE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_AREA:TSB_TILE"; Pos = MAP_APPFONT ( 138 , 117 ) ; Size = MAP_APPFONT ( 54 , 10 ) ; TabStop = TRUE ; @@ -506,6 +533,7 @@ TabPage RID_SVXPAGE_AREA }; TriStateBox TSB_STRETCH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_AREA:TSB_STRETCH"; Pos = MAP_APPFONT ( 194 , 117 ) ; Size = MAP_APPFONT ( 54 , 10 ) ; TabStop = TRUE ; @@ -519,18 +547,21 @@ TabPage RID_SVXPAGE_AREA }; RadioButton RBT_ROW { + HelpID = "cui:RadioButton:RID_SVXPAGE_AREA:RBT_ROW"; Pos = MAP_APPFONT ( 138 , 144 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; Text [ en-US ] = "Ro~w" ; }; RadioButton RBT_COLUMN { + HelpID = "cui:RadioButton:RID_SVXPAGE_AREA:RBT_COLUMN"; Pos = MAP_APPFONT ( 138 , 158 ) ; Size = MAP_APPFONT ( 75 , 10 ) ; Text [ en-US ] = "Colu~mn" ; }; MetricField MTR_FLD_OFFSET { + HelpID = "cui:MetricField:RID_SVXPAGE_AREA:MTR_FLD_OFFSET"; Border = TRUE ; Pos = MAP_APPFONT ( 219 , 157 ) ; Size = MAP_APPFONT ( 29 , 12 ) ; @@ -560,6 +591,7 @@ TabPage RID_SVXPAGE_SHADOW }; TriStateBox TSB_SHOW_SHADOW { + HelpID = "cui:TriStateBox:RID_SVXPAGE_SHADOW:TSB_SHOW_SHADOW"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 110 , 10 ) ; TabStop = TRUE ; @@ -587,6 +619,7 @@ TabPage RID_SVXPAGE_SHADOW }; MetricField MTR_FLD_DISTANCE { + HelpID = "cui:MetricField:RID_SVXPAGE_SHADOW:MTR_FLD_DISTANCE"; Pos = MAP_APPFONT ( 65 , 67 ) ; Size = MAP_APPFONT ( 47 , 12 ) ; Border = TRUE ; @@ -604,6 +637,7 @@ TabPage RID_SVXPAGE_SHADOW }; ListBox LB_SHADOW_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_SHADOW:LB_SHADOW_COLOR"; Pos = MAP_APPFONT ( 65 , 86 ) ; Size = MAP_APPFONT ( 57 , 100 ) ; DropDown = TRUE ; @@ -625,6 +659,7 @@ TabPage RID_SVXPAGE_SHADOW }; MetricField MTR_SHADOW_TRANSPARENT { + HelpID = "cui:MetricField:RID_SVXPAGE_SHADOW:MTR_SHADOW_TRANSPARENT"; Border = TRUE ; Pos = MAP_APPFONT ( 65 , 105 ) ; Size = MAP_APPFONT ( 47 , 12 ) ; @@ -667,6 +702,7 @@ TabPage RID_SVXPAGE_HATCH }; MetricField MTR_FLD_DISTANCE { + HelpID = "cui:MetricField:RID_SVXPAGE_HATCH:MTR_FLD_DISTANCE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 25 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -689,6 +725,7 @@ TabPage RID_SVXPAGE_HATCH }; MetricField MTR_FLD_ANGLE { + HelpID = "cui:MetricField:RID_SVXPAGE_HATCH:MTR_FLD_ANGLE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 52 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -717,6 +754,7 @@ TabPage RID_SVXPAGE_HATCH }; ListBox LB_LINE_TYPE { + HelpID = "cui:ListBox:RID_SVXPAGE_HATCH:LB_LINE_TYPE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 134 ) ; Size = MAP_APPFONT ( 62 , 62 ) ; @@ -737,6 +775,7 @@ TabPage RID_SVXPAGE_HATCH }; ListBox LB_LINE_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_HATCH:LB_LINE_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 161 ) ; Size = MAP_APPFONT ( 62 , 100 ) ; @@ -746,6 +785,7 @@ TabPage RID_SVXPAGE_HATCH }; ListBox LB_HATCHINGS { + HelpID = "cui:ListBox:RID_SVXPAGE_HATCH:LB_HATCHINGS"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 14 ) ; Size = MAP_APPFONT ( 88 , 110 ) ; @@ -759,6 +799,7 @@ TabPage RID_SVXPAGE_HATCH }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_HATCH:BTN_ADD"; Pos = MAP_APPFONT ( 197 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; @@ -766,6 +807,7 @@ TabPage RID_SVXPAGE_HATCH }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_HATCH:BTN_MODIFY"; Pos = MAP_APPFONT ( 197 , 32 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify..." ; @@ -773,6 +815,7 @@ TabPage RID_SVXPAGE_HATCH }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_HATCH:BTN_DELETE"; Pos = MAP_APPFONT ( 197 , 68 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -780,6 +823,7 @@ TabPage RID_SVXPAGE_HATCH }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_HATCH:BTN_LOAD"; Pos = MAP_APPFONT ( 197 , 104 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -795,6 +839,7 @@ TabPage RID_SVXPAGE_HATCH }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_HATCH:BTN_SAVE"; Pos = MAP_APPFONT ( 197 , 124 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -843,6 +888,7 @@ TabPage RID_SVXPAGE_BITMAP }; ListBox LB_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_BITMAP:LB_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 115 ) ; Size = MAP_APPFONT ( 62 , 100 ) ; @@ -858,6 +904,7 @@ TabPage RID_SVXPAGE_BITMAP }; ListBox LB_BACKGROUND_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_BITMAP:LB_BACKGROUND_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 142 ) ; Size = MAP_APPFONT ( 62 , 100 ) ; @@ -872,6 +919,7 @@ TabPage RID_SVXPAGE_BITMAP }; ListBox LB_BITMAPS { + HelpID = "cui:ListBox:RID_SVXPAGE_BITMAP:LB_BITMAPS"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 14 ) ; Size = MAP_APPFONT ( 88 , 110 ) ; @@ -885,6 +933,7 @@ TabPage RID_SVXPAGE_BITMAP }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_BITMAP:BTN_ADD"; Pos = MAP_APPFONT ( 197 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; @@ -892,6 +941,7 @@ TabPage RID_SVXPAGE_BITMAP }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_BITMAP:BTN_MODIFY"; Pos = MAP_APPFONT ( 197 , 32 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify..." ; @@ -899,6 +949,7 @@ TabPage RID_SVXPAGE_BITMAP }; PushButton BTN_IMPORT { + HelpID = "cui:PushButton:RID_SVXPAGE_BITMAP:BTN_IMPORT"; Pos = MAP_APPFONT ( 197 , 50 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Import..." ; @@ -906,6 +957,7 @@ TabPage RID_SVXPAGE_BITMAP }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_BITMAP:BTN_DELETE"; Pos = MAP_APPFONT ( 197 , 68 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -913,6 +965,7 @@ TabPage RID_SVXPAGE_BITMAP }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_BITMAP:BTN_LOAD"; Pos = MAP_APPFONT ( 197 , 104 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -928,6 +981,7 @@ TabPage RID_SVXPAGE_BITMAP }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_BITMAP:BTN_SAVE"; Pos = MAP_APPFONT ( 197 , 124 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -963,6 +1017,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ListBox LB_GRADIENT_TYPES { + HelpID = "cui:ListBox:RID_SVXPAGE_GRADIENT:LB_GRADIENT_TYPES"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 14 ) ; Size = MAP_APPFONT ( 48, 63 ) ; @@ -986,6 +1041,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_CENTER_X { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_CENTER_X"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 30 ) ; Size = MAP_APPFONT ( 40 , 12 ) ; @@ -1007,6 +1063,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_CENTER_Y { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_CENTER_Y"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 46 ) ; Size = MAP_APPFONT ( 40, 12 ) ; @@ -1028,6 +1085,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_ANGLE { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_ANGLE"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 62 ) ; Size = MAP_APPFONT ( 40, 12 ) ; @@ -1048,6 +1106,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_BORDER { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_BORDER"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 78 ) ; Size = MAP_APPFONT ( 40, 12 ) ; @@ -1069,6 +1128,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ListBox LB_COLOR_FROM { + HelpID = "cui:ListBox:RID_SVXPAGE_GRADIENT:LB_COLOR_FROM"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 97 ) ; Size = MAP_APPFONT ( 48, 100 ) ; @@ -1078,6 +1138,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_COLOR_FROM { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_COLOR_FROM"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 113 ) ; Size = MAP_APPFONT ( 40, 12 ) ; @@ -1099,6 +1160,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ListBox LB_COLOR_TO { + HelpID = "cui:ListBox:RID_SVXPAGE_GRADIENT:LB_COLOR_TO"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 131 ) ; Size = MAP_APPFONT ( 48, 100 ) ; @@ -1108,6 +1170,7 @@ TabPage RID_SVXPAGE_GRADIENT }; MetricField MTR_COLOR_TO { + HelpID = "cui:MetricField:RID_SVXPAGE_GRADIENT:MTR_COLOR_TO"; Border = TRUE ; Pos = MAP_APPFONT ( 49 , 147 ) ; Size = MAP_APPFONT ( 40, 12 ) ; @@ -1123,6 +1186,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ListBox LB_GRADIENTS { + HelpID = "cui:ListBox:RID_SVXPAGE_GRADIENT:LB_GRADIENTS"; Border = TRUE ; Pos = MAP_APPFONT ( 103 , 14 ) ; Size = MAP_APPFONT ( 88 , 110 ) ; @@ -1136,6 +1200,7 @@ TabPage RID_SVXPAGE_GRADIENT }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_GRADIENT:BTN_ADD"; Pos = MAP_APPFONT ( 197 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; @@ -1143,6 +1208,7 @@ TabPage RID_SVXPAGE_GRADIENT }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_GRADIENT:BTN_MODIFY"; Pos = MAP_APPFONT ( 197 , 32 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify..." ; @@ -1150,6 +1216,7 @@ TabPage RID_SVXPAGE_GRADIENT }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_GRADIENT:BTN_DELETE"; Pos = MAP_APPFONT ( 197 , 68 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -1157,6 +1224,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_GRADIENT:BTN_LOAD"; Pos = MAP_APPFONT ( 197 , 104 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -1172,6 +1240,7 @@ TabPage RID_SVXPAGE_GRADIENT }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_GRADIENT:BTN_SAVE"; Pos = MAP_APPFONT ( 197 , 124 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -1208,6 +1277,7 @@ TabPage RID_SVXPAGE_COLOR }; Edit EDT_NAME { + HelpID = "cui:Edit:RID_SVXPAGE_COLOR:EDT_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 14 ) ; Size = MAP_APPFONT ( 76 , 12 ) ; @@ -1221,6 +1291,7 @@ TabPage RID_SVXPAGE_COLOR }; ListBox LB_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_COLOR:LB_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 42 , 30 ) ; Size = MAP_APPFONT ( 76 , 100 ) ; @@ -1258,6 +1329,7 @@ TabPage RID_SVXPAGE_COLOR }; ListBox LB_COLORMODEL { + HelpID = "cui:ListBox:RID_SVXPAGE_COLOR:LB_COLORMODEL"; Border = TRUE ; Pos = MAP_APPFONT ( 157 , 71 ) ; Size = MAP_APPFONT ( 34 , 12 ) ; @@ -1277,6 +1349,7 @@ TabPage RID_SVXPAGE_COLOR }; MetricField MTR_FLD_1 { + HelpID = "cui:MetricField:RID_SVXPAGE_COLOR:MTR_FLD_1"; Border = TRUE ; Pos = MAP_APPFONT ( 157 , 87 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; @@ -1296,6 +1369,7 @@ TabPage RID_SVXPAGE_COLOR }; MetricField MTR_FLD_2 { + HelpID = "cui:MetricField:RID_SVXPAGE_COLOR:MTR_FLD_2"; Border = TRUE ; Pos = MAP_APPFONT ( 157 , 103 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; @@ -1315,6 +1389,7 @@ TabPage RID_SVXPAGE_COLOR }; MetricField MTR_FLD_3 { + HelpID = "cui:MetricField:RID_SVXPAGE_COLOR:MTR_FLD_3"; Border = TRUE ; Pos = MAP_APPFONT ( 157 , 119 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; @@ -1334,6 +1409,7 @@ TabPage RID_SVXPAGE_COLOR }; MetricField MTR_FLD_4 { + HelpID = "cui:MetricField:RID_SVXPAGE_COLOR:MTR_FLD_4"; Border = TRUE ; Pos = MAP_APPFONT ( 157 , 135 ) ; Size = MAP_APPFONT ( 30 , 12 ) ; @@ -1347,6 +1423,7 @@ TabPage RID_SVXPAGE_COLOR }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_COLOR:BTN_ADD"; Pos = MAP_APPFONT ( 197 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add" ; @@ -1354,6 +1431,7 @@ TabPage RID_SVXPAGE_COLOR }; PushButton BTN_WORK_ON { + HelpID = "cui:PushButton:RID_SVXPAGE_COLOR:BTN_WORK_ON"; Pos = MAP_APPFONT ( 197 , 50 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Edit..." ; @@ -1361,6 +1439,7 @@ TabPage RID_SVXPAGE_COLOR }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_COLOR:BTN_DELETE"; Pos = MAP_APPFONT ( 197 , 68 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -1368,6 +1447,7 @@ TabPage RID_SVXPAGE_COLOR }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_COLOR:BTN_MODIFY"; Pos = MAP_APPFONT ( 197, 32 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify" ; @@ -1375,6 +1455,7 @@ TabPage RID_SVXPAGE_COLOR }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_COLOR:BTN_LOAD"; Pos = MAP_APPFONT ( 197 , 104 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -1390,6 +1471,7 @@ TabPage RID_SVXPAGE_COLOR }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_COLOR:BTN_SAVE"; Pos = MAP_APPFONT ( 197 , 124 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -1463,4 +1545,13 @@ TabDialog RID_SVXDLG_AREA }; }; - // ********************************************************************** EOF +String STR_LB_HATCHINGSTYLE +{ + Text [ en-US ] = "Hatching Style" ; +}; + +String STR_CUI_COLORMODEL +{ + Text [ en-US ] = "Color Mode" ; +}; + diff --git a/cui/source/tabpages/tabline.cxx b/cui/source/tabpages/tabline.cxx index d418bff74a19..edd5d339a5e3 100644 --- a/cui/source/tabpages/tabline.cxx +++ b/cui/source/tabpages/tabline.cxx @@ -63,7 +63,7 @@ SvxLineTabDialog::SvxLineTabDialog const SfxItemSet* pAttr, SdrModel* pModel, const SdrObject* pSdrObj, - BOOL bHasObj + sal_Bool bHasObj ) : SfxTabDialog ( pParent, CUI_RES( RID_SVXDLG_LINE ), pAttr ), @@ -87,7 +87,7 @@ SvxLineTabDialog::SvxLineTabDialog nPosLineEndLb( 0 ), mnPos( 0 ), mbAreaTP( sal_False ), - mbDeleteColorTable( TRUE ) + mbDeleteColorTable( sal_True ) { FreeResource(); @@ -204,7 +204,7 @@ short SvxLineTabDialog::Ok() SavePalettes(); // Es wird RET_OK zurueckgeliefert, wenn wenigstens eine - // TabPage in FillItemSet() TRUE zurueckliefert. Dieses + // TabPage in FillItemSet() sal_True zurueckliefert. Dieses // geschieht z.Z. standardmaessig. return( SfxTabDialog::Ok() ); } @@ -222,7 +222,7 @@ IMPL_LINK_INLINE_END( SvxLineTabDialog, CancelHdlImpl, void *, EMPTYARG ) // ----------------------------------------------------------------------- -void SvxLineTabDialog::PageCreated( USHORT nId, SfxTabPage &rPage ) +void SvxLineTabDialog::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { switch( nId ) { diff --git a/cui/source/tabpages/tabline.hrc b/cui/source/tabpages/tabline.hrc index 0034e2126bf5..81e9e99e5061 100644 --- a/cui/source/tabpages/tabline.hrc +++ b/cui/source/tabpages/tabline.hrc @@ -41,6 +41,21 @@ #define FT_LINE_ENDS_WIDTH 6 #define LB_START_STYLE 3 #define LB_END_STYLE 4 +//IAccessibility2 Impplementaton 2009----- +#define STR_STYLE (LB_END_STYLE+1) +#define STR_LB_START_STYLE 30 +#define STR_LB_END_STYLE 31 +#define STR_MTR_FLD_START_WIDTH 32 +#define STR_MTR_FLD_END_WIDTH 33 +#define STR_CENTER_START 34 +#define STR_CENTER_END 35 +#define STR_START_TYPE 36 +#define STR_END_TYPE 37 +#define STR_START_NUM 38 +#define STR_END_NUM 39 +#define STR_START_LENGTH 40 +#define STR_END_LENGTH 41 +//-----IAccessibility2 Impplementaton 2009 #define MTR_FLD_START_WIDTH 3 #define MTR_FLD_END_WIDTH 2 #define CBX_SYNCHRONIZE 1 @@ -103,4 +118,13 @@ #define MN_SYMBOLS_AUTO 5 #define MN_GALLERY_ENTRY 100 - +/* +//IAccessibility2 Implementation 2009----- +#define STR_START_TYPE 1 +#define STR_END_TYPE 2 +#define STR_START_NUM 3 +#define STR_END_NUM 4 +#define STR_START_LENGTH 5 +#define STR_END_LENGTH 6 +//-----IAccessibility2 Implementation 2009 +*/ diff --git a/cui/source/tabpages/tabline.src b/cui/source/tabpages/tabline.src index e16c3d7e9529..de03c1b0a803 100644 --- a/cui/source/tabpages/tabline.src +++ b/cui/source/tabpages/tabline.src @@ -55,6 +55,7 @@ TabPage RID_SVXPAGE_LINE }; ListBox LB_LINE_STYLE { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE:LB_LINE_STYLE"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 25 ) ; Size = MAP_APPFONT ( 100 , 100 ) ; @@ -70,6 +71,7 @@ TabPage RID_SVXPAGE_LINE }; ListBox LB_COLOR { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE:LB_COLOR"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 52 ) ; Size = MAP_APPFONT ( 100 , 100 ) ; @@ -85,6 +87,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MTR_FLD_LINE_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MTR_FLD_LINE_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 79 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -108,6 +111,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MTR_LINE_TRANSPARENT { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MTR_LINE_TRANSPARENT"; Border = TRUE ; Pos = MAP_APPFONT ( 12 , 106 ) ; Size = MAP_APPFONT ( 50 , 12 ) ; @@ -141,6 +145,7 @@ TabPage RID_SVXPAGE_LINE }; ListBox LB_START_STYLE { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE:LB_START_STYLE"; Border = TRUE ; Pos = MAP_APPFONT ( 130 , 25 ) ; Size = MAP_APPFONT ( 57 , 99 ) ; @@ -150,6 +155,7 @@ TabPage RID_SVXPAGE_LINE }; ListBox LB_END_STYLE { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE:LB_END_STYLE"; Border = TRUE ; Pos = MAP_APPFONT ( 191 , 25 ) ; Size = MAP_APPFONT ( 57 , 100 ) ; @@ -165,6 +171,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MTR_FLD_START_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MTR_FLD_START_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 130 , 52 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -182,6 +189,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MTR_FLD_END_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MTR_FLD_END_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 191 , 52 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -199,6 +207,7 @@ TabPage RID_SVXPAGE_LINE }; TriStateBox TSB_CENTER_START { + HelpID = "cui:TriStateBox:RID_SVXPAGE_LINE:TSB_CENTER_START"; Pos = MAP_APPFONT ( 130 , 68 ) ; Size = MAP_APPFONT ( 57 , 10 ) ; Text [ en-US ] = "Ce~nter" ; @@ -206,6 +215,7 @@ TabPage RID_SVXPAGE_LINE }; TriStateBox TSB_CENTER_END { + HelpID = "cui:TriStateBox:RID_SVXPAGE_LINE:TSB_CENTER_END"; Pos = MAP_APPFONT ( 191 , 68 ) ; Size = MAP_APPFONT ( 57 , 10 ) ; Text [ en-US ] = "C~enter" ; @@ -213,6 +223,7 @@ TabPage RID_SVXPAGE_LINE }; CheckBox CBX_SYNCHRONIZE { + HelpID = "cui:CheckBox:RID_SVXPAGE_LINE:CBX_SYNCHRONIZE"; // #116827# // Pos = MAP_APPFONT ( 130 , 107 ) ; Pos = MAP_APPFONT ( 130 , 68 + (16 - 4) ) ; @@ -238,6 +249,7 @@ TabPage RID_SVXPAGE_LINE }; ListBox LB_EDGE_STYLE { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE:LB_EDGE_STYLE"; Border = TRUE ; Pos = MAP_APPFONT ( 130 , 25 + (16 * 6) - 4 ) ; Size = MAP_APPFONT ( 57 , 99 ) ; @@ -273,6 +285,7 @@ TabPage RID_SVXPAGE_LINE MenuButton MB_SYMBOL_BITMAP { + HelpID = "cui:MenuButton:RID_SVXPAGE_LINE:MB_SYMBOL_BITMAP"; Hide = TRUE ; Pos = MAP_APPFONT ( 130 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; @@ -319,6 +332,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MF_SYMBOL_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MF_SYMBOL_WIDTH"; Pos = MAP_APPFONT ( 191 , 30 ); Size = MAP_APPFONT ( 57 , 12 ) ; Border = TRUE ; @@ -345,6 +359,7 @@ TabPage RID_SVXPAGE_LINE }; MetricField MF_SYMBOL_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE:MF_SYMBOL_HEIGHT"; Pos = MAP_APPFONT ( 191 , 46 ); Size = MAP_APPFONT ( 57 , 12 ) ; Border = TRUE ; @@ -364,11 +379,40 @@ TabPage RID_SVXPAGE_LINE }; CheckBox CB_SYMBOL_RATIO { + HelpID = "cui:CheckBox:RID_SVXPAGE_LINE:CB_SYMBOL_RATIO"; Hide = TRUE ; Pos = MAP_APPFONT ( 130 , 62 ); Size = MAP_APPFONT ( 118 , 10 ) ; Text [ en-US ] = "Keep ratio" ; }; + String STR_STYLE + { + Text [ en-US ] = "Style" ; + }; + String STR_LB_START_STYLE + { + Text [ en-US ] = "Start style" ; + }; + String STR_LB_END_STYLE + { + Text [ en-US ] = "End style" ; + }; + String STR_MTR_FLD_START_WIDTH + { + Text [ en-US ] = "Start width" ; + }; + String STR_MTR_FLD_END_WIDTH + { + Text [ en-US ] = "End width" ; + }; + String STR_CENTER_START + { + Text [ en-US ] = "Start with center" ; + }; + String STR_CENTER_END + { + Text [ en-US ] = "End with center" ; + }; }; // Defining LineStyles -------------------- @@ -394,6 +438,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; ListBox LB_TYPE_1 { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE_DEF:LB_TYPE_1"; Border = TRUE ; Pos = MAP_APPFONT ( 66 , 32 ) ; Size = MAP_APPFONT ( 43 , 49 ) ; @@ -407,6 +452,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; ListBox LB_TYPE_2 { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE_DEF:LB_TYPE_2"; Border = TRUE ; Pos = MAP_APPFONT ( 113 , 32 ) ; Size = MAP_APPFONT ( 43 , 49 ) ; @@ -426,6 +472,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; NumericField NUM_FLD_1 { + HelpID = "cui:NumericField:RID_SVXPAGE_LINE_DEF:NUM_FLD_1"; Border = TRUE ; Pos = MAP_APPFONT ( 66 , 48 ) ; Size = MAP_APPFONT ( 43 , 12 ) ; @@ -440,6 +487,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; NumericField NUM_FLD_2 { + HelpID = "cui:NumericField:RID_SVXPAGE_LINE_DEF:NUM_FLD_2"; Border = TRUE ; Pos = MAP_APPFONT ( 113 , 48 ) ; Size = MAP_APPFONT ( 43 , 12 ) ; @@ -460,6 +508,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; MetricField MTR_FLD_LENGTH_1 { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE_DEF:MTR_FLD_LENGTH_1"; Border = TRUE ; Pos = MAP_APPFONT ( 66 , 64 ) ; Size = MAP_APPFONT ( 43 , 12 ) ; @@ -480,6 +529,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; MetricField MTR_FLD_LENGTH_2 { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE_DEF:MTR_FLD_LENGTH_2"; Border = TRUE ; Pos = MAP_APPFONT ( 113 , 64 ) ; Size = MAP_APPFONT ( 43 , 12 ) ; @@ -506,6 +556,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; MetricField MTR_FLD_DISTANCE { + HelpID = "cui:MetricField:RID_SVXPAGE_LINE_DEF:MTR_FLD_DISTANCE"; Border = TRUE ; Pos = MAP_APPFONT ( 66 , 79 ) ; Size = MAP_APPFONT ( 43 , 12 ) ; @@ -524,6 +575,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; CheckBox CBX_SYNCHRONIZE { + HelpID = "cui:CheckBox:RID_SVXPAGE_LINE_DEF:CBX_SYNCHRONIZE"; Pos = MAP_APPFONT ( 12 , 95 ) ; Size = MAP_APPFONT ( 174 , 10 ) ; Text [ en-US ] = "~Fit to line width" ; @@ -540,6 +592,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; ListBox LB_LINESTYLES { + HelpID = "cui:ListBox:RID_SVXPAGE_LINE_DEF:LB_LINESTYLES"; Border = TRUE ; Pos = MAP_APPFONT ( 66 , 14 ) ; Size = MAP_APPFONT ( 120 , 80 ) ; @@ -549,6 +602,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_LINE_DEF:BTN_ADD"; Pos = MAP_APPFONT ( 198 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; @@ -556,6 +610,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_LINE_DEF:BTN_MODIFY"; Pos = MAP_APPFONT ( 198 , 34 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify..." ; @@ -563,6 +618,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_LINE_DEF:BTN_DELETE"; Pos = MAP_APPFONT ( 198 , 54 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -570,6 +626,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_LINE_DEF:BTN_LOAD"; Pos = MAP_APPFONT ( 198 , 74 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -585,6 +642,7 @@ TabPage RID_SVXPAGE_LINE_DEF }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_LINE_DEF:BTN_SAVE"; Pos = MAP_APPFONT ( 198 , 96 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -605,6 +663,30 @@ TabPage RID_SVXPAGE_LINE_DEF Size = MAP_APPFONT ( 248 , 40 ) ; }; + String STR_START_TYPE + { + Text [ en-US ] = "Start type" ; + }; + String STR_END_TYPE + { + Text [ en-US ] = "End type" ; + }; + String STR_START_NUM + { + Text [ en-US ] = "Start number" ; + }; + String STR_END_NUM + { + Text [ en-US ] = "End number" ; + }; + String STR_START_LENGTH + { + Text [ en-US ] = "Start length" ; + }; + String STR_END_LENGTH + { + Text [ en-US ] = "End length" ; + }; }; // Defining LineEnds -------------------- @@ -638,6 +720,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; Edit EDT_NAME { + HelpID = "cui:Edit:RID_SVXPAGE_LINEEND_DEF:EDT_NAME"; Border = TRUE ; Pos = MAP_APPFONT ( 98 , 14 ) ; Size = MAP_APPFONT ( 87 , 12 ) ; @@ -651,6 +734,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; ListBox LB_LINEENDS { + HelpID = "cui:ListBox:RID_SVXPAGE_LINEEND_DEF:LB_LINEENDS"; Border = TRUE ; Pos = MAP_APPFONT ( 98 , 30 ) ; Size = MAP_APPFONT ( 87 , 80 ) ; @@ -660,6 +744,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; PushButton BTN_ADD { + HelpID = "cui:PushButton:RID_SVXPAGE_LINEEND_DEF:BTN_ADD"; Pos = MAP_APPFONT ( 198 , 14 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Add..." ; @@ -667,6 +752,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; PushButton BTN_MODIFY { + HelpID = "cui:PushButton:RID_SVXPAGE_LINEEND_DEF:BTN_MODIFY"; Pos = MAP_APPFONT ( 198 , 34 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Modify..." ; @@ -674,6 +760,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; PushButton BTN_DELETE { + HelpID = "cui:PushButton:RID_SVXPAGE_LINEEND_DEF:BTN_DELETE"; Pos = MAP_APPFONT ( 198 , 54 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete..." ; @@ -681,6 +768,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; ImageButton BTN_LOAD { + HelpID = "cui:ImageButton:RID_SVXPAGE_LINEEND_DEF:BTN_LOAD"; Pos = MAP_APPFONT ( 198 , 74 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; @@ -696,6 +784,7 @@ TabPage RID_SVXPAGE_LINEEND_DEF }; ImageButton BTN_SAVE { + HelpID = "cui:ImageButton:RID_SVXPAGE_LINEEND_DEF:BTN_SAVE"; Pos = MAP_APPFONT ( 198 , 96 ) ; Size = MAP_APPFONT ( 16 , 16 ) ; TabStop = TRUE ; diff --git a/cui/source/tabpages/tabstpge.cxx b/cui/source/tabpages/tabstpge.cxx index 55b6acd21258..e49a21fa33a1 100644 --- a/cui/source/tabpages/tabstpge.cxx +++ b/cui/source/tabpages/tabstpge.cxx @@ -53,10 +53,10 @@ class TabWin_Impl : public Window { private: - USHORT nTabStyle; + sal_uInt16 nTabStyle; public: - TabWin_Impl( Window* pParent, const ResId& rId, USHORT nStyle ) : + TabWin_Impl( Window* pParent, const ResId& rId, sal_uInt16 nStyle ) : Window( pParent, rId ), nTabStyle( nStyle ) {} @@ -65,7 +65,7 @@ public: // static ---------------------------------------------------------------- -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SID_ATTR_TABSTOP, SID_ATTR_TABSTOP_OFFSET, @@ -103,27 +103,27 @@ SvxTabulatorTabPage::SvxTabulatorTabPage( Window* pParent, SfxTabPage( pParent, CUI_RES( RID_SVXPAGE_TABULATOR ), rAttr ), - aTabBox ( this, CUI_RES( ED_TABPOS ) ), aTabLabel ( this, CUI_RES( FL_TABPOS ) ), + aTabBox ( this, CUI_RES( ED_TABPOS ) ), aTabLabelVert ( this, CUI_RES( FL_TABPOS_VERT ) ), + aTabTypeLabel ( this, CUI_RES( FL_TABTYPE ) ), aLeftTab ( this, CUI_RES( BTN_TABTYPE_LEFT ) ), aRightTab ( this, CUI_RES( BTN_TABTYPE_RIGHT ) ), aCenterTab ( this, CUI_RES( BTN_TABTYPE_CENTER ) ), aDezTab ( this, CUI_RES( BTN_TABTYPE_DECIMAL ) ), - pLeftWin ( new TabWin_Impl( this, CUI_RES( WIN_TABLEFT ), (USHORT)(RULER_TAB_LEFT|WB_HORZ) ) ), - pRightWin ( new TabWin_Impl( this, CUI_RES( WIN_TABRIGHT ), (USHORT)(RULER_TAB_RIGHT|WB_HORZ) ) ), - pCenterWin ( new TabWin_Impl( this, CUI_RES( WIN_TABCENTER ), (USHORT)(RULER_TAB_CENTER|WB_HORZ) ) ), - pDezWin ( new TabWin_Impl( this, CUI_RES( WIN_TABDECIMAL ), (USHORT)(RULER_TAB_DECIMAL|WB_HORZ) ) ), + pLeftWin ( new TabWin_Impl( this, CUI_RES( WIN_TABLEFT ), (sal_uInt16)(RULER_TAB_LEFT|WB_HORZ) ) ), + pRightWin ( new TabWin_Impl( this, CUI_RES( WIN_TABRIGHT ), (sal_uInt16)(RULER_TAB_RIGHT|WB_HORZ) ) ), + pCenterWin ( new TabWin_Impl( this, CUI_RES( WIN_TABCENTER ), (sal_uInt16)(RULER_TAB_CENTER|WB_HORZ) ) ), + pDezWin ( new TabWin_Impl( this, CUI_RES( WIN_TABDECIMAL ), (sal_uInt16)(RULER_TAB_DECIMAL|WB_HORZ) ) ), aDezCharLabel ( this, CUI_RES( FT_TABTYPE_DECCHAR ) ), aDezChar ( this, CUI_RES( ED_TABTYPE_DECCHAR ) ), - aTabTypeLabel ( this, CUI_RES( FL_TABTYPE ) ), + aFillLabel ( this, CUI_RES( FL_FILLCHAR ) ), aNoFillChar ( this, CUI_RES( BTN_FILLCHAR_NO ) ), aFillPoints ( this, CUI_RES( BTN_FILLCHAR_POINTS ) ), aFillDashLine ( this, CUI_RES( BTN_FILLCHAR_DASHLINE ) ), aFillSolidLine ( this, CUI_RES( BTN_FILLCHAR_UNDERSCORE ) ), aFillSpecial ( this, CUI_RES( BTN_FILLCHAR_OTHER ) ), aFillChar ( this, CUI_RES( ED_FILLCHAR_OTHER ) ), - aFillLabel ( this, CUI_RES( FL_FILLCHAR ) ), aNewBtn ( this, CUI_RES( BTN_NEW ) ), aDelAllBtn ( this, CUI_RES( BTN_DELALL ) ), aDelBtn ( this, CUI_RES( BTN_DEL ) ), @@ -132,7 +132,7 @@ SvxTabulatorTabPage::SvxTabulatorTabPage( Window* pParent, aNewTabs ( 0, 0, SVX_TAB_ADJUST_LEFT, GetWhich( SID_ATTR_TABSTOP ) ), nDefDist ( 0 ), eDefUnit( FUNIT_100TH_MM ), - bCheck ( FALSE ) + bCheck ( sal_False ) { SvtCJKOptions aCJKOptions; @@ -142,6 +142,7 @@ SvxTabulatorTabPage::SvxTabulatorTabPage( Window* pParent, aRightTab .SetText(String(CUI_RES( ST_RIGHTTAB_ASIAN ))); } + aFillChar.SetAccessibleName(String(CUI_RES( ST_FILLCHAR_OTHER ))); // diese Page braucht ExchangeSupport SetExchangeSupport(); @@ -179,6 +180,22 @@ SvxTabulatorTabPage::SvxTabulatorTabPage( Window* pParent, aTabBox.SetDoubleClickHdl( LINK( this, SvxTabulatorTabPage, SelectHdl_Impl ) ); aTabBox.SetModifyHdl( LINK( this, SvxTabulatorTabPage, ModifyHdl_Impl ) ); + aLeftTab.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + aRightTab.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + aCenterTab.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + aDezTab.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + aDezCharLabel.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + aDezChar.SetAccessibleRelationMemberOf( &aTabTypeLabel ); + + aNoFillChar.SetAccessibleRelationMemberOf( &aFillLabel ); + aFillPoints.SetAccessibleRelationMemberOf( &aFillLabel ); + aFillDashLine.SetAccessibleRelationMemberOf( &aFillLabel ); + aFillSolidLine.SetAccessibleRelationMemberOf( &aFillLabel ); + aFillSpecial.SetAccessibleRelationMemberOf( &aFillLabel ); + aFillChar.SetAccessibleRelationMemberOf( &aFillLabel ); + + aFillChar.SetAccessibleRelationLabeledBy(&aFillSpecial); + // das Default-Dezimalzeichen vom System holen LocaleDataWrapper aLocaleWrapper( ::comphelper::getProcessServiceFactory(), Application::GetSettings().GetLocale() ); aAktTab.GetDecimal() = aLocaleWrapper.getNumDecimalSep().GetChar(0); @@ -197,16 +214,16 @@ SvxTabulatorTabPage::~SvxTabulatorTabPage() // ----------------------------------------------------------------------- -USHORT* SvxTabulatorTabPage::GetRanges() +sal_uInt16* SvxTabulatorTabPage::GetRanges() { return pRanges; } // ----------------------------------------------------------------------- -BOOL SvxTabulatorTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxTabulatorTabPage::FillItemSet( SfxItemSet& rSet ) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; // Hier die Werte aus den Controls eintueten if ( aNewBtn.IsEnabled() ) @@ -228,7 +245,7 @@ BOOL SvxTabulatorTabPage::FillItemSet( SfxItemSet& rSet ) const SfxPoolItem* pLRSpace; // wenn nicht im neuen Set, dann vielleicht im alten if ( SFX_ITEM_SET != - rSet.GetItemState( GetWhich( SID_ATTR_LRSPACE ), TRUE, &pLRSpace ) ) + rSet.GetItemState( GetWhich( SID_ATTR_LRSPACE ), sal_True, &pLRSpace ) ) pLRSpace = GetOldItem( rSet, SID_ATTR_LRSPACE ); if ( pLRSpace && ( (SvxLRSpaceItem*)pLRSpace )->GetTxtFirstLineOfst() < 0 ) @@ -240,7 +257,7 @@ BOOL SvxTabulatorTabPage::FillItemSet( SfxItemSet& rSet ) SvxTabStopItem aTmp( aNewTabs ); aTmp.Remove( 0, aTmp.Count() ); - for ( USHORT i = 0; i < aNewTabs.Count(); ++i ) + for ( sal_uInt16 i = 0; i < aNewTabs.Count(); ++i ) { SvxTabStop aTmpStop = aNewTabs[i]; aTmpStop.GetTabPos() = @@ -251,13 +268,13 @@ BOOL SvxTabulatorTabPage::FillItemSet( SfxItemSet& rSet ) if ( !pOld || !( *( (SvxTabStopItem*)pOld ) == aTmp ) ) { rSet.Put( aTmp ); - bModified = TRUE; + bModified = sal_True; } } else if ( !pOld || !( *( (SvxTabStopItem*)pOld ) == aNewTabs ) ) { rSet.Put( aNewTabs ); - bModified = TRUE; + bModified = sal_True; } return bModified; } @@ -287,7 +304,7 @@ void SvxTabulatorTabPage::Reset( const SfxItemSet& rSet ) SvxTabStopItem aTmp( *( (const SvxTabStopItem*)pItem ) ); aNewTabs.Remove( 0, aNewTabs.Count() ); - for ( USHORT i = 0; i < aTmp.Count(); ++i ) + for ( sal_uInt16 i = 0; i < aTmp.Count(); ++i ) { SvxTabStop aTmpStop = aTmp[i]; aTmpStop.GetTabPos() = @@ -310,7 +327,7 @@ void SvxTabulatorTabPage::Reset( const SfxItemSet& rSet ) (long)((const SfxUInt16Item*)pItem)->GetValue(), eUnit, MAP_100TH_MM ); // Aktuell selektierte Tab-Pos - USHORT nTabPos = 0; + sal_uInt16 nTabPos = 0; pItem = GetItem( rSet, SID_ATTR_TABSTOP_POS ); if ( pItem ) @@ -321,7 +338,7 @@ void SvxTabulatorTabPage::Reset( const SfxItemSet& rSet ) // ----------------------------------------------------------------------- -void SvxTabulatorTabPage::DisableControls( const USHORT nFlag ) +void SvxTabulatorTabPage::DisableControls( const sal_uInt16 nFlag ) { if ( ( TABTYPE_LEFT & nFlag ) == TABTYPE_LEFT ) { @@ -375,13 +392,13 @@ int SvxTabulatorTabPage::DeactivatePage( SfxItemSet* _pSet ) // ----------------------------------------------------------------------- -void SvxTabulatorTabPage::InitTabPos_Impl( USHORT nTabPos ) +void SvxTabulatorTabPage::InitTabPos_Impl( sal_uInt16 nTabPos ) { aTabBox.Clear(); long nOffset = 0; const SfxPoolItem* pItem = 0; - if ( GetItemSet().GetItemState( SID_ATTR_TABSTOP_OFFSET, TRUE, &pItem ) + if ( GetItemSet().GetItemState( SID_ATTR_TABSTOP_OFFSET, sal_True, &pItem ) == SFX_ITEM_SET ) { nOffset = ( (const SfxInt32Item*)pItem )->GetValue(); @@ -390,7 +407,7 @@ void SvxTabulatorTabPage::InitTabPos_Impl( USHORT nTabPos ) } // Aktuelle TabPos korrigieren und Defaults-Tabs - for ( USHORT i = 0; i < aNewTabs.Count(); i++ ) + for ( sal_uInt16 i = 0; i < aNewTabs.Count(); i++ ) { if ( aNewTabs[i].GetAdjustment() != SVX_TAB_ADJUST_DEFAULT ) { @@ -402,14 +419,14 @@ void SvxTabulatorTabPage::InitTabPos_Impl( USHORT nTabPos ) } // aktuellen Tabulator auswaehlen - const USHORT nSize = aNewTabs.Count(); + const sal_uInt16 nSize = aNewTabs.Count(); if ( nTabPos >= nSize ) nTabPos = 0; // alle RadioButtons erstmal ausschalten - aLeftTab.Check( TRUE ); - aNoFillChar.Check( TRUE ); + aLeftTab.Check( sal_True ); + aNoFillChar.Check( sal_True ); if( aTabBox.GetEntryCount() > 0 ) { @@ -492,7 +509,7 @@ IMPL_LINK( SvxTabulatorTabPage, NewHdl_Impl, Button *, pBtn ) long nOffset = 0; const SfxPoolItem* pItem = 0; - if ( GetItemSet().GetItemState( SID_ATTR_TABSTOP_OFFSET, TRUE, &pItem ) == + if ( GetItemSet().GetItemState( SID_ATTR_TABSTOP_OFFSET, sal_True, &pItem ) == SFX_ITEM_SET ) { nOffset = ( (const SfxInt32Item*)pItem )->GetValue(); @@ -500,9 +517,9 @@ IMPL_LINK( SvxTabulatorTabPage, NewHdl_Impl, Button *, pBtn ) nOffset = OutputDevice::LogicToLogic( nOffset, eUnit, MAP_100TH_MM ); } const long nReal = nVal - nOffset; - USHORT nSize = aTabBox.GetEntryCount(); + sal_uInt16 nSize = aTabBox.GetEntryCount(); - USHORT i; + sal_uInt16 i; for( i = 0; i < nSize; i++ ) { if ( nReal < aNewTabs[i].GetTabPos() ) @@ -530,7 +547,7 @@ IMPL_LINK( SvxTabulatorTabPage, NewHdl_Impl, Button *, pBtn ) // falls kein RadioButton geclickt wurde, // muss trotzdem geputtet werden - bCheck |= TRUE; + bCheck |= sal_True; // set the selection into the position Edit aTabBox.SetSelection(Selection(0, aTabBox.GetText().Len())); return 0; @@ -540,7 +557,7 @@ IMPL_LINK( SvxTabulatorTabPage, NewHdl_Impl, Button *, pBtn ) IMPL_LINK( SvxTabulatorTabPage, DelHdl_Impl, Button *, EMPTYARG ) { - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue() ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue() ); if ( nPos == COMBOBOX_ENTRY_NOTFOUND ) return 0; @@ -556,7 +573,7 @@ IMPL_LINK( SvxTabulatorTabPage, DelHdl_Impl, Button *, EMPTYARG ) aNewTabs.Remove( nPos ); // aAktTab neu setzen - const USHORT nSize = aNewTabs.Count(); + const sal_uInt16 nSize = aNewTabs.Count(); if ( nSize > 0 ) { @@ -576,7 +593,7 @@ IMPL_LINK( SvxTabulatorTabPage, DelHdl_Impl, Button *, EMPTYARG ) // falls kein RadioButton geclickt wurde, // muss trotzdem geputtet werden - bCheck |= TRUE; + bCheck |= sal_True; return 0; } @@ -590,7 +607,7 @@ IMPL_LINK( SvxTabulatorTabPage, DelAllHdl_Impl, Button *, EMPTYARG ) InitTabPos_Impl(); // damit in FillItemSet() geputtet wird - bCheck |= TRUE; + bCheck |= sal_True; } return 0; } @@ -599,7 +616,7 @@ IMPL_LINK( SvxTabulatorTabPage, DelAllHdl_Impl, Button *, EMPTYARG ) IMPL_LINK( SvxTabulatorTabPage, TabTypeCheckHdl_Impl, RadioButton *, pBox ) { - bCheck |= TRUE; + bCheck |= sal_True; SvxTabAdjust eAdj; aDezChar.Disable(); aDezCharLabel.Disable(); @@ -620,7 +637,7 @@ IMPL_LINK( SvxTabulatorTabPage, TabTypeCheckHdl_Impl, RadioButton *, pBox ) } aAktTab.GetAdjustment() = eAdj; - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { @@ -634,8 +651,8 @@ IMPL_LINK( SvxTabulatorTabPage, TabTypeCheckHdl_Impl, RadioButton *, pBox ) IMPL_LINK( SvxTabulatorTabPage, FillTypeCheckHdl_Impl, RadioButton *, pBox ) { - bCheck |= TRUE; - BYTE cFill = ' '; + bCheck |= sal_True; + sal_uInt8 cFill = ' '; aFillChar.SetText( String() ); aFillChar.Disable(); @@ -651,7 +668,7 @@ IMPL_LINK( SvxTabulatorTabPage, FillTypeCheckHdl_Impl, RadioButton *, pBox ) cFill = '-'; aAktTab.GetFill() = cFill; - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { @@ -670,7 +687,7 @@ IMPL_LINK( SvxTabulatorTabPage, GetFillCharHdl_Impl, Edit *, pEdit ) if ( aChar.Len() > 0 ) aAktTab.GetFill() = aChar.GetChar( 0 ); - const USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit); + const sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { aNewTabs.Remove( nPos ); @@ -687,7 +704,7 @@ IMPL_LINK( SvxTabulatorTabPage, GetDezCharHdl_Impl, Edit *, pEdit ) if ( aChar.Len() > 0 && ( aChar.GetChar( 0 ) >= ' ')) aAktTab.GetDecimal() = aChar.GetChar( 0 ); - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { aNewTabs.Remove( nPos ); @@ -700,7 +717,7 @@ IMPL_LINK( SvxTabulatorTabPage, GetDezCharHdl_Impl, Edit *, pEdit ) IMPL_LINK( SvxTabulatorTabPage, SelectHdl_Impl, MetricBox *, EMPTYARG ) { - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { aAktTab = aNewTabs[nPos]; @@ -714,7 +731,7 @@ IMPL_LINK( SvxTabulatorTabPage, SelectHdl_Impl, MetricBox *, EMPTYARG ) IMPL_LINK( SvxTabulatorTabPage, ModifyHdl_Impl, MetricBox *, EMPTYARG ) { - USHORT nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); + sal_uInt16 nPos = aTabBox.GetValuePos( aTabBox.GetValue( eDefUnit ), eDefUnit ); if ( nPos != COMBOBOX_ENTRY_NOTFOUND ) { aAktTab = aNewTabs[nPos]; diff --git a/cui/source/tabpages/tabstpge.hrc b/cui/source/tabpages/tabstpge.hrc index be3823fd9cd4..40bcc35dba0d 100644 --- a/cui/source/tabpages/tabstpge.hrc +++ b/cui/source/tabpages/tabstpge.hrc @@ -59,5 +59,8 @@ #define BTN_DELALL 52 #define ST_LEFTTAB_ASIAN 53 #define ST_RIGHTTAB_ASIAN 54 +//IAccessibility2 Implementation 2009----- +#define ST_FILLCHAR_OTHER 55 +//-----IAccessibility2 Implementation 2009 #endif diff --git a/cui/source/tabpages/tabstpge.src b/cui/source/tabpages/tabstpge.src index 3bd0467f2f0c..e4f2c600a87e 100644 --- a/cui/source/tabpages/tabstpge.src +++ b/cui/source/tabpages/tabstpge.src @@ -45,6 +45,7 @@ TabPage RID_SVXPAGE_TABULATOR }; MetricBox ED_TABPOS { + HelpID = "cui:MetricBox:RID_SVXPAGE_TABULATOR:ED_TABPOS"; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 39 , 165 ) ; Minimum = -5600 ; @@ -66,6 +67,7 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_TABTYPE_LEFT { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_TABTYPE_LEFT"; Pos = MAP_APPFONT ( 66 , 14 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "~Left" ; @@ -78,6 +80,7 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_TABTYPE_RIGHT { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_TABTYPE_RIGHT"; Pos = MAP_APPFONT ( 66 , 28 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "Righ~t" ; @@ -89,6 +92,7 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_TABTYPE_CENTER { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_TABTYPE_CENTER"; Pos = MAP_APPFONT ( 66 , 42 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "C~entered" ; @@ -100,6 +104,7 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_TABTYPE_DECIMAL { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_TABTYPE_DECIMAL"; Pos = MAP_APPFONT ( 66 , 56 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "Deci~mal" ; @@ -117,6 +122,7 @@ TabPage RID_SVXPAGE_TABULATOR }; Edit ED_TABTYPE_DECCHAR { + HelpID = "cui:Edit:RID_SVXPAGE_TABULATOR:ED_TABTYPE_DECCHAR"; Border = TRUE ; Pos = MAP_APPFONT ( 156 , 68 ) ; Size = MAP_APPFONT ( 9 , 12 ) ; @@ -130,6 +136,7 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_FILLCHAR_NO { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_FILLCHAR_NO"; Pos = MAP_APPFONT ( 66 , 97 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "N~one" ; @@ -137,30 +144,35 @@ TabPage RID_SVXPAGE_TABULATOR }; RadioButton BTN_FILLCHAR_POINTS { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_FILLCHAR_POINTS"; Pos = MAP_APPFONT ( 66 , 111 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text = "~........" ; }; RadioButton BTN_FILLCHAR_DASHLINE { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_FILLCHAR_DASHLINE"; Pos = MAP_APPFONT ( 66 , 125 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text = "~--------" ; }; RadioButton BTN_FILLCHAR_UNDERSCORE { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_FILLCHAR_UNDERSCORE"; Pos = MAP_APPFONT ( 66 , 139 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text = "~_____" ; }; RadioButton BTN_FILLCHAR_OTHER { + HelpID = "cui:RadioButton:RID_SVXPAGE_TABULATOR:BTN_FILLCHAR_OTHER"; Pos = MAP_APPFONT ( 66 , 153 ) ; Size = MAP_APPFONT ( 89 , 10 ) ; Text [ en-US ] = "Character" ; }; Edit ED_FILLCHAR_OTHER { + HelpID = "cui:Edit:RID_SVXPAGE_TABULATOR:ED_FILLCHAR_OTHER"; Border = TRUE ; Pos = MAP_APPFONT ( 156 , 151 ) ; Size = MAP_APPFONT ( 9 , 12 ) ; @@ -168,18 +180,21 @@ TabPage RID_SVXPAGE_TABULATOR }; PushButton BTN_NEW { + HelpID = "cui:PushButton:RID_SVXPAGE_TABULATOR:BTN_NEW"; Pos = MAP_APPFONT ( 204 , 6 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~New" ; }; PushButton BTN_DELALL { + HelpID = "cui:PushButton:RID_SVXPAGE_TABULATOR:BTN_DELALL"; Pos = MAP_APPFONT ( 204 , 23 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "Delete ~All" ; }; PushButton BTN_DEL { + HelpID = "cui:PushButton:RID_SVXPAGE_TABULATOR:BTN_DEL"; Pos = MAP_APPFONT ( 204 , 40 ) ; Size = MAP_APPFONT ( 50 , 14 ) ; Text [ en-US ] = "~Delete" ; @@ -192,40 +207,9 @@ TabPage RID_SVXPAGE_TABULATOR { Text [ en-US ] = "Righ~t/Bottom" ; }; + String ST_FILLCHAR_OTHER + { + Text [ en-US ] = "Character" ; + }; }; - // ********************************************************************** EOF - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/cui/source/tabpages/textanim.cxx b/cui/source/tabpages/textanim.cxx index c7c38975a6d2..44051fcee53e 100644 --- a/cui/source/tabpages/textanim.cxx +++ b/cui/source/tabpages/textanim.cxx @@ -43,7 +43,7 @@ #include <dialmgr.hxx> #include "svx/dlgutil.hxx" -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SDRATTR_TEXT_ANIKIND, SDRATTR_TEXT_ANIAMOUNT, @@ -75,7 +75,7 @@ SvxTextTabDialog::SvxTextTabDialog( Window* pParent, |* \************************************************************************/ -void SvxTextTabDialog::PageCreated( USHORT nId, SfxTabPage &rPage ) +void SvxTextTabDialog::PageCreated( sal_uInt16 nId, SfxTabPage &rPage ) { switch( nId ) { @@ -156,6 +156,24 @@ SvxTextAnimationPage::SvxTextAnimationPage( Window* pWindow, const SfxItemSet& r aBtnLeft.SetClickHdl( aLink ); aBtnRight.SetClickHdl( aLink ); aBtnDown.SetClickHdl( aLink ); + + aNumFldCount.SetAccessibleRelationLabeledBy( &aTsbEndless ); + aMtrFldAmount.SetAccessibleRelationLabeledBy( &aTsbPixel ); + aMtrFldDelay.SetAccessibleRelationLabeledBy( &aTsbAuto ); + + aBtnUp.SetAccessibleRelationLabeledBy( &aFtDirection ); + aBtnLeft.SetAccessibleRelationLabeledBy( &aFtDirection ); + aBtnRight.SetAccessibleRelationLabeledBy( &aFtDirection ); + aBtnDown.SetAccessibleRelationLabeledBy( &aFtDirection ); + + aBtnUp.SetAccessibleRelationMemberOf( &aFlEffect ); + aBtnLeft.SetAccessibleRelationMemberOf( &aFlEffect ); + aBtnRight.SetAccessibleRelationMemberOf( &aFlEffect ); + aBtnDown.SetAccessibleRelationMemberOf( &aFlEffect ); + + aTsbEndless.SetAccessibleRelationLabeledBy( &aFtCount ); + aTsbPixel.SetAccessibleRelationLabeledBy( &aFtAmount ); + aTsbAuto.SetAccessibleRelationLabeledBy( &aFtDelay ); } /************************************************************************* @@ -186,7 +204,7 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) if( pItem ) { eAniKind = ( ( const SdrTextAniKindItem* )pItem )->GetValue(); - aLbEffect.SelectEntryPos( sal::static_int_cast< USHORT >(eAniKind) ); + aLbEffect.SelectEntryPos( sal::static_int_cast< sal_uInt16 >(eAniKind) ); } else aLbEffect.SetNoSelection(); @@ -203,10 +221,10 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) } else { - aBtnUp.Check( FALSE ); - aBtnLeft.Check( FALSE ); - aBtnRight.Check( FALSE ); - aBtnDown.Check( FALSE ); + aBtnUp.Check( sal_False ); + aBtnLeft.Check( sal_False ); + aBtnRight.Check( sal_False ); + aBtnDown.Check( sal_False ); } aBtnUp.SaveValue(); aBtnLeft.SaveValue(); @@ -219,8 +237,8 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_TEXT_ANISTARTINSIDE ); if( pItem ) { - aTsbStartInside.EnableTriState( FALSE ); - BOOL bValue = ( ( const SdrTextAniStartInsideItem* )pItem )->GetValue(); + aTsbStartInside.EnableTriState( sal_False ); + sal_Bool bValue = ( ( const SdrTextAniStartInsideItem* )pItem )->GetValue(); if( bValue ) aTsbStartInside.SetState( STATE_CHECK ); else @@ -236,8 +254,8 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_TEXT_ANISTOPINSIDE ); if( pItem ) { - aTsbStopInside.EnableTriState( FALSE ); - BOOL bValue = ( ( const SdrTextAniStopInsideItem* )pItem )->GetValue(); + aTsbStopInside.EnableTriState( sal_False ); + sal_Bool bValue = ( ( const SdrTextAniStopInsideItem* )pItem )->GetValue(); if( bValue ) aTsbStopInside.SetState( STATE_CHECK ); else @@ -253,7 +271,7 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_TEXT_ANICOUNT ); if( pItem ) { - aTsbEndless.EnableTriState( FALSE ); + aTsbEndless.EnableTriState( sal_False ); long nValue = (long) ( ( const SdrTextAniCountItem* )pItem )->GetValue(); aNumFldCount.SetValue( nValue ); if( nValue == 0 ) @@ -261,7 +279,7 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) if( eAniKind == SDRTEXTANI_SLIDE ) { aTsbEndless.SetState( STATE_NOCHECK ); - aTsbEndless.Enable( FALSE ); + aTsbEndless.Enable( sal_False ); } else { @@ -286,7 +304,7 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_TEXT_ANIDELAY ); if( pItem ) { - aTsbAuto.EnableTriState( FALSE ); + aTsbAuto.EnableTriState( sal_False ); long nValue = (long) ( ( const SdrTextAniDelayItem* )pItem )->GetValue(); aMtrFldDelay.SetValue( nValue ); if( nValue == 0 ) @@ -311,7 +329,7 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) pItem = &pPool->GetDefaultItem( SDRATTR_TEXT_ANIAMOUNT ); if( pItem ) { - aTsbPixel.EnableTriState( FALSE ); + aTsbPixel.EnableTriState( sal_False ); long nValue = (long) ( ( const SdrTextAniAmountItem* )pItem )->GetValue(); if( nValue <= 0 ) { @@ -367,10 +385,10 @@ void SvxTextAnimationPage::Reset( const SfxItemSet& rAttrs ) |* \************************************************************************/ -BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) +sal_Bool SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) { - BOOL bModified = FALSE; - USHORT nPos; + sal_Bool bModified = sal_False; + sal_uInt16 nPos; TriState eState; // Animationstyp @@ -379,7 +397,7 @@ BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) nPos != aLbEffect.GetSavedValue() ) { rAttrs.Put( SdrTextAniKindItem( (SdrTextAniKind) nPos ) ); - bModified = TRUE; + bModified = sal_True; } // Animationsrichtung @@ -390,23 +408,23 @@ BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) { SdrTextAniDirection eValue = (SdrTextAniDirection) GetSelectedDirection(); rAttrs.Put( SdrTextAniDirectionItem( eValue ) ); - bModified = TRUE; + bModified = sal_True; } // Start inside eState = aTsbStartInside.GetState(); if( eState != aTsbStartInside.GetSavedValue() ) { - rAttrs.Put( SdrTextAniStartInsideItem( (BOOL) STATE_CHECK == eState ) ); - bModified = TRUE; + rAttrs.Put( SdrTextAniStartInsideItem( (sal_Bool) STATE_CHECK == eState ) ); + bModified = sal_True; } // Stop inside eState = aTsbStopInside.GetState(); if( eState != aTsbStopInside.GetSavedValue() ) { - rAttrs.Put( SdrTextAniStopInsideItem( (BOOL) STATE_CHECK == eState ) ); - bModified = TRUE; + rAttrs.Put( SdrTextAniStopInsideItem( (sal_Bool) STATE_CHECK == eState ) ); + bModified = sal_True; } // Anzahl @@ -417,17 +435,17 @@ BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) { sal_Int64 nValue = 0; if( eState == STATE_CHECK /*#89844#*/ && aTsbEndless.IsEnabled()) - bModified = TRUE; + bModified = sal_True; else { if( aStr != aNumFldCount.GetSavedValue() ) { nValue = aNumFldCount.GetValue(); - bModified = TRUE; + bModified = sal_True; } } if( bModified ) - rAttrs.Put( SdrTextAniCountItem( (UINT16) nValue ) ); + rAttrs.Put( SdrTextAniCountItem( (sal_uInt16) nValue ) ); } // Verzoegerung @@ -438,17 +456,17 @@ BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) { sal_Int64 nValue = 0; if( eState == STATE_CHECK ) - bModified = TRUE; + bModified = sal_True; else { if( aStr != aMtrFldDelay.GetSavedValue() ) { nValue = aMtrFldDelay.GetValue(); - bModified = TRUE; + bModified = sal_True; } } if( bModified ) - rAttrs.Put( SdrTextAniDelayItem( (UINT16) nValue ) ); + rAttrs.Put( SdrTextAniDelayItem( (sal_uInt16) nValue ) ); } // Schrittweite @@ -467,9 +485,9 @@ BOOL SvxTextAnimationPage::FillItemSet( SfxItemSet& rAttrs) { nValue = GetCoreValue( aMtrFldAmount, eUnit ); } - rAttrs.Put( SdrTextAniAmountItem( (INT16) nValue ) ); + rAttrs.Put( SdrTextAniAmountItem( (sal_Int16) nValue ) ); - bModified = TRUE; + bModified = sal_True; } return( bModified ); @@ -491,7 +509,7 @@ void SvxTextAnimationPage::Construct() |* \************************************************************************/ -USHORT* SvxTextAnimationPage::GetRanges() +sal_uInt16* SvxTextAnimationPage::GetRanges() { return( pRanges ); } @@ -516,7 +534,7 @@ SfxTabPage* SvxTextAnimationPage::Create( Window* pWindow, IMPL_LINK( SvxTextAnimationPage, SelectEffectHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbEffect.GetSelectEntryPos(); + sal_uInt16 nPos = aLbEffect.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { eAniKind = (SdrTextAniKind) nPos; @@ -736,9 +754,9 @@ void SvxTextAnimationPage::SelectDirection( SdrTextAniDirection nValue ) |* \************************************************************************/ -USHORT SvxTextAnimationPage::GetSelectedDirection() +sal_uInt16 SvxTextAnimationPage::GetSelectedDirection() { - USHORT nValue = 0; + sal_uInt16 nValue = 0; if( aBtnUp.IsChecked() ) nValue = SDRTEXTANI_UP; diff --git a/cui/source/tabpages/textanim.src b/cui/source/tabpages/textanim.src index 229875a6ad4d..4f2ffda07519 100644 --- a/cui/source/tabpages/textanim.src +++ b/cui/source/tabpages/textanim.src @@ -71,6 +71,7 @@ // RID_SVXPAGE_TEXTANIMATION --------------------------------------------- TabPage RID_SVXPAGE_TEXTANIMATION { + HelpID = "cui:TabPage:RID_SVXPAGE_TEXTANIMATION"; SVLook = TRUE ; Hide = TRUE ; Size = MAP_APPFONT ( MA_TOTAL_WIDTH , 185 ) ; @@ -91,6 +92,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; ListBox LB_EFFECT { + HelpID = "cui:ListBox:RID_SVXPAGE_TEXTANIMATION:LB_EFFECT"; Border = TRUE ; Pos = MAP_APPFONT ( MA_EFFECTLIST_X, MA_CURR_Y + 1 ) ; Size = MAP_APPFONT ( MA_EFFECTLIST_WIDTH , 57 ) ; @@ -117,6 +119,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; ImageButton BTN_UP { + HelpID = "cui:ImageButton:RID_SVXPAGE_TEXTANIMATION:BTN_UP"; Pos = MAP_APPFONT ( MA_TOTAL_WIDTH - MA_MOVEBUT_GRACE_X - 2*MA_BUTTON_WIDTH - RSC_SP_TBPG_INNERBORDER_RIGHT - RSC_SP_FLGR_INNERBORDER_RIGHT, RSC_SP_TBPG_INNERBORDER_TOP + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP ); Size = BUTTON_SIZE ; @@ -125,6 +128,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; ImageButton BTN_LEFT { + HelpID = "cui:ImageButton:RID_SVXPAGE_TEXTANIMATION:BTN_LEFT"; Pos = MAP_APPFONT ( MA_TOTAL_WIDTH - MA_MOVEBUT_GRACE_X - 3*MA_BUTTON_WIDTH - RSC_SP_TBPG_INNERBORDER_RIGHT - RSC_SP_FLGR_INNERBORDER_RIGHT, RSC_SP_TBPG_INNERBORDER_TOP + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP + MA_BUTTON_HEIGHT); Size = BUTTON_SIZE ; @@ -133,6 +137,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; ImageButton BTN_RIGHT { + HelpID = "cui:ImageButton:RID_SVXPAGE_TEXTANIMATION:BTN_RIGHT"; Pos = MAP_APPFONT ( MA_TOTAL_WIDTH - MA_MOVEBUT_GRACE_X - MA_BUTTON_WIDTH - RSC_SP_TBPG_INNERBORDER_RIGHT - RSC_SP_FLGR_INNERBORDER_RIGHT, RSC_SP_TBPG_INNERBORDER_TOP + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP + MA_BUTTON_HEIGHT ) ; Size = BUTTON_SIZE ; @@ -141,6 +146,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; ImageButton BTN_DOWN { + HelpID = "cui:ImageButton:RID_SVXPAGE_TEXTANIMATION:BTN_DOWN"; Pos = MAP_APPFONT ( MA_TOTAL_WIDTH - MA_MOVEBUT_GRACE_X - 2*MA_BUTTON_WIDTH - RSC_SP_TBPG_INNERBORDER_RIGHT - RSC_SP_FLGR_INNERBORDER_RIGHT, RSC_SP_TBPG_INNERBORDER_TOP + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP + 2*MA_BUTTON_HEIGHT ) ; Size = BUTTON_SIZE ; @@ -157,6 +163,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION #define MA_CURR_Y2 RSC_SP_TBPG_INNERBORDER_TOP + MA_EFFECTSGROUP_HEIGHT + RSC_CD_FIXEDLINE_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP TriStateBox TSB_START_INSIDE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTANIMATION:TSB_START_INSIDE"; TabStop = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT, MA_CURR_Y2 ) ; Size = MAP_APPFONT ( MA_TOTAL_WIDTH - RSC_SP_TBPG_INNERBORDER_LEFT - RSC_SP_TBPG_INNERBORDER_RIGHT - 12, RSC_CD_CHECKBOX_HEIGHT ); @@ -165,6 +172,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION #define MA_CURR_Y3 MA_CURR_Y2 + RSC_CD_CHECKBOX_HEIGHT + RSC_SP_CTRL_GROUP_Y TriStateBox TSB_STOP_INSIDE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTANIMATION:TSB_STOP_INSIDE"; TabStop = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT, MA_CURR_Y3 ) ; Size = MAP_APPFONT ( MA_TOTAL_WIDTH - RSC_SP_TBPG_INNERBORDER_LEFT - RSC_SP_TBPG_INNERBORDER_RIGHT - 12, RSC_CD_CHECKBOX_HEIGHT ); @@ -181,6 +189,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION #define MA_CURR_Y5 MA_CURR_Y4 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP TriStateBox TSB_ENDLESS { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTANIMATION:TSB_ENDLESS"; TabStop = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 9 , MA_CURR_Y5 + 2 ) ; Size = MAP_APPFONT ( 71 , RSC_CD_CHECKBOX_HEIGHT ) ; @@ -188,6 +197,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; NumericField NUM_FLD_COUNT { + HelpID = "cui:NumericField:RID_SVXPAGE_TEXTANIMATION:NUM_FLD_COUNT"; Border = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 80 + RSC_SP_CTRL_GROUP_X, MA_CURR_Y5 ) ; @@ -209,6 +219,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION #define MA_CURR_Y7 MA_CURR_Y6 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP TriStateBox TSB_PIXEL { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTANIMATION:TSB_PIXEL"; TabStop = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 9 , MA_CURR_Y7 + 2 ) ; Size = MAP_APPFONT ( 71 , RSC_CD_CHECKBOX_HEIGHT ) ; @@ -216,6 +227,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; MetricField MTR_FLD_AMOUNT { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTANIMATION:MTR_FLD_AMOUNT"; Border = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 80 + RSC_SP_CTRL_GROUP_X, MA_CURR_Y7 ) ; @@ -242,6 +254,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION #define MA_CURR_Y9 MA_CURR_Y8 + RSC_CD_FIXEDTEXT_HEIGHT + RSC_SP_FLGR_INNERBORDER_TOP TriStateBox TSB_AUTO { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTANIMATION:TSB_AUTO"; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 9 , MA_CURR_Y9 + 2 ) ; Size = MAP_APPFONT ( 71 , RSC_CD_CHECKBOX_HEIGHT ) ; TabStop = TRUE ; @@ -249,6 +262,7 @@ TabPage RID_SVXPAGE_TEXTANIMATION }; MetricField MTR_FLD_DELAY { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTANIMATION:MTR_FLD_DELAY"; Border = TRUE ; Pos = MAP_APPFONT ( RSC_SP_TBPG_INNERBORDER_LEFT + RSC_SP_FLGR_INNERBORDER_LEFT + 80 + RSC_SP_CTRL_GROUP_X, MA_CURR_Y9 ) ; diff --git a/cui/source/tabpages/textattr.cxx b/cui/source/tabpages/textattr.cxx index 8a4a59fa238f..ba83ce16c707 100644 --- a/cui/source/tabpages/textattr.cxx +++ b/cui/source/tabpages/textattr.cxx @@ -54,7 +54,7 @@ #include <svx/ofaitem.hxx> #include <editeng/writingmodeitem.hxx> -static USHORT pRanges[] = +static sal_uInt16 pRanges[] = { SDRATTR_MISC_FIRST, SDRATTR_TEXT_HORZADJUST, SDRATTR_TEXT_WORDWRAP, SDRATTR_TEXT_AUTOGROWSIZE, @@ -113,6 +113,8 @@ SvxTextAttrPage::SvxTextAttrPage( Window* pWindow, const SfxItemSet& rInAttrs ) aTsbFullWidth.SetClickHdl( LINK( this, SvxTextAttrPage, ClickFullWidthHdl_Impl ) ); + + aCtlPosition.SetAccessibleRelationMemberOf( &aFlPosition ); } /************************************************************************* @@ -195,7 +197,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) { aTsbAutoGrowHeight.SetState( ( ( const SdrTextAutoGrowHeightItem& )rAttrs.Get( SDRATTR_TEXT_AUTOGROWHEIGHT ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbAutoGrowHeight.EnableTriState( FALSE ); + aTsbAutoGrowHeight.EnableTriState( sal_False ); } else aTsbAutoGrowHeight.SetState( STATE_DONTKNOW ); @@ -206,7 +208,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) { aTsbAutoGrowWidth.SetState( ( ( const SdrTextAutoGrowWidthItem& )rAttrs.Get( SDRATTR_TEXT_AUTOGROWWIDTH ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbAutoGrowWidth.EnableTriState( FALSE ); + aTsbAutoGrowWidth.EnableTriState( sal_False ); } else aTsbAutoGrowWidth.SetState( STATE_DONTKNOW ); @@ -217,7 +219,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) { aTsbAutoGrowSize.SetState( ( ( const SdrTextAutoGrowHeightItem& )rAttrs.Get( SDRATTR_TEXT_AUTOGROWHEIGHT ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbAutoGrowSize.EnableTriState( FALSE ); + aTsbAutoGrowSize.EnableTriState( sal_False ); } else aTsbAutoGrowSize.SetState( STATE_DONTKNOW ); @@ -228,7 +230,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) { aTsbWordWrapText.SetState( ( ( const SdrTextWordWrapItem& )rAttrs.Get( SDRATTR_TEXT_WORDWRAP ) ). GetValue() ? STATE_CHECK : STATE_NOCHECK ); - aTsbWordWrapText.EnableTriState( FALSE ); + aTsbWordWrapText.EnableTriState( sal_False ); } else aTsbWordWrapText.SetState( STATE_DONTKNOW ); @@ -247,7 +249,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) SdrTextHorzAdjust eTHA = (SdrTextHorzAdjust)((const SdrTextHorzAdjustItem&)rAttrs.Get(SDRATTR_TEXT_HORZADJUST)).GetValue(); RECT_POINT eRP = RP_LB; - aTsbFullWidth.EnableTriState( FALSE ); + aTsbFullWidth.EnableTriState( sal_False ); // Translate item values into local anchor position. switch (eTVA) @@ -321,7 +323,7 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) SdrFitToSizeType eFTS = (SdrFitToSizeType) ( ( const SdrTextFitToSizeTypeItem& )rAttrs.Get( SDRATTR_TEXT_FITTOSIZE ) ).GetValue(); aTsbFitToSize.SetState( eFTS == SDRTEXTFIT_NONE ? STATE_NOCHECK : STATE_CHECK ); - aTsbFitToSize.EnableTriState( FALSE ); + aTsbFitToSize.EnableTriState( sal_False ); } else aTsbFitToSize.SetState( STATE_DONTKNOW ); @@ -330,9 +332,9 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) // Konturfluss if( rAttrs.GetItemState( SDRATTR_TEXT_CONTOURFRAME ) != SFX_ITEM_DONTCARE ) { - BOOL bContour = ( ( const SdrTextContourFrameItem& )rAttrs.Get( SDRATTR_TEXT_CONTOURFRAME ) ).GetValue(); + sal_Bool bContour = ( ( const SdrTextContourFrameItem& )rAttrs.Get( SDRATTR_TEXT_CONTOURFRAME ) ).GetValue(); aTsbContour.SetState( bContour ? STATE_CHECK : STATE_NOCHECK ); - aTsbContour.EnableTriState( FALSE ); + aTsbContour.EnableTriState( sal_False ); } else aTsbContour.SetState( STATE_DONTKNOW ); @@ -347,13 +349,13 @@ void SvxTextAttrPage::Reset( const SfxItemSet& rAttrs ) |* \************************************************************************/ -BOOL SvxTextAttrPage::FillItemSet( SfxItemSet& rAttrs) +sal_Bool SvxTextAttrPage::FillItemSet( SfxItemSet& rAttrs) { SfxItemPool* pPool = rAttrs.GetPool(); DBG_ASSERT( pPool, "Wo ist der Pool" ); SfxMapUnit eUnit = pPool->GetMetric( SDRATTR_TEXT_LEFTDIST ); - INT32 nValue; + sal_Int32 nValue; TriState eState; if( aMtrFldLeft.GetText() != aMtrFldLeft.GetSavedValue() ) @@ -383,32 +385,32 @@ BOOL SvxTextAttrPage::FillItemSet( SfxItemSet& rAttrs) eState = aTsbAutoGrowHeight.GetState(); if( eState != aTsbAutoGrowHeight.GetSavedValue() ) { - rAttrs.Put( SdrTextAutoGrowHeightItem( (BOOL) STATE_CHECK == eState ) ); + rAttrs.Put( SdrTextAutoGrowHeightItem( (sal_Bool) STATE_CHECK == eState ) ); } eState = aTsbAutoGrowWidth.GetState(); if( eState != aTsbAutoGrowWidth.GetSavedValue() ) { - rAttrs.Put( SdrTextAutoGrowWidthItem( (BOOL) STATE_CHECK == eState ) ); + rAttrs.Put( SdrTextAutoGrowWidthItem( (sal_Bool) STATE_CHECK == eState ) ); } eState = aTsbAutoGrowSize.GetState(); if( eState != aTsbAutoGrowSize.GetSavedValue() ) { - rAttrs.Put( SdrTextAutoGrowHeightItem( (BOOL) STATE_CHECK == eState ) ); + rAttrs.Put( SdrTextAutoGrowHeightItem( (sal_Bool) STATE_CHECK == eState ) ); } eState = aTsbWordWrapText.GetState(); if( eState != aTsbWordWrapText.GetSavedValue() ) { - rAttrs.Put( SdrTextWordWrapItem( (BOOL) STATE_CHECK == eState ) ); + rAttrs.Put( SdrTextWordWrapItem( (sal_Bool) STATE_CHECK == eState ) ); } // Konturfluss eState = aTsbContour.GetState(); if( eState != aTsbContour.GetSavedValue() ) { - rAttrs.Put( SdrTextContourFrameItem( (BOOL) STATE_CHECK == eState ) ); + rAttrs.Put( SdrTextContourFrameItem( (sal_Bool) STATE_CHECK == eState ) ); } eState = aTsbFitToSize.GetState(); @@ -487,7 +489,7 @@ BOOL SvxTextAttrPage::FillItemSet( SfxItemSet& rAttrs) rAttrs.Put( SdrTextHorzAdjustItem( eTHA ) ); } - return( TRUE ); + return( sal_True ); } /************************************************************************* @@ -500,8 +502,8 @@ void SvxTextAttrPage::Construct() { DBG_ASSERT( pView, "Keine gueltige View Uebergeben!" ); - bFitToSizeEnabled = bContourEnabled = TRUE; - bWordWrapTextEnabled = bAutoGrowSizeEnabled = bAutoGrowWidthEnabled = bAutoGrowHeightEnabled = FALSE; + bFitToSizeEnabled = bContourEnabled = sal_True; + bWordWrapTextEnabled = bAutoGrowSizeEnabled = bAutoGrowWidthEnabled = bAutoGrowHeightEnabled = sal_False; const SdrMarkList& rMarkList = pView->GetMarkedObjectList(); if( rMarkList.GetMarkCount() == 1 ) @@ -520,18 +522,18 @@ void SvxTextAttrPage::Construct() if ( ((SdrTextObj*)pObj)->HasText() ) { // Konturfluss ist NICHT bei reinen Textobjekten m�glich - bContourEnabled = FALSE; + bContourEnabled = sal_False; // Breite und Hoehe anpassen ist NUR bei reinen Textobjekten m�glich - bAutoGrowWidthEnabled = bAutoGrowHeightEnabled = TRUE; + bAutoGrowWidthEnabled = bAutoGrowHeightEnabled = sal_True; } } break; case OBJ_CUSTOMSHAPE : { - bFitToSizeEnabled = bContourEnabled = FALSE; - bAutoGrowSizeEnabled = TRUE; - bWordWrapTextEnabled = TRUE; + bFitToSizeEnabled = bContourEnabled = sal_False; + bAutoGrowSizeEnabled = sal_True; + bWordWrapTextEnabled = sal_True; } break; default: ;//prevent warning @@ -564,7 +566,7 @@ SfxTabPage* SvxTextAttrPage::Create( Window* pWindow, |* \************************************************************************/ -USHORT* SvxTextAttrPage::GetRanges() +sal_uInt16* SvxTextAttrPage::GetRanges() { return( pRanges ); } @@ -682,10 +684,10 @@ IMPL_LINK( SvxTextAttrPage, ClickFullWidthHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxTextAttrPage, ClickHdl_Impl, void *, EMPTYARG ) { - BOOL bAutoGrowWidth = aTsbAutoGrowWidth.GetState() == STATE_CHECK; - BOOL bAutoGrowHeight = aTsbAutoGrowHeight.GetState() == STATE_CHECK; - BOOL bFitToSize = aTsbFitToSize.GetState() == STATE_CHECK; - BOOL bContour = aTsbContour.GetState() == STATE_CHECK; + sal_Bool bAutoGrowWidth = aTsbAutoGrowWidth.GetState() == STATE_CHECK; + sal_Bool bAutoGrowHeight = aTsbAutoGrowHeight.GetState() == STATE_CHECK; + sal_Bool bFitToSize = aTsbFitToSize.GetState() == STATE_CHECK; + sal_Bool bContour = aTsbContour.GetState() == STATE_CHECK; aTsbContour.Enable( !bFitToSize && !( ( bAutoGrowWidth && bAutoGrowWidthEnabled ) || ( bAutoGrowHeight && bAutoGrowHeightEnabled ) ) && diff --git a/cui/source/tabpages/textattr.src b/cui/source/tabpages/textattr.src index 59b0a534472d..c4ae4b5062ce 100644 --- a/cui/source/tabpages/textattr.src +++ b/cui/source/tabpages/textattr.src @@ -46,6 +46,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_AUTOGROW_WIDTH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_AUTOGROW_WIDTH"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 14 ) ; Size = MAP_APPFONT ( 102 , 10 ) ; @@ -53,6 +54,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_AUTOGROW_HEIGHT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_AUTOGROW_HEIGHT"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 28 ) ; Size = MAP_APPFONT ( 102 , 10 ) ; @@ -60,6 +62,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_FIT_TO_SIZE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_FIT_TO_SIZE"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 42 ) ; Size = MAP_APPFONT ( 102 , 10 ) ; @@ -67,6 +70,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_CONTOUR { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_CONTOUR"; TabStop = TRUE ; Pos = MAP_APPFONT ( 12 , 56 ) ; Size = MAP_APPFONT ( 102 , 10 ) ; @@ -74,6 +78,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_WORDWRAP_TEXT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_WORDWRAP_TEXT"; TabStop = TRUE; Pos = MAP_APPFONT( 132, 14 ) ; Size = MAP_APPFONT( 127 , 10 ) ; @@ -81,6 +86,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_AUTOGROW_SIZE { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_AUTOGROW_SIZE"; TabStop = TRUE; Pos = MAP_APPFONT( 132, 28 ); Size = MAP_APPFONT( 127 , 10 ); @@ -118,6 +124,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; MetricField MTR_FLD_LEFT { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTATTR:MTR_FLD_LEFT"; Border = TRUE ; Pos = MAP_APPFONT ( 69 , 83 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -134,6 +141,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; MetricField MTR_FLD_RIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTATTR:MTR_FLD_RIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 69 , 99 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -150,6 +158,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; MetricField MTR_FLD_TOP { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTATTR:MTR_FLD_TOP"; Border = TRUE ; Pos = MAP_APPFONT ( 69 , 115 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -166,6 +175,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; MetricField MTR_FLD_BOTTOM { + HelpID = "cui:MetricField:RID_SVXPAGE_TEXTATTR:MTR_FLD_BOTTOM"; Border = TRUE ; Pos = MAP_APPFONT ( 69 , 131 ) ; Size = MAP_APPFONT ( 45 , 12 ) ; @@ -202,6 +212,7 @@ TabPage RID_SVXPAGE_TEXTATTR }; TriStateBox TSB_FULL_WIDTH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_TEXTATTR:TSB_FULL_WIDTH"; TabStop = TRUE ; Pos = MAP_APPFONT ( 132 , 139 ) ; Size = MAP_APPFONT ( 116 , 10 ) ; diff --git a/cui/source/tabpages/tparea.cxx b/cui/source/tabpages/tparea.cxx index 8493665bc01d..074cac9c084d 100644 --- a/cui/source/tabpages/tparea.cxx +++ b/cui/source/tabpages/tparea.cxx @@ -53,12 +53,12 @@ #include "svx/dlgutil.hxx" #include <svl/intitem.hxx> #include <sfx2/request.hxx> - +#include "paragrph.hrc" #define DLGWIN this->GetParent()->GetParent() // static ---------------------------------------------------------------- -static USHORT pAreaRanges[] = +static sal_uInt16 pAreaRanges[] = { XATTR_GRADIENTSTEPCOUNT, XATTR_GRADIENTSTEPCOUNT, @@ -67,7 +67,7 @@ static USHORT pAreaRanges[] = 0 }; -static USHORT pTransparenceRanges[] = +static sal_uInt16 pTransparenceRanges[] = { XATTR_FILLTRANSPARENCE, XATTR_FILLTRANSPARENCE, @@ -87,8 +87,8 @@ static USHORT pTransparenceRanges[] = IMPL_LINK(SvxTransparenceTabPage, ClickTransOffHdl_Impl, void *, EMPTYARG) { // disable all other controls - ActivateLinear(FALSE); - ActivateGradient(FALSE); + ActivateLinear(sal_False); + ActivateGradient(sal_False); // Preview rXFSet.ClearItem (XATTR_FILLTRANSPARENCE); @@ -96,7 +96,7 @@ IMPL_LINK(SvxTransparenceTabPage, ClickTransOffHdl_Impl, void *, EMPTYARG) aCtlXRectPreview.SetAttributes( aXFillAttr.GetItemSet() ); aCtlBitmapPreview.SetAttributes( aXFillAttr.GetItemSet() ); - InvalidatePreview( FALSE ); + InvalidatePreview( sal_False ); return( 0L ); } @@ -104,8 +104,8 @@ IMPL_LINK(SvxTransparenceTabPage, ClickTransOffHdl_Impl, void *, EMPTYARG) IMPL_LINK(SvxTransparenceTabPage, ClickTransLinearHdl_Impl, void *, EMPTYARG) { // enable linear, disable other - ActivateLinear(TRUE); - ActivateGradient(FALSE); + ActivateLinear(sal_True); + ActivateGradient(sal_False); // preview rXFSet.ClearItem (XATTR_FILLFLOATTRANSPARENCE); @@ -117,8 +117,8 @@ IMPL_LINK(SvxTransparenceTabPage, ClickTransLinearHdl_Impl, void *, EMPTYARG) IMPL_LINK(SvxTransparenceTabPage, ClickTransGradientHdl_Impl, void *, EMPTYARG) { // enable gradient, disable other - ActivateLinear(FALSE); - ActivateGradient(TRUE); + ActivateLinear(sal_False); + ActivateGradient(sal_True); // preview rXFSet.ClearItem (XATTR_FILLTRANSPARENCE); @@ -127,14 +127,14 @@ IMPL_LINK(SvxTransparenceTabPage, ClickTransGradientHdl_Impl, void *, EMPTYARG) return( 0L ); } -void SvxTransparenceTabPage::ActivateLinear(BOOL bActivate) +void SvxTransparenceTabPage::ActivateLinear(sal_Bool bActivate) { aMtrTransparent.Enable(bActivate); } IMPL_LINK(SvxTransparenceTabPage, ModifyTransparentHdl_Impl, void*, EMPTYARG) { - UINT16 nPos = (UINT16)aMtrTransparent.GetValue(); + sal_uInt16 nPos = (sal_uInt16)aMtrTransparent.GetValue(); XFillTransparenceItem aItem(nPos); rXFSet.Put(XFillTransparenceItem(aItem)); @@ -153,16 +153,16 @@ IMPL_LINK(SvxTransparenceTabPage, ModifiedTrgrHdl_Impl, void *, pControl) } // preview - UINT8 nStartCol = (UINT8)(((UINT16)aMtrTrgrStartValue.GetValue() * 255) / 100); - UINT8 nEndCol = (UINT8)(((UINT16)aMtrTrgrEndValue.GetValue() * 255) / 100); + sal_uInt8 nStartCol = (sal_uInt8)(((sal_uInt16)aMtrTrgrStartValue.GetValue() * 255) / 100); + sal_uInt8 nEndCol = (sal_uInt8)(((sal_uInt16)aMtrTrgrEndValue.GetValue() * 255) / 100); XGradient aTmpGradient( Color(nStartCol, nStartCol, nStartCol), Color(nEndCol, nEndCol, nEndCol), (XGradientStyle)aLbTrgrGradientType.GetSelectEntryPos(), - (UINT16)aMtrTrgrAngle.GetValue() * 10, - (UINT16)aMtrTrgrCenterX.GetValue(), - (UINT16)aMtrTrgrCenterY.GetValue(), - (UINT16)aMtrTrgrBorder.GetValue(), + (sal_uInt16)aMtrTrgrAngle.GetValue() * 10, + (sal_uInt16)aMtrTrgrCenterX.GetValue(), + (sal_uInt16)aMtrTrgrCenterY.GetValue(), + (sal_uInt16)aMtrTrgrBorder.GetValue(), 100, 100); String aString; @@ -174,7 +174,7 @@ IMPL_LINK(SvxTransparenceTabPage, ModifiedTrgrHdl_Impl, void *, pControl) return( 0L ); } -void SvxTransparenceTabPage::ActivateGradient(BOOL bActivate) +void SvxTransparenceTabPage::ActivateGradient(sal_Bool bActivate) { aFtTrgrType.Enable(bActivate); aLbTrgrGradientType.Enable(bActivate); @@ -277,13 +277,18 @@ SvxTransparenceTabPage::SvxTransparenceTabPage(Window* pParent, const SfxItemSet aCtlBitmapPreview ( this, CUI_RES( CTL_BITMAP_PREVIEW ) ), aCtlXRectPreview ( this, CUI_RES( CTL_TRANS_PREVIEW ) ), - bBitmap ( FALSE ), + bBitmap ( sal_False ), pXPool ( (XOutdevItemPool*) rInAttrs.GetPool() ), aXFillAttr ( pXPool ), rXFSet ( aXFillAttr.GetItemSet() ) { FreeResource(); + String accName = String(CUI_RES(STR_EXAMPLE)); + aCtlBitmapPreview.SetAccessibleName(accName); + aCtlXRectPreview.SetAccessibleName(accName); + aMtrTransparent.SetAccessibleRelationLabeledBy( &aRbtTransLinear ); + // main selection aRbtTransOff.SetClickHdl(LINK(this, SvxTransparenceTabPage, ClickTransOffHdl_Impl)); aRbtTransLinear.SetClickHdl(LINK(this, SvxTransparenceTabPage, ClickTransLinearHdl_Impl)); @@ -319,33 +324,33 @@ SfxTabPage* SvxTransparenceTabPage::Create(Window* pWindow, const SfxItemSet& rA return(new SvxTransparenceTabPage(pWindow, rAttrs)); } -UINT16* SvxTransparenceTabPage::GetRanges() +sal_uInt16* SvxTransparenceTabPage::GetRanges() { return(pTransparenceRanges); } -BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) +sal_Bool SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) { const SfxPoolItem* pGradientItem = NULL; const SfxPoolItem* pLinearItem = NULL; - SfxItemState eStateGradient(rOutAttrs.GetItemState(XATTR_FILLFLOATTRANSPARENCE, TRUE, &pGradientItem)); - SfxItemState eStateLinear(rOutAttrs.GetItemState(XATTR_FILLTRANSPARENCE, TRUE, &pLinearItem)); - BOOL bGradActive = (eStateGradient == SFX_ITEM_SET && ((XFillFloatTransparenceItem*)pGradientItem)->IsEnabled()); - BOOL bLinearActive = (eStateLinear == SFX_ITEM_SET && ((XFillTransparenceItem*)pLinearItem)->GetValue() != 0); + SfxItemState eStateGradient(rOutAttrs.GetItemState(XATTR_FILLFLOATTRANSPARENCE, sal_True, &pGradientItem)); + SfxItemState eStateLinear(rOutAttrs.GetItemState(XATTR_FILLTRANSPARENCE, sal_True, &pLinearItem)); + sal_Bool bGradActive = (eStateGradient == SFX_ITEM_SET && ((XFillFloatTransparenceItem*)pGradientItem)->IsEnabled()); + sal_Bool bLinearActive = (eStateLinear == SFX_ITEM_SET && ((XFillTransparenceItem*)pLinearItem)->GetValue() != 0); // #103765# - BOOL bGradUsed = (eStateGradient == SFX_ITEM_DONTCARE); - BOOL bLinearUsed = (eStateLinear == SFX_ITEM_DONTCARE); + sal_Bool bGradUsed = (eStateGradient == SFX_ITEM_DONTCARE); + sal_Bool bLinearUsed = (eStateLinear == SFX_ITEM_DONTCARE); - BOOL bModified(FALSE); - BOOL bSwitchOffLinear(FALSE); - BOOL bSwitchOffGradient(FALSE); + sal_Bool bModified(sal_False); + sal_Bool bSwitchOffLinear(sal_False); + sal_Bool bSwitchOffGradient(sal_False); if(aMtrTransparent.IsEnabled()) { // linear transparence - UINT16 nPos = (UINT16)aMtrTransparent.GetValue(); - if(nPos != (UINT16)aMtrTransparent.GetSavedValue().ToInt32() || !bLinearActive) + sal_uInt16 nPos = (sal_uInt16)aMtrTransparent.GetValue(); + if(nPos != (sal_uInt16)aMtrTransparent.GetSavedValue().ToInt32() || !bLinearActive) { XFillTransparenceItem aItem(nPos); SdrShadowTransparenceItem aShadowItem(nPos); @@ -354,8 +359,8 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) { rAttrs.Put(aItem); rAttrs.Put(aShadowItem); - bModified = TRUE; - bSwitchOffGradient = TRUE; + bModified = sal_True; + bSwitchOffGradient = sal_True; } } } @@ -364,23 +369,23 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) // transparence gradient, fill ItemSet from values if(!bGradActive || (XGradientStyle)aLbTrgrGradientType.GetSelectEntryPos() != (XGradientStyle)aLbTrgrGradientType.GetSavedValue() - || (UINT16)aMtrTrgrAngle.GetValue() != (UINT16)aMtrTrgrAngle.GetSavedValue().ToInt32() - || (UINT16)aMtrTrgrCenterX.GetValue() != (UINT16)aMtrTrgrCenterX.GetSavedValue().ToInt32() - || (UINT16)aMtrTrgrCenterY.GetValue() != (UINT16)aMtrTrgrCenterY.GetSavedValue().ToInt32() - || (UINT16)aMtrTrgrBorder.GetValue() != (UINT16)aMtrTrgrBorder.GetSavedValue().ToInt32() - || (UINT16)aMtrTrgrStartValue.GetValue() != (UINT16)aMtrTrgrStartValue.GetSavedValue().ToInt32() - || (UINT16)aMtrTrgrEndValue.GetValue() != (UINT16)aMtrTrgrEndValue.GetSavedValue().ToInt32() ) + || (sal_uInt16)aMtrTrgrAngle.GetValue() != (sal_uInt16)aMtrTrgrAngle.GetSavedValue().ToInt32() + || (sal_uInt16)aMtrTrgrCenterX.GetValue() != (sal_uInt16)aMtrTrgrCenterX.GetSavedValue().ToInt32() + || (sal_uInt16)aMtrTrgrCenterY.GetValue() != (sal_uInt16)aMtrTrgrCenterY.GetSavedValue().ToInt32() + || (sal_uInt16)aMtrTrgrBorder.GetValue() != (sal_uInt16)aMtrTrgrBorder.GetSavedValue().ToInt32() + || (sal_uInt16)aMtrTrgrStartValue.GetValue() != (sal_uInt16)aMtrTrgrStartValue.GetSavedValue().ToInt32() + || (sal_uInt16)aMtrTrgrEndValue.GetValue() != (sal_uInt16)aMtrTrgrEndValue.GetSavedValue().ToInt32() ) { - UINT8 nStartCol = (UINT8)(((UINT16)aMtrTrgrStartValue.GetValue() * 255) / 100); - UINT8 nEndCol = (UINT8)(((UINT16)aMtrTrgrEndValue.GetValue() * 255) / 100); + sal_uInt8 nStartCol = (sal_uInt8)(((sal_uInt16)aMtrTrgrStartValue.GetValue() * 255) / 100); + sal_uInt8 nEndCol = (sal_uInt8)(((sal_uInt16)aMtrTrgrEndValue.GetValue() * 255) / 100); XGradient aTmpGradient( Color(nStartCol, nStartCol, nStartCol), Color(nEndCol, nEndCol, nEndCol), (XGradientStyle)aLbTrgrGradientType.GetSelectEntryPos(), - (UINT16)aMtrTrgrAngle.GetValue() * 10, - (UINT16)aMtrTrgrCenterX.GetValue(), - (UINT16)aMtrTrgrCenterY.GetValue(), - (UINT16)aMtrTrgrBorder.GetValue(), + (sal_uInt16)aMtrTrgrAngle.GetValue() * 10, + (sal_uInt16)aMtrTrgrCenterX.GetValue(), + (sal_uInt16)aMtrTrgrCenterY.GetValue(), + (sal_uInt16)aMtrTrgrBorder.GetValue(), 100, 100); String aString; @@ -390,16 +395,16 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) if(!pOld || !(*(const XFillFloatTransparenceItem*)pOld == aItem) || !bGradActive) { rAttrs.Put(aItem); - bModified = TRUE; - bSwitchOffLinear = TRUE; + bModified = sal_True; + bSwitchOffLinear = sal_True; } } } else { // no transparence - bSwitchOffGradient = TRUE; - bSwitchOffLinear = TRUE; + bSwitchOffGradient = sal_True; + bSwitchOffLinear = sal_True; } // disable unused XFillFloatTransparenceItem @@ -411,9 +416,9 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) aGrad.SetEndIntens(100); String aString; XFillFloatTransparenceItem aItem( rXFSet.GetPool()/*aString*/, aGrad); - aItem.SetEnabled(FALSE); + aItem.SetEnabled(sal_False); rAttrs.Put(aItem); - bModified = TRUE; + bModified = sal_True; } // disable unused XFillFloatTransparenceItem @@ -423,7 +428,7 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) SdrShadowTransparenceItem aShadowItem(0); rAttrs.Put(aItem); rAttrs.Put(aShadowItem); - bModified = TRUE; + bModified = sal_True; } rAttrs.Put (CntUInt16Item(SID_PAGE_TYPE,nPageType)); return bModified; @@ -432,30 +437,30 @@ BOOL SvxTransparenceTabPage::FillItemSet(SfxItemSet& rAttrs) void SvxTransparenceTabPage::Reset(const SfxItemSet& rAttrs) { const SfxPoolItem* pGradientItem = NULL; - SfxItemState eStateGradient(rAttrs.GetItemState(XATTR_FILLFLOATTRANSPARENCE, TRUE, &pGradientItem)); + SfxItemState eStateGradient(rAttrs.GetItemState(XATTR_FILLFLOATTRANSPARENCE, sal_True, &pGradientItem)); if(!pGradientItem) pGradientItem = &rAttrs.Get(XATTR_FILLFLOATTRANSPARENCE); - BOOL bGradActive = (eStateGradient == SFX_ITEM_SET && ((XFillFloatTransparenceItem*)pGradientItem)->IsEnabled()); + sal_Bool bGradActive = (eStateGradient == SFX_ITEM_SET && ((XFillFloatTransparenceItem*)pGradientItem)->IsEnabled()); const SfxPoolItem* pLinearItem = NULL; - SfxItemState eStateLinear(rAttrs.GetItemState(XATTR_FILLTRANSPARENCE, TRUE, &pLinearItem)); + SfxItemState eStateLinear(rAttrs.GetItemState(XATTR_FILLTRANSPARENCE, sal_True, &pLinearItem)); if(!pLinearItem) pLinearItem = &rAttrs.Get(XATTR_FILLTRANSPARENCE); - BOOL bLinearActive = (eStateLinear == SFX_ITEM_SET && ((XFillTransparenceItem*)pLinearItem)->GetValue() != 0); + sal_Bool bLinearActive = (eStateLinear == SFX_ITEM_SET && ((XFillTransparenceItem*)pLinearItem)->GetValue() != 0); // transparence gradient const XGradient& rGradient = ((XFillFloatTransparenceItem*)pGradientItem)->GetGradientValue(); XGradientStyle eXGS(rGradient.GetGradientStyle()); - aLbTrgrGradientType.SelectEntryPos(sal::static_int_cast< USHORT >(eXGS)); + aLbTrgrGradientType.SelectEntryPos(sal::static_int_cast< sal_uInt16 >(eXGS)); aMtrTrgrAngle.SetValue(rGradient.GetAngle() / 10); aMtrTrgrBorder.SetValue(rGradient.GetBorder()); aMtrTrgrCenterX.SetValue(rGradient.GetXOffset()); aMtrTrgrCenterY.SetValue(rGradient.GetYOffset()); - aMtrTrgrStartValue.SetValue((UINT16)((((UINT16)rGradient.GetStartColor().GetRed() + 1) * 100) / 255)); - aMtrTrgrEndValue.SetValue((UINT16)((((UINT16)rGradient.GetEndColor().GetRed() + 1) * 100) / 255)); + aMtrTrgrStartValue.SetValue((sal_uInt16)((((sal_uInt16)rGradient.GetStartColor().GetRed() + 1) * 100) / 255)); + aMtrTrgrEndValue.SetValue((sal_uInt16)((((sal_uInt16)rGradient.GetEndColor().GetRed() + 1) * 100) / 255)); // linear transparence - UINT16 nTransp = ((XFillTransparenceItem*)pLinearItem)->GetValue(); + sal_uInt16 nTransp = ((XFillTransparenceItem*)pLinearItem)->GetValue(); aMtrTransparent.SetValue(bLinearActive ? nTransp : 50); ModifyTransparentHdl_Impl(NULL); @@ -490,7 +495,7 @@ void SvxTransparenceTabPage::Reset(const SfxItemSet& rAttrs) aMtrTrgrStartValue.SaveValue(); aMtrTrgrEndValue.SaveValue(); - BOOL bActive = InitPreview ( rAttrs ); + sal_Bool bActive = InitPreview ( rAttrs ); InvalidatePreview ( bActive ); } @@ -521,7 +526,7 @@ void SvxTransparenceTabPage::PointChanged(Window* , RECT_POINT eRcPt) // // Preview-Methods // -BOOL SvxTransparenceTabPage::InitPreview ( const SfxItemSet& rSet ) +sal_Bool SvxTransparenceTabPage::InitPreview ( const SfxItemSet& rSet ) { // set transparencetyp for preview if ( aRbtTransOff.IsChecked() ) @@ -563,7 +568,7 @@ BOOL SvxTransparenceTabPage::InitPreview ( const SfxItemSet& rSet ) return !aRbtTransOff.IsChecked(); } -void SvxTransparenceTabPage::InvalidatePreview (BOOL bEnable) +void SvxTransparenceTabPage::InvalidatePreview (sal_Bool bEnable) { if ( bBitmap ) { @@ -661,6 +666,10 @@ SvxAreaTabPage::SvxAreaTabPage( Window* pParent, const SfxItemSet& rInAttrs ) : { FreeResource(); + String accName = String(CUI_RES(STR_EXAMPLE)); + aCtlXRectPreview.SetAccessibleName(accName); + aCtlBitmapPreview.SetAccessibleName(accName); + // Gruppen, die sich ueberlagern aLbBitmap.Hide(); aCtlBitmapPreview.Hide(); @@ -693,7 +702,7 @@ SvxAreaTabPage::SvxAreaTabPage( Window* pParent, const SfxItemSet& rInAttrs ) : aLbHatchBckgrdColor.Hide(); - aTsbOriginal.EnableTriState( FALSE ); + aTsbOriginal.EnableTriState( sal_False ); // this page needs ExchangeSupport @@ -710,8 +719,8 @@ SvxAreaTabPage::SvxAreaTabPage( Window* pParent, const SfxItemSet& rInAttrs ) : break; default: ;//prevent warning } - SetFieldUnit( aMtrFldXSize, eFUnit, TRUE ); - SetFieldUnit( aMtrFldYSize, eFUnit, TRUE ); + SetFieldUnit( aMtrFldXSize, eFUnit, sal_True ); + SetFieldUnit( aMtrFldYSize, eFUnit, sal_True ); // get PoolUnit SfxItemPool* pPool = rOutAttrs.GetPool(); @@ -756,7 +765,16 @@ SvxAreaTabPage::SvxAreaTabPage( Window* pParent, const SfxItemSet& rInAttrs ) : aTypeLB.SetSelectHdl( LINK( this, SvxAreaTabPage, SelectDialogTypeHdl_Impl ) ); // #i76307# always paint the preview in LTR, because this is what the document does - aCtlXRectPreview.EnableRTL(FALSE); + aCtlXRectPreview.EnableRTL(sal_False); + + aNumFldStepCount.SetAccessibleRelationLabeledBy( &aTsbStepCount ); + aCtlPosition.SetAccessibleRelationMemberOf( &aFlPosition ); + aLbHatchBckgrdColor.SetAccessibleRelationLabeledBy( &aCbxHatchBckgrd ); + aLbHatchBckgrdColor.SetAccessibleName(aCbxHatchBckgrd.GetText()); + + aLbColor.SetAccessibleRelationMemberOf( &aFlProp ); + aMtrFldOffset.SetAccessibleRelationLabeledBy(&aFlOffset); + aMtrFldOffset.SetAccessibleName(aFlOffset.GetText()); } // ----------------------------------------------------------------------- @@ -776,7 +794,7 @@ void SvxAreaTabPage::Construct() void SvxAreaTabPage::ActivatePage( const SfxItemSet& rSet ) { - USHORT nCount; + sal_uInt16 nCount; SFX_ITEMSET_ARG (&rSet,pPageTypeItem,SfxUInt16Item,SID_PAGE_TYPE,sal_False); SFX_ITEMSET_ARG (&rSet,pPosItem,SfxUInt16Item,SID_TABPAGE_POS,sal_False); if (pPageTypeItem) @@ -785,7 +803,7 @@ void SvxAreaTabPage::ActivatePage( const SfxItemSet& rSet ) SetPos(pPosItem->GetValue()); if( nDlgType == 0 ) // Flaechen-Dialog { - *pbAreaTP = TRUE; + *pbAreaTP = sal_True; if( pColorTab ) { @@ -968,11 +986,11 @@ int SvxAreaTabPage::DeactivatePage( SfxItemSet* _pSet ) // ----------------------------------------------------------------------- -BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) +sal_Bool SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) { const SfxPoolItem* pOld = NULL; - USHORT _nPos; - BOOL bModified = FALSE; + sal_uInt16 _nPos; + sal_Bool bModified = sal_False; if( nDlgType != 0 || *pbAreaTP ) { @@ -989,7 +1007,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillStyleItem*)pOld == aStyleItem ) ) { rAttrs.Put( aStyleItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1006,20 +1024,20 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillColorItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } // NEU if( (eSavedStyle != eStyle) && ( bModified || - SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), TRUE ) ) ) + SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), sal_True ) ) ) { XFillStyleItem aStyleItem( XFILL_SOLID ); pOld = GetOldItem( rAttrs, XATTR_FILLSTYLE ); if ( !pOld || !( *(const XFillStyleItem*)pOld == aStyleItem ) ) { rAttrs.Put( aStyleItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1037,20 +1055,20 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillGradientItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } // NEU if( (eSavedStyle != eStyle) && ( bModified || - SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), TRUE ) ) ) + SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), sal_True ) ) ) { XFillStyleItem aStyleItem( XFILL_GRADIENT ); pOld = GetOldItem( rAttrs, XATTR_FILLSTYLE ); if ( !pOld || !( *(const XFillStyleItem*)pOld == aStyleItem ) ) { rAttrs.Put( aStyleItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1068,7 +1086,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillHatchItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } XFillBackgroundItem aItem ( aCbxHatchBckgrd.IsChecked() ); @@ -1083,20 +1101,20 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillColorItem*)pOld == aFillColorItem ) ) { rAttrs.Put( aFillColorItem ); - bModified = TRUE; + bModified = sal_True; } } // NEU if( (eSavedStyle != eStyle) && ( bModified || - SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), TRUE ) ) ) + SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), sal_True ) ) ) { XFillStyleItem aStyleItem( XFILL_HATCH ); pOld = GetOldItem( rAttrs, XATTR_FILLSTYLE ); if ( !pOld || !( *(const XFillStyleItem*)pOld == aStyleItem ) ) { rAttrs.Put( aStyleItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1114,20 +1132,20 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillBitmapItem*)pOld == aFillBitmapItem ) ) { rAttrs.Put( aFillBitmapItem ); - bModified = TRUE; + bModified = sal_True; } } // NEU if( (eSavedStyle != eStyle) && ( bModified || - SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), TRUE ) ) ) + SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), sal_True ) ) ) { XFillStyleItem aStyleItem( XFILL_BITMAP ); pOld = GetOldItem( rAttrs, XATTR_FILLSTYLE ); if ( !pOld || !( *(const XFillStyleItem*)pOld == aStyleItem ) ) { rAttrs.Put( aStyleItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1137,22 +1155,22 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) // Schrittweite if( aTsbStepCount.IsEnabled() ) { - UINT16 nValue = 0; - BOOL bValueModified = FALSE; + sal_uInt16 nValue = 0; + sal_Bool bValueModified = sal_False; TriState eState = aTsbStepCount.GetState(); if( eState == STATE_CHECK ) { if( eState != aTsbStepCount.GetSavedValue() ) - bValueModified = TRUE; + bValueModified = sal_True; } else { // Zustand != Disabled ? if( aNumFldStepCount.GetText().Len() > 0 ) { - nValue = (UINT16) aNumFldStepCount.GetValue(); - if( nValue != (UINT16) aNumFldStepCount.GetSavedValue().ToInt32() ) - bValueModified = TRUE; + nValue = (sal_uInt16) aNumFldStepCount.GetValue(); + if( nValue != (sal_uInt16) aNumFldStepCount.GetSavedValue().ToInt32() ) + bValueModified = sal_True; } } if( bValueModified ) @@ -1162,7 +1180,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XGradientStepCountItem*)pOld == aFillBitmapItem ) ) { rAttrs.Put( aFillBitmapItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1174,12 +1192,12 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if( eState != aTsbTile.GetSavedValue() ) { XFillBmpTileItem aFillBmpTileItem( - sal::static_int_cast< BOOL >( eState ) ); + sal::static_int_cast< sal_Bool >( eState ) ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_TILE ); if ( !pOld || !( *(const XFillBmpTileItem*)pOld == aFillBmpTileItem ) ) { rAttrs.Put( aFillBmpTileItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1190,19 +1208,19 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if( eState != aTsbStretch.GetSavedValue() ) { XFillBmpStretchItem aFillBmpStretchItem( - sal::static_int_cast< BOOL >( eState ) ); + sal::static_int_cast< sal_Bool >( eState ) ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_STRETCH ); if ( !pOld || !( *(const XFillBmpStretchItem*)pOld == aFillBmpStretchItem ) ) { rAttrs.Put( aFillBmpStretchItem ); - bModified = TRUE; + bModified = sal_True; } } } // Originalgroesse (im UI) wird wie folgt benutzt: // Controls sind disabled, muessen aber gesetzt werden. - // SizeX = 0; SizeY = 0; Log = TRUE + // SizeX = 0; SizeY = 0; Log = sal_True //aTsbScale TriState eState = aTsbScale.GetState(); @@ -1215,7 +1233,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if( aTsbScale.IsEnabled() ) pItem = new XFillBmpSizeLogItem( eState == STATE_NOCHECK ); else if( aTsbOriginal.IsEnabled() && aTsbOriginal.GetState() == STATE_CHECK ) - pItem = new XFillBmpSizeLogItem( TRUE ); + pItem = new XFillBmpSizeLogItem( sal_True ); if( pItem ) { @@ -1223,7 +1241,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillBmpSizeLogItem*)pOld == *pItem ) ) { rAttrs.Put( *pItem ); - bModified = TRUE; + bModified = sal_True; } delete pItem; } @@ -1260,7 +1278,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillBmpSizeXItem*)pOld == *pItem ) ) { rAttrs.Put( *pItem ); - bModified = TRUE; + bModified = sal_True; } delete pItem; } @@ -1297,7 +1315,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillBmpSizeYItem*)pOld == *pItem ) ) { rAttrs.Put( *pItem ); - bModified = TRUE; + bModified = sal_True; } delete pItem; } @@ -1316,24 +1334,24 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) { if( aRbtRow.IsChecked() ) { - XFillBmpTileOffsetXItem aFillBmpTileOffsetXItem( (UINT16) aMtrFldOffset.GetValue() ); + XFillBmpTileOffsetXItem aFillBmpTileOffsetXItem( (sal_uInt16) aMtrFldOffset.GetValue() ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_TILEOFFSETX ); if ( !pOld || !( *(const XFillBmpTileOffsetXItem*)pOld == aFillBmpTileOffsetXItem ) ) { rAttrs.Put( aFillBmpTileOffsetXItem ); rAttrs.Put( XFillBmpTileOffsetYItem( 0 ) ); - bModified = TRUE; + bModified = sal_True; } } else if( aRbtColumn.IsChecked() ) { - XFillBmpTileOffsetYItem aFillBmpTileOffsetYItem( (UINT16) aMtrFldOffset.GetValue() ); + XFillBmpTileOffsetYItem aFillBmpTileOffsetYItem( (sal_uInt16) aMtrFldOffset.GetValue() ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_TILEOFFSETY ); if ( !pOld || !( *(const XFillBmpTileOffsetYItem*)pOld == aFillBmpTileOffsetYItem ) ) { rAttrs.Put( aFillBmpTileOffsetYItem ); rAttrs.Put( XFillBmpTileOffsetXItem( 0 ) ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1342,16 +1360,16 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) //aCtlPosition if( aCtlPosition.IsEnabled() ) { - BOOL bPut = FALSE; + sal_Bool bPut = sal_False; RECT_POINT _eRP = aCtlPosition.GetActualRP(); if( SFX_ITEM_DONTCARE == rOutAttrs.GetItemState( XATTR_FILLBMP_POS ) ) - bPut = TRUE; + bPut = sal_True; else { RECT_POINT eValue = ( ( const XFillBmpPosItem& ) rOutAttrs.Get( XATTR_FILLBMP_POS ) ).GetValue(); if( eValue != _eRP ) - bPut = TRUE; + bPut = sal_True; } if( bPut ) { @@ -1360,7 +1378,7 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XFillBmpPosItem*)pOld == aFillBmpPosItem ) ) { rAttrs.Put( aFillBmpPosItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1372,12 +1390,12 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if( sMtrXOffset.Len() > 0 && sMtrXOffset != aMtrFldXOffset.GetSavedValue() ) { - XFillBmpPosOffsetXItem aFillBmpPosOffsetXItem( (UINT16) aMtrFldXOffset.GetValue() ); + XFillBmpPosOffsetXItem aFillBmpPosOffsetXItem( (sal_uInt16) aMtrFldXOffset.GetValue() ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_POSOFFSETX ); if ( !pOld || !( *(const XFillBmpPosOffsetXItem*)pOld == aFillBmpPosOffsetXItem ) ) { rAttrs.Put( aFillBmpPosOffsetXItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1389,12 +1407,12 @@ BOOL SvxAreaTabPage::FillItemSet( SfxItemSet& rAttrs ) if( sMtrYOffset.Len() > 0 && sMtrYOffset != aMtrFldYOffset.GetSavedValue() ) { - XFillBmpPosOffsetYItem aFillBmpPosOffsetYItem( (UINT16) aMtrFldYOffset.GetValue() ); + XFillBmpPosOffsetYItem aFillBmpPosOffsetYItem( (sal_uInt16) aMtrFldYOffset.GetValue() ); pOld = GetOldItem( rAttrs, XATTR_FILLBMP_POSOFFSETY ); if ( !pOld || !( *(const XFillBmpPosOffsetYItem*)pOld == aFillBmpPosOffsetYItem ) ) { rAttrs.Put( aFillBmpPosOffsetYItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -1414,7 +1432,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) { eXFS = (XFillStyle) ( ( ( const XFillStyleItem& ) rAttrs. Get( GetWhich( XATTR_FILLSTYLE ) ) ).GetValue() ); - aTypeLB.SelectEntryPos( sal::static_int_cast< USHORT >( eXFS ) ); + aTypeLB.SelectEntryPos( sal::static_int_cast< sal_uInt16 >( eXFS ) ); switch( eXFS ) { case XFILL_NONE: @@ -1507,8 +1525,8 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) if( ( rAttrs.GetItemState( XATTR_GRADIENTSTEPCOUNT ) != SFX_ITEM_DONTCARE ) || ( rAttrs.GetItemState( XATTR_FILLSTYLE ) != SFX_ITEM_DONTCARE ) ) { - aTsbStepCount.EnableTriState( FALSE ); - UINT16 nValue = ( ( const XGradientStepCountItem& ) rAttrs.Get( XATTR_GRADIENTSTEPCOUNT ) ).GetValue(); + aTsbStepCount.EnableTriState( sal_False ); + sal_uInt16 nValue = ( ( const XGradientStepCountItem& ) rAttrs.Get( XATTR_GRADIENTSTEPCOUNT ) ).GetValue(); if( nValue == 0 ) { aTsbStepCount.SetState( STATE_CHECK ); @@ -1532,7 +1550,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) // Ist Kacheln gesetzt? if( rAttrs.GetItemState( XATTR_FILLBMP_TILE ) != SFX_ITEM_DONTCARE ) { - aTsbTile.EnableTriState( FALSE ); + aTsbTile.EnableTriState( sal_False ); if( ( ( const XFillBmpTileItem& ) rAttrs.Get( XATTR_FILLBMP_TILE ) ).GetValue() ) aTsbTile.SetState( STATE_CHECK ); @@ -1545,7 +1563,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) // Ist Stretchen gesetzt? if( rAttrs.GetItemState( XATTR_FILLBMP_STRETCH ) != SFX_ITEM_DONTCARE ) { - aTsbStretch.EnableTriState( FALSE ); + aTsbStretch.EnableTriState( sal_False ); if( ( ( const XFillBmpStretchItem& ) rAttrs.Get( XATTR_FILLBMP_STRETCH ) ).GetValue() ) aTsbStretch.SetState( STATE_CHECK ); @@ -1559,7 +1577,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aTsbScale if( rAttrs.GetItemState( XATTR_FILLBMP_SIZELOG ) != SFX_ITEM_DONTCARE ) { - aTsbScale.EnableTriState( FALSE ); + aTsbScale.EnableTriState( sal_False ); if( ( ( const XFillBmpSizeLogItem& ) rAttrs.Get( XATTR_FILLBMP_SIZELOG ) ).GetValue() ) aTsbScale.SetState( STATE_NOCHECK ); @@ -1578,7 +1596,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aMtrFldXSize if( rAttrs.GetItemState( XATTR_FILLBMP_SIZEX ) != SFX_ITEM_DONTCARE ) { - INT32 nValue = ( ( const XFillBmpSizeXItem& ) rAttrs.Get( XATTR_FILLBMP_SIZEX ) ).GetValue(); + sal_Int32 nValue = ( ( const XFillBmpSizeXItem& ) rAttrs.Get( XATTR_FILLBMP_SIZEX ) ).GetValue(); if( aTsbScale.GetState() == STATE_CHECK ) { // Wenn im Item eine Prozentangabe steckt, @@ -1606,7 +1624,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aMtrFldYSize if( rAttrs.GetItemState( XATTR_FILLBMP_SIZEY ) != SFX_ITEM_DONTCARE ) { - INT32 nValue = ( ( const XFillBmpSizeYItem& ) rAttrs.Get( XATTR_FILLBMP_SIZEY ) ).GetValue(); + sal_Int32 nValue = ( ( const XFillBmpSizeYItem& ) rAttrs.Get( XATTR_FILLBMP_SIZEY ) ).GetValue(); if( aTsbScale.GetState() == STATE_CHECK ) { // Wenn im Item eine Prozentangabe steckt, @@ -1640,7 +1658,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aMtrFldOffset if( rAttrs.GetItemState( XATTR_FILLBMP_TILEOFFSETX ) != SFX_ITEM_DONTCARE ) { - UINT16 nValue = ( ( const XFillBmpTileOffsetXItem& ) rAttrs.Get( XATTR_FILLBMP_TILEOFFSETX ) ).GetValue(); + sal_uInt16 nValue = ( ( const XFillBmpTileOffsetXItem& ) rAttrs.Get( XATTR_FILLBMP_TILEOFFSETX ) ).GetValue(); if( nValue > 0 ) { aMtrFldOffset.SetValue( nValue ); @@ -1674,7 +1692,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aMtrFldXOffset if( rAttrs.GetItemState( XATTR_FILLBMP_POSOFFSETX ) != SFX_ITEM_DONTCARE ) { - INT32 nValue = ( ( const XFillBmpPosOffsetXItem& ) rAttrs.Get( XATTR_FILLBMP_POSOFFSETX ) ).GetValue(); + sal_Int32 nValue = ( ( const XFillBmpPosOffsetXItem& ) rAttrs.Get( XATTR_FILLBMP_POSOFFSETX ) ).GetValue(); aMtrFldXOffset.SetValue( nValue ); } else @@ -1683,7 +1701,7 @@ void SvxAreaTabPage::Reset( const SfxItemSet& rAttrs ) //aMtrFldYOffset if( rAttrs.GetItemState( XATTR_FILLBMP_POSOFFSETY ) != SFX_ITEM_DONTCARE ) { - INT32 nValue = ( ( const XFillBmpPosOffsetYItem& ) rAttrs.Get( XATTR_FILLBMP_POSOFFSETY ) ).GetValue(); + sal_Int32 nValue = ( ( const XFillBmpPosOffsetYItem& ) rAttrs.Get( XATTR_FILLBMP_POSOFFSETY ) ).GetValue(); aMtrFldYOffset.SetValue( nValue ); } else @@ -1722,7 +1740,7 @@ SfxTabPage* SvxAreaTabPage::Create( Window* pWindow, //------------------------------------------------------------------------ -USHORT* SvxAreaTabPage::GetRanges() +sal_uInt16* SvxAreaTabPage::GetRanges() { return( pAreaRanges ); } @@ -1854,7 +1872,7 @@ IMPL_LINK( SvxAreaTabPage, ClickColorHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxAreaTabPage, ModifyColorHdl_Impl, void *, EMPTYARG ) { const SfxPoolItem* pPoolItem = NULL; - USHORT _nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 _nPos = aLbColor.GetSelectEntryPos(); aLbHatchBckgrdColor.SelectEntryPos( _nPos ); if( _nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -1863,7 +1881,7 @@ IMPL_LINK( SvxAreaTabPage, ModifyColorHdl_Impl, void *, EMPTYARG ) aLbColor.GetSelectEntryColor() ) ); } // NEU - else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), TRUE, &pPoolItem ) ) + else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), sal_True, &pPoolItem ) ) { rXFSet.Put( XFillStyleItem( XFILL_SOLID ) ); Color aColor( ( ( const XFillColorItem* ) pPoolItem )->GetColorValue() ); @@ -1945,7 +1963,7 @@ IMPL_LINK( SvxAreaTabPage, ClickGradientHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxAreaTabPage, ModifyGradientHdl_Impl, void *, EMPTYARG ) { const SfxPoolItem* pPoolItem = NULL; - USHORT _nPos = aLbGradient.GetSelectEntryPos(); + sal_uInt16 _nPos = aLbGradient.GetSelectEntryPos(); if( _nPos != LISTBOX_ENTRY_NOTFOUND ) { // ItemSet fuellen und an aCtlXRectPreview weiterleiten @@ -1955,7 +1973,7 @@ IMPL_LINK( SvxAreaTabPage, ModifyGradientHdl_Impl, void *, EMPTYARG ) rXFSet.Put( XFillGradientItem( String(), pEntry->GetGradient() ) ); } - else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), TRUE, &pPoolItem ) ) + else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), sal_True, &pPoolItem ) ) { rXFSet.Put( XFillStyleItem( XFILL_GRADIENT ) ); rXFSet.Put( XFillGradientItem( String(), ( ( const XFillGradientItem* ) pPoolItem )->GetGradientValue() ) ); @@ -2039,7 +2057,7 @@ IMPL_LINK( SvxAreaTabPage, ClickHatchingHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxAreaTabPage, ModifyHatchingHdl_Impl, void *, EMPTYARG ) { const SfxPoolItem* pPoolItem = NULL; - USHORT _nPos = aLbHatching.GetSelectEntryPos(); + sal_uInt16 _nPos = aLbHatching.GetSelectEntryPos(); if( _nPos != LISTBOX_ENTRY_NOTFOUND ) { // ItemSet fuellen und an aCtlXRectPreview weiterleiten @@ -2048,7 +2066,7 @@ IMPL_LINK( SvxAreaTabPage, ModifyHatchingHdl_Impl, void *, EMPTYARG ) rXFSet.Put( XFillStyleItem( XFILL_HATCH ) ); rXFSet.Put( XFillHatchItem( String(), pEntry->GetHatch() ) ); } - else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), TRUE, &pPoolItem ) ) + else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), sal_True, &pPoolItem ) ) { rXFSet.Put( XFillStyleItem( XFILL_HATCH ) ); rXFSet.Put( XFillHatchItem( String(), ( ( const XFillHatchItem* ) pPoolItem )->GetHatchValue() ) ); @@ -2067,14 +2085,14 @@ IMPL_LINK( SvxAreaTabPage, ModifyHatchingHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxAreaTabPage, ModifyHatchBckgrdColorHdl_Impl, void *, EMPTYARG ) { const SfxPoolItem* pPoolItem = NULL; - USHORT _nPos = aLbHatchBckgrdColor.GetSelectEntryPos(); + sal_uInt16 _nPos = aLbHatchBckgrdColor.GetSelectEntryPos(); aLbColor.SelectEntryPos( _nPos ); if( _nPos != LISTBOX_ENTRY_NOTFOUND ) { rXFSet.Put( XFillColorItem( String(), aLbHatchBckgrdColor.GetSelectEntryColor() ) ); } - else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), TRUE, &pPoolItem ) ) + else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), sal_True, &pPoolItem ) ) { Color aColor( ( ( const XFillColorItem* ) pPoolItem )->GetColorValue() ); rXFSet.Put( XFillColorItem( String(), aColor ) ); @@ -2198,7 +2216,7 @@ IMPL_LINK( SvxAreaTabPage, ClickBitmapHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxAreaTabPage, ModifyBitmapHdl_Impl, void *, EMPTYARG ) { const SfxPoolItem* pPoolItem = NULL; - USHORT _nPos = aLbBitmap.GetSelectEntryPos(); + sal_uInt16 _nPos = aLbBitmap.GetSelectEntryPos(); if( _nPos != LISTBOX_ENTRY_NOTFOUND ) { // ItemSet fuellen und an aCtlXRectPreview weiterleiten @@ -2207,7 +2225,7 @@ IMPL_LINK( SvxAreaTabPage, ModifyBitmapHdl_Impl, void *, EMPTYARG ) rXFSet.Put( XFillStyleItem( XFILL_BITMAP ) ); rXFSet.Put( XFillBitmapItem( String(), pEntry->GetXBitmap() ) ); } - else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), TRUE, &pPoolItem ) ) + else if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), sal_True, &pPoolItem ) ) { rXFSet.Put( XFillStyleItem( XFILL_BITMAP ) ); rXFSet.Put( XFillBitmapItem( String(), ( ( const XFillBitmapItem* ) pPoolItem )->GetBitmapValue() ) ); @@ -2238,12 +2256,12 @@ IMPL_LINK( SvxAreaTabPage, ModifyStepCountHdl_Impl, void *, p ) aNumFldStepCount.Disable(); } - UINT16 nValue = 0; + sal_uInt16 nValue = 0; if( aTsbStepCount.GetState() != STATE_CHECK ) { // Zustand != Disabled ? if( aNumFldStepCount.GetText().Len() > 0 ) - nValue = (UINT16) aNumFldStepCount.GetValue(); + nValue = (sal_uInt16) aNumFldStepCount.GetValue(); } rXFSet.Put( XGradientStepCountItem( nValue ) ); aCtlXRectPreview.SetAttributes( aXFillAttr.GetItemSet() ); @@ -2359,12 +2377,12 @@ IMPL_LINK( SvxAreaTabPage, ModifyTileHdl_Impl, void *, EMPTYARG ) aMtrFldYSize.SetValue( aMtrFldYSize.GetValue() ); } - rXFSet.Put( XFillBmpTileItem( sal::static_int_cast< BOOL >( eState ) ) ); + rXFSet.Put( XFillBmpTileItem( sal::static_int_cast< sal_Bool >( eState ) ) ); if( aTsbStretch.IsEnabled() ) rXFSet.Put( XFillBmpStretchItem( - sal::static_int_cast< BOOL >( aTsbStretch.GetState() ) ) ); + sal::static_int_cast< sal_Bool >( aTsbStretch.GetState() ) ) ); if( aTsbScale.IsEnabled() ) rXFSet.Put( XFillBmpSizeLogItem( aTsbScale.GetState() == STATE_NOCHECK ) ); @@ -2387,7 +2405,7 @@ IMPL_LINK( SvxAreaTabPage, ModifyTileHdl_Impl, void *, EMPTYARG ) { // Originalgroesse -> Size == 0 rXFSet.Put( XFillBmpSizeXItem( 0 ) ); - rXFSet.Put( XFillBmpSizeLogItem( TRUE ) ); + rXFSet.Put( XFillBmpSizeLogItem( sal_True ) ); } if( aMtrFldYSize.IsEnabled() ) @@ -2408,20 +2426,20 @@ IMPL_LINK( SvxAreaTabPage, ModifyTileHdl_Impl, void *, EMPTYARG ) { // Originalgroesse -> Size == 0 rXFSet.Put( XFillBmpSizeYItem( 0 ) ); - rXFSet.Put( XFillBmpSizeLogItem( TRUE ) ); + rXFSet.Put( XFillBmpSizeLogItem( sal_True ) ); } if( aMtrFldOffset.IsEnabled() ) { if( aRbtRow.IsChecked() ) { - rXFSet.Put( XFillBmpTileOffsetXItem( (UINT16) aMtrFldOffset.GetValue() ) ); - rXFSet.Put( XFillBmpTileOffsetYItem( (UINT16) 0 ) ); + rXFSet.Put( XFillBmpTileOffsetXItem( (sal_uInt16) aMtrFldOffset.GetValue() ) ); + rXFSet.Put( XFillBmpTileOffsetYItem( (sal_uInt16) 0 ) ); } else if( aRbtColumn.IsChecked() ) { - rXFSet.Put( XFillBmpTileOffsetXItem( (UINT16) 0 ) ); - rXFSet.Put( XFillBmpTileOffsetYItem( (UINT16) aMtrFldOffset.GetValue() ) ); + rXFSet.Put( XFillBmpTileOffsetXItem( (sal_uInt16) 0 ) ); + rXFSet.Put( XFillBmpTileOffsetYItem( (sal_uInt16) aMtrFldOffset.GetValue() ) ); } } @@ -2429,10 +2447,10 @@ IMPL_LINK( SvxAreaTabPage, ModifyTileHdl_Impl, void *, EMPTYARG ) rXFSet.Put( XFillBmpPosItem( aCtlPosition.GetActualRP() ) ); if( aMtrFldXOffset.IsEnabled() ) - rXFSet.Put( XFillBmpPosOffsetXItem( (UINT16) aMtrFldXOffset.GetValue() ) ); + rXFSet.Put( XFillBmpPosOffsetXItem( (sal_uInt16) aMtrFldXOffset.GetValue() ) ); if( aMtrFldYOffset.IsEnabled() ) - rXFSet.Put( XFillBmpPosOffsetYItem( (UINT16) aMtrFldYOffset.GetValue() ) ); + rXFSet.Put( XFillBmpPosOffsetYItem( (sal_uInt16) aMtrFldYOffset.GetValue() ) ); aCtlBitmapPreview.SetAttributes( aXFillAttr.GetItemSet() ); diff --git a/cui/source/tabpages/tpbitmap.cxx b/cui/source/tabpages/tpbitmap.cxx index e7b5cf60275d..3deed69a50f1 100644 --- a/cui/source/tabpages/tpbitmap.cxx +++ b/cui/source/tabpages/tpbitmap.cxx @@ -66,6 +66,7 @@ #include <svx/svxdlg.hxx> #include <dialmgr.hxx> #include "sfx2/opengrf.hxx" +#include "paragrph.hrc" #define DLGWIN this->GetParent()->GetParent() @@ -140,6 +141,16 @@ SvxBitmapTabPage::SvxBitmapTabPage aLbBackgroundColor.SetSelectHdl( LINK( this, SvxBitmapTabPage, ChangeBackgrndColorHdl_Impl ) ); + String accName = String(SVX_RES(STR_EXAMPLE)); + aCtlPreview.SetAccessibleName(accName); + aCtlPixel.SetAccessibleRelationMemberOf( &aFlProp ); + aCtlPixel.SetAccessibleRelationLabeledBy( &aFtPixelEdit ); + aLbBitmaps.SetAccessibleRelationLabeledBy(&aLbBitmaps); + aBtnAdd.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnModify.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnImport.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnDelete.SetAccessibleRelationMemberOf( &aFlProp ); + } // ----------------------------------------------------------------------- @@ -158,12 +169,12 @@ void SvxBitmapTabPage::Construct() void SvxBitmapTabPage::ActivatePage( const SfxItemSet& ) { - USHORT nPos; - USHORT nCount; + sal_uInt16 nPos; + sal_uInt16 nCount; if( *pDlgType == 0 ) // Flaechen-Dialog { - *pbAreaTP = FALSE; + *pbAreaTP = sal_False; if( pColorTab ) { @@ -246,9 +257,9 @@ int SvxBitmapTabPage::DeactivatePage( SfxItemSet* _pSet) // ----------------------------------------------------------------------- -BOOL SvxBitmapTabPage::FillItemSet( SfxItemSet& _rOutAttrs ) +sal_Bool SvxBitmapTabPage::FillItemSet( SfxItemSet& _rOutAttrs ) { - if( *pDlgType == 0 && *pbAreaTP == FALSE ) // Flaechen-Dialog + if( *pDlgType == 0 && *pbAreaTP == sal_False ) // Flaechen-Dialog { if( *pPageType == PT_BITMAP ) { @@ -256,7 +267,7 @@ BOOL SvxBitmapTabPage::FillItemSet( SfxItemSet& _rOutAttrs ) XOBitmap aXOBitmap; String aString; - USHORT nPos = aLbBitmaps.GetSelectEntryPos(); + sal_uInt16 nPos = aLbBitmaps.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { aXOBitmap = pBitmapList->GetBitmap( nPos )->GetXBitmap(); @@ -276,7 +287,7 @@ BOOL SvxBitmapTabPage::FillItemSet( SfxItemSet& _rOutAttrs ) _rOutAttrs.Put( XFillBitmapItem( aString, aXOBitmap ) ); } } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------- @@ -334,11 +345,11 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) else { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), sal_True, &pPoolItem ) ) { XFillStyle eXFS = (XFillStyle) ( ( const XFillStyleItem* ) pPoolItem )->GetValue(); if( ( XFILL_BITMAP == eXFS ) && - ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), TRUE, &pPoolItem ) ) ) + ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLBITMAP ), sal_True, &pPoolItem ) ) ) { pXOBitmap = new XOBitmap( ( ( const XFillBitmapItem* ) pPoolItem )->GetBitmapValue() ); } @@ -365,7 +376,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) sal_uInt32 nCol1(0xffffffff); // background sal_uInt32 nCol2(0xffffffff); // pixel BitmapReadAccess* pAccess = aBitmap.AcquireReadAccess(); - sal_Bool bValid(TRUE); + sal_Bool bValid(sal_True); if(pAccess) { @@ -398,7 +409,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) else { // Third color detected - bValid = FALSE; + bValid = sal_False; } } else @@ -421,7 +432,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) else { // no access -> no success - bValid = FALSE; + bValid = sal_False; } if(bValid) @@ -454,7 +465,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) if( pXOBitmap->GetBitmapType() == XBITMAP_IMPORT ) { aCtlPixel.Reset(); - aCtlPixel.SetPaintable( FALSE ); + aCtlPixel.SetPaintable( sal_False ); aCtlPixel.Disable(); aFtPixelEdit.Disable(); aFtColor.Disable(); @@ -466,7 +477,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) } else if( pXOBitmap->GetBitmapType() == XBITMAP_8X8 ) { - aCtlPixel.SetPaintable( TRUE ); + aCtlPixel.SetPaintable( sal_True ); aCtlPixel.Enable(); aFtPixelEdit.Enable(); aFtColor.Enable(); @@ -515,7 +526,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) aCtlPreview.SetAttributes( aXFillAttr.GetItemSet() ); aCtlPreview.Invalidate(); - bBmpChanged = FALSE; + bBmpChanged = sal_False; delete pXOBitmap; } return 0L; @@ -525,7 +536,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBitmapHdl_Impl, void *, EMPTYARG ) long SvxBitmapTabPage::CheckChanges_Impl() { - USHORT nPos = aLbBitmaps.GetSelectEntryPos(); + sal_uInt16 nPos = aLbBitmaps.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { String aString = aLbBitmaps.GetSelectEntry(); @@ -586,18 +597,18 @@ IMPL_LINK( SvxBitmapTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) long nCount = pBitmapList->Count(); long j = 1; - BOOL bDifferent = FALSE; + sal_Bool bDifferent = sal_False; while( !bDifferent ) { aName = aNewName; aName += sal_Unicode(' '); aName += UniString::CreateFromInt32( j++ ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pBitmapList->GetBitmap( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); @@ -605,17 +616,17 @@ IMPL_LINK( SvxBitmapTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); WarningBox* pWarnBox = NULL; - USHORT nError = RID_SVXSTR_WARN_NAME_DUPLICATE; + sal_uInt16 nError = RID_SVXSTR_WARN_NAME_DUPLICATE; while( pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pBitmapList->GetBitmap( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; if( bDifferent ) { nError = 0; @@ -652,7 +663,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) else // Es muss sich um eine nicht vorhandene importierte Bitmap handeln { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == rOutAttrs.GetItemState( XATTR_FILLBITMAP, TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == rOutAttrs.GetItemState( XATTR_FILLBITMAP, sal_True, &pPoolItem ) ) { XOBitmap aXOBitmap( ( ( const XFillBitmapItem* ) pPoolItem )->GetBitmapValue() ); pEntry = new XBitmapEntry( aXOBitmap, aName ); @@ -671,7 +682,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) #ifdef WNT // hack: #31355# W.P. Rectangle aRect( aLbBitmaps.GetPosPixel(), aLbBitmaps.GetSizePixel() ); - if( TRUE ) { // ??? overlapped with pDlg + if( sal_True ) { // ??? overlapped with pDlg // and srolling Invalidate( aRect ); //aLbBitmaps.Invalidate(); @@ -739,12 +750,12 @@ IMPL_LINK( SvxBitmapTabPage, ClickImportHdl_Impl, void *, EMPTYARG ) { pDlg->GetName( aName ); - BOOL bDifferent = TRUE; + sal_Bool bDifferent = sal_True; long nCount = pBitmapList->Count(); for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pBitmapList->GetBitmap( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; if( bDifferent ) { nError = 0; @@ -779,7 +790,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickImportHdl_Impl, void *, EMPTYARG ) #ifdef WNT // hack: #31355# W.P. Rectangle aRect( aLbBitmaps.GetPosPixel(), aLbBitmaps.GetSizePixel() ); - if( TRUE ) { // ??? overlapped with pDlg + if( sal_True ) { // ??? overlapped with pDlg // and srolling Invalidate( aRect ); } @@ -809,7 +820,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickImportHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxBitmapTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbBitmaps.GetSelectEntryPos(); + sal_uInt16 nPos = aLbBitmaps.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -825,24 +836,24 @@ IMPL_LINK( SvxBitmapTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pDlg, "Dialogdiet fail!"); long nCount = pBitmapList->Count(); - BOOL bDifferent = FALSE; - BOOL bLoop = TRUE; + sal_Bool bDifferent = sal_False; + sal_Bool bLoop = sal_True; while( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pBitmapList->GetBitmap( i )->GetName() && aName != aOldName ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; XBitmapEntry* pEntry = pBitmapList->GetBitmap( nPos ); pEntry->SetName( aName ); @@ -861,7 +872,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) // Flag fuer modifiziert setzen *pnBitmapListState |= CT_MODIFIED; - bBmpChanged = FALSE; + bBmpChanged = sal_False; } else { @@ -879,7 +890,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxBitmapTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbBitmaps.GetSelectEntryPos(); + sal_uInt16 nPos = aLbBitmaps.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -915,7 +926,7 @@ IMPL_LINK( SvxBitmapTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxBitmapTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; ResMgr& rMgr = CUI_MGR(); if ( *pnBitmapListState & CT_MODIFIED ) @@ -1084,7 +1095,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangePixelColorHdl_Impl, void *, EMPTYARG ) aCtlPreview.SetAttributes( aXFillAttr.GetItemSet() ); aCtlPreview.Invalidate(); - bBmpChanged = TRUE; + bBmpChanged = sal_True; return 0L; } @@ -1103,7 +1114,7 @@ IMPL_LINK( SvxBitmapTabPage, ChangeBackgrndColorHdl_Impl, void *, EMPTYARG ) aCtlPreview.SetAttributes( aXFillAttr.GetItemSet() ); aCtlPreview.Invalidate(); - bBmpChanged = TRUE; + bBmpChanged = sal_True; return 0L; } @@ -1121,7 +1132,7 @@ void SvxBitmapTabPage::PointChanged( Window* pWindow, RECT_POINT ) aCtlPreview.SetAttributes( aXFillAttr.GetItemSet() ); aCtlPreview.Invalidate(); - bBmpChanged = TRUE; + bBmpChanged = sal_True; } } diff --git a/cui/source/tabpages/tpcolor.cxx b/cui/source/tabpages/tpcolor.cxx index 124417157409..5a71867ef587 100644 --- a/cui/source/tabpages/tpcolor.cxx +++ b/cui/source/tabpages/tpcolor.cxx @@ -113,7 +113,7 @@ SvxColorTabPage::SvxColorTabPage rOutAttrs ( rInAttrs ), pColorTab( NULL ), - bDeleteColorTable ( TRUE ), + bDeleteColorTable ( sal_True ), pXPool ( (XOutdevItemPool*) rInAttrs.GetPool() ), aXFStyleItem ( XFILL_SOLID ), @@ -166,6 +166,11 @@ SvxColorTabPage::SvxColorTabPage aValSetColorTable.SetExtraSpacing( 0 ); aValSetColorTable.Show(); + aLbColorModel.SetAccessibleName( String( CUI_RES(STR_CUI_COLORMODEL) ) ); + aBtnAdd.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnModify.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnWorkOn.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnDelete.SetAccessibleRelationMemberOf( &aFlProp ); } // ----------------------------------------------------------------------- @@ -182,7 +187,7 @@ void SvxColorTabPage::ActivatePage( const SfxItemSet& ) { if( *pDlgType == 0 ) // Flaechen-Dialog { - *pbAreaTP = FALSE; + *pbAreaTP = sal_False; if( pColorTab ) { @@ -197,7 +202,7 @@ void SvxColorTabPage::ActivatePage( const SfxItemSet& ) else if( *pPageType == PT_COLOR && *pPos == LISTBOX_ENTRY_NOTFOUND ) { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLCOLOR ), sal_True, &pPoolItem ) ) { aLbColorModel.SelectEntryPos( CM_RGB ); @@ -279,7 +284,7 @@ long SvxColorTabPage::CheckChanges_Impl() if (eCM != CM_RGB) ConvertColorValues (aTmpColor, CM_RGB); - USHORT nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { Color aColor = pColorTab->GetColor( nPos )->GetColor(); @@ -345,15 +350,15 @@ long SvxColorTabPage::CheckChanges_Impl() // ----------------------------------------------------------------------- -BOOL SvxColorTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxColorTabPage::FillItemSet( SfxItemSet& rSet ) { if( ( *pDlgType != 0 ) || - ( *pPageType == PT_COLOR && *pbAreaTP == FALSE ) ) + ( *pPageType == PT_COLOR && *pbAreaTP == sal_False ) ) { String aString; Color aColor; - USHORT nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { aColor = pColorTab->GetColor( nPos )->GetColor(); @@ -369,14 +374,14 @@ BOOL SvxColorTabPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( XFillStyleItem( XFILL_SOLID ) ); } - return( TRUE ); + return( sal_True ); } // ----------------------------------------------------------------------- void SvxColorTabPage::Reset( const SfxItemSet& rSet ) { - USHORT nState = rSet.GetItemState( XATTR_FILLCOLOR ); + sal_uInt16 nState = rSet.GetItemState( XATTR_FILLCOLOR ); if ( nState >= SFX_ITEM_DEFAULT ) { @@ -388,7 +393,7 @@ void SvxColorTabPage::Reset( const SfxItemSet& rSet ) // Farbmodell setzen String aStr = GetUserData(); - aLbColorModel.SelectEntryPos( (USHORT) aStr.ToInt32() ); + aLbColorModel.SelectEntryPos( (sal_uInt16) aStr.ToInt32() ); ChangeColorHdl_Impl( this ); SelectColorModelHdl_Impl( this ); @@ -428,10 +433,10 @@ SfxTabPage* SvxColorTabPage::Create( Window* pWindow, IMPL_LINK( SvxColorTabPage, ModifiedHdl_Impl, void *, EMPTYARG ) { // lese aktuelle MtrFields aus, wenn cmyk, dann k-Wert als Trans.-Farbe - aAktuellColor.SetColor ( Color( (UINT8)PercentToColor_Impl( (USHORT) aMtrFldColorModel4.GetValue() ), - (UINT8)PercentToColor_Impl( (USHORT) aMtrFldColorModel1.GetValue() ), - (UINT8)PercentToColor_Impl( (USHORT) aMtrFldColorModel2.GetValue() ), - (UINT8)PercentToColor_Impl( (USHORT) aMtrFldColorModel3.GetValue() ) ).GetColor() ); + aAktuellColor.SetColor ( Color( (sal_uInt8)PercentToColor_Impl( (sal_uInt16) aMtrFldColorModel4.GetValue() ), + (sal_uInt8)PercentToColor_Impl( (sal_uInt16) aMtrFldColorModel1.GetValue() ), + (sal_uInt8)PercentToColor_Impl( (sal_uInt16) aMtrFldColorModel2.GetValue() ), + (sal_uInt8)PercentToColor_Impl( (sal_uInt16) aMtrFldColorModel3.GetValue() ) ).GetColor() ); Color aTmpColor(aAktuellColor); if (eCM != CM_RGB) @@ -463,12 +468,12 @@ IMPL_LINK( SvxColorTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) String aName( aEdtName.GetText() ); XColorEntry* pEntry; long nCount = pColorTab->Count(); - BOOL bDifferent = TRUE; + sal_Bool bDifferent = sal_True; // Pruefen, ob Name schon vorhanden ist for ( long i = 0; i < nCount && bDifferent; i++ ) if ( aName == pColorTab->GetColor( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; // Wenn ja, wird wiederholt ein neuer Name angefordert if ( !bDifferent ) @@ -482,21 +487,21 @@ IMPL_LINK( SvxColorTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pFact, "Dialogdiet fail!"); AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); - BOOL bLoop = TRUE; + sal_Bool bLoop = sal_True; while ( !bDifferent && bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pColorTab->GetColor( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) - bLoop = FALSE; + bLoop = sal_False; else aWarningBox.Execute(); } @@ -541,7 +546,7 @@ IMPL_LINK( SvxColorTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) // IMPL_LINK( SvxColorTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -549,12 +554,12 @@ IMPL_LINK( SvxColorTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) String aDesc( ResId( RID_SVXSTR_DESC_COLOR, rMgr ) ); String aName( aEdtName.GetText() ); long nCount = pColorTab->Count(); - BOOL bDifferent = TRUE; + sal_Bool bDifferent = sal_True; // Pruefen, ob Name schon vorhanden ist for ( long i = 0; i < nCount && bDifferent; i++ ) if ( aName == pColorTab->GetColor( i )->GetName() && nPos != i ) - bDifferent = FALSE; + bDifferent = sal_False; // Wenn ja, wird wiederholt ein neuer Name angefordert if ( !bDifferent ) @@ -568,19 +573,19 @@ IMPL_LINK( SvxColorTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pFact, "Dialogdiet fail!"); AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); - BOOL bLoop = TRUE; + sal_Bool bLoop = sal_True; while ( !bDifferent && bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for ( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pColorTab->GetColor( i )->GetName() && nPos != i ) - bDifferent = FALSE; + bDifferent = sal_False; if( bDifferent ) - bLoop = FALSE; + bLoop = sal_False; else aWarningBox.Execute(); } @@ -632,7 +637,7 @@ IMPL_LINK( SvxColorTabPage, ClickWorkOnHdl_Impl, void *, EMPTYARG ) if( pColorDlg->Execute() == RET_OK ) { - USHORT nK = 0; + sal_uInt16 nK = 0; Color aPreviewColor = pColorDlg->GetColor(); aAktuellColor = aPreviewColor; if (eCM != CM_RGB) @@ -662,7 +667,7 @@ IMPL_LINK( SvxColorTabPage, ClickWorkOnHdl_Impl, void *, EMPTYARG ) // IMPL_LINK( SvxColorTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -672,14 +677,14 @@ IMPL_LINK( SvxColorTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) if( aQueryBox.Execute() == RET_YES ) { // Jetzt wird richtig geloescht - ULONG nCount = pColorTab->Count() - 1; + sal_uLong nCount = pColorTab->Count() - 1; XColorEntry* pEntry; pEntry = pColorTab->Remove( nPos ); DBG_ASSERT( pEntry, "ColorEntry nicht vorhanden (1) !" ); delete pEntry; - for( ULONG i = nPos; i < nCount; i++ ) + for( sal_uLong i = nPos; i < nCount; i++ ) { pEntry = pColorTab->Remove( i + 1 ); DBG_ASSERT( pEntry, "ColorEntry nicht vorhanden (2) !" ); @@ -720,7 +725,7 @@ IMPL_LINK( SvxColorTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxColorTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { ResMgr& rMgr = CUI_MGR(); - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; if( *pnColorTableState & CT_MODIFIED ) { @@ -772,7 +777,7 @@ IMPL_LINK( SvxColorTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) if( bDeleteColorTable ) delete pColorTab; else - bDeleteColorTable = TRUE; + bDeleteColorTable = sal_True; } pColorTab = pColTab; @@ -917,7 +922,7 @@ IMPL_LINK( SvxColorTabPage, ClickSaveHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxColorTabPage, SelectColorLBHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { aValSetColorTable.SelectItem( nPos + 1 ); @@ -940,7 +945,7 @@ IMPL_LINK( SvxColorTabPage, SelectColorLBHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxColorTabPage, SelectValSetHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aValSetColorTable.GetSelectItemId(); + sal_uInt16 nPos = aValSetColorTable.GetSelectItemId(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { aLbColor.SelectEntryPos( nPos - 1 ); @@ -970,16 +975,16 @@ void SvxColorTabPage::ConvertColorValues (Color& rColor, ColorModel eModell) { case CM_RGB: { - CmykToRgb_Impl (rColor, (USHORT)rColor.GetTransparency() ); - rColor.SetTransparency ((UINT8) 0); + CmykToRgb_Impl (rColor, (sal_uInt16)rColor.GetTransparency() ); + rColor.SetTransparency ((sal_uInt8) 0); } break; case CM_CMYK: { - USHORT nK; + sal_uInt16 nK; RgbToCmyk_Impl (rColor, nK ); - rColor.SetTransparency ((UINT8) nK); + rColor.SetTransparency ((sal_uInt8) nK); } break; } @@ -1104,6 +1109,12 @@ IMPL_LINK( SvxColorTabPage, SelectColorModelHdl_Impl, void *, EMPTYARG ) aMtrFldColorModel3.SetValue( ColorToPercent_Impl( aAktuellColor.GetBlue() ) ); aMtrFldColorModel4.SetValue( ColorToPercent_Impl( aAktuellColor.GetTransparency() ) ); } + + aMtrFldColorModel1.SetAccessibleName( GetNonMnemonicString(aFtColorModel1.GetText()) ); + aMtrFldColorModel2.SetAccessibleName( GetNonMnemonicString(aFtColorModel2.GetText()) ); + aMtrFldColorModel3.SetAccessibleName( GetNonMnemonicString(aFtColorModel3.GetText()) ); + aMtrFldColorModel4.SetAccessibleName( GetNonMnemonicString(aFtColorModel4.GetText()) ); + return( 0L ); } @@ -1145,7 +1156,7 @@ void SvxColorTabPage::FillValueSet_Impl( ValueSet& rVs ) for( long i = 0; i < nCount; i++ ) { pColorEntry = pColorTab->GetColor( i ); - rVs.InsertItem( (USHORT) i + 1, pColorEntry->GetColor(), pColorEntry->GetName() ); + rVs.InsertItem( (sal_uInt16) i + 1, pColorEntry->GetColor(), pColorEntry->GetName() ); } } @@ -1157,24 +1168,24 @@ void SvxColorTabPage::FillValueSet_Impl( ValueSet& rVs ) // Bei weiteren Farbmodellen sollte man hierfuer eigene Klassen entwickeln, // die dann auch entsprechende Casts enthalten. -void SvxColorTabPage::RgbToCmyk_Impl( Color& rColor, USHORT& rK ) +void SvxColorTabPage::RgbToCmyk_Impl( Color& rColor, sal_uInt16& rK ) { - USHORT const nColor1 = 255 - rColor.GetRed(); - USHORT const nColor2 = 255 - rColor.GetGreen(); - USHORT const nColor3 = 255 - rColor.GetBlue(); + sal_uInt16 const nColor1 = 255 - rColor.GetRed(); + sal_uInt16 const nColor2 = 255 - rColor.GetGreen(); + sal_uInt16 const nColor3 = 255 - rColor.GetBlue(); rK = Min( Min( nColor1, nColor2 ), nColor3 ); - rColor.SetRed( sal::static_int_cast< UINT8 >( nColor1 - rK ) ); - rColor.SetGreen( sal::static_int_cast< UINT8 >( nColor2 - rK ) ); - rColor.SetBlue( sal::static_int_cast< UINT8 >( nColor3 - rK ) ); + rColor.SetRed( sal::static_int_cast< sal_uInt8 >( nColor1 - rK ) ); + rColor.SetGreen( sal::static_int_cast< sal_uInt8 >( nColor2 - rK ) ); + rColor.SetBlue( sal::static_int_cast< sal_uInt8 >( nColor3 - rK ) ); } //------------------------------------------------------------------------ // Umgekehrter Fall zu RgbToCmyk_Impl (s.o.) -void SvxColorTabPage::CmykToRgb_Impl( Color& rColor, const USHORT nK ) +void SvxColorTabPage::CmykToRgb_Impl( Color& rColor, const sal_uInt16 nK ) { long lTemp; @@ -1182,26 +1193,26 @@ void SvxColorTabPage::CmykToRgb_Impl( Color& rColor, const USHORT nK ) if( lTemp < 0L ) lTemp = 0L; - rColor.SetRed( (BYTE)lTemp ); + rColor.SetRed( (sal_uInt8)lTemp ); lTemp = 255 - ( rColor.GetGreen() + nK ); if( lTemp < 0L ) lTemp = 0L; - rColor.SetGreen( (BYTE)lTemp ); + rColor.SetGreen( (sal_uInt8)lTemp ); lTemp = 255 - ( rColor.GetBlue() + nK ); if( lTemp < 0L ) lTemp = 0L; - rColor.SetBlue( (BYTE)lTemp ); + rColor.SetBlue( (sal_uInt8)lTemp ); } //------------------------------------------------------------------------ -USHORT SvxColorTabPage::ColorToPercent_Impl( USHORT nColor ) +sal_uInt16 SvxColorTabPage::ColorToPercent_Impl( sal_uInt16 nColor ) { - USHORT nWert = 0; + sal_uInt16 nWert = 0; switch (eCM) { @@ -1210,7 +1221,7 @@ USHORT SvxColorTabPage::ColorToPercent_Impl( USHORT nColor ) break; case CM_CMYK: - nWert = (USHORT) ( (double) nColor * 100.0 / 255.0 + 0.5 ); + nWert = (sal_uInt16) ( (double) nColor * 100.0 / 255.0 + 0.5 ); break; } @@ -1219,9 +1230,9 @@ USHORT SvxColorTabPage::ColorToPercent_Impl( USHORT nColor ) //------------------------------------------------------------------------ -USHORT SvxColorTabPage::PercentToColor_Impl( USHORT nPercent ) +sal_uInt16 SvxColorTabPage::PercentToColor_Impl( sal_uInt16 nPercent ) { - USHORT nWert = 0; + sal_uInt16 nWert = 0; switch (eCM) { @@ -1230,7 +1241,7 @@ USHORT SvxColorTabPage::PercentToColor_Impl( USHORT nPercent ) break; case CM_CMYK: - nWert = (USHORT) ( (double) nPercent * 255.0 / 100.0 + 0.5 ); + nWert = (sal_uInt16) ( (double) nPercent * 255.0 / 100.0 + 0.5 ); break; } diff --git a/cui/source/tabpages/tpgradnt.cxx b/cui/source/tabpages/tpgradnt.cxx index e7b68c9f2f95..d762f74c70c6 100644 --- a/cui/source/tabpages/tpgradnt.cxx +++ b/cui/source/tabpages/tpgradnt.cxx @@ -50,6 +50,7 @@ #include <dialmgr.hxx> #include <svx/dialmgr.hxx> #include <svx/dialogs.hrc> +#include "paragrph.hrc" #define DLGWIN this->GetParent()->GetParent() @@ -107,6 +108,10 @@ SvxGradientTabPage::SvxGradientTabPage { FreeResource(); + aCtlPreview.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + aLbGradients.SetAccessibleName( GetText()); + + // diese Page braucht ExchangeSupport SetExchangeSupport(); @@ -145,8 +150,13 @@ SvxGradientTabPage::SvxGradientTabPage aBtnSave.SetClickHdl( LINK( this, SvxGradientTabPage, ClickSaveHdl_Impl ) ); + aBtnAdd.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnModify.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnDelete.SetAccessibleRelationMemberOf( &aFlProp ); + aLbGradients.SetAccessibleRelationLabeledBy(&aLbGradients); + // #i76307# always paint the preview in LTR, because this is what the document does - aCtlPreview.EnableRTL( FALSE ); + aCtlPreview.EnableRTL( sal_False ); } // ----------------------------------------------------------------------- @@ -165,12 +175,12 @@ void SvxGradientTabPage::Construct() void SvxGradientTabPage::ActivatePage( const SfxItemSet& ) { - USHORT nPos; - USHORT nCount; + sal_uInt16 nPos; + sal_uInt16 nCount; if( *pDlgType == 0 ) // Flaechen-Dialog { - *pbAreaTP = FALSE; + *pbAreaTP = sal_False; if( pColorTab ) { @@ -259,13 +269,13 @@ long SvxGradientTabPage::CheckChanges_Impl() aLbColorTo.GetSelectEntryColor(), (XGradientStyle) aLbGradientType.GetSelectEntryPos(), static_cast<long>(aMtrAngle.GetValue() * 10), // sollte in Resource geaendert werden - (USHORT) aMtrCenterX.GetValue(), - (USHORT) aMtrCenterY.GetValue(), - (USHORT) aMtrBorder.GetValue(), - (USHORT) aMtrColorFrom.GetValue(), - (USHORT) aMtrColorTo.GetValue() ); + (sal_uInt16) aMtrCenterX.GetValue(), + (sal_uInt16) aMtrCenterY.GetValue(), + (sal_uInt16) aMtrBorder.GetValue(), + (sal_uInt16) aMtrColorFrom.GetValue(), + (sal_uInt16) aMtrColorTo.GetValue() ); - USHORT nPos = aLbGradients.GetSelectEntryPos(); + sal_uInt16 nPos = aLbGradients.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { XGradient aGradient = pGradientList->GetGradient( nPos )->GetGradient(); @@ -322,15 +332,15 @@ long SvxGradientTabPage::CheckChanges_Impl() // ----------------------------------------------------------------------- -BOOL SvxGradientTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxGradientTabPage::FillItemSet( SfxItemSet& rSet ) { - if( *pDlgType == 0 && *pPageType == PT_GRADIENT && *pbAreaTP == FALSE ) + if( *pDlgType == 0 && *pPageType == PT_GRADIENT && *pbAreaTP == sal_False ) { // CheckChanges(); <-- doppelte Abfrage ? XGradient* pXGradient = NULL; String aString; - USHORT nPos = aLbGradients.GetSelectEntryPos(); + sal_uInt16 nPos = aLbGradients.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { pXGradient = new XGradient( pGradientList->GetGradient( nPos )->GetGradient() ); @@ -344,11 +354,11 @@ BOOL SvxGradientTabPage::FillItemSet( SfxItemSet& rSet ) aLbColorTo.GetSelectEntryColor(), (XGradientStyle) aLbGradientType.GetSelectEntryPos(), static_cast<long>(aMtrAngle.GetValue() * 10), // sollte in Resource geaendert werden - (USHORT) aMtrCenterX.GetValue(), - (USHORT) aMtrCenterY.GetValue(), - (USHORT) aMtrBorder.GetValue(), - (USHORT) aMtrColorFrom.GetValue(), - (USHORT) aMtrColorTo.GetValue() ); + (sal_uInt16) aMtrCenterX.GetValue(), + (sal_uInt16) aMtrCenterY.GetValue(), + (sal_uInt16) aMtrBorder.GetValue(), + (sal_uInt16) aMtrColorFrom.GetValue(), + (sal_uInt16) aMtrColorTo.GetValue() ); } DBG_ASSERT( pXGradient, "XGradient konnte nicht erzeugt werden" ); rSet.Put( XFillStyleItem( XFILL_GRADIENT ) ); @@ -356,7 +366,7 @@ BOOL SvxGradientTabPage::FillItemSet( SfxItemSet& rSet ) delete pXGradient; } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------- @@ -399,11 +409,11 @@ IMPL_LINK( SvxGradientTabPage, ModifiedHdl_Impl, void *, pControl ) aLbColorTo.GetSelectEntryColor(), eXGS, static_cast<long>(aMtrAngle.GetValue() * 10), // sollte in Resource geaendert werden - (USHORT) aMtrCenterX.GetValue(), - (USHORT) aMtrCenterY.GetValue(), - (USHORT) aMtrBorder.GetValue(), - (USHORT) aMtrColorFrom.GetValue(), - (USHORT) aMtrColorTo.GetValue() ); + (sal_uInt16) aMtrCenterX.GetValue(), + (sal_uInt16) aMtrCenterY.GetValue(), + (sal_uInt16) aMtrBorder.GetValue(), + (sal_uInt16) aMtrColorFrom.GetValue(), + (sal_uInt16) aMtrColorTo.GetValue() ); // Enablen/Disablen von Controls if( pControl == &aLbGradientType || pControl == this ) @@ -429,18 +439,18 @@ IMPL_LINK( SvxGradientTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) long nCount = pGradientList->Count(); long j = 1; - BOOL bDifferent = FALSE; + sal_Bool bDifferent = sal_False; while( !bDifferent ) { aName = aNewName; aName += sal_Unicode(' '); aName += UniString::CreateFromInt32( j++ ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pGradientList->GetGradient( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); @@ -448,17 +458,17 @@ IMPL_LINK( SvxGradientTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); WarningBox* pWarnBox = NULL; - USHORT nError = RID_SVXSTR_WARN_NAME_DUPLICATE; + sal_uInt16 nError = RID_SVXSTR_WARN_NAME_DUPLICATE; while( pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pGradientList->GetGradient( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; if( bDifferent ) { @@ -486,11 +496,11 @@ IMPL_LINK( SvxGradientTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) aLbColorTo.GetSelectEntryColor(), (XGradientStyle) aLbGradientType.GetSelectEntryPos(), static_cast<long>(aMtrAngle.GetValue() * 10), // sollte in Resource geaendert werden - (USHORT) aMtrCenterX.GetValue(), - (USHORT) aMtrCenterY.GetValue(), - (USHORT) aMtrBorder.GetValue(), - (USHORT) aMtrColorFrom.GetValue(), - (USHORT) aMtrColorTo.GetValue() ); + (sal_uInt16) aMtrCenterX.GetValue(), + (sal_uInt16) aMtrCenterY.GetValue(), + (sal_uInt16) aMtrBorder.GetValue(), + (sal_uInt16) aMtrColorFrom.GetValue(), + (sal_uInt16) aMtrColorTo.GetValue() ); XGradientEntry* pEntry = new XGradientEntry( aXGradient, aName ); pGradientList->Insert( pEntry, nCount ); @@ -502,7 +512,7 @@ IMPL_LINK( SvxGradientTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) #ifdef WNT // hack: #31355# W.P. Rectangle aRect( aLbGradients.GetPosPixel(), aLbGradients.GetSizePixel() ); - if( TRUE ) { // ??? overlapped with pDlg + if( sal_True ) { // ??? overlapped with pDlg // and srolling Invalidate( aRect ); } @@ -528,7 +538,7 @@ IMPL_LINK( SvxGradientTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxGradientTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbGradients.GetSelectEntryPos(); + sal_uInt16 nPos = aLbGradients.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -544,33 +554,33 @@ IMPL_LINK( SvxGradientTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pDlg, "Dialogdiet fail!"); long nCount = pGradientList->Count(); - BOOL bDifferent = FALSE; - BOOL bLoop = TRUE; + sal_Bool bDifferent = sal_False; + sal_Bool bLoop = sal_True; while( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pGradientList->GetGradient( i )->GetName() && aName != aOldName ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; XGradient aXGradient( aLbColorFrom.GetSelectEntryColor(), aLbColorTo.GetSelectEntryColor(), (XGradientStyle) aLbGradientType.GetSelectEntryPos(), static_cast<long>(aMtrAngle.GetValue() * 10), // sollte in Resource geaendert werden - (USHORT) aMtrCenterX.GetValue(), - (USHORT) aMtrCenterY.GetValue(), - (USHORT) aMtrBorder.GetValue(), - (USHORT) aMtrColorFrom.GetValue(), - (USHORT) aMtrColorTo.GetValue() ); + (sal_uInt16) aMtrCenterX.GetValue(), + (sal_uInt16) aMtrCenterY.GetValue(), + (sal_uInt16) aMtrBorder.GetValue(), + (sal_uInt16) aMtrColorFrom.GetValue(), + (sal_uInt16) aMtrColorTo.GetValue() ); XGradientEntry* pEntry = new XGradientEntry( aXGradient, aName ); @@ -600,7 +610,7 @@ IMPL_LINK( SvxGradientTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxGradientTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbGradients.GetSelectEntryPos(); + sal_uInt16 nPos = aLbGradients.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -636,7 +646,7 @@ IMPL_LINK( SvxGradientTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxGradientTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { ResMgr& rMgr = CUI_MGR(); - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; if ( *pnGradientListState & CT_MODIFIED ) { @@ -806,10 +816,10 @@ IMPL_LINK( SvxGradientTabPage, ChangeGradientHdl_Impl, void *, EMPTYARG ) else { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), sal_True, &pPoolItem ) ) { if( ( XFILL_GRADIENT == (XFillStyle) ( ( const XFillStyleItem* ) pPoolItem )->GetValue() ) && - ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), TRUE, &pPoolItem ) ) ) + ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLGRADIENT ), sal_True, &pPoolItem ) ) ) { pGradient = new XGradient( ( ( const XFillGradientItem* ) pPoolItem )->GetGradientValue() ); } @@ -828,7 +838,7 @@ IMPL_LINK( SvxGradientTabPage, ChangeGradientHdl_Impl, void *, EMPTYARG ) XGradientStyle eXGS = pGradient->GetGradientStyle(); aLbGradientType.SelectEntryPos( - sal::static_int_cast< USHORT >( eXGS ) ); + sal::static_int_cast< sal_uInt16 >( eXGS ) ); // Wenn der EIntrag nicht in der Listbox ist, werden die Farben // temporaer hinzugenommen aLbColorFrom.SetNoSelection(); diff --git a/cui/source/tabpages/tphatch.cxx b/cui/source/tabpages/tphatch.cxx index 7896c0aa128c..de7365e54d20 100644 --- a/cui/source/tabpages/tphatch.cxx +++ b/cui/source/tabpages/tphatch.cxx @@ -50,6 +50,7 @@ #include <dialmgr.hxx> #include "svx/dlgutil.hxx" #include <svx/dialmgr.hxx> +#include "paragrph.hrc" #include <svx/dialogs.hrc> #define DLGWIN this->GetParent()->GetParent() @@ -146,6 +147,15 @@ SvxHatchTabPage::SvxHatchTabPage aBtnSave.SetClickHdl( LINK( this, SvxHatchTabPage, ClickSaveHdl_Impl ) ); aCtlPreview.SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + + aCtlPreview.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + aLbHatchings.SetAccessibleName( String(CUI_RES(STR_LB_HATCHINGSTYLE)) ); + aCtlAngle.SetAccessibleRelationMemberOf( &aFlProp ); + aLbHatchings.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnAdd.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnModify.SetAccessibleRelationMemberOf( &aFlProp ); + aBtnDelete.SetAccessibleRelationMemberOf( &aFlProp ); + aLbHatchings.SetAccessibleRelationLabeledBy(&aLbHatchings); } // ----------------------------------------------------------------------- @@ -163,12 +173,12 @@ void SvxHatchTabPage::Construct() void SvxHatchTabPage::ActivatePage( const SfxItemSet& rSet ) { - USHORT nPos; - USHORT nCount; + sal_uInt16 nPos; + sal_uInt16 nCount; if( *pDlgType == 0 ) // Flaechen-Dialog { - *pbAreaTP = FALSE; + *pbAreaTP = sal_False; if( pColorTab ) { @@ -287,7 +297,7 @@ long SvxHatchTabPage::CheckChanges_Impl() delete aMessDlg; } - USHORT nPos = aLbHatchings.GetSelectEntryPos(); + sal_uInt16 nPos = aLbHatchings.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) *pPos = nPos; return 0L; @@ -295,9 +305,9 @@ long SvxHatchTabPage::CheckChanges_Impl() // ----------------------------------------------------------------------- -BOOL SvxHatchTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxHatchTabPage::FillItemSet( SfxItemSet& rSet ) { - if( *pDlgType == 0 && *pbAreaTP == FALSE ) // Flaechen-Dialog + if( *pDlgType == 0 && *pbAreaTP == sal_False ) // Flaechen-Dialog { if( *pPageType == PT_HATCH ) { @@ -305,7 +315,7 @@ BOOL SvxHatchTabPage::FillItemSet( SfxItemSet& rSet ) XHatch* pXHatch = NULL; String aString; - USHORT nPos = aLbHatchings.GetSelectEntryPos(); + sal_uInt16 nPos = aLbHatchings.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { pXHatch = new XHatch( pHatchingList->GetHatch( nPos )->GetHatch() ); @@ -326,7 +336,7 @@ BOOL SvxHatchTabPage::FillItemSet( SfxItemSet& rSet ) delete pXHatch; } } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------- @@ -409,10 +419,10 @@ IMPL_LINK( SvxHatchTabPage, ChangeHatchHdl_Impl, void *, EMPTYARG ) else { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLSTYLE ), sal_True, &pPoolItem ) ) { if( ( XFILL_HATCH == (XFillStyle) ( ( const XFillStyleItem* ) pPoolItem )->GetValue() ) && - ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), TRUE, &pPoolItem ) ) ) + ( SFX_ITEM_SET == rOutAttrs.GetItemState( GetWhich( XATTR_FILLHATCH ), sal_True, &pPoolItem ) ) ) { pHatch = new XHatch( ( ( const XFillHatchItem* ) pPoolItem )->GetHatchValue() ); } @@ -428,7 +438,7 @@ IMPL_LINK( SvxHatchTabPage, ChangeHatchHdl_Impl, void *, EMPTYARG ) if( pHatch ) { aLbLineType.SelectEntryPos( - sal::static_int_cast< USHORT >( pHatch->GetHatchStyle() ) ); + sal::static_int_cast< sal_uInt16 >( pHatch->GetHatchStyle() ) ); // Wenn der Eintrag nicht in der Listbox ist, wird die Farbe // temporaer hinzugenommen aLbLineColor.SetNoSelection(); @@ -482,18 +492,18 @@ IMPL_LINK( SvxHatchTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) long nCount = pHatchingList->Count(); long j = 1; - BOOL bDifferent = FALSE; + sal_Bool bDifferent = sal_False; while( !bDifferent ) { aName = aNewName; aName += sal_Unicode(' '); aName += UniString::CreateFromInt32( j++ ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pHatchingList->GetHatch( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); @@ -501,17 +511,17 @@ IMPL_LINK( SvxHatchTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); WarningBox* pWarnBox = NULL; - USHORT nError = RID_SVXSTR_WARN_NAME_DUPLICATE; + sal_uInt16 nError = RID_SVXSTR_WARN_NAME_DUPLICATE; while( pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if( aName == pHatchingList->GetHatch( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; if( bDifferent ) { nError = 0; @@ -549,7 +559,7 @@ IMPL_LINK( SvxHatchTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) #ifdef WNT // hack: #31355# W.P. Rectangle aRect( aLbHatchings.GetPosPixel(), aLbHatchings.GetSizePixel() ); - if( TRUE ) { // ??? overlapped with pDlg + if( sal_True ) { // ??? overlapped with pDlg // and srolling Invalidate( aRect ); } @@ -575,7 +585,7 @@ IMPL_LINK( SvxHatchTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxHatchTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbHatchings.GetSelectEntryPos(); + sal_uInt16 nPos = aLbHatchings.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -591,23 +601,23 @@ IMPL_LINK( SvxHatchTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pDlg, "Dialogdiet fail!"); long nCount = pHatchingList->Count(); - BOOL bDifferent = FALSE; - BOOL bLoop = TRUE; + sal_Bool bDifferent = sal_False; + sal_Bool bLoop = sal_True; while( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pHatchingList->GetHatch( i )->GetName() && aName != aOldName ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; XHatch aXHatch( aLbLineColor.GetSelectEntryColor(), (XHatchStyle) aLbLineType.GetSelectEntryPos(), GetCoreValue( aMtrDistance, ePoolUnit ), @@ -647,7 +657,7 @@ IMPL_LINK( SvxHatchTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxHatchTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbHatchings.GetSelectEntryPos(); + sal_uInt16 nPos = aLbHatchings.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -683,7 +693,7 @@ IMPL_LINK( SvxHatchTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxHatchTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { ResMgr& rMgr = CUI_MGR(); - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; if ( *pnHatchingListState & CT_MODIFIED ) { diff --git a/cui/source/tabpages/tpline.cxx b/cui/source/tabpages/tpline.cxx index cfa9731a63c9..b2e10d6210a2 100644 --- a/cui/source/tabpages/tpline.cxx +++ b/cui/source/tabpages/tpline.cxx @@ -61,6 +61,7 @@ #include <svx/gallery.hxx> #include <svx/xbitmap.hxx> #include <unotools/localfilehelper.hxx> +#include "paragrph.hrc" #include "sfx2/opengrf.hxx" #include <svx/dialmgr.hxx> #include <svx/dialogs.hrc> @@ -77,7 +78,7 @@ // static ---------------------------------------------------------------- -static USHORT pLineRanges[] = +static sal_uInt16 pLineRanges[] = { XATTR_LINETRANSPARENCE, XATTR_LINETRANSPARENCE, @@ -98,6 +99,7 @@ SvxLineTabPage::SvxLineTabPage const SfxItemSet& rInAttrs ) : SvxTabPage ( pParent, CUI_RES( RID_SVXPAGE_LINE ), rInAttrs ), + aFlLine ( this, CUI_RES( FL_LINE ) ), aFtLineStyle ( this, CUI_RES( FT_LINE_STYLE ) ), aLbLineStyle ( this, CUI_RES( LB_LINE_STYLE ) ), aFtColor ( this, CUI_RES( FT_COLOR ) ), @@ -106,19 +108,18 @@ SvxLineTabPage::SvxLineTabPage aMtrLineWidth ( this, CUI_RES( MTR_FLD_LINE_WIDTH ) ), aFtTransparent ( this, CUI_RES( FT_TRANSPARENT ) ), aMtrTransparent ( this, CUI_RES( MTR_LINE_TRANSPARENT ) ), - aFlLine ( this, CUI_RES( FL_LINE ) ), - aFtLineEndsStyle ( this, CUI_RES( FT_LINE_ENDS_STYLE ) ), + aFlLineEnds ( this, CUI_RES( FL_LINE_ENDS ) ), aLbStartStyle ( this, CUI_RES( LB_START_STYLE ) ), - aFtLineEndsWidth ( this, CUI_RES( FT_LINE_ENDS_WIDTH ) ), aMtrStartWidth ( this, CUI_RES( MTR_FLD_START_WIDTH ) ), aTsbCenterStart ( this, CUI_RES( TSB_CENTER_START ) ), + aFtLineEndsStyle ( this, CUI_RES( FT_LINE_ENDS_STYLE ) ), aLbEndStyle ( this, CUI_RES( LB_END_STYLE ) ), + aFtLineEndsWidth ( this, CUI_RES( FT_LINE_ENDS_WIDTH ) ), aMtrEndWidth ( this, CUI_RES( MTR_FLD_END_WIDTH ) ), aTsbCenterEnd ( this, CUI_RES( TSB_CENTER_END ) ), aCbxSynchronize ( this, CUI_RES( CBX_SYNCHRONIZE ) ), - aFlLineEnds ( this, CUI_RES( FL_LINE_ENDS ) ), - aCtlPreview ( this, CUI_RES( CTL_PREVIEW ) ), aFLSeparator ( this, CUI_RES( FL_SEPARATOR ) ), + aCtlPreview ( this, CUI_RES( CTL_PREVIEW ) ), // #116827# maFLEdgeStyle ( this, CUI_RES( FL_EDGE_STYLE ) ), @@ -139,9 +140,9 @@ SvxLineTabPage::SvxLineTabPage aSymbolHeightMF ( this, CUI_RES(MF_SYMBOL_HEIGHT)), aSymbolRatioCB ( this, CUI_RES(CB_SYMBOL_RATIO)), - bLastWidthModified(FALSE), + bLastWidthModified(sal_False), aSymbolLastSize(Size(0,0)), - bSymbols(FALSE), + bSymbols(sal_False), rOutAttrs ( rInAttrs ), bObjSelected( sal_False ), @@ -158,8 +159,18 @@ SvxLineTabPage::SvxLineTabPage pnColorTableState( 0 ), nPageType ( 0 ) { + aLbEndStyle.SetAccessibleName(String(CUI_RES(STR_STYLE))); + aLbStartStyle.SetAccessibleName(String(CUI_RES( STR_LB_START_STYLE ) ) ); + aMtrStartWidth.SetAccessibleName(String(CUI_RES( STR_MTR_FLD_START_WIDTH ) ) ); + aLbEndStyle.SetAccessibleName(String(CUI_RES( STR_LB_END_STYLE ) ) ); + aMtrEndWidth.SetAccessibleName(String(CUI_RES( STR_MTR_FLD_END_WIDTH ) ) ); + aTsbCenterStart.SetAccessibleName(String(CUI_RES( STR_CENTER_START ) ) ); + aTsbCenterEnd.SetAccessibleName(String(CUI_RES( STR_CENTER_END ) ) ); + FreeResource(); + aCtlPreview.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + // diese Page braucht ExchangeSupport SetExchangeSupport(); @@ -227,14 +238,14 @@ SvxLineTabPage::SvxLineTabPage aSymbolHeightMF.SetModifyHdl(LINK(this, SvxLineTabPage, SizeHdl_Impl)); aSymbolRatioCB.SetClickHdl(LINK(this, SvxLineTabPage, RatioHdl_Impl)); - aSymbolRatioCB.Check(TRUE); - ShowSymbolControls(FALSE); + aSymbolRatioCB.Check(sal_True); + ShowSymbolControls(sal_False); // #63083# nActLineWidth = -1; } //#58425# Symbole auf einer Linie (z.B. StarChart) , Symbol-Controls aktivieren -void SvxLineTabPage::ShowSymbolControls(BOOL bOn) +void SvxLineTabPage::ShowSymbolControls(sal_Bool bOn) { bSymbols=bOn; aSymbolWidthFT.Show(bOn); @@ -279,7 +290,7 @@ void SvxLineTabPage::Construct() void SvxLineTabPage::FillListboxes() { // Linienstile - USHORT nOldSelect = aLbLineStyle.GetSelectEntryPos(); + sal_uInt16 nOldSelect = aLbLineStyle.GetSelectEntryPos(); aLbLineStyle.FillStyles(); aLbLineStyle.Fill( pDashList ); aLbLineStyle.SelectEntryPos( nOldSelect ); @@ -294,7 +305,7 @@ void SvxLineTabPage::FillListboxes() nOldSelect = aLbEndStyle.GetSelectEntryPos(); aLbEndStyle.Clear(); aLbEndStyle.InsertEntry( sNone ); - aLbEndStyle.Fill( pLineEndList, FALSE ); + aLbEndStyle.Fill( pLineEndList, sal_False ); aLbEndStyle.SelectEntryPos( nOldSelect ); } @@ -307,8 +318,8 @@ void SvxLineTabPage::ActivatePage( const SfxItemSet& rSet ) SetPageType(pPageTypeItem->GetValue()); if( nDlgType == 0 && pDashList ) { - USHORT nPos; - USHORT nCount; + sal_uInt16 nPos; + sal_uInt16 nCount; // Dashliste if( ( *pnDashListState & CT_MODIFIED ) || @@ -369,7 +380,7 @@ void SvxLineTabPage::ActivatePage( const SfxItemSet& rSet ) aLbEndStyle.Clear(); aLbEndStyle.InsertEntry( sNone ); - aLbEndStyle.Fill( pLineEndList, FALSE ); + aLbEndStyle.Fill( pLineEndList, sal_False ); nCount = aLbEndStyle.GetEntryCount(); if( nCount == 0 ) @@ -453,7 +464,7 @@ int SvxLineTabPage::DeactivatePage( SfxItemSet* _pSet ) { nPageType = 1; // evtl. fuer Erweiterungen *pPosDashLb = aLbLineStyle.GetSelectEntryPos() - 2;// erster Eintrag SOLID !!! - USHORT nPos = aLbStartStyle.GetSelectEntryPos(); + sal_uInt16 nPos = aLbStartStyle.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) nPos--; *pPosLineEndLb = nPos; @@ -467,11 +478,11 @@ int SvxLineTabPage::DeactivatePage( SfxItemSet* _pSet ) // ----------------------------------------------------------------------- -BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) +sal_Bool SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) { const SfxPoolItem* pOld = NULL; - USHORT nPos; - BOOL bModified = FALSE; + sal_uInt16 nPos; + sal_Bool bModified = sal_False; // Um evtl. Modifikationen der Liste vorzubeugen // werden Items anderer Seiten nicht gesetzt @@ -500,7 +511,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineDashItem*)pOld == aDashItem ) ) { rAttrs.Put( aDashItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -508,7 +519,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineStyleItem*)pOld == *pStyleItem ) ) { rAttrs.Put( *pStyleItem ); - bModified = TRUE; + bModified = sal_True; } delete pStyleItem; } @@ -522,7 +533,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineWidthItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } //Breite Linienanfang @@ -533,7 +544,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineStartWidthItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } //Breite Linienende @@ -544,7 +555,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineEndWidthItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -557,7 +568,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineColorItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -579,7 +590,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) ( !pOld || !( *(const XLineEndItem*)pOld == *pItem ) ) ) { rAttrs.Put( *pItem ); - bModified = TRUE; + bModified = sal_True; } delete pItem; } @@ -599,7 +610,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) ( !pOld || !( *(const XLineEndItem*)pOld == *pItem ) ) ) { rAttrs.Put( *pItem ); - bModified = TRUE; + bModified = sal_True; } delete pItem; } @@ -609,23 +620,23 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) TriState eState = aTsbCenterStart.GetState(); if( eState != aTsbCenterStart.GetSavedValue() ) { - XLineStartCenterItem aItem( sal::static_int_cast< BOOL >( eState ) ); + XLineStartCenterItem aItem( sal::static_int_cast< sal_Bool >( eState ) ); pOld = GetOldItem( rAttrs, XATTR_LINESTARTCENTER ); if ( !pOld || !( *(const XLineStartCenterItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } eState = aTsbCenterEnd.GetState(); if( eState != aTsbCenterEnd.GetSavedValue() ) { - XLineEndCenterItem aItem( sal::static_int_cast< BOOL >( eState ) ); + XLineEndCenterItem aItem( sal::static_int_cast< sal_Bool >( eState ) ); pOld = GetOldItem( rAttrs, XATTR_LINEENDCENTER ); if ( !pOld || !( *(const XLineEndCenterItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -637,7 +648,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineStartWidthItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } //Breite Linienende @@ -648,20 +659,20 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const XLineEndWidthItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } // Transparenz - UINT16 nVal = (UINT16)aMtrTransparent.GetValue(); - if( nVal != (UINT16)aMtrTransparent.GetSavedValue().ToInt32() ) + sal_uInt16 nVal = (sal_uInt16)aMtrTransparent.GetValue(); + if( nVal != (sal_uInt16)aMtrTransparent.GetSavedValue().ToInt32() ) { XLineTransparenceItem aItem( nVal ); pOld = GetOldItem( rAttrs, XATTR_LINETRANSPARENCE ); if ( !pOld || !( *(const XLineTransparenceItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } @@ -702,7 +713,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if(!pOld || !(*(const XLineJointItem*)pOld == *pNew)) { rAttrs.Put( *pNew ); - bModified = TRUE; + bModified = sal_True; } delete pNew; @@ -718,7 +729,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if(bNewSize) { rAttrs.Put(aSItem); - bModified=TRUE; + bModified=sal_True; } SfxInt32Item aTItem(rAttrs.GetPool()->GetWhich(SID_ATTR_SYMBOLTYPE),nSymbolType); @@ -729,7 +740,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if(bNewType) { rAttrs.Put(aTItem); - bModified=TRUE; + bModified=sal_True; } if(nSymbolType!=SVX_SYMBOLTYPE_NONE) @@ -741,7 +752,7 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) if(bNewBrush) { rAttrs.Put(aBItem); - bModified=TRUE; + bModified=sal_True; } } } @@ -751,9 +762,9 @@ BOOL SvxLineTabPage::FillItemSet( SfxItemSet& rAttrs ) // ----------------------------------------------------------------------- -BOOL SvxLineTabPage::FillXLSet_Impl() +sal_Bool SvxLineTabPage::FillXLSet_Impl() { - USHORT nPos; + sal_uInt16 nPos; if( aLbLineStyle.GetSelectEntryPos() == LISTBOX_ENTRY_NOTFOUND ) { @@ -832,23 +843,23 @@ BOOL SvxLineTabPage::FillXLSet_Impl() // Linienenden zentriert if( aTsbCenterStart.GetState() == STATE_CHECK ) - rXLSet.Put( XLineStartCenterItem( TRUE ) ); + rXLSet.Put( XLineStartCenterItem( sal_True ) ); else if( aTsbCenterStart.GetState() == STATE_NOCHECK ) - rXLSet.Put( XLineStartCenterItem( FALSE ) ); + rXLSet.Put( XLineStartCenterItem( sal_False ) ); if( aTsbCenterEnd.GetState() == STATE_CHECK ) - rXLSet.Put( XLineEndCenterItem( TRUE ) ); + rXLSet.Put( XLineEndCenterItem( sal_True ) ); else if( aTsbCenterEnd.GetState() == STATE_NOCHECK ) - rXLSet.Put( XLineEndCenterItem( FALSE ) ); + rXLSet.Put( XLineEndCenterItem( sal_False ) ); // Transparenz - UINT16 nVal = (UINT16)aMtrTransparent.GetValue(); + sal_uInt16 nVal = (sal_uInt16)aMtrTransparent.GetValue(); rXLSet.Put( XLineTransparenceItem( nVal ) ); // #116827# aCtlPreview.SetLineAttributes(aXLineAttr.GetItemSet()); - return( TRUE ); + return( sal_True ); } // ----------------------------------------------------------------------- @@ -861,11 +872,11 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) // Linienstil const SfxPoolItem *pPoolItem; long nSymType=SVX_SYMBOLTYPE_UNKNOWN; - BOOL bPrevSym=FALSE; - BOOL bEnable=TRUE; - BOOL bIgnoreGraphic=FALSE; - BOOL bIgnoreSize=FALSE; - if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_SYMBOLTYPE),TRUE,&pPoolItem) == SFX_ITEM_SET) + sal_Bool bPrevSym=sal_False; + sal_Bool bEnable=sal_True; + sal_Bool bIgnoreGraphic=sal_False; + sal_Bool bIgnoreSize=sal_False; + if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_SYMBOLTYPE),sal_True,&pPoolItem) == SFX_ITEM_SET) { nSymType=((const SfxInt32Item *)pPoolItem)->GetValue(); } @@ -874,13 +885,13 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) { aSymbolGraphic=aAutoSymbolGraphic; aSymbolSize=aSymbolLastSize=aAutoSymbolGraphic.GetPrefSize(); - bPrevSym=TRUE; + bPrevSym=sal_True; } else if(nSymType == SVX_SYMBOLTYPE_NONE) { - bEnable=FALSE; - bIgnoreGraphic=TRUE; - bIgnoreSize=TRUE; + bEnable=sal_False; + bIgnoreGraphic=sal_True; + bIgnoreSize=sal_True; } else if(nSymType >= 0) { @@ -889,7 +900,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) SdrModel* pModel = new SdrModel(NULL, NULL, LOADREFCOUNTS); pModel->GetItemPool().FreezeIdRanges(); - SdrPage* pPage = new SdrPage( *pModel, FALSE ); + SdrPage* pPage = new SdrPage( *pModel, sal_False ); pPage->SetSize(Size(1000,1000)); pModel->InsertPage( pPage, 0 ); SdrView* pView = new SdrView( pModel, &aVDev ); @@ -922,9 +933,9 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) aSymbolSize=pObj->GetSnapRect().GetSize(); aSymbolGraphic.SetPrefSize(aSymbolSize); aSymbolGraphic.SetPrefMapMode(MAP_100TH_MM); - bPrevSym=TRUE; - bEnable=TRUE; - bIgnoreGraphic=TRUE; + bPrevSym=sal_True; + bEnable=sal_True; + bIgnoreGraphic=sal_True; pView->UnmarkAll(); pObj=pPage->RemoveObject(0); @@ -935,7 +946,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) delete pView; delete pModel; } - if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_BRUSH),TRUE,&pPoolItem) == SFX_ITEM_SET) + if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_BRUSH),sal_True,&pPoolItem) == SFX_ITEM_SET) { const Graphic* pGraphic = ((const SvxBrushItem *)pPoolItem)->GetGraphic(); if( pGraphic ) @@ -950,10 +961,10 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) pGraphic->GetPrefMapMode(), MAP_100TH_MM ); } - bPrevSym=TRUE; + bPrevSym=sal_True; } } - if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_SYMBOLSIZE),TRUE,&pPoolItem) == SFX_ITEM_SET) + if(rAttrs.GetItemState(rAttrs.GetPool()->GetWhich(SID_ATTR_SYMBOLSIZE),sal_True,&pPoolItem) == SFX_ITEM_SET) { aSymbolSize = ((const SvxSizeItem *)pPoolItem)->GetSize(); } @@ -1032,7 +1043,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) else if( rAttrs.GetItemState( XATTR_LINESTART ) != SFX_ITEM_DONTCARE ) { // #86265# select entry using list and polygon, not string - sal_Bool bSelected(FALSE); + sal_Bool bSelected(sal_False); const basegfx::B2DPolyPolygon& rItemPolygon = ((const XLineStartItem&)rAttrs.Get(XATTR_LINESTART)).GetLineStartValue(); for(sal_Int32 a(0);!bSelected && a < pLineEndList->Count(); a++) @@ -1044,7 +1055,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) { // select this entry aLbStartStyle.SelectEntryPos((sal_uInt16)a + 1); - bSelected = TRUE; + bSelected = sal_True; } } @@ -1065,7 +1076,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) else if( rAttrs.GetItemState( XATTR_LINEEND ) != SFX_ITEM_DONTCARE ) { // #86265# select entry using list and polygon, not string - sal_Bool bSelected(FALSE); + sal_Bool bSelected(sal_False); const basegfx::B2DPolyPolygon& rItemPolygon = ((const XLineEndItem&)rAttrs.Get(XATTR_LINEEND)).GetLineEndValue(); for(sal_Int32 a(0);!bSelected && a < pLineEndList->Count(); a++) @@ -1077,7 +1088,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) { // select this entry aLbEndStyle.SelectEntryPos((sal_uInt16)a + 1); - bSelected = TRUE; + bSelected = sal_True; } } @@ -1125,7 +1136,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) } else if( rAttrs.GetItemState( XATTR_LINESTARTCENTER ) != SFX_ITEM_DONTCARE ) { - aTsbCenterStart.EnableTriState( FALSE ); + aTsbCenterStart.EnableTriState( sal_False ); if( ( ( const XLineStartCenterItem& ) rAttrs.Get( XATTR_LINESTARTCENTER ) ).GetValue() ) aTsbCenterStart.SetState( STATE_CHECK ); @@ -1145,7 +1156,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) } else if( rAttrs.GetItemState( XATTR_LINEENDCENTER ) != SFX_ITEM_DONTCARE ) { - aTsbCenterEnd.EnableTriState( FALSE ); + aTsbCenterEnd.EnableTriState( sal_False ); if( ( ( const XLineEndCenterItem& ) rAttrs.Get( XATTR_LINEENDCENTER ) ).GetValue() ) aTsbCenterEnd.SetState( STATE_CHECK ); @@ -1160,7 +1171,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) // Transparenz if( rAttrs.GetItemState( XATTR_LINETRANSPARENCE ) != SFX_ITEM_DONTCARE ) { - USHORT nTransp = ( ( const XLineTransparenceItem& ) rAttrs. + sal_uInt16 nTransp = ( ( const XLineTransparenceItem& ) rAttrs. Get( XATTR_LINETRANSPARENCE ) ).GetValue(); aMtrTransparent.SetValue( nTransp ); ChangeTransparentHdl_Impl( NULL ); @@ -1184,7 +1195,7 @@ void SvxLineTabPage::Reset( const SfxItemSet& rAttrs ) // Synchronisieren // Jetzt wird der Wert aus der INI-Datei geholt (#42258#) String aStr = GetUserData(); - aCbxSynchronize.Check( (BOOL)aStr.ToInt32() ); + aCbxSynchronize.Check( (sal_Bool)aStr.ToInt32() ); // #116827# if(bObjSelected && SFX_ITEM_DEFAULT == rAttrs.GetItemState(XATTR_LINEJOINT)) @@ -1240,7 +1251,7 @@ SfxTabPage* SvxLineTabPage::Create( Window* pWindow, //------------------------------------------------------------------------ -USHORT* SvxLineTabPage::GetRanges() +sal_uInt16* SvxLineTabPage::GetRanges() { return( pLineRanges ); } @@ -1252,12 +1263,12 @@ IMPL_LINK( SvxLineTabPage, ChangePreviewHdl_Impl, void *, pCntrl ) if(pCntrl == &aMtrLineWidth) { // Linienbreite und Start/EndBreite - INT32 nNewLineWidth = GetCoreValue( aMtrLineWidth, ePoolUnit ); + sal_Int32 nNewLineWidth = GetCoreValue( aMtrLineWidth, ePoolUnit ); if(nActLineWidth == -1) { // Noch nicht initialisiert, hole den Startwert const SfxPoolItem* pOld = GetOldItem( rXLSet, XATTR_LINEWIDTH ); - INT32 nStartLineWidth = 0; + sal_Int32 nStartLineWidth = 0; if(pOld) nStartLineWidth = (( const XLineWidthItem *)pOld)->GetValue(); nActLineWidth = nStartLineWidth; @@ -1266,8 +1277,8 @@ IMPL_LINK( SvxLineTabPage, ChangePreviewHdl_Impl, void *, pCntrl ) if(nActLineWidth != nNewLineWidth) { // Anpassungen Start/EndWidth #63083# - INT32 nValAct = GetCoreValue( aMtrStartWidth, ePoolUnit ); - INT32 nValNew = nValAct + (((nNewLineWidth - nActLineWidth) * 15) / 10); + sal_Int32 nValAct = GetCoreValue( aMtrStartWidth, ePoolUnit ); + sal_Int32 nValNew = nValAct + (((nNewLineWidth - nActLineWidth) * 15) / 10); if(nValNew < 0) nValNew = 0; SetMetricValue( aMtrStartWidth, nValNew, ePoolUnit ); @@ -1420,7 +1431,7 @@ IMPL_LINK( SvxLineTabPage, ChangeEndHdl_Impl, void *, p ) IMPL_LINK( SvxLineTabPage, ChangeTransparentHdl_Impl, void *, EMPTYARG ) { - UINT16 nVal = (UINT16)aMtrTransparent.GetValue(); + sal_uInt16 nVal = (sal_uInt16)aMtrTransparent.GetValue(); XLineTransparenceItem aItem( nVal ); rXLSet.Put( XLineTransparenceItem( aItem ) ); @@ -1480,7 +1491,7 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) SvxBmpItemInfo* pInfo = new SvxBmpItemInfo(); pInfo->pBrushItem = pBrushItem; - pInfo->nItemId = (UINT16)(MN_GALLERY_ENTRY + i); + pInfo->nItemId = (sal_uInt16)(MN_GALLERY_ENTRY + i); aGrfBrushItems.Insert(pInfo, i); const Graphic* pGraphic = pBrushItem->GetGraphic(); @@ -1491,7 +1502,7 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) if(aSize.Width() > MAX_BMP_WIDTH || aSize.Height() > MAX_BMP_HEIGHT) { - BOOL bWidth = aSize.Width() > aSize.Height(); + sal_Bool bWidth = aSize.Width() > aSize.Height(); double nScale = bWidth ? (double)MAX_BMP_WIDTH / (double)aSize.Width(): (double)MAX_BMP_HEIGHT / (double)aSize.Height(); @@ -1509,7 +1520,7 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) } aSymbolMB.GetPopupMenu()->SetPopupMenu( MN_GALLERY, pPopup ); if(!aGrfNames.Count()) - aSymbolMB.GetPopupMenu()->EnableItem(MN_GALLERY, FALSE); + aSymbolMB.GetPopupMenu()->EnableItem(MN_GALLERY, sal_False); } if(!pButton->GetPopupMenu()->GetPopupMenu( MN_SYMBOLS ) && pSymbolList) @@ -1519,7 +1530,7 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) SdrModel* pModel = new SdrModel(NULL, NULL, LOADREFCOUNTS); pModel->GetItemPool().FreezeIdRanges(); // Page - SdrPage* pPage = new SdrPage( *pModel, FALSE ); + SdrPage* pPage = new SdrPage( *pModel, sal_False ); pPage->SetSize(Size(1000,1000)); pModel->InsertPage( pPage, 0 ); // 3D View @@ -1559,13 +1570,13 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) SvxBmpItemInfo* pInfo = new SvxBmpItemInfo(); pInfo->pBrushItem = pBrushItem; - pInfo->nItemId = (UINT16)(MN_GALLERY_ENTRY + i + nNumMenuGalleryItems); + pInfo->nItemId = (sal_uInt16)(MN_GALLERY_ENTRY + i + nNumMenuGalleryItems); aGrfBrushItems.Insert(pInfo, nNumMenuGalleryItems + i); Size aSize(aBitmap.GetSizePixel()); if(aSize.Width() > MAX_BMP_WIDTH || aSize.Height() > MAX_BMP_HEIGHT) { - BOOL bWidth = aSize.Width() > aSize.Height(); + sal_Bool bWidth = aSize.Width() > aSize.Height(); double nScale = bWidth ? (double)MAX_BMP_WIDTH / (double)aSize.Width(): (double)MAX_BMP_HEIGHT / (double)aSize.Height(); @@ -1576,7 +1587,7 @@ IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton ) } aSymbolMB.GetPopupMenu()->SetPopupMenu( MN_SYMBOLS, pPopup ); if(!aGrfNames.Count()) - aSymbolMB.GetPopupMenu()->EnableItem(MN_SYMBOLS, FALSE); + aSymbolMB.GetPopupMenu()->EnableItem(MN_SYMBOLS, sal_False); delete pView; delete pModel; @@ -1591,7 +1602,7 @@ IMPL_STATIC_LINK(SvxLineTabPage, GraphicArrivedHdl_Impl, SvxBrushItem*, pItem) PopupMenu* pPopup = pThis->aSymbolMB.GetPopupMenu()->GetPopupMenu( MN_GALLERY ); SvxBmpItemInfo* pBmpInfo = 0; - for ( USHORT i = 0; i < pThis->aGrfBrushItems.Count(); i++ ) + for ( sal_uInt16 i = 0; i < pThis->aGrfBrushItems.Count(); i++ ) { SvxBmpItemInfo* pInfo = (SvxBmpItemInfo*)pThis->aGrfBrushItems.GetObject(i); if( pInfo->pBrushItem == pItem ) @@ -1608,7 +1619,7 @@ IMPL_STATIC_LINK(SvxLineTabPage, GraphicArrivedHdl_Impl, SvxBrushItem*, pItem) if(aSize.Width() > MAX_BMP_WIDTH || aSize.Height() > MAX_BMP_HEIGHT) { - BOOL bWidth = aSize.Width() > aSize.Height(); + sal_Bool bWidth = aSize.Width() > aSize.Height(); double nScale = bWidth ? (double)MAX_BMP_WIDTH / (double)aSize.Width(): (double)MAX_BMP_HEIGHT / (double)aSize.Height(); @@ -1626,12 +1637,12 @@ IMPL_STATIC_LINK(SvxLineTabPage, GraphicArrivedHdl_Impl, SvxBrushItem*, pItem) //Handler f�r Menuebutton IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { - USHORT nItemId = pButton->GetCurItemId(); + sal_uInt16 nItemId = pButton->GetCurItemId(); const Graphic* pGraphic = 0; Graphic aGraphic; String aGrfName; - BOOL bResetSize = FALSE; - BOOL bEnable=TRUE; + sal_Bool bResetSize = sal_False; + sal_Bool bEnable=sal_True; long nPreviousSymbolType = nSymbolType; if(nItemId >= MN_GALLERY_ENTRY) @@ -1643,7 +1654,7 @@ IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) else { nSymbolType=SVX_SYMBOLTYPE_BRUSHITEM; - bResetSize = TRUE; + bResetSize = sal_True; } SvxBmpItemInfo* pInfo = (SvxBmpItemInfo*)aGrfBrushItems.GetObject(nItemId - MN_GALLERY_ENTRY); pGraphic = pInfo->pBrushItem->GetGraphic(); @@ -1662,7 +1673,7 @@ IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { nSymbolType=SVX_SYMBOLTYPE_NONE; pGraphic=NULL; - bEnable=FALSE; + bEnable=sal_False; } break; default: @@ -1678,7 +1689,7 @@ IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { nSymbolType=SVX_SYMBOLTYPE_BRUSHITEM; pGraphic = &aGraphic; - bResetSize = TRUE; + bResetSize = sal_True; } } if( !pGraphic ) @@ -1711,7 +1722,7 @@ IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) { aSymbolGraphic=Graphic(); aCtlPreview.SetSymbol(NULL,aSymbolSize); - bEnable=FALSE; + bEnable=sal_False; } aSymbolLastSize=aSymbolSize; SetMetricValue(aSymbolWidthMF, aSymbolSize.Width(), ePoolUnit); @@ -1728,9 +1739,9 @@ IMPL_LINK( SvxLineTabPage, GraphicHdl_Impl, MenuButton *, pButton ) IMPL_LINK( SvxLineTabPage, SizeHdl_Impl, MetricField *, pField) { bNewSize=true; - BOOL bWidth = (BOOL)(pField == &aSymbolWidthMF); + sal_Bool bWidth = (sal_Bool)(pField == &aSymbolWidthMF); bLastWidthModified = bWidth; - BOOL bRatio = aSymbolRatioCB.IsChecked(); + sal_Bool bRatio = aSymbolRatioCB.IsChecked(); long nWidthVal = static_cast<long>(aSymbolWidthMF.Denormalize(aSymbolWidthMF.GetValue(FUNIT_100TH_MM))); long nHeightVal= static_cast<long>(aSymbolHeightMF.Denormalize(aSymbolHeightMF.GetValue(FUNIT_100TH_MM))); nWidthVal = OutputDevice::LogicToLogic(nWidthVal,MAP_100TH_MM,(MapUnit)ePoolUnit ); @@ -1821,7 +1832,7 @@ void SvxLineTabPage::PageCreated (SfxAllItemSet aSet) if(pSdrObjListItem) //symbols { - ShowSymbolControls(TRUE); + ShowSymbolControls(sal_True); pSymbolList = static_cast<SdrObjList*>(pSdrObjListItem->GetValue()); if (pSymbolAttrItem) pSymbolAttr = new SfxItemSet(pSymbolAttrItem->GetItemSet()); diff --git a/cui/source/tabpages/tplnedef.cxx b/cui/source/tabpages/tplnedef.cxx index 4dd53f46a7ed..41f7085c2934 100644 --- a/cui/source/tabpages/tplnedef.cxx +++ b/cui/source/tabpages/tplnedef.cxx @@ -106,6 +106,13 @@ SvxLineDefTabPage::SvxLineDefTabPage aXLineAttr ( pXPool ), rXLSet ( aXLineAttr.GetItemSet() ) { + aLbType1.SetAccessibleName(String(CUI_RES( STR_START_TYPE ) ) ); + aLbType2.SetAccessibleName(String(CUI_RES( STR_END_TYPE ) ) ); + aNumFldNumber1.SetAccessibleName(String(CUI_RES( STR_START_NUM ) ) ); + aNumFldNumber2.SetAccessibleName(String(CUI_RES( STR_END_NUM ) ) ); + aMtrLength1.SetAccessibleName(String(CUI_RES( STR_START_LENGTH ) ) ); + aMtrLength2.SetAccessibleName(String(CUI_RES( STR_END_LENGTH ) ) ); + FreeResource(); // diese Page braucht ExchangeSupport @@ -168,6 +175,12 @@ SvxLineDefTabPage::SvxLineDefTabPage aMtrDistance.SetModifyHdl( aLink ); pDashList = NULL; + + aBtnAdd.SetAccessibleRelationMemberOf( &aFlDefinition ); + aBtnModify.SetAccessibleRelationMemberOf( &aFlDefinition ); + aBtnDelete.SetAccessibleRelationMemberOf( &aFlDefinition ); + aBtnLoad.SetAccessibleRelationMemberOf( &aFlDefinition ); + aBtnSave.SetAccessibleRelationMemberOf( &aFlDefinition ); } @@ -275,7 +288,7 @@ void SvxLineDefTabPage::CheckChanges_Impl() - USHORT nPos = aLbLineStyles.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineStyles.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { *pPosDashLb = nPos; @@ -284,7 +297,7 @@ void SvxLineDefTabPage::CheckChanges_Impl() // ----------------------------------------------------------------------- -BOOL SvxLineDefTabPage::FillItemSet( SfxItemSet& rAttrs ) +sal_Bool SvxLineDefTabPage::FillItemSet( SfxItemSet& rAttrs ) { if( *pDlgType == 0 ) // Linien-Dialog { @@ -297,7 +310,7 @@ BOOL SvxLineDefTabPage::FillItemSet( SfxItemSet& rAttrs ) rAttrs.Put( XLineDashItem( aString, aDash ) ); } } - return( TRUE ); + return( sal_True ); } // ----------------------------------------------------------------------- @@ -554,40 +567,40 @@ IMPL_LINK( SvxLineDefTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) long nCount = pDashList->Count(); long j = 1; - BOOL bDifferent = FALSE; + sal_Bool bDifferent = sal_False; while ( !bDifferent ) { aName = aNewName; aName += sal_Unicode(' '); aName += UniString::CreateFromInt32( j++ ); - bDifferent = TRUE; + bDifferent = sal_True; for ( long i = 0; i < nCount && bDifferent; i++ ) if ( aName == pDashList->GetDash( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); DBG_ASSERT(pFact, "Dialogdiet fail!"); AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); - BOOL bLoop = TRUE; + sal_Bool bLoop = sal_True; while ( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pDashList->GetDash( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; FillDash_Impl(); pEntry = new XDashEntry( aDash, aName ); @@ -636,7 +649,7 @@ IMPL_LINK( SvxLineDefTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxLineDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbLineStyles.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineStyles.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -652,24 +665,24 @@ IMPL_LINK( SvxLineDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pDlg, "Dialogdiet fail!"); long nCount = pDashList->Count(); - BOOL bDifferent = FALSE; - BOOL bLoop = TRUE; + sal_Bool bDifferent = sal_False; + sal_Bool bLoop = sal_True; while ( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pDashList->GetDash( i )->GetName() && aName != aOldName ) - bDifferent = FALSE; + bDifferent = sal_False; } if ( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; FillDash_Impl(); XDashEntry* pEntry = new XDashEntry( aDash, aName ); @@ -710,7 +723,7 @@ IMPL_LINK( SvxLineDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxLineDefTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbLineStyles.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineStyles.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -748,7 +761,7 @@ IMPL_LINK( SvxLineDefTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxLineDefTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { ResMgr& rMgr = CUI_MGR(); - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; if ( *pnDashListState & CT_MODIFIED ) { @@ -885,10 +898,10 @@ void SvxLineDefTabPage::FillDash_Impl() eXDS = XDASH_RECT; aDash.SetDashStyle( eXDS ); - aDash.SetDots( (BYTE) aNumFldNumber1.GetValue() ); + aDash.SetDots( (sal_uInt8) aNumFldNumber1.GetValue() ); aDash.SetDotLen( aLbType1.GetSelectEntryPos() == 0 ? 0 : GetCoreValue( aMtrLength1, ePoolUnit ) ); - aDash.SetDashes( (BYTE) aNumFldNumber2.GetValue() ); + aDash.SetDashes( (sal_uInt8) aNumFldNumber2.GetValue() ); aDash.SetDashLen( aLbType2.GetSelectEntryPos() == 0 ? 0 : GetCoreValue( aMtrLength2, ePoolUnit ) ); aDash.SetDistance( GetCoreValue( aMtrDistance, ePoolUnit ) ); @@ -907,7 +920,7 @@ void SvxLineDefTabPage::FillDialog_Impl() if( eXDS == XDASH_RECTRELATIVE ) aCbxSynchronize.Check(); else - aCbxSynchronize.Check( FALSE ); + aCbxSynchronize.Check( sal_False ); aNumFldNumber1.SetValue( aDash.GetDots() ); SetMetricValue( aMtrLength1, aDash.GetDotLen(), ePoolUnit ); @@ -936,7 +949,7 @@ void SvxLineDefTabPage::DataChanged( const DataChangedEvent& rDCEvt ) if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) ) { - USHORT nOldSelect = aLbLineStyles.GetSelectEntryPos(); + sal_uInt16 nOldSelect = aLbLineStyles.GetSelectEntryPos(); aLbLineStyles.Clear(); aLbLineStyles.Fill( pDashList ); aLbLineStyles.SelectEntryPos( nOldSelect ); diff --git a/cui/source/tabpages/tplneend.cxx b/cui/source/tabpages/tplneend.cxx index b770136bbf7c..30b94a0759ad 100644 --- a/cui/source/tabpages/tplneend.cxx +++ b/cui/source/tabpages/tplneend.cxx @@ -130,6 +130,9 @@ SvxLineEndDefTabPage::SvxLineEndDefTabPage aLbLineEnds.SetSelectHdl( LINK( this, SvxLineEndDefTabPage, SelectLineEndHdl_Impl ) ); + aBtnAdd.SetAccessibleRelationMemberOf(&aFlTip); + aBtnModify.SetAccessibleRelationMemberOf(&aFlTip); + aBtnDelete.SetAccessibleRelationMemberOf(&aFlTip); } //------------------------------------------------------------------------ @@ -156,7 +159,7 @@ void SvxLineEndDefTabPage::Construct() pPolyObj->TakeObjInfo( aInfoRec ); SdrObject* pNewObj = 0; if( aInfoRec.bCanConvToPath ) - pNewObj = pPolyObj->ConvertToPolyObj( TRUE, FALSE ); + pNewObj = pPolyObj->ConvertToPolyObj( sal_True, sal_False ); bCreateArrowPossible = pNewObj && pNewObj->ISA( SdrPathObj ); SdrObject::Free( pNewObj ); @@ -206,7 +209,7 @@ int SvxLineEndDefTabPage::DeactivatePage( SfxItemSet* _pSet ) void SvxLineEndDefTabPage::CheckChanges_Impl() { - USHORT nPos = aLbLineEnds.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineEnds.GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -229,7 +232,7 @@ void SvxLineEndDefTabPage::CheckChanges_Impl() // ----------------------------------------------------------------------- -BOOL SvxLineEndDefTabPage::FillItemSet( SfxItemSet& rSet ) +sal_Bool SvxLineEndDefTabPage::FillItemSet( SfxItemSet& rSet ) { if( *pDlgType == 0 ) // Linien-Dialog { @@ -244,7 +247,7 @@ BOOL SvxLineEndDefTabPage::FillItemSet( SfxItemSet& rSet ) rSet.Put( XLineEndItem( pEntry->GetName(), pEntry->GetLineEnd() ) ); } } - return( TRUE ); + return( sal_True ); } // ----------------------------------------------------------------------- @@ -333,7 +336,7 @@ long SvxLineEndDefTabPage::ChangePreviewHdl_Impl( void* ) IMPL_LINK( SvxLineEndDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbLineEnds.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineEnds.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -341,12 +344,12 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) String aDesc( ResId( RID_SVXSTR_DESC_LINEEND, rMgr ) ); String aName( aEdtName.GetText() ); long nCount = pLineEndList->Count(); - BOOL bDifferent = TRUE; + sal_Bool bDifferent = sal_True; // Pruefen, ob Name schon vorhanden ist for ( long i = 0; i < nCount && bDifferent; i++ ) if ( aName == pLineEndList->GetLineEnd( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; // Wenn ja, wird wiederholt ein neuer Name angefordert if ( !bDifferent ) @@ -360,21 +363,21 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickModifyHdl_Impl, void *, EMPTYARG ) DBG_ASSERT(pFact, "Dialogdiet fail!"); AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); - BOOL bLoop = TRUE; + sal_Bool bLoop = sal_True; while( !bDifferent && bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pLineEndList->GetLineEnd( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) - bLoop = FALSE; + bLoop = sal_False; else aWarningBox.Execute(); } @@ -421,7 +424,7 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) if( aInfoRec.bCanConvToPath ) { - pNewObj = pConvPolyObj = pPolyObj->ConvertToPolyObj( TRUE, FALSE ); + pNewObj = pConvPolyObj = pPolyObj->ConvertToPolyObj( sal_True, sal_False ); if( !pNewObj || !pNewObj->ISA( SdrPathObj ) ) return( 0L ); // Abbruch, zusaetzliche Sicherheit, die bei @@ -449,40 +452,40 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) long nCount = pLineEndList->Count(); long j = 1; - BOOL bDifferent = FALSE; + sal_Bool bDifferent = sal_False; while ( !bDifferent ) { aName = aNewName; aName += sal_Unicode(' '); aName += UniString::CreateFromInt32( j++ ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) if ( aName == pLineEndList->GetLineEnd( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); DBG_ASSERT(pFact, "Dialogdiet fail!"); AbstractSvxNameDialog* pDlg = pFact->CreateSvxNameDialog( DLGWIN, aName, aDesc ); DBG_ASSERT(pDlg, "Dialogdiet fail!"); - BOOL bLoop = TRUE; + sal_Bool bLoop = sal_True; while ( bLoop && pDlg->Execute() == RET_OK ) { pDlg->GetName( aName ); - bDifferent = TRUE; + bDifferent = sal_True; for( long i = 0; i < nCount && bDifferent; i++ ) { if( aName == pLineEndList->GetLineEnd( i )->GetName() ) - bDifferent = FALSE; + bDifferent = sal_False; } if( bDifferent ) { - bLoop = FALSE; + bLoop = sal_False; pEntry = new XLineEndEntry( aNewPolyPolygon, aName ); long nLineEndCount = pLineEndList->Count(); @@ -524,7 +527,7 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickAddHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxLineEndDefTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) { - USHORT nPos = aLbLineEnds.GetSelectEntryPos(); + sal_uInt16 nPos = aLbLineEnds.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { @@ -561,7 +564,7 @@ IMPL_LINK( SvxLineEndDefTabPage, ClickDeleteHdl_Impl, void *, EMPTYARG ) IMPL_LINK( SvxLineEndDefTabPage, ClickLoadHdl_Impl, void *, EMPTYARG ) { ResMgr& rMgr = CUI_MGR(); - USHORT nReturn = RET_YES; + sal_uInt16 nReturn = RET_YES; if ( *pnLineEndListState & CT_MODIFIED ) { @@ -688,7 +691,7 @@ void SvxLineEndDefTabPage::DataChanged( const DataChangedEvent& rDCEvt ) if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) ) { - USHORT nOldSelect = aLbLineEnds.GetSelectEntryPos(); + sal_uInt16 nOldSelect = aLbLineEnds.GetSelectEntryPos(); aLbLineEnds.Clear(); aLbLineEnds.Fill( pLineEndList ); aLbLineEnds.SelectEntryPos( nOldSelect ); diff --git a/cui/source/tabpages/tpshadow.cxx b/cui/source/tabpages/tpshadow.cxx index 54a4aa473587..a7109fadb3b3 100644 --- a/cui/source/tabpages/tpshadow.cxx +++ b/cui/source/tabpages/tpshadow.cxx @@ -44,7 +44,7 @@ #include <dialmgr.hxx> #include "svx/dlgutil.hxx" #include <cuitabline.hxx> - +#include "paragrph.hrc" #include <svx/xlineit0.hxx> #include <sfx2/request.hxx> @@ -52,7 +52,7 @@ // static ---------------------------------------------------------------- -static USHORT pShadowRanges[] = +static sal_uInt16 pShadowRanges[] = { SDRATTR_SHADOWCOLOR, SDRATTR_SHADOWTRANSPARENCE, @@ -84,7 +84,7 @@ SvxShadowTabPage::SvxShadowTabPage( Window* pParent, const SfxItemSet& rInAttrs aCtlXRectPreview ( this, CUI_RES( CTL_COLOR_PREVIEW ) ), rOutAttrs ( rInAttrs ), pColorTab( NULL ), - bDisable ( FALSE ), + bDisable ( sal_False ), pXPool ( (XOutdevItemPool*) rInAttrs.GetPool() ), aXFillAttr ( pXPool ), rXFSet ( aXFillAttr.GetItemSet() ) @@ -186,6 +186,8 @@ SvxShadowTabPage::SvxShadowTabPage( Window* pParent, const SfxItemSet& rInAttrs aMtrTransparent.SetModifyHdl( aLink ); aMtrDistance.SetModifyHdl( aLink ); + aCtlXRectPreview.SetAccessibleName(String(CUI_RES(STR_EXAMPLE))); + aCtlPosition.SetAccessibleRelationMemberOf( &aFlProp ); } // ----------------------------------------------------------------------- @@ -213,8 +215,8 @@ void SvxShadowTabPage::Construct() void SvxShadowTabPage::ActivatePage( const SfxItemSet& rSet ) { - USHORT nPos; - USHORT nCount; + sal_uInt16 nPos; + sal_uInt16 nCount; SFX_ITEMSET_ARG (&rSet,pPageTypeItem,SfxUInt16Item,SID_PAGE_TYPE,sal_False); if (pPageTypeItem) @@ -274,10 +276,10 @@ int SvxShadowTabPage::DeactivatePage( SfxItemSet* _pSet ) // ----------------------------------------------------------------------- -BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) +sal_Bool SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) { const SfxPoolItem* pOld = NULL; - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if( !bDisable ) { @@ -285,20 +287,20 @@ BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) TriState eState = aTsbShowShadow.GetState(); if( eState != aTsbShowShadow.GetSavedValue() ) { - SdrShadowItem aItem( sal::static_int_cast< BOOL >( eState ) ); + SdrShadowItem aItem( sal::static_int_cast< sal_Bool >( eState ) ); pOld = GetOldItem( rAttrs, SDRATTR_SHADOW ); if ( !pOld || !( *(const SdrShadowItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } // Schatten-Entfernung // Etwas umstaendliche Abfrage, ob etwas geaendert wurde, // da Items nicht direkt auf Controls abbildbar sind - INT32 nX = 0L, nY = 0L; - INT32 nXY = GetCoreValue( aMtrDistance, ePoolUnit ); + sal_Int32 nX = 0L, nY = 0L; + sal_Int32 nXY = GetCoreValue( aMtrDistance, ePoolUnit ); switch( aCtlPosition.GetActualRP() ) { @@ -321,8 +323,8 @@ BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) rOutAttrs.GetItemState( SDRATTR_SHADOWXDIST ) != SFX_ITEM_DONTCARE || rOutAttrs.GetItemState( SDRATTR_SHADOWYDIST ) != SFX_ITEM_DONTCARE ) { - INT32 nOldX = 9876543; // Unmoeglicher Wert, entspr. DontCare - INT32 nOldY = 9876543; + sal_Int32 nOldX = 9876543; // Unmoeglicher Wert, entspr. DontCare + sal_Int32 nOldY = 9876543; if( rOutAttrs.GetItemState( SDRATTR_SHADOWXDIST ) != SFX_ITEM_DONTCARE && rOutAttrs.GetItemState( SDRATTR_SHADOWYDIST ) != SFX_ITEM_DONTCARE ) { @@ -337,7 +339,7 @@ BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) ( !pOld || !( *(const SdrShadowXDistItem*)pOld == aXItem ) ) ) { rAttrs.Put( aXItem ); - bModified = TRUE; + bModified = sal_True; } SdrShadowYDistItem aYItem( nY ); pOld = GetOldItem( rAttrs, SDRATTR_SHADOWYDIST ); @@ -345,12 +347,12 @@ BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) ( !pOld || !( *(const SdrShadowYDistItem*)pOld == aYItem ) ) ) { rAttrs.Put( aYItem ); - bModified = TRUE; + bModified = sal_True; } } // ShadowColor - USHORT nPos = aLbShadowColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbShadowColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND && nPos != aLbShadowColor.GetSavedValue() ) { @@ -360,20 +362,20 @@ BOOL SvxShadowTabPage::FillItemSet( SfxItemSet& rAttrs ) if ( !pOld || !( *(const SdrShadowColorItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } // Transparenz - UINT16 nVal = (UINT16)aMtrTransparent.GetValue(); - if( nVal != (UINT16)aMtrTransparent.GetSavedValue().ToInt32() ) + sal_uInt16 nVal = (sal_uInt16)aMtrTransparent.GetValue(); + if( nVal != (sal_uInt16)aMtrTransparent.GetSavedValue().ToInt32() ) { SdrShadowTransparenceItem aItem( nVal ); pOld = GetOldItem( rAttrs, SDRATTR_SHADOWTRANSPARENCE ); if ( !pOld || !( *(const SdrShadowTransparenceItem*)pOld == aItem ) ) { rAttrs.Put( aItem ); - bModified = TRUE; + bModified = sal_True; } } } @@ -395,7 +397,7 @@ void SvxShadowTabPage::Reset( const SfxItemSet& rAttrs ) // Ist Schatten gesetzt? if( rAttrs.GetItemState( SDRATTR_SHADOW ) != SFX_ITEM_DONTCARE ) { - aTsbShowShadow.EnableTriState( FALSE ); + aTsbShowShadow.EnableTriState( sal_False ); if( ( ( const SdrShadowItem& ) rAttrs.Get( SDRATTR_SHADOW ) ).GetValue() ) aTsbShowShadow.SetState( STATE_CHECK ); @@ -413,8 +415,8 @@ void SvxShadowTabPage::Reset( const SfxItemSet& rAttrs ) if( rAttrs.GetItemState( SDRATTR_SHADOWXDIST ) != SFX_ITEM_DONTCARE && rAttrs.GetItemState( SDRATTR_SHADOWYDIST ) != SFX_ITEM_DONTCARE ) { - INT32 nX = ( ( const SdrShadowXDistItem& ) rAttrs.Get( SDRATTR_SHADOWXDIST ) ).GetValue(); - INT32 nY = ( ( const SdrShadowYDistItem& ) rAttrs.Get( SDRATTR_SHADOWYDIST ) ).GetValue(); + sal_Int32 nX = ( ( const SdrShadowXDistItem& ) rAttrs.Get( SDRATTR_SHADOWXDIST ) ).GetValue(); + sal_Int32 nY = ( ( const SdrShadowYDistItem& ) rAttrs.Get( SDRATTR_SHADOWYDIST ) ).GetValue(); if( nX != 0 ) SetMetricValue( aMtrDistance, nX < 0L ? -nX : nX, ePoolUnit ); @@ -441,8 +443,8 @@ void SvxShadowTabPage::Reset( const SfxItemSet& rAttrs ) SdrShadowYDistItem* pYDistItem = (SdrShadowYDistItem*)&pPool->GetDefaultItem (SDRATTR_SHADOWYDIST); if (pXDistItem && pYDistItem) { - INT32 nX = pXDistItem->GetValue(); - INT32 nY = pYDistItem->GetValue(); + sal_Int32 nX = pXDistItem->GetValue(); + sal_Int32 nY = pYDistItem->GetValue(); if( nX != 0 ) SetMetricValue( aMtrDistance, nX < 0L ? -nX : nX, ePoolUnit ); else @@ -467,7 +469,7 @@ void SvxShadowTabPage::Reset( const SfxItemSet& rAttrs ) // Transparenz if( rAttrs.GetItemState( SDRATTR_SHADOWTRANSPARENCE ) != SFX_ITEM_DONTCARE ) { - USHORT nTransp = ( ( const SdrShadowTransparenceItem& ) rAttrs.Get( SDRATTR_SHADOWTRANSPARENCE ) ).GetValue(); + sal_uInt16 nTransp = ( ( const SdrShadowTransparenceItem& ) rAttrs.Get( SDRATTR_SHADOWTRANSPARENCE ) ).GetValue(); aMtrTransparent.SetValue( nTransp ); } else @@ -499,7 +501,7 @@ SfxTabPage* SvxShadowTabPage::Create( Window* pWindow, //------------------------------------------------------------------------ -USHORT* SvxShadowTabPage::GetRanges() +sal_uInt16* SvxShadowTabPage::GetRanges() { return( pShadowRanges ); } @@ -546,19 +548,19 @@ IMPL_LINK( SvxShadowTabPage, ModifyShadowHdl_Impl, void *, EMPTYARG ) else rXFSet.Put( XFillStyleItem( XFILL_NONE ) ); - USHORT nPos = aLbShadowColor.GetSelectEntryPos(); + sal_uInt16 nPos = aLbShadowColor.GetSelectEntryPos(); if( nPos != LISTBOX_ENTRY_NOTFOUND ) { rXFSet.Put( XFillColorItem( String(), aLbShadowColor.GetSelectEntryColor() ) ); } - UINT16 nVal = (UINT16)aMtrTransparent.GetValue(); + sal_uInt16 nVal = (sal_uInt16)aMtrTransparent.GetValue(); XFillTransparenceItem aItem( nVal ); rXFSet.Put( XFillTransparenceItem( aItem ) ); // Schatten-Entfernung - INT32 nX = 0L, nY = 0L; - INT32 nXY = GetCoreValue( aMtrDistance, ePoolUnit ); + sal_Int32 nX = 0L, nY = 0L; + sal_Int32 nXY = GetCoreValue( aMtrDistance, ePoolUnit ); switch( aCtlPosition.GetActualRP() ) { case RP_LT: nX = nY = -nXY; break; diff --git a/cui/source/tabpages/transfrm.cxx b/cui/source/tabpages/transfrm.cxx index acd806a1790a..3b75b322b828 100644 --- a/cui/source/tabpages/transfrm.cxx +++ b/cui/source/tabpages/transfrm.cxx @@ -55,7 +55,7 @@ // static ---------------------------------------------------------------- -static USHORT pPosSizeRanges[] = +static sal_uInt16 pPosSizeRanges[] = { SID_ATTR_TRANSFORM_POS_X, SID_ATTR_TRANSFORM_POS_Y, @@ -74,7 +74,7 @@ static USHORT pPosSizeRanges[] = 0 }; -static USHORT pAngleRanges[] = +static sal_uInt16 pAngleRanges[] = { SID_ATTR_TRANSFORM_ROT_X, SID_ATTR_TRANSFORM_ANGLE, @@ -83,7 +83,7 @@ static USHORT pAngleRanges[] = 0 }; -static USHORT pSlantRanges[] = +static sal_uInt16 pSlantRanges[] = { SDRATTR_ECKENRADIUS, SDRATTR_ECKENRADIUS, @@ -119,7 +119,7 @@ void lcl_ScaleRect(basegfx::B2DRange& rRange, const Fraction aUIScale) \************************************************************************/ SvxTransformTabDialog::SvxTransformTabDialog( Window* pParent, const SfxItemSet* pAttr, - const SdrView* pSdrView, USHORT nAnchorTypes ) : + const SdrView* pSdrView, sal_uInt16 nAnchorTypes ) : SfxTabDialog( pParent, CUI_RES( RID_SVXDLG_TRANSFORM ), pAttr ), pView ( pSdrView ), nAnchorCtrls(nAnchorTypes) @@ -151,7 +151,7 @@ SvxTransformTabDialog::~SvxTransformTabDialog() // ----------------------------------------------------------------------- -void SvxTransformTabDialog::PageCreated(USHORT nId, SfxTabPage &rPage) +void SvxTransformTabDialog::PageCreated(sal_uInt16 nId, SfxTabPage &rPage) { switch(nId) { @@ -247,6 +247,11 @@ SvxAngleTabPage::SvxAngleTabPage( Window* pParent, const SfxItemSet& rInAttrs ) ePoolUnit = pPool->GetMetric(SID_ATTR_TRANSFORM_POS_X); aMtrAngle.SetModifyHdl(LINK( this, SvxAngleTabPage, ModifiedHdl)); + + aCtlRect.SetAccessibleRelationLabeledBy(&aFtPosPresets); + aCtlRect.SetAccessibleRelationMemberOf(&aFlPosition); + aCtlAngle.SetAccessibleRelationLabeledBy(&aFtAnglePresets); + aCtlAngle.SetAccessibleRelationMemberOf(&aFlAngle); } // ----------------------------------------------------------------------- @@ -255,8 +260,8 @@ void SvxAngleTabPage::Construct() { DBG_ASSERT(pView, "No valid view (!)"); eDlgUnit = GetModuleFieldUnit(GetItemSet()); - SetFieldUnit(aMtrPosX, eDlgUnit, TRUE); - SetFieldUnit(aMtrPosY, eDlgUnit, TRUE); + SetFieldUnit(aMtrPosX, eDlgUnit, sal_True); + SetFieldUnit(aMtrPosY, eDlgUnit, sal_True); if(FUNIT_MILE == eDlgUnit || FUNIT_KM == eDlgUnit) { @@ -311,9 +316,9 @@ void SvxAngleTabPage::Construct() // ----------------------------------------------------------------------- -BOOL SvxAngleTabPage::FillItemSet(SfxItemSet& rSet) +sal_Bool SvxAngleTabPage::FillItemSet(SfxItemSet& rSet) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if(aMtrAngle.IsValueModified() || aMtrPosX.IsValueModified() || aMtrPosY.IsValueModified()) { @@ -325,7 +330,7 @@ BOOL SvxAngleTabPage::FillItemSet(SfxItemSet& rSet) rSet.Put(SfxInt32Item(GetWhich(SID_ATTR_TRANSFORM_ROT_X), basegfx::fround(fTmpX))); rSet.Put(SfxInt32Item(GetWhich(SID_ATTR_TRANSFORM_ROT_Y), basegfx::fround(fTmpY))); - bModified |= TRUE; + bModified |= sal_True; } return bModified; @@ -382,7 +387,7 @@ SfxTabPage* SvxAngleTabPage::Create( Window* pWindow, const SfxItemSet& rSet) //------------------------------------------------------------------------ -USHORT* SvxAngleTabPage::GetRanges() +sal_uInt16* SvxAngleTabPage::GetRanges() { return(pAngleRanges); } @@ -541,7 +546,7 @@ void SvxSlantTabPage::Construct() // get the range DBG_ASSERT(pView, "no valid view (!)"); eDlgUnit = GetModuleFieldUnit(GetItemSet()); - SetFieldUnit(aMtrRadius, eDlgUnit, TRUE); + SetFieldUnit(aMtrRadius, eDlgUnit, sal_True); { // #i75273# Rectangle aTempRect(pView->GetAllMarkedRect()); @@ -552,9 +557,9 @@ void SvxSlantTabPage::Construct() // ----------------------------------------------------------------------- -BOOL SvxSlantTabPage::FillItemSet(SfxItemSet& rAttrs) +sal_Bool SvxSlantTabPage::FillItemSet(SfxItemSet& rAttrs) { - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; String aStr = aMtrRadius.GetText(); if( aStr != aMtrRadius.GetSavedValue() ) @@ -564,16 +569,16 @@ BOOL SvxSlantTabPage::FillItemSet(SfxItemSet& rAttrs) nTmp = Fraction( nTmp ) * aUIScale; rAttrs.Put( SdrEckenradiusItem( nTmp ) ); - bModified = TRUE; + bModified = sal_True; } aStr = aMtrAngle.GetText(); if( aStr != aMtrAngle.GetSavedValue() ) { - INT32 nValue = static_cast<INT32>(aMtrAngle.GetValue()); + sal_Int32 nValue = static_cast<sal_Int32>(aMtrAngle.GetValue()); rAttrs.Put( SfxInt32Item( SID_ATTR_TRANSFORM_SHEAR, nValue ) ); - bModified = TRUE; + bModified = sal_True; } if( bModified ) @@ -586,7 +591,7 @@ BOOL SvxSlantTabPage::FillItemSet(SfxItemSet& rAttrs) rAttrs.Put(SfxInt32Item(SID_ATTR_TRANSFORM_SHEAR_X, aPt.X())); rAttrs.Put(SfxInt32Item(SID_ATTR_TRANSFORM_SHEAR_Y, aPt.Y())); - rAttrs.Put( SfxBoolItem( SID_ATTR_TRANSFORM_SHEAR_VERTICAL, FALSE ) ); + rAttrs.Put( SfxBoolItem( SID_ATTR_TRANSFORM_SHEAR_VERTICAL, sal_False ) ); } return( bModified ); @@ -659,7 +664,7 @@ SfxTabPage* SvxSlantTabPage::Create( Window* pWindow, const SfxItemSet& rOutAttr //------------------------------------------------------------------------ -USHORT* SvxSlantTabPage::GetRanges() +sal_uInt16* SvxSlantTabPage::GetRanges() { return( pSlantRanges ); } @@ -670,7 +675,7 @@ void SvxSlantTabPage::ActivatePage( const SfxItemSet& rSet ) { SfxRectangleItem* pRectItem = NULL; - if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , FALSE, (const SfxPoolItem**) &pRectItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , sal_False, (const SfxPoolItem**) &pRectItem ) ) { const Rectangle aTempRect(pRectItem->GetValue()); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); @@ -733,7 +738,7 @@ SvxPositionSizeTabPage::SvxPositionSizeTabPage( Window* pParent, const SfxItemSe mrOutAttrs ( rInAttrs ), mnProtectSizeState( STATE_NOCHECK ), - mbPageDisabled ( FALSE ), + mbPageDisabled ( sal_False ), mbProtectDisabled( false ), mbSizeDisabled( false ), mbAdjustDisabled( true ) @@ -762,6 +767,10 @@ SvxPositionSizeTabPage::SvxPositionSizeTabPage( Window* pParent, const SfxItemSe maTsbPosProtect.SetClickHdl( LINK( this, SvxPositionSizeTabPage, ChangePosProtectHdl ) ); maTsbSizeProtect.SetClickHdl( LINK( this, SvxPositionSizeTabPage, ChangeSizeProtectHdl ) ); + maCtlPos.SetAccessibleRelationMemberOf( &maFlPosition ); + maCtlSize.SetAccessibleRelationMemberOf( &maFlSize ); + maCtlPos.SetAccessibleRelationLabeledBy( &maFtPosReference ); + maCtlSize.SetAccessibleRelationLabeledBy( &maFtSizeReference ); } // ----------------------------------------------------------------------- @@ -771,10 +780,10 @@ void SvxPositionSizeTabPage::Construct() // get range and work area DBG_ASSERT( mpView, "no valid view (!)" ); meDlgUnit = GetModuleFieldUnit( GetItemSet() ); - SetFieldUnit( maMtrPosX, meDlgUnit, TRUE ); - SetFieldUnit( maMtrPosY, meDlgUnit, TRUE ); - SetFieldUnit( maMtrWidth, meDlgUnit, TRUE ); - SetFieldUnit( maMtrHeight, meDlgUnit, TRUE ); + SetFieldUnit( maMtrPosX, meDlgUnit, sal_True ); + SetFieldUnit( maMtrPosY, meDlgUnit, sal_True ); + SetFieldUnit( maMtrWidth, meDlgUnit, sal_True ); + SetFieldUnit( maMtrHeight, meDlgUnit, sal_True ); if(FUNIT_MILE == meDlgUnit || FUNIT_KM == meDlgUnit) { @@ -815,7 +824,7 @@ void SvxPositionSizeTabPage::Construct() // diferent anchor positions maMtrPosX.SetText( String() ); maMtrPosY.SetText( String() ); - mbPageDisabled = TRUE; + mbPageDisabled = sal_True; return; } } @@ -842,8 +851,8 @@ void SvxPositionSizeTabPage::Construct() maTsbAutoGrowHeight.SetClickHdl( LINK( this, SvxPositionSizeTabPage, ClickSizeProtectHdl ) ); // is used as flag to evaluate if its selectable - maTsbAutoGrowWidth.EnableTriState( FALSE ); - maTsbAutoGrowHeight.EnableTriState( FALSE ); + maTsbAutoGrowWidth.EnableTriState( sal_False ); + maTsbAutoGrowHeight.EnableTriState( sal_False ); } } @@ -862,9 +871,9 @@ void SvxPositionSizeTabPage::Construct() // ----------------------------------------------------------------------- -BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) +sal_Bool SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) { - BOOL bModified(FALSE); + sal_Bool bModified(sal_False); if ( maMtrWidth.HasFocus() ) { @@ -896,7 +905,7 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) rOutAttrs.Put(SfxInt32Item(GetWhich(SID_ATTR_TRANSFORM_POS_X), basegfx::fround(fX))); rOutAttrs.Put(SfxInt32Item(GetWhich(SID_ATTR_TRANSFORM_POS_Y), basegfx::fround(fY))); - bModified |= TRUE; + bModified |= sal_True; } if ( maTsbPosProtect.GetState() != maTsbPosProtect.GetSavedValue() ) @@ -909,10 +918,10 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) { rOutAttrs.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_PROTECT_POS ), - maTsbPosProtect.GetState() == STATE_CHECK ? TRUE : FALSE ) ); + maTsbPosProtect.GetState() == STATE_CHECK ? sal_True : sal_False ) ); } - bModified |= TRUE; + bModified |= sal_True; } } @@ -936,11 +945,11 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) // put Width & Height to itemset rOutAttrs.Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_WIDTH ), - (UINT32) lWidth ) ); + (sal_uInt32) lWidth ) ); rOutAttrs.Put( SfxUInt32Item( GetWhich( SID_ATTR_TRANSFORM_HEIGHT ), - (UINT32) lHeight ) ); - rOutAttrs.Put( SfxAllEnumItem( GetWhich( SID_ATTR_TRANSFORM_SIZE_POINT ), sal::static_int_cast< USHORT >( meRP ) ) ); - bModified |= TRUE; + (sal_uInt32) lHeight ) ); + rOutAttrs.Put( SfxAllEnumItem( GetWhich( SID_ATTR_TRANSFORM_SIZE_POINT ), sal::static_int_cast< sal_uInt16 >( meRP ) ) ); + bModified |= sal_True; } if ( maTsbSizeProtect.GetState() != maTsbSizeProtect.GetSavedValue() ) @@ -950,8 +959,8 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) else rOutAttrs.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_PROTECT_SIZE ), - maTsbSizeProtect.GetState() == STATE_CHECK ? TRUE : FALSE ) ); - bModified |= TRUE; + maTsbSizeProtect.GetState() == STATE_CHECK ? sal_True : sal_False ) ); + bModified |= sal_True; } if ( maTsbAutoGrowWidth.GetState() != maTsbAutoGrowWidth.GetSavedValue() ) @@ -963,9 +972,9 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) else rOutAttrs.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_AUTOWIDTH ), - maTsbAutoGrowWidth.GetState() == STATE_CHECK ? TRUE : FALSE ) ); + maTsbAutoGrowWidth.GetState() == STATE_CHECK ? sal_True : sal_False ) ); } - bModified |= TRUE; + bModified |= sal_True; } if ( maTsbAutoGrowHeight.GetState() != maTsbAutoGrowHeight.GetSavedValue() ) @@ -977,9 +986,9 @@ BOOL SvxPositionSizeTabPage::FillItemSet( SfxItemSet& rOutAttrs ) else rOutAttrs.Put( SfxBoolItem( GetWhich( SID_ATTR_TRANSFORM_AUTOHEIGHT ), - maTsbAutoGrowHeight.GetState() == STATE_CHECK ? TRUE : FALSE ) ); + maTsbAutoGrowHeight.GetState() == STATE_CHECK ? sal_True : sal_False ) ); } - bModified |= TRUE; + bModified |= sal_True; } @@ -1014,7 +1023,7 @@ void SvxPositionSizeTabPage::Reset( const SfxItemSet& ) { sal_Bool bProtected = ( ( const SfxBoolItem* )pItem )->GetValue(); maTsbPosProtect.SetState( bProtected ? STATE_CHECK : STATE_NOCHECK ); - maTsbPosProtect.EnableTriState( FALSE ); + maTsbPosProtect.EnableTriState( sal_False ); } else { @@ -1057,7 +1066,7 @@ void SvxPositionSizeTabPage::Reset( const SfxItemSet& ) { maTsbSizeProtect.SetState( ( (const SfxBoolItem*)pItem )->GetValue() ? STATE_CHECK : STATE_NOCHECK ); - maTsbSizeProtect.EnableTriState( FALSE ); + maTsbSizeProtect.EnableTriState( sal_False ); } else maTsbSizeProtect.SetState( STATE_DONTKNOW ); @@ -1082,7 +1091,7 @@ void SvxPositionSizeTabPage::Reset( const SfxItemSet& ) // Ist Abgleich gesetzt? String aStr = GetUserData(); - maCbxScale.Check( (BOOL)aStr.ToInt32() ); + maCbxScale.Check( (sal_Bool)aStr.ToInt32() ); maTsbSizeProtect.SaveValue(); maTsbAutoGrowWidth.SaveValue(); @@ -1102,7 +1111,7 @@ SfxTabPage* SvxPositionSizeTabPage::Create( Window* pWindow, const SfxItemSet& r //------------------------------------------------------------------------ -USHORT* SvxPositionSizeTabPage::GetRanges() +sal_uInt16* SvxPositionSizeTabPage::GetRanges() { return( pPosSizeRanges ); } @@ -1113,7 +1122,7 @@ void SvxPositionSizeTabPage::ActivatePage( const SfxItemSet& rSet ) { SfxRectangleItem* pRectItem = NULL; - if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , FALSE, (const SfxPoolItem**) &pRectItem ) ) + if( SFX_ITEM_SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , sal_False, (const SfxPoolItem**) &pRectItem ) ) { { // #i75273# const Rectangle aTempRect(pRectItem->GetValue()); diff --git a/cui/source/tabpages/transfrm.src b/cui/source/tabpages/transfrm.src index 761fdcfb2349..c753402f0440 100644 --- a/cui/source/tabpages/transfrm.src +++ b/cui/source/tabpages/transfrm.src @@ -61,6 +61,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; MetricField MTR_FLD_POS_X { + HelpID = "cui:MetricField:RID_SVXPAGE_POSITION_SIZE:MTR_FLD_POS_X"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 14 + 8 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -76,6 +77,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; MetricField MTR_FLD_POS_Y { + HelpID = "cui:MetricField:RID_SVXPAGE_POSITION_SIZE:MTR_FLD_POS_Y"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 30 + 8 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -127,6 +129,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; MetricField MTR_FLD_WIDTH { + HelpID = "cui:MetricField:RID_SVXPAGE_POSITION_SIZE:MTR_FLD_WIDTH"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 14 + 61 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -142,6 +145,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; MetricField MTR_FLD_HEIGHT { + HelpID = "cui:MetricField:RID_SVXPAGE_POSITION_SIZE:MTR_FLD_HEIGHT"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 30 + 61 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -172,6 +176,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; CheckBox CBX_SCALE { + HelpID = "cui:CheckBox:RID_SVXPAGE_POSITION_SIZE:CBX_SCALE"; Pos = MAP_APPFONT ( 12 , 47 + 61 ) ; Size = MAP_APPFONT ( 162 , 10 ) ; TabStop = TRUE ; @@ -189,6 +194,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE TriStateBox TSB_POSPROTECT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_POSITION_SIZE:TSB_POSPROTECT"; Pos = MAP_APPFONT ( 12 , 10 + 120 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; Text [ en-US ] = "Position" ; @@ -197,6 +203,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE TriStateBox TSB_SIZEPROTECT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_POSITION_SIZE:TSB_SIZEPROTECT"; Pos = MAP_APPFONT ( 12 , 24 + 120 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; Text [ en-US ] = "~Size" ; @@ -213,6 +220,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; TriStateBox TSB_AUTOGROW_WIDTH { + HelpID = "cui:TriStateBox:RID_SVXPAGE_POSITION_SIZE:TSB_AUTOGROW_WIDTH"; Pos = MAP_APPFONT ( 12 + 121 + 8, 10 + 120 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; Text [ en-US ] = "~Fit width to text" ; @@ -220,6 +228,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; TriStateBox TSB_AUTOGROW_HEIGHT { + HelpID = "cui:TriStateBox:RID_SVXPAGE_POSITION_SIZE:TSB_AUTOGROW_HEIGHT"; Pos = MAP_APPFONT ( 12 + 121 + 8, 24 + 120 ) ; Size = MAP_APPFONT ( 113 , 10 ) ; Text [ en-US ] = "Fit ~height to text" ; @@ -251,6 +260,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; ListBox LB_ANCHOR { + HelpID = "cui:ListBox:RID_SVXPAGE_POSITION_SIZE:LB_ANCHOR"; Pos = MAP_APPFONT ( 46 + 121 + 16 , 8 + 120 ) ; Size = MAP_APPFONT ( 54 , 60 ) ; Hide = TRUE ; @@ -272,6 +282,7 @@ TabPage RID_SVXPAGE_POSITION_SIZE }; ListBox LB_ORIENT { + HelpID = "cui:ListBox:RID_SVXPAGE_POSITION_SIZE:LB_ORIENT"; Pos = MAP_APPFONT ( 46 + 121 + 16 , 22 + 120 ); Size = MAP_APPFONT ( 54 , 60 ) ; Hide = TRUE ; @@ -319,6 +330,7 @@ TabPage RID_SVXPAGE_ANGLE }; MetricField MTR_FLD_POS_X { + HelpID = "cui:MetricField:RID_SVXPAGE_ANGLE:MTR_FLD_POS_X"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 14 + 11 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -334,6 +346,7 @@ TabPage RID_SVXPAGE_ANGLE }; MetricField MTR_FLD_POS_Y { + HelpID = "cui:MetricField:RID_SVXPAGE_ANGLE:MTR_FLD_POS_Y"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 30 + 11 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -376,6 +389,7 @@ TabPage RID_SVXPAGE_ANGLE }; MetricField MTR_FLD_ANGLE { + HelpID = "cui:MetricField:RID_SVXPAGE_ANGLE:MTR_FLD_ANGLE"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 82 + 22 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -427,6 +441,7 @@ TabPage RID_SVXPAGE_SLANT }; MetricField MTR_FLD_RADIUS { + HelpID = "cui:MetricField:RID_SVXPAGE_SLANT:MTR_FLD_RADIUS"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 14 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; @@ -454,6 +469,7 @@ TabPage RID_SVXPAGE_SLANT }; MetricField MTR_FLD_ANGLE { + HelpID = "cui:MetricField:RID_SVXPAGE_SLANT:MTR_FLD_ANGLE"; Border = TRUE ; Pos = MAP_APPFONT ( 56 , 46 ) ; Size = MAP_APPFONT ( 54 , 12 ) ; |