[Libreoffice-commits] core.git: 66 commits - accessibility/source avmedia/source basctl/source basic/qa basic/source bridges/source canvas/source comphelper/source compilerplugins/clang connectivity/source cppcanvas/source cppuhelper/source cppu/source cui/source dbaccess/source desktop/source editeng/source extensions/source filter/source forms/source formula/source fpicker/source framework/source hwpfilter/source i18npool/source idlc/source idl/source include/basic include/comphelper include/connectivity include/cppu include/cppuhelper include/osl include/sfx2 include/svl include/svx include/tools include/vcl io/source javaunohelper/source jvmfwk/plugins jvmfwk/source l10ntools/source lingucomponent/source linguistic/source lotuswordpro/source oox/source opencl/inc opencl/source pyuno/source registry/source rsc/source sal/osl sal/qa sal/rtl sal/textenc sax/source scaddins/source sc/inc sc/source sdext/source sd/inc sd/source sfx2/source shell/source sot/qa sot/source starmath/inc starmath/sourc e stoc/source store/source svl/source svtools/qa svtools/source svx/source sw/inc sw/source toolkit/source tools/source ucb/source unotools/source unoxml/source uui/source vcl/generic vcl/headless vcl/opengl vcl/source vcl/unx xmlhelp/source xmloff/source xmlscript/source xmlsecurity/source
Stephan Bergmann
sbergman at redhat.com
Sat Mar 28 11:10:14 PDT 2015
accessibility/source/extended/accessibletabbarpagelist.cxx | 2
accessibility/source/standard/vclxaccessiblebox.cxx | 2
accessibility/source/standard/vclxaccessibletoolbox.cxx | 4
avmedia/source/opengl/oglwindow.cxx | 10
basctl/source/basicide/basicbox.cxx | 4
basctl/source/basicide/baside2b.cxx | 2
basctl/source/basicide/basobj3.cxx | 2
basctl/source/basicide/moduldl2.cxx | 4
basctl/source/basicide/moduldlg.cxx | 2
basctl/source/dlged/managelang.cxx | 6
basic/qa/cppunit/basictest.hxx | 2
basic/source/basmgr/basmgr.cxx | 2
basic/source/classes/propacc.cxx | 12
basic/source/classes/sbunoobj.cxx | 18
basic/source/runtime/ddectrl.cxx | 2
basic/source/runtime/iosys.cxx | 2
basic/source/runtime/runtime.cxx | 8
bridges/source/cpp_uno/gcc3_linux_x86-64/callvirtualmethod.cxx | 4
bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx | 6
bridges/source/cpp_uno/gcc3_linux_x86-64/except.cxx | 2
bridges/source/cpp_uno/gcc3_linux_x86-64/rtti.cxx | 2
bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx | 8
bridges/source/jni_uno/jni_base.h | 2
bridges/source/jni_uno/jni_bridge.cxx | 8
bridges/source/jni_uno/jni_data.cxx | 252 +++++-----
bridges/source/jni_uno/jni_java2uno.cxx | 8
bridges/source/jni_uno/jni_uno2java.cxx | 20
canvas/source/cairo/cairo_canvashelper.cxx | 2
canvas/source/cairo/cairo_textlayout.cxx | 2
comphelper/source/container/container.cxx | 4
comphelper/source/eventattachermgr/eventattachermgr.cxx | 18
comphelper/source/misc/syntaxhighlight.cxx | 2
comphelper/source/misc/types.cxx | 4
compilerplugins/clang/cstylecast.cxx | 11
compilerplugins/clang/redundantcast.cxx | 5
connectivity/source/commontools/FValue.cxx | 72 +-
connectivity/source/commontools/dbtools.cxx | 50 -
connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx | 2
connectivity/source/drivers/evoab2/NResultSet.cxx | 8
connectivity/source/drivers/firebird/PreparedStatement.cxx | 4
connectivity/source/drivers/firebird/StatementCommonBase.cxx | 4
connectivity/source/drivers/firebird/Util.cxx | 26 -
connectivity/source/drivers/odbc/OPreparedStatement.cxx | 2
connectivity/source/drivers/odbc/OTools.cxx | 36 -
connectivity/source/drivers/postgresql/pq_tools.cxx | 24
cppcanvas/source/mtfrenderer/emfplus.cxx | 6
cppu/source/LogBridge/LogBridge.cxx | 2
cppu/source/helper/purpenv/helper_purpenv_Proxy.cxx | 2
cppu/source/typelib/typelib.cxx | 2
cppu/source/uno/assign.hxx | 108 ++--
cppu/source/uno/constr.hxx | 34 -
cppu/source/uno/copy.hxx | 126 ++---
cppu/source/uno/data.cxx | 8
cppu/source/uno/destr.hxx | 32 -
cppu/source/uno/eq.hxx | 248 ++++-----
cppu/source/uno/lbenv.cxx | 20
cppu/source/uno/lbmap.cxx | 2
cppu/source/uno/prim.hxx | 4
cppu/source/uno/sequence.cxx | 38 -
cppuhelper/source/implbase_ex.cxx | 2
cppuhelper/source/interfacecontainer.cxx | 56 +-
cppuhelper/source/macro_expander.cxx | 2
cppuhelper/source/propshlp.cxx | 24
cppuhelper/source/tdmgr.cxx | 20
cui/source/customize/acccfg.cxx | 28 -
cui/source/customize/cfg.cxx | 56 +-
cui/source/customize/cfgutil.cxx | 16
cui/source/customize/eventdlg.cxx | 6
cui/source/customize/macropg.cxx | 2
cui/source/customize/selector.cxx | 10
cui/source/dialogs/hangulhanjadlg.cxx | 2
cui/source/dialogs/hldocntp.cxx | 12
cui/source/dialogs/hlmarkwn.cxx | 8
cui/source/dialogs/iconcdlg.cxx | 6
cui/source/dialogs/linkdlg.cxx | 14
cui/source/dialogs/multipat.cxx | 12
cui/source/dialogs/scriptdlg.cxx | 16
cui/source/inc/cfg.hxx | 4
cui/source/options/optasian.cxx | 2
cui/source/options/optgdlg.cxx | 2
cui/source/options/optjava.cxx | 2
cui/source/options/optopencl.cxx | 8
cui/source/options/optpath.cxx | 16
cui/source/options/treeopt.cxx | 40 -
cui/source/tabpages/autocdlg.cxx | 12
cui/source/tabpages/chardlg.cxx | 4
cui/source/tabpages/swpossizetabpage.cxx | 16
dbaccess/source/ui/browser/exsrcbrw.cxx | 4
dbaccess/source/ui/browser/formadapter.cxx | 4
desktop/source/app/officeipcthread.cxx | 6
desktop/source/lib/init.cxx | 4
desktop/source/offacc/acceptor.cxx | 2
editeng/source/items/xmlcnitm.cxx | 4
editeng/source/misc/acorrcfg.cxx | 94 +--
editeng/source/uno/unoipset.cxx | 20
extensions/source/bibliography/bibconfig.cxx | 2
extensions/source/bibliography/bibload.cxx | 8
extensions/source/bibliography/datman.cxx | 12
extensions/source/bibliography/general.cxx | 2
extensions/source/bibliography/toolbar.cxx | 8
extensions/source/plugin/base/nfuncs.cxx | 8
extensions/source/plugin/base/xplugin.cxx | 4
extensions/source/plugin/inc/plugin/unx/plugcon.hxx | 2
extensions/source/plugin/unx/npnapi.cxx | 54 +-
extensions/source/plugin/unx/nppapi.cxx | 24
extensions/source/plugin/unx/plugcon.cxx | 2
extensions/source/propctrlr/propertyeditor.cxx | 2
extensions/source/propctrlr/selectlabeldialog.cxx | 4
extensions/source/propctrlr/taborder.cxx | 2
extensions/source/update/ui/updatecheckui.cxx | 2
filter/source/graphicfilter/icgm/actimpr.cxx | 6
filter/source/graphicfilter/icgm/cgm.cxx | 4
filter/source/graphicfilter/ieps/ieps.cxx | 4
filter/source/graphicfilter/ipcd/ipcd.cxx | 16
filter/source/msfilter/escherex.cxx | 140 ++---
filter/source/msfilter/eschesdo.cxx | 20
filter/source/msfilter/eschesdo.hxx | 2
filter/source/msfilter/msdffimp.cxx | 2
filter/source/msfilter/svdfppt.cxx | 6
filter/source/pdf/impdialog.cxx | 2
filter/source/svg/svgwriter.cxx | 2
filter/source/xsltdialog/xmlfiltersettingsdialog.cxx | 12
filter/source/xsltfilter/OleHandler.cxx | 2
forms/source/component/Button.cxx | 2
forms/source/component/DatabaseForm.cxx | 2
forms/source/component/FormattedField.cxx | 2
forms/source/component/ListBox.cxx | 4
forms/source/component/RadioButton.cxx | 4
forms/source/xforms/xpathlib/xpathlib.cxx | 6
formula/source/ui/dlg/funcpage.cxx | 2
formula/source/ui/dlg/structpg.cxx | 4
fpicker/source/office/iodlg.cxx | 2
framework/source/dispatch/windowcommanddispatch.cxx | 4
framework/source/fwe/classes/imagewrapper.cxx | 6
framework/source/fwi/helper/networkdomain.cxx | 2
framework/source/fwi/uielement/constitemcontainer.cxx | 10
framework/source/recording/dispatchrecorder.cxx | 8
framework/source/uielement/addonstoolbarmanager.cxx | 4
hwpfilter/source/formula.cxx | 4
hwpfilter/source/grammar.cxx | 4
hwpfilter/source/hbox.cxx | 2
hwpfilter/source/hcode.cxx | 2
hwpfilter/source/hgzip.cxx | 8
hwpfilter/source/hiodev.cxx | 8
hwpfilter/source/hstream.cxx | 2
hwpfilter/source/hstyle.cxx | 2
hwpfilter/source/hwpreader.cxx | 14
hwpfilter/source/lexer.cxx | 14
hwpfilter/source/mzstring.cxx | 4
i18npool/source/breakiterator/breakiterator_ctl.cxx | 4
i18npool/source/breakiterator/breakiterator_th.cxx | 4
i18npool/source/indexentry/indexentrysupplier_default.cxx | 2
i18npool/source/textconversion/genconv_dict.cxx | 2
idl/source/prj/globals.cxx | 6
idlc/source/aststack.cxx | 4
idlc/source/idlccompile.cxx | 2
include/basic/basrdll.hxx | 2
include/comphelper/extract.hxx | 2
include/connectivity/FValue.hxx | 2
include/cppu/Enterable.hxx | 10
include/cppuhelper/proptypehlp.hxx | 38 -
include/osl/thread.hxx | 2
include/sfx2/msg.hxx | 6
include/svl/poolitem.hxx | 2
include/svx/svdetc.hxx | 2
include/tools/debug.hxx | 2
include/tools/link.hxx | 6
include/vcl/cmdevt.hxx | 20
include/vcl/event.hxx | 8
include/vcl/opengl/OpenGLContext.hxx | 2
io/source/stm/opump.cxx | 4
io/source/stm/streamhelper.cxx | 2
javaunohelper/source/bootstrap.cxx | 4
javaunohelper/source/javaunohelper.cxx | 4
jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx | 4
jvmfwk/source/elements.cxx | 10
jvmfwk/source/framework.cxx | 6
l10ntools/source/xmlparse.cxx | 10
lingucomponent/source/languageguessing/simpleguesser.cxx | 4
linguistic/source/gciterator.cxx | 2
lotuswordpro/source/filter/benval.cxx | 2
lotuswordpro/source/filter/lwptools.cxx | 4
oox/source/core/xmlfilterbase.cxx | 2
oox/source/export/drawingml.cxx | 34 -
opencl/inc/opencl_device_selection.h | 14
opencl/source/opencl_device.cxx | 28 -
opencl/source/openclwrapper.cxx | 2
pyuno/source/loader/pyuno_loader.cxx | 2
pyuno/source/module/pyuno.cxx | 38 -
pyuno/source/module/pyuno_adapter.cxx | 2
pyuno/source/module/pyuno_runtime.cxx | 10
pyuno/source/module/pyuno_type.cxx | 4
registry/source/keyimpl.cxx | 54 +-
registry/source/reflread.cxx | 70 +-
registry/source/reflwrit.cxx | 6
registry/source/regimpl.cxx | 30 -
registry/source/registry.cxx | 24
registry/source/regkey.cxx | 8
rsc/source/parser/rsckey.cxx | 12
rsc/source/parser/rscpar.cxx | 6
rsc/source/parser/rscyacc.y | 2
rsc/source/prj/start.cxx | 48 -
rsc/source/res/rscarray.cxx | 2
rsc/source/res/rscclass.cxx | 10
rsc/source/res/rscconst.cxx | 10
rsc/source/res/rsccont.cxx | 14
rsc/source/res/rscflag.cxx | 2
rsc/source/res/rscmgr.cxx | 2
rsc/source/res/rscrange.cxx | 6
rsc/source/res/rscstr.cxx | 6
rsc/source/rsc/rsc.cxx | 2
rsc/source/tools/rscchar.cxx | 2
rsc/source/tools/rsctools.cxx | 12
rsc/source/tools/rsctree.cxx | 6
sal/osl/unx/conditn.cxx | 12
sal/osl/unx/file_misc.cxx | 6
sal/osl/unx/file_stat.cxx | 4
sal/osl/unx/file_volume.cxx | 6
sal/osl/unx/mutex.cxx | 2
sal/osl/unx/pipe.cxx | 10
sal/osl/unx/process.cxx | 32 -
sal/osl/unx/process_impl.cxx | 2
sal/osl/unx/profile.cxx | 56 +-
sal/osl/unx/security.cxx | 8
sal/osl/unx/signal.cxx | 2
sal/osl/unx/socket.cxx | 26 -
sal/osl/unx/thread.cxx | 32 -
sal/qa/osl/file/osl_File.cxx | 16
sal/qa/osl/module/osl_Module.cxx | 6
sal/qa/osl/process/osl_Thread.cxx | 14
sal/qa/rtl/alloc/rtl_alloc.cxx | 6
sal/rtl/alloc_arena.cxx | 12
sal/rtl/alloc_cache.cxx | 20
sal/rtl/alloc_global.cxx | 8
sal/rtl/byteseq.cxx | 14
sal/rtl/cipher.cxx | 36 -
sal/rtl/cmdargs.cxx | 2
sal/rtl/crc.cxx | 2
sal/rtl/digest.cxx | 64 +-
sal/rtl/hash.cxx | 4
sal/rtl/locale.cxx | 8
sal/rtl/random.cxx | 12
sal/rtl/strtmpl.cxx | 6
sal/textenc/convertbig5hkscs.cxx | 4
sal/textenc/converteuctw.cxx | 4
sal/textenc/convertgb18030.cxx | 4
sal/textenc/convertsimple.cxx | 4
sal/textenc/tcvtbyte.cxx | 2
sal/textenc/tcvtmb.cxx | 8
sal/textenc/tcvtutf7.cxx | 8
sal/textenc/textcvt.cxx | 16
sax/source/expatwrap/sax_expat.cxx | 22
sax/source/tools/fastattribs.cxx | 4
sc/inc/scmod.hxx | 2
sc/source/core/data/dptabsrc.cxx | 2
sc/source/core/opencl/formulagroupcl.cxx | 16
sc/source/core/tool/adiasync.cxx | 4
sc/source/core/tool/rangelst.cxx | 4
sc/source/core/tool/rangenam.cxx | 4
sc/source/ui/app/drwtrans.cxx | 6
sc/source/ui/app/scdll.cxx | 2
sc/source/ui/app/transobj.cxx | 6
sc/source/ui/dbgui/PivotLayoutTreeList.cxx | 4
sc/source/ui/dbgui/PivotLayoutTreeListBase.cxx | 4
sc/source/ui/dbgui/PivotLayoutTreeListData.cxx | 8
sc/source/ui/dbgui/foptmgr.cxx | 6
sc/source/ui/dbgui/sfiltdlg.cxx | 6
sc/source/ui/dbgui/tpsort.cxx | 6
sc/source/ui/dbgui/tpsubt.cxx | 10
sc/source/ui/docshell/impex.cxx | 6
sc/source/ui/formdlg/dwfunctr.cxx | 12
sc/source/ui/miscdlgs/acredlin.cxx | 58 +-
sc/source/ui/pagedlg/areasdlg.cxx | 4
sc/source/ui/unoobj/docuno.cxx | 4
sc/source/ui/unoobj/miscuno.cxx | 8
sc/source/ui/vba/vbarange.cxx | 2
scaddins/source/analysis/analysis.cxx | 2
scaddins/source/analysis/analysishelper.cxx | 6
sd/inc/sdmod.hxx | 2
sd/source/filter/eppt/eppt.cxx | 14
sd/source/filter/eppt/epptso.cxx | 28 -
sd/source/filter/eppt/pptx-epptbase.cxx | 6
sd/source/filter/eppt/pptx-text.cxx | 54 +-
sd/source/filter/html/htmlex.cxx | 4
sd/source/filter/ppt/pptin.cxx | 2
sd/source/filter/ppt/propread.cxx | 4
sd/source/filter/xml/sdxmlwrp.cxx | 2
sd/source/ui/app/optsitem.cxx | 138 ++---
sd/source/ui/app/sddll.cxx | 2
sd/source/ui/app/sdmod.cxx | 2
sd/source/ui/app/sdmod1.cxx | 2
sd/source/ui/app/sdxfer.cxx | 4
sd/source/ui/dlg/PhotoAlbumDialog.cxx | 26 -
sd/source/ui/dlg/custsdlg.cxx | 2
sd/source/ui/remotecontrol/BluetoothServer.cxx | 2
sd/source/ui/remotecontrol/BufferedStreamSocket.cxx | 2
sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx | 2
sd/source/ui/slideshow/slideshowimpl.cxx | 2
sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx | 2
sd/source/ui/unoidl/unopage.cxx | 4
sdext/source/pdfimport/pdfparse/pdfentries.cxx | 4
sdext/source/pdfimport/pdfparse/pdfparse.cxx | 2
sfx2/source/appl/fileobj.cxx | 2
sfx2/source/appl/impldde.cxx | 2
sfx2/source/appl/newhelp.cxx | 10
sfx2/source/appl/opengrf.cxx | 2
sfx2/source/appl/shutdowniconunx.cxx | 6
sfx2/source/control/dispatch.cxx | 2
sfx2/source/control/objface.cxx | 10
sfx2/source/control/shell.cxx | 6
sfx2/source/dialog/styfitem.cxx | 12
sfx2/source/dialog/versdlg.cxx | 6
sfx2/source/menu/mnuitem.cxx | 2
shell/source/backends/gconfbe/gconfaccess.cxx | 2
sot/qa/cppunit/test_sot.cxx | 2
sot/source/sdstor/stgcache.cxx | 2
sot/source/sdstor/stgcache.hxx | 2
sot/source/sdstor/stgelem.cxx | 4
sot/source/sdstor/stgstrms.cxx | 18
sot/source/sdstor/storage.cxx | 4
sot/source/sdstor/ucbstorage.cxx | 2
starmath/inc/smmod.hxx | 2
starmath/source/smdll.cxx | 2
starmath/source/unomodel.cxx | 12
stoc/source/corereflection/base.hxx | 10
stoc/source/corereflection/crarray.cxx | 10
stoc/source/corereflection/crcomp.cxx | 6
stoc/source/corereflection/crefl.cxx | 8
stoc/source/corereflection/criface.cxx | 22
stoc/source/inspect/introspection.cxx | 12
stoc/source/invocation/invocation.cxx | 2
stoc/source/invocation_adapterfactory/iafactory.cxx | 18
stoc/source/servicemanager/servicemanager.cxx | 2
stoc/source/typeconv/convert.cxx | 88 +--
store/source/storcach.cxx | 2
store/source/storlckb.cxx | 4
svl/source/config/cjkoptions.cxx | 2
svl/source/items/itemprop.cxx | 2
svl/source/items/itemset.cxx | 2
svl/source/misc/fstathelper.cxx | 2
svl/source/numbers/numfmuno.cxx | 2
svtools/qa/unit/testHtmlWriter.cxx | 2
svtools/source/config/apearcfg.cxx | 4
svtools/source/config/colorcfg.cxx | 2
svtools/source/config/extcolorcfg.cxx | 2
svtools/source/config/fontsubstconfig.cxx | 6
svtools/source/config/htmlcfg.cxx | 14
svtools/source/contnr/fileview.cxx | 16
svtools/source/control/ctrltool.cxx | 4
svtools/source/graphic/graphic.cxx | 4
svtools/source/misc/transfer2.cxx | 4
svtools/source/svhtml/htmlkywd.cxx | 20
svtools/source/svrtf/rtfkeywd.cxx | 24
svtools/source/uno/treecontrolpeer.cxx | 2
svx/source/dialog/ctredlin.cxx | 6
svx/source/dialog/docrecovery.cxx | 6
svx/source/dialog/rubydialog.cxx | 8
svx/source/fmcomp/gridcols.cxx | 6
svx/source/fmcomp/gridctrl.cxx | 10
svx/source/form/filtnav.cxx | 48 -
svx/source/form/navigatortree.cxx | 42 -
svx/source/items/customshapeitem.cxx | 42 -
svx/source/sdr/properties/itemsettools.cxx | 14
svx/source/svdraw/svdglev.cxx | 38 -
svx/source/svdraw/svdhdl.cxx | 4
svx/source/svdraw/svdobj.cxx | 2
svx/source/svdraw/svdpoev.cxx | 18
svx/source/table/cell.cxx | 2
svx/source/tbxctrls/fillctrl.cxx | 6
svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx | 2
svx/source/unodraw/XPropertyTable.cxx | 2
svx/source/unodraw/unoshap2.cxx | 14
svx/source/unodraw/unoshape.cxx | 4
svx/source/xoutdev/_xoutbmp.cxx | 2
svx/source/xoutdev/xattr.cxx | 8
sw/inc/swmodule.hxx | 2
sw/source/core/attr/format.cxx | 2
sw/source/core/bastyp/calc.cxx | 4
sw/source/core/doc/DocumentContentOperationsManager.cxx | 2
sw/source/core/doc/doc.cxx | 2
sw/source/core/doc/docedt.cxx | 2
sw/source/core/doc/docfmt.cxx | 2
sw/source/core/doc/swserv.cxx | 2
sw/source/core/docnode/ndtbl.cxx | 2
sw/source/core/docnode/nodes.cxx | 2
sw/source/core/edit/edglss.cxx | 2
sw/source/core/edit/edlingu.cxx | 4
sw/source/core/fields/authfld.cxx | 6
sw/source/core/fields/cellfml.cxx | 14
sw/source/core/fields/dbfld.cxx | 2
sw/source/core/fields/ddefld.cxx | 2
sw/source/core/fields/docufld.cxx | 20
sw/source/core/fields/expfld.cxx | 10
sw/source/core/fields/flddat.cxx | 4
sw/source/core/fields/scrptfld.cxx | 2
sw/source/core/fields/tblcalc.cxx | 2
sw/source/core/fields/usrfld.cxx | 6
sw/source/core/frmedt/fefly1.cxx | 2
sw/source/core/graphic/grfatr.cxx | 2
sw/source/core/layout/atrfrm.cxx | 34 -
sw/source/core/layout/dbg_lay.cxx | 16
sw/source/core/layout/dumpfilter.cxx | 4
sw/source/core/layout/frmtool.cxx | 6
sw/source/core/para/paratr.cxx | 4
sw/source/core/text/porfly.cxx | 2
sw/source/core/text/porfly.hxx | 8
sw/source/core/text/txtcache.cxx | 4
sw/source/core/text/txtfrm.cxx | 6
sw/source/core/txtnode/fmtatr2.cxx | 2
sw/source/core/txtnode/fntcache.cxx | 12
sw/source/core/txtnode/swfntcch.cxx | 4
sw/source/core/unocore/swunohelper.cxx | 2
sw/source/core/unocore/unodraw.cxx | 24
sw/source/core/unocore/unofield.cxx | 4
sw/source/core/unocore/unoframe.cxx | 6
sw/source/core/unocore/unoobj.cxx | 8
sw/source/core/unocore/unosett.cxx | 22
sw/source/core/unocore/unosrch.cxx | 2
sw/source/core/unocore/unostyle.cxx | 14
sw/source/core/unocore/unotbl.cxx | 26 -
sw/source/filter/basflt/fltini.cxx | 2
sw/source/filter/html/htmlcss1.cxx | 2
sw/source/filter/html/htmlforw.cxx | 100 +--
sw/source/filter/ww8/rtfattributeoutput.cxx | 12
sw/source/filter/ww8/rtfsdrexport.cxx | 2
sw/source/filter/ww8/wrtw8esh.cxx | 12
sw/source/filter/ww8/wrtw8sty.cxx | 18
sw/source/filter/ww8/ww8graf.cxx | 4
sw/source/filter/ww8/ww8par.cxx | 8
sw/source/filter/ww8/ww8par2.cxx | 4
sw/source/filter/ww8/ww8par6.cxx | 2
sw/source/filter/ww8/ww8scan.cxx | 56 +-
sw/source/filter/xml/XMLRedlineImportHelper.cxx | 8
sw/source/filter/xml/swxml.cxx | 6
sw/source/filter/xml/wrtxml.cxx | 2
sw/source/filter/xml/xmlexp.cxx | 4
sw/source/filter/xml/xmlimp.cxx | 4
sw/source/filter/xml/xmltble.cxx | 2
sw/source/filter/xml/xmltexti.cxx | 4
sw/source/ui/chrdlg/swuiccoll.cxx | 4
sw/source/ui/config/optload.cxx | 10
sw/source/ui/config/optpage.cxx | 16
sw/source/ui/dbui/dbinsdlg.cxx | 12
sw/source/ui/dialog/uiregionsw.cxx | 40 -
sw/source/ui/envelp/label1.cxx | 18
sw/source/ui/envelp/labelexp.cxx | 8
sw/source/ui/frmdlg/frmpage.cxx | 18
sw/source/ui/index/cnttab.cxx | 8
sw/source/ui/misc/glosbib.cxx | 16
sw/source/ui/misc/glossary.cxx | 20
sw/source/ui/misc/srtdlg.cxx | 8
sw/source/ui/table/tabledlg.cxx | 4
sw/source/uibase/app/docsh2.cxx | 4
sw/source/uibase/app/docst.cxx | 2
sw/source/uibase/app/swdll.cxx | 2
sw/source/uibase/config/modcfg.cxx | 28 -
sw/source/uibase/config/prtopt.cxx | 32 -
sw/source/uibase/config/usrpref.cxx | 6
sw/source/uibase/dochdl/swdtflvr.cxx | 8
sw/source/uibase/docvw/SidebarWin.cxx | 2
sw/source/uibase/envelp/envimg.cxx | 4
sw/source/uibase/envelp/labimg.cxx | 8
sw/source/uibase/misc/redlndlg.cxx | 4
sw/source/uibase/shells/tabsh.cxx | 2
sw/source/uibase/shells/textidx.cxx | 2
sw/source/uibase/uiview/view.cxx | 4
sw/source/uibase/uiview/view2.cxx | 4
sw/source/uibase/uno/SwXDocumentSettings.cxx | 88 +--
sw/source/uibase/uno/unomod.cxx | 36 -
sw/source/uibase/uno/unotxdoc.cxx | 14
sw/source/uibase/uno/unotxvw.cxx | 2
sw/source/uibase/utlui/content.cxx | 124 ++--
sw/source/uibase/utlui/glbltree.cxx | 22
sw/source/uibase/utlui/navicfg.cxx | 4
sw/source/uibase/wrtsh/select.cxx | 2
toolkit/source/awt/scrollabledialog.cxx | 2
toolkit/source/awt/vclxaccessiblecomponent.cxx | 10
toolkit/source/awt/vclxbitmap.cxx | 4
toolkit/source/awt/vclxfont.cxx | 2
toolkit/source/awt/vclxgraphics.cxx | 2
toolkit/source/awt/vclxprinter.cxx | 2
toolkit/source/awt/vclxtoolkit.cxx | 10
toolkit/source/awt/vclxwindow.cxx | 24
tools/source/inet/inetstrm.cxx | 14
tools/source/rc/rc.cxx | 2
tools/source/rc/resmgr.cxx | 56 +-
tools/source/ref/errinf.cxx | 2
tools/source/stream/stream.cxx | 16
tools/source/zcodec/zcodec.cxx | 4
ucb/source/sorter/sortresult.cxx | 4
ucb/source/ucp/ftp/ftpurl.cxx | 6
ucb/source/ucp/gio/gio_content.cxx | 2
ucb/source/ucp/gio/gio_mount.cxx | 2
unotools/source/config/fltrcfg.cxx | 10
unotools/source/config/fontcfg.cxx | 8
unotools/source/config/misccfg.cxx | 6
unotools/source/config/saveopt.cxx | 2
unotools/source/misc/fontcvt.cxx | 4
unotools/source/ucbhelper/ucblockbytes.cxx | 2
unoxml/source/dom/documentbuilder.cxx | 2
uui/source/iahndl.cxx | 4
vcl/generic/fontmanager/fontconfig.cxx | 4
vcl/generic/fontmanager/fontmanager.cxx | 6
vcl/generic/fontmanager/parseAFM.cxx | 32 -
vcl/generic/glyphs/gcach_ftyp.cxx | 10
vcl/generic/glyphs/gcach_layout.cxx | 12
vcl/generic/print/common_gfx.cxx | 2
vcl/generic/print/genprnpsp.cxx | 4
vcl/generic/print/genpspgraphics.cxx | 4
vcl/generic/print/glyphset.cxx | 12
vcl/generic/print/printerjob.cxx | 2
vcl/generic/print/prtsetup.cxx | 8
vcl/generic/print/text_gfx.cxx | 20
vcl/headless/svpprn.cxx | 2
vcl/opengl/x11/gdiimpl.cxx | 2
vcl/source/app/svmain.cxx | 4
vcl/source/control/button.cxx | 4
vcl/source/control/field.cxx | 4
vcl/source/control/fixed.cxx | 4
vcl/source/filter/graphicfilter.cxx | 2
vcl/source/filter/igif/decode.cxx | 4
vcl/source/filter/jpeg/JpegReader.cxx | 10
vcl/source/filter/jpeg/JpegWriter.cxx | 10
vcl/source/filter/jpeg/jpegc.cxx | 2
vcl/source/filter/wmf/winmtf.cxx | 22
vcl/source/filter/wmf/winmtf.hxx | 6
vcl/source/filter/wmf/wmfwr.cxx | 2
vcl/source/font/PhysicalFontCollection.cxx | 2
vcl/source/fontsubset/gsub.cxx | 6
vcl/source/fontsubset/list.cxx | 4
vcl/source/fontsubset/sft.cxx | 56 +-
vcl/source/fontsubset/ttcr.cxx | 150 ++---
vcl/source/gdi/animate.cxx | 2
vcl/source/gdi/bitmap3.cxx | 6
vcl/source/gdi/bitmap4.cxx | 4
vcl/source/gdi/configsettings.cxx | 2
vcl/source/gdi/dibtools.cxx | 4
vcl/source/gdi/gdimtf.cxx | 38 -
vcl/source/gdi/image.cxx | 16
vcl/source/gdi/impvect.cxx | 10
vcl/source/gdi/jobset.cxx | 4
vcl/source/gdi/octree.cxx | 4
vcl/source/gdi/pdfwriter_impl.cxx | 16
vcl/source/gdi/pdfwriter_impl2.cxx | 4
vcl/source/gdi/pngwrite.cxx | 2
vcl/source/gdi/sallayout.cxx | 12
vcl/source/helper/strhelper.cxx | 8
vcl/source/helper/xconnection.cxx | 8
vcl/source/opengl/OpenGLContext.cxx | 2
vcl/source/outdev/hatch.cxx | 8
vcl/source/outdev/text.cxx | 8
vcl/source/window/accel.cxx | 12
vcl/source/window/debug.cxx | 2
vcl/source/window/debugevent.cxx | 2
vcl/source/window/menu.cxx | 16
vcl/source/window/resource.cxx | 2
vcl/source/window/syschild.cxx | 2
vcl/source/window/toolbox.cxx | 8
vcl/source/window/toolbox2.cxx | 8
vcl/source/window/winproc.cxx | 70 +-
vcl/unx/generic/app/i18n_cb.cxx | 14
vcl/unx/generic/app/i18n_ic.cxx | 8
vcl/unx/generic/app/i18n_status.cxx | 24
vcl/unx/generic/app/saldisp.cxx | 2
vcl/unx/generic/app/sm.cxx | 14
vcl/unx/generic/app/wmadaptor.cxx | 14
vcl/unx/generic/dtrans/X11_selection.cxx | 10
vcl/unx/generic/dtrans/bmp.cxx | 6
vcl/unx/generic/dtrans/config.cxx | 2
vcl/unx/generic/gdi/cairo_xlib_cairo.cxx | 22
vcl/unx/generic/gdi/cairotextrender.cxx | 6
vcl/unx/generic/printer/cupsmgr.cxx | 32 -
vcl/unx/generic/printer/jobdata.cxx | 2
vcl/unx/generic/window/salframe.cxx | 6
vcl/unx/generic/window/salobj.cxx | 32 -
vcl/unx/gtk/a11y/atkfactory.cxx | 2
vcl/unx/gtk/a11y/atkhypertext.cxx | 4
vcl/unx/gtk/a11y/atktextattributes.cxx | 10
vcl/unx/gtk/a11y/atkwindow.cxx | 2
vcl/unx/gtk/a11y/atkwrapper.cxx | 4
vcl/unx/gtk/app/gtkdata.cxx | 10
vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx | 2
vcl/unx/gtk/window/gloactiongroup.cxx | 4
vcl/unx/gtk/window/gtkobject.cxx | 6
vcl/unx/gtk/window/gtksalframe.cxx | 48 -
vcl/unx/gtk/window/gtksalmenu.cxx | 4
vcl/unx/gtk/window/hudawareness.cxx | 6
vcl/unx/kde/kdedata.cxx | 2
xmlhelp/source/cxxhelp/provider/urlparameter.cxx | 8
xmloff/source/core/unoatrcn.cxx | 4
xmloff/source/draw/XMLImageMapExport.cxx | 2
xmloff/source/draw/shapeexport.cxx | 10
xmloff/source/draw/ximpcustomshape.cxx | 32 -
xmloff/source/style/XMLConstantsPropertyHandler.cxx | 2
xmloff/source/style/XMLPageExport.cxx | 2
xmloff/source/style/impastpl.cxx | 2
xmloff/source/style/prstylei.cxx | 2
xmloff/source/style/styleexp.cxx | 6
xmloff/source/style/xmlbahdl.cxx | 2
xmloff/source/style/xmlnume.cxx | 4
xmloff/source/style/xmlnumi.cxx | 2
xmloff/source/style/xmlstyle.cxx | 2
xmloff/source/text/XMLIndexMarkExport.cxx | 4
xmloff/source/text/XMLLineNumberingExport.cxx | 8
xmloff/source/text/XMLRedlineExport.cxx | 22
xmloff/source/text/XMLSectionExport.cxx | 30 -
xmloff/source/text/XMLTextColumnsExport.cxx | 4
xmloff/source/text/XMLTextHeaderFooterContext.cxx | 6
xmloff/source/text/XMLTextMasterPageContext.cxx | 2
xmloff/source/text/txtexppr.cxx | 8
xmloff/source/text/txtflde.cxx | 4
xmloff/source/text/txtftne.cxx | 2
xmloff/source/text/txtimppr.cxx | 2
xmloff/source/text/txtparae.cxx | 42 -
xmloff/source/text/txtprhdl.cxx | 12
xmloff/source/text/txtstyli.cxx | 2
xmlscript/source/xmldlg_imexp/xmldlg_expmodels.cxx | 4
xmlscript/source/xmldlg_imexp/xmldlg_export.cxx | 26 -
xmlsecurity/source/dialogs/certificateviewer.cxx | 10
xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx | 2
xmlsecurity/source/xmlsec/saxhelper.cxx | 2
xmlsecurity/source/xmlsec/xmlstreamio.cxx | 4
622 files changed, 3645 insertions(+), 3647 deletions(-)
New commits:
commit ef44d45a4e23ee58b245563222d18bc18300c3d1
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:56 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: Idff46e5642034cf751d557de9a49c02a7abf27bb
diff --git a/compilerplugins/clang/cstylecast.cxx b/compilerplugins/clang/cstylecast.cxx
index 048d2d5..fcc1fc82 100644
--- a/compilerplugins/clang/cstylecast.cxx
+++ b/compilerplugins/clang/cstylecast.cxx
@@ -114,14 +114,9 @@ bool CStyleCast::VisitCStyleCastExpr(const CStyleCastExpr * expr) {
std::string incompFrom;
std::string incompTo;
if( expr->getCastKind() == CK_BitCast ) {
- QualType t = resolvePointers(expr->getSubExprAsWritten()->getType());
- // Ignore "safe" casts for now that involve casting from void* (and can
- // thus not be interpreted as either a static_cast or a
- // reinterpret_cast, with potentially different results):
- if (t->isVoidType()) {
- return true;
- }
- if (t->isIncompleteType()) {
+ if (resolvePointers(expr->getSubExprAsWritten()->getType())
+ ->isIncompleteType())
+ {
incompFrom = "incomplete ";
}
if (resolvePointers(expr->getType())->isIncompleteType()) {
commit 51a705c439ef2074120f276cce641d8e21768e8f
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:48 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: I112f4df678d9f3e70df7782443c860f930909e33
diff --git a/xmlsecurity/source/dialogs/certificateviewer.cxx b/xmlsecurity/source/dialogs/certificateviewer.cxx
index d4f0f5a..309a29a 100644
--- a/xmlsecurity/source/dialogs/certificateviewer.cxx
+++ b/xmlsecurity/source/dialogs/certificateviewer.cxx
@@ -158,7 +158,7 @@ void CertificateViewerDetailsTP::Clear( void )
SvTreeListEntry* pEntry = m_pElementsLB->GetEntry( i );
while( pEntry )
{
- delete ( Details_UserDatat* ) pEntry->GetUserData();
+ delete static_cast<Details_UserDatat*>(pEntry->GetUserData());
++i;
pEntry = m_pElementsLB->GetEntry( i );
}
@@ -271,7 +271,7 @@ IMPL_LINK_NOARG(CertificateViewerDetailsTP, ElementSelectHdl)
bool bFixedWidthFont;
if( pEntry )
{
- const Details_UserDatat* p = ( Details_UserDatat* ) pEntry->GetUserData();
+ const Details_UserDatat* p = static_cast<Details_UserDatat*>(pEntry->GetUserData());
aElementText = p->maTxt;
bFixedWidthFont = p->mbFixedWidthFont;
}
@@ -370,7 +370,7 @@ IMPL_LINK_NOARG(CertificateViewerCertPathTP, ViewCertHdl)
SvTreeListEntry* pEntry = mpCertPathLB->FirstSelected();
if( pEntry )
{
- CertificateViewer aViewer( this, mpDlg->mxSecurityEnvironment, ((CertPath_UserData*)pEntry->GetUserData())->mxCert, false );
+ CertificateViewer aViewer( this, mpDlg->mxSecurityEnvironment, static_cast<CertPath_UserData*>(pEntry->GetUserData())->mxCert, false );
aViewer.Execute();
}
@@ -383,7 +383,7 @@ IMPL_LINK_NOARG(CertificateViewerCertPathTP, CertSelectHdl)
SvTreeListEntry* pEntry = mpCertPathLB->FirstSelected();
if( pEntry )
{
- CertPath_UserData* pData = (CertPath_UserData*) pEntry->GetUserData();
+ CertPath_UserData* pData = static_cast<CertPath_UserData*>(pEntry->GetUserData());
if ( pData )
sStatus = pData->mbValid ? msCertOK : msCertNotValidated;
}
@@ -400,7 +400,7 @@ void CertificateViewerCertPathTP::Clear( void )
SvTreeListEntry* pEntry = mpCertPathLB->GetEntry( i );
while( pEntry )
{
- delete ( CertPath_UserData* ) pEntry->GetUserData();
+ delete static_cast<CertPath_UserData*>(pEntry->GetUserData());
++i;
pEntry = mpCertPathLB->GetEntry( i );
}
diff --git a/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx b/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
index 0355e27..ceb6289 100644
--- a/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
+++ b/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
@@ -97,7 +97,7 @@ char* GetPasswordFunction( PK11SlotInfo* pSlot, PRBool bRetry, void* /*arg*/ )
pPasswordRequest->getPassword(),
osl_getThreadTextEncoding()));
sal_Int32 nLen = aPassword.getLength();
- char* pPassword = (char*) PORT_Alloc( nLen+1 ) ;
+ char* pPassword = static_cast<char*>(PORT_Alloc( nLen+1 ) );
pPassword[nLen] = 0;
memcpy( pPassword, aPassword.getStr(), nLen );
return pPassword;
diff --git a/xmlsecurity/source/xmlsec/saxhelper.cxx b/xmlsecurity/source/xmlsec/saxhelper.cxx
index cd15cc6..0751678 100644
--- a/xmlsecurity/source/xmlsec/saxhelper.cxx
+++ b/xmlsecurity/source/xmlsec/saxhelper.cxx
@@ -67,7 +67,7 @@ const xmlChar** attrlist_to_nxmlstr( const cssu::Sequence< cssxcsax::XMLAttribut
if( nLength != 0 )
{
- attrs = ( const xmlChar** )xmlMalloc( ( nLength * 2 + 2 ) * sizeof( xmlChar* ) ) ;
+ attrs = static_cast<const xmlChar**>(xmlMalloc( ( nLength * 2 + 2 ) * sizeof( xmlChar* ) ));
}
else
{
diff --git a/xmlsecurity/source/xmlsec/xmlstreamio.cxx b/xmlsecurity/source/xmlsec/xmlstreamio.cxx
index 8223a9f..1034e8b 100644
--- a/xmlsecurity/source/xmlsec/xmlstreamio.cxx
+++ b/xmlsecurity/source/xmlsec/xmlstreamio.cxx
@@ -116,7 +116,7 @@ int xmlStreamRead( void* context, char* buffer, int len )
if( ( enableXmlStreamIO & XMLSTREAMIO_INITIALIZED ) &&
( enableXmlStreamIO & XMLSTREAMIO_REGISTERED ) ) {
if( context != NULL ) {
- xInputStream = ( com::sun::star::io::XInputStream* )context ;
+ xInputStream = static_cast<com::sun::star::io::XInputStream*>(context);
if( !xInputStream.is() )
return 0 ;
@@ -137,7 +137,7 @@ int xmlStreamClose( void * context )
( enableXmlStreamIO & XMLSTREAMIO_REGISTERED ) ) {
if( context != NULL ) {
::com::sun::star::io::XInputStream* pInputStream ;
- pInputStream = ( ::com::sun::star::io::XInputStream* )context ;
+ pInputStream = static_cast<css::io::XInputStream*>(context);
pInputStream->release() ;
}
}
commit b51252247ef9b53fea133aaa801e662369f71ea4
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:44 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: Id64d800ccebab274e5bb7ad2667c0e270e745bdf
diff --git a/xmlscript/source/xmldlg_imexp/xmldlg_expmodels.cxx b/xmlscript/source/xmldlg_imexp/xmldlg_expmodels.cxx
index dc5d0b7..10d03ce 100644
--- a/xmlscript/source/xmldlg_imexp/xmldlg_expmodels.cxx
+++ b/xmlscript/source/xmldlg_imexp/xmldlg_expmodels.cxx
@@ -873,10 +873,10 @@ void ElementDescriptor::readFormattedFieldModel( StyleBag * all_styles )
switch (a.getValueTypeClass())
{
case TypeClass_DOUBLE:
- addAttribute( XMLNS_DIALOGS_PREFIX ":value-default", OUString::number( *(double const *)a.getValue() ) );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":value-default", OUString::number( *static_cast<double const *>(a.getValue()) ) );
break;
case TypeClass_STRING:
- addAttribute( XMLNS_DIALOGS_PREFIX ":value-default", *(OUString const *)a.getValue() );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":value-default", *static_cast<OUString const *>(a.getValue()) );
break;
default:
break;
diff --git a/xmlscript/source/xmldlg_imexp/xmldlg_export.cxx b/xmlscript/source/xmldlg_imexp/xmldlg_export.cxx
index ab9049f..5bb12a3 100644
--- a/xmlscript/source/xmldlg_imexp/xmldlg_export.cxx
+++ b/xmlscript/source/xmldlg_imexp/xmldlg_export.cxx
@@ -518,7 +518,7 @@ void ElementDescriptor::readHexLongAttr( OUString const & rPropName, OUString co
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- addAttribute( rAttrName, "0x" + OUString::number((sal_Int64)(sal_uInt64)*(sal_uInt32 *)a.getValue(),16) );
+ addAttribute( rAttrName, "0x" + OUString::number((sal_Int64)(sal_uInt64)*static_cast<sal_uInt32 const *>(a.getValue()),16) );
}
}
}
@@ -530,7 +530,7 @@ void ElementDescriptor::readDateFormatAttr( OUString const & rPropName, OUString
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case 0:
addAttribute( rAttrName, "system_short" );
@@ -627,7 +627,7 @@ void ElementDescriptor::readTimeFormatAttr( OUString const & rPropName, OUString
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case 0:
addAttribute( rAttrName, "24h_short" );
@@ -664,7 +664,7 @@ void ElementDescriptor::readAlignAttr( OUString const & rPropName, OUString cons
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case 0:
addAttribute( rAttrName, "left" );
@@ -745,7 +745,7 @@ void ElementDescriptor::readImageAlignAttr( OUString const & rPropName, OUString
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case 0:
addAttribute( rAttrName, "left" );
@@ -776,7 +776,7 @@ void ElementDescriptor::readImagePositionAttr( OUString const & rPropName, OUStr
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case awt::ImagePosition::LeftTop:
addAttribute( rAttrName, "left-top" );
@@ -832,7 +832,7 @@ void ElementDescriptor::readButtonTypeAttr( OUString const & rPropName, OUString
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case awt::PushButtonType_STANDARD:
addAttribute( rAttrName, "standard" );
@@ -861,7 +861,7 @@ void ElementDescriptor::readOrientationAttr( OUString const & rPropName, OUStrin
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- switch (*(sal_Int32 const *)a.getValue())
+ switch (*static_cast<sal_Int32 const *>(a.getValue()))
{
case 0:
addAttribute( rAttrName, "horizontal" );
@@ -884,7 +884,7 @@ void ElementDescriptor::readLineEndFormatAttr( OUString const & rPropName, OUStr
Any a( _xProps->getPropertyValue( rPropName ) );
if (a.getValueTypeClass() == TypeClass_SHORT)
{
- switch (*(sal_Int16 const *)a.getValue())
+ switch (*static_cast<sal_Int16 const *>(a.getValue()))
{
case awt::LineEndFormat::CARRIAGE_RETURN:
addAttribute( rAttrName, "carriage-return" );
@@ -1103,22 +1103,22 @@ void ElementDescriptor::readDefaults( bool supportPrintable, bool supportVisible
a = _xProps->getPropertyValue( "PositionX" );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- addAttribute( XMLNS_DIALOGS_PREFIX ":left", OUString::number( *(sal_Int32 const *)a.getValue() ) );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":left", OUString::number( *static_cast<sal_Int32 const *>(a.getValue()) ) );
}
a = _xProps->getPropertyValue( "PositionY" );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- addAttribute( XMLNS_DIALOGS_PREFIX ":top", OUString::number( *(sal_Int32 const *)a.getValue() ) );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":top", OUString::number( *static_cast<sal_Int32 const *>(a.getValue()) ) );
}
a = _xProps->getPropertyValue( "Width" );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- addAttribute( XMLNS_DIALOGS_PREFIX ":width", OUString::number( *(sal_Int32 const *)a.getValue() ) );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":width", OUString::number( *static_cast<sal_Int32 const *>(a.getValue()) ) );
}
a = _xProps->getPropertyValue( "Height" );
if (a.getValueTypeClass() == TypeClass_LONG)
{
- addAttribute( XMLNS_DIALOGS_PREFIX ":height", OUString::number( *(sal_Int32 const *)a.getValue() ) );
+ addAttribute( XMLNS_DIALOGS_PREFIX ":height", OUString::number( *static_cast<sal_Int32 const *>(a.getValue()) ) );
}
if (supportPrintable)
commit 44b9b27b1ad161191d254f5497e7eb0766854966
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:37 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: I962bd44f2ef6204ed2ea51f79b752bd948f67209
diff --git a/xmloff/source/core/unoatrcn.cxx b/xmloff/source/core/unoatrcn.cxx
index df29325..1f4dfba 100644
--- a/xmloff/source/core/unoatrcn.cxx
+++ b/xmloff/source/core/unoatrcn.cxx
@@ -165,7 +165,7 @@ void SAL_CALL SvUnoAttributeContainer::replaceByName(const OUString& aName, cons
if( nAttr == USHRT_MAX )
throw container::NoSuchElementException();
- xml::AttributeData* pData = (xml::AttributeData*)aElement.getValue();
+ xml::AttributeData const * pData = static_cast<xml::AttributeData const *>(aElement.getValue());
sal_Int32 nPos = aName.indexOf( ':' );
if( nPos != -1L )
@@ -208,7 +208,7 @@ throw( lang::IllegalArgumentException, container::ElementExistException, lang::W
if( nAttr != USHRT_MAX )
throw container::ElementExistException();
- xml::AttributeData* pData = (xml::AttributeData*)aElement.getValue();
+ xml::AttributeData const * pData = static_cast<xml::AttributeData const *>(aElement.getValue());
sal_Int32 nPos = aName.indexOf( ':' );
if( nPos != -1L )
diff --git a/xmloff/source/draw/XMLImageMapExport.cxx b/xmloff/source/draw/XMLImageMapExport.cxx
index b1a4b71..9ea9b58 100644
--- a/xmloff/source/draw/XMLImageMapExport.cxx
+++ b/xmloff/source/draw/XMLImageMapExport.cxx
@@ -199,7 +199,7 @@ void XMLImageMapExport::ExportMapEntry(
// is-active
aAny = rPropertySet->getPropertyValue(msIsActive);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
mrExport.AddAttribute(XML_NAMESPACE_DRAW, XML_NOHREF, XML_NOHREF);
}
diff --git a/xmloff/source/draw/shapeexport.cxx b/xmloff/source/draw/shapeexport.cxx
index 67854f7..e7ec2fb 100644
--- a/xmloff/source/draw/shapeexport.cxx
+++ b/xmloff/source/draw/shapeexport.cxx
@@ -1986,11 +1986,11 @@ void XMLShapeExport::ImpExportLineShape(
// get the two points
uno::Any aAny(xPropSet->getPropertyValue("Geometry"));
- drawing::PointSequenceSequence* pSourcePolyPolygon = (drawing::PointSequenceSequence*)aAny.getValue();
+ drawing::PointSequenceSequence const * pSourcePolyPolygon = static_cast<drawing::PointSequenceSequence const *>(aAny.getValue());
if(pSourcePolyPolygon)
{
- drawing::PointSequence* pOuterSequence = pSourcePolyPolygon->getArray();
+ drawing::PointSequence* pOuterSequence = const_cast<css::drawing::PointSequenceSequence *>(pSourcePolyPolygon)->getArray();
if(pOuterSequence)
{
drawing::PointSequence* pInnerSequence = pOuterSequence++;
@@ -2164,7 +2164,7 @@ void XMLShapeExport::ImpExportPolygonShape(
// get PolygonBezier
uno::Any aAny( xPropSet->getPropertyValue("Geometry") );
const basegfx::B2DPolyPolygon aPolyPolygon(
- basegfx::tools::UnoPolyPolygonBezierCoordsToB2DPolyPolygon(*(drawing::PolyPolygonBezierCoords*)aAny.getValue()));
+ basegfx::tools::UnoPolyPolygonBezierCoordsToB2DPolyPolygon(*static_cast<drawing::PolyPolygonBezierCoords const *>(aAny.getValue())));
if(aPolyPolygon.count())
{
@@ -2185,7 +2185,7 @@ void XMLShapeExport::ImpExportPolygonShape(
// get non-bezier polygon
uno::Any aAny( xPropSet->getPropertyValue("Geometry") );
const basegfx::B2DPolyPolygon aPolyPolygon(
- basegfx::tools::UnoPointSequenceSequenceToB2DPolyPolygon(*(drawing::PointSequenceSequence*)aAny.getValue()));
+ basegfx::tools::UnoPointSequenceSequenceToB2DPolyPolygon(*static_cast<drawing::PointSequenceSequence const *>(aAny.getValue())));
if(!aPolyPolygon.areControlPointsUsed() && 1 == aPolyPolygon.count())
{
@@ -2579,7 +2579,7 @@ void XMLShapeExport::ImpExportConnectorShape(
if( xProps->getPropertyValue("PolyPolygonBezier") >>= aAny )
{
// get PolygonBezier
- drawing::PolyPolygonBezierCoords* pSourcePolyPolygon = (drawing::PolyPolygonBezierCoords*)aAny.getValue();
+ drawing::PolyPolygonBezierCoords const * pSourcePolyPolygon = static_cast<drawing::PolyPolygonBezierCoords const *>(aAny.getValue());
if(pSourcePolyPolygon && pSourcePolyPolygon->Coordinates.getLength())
{
diff --git a/xmloff/source/draw/ximpcustomshape.cxx b/xmloff/source/draw/ximpcustomshape.cxx
index 0db4b72..e751697 100644
--- a/xmloff/source/draw/ximpcustomshape.cxx
+++ b/xmloff/source/draw/ximpcustomshape.cxx
@@ -1290,27 +1290,27 @@ void XMLEnhancedCustomShapeContext::EndElement()
case EAS_Coordinates :
case EAS_GluePoints :
{
- uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair >& rSeq =
- *((uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair >*)
+ uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair > const & rSeq =
+ *static_cast<uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair > const *>(
aPathIter->Value.getValue());
for ( i = 0; i < rSeq.getLength(); i++ )
{
- CheckAndResolveEquationParameter( rSeq[ i ].First, pH );
- CheckAndResolveEquationParameter( rSeq[ i ].Second, pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].First), pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].Second), pH );
}
}
break;
case EAS_TextFrames :
{
- uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame >& rSeq =
- *((uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame >*)
+ uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame > const & rSeq =
+ *static_cast<uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame > const *>(
aPathIter->Value.getValue());
for ( i = 0; i < rSeq.getLength(); i++ )
{
- CheckAndResolveEquationParameter( rSeq[ i ].TopLeft.First, pH );
- CheckAndResolveEquationParameter( rSeq[ i ].TopLeft.Second, pH );
- CheckAndResolveEquationParameter( rSeq[ i ].BottomRight.First, pH );
- CheckAndResolveEquationParameter( rSeq[ i ].BottomRight.Second, pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].TopLeft.First), pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].TopLeft.Second), pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].BottomRight.First), pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>(rSeq[ i ].BottomRight.Second), pH );
}
}
break;
@@ -1335,18 +1335,18 @@ void XMLEnhancedCustomShapeContext::EndElement()
case EAS_RadiusRangeMinimum :
case EAS_RadiusRangeMaximum :
{
- CheckAndResolveEquationParameter( *((com::sun::star::drawing::EnhancedCustomShapeParameter*)
- pValues->Value.getValue()), pH );
+ CheckAndResolveEquationParameter( *const_cast<css::drawing::EnhancedCustomShapeParameter *>(static_cast<com::sun::star::drawing::EnhancedCustomShapeParameter const *>(
+ pValues->Value.getValue())), pH );
}
break;
case EAS_Position :
case EAS_Polar :
{
- CheckAndResolveEquationParameter( (*((com::sun::star::drawing::EnhancedCustomShapeParameterPair*)
- pValues->Value.getValue())).First, pH );
- CheckAndResolveEquationParameter( (*((com::sun::star::drawing::EnhancedCustomShapeParameterPair*)
- pValues->Value.getValue())).Second, pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>((*static_cast<com::sun::star::drawing::EnhancedCustomShapeParameterPair const *>(
+ pValues->Value.getValue())).First), pH );
+ CheckAndResolveEquationParameter( const_cast<css::drawing::EnhancedCustomShapeParameter &>((*static_cast<com::sun::star::drawing::EnhancedCustomShapeParameterPair const *>(
+ pValues->Value.getValue())).Second), pH );
}
break;
default:
diff --git a/xmloff/source/style/XMLConstantsPropertyHandler.cxx b/xmloff/source/style/XMLConstantsPropertyHandler.cxx
index 9a38098..ca3843f 100644
--- a/xmloff/source/style/XMLConstantsPropertyHandler.cxx
+++ b/xmloff/source/style/XMLConstantsPropertyHandler.cxx
@@ -67,7 +67,7 @@ bool XMLConstantsPropertyHandler::exportXML(
if( rValue.hasValue() && (rValue.getValueTypeClass() == TypeClass_ENUM))
{
- nEnum = *((sal_Int32*)rValue.getValue());
+ nEnum = *static_cast<sal_Int32 const *>(rValue.getValue());
bRet = true;
}
else
diff --git a/xmloff/source/style/XMLPageExport.cxx b/xmloff/source/style/XMLPageExport.cxx
index 0bd5d95..7713b66 100644
--- a/xmloff/source/style/XMLPageExport.cxx
+++ b/xmloff/source/style/XMLPageExport.cxx
@@ -92,7 +92,7 @@ bool XMLPageExport::exportStyle(
if( xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
Any aAny = xPropSet->getPropertyValue( sIsPhysical );
- if( !*(sal_Bool *)aAny.getValue() )
+ if( !*static_cast<sal_Bool const *>(aAny.getValue()) )
return false;
}
diff --git a/xmloff/source/style/impastpl.cxx b/xmloff/source/style/impastpl.cxx
index 3147eda..b6e1b2a 100644
--- a/xmloff/source/style/impastpl.cxx
+++ b/xmloff/source/style/impastpl.cxx
@@ -86,7 +86,7 @@ struct2string(void *data,
result.append(":");
result.append(compoundType->ppMemberNames[i]);
result.append("=");
- result.append(data2string(((char *)data)+compoundType->pMemberOffsets[i],
+ result.append(data2string(static_cast<char *>(data)+compoundType->pMemberOffsets[i],
compoundType->ppTypeRefs[i]));
}
diff --git a/xmloff/source/style/prstylei.cxx b/xmloff/source/style/prstylei.cxx
index bda1075..47f1910 100644
--- a/xmloff/source/style/prstylei.cxx
+++ b/xmloff/source/style/prstylei.cxx
@@ -367,7 +367,7 @@ void XMLPropStyleContext::CreateAndInsert( bool bOverwrite )
if( !bNew && xPropSetInfo->hasPropertyByName( msIsPhysical ) )
{
Any aAny = xPropSet->getPropertyValue( msIsPhysical );
- bNew = !*(sal_Bool *)aAny.getValue();
+ bNew = !*static_cast<sal_Bool const *>(aAny.getValue());
}
SetNew( bNew );
if( rName != GetName() )
diff --git a/xmloff/source/style/styleexp.cxx b/xmloff/source/style/styleexp.cxx
index 2089fb0..43fbab8 100644
--- a/xmloff/source/style/styleexp.cxx
+++ b/xmloff/source/style/styleexp.cxx
@@ -96,7 +96,7 @@ bool XMLStyleExport::exportStyle(
if( xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
aAny = xPropSet->getPropertyValue( sIsPhysical );
- if( !*(sal_Bool *)aAny.getValue() )
+ if( !*static_cast<sal_Bool const *>(aAny.getValue()) )
return false;
}
@@ -164,7 +164,7 @@ bool XMLStyleExport::exportStyle(
if( xPropSetInfo->hasPropertyByName( sIsAutoUpdate ) )
{
aAny = xPropSet->getPropertyValue( sIsAutoUpdate );
- if( *(sal_Bool *)aAny.getValue() )
+ if( *static_cast<sal_Bool const *>(aAny.getValue()) )
GetExport().AddAttribute( XML_NAMESPACE_STYLE, XML_AUTO_UPDATE,
XML_TRUE );
}
@@ -472,7 +472,7 @@ void XMLStyleExport::exportStyleFamily(
if( xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
Any aAny( xPropSet->getPropertyValue( sIsPhysical ) );
- if( !*(sal_Bool *)aAny.getValue() )
+ if( !*static_cast<sal_Bool const *>(aAny.getValue()) )
continue;
}
diff --git a/xmloff/source/style/xmlbahdl.cxx b/xmloff/source/style/xmlbahdl.cxx
index bee67a4..6c93da9 100644
--- a/xmloff/source/style/xmlbahdl.cxx
+++ b/xmloff/source/style/xmlbahdl.cxx
@@ -695,7 +695,7 @@ bool XMLIsTransparentPropHdl::exportXML( OUString& rStrExpValue, const Any& rVal
// MIB: This looks a bit strange, because bTransPropValue == bValue should
// do the same, but this only applies if 'true' is represented by the same
// 8 bit value in bValue and bTransPropValue. Who will ensure this?
- bool bValue = *(sal_Bool *)rValue.getValue();
+ bool bValue = *static_cast<sal_Bool const *>(rValue.getValue());
bool bIsTrans = bTransPropValue ? bValue : !bValue;
if( bIsTrans )
diff --git a/xmloff/source/style/xmlnume.cxx b/xmloff/source/style/xmlnume.cxx
index db278ab..c658ed1 100644
--- a/xmloff/source/style/xmlnume.cxx
+++ b/xmloff/source/style/xmlnume.cxx
@@ -680,7 +680,7 @@ void SvxXMLNumRuleExport::exportNumberingRule(
xPropSetInfo->hasPropertyByName( sIsContinuousNumbering ) )
{
Any aAny( xPropSet->getPropertyValue( sIsContinuousNumbering ) );
- bContNumbering = *(sal_Bool *)aAny.getValue();
+ bContNumbering = *static_cast<sal_Bool const *>(aAny.getValue());
}
if( bContNumbering )
GetExport().AddAttribute( XML_NAMESPACE_TEXT,
@@ -708,7 +708,7 @@ bool SvxXMLNumRuleExport::exportStyle( const Reference< XStyle >& rStyle )
if( xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
aAny = xPropSet->getPropertyValue( sIsPhysical );
- if( !*(sal_Bool *)aAny.getValue() )
+ if( !*static_cast<sal_Bool const *>(aAny.getValue()) )
return false;
}
diff --git a/xmloff/source/style/xmlnumi.cxx b/xmloff/source/style/xmlnumi.cxx
index 810a724..bea31bf 100644
--- a/xmloff/source/style/xmlnumi.cxx
+++ b/xmloff/source/style/xmlnumi.cxx
@@ -1191,7 +1191,7 @@ void SvxXMLListStyleContext::CreateAndInsertLate( bool bOverwrite )
if( !bNew && xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
Any aAny = xPropSet->getPropertyValue( sIsPhysical );
- bNew = !*(sal_Bool *)aAny.getValue();
+ bNew = !*static_cast<sal_Bool const *>(aAny.getValue());
}
if ( xPropSetInfo->hasPropertyByName( "Hidden" ) )
diff --git a/xmloff/source/style/xmlstyle.cxx b/xmloff/source/style/xmlstyle.cxx
index a4600a4..93ede07 100644
--- a/xmloff/source/style/xmlstyle.cxx
+++ b/xmloff/source/style/xmlstyle.cxx
@@ -701,7 +701,7 @@ Reference < XAutoStyleFamily > SvXMLStylesContext::GetAutoStyles( sal_uInt16 nFa
if (xAutoStyleFamilies->hasByName(sName))
{
Any aAny = xAutoStyleFamilies->getByName( sName );
- xAutoStyles = *(Reference<XAutoStyleFamily>*)aAny.getValue();
+ xAutoStyles = *static_cast<Reference<XAutoStyleFamily> const *>(aAny.getValue());
if( bPara )
const_cast<SvXMLStylesContext *>(this)->mxParaAutoStyles = xAutoStyles;
else
diff --git a/xmloff/source/text/XMLIndexMarkExport.cxx b/xmloff/source/text/XMLIndexMarkExport.cxx
index 60b97be..9004c74 100644
--- a/xmloff/source/text/XMLIndexMarkExport.cxx
+++ b/xmloff/source/text/XMLIndexMarkExport.cxx
@@ -92,7 +92,7 @@ void XMLIndexMarkExport::ExportIndexMark(
// collapsed/alternative text entry?
aAny = rPropSet->getPropertyValue(sIsCollapsed);
- if (*(sal_Bool *)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
// collapsed entry: needs alternative text
nElementNo = 0;
@@ -108,7 +108,7 @@ void XMLIndexMarkExport::ExportIndexMark(
{
// start and end entries: has ID
aAny = rPropSet->getPropertyValue(sIsStart);
- nElementNo = *(sal_Bool *)aAny.getValue() ? 1 : 2;
+ nElementNo = *static_cast<sal_Bool const *>(aAny.getValue()) ? 1 : 2;
// generate ID
OUStringBuffer sBuf;
diff --git a/xmloff/source/text/XMLLineNumberingExport.cxx b/xmloff/source/text/XMLLineNumberingExport.cxx
index 7e89f1c..ae2732f 100644
--- a/xmloff/source/text/XMLLineNumberingExport.cxx
+++ b/xmloff/source/text/XMLLineNumberingExport.cxx
@@ -90,7 +90,7 @@ void XMLLineNumberingExport::Export()
// enable
aAny = xLineNumbering->getPropertyValue(sIsOn);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_NUMBER_LINES, XML_FALSE);
@@ -98,7 +98,7 @@ void XMLLineNumberingExport::Export()
// count empty lines
aAny = xLineNumbering->getPropertyValue(sCountEmptyLines);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_COUNT_EMPTY_LINES, XML_FALSE);
@@ -106,7 +106,7 @@ void XMLLineNumberingExport::Export()
// count in frames
aAny = xLineNumbering->getPropertyValue(sCountLinesInFrames);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_COUNT_IN_TEXT_BOXES, XML_TRUE);
@@ -114,7 +114,7 @@ void XMLLineNumberingExport::Export()
// restart numbering
aAny = xLineNumbering->getPropertyValue(sRestartAtEachPage);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_RESTART_ON_PAGE, XML_TRUE);
diff --git a/xmloff/source/text/XMLRedlineExport.cxx b/xmloff/source/text/XMLRedlineExport.cxx
index fa93ac9..899f6a5 100644
--- a/xmloff/source/text/XMLRedlineExport.cxx
+++ b/xmloff/source/text/XMLRedlineExport.cxx
@@ -213,8 +213,8 @@ void XMLRedlineExport::ExportChangesListElements()
Reference<XPropertySet> aDocPropertySet( rExport.GetModel(),
uno::UNO_QUERY );
// redlining enabled?
- bool bEnabled = *(sal_Bool*)aDocPropertySet->getPropertyValue(
- sRecordChanges ).getValue();
+ bool bEnabled = *static_cast<sal_Bool const *>(aDocPropertySet->getPropertyValue(
+ sRecordChanges ).getValue());
// only export if we have redlines or attributes
if ( aEnumAccess->hasElements() || bEnabled )
@@ -248,7 +248,7 @@ void XMLRedlineExport::ExportChangesListElements()
// export only if not in header or footer
// (those must be exported with their XText)
aAny = xPropSet->getPropertyValue(sIsInHeaderFooter);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
// and finally, export change
ExportChangedRegion(xPropSet);
@@ -272,8 +272,8 @@ void XMLRedlineExport::ExportChangeAutoStyle(
Any aIsStart = rPropSet->getPropertyValue(sIsStart);
Any aIsCollapsed = rPropSet->getPropertyValue(sIsCollapsed);
- if ( *(sal_Bool*)aIsStart.getValue() ||
- *(sal_Bool*)aIsCollapsed.getValue() )
+ if ( *static_cast<sal_Bool const *>(aIsStart.getValue()) ||
+ *static_cast<sal_Bool const *>(aIsCollapsed.getValue()) )
pCurrentChangesList->push_back(rPropSet);
}
@@ -315,7 +315,7 @@ void XMLRedlineExport::ExportChangesListAutoStyles()
// export only if not in header or footer
// (those must be exported with their XText)
aAny = xPropSet->getPropertyValue(sIsInHeaderFooter);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
ExportChangeAutoStyle(xPropSet);
}
@@ -331,7 +331,7 @@ void XMLRedlineExport::ExportChangeInline(
// determine element name (depending on collapsed, start/end)
enum XMLTokenEnum eElement = XML_TOKEN_INVALID;
Any aAny = rPropSet->getPropertyValue(sIsCollapsed);
- bool bCollapsed = *(sal_Bool *)aAny.getValue();
+ bool bCollapsed = *static_cast<sal_Bool const *>(aAny.getValue());
if (bCollapsed)
{
eElement = XML_CHANGE;
@@ -339,7 +339,7 @@ void XMLRedlineExport::ExportChangeInline(
else
{
aAny = rPropSet->getPropertyValue(sIsStart);
- const bool bStart = *(sal_Bool *)aAny.getValue();
+ const bool bStart = *static_cast<sal_Bool const *>(aAny.getValue());
eElement = bStart ? XML_CHANGE_START : XML_CHANGE_END;
}
@@ -364,7 +364,7 @@ void XMLRedlineExport::ExportChangedRegion(
// merge-last-paragraph
Any aAny = rPropSet->getPropertyValue(sMergeLastPara);
- if( ! *(sal_Bool*)aAny.getValue() )
+ if( ! *static_cast<sal_Bool const *>(aAny.getValue()) )
rExport.AddAttribute(XML_NAMESPACE_TEXT, XML_MERGE_LAST_PARAGRAPH,
XML_FALSE);
@@ -581,11 +581,11 @@ void XMLRedlineExport::ExportStartOrEndRedline(
}
else if (sIsCollapsed.equals(pValues[i].Name))
{
- bIsCollapsed = *(sal_Bool*)pValues[i].Value.getValue();
+ bIsCollapsed = *static_cast<sal_Bool const *>(pValues[i].Value.getValue());
}
else if (sIsStart.equals(pValues[i].Name))
{
- bIsStart = *(sal_Bool*)pValues[i].Value.getValue();
+ bIsStart = *static_cast<sal_Bool const *>(pValues[i].Value.getValue());
}
}
diff --git a/xmloff/source/text/XMLSectionExport.cxx b/xmloff/source/text/XMLSectionExport.cxx
index c2912a5..94049fa 100644
--- a/xmloff/source/text/XMLSectionExport.cxx
+++ b/xmloff/source/text/XMLSectionExport.cxx
@@ -436,7 +436,7 @@ void XMLSectionExport::ExportRegularSectionStart(
// #97450# store hidden-status (of conditional sections only)
aAny = xPropSet->getPropertyValue(sIsCurrentlyVisible);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT, XML_IS_HIDDEN,
XML_TRUE);
@@ -447,14 +447,14 @@ void XMLSectionExport::ExportRegularSectionStart(
eDisplay = XML_NONE;
}
aAny = xPropSet->getPropertyValue(sIsVisible);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT, XML_DISPLAY, eDisplay);
}
// protect + protection key
aAny = xPropSet->getPropertyValue(sIsProtected);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT, XML_PROTECTED, XML_TRUE);
}
@@ -538,7 +538,7 @@ void XMLSectionExport::ExportRegularSectionStart(
sItem);
aAny = xPropSet->getPropertyValue(sIsAutomaticUpdate);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_OFFICE,
XML_AUTOMATIC_UPDATE, XML_TRUE);
@@ -772,7 +772,7 @@ void XMLSectionExport::ExportBaseIndexStart(
{
// protect + protection key
Any aAny = rPropertySet->getPropertyValue(sIsProtected);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT, XML_PROTECTED, XML_TRUE);
}
@@ -816,7 +816,7 @@ void XMLSectionExport::ExportBaseIndexSource(
{
// document or chapter index?
aAny = rPropertySet->getPropertyValue(sCreateFromChapter);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT,
XML_INDEX_SCOPE, XML_CHAPTER);
@@ -824,7 +824,7 @@ void XMLSectionExport::ExportBaseIndexSource(
// tab-stops relative to margin?
aAny = rPropertySet->getPropertyValue(sIsRelativeTabstops);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT,
XML_RELATIVE_TAB_STOP_POSITION,
@@ -925,7 +925,7 @@ void XMLSectionExport::ExportTableAndIllustrationIndexSourceAttributes(
{
// use caption
Any aAny = rPropertySet->getPropertyValue(sCreateFromLabels);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
GetExport().AddAttribute(XML_NAMESPACE_TEXT,
XML_USE_CAPTION, XML_FALSE);
@@ -1295,7 +1295,7 @@ void XMLSectionExport::ExportIndexTemplateElement(
case TOK_TPARAM_TAB_RIGHT_ALIGNED:
bRightAligned =
- *(sal_Bool *)rValues[i].Value.getValue();
+ *static_cast<sal_Bool const *>(rValues[i].Value.getValue());
break;
case TOK_TPARAM_TAB_POSITION:
@@ -1305,7 +1305,7 @@ void XMLSectionExport::ExportIndexTemplateElement(
// #i21237#
case TOK_TPARAM_TAB_WITH_TAB:
- bWithTabStop = *(sal_Bool *)rValues[i].Value.getValue();
+ bWithTabStop = *static_cast<sal_Bool const *>(rValues[i].Value.getValue());
bWithTabStopOK = true;
break;
@@ -1602,7 +1602,7 @@ void XMLSectionExport::ExportBoolean(
OSL_ENSURE(eAttributeName != XML_TOKEN_INVALID, "Need attribute name");
Any aAny = rPropSet->getPropertyValue(sPropertyName);
- bool bTmp = *(sal_Bool*)aAny.getValue();
+ bool bTmp = *static_cast<sal_Bool const *>(aAny.getValue());
// value = value ^ bInvert
// omit if value == default
@@ -1658,14 +1658,14 @@ void XMLSectionExport::ExportBibliographyConfiguration(SvXMLExport& rExport)
rExport.AddAttribute(XML_NAMESPACE_TEXT, XML_SUFFIX, sTmp);
aAny = xPropSet->getPropertyValue(sIsNumberEntries);
- if (*(sal_Bool*)aAny.getValue())
+ if (*static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_NUMBERED_ENTRIES, XML_TRUE);
}
aAny = xPropSet->getPropertyValue(sIsSortByPosition);
- if (! *(sal_Bool*)aAny.getValue())
+ if (! *static_cast<sal_Bool const *>(aAny.getValue()))
{
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_SORT_BY_POSITION, XML_FALSE);
@@ -1720,7 +1720,7 @@ void XMLSectionExport::ExportBibliographyConfiguration(SvXMLExport& rExport)
}
else if (rValue.Name == "IsSortAscending")
{
- bool bTmp = *(sal_Bool*)rValue.Value.getValue();
+ bool bTmp = *static_cast<sal_Bool const *>(rValue.Value.getValue());
rExport.AddAttribute(XML_NAMESPACE_TEXT,
XML_SORT_ASCENDING,
bTmp ? XML_TRUE : XML_FALSE);
@@ -1760,7 +1760,7 @@ bool XMLSectionExport::IsMuteSection(
{
Any aAny = xPropSet->getPropertyValue(sIsGlobalDocumentSection);
- if ( *(sal_Bool*)aAny.getValue() )
+ if ( *static_cast<sal_Bool const *>(aAny.getValue()) )
{
Reference<XDocumentIndex> xIndex;
if (! GetIndex(rSection, xIndex))
diff --git a/xmloff/source/text/XMLTextColumnsExport.cxx b/xmloff/source/text/XMLTextColumnsExport.cxx
index 1ced191..ee797e2 100644
--- a/xmloff/source/text/XMLTextColumnsExport.cxx
+++ b/xmloff/source/text/XMLTextColumnsExport.cxx
@@ -72,7 +72,7 @@ void XMLTextColumnsExport::exportXML( const Any& rAny )
if( xPropSet.is() )
{
Any aAny = xPropSet->getPropertyValue( sIsAutomatic );
- if ( *(sal_Bool*)aAny.getValue() )
+ if ( *static_cast<sal_Bool const *>(aAny.getValue()) )
{
aAny = xPropSet->getPropertyValue( sAutomaticDistance );
sal_Int32 nDistance = 0;
@@ -92,7 +92,7 @@ void XMLTextColumnsExport::exportXML( const Any& rAny )
if( xPropSet.is() )
{
Any aAny = xPropSet->getPropertyValue( sSeparatorLineIsOn );
- if( *(sal_Bool *)aAny.getValue() )
+ if( *static_cast<sal_Bool const *>(aAny.getValue()) )
{
// style:width
aAny = xPropSet->getPropertyValue( sSeparatorLineWidth );
diff --git a/xmloff/source/text/XMLTextHeaderFooterContext.cxx b/xmloff/source/text/XMLTextHeaderFooterContext.cxx
index 40ac808..f752e33 100644
--- a/xmloff/source/text/XMLTextHeaderFooterContext.cxx
+++ b/xmloff/source/text/XMLTextHeaderFooterContext.cxx
@@ -61,7 +61,7 @@ XMLTextHeaderFooterContext::XMLTextHeaderFooterContext( SvXMLImport& rImport, sa
Any aAny;
aAny = xPropSet->getPropertyValue( sOn );
- bool bOn = *(sal_Bool *)aAny.getValue();
+ bool bOn = *static_cast<sal_Bool const *>(aAny.getValue());
if( bOn )
{
@@ -131,7 +131,7 @@ SvXMLImportContext *XMLTextHeaderFooterContext::CreateChildContext(
else
{
aAny = xPropSet->getPropertyValue( sOn );
- sal_Bool bOn = *(sal_Bool *)aAny.getValue();
+ sal_Bool bOn = *static_cast<sal_Bool const *>(aAny.getValue());
if( !bOn )
{
@@ -147,7 +147,7 @@ SvXMLImportContext *XMLTextHeaderFooterContext::CreateChildContext(
// If a header or footer is not shared, share it now.
aAny = xPropSet->getPropertyValue( sShareContent );
- sal_Bool bShared = *(sal_Bool *)aAny.getValue();
+ sal_Bool bShared = *static_cast<sal_Bool const *>(aAny.getValue());
if( !bShared )
{
bShared = sal_True;
diff --git a/xmloff/source/text/XMLTextMasterPageContext.cxx b/xmloff/source/text/XMLTextMasterPageContext.cxx
index 36ea035..21eafe4 100644
--- a/xmloff/source/text/XMLTextMasterPageContext.cxx
+++ b/xmloff/source/text/XMLTextMasterPageContext.cxx
@@ -150,7 +150,7 @@ XMLTextMasterPageContext::XMLTextMasterPageContext( SvXMLImport& rImport,
if( !bNew && xPropSetInfo->hasPropertyByName( sIsPhysical ) )
{
aAny = xPropSet->getPropertyValue( sIsPhysical );
- bNew = !*(sal_Bool *)aAny.getValue();
+ bNew = !*static_cast<sal_Bool const *>(aAny.getValue());
}
SetNew( bNew );
diff --git a/xmloff/source/text/txtexppr.cxx b/xmloff/source/text/txtexppr.cxx
index 1300c3b..0dd5312 100644
--- a/xmloff/source/text/txtexppr.cxx
+++ b/xmloff/source/text/txtexppr.cxx
@@ -140,7 +140,7 @@ void XMLTextExportPropertySetMapper::handleSpecialItem(
{
case CTF_DROPCAPWHOLEWORD:
DBG_ASSERT( !bDropWholeWord, "drop whole word is set already!" );
- pThis->bDropWholeWord = *(sal_Bool *)rProperty.maValue.getValue();
+ pThis->bDropWholeWord = *static_cast<sal_Bool const *>(rProperty.maValue.getValue());
break;
case CTF_DROPCAPCHARSTYLE:
DBG_ASSERT( sDropCharStyle.isEmpty(), "drop char style is set already!" );
@@ -994,7 +994,7 @@ void XMLTextExportPropertySetMapper::ContextFilter(
}
if( pWrapContourModeState &&
(!pWrapContourState ||
- !*(sal_Bool *)pWrapContourState ->maValue.getValue() ) )
+ !*static_cast<sal_Bool const *>(pWrapContourState ->maValue.getValue()) ) )
pWrapContourModeState->mnIndex = -1;
}
@@ -1012,7 +1012,7 @@ void XMLTextExportPropertySetMapper::ContextFilter(
if( pHoriOrientState && pHoriOrientMirroredState )
{
if( pHoriOrientMirrorState &&
- *(sal_Bool *)pHoriOrientMirrorState->maValue.getValue() )
+ *static_cast<sal_Bool const *>(pHoriOrientMirrorState->maValue.getValue()) )
pHoriOrientState->mnIndex = -1;
else
pHoriOrientMirroredState->mnIndex = -1;
@@ -1088,7 +1088,7 @@ void XMLTextExportPropertySetMapper::ContextFilter(
if( pShapeHoriOrientState && pShapeHoriOrientMirroredState )
{
if( pShapeHoriOrientMirrorState &&
- *(sal_Bool *)pShapeHoriOrientMirrorState->maValue.getValue() )
+ *static_cast<sal_Bool const *>(pShapeHoriOrientMirrorState->maValue.getValue()) )
pShapeHoriOrientState->mnIndex = -1;
else
pShapeHoriOrientMirroredState->mnIndex = -1;
diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx
index aabd4be..13e3f21 100644
--- a/xmloff/source/text/txtflde.cxx
+++ b/xmloff/source/text/txtflde.cxx
@@ -2988,7 +2988,7 @@ enum XMLTokenEnum XMLTextFieldExport::MapPageNumberName(
enum XMLTokenEnum eName = XML_TOKEN_INVALID;
PageNumberType ePage;
Any aAny = xPropSet->getPropertyValue(sPropertySubType);
- ePage = *(PageNumberType*)aAny.getValue();
+ ePage = *static_cast<PageNumberType const *>(aAny.getValue());
switch (ePage)
{
@@ -3531,7 +3531,7 @@ inline bool GetBoolProperty(
const Reference<XPropertySet> & xPropSet)
{
Any aAny = xPropSet->getPropertyValue(sPropName);
- bool bBool = *(sal_Bool *)aAny.getValue();
+ bool bBool = *static_cast<sal_Bool const *>(aAny.getValue());
return bBool;
}
diff --git a/xmloff/source/text/txtftne.cxx b/xmloff/source/text/txtftne.cxx
index 4db45c9..4f8fcaf 100644
--- a/xmloff/source/text/txtftne.cxx
+++ b/xmloff/source/text/txtftne.cxx
@@ -317,7 +317,7 @@ void XMLTextParagraphExport::exportTextFootnoteConfigurationHelper(
aAny = rFootnoteConfig->getPropertyValue(
sPositionEndOfDoc);
GetExport().AddAttribute(XML_NAMESPACE_TEXT, XML_FOOTNOTES_POSITION,
- ( (*(sal_Bool *)aAny.getValue()) ?
+ ( (*static_cast<sal_Bool const *>(aAny.getValue())) ?
XML_DOCUMENT : XML_PAGE ) );
aAny = rFootnoteConfig->getPropertyValue(sFootnoteCounting);
diff --git a/xmloff/source/text/txtimppr.cxx b/xmloff/source/text/txtimppr.cxx
index ef38374..08cb395 100644
--- a/xmloff/source/text/txtimppr.cxx
+++ b/xmloff/source/text/txtimppr.cxx
@@ -656,7 +656,7 @@ void XMLTextImportPropertyMapper::finished(
// #i5775# don't overwrite %transparency with binary transparency
if( ( pBackTransparency != NULL ) && ( pBackTransparent != NULL ) )
{
- if( ! *(sal_Bool*)(pBackTransparent->maValue.getValue()) )
+ if( ! *static_cast<sal_Bool const *>(pBackTransparent->maValue.getValue()) )
pBackTransparent->mnIndex = -1;
}
diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 06562ee..025bb0b 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -511,13 +511,13 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily,
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "IsAutomatic" ) )
{
- bAdd = *(sal_Bool *)xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue();
+ bAdd = *static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue());
// Check on outline style (#i73361#)
if ( bAdd &&
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "NumberingIsOutline" ) )
{
- bAdd = !(*(sal_Bool *)xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue());
+ bAdd = !(*static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue()));
}
}
else
@@ -626,13 +626,13 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily,
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "IsAutomatic" ) )
{
- bAdd = *(sal_Bool *)xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue();
+ bAdd = *static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue());
// Check on outline style (#i73361#)
if ( bAdd &&
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "NumberingIsOutline" ) )
{
- bAdd = !(*(sal_Bool *)xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue());
+ bAdd = !(*static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue()));
}
}
else
@@ -1475,13 +1475,13 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
}
Any aAny = xAutoStyleFamilies->getByName( sName );
- Reference< XAutoStyleFamily > xAutoStyles = *(Reference<XAutoStyleFamily>*)aAny.getValue();
+ Reference< XAutoStyleFamily > xAutoStyles = *static_cast<Reference<XAutoStyleFamily> const *>(aAny.getValue());
Reference < XEnumeration > xAutoStylesEnum( xAutoStyles->createEnumeration() );
while ( xAutoStylesEnum->hasMoreElements() )
{
aAny = xAutoStylesEnum->nextElement();
- Reference< XAutoStyle > xAutoStyle = *(Reference<XAutoStyle>*)aAny.getValue();
+ Reference< XAutoStyle > xAutoStyle = *static_cast<Reference<XAutoStyle> const *>(aAny.getValue());
Reference < XPropertySet > xPSet( xAutoStyle, uno::UNO_QUERY );
Add( nFamily, xPSet, 0, true );
}
@@ -1498,7 +1498,7 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
while ( xTextFieldsEnum->hasMoreElements() )
{
Any aAny = xTextFieldsEnum->nextElement();
- Reference< XTextField > xTextField = *(Reference<XTextField>*)aAny.getValue();
+ Reference< XTextField > xTextField = *static_cast<Reference<XTextField> const *>(aAny.getValue());
exportTextField( xTextField, bAutoStyles, bIsProgress,
!xAutoStylesSupp.is() );
try
@@ -1576,7 +1576,7 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
for( sal_Int32 i = 0; i < nCount; ++i )
{
Any aAny = xSections->getByIndex( i );
- Reference< XTextSection > xSection = *(Reference<XTextSection>*)aAny.getValue();
+ Reference< XTextSection > xSection = *static_cast<Reference<XTextSection> const *>(aAny.getValue());
Reference < XPropertySet > xPSet( xSection, uno::UNO_QUERY );
Add( XML_STYLE_FAMILY_TEXT_SECTION, xPSet );
}
@@ -1594,7 +1594,7 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
for( sal_Int32 i = 0; i < nCount; ++i )
{
Any aAny = xTables->getByIndex( i );
- Reference< XTextTable > xTable = *(Reference<XTextTable>*)aAny.getValue();
+ Reference< XTextTable > xTable = *static_cast<Reference<XTextTable> const *>(aAny.getValue());
exportTable( xTable, true, true );
}
}
@@ -1624,13 +1624,13 @@ bool XMLTextParagraphExport::collectTextAutoStylesOptimized( bool bIsProgress )
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "IsAutomatic" ) )
{
- bAdd = *(sal_Bool *)xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue();
+ bAdd = *static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "IsAutomatic" ).getValue());
// Check on outline style (#i73361#)
if ( bAdd &&
xNumPropSet->getPropertySetInfo()
->hasPropertyByName( "NumberingIsOutline" ) )
{
- bAdd = !(*(sal_Bool *)xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue());
+ bAdd = !(*static_cast<sal_Bool const *>(xNumPropSet->getPropertyValue( "NumberingIsOutline" ).getValue()));
}
}
else
@@ -2517,13 +2517,13 @@ void XMLTextParagraphExport::exportTextMark(
// start, end, or point-reference?
sal_Int8 nElement;
- if( *(sal_Bool *)rPropSet->getPropertyValue(sIsCollapsed).getValue() )
+ if( *static_cast<sal_Bool const *>(rPropSet->getPropertyValue(sIsCollapsed).getValue()) )
{
nElement = 0;
}
else
{
- nElement = *(sal_Bool *)rPropSet->getPropertyValue(sIsStart).getValue() ? 1 : 2;
+ nElement = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue(sIsStart).getValue()) ? 1 : 2;
}
// bookmark, bookmark-start: xml:id and RDFa for RDF metadata
@@ -2684,7 +2684,7 @@ XMLShapeExportFlags XMLTextParagraphExport::addTextFrameAttributes(
bool bSyncWidth = false;
if( xPropSetInfo->hasPropertyByName( sIsSyncWidthToHeight ) )
{
- bSyncWidth = *(sal_Bool *)rPropSet->getPropertyValue( sIsSyncWidthToHeight ).getValue();
+ bSyncWidth = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue( sIsSyncWidthToHeight ).getValue());
if( bSyncWidth )
GetExport().AddAttribute( XML_NAMESPACE_STYLE, XML_REL_WIDTH,
XML_SCALE );
@@ -2712,7 +2712,7 @@ XMLShapeExportFlags XMLTextParagraphExport::addTextFrameAttributes(
bool bSyncHeight = false;
if( xPropSetInfo->hasPropertyByName( sIsSyncHeightToWidth ) )
{
- bSyncHeight = *(sal_Bool *)rPropSet->getPropertyValue( sIsSyncHeightToWidth ).getValue();
+ bSyncHeight = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue( sIsSyncHeightToWidth ).getValue());
}
sal_Int16 nRelHeight = 0;
if( !bSyncHeight && xPropSetInfo->hasPropertyByName( sRelativeHeight ) )
@@ -2979,7 +2979,7 @@ void XMLTextParagraphExport::exportContour(
if( rPropSetInfo->hasPropertyByName( sIsPixelContour ) )
{
- bPixel = *(sal_Bool *)rPropSet->getPropertyValue( sIsPixelContour ).getValue();
+ bPixel = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue( sIsPixelContour ).getValue());
}
// svg: width
@@ -3041,8 +3041,8 @@ void XMLTextParagraphExport::exportContour(
if( rPropSetInfo->hasPropertyByName( sIsAutomaticContour ) )
{
- bool bTmp = *(sal_Bool *)rPropSet->getPropertyValue(
- sIsAutomaticContour ).getValue();
+ bool bTmp = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue(
+ sIsAutomaticContour ).getValue());
GetExport().AddAttribute( XML_NAMESPACE_DRAW,
XML_RECREATE_ON_EDIT, bTmp ? XML_TRUE : XML_FALSE );
}
@@ -3263,7 +3263,7 @@ bool XMLTextParagraphExport::addHyperlinkAttributes(
&& ( !rPropState.is()
|| PropertyState_DIRECT_VALUE == rPropState->getPropertyState( sServerMap ) ) )
{
- bServerMap = *(sal_Bool *) rPropSet->getPropertyValue( sServerMap ).getValue();
+ bServerMap = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue( sServerMap ).getValue());
if ( bServerMap )
bExport = true;
}
@@ -3640,11 +3640,11 @@ void XMLTextParagraphExport::exportRuby(
bool bAutoStyles )
{
// early out: a collapsed ruby makes no sense
- if (*(sal_Bool*)rPropSet->getPropertyValue(sIsCollapsed).getValue())
+ if (*static_cast<sal_Bool const *>(rPropSet->getPropertyValue(sIsCollapsed).getValue()))
return;
// start value ?
- bool bStart = (*(sal_Bool*)rPropSet->getPropertyValue(sIsStart).getValue());
+ bool bStart = *static_cast<sal_Bool const *>(rPropSet->getPropertyValue(sIsStart).getValue());
if (bAutoStyles)
{
diff --git a/xmloff/source/text/txtprhdl.cxx b/xmloff/source/text/txtprhdl.cxx
index 78d8215..35db468 100644
--- a/xmloff/source/text/txtprhdl.cxx
+++ b/xmloff/source/text/txtprhdl.cxx
@@ -351,7 +351,7 @@ bool XMLOpaquePropHdl_Impl::exportXML(
const Any& rValue,
const SvXMLUnitConverter& ) const
{
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
rStrExpValue = GetXMLToken( XML_FOREGROUND );
else
rStrExpValue = GetXMLToken( XML_BACKGROUND );
@@ -401,7 +401,7 @@ bool XMLContourModePropHdl_Impl::exportXML(
const Any& rValue,
const SvXMLUnitConverter& ) const
{
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
rStrExpValue = GetXMLToken( XML_OUTSIDE );
else
rStrExpValue = GetXMLToken( XML_FULL );
@@ -454,7 +454,7 @@ bool XMLParagraphOnlyPropHdl_Impl::exportXML(
const Any& rValue,
const SvXMLUnitConverter& ) const
{
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
rStrExpValue = GetXMLToken( XML_1 );
else
rStrExpValue = GetXMLToken( XML_NO_LIMIT );
@@ -580,7 +580,7 @@ bool XMLFrameProtectPropHdl_Impl::exportXML(
const Any& rValue,
const SvXMLUnitConverter& ) const
{
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
{
if( rStrExpValue.isEmpty() ||
IsXMLToken( rStrExpValue, XML_NONE ) )
@@ -823,7 +823,7 @@ bool XMLGrfMirrorPropHdl_Impl::exportXML(
const Any& rValue,
const SvXMLUnitConverter& ) const
{
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
{
if( rStrExpValue.isEmpty() ||
IsXMLToken( rStrExpValue, XML_NONE ) )
@@ -1099,7 +1099,7 @@ bool XMLTextSyncWidthHeightPropHdl_Impl::exportXML(
const SvXMLUnitConverter& ) const
{
bool bRet = false;
- if( *(sal_Bool *)rValue.getValue() )
+ if( *static_cast<sal_Bool const *>(rValue.getValue()) )
{
rStrExpValue = sValue;
bRet = true;
diff --git a/xmloff/source/text/txtstyli.cxx b/xmloff/source/text/txtstyli.cxx
index 5167c6b..2d25f61 100644
--- a/xmloff/source/text/txtstyli.cxx
+++ b/xmloff/source/text/txtstyli.cxx
@@ -499,7 +499,7 @@ void XMLTextStyleContext::FillPropertySet(
if ( nIndex != -1 )
{
Any& rAny = GetProperties()[nIndex].maValue;
- bool bVal = *(sal_Bool*)rAny.getValue();
+ bool bVal = *static_cast<sal_Bool const *>(rAny.getValue());
bHasCombinedCharactersLetter = bVal;
}
commit 1bfdea75d23d79e8b0d2d7c1548d716d0ca27488
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:34 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: Ie42bd7a48391615ea8f48b24d6bfe2bbebb31a0b
diff --git a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
index 6deea99..6c86d78 100644
--- a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
+++ b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
@@ -783,7 +783,7 @@ helpOpen(const char * URI) {
static int
helpRead(void * context, char * buffer, int len) {
- Reference< XInputStream > *pRef = (Reference< XInputStream >*)context;
+ Reference< XInputStream > *pRef = static_cast<Reference< XInputStream >*>(context);
Sequence< sal_Int8 > aSeq;
len = (*pRef)->readBytes( aSeq,len);
@@ -800,7 +800,7 @@ zipRead(void * context, char * buffer, int len) {
static int
fileRead(void * context, char * buffer, int len) {
int nRead = 0;
- osl::File *pFile = (osl::File*)context;
+ osl::File *pFile = static_cast<osl::File*>(context);
if (pFile)
{
sal_uInt64 uRead = 0;
@@ -812,14 +812,14 @@ fileRead(void * context, char * buffer, int len) {
static int
uriClose(void * context) {
- Reference< XInputStream > *pRef = (Reference< XInputStream >*)context;
+ Reference< XInputStream > *pRef = static_cast<Reference< XInputStream >*>(context);
delete pRef;
return 0;
}
static int
fileClose(void * context) {
- osl::File *pFile = (osl::File*)context;
+ osl::File *pFile = static_cast<osl::File*>(context);
if (pFile)
{
pFile->close();
commit 18804c92e10c7f4572b9698b1cf6dc86db8d6f32
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sat Mar 28 19:08:26 2015 +0100
Clean up C-style casts from pointers to void
Change-Id: Iad602cece6e328c7f5d5f36adb294c97b152ade3
diff --git a/include/vcl/cmdevt.hxx b/include/vcl/cmdevt.hxx
index 851c5d9..ad6a9dc 100644
--- a/include/vcl/cmdevt.hxx
+++ b/include/vcl/cmdevt.hxx
@@ -447,7 +447,7 @@ inline CommandEvent::CommandEvent( const Point& rMousePos,
inline const CommandExtTextInputData* CommandEvent::GetExtTextInputData() const
{
if ( mnCommand == COMMAND_EXTTEXTINPUT )
- return (const CommandExtTextInputData*)mpData;
+ return static_cast<const CommandExtTextInputData*>(mpData);
else
return NULL;
}
@@ -455,7 +455,7 @@ inline const CommandExtTextInputData* CommandEvent::GetExtTextInputData() const
inline const CommandInputContextData* CommandEvent::GetInputContextChangeData() const
{
if ( mnCommand == COMMAND_INPUTCONTEXTCHANGE )
- return (const CommandInputContextData*)mpData;
+ return static_cast<const CommandInputContextData*>(mpData);
else
return NULL;
}
@@ -463,7 +463,7 @@ inline const CommandInputContextData* CommandEvent::GetInputContextChangeData()
inline const CommandWheelData* CommandEvent::GetWheelData() const
{
if ( mnCommand == COMMAND_WHEEL )
- return (const CommandWheelData*)mpData;
+ return static_cast<const CommandWheelData*>(mpData);
else
return NULL;
}
@@ -471,7 +471,7 @@ inline const CommandWheelData* CommandEvent::GetWheelData() const
inline const CommandScrollData* CommandEvent::GetAutoScrollData() const
{
if ( mnCommand == COMMAND_AUTOSCROLL )
- return (const CommandScrollData*)mpData;
+ return static_cast<const CommandScrollData*>(mpData);
else
return NULL;
}
@@ -479,7 +479,7 @@ inline const CommandScrollData* CommandEvent::GetAutoScrollData() const
inline const CommandModKeyData* CommandEvent::GetModKeyData() const
{
if( mnCommand == COMMAND_MODKEYCHANGE )
- return (const CommandModKeyData*)mpData;
+ return static_cast<const CommandModKeyData*>(mpData);
else
return NULL;
}
@@ -487,7 +487,7 @@ inline const CommandModKeyData* CommandEvent::GetModKeyData() const
inline const CommandDialogData* CommandEvent::GetDialogData() const
{
if( mnCommand == COMMAND_SHOWDIALOG )
- return (const CommandDialogData*)mpData;
+ return static_cast<const CommandDialogData*>(mpData);
else
return NULL;
}
@@ -495,7 +495,7 @@ inline const CommandDialogData* CommandEvent::GetDialogData() const
inline CommandMediaData* CommandEvent::GetMediaData() const
{
if( mnCommand == COMMAND_MEDIA )
- return (CommandMediaData*)(mpData);
+ return static_cast<CommandMediaData*>(mpData);
else
return NULL;
}
@@ -503,7 +503,7 @@ inline CommandMediaData* CommandEvent::GetMediaData() const
inline const CommandSelectionChangeData* CommandEvent::GetSelectionChangeData() const
{
if( mnCommand == COMMAND_SELECTIONCHANGE )
- return (const CommandSelectionChangeData*)mpData;
+ return static_cast<const CommandSelectionChangeData*>(mpData);
else
return NULL;
}
@@ -511,7 +511,7 @@ inline const CommandSelectionChangeData* CommandEvent::GetSelectionChangeData()
inline const CommandSwipeData* CommandEvent::GetSwipeData() const
{
if( mnCommand == COMMAND_SWIPE )
- return (const CommandSwipeData*)(mpData);
+ return static_cast<const CommandSwipeData*>(mpData);
else
return NULL;
}
@@ -519,7 +519,7 @@ inline const CommandSwipeData* CommandEvent::GetSwipeData() const
inline const CommandLongPressData* CommandEvent::GetLongPressData() const
{
if( mnCommand == COMMAND_LONGPRESS )
- return (const CommandLongPressData*)(mpData);
+ return static_cast<const CommandLongPressData*>(mpData);
else
return NULL;
}
diff --git a/include/vcl/event.hxx b/include/vcl/event.hxx
index 990a7ec..8ad67fb 100644
--- a/include/vcl/event.hxx
+++ b/include/vcl/event.hxx
@@ -455,7 +455,7 @@ inline NotifyEvent::NotifyEvent( MouseNotifyEvent nEventType, vcl::Window* pWind
inline const KeyEvent* NotifyEvent::GetKeyEvent() const
{
if ( (mnEventType == MouseNotifyEvent::KEYINPUT) || (mnEventType == MouseNotifyEvent::KEYUP) )
- return (const KeyEvent*)mpData;
+ return static_cast<const KeyEvent*>(mpData);
else
return NULL;
}
@@ -463,7 +463,7 @@ inline const KeyEvent* NotifyEvent::GetKeyEvent() const
inline const MouseEvent* NotifyEvent::GetMouseEvent() const
{
if ( (mnEventType >= MouseNotifyEvent::MOUSEBUTTONDOWN) && (mnEventType <= MouseNotifyEvent::MOUSEMOVE) )
- return (const MouseEvent*)mpData;
+ return static_cast<const MouseEvent*>(mpData);
else
return NULL;
}
@@ -471,7 +471,7 @@ inline const MouseEvent* NotifyEvent::GetMouseEvent() const
inline const CommandEvent* NotifyEvent::GetCommandEvent() const
{
if ( mnEventType == MouseNotifyEvent::COMMAND )
- return (const CommandEvent*)mpData;
+ return static_cast<const CommandEvent*>(mpData);
else
return NULL;
}
@@ -529,7 +529,7 @@ inline DataChangedEvent::DataChangedEvent( DataChangedEventType nType,
inline const AllSettings* DataChangedEvent::GetOldSettings() const
{
if ( mnType == DataChangedEventType::SETTINGS )
- return (const AllSettings*)mpData;
+ return static_cast<const AllSettings*>(mpData);
else
return NULL;
}
diff --git a/include/vcl/opengl/OpenGLContext.hxx b/include/vcl/opengl/OpenGLContext.hxx
index 0e98da6..8be646e 100644
--- a/include/vcl/opengl/OpenGLContext.hxx
+++ b/include/vcl/opengl/OpenGLContext.hxx
@@ -81,7 +81,7 @@ struct GLWindow
return GL_FALSE;
}
- deleteThis=lookHere=(char*)malloc(strlen(reinterpret_cast<const char*>(extString))+1);
+ deleteThis=lookHere=static_cast<char*>(malloc(strlen(reinterpret_cast<const char*>(extString))+1));
if (lookHere==NULL)
{
return GL_FALSE;
diff --git a/vcl/generic/fontmanager/fontconfig.cxx b/vcl/generic/fontmanager/fontconfig.cxx
index 2a354cc..f872164 100644
--- a/vcl/generic/fontmanager/fontconfig.cxx
+++ b/vcl/generic/fontmanager/fontconfig.cxx
@@ -919,7 +919,7 @@ IMPL_LINK_NOARG(PrintFontManager, autoInstallFontLangSupport)
return -1;
}
- gchar **fonts = (gchar**)g_malloc((m_aCurrentRequests.size() + 1) * sizeof(gchar*));
+ gchar **fonts = static_cast<gchar**>(g_malloc((m_aCurrentRequests.size() + 1) * sizeof(gchar*)));
gchar **font = fonts;
for (std::vector<OString>::const_iterator aI = m_aCurrentRequests.begin(); aI != m_aCurrentRequests.end(); ++aI)
*font++ = const_cast<gchar*>(aI->getStr());
@@ -1088,7 +1088,7 @@ bool PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissi
// update rMissingCodes by removing resolved unicodes
if( !rMissingCodes.isEmpty() )
{
- sal_uInt32* pRemainingCodes = (sal_uInt32*)alloca( rMissingCodes.getLength() * sizeof(sal_uInt32) );
+ sal_uInt32* pRemainingCodes = static_cast<sal_uInt32*>(alloca( rMissingCodes.getLength() * sizeof(sal_uInt32) ));
int nRemainingLen = 0;
FcCharSet* unicodes;
if (!FcPatternGetCharSet(pSet->fonts[0], FC_CHARSET, 0, &unicodes))
diff --git a/vcl/generic/fontmanager/fontmanager.cxx b/vcl/generic/fontmanager/fontmanager.cxx
index c98ccc5..f2b67d1 100644
--- a/vcl/generic/fontmanager/fontmanager.cxx
+++ b/vcl/generic/fontmanager/fontmanager.cxx
@@ -472,7 +472,7 @@ bool PrintFontManager::PrintFont::readAfmMetrics( MultiAtomProvider* pProvider,
// first transform the character codes to unicode
// note: this only works with single byte encodings
- sal_Unicode* pUnicodes = (sal_Unicode*)alloca( pInfo->numOfChars * sizeof(sal_Unicode));
+ sal_Unicode* pUnicodes = static_cast<sal_Unicode*>(alloca( pInfo->numOfChars * sizeof(sal_Unicode)));
CharMetricInfo* pChar = pInfo->cmi;
int i;
@@ -979,7 +979,7 @@ std::vector<fontID> PrintFontManager::findFontFileIDs( int nDirID, const OString
OUString PrintFontManager::convertTrueTypeName( void* pRecord ) const
{
- NameRecord* pNameRecord = (NameRecord*)pRecord;
+ NameRecord* pNameRecord = static_cast<NameRecord*>(pRecord);
OUString aValue;
if(
( pNameRecord->platformID == 3 && ( pNameRecord->encodingID == 0 || pNameRecord->encodingID == 1 ) ) // MS, Unicode
@@ -1128,7 +1128,7 @@ void PrintFontManager::analyzeTrueTypeFamilyName( void* pTTFont, ::std::list< OU
::std::set< OUString > aSet;
NameRecord* pNameRecords = NULL;
- int nNameRecords = GetTTNameRecords( (TrueTypeFont*)pTTFont, &pNameRecords );
+ int nNameRecords = GetTTNameRecords( static_cast<TrueTypeFont*>(pTTFont), &pNameRecords );
if( nNameRecords && pNameRecords )
{
LanguageTag aSystem("");
diff --git a/vcl/generic/fontmanager/parseAFM.cxx b/vcl/generic/fontmanager/parseAFM.cxx
index e3a3170..267ef1c 100644
--- a/vcl/generic/fontmanager/parseAFM.cxx
+++ b/vcl/generic/fontmanager/parseAFM.cxx
@@ -120,7 +120,7 @@ FileInputStream::FileInputStream(const char* pFilename)
struct stat aStat;
if (!fstat(fileno(fp), &aStat) && S_ISREG(aStat.st_mode) && aStat.st_size > 0)
{
- m_pMemory = (char*)rtl_allocateMemory( aStat.st_size );
+ m_pMemory = static_cast<char*>(rtl_allocateMemory( aStat.st_size ));
m_nLen = (unsigned int)fread( m_pMemory, 1, aStat.st_size, fp );
}
fclose( fp );
@@ -666,7 +666,7 @@ reallocFontMetrics( void **pp_fontmetrics, int *p_oldcount, int n_newcount, unsi
if (*p_oldcount == n_newcount)
return ok;
- p_tmpmetrics = (char*)realloc(*pp_fontmetrics, n_newcount * n_size);
+ p_tmpmetrics = static_cast<char*>(realloc(*pp_fontmetrics, n_newcount * n_size));
if (p_tmpmetrics == NULL)
return storageProblem;
@@ -816,7 +816,7 @@ static int parseCharMetrics( FileInputStream* fp, FontInfo* fi)
tail = &(node->next);
}
- *tail = (Ligature *) calloc(1, sizeof(Ligature));
+ *tail = static_cast<Ligature *>(calloc(1, sizeof(Ligature)));
if ((keyword = token(fp,tokenlen)) != NULL)
(*tail)->succ = (char *)strdup(keyword);
if ((keyword = token(fp,tokenlen)) != NULL)
@@ -1169,8 +1169,8 @@ static int parseCompCharData( FileInputStream* fp, FontInfo* fi)
fi->ccd[pos].ccName = strdup( keyword );
if ((keyword = token(fp,tokenlen)) != NULL)
fi->ccd[pos].numOfPieces = atoi(keyword);
- fi->ccd[pos].pieces = (Pcc *)
- calloc(fi->ccd[pos].numOfPieces, sizeof(Pcc));
+ fi->ccd[pos].pieces = static_cast<Pcc *>(
+ calloc(fi->ccd[pos].numOfPieces, sizeof(Pcc)));
j = 0;
ccount++;
}
@@ -1252,12 +1252,12 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
char *keyword; /* used to store a token */
- (*fi) = (FontInfo *) calloc(1, sizeof(FontInfo));
+ (*fi) = static_cast<FontInfo *>(calloc(1, sizeof(FontInfo)));
if ((*fi) == NULL) { error = storageProblem; return error; }
if (flags & P_G)
{
- (*fi)->gfi = (GlobalFontInfo *) calloc(1, sizeof(GlobalFontInfo));
+ (*fi)->gfi = static_cast<GlobalFontInfo *>(calloc(1, sizeof(GlobalFontInfo)));
if ((*fi)->gfi == NULL) { error = storageProblem; return error; }
}
@@ -1281,8 +1281,8 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
(*fi)->numOfChars = atoi(keyword);
if (flags & (P_M ^ P_W))
{
- (*fi)->cmi = (CharMetricInfo *)
- calloc((*fi)->numOfChars, sizeof(CharMetricInfo));
+ (*fi)->cmi = static_cast<CharMetricInfo *>(
+ calloc((*fi)->numOfChars, sizeof(CharMetricInfo)));
if ((*fi)->cmi == NULL) { error = storageProblem; return error; }
code = parseCharMetrics(&aFile, *fi);
}
@@ -1290,7 +1290,7 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
{
if (flags & P_W)
{
- (*fi)->cwi = (int *) calloc(256, sizeof(int));
+ (*fi)->cwi = static_cast<int *>(calloc(256, sizeof(int)));
if ((*fi)->cwi == NULL)
{
error = storageProblem;
@@ -1331,8 +1331,8 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
if ((flags & P_T) && keyword)
{
(*fi)->numOfTracks = atoi(keyword);
- (*fi)->tkd = (TrackKernData *)
- calloc((*fi)->numOfTracks, sizeof(TrackKernData));
+ (*fi)->tkd = static_cast<TrackKernData *>(
+ calloc((*fi)->numOfTracks, sizeof(TrackKernData)));
if ((*fi)->tkd == NULL)
{
error = storageProblem;
@@ -1346,8 +1346,8 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
if ((flags & P_P) && keyword)
{
(*fi)->numOfPairs = atoi(keyword);
- (*fi)->pkd = (PairKernData *)
- calloc((*fi)->numOfPairs, sizeof(PairKernData));
+ (*fi)->pkd = static_cast<PairKernData *>(
+ calloc((*fi)->numOfPairs, sizeof(PairKernData)));
if ((*fi)->pkd == NULL)
{
error = storageProblem;
@@ -1361,8 +1361,8 @@ int parseFile( const char* pFilename, FontInfo** fi, FLAGS flags)
if ((flags & P_C) && keyword)
{
(*fi)->numOfComps = atoi(keyword);
- (*fi)->ccd = (CompCharData *)
- calloc((*fi)->numOfComps, sizeof(CompCharData));
+ (*fi)->ccd = static_cast<CompCharData *>(
+ calloc((*fi)->numOfComps, sizeof(CompCharData)));
if ((*fi)->ccd == NULL)
{
error = storageProblem;
diff --git a/vcl/generic/glyphs/gcach_ftyp.cxx b/vcl/generic/glyphs/gcach_ftyp.cxx
index 887b5f4..93a79b1 100644
--- a/vcl/generic/glyphs/gcach_ftyp.cxx
+++ b/vcl/generic/glyphs/gcach_ftyp.cxx
@@ -169,8 +169,8 @@ bool FtFontFile::Map()
return false;
}
mnFileSize = aStat.st_size;
- mpFileMap = (unsigned char*)
- mmap( NULL, mnFileSize, PROT_READ, MAP_SHARED, nFile, 0 );
+ mpFileMap = static_cast<unsigned char*>(
+ mmap( NULL, mnFileSize, PROT_READ, MAP_SHARED, nFile, 0 ));
if( mpFileMap == MAP_FAILED )
mpFileMap = NULL;
close( nFile );
@@ -548,7 +548,7 @@ ServerFont::ServerFont( const FontSelectPattern& rFSD, FtFontInfo* pFI )
//static const int TT_CODEPAGE_RANGE_950 = (1L << 20); // Chinese: Traditional
//static const int TT_CODEPAGE_RANGE_1361 = (1L << 21); // Korean Johab
static const int TT_CODEPAGE_RANGES1_CJKT = 0x3F0000; // all of the above
- const TT_OS2* pOs2 = (const TT_OS2*)FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 );
+ const TT_OS2* pOs2 = static_cast<const TT_OS2*>(FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 ));
if ((pOs2) && (pOs2->ulCodePageRange1 & TT_CODEPAGE_RANGES1_CJKT )
&& rFSD.mnHeight < 20)
mbUseGamma = true;
@@ -652,7 +652,7 @@ void ServerFont::FetchFontMetric( ImplFontMetricData& rTo, long& rFactor ) const
rFactor = 0x100;
- const TT_OS2* pOS2 = (const TT_OS2*)FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 );
+ const TT_OS2* pOS2 = static_cast<const TT_OS2*>(FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 ));
const double fScale = (double)GetFontSelData().mnHeight / maFaceFT->units_per_EM;
rTo.mnAscent = 0;
@@ -676,7 +676,7 @@ void ServerFont::FetchFontMetric( ImplFontMetricData& rTo, long& rFactor ) const
}
else
{
- const TT_HoriHeader* pHHea = (const TT_HoriHeader*)FT_Get_Sfnt_Table(maFaceFT, ft_sfnt_hhea);
+ const TT_HoriHeader* pHHea = static_cast<const TT_HoriHeader*>(FT_Get_Sfnt_Table(maFaceFT, ft_sfnt_hhea));
if (pHHea)
{
rTo.mnAscent = pHHea->Ascender * fScale + 0.5;
diff --git a/vcl/generic/glyphs/gcach_layout.cxx b/vcl/generic/glyphs/gcach_layout.cxx
index 8e9deeb..94486a1 100644
--- a/vcl/generic/glyphs/gcach_layout.cxx
+++ b/vcl/generic/glyphs/gcach_layout.cxx
@@ -126,7 +126,7 @@ static hb_blob_t *getFontTable(hb_face_t* /*face*/, hb_tag_t nTableTag, void* pU
pTagName[3] = (char)(nTableTag);
pTagName[4] = 0;
- ServerFont* pFont = (ServerFont*) pUserData;
+ ServerFont* pFont = static_cast<ServerFont*>(pUserData);
SAL_INFO("vcl.harfbuzz", "getFontTable(" << pFont << ", " << pTagName << ")");
@@ -145,7 +145,7 @@ static hb_bool_t getFontGlyph(hb_font_t* /*font*/, void* pFontData,
hb_codepoint_t* nGlyphIndex,
void* /*pUserData*/)
{
- ServerFont* pFont = (ServerFont*) pFontData;
+ ServerFont* pFont = static_cast<ServerFont*>(pFontData);
*nGlyphIndex = pFont->GetRawGlyphIndex(ch, vs);
return *nGlyphIndex != 0;
@@ -155,7 +155,7 @@ static hb_position_t getGlyphAdvanceH(hb_font_t* /*font*/, void* pFontData,
hb_codepoint_t nGlyphIndex,
void* /*pUserData*/)
{
- ServerFont* pFont = (ServerFont*) pFontData;
+ ServerFont* pFont = static_cast<ServerFont*>(pFontData);
const GlyphMetric& rGM = pFont->GetGlyphMetric(nGlyphIndex);
return rGM.GetCharWidth() << 6;
}
@@ -192,7 +192,7 @@ static hb_position_t getGlyphKerningH(hb_font_t* /*font*/, void* pFontData,
{
// This callback is for old style 'kern' table, GPOS kerning is handled by HarfBuzz directly
- ServerFont* pFont = (ServerFont*) pFontData;
+ ServerFont* pFont = static_cast<ServerFont*>(pFontData);
FT_Face aFace = pFont->GetFtFace();
SAL_INFO("vcl.harfbuzz", "getGlyphKerningH(" << pFont << ", " << nGlyphIndex1 << ", " << nGlyphIndex2 << ")");
@@ -223,7 +223,7 @@ static hb_bool_t getGlyphExtents(hb_font_t* /*font*/, void* pFontData,
hb_glyph_extents_t* pExtents,
void* /*pUserData*/)
{
- ServerFont* pFont = (ServerFont*) pFontData;
+ ServerFont* pFont = static_cast<ServerFont*>(pFontData);
FT_Face aFace = pFont->GetFtFace();
SAL_INFO("vcl.harfbuzz", "getGlyphExtents(" << pFont << ", " << nGlyphIndex << ")");
@@ -247,7 +247,7 @@ static hb_bool_t getGlyphContourPoint(hb_font_t* /*font*/, void* pFontData,
void* /*pUserData*/)
{
bool ret = false;
- ServerFont* pFont = (ServerFont*) pFontData;
+ ServerFont* pFont = static_cast<ServerFont*>(pFontData);
FT_Face aFace = pFont->GetFtFace();
SAL_INFO("vcl.harfbuzz", "getGlyphContourPoint(" << pFont << ", " << nGlyphIndex << ", " << nPointIndex << ")");
diff --git a/vcl/generic/print/common_gfx.cxx b/vcl/generic/print/common_gfx.cxx
index cc7c4d9..769bb98 100644
--- a/vcl/generic/print/common_gfx.cxx
+++ b/vcl/generic/print/common_gfx.cxx
@@ -1219,7 +1219,7 @@ PrinterGfx::DrawEPS( const Rectangle& rBoundingBox, void* pPtr, sal_uInt32 nSize
bSuccess = nOutLength == nSize;
// corresponding EndDocument
- if( ((char*)pPtr)[ nSize-1 ] != '\n' )
+ if( static_cast<char*>(pPtr)[ nSize-1 ] != '\n' )
WritePS( mpPageBody, "\n" );
WritePS( mpPageBody, "%%EndDocument\n" );
diff --git a/vcl/generic/print/genprnpsp.cxx b/vcl/generic/print/genprnpsp.cxx
index 0eb6337..7a0ab922 100644
--- a/vcl/generic/print/genprnpsp.cxx
+++ b/vcl/generic/print/genprnpsp.cxx
@@ -232,7 +232,7 @@ static void copyJobDataToJobSetup( ImplJobSetup* pJobSetup, JobData& rData )
if( rData.getStreamBuffer( pBuffer, nBytes ) )
{
pJobSetup->mnDriverDataLen = nBytes;
- pJobSetup->mpDriverData = (sal_uInt8*)pBuffer;
+ pJobSetup->mpDriverData = static_cast<sal_uInt8*>(pBuffer);
}
else
{
@@ -563,7 +563,7 @@ bool PspSalInfoPrinter::Setup( SalFrame* pFrame, ImplJobSetup* pJobSetup )
void* pBuffer = NULL;
aInfo.getStreamBuffer( pBuffer, nBytes );
pJobSetup->mnDriverDataLen = nBytes;
- pJobSetup->mpDriverData = (sal_uInt8*)pBuffer;
+ pJobSetup->mpDriverData = static_cast<sal_uInt8*>(pBuffer);
// copy everything to job setup
copyJobDataToJobSetup( pJobSetup, aInfo );
diff --git a/vcl/generic/print/genpspgraphics.cxx b/vcl/generic/print/genpspgraphics.cxx
index af73d8a..d121ba6 100644
--- a/vcl/generic/print/genpspgraphics.cxx
+++ b/vcl/generic/print/genpspgraphics.cxx
@@ -1248,7 +1248,7 @@ void GenPspGraphics::DoFreeEmbedFontData( const void* pData, long nLen )
{
#if defined( UNX )
if( pData )
- munmap( (char*)pData, nLen );
+ munmap( const_cast<void *>(pData), nLen );
#else
(void)nLen;
rtl_freeMemory( (void *)pData );
@@ -1332,7 +1332,7 @@ const void* GenPspGraphics::DoGetEmbedFontData( psp::fontID aFont, const sal_Ucs
rInfo.m_nFontType = FontSubsetInfo::SFNT_TTF;
break;
case psp::fonttype::Type1: {
- const bool bPFA = ((*(unsigned char*)pFile) < 0x80);
+ const bool bPFA = *static_cast<unsigned char*>(pFile) < 0x80;
rInfo.m_nFontType = bPFA ? FontSubsetInfo::TYPE1_PFA : FontSubsetInfo::TYPE1_PFB;
}
break;
diff --git a/vcl/generic/print/glyphset.cxx b/vcl/generic/print/glyphset.cxx
index 3ac8d8d..37bd752 100644
--- a/vcl/generic/print/glyphset.cxx
+++ b/vcl/generic/print/glyphset.cxx
@@ -448,8 +448,8 @@ void GlyphSet::DrawGlyphs(
const sal_Int32* pDeltaArray,
const bool bUseGlyphs)
{
- unsigned char *pGlyphID = (unsigned char*)alloca (nLen * sizeof(unsigned char));
- sal_Int32 *pGlyphSetID = (sal_Int32*)alloca (nLen * sizeof(sal_Int32));
+ unsigned char *pGlyphID = static_cast<unsigned char*>(alloca (nLen * sizeof(unsigned char)));
+ sal_Int32 *pGlyphSetID = static_cast<sal_Int32*>(alloca (nLen * sizeof(sal_Int32)));
std::set< sal_Int32 > aGlyphSet;
// convert unicode to font glyph id and font subset
@@ -464,8 +464,8 @@ void GlyphSet::DrawGlyphs(
// loop over all glyph sets to detect substrings that can be xshown together
// without changing the postscript font
- sal_Int32 *pDeltaSubset = (sal_Int32*)alloca (nLen * sizeof(sal_Int32));
- unsigned char *pGlyphSubset = (unsigned char*)alloca (nLen * sizeof(unsigned char));
+ sal_Int32 *pDeltaSubset = static_cast<sal_Int32*>(alloca (nLen * sizeof(sal_Int32)));
+ unsigned char *pGlyphSubset = static_cast<unsigned char*>(alloca (nLen * sizeof(unsigned char)));
std::set< sal_Int32 >::iterator aSet;
for (aSet = aGlyphSet.begin(); aSet != aGlyphSet.end(); ++aSet)
@@ -545,8 +545,8 @@ GlyphSet::ImplDrawText (PrinterGfx &rGfx, const Point& rPoint,
}
int nChar;
- unsigned char *pGlyphID = (unsigned char*)alloca (nLen * sizeof(unsigned char));
- sal_Int32 *pGlyphSetID = (sal_Int32*)alloca (nLen * sizeof(sal_Int32));
+ unsigned char *pGlyphID = static_cast<unsigned char*>(alloca (nLen * sizeof(unsigned char)));
+ sal_Int32 *pGlyphSetID = static_cast<sal_Int32*>(alloca (nLen * sizeof(sal_Int32)));
// convert unicode to glyph id and char set (font subset)
for (nChar = 0; nChar < nLen; nChar++)
diff --git a/vcl/generic/print/printerjob.cxx b/vcl/generic/print/printerjob.cxx
index 7cfeead..f3aa39d 100644
--- a/vcl/generic/print/printerjob.cxx
+++ b/vcl/generic/print/printerjob.cxx
@@ -66,7 +66,7 @@ AppendPS (FILE* pDst, osl::File* pSrc, unsigned char* pBuffer,
if (nBlockSize == 0)
nBlockSize = nBLOCKSIZE;
if (pBuffer == NULL)
- pBuffer = (unsigned char*)alloca (nBlockSize);
+ pBuffer = static_cast<unsigned char*>(alloca (nBlockSize));
sal_uInt64 nIn = 0;
sal_uInt64 nOut = 0;
diff --git a/vcl/generic/print/prtsetup.cxx b/vcl/generic/print/prtsetup.cxx
index ed598b6..cbe60c3 100644
--- a/vcl/generic/print/prtsetup.cxx
+++ b/vcl/generic/print/prtsetup.cxx
@@ -258,7 +258,7 @@ IMPL_LINK( RTSPaperPage, SelectHdl, ListBox*, pBox )
}
if( pKey )
{
- PPDValue* pValue = (PPDValue*)pBox->GetSelectEntryData();
+ PPDValue* pValue = static_cast<PPDValue*>(pBox->GetSelectEntryData());
m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
update();
}
@@ -412,13 +412,13 @@ IMPL_LINK( RTSDevicePage, SelectHdl, ListBox*, pBox )
{
if( pBox == m_pPPDKeyBox )
{
- const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetSelectEntryData();
+ const PPDKey* pKey = static_cast<PPDKey*>(m_pPPDKeyBox->GetSelectEntryData());
FillValueBox( pKey );
}
else if( pBox == m_pPPDValueBox )
{
- const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetSelectEntryData();
- const PPDValue* pValue = (PPDValue*)m_pPPDValueBox->GetSelectEntryData();
+ const PPDKey* pKey = static_cast<PPDKey*>(m_pPPDKeyBox->GetSelectEntryData());
+ const PPDValue* pValue = static_cast<PPDValue*>(m_pPPDValueBox->GetSelectEntryData());
if (pKey && pValue)
{
m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
diff --git a/vcl/generic/print/text_gfx.cxx b/vcl/generic/print/text_gfx.cxx
index dec1304..569a10e 100644
--- a/vcl/generic/print/text_gfx.cxx
+++ b/vcl/generic/print/text_gfx.cxx
@@ -197,9 +197,9 @@ void PrinterGfx::DrawGlyphs(
// vertical glyphs can have an additional rotation ... sigh.
// so break up text in chunks of normal glyphs and print out
// specially rotated glyphs extra
- sal_GlyphId* pTempGlyphIds = (sal_GlyphId*)alloca(sizeof(sal_Int32)*nLen);
- sal_Int32* pTempDelta = (sal_Int32*)alloca(sizeof(sal_Int32)*nLen);
- sal_Unicode* pTempUnicodes = (sal_Unicode*)alloca(sizeof(sal_Unicode)*nLen);
+ sal_GlyphId* pTempGlyphIds = static_cast<sal_GlyphId*>(alloca(sizeof(sal_Int32)*nLen));
+ sal_Int32* pTempDelta = static_cast<sal_Int32*>(alloca(sizeof(sal_Int32)*nLen));
+ sal_Unicode* pTempUnicodes = static_cast<sal_Unicode*>(alloca(sizeof(sal_Unicode)*nLen));
sal_Int16 nTempLen = 0;
sal_Int32 nTempFirstDelta = 0;
Point aRotPoint;
@@ -314,7 +314,7 @@ PrinterGfx::DrawText (
sal_Unicode *pEffectiveStr;
if ( aFont.IsSymbolFont() )
{
- pEffectiveStr = (sal_Unicode*)alloca(nLen * sizeof(pStr[0]));
+ pEffectiveStr = static_cast<sal_Unicode*>(alloca(nLen * sizeof(pStr[0])));
for (int i = 0; i < nLen; i++)
pEffectiveStr[i] = pStr[i] < 256 ? pStr[i] + 0xF000 : pStr[i];
}
@@ -323,8 +323,8 @@ PrinterGfx::DrawText (
pEffectiveStr = const_cast<sal_Unicode*>(pStr);
}
- fontID *pFontMap = (fontID*) alloca(nLen * sizeof(fontID));
- sal_Int32 *pCharWidth = (sal_Int32*) alloca(nLen * sizeof(sal_Int32));
+ fontID *pFontMap = static_cast<fontID*>(alloca(nLen * sizeof(fontID)));
+ sal_Int32 *pCharWidth = static_cast<sal_Int32*>(alloca(nLen * sizeof(sal_Int32)));
for( int n = 0; n < nLen; n++ )
{
@@ -335,7 +335,7 @@ PrinterGfx::DrawText (
}
// setup a new delta array, use virtual resolution of 1000
- sal_Int32* pNewDeltaArray = (sal_Int32*)alloca( sizeof( sal_Int32 )*nLen );
+ sal_Int32* pNewDeltaArray = static_cast<sal_Int32*>(alloca( sizeof( sal_Int32 )*nLen ));
if ( pDeltaArray != 0)
{
for (int i = 0; i < nLen - 1; i++)
@@ -438,7 +438,7 @@ bool PrinterGfx::drawVerticalizedText(
if (!rMgr.getFontInfo(mnFontID, aInfo))
return false;
- sal_Int32* pDelta = (sal_Int32*)alloca( nLen * sizeof(sal_Int32) );
+ sal_Int32* pDelta = static_cast<sal_Int32*>(alloca( nLen * sizeof(sal_Int32) ));
int nTextScale = maVirtualStatus.mnTextWidth ? maVirtualStatus.mnTextWidth : maVirtualStatus.mnTextHeight;
int nNormalAngle = mnTextAngle;
@@ -447,7 +447,7 @@ bool PrinterGfx::drawVerticalizedText(
double fSin = sin( -2.0*M_PI*nNormalAngle/3600 );
double fCos = cos( -2.0*M_PI*nNormalAngle/3600 );
- bool* pGsubFlags = (bool*)alloca( nLen * sizeof(bool) );
+ bool* pGsubFlags = static_cast<bool*>(alloca( nLen * sizeof(bool) ));
rMgr.hasVerticalSubstitutions( mnFontID, pStr, nLen, pGsubFlags );
Point aPoint( rPoint );
@@ -546,7 +546,7 @@ PrinterGfx::LicenseWarning(const Point& rPoint, const sal_Unicode* pStr,
PSSetFont (aFontName, RTL_TEXTENCODING_ISO_8859_1);
sal_Size nSize = 4 * nLen;
- unsigned char* pBuffer = (unsigned char*)alloca (nSize* sizeof(unsigned char));
+ unsigned char* pBuffer = static_cast<unsigned char*>(alloca (nSize* sizeof(unsigned char)));
ConverterFactory &rCvt = GetConverterFactory ();
nSize = rCvt.Convert (pStr, nLen, pBuffer, nSize, RTL_TEXTENCODING_ISO_8859_1);
diff --git a/vcl/headless/svpprn.cxx b/vcl/headless/svpprn.cxx
index ea481e3..cc70349 100644
--- a/vcl/headless/svpprn.cxx
+++ b/vcl/headless/svpprn.cxx
@@ -144,7 +144,7 @@ static void copyJobDataToJobSetup( ImplJobSetup* pJobSetup, JobData& rData )
if( rData.getStreamBuffer( pBuffer, nBytes ) )
{
pJobSetup->mnDriverDataLen = nBytes;
- pJobSetup->mpDriverData = (sal_uInt8*)pBuffer;
+ pJobSetup->mpDriverData = static_cast<sal_uInt8*>(pBuffer);
}
else
{
diff --git a/vcl/opengl/x11/gdiimpl.cxx b/vcl/opengl/x11/gdiimpl.cxx
index bbc68b9..1d453da 100644
--- a/vcl/opengl/x11/gdiimpl.cxx
+++ b/vcl/opengl/x11/gdiimpl.cxx
@@ -93,7 +93,7 @@ bool X11OpenGLSalGraphicsImpl::FillPixmapFromScreen( X11Pixmap* pPixmap, int nX,
glXWaitX();
// TODO: lfrb: What if offscreen?
- pData = (char*) malloc( pPixmap->GetWidth() * pPixmap->GetHeight() * 4 );
+ pData = static_cast<char*>(malloc( pPixmap->GetWidth() * pPixmap->GetHeight() * 4 ));
glPixelStorei( GL_PACK_ALIGNMENT, 1 );
glReadPixels( nX, GetHeight() - nY, pPixmap->GetWidth(), pPixmap->GetHeight(),
GL_RGBA, GL_UNSIGNED_BYTE, pData );
diff --git a/vcl/source/app/svmain.cxx b/vcl/source/app/svmain.cxx
index fdf2b9f..aee0b91 100644
--- a/vcl/source/app/svmain.cxx
+++ b/vcl/source/app/svmain.cxx
@@ -595,8 +595,8 @@ extern "C"
{
static void SAL_CALL MainWorkerFunction( void* pArgs )
{
- ((WorkerThreadData*)pArgs)->pWorker( ((WorkerThreadData*)pArgs)->pThreadData );
- delete (WorkerThreadData*)pArgs;
+ static_cast<WorkerThreadData*>(pArgs)->pWorker( static_cast<WorkerThreadData*>(pArgs)->pThreadData );
+ delete static_cast<WorkerThreadData*>(pArgs);
hThreadID = 0;
}
} // extern "C"
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index f4ca6e6..5b9c8c2 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -3742,8 +3742,8 @@ ImageButton::ImageButton( vcl::Window* pParent, const ResId& rResId ) :
if ( RSC_IMAGEBUTTON_IMAGE & nObjMask )
{
- SetModeImage( Image( ResId( (RSHEADER_TYPE*)GetClassRes(), *rResId.GetResMgr() ) ) );
- IncrementRes( GetObjSizeRes( (RSHEADER_TYPE*)GetClassRes() ) );
+ SetModeImage( Image( ResId( static_cast<RSHEADER_TYPE*>(GetClassRes()), *rResId.GetResMgr() ) ) );
+ IncrementRes( GetObjSizeRes( static_cast<RSHEADER_TYPE*>(GetClassRes()) ) );
}
if ( RSC_IMAGEBUTTON_SYMBOL & nObjMask )
diff --git a/vcl/source/control/field.cxx b/vcl/source/control/field.cxx
index 8a9cbed..c71b726 100644
--- a/vcl/source/control/field.cxx
+++ b/vcl/source/control/field.cxx
@@ -828,7 +828,7 @@ bool NumericField::set_property(const OString &rKey, const OString &rValue)
void NumericField::ImplLoadRes( const ResId& rResId )
{
SpinField::ImplLoadRes( rResId );
- NumericFormatter::ImplLoadRes( ResId( (RSHEADER_TYPE *)GetClassRes(), *rResId.GetResMgr() ) );
+ NumericFormatter::ImplLoadRes( ResId( static_cast<RSHEADER_TYPE *>(GetClassRes()), *rResId.GetResMgr() ) );
sal_uLong nMask = ReadLongRes();
@@ -1663,7 +1663,7 @@ bool MetricField::set_property(const OString &rKey, const OString &rValue)
void MetricField::ImplLoadRes( const ResId& rResId )
{
SpinField::ImplLoadRes( rResId );
- MetricFormatter::ImplLoadRes( ResId( (RSHEADER_TYPE *)GetClassRes(), *rResId.GetResMgr() ) );
+ MetricFormatter::ImplLoadRes( ResId( static_cast<RSHEADER_TYPE *>(GetClassRes()), *rResId.GetResMgr() ) );
sal_uLong nMask = ReadLongRes();
diff --git a/vcl/source/control/fixed.cxx b/vcl/source/control/fixed.cxx
index f8e36da..62c6135 100644
--- a/vcl/source/control/fixed.cxx
+++ b/vcl/source/control/fixed.cxx
@@ -892,8 +892,8 @@ void FixedImage::ImplLoadRes( const ResId& rResId )
if ( RSC_FIXEDIMAGE_IMAGE & nObjMask )
{
- maImage = Image( ResId( (RSHEADER_TYPE*)GetClassRes(), *rResId.GetResMgr() ) );
- IncrementRes( GetObjSizeRes( (RSHEADER_TYPE*)GetClassRes() ) );
+ maImage = Image( ResId( static_cast<RSHEADER_TYPE*>(GetClassRes()), *rResId.GetResMgr() ) );
+ IncrementRes( GetObjSizeRes( static_cast<RSHEADER_TYPE*>(GetClassRes()) ) );
}
}
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 21e643e..9072052 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -2095,7 +2095,7 @@ sal_uInt16 GraphicFilter::ExportGraphic( const Graphic& rGraphic, const OUString
xActiveDataSource->setOutputStream( css::uno::Reference< css::io::XOutputStream >(
xStmIf, css::uno::UNO_QUERY ) );
- css::uno::Sequence< sal_Int8 > aMtfSeq( (sal_Int8*) aMemStm.GetData(), aMemStm.Tell() );
+ css::uno::Sequence< sal_Int8 > aMtfSeq( static_cast<sal_Int8 const *>(aMemStm.GetData()), aMemStm.Tell() );
xSVGWriter->write( xSaxWriter, aMtfSeq );
}
}
diff --git a/vcl/source/filter/igif/decode.cxx b/vcl/source/filter/igif/decode.cxx
index d50ac7c..46a666f 100644
--- a/vcl/source/filter/igif/decode.cxx
+++ b/vcl/source/filter/igif/decode.cxx
@@ -68,7 +68,7 @@ HPBYTE GIFLZWDecompressor::DecompressBlock( HPBYTE pSrc, sal_uInt8 cBufSize,
{
sal_uLong nTargetSize = 4096;
sal_uLong nCount = 0;
- HPBYTE pTarget = (HPBYTE) rtl_allocateMemory( nTargetSize );
+ HPBYTE pTarget = static_cast<HPBYTE>(rtl_allocateMemory( nTargetSize ));
HPBYTE pTmpTarget = pTarget;
nBlockBufSize = cBufSize;
@@ -83,7 +83,7 @@ HPBYTE GIFLZWDecompressor::DecompressBlock( HPBYTE pSrc, sal_uInt8 cBufSize,
{
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list