summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-06-20 09:35:55 +0200
committerBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-06-20 09:35:55 +0200
commit199a69a3bab2153bde0e09ab3e286408e0a6a561 (patch)
tree6beb12a20bd334ffcea97ca4d019c79db4effa68
parentcdf12fc756a28acd2e0b7686a17af324ec093509 (diff)
parent53f86bcbf3fb81cad4971c9ec28fb996a4a387bc (diff)
Merge branch 'master' into feature/gnumake4
-rw-r--r--.gitignore18
-rw-r--r--animations/inc/animations/animationnodehelper.hxx3
-rw-r--r--animations/prj/d.lst16
-rw-r--r--animations/source/animcore/animcore.cxx31
-rw-r--r--animations/source/animcore/animcore.xml2
-rw-r--r--animations/source/animcore/factreg.cxx7
-rw-r--r--animations/source/animcore/factreg.hxx3
-rw-r--r--animations/source/animcore/makefile.mk12
-rw-r--r--animations/source/animcore/targetpropertiescreator.cxx30
-rw-r--r--sd/AllLangResTarget_sd.mk110
-rw-r--r--sd/CppunitTest_sd_uimpress.mk103
-rw-r--r--sd/JunitTest_sd_unoapi.mk49
-rw-r--r--sd/Library_sd.mk520
-rw-r--r--sd/Library_sdd.mk63
-rw-r--r--sd/Library_sdfilt.mk105
-rw-r--r--sd/Library_sdui.mk101
-rw-r--r--sd/Makefile (renamed from sd/qa/unoapi/makefile.mk)34
-rw-r--r--sd/Module_sd.mk50
-rw-r--r--sd/Package_inc.mk32
-rw-r--r--sd/Package_uiconfig.mk129
-rw-r--r--sd/Package_web.mk58
-rw-r--r--sd/Package_xml.mk62
-rw-r--r--sd/inc/CustomAnimationCloner.hxx3
-rw-r--r--sd/inc/CustomAnimationEffect.hxx3
-rw-r--r--sd/inc/CustomAnimationPreset.hxx16
-rw-r--r--sd/inc/EffectMigration.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/FactoryIds.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/Outliner.hxx6
-rw-r--r--[-rwxr-xr-x]sd/inc/OutlinerIterator.hxx2
-rw-r--r--sd/inc/SdShapeTypes.hxx11
-rw-r--r--sd/inc/TransitionPreset.hxx12
-rw-r--r--sd/inc/animations.hxx3
-rw-r--r--sd/inc/anmdef.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/anminfo.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/app.hrc13
-rw-r--r--sd/inc/app.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/cusshow.hxx4
-rw-r--r--sd/inc/diadef.h2
-rw-r--r--[-rwxr-xr-x]sd/inc/drawdoc.hxx46
-rw-r--r--sd/inc/eetext.hxx2
-rw-r--r--sd/inc/fadedef.h2
-rw-r--r--[-rwxr-xr-x]sd/inc/glob.hxx2
-rw-r--r--sd/inc/helper/simplereferencecomponent.hxx3
-rwxr-xr-xsd/inc/helpids.h3
-rw-r--r--sd/inc/imapinfo.hxx2
-rw-r--r--sd/inc/makefile.mk48
-rw-r--r--sd/inc/misc.hxx36
-rw-r--r--sd/inc/misc/scopelock.hxx3
-rw-r--r--sd/inc/movedef.hxx2
-rw-r--r--sd/inc/pch/precompiled_sd.cxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/pch/precompiled_sd.hxx19
-rw-r--r--sd/inc/pglink.hxx16
-rw-r--r--[-rwxr-xr-x]sd/inc/pres.hxx2
-rw-r--r--sd/inc/prlayout.hxx2
-rw-r--r--sd/inc/resltn.hxx2
-rw-r--r--sd/inc/sd_primitivetypes2d.hxx5
-rw-r--r--[-rwxr-xr-x]sd/inc/sdabstdlg.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/sdattr.hxx4
-rw-r--r--sd/inc/sdcgmfilter.hxx3
-rw-r--r--sd/inc/sdcommands.h1
-rw-r--r--sd/inc/sddll.hxx2
-rw-r--r--sd/inc/sddllapi.h3
-rw-r--r--sd/inc/sdenumdef.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/sderror.hxx7
-rw-r--r--sd/inc/sdfilter.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/sdgrffilter.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/sdhtmlfilter.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/sdiocmpt.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/sdmod.hxx2
-rw-r--r--sd/inc/sdobjfac.hxx2
-rw-r--r--[-rwxr-xr-x]sd/inc/sdpage.hxx11
-rw-r--r--sd/inc/sdpptwrp.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/sdresid.hxx5
-rw-r--r--sd/inc/sdundo.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/sdxmlwrp.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/shapelist.hxx3
-rw-r--r--sd/inc/stlfamily.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/stlpool.hxx8
-rw-r--r--[-rwxr-xr-x]sd/inc/stlsheet.hxx2
-rw-r--r--sd/inc/strmname.h4
-rw-r--r--[-rwxr-xr-x]sd/inc/textapi.hxx3
-rw-r--r--sd/inc/undo/undofactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/inc/undo/undomanager.hxx3
-rw-r--r--sd/inc/undo/undoobjects.hxx3
-rw-r--r--sd/inc/undoanim.hxx2
-rw-r--r--sd/prj/build.lst49
-rw-r--r--[-rwxr-xr-x]sd/prj/d.lst60
-rwxr-xr-x[-rw-r--r--]sd/prj/makefile.mk (renamed from sd/source/filter/cgm/makefile.mk)21
-rw-r--r--sd/qa/unit/export.map7
-rw-r--r--sd/qa/unit/uimpress.cxx133
-rw-r--r--sd/qa/unit/version.map34
-rw-r--r--sd/qa/unoapi/Test.java51
-rwxr-xr-xsd/sdi/SlideSorterController.sdi1
-rwxr-xr-xsd/sdi/_drvwsh.sdi44
-rwxr-xr-xsd/sdi/makefile.mk97
-rwxr-xr-xsd/sdi/outlnvsh.sdi1
-rwxr-xr-xsd/sdi/sdraw.sdi133
-rw-r--r--sd/source/core/CustomAnimationCloner.cxx21
-rw-r--r--[-rwxr-xr-x]sd/source/core/CustomAnimationEffect.cxx149
-rw-r--r--[-rwxr-xr-x]sd/source/core/CustomAnimationPreset.cxx41
-rw-r--r--sd/source/core/EffectMigration.cxx72
-rw-r--r--sd/source/core/PageListWatcher.cxx8
-rw-r--r--sd/source/core/PageListWatcher.hxx3
-rw-r--r--sd/source/core/TransitionPreset.cxx48
-rw-r--r--[-rwxr-xr-x]sd/source/core/anminfo.cxx5
-rw-r--r--sd/source/core/annotations/Annotation.cxx4
-rw-r--r--sd/source/core/annotations/AnnotationAccess.cxx2
-rw-r--r--sd/source/core/annotations/AnnotationEnumeration.cxx2
-rw-r--r--sd/source/core/annotations/makefile.mk49
-rw-r--r--[-rwxr-xr-x]sd/source/core/cusshow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/core/drawdoc.cxx82
-rw-r--r--[-rwxr-xr-x]sd/source/core/drawdoc2.cxx102
-rw-r--r--[-rwxr-xr-x]sd/source/core/drawdoc3.cxx68
-rw-r--r--[-rwxr-xr-x]sd/source/core/drawdoc4.cxx123
-rw-r--r--[-rwxr-xr-x]sd/source/core/drawdoc_animations.cxx3
-rw-r--r--sd/source/core/glob.src1
-rw-r--r--sd/source/core/makefile.mk78
-rw-r--r--[-rwxr-xr-x]sd/source/core/pglink.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/core/sdattr.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/core/sdiocmpt.cxx3
-rw-r--r--sd/source/core/sdobjfac.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/core/sdpage.cxx126
-rw-r--r--[-rwxr-xr-x]sd/source/core/sdpage2.cxx84
-rw-r--r--sd/source/core/sdpage_animations.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/core/shapelist.cxx9
-rw-r--r--sd/source/core/stlfamily.cxx59
-rw-r--r--[-rwxr-xr-x]sd/source/core/stlpool.cxx156
-rw-r--r--[-rwxr-xr-x]sd/source/core/stlsheet.cxx84
-rw-r--r--sd/source/core/text/makefile.mk48
-rw-r--r--[-rwxr-xr-x]sd/source/core/text/textapi.cxx4
-rw-r--r--sd/source/core/typemap.cxx7
-rw-r--r--sd/source/core/undo/makefile.mk50
-rw-r--r--sd/source/core/undo/undofactory.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/core/undo/undomanager.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/core/undo/undoobjects.cxx3
-rw-r--r--sd/source/core/undoanim.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/filter/cgm/sdcgmfilter.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/filter/eppt/eppt.cxx1685
-rw-r--r--[-rwxr-xr-x]sd/source/filter/eppt/eppt.hxx814
-rw-r--r--sd/source/filter/eppt/epptbase.hxx454
-rw-r--r--[-rwxr-xr-x]sd/source/filter/eppt/epptdef.hxx3
-rw-r--r--sd/source/filter/eppt/epptooxml.hxx183
-rw-r--r--sd/source/filter/eppt/epptso.cxx2268
-rw-r--r--[-rwxr-xr-x]sd/source/filter/eppt/escherex.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/filter/eppt/escherex.hxx3
-rw-r--r--sd/source/filter/eppt/grouptable.hxx86
-rw-r--r--sd/source/filter/eppt/makefile.mk52
-rw-r--r--sd/source/filter/eppt/pptexanimations.cxx412
-rw-r--r--sd/source/filter/eppt/pptexanimations.hxx32
-rw-r--r--sd/source/filter/eppt/pptexsoundcollection.cxx55
-rw-r--r--sd/source/filter/eppt/pptexsoundcollection.hxx25
-rw-r--r--sd/source/filter/eppt/pptx-epptbase.cxx1022
-rw-r--r--sd/source/filter/eppt/pptx-epptooxml.cxx2291
-rw-r--r--sd/source/filter/eppt/pptx-grouptable.cxx142
-rw-r--r--sd/source/filter/eppt/pptx-stylesheet.cxx509
-rw-r--r--sd/source/filter/eppt/pptx-text.cxx1435
-rw-r--r--sd/source/filter/eppt/text.hxx270
-rw-r--r--[-rwxr-xr-x]sd/source/filter/grf/sdgrffilter.cxx37
-rw-r--r--sd/source/filter/html/HtmlOptionsDialog.cxx9
-rw-r--r--sd/source/filter/html/buttonset.cxx18
-rw-r--r--sd/source/filter/html/buttonset.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/filter/html/htmlattr.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/filter/html/htmlattr.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/filter/html/htmlex.cxx149
-rw-r--r--[-rwxr-xr-x]sd/source/filter/html/htmlex.hxx12
-rw-r--r--sd/source/filter/html/makefile.mk68
-rw-r--r--[-rwxr-xr-x]sd/source/filter/html/pubdlg.cxx108
-rw-r--r--sd/source/filter/html/sdhtmlfilter.cxx3
-rw-r--r--sd/source/filter/makefile.mk55
-rw-r--r--sd/source/filter/ppt/makefile.mk57
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/ppt97animations.cxx299
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/ppt97animations.hxx6
-rw-r--r--sd/source/filter/ppt/pptanimations.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptatom.cxx (renamed from sd/source/filter/ppt/pptatom.cpp)9
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptatom.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptin.cxx186
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptin.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptinanimations.cxx88
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/pptinanimations.hxx3
-rw-r--r--sd/source/filter/ppt/propread.cxx205
-rw-r--r--[-rwxr-xr-x]sd/source/filter/ppt/propread.hxx51
-rw-r--r--sd/source/filter/sdfilter.cxx29
-rw-r--r--[-rwxr-xr-x]sd/source/filter/sdpptwrp.cxx13
-rw-r--r--sd/source/filter/xml/makefile.mk47
-rw-r--r--sd/source/filter/xml/sdtransform.cxx18
-rw-r--r--[-rwxr-xr-x]sd/source/filter/xml/sdxmlwrp.cxx45
-rw-r--r--sd/source/helper/makefile.mk47
-rw-r--r--sd/source/helper/simplereferencecomponent.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx5
-rw-r--r--sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx32
-rw-r--r--[-rwxr-xr-x]sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx5
-rw-r--r--sd/source/ui/accessibility/AccessibleOutlineView.cxx25
-rw-r--r--sd/source/ui/accessibility/AccessiblePageShape.cxx12
-rw-r--r--sd/source/ui/accessibility/AccessiblePresentationGraphicShape.cxx7
-rw-r--r--sd/source/ui/accessibility/AccessiblePresentationOLEShape.cxx35
-rw-r--r--sd/source/ui/accessibility/AccessiblePresentationShape.cxx25
-rw-r--r--sd/source/ui/accessibility/AccessibleScrollPanel.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx15
-rw-r--r--sd/source/ui/accessibility/AccessibleSlideSorterView.cxx65
-rw-r--r--[-rwxr-xr-x]sd/source/ui/accessibility/AccessibleTreeNode.cxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/accessibility/AccessibleViewForwarder.cxx5
-rw-r--r--sd/source/ui/accessibility/SdShapeTypes.cxx133
-rwxr-xr-xsd/source/ui/accessibility/makefile.mk71
-rw-r--r--sd/source/ui/animations/CustomAnimation.hrc28
-rw-r--r--sd/source/ui/animations/CustomAnimation.src52
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationCreateDialog.cxx18
-rw-r--r--sd/source/ui/animations/CustomAnimationCreateDialog.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationDialog.cxx70
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationDialog.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationList.cxx96
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationList.hxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationPane.cxx38
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/CustomAnimationPane.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/DialogListBox.cxx3
-rw-r--r--sd/source/ui/animations/STLPropertySet.cxx11
-rw-r--r--sd/source/ui/animations/STLPropertySet.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/SlideTransitionPane.cxx28
-rw-r--r--sd/source/ui/animations/SlideTransitionPane.hxx3
-rwxr-xr-xsd/source/ui/animations/makefile.mk65
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/motionpathtag.cxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/animations/motionpathtag.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationmanager.cxx295
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationmanagerimpl.hxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationtag.cxx29
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationtag.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationwindow.cxx30
-rw-r--r--[-rwxr-xr-x]sd/source/ui/annotations/annotationwindow.hxx5
-rw-r--r--sd/source/ui/annotations/makefile.mk56
-rw-r--r--sd/source/ui/app/app.src1
-rwxr-xr-xsd/source/ui/app/makefile.mk112
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/menuids2_tmpl.src6
-rw-r--r--sd/source/ui/app/menuids3_tmpl.src1
-rw-r--r--sd/source/ui/app/menuids_tmpl.src47
-rw-r--r--sd/source/ui/app/menuportal_tmpl.src1
-rw-r--r--sd/source/ui/app/optsitem.cxx32
-rw-r--r--sd/source/ui/app/popup.src3
-rw-r--r--sd/source/ui/app/popup2_tmpl.src43
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/res_bmp.src218
-rw-r--r--sd/source/ui/app/sddll.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sddll1.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sddll2.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdmod.cxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdmod1.cxx23
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdmod2.cxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdpopup.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdresid.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/sdxfer.cxx52
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/strings.src0
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/tbxww.cxx152
-rw-r--r--[-rwxr-xr-x]sd/source/ui/app/tmplctrl.cxx2
-rwxr-xr-xsd/source/ui/controller/makefile.mk54
-rw-r--r--sd/source/ui/controller/slidelayoutcontroller.cxx85
-rw-r--r--sd/source/ui/controller/slidelayoutcontroller.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/AnimationChildWindow.cxx16
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/LayerDialogChildWindow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/LayerDialogContent.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/LayerTabBar.cxx36
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/NavigatorChildWindow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/PaneChildWindows.cxx5
-rw-r--r--sd/source/ui/dlg/PaneDockingWindow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/PaneShells.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/SpellDialogChildWindow.cxx3
-rw-r--r--sd/source/ui/dlg/TemplateScanner.cxx41
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/animobjs.cxx37
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/animobjs.src6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/assclass.cxx126
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/brkdlg.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/celltempl.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/copydlg.cxx12
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/custsdlg.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/custsdlg.src0
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/diactrl.cxx2
-rw-r--r--sd/source/ui/dlg/dlg_char.src1
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgass.cxx91
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgassim.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgassim.hxx16
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgchar.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgctrls.cxx22
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgfield.cxx12
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgolbul.cxx26
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgpage.cxx6
-rw-r--r--sd/source/ui/dlg/dlgpage.src1
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/dlgsnap.cxx14
-rw-r--r--sd/source/ui/dlg/dlgsnap.src49
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/docprev.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/filedlg.cxx51
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/gluectrl.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/headerfooterdlg.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/ins_paste.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/inspagob.cxx12
-rw-r--r--sd/source/ui/dlg/inspagob.src1
-rw-r--r--sd/source/ui/dlg/layeroptionsdlg.cxx6
-rwxr-xr-xsd/source/ui/dlg/makefile.mk193
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/masterlayoutdlg.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/morphdlg.cxx31
-rw-r--r--sd/source/ui/dlg/morphdlg.src2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/navigatr.cxx56
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/navigatr.src10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/paragr.cxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/present.cxx2
-rw-r--r--sd/source/ui/dlg/present.src2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/prltempl.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/prntopts.cxx5
-rw-r--r--sd/source/ui/dlg/sdabstdlg.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/sddlgfact.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/sddlgfact.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/sdpreslt.cxx14
-rw-r--r--sd/source/ui/dlg/sdpreslt.src1
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/sdtreelb.cxx192
-rw-r--r--sd/source/ui/dlg/sduiexp.cxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/tabtempl.cxx4
-rw-r--r--sd/source/ui/dlg/tabtempl.src4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/tpaction.cxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/tpaction.src0
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/tpoption.cxx16
-rw-r--r--sd/source/ui/dlg/tpoption.src10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/unchss.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/vectdlg.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/dlg/vectdlg.src10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/docshell/docshel2.cxx53
-rw-r--r--[-rwxr-xr-x]sd/source/ui/docshell/docshel3.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/docshell/docshel4.cxx99
-rw-r--r--[-rwxr-xr-x]sd/source/ui/docshell/docshell.cxx108
-rw-r--r--[-rwxr-xr-x]sd/source/ui/docshell/grdocsh.cxx8
-rw-r--r--sd/source/ui/docshell/makefile.mk56
-rw-r--r--sd/source/ui/docshell/sdclient.cxx17
-rw-r--r--sd/source/ui/framework/configuration/ChangeRequestQueue.cxx3
-rw-r--r--sd/source/ui/framework/configuration/ChangeRequestQueue.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.hxx3
-rw-r--r--sd/source/ui/framework/configuration/Configuration.cxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationClassifier.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationClassifier.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationController.cxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.cxx6
-rw-r--r--sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.cxx6
-rw-r--r--sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationTracer.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationTracer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationUpdater.cxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ConfigurationUpdater.hxx3
-rw-r--r--sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.cxx6
-rw-r--r--sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.hxx3
-rw-r--r--sd/source/ui/framework/configuration/ResourceFactoryManager.cxx3
-rw-r--r--sd/source/ui/framework/configuration/ResourceFactoryManager.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/configuration/ResourceId.cxx5
-rw-r--r--sd/source/ui/framework/configuration/UpdateRequest.cxx4
-rw-r--r--sd/source/ui/framework/configuration/UpdateRequest.hxx3
-rw-r--r--sd/source/ui/framework/configuration/makefile.mk63
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/BasicPaneFactory.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/BasicPaneFactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/BasicToolBarFactory.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/BasicToolBarFactory.hxx3
-rw-r--r--sd/source/ui/framework/factories/BasicViewFactory.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/BasicViewFactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/ChildWindowPane.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/ChildWindowPane.hxx13
-rw-r--r--sd/source/ui/framework/factories/FrameWindowPane.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/FrameWindowPane.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/FullScreenPane.cxx5
-rw-r--r--sd/source/ui/framework/factories/FullScreenPane.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/Pane.cxx28
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/PresentationFactory.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/TaskPanelFactory.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/TaskPanelFactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/factories/ViewShellWrapper.cxx25
-rw-r--r--sd/source/ui/framework/factories/makefile.mk60
-rw-r--r--sd/source/ui/framework/module/CenterViewFocusModule.cxx3
-rw-r--r--sd/source/ui/framework/module/CenterViewFocusModule.hxx3
-rw-r--r--sd/source/ui/framework/module/DrawModule.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ImpressModule.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ModuleController.cxx27
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/PresentationModule.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ReadOnlyModeObserver.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ReadOnlyModeObserver.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ResourceManager.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ResourceManager.hxx3
-rw-r--r--sd/source/ui/framework/module/ShellStackGuard.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/module/ShellStackGuard.hxx3
-rw-r--r--sd/source/ui/framework/module/SlideSorterModule.cxx3
-rw-r--r--sd/source/ui/framework/module/SlideSorterModule.hxx3
-rw-r--r--sd/source/ui/framework/module/ToolBarModule.cxx3
-rw-r--r--sd/source/ui/framework/module/ToolBarModule.hxx3
-rw-r--r--sd/source/ui/framework/module/ToolPanelModule.cxx6
-rw-r--r--sd/source/ui/framework/module/ToolPanelModule.hxx3
-rw-r--r--sd/source/ui/framework/module/ViewTabBarModule.cxx3
-rw-r--r--sd/source/ui/framework/module/ViewTabBarModule.hxx3
-rwxr-xr-xsd/source/ui/framework/module/makefile.mk62
-rw-r--r--[-rwxr-xr-x]sd/source/ui/framework/tools/FrameworkHelper.cxx74
-rw-r--r--sd/source/ui/framework/tools/makefile.mk51
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/bulmaper.cxx55
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuarea.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fubullet.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuchar.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fucon3d.cxx23
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconarc.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconbez.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconcs.cxx7
-rw-r--r--sd/source/ui/func/fuconnct.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconrec.cxx22
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconstr.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuconuno.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fucopy.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fucushow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fudraw.cxx34
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fudspord.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuediglu.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuexpand.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuformatpaintbrush.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuhhconv.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuinsert.cxx32
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuinsfil.cxx28
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuline.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fulinend.cxx5
-rw-r--r--sd/source/ui/func/fulink.cxx5
-rw-r--r--sd/source/ui/func/fumeasur.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fumorph.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuoaprms.cxx26
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuolbull.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuoltext.cxx21
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuoutl.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fupage.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuparagr.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fupoor.cxx67
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuprlout.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuprobjs.cxx23
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuscale.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fusearch.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fusel.cxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fusldlg.cxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fusnapln.cxx90
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fusumry.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/futempl.cxx51
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/futext.cxx92
-rw-r--r--sd/source/ui/func/futhes.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/futransf.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/futxtatt.cxx3
-rw-r--r--sd/source/ui/func/fuvect.cxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/fuzoom.cxx11
-rwxr-xr-xsd/source/ui/func/makefile.mk185
-rw-r--r--sd/source/ui/func/sdundo.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/sdundogr.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/smarttag.cxx2
-rw-r--r--sd/source/ui/func/undoback.cxx4
-rw-r--r--sd/source/ui/func/undoheaderfooter.cxx2
-rw-r--r--sd/source/ui/func/undolayer.cxx3
-rw-r--r--sd/source/ui/func/undopage.cxx2
-rw-r--r--sd/source/ui/func/unmovss.cxx12
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/unoaprms.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/func/unprlout.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/3dchld.hxx2
-rw-r--r--sd/source/ui/inc/AccessibleDocumentViewBase.hxx3
-rw-r--r--sd/source/ui/inc/AccessibleDrawDocumentView.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/AccessibleOutlineEditSource.hxx3
-rw-r--r--sd/source/ui/inc/AccessibleOutlineView.hxx3
-rw-r--r--sd/source/ui/inc/AccessiblePageShape.hxx3
-rw-r--r--sd/source/ui/inc/AccessiblePresentationGraphicShape.hxx3
-rw-r--r--sd/source/ui/inc/AccessiblePresentationOLEShape.hxx3
-rw-r--r--sd/source/ui/inc/AccessiblePresentationShape.hxx3
-rw-r--r--sd/source/ui/inc/AccessibleScrollPanel.hxx3
-rw-r--r--sd/source/ui/inc/AccessibleSlideSorterObject.hxx15
-rw-r--r--sd/source/ui/inc/AccessibleSlideSorterView.hxx19
-rwxr-xr-xsd/source/ui/inc/AccessibleSlideView.hxx280
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/AccessibleTreeNode.hxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/AccessibleViewForwarder.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/AnimationChildWindow.hxx2
-rw-r--r--sd/source/ui/inc/BezierObjectBar.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/BreakDlg.hxx5
-rw-r--r--sd/source/ui/inc/Client.hxx4
-rw-r--r--sd/source/ui/inc/ClientView.hxx2
-rw-r--r--sd/source/ui/inc/CustomAnimation.hxx6
-rw-r--r--sd/source/ui/inc/DialogListBox.hxx3
-rw-r--r--sd/source/ui/inc/DocumentRenderer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/DrawController.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/DrawDocShell.hxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/DrawSubController.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/DrawViewShell.hxx9
-rw-r--r--sd/source/ui/inc/EventMultiplexer.hxx3
-rw-r--r--sd/source/ui/inc/FormShellManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/FrameView.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/GraphicDocShell.hxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/GraphicObjectBar.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/GraphicViewShell.hxx3
-rw-r--r--sd/source/ui/inc/GraphicViewShellBase.hxx3
-rw-r--r--sd/source/ui/inc/ImpressViewShellBase.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/LayerDialogChildWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/LayerDialogContent.hxx4
-rw-r--r--sd/source/ui/inc/LayerTabBar.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/MasterPageObserver.hxx3
-rw-r--r--sd/source/ui/inc/MediaObjectBar.hxx3
-rw-r--r--sd/source/ui/inc/MutexOwner.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/NavigatorChildWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/NotesChildWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/OutlineBulletDlg.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/OutlineView.hxx46
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/OutlineViewShell.hxx3
-rw-r--r--sd/source/ui/inc/OutlineViewShellBase.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/OutlinerIteratorImpl.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/PaneChildWindows.hxx3
-rw-r--r--sd/source/ui/inc/PaneDockingWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/PaneShells.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/PresentationViewShell.hxx3
-rw-r--r--sd/source/ui/inc/PresentationViewShellBase.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/PreviewRenderer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/Ruler.hxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SdUnoDrawView.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SdUnoOutlineView.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SdUnoSlideView.hxx4
-rw-r--r--sd/source/ui/inc/ShellFactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SlideSorter.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SlideSorterChildWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SlideSorterViewShell.hxx3
-rw-r--r--sd/source/ui/inc/SlideSorterViewShellBase.hxx3
-rwxr-xr-xsd/source/ui/inc/SlideView.hxx144
-rwxr-xr-xsd/source/ui/inc/SlideViewShell.hxx175
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/SpellDialogChildWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/TabControl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/TemplateScanner.hxx3
-rw-r--r--sd/source/ui/inc/TextLogger.hxx3
-rw-r--r--sd/source/ui/inc/TextObjectBar.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ToolBarManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/UpdateLockManager.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/View.hxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewClipboard.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewShell.hxx28
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewShellBase.hxx3
-rw-r--r--sd/source/ui/inc/ViewShellHint.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewShellImplementation.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewShellManager.hxx2
-rw-r--r--sd/source/ui/inc/ViewTabBar.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ViewTabControl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/Window.hxx8
-rw-r--r--sd/source/ui/inc/WindowUpdater.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/animobjs.hxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/annotationmanager.hxx3
-rw-r--r--sd/source/ui/inc/assclass.hxx21
-rwxr-xr-xsd/source/ui/inc/bmcache.hxx52
-rw-r--r--sd/source/ui/inc/bulmaper.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/celltempl.hxx3
-rw-r--r--sd/source/ui/inc/cfgids.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/copydlg.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/custsdlg.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/diactrl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlg_char.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlgass.hxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlgctrls.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlgfield.hxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlgpage.hxx2
-rw-r--r--sd/source/ui/inc/dlgsnap.hrc6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/dlgsnap.hxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/docprev.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/drawview.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/filedlg.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/Configuration.hxx3
-rw-r--r--sd/source/ui/inc/framework/ConfigurationController.hxx3
-rw-r--r--sd/source/ui/inc/framework/DrawModule.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/FrameworkHelper.hxx3
-rw-r--r--sd/source/ui/inc/framework/ImpressModule.hxx3
-rw-r--r--sd/source/ui/inc/framework/ModuleController.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/Pane.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/PresentationFactory.hxx3
-rw-r--r--sd/source/ui/inc/framework/PresentationModule.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/ResourceId.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/framework/ViewShellWrapper.hxx3
-rw-r--r--sd/source/ui/inc/fuarea.hxx2
-rw-r--r--sd/source/ui/inc/fubullet.hxx2
-rw-r--r--sd/source/ui/inc/fuchar.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fucon3d.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconarc.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconbez.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconcs.hxx3
-rw-r--r--sd/source/ui/inc/fuconnct.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconrec.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconstr.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuconuno.hxx3
-rw-r--r--sd/source/ui/inc/fucopy.hxx2
-rw-r--r--sd/source/ui/inc/fucushow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fudraw.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fudspord.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuediglu.hxx2
-rw-r--r--sd/source/ui/inc/fuexpand.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuformatpaintbrush.hxx3
-rw-r--r--sd/source/ui/inc/fugrid.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuhhconv.hxx5
-rw-r--r--sd/source/ui/inc/fuinsert.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuinsfil.hxx3
-rw-r--r--sd/source/ui/inc/fuline.hxx2
-rw-r--r--sd/source/ui/inc/fulinend.hxx2
-rw-r--r--sd/source/ui/inc/fulink.hxx2
-rw-r--r--sd/source/ui/inc/fumeasur.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fumorph.hxx6
-rw-r--r--sd/source/ui/inc/fuoaprms.hxx2
-rw-r--r--sd/source/ui/inc/fuolbull.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuoltext.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuoutl.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fupage.hxx2
-rw-r--r--sd/source/ui/inc/fuparagr.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fupoor.hxx11
-rw-r--r--sd/source/ui/inc/fuprlout.hxx2
-rw-r--r--sd/source/ui/inc/fuprobjs.hxx2
-rw-r--r--sd/source/ui/inc/fuscale.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fusearch.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fusel.hxx2
-rw-r--r--sd/source/ui/inc/fusldlg.hxx3
-rw-r--r--sd/source/ui/inc/fuslhide.hxx63
-rwxr-xr-xsd/source/ui/inc/fuslid.hxx77
-rwxr-xr-xsd/source/ui/inc/fuslsel.hxx120
-rw-r--r--sd/source/ui/inc/fusnapln.hxx3
-rw-r--r--sd/source/ui/inc/fusumry.hxx2
-rw-r--r--sd/source/ui/inc/futempl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/futext.hxx7
-rw-r--r--sd/source/ui/inc/futhes.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/futransf.hxx4
-rw-r--r--sd/source/ui/inc/futxtatt.hxx2
-rw-r--r--sd/source/ui/inc/fuvect.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/fuzoom.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/gluectrl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/headerfooterdlg.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/ins_paste.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/inspagob.hxx5
-rw-r--r--sd/source/ui/inc/layeroptionsdlg.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/masterlayoutdlg.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/morphdlg.hxx9
-rwxr-xr-xsd/source/ui/inc/navigatr.hrc1
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/navigatr.hxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/optdlg.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/optsitem.hxx19
-rw-r--r--sd/source/ui/inc/paragr.hxx4
-rw-r--r--sd/source/ui/inc/pgjump.hxx2
-rw-r--r--sd/source/ui/inc/present.hxx12
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/prltempl.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/prntopts.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/pubdlg.hxx20
-rwxr-xr-xsd/source/ui/inc/res_bmp.hrc52
-rw-r--r--sd/source/ui/inc/sdpopup.hxx3
-rw-r--r--sd/source/ui/inc/sdpreslt.hxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/sdtreelb.hxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/sdundogr.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/sdxfer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/slideshow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/smarttag.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/sprite.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tabtempl.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/ControlContainer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/ILayoutableWindow.hxx3
-rw-r--r--sd/source/ui/inc/taskpane/PanelId.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/ScrollPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/SlideSorterCacheDisplay.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/SubToolPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/TaskPaneControlFactory.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/TaskPaneTreeNode.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/TitleBar.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/taskpane/TitledControl.hxx5
-rw-r--r--sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tbx_ww.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tmplctrl.hxx2
-rw-r--r--sd/source/ui/inc/tools/AsynchronousCall.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/AsynchronousTask.hxx3
-rw-r--r--sd/source/ui/inc/tools/ConfigurationAccess.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/IconCache.hxx5
-rw-r--r--sd/source/ui/inc/tools/IdleDetection.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/PropertySet.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/SlotStateListener.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tools/TimerBasedTaskExecution.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tpaction.hxx2
-rw-r--r--sd/source/ui/inc/tpoption.hrc5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/tpoption.hxx14
-rw-r--r--sd/source/ui/inc/unchss.hxx2
-rw-r--r--sd/source/ui/inc/undoback.hxx3
-rw-r--r--sd/source/ui/inc/undoheaderfooter.hxx2
-rw-r--r--sd/source/ui/inc/undolayer.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/undopage.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/unmodpg.hxx2
-rw-r--r--sd/source/ui/inc/unmovss.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/unoaprms.hxx2
-rw-r--r--sd/source/ui/inc/unokywds.hxx6
-rw-r--r--sd/source/ui/inc/unomodel.hxx3
-rw-r--r--sd/source/ui/inc/unoprnms.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/unosrch.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/unprlout.hxx2
-rw-r--r--sd/source/ui/inc/unslsel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/vectdlg.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/view/viewoverlaymanager.hxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/inc/zoomlist.hxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/EditWindow.cxx103
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/EditWindow.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/NotesChildWindow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/NotesChildWindow.src0
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/NotesDockingWindow.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/NotesDockingWindow.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/notes/TextLogger.cxx11
-rwxr-xr-xsd/source/ui/notes/makefile.mk60
-rw-r--r--sd/source/ui/presenter/CanvasUpdateRequester.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/presenter/CanvasUpdateRequester.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/presenter/PresenterCanvas.cxx15
-rw-r--r--sd/source/ui/presenter/PresenterCanvas.hxx3
-rw-r--r--sd/source/ui/presenter/PresenterCanvasFactory.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/presenter/PresenterHelper.cxx11
-rw-r--r--sd/source/ui/presenter/PresenterHelper.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/presenter/PresenterPreviewCache.cxx14
-rw-r--r--sd/source/ui/presenter/PresenterPreviewCache.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/presenter/PresenterTextView.cxx31
-rw-r--r--sd/source/ui/presenter/PresenterTextView.hxx3
-rw-r--r--sd/source/ui/presenter/SlideRenderer.cxx18
-rw-r--r--sd/source/ui/presenter/SlideRenderer.hxx3
-rw-r--r--sd/source/ui/presenter/makefile.mk56
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/PaneHider.cxx3
-rw-r--r--sd/source/ui/slideshow/PaneHider.hxx3
-rw-r--r--sd/source/ui/slideshow/SlideShowRestarter.cxx3
-rw-r--r--sd/source/ui/slideshow/SlideShowRestarter.hxx3
-rwxr-xr-xsd/source/ui/slideshow/makefile.mk65
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/showwin.cxx37
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/showwindow.hxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/slideshow.cxx58
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/slideshow.src0
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/slideshowimpl.cxx255
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slideshow/slideshowimpl.hxx7
-rw-r--r--sd/source/ui/slideshow/slideshowviewimpl.cxx33
-rw-r--r--sd/source/ui/slideshow/slideshowviewimpl.hxx7
-rw-r--r--sd/source/ui/slidesorter/cache/SlsBitmapCache.cxx5
-rw-r--r--sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsBitmapFactory.hxx3
-rw-r--r--sd/source/ui/slidesorter/cache/SlsCacheCompactor.cxx3
-rw-r--r--sd/source/ui/slidesorter/cache/SlsCacheCompactor.hxx3
-rw-r--r--sd/source/ui/slidesorter/cache/SlsCacheConfiguration.cxx130
-rw-r--r--sd/source/ui/slidesorter/cache/SlsCacheConfiguration.hxx4
-rw-r--r--sd/source/ui/slidesorter/cache/SlsGenericPageCache.cxx2
-rw-r--r--sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx3
-rw-r--r--sd/source/ui/slidesorter/cache/SlsPageCache.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsQueueProcessorThread.hxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsRequestFactory.cxx2
-rw-r--r--sd/source/ui/slidesorter/cache/SlsRequestFactory.hxx3
-rw-r--r--sd/source/ui/slidesorter/cache/SlsRequestPriorityClass.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx3
-rwxr-xr-xsd/source/ui/slidesorter/cache/makefile.mk64
-rw-r--r--sd/source/ui/slidesorter/controller/SlideSorterController.cxx69
-rw-r--r--sd/source/ui/slidesorter/controller/SlsAnimationFunction.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsAnimator.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsClipboard.cxx12
-rw-r--r--sd/source/ui/slidesorter/controller/SlsCommand.hxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsCurrentSlideManager.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsFocusManager.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsHideSlideFunction.cxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsHideSlideFunction.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsListener.cxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsListener.hxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsPageObjectFactory.cxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsPageSelector.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsProperties.cxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsSelectionCommand.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsSelectionCommand.hxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsSelectionManager.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsSlideFunction.cxx3
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSlotManager.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/controller/SlsTransferable.cxx3
-rwxr-xr-xsd/source/ui/slidesorter/controller/makefile.mk69
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/cache/SlsCacheContext.hxx2
-rw-r--r--sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsClipboard.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsCurrentSlideManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsFocusManager.hxx2
-rw-r--r--sd/source/ui/slidesorter/inc/controller/SlsPageObjectFactory.hxx2
-rw-r--r--sd/source/ui/slidesorter/inc/controller/SlsPageSelector.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsProperties.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/controller/SlsSelectionFunction.hxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsSelectionManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/controller/SlsSlideFunction.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/controller/SlsSlotManager.hxx2
-rw-r--r--sd/source/ui/slidesorter/inc/controller/SlsTransferable.hxx2
-rw-r--r--sd/source/ui/slidesorter/inc/model/SlideSorterModel.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/model/SlsEnumeration.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/model/SlsPageDescriptor.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/model/SlsPageEnumeration.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/model/SlsPageEnumerationProvider.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/model/SlsSharedPageDescriptor.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/view/SlideSorterView.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/view/SlsFontProvider.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/view/SlsLayouter.hxx3
-rw-r--r--sd/source/ui/slidesorter/inc/view/SlsPageObject.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/view/SlsPageObjectViewContact.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/inc/view/SlsPageObjectViewObjectContact.hxx3
-rw-r--r--sd/source/ui/slidesorter/makefile.mk58
-rw-r--r--sd/source/ui/slidesorter/model/SlideSorterModel.cxx5
-rw-r--r--sd/source/ui/slidesorter/model/SlsPageDescriptor.cxx3
-rw-r--r--sd/source/ui/slidesorter/model/SlsPageEnumeration.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/model/SlsPageEnumerationProvider.cxx6
-rwxr-xr-xsd/source/ui/slidesorter/model/makefile.mk57
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/shell/SlideSorter.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/shell/SlideSorterChildWindow.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/shell/SlideSorterService.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/shell/SlideSorterService.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx30
-rwxr-xr-xsd/source/ui/slidesorter/shell/makefile.mk55
-rw-r--r--sd/source/ui/slidesorter/view/SlideSorterView.cxx3
-rw-r--r--sd/source/ui/slidesorter/view/SlsButtonBar.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/view/SlsFontProvider.cxx3
-rw-r--r--sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx8
-rw-r--r--sd/source/ui/slidesorter/view/SlsLayouter.cxx3
-rw-r--r--sd/source/ui/slidesorter/view/SlsPageObject.cxx3
-rw-r--r--sd/source/ui/slidesorter/view/SlsResource.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx3
-rwxr-xr-xsd/source/ui/slidesorter/view/makefile.mk69
-rw-r--r--[-rwxr-xr-x]sd/source/ui/table/TableDesignPane.cxx20
-rw-r--r--sd/source/ui/table/TableDesignPane.hxx3
-rw-r--r--sd/source/ui/table/makefile.mk56
-rw-r--r--[-rwxr-xr-x]sd/source/ui/table/tablefunction.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/table/tableobjectbar.cxx3
-rw-r--r--sd/source/ui/table/tableobjectbar.hxx3
-rw-r--r--sd/source/ui/toolpanel/ConstrainedIterator.cxx3
-rw-r--r--sd/source/ui/toolpanel/ConstrainedIterator.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/ControlContainer.cxx3
-rw-r--r--sd/source/ui/toolpanel/ControlContainerDescriptor.hxx5
-rw-r--r--sd/source/ui/toolpanel/ControlList.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/LayoutMenu.cxx63
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/LayoutMenu.hxx5
-rw-r--r--sd/source/ui/toolpanel/MethodGuard.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/ScrollPanel.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/SlideSorterCacheDisplay.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/SubToolPanel.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneControlFactory.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneFocusManager.cxx33
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneFocusManager.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneShellManager.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneShellManager.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TaskPaneTreeNode.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TestMenu.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TestMenu.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TestPanel.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TestPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TitleBar.cxx26
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/TitledControl.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/ToolPanel.cxx3
-rw-r--r--sd/source/ui/toolpanel/ToolPanel.hxx3
-rw-r--r--sd/source/ui/toolpanel/ToolPanelDescriptor.hxx3
-rw-r--r--sd/source/ui/toolpanel/ToolPanelFactory.cxx7
-rw-r--r--sd/source/ui/toolpanel/ToolPanelUIElement.cxx3
-rw-r--r--sd/source/ui/toolpanel/ToolPanelUIElement.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/ToolPanelViewShell.cxx8
-rw-r--r--sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/AnimationSchemesPanel.cxx32
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/AnimationSchemesPanel.hxx32
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx3
-rw-r--r--sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/CustomAnimationPanel.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/CustomAnimationPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/DocumentHelper.cxx93
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/DocumentHelper.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainer.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainer.hxx3
-rw-r--r--sd/source/ui/toolpanel/controls/MasterPageContainerFiller.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainerFiller.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainerProviders.cxx19
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainerProviders.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainerQueue.cxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageContainerQueue.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageDescriptor.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageDescriptor.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPageObserver.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPagesPanel.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPagesPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx86
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/PreviewValueSet.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/PreviewValueSet.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx3
-rw-r--r--sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx3
-rw-r--r--sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.cxx209
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/SlideTransitionPanel.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/SlideTransitionPanel.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/TableDesignPanel.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/toolpanel/controls/TableDesignPanel.hxx3
-rwxr-xr-xsd/source/ui/toolpanel/controls/makefile.mk67
-rwxr-xr-xsd/source/ui/toolpanel/makefile.mk70
-rw-r--r--sd/source/ui/tools/AsynchronousCall.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/tools/ConfigurationAccess.cxx6
-rw-r--r--sd/source/ui/tools/EventMultiplexer.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/tools/IconCache.cxx7
-rw-r--r--sd/source/ui/tools/IdleDetection.cxx3
-rw-r--r--sd/source/ui/tools/PreviewRenderer.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/tools/PropertySet.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/tools/SdGlobalResourceContainer.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/tools/SlotStateListener.cxx5
-rw-r--r--sd/source/ui/tools/TimerBasedTaskExecution.cxx2
-rw-r--r--sd/source/ui/tools/makefile.mk61
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/DrawController.cxx76
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/SdUnoDrawView.cxx30
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/SdUnoOutlineView.cxx44
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/SdUnoSlideView.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/UnoDocumentSettings.cxx37
-rw-r--r--sd/source/ui/unoidl/UnoDocumentSettings.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/detreg.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/facreg.cxx9
-rwxr-xr-xsd/source/ui/unoidl/makefile.mk90
-rw-r--r--sd/source/ui/unoidl/randomnode.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/sddetect.cxx40
-rw-r--r--sd/source/ui/unoidl/sddetect.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unocpres.cxx34
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unocpres.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unodoc.cxx8
-rw-r--r--sd/source/ui/unoidl/unohelp.hxx3
-rw-r--r--sd/source/ui/unoidl/unokywds.cxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unolayer.cxx50
-rw-r--r--sd/source/ui/unoidl/unolayer.hxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unomodel.cxx434
-rw-r--r--sd/source/ui/unoidl/unomodule.cxx10
-rw-r--r--sd/source/ui/unoidl/unomodule.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unoobj.cxx101
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unoobj.hxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unopage.cxx196
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unopage.hxx9
-rw-r--r--sd/source/ui/unoidl/unopback.cxx18
-rw-r--r--sd/source/ui/unoidl/unopback.hxx2
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unopool.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unosrch.cxx23
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unowcntr.cxx70
-rw-r--r--[-rwxr-xr-x]sd/source/ui/unoidl/unowcntr.hxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/DocumentRenderer.cxx65
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/DocumentRenderer.src0
-rw-r--r--sd/source/ui/view/FormShellManager.cxx99
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/GraphicObjectBar.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/GraphicViewShellBase.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ImpressViewShellBase.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/MediaObjectBar.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/OutlineViewShellBase.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/Outliner.cxx18
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/OutlinerIterator.cxx11
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/PresentationViewShellBase.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/SlideSorterViewShellBase.cxx4
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ToolBarManager.cxx5
-rw-r--r--sd/source/ui/view/UpdateLockManager.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ViewClipboard.cxx99
-rw-r--r--sd/source/ui/view/ViewShellBase.cxx33
-rw-r--r--sd/source/ui/view/ViewShellHint.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ViewShellImplementation.cxx17
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ViewShellManager.cxx113
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/ViewTabBar.cxx39
-rw-r--r--sd/source/ui/view/WindowUpdater.cxx13
-rwxr-xr-xsd/source/ui/view/bmcache.cxx78
-rw-r--r--sd/source/ui/view/clview.cxx10
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drawview.cxx28
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drbezob.cxx3
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drtxtob.cxx50
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drtxtob1.cxx40
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews1.cxx103
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews2.cxx47
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews3.cxx111
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews4.cxx51
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews5.cxx30
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews6.cxx27
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews7.cxx50
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews8.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviews9.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsa.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsb.cxx21
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsc.cxx43
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsd.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewse.cxx48
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsf.cxx28
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsg.cxx20
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsh.cxx9
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsi.cxx7
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drviewsj.cxx65
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/drvwshrg.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/frmview.cxx158
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/grviewsh.cxx3
-rw-r--r--sd/source/ui/view/makefile.mk123
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/outlnvs2.cxx53
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/outlnvsh.cxx275
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/outlview.cxx450
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/presvish.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdruler.cxx13
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdview.cxx35
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdview2.cxx8
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdview3.cxx70
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdview4.cxx46
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdview5.cxx5
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/sdwindow.cxx34
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/tabcontr.cxx41
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/unmodpg.cxx6
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/viewoverlaymanager.cxx15
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/viewshe2.cxx12
-rw-r--r--sd/source/ui/view/viewshe3.cxx31
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/viewshel.cxx105
-rw-r--r--[-rwxr-xr-x]sd/source/ui/view/zoomlist.cxx113
-rw-r--r--sd/source/unotypes/makefile.mk53
-rwxr-xr-xsd/uiconfig/sdraw/menubar/menubar.xml7
-rw-r--r--sd/uiconfig/sdraw/statusbar/statusbar.xml2
-rw-r--r--sd/uiconfig/sdraw/toolbar/toolbar.xml4
-rwxr-xr-xsd/uiconfig/simpress/menubar/menubar.xml11
-rw-r--r--sd/uiconfig/simpress/statusbar/statusbar.xml2
-rw-r--r--sd/uiconfig/simpress/toolbar/toolbar.xml4
-rw-r--r--[-rwxr-xr-x]sd/util/hidother.src0
-rwxr-xr-xsd/util/makefile.mk291
-rw-r--r--sd/util/sdfilt.component7
-rw-r--r--sd/util/sdfilt.map2
-rw-r--r--sd/workben/custompanel/ctp_panel.cxx3
-rw-r--r--sd/workben/custompanel/ctp_panel.hxx3
-rw-r--r--sd/workben/testdll/makefile28
-rw-r--r--sd/xml/transitions-ogl.xml15
-rw-r--r--sd/xml/transitions.xml3
-rw-r--r--slideshow/CppunitTest_slideshow.mk77
-rw-r--r--slideshow/Executable_demoshow.mk71
-rw-r--r--slideshow/Library_OGLTrans.mk111
-rw-r--r--slideshow/Library_slideshow.mk185
-rw-r--r--slideshow/Makefile (renamed from slideshow/inc/makefile.mk)27
-rw-r--r--slideshow/Module_slideshow.mk41
-rw-r--r--slideshow/inc/pch/precompiled_slideshow.cxx2
-rw-r--r--slideshow/inc/pch/precompiled_slideshow.hxx2
-rw-r--r--slideshow/prj/build.lst12
-rw-r--r--slideshow/prj/d.lst8
-rwxr-xr-x[-rw-r--r--]slideshow/prj/makefile.mk (renamed from sd/source/filter/grf/makefile.mk)22
-rw-r--r--slideshow/qa/debug/nodetree.sh4
-rw-r--r--slideshow/qa/debug/timings.pl3
-rw-r--r--slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.h94
-rw-r--r--slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.m231
-rw-r--r--slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.hxx497
-rw-r--r--slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.mm1326
-rw-r--r--slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionerImpl.mm1132
-rw-r--r--slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.h39
-rw-r--r--slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.m195
-rw-r--r--slideshow/source/engine/OGLTrans/makefile.mk88
-rw-r--r--slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.cxx142
-rw-r--r--slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.hxx (renamed from slideshow/source/engine/OGLTrans/OGLTrans_Shaders.hxx)5
-rw-r--r--slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.cxx (renamed from slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.cxx)11
-rw-r--r--slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.hxx (renamed from slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.hxx)15
-rw-r--r--slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl.cxx1482
-rw-r--r--slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.cxx (renamed from slideshow/source/engine/OGLTrans/OGLTrans_Shaders.cxx)4
-rw-r--r--slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.hxx71
-rw-r--r--slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.cxx1315
-rw-r--r--slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.hxx506
-rw-r--r--slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionerImpl.cxx (renamed from slideshow/source/engine/OGLTrans/OGLTrans_TransitionerImpl.cxx)57
-rw-r--r--slideshow/source/engine/activities/accumulation.hxx3
-rw-r--r--slideshow/source/engine/activities/activitiesfactory.cxx9
-rw-r--r--slideshow/source/engine/activities/activitybase.cxx3
-rw-r--r--slideshow/source/engine/activities/activitybase.hxx2
-rw-r--r--slideshow/source/engine/activities/activityparameters.hxx2
-rw-r--r--slideshow/source/engine/activities/continuousactivitybase.cxx3
-rw-r--r--slideshow/source/engine/activities/continuousactivitybase.hxx3
-rw-r--r--slideshow/source/engine/activities/continuouskeytimeactivitybase.cxx3
-rw-r--r--slideshow/source/engine/activities/continuouskeytimeactivitybase.hxx3
-rw-r--r--slideshow/source/engine/activities/discreteactivitybase.cxx3
-rw-r--r--slideshow/source/engine/activities/discreteactivitybase.hxx3
-rw-r--r--slideshow/source/engine/activities/interpolation.hxx12
-rw-r--r--slideshow/source/engine/activities/makefile.mk53
-rw-r--r--slideshow/source/engine/activities/simplecontinuousactivitybase.cxx3
-rw-r--r--slideshow/source/engine/activities/simplecontinuousactivitybase.hxx3
-rw-r--r--slideshow/source/engine/activitiesqueue.cxx8
-rw-r--r--slideshow/source/engine/animatedsprite.cxx3
-rw-r--r--slideshow/source/engine/animationfactory.cxx24
-rw-r--r--slideshow/source/engine/animationnodes/animationaudionode.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationaudionode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationbasenode.cxx4
-rw-r--r--slideshow/source/engine/animationnodes/animationbasenode.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationcolornode.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationcolornode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationcommandnode.cxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationcommandnode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationnodefactory.cxx11
-rw-r--r--slideshow/source/engine/animationnodes/animationpathmotionnode.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationpathmotionnode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationsetnode.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationsetnode.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/animationtransformnode.cxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationtransformnode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationtransitionfilternode.cxx3
-rw-r--r--slideshow/source/engine/animationnodes/animationtransitionfilternode.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/basecontainernode.cxx4
-rw-r--r--slideshow/source/engine/animationnodes/basecontainernode.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/basenode.cxx10
-rw-r--r--slideshow/source/engine/animationnodes/basenode.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/generateevent.cxx30
-rw-r--r--slideshow/source/engine/animationnodes/generateevent.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/makefile.mk61
-rw-r--r--slideshow/source/engine/animationnodes/nodetools.cxx3
-rw-r--r--slideshow/source/engine/animationnodes/nodetools.hxx3
-rw-r--r--slideshow/source/engine/animationnodes/paralleltimecontainer.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/paralleltimecontainer.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/propertyanimationnode.cxx2
-rw-r--r--slideshow/source/engine/animationnodes/propertyanimationnode.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/sequentialtimecontainer.cxx6
-rw-r--r--slideshow/source/engine/animationnodes/sequentialtimecontainer.hxx2
-rw-r--r--slideshow/source/engine/animationnodes/setactivity.hxx3
-rw-r--r--slideshow/source/engine/attributemap.cxx24
-rw-r--r--slideshow/source/engine/color.cxx85
-rw-r--r--slideshow/source/engine/debug.cxx55
-rw-r--r--slideshow/source/engine/delayevent.cxx2
-rw-r--r--slideshow/source/engine/effectrewinder.cxx3
-rw-r--r--slideshow/source/engine/effectrewinder.hxx3
-rw-r--r--slideshow/source/engine/eventmultiplexer.cxx6
-rw-r--r--slideshow/source/engine/eventqueue.cxx8
-rw-r--r--slideshow/source/engine/expressionnodefactory.cxx3
-rw-r--r--slideshow/source/engine/makefile.mk102
-rw-r--r--slideshow/source/engine/rehearsetimingsactivity.cxx12
-rw-r--r--slideshow/source/engine/rehearsetimingsactivity.hxx3
-rw-r--r--slideshow/source/engine/screenupdater.cxx3
-rw-r--r--slideshow/source/engine/shapeattributelayer.cxx3
-rw-r--r--slideshow/source/engine/shapes/appletshape.cxx3
-rw-r--r--slideshow/source/engine/shapes/appletshape.hxx3
-rw-r--r--slideshow/source/engine/shapes/backgroundshape.cxx3
-rw-r--r--slideshow/source/engine/shapes/backgroundshape.hxx3
-rw-r--r--slideshow/source/engine/shapes/drawinglayeranimation.cxx13
-rw-r--r--slideshow/source/engine/shapes/drawinglayeranimation.hxx2
-rw-r--r--slideshow/source/engine/shapes/drawshape.cxx11
-rw-r--r--slideshow/source/engine/shapes/drawshape.hxx3
-rw-r--r--slideshow/source/engine/shapes/drawshapesubsetting.cxx52
-rw-r--r--slideshow/source/engine/shapes/drawshapesubsetting.hxx3
-rw-r--r--slideshow/source/engine/shapes/externalshapebase.cxx5
-rw-r--r--slideshow/source/engine/shapes/externalshapebase.hxx3
-rw-r--r--slideshow/source/engine/shapes/gdimtftools.cxx61
-rw-r--r--slideshow/source/engine/shapes/gdimtftools.hxx3
-rw-r--r--slideshow/source/engine/shapes/intrinsicanimationactivity.cxx3
-rw-r--r--slideshow/source/engine/shapes/intrinsicanimationactivity.hxx3
-rw-r--r--slideshow/source/engine/shapes/makefile.mk60
-rw-r--r--slideshow/source/engine/shapes/mediashape.cxx3
-rw-r--r--slideshow/source/engine/shapes/mediashape.hxx3
-rw-r--r--slideshow/source/engine/shapes/shapeimporter.cxx16
-rw-r--r--slideshow/source/engine/shapes/viewappletshape.cxx11
-rw-r--r--slideshow/source/engine/shapes/viewappletshape.hxx3
-rw-r--r--slideshow/source/engine/shapes/viewbackgroundshape.cxx6
-rw-r--r--slideshow/source/engine/shapes/viewbackgroundshape.hxx3
-rw-r--r--slideshow/source/engine/shapes/viewmediashape.cxx28
-rw-r--r--slideshow/source/engine/shapes/viewmediashape.hxx3
-rw-r--r--slideshow/source/engine/shapes/viewshape.cxx7
-rw-r--r--slideshow/source/engine/shapes/viewshape.hxx5
-rw-r--r--slideshow/source/engine/shapesubset.cxx5
-rw-r--r--slideshow/source/engine/slide/layer.cxx3
-rw-r--r--slideshow/source/engine/slide/layer.hxx3
-rw-r--r--slideshow/source/engine/slide/layermanager.cxx24
-rw-r--r--slideshow/source/engine/slide/layermanager.hxx7
-rw-r--r--slideshow/source/engine/slide/makefile.mk51
-rw-r--r--slideshow/source/engine/slide/shapemanagerimpl.cxx11
-rw-r--r--slideshow/source/engine/slide/shapemanagerimpl.hxx3
-rw-r--r--slideshow/source/engine/slide/slideanimations.cxx5
-rw-r--r--slideshow/source/engine/slide/slideanimations.hxx3
-rw-r--r--slideshow/source/engine/slide/slideimpl.cxx55
-rw-r--r--slideshow/source/engine/slide/userpaintoverlay.cxx5
-rw-r--r--slideshow/source/engine/slide/userpaintoverlay.hxx3
-rw-r--r--slideshow/source/engine/slidebitmap.cxx6
-rw-r--r--slideshow/source/engine/slideshowcontext.cxx3
-rw-r--r--slideshow/source/engine/slideshowimpl.cxx477
-rw-r--r--slideshow/source/engine/slideview.cxx14
-rw-r--r--slideshow/source/engine/smilfunctionparser.cxx6
-rw-r--r--slideshow/source/engine/soundplayer.cxx5
-rw-r--r--slideshow/source/engine/sp_debug.cxx3
-rw-r--r--slideshow/source/engine/tools.cxx32
-rw-r--r--slideshow/source/engine/transitions/barndoorwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/barndoorwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/barwipepolypolygon.cxx3
-rw-r--r--slideshow/source/engine/transitions/barwipepolypolygon.hxx3
-rw-r--r--slideshow/source/engine/transitions/boxwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/boxwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/checkerboardwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/checkerboardwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/clippingfunctor.cxx5
-rw-r--r--slideshow/source/engine/transitions/clippingfunctor.hxx3
-rw-r--r--slideshow/source/engine/transitions/clockwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/clockwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/combtransition.cxx3
-rw-r--r--slideshow/source/engine/transitions/combtransition.hxx3
-rw-r--r--slideshow/source/engine/transitions/doublediamondwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/doublediamondwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/ellipsewipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/ellipsewipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/fanwipe.cxx2
-rw-r--r--slideshow/source/engine/transitions/fanwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/figurewipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/figurewipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/fourboxwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/fourboxwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/iriswipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/iriswipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/makefile.mk73
-rw-r--r--slideshow/source/engine/transitions/parametricpolypolygon.hxx3
-rw-r--r--slideshow/source/engine/transitions/parametricpolypolygonfactory.cxx3
-rw-r--r--slideshow/source/engine/transitions/parametricpolypolygonfactory.hxx3
-rw-r--r--slideshow/source/engine/transitions/pinwheelwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/pinwheelwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/randomwipe.cxx12
-rw-r--r--slideshow/source/engine/transitions/randomwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/shapetransitionfactory.cxx11
-rw-r--r--slideshow/source/engine/transitions/slidechangebase.cxx3
-rw-r--r--slideshow/source/engine/transitions/slidechangebase.hxx3
-rw-r--r--slideshow/source/engine/transitions/slidetransitionfactory.cxx130
-rw-r--r--slideshow/source/engine/transitions/snakewipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/snakewipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/spiralwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/spiralwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/sweepwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/sweepwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/transitionfactorytab.cxx17
-rw-r--r--slideshow/source/engine/transitions/transitiontools.cxx3
-rw-r--r--slideshow/source/engine/transitions/transitiontools.hxx3
-rw-r--r--slideshow/source/engine/transitions/veewipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/veewipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/waterfallwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/waterfallwipe.hxx3
-rw-r--r--slideshow/source/engine/transitions/zigzagwipe.cxx3
-rw-r--r--slideshow/source/engine/transitions/zigzagwipe.hxx3
-rw-r--r--slideshow/source/engine/unoviewcontainer.cxx3
-rw-r--r--slideshow/source/engine/usereventqueue.cxx4
-rw-r--r--slideshow/source/engine/waitsymbol.cxx11
-rw-r--r--slideshow/source/engine/waitsymbol.hxx3
-rw-r--r--slideshow/source/engine/wakeupevent.cxx5
-rw-r--r--slideshow/source/inc/activitiesfactory.hxx2
-rw-r--r--slideshow/source/inc/activitiesqueue.hxx3
-rw-r--r--slideshow/source/inc/activity.hxx3
-rw-r--r--slideshow/source/inc/animatableshape.hxx3
-rw-r--r--slideshow/source/inc/animatedsprite.hxx3
-rw-r--r--slideshow/source/inc/animation.hxx3
-rw-r--r--slideshow/source/inc/animationactivity.hxx3
-rw-r--r--slideshow/source/inc/animationeventhandler.hxx3
-rw-r--r--slideshow/source/inc/animationfactory.hxx3
-rw-r--r--slideshow/source/inc/animationfunction.hxx3
-rw-r--r--slideshow/source/inc/animationnode.hxx2
-rw-r--r--slideshow/source/inc/animationnodefactory.hxx3
-rw-r--r--slideshow/source/inc/attributableshape.hxx3
-rw-r--r--slideshow/source/inc/attributemap.hxx3
-rw-r--r--slideshow/source/inc/boolanimation.hxx3
-rw-r--r--slideshow/source/inc/coloranimation.hxx3
-rw-r--r--slideshow/source/inc/cursormanager.hxx3
-rw-r--r--slideshow/source/inc/debug.hxx3
-rw-r--r--slideshow/source/inc/delayevent.hxx3
-rw-r--r--slideshow/source/inc/disposable.hxx3
-rw-r--r--slideshow/source/inc/doctreenode.hxx3
-rw-r--r--slideshow/source/inc/doctreenodesupplier.hxx3
-rw-r--r--slideshow/source/inc/enumanimation.hxx3
-rw-r--r--slideshow/source/inc/event.hxx3
-rw-r--r--slideshow/source/inc/eventhandler.hxx3
-rw-r--r--slideshow/source/inc/eventmultiplexer.hxx4
-rw-r--r--slideshow/source/inc/eventqueue.hxx3
-rw-r--r--slideshow/source/inc/expressionnode.hxx3
-rw-r--r--slideshow/source/inc/expressionnodefactory.hxx3
-rw-r--r--slideshow/source/inc/externalmediashape.hxx3
-rw-r--r--slideshow/source/inc/framerate.hxx3
-rw-r--r--slideshow/source/inc/hslcolor.hxx19
-rw-r--r--slideshow/source/inc/hslcoloranimation.hxx3
-rw-r--r--slideshow/source/inc/hyperlinkarea.hxx3
-rw-r--r--slideshow/source/inc/hyperlinkhandler.hxx3
-rw-r--r--slideshow/source/inc/interruptabledelayevent.hxx5
-rw-r--r--slideshow/source/inc/intrinsicanimationeventhandler.hxx3
-rw-r--r--slideshow/source/inc/listenercontainer.hxx2
-rw-r--r--slideshow/source/inc/listenercontainerimpl.hxx2
-rw-r--r--slideshow/source/inc/mouseeventhandler.hxx3
-rw-r--r--slideshow/source/inc/numberanimation.hxx3
-rw-r--r--slideshow/source/inc/pairanimation.hxx3
-rw-r--r--slideshow/source/inc/pauseeventhandler.hxx3
-rw-r--r--slideshow/source/inc/rgbcolor.hxx28
-rw-r--r--slideshow/source/inc/screenupdater.hxx3
-rw-r--r--slideshow/source/inc/shape.hxx3
-rw-r--r--slideshow/source/inc/shapeattributelayer.hxx3
-rw-r--r--slideshow/source/inc/shapeattributelayerholder.hxx3
-rw-r--r--slideshow/source/inc/shapecursoreventhandler.hxx3
-rw-r--r--slideshow/source/inc/shapeimporter.hxx5
-rw-r--r--slideshow/source/inc/shapelistenereventhandler.hxx3
-rw-r--r--slideshow/source/inc/shapemanager.hxx3
-rw-r--r--slideshow/source/inc/shapemaps.hxx3
-rw-r--r--slideshow/source/inc/shapesubset.hxx3
-rw-r--r--slideshow/source/inc/slide.hxx3
-rw-r--r--slideshow/source/inc/slidebitmap.hxx3
-rw-r--r--slideshow/source/inc/slideshowcontext.hxx3
-rw-r--r--slideshow/source/inc/slideshowexceptions.hxx3
-rw-r--r--slideshow/source/inc/slideview.hxx2
-rw-r--r--slideshow/source/inc/smilfunctionparser.hxx3
-rw-r--r--slideshow/source/inc/soundplayer.hxx3
-rw-r--r--slideshow/source/inc/state.hxx3
-rw-r--r--slideshow/source/inc/stringanimation.hxx3
-rw-r--r--slideshow/source/inc/subsettableshapemanager.hxx3
-rw-r--r--slideshow/source/inc/tools.hxx7
-rw-r--r--slideshow/source/inc/transitionfactory.hxx3
-rw-r--r--slideshow/source/inc/transitioninfo.hxx3
-rw-r--r--slideshow/source/inc/unoview.hxx3
-rw-r--r--slideshow/source/inc/unoviewcontainer.hxx3
-rw-r--r--slideshow/source/inc/usereventqueue.hxx4
-rw-r--r--slideshow/source/inc/userpainteventhandler.hxx3
-rw-r--r--slideshow/source/inc/view.hxx3
-rw-r--r--slideshow/source/inc/vieweventhandler.hxx3
-rw-r--r--slideshow/source/inc/viewlayer.hxx3
-rw-r--r--slideshow/source/inc/viewrepainthandler.hxx3
-rw-r--r--slideshow/source/inc/viewupdate.hxx3
-rw-r--r--slideshow/source/inc/wakeupevent.hxx3
-rw-r--r--slideshow/test/demoshow.cxx28
-rw-r--r--slideshow/test/export.map2
-rw-r--r--slideshow/test/makefile.mk101
-rw-r--r--slideshow/test/slidetest.cxx8
-rw-r--r--slideshow/test/tests.hxx3
-rw-r--r--slideshow/test/testshape.cxx14
-rw-r--r--slideshow/test/testview.cxx22
-rw-r--r--slideshow/test/views.cxx14
-rw-r--r--slideshow/util/makefile.mk112
1307 files changed, 24463 insertions, 18806 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000..9ea0cd6eb
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,18 @@
+# backup and temporary files
+*~
+.*.sw[op]
+.gitattributes
+
+# the build directories
+/*/unxlng??
+/*/unxlng??.pro
+/*/wntmsc???
+/*/wntmsc???.pro
+/*/wntgcc?
+/*/wntgcc?.pro
+/*/unxmac??
+/*/unxmac??.pro
+/*/unxios?
+/*/unxios?.pro
+/*/unxand?
+/*/unxand?.pro
diff --git a/animations/inc/animations/animationnodehelper.hxx b/animations/inc/animations/animationnodehelper.hxx
index 9f8dc1c13..c6826d6e3 100644
--- a/animations/inc/animations/animationnodehelper.hxx
+++ b/animations/inc/animations/animationnodehelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -128,3 +129,5 @@ namespace anim
}
#endif /* INCLUDED_ANIMATIONS_ANIMATIONNODEHELPER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/animations/prj/d.lst b/animations/prj/d.lst
index 9a91b35b2..b0e6f3cd9 100644
--- a/animations/prj/d.lst
+++ b/animations/prj/d.lst
@@ -1,10 +1,10 @@
-..\%__SRC%\bin\animcore.dll %_DEST%\bin%_EXT%\animcore.dll
-..\%__SRC%\lib\libanimcore.so %_DEST%\lib%_EXT%\libanimcore.so
-..\%__SRC%\lib\*.dylib %_DEST%\lib%_EXT%\*
-..\source\animcore\animcore.xml %_DEST%\xml%_EXT%\animcore.xml
+..\%__SRC%\bin\animcore.dll %_DEST%\bin\animcore.dll
+..\%__SRC%\lib\libanimcore.so %_DEST%\lib\libanimcore.so
+..\%__SRC%\lib\*.dylib %_DEST%\lib\*
+..\source\animcore\animcore.xml %_DEST%\xml\animcore.xml
-..\%__SRC%\lib\lib*static*.dylib %_DEST%\lib%_EXT%\lib*static*.dylib
+..\%__SRC%\lib\lib*static*.dylib %_DEST%\lib\lib*static*.dylib
-mkdir: %_DEST%\inc%_EXT%\animations
-..\inc\animations\animationnodehelper.hxx %_DEST%\inc%_EXT%\animations\animationnodehelper.hxx
-..\%__SRC%\misc\animcore.component %_DEST%\xml%_EXT%\animcore.component
+mkdir: %_DEST%\inc\animations
+..\inc\animations\animationnodehelper.hxx %_DEST%\inc\animations\animationnodehelper.hxx
+..\%__SRC%\misc\animcore.component %_DEST%\xml\animcore.component
diff --git a/animations/source/animcore/animcore.cxx b/animations/source/animcore/animcore.cxx
index 59a619b21..cfed7a275 100644
--- a/animations/source/animcore/animcore.cxx
+++ b/animations/source/animcore/animcore.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,8 +53,8 @@
#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/util/XChangesNotifier.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
+#include <comphelper/servicehelper.hxx>
#include <cppuhelper/interfacecontainer.hxx>
-
#include <cppuhelper/implbase1.hxx>
#include <rtl/uuid.h>
@@ -242,8 +243,6 @@ public:
virtual void SAL_CALL setSubtype( sal_Int16 _subtype ) throw (RuntimeException);
virtual sal_Bool SAL_CALL getMode() throw (RuntimeException);
virtual void SAL_CALL setMode( sal_Bool _mode ) throw (RuntimeException);
-// virtual sal_Bool SAL_CALL getDirection() throw (RuntimeException);
-// virtual void SAL_CALL setDirection( sal_Bool _direction ) throw (RuntimeException);
virtual sal_Int32 SAL_CALL getFadeColor() throw (RuntimeException);
virtual void SAL_CALL setFadeColor( sal_Int32 _fadecolor ) throw (RuntimeException);
@@ -254,7 +253,7 @@ public:
virtual void SAL_CALL setVolume( double _volume ) throw (RuntimeException);
- // XCommand
+ // XCommand - the following two shadowed by animate, unfortunately
// virtual Any SAL_CALL getTarget() throw (RuntimeException);
// virtual void SAL_CALL setTarget( const Any& _target ) throw (RuntimeException);
virtual sal_Int16 SAL_CALL getCommand() throw (RuntimeException);
@@ -745,7 +744,7 @@ void SAL_CALL AnimationNode::acquire( ) throw ()
// XInterface
void SAL_CALL AnimationNode::release( ) throw ()
{
- OWeakObject::acquire();
+ OWeakObject::release();
}
// --------------------------------------------------------------------
@@ -1875,7 +1874,7 @@ Reference< XAnimationNode > SAL_CALL AnimationNode::insertAfter( const Reference
if( ::std::find(maChilds.begin(), maChilds.end(), newChild) != maChilds.end() )
throw ElementExistException();
- before++;
+ ++before;
if( before != maChilds.end() )
maChilds.insert( before, newChild );
else
@@ -2042,22 +2041,14 @@ void SAL_CALL AnimationNode::removeChangesListener( const Reference< XChangesLis
}
}
-// --------------------------------------------------------------------
+namespace
+{
+ class theAnimationNodeUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theAnimationNodeUnoTunnelId > {};
+}
const ::com::sun::star::uno::Sequence< sal_Int8 > & AnimationNode::getUnoTunnelId()
{
- static ::com::sun::star::uno::Sequence< sal_Int8 > * pSeq = 0;
- if( !pSeq )
- {
- ::osl::Guard< ::osl::Mutex > aGuard( ::osl::Mutex::getGlobalMutex() );
- if( !pSeq )
- {
- static ::com::sun::star::uno::Sequence< sal_Int8 > aSeq( 16 );
- rtl_createUuid( (sal_uInt8*)aSeq.getArray(), 0, sal_True );
- pSeq = &aSeq;
- }
- }
- return *pSeq;
+ return theAnimationNodeUnoTunnelId::get().getSeq();
}
// --------------------------------------------------------------------
@@ -2087,3 +2078,5 @@ void AnimationNode::fireChangeListener()
// --------------------------------------------------------------------
} // namespace animcore
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/animations/source/animcore/animcore.xml b/animations/source/animcore/animcore.xml
index 028008fc7..22c3ddda6 100644
--- a/animations/source/animcore/animcore.xml
+++ b/animations/source/animcore/animcore.xml
@@ -19,12 +19,10 @@
<project-build-dependency> cppuhelper </project-build-dependency>
<project-build-dependency> cppu </project-build-dependency>
- <project-build-dependency> vos </project-build-dependency>
<project-build-dependency> sal </project-build-dependency>
<runtime-module-dependency> cppuhelper </runtime-module-dependency>
<runtime-module-dependency> cppu2 </runtime-module-dependency>
- <runtime-module-dependency> vos2MSC </runtime-module-dependency>
<runtime-module-dependency> sal2 </runtime-module-dependency>
</module-description>
diff --git a/animations/source/animcore/factreg.cxx b/animations/source/animcore/factreg.cxx
index 060ef6823..9aa48477b 100644
--- a/animations/source/animcore/factreg.cxx
+++ b/animations/source/animcore/factreg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79,16 +80,18 @@ sal_Bool SAL_CALL component_canUnload( TimeValue *pTime )
}
//==================================================================================================
-void SAL_CALL component_getImplementationEnvironment(
+SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** )
{
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//==================================================================================================
-void * SAL_CALL component_getFactory(
+SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory(
const sal_Char * pImplName, void * pServiceManager, void * pRegistryKey )
{
return component_getFactoryHelper( pImplName, pServiceManager, pRegistryKey , g_entries );
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/animations/source/animcore/factreg.hxx b/animations/source/animcore/factreg.hxx
index d066db028..c9e0b1ad2 100644
--- a/animations/source/animcore/factreg.hxx
+++ b/animations/source/animcore/factreg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,5 @@ DECL_NODE_FACTORY( COMMAND );
DECL_NODE_FACTORY( TargetPropertiesCreator );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/animations/source/animcore/makefile.mk b/animations/source/animcore/makefile.mk
index 674858cd5..9c6b4a2cd 100644
--- a/animations/source/animcore/makefile.mk
+++ b/animations/source/animcore/makefile.mk
@@ -24,24 +24,21 @@
# for a copy of the LGPLv3 License.
#
#*************************************************************************
+
PRJ=..$/..
PRJNAME=animations
TARGET=animcore
ENABLE_EXCEPTIONS=TRUE
NO_BSYMBOLIC=TRUE
-#COMP1TYPELIST=$(TARGET)
-#COMPRDB=$(SOLARBINDIR)$/offapi.rdb
# --- Settings -----------------------------------------------------
+
.INCLUDE : settings.mk
+
.IF "$(L10N_framework)"==""
-# --- Files --------------------------------------------------------
-#UNOUCRDEP=$(SOLARBINDIR)$/offapi.rdb
-#UNOUCRRDB=$(SOLARBINDIR)$/offapi.rdb
-#UNOUCROUT=$(OUT)$/inc$/animations
-#INCPRE+= $(UNOUCROUT)
+# --- Files --------------------------------------------------------
SLOFILES = $(SLO)$/animcore.obj\
$(SLO)$/factreg.obj\
@@ -68,7 +65,6 @@ DEF1NAME= $(SHL1TARGET)
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
-
ALLTAR : $(MISC)/animcore.component
$(MISC)/animcore.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
diff --git a/animations/source/animcore/targetpropertiescreator.cxx b/animations/source/animcore/targetpropertiescreator.cxx
index 181d2c628..f0b343988 100644
--- a/animations/source/animcore/targetpropertiescreator.cxx
+++ b/animations/source/animcore/targetpropertiescreator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,7 +49,7 @@
#include <animations/animationnodehelper.hxx>
#include <vector>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
using namespace ::com::sun::star;
@@ -140,7 +141,7 @@ namespace animcore
*/
sal_Int16 mnParagraphIndex;
- /// Comparison needed for hash_map
+ /// Comparison needed for boost::unordered_map
bool operator==( const ShapeHashKey& rRHS ) const
{
return mxRef == rRHS.mxRef && mnParagraphIndex == rRHS.mnParagraphIndex;
@@ -148,7 +149,7 @@ namespace animcore
};
// A hash map which maps a XShape to the corresponding vector of initial properties
- typedef ::std::hash_map< ShapeHashKey,
+ typedef ::boost::unordered_map< ShapeHashKey,
VectorOfNamedValues,
::std::size_t (*)(const ShapeHashKey&) > XShapeHash;
@@ -194,8 +195,7 @@ namespace animcore
{
if( !xNode.is() )
{
- OSL_ENSURE( false,
- "AnimCore: NodeFunctor::operator(): invalid XAnimationNode" );
+ OSL_FAIL( "AnimCore: NodeFunctor::operator(): invalid XAnimationNode" );
return;
}
@@ -216,8 +216,7 @@ namespace animcore
// TODO(E1): I'm not too sure what to expect here...
if( !xIterNode->getTarget().hasValue() )
{
- OSL_ENSURE( false,
- "animcore: NodeFunctor::operator(): no target on ITERATE node" );
+ OSL_FAIL( "animcore: NodeFunctor::operator(): no target on ITERATE node" );
return;
}
@@ -231,8 +230,7 @@ namespace animcore
// no shape provided. Maybe a ParagraphTarget?
if( !(xIterNode->getTarget() >>= aTarget) )
{
- OSL_ENSURE( false,
- "animcore: NodeFunctor::operator(): could not extract any "
+ OSL_FAIL( "animcore: NodeFunctor::operator(): could not extract any "
"target information" );
return;
}
@@ -242,8 +240,7 @@ namespace animcore
if( !xTargetShape.is() )
{
- OSL_ENSURE( false,
- "animcore: NodeFunctor::operator(): invalid shape in ParagraphTarget" );
+ OSL_FAIL( "animcore: NodeFunctor::operator(): invalid shape in ParagraphTarget" );
return;
}
}
@@ -259,8 +256,7 @@ namespace animcore
if( !::anim::for_each_childNode( xNode,
aFunctor ) )
{
- OSL_ENSURE( false,
- "AnimCore: NodeFunctor::operator(): child node iteration failed, "
+ OSL_FAIL( "AnimCore: NodeFunctor::operator(): child node iteration failed, "
"or extraneous container nodes encountered" );
}
}
@@ -319,8 +315,7 @@ namespace animcore
if( !(xAnimateNode->getTarget() >>= aUnoTarget) )
{
- OSL_ENSURE( false,
- "AnimCore: NodeFunctor::operator(): unknown target type encountered" );
+ OSL_FAIL( "AnimCore: NodeFunctor::operator(): unknown target type encountered" );
break;
}
@@ -331,8 +326,7 @@ namespace animcore
if( !aTarget.mxRef.is() )
{
- OSL_ENSURE( false,
- "AnimCore: NodeFunctor::operator(): Found target, but XShape is NULL" );
+ OSL_FAIL( "AnimCore: NodeFunctor::operator(): Found target, but XShape is NULL" );
break; // invalid target XShape
}
@@ -501,3 +495,5 @@ namespace animcore
}
} // namespace animcore
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/AllLangResTarget_sd.mk b/sd/AllLangResTarget_sd.mk
new file mode 100644
index 000000000..68a5c6bf1
--- /dev/null
+++ b/sd/AllLangResTarget_sd.mk
@@ -0,0 +1,110 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_AllLangResTarget_AllLangResTarget,sd))
+
+$(eval $(call gb_AllLangResTarget_set_reslocation,sd,sd))
+
+$(eval $(call gb_AllLangResTarget_add_srs,sd,\
+ sd/res \
+))
+
+$(eval $(call gb_SrsTarget_SrsTarget,sd/res))
+
+$(eval $(call gb_SrsTarget_set_include,sd/res,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/source/ui/inc) \
+ -I$(realpath $(SRCDIR)/sd/source/ui/slidesorter/inc) \
+ -I$(WORKDIR)/inc/sd \
+ -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_SrsTarget_add_files,sd/res,\
+ sd/source/core/glob.src \
+ sd/source/filter/html/pubdlg.src \
+ sd/source/ui/accessibility/accessibility.src \
+ sd/source/ui/animations/CustomAnimationCreateDialog.src \
+ sd/source/ui/animations/CustomAnimationDialog.src \
+ sd/source/ui/animations/CustomAnimationPane.src \
+ sd/source/ui/animations/CustomAnimation.src \
+ sd/source/ui/animations/SlideTransitionPane.src \
+ sd/source/ui/annotations/annotations.src \
+ sd/source/ui/app/app.src \
+ sd/source/ui/app/popup.src \
+ sd/source/ui/app/res_bmp.src \
+ sd/source/ui/app/sdstring.src \
+ sd/source/ui/app/strings.src \
+ sd/source/ui/app/toolbox.src \
+ sd/source/ui/dlg/animobjs.src \
+ sd/source/ui/dlg/brkdlg.src \
+ sd/source/ui/dlg/copydlg.src \
+ sd/source/ui/dlg/custsdlg.src \
+ sd/source/ui/dlg/dlgass.src \
+ sd/source/ui/dlg/dlg_char.src \
+ sd/source/ui/dlg/dlgfield.src \
+ sd/source/ui/dlg/dlgolbul.src \
+ sd/source/ui/dlg/dlgpage.src \
+ sd/source/ui/dlg/dlgsnap.src \
+ sd/source/ui/dlg/headerfooterdlg.src \
+ sd/source/ui/dlg/inspagob.src \
+ sd/source/ui/dlg/ins_paste.src \
+ sd/source/ui/dlg/LayerDialog.src \
+ sd/source/ui/dlg/layeroptionsdlg.src \
+ sd/source/ui/dlg/masterlayoutdlg.src \
+ sd/source/ui/dlg/morphdlg.src \
+ sd/source/ui/dlg/navigatr.src \
+ sd/source/ui/dlg/PaneDockingWindow.src \
+ sd/source/ui/dlg/paragr.src \
+ sd/source/ui/dlg/present.src \
+ sd/source/ui/dlg/prltempl.src \
+ sd/source/ui/dlg/prntopts.src \
+ sd/source/ui/dlg/sdpreslt.src \
+ sd/source/ui/dlg/tabtempl.src \
+ sd/source/ui/dlg/tpaction.src \
+ sd/source/ui/dlg/tpoption.src \
+ sd/source/ui/dlg/vectdlg.src \
+ sd/source/ui/notes/NotesChildWindow.src \
+ sd/source/ui/slideshow/slideshow.src \
+ sd/source/ui/slidesorter/view/SlsResource.src \
+ sd/source/ui/table/TableDesignPane.src \
+ sd/source/ui/view/DocumentRenderer.src \
+))
+
+$(eval $(call gb_SrsTarget_add_templates,sd/res,\
+ sd/source/ui/app/menuids2_tmpl.src \
+ sd/source/ui/app/menuids3_tmpl.src \
+ sd/source/ui/app/menuids4_tmpl.src \
+ sd/source/ui/app/menuids_tmpl.src \
+ sd/source/ui/app/menuportal_tmpl.src \
+ sd/source/ui/app/menu_tmpl.src \
+ sd/source/ui/app/popup2_tmpl.src \
+ sd/source/ui/app/tbxids_tmpl.src \
+ sd/source/ui/app/toolbox2_tmpl.src \
+))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/CppunitTest_sd_uimpress.mk b/sd/CppunitTest_sd_uimpress.mk
new file mode 100644
index 000000000..69db5c2b6
--- /dev/null
+++ b/sd/CppunitTest_sd_uimpress.mk
@@ -0,0 +1,103 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_CppunitTest_CppunitTest,sd_uimpress))
+
+$(eval $(call gb_CppunitTest_set_include,sd_uimpress,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_CppunitTest_set_defs,sd_uimpress,\
+ $$(DEFS) \
+ -DSD_DLLIMPLEMENTATION \
+))
+
+$(eval $(call gb_CppunitTest_add_library_objects,sd_uimpress,sd))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,sd_uimpress,\
+ avmedia \
+ basegfx \
+ canvastools \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ drawinglayer \
+ editeng \
+ i18nisolang1 \
+ sal \
+ salhelper \
+ sb \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ svx \
+ tk \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ xo \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sd_uimpress,\
+ sd/qa/unit/uimpress \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,sd_uimpress))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,sd_uimpress,\
+ types \
+))
+
+$(eval $(call gb_CppunitTest_add_service_rdbs,sd_uimpress,\
+ sd_uimpress \
+))
+
+$(eval $(call gb_CppunitTest_set_args,sd_uimpress,\
+ --headless \
+ --invisible \
+))
+
+$(eval $(call gb_RdbTarget_RdbTarget,sd_uimpress))
+
+$(eval $(call gb_RdbTarget_add_components,sd_uimpress,\
+ framework/util/fwk \
+))
+
+$(eval $(call gb_RdbTarget_add_old_components,sd_uimpress,\
+ i18npool \
+))
+
+# vim: set noet sw=4:
diff --git a/sd/JunitTest_sd_unoapi.mk b/sd/JunitTest_sd_unoapi.mk
new file mode 100644
index 000000000..6afd01f60
--- /dev/null
+++ b/sd/JunitTest_sd_unoapi.mk
@@ -0,0 +1,49 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# Bjoern Michaelsen, Canonical Ltd. <bjoern.michaelsen@canonical.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_JunitTest_JunitTest,sd_unoapi))
+
+$(eval $(call gb_JunitTest_set_defs,sd_unoapi,\
+ $$(DEFS) \
+ -Dorg.openoffice.test.arg.sce=$(SRCDIR)/sd/qa/unoapi/sd.sce \
+ -Dorg.openoffice.test.arg.xcl=$(SRCDIR)/sd/qa/unoapi/knownissues.xcl \
+ -Dorg.openoffice.test.arg.tdoc=$(SRCDIR)/sd/qa/unoapi/testdocuments \
+))
+
+$(eval $(call gb_JunitTest_add_jars,sd_unoapi,\
+ $(OUTDIR)/bin/OOoRunner.jar \
+ $(OUTDIR)/bin/ridl.jar \
+ $(OUTDIR)/bin/test.jar \
+ $(OUTDIR)/bin/unoil.jar \
+ $(OUTDIR)/bin/jurt.jar \
+))
+
+$(eval $(call gb_JunitTest_add_classes,sd_unoapi,\
+ org.openoffice.test.UnoApiTest \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/sd/Library_sd.mk b/sd/Library_sd.mk
new file mode 100644
index 000000000..a96e3b8e2
--- /dev/null
+++ b/sd/Library_sd.mk
@@ -0,0 +1,520 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,sd))
+
+$(eval $(call gb_Library_add_precompiled_header,sd,$(SRCDIR)/sd/inc/pch/precompiled_sd))
+
+$(eval $(call gb_Library_add_sdi_headers,sd,\
+ sd/sdi/sdgslots \
+ sd/sdi/sdslots \
+))
+
+$(eval $(call gb_Library_set_include,sd,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/inc/pch) \
+ -I$(realpath $(SRCDIR)/sd/sdi) \
+ -I$(realpath $(SRCDIR)/sd/source/ui/inc) \
+ -I$(realpath $(SRCDIR)/sd/source/ui/slidesorter/inc) \
+ -I$(WORKDIR)/inc/sd \
+ -I$(WORKDIR)/SdiTarget/sd/sdi \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_set_defs,sd,\
+ $$(DEFS) \
+ -DSD_DLLIMPLEMENTATION \
+))
+
+ifneq ($(strip $(dbg_anim_log)$(DBG_ANIM_LOG)),)
+$(eval $(call gb_Library_set_defs,sd,\
+ $$(DEFS) \
+ -DDBG_ANIM_LOG \
+))
+endif
+
+$(eval $(call gb_Library_add_linked_libs,sd,\
+ avmedia \
+ basegfx \
+ canvastools \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ drawinglayer \
+ editeng \
+ i18nisolang1 \
+ oox \
+ sal \
+ salhelper \
+ sax \
+ sb \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ svx \
+ tk \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_set_componentfile,sd,sd/util/sd))
+
+$(eval $(call gb_Library_add_exception_objects,sd,\
+ sd/source/core/anminfo \
+ sd/source/core/annotations/Annotation \
+ sd/source/core/annotations/AnnotationEnumeration \
+ sd/source/core/cusshow \
+ sd/source/core/CustomAnimationCloner \
+ sd/source/core/CustomAnimationEffect \
+ sd/source/core/CustomAnimationPreset \
+ sd/source/core/drawdoc \
+ sd/source/core/drawdoc2 \
+ sd/source/core/drawdoc3 \
+ sd/source/core/drawdoc4 \
+ sd/source/core/drawdoc_animations \
+ sd/source/core/EffectMigration \
+ sd/source/core/PageListWatcher \
+ sd/source/core/pglink \
+ sd/source/core/sdattr \
+ sd/source/core/sdiocmpt \
+ sd/source/core/sdobjfac \
+ sd/source/core/sdpage \
+ sd/source/core/sdpage2 \
+ sd/source/core/sdpage_animations \
+ sd/source/core/shapelist \
+ sd/source/core/stlfamily \
+ sd/source/core/stlpool \
+ sd/source/core/stlsheet \
+ sd/source/core/text/textapi \
+ sd/source/core/TransitionPreset \
+ sd/source/core/typemap \
+ sd/source/core/undoanim \
+ sd/source/core/undo/undofactory \
+ sd/source/core/undo/undomanager \
+ sd/source/core/undo/undoobjects \
+ sd/source/filter/cgm/sdcgmfilter \
+ sd/source/filter/grf/sdgrffilter \
+ sd/source/filter/html/buttonset \
+ sd/source/filter/html/htmlex \
+ sd/source/filter/html/HtmlOptionsDialog \
+ sd/source/filter/html/sdhtmlfilter \
+ sd/source/filter/sdfilter \
+ sd/source/filter/sdpptwrp \
+ sd/source/filter/xml/sdtransform \
+ sd/source/filter/xml/sdxmlwrp \
+ sd/source/helper/simplereferencecomponent \
+ sd/source/ui/accessibility/AccessibleDocumentViewBase \
+ sd/source/ui/accessibility/AccessibleDrawDocumentView \
+ sd/source/ui/accessibility/AccessibleOutlineEditSource \
+ sd/source/ui/accessibility/AccessibleOutlineView \
+ sd/source/ui/accessibility/AccessiblePageShape \
+ sd/source/ui/accessibility/AccessiblePresentationGraphicShape \
+ sd/source/ui/accessibility/AccessiblePresentationOLEShape \
+ sd/source/ui/accessibility/AccessiblePresentationShape \
+ sd/source/ui/accessibility/AccessibleScrollPanel \
+ sd/source/ui/accessibility/AccessibleSlideSorterObject \
+ sd/source/ui/accessibility/AccessibleSlideSorterView \
+ sd/source/ui/accessibility/AccessibleTreeNode \
+ sd/source/ui/accessibility/AccessibleViewForwarder \
+ sd/source/ui/accessibility/SdShapeTypes \
+ sd/source/ui/animations/CustomAnimationCreateDialog \
+ sd/source/ui/animations/CustomAnimationDialog \
+ sd/source/ui/animations/CustomAnimationList \
+ sd/source/ui/animations/CustomAnimationPane \
+ sd/source/ui/animations/DialogListBox \
+ sd/source/ui/animations/motionpathtag \
+ sd/source/ui/animations/SlideTransitionPane \
+ sd/source/ui/animations/STLPropertySet \
+ sd/source/ui/annotations/annotationmanager \
+ sd/source/ui/annotations/annotationtag \
+ sd/source/ui/annotations/annotationwindow \
+ sd/source/ui/app/sddll \
+ sd/source/ui/app/sddll1 \
+ sd/source/ui/app/sddll2 \
+ sd/source/ui/app/sdmod \
+ sd/source/ui/app/sdmod1 \
+ sd/source/ui/app/sdmod2 \
+ sd/source/ui/app/sdpopup \
+ sd/source/ui/app/sdxfer \
+ sd/source/ui/app/tbxww \
+ sd/source/ui/app/tmplctrl \
+ sd/source/ui/controller/slidelayoutcontroller \
+ sd/source/ui/dlg/AnimationChildWindow \
+ sd/source/ui/dlg/animobjs \
+ sd/source/ui/dlg/assclass \
+ sd/source/ui/dlg/diactrl \
+ sd/source/ui/dlg/dlgctrls \
+ sd/source/ui/dlg/docprev \
+ sd/source/ui/dlg/filedlg \
+ sd/source/ui/dlg/gluectrl \
+ sd/source/ui/dlg/ins_paste \
+ sd/source/ui/dlg/LayerDialogChildWindow \
+ sd/source/ui/dlg/LayerDialogContent \
+ sd/source/ui/dlg/layeroptionsdlg \
+ sd/source/ui/dlg/LayerTabBar \
+ sd/source/ui/dlg/NavigatorChildWindow \
+ sd/source/ui/dlg/navigatr \
+ sd/source/ui/dlg/PaneChildWindows \
+ sd/source/ui/dlg/PaneDockingWindow \
+ sd/source/ui/dlg/PaneShells \
+ sd/source/ui/dlg/sdabstdlg \
+ sd/source/ui/dlg/sdtreelb \
+ sd/source/ui/dlg/SpellDialogChildWindow \
+ sd/source/ui/dlg/TemplateScanner \
+ sd/source/ui/dlg/unchss \
+ sd/source/ui/docshell/docshel2 \
+ sd/source/ui/docshell/docshel3 \
+ sd/source/ui/docshell/docshel4 \
+ sd/source/ui/docshell/docshell \
+ sd/source/ui/docshell/grdocsh \
+ sd/source/ui/docshell/sdclient \
+ sd/source/ui/framework/configuration/ChangeRequestQueue \
+ sd/source/ui/framework/configuration/ChangeRequestQueueProcessor \
+ sd/source/ui/framework/configuration/Configuration \
+ sd/source/ui/framework/configuration/ConfigurationClassifier \
+ sd/source/ui/framework/configuration/ConfigurationController \
+ sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster \
+ sd/source/ui/framework/configuration/ConfigurationControllerResourceManager \
+ sd/source/ui/framework/configuration/ConfigurationTracer \
+ sd/source/ui/framework/configuration/ConfigurationUpdater \
+ sd/source/ui/framework/configuration/GenericConfigurationChangeRequest \
+ sd/source/ui/framework/configuration/ResourceFactoryManager \
+ sd/source/ui/framework/configuration/ResourceId \
+ sd/source/ui/framework/configuration/UpdateRequest \
+ sd/source/ui/framework/factories/BasicPaneFactory \
+ sd/source/ui/framework/factories/BasicToolBarFactory \
+ sd/source/ui/framework/factories/BasicViewFactory \
+ sd/source/ui/framework/factories/ChildWindowPane \
+ sd/source/ui/framework/factories/FrameWindowPane \
+ sd/source/ui/framework/factories/FullScreenPane \
+ sd/source/ui/framework/factories/Pane \
+ sd/source/ui/framework/factories/PresentationFactory \
+ sd/source/ui/framework/factories/TaskPanelFactory \
+ sd/source/ui/framework/factories/ViewShellWrapper \
+ sd/source/ui/framework/module/CenterViewFocusModule \
+ sd/source/ui/framework/module/DrawModule \
+ sd/source/ui/framework/module/ImpressModule \
+ sd/source/ui/framework/module/ModuleController \
+ sd/source/ui/framework/module/PresentationModule \
+ sd/source/ui/framework/module/ReadOnlyModeObserver \
+ sd/source/ui/framework/module/ResourceManager \
+ sd/source/ui/framework/module/ShellStackGuard \
+ sd/source/ui/framework/module/SlideSorterModule \
+ sd/source/ui/framework/module/ToolBarModule \
+ sd/source/ui/framework/module/ToolPanelModule \
+ sd/source/ui/framework/module/ViewTabBarModule \
+ sd/source/ui/framework/tools/FrameworkHelper \
+ sd/source/ui/func/bulmaper \
+ sd/source/ui/func/fuarea \
+ sd/source/ui/func/fubullet \
+ sd/source/ui/func/fuchar \
+ sd/source/ui/func/fucon3d \
+ sd/source/ui/func/fuconarc \
+ sd/source/ui/func/fuconbez \
+ sd/source/ui/func/fuconcs \
+ sd/source/ui/func/fuconnct \
+ sd/source/ui/func/fuconrec \
+ sd/source/ui/func/fuconstr \
+ sd/source/ui/func/fuconuno \
+ sd/source/ui/func/fucopy \
+ sd/source/ui/func/fucushow \
+ sd/source/ui/func/fudraw \
+ sd/source/ui/func/fudspord \
+ sd/source/ui/func/fuediglu \
+ sd/source/ui/func/fuexpand \
+ sd/source/ui/func/fuformatpaintbrush \
+ sd/source/ui/func/fuhhconv \
+ sd/source/ui/func/fuinsert \
+ sd/source/ui/func/fuinsfil \
+ sd/source/ui/func/fuline \
+ sd/source/ui/func/fulinend \
+ sd/source/ui/func/fulink \
+ sd/source/ui/func/fumeasur \
+ sd/source/ui/func/fumorph \
+ sd/source/ui/func/fuoaprms \
+ sd/source/ui/func/fuolbull \
+ sd/source/ui/func/fuoltext \
+ sd/source/ui/func/fuoutl \
+ sd/source/ui/func/fupage \
+ sd/source/ui/func/fuparagr \
+ sd/source/ui/func/fupoor \
+ sd/source/ui/func/fuprlout \
+ sd/source/ui/func/fuprobjs \
+ sd/source/ui/func/fuscale \
+ sd/source/ui/func/fusearch \
+ sd/source/ui/func/fusel \
+ sd/source/ui/func/fusldlg \
+ sd/source/ui/func/fusnapln \
+ sd/source/ui/func/fusumry \
+ sd/source/ui/func/futempl \
+ sd/source/ui/func/futhes \
+ sd/source/ui/func/futransf \
+ sd/source/ui/func/futxtatt \
+ sd/source/ui/func/fuvect \
+ sd/source/ui/func/fuzoom \
+ sd/source/ui/func/sdundo \
+ sd/source/ui/func/sdundogr \
+ sd/source/ui/func/smarttag \
+ sd/source/ui/func/undoback \
+ sd/source/ui/func/undoheaderfooter \
+ sd/source/ui/func/undolayer \
+ sd/source/ui/func/undopage \
+ sd/source/ui/func/unmovss \
+ sd/source/ui/func/unoaprms \
+ sd/source/ui/func/unprlout \
+ sd/source/ui/presenter/CanvasUpdateRequester \
+ sd/source/ui/presenter/PresenterCanvas \
+ sd/source/ui/presenter/PresenterHelper \
+ sd/source/ui/presenter/PresenterPreviewCache \
+ sd/source/ui/presenter/PresenterTextView \
+ sd/source/ui/presenter/SlideRenderer \
+ sd/source/ui/slideshow/PaneHider \
+ sd/source/ui/slideshow/showwin \
+ sd/source/ui/slideshow/slideshow \
+ sd/source/ui/slideshow/slideshowimpl \
+ sd/source/ui/slideshow/SlideShowRestarter \
+ sd/source/ui/slideshow/slideshowviewimpl \
+ sd/source/ui/slidesorter/cache/SlsBitmapCache \
+ sd/source/ui/slidesorter/cache/SlsBitmapCompressor \
+ sd/source/ui/slidesorter/cache/SlsBitmapFactory \
+ sd/source/ui/slidesorter/cache/SlsCacheCompactor \
+ sd/source/ui/slidesorter/cache/SlsCacheConfiguration \
+ sd/source/ui/slidesorter/cache/SlsGenericPageCache \
+ sd/source/ui/slidesorter/cache/SlsPageCache \
+ sd/source/ui/slidesorter/cache/SlsPageCacheManager \
+ sd/source/ui/slidesorter/cache/SlsQueueProcessor \
+ sd/source/ui/slidesorter/cache/SlsRequestFactory \
+ sd/source/ui/slidesorter/cache/SlsRequestQueue \
+ sd/source/ui/slidesorter/controller/SlideSorterController \
+ sd/source/ui/slidesorter/controller/SlsAnimationFunction \
+ sd/source/ui/slidesorter/controller/SlsAnimator \
+ sd/source/ui/slidesorter/controller/SlsClipboard \
+ sd/source/ui/slidesorter/controller/SlsCurrentSlideManager \
+ sd/source/ui/slidesorter/controller/SlsDragAndDropContext \
+ sd/source/ui/slidesorter/controller/SlsFocusManager \
+ sd/source/ui/slidesorter/controller/SlsInsertionIndicatorHandler \
+ sd/source/ui/slidesorter/controller/SlsListener \
+ sd/source/ui/slidesorter/controller/SlsPageSelector \
+ sd/source/ui/slidesorter/controller/SlsProperties \
+ sd/source/ui/slidesorter/controller/SlsScrollBarManager \
+ sd/source/ui/slidesorter/controller/SlsSelectionCommand \
+ sd/source/ui/slidesorter/controller/SlsSelectionFunction \
+ sd/source/ui/slidesorter/controller/SlsSelectionManager \
+ sd/source/ui/slidesorter/controller/SlsSelectionObserver \
+ sd/source/ui/slidesorter/controller/SlsSlotManager \
+ sd/source/ui/slidesorter/controller/SlsTransferable \
+ sd/source/ui/slidesorter/controller/SlsVisibleAreaManager \
+ sd/source/ui/slidesorter/model/SlideSorterModel \
+ sd/source/ui/slidesorter/model/SlsPageDescriptor \
+ sd/source/ui/slidesorter/model/SlsPageEnumeration \
+ sd/source/ui/slidesorter/model/SlsPageEnumerationProvider \
+ sd/source/ui/slidesorter/model/SlsVisualState \
+ sd/source/ui/slidesorter/shell/SlideSorter \
+ sd/source/ui/slidesorter/shell/SlideSorterService \
+ sd/source/ui/slidesorter/shell/SlideSorterViewShell \
+ sd/source/ui/slidesorter/view/SlideSorterView \
+ sd/source/ui/slidesorter/view/SlsButtonBar \
+ sd/source/ui/slidesorter/view/SlsFontProvider \
+ sd/source/ui/slidesorter/view/SlsFramePainter \
+ sd/source/ui/slidesorter/view/SlsInsertAnimator \
+ sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay \
+ sd/source/ui/slidesorter/view/SlsLayeredDevice \
+ sd/source/ui/slidesorter/view/SlsLayouter \
+ sd/source/ui/slidesorter/view/SlsPageObjectLayouter \
+ sd/source/ui/slidesorter/view/SlsPageObjectPainter \
+ sd/source/ui/slidesorter/view/SlsTheme \
+ sd/source/ui/slidesorter/view/SlsToolTip \
+ sd/source/ui/slidesorter/view/SlsViewCacheContext \
+ sd/source/ui/table/TableDesignPane \
+ sd/source/ui/table/tablefunction \
+ sd/source/ui/table/tableobjectbar \
+ sd/source/ui/toolpanel/ControlContainer \
+ sd/source/ui/toolpanel/controls/AllMasterPagesSelector \
+ sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector \
+ sd/source/ui/toolpanel/controls/CustomAnimationPanel \
+ sd/source/ui/toolpanel/controls/DocumentHelper \
+ sd/source/ui/toolpanel/controls/MasterPageContainer \
+ sd/source/ui/toolpanel/controls/MasterPageContainerFiller \
+ sd/source/ui/toolpanel/controls/MasterPageContainerProviders \
+ sd/source/ui/toolpanel/controls/MasterPageContainerQueue \
+ sd/source/ui/toolpanel/controls/MasterPageDescriptor \
+ sd/source/ui/toolpanel/controls/MasterPageObserver \
+ sd/source/ui/toolpanel/controls/MasterPagesPanel \
+ sd/source/ui/toolpanel/controls/MasterPagesSelector \
+ sd/source/ui/toolpanel/controls/PreviewValueSet \
+ sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages \
+ sd/source/ui/toolpanel/controls/RecentMasterPagesSelector \
+ sd/source/ui/toolpanel/controls/SlideTransitionPanel \
+ sd/source/ui/toolpanel/controls/TableDesignPanel \
+ sd/source/ui/toolpanel/LayoutMenu \
+ sd/source/ui/toolpanel/ScrollPanel \
+ sd/source/ui/toolpanel/SlideSorterCacheDisplay \
+ sd/source/ui/toolpanel/SubToolPanel \
+ sd/source/ui/toolpanel/TaskPaneControlFactory \
+ sd/source/ui/toolpanel/TaskPaneFocusManager \
+ sd/source/ui/toolpanel/TaskPaneShellManager \
+ sd/source/ui/toolpanel/TaskPaneTreeNode \
+ sd/source/ui/toolpanel/TestMenu \
+ sd/source/ui/toolpanel/TestPanel \
+ sd/source/ui/toolpanel/TitleBar \
+ sd/source/ui/toolpanel/TitledControl \
+ sd/source/ui/toolpanel/ToolPanel \
+ sd/source/ui/toolpanel/ToolPanelFactory \
+ sd/source/ui/toolpanel/ToolPanelUIElement \
+ sd/source/ui/toolpanel/ToolPanelViewShell \
+ sd/source/ui/tools/AsynchronousCall \
+ sd/source/ui/tools/ConfigurationAccess \
+ sd/source/ui/tools/EventMultiplexer \
+ sd/source/ui/tools/IconCache \
+ sd/source/ui/tools/IdleDetection \
+ sd/source/ui/tools/PreviewRenderer \
+ sd/source/ui/tools/PropertySet \
+ sd/source/ui/tools/SdGlobalResourceContainer \
+ sd/source/ui/tools/SlotStateListener \
+ sd/source/ui/tools/TimerBasedTaskExecution \
+ sd/source/ui/unoidl/DrawController \
+ sd/source/ui/unoidl/facreg \
+ sd/source/ui/unoidl/randomnode \
+ sd/source/ui/unoidl/SdUnoDrawView \
+ sd/source/ui/unoidl/SdUnoOutlineView \
+ sd/source/ui/unoidl/SdUnoSlideView \
+ sd/source/ui/unoidl/unocpres \
+ sd/source/ui/unoidl/unodoc \
+ sd/source/ui/unoidl/UnoDocumentSettings \
+ sd/source/ui/unoidl/unokywds \
+ sd/source/ui/unoidl/unolayer \
+ sd/source/ui/unoidl/unomodel \
+ sd/source/ui/unoidl/unomodule \
+ sd/source/ui/unoidl/unoobj \
+ sd/source/ui/unoidl/unopage \
+ sd/source/ui/unoidl/unopback \
+ sd/source/ui/unoidl/unopool \
+ sd/source/ui/unoidl/unosrch \
+ sd/source/ui/view/clview \
+ sd/source/ui/view/DocumentRenderer \
+ sd/source/ui/view/drawview \
+ sd/source/ui/view/drbezob \
+ sd/source/ui/view/drtxtob \
+ sd/source/ui/view/drtxtob1 \
+ sd/source/ui/view/drviews1 \
+ sd/source/ui/view/drviews2 \
+ sd/source/ui/view/drviews3 \
+ sd/source/ui/view/drviews4 \
+ sd/source/ui/view/drviews5 \
+ sd/source/ui/view/drviews6 \
+ sd/source/ui/view/drviews7 \
+ sd/source/ui/view/drviews8 \
+ sd/source/ui/view/drviews9 \
+ sd/source/ui/view/drviewsa \
+ sd/source/ui/view/drviewsb \
+ sd/source/ui/view/drviewsc \
+ sd/source/ui/view/drviewsd \
+ sd/source/ui/view/drviewse \
+ sd/source/ui/view/drviewsf \
+ sd/source/ui/view/drviewsg \
+ sd/source/ui/view/drviewsh \
+ sd/source/ui/view/drviewsi \
+ sd/source/ui/view/drviewsj \
+ sd/source/ui/view/drvwshrg \
+ sd/source/ui/view/FormShellManager \
+ sd/source/ui/view/frmview \
+ sd/source/ui/view/GraphicObjectBar \
+ sd/source/ui/view/GraphicViewShellBase \
+ sd/source/ui/view/grviewsh \
+ sd/source/ui/view/ImpressViewShellBase \
+ sd/source/ui/view/MediaObjectBar \
+ sd/source/ui/view/Outliner \
+ sd/source/ui/view/OutlinerIterator \
+ sd/source/ui/view/OutlineViewShellBase \
+ sd/source/ui/view/outlnvs2 \
+ sd/source/ui/view/outlnvsh \
+ sd/source/ui/view/outlview \
+ sd/source/ui/view/PresentationViewShellBase \
+ sd/source/ui/view/presvish \
+ sd/source/ui/view/sdruler \
+ sd/source/ui/view/sdview \
+ sd/source/ui/view/sdview2 \
+ sd/source/ui/view/sdview3 \
+ sd/source/ui/view/sdview4 \
+ sd/source/ui/view/sdview5 \
+ sd/source/ui/view/sdwindow \
+ sd/source/ui/view/SlideSorterViewShellBase \
+ sd/source/ui/view/tabcontr \
+ sd/source/ui/view/ToolBarManager \
+ sd/source/ui/view/unmodpg \
+ sd/source/ui/view/UpdateLockManager \
+ sd/source/ui/view/ViewClipboard \
+ sd/source/ui/view/viewoverlaymanager \
+ sd/source/ui/view/viewshe2 \
+ sd/source/ui/view/viewshe3 \
+ sd/source/ui/view/viewshel \
+ sd/source/ui/view/ViewShellBase \
+ sd/source/ui/view/ViewShellHint \
+ sd/source/ui/view/ViewShellImplementation \
+ sd/source/ui/view/ViewShellManager \
+ sd/source/ui/view/ViewTabBar \
+ sd/source/ui/view/WindowUpdater \
+ sd/source/ui/view/zoomlist \
+))
+
+$(eval $(call gb_Library_add_noexception_objects,sd,\
+ sd/source/ui/app/sdresid \
+))
+
+ifeq ($(strip $(GUI)),WNT)
+$(eval $(call gb_Library_add_cxxobjects,sd,\
+ sd/source/ui/app/optsitem \
+ sd/source/ui/func/futext \
+ , $(gb_COMPILERNOOPTFLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) \
+))
+else
+$(eval $(call gb_Library_add_exception_objects,sd,\
+ sd/source/ui/app/optsitem \
+ sd/source/ui/func/futext \
+))
+endif
+
+ifeq ($(strip $(COM)),GCC)
+$(eval $(call gb_Library_add_cxxobjects,sd,\
+ sd/source/ui/unoidl/unowcntr \
+ , $(gb_COMPILERNOOPTFLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) \
+))
+else
+$(eval $(call gb_Library_add_exception_objects,sd,\
+ sd/source/ui/unoidl/unowcntr \
+))
+endif
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Library_sdd.mk b/sd/Library_sdd.mk
new file mode 100644
index 000000000..894e39963
--- /dev/null
+++ b/sd/Library_sdd.mk
@@ -0,0 +1,63 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,sdd))
+
+$(eval $(call gb_Library_add_precompiled_header,sdd,$(SRCDIR)/sd/inc/pch/precompiled_sd))
+
+$(eval $(call gb_Library_set_include,sdd,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_add_linked_libs,sdd,\
+ cppu \
+ cppuhelper \
+ sal \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_set_componentfile,sdd,sd/util/sdd))
+
+$(eval $(call gb_Library_add_exception_objects,sdd,\
+ sd/source/ui/unoidl/detreg \
+ sd/source/ui/unoidl/sddetect \
+))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Library_sdfilt.mk b/sd/Library_sdfilt.mk
new file mode 100644
index 000000000..b1bb3de9a
--- /dev/null
+++ b/sd/Library_sdfilt.mk
@@ -0,0 +1,105 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,sdfilt))
+
+$(eval $(call gb_Library_add_precompiled_header,sdfilt,$(SRCDIR)/sd/inc/pch/precompiled_sd))
+
+$(eval $(call gb_Library_set_include,sdfilt,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_set_defs,sdfilt,\
+ $$(DEFS) \
+ -DSD_DLLIMPLEMENTATION \
+))
+
+ifneq ($(strip $(dbg_anim_log)$(DBG_ANIM_LOG)),)
+$(eval $(call gb_Library_set_defs,sdfilt,\
+ $$(DEFS) \
+ -DDBG_ANIM_LOG \
+))
+endif
+
+$(eval $(call gb_Library_add_linked_libs,sdfilt,\
+ comphelper \
+ cppu \
+ cppuhelper \
+ editeng \
+ i18nisolang1 \
+ msfilter \
+ oox \
+ sal \
+ sax \
+ sd \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_set_componentfile,sdfilt,sd/util/sdfilt))
+
+$(eval $(call gb_Library_add_exception_objects,sdfilt,\
+ sd/source/filter/eppt/eppt \
+ sd/source/filter/eppt/escherex \
+ sd/source/filter/eppt/pptexanimations \
+ sd/source/filter/eppt/pptexsoundcollection \
+ sd/source/filter/eppt/pptx-epptbase \
+ sd/source/filter/eppt/pptx-epptooxml \
+ sd/source/filter/eppt/pptx-grouptable \
+ sd/source/filter/eppt/pptx-stylesheet \
+ sd/source/filter/eppt/pptx-text \
+ sd/source/filter/ppt/ppt97animations \
+ sd/source/filter/ppt/pptatom \
+ sd/source/filter/ppt/pptin \
+ sd/source/filter/ppt/pptinanimations \
+ sd/source/filter/ppt/propread \
+))
+
+ifeq ($(strip $(COM)),GCC)
+$(eval $(call gb_Library_add_cxxobjects,sdfilt,\
+ sd/source/filter/eppt/epptso \
+ , $(gb_COMPILERNOOPTFLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) \
+))
+else
+$(eval $(call gb_Library_add_exception_objects,sdfilt,\
+ sd/source/filter/eppt/epptso \
+))
+endif
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Library_sdui.mk b/sd/Library_sdui.mk
new file mode 100644
index 000000000..e74e96578
--- /dev/null
+++ b/sd/Library_sdui.mk
@@ -0,0 +1,101 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,sdui))
+
+$(eval $(call gb_Library_add_precompiled_header,sdui,$(SRCDIR)/sd/inc/pch/precompiled_sd))
+
+$(eval $(call gb_Library_set_include,sdui,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/sd/inc) \
+ -I$(realpath $(SRCDIR)/sd/inc/pch) \
+ -I$(realpath $(SRCDIR)/sd/source/ui/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_set_defs,sdui,\
+ $$(DEFS) \
+ -DSD_DLLIMPLEMENTATION \
+))
+
+$(eval $(call gb_Library_add_linked_libs,sdui,\
+ basegfx \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ editeng \
+ i18nisolang1 \
+ sal \
+ sd \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ svx \
+ tl \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_add_exception_objects,sdui,\
+ sd/source/filter/html/htmlattr \
+ sd/source/ui/dlg/brkdlg \
+ sd/source/ui/dlg/copydlg \
+ sd/source/ui/dlg/masterlayoutdlg \
+ sd/source/ui/dlg/morphdlg \
+ sd/source/ui/dlg/paragr \
+ sd/source/ui/dlg/present \
+ sd/source/ui/dlg/prltempl \
+ sd/source/ui/dlg/prntopts \
+ sd/source/ui/dlg/sddlgfact \
+ sd/source/ui/dlg/sdpreslt \
+ sd/source/ui/dlg/sduiexp \
+ sd/source/ui/dlg/tabtempl \
+ sd/source/ui/dlg/tpaction \
+ sd/source/ui/dlg/tpoption \
+ sd/source/ui/dlg/vectdlg \
+ sd/source/ui/dlg/custsdlg \
+ sd/source/ui/dlg/dlgass \
+ sd/source/ui/dlg/dlgassim \
+ sd/source/ui/dlg/dlgchar \
+ sd/source/ui/dlg/dlgfield \
+ sd/source/ui/dlg/dlgolbul \
+ sd/source/ui/dlg/dlgpage \
+ sd/source/ui/dlg/dlgsnap \
+ sd/source/ui/dlg/headerfooterdlg \
+ sd/source/ui/dlg/inspagob \
+ sd/source/filter/html/pubdlg \
+))
+
+# $(WORKDIR)/inc/sd/sddll0.hxx :
+ # echo "#define" DLL_NAME \"$(if $(filter UNX,$(GUI)),lib)sd$(DLLPOSTFIX)$(DLLPOST)\" > $@
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/qa/unoapi/makefile.mk b/sd/Makefile
index 62aefb3f5..a79aff831 100644
--- a/sd/qa/unoapi/makefile.mk
+++ b/sd/Makefile
@@ -1,6 +1,7 @@
#*************************************************************************
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -21,28 +22,17 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#***********************************************************************/
-
-.IF "$(OOO_SUBSEQUENT_TESTS)" == ""
-nothing .PHONY:
-.ELSE
-
-PRJ = ../..
-PRJNAME = sd
-TARGET = qa_unoapi
+#
+#*************************************************************************
-.IF "$(OOO_JUNIT_JAR)" != ""
-PACKAGE = org/openoffice/sd/qa/unoapi
-JAVATESTFILES = Test.java
-JAVAFILES = $(JAVATESTFILES)
-JARFILES = OOoRunner.jar ridl.jar test.jar
-EXTRAJARFILES = $(OOO_JUNIT_JAR)
-.END
+ifeq ($(strip $(SOLARENV)),)
+$(error No environment set!)
+endif
-.INCLUDE: settings.mk
-.INCLUDE: target.mk
-.INCLUDE: installationtest.mk
+gb_PARTIALBUILD := T
+GBUILDDIR := $(SOLARENV)/gbuild
+include $(GBUILDDIR)/gbuild.mk
-ALLTAR : javatest
+$(eval $(call gb_Module_make_global_targets,$(shell ls $(dir $(realpath $(firstword $(MAKEFILE_LIST))))/Module*.mk)))
-.END
+# vim: set noet sw=4 ts=4:
diff --git a/sd/Module_sd.mk b/sd/Module_sd.mk
new file mode 100644
index 000000000..a4f129829
--- /dev/null
+++ b/sd/Module_sd.mk
@@ -0,0 +1,50 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# Bjoern Michaelsen, Canonical Ltd. <bjoern.michaelsen@canonical.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Module_Module,sd))
+
+$(eval $(call gb_Module_add_targets,sd,\
+ AllLangResTarget_sd \
+ Library_sd \
+ Library_sdd \
+ Library_sdfilt \
+ Library_sdui \
+ Package_inc \
+ Package_uiconfig \
+ Package_web \
+ Package_xml \
+))
+
+$(eval $(call gb_Module_add_check_targets,sd,\
+ CppunitTest_sd_uimpress \
+))
+
+$(eval $(call gb_Module_add_subsequentcheck_targets,sd,\
+ JunitTest_sd_unoapi \
+))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Package_inc.mk b/sd/Package_inc.mk
new file mode 100644
index 000000000..fcf22384d
--- /dev/null
+++ b/sd/Package_inc.mk
@@ -0,0 +1,32 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Package_Package,sd_inc,$(SRCDIR)/sd/inc))
+
+$(eval $(call gb_Package_add_file,sd_inc,inc/sd/sddll.hxx,sddll.hxx))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Package_uiconfig.mk b/sd/Package_uiconfig.mk
new file mode 100644
index 000000000..de77ff4bc
--- /dev/null
+++ b/sd/Package_uiconfig.mk
@@ -0,0 +1,129 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Package_Package,sd_uiconfig,$(SRCDIR)/sd/uiconfig))
+
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/menubar/menubar.xml,sdraw/menubar/menubar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/statusbar/statusbar.xml,sdraw/statusbar/statusbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/3dobjectsbar.xml,sdraw/toolbar/3dobjectsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/alignmentbar.xml,sdraw/toolbar/alignmentbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/arrowsbar.xml,sdraw/toolbar/arrowsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/arrowshapes.xml,sdraw/toolbar/arrowshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/basicshapes.xml,sdraw/toolbar/basicshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/bezierobjectbar.xml,sdraw/toolbar/bezierobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/calloutshapes.xml,sdraw/toolbar/calloutshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/choosemodebar.xml,sdraw/toolbar/choosemodebar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/colorbar.xml,sdraw/toolbar/colorbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/commentsbar.xml,sdraw/toolbar/commentsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/connectorsbar.xml,sdraw/toolbar/connectorsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/drawingobjectbar.xml,sdraw/toolbar/drawingobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/ellipsesbar.xml,sdraw/toolbar/ellipsesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/extrusionobjectbar.xml,sdraw/toolbar/extrusionobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/findbar.xml,sdraw/toolbar/findbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/flowchartshapes.xml,sdraw/toolbar/flowchartshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/fontworkobjectbar.xml,sdraw/toolbar/fontworkobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/fontworkshapetype.xml,sdraw/toolbar/fontworkshapetype.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/formcontrols.xml,sdraw/toolbar/formcontrols.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/formdesign.xml,sdraw/toolbar/formdesign.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/formsfilterbar.xml,sdraw/toolbar/formsfilterbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/formsnavigationbar.xml,sdraw/toolbar/formsnavigationbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/formtextobjectbar.xml,sdraw/toolbar/formtextobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/fullscreenbar.xml,sdraw/toolbar/fullscreenbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/gluepointsobjectbar.xml,sdraw/toolbar/gluepointsobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/graffilterbar.xml,sdraw/toolbar/graffilterbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/graphicobjectbar.xml,sdraw/toolbar/graphicobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/insertbar.xml,sdraw/toolbar/insertbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/linesbar.xml,sdraw/toolbar/linesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/masterviewtoolbar.xml,sdraw/toolbar/masterviewtoolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/mediaobjectbar.xml,sdraw/toolbar/mediaobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/moreformcontrols.xml,sdraw/toolbar/moreformcontrols.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/optimizetablebar.xml,sdraw/toolbar/optimizetablebar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/optionsbar.xml,sdraw/toolbar/optionsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/positionbar.xml,sdraw/toolbar/positionbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/rectanglesbar.xml,sdraw/toolbar/rectanglesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/standardbar.xml,sdraw/toolbar/standardbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/starshapes.xml,sdraw/toolbar/starshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/symbolshapes.xml,sdraw/toolbar/symbolshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/tableobjectbar.xml,sdraw/toolbar/tableobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/textbar.xml,sdraw/toolbar/textbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/textobjectbar.xml,sdraw/toolbar/textobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/toolbar.xml,sdraw/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/viewerbar.xml,sdraw/toolbar/viewerbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/sdraw/toolbar/zoombar.xml,sdraw/toolbar/zoombar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/menubar/menubar.xml,simpress/menubar/menubar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/statusbar/statusbar.xml,simpress/statusbar/statusbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/3dobjectsbar.xml,simpress/toolbar/3dobjectsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/alignmentbar.xml,simpress/toolbar/alignmentbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/arrowsbar.xml,simpress/toolbar/arrowsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/arrowshapes.xml,simpress/toolbar/arrowshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/basicshapes.xml,simpress/toolbar/basicshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/bezierobjectbar.xml,simpress/toolbar/bezierobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/calloutshapes.xml,simpress/toolbar/calloutshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/choosemodebar.xml,simpress/toolbar/choosemodebar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/colorbar.xml,simpress/toolbar/colorbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/commentsbar.xml,simpress/toolbar/commentsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/commontaskbar.xml,simpress/toolbar/commontaskbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/connectorsbar.xml,simpress/toolbar/connectorsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/drawingobjectbar.xml,simpress/toolbar/drawingobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/ellipsesbar.xml,simpress/toolbar/ellipsesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/extrusionobjectbar.xml,simpress/toolbar/extrusionobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/findbar.xml,simpress/toolbar/findbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/flowchartshapes.xml,simpress/toolbar/flowchartshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/fontworkobjectbar.xml,simpress/toolbar/fontworkobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/fontworkshapetype.xml,simpress/toolbar/fontworkshapetype.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/formcontrols.xml,simpress/toolbar/formcontrols.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/formdesign.xml,simpress/toolbar/formdesign.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/formsfilterbar.xml,simpress/toolbar/formsfilterbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/formsnavigationbar.xml,simpress/toolbar/formsnavigationbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/formtextobjectbar.xml,simpress/toolbar/formtextobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/fullscreenbar.xml,simpress/toolbar/fullscreenbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/gluepointsobjectbar.xml,simpress/toolbar/gluepointsobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/graffilterbar.xml,simpress/toolbar/graffilterbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/graphicobjectbar.xml,simpress/toolbar/graphicobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/insertbar.xml,simpress/toolbar/insertbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/linesbar.xml,simpress/toolbar/linesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/masterviewtoolbar.xml,simpress/toolbar/masterviewtoolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/mediaobjectbar.xml,simpress/toolbar/mediaobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/moreformcontrols.xml,simpress/toolbar/moreformcontrols.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/optimizetablebar.xml,simpress/toolbar/optimizetablebar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/optionsbar.xml,simpress/toolbar/optionsbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/outlinetoolbar.xml,simpress/toolbar/outlinetoolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/positionbar.xml,simpress/toolbar/positionbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/rectanglesbar.xml,simpress/toolbar/rectanglesbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/slideviewobjectbar.xml,simpress/toolbar/slideviewobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/slideviewtoolbar.xml,simpress/toolbar/slideviewtoolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/standardbar.xml,simpress/toolbar/standardbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/starshapes.xml,simpress/toolbar/starshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/symbolshapes.xml,simpress/toolbar/symbolshapes.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/tableobjectbar.xml,simpress/toolbar/tableobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/textbar.xml,simpress/toolbar/textbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/textobjectbar.xml,simpress/toolbar/textobjectbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/toolbar.xml,simpress/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/viewerbar.xml,simpress/toolbar/viewerbar.xml))
+$(eval $(call gb_Package_add_file,sd_uiconfig,xml/uiconfig/modules/simpress/toolbar/zoombar.xml,simpress/toolbar/zoombar.xml))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Package_web.mk b/sd/Package_web.mk
new file mode 100644
index 000000000..da370532d
--- /dev/null
+++ b/sd/Package_web.mk
@@ -0,0 +1,58 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Package_Package,sd_web,$(SRCDIR)/sd/res))
+
+$(eval $(call gb_Package_add_file,sd_web,pck/glas-blue.zip,buttons/glas-blue.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/glas-green.zip,buttons/glas-green.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/glas-red.zip,buttons/glas-red.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/round-gorilla.zip,buttons/round-gorilla.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/round-white.zip,buttons/round-white.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/simple.zip,buttons/simple.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/square-blue.zip,buttons/square-blue.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/square-gray.zip,buttons/square-gray.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/square-green.zip,buttons/square-green.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/square-red.zip,buttons/square-red.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/square-yellow.zip,buttons/square-yellow.zip))
+$(eval $(call gb_Package_add_file,sd_web,pck/common.inc,webview/common.inc))
+$(eval $(call gb_Package_add_file,sd_web,pck/common.pl,webview/common.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/edit.asp,webview/edit.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/editpic.asp,webview/editpic.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/editpic.pl,webview/editpic.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/edit.pl,webview/edit.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/index.pl,webview/index.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/poll.asp,webview/poll.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/poll.pl,webview/poll.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/savepic.asp,webview/savepic.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/savepic.pl,webview/savepic.pl))
+$(eval $(call gb_Package_add_file,sd_web,pck/show.asp,webview/show.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/show.pl,webview/show.pl))
+# the following two files are really renamed
+$(eval $(call gb_Package_add_file,sd_web,pck/webcast.asp,webview/webview.asp))
+$(eval $(call gb_Package_add_file,sd_web,pck/webcast.pl,webview/webview.pl))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/Package_xml.mk b/sd/Package_xml.mk
new file mode 100644
index 000000000..5c511cf16
--- /dev/null
+++ b/sd/Package_xml.mk
@@ -0,0 +1,62 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Package_Package,sd_xml,$(SRCDIR)/sd/xml))
+
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessibleDrawDocumentView.xml,AccessibleDrawDocumentView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessibleOutlineView.xml,AccessibleOutlineView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessiblePageShape.xml,AccessiblePageShape.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessiblePresentationGraphicShape.xml,AccessiblePresentationGraphicShape.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessiblePresentationOLEShape.xml,AccessiblePresentationOLEShape.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessiblePresentationShape.xml,AccessiblePresentationShape.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessibleSlideViewObject.xml,AccessibleSlideViewObject.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/AccessibleSlideView.xml,AccessibleSlideView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/DrawingView.xml,DrawingView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/effects.xml,effects.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/HandoutView.xml,HandoutView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/NotesView.xml,NotesView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/OutlineView.xml,OutlineView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/PresentationView.xml,PresentationView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdDocLinkTargets.xml,SdDocLinkTargets.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdDrawPagesAccess.xml,SdDrawPagesAccess.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdDrawPage.xml,SdDrawPage.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdGenericDrawPage.xml,SdGenericDrawPage.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdLayerManager.xml,SdLayerManager.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdLayer.xml,SdLayer.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdMasterPagesAccess.xml,SdMasterPagesAccess.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdMasterPage.xml,SdMasterPage.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdPageLinkTargets.xml,SdPageLinkTargets.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdXCustomPresentationAccess.xml,SdXCustomPresentationAccess.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdXCustomPresentation.xml,SdXCustomPresentation.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdXImpressDocument.xml,SdXImpressDocument.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdXPresentation.xml,SdXPresentation.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SdXShape.xml,SdXShape.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/SlidesView.xml,SlidesView.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/transitions-ogl.xml,transitions-ogl.xml))
+$(eval $(call gb_Package_add_file,sd_xml,xml/transitions.xml,transitions.xml))
+
+# vim: set noet ts=4 sw=4:
diff --git a/sd/inc/CustomAnimationCloner.hxx b/sd/inc/CustomAnimationCloner.hxx
index abe2bc784..7369efaed 100644
--- a/sd/inc/CustomAnimationCloner.hxx
+++ b/sd/inc/CustomAnimationCloner.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,3 +41,5 @@ namespace sd
}
#endif // _SD_CUSTOMANIMATIONCLONER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/CustomAnimationEffect.hxx b/sd/inc/CustomAnimationEffect.hxx
index 40ddce3db..b88687726 100644
--- a/sd/inc/CustomAnimationEffect.hxx
+++ b/sd/inc/CustomAnimationEffect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -474,3 +475,5 @@ private:
}
#endif // _SD_CUSTOMANIMATIONEFFECT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/CustomAnimationPreset.hxx b/sd/inc/CustomAnimationPreset.hxx
index fdf577fb8..fb2a7b7c7 100644
--- a/sd/inc/CustomAnimationPreset.hxx
+++ b/sd/inc/CustomAnimationPreset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,23 +29,19 @@
#ifndef _SD_CUSTOMANIMATIONPRESET_HXX
#define _SD_CUSTOMANIMATIONPRESET_HXX
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/animations/AnimationNodeType.hpp>
-#ifndef _UTL_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
#include <CustomAnimationEffect.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace sd {
-typedef std::hash_map< rtl::OUString, CustomAnimationEffectPtr, comphelper::UStringHash, comphelper::UStringEqual > EffectsSubTypeMap;
-typedef std::hash_map< rtl::OUString, rtl::OUString, comphelper::UStringHash, comphelper::UStringEqual > UStringMap;
+typedef boost::unordered_map< rtl::OUString, CustomAnimationEffectPtr, comphelper::UStringHash, comphelper::UStringEqual > EffectsSubTypeMap;
+typedef boost::unordered_map< rtl::OUString, rtl::OUString, comphelper::UStringHash, comphelper::UStringEqual > UStringMap;
typedef std::vector< rtl::OUString > UStringList;
class CustomAnimationPreset
@@ -83,7 +80,7 @@ private:
};
typedef boost::shared_ptr< CustomAnimationPreset > CustomAnimationPresetPtr;
-typedef std::hash_map<rtl::OUString, CustomAnimationPresetPtr, comphelper::UStringHash, comphelper::UStringEqual> EffectDescriptorMap;
+typedef boost::unordered_map<rtl::OUString, CustomAnimationPresetPtr, comphelper::UStringHash, comphelper::UStringEqual> EffectDescriptorMap;
typedef std::vector< CustomAnimationPresetPtr > EffectDescriptorList;
struct PresetCategory
@@ -110,8 +107,6 @@ public:
::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode > getRandomPreset( sal_Int16 nPresetClass ) const;
SD_DLLPUBLIC CustomAnimationPresetPtr getEffectDescriptor( const rtl::OUString& rPresetId ) const;
-// const AnimationEffect* getEffect( const rtl::OUString& rPresetId ) const;
-// const AnimationEffect* getEffect( const rtl::OUString& rPresetId, const rtl::OUString& rPresetSubType ) const;
const rtl::OUString& getUINameForPresetId( const rtl::OUString& rPresetId ) const;
const rtl::OUString& getUINameForProperty( const rtl::OUString& rProperty ) const;
@@ -153,3 +148,4 @@ typedef boost::shared_ptr< CustomAnimationPresets > CustomAnimationPresetsPtr;
#endif // _SD_CUSTOMANIMATIONEFFECTS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/EffectMigration.hxx b/sd/inc/EffectMigration.hxx
index f9a0f1663..f5eb7fe4f 100644
--- a/sd/inc/EffectMigration.hxx
+++ b/sd/inc/EffectMigration.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -81,3 +82,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/FactoryIds.hxx b/sd/inc/FactoryIds.hxx
index 65ff1c925..ff56c4ca8 100755..100644
--- a/sd/inc/FactoryIds.hxx
+++ b/sd/inc/FactoryIds.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,4 @@ enum ViewShellFactoryIds
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/Outliner.hxx b/sd/inc/Outliner.hxx
index 79dd68314..09d5617a9 100755..100644
--- a/sd/inc/Outliner.hxx
+++ b/sd/inc/Outliner.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -163,7 +164,7 @@ public:
/** Starts the text conversion (hangul/hanja or Chinese simplified/traditional)
for the current viewshell */
- void StartConversion( sal_Int16 nSourceLanguage, sal_Int16 nTargetLanguage,
+ void StartConversion( sal_Int16 nSourceLanguage, sal_Int16 nTargetLanguage,
const Font *pTargetFont, sal_Int32 nOptions, sal_Bool bIsInteractive );
/** This is called internaly when text conversion is started.
@@ -238,7 +239,7 @@ private:
*/
bool mbFoundObject;
- /** When set to <TRUE/> this flag indicates that an error has occured
+ /** When set to <TRUE/> this flag indicates that an error has occurred
that should terminate the iteration over the objects to search/spell
check.
*/
@@ -551,3 +552,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/OutlinerIterator.hxx b/sd/inc/OutlinerIterator.hxx
index 4413709d6..c86ef0f24 100755..100644
--- a/sd/inc/OutlinerIterator.hxx
+++ b/sd/inc/OutlinerIterator.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -368,3 +369,4 @@ public:
#endif // _SD_OUTLINER_ITERATOR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/SdShapeTypes.hxx b/sd/inc/SdShapeTypes.hxx
index 652fe2f45..19effad6a 100644
--- a/sd/inc/SdShapeTypes.hxx
+++ b/sd/inc/SdShapeTypes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _SD_SD_SHAPE_TYPES_HXX
#define _SD_SD_SHAPE_TYPES_HXX
-#ifndef _SVX_ACCESSIBILITY_ACCESSIBLE_SHAPE_TYPE_HANDLERHXX
#include <svx/ShapeTypeHandler.hxx>
-#endif
#include <svx/AccessibleShape.hxx>
#include <com/sun/star/accessibility/XAccessible.hpp>
@@ -72,12 +71,8 @@ AccessibleShape*
);
-/** List of shape type descriptors corresponding to the
- <type>SdShapeTypes</type> enum.
-*/
-extern ShapeTypeDescriptor aSdShapeTypeList[];
-
-
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/TransitionPreset.hxx b/sd/inc/TransitionPreset.hxx
index 4895ec71b..cbdac521a 100644
--- a/sd/inc/TransitionPreset.hxx
+++ b/sd/inc/TransitionPreset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,17 +29,13 @@
#ifndef _SD_TRANSITIONPRESET_HXX
#define _SD_TRANSITIONPRESET_HXX
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#ifndef _UTL_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
#include <list>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace com { namespace sun { namespace star {
namespace animations { class XAnimationNode; }
@@ -53,7 +50,7 @@ namespace sd {
class TransitionPreset;
typedef boost::shared_ptr< TransitionPreset > TransitionPresetPtr;
typedef std::list< TransitionPresetPtr > TransitionPresetList;
-typedef std::hash_map< rtl::OUString, rtl::OUString, comphelper::UStringHash, comphelper::UStringEqual > UStringMap;
+typedef boost::unordered_map< rtl::OUString, rtl::OUString, comphelper::UStringHash, comphelper::UStringEqual > UStringMap;
class TransitionPreset
{
@@ -81,8 +78,6 @@ private:
rtl::OUString maPresetId;
rtl::OUString maUIName;
- static sd::TransitionPresetList* mpTransitionPresetList;
-
static bool importTransitionsFile( TransitionPresetList& rList,
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceFactory,
UStringMap& rTransitionNameMape,
@@ -93,3 +88,4 @@ private:
#endif // _SD_TRANSITIONPRESET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/animations.hxx b/sd/inc/animations.hxx
index a0f5008e4..1fe6f64dc 100644
--- a/sd/inc/animations.hxx
+++ b/sd/inc/animations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#ifndef _SD_ANIMATIONS_HXX_
#define _SD_ANIMATIONS_HXX_
@@ -28,3 +29,5 @@ SD_DLLPUBLIC void stl_process_after_effect_node_func(AfterEffectNode& rNode);
} // namespace sd;
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/anmdef.hxx b/sd/inc/anmdef.hxx
index 9a2e231b6..161349a21 100644
--- a/sd/inc/anmdef.hxx
+++ b/sd/inc/anmdef.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,3 +40,4 @@
#endif // _SD_ANIMATIONDEF_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/anminfo.hxx b/sd/inc/anminfo.hxx
index 74cb27ae3..cbbb9e22d 100755..100644
--- a/sd/inc/anminfo.hxx
+++ b/sd/inc/anminfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,7 +71,6 @@ public:
String maSecondSoundFile; // fuer Objekt ausblenden
sal_Bool mbSecondSoundOn; // fuer Objekt ausblenden
sal_Bool mbSecondPlayFull;// fuer Objekt ausblenden
-// String maBookmark; // Sprung zu Objekt/Seite
sal_uInt16 mnVerb; // fuer OLE-Objekt
sal_uLong mnPresOrder;
SdrObject& mrObject;
@@ -87,3 +87,4 @@ public:
#endif // _SD_ANMINFO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/app.hrc b/sd/inc/app.hrc
index 03b22b3e8..19bc3bd94 100755..100644
--- a/sd/inc/app.hrc
+++ b/sd/inc/app.hrc
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -215,10 +215,6 @@
#define SID_CONNECTOR_LINES_CIRCLES (SID_SD_START+145)
// Options-Leisten Slot-IDs
-//#i80528##define SID_GRAPHIC_DRAFT (SID_SD_START+146)
-//#i80528##define SID_FILL_DRAFT (SID_SD_START+147)
-//#i80528##define SID_TEXT_DRAFT (SID_SD_START+148)
-//#i80528##define SID_LINE_DRAFT (SID_SD_START+149)
#define SID_HANDLES_DRAFT (SID_SD_START+150)
#define SID_SOLID_CREATE (SID_SD_START+151)
#define SID_HELPLINES_USE (SID_SD_START+152)
@@ -500,11 +496,12 @@
#define SID_DISPLAY_MASTER_OBJECTS (SID_SD_START+437)
#define SID_INSERTPAGE_LAYOUT_MENU (SID_SD_START+438)
#define SID_TP_EDIT_MASTER (SID_SD_START+439)
+#define SID_OUTLINE_TEXT_AUTOFIT (SID_SD_START+440)
// Add companion for the SID_HIDE_SLIDE (that is defined in svx)
-#define SID_SHOW_SLIDE (SID_SD_START+440)
+#define SID_SHOW_SLIDE (SID_SD_START+441)
-#define SID_ADD_MOTION_PATH (SID_SD_START+441)
-#define SID_TABLE_TOOLBOX (SID_SD_START+442)
+#define SID_ADD_MOTION_PATH (SID_SD_START+442)
+#define SID_TABLE_TOOLBOX (SID_SD_START+443)
#endif
diff --git a/sd/inc/app.hxx b/sd/inc/app.hxx
index 1fa4af2e7..68a6fe0f2 100644
--- a/sd/inc/app.hxx
+++ b/sd/inc/app.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,3 +28,4 @@
#define _SD_DLL // fuer SD_MOD()
#include "sdmod.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/cusshow.hxx b/sd/inc/cusshow.hxx
index d724a34cd..1f981e9a7 100755..100644
--- a/sd/inc/cusshow.hxx
+++ b/sd/inc/cusshow.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -77,3 +78,4 @@ public:
#endif // _SD_CUSSHOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/diadef.h b/sd/inc/diadef.h
index c8fa5339e..922c75628 100644
--- a/sd/inc/diadef.h
+++ b/sd/inc/diadef.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,3 +41,4 @@ enum PresChange
#endif // _SD_DIADEF_H
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/drawdoc.hxx b/sd/inc/drawdoc.hxx
index 13286b34a..7b8d16444 100755..100644
--- a/sd/inc/drawdoc.hxx
+++ b/sd/inc/drawdoc.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,7 +42,6 @@
#include <com/sun/star/lang/Locale.hpp>
#include <com/sun/star/text/WritingMode.hpp>
-// #107844#
#include <svx/svdundo.hxx>
#include <vector>
@@ -111,6 +111,7 @@ SV_DECL_REF(DrawDocShell)
class DrawDocShell;
class UndoManager;
class ShapeList;
+class FrameView;
}
class ImpDrawPageListWatcher;
@@ -167,7 +168,7 @@ private:
Timer* mpOnlineSpellingTimer;
sd::ShapeList* mpOnlineSpellingList;
SvxSearchItem* mpOnlineSearchItem;
- List* mpFrameViewList;
+ std::vector<sd::FrameView*> maFrameViewList;
List* mpCustomShowList;
::sd::DrawDocShell* mpDocSh;
SdTransferable * mpCreatingTransferable;
@@ -195,7 +196,6 @@ private:
CharClass* mpCharClass;
::com::sun::star::lang::Locale* mpLocale;
- // #109538#
::std::auto_ptr<ImpDrawPageListWatcher> mpDrawPageListWatcher;
::std::auto_ptr<ImpMasterPageListWatcher> mpMasterPageListWatcher;
@@ -224,10 +224,10 @@ public:
~SdDrawDocument();
virtual SdrModel* AllocModel() const;
- virtual SdrPage* AllocPage(FASTBOOL bMasterPage);
+ virtual SdrPage* AllocPage(bool bMasterPage);
virtual const SdrModel* LoadModel(const String& rFileName);
virtual void DisposeLoadedModels();
- virtual FASTBOOL IsReadOnly() const;
+ virtual bool IsReadOnly() const;
virtual void SetChanged(sal_Bool bFlag = sal_True);
virtual SvStream* GetDocumentStream(SdrDocumentStreamInfo& rStreamInfo) const;
@@ -408,7 +408,7 @@ public:
sal_uLong GetLinkCount();
- List* GetFrameViewList() const { return mpFrameViewList; }
+ std::vector<sd::FrameView*>& GetFrameViewList() { return maFrameViewList; }
SD_DLLPUBLIC List* GetCustomShowList(sal_Bool bCreate = sal_False);
void NbcSetChanged(sal_Bool bFlag = sal_True);
@@ -427,8 +427,7 @@ public:
sal_Bool IsNewOrLoadCompleted() const {return mbNewOrLoadCompleted; }
::sd::FrameView* GetFrameView(sal_uLong nPos) {
- return static_cast< ::sd::FrameView*>(
- mpFrameViewList->GetObject(nPos));}
+ return nPos < maFrameViewList.size() ? maFrameViewList[nPos] : NULL; }
/** deprecated*/
SdAnimationInfo* GetAnimationInfo(SdrObject* pObject) const;
@@ -449,8 +448,8 @@ public:
void Merge(SdrModel& rSourceModel,
sal_uInt16 nFirstPageNum=0, sal_uInt16 nLastPageNum=0xFFFF,
sal_uInt16 nDestPos=0xFFFF,
- FASTBOOL bMergeMasterPages=sal_False, FASTBOOL bAllMasterPages=sal_False,
- FASTBOOL bUndo=sal_True, FASTBOOL bTreadSourceAsConst=sal_False);
+ bool bMergeMasterPages = false, bool bAllMasterPages = false,
+ bool bUndo = true, bool bTreadSourceAsConst = false);
SD_DLLPUBLIC ::com::sun::star::text::WritingMode GetDefaultWritingMode() const;
void SetDefaultWritingMode( ::com::sun::star::text::WritingMode eMode );
@@ -539,16 +538,6 @@ public:
@param sNotesPageName
Name of the standard page. An empty string leads to using an
automatically created name.
- @param eStandardLayout
- Layout to use for the new standard page. Note that this layout
- is not used when the given <argument>pCurrentPage</argument> is
- not a standard page. In this case the layout is taken from the
- standard page associated with <argument>pCurrentPage</argument>.
- @param eNotesLayout
- Layout to use for the new notes page. Note that this layout
- is not used when the given <argument>pCurrentPage</argument> is
- not a notes page. In this case the layout is taken from the
- notes page associated with <argument>pCurrentPage</argument>.
@param bIsPageBack
This flag indicates whether to show the background shape.
@param bIsPageObj
@@ -566,8 +555,6 @@ public:
PageKind ePageKind,
const String& sStandardPageName,
const String& sNotesPageName,
- AutoLayout eStandardLayout,
- AutoLayout eNotesLayout,
sal_Bool bIsPageBack,
sal_Bool bIsPageObj,
const sal_Int32 nInsertPosition = -1);
@@ -610,16 +597,6 @@ private:
@param sNotesPageName
Name of the standard page. An empty string leads to using an
automatically created name.
- @param eStandardLayout
- Layout to use for the new standard page. Note that this layout
- is not used when the given <argument>pCurrentPage</argument> is
- not a standard page. In this case the layout is taken from the
- standard page associated with <argument>pCurrentPage</argument>.
- @param eNotesLayout
- Layout to use for the new notes page. Note that this layout
- is not used when the given <argument>pCurrentPage</argument> is
- not a notes page. In this case the layout is taken from the
- notes page associated with <argument>pCurrentPage</argument>.
@param bIsPageBack
This flag indicates whether to show the background shape.
@param bIsPageObj
@@ -641,8 +618,6 @@ private:
PageKind ePageKind,
const String& sStandardPageName,
const String& sNotesPageName,
- AutoLayout eStandardLayout,
- AutoLayout eNotesLayout,
sal_Bool bIsPageBack,
sal_Bool bIsPageObj,
SdPage* pStandardPage,
@@ -672,7 +647,6 @@ private:
sal_Bool bIsPageBack,
sal_Bool bIsPageObj);
- // #109538#
virtual void PageListChanged();
virtual void MasterPageListChanged();
};
@@ -700,3 +674,5 @@ private:
}
#endif // _DRAWDOC_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/eetext.hxx b/sd/inc/eetext.hxx
index 7edbb120b..c49cac4d8 100644
--- a/sd/inc/eetext.hxx
+++ b/sd/inc/eetext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,3 +33,4 @@
#endif // EETEXT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/fadedef.h b/sd/inc/fadedef.h
index 0b46e061b..25d7c91ae 100644
--- a/sd/inc/fadedef.h
+++ b/sd/inc/fadedef.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,3 +43,4 @@ enum FadeSpeed
#endif // _SD_FADEDEF_H
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/glob.hxx b/sd/inc/glob.hxx
index 145627148..ca2494617 100755..100644
--- a/sd/inc/glob.hxx
+++ b/sd/inc/glob.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,4 @@ const sal_uInt32 SdUDInventor=sal_uInt32('S')*0x00000001+
#endif // _SD_GLOB_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/helper/simplereferencecomponent.hxx b/sd/inc/helper/simplereferencecomponent.hxx
index c8c6d834b..eee7cefde 100644
--- a/sd/inc/helper/simplereferencecomponent.hxx
+++ b/sd/inc/helper/simplereferencecomponent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -113,3 +114,5 @@ private:
}
#endif // _SALHELPER_SimpleReferenceComponent_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/helpids.h b/sd/inc/helpids.h
index 550fba2bf..93aaa7950 100755
--- a/sd/inc/helpids.h
+++ b/sd/inc/helpids.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -249,3 +250,5 @@
#define HID_MN_SUB_PREVIEW_OUTPUT_QUALITY "SD_HID_MN_SUB_PREVIEW_OUTPUT_QUALITY"
#define HID_MN_SUB_CONVERT "SD_HID_MN_SUB_CONVERT"
#define HID_MN_SUB_MIRROR "SD_HID_MN_SUB_MIRROR"
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/imapinfo.hxx b/sd/inc/imapinfo.hxx
index 78b5bcef2..65473c4bf 100644
--- a/sd/inc/imapinfo.hxx
+++ b/sd/inc/imapinfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,4 @@ public:
#endif // _SD_IMAPINFO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/makefile.mk b/sd/inc/makefile.mk
deleted file mode 100644
index 1101f31d8..000000000
--- a/sd/inc/makefile.mk
+++ /dev/null
@@ -1,48 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..
-
-PRJNAME=sd
-TARGET=inc
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-# --- Targets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
-.IF "$(ENABLE_PCH)"!=""
-ALLTAR : \
- $(SLO)$/precompiled.pch \
- $(SLO)$/precompiled_ex.pch
-
-.ENDIF # "$(ENABLE_PCH)"!=""
-
diff --git a/sd/inc/misc.hxx b/sd/inc/misc.hxx
deleted file mode 100644
index a2b7e5687..000000000
--- a/sd/inc/misc.hxx
+++ /dev/null
@@ -1,36 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _SD_MISC_HXX
-#define _SD_MISC_HXX
-
-// do we have a StarOffice Image OLE server?
-#undef STARIMAGE_AVAILABLE
-
-#endif // _SD_MISC_HXX
-
-
diff --git a/sd/inc/misc/scopelock.hxx b/sd/inc/misc/scopelock.hxx
index e2c03e0b7..81ef0dea7 100644
--- a/sd/inc/misc/scopelock.hxx
+++ b/sd/inc/misc/scopelock.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ private:
} // namespace sd
#endif // _SD_UNDOMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/movedef.hxx b/sd/inc/movedef.hxx
index ff824f72b..2cdb6549c 100644
--- a/sd/inc/movedef.hxx
+++ b/sd/inc/movedef.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,3 +41,4 @@ enum MoveSpeed
#endif // _SD_MOVEDEF_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/pch/precompiled_sd.cxx b/sd/inc/pch/precompiled_sd.cxx
index 49387c566..43c69b04a 100644
--- a/sd/inc/pch/precompiled_sd.cxx
+++ b/sd/inc/pch/precompiled_sd.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,3 +28,4 @@
#include "precompiled_sd.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/pch/precompiled_sd.hxx b/sd/inc/pch/precompiled_sd.hxx
index b663187a1..e8e46b94c 100755..100644
--- a/sd/inc/pch/precompiled_sd.hxx
+++ b/sd/inc/pch/precompiled_sd.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/************************************************************************cherex
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -547,7 +548,6 @@
#include "svl/svstdarr.hxx"
#include "unotools/syslocale.hxx"
#include "svtools/tabbar.hxx"
-#include "svtools/treelist.hxx"
#include "svl/undo.hxx"
#include "svtools/unoimap.hxx"
#include "svl/urihelper.hxx"
@@ -620,7 +620,6 @@
#include "svx/grafctrl.hxx"
#include "svx/hlnkitem.hxx"
#include "svx/hyperdlg.hxx"
-#include "svx/hyprlink.hxx"
#include "svx/imapdlg.hxx"
#include "svx/itemwin.hxx"
#include "svx/langbox.hxx"
@@ -805,10 +804,8 @@
#include "tools/gen.hxx"
#include "tools/globname.hxx"
#include "tools/link.hxx"
-#include "tools/list.hxx"
#include "tools/multisel.hxx"
#include "tools/poly.hxx"
-#include "tools/pstm.hxx"
#include "tools/rc.hxx"
#include "tools/ref.hxx"
#include "tools/resid.hxx"
@@ -903,12 +900,12 @@
#include "tools/wintypes.hxx"
#include "vcl/wrkwin.hxx"
-#include "vos/diagnose.hxx"
-#include "vos/module.hxx"
-#include "vos/mutex.hxx"
-#include "vos/process.hxx"
-#include "vos/thread.hxx"
-#include "vos/xception.hxx"
+#include "osl/diagnose.h"
+#include "osl/module.hxx"
+#include "osl/mutex.hxx"
+#include "osl/process.h"
//---MARKER---
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/pglink.hxx b/sd/inc/pglink.hxx
index 2d301fa83..cd91198e6 100644
--- a/sd/inc/pglink.hxx
+++ b/sd/inc/pglink.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,8 +29,6 @@
#ifndef _PGLINK_HXX
#define _PGLINK_HXX
-#ifndef SVX_LIGHT
-
#include <sfx2/lnkbase.hxx>
class SdPage;
@@ -45,19 +44,14 @@ public:
virtual ~SdPageLink();
virtual void Closed();
- virtual void DataChanged( const String& ,
- const ::com::sun::star::uno::Any & );
- FASTBOOL Connect() { return 0 != SvBaseLink::GetRealObject(); }
+ virtual ::sfx2::SvBaseLink::UpdateResult DataChanged(
+ const String& rMimeType, const ::com::sun::star::uno::Any & rValue );
+ bool Connect() { return 0 != SvBaseLink::GetRealObject(); }
};
-#else
-
-class SdPageLink;
-
-#endif
-
#endif // _PGLINK_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/pres.hxx b/sd/inc/pres.hxx
index 4812505a8..0b1371601 100755..100644
--- a/sd/inc/pres.hxx
+++ b/sd/inc/pres.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,3 +140,4 @@ enum NavigatorDragType
#endif // _PRESENTATION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/prlayout.hxx b/sd/inc/prlayout.hxx
index 341233f52..cd2f71297 100644
--- a/sd/inc/prlayout.hxx
+++ b/sd/inc/prlayout.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,4 @@ enum PresentationObjects
#endif // _SD_PRLAYOUT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/resltn.hxx b/sd/inc/resltn.hxx
index 5f5ae78e2..dcca7feff 100644
--- a/sd/inc/resltn.hxx
+++ b/sd/inc/resltn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,4 @@ enum PublishingScript
#endif // _SD_RESLTN_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sd_primitivetypes2d.hxx b/sd/inc/sd_primitivetypes2d.hxx
index 0f4440710..519b9e78b 100644
--- a/sd/inc/sd_primitivetypes2d.hxx
+++ b/sd/inc/sd_primitivetypes2d.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef INCLUDED_SD_PRIMITIVETYPES2D_HXX
#define INCLUDED_SD_PRIMITIVETYPES2D_HXX
-#ifndef INCLUDED_DRAWINGLAYER_PRIMITIVE2D_PRIMITIVETYPES2D_HXX
#include <drawinglayer/primitive2d/drawinglayer_primitivetypes2d.hxx>
-#endif
//////////////////////////////////////////////////////////////////////////////
@@ -47,3 +46,5 @@
//////////////////////////////////////////////////////////////////////////////
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdabstdlg.hxx b/sd/inc/sdabstdlg.hxx
index 84e6fd70f..d1cede9fd 100755..100644
--- a/sd/inc/sdabstdlg.hxx
+++ b/sd/inc/sdabstdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -223,3 +224,4 @@ public:
};
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdattr.hxx b/sd/inc/sdattr.hxx
index f4a28b7d5..a328ff8d9 100755..100644
--- a/sd/inc/sdattr.hxx
+++ b/sd/inc/sdattr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include <svl/stritem.hxx>
#include <sfx2/sfx.hrc>
-#ifndef _SDATTR_HRC
#include "sdattr.hrc"
-#endif
#include "glob.hxx"
#include "fadedef.h"
#include "diadef.h"
@@ -173,3 +172,4 @@ public:
#endif // _SDATTR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdcgmfilter.hxx b/sd/inc/sdcgmfilter.hxx
index 1d90dada1..c7591710e 100644
--- a/sd/inc/sdcgmfilter.hxx
+++ b/sd/inc/sdcgmfilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,5 @@ public:
};
#endif // _SD_SDCGMFILTER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdcommands.h b/sd/inc/sdcommands.h
index c8870635a..1f5899455 100644
--- a/sd/inc/sdcommands.h
+++ b/sd/inc/sdcommands.h
@@ -213,6 +213,7 @@
#define CMD_SID_ORIGINAL_SIZE ".uno:OriginalSize"
#define CMD_SID_SAVEGRAPHIC ".uno:SaveGraphic"
#define CMD_SID_OUTLINEMODE ".uno:OutlineMode"
+#define CMD_SID_OUTLINE_TEXT_AUTOFIT ".uno.OutlineTextAutofit"
#define CMD_SID_OUTPUT_QUALITY_BLACKWHITE ".uno:OutputQualityBlackWhite"
#define CMD_SID_OUTPUT_QUALITY_COLOR ".uno:OutputQualityColor"
#define CMD_SID_OUTPUT_QUALITY_CONTRAST ".uno:OutputQualityContrast"
diff --git a/sd/inc/sddll.hxx b/sd/inc/sddll.hxx
index ed0dcc003..5511dc209 100644
--- a/sd/inc/sddll.hxx
+++ b/sd/inc/sddll.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,4 @@ public:
#endif // _SDDLL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sddllapi.h b/sd/inc/sddllapi.h
index f76257c6e..c9e704040 100644
--- a/sd/inc/sddllapi.h
+++ b/sd/inc/sddllapi.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,3 +39,5 @@
#define SD_DLLPRIVATE SAL_DLLPRIVATE
#endif /* INCLUDED_SDDLLAPI_H */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdenumdef.hxx b/sd/inc/sdenumdef.hxx
index db4e90c60..30ba42fdb 100644
--- a/sd/inc/sdenumdef.hxx
+++ b/sd/inc/sdenumdef.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,3 +37,4 @@ enum SnapKind { SK_HORIZONTAL, SK_VERTICAL, SK_POINT };
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sderror.hxx b/sd/inc/sderror.hxx
index 242e385fc..9f10fc52b 100755..100644
--- a/sd/inc/sderror.hxx
+++ b/sd/inc/sderror.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,12 +50,12 @@
#ifndef __RSC
-inline FASTBOOL IsWarning( sal_uLong nErr )
+inline bool IsWarning( sal_uLong nErr )
{
return 0 != ( nErr & ERRCODE_WARNING_MASK & nErr );
}
-inline FASTBOOL IsError( sal_uLong nErr )
+inline bool IsError( sal_uLong nErr )
{
return nErr && 0 == ( ERRCODE_WARNING_MASK & nErr );
}
@@ -63,3 +64,5 @@ inline FASTBOOL IsError( sal_uLong nErr )
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdfilter.hxx b/sd/inc/sdfilter.hxx
index dffe972cc..9c06ba80d 100644
--- a/sd/inc/sdfilter.hxx
+++ b/sd/inc/sdfilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,5 @@ private:
};
#endif // _SD_SDFILTER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdgrffilter.hxx b/sd/inc/sdgrffilter.hxx
index a92bc0afe..e2d1ca122 100755..100644
--- a/sd/inc/sdgrffilter.hxx
+++ b/sd/inc/sdgrffilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,5 @@ public:
};
#endif // _SD_SDGRFFILTER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdhtmlfilter.hxx b/sd/inc/sdhtmlfilter.hxx
index 34e2ac603..5b4427d3f 100755..100644
--- a/sd/inc/sdhtmlfilter.hxx
+++ b/sd/inc/sdhtmlfilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ private:
};
#endif // _SD_SDHTMLFILTER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdiocmpt.hxx b/sd/inc/sdiocmpt.hxx
index 904168e77..e43d42851 100755..100644
--- a/sd/inc/sdiocmpt.hxx
+++ b/sd/inc/sdiocmpt.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,4 @@ public:
#endif // _SD_SDIOCMPT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdmod.hxx b/sd/inc/sdmod.hxx
index 74a10b789..6ffac8b11 100755..100644
--- a/sd/inc/sdmod.hxx
+++ b/sd/inc/sdmod.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -214,3 +215,4 @@ private:
#endif // _SDMOD_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdobjfac.hxx b/sd/inc/sdobjfac.hxx
index 01e28732f..962badaa0 100644
--- a/sd/inc/sdobjfac.hxx
+++ b/sd/inc/sdobjfac.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ extern SdObjectFactory aSdObjectFactory;
#endif // _SDOBJFAC_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdpage.hxx b/sd/inc/sdpage.hxx
index 0b894c811..6b018b8a6 100755..100644
--- a/sd/inc/sdpage.hxx
+++ b/sd/inc/sdpage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _SDPAGE_HXX
#define _SDPAGE_HXX
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
#ifndef INCLUDED_FUNCTIONAL
#include <functional>
@@ -44,9 +43,7 @@
#include <functional>
#include <vector>
#include <svx/svdobj.hxx>
-#ifndef _FM_FMPAGE_HXX //autogen
#include <svx/fmpage.hxx>
-#endif
#include "fadedef.h"
#include "diadef.h"
#ifndef _PRESENTATION
@@ -188,7 +185,7 @@ public:
virtual void SetUppBorder(sal_Int32 nBorder);
virtual void SetLwrBorder(sal_Int32 nBorder);
virtual void SetModel(SdrModel* pNewModel);
- virtual FASTBOOL IsReadOnly() const;
+ virtual bool IsReadOnly() const;
sd::ShapeList& GetPresentationShapeList() { return maPresentationShapeList; }
@@ -221,7 +218,7 @@ public:
virtual SdrObject* NbcRemoveObject(sal_uLong nObjNum);
virtual SdrObject* RemoveObject(sal_uLong nObjNum);
- // #95876# Also overload ReplaceObject methods to realize when
+ // Also overload ReplaceObject methods to realize when
// objects are removed with this mechanism instead of RemoveObject
virtual SdrObject* NbcReplaceObject(SdrObject* pNewObj, sal_uLong nObjNum);
virtual SdrObject* ReplaceObject(SdrObject* pNewObj, sal_uLong nObjNum);
@@ -411,3 +408,5 @@ private:
};
#endif // _SDPAGE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdpptwrp.hxx b/sd/inc/sdpptwrp.hxx
index 3eaa7bcfa..9b7f87c69 100644
--- a/sd/inc/sdpptwrp.hxx
+++ b/sd/inc/sdpptwrp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,5 @@ private:
};
#endif // _SD_PPTWRP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdresid.hxx b/sd/inc/sdresid.hxx
index 4408a52de..123de1ca0 100755..100644
--- a/sd/inc/sdresid.hxx
+++ b/sd/inc/sdresid.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef SD_RESID_HXX
#define SD_RESID_HXX
-#ifndef _RESID_HXX //autogen
#include <tools/resid.hxx>
-#endif
#include "sddllapi.h"
class SD_DLLPUBLIC SdResId : public ResId
@@ -40,3 +39,5 @@ public:
};
#endif /* _SD_SDRESID_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdundo.hxx b/sd/inc/sdundo.hxx
index a09b5ec67..daa0b534d 100644
--- a/sd/inc/sdundo.hxx
+++ b/sd/inc/sdundo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ protected:
};
#endif // _SD_SDUNDO_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/sdxmlwrp.hxx b/sd/inc/sdxmlwrp.hxx
index c0ba807ee..4ae0e46df 100755..100644
--- a/sd/inc/sdxmlwrp.hxx
+++ b/sd/inc/sdxmlwrp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,3 +62,5 @@ private:
};
#endif // _SDXMLWRP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/shapelist.hxx b/sd/inc/shapelist.hxx
index 87d6c2153..e0af9510e 100755..100644
--- a/sd/inc/shapelist.hxx
+++ b/sd/inc/shapelist.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -84,3 +85,5 @@ namespace sd
}
#endif // _SHAPELIST_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/stlfamily.hxx b/sd/inc/stlfamily.hxx
index d7bdcbf0e..5d97f16a3 100644
--- a/sd/inc/stlfamily.hxx
+++ b/sd/inc/stlfamily.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124,3 +125,5 @@ private:
typedef rtl::Reference< SdStyleFamily > SdStyleFamilyRef;
#endif // _SD_STLFAMILY_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/stlpool.hxx b/sd/inc/stlpool.hxx
index 4fe4cfe32..6ef2f2556 100755..100644
--- a/sd/inc/stlpool.hxx
+++ b/sd/inc/stlpool.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,6 +50,7 @@
class SdStyleSheet;
class SdDrawDocument;
class SdPage;
+class SfxStyleSheetBase;
typedef std::map< const SdPage*, SdStyleFamilyRef > SdStyleFamilyMap;
@@ -70,7 +72,7 @@ public:
SfxStyleSheetBase* GetTitleSheet(const String& rLayoutName);
// Caller muss Liste loeschen
- List* CreateOutlineSheetList(const String& rLayoutName);
+ void CreateOutlineSheetList(const String& rLayoutName, std::vector<SfxStyleSheetBase*> &rOutlineStyles);
/** creates all layout style sheets for the givin layout name if they
don't exist yet.
@@ -81,7 +83,7 @@ public:
when styles are missing.
*/
SD_DLLPUBLIC void CreateLayoutStyleSheets(const String& rLayoutName, sal_Bool bCheck = sal_False );
- List* CreateLayoutSheetNames(const String& rLayoutName) const;
+ void CreateLayoutSheetNames(const String& rLayoutName, std::vector<String> &aNameList) const;
void CreateLayoutSheetList(const String& rLayoutName, SdStyleSheetVector& rLayoutSheets);
void CopyLayoutSheets(const String& rLayoutName, SdStyleSheetPool& rSourcePool, SdStyleSheetVector& rCreatedSheets );
void CopyGraphicSheets(SdStyleSheetPool& rSourcePool);
@@ -149,3 +151,5 @@ private:
};
#endif // _SD_STLPOOL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/stlsheet.hxx b/sd/inc/stlsheet.hxx
index 2037d0ed0..c6693d6b0 100755..100644
--- a/sd/inc/stlsheet.hxx
+++ b/sd/inc/stlsheet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -159,3 +160,4 @@ typedef std::vector< SdStyleSheetRef > SdStyleSheetVector;
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/strmname.h b/sd/inc/strmname.h
index ed555b847..8d8c929cb 100644
--- a/sd/inc/strmname.h
+++ b/sd/inc/strmname.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,9 +43,12 @@ static const String pPreviewName( RTL_CONSTASCII_USTRINGPARAM( "StarDrawTemplate
// PowerPoint-Filter
static const String pFilterPowerPoint97( RTL_CONSTASCII_USTRINGPARAM( "MS PowerPoint 97" ));
static const String pFilterPowerPoint97Template( RTL_CONSTASCII_USTRINGPARAM( "MS PowerPoint 97 Vorlage" ));
+static const String pFilterPowerPoint97AutoPlay( RTL_CONSTASCII_USTRINGPARAM( "MS PowerPoint 97 AutoPlay" ));
// XML content stream
static const String pStarDrawXMLContent( RTL_CONSTASCII_USTRINGPARAM( "content.xml" ));
static const String pStarDrawOldXMLContent( RTL_CONSTASCII_USTRINGPARAM( "Content.xml" ));
#endif // _SD_STRMNAME_H
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/textapi.hxx b/sd/inc/textapi.hxx
index 99186d46d..5fa582174 100755..100644
--- a/sd/inc/textapi.hxx
+++ b/sd/inc/textapi.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,5 @@ private:
#endif // _SD_TEXTAPI_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/undo/undofactory.hxx b/sd/inc/undo/undofactory.hxx
index ac39f8b69..cd1e7d6be 100644
--- a/sd/inc/undo/undofactory.hxx
+++ b/sd/inc/undo/undofactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,5 @@ public:
}
#endif // _SD_UNDOMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/undo/undomanager.hxx b/sd/inc/undo/undomanager.hxx
index 874a4c8c0..bd7f3c1b7 100755..100644
--- a/sd/inc/undo/undomanager.hxx
+++ b/sd/inc/undo/undomanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,5 @@ private:
}
#endif // _SD_UNDOMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/undo/undoobjects.hxx b/sd/inc/undo/undoobjects.hxx
index 5048d9292..c0975ed1e 100644
--- a/sd/inc/undo/undoobjects.hxx
+++ b/sd/inc/undo/undoobjects.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -200,3 +201,5 @@ protected:
} // namespace sd
#endif // _SD_UNDOOBJECTS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/inc/undoanim.hxx b/sd/inc/undoanim.hxx
index 8c173039b..0e626c5d4 100644
--- a/sd/inc/undoanim.hxx
+++ b/sd/inc/undoanim.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,4 @@ private:
#endif // _SD_UNDO_ANIM_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/prj/build.lst b/sd/prj/build.lst
index 72ee2777a..dc4c16095 100644
--- a/sd/prj/build.lst
+++ b/sd/prj/build.lst
@@ -1,48 +1,3 @@
-sd sd : filter L10N:l10n animations svx sfx2 stoc canvas LIBXSLT:libxslt NULL
+sd sd : filter TRANSLATIONS:translations animations svx sfx2 stoc canvas LIBXSLT:libxslt oox ure NULL
sd sd usr1 - all sd_mkout NULL
-sd sd\inc nmake - all sd_inc NULL
-sd sd\prj get - all sd_prj NULL
-sd sd\source\ui\inc get - all sd_sinc NULL
-sd sd\res get - all sd_res NULL
-sd sd\res\imagelst get - all sd_resil NULL
-sd sd\sdi nmake - all sd_sdi NULL
-sd sd\source\helper nmake - all sd_helper sd_inc NULL
-sd sd\source\ui\func nmake - all sd_func sd_sdi sd_inc NULL
-sd sd\source\ui\view nmake - all sd_view sd_sdi sd_inc NULL
-sd sd\source\ui\app nmake - all sd_app sd_sdi sd_inc NULL
-sd sd\source\ui\dlg nmake - all sd_dlg sd_sdi sd_inc NULL
-sd sd\source\core nmake - all sd_core sd_sdi sd_inc NULL
-sd sd\source\core\undo nmake - all sd_undo sd_core sd_inc NULL
-sd sd\source\core\text nmake - all sd_text sd_inc NULL
-sd sd\source\core\annotations nmake - all sd_annotations sd_inc NULL
-sd sd\source\ui\docshell nmake - all sd_docsh sd_sdi sd_inc NULL
-sd sd\source\ui\unoidl nmake - all sd_unid sd_sdi sd_inc NULL
-sd sd\source\ui\accessibility nmake - all sd_accessibility sd_inc NULL
-sd sd\source\ui\toolpanel nmake - all sd_toolpanel sd_sdi sd_inc NULL
-sd sd\source\ui\toolpanel\controls nmake - all sd_toolpanel_controls sd_sdi sd_inc NULL
-sd sd\source\ui\tools nmake - all sd_tools sd_inc NULL
-sd sd\source\ui\slidesorter\shell nmake - all sd_slsshell sd_sdi sd_inc NULL
-sd sd\source\ui\slidesorter\model nmake - all sd_slsmodel sd_inc NULL
-sd sd\source\ui\slidesorter\view nmake - all sd_slsview sd_inc NULL
-sd sd\source\ui\slidesorter\controller nmake - all sd_slscontroller sd_sdi sd_inc NULL
-sd sd\source\ui\slidesorter\cache nmake - all sd_slscache sd_inc NULL
-sd sd\source\ui\controller nmake - all sd_controller sd_inc NULL
-sd sd\source\ui\notes nmake - all sd_notes sd_inc NULL
-sd sd\source\ui\table nmake - all sd_table sd_sdi sd_inc NULL
-sd sd\source\filter\ppt nmake - all sd_ppt sd_inc NULL
-sd sd\source\filter nmake - all sd_filt sd_sdi sd_ppt sd_inc NULL
-sd sd\source\filter\cgm nmake - all sd_cgm sd_inc NULL
-sd sd\source\filter\eppt nmake - all sd_eppt sd_inc NULL
-sd sd\source\filter\grf nmake - all sd_grf sd_inc NULL
-sd sd\source\filter\xml nmake - all sd_xml sd_inc NULL
-sd sd\source\filter\html nmake - all sd_html sd_inc NULL
-sd sd\source\ui\animations nmake - all sd_animations sd_inc NULL
-sd sd\source\ui\slideshow nmake - all sd_slideshow sd_sdi sd_inc NULL
-sd sd\source\ui\presenter nmake - all sd_presenter sd_inc NULL
-sd sd\source\ui\framework\configuration nmake - all sd_framework_configuration sd_inc NULL
-sd sd\source\ui\framework\module nmake - all sd_framework_module sd_inc NULL
-sd sd\source\ui\framework\factories nmake - all sd_framework_factories sd_inc NULL
-sd sd\source\ui\framework\tools nmake - all sd_framework_tools sd_inc NULL
-sd sd\source\ui\annotations nmake - all sd_uiannotations sd_inc NULL
-sd sd\util nmake - all sd_util sd_app sd_cgm sd_core sd_dlg sd_docsh sd_eppt sd_filt sd_func sd_grf sd_unid sd_view sd_xml sd_html sd_ppt sd_accessibility sd_animations sd_toolpanel sd_toolpanel_controls sd_tools sd_slsshell sd_slsmodel sd_slsview sd_slscontroller sd_slscache sd_notes sd_controller sd_table sd_slideshow sd_presenter sd_undo sd_helper sd_framework_configuration sd_framework_module sd_framework_tools sd_framework_factories sd_text sd_annotations sd_uiannotations NULL
-sd sd\qa\unoapi nmake - all sd_qa_unoapi NULL
+sd sd\prj nmake - all sd_prj NULL
diff --git a/sd/prj/d.lst b/sd/prj/d.lst
index 0ebbb9a4e..716d18879 100755..100644
--- a/sd/prj/d.lst
+++ b/sd/prj/d.lst
@@ -1,59 +1,3 @@
-mkdir: %COMMON_DEST%\bin%_EXT%\hid
-mkdir: %COMMON_DEST%\res%_EXT%
-mkdir: %_DEST%\xml%_EXT%\uiconfig
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\sdraw
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\simpress
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\menubar
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\simpress\menubar
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\toolbar
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\simpress\toolbar
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\statusbar
-mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\simpress\statusbar
-..\%COMMON_OUTDIR%\misc\*.hid %COMMON_DEST%\bin%_EXT%\hid\*.hid
-..\%COMMON_OUTDIR%\srs\core_srs.hid %COMMON_DEST%\res%_EXT%\sdcore_srs.hid
-
-..\%__SRC%\misc\*.map %_DEST%\bin%_EXT%\*.map
-..\%__SRC%\lib\sdi.lib %_DEST%\lib%_EXT%\sdi.lib
-..\%__SRC%\slb\lib*.* %_DEST%\lib%_EXT%\lib*.*
-..\%__SRC%\lib\lib*.* %_DEST%\lib%_EXT%\lib*.*
-..\%__SRC%\bin\sd?????.dll %_DEST%\bin%_EXT%\sd?????.dll
-..\%__SRC%\bin\sd??????.dll %_DEST%\bin%_EXT%\sd??????.dll
-..\%__SRC%\bin\sd*.res %_DEST%\bin%_EXT%\sd*.res
-..\%__SRC%\bin\sd???????.dll %_DEST%\bin%_EXT%\sd???????.dll
-..\%__SRC%\bin\emp?????.* %_DEST%\bin%_EXT%\emp?????.*
-
-mkdir: %_DEST%\pck%_EXT%
-..\res\webview\common.inc %_DEST%\pck%_EXT%\common.inc
-..\res\webview\common.pl %_DEST%\pck%_EXT%\common.pl
-..\res\webview\edit.asp %_DEST%\pck%_EXT%\edit.asp
-..\res\webview\edit.pl %_DEST%\pck%_EXT%\edit.pl
-..\res\webview\editpic.asp %_DEST%\pck%_EXT%\editpic.asp
-..\res\webview\editpic.pl %_DEST%\pck%_EXT%\editpic.pl
-..\res\webview\index.pl %_DEST%\pck%_EXT%\index.pl
-..\res\webview\poll.asp %_DEST%\pck%_EXT%\poll.asp
-..\res\webview\poll.pl %_DEST%\pck%_EXT%\poll.pl
-..\res\webview\savepic.asp %_DEST%\pck%_EXT%\savepic.asp
-..\res\webview\savepic.pl %_DEST%\pck%_EXT%\savepic.pl
-..\res\webview\show.asp %_DEST%\pck%_EXT%\show.asp
-..\res\webview\show.pl %_DEST%\pck%_EXT%\show.pl
-..\res\webview\webview.asp %_DEST%\pck%_EXT%\webcast.asp
-..\res\webview\webview.pl %_DEST%\pck%_EXT%\webcast.pl
-
-..\res\buttons\*.zip %_DEST%\pck%_EXT%\*.zip
-
-mkdir: %_DEST%\inc%_EXT%\sd
-..\inc\sddll.hxx %_DEST%\inc%_EXT%\sd\sddll.hxx
-
-..\xml\*.xml %_DEST%\xml%_EXT%\*.xml
-
-..\uiconfig\sdraw\menubar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\menubar\*.xml
-..\uiconfig\simpress\menubar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\simpress\menubar\*.xml
-..\uiconfig\sdraw\toolbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\toolbar\*.xml
-..\uiconfig\simpress\toolbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\simpress\toolbar\*.xml
-..\uiconfig\sdraw\statusbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\sdraw\statusbar\*.xml
-..\uiconfig\simpress\statusbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\simpress\statusbar\*.xml
-
-..\%__SRC%\misc\sd.component %_DEST%\xml%_EXT%\sd.component
-..\%__SRC%\misc\sdd.component %_DEST%\xml%_EXT%\sdd.component
+..\%__SRC%\misc\sdfilt.component %_DEST%\xml\sdfilt.component
+..\%__SRC%\misc\sdfilt.component %_DEST%\xml%_EXT%\sdfilt.component \ No newline at end of file
diff --git a/sd/source/filter/cgm/makefile.mk b/sd/prj/makefile.mk
index 65ac2c485..e312a7cca 100644..100755
--- a/sd/source/filter/cgm/makefile.mk
+++ b/sd/prj/makefile.mk
@@ -25,19 +25,16 @@
#
#*************************************************************************
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=cgm
-
-# --- Settings -----------------------------------------------------
+PRJ=..
+TARGET=prj
.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/sdcgmfilter.obj
-# --- Targets --------------------------------------------------------------
+.IF "$(VERBOSE)"!=""
+VERBOSEFLAG :=
+.ELSE
+VERBOSEFLAG := -s
+.ENDIF
-.INCLUDE : target.mk
+all:
+ cd $(PRJ) && $(GNUMAKE) $(VERBOSEFLAG) -r -j$(MAXPROCESS) $(gb_MAKETARGET) && $(GNUMAKE) $(VERBOSEFLAG) -r deliverlog
diff --git a/sd/qa/unit/export.map b/sd/qa/unit/export.map
new file mode 100644
index 000000000..4ca70fa85
--- /dev/null
+++ b/sd/qa/unit/export.map
@@ -0,0 +1,7 @@
+UDK_3.0 {
+ global:
+ registerAllTestFunction;
+
+ local:
+ *;
+};
diff --git a/sd/qa/unit/uimpress.cxx b/sd/qa/unit/uimpress.cxx
new file mode 100644
index 000000000..c34f72454
--- /dev/null
+++ b/sd/qa/unit/uimpress.cxx
@@ -0,0 +1,133 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Initial Developer of the Original Code is
+ * Novell, Inc.
+ * Portions created by the Initial Developer are Copyright (C) 2010 the
+ * Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s): Thorsten Behrens <tbehrens@novell.com>
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include "precompiled_sd.hxx"
+
+#include <sal/config.h>
+#include <sal/cppunit.h>
+
+#include <cppuhelper/bootstrap.hxx>
+#include <comphelper/processfactory.hxx>
+
+#include <vcl/svapp.hxx>
+#include <sddll.hxx>
+#include <drawdoc.hxx>
+
+#include <iostream>
+#include <vector>
+
+using namespace ::com::sun::star;
+
+namespace {
+
+class Test : public CppUnit::TestFixture {
+public:
+ Test();
+ ~Test();
+
+ virtual void setUp();
+ virtual void tearDown();
+
+ void testAddPage();
+ void testCustomShow();
+
+ CPPUNIT_TEST_SUITE(Test);
+ CPPUNIT_TEST(testAddPage);
+ CPPUNIT_TEST(testCustomShow);
+ CPPUNIT_TEST_SUITE_END();
+
+private:
+ uno::Reference< uno::XComponentContext > m_xContext;
+ SdDrawDocument* m_pDoc;
+};
+
+Test::Test()
+ : m_pDoc(0)
+{
+ m_xContext = cppu::defaultBootstrap_InitialComponentContext();
+
+ uno::Reference<lang::XMultiComponentFactory> xFactory(m_xContext->getServiceManager());
+ uno::Reference<lang::XMultiServiceFactory> xSM(xFactory, uno::UNO_QUERY_THROW);
+
+ //Without this we're crashing because callees are using
+ //getProcessServiceFactory. In general those should be removed in favour
+ //of retaining references to the root ServiceFactory as its passed around
+ comphelper::setProcessServiceFactory(xSM);
+
+ InitVCL(xSM);
+
+ SdDLL::Init();
+}
+
+void Test::setUp()
+{
+ m_pDoc = new SdDrawDocument(DOCUMENT_TYPE_IMPRESS, NULL);
+}
+
+void Test::tearDown()
+{
+ delete m_pDoc;
+}
+
+Test::~Test()
+{
+ uno::Reference< lang::XComponent >(m_xContext, uno::UNO_QUERY_THROW)->dispose();
+}
+
+void Test::testAddPage()
+{
+ SdrPage* pPage = m_pDoc->AllocPage(false);
+ m_pDoc->InsertPage(pPage);
+ CPPUNIT_ASSERT_MESSAGE("added one page to model",
+ m_pDoc->GetPageCount()==1);
+ m_pDoc->DeletePage(0);
+ CPPUNIT_ASSERT_MESSAGE("removed one page to model",
+ m_pDoc->GetPageCount()==0);
+
+ SdrPage* pMasterPage = m_pDoc->AllocPage(true);
+ m_pDoc->InsertMasterPage(pMasterPage);
+ CPPUNIT_ASSERT_MESSAGE("added one master page to model",
+ m_pDoc->GetMasterPageCount()==1);
+ m_pDoc->DeleteMasterPage(0);
+ CPPUNIT_ASSERT_MESSAGE("removed one master page to model",
+ m_pDoc->GetMasterPageCount()==0);
+}
+
+void Test::testCustomShow()
+{
+ CPPUNIT_ASSERT_MESSAGE("test generation of custom show list!",
+ m_pDoc->GetCustomShowList(sal_True));
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
+
+}
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/qa/unit/version.map b/sd/qa/unit/version.map
new file mode 100644
index 000000000..3308588ef
--- /dev/null
+++ b/sd/qa/unit/version.map
@@ -0,0 +1,34 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+UDK_3_0_0 {
+ global:
+ cppunitTestPlugIn;
+
+ local:
+ *;
+};
diff --git a/sd/qa/unoapi/Test.java b/sd/qa/unoapi/Test.java
deleted file mode 100644
index cfb4f13d7..000000000
--- a/sd/qa/unoapi/Test.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*************************************************************************
-* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-*
-* Copyright 2000, 2010 Oracle and/or its affiliates.
-*
-* OpenOffice.org - a multi-platform office productivity suite
-*
-* This file is part of OpenOffice.org.
-*
-* OpenOffice.org is free software: you can redistribute it and/or modify
-* it under the terms of the GNU Lesser General Public License version 3
-* only, as published by the Free Software Foundation.
-*
-* OpenOffice.org is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-* GNU Lesser General Public License version 3 for more details
-* (a copy is included in the LICENSE file that accompanied this code).
-*
-* You should have received a copy of the GNU Lesser General Public License
-* version 3 along with OpenOffice.org. If not, see
-* <http://www.openoffice.org/license.html>
-* for a copy of the LGPLv3 License.
-************************************************************************/
-
-package org.openoffice.sd.qa.unoapi;
-
-import org.openoffice.Runner;
-import org.openoffice.test.OfficeConnection;
-import static org.junit.Assert.*;
-
-public final class Test {
- @org.junit.Before public void setUp() throws Exception {
- connection.setUp();
- }
-
- @org.junit.After public void tearDown()
- throws InterruptedException, com.sun.star.uno.Exception
- {
- connection.tearDown();
- }
-
- @org.junit.Test public void test() {
- assertTrue(
- Runner.run(
- "-sce", "sd.sce", "-xcl", "knownissues.xcl", "-cs",
- connection.getDescription()));
- }
-
- private final OfficeConnection connection = new OfficeConnection();
-}
diff --git a/sd/sdi/SlideSorterController.sdi b/sd/sdi/SlideSorterController.sdi
index 2077b62dd..ba3667e3f 100755
--- a/sd/sdi/SlideSorterController.sdi
+++ b/sd/sdi/SlideSorterController.sdi
@@ -273,7 +273,6 @@ interface SlideSorterView
StateMethod = GetCtrlState ;
]
- // #96090#
SID_GETUNDOSTRINGS // ole : no, status : ?
[
ExecMethod = FuSupport ;
diff --git a/sd/sdi/_drvwsh.sdi b/sd/sdi/_drvwsh.sdi
index ddc51c9ac..a307b4528 100755
--- a/sd/sdi/_drvwsh.sdi
+++ b/sd/sdi/_drvwsh.sdi
@@ -25,18 +25,6 @@
*
************************************************************************/
-enum SdrFitToSizeType
-{
- SDRTEXTFIT_NONE ,
- SDRTEXTFIT_PROPORTIONAL ,
- SDRTEXTFIT_ALLLINES ,
- SDRTEXTFIT_RESIZEATTR
-}
-item UINT32 SvxObjectItem ;
-item BOOL SdrShadowItem ;
-item SdrFitToSizeType SdrTextFitToSizeTypeItem ;
-
-
interface DrawView
{
SID_JUMPTOMARK // ole : no, status : ?
@@ -669,6 +657,11 @@ interface DrawView
ExecMethod = FuPermanent ;
StateMethod = GetMenuState ;
]
+ SID_OUTLINE_TEXT_AUTOFIT // ole : no, status : ?
+ [
+ ExecMethod = FuTemporary ;
+ StateMethod = GetMenuState ;
+ ]
SID_TEXT_FITTOSIZE_VERTICAL // ole : no, status : ?
[
ExecMethod = FuPermanent ;
@@ -1234,7 +1227,6 @@ interface DrawView
[
ExecMethod = FuPermanent ;
]
- // #98721#
SID_FM_CREATE_FIELDCONTROL
[
SlotType = SfxBoolItem ;
@@ -1952,27 +1944,6 @@ interface DrawView
//ExecMethod = FuTemporary ;
//StateMethod = GetMenuState ;
]
- // Neue Slots fuer Optionsleiste
-//#i80528# SID_GRAPHIC_DRAFT // ole : ?, status : ?
-//#i80528# [
-//#i80528# ExecMethod = ExecOptionsBar ;
-//#i80528# StateMethod = GetOptionsBarState ;
-//#i80528# ]
-//#i80528# SID_FILL_DRAFT // ole : ?, status : ?
-//#i80528# [
-//#i80528# ExecMethod = ExecOptionsBar ;
-//#i80528# StateMethod = GetOptionsBarState ;
-//#i80528# ]
-//#i80528# SID_TEXT_DRAFT // ole : ?, status : ?
-//#i80528# [
-//#i80528# ExecMethod = ExecOptionsBar ;
-//#i80528# StateMethod = GetOptionsBarState ;
-//#i80528# ]
-//#i80528# SID_LINE_DRAFT // ole : ?, status : ?
-//#i80528# [
-//#i80528# ExecMethod = ExecOptionsBar ;
-//#i80528# StateMethod = GetOptionsBarState ;
-//#i80528# ]
SID_HANDLES_DRAFT // ole : ?, status : ?
[
ExecMethod = ExecOptionsBar ;
@@ -2183,6 +2154,11 @@ interface DrawView
ExecMethod = FuSupport ;
StateMethod = GetCtrlState ;
]
+ SID_TRANSLITERATE_ROTATE_CASE // ole : no, status : ?
+ [
+ ExecMethod = FuSupportRotate ;
+ StateMethod = GetCtrlState ;
+ ]
SID_TRANSLITERATE_LOWER // ole : no, status : ?
[
ExecMethod = FuSupport ;
diff --git a/sd/sdi/makefile.mk b/sd/sdi/makefile.mk
deleted file mode 100755
index a950aad5d..000000000
--- a/sd/sdi/makefile.mk
+++ /dev/null
@@ -1,97 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..
-
-PRJNAME=sd
-TARGET=sdslots
-TARGET2=sdgslots
-SDI1EXPORT=sdraw
-SDI2EXPORT=sdraw
-SVSDIINC=$(PRJ)$/source$/ui$/inc
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.IF "$(L10N_framework)"==""
-
-# --- Files --------------------------------------------------------
-
-
-SDI1NAME=$(TARGET)
-SDI2NAME=$(TARGET2)
-SIDHRCNAME=SDSLOTS.HRC
-
-SVSDI1DEPEND= \
- $(SOLARINCXDIR)$/sfx2/sfx.sdi \
- $(SOLARINCXDIR)$/sfx2/sfxitems.sdi \
- $(SOLARINCXDIR)$/svx/svx.sdi \
- $(SOLARINCXDIR)$/svx/svxitems.sdi \
- $(SOLARINCXDIR)$/svx/xoitems.sdi \
- sdraw.sdi \
- app.sdi \
- _docsh.sdi \
- docshell.sdi \
- drtxtob.sdi \
- drbezob.sdi \
- drgrfob.sdi \
- _drvwsh.sdi \
- drviewsh.sdi \
- mediaob.sdi \
- tables.sdi\
- outlnvsh.sdi \
- SlideSorterController.sdi \
- ViewShellBase.sdi \
- ToolPanelViewShell.sdi \
- sdslots.hrc \
- $(PRJ)$/inc$/app.hrc
-
-SVSDI2DEPEND= \
- $(SOLARINCXDIR)$/sfx2/sfx.sdi \
- $(SOLARINCXDIR)$/sfx2/sfxitems.sdi \
- $(SOLARINCXDIR)$/svx/svx.sdi \
- $(SOLARINCXDIR)$/svx/svxitems.sdi \
- $(SOLARINCXDIR)$/svx/xoitems.sdi \
- sdraw.sdi \
- app.sdi \
- _docsh.sdi \
- grdocsh.sdi \
- drtxtob.sdi \
- drbezob.sdi \
- drgrfob.sdi \
- _drvwsh.sdi \
- grviewsh.sdi \
- mediaob.sdi \
- outlnvsh.sdi \
- ViewShellBase.sdi \
- ToolPanelViewShell.sdi \
- sdslots.hrc \
- $(PRJ)$/inc$/app.hrc
-
-# --- Targets -------------------------------------------------------
-.ENDIF
-.INCLUDE : target.mk
diff --git a/sd/sdi/outlnvsh.sdi b/sd/sdi/outlnvsh.sdi
index e4f3b2a64..d2c9239be 100755
--- a/sd/sdi/outlnvsh.sdi
+++ b/sd/sdi/outlnvsh.sdi
@@ -484,7 +484,6 @@ interface OutlineView
StateMethod = GetCtrlState ;
]
- // #96090#
SID_GETUNDOSTRINGS // ole : no, status : ?
[
ExecMethod = FuSupport ;
diff --git a/sd/sdi/sdraw.sdi b/sd/sdi/sdraw.sdi
index e321cd7ee..016590ebf 100755
--- a/sd/sdi/sdraw.sdi
+++ b/sd/sdi/sdraw.sdi
@@ -2328,33 +2328,6 @@ SfxVoidItem SetFillColor SID_SETFILLCOLOR
]
//--------------------------------------------------------------------------
-//#i80528#SfxBoolItem FillDraft SID_FILL_DRAFT
-//#i80528#
-//#i80528#[
-//#i80528# /* flags: */
-//#i80528# AutoUpdate = FALSE,
-//#i80528# Cachable = Cachable,
-//#i80528# FastCall = FALSE,
-//#i80528# HasCoreId = FALSE,
-//#i80528# HasDialog = FALSE,
-//#i80528# ReadOnlyDoc = TRUE,
-//#i80528# Toggle = FALSE,
-//#i80528# Container = FALSE,
-//#i80528# RecordAbsolute = FALSE,
-//#i80528# RecordPerSet;
-//#i80528# Synchron;
-//#i80528#
-//#i80528# Readonly = FALSE,
-//#i80528#
-//#i80528# /* config: */
-//#i80528# AccelConfig = TRUE,
-//#i80528# MenuConfig = TRUE,
-//#i80528# StatusBarConfig = FALSE,
-//#i80528# ToolBoxConfig = TRUE,
-//#i80528# GroupId = GID_VIEW;
-//#i80528#]
-
-//--------------------------------------------------------------------------
SfxVoidItem Forward SID_MOREFRONT
()
[
@@ -2989,33 +2962,6 @@ SfxVoidItem GradientStartColor SID_SETGRADSTARTCOLOR
]
//--------------------------------------------------------------------------
-//#i80528#SfxBoolItem GraphicDraft SID_GRAPHIC_DRAFT
-//#i80528#
-//#i80528#[
-//#i80528# /* flags: */
-//#i80528# AutoUpdate = FALSE,
-//#i80528# Cachable = Cachable,
-//#i80528# FastCall = FALSE,
-//#i80528# HasCoreId = FALSE,
-//#i80528# HasDialog = FALSE,
-//#i80528# ReadOnlyDoc = TRUE,
-//#i80528# Toggle = FALSE,
-//#i80528# Container = FALSE,
-//#i80528# RecordAbsolute = FALSE,
-//#i80528# RecordPerSet;
-//#i80528# Synchron;
-//#i80528#
-//#i80528# Readonly = FALSE,
-//#i80528#
-//#i80528# /* config: */
-//#i80528# AccelConfig = TRUE,
-//#i80528# MenuConfig = TRUE,
-//#i80528# StatusBarConfig = FALSE,
-//#i80528# ToolBoxConfig = TRUE,
-//#i80528# GroupId = GID_VIEW;
-//#i80528#]
-
-//--------------------------------------------------------------------------
SfxVoidItem GraphicExport SID_GRAPHIC_EXPORT
()
[
@@ -4031,33 +3977,6 @@ SfxVoidItem LineColor SID_SETLINECOLOR
]
//--------------------------------------------------------------------------
-//#i80528#SfxBoolItem LineDraft SID_LINE_DRAFT
-//#i80528#
-//#i80528#[
-//#i80528# /* flags: */
-//#i80528# AutoUpdate = FALSE,
-//#i80528# Cachable = Cachable,
-//#i80528# FastCall = FALSE,
-//#i80528# HasCoreId = FALSE,
-//#i80528# HasDialog = FALSE,
-//#i80528# ReadOnlyDoc = TRUE,
-//#i80528# Toggle = FALSE,
-//#i80528# Container = FALSE,
-//#i80528# RecordAbsolute = FALSE,
-//#i80528# RecordPerSet;
-//#i80528# Synchron;
-//#i80528#
-//#i80528# Readonly = FALSE,
-//#i80528#
-//#i80528# /* config: */
-//#i80528# AccelConfig = TRUE,
-//#i80528# MenuConfig = TRUE,
-//#i80528# StatusBarConfig = FALSE,
-//#i80528# ToolBoxConfig = TRUE,
-//#i80528# GroupId = GID_VIEW;
-//#i80528#]
-
-//--------------------------------------------------------------------------
SfxVoidItem LineEndPolygon SID_LINEEND_POLYGON
()
[
@@ -6297,34 +6216,34 @@ SfxVoidItem TextAttributes SID_TEXTATTR_DLG
]
//--------------------------------------------------------------------------
-//#i80528#SfxBoolItem TextDraft SID_TEXT_DRAFT
-//#i80528#
-//#i80528#[
-//#i80528# /* flags: */
-//#i80528# AutoUpdate = FALSE,
-//#i80528# Cachable = Cachable,
-//#i80528# FastCall = FALSE,
-//#i80528# HasCoreId = FALSE,
-//#i80528# HasDialog = FALSE,
-//#i80528# ReadOnlyDoc = TRUE,
-//#i80528# Toggle = FALSE,
-//#i80528# Container = FALSE,
-//#i80528# RecordAbsolute = FALSE,
-//#i80528# RecordPerSet;
-//#i80528# Synchron;
-//#i80528#
-//#i80528# Readonly = FALSE,
-//#i80528#
-//#i80528# /* config: */
-//#i80528# AccelConfig = TRUE,
-//#i80528# MenuConfig = TRUE,
-//#i80528# StatusBarConfig = FALSE,
-//#i80528# ToolBoxConfig = TRUE,
-//#i80528# GroupId = GID_VIEW;
-//#i80528#]
+SfxBoolItem TextFitToSizeTool SID_TEXT_FITTOSIZE
+
+[
+ /* flags: */
+ AutoUpdate = TRUE,
+ Cachable = Cachable,
+ FastCall = FALSE,
+ HasCoreId = FALSE,
+ HasDialog = FALSE,
+ ReadOnlyDoc = FALSE,
+ Toggle = FALSE,
+ Container = FALSE,
+ RecordAbsolute = FALSE,
+ RecordPerSet;
+ Synchron;
+
+ Readonly = FALSE,
+
+ /* config: */
+ AccelConfig = TRUE,
+ MenuConfig = TRUE,
+ StatusBarConfig = FALSE,
+ ToolBoxConfig = TRUE,
+ GroupId = GID_FORMAT;
+]
//--------------------------------------------------------------------------
-SfxBoolItem TextFitToSizeTool SID_TEXT_FITTOSIZE
+SfxBoolItem TextAutoFitToSize SID_OUTLINE_TEXT_AUTOFIT
[
/* flags: */
diff --git a/sd/source/core/CustomAnimationCloner.cxx b/sd/source/core/CustomAnimationCloner.cxx
index 002cca85c..d931f1a2b 100644
--- a/sd/source/core/CustomAnimationCloner.cxx
+++ b/sd/source/core/CustomAnimationCloner.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,22 +30,12 @@
#include "precompiled_sd.hxx"
#include <com/sun/star/animations/XAnimationNode.hpp>
#include <com/sun/star/animations/Event.hpp>
-#ifndef _COM_SUN_STAR_ANIMATIONS_XAnimateColor_HPP_
#include <com/sun/star/animations/XAnimateColor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ANIMATIONS_XAnimateSet_HPP_
#include <com/sun/star/animations/XAnimateSet.hpp>
-#endif
#include <com/sun/star/animations/XCommand.hpp>
-#ifndef _COM_SUN_STAR_ANIMATIONS_XAnimateMotion_HPP_
#include <com/sun/star/animations/XAnimateMotion.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ANIMATIONS_XAnimateTransform_HPP_
#include <com/sun/star/animations/XAnimateTransform.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ANIMATIONS_XTransitionFilter_HPP_
#include <com/sun/star/animations/XTransitionFilter.hpp>
-#endif
#include <com/sun/star/animations/XIterateContainer.hpp>
#include <com/sun/star/animations/XAudio.hpp>
#include <com/sun/star/animations/AnimationNodeType.hpp>
@@ -149,7 +140,7 @@ namespace sd
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::CustomAnimationClonerImpl::Clone(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -234,7 +225,7 @@ namespace sd
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::CustomAnimationClonerImpl::transformNode(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -309,7 +300,7 @@ namespace sd
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::CustomAnimationClonerImpl::transformValue(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -344,7 +335,9 @@ namespace sd
return maCloneNodeVector[nNode];
}
- DBG_ERROR( "sd::CustomAnimationClonerImpl::getClonedNode() failed!" );
+ OSL_FAIL( "sd::CustomAnimationClonerImpl::getClonedNode() failed!" );
return xSource;
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/CustomAnimationEffect.cxx b/sd/source/core/CustomAnimationEffect.cxx
index b2b3b6320..c6ceae3a0 100755..100644
--- a/sd/source/core/CustomAnimationEffect.cxx
+++ b/sd/source/core/CustomAnimationEffect.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,9 +58,7 @@
#include <com/sun/star/lang/Locale.hpp>
#include <com/sun/star/i18n/XBreakIterator.hpp>
#include <com/sun/star/i18n/CharacterIteratorMode.hpp>
-#ifndef _COM_SUN_STAR_TEXT_WORDTYPE_HPP_
#include <com/sun/star/i18n/WordType.hpp>
-#endif
#include <com/sun/star/presentation/TextAnimationType.hpp>
#include <basegfx/polygon/b2dpolypolygon.hxx>
@@ -177,27 +176,27 @@ void CustomAnimationEffect::setNode( const ::com::sun::star::uno::Reference< ::c
while( nLength-- )
{
- if( p->Name.equalsAscii( "node-type" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
{
p->Value >>= mnNodeType;
}
- else if( p->Name.equalsAscii( "preset-id" ) )
+ else if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-id" ) ) )
{
p->Value >>= maPresetId;
}
- else if( p->Name.equalsAscii( "preset-sub-type" ) )
+ else if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-sub-type" ) ) )
{
p->Value >>= maPresetSubType;
}
- else if( p->Name.equalsAscii( "preset-class" ) )
+ else if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-class" ) ) )
{
p->Value >>= mnPresetClass;
}
- else if( p->Name.equalsAscii( "preset-property" ) )
+ else if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-property" ) ) )
{
p->Value >>= maProperty;
}
- else if( p->Name.equalsAscii( "group-id" ) )
+ else if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "group-id" ) ) )
{
p->Value >>= mnGroupId;
}
@@ -315,7 +314,7 @@ sal_Int32 CustomAnimationEffect::getNumberOfSubitems( const Any& aTarget, sal_In
{
// TODO/LATER: Optimize this, don't create a break iterator each time
Reference< lang::XMultiServiceFactory > xMSF( ::comphelper::getProcessServiceFactory() );
- Reference < i18n::XBreakIterator > xBI( xMSF->createInstance( OUString::createFromAscii( "com.sun.star.i18n.BreakIterator" ) ), UNO_QUERY );
+ Reference < i18n::XBreakIterator > xBI( xMSF->createInstance( OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.i18n.BreakIterator" )) ), UNO_QUERY );
DBG_ASSERT( xBI.is(), "sd::CustomAnimationEffect::getNumberOfSubitems(), could not create a 'com.sun.star.i18n.BreakIterator'!" );
if( xBI.is() )
@@ -380,7 +379,7 @@ sal_Int32 CustomAnimationEffect::getNumberOfSubitems( const Any& aTarget, sal_In
{
(void)e;
nSubItems = 0;
- DBG_ERROR( "sd::CustomAnimationEffect::getNumberOfSubitems(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::getNumberOfSubitems(), exception cought!" );
}
return nSubItems;
@@ -418,7 +417,7 @@ sal_Int32 CustomAnimationEffect::get_node_type( const Reference< XAnimationNode
const NamedValue* p = aUserData.getConstArray();
while( nLength-- )
{
- if( p->Name.equalsAscii( "node-type" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
{
p->Value >>= nNodeType;
break;
@@ -450,7 +449,7 @@ void CustomAnimationEffect::setPresetClass( sal_Int16 nPresetClass )
NamedValue* p = aUserData.getArray();
while( nLength-- )
{
- if( p->Name.equalsAscii( "preset-class" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-class" ) ) )
{
p->Value <<= mnPresetClass;
bFound = true;
@@ -491,7 +490,7 @@ void CustomAnimationEffect::setNodeType( sal_Int16 nNodeType )
NamedValue* p = aUserData.getArray();
while( nLength-- )
{
- if( p->Name.equalsAscii( "node-type" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
{
p->Value <<= mnNodeType;
bFound = true;
@@ -532,7 +531,7 @@ void CustomAnimationEffect::setGroupId( sal_Int32 nGroupId )
NamedValue* p = aUserData.getArray();
while( nLength-- )
{
- if( p->Name.equalsAscii( "group-id" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "group-id" ) ) )
{
p->Value <<= mnGroupId;
bFound = true;
@@ -708,7 +707,7 @@ void CustomAnimationEffect::setTarget( const ::com::sun::star::uno::Any& rTarget
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setTarget(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setTarget(), exception cought!" );
}
}
@@ -745,7 +744,7 @@ void CustomAnimationEffect::setTargetSubItem( sal_Int16 nSubItem )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setTargetSubItem(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setTargetSubItem(), exception cought!" );
}
}
@@ -795,7 +794,7 @@ void CustomAnimationEffect::setDuration( double fDuration )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setDuration(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setDuration(), exception cought!" );
}
}
@@ -810,7 +809,7 @@ void CustomAnimationEffect::setBegin( double fBegin )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setBegin(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setBegin(), exception cought!" );
}
}
@@ -825,7 +824,7 @@ void CustomAnimationEffect::setAcceleration( double fAcceleration )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setAcceleration(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setAcceleration(), exception cought!" );
}
}
// --------------------------------------------------------------------
@@ -839,7 +838,7 @@ void CustomAnimationEffect::setDecelerate( double fDecelerate )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setDecelerate(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setDecelerate(), exception cought!" );
}
}
@@ -854,7 +853,7 @@ void CustomAnimationEffect::setAutoReverse( sal_Bool bAutoReverse )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationEffect::setAutoReverse(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setAutoReverse(), exception cought!" );
}
}
@@ -1116,7 +1115,7 @@ void CustomAnimationEffect::setIterateType( sal_Int16 nIterateType )
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationEffect::setIterateType(), Exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationEffect::setIterateType(), Exception cought!" );
}
}
@@ -1162,7 +1161,7 @@ void CustomAnimationEffect::setIterateInterval( double fIterateInterval )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::getPath(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::getPath(), exception cought!" );
}
return aPath;
@@ -1191,7 +1190,7 @@ void CustomAnimationEffect::setPath( const ::rtl::OUString& rPath )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setPath(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setPath(), exception cought!" );
}
}
@@ -1241,7 +1240,7 @@ Any CustomAnimationEffect::getProperty( sal_Int32 nNodeType, const OUString& rAt
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::getProperty(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::getProperty(), exception cought!" );
}
return aProperty;
@@ -1319,7 +1318,7 @@ bool CustomAnimationEffect::setProperty( sal_Int32 nNodeType, const OUString& rA
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setProperty(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setProperty(), exception cought!" );
}
return bChanged;
@@ -1378,7 +1377,7 @@ Any CustomAnimationEffect::getColor( sal_Int32 nIndex )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::getColor(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::getColor(), exception cought!" );
}
return aColor;
@@ -1434,7 +1433,7 @@ void CustomAnimationEffect::setColor( sal_Int32 nIndex, const Any& rColor )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setColor(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setColor(), exception cought!" );
}
}
@@ -1481,7 +1480,7 @@ Any CustomAnimationEffect::getTransformationProperty( sal_Int32 nTransformType,
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::getTransformationProperty(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::getTransformationProperty(), exception cought!" );
}
return aProperty;
@@ -1555,7 +1554,7 @@ bool CustomAnimationEffect::setTransformationProperty( sal_Int32 nTransformType,
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setTransformationProperty(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setTransformationProperty(), exception cought!" );
}
return bChanged;
@@ -1578,7 +1577,7 @@ void CustomAnimationEffect::createAudio( const ::com::sun::star::uno::Any& rSour
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::createAudio(), exception cought!" );
+ OSL_FAIL("sd::CustomAnimationEffect::createAudio(), exception cought!" );
}
}
@@ -1602,7 +1601,7 @@ static Reference< XCommand > findCommandNode( const Reference< XAnimationNode >&
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::findCommandNode(), exception caught!" );
+ OSL_FAIL("sd::findCommandNode(), exception caught!" );
}
return xCommand;
@@ -1635,7 +1634,7 @@ void CustomAnimationEffect::removeAudio()
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::removeAudio(), exception caught!" );
+ OSL_FAIL("sd::CustomAnimationEffect::removeAudio(), exception caught!" );
}
}
@@ -1656,7 +1655,7 @@ void CustomAnimationEffect::setAudio( const Reference< ::com::sun::star::animati
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setAudio(), exception caught!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setAudio(), exception caught!" );
}
}
@@ -1683,7 +1682,7 @@ void CustomAnimationEffect::setStopAudio()
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationEffect::setStopAudio(), exception caught!" );
+ OSL_FAIL("sd::CustomAnimationEffect::setStopAudio(), exception caught!" );
}
}
@@ -1926,7 +1925,7 @@ CustomAnimationEffectPtr EffectSequenceHelper::append( const SdrPathObj& rPathOb
}
catch( Exception& )
{
- DBG_ERROR( "sd::EffectSequenceHelper::append(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::append(), exception cought!" );
}
return pEffect;
@@ -1951,7 +1950,7 @@ void EffectSequenceHelper::replace( const CustomAnimationEffectPtr& pEffect, con
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::EffectSequenceHelper::replace(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::replace(), exception cought!" );
}
}
@@ -2108,7 +2107,7 @@ void EffectSequenceHelper::implRebuild()
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::EffectSequenceHelper::rebuild(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::rebuild(), exception cought!" );
}
}
@@ -2215,7 +2214,6 @@ void stl_process_after_effect_node_func(AfterEffectNode& rNode)
{
Reference< XAnimationNode > xNode( xNextContainer, UNO_QUERY_THROW );
xNode->setBegin( makeAny( (double)0.0 ) );
-// xNode->setFill( AnimationFill::HOLD );
xNextClickContainer->appendChild( xNode );
}
}
@@ -2246,7 +2244,6 @@ void stl_process_after_effect_node_func(AfterEffectNode& rNode)
{
Reference< XAnimationNode > xNode( xNextContainer, UNO_QUERY_THROW );
xNode->setBegin( makeAny( (double)0.0 ) );
-// xNode->setFill( AnimationFill::HOLD );
xNewClickContainer->appendChild( xNode );
}
}
@@ -2278,7 +2275,7 @@ void stl_process_after_effect_node_func(AfterEffectNode& rNode)
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "ppt::stl_process_after_effect_node_func::operator(), exception cought!" );
+ OSL_FAIL( "ppt::stl_process_after_effect_node_func::operator(), exception cought!" );
}
}
@@ -2730,7 +2727,7 @@ void EffectSequenceHelper::createTextGroupParagraphEffects( CustomAnimationTextG
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::EffectSequenceHelper::createTextGroup(), exception cought!" );
+ OSL_FAIL("sd::EffectSequenceHelper::createTextGroup(), exception cought!" );
}
}
@@ -3055,7 +3052,7 @@ void EffectSequenceHelper::create( const ::com::sun::star::uno::Reference< ::com
}
catch( Exception& )
{
- DBG_ERROR( "sd::EffectSequenceHelper::create(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::create(), exception cought!" );
}
}
@@ -3078,7 +3075,7 @@ void EffectSequenceHelper::createEffectsequence( const Reference< XAnimationNode
}
catch( Exception& )
{
- DBG_ERROR( "sd::EffectSequenceHelper::createEffectsequence(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::createEffectsequence(), exception cought!" );
}
}
@@ -3125,7 +3122,7 @@ void EffectSequenceHelper::createEffects( const Reference< XAnimationNode >& xNo
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::EffectSequenceHelper::createEffects(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::createEffects(), exception cought!" );
}
}
@@ -3143,7 +3140,7 @@ void EffectSequenceHelper::processAfterEffect( const Reference< XAnimationNode >
while( nLength-- )
{
- if( p->Name.equalsAscii( "master-element" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "master-element" ) ) )
{
p->Value >>= xMaster;
break;
@@ -3187,48 +3184,10 @@ void EffectSequenceHelper::processAfterEffect( const Reference< XAnimationNode >
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::EffectSequenceHelper::processAfterEffect(), exception cought!" );
+ OSL_FAIL( "sd::EffectSequenceHelper::processAfterEffect(), exception cought!" );
}
}
-/*
-double EffectSequenceHelper::calculateIterateNodeDuration(
-{
- Reference< i18n::XBreakIterator > xBI( ImplGetBreakIterator() );
-
- sal_Int32 nDone;
- sal_Int32 nNextCellBreak( xBI->nextCharacters(rTxt, nIdx, rLocale, i18n::CharacterIteratorMode::SKIPCELL, 0, nDone) );
- i18n::Boundary nNextWordBoundary( xBI->getWordBoundary(rTxt, nIdx, rLocale, i18n::WordType::ANY_WORD, sal_True) );
- sal_Int32 nNextSentenceBreak( xBI->endOfSentence(rTxt, nIdx, rLocale) );
-
- const sal_Int32 nEndPos( nIdx + nLen );
- sal_Int32 i, currOffset(0);
- for( i=nIdx; i<nEndPos; ++i )
- {
- // TODO: Check whether position update is valid for CTL/BiDi
- rOutDev.DrawText( rPos + Point(currOffset,0), rTxt, i, 1 );
- currOffset = *pDXArray++;
-
- // issue the comments at the respective break positions
- if( i == nNextCellBreak )
- {
- rMtf.AddAction( new MetaCommentAction( "XTEXT_EOC" ) );
- nNextCellBreak = xBI->nextCharacters(rTxt, i, rLocale, i18n::CharacterIteratorMode::SKIPCELL, 1, nDone);
- }
- if( i == nNextWordBoundary.endPos )
- {
- rMtf.AddAction( new MetaCommentAction( "XTEXT_EOW" ) );
- nNextWordBoundary = xBI->getWordBoundary(rTxt, i+1, rLocale, i18n::WordType::ANY_WORD, sal_True);
- }
- if( i == nNextSentenceBreak )
- {
- rMtf.AddAction( new MetaCommentAction( "XTEXT_EOS" ) );
- nNextSentenceBreak = xBI->endOfSentence(rTxt, i+1, rLocale);
- }
- }
-}
-
-*/
// ====================================================================
class AnimationChangeListener : public cppu::WeakImplHelper1< XChangesListener >
@@ -3388,7 +3347,7 @@ void MainSequence::createMainSequence()
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::MainSequence::create(), exception cought!" );
+ OSL_FAIL( "sd::MainSequence::create(), exception cought!" );
return;
}
@@ -3402,7 +3361,7 @@ void MainSequence::reset()
EffectSequenceHelper::reset();
InteractiveSequenceList::iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); ++aIter )
(*aIter)->reset();
maInteractiveSequenceList.clear();
@@ -3455,7 +3414,7 @@ CustomAnimationEffectPtr MainSequence::findEffect( const ::com::sun::star::uno::
if( pEffect.get() == 0 )
{
InteractiveSequenceList::const_iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); (aIter != maInteractiveSequenceList.end()) && (pEffect.get() == 0); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); (aIter != maInteractiveSequenceList.end()) && (pEffect.get() == 0); ++aIter )
{
pEffect = (*aIter)->findEffect( xNode );
}
@@ -3475,7 +3434,7 @@ sal_Int32 MainSequence::getOffsetFromEffect( const CustomAnimationEffectPtr& pEf
nOffset = EffectSequenceHelper::getCount();
InteractiveSequenceList::const_iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); ++aIter )
{
sal_Int32 nTemp = (*aIter)->getOffsetFromEffect( pEffect );
if( nTemp != -1 )
@@ -3564,7 +3523,7 @@ void MainSequence::insertTextRange( const com::sun::star::uno::Any& aTarget )
EffectSequenceHelper::insertTextRange( aTarget );
InteractiveSequenceList::iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); ++aIter )
{
(*aIter)->insertTextRange( aTarget );
}
@@ -3576,7 +3535,7 @@ void MainSequence::disposeTextRange( const com::sun::star::uno::Any& aTarget )
EffectSequenceHelper::disposeTextRange( aTarget );
InteractiveSequenceList::iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); ++aIter )
{
(*aIter)->disposeTextRange( aTarget );
}
@@ -3590,7 +3549,7 @@ void MainSequence::onTextChanged( const Reference< XShape >& xShape )
EffectSequenceHelper::onTextChanged( xShape );
InteractiveSequenceList::iterator aIter;
- for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); aIter++ )
+ for( aIter = maInteractiveSequenceList.begin(); aIter != maInteractiveSequenceList.end(); ++aIter )
{
(*aIter)->onTextChanged( xShape );
}
@@ -3603,7 +3562,7 @@ void EffectSequenceHelper::onTextChanged( const Reference< XShape >& xShape )
bool bChanges = false;
EffectSequence::iterator aIter;
- for( aIter = maEffects.begin(); aIter != maEffects.end(); aIter++ )
+ for( aIter = maEffects.begin(); aIter != maEffects.end(); ++aIter )
{
if( (*aIter)->getTargetShape() == xShape )
bChanges |= (*aIter)->checkForText();
@@ -3798,7 +3757,7 @@ InteractiveSequence::InteractiveSequence( const Reference< XTimeContainer >& xSe
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::InteractiveSequence::InteractiveSequence(), exception cought!" );
+ OSL_FAIL( "sd::InteractiveSequence::InteractiveSequence(), exception cought!" );
return;
}
}
@@ -3832,3 +3791,5 @@ MainSequenceRebuildGuard::~MainSequenceRebuildGuard()
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/CustomAnimationPreset.cxx b/sd/source/core/CustomAnimationPreset.cxx
index 0fed13b42..7763c518c 100755..100644
--- a/sd/source/core/CustomAnimationPreset.cxx
+++ b/sd/source/core/CustomAnimationPreset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,13 +48,12 @@
#include <tools/debug.hxx>
#include <rtl/uri.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <unotools/ucbstreamhelper.hxx>
#include <CustomAnimationPreset.hxx>
#include <algorithm>
-using namespace ::vos;
using namespace ::com::sun::star;
using namespace ::com::sun::star::animations;
using namespace ::com::sun::star::presentation;
@@ -94,7 +94,7 @@ static Reference< XNameAccess > getNodeAccess( const Reference< XMultiServiceFac
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::getNodeAccess(), Exception catched!" );
+ OSL_FAIL( "sd::getNodeAccess(), Exception catched!" );
}
return xConfigAccess;
@@ -132,12 +132,12 @@ void implImportLabels( const Reference< XMultiServiceFactory >& xConfigProvider,
catch( lang::WrappedTargetException& e )
{
(void)e;
- DBG_ERROR( "sd::implImportLabels(), WrappedTargetException catched!" );
+ OSL_FAIL( "sd::implImportLabels(), WrappedTargetException catched!" );
}
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::implImportLabels(), Exception catched!" );
+ OSL_FAIL( "sd::implImportLabels(), Exception catched!" );
}
}
@@ -209,7 +209,7 @@ Reference< XAnimationNode > CustomAnimationPreset::create( const rtl::OUString&
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPresets::create(), exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::create(), exception catched!" );
}
Reference< XAnimationNode > xNode;
@@ -275,7 +275,7 @@ Reference< XAnimationNode > implImportEffects( const Reference< XMultiServiceFac
// get parser
Reference< xml::sax::XParser > xParser(
xServiceFactory->createInstance(
- OUString::createFromAscii("com.sun.star.xml.sax.Parser") ),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.sax.Parser")) ),
UNO_QUERY );
DBG_ASSERT( xParser.is(), "Can't create parser" );
@@ -304,22 +304,22 @@ Reference< XAnimationNode > implImportEffects( const Reference< XMultiServiceFac
catch( xml::sax::SAXParseException& r )
{
(void)r;
- DBG_ERROR( "sd::implImportEffects(), SAXParseException catched!" );
+ OSL_FAIL( "sd::implImportEffects(), SAXParseException catched!" );
}
catch( xml::sax::SAXException& r )
{
(void)r;
- DBG_ERROR( "sd::implImportEffects(), SAXException catched!" );
+ OSL_FAIL( "sd::implImportEffects(), SAXException catched!" );
}
catch( io::IOException& r )
{
(void)r;
- DBG_ERROR( "sd::implImportEffects(), IOException catched!" );
+ OSL_FAIL( "sd::implImportEffects(), IOException catched!" );
}
catch( Exception& r )
{
(void)r;
- DBG_ERROR( "sd::importEffects(), Exception catched!" );
+ OSL_FAIL( "sd::importEffects(), Exception catched!" );
}
return xRootNode;
@@ -413,22 +413,22 @@ void CustomAnimationPresets::importEffects()
catch( xml::sax::SAXParseException& r )
{
(void)r;
- DBG_ERROR( "sd::CustomAnimationPresets::importEffects(), SAXParseException catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importEffects(), SAXParseException catched!" );
}
catch( xml::sax::SAXException& r )
{
(void)r;
- DBG_ERROR( "sd::CustomAnimationPresets::importEffects(), SAXException catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importEffects(), SAXException catched!" );
}
catch( io::IOException& r )
{
(void)r;
- DBG_ERROR( "sd::CustomAnimationPresets::importEffects(), IOException catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importEffects(), IOException catched!" );
}
catch( Exception& r )
{
(void)r;
- DBG_ERROR( "sd::CustomAnimationPresets::importEffects(), Exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importEffects(), Exception catched!" );
}
}
@@ -473,12 +473,12 @@ void CustomAnimationPresets::importResources()
catch( lang::WrappedTargetException& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPresets::importResources(), WrappedTargetException catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importResources(), WrappedTargetException catched!" );
}
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPresets::importResources(), Exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importResources(), Exception catched!" );
}
}
@@ -542,7 +542,7 @@ void CustomAnimationPresets::importPresets( const Reference< XMultiServiceFactor
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPresets::importPresets(), Exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPresets::importPresets(), Exception catched!" );
}
#ifdef DEBUG
@@ -550,7 +550,7 @@ void CustomAnimationPresets::importPresets( const Reference< XMultiServiceFactor
{
ByteString aTmp( "sd::CustomAnimationPresets::importPresets(), invalid preset id!\n" );
aTmp += ByteString( aMissedPresetIds, RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aTmp.GetBuffer() );
+ OSL_FAIL( aTmp.GetBuffer() );
}
#endif
}
@@ -613,7 +613,7 @@ const CustomAnimationPresets& CustomAnimationPresets::getCustomAnimationPresets(
{
if( !mpCustomAnimationPresets )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( !mpCustomAnimationPresets )
{
@@ -670,3 +670,4 @@ Reference< XAnimationNode > CustomAnimationPresets::getRandomPreset( sal_Int16 n
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/EffectMigration.cxx b/sd/source/core/EffectMigration.cxx
index 04ecd4c31..5873719b6 100644
--- a/sd/source/core/EffectMigration.cxx
+++ b/sd/source/core/EffectMigration.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,7 +41,6 @@
#include <EffectMigration.hxx>
#include <anminfo.hxx>
-using namespace ::vos;
using namespace ::sd;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::animations;
@@ -386,29 +386,9 @@ deprecated_AnimationEffect_conversion_table[] =
{ AnimationEffect_DISSOLVE, "ooo-entrance-fade-in-and-zoom", 0 },
{ AnimationEffect_DISSOLVE, "ooo-entrance-fade-in-and-swivel", 0 },
-// open
-/*
- { AnimationEffect_ZOOM_IN_FROM_LEFT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_UPPERLEFT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_TOP, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_UPPERRIGHT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_RIGHT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_LOWERRIGHT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_BOTTOM, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_LOWERLEFT, "ooo-entrance-zoom","in" },
- { AnimationEffect_ZOOM_IN_FROM_CENTER, "ooo-entrance-zoom","in" },
-
- { AnimationEffect_ZOOM_OUT_FROM_LEFT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_UPPERLEFT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_TOP, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_UPPERRIGHT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_RIGHT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_LOWERRIGHT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_BOTTOM, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_LOWERLEFT, "ooo-entrance-appear",0 },
- { AnimationEffect_ZOOM_OUT_FROM_CENTER, "ooo-entrance-appear",0 },
- { AnimationEffect_PATH, "ooo-entrance-spiral-in",0 },
-*/
+ // still open (no matching effect: AnimationEffect_ZOOM_IN_FROM_*,
+ // AnimationEffect_ZOOM_OUT_FROM_*, AnimationEffect_PATH
+
{ AnimationEffect_NONE, 0, 0 }
};
@@ -416,7 +396,7 @@ EffectSequence::iterator ImplFindEffect( MainSequencePtr& pMainSequence, const R
{
EffectSequence::iterator aIter;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( (pEffect->getTargetShape() == rShape) && (pEffect->getTargetSubItem() == nSubItem) )
@@ -447,7 +427,7 @@ void EffectMigration::SetAnimationEffect( SvxShape* pShape, AnimationEffect eEff
if( !ConvertAnimationEffect( eEffect, aPresetId, aPresetSubType ) )
{
- DBG_ERROR( "sd::EffectMigration::SetAnimationEffect(), no mapping for given AnimationEffect value" );
+ OSL_FAIL( "sd::EffectMigration::SetAnimationEffect(), no mapping for given AnimationEffect value" );
return;
}
@@ -567,7 +547,7 @@ AnimationEffect EffectMigration::GetAnimationEffect( SvxShape* pShape )
EffectSequence::iterator aIter;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -615,7 +595,7 @@ void EffectMigration::SetTextAnimationEffect( SvxShape* pShape, AnimationEffect
if( !ConvertAnimationEffect( eEffect, aPresetId, aPresetSubType ) )
{
- DBG_ERROR( "sd::EffectMigration::SetAnimationEffect(), no mapping for given AnimationEffect value" );
+ OSL_FAIL( "sd::EffectMigration::SetAnimationEffect(), no mapping for given AnimationEffect value" );
return;
}
@@ -707,7 +687,7 @@ void EffectMigration::SetTextAnimationEffect( SvxShape* pShape, AnimationEffect
const EffectSequence& rEffects = pGroup->getEffects();
EffectSequence::const_iterator aIter;
- for( aIter = rEffects.begin(); aIter != rEffects.end(); aIter++ )
+ for( aIter = rEffects.begin(); aIter != rEffects.end(); ++aIter )
{
// only work on paragraph targets
if( (*aIter)->getTarget().getValueType() == ::getCppuType((const ParagraphTarget*)0) )
@@ -828,7 +808,6 @@ double EffectMigration::ConvertAnimationSpeed( AnimationSpeed eSpeed )
{
case AnimationSpeed_SLOW: fDuration = 2.0; break;
case AnimationSpeed_FAST: fDuration = 0.5; break;
- //case AnimationSpeed_MEDIUM:
default:
fDuration = 1.0; break;
}
@@ -856,7 +835,7 @@ void EffectMigration::SetAnimationSpeed( SvxShape* pShape, AnimationSpeed eSpeed
EffectSequence::iterator aIter;
bool bNeedRebuild = false;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -884,7 +863,7 @@ AnimationSpeed EffectMigration::GetAnimationSpeed( SvxShape* pShape )
double fDuration = 1.0;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -936,7 +915,7 @@ void EffectMigration::SetDimColor( SvxShape* pShape, sal_Int32 nColor )
EffectSequence::iterator aIter;
bool bNeedRebuild = false;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -967,7 +946,7 @@ sal_Int32 EffectMigration::GetDimColor( SvxShape* pShape )
const Reference< XShape > xShape( pShape );
EffectSequence::iterator aIter;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( (pEffect->getTargetShape() == xShape) &&
@@ -998,8 +977,6 @@ void EffectMigration::SetDimHide( SvxShape* pShape, sal_Bool bDimHide )
if( implIsInsideGroup( pObj ) )
return;
- Any aEmpty;
-
sd::MainSequencePtr pMainSequence = static_cast<SdPage*>(pObj->GetPage())->getMainSequence();
const Reference< XShape > xShape( pShape );
@@ -1007,14 +984,16 @@ void EffectMigration::SetDimHide( SvxShape* pShape, sal_Bool bDimHide )
EffectSequence::iterator aIter;
bool bNeedRebuild = false;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
{
pEffect->setHasAfterEffect( bDimHide ? true : false );
- if( bDimHide )
+ if( bDimHide ) {
+ Any aEmpty;
pEffect->setDimColor( aEmpty );
+ }
pEffect->setAfterEffectOnNext( false );
bNeedRebuild = true;
}
@@ -1039,7 +1018,7 @@ sal_Bool EffectMigration::GetDimHide( SvxShape* pShape )
const Reference< XShape > xShape( pShape );
EffectSequence::iterator aIter;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -1081,7 +1060,7 @@ void EffectMigration::SetDimPrevious( SvxShape* pShape, sal_Bool bDimPrevious )
EffectSequence::iterator aIter;
bool bNeedRebuild = false;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -1113,7 +1092,7 @@ sal_Bool EffectMigration::GetDimPrevious( SvxShape* pShape )
const Reference< XShape > xShape( pShape );
EffectSequence::iterator aIter;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -1152,7 +1131,7 @@ void EffectMigration::SetPresentationOrder( SvxShape* pShape, sal_Int32 nNewPos
EffectSequence::iterator aIter( rSequence.begin() );
EffectSequence::iterator aEnd( rSequence.end() );
- for( nPos = 0; aIter != aEnd; aIter++ )
+ for( nPos = 0; aIter != aEnd; ++aIter )
{
CustomAnimationEffectPtr pEffect = (*aIter);
@@ -1180,7 +1159,7 @@ void EffectMigration::SetPresentationOrder( SvxShape* pShape, sal_Int32 nNewPos
// check if there is at least one effect for xThis
if( nCurrentPos == -1 )
{
- DBG_ERROR("sd::EffectMigration::SetPresentationOrder() failed cause this shape has no effect" );
+ OSL_FAIL("sd::EffectMigration::SetPresentationOrder() failed cause this shape has no effect" );
return;
}
@@ -1241,7 +1220,7 @@ sal_Int32 EffectMigration::GetPresentationOrder( SvxShape* pShape )
EffectSequence::iterator aIter( rSequence.begin() );
EffectSequence::iterator aEnd( rSequence.end() );
- for( ; aIter != aEnd; aIter++ )
+ for( ; aIter != aEnd; ++aIter )
{
CustomAnimationEffectPtr pEffect = (*aIter);
@@ -1280,7 +1259,7 @@ void EffectMigration::UpdateSoundEffect( SvxShape* pShape, SdAnimationInfo* pInf
if( pInfo->mbSoundOn )
aSoundFile = pInfo->maSoundFile;
- for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); aIter++ )
+ for( aIter = pMainSequence->getBegin(); aIter != pMainSequence->getEnd(); ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -1321,7 +1300,7 @@ OUString EffectMigration::GetSoundFile( SvxShape* pShape )
for( aIter = pMainSequence->getBegin();
(aSoundFile.getLength() == 0) && (aIter != pMainSequence->getEnd());
- aIter++ )
+ ++aIter )
{
CustomAnimationEffectPtr pEffect( (*aIter) );
if( pEffect->getTargetShape() == xShape )
@@ -1342,3 +1321,4 @@ sal_Bool EffectMigration::GetSoundOn( SvxShape* pShape )
return GetSoundFile( pShape ).getLength() != 0;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/PageListWatcher.cxx b/sd/source/core/PageListWatcher.cxx
index b31dce70d..83357e838 100644
--- a/sd/source/core/PageListWatcher.cxx
+++ b/sd/source/core/PageListWatcher.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,7 +36,6 @@
#include <svx/svdmodel.hxx>
//////////////////////////////////////////////////////////////////////////////
-// #109538#
void ImpPageListWatcher::ImpRecreateSortedPageListOnDemand()
{
@@ -127,9 +127,7 @@ SdPage* ImpPageListWatcher::GetSdPage(PageKind ePgKind, sal_uInt32 nPgNum)
}
case PK_HANDOUT:
{
-// #11420# for models used to transfer drawing shapes via clipboard its
-// ok to not have a handout page
-// DBG_ASSERT(mpHandoutPage, "ImpPageListWatcher::GetSdPage: access to non existing handout page (!)");
+// #11420# for models used to transfer drawing shapes via clipboard its ok to not have a handout page
DBG_ASSERT(nPgNum == 0L, "ImpPageListWatcher::GetSdPage: access to non existing handout page (!)");
if (nPgNum == 0)
pRetval = mpHandoutPage;
@@ -221,3 +219,5 @@ ImpMasterPageListWatcher::ImpMasterPageListWatcher(const SdrModel& rModel)
ImpMasterPageListWatcher::~ImpMasterPageListWatcher()
{
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/PageListWatcher.hxx b/sd/source/core/PageListWatcher.hxx
index a5280477f..b45f8bf47 100644
--- a/sd/source/core/PageListWatcher.hxx
+++ b/sd/source/core/PageListWatcher.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/TransitionPreset.cxx b/sd/source/core/TransitionPreset.cxx
index a0bc4931b..049129ede 100644
--- a/sd/source/core/TransitionPreset.cxx
+++ b/sd/source/core/TransitionPreset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,7 +37,7 @@
#include <com/sun/star/util/XMacroExpander.hpp>
#include <com/sun/star/animations/AnimationNodeType.hpp>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <tools/urlobj.hxx>
#include <unotools/streamwrap.hxx>
#include <comphelper/processfactory.hxx>
@@ -44,18 +45,16 @@
#include <tools/stream.hxx>
#include <rtl/uri.hxx>
+#include <rtl/instance.hxx>
#include <tools/debug.hxx>
-#ifndef _SD_CUSTOMANIMATIONPRESET_HXX
#include <TransitionPreset.hxx>
-#endif
#include <unotools/ucbstreamhelper.hxx>
#include <algorithm>
#include "sdpage.hxx"
-using namespace ::vos;
using namespace ::com::sun::star;
using namespace ::com::sun::star::animations;
@@ -84,7 +83,7 @@ TransitionPreset::TransitionPreset( const ::com::sun::star::uno::Reference< ::co
const NamedValue* p = aUserData.getConstArray();
while( nLength-- )
{
- if( p->Name.equalsAscii( "preset-id" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-id" ) ) )
{
p->Value >>= maPresetId;
break;
@@ -137,7 +136,7 @@ bool TransitionPreset::importTransitionsFile( TransitionPresetList& rList,
}
else
{
- DBG_ERROR( "sd::TransitionPreset::importTransitionPresetList(), missformed xml configuration file, giving up!" );
+ OSL_FAIL( "sd::TransitionPreset::importTransitionPresetList(), misformed xml configuration file, giving up!" );
break;
}
}
@@ -221,27 +220,40 @@ bool TransitionPreset::importTransitionPresetList( TransitionPresetList& rList )
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::TransitionPreset::importResources(), Exception cought!" );
+ OSL_FAIL( "sd::TransitionPreset::importResources(), Exception cought!" );
}
return bRet;
}
-TransitionPresetList* TransitionPreset::mpTransitionPresetList = 0;
-
-const TransitionPresetList& TransitionPreset::getTransitionPresetList()
+namespace
{
- if( !mpTransitionPresetList )
+ class ImportedTransitionPresetList
{
- OGuard aGuard( Application::GetSolarMutex() );
- if( !mpTransitionPresetList )
+ private:
+ sd::TransitionPresetList m_aTransitionPresetList;
+ public:
+ ImportedTransitionPresetList()
{
- mpTransitionPresetList = new sd::TransitionPresetList();
- sd::TransitionPreset::importTransitionPresetList( *mpTransitionPresetList );
+ sd::TransitionPreset::importTransitionPresetList(
+ m_aTransitionPresetList);
}
- }
+ const sd::TransitionPresetList& getList() const
+ {
+ return m_aTransitionPresetList;
+ }
+ };
- return *mpTransitionPresetList;
+ class theTransitionPresetList :
+ public rtl::Static<ImportedTransitionPresetList,
+ theTransitionPresetList>
+ {
+ };
+}
+
+const TransitionPresetList& TransitionPreset::getTransitionPresetList()
+{
+ return theTransitionPresetList::get().getList();
}
void TransitionPreset::apply( SdPage* pSlide ) const
@@ -256,3 +268,5 @@ void TransitionPreset::apply( SdPage* pSlide ) const
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/anminfo.cxx b/sd/source/core/anminfo.cxx
index 4ae58fb26..27e198c64 100755..100644
--- a/sd/source/core/anminfo.cxx
+++ b/sd/source/core/anminfo.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,7 +41,6 @@
#include "sdiocmpt.hxx"
#include "drawdoc.hxx"
-// #90477#
#include <tools/tenccvt.hxx>
using namespace ::com::sun::star;
@@ -93,7 +93,6 @@ SdAnimationInfo::SdAnimationInfo(const SdAnimationInfo& rAnmInfo, SdrObject& rOb
maSecondSoundFile (rAnmInfo.maSecondSoundFile),
mbSecondSoundOn (rAnmInfo.mbSecondSoundOn),
mbSecondPlayFull (rAnmInfo.mbSecondPlayFull),
-// maBookmark (rAnmInfo.maBookmark),
mnVerb (rAnmInfo.mnVerb),
mnPresOrder (LIST_APPEND),
mrObject (rObject)
@@ -150,3 +149,5 @@ String SdAnimationInfo::GetBookmark()
return sBookmark;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/annotations/Annotation.cxx b/sd/source/core/annotations/Annotation.cxx
index e61ead7f8..8952254f6 100644
--- a/sd/source/core/annotations/Annotation.cxx
+++ b/sd/source/core/annotations/Annotation.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -375,7 +376,7 @@ UndoInsertOrRemoveAnnotation::UndoInsertOrRemoveAnnotation( Annotation& rAnnotat
Reference< XAnnotation > xAnnotation( &rAnnotation );
const AnnotationVector& rVec = pPage->getAnnotations();
- for( AnnotationVector::const_iterator iter = rVec.begin(); iter != rVec.end(); iter++ )
+ for( AnnotationVector::const_iterator iter = rVec.begin(); iter != rVec.end(); ++iter )
{
if( (*iter) == xAnnotation )
break;
@@ -443,3 +444,4 @@ void UndoAnnotation::Redo()
} // namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/annotations/AnnotationAccess.cxx b/sd/source/core/annotations/AnnotationAccess.cxx
index ffcca9796..c87328977 100644
--- a/sd/source/core/annotations/AnnotationAccess.cxx
+++ b/sd/source/core/annotations/AnnotationAccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#include "sal/config.h"
#include "com/sun/star/uno/XComponentContext.hpp"
#include "cppuhelper/implbase1.hxx"
@@ -57,3 +58,4 @@ css::uno::Reference< css::office::XAnnotationEnumeration > SAL_CALL AnnotationAc
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/annotations/AnnotationEnumeration.cxx b/sd/source/core/annotations/AnnotationEnumeration.cxx
index 605c65a47..db23fbf70 100644
--- a/sd/source/core/annotations/AnnotationEnumeration.cxx
+++ b/sd/source/core/annotations/AnnotationEnumeration.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,4 @@ css::uno::Reference< css::office::XAnnotation > SAL_CALL AnnotationEnumeration::
} // namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/annotations/makefile.mk b/sd/source/core/annotations/makefile.mk
deleted file mode 100644
index 7f5258a5e..000000000
--- a/sd/source/core/annotations/makefile.mk
+++ /dev/null
@@ -1,49 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=annotations
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/Annotation.obj \
- $(SLO)$/AnnotationEnumeration.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/core/cusshow.cxx b/sd/source/core/cusshow.cxx
index 79bda9e5b..ad7d2b3a2 100755..100644
--- a/sd/source/core/cusshow.cxx
+++ b/sd/source/core/cusshow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,7 +37,6 @@
#include "sdpage.hxx"
#include "drawdoc.hxx"
-// #90477#
#include <tools/tenccvt.hxx>
using namespace ::com::sun::star;
@@ -134,3 +134,4 @@ String SdCustomShow::GetName() const
return aName;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/drawdoc.cxx b/sd/source/core/drawdoc.cxx
index a7e05ec65..d49e4d127 100755..100644
--- a/sd/source/core/drawdoc.cxx
+++ b/sd/source/core/drawdoc.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,9 +70,7 @@
#include <i18npool/mslangid.hxx>
#include <unotools/charclass.hxx>
#include <comphelper/processfactory.hxx>
-#ifndef _SVTOOLS_PATHOPTIONS_HXX_
#include <unotools/pathoptions.hxx>
-#endif
#include <unotools/lingucfg.hxx>
#include <unotools/linguprops.hxx>
@@ -93,7 +92,6 @@
#include "../ui/inc/optsitem.hxx"
#include "../ui/inc/FrameView.hxx"
-// #90477#
#include <tools/tenccvt.hxx>
using ::rtl::OUString;
@@ -158,7 +156,6 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
, mpOnlineSpellingTimer(NULL)
, mpOnlineSpellingList(NULL)
, mpOnlineSearchItem(NULL)
-, mpFrameViewList( new List() )
, mpCustomShowList(NULL)
, mpDocSh(static_cast< ::sd::DrawDocShell*>(pDrDocSh))
, mpCreatingTransferable( NULL )
@@ -177,7 +174,6 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
, mpDrawPageListWatcher(0)
, mpMasterPageListWatcher(0)
{
- // #109538#
mpDrawPageListWatcher = ::std::auto_ptr<ImpDrawPageListWatcher>(
new ImpDrawPageListWatcher(*this));
mpMasterPageListWatcher = ::std::auto_ptr<ImpMasterPageListWatcher>(
@@ -195,7 +191,7 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
SdOptions* pOptions = SD_MOD()->GetSdOptions(meDocType);
pOptions->GetScale( nX, nY );
- // #92067# Allow UI scale only for draw documents.
+ // Allow UI scale only for draw documents.
if( eType == DOCUMENT_TYPE_DRAW )
SetUIUnit( (FieldUnit)pOptions->GetMetric(), Fraction( nX, nY ) ); // user-defined
else
@@ -273,7 +269,7 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
}
catch(...)
{
- DBG_ERROR("Can't get SpellChecker");
+ OSL_FAIL("Can't get SpellChecker");
}
rOutliner.SetDefaultLanguage( Application::GetSettings().GetLanguage() );
@@ -327,7 +323,7 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
}
catch(...)
{
- DBG_ERROR("Can't get SpellChecker");
+ OSL_FAIL("Can't get SpellChecker");
}
pHitTestOutliner->SetDefaultLanguage( Application::GetSettings().GetLanguage() );
@@ -348,7 +344,7 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
*
* Es werden auf Pages und MasterPages folgende Default-Layer angelegt:
*
- * Layer STR_LAYOUT : Standardlayer fr alle Zeichenobjekte
+ * Layer STR_LAYOUT : Standardlayer f�r alle Zeichenobjekte
*
* Layer STR_BCKGRND : Hintergrund der MasterPage
* (auf normalen Pages z.Z. keine Verwendung)
@@ -356,7 +352,7 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
* Layer STR_BCKGRNDOBJ: Objekte auf dem Hintergrund der MasterPage
* (auf normalen Pages z.Z. keine Verwendung)
*
- * Layer STR_CONTROLS : Standardlayer fr Controls
+ * Layer STR_CONTROLS : Standardlayer f�r Controls
*
**************************************************************************/
{
@@ -401,7 +397,6 @@ SdDrawDocument::~SdDrawDocument()
CloseBookmarkDoc();
SetAllocDocSh(sal_False);
- // #116168#
ClearModel(sal_True);
if (pLinkManager)
@@ -416,20 +411,9 @@ SdDrawDocument::~SdDrawDocument()
pLinkManager = NULL;
}
- ::sd::FrameView* pFrameView = NULL;
-
- for (sal_uLong i = 0; i < mpFrameViewList->Count(); i++)
- {
- // Ggf. FrameViews loeschen
- pFrameView =
- static_cast< ::sd::FrameView*>(mpFrameViewList->GetObject(i));
-
- if (pFrameView)
- delete pFrameView;
- }
-
- delete mpFrameViewList;
- mpFrameViewList = NULL;
+ std::vector<sd::FrameView*>::iterator pIter;
+ for ( pIter = maFrameViewList.begin(); pIter != maFrameViewList.end(); ++pIter )
+ delete *pIter;
if (mpCustomShowList)
{
@@ -534,9 +518,9 @@ SdrModel* SdDrawDocument::AllocModel() const
|*
\************************************************************************/
-SdrPage* SdDrawDocument::AllocPage(FASTBOOL bMasterPage)
+SdrPage* SdDrawDocument::AllocPage(bool bMasterPage)
{
- return new SdPage(*this, NULL, (sal_Bool)bMasterPage);
+ return new SdPage(*this, NULL, bMasterPage);
}
/*************************************************************************
@@ -573,7 +557,7 @@ void SdDrawDocument::SetChanged(sal_Bool bFlag)
void SdDrawDocument::NbcSetChanged(sal_Bool bFlag)
{
- // #100237# forward to baseclass
+ // forward to baseclass
FmFormModel::SetChanged(bFlag);
}
@@ -682,7 +666,7 @@ void SdDrawDocument::NewOrLoadCompleted(DocCreationMode eMode)
SdStyleSheetPool* pSPool = (SdStyleSheetPool*) GetStyleSheetPool();
sal_uInt16 nPage, nPageCount;
- // #96323# create missing layout style sheets for broken documents
+ // create missing layout style sheets for broken documents
// that where created with the 5.2
nPageCount = GetMasterSdPageCount( PK_STANDARD );
for (nPage = 0; nPage < nPageCount; nPage++)
@@ -749,21 +733,6 @@ void SdDrawDocument::UpdateAllLinks()
*/
void SdDrawDocument::NewOrLoadCompleted( SdPage* pPage, SdStyleSheetPool* pSPool )
{
-/* cl removed because not needed anymore since binfilter
- SdrObjListIter aShapeIter( *pPage );
- while( aShapeIter.IsMore() )
- {
- OutlinerParaObject* pOPO = aShapeIter.Next()->GetOutlinerParaObject();
- if( pOPO )
- {
- if( pOPO->GetOutlinerMode() == OUTLINERMODE_DONTKNOW )
- pOPO->SetOutlinerMode( OUTLINERMODE_TEXTOBJECT );
-
- pOPO->FinishLoad( pSPool );
- }
- }
-*/
-
const sd::ShapeList& rPresentationShapes( pPage->GetPresentationShapeList() );
if(!rPresentationShapes.isEmpty())
{
@@ -771,9 +740,10 @@ void SdDrawDocument::NewOrLoadCompleted( SdPage* pPage, SdStyleSheetPool* pSPool
String aName = pPage->GetLayoutName();
aName.Erase( aName.SearchAscii( SD_LT_SEPARATOR ));
- List* pOutlineList = pSPool->CreateOutlineSheetList(aName);
- SfxStyleSheet* pTitleSheet = (SfxStyleSheet*)
- pSPool->GetTitleSheet(aName);
+ std::vector<SfxStyleSheetBase*> aOutlineList;
+ pSPool->CreateOutlineSheetList(aName,aOutlineList);
+
+ SfxStyleSheet* pTitleSheet = (SfxStyleSheet*)pSPool->GetTitleSheet(aName);
SdrObject* pObj = rPresentationShapes.getNextShape(0);
@@ -800,14 +770,16 @@ void SdDrawDocument::NewOrLoadCompleted( SdPage* pPage, SdStyleSheetPool* pSPool
if( pOPO && pOPO->GetOutlinerMode() == OUTLINERMODE_DONTKNOW )
pOPO->SetOutlinerMode( OUTLINERMODE_OUTLINEOBJECT );
- for (sal_uInt16 nSheet = 0; nSheet < 10; nSheet++)
+ std::vector<SfxStyleSheetBase*>::iterator iter;
+ for (iter = aOutlineList.begin(); iter != aOutlineList.end(); ++iter)
{
- SfxStyleSheet* pSheet = (SfxStyleSheet*)pOutlineList->GetObject(nSheet);
+ SfxStyleSheet* pSheet = reinterpret_cast<SfxStyleSheet*>(*iter);
+
if (pSheet)
{
pObj->StartListening(*pSheet);
- if( nSheet == 0)
+ if( iter == aOutlineList.begin())
// Textrahmen hoert auf StyleSheet der Ebene1
pObj->NbcSetStyleSheet(pSheet, sal_True);
}
@@ -831,8 +803,6 @@ void SdDrawDocument::NewOrLoadCompleted( SdPage* pPage, SdStyleSheetPool* pSPool
pObj = rPresentationShapes.getNextShape(pObj);
}
-
- delete pOutlineList;
}
}
@@ -988,9 +958,6 @@ SvxNumType SdDrawDocument::GetPageNumType() const
void SdDrawDocument::SetPrinterIndependentLayout (sal_Int32 nMode)
{
- // #108104#
- // DBG_ASSERT (mpDocSh!=NULL, "No available document shell to set ref device at.");
-
switch (nMode)
{
case ::com::sun::star::document::PrinterIndependentLayout::DISABLED:
@@ -998,7 +965,6 @@ void SdDrawDocument::SetPrinterIndependentLayout (sal_Int32 nMode)
// Just store supported modes and inform the doc shell.
mnPrinterIndependentLayout = nMode;
- // #108104#
// Since it is possible that a SdDrawDocument is constructed without a
// SdDrawDocShell the pointer member mpDocSh needs to be tested
// before the call is executed. This is e.-g. used for copy/paste.
@@ -1030,13 +996,11 @@ void SdDrawDocument::SetStartWithPresentation( bool bStartWithPresentation )
mbStartWithPresentation = bStartWithPresentation;
}
-// #109538#
void SdDrawDocument::PageListChanged()
{
mpDrawPageListWatcher->Invalidate();
}
-// #109538#
void SdDrawDocument::MasterPageListChanged()
{
mpMasterPageListWatcher->Invalidate();
@@ -1075,3 +1039,5 @@ sal_uInt16 SdDrawDocument::GetAnnotationAuthorIndex( const rtl::OUString& rAutho
}
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/drawdoc2.cxx b/sd/source/core/drawdoc2.cxx
index ae3742db0..ce052d15d 100755..100644
--- a/sd/source/core/drawdoc2.cxx
+++ b/sd/source/core/drawdoc2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include <vcl/wrkwin.hxx>
#include <sfx2/printer.hxx>
#include <sfx2/app.hxx>
-#ifndef SD_OUTLINE_HXX
#include "Outliner.hxx"
-#endif
#include <editeng/paperinf.hxx>
#include <svx/svdopage.hxx>
#include <svx/svdoole2.hxx>
@@ -210,52 +209,23 @@ sal_uInt16 SdDrawDocument::GetPageByName(const String& rPgName, sal_Bool& rbIsMa
return nPageNum;
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
SdPage* SdDrawDocument::GetSdPage(sal_uInt16 nPgNum, PageKind ePgKind) const
{
- // #109538#
return mpDrawPageListWatcher->GetSdPage(ePgKind, sal_uInt32(nPgNum));
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
sal_uInt16 SdDrawDocument::GetSdPageCount(PageKind ePgKind) const
{
- // #109538#
return (sal_uInt16)mpDrawPageListWatcher->GetSdPageCount(ePgKind);
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
SdPage* SdDrawDocument::GetMasterSdPage(sal_uInt16 nPgNum, PageKind ePgKind)
{
- // #109538#
return mpMasterPageListWatcher->GetSdPage(ePgKind, sal_uInt32(nPgNum));
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
sal_uInt16 SdDrawDocument::GetMasterSdPageCount(PageKind ePgKind) const
{
- // #109538#
return (sal_uInt16)mpMasterPageListWatcher->GetSdPageCount(ePgKind);
}
@@ -568,8 +538,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
/**********************************************************************
* Handzettel-Seite einfuegen
**********************************************************************/
- sal_Bool bMasterPage;
- SdPage* pHandoutPage = dynamic_cast< SdPage* >( AllocPage(bMasterPage=sal_False) );
+ SdPage* pHandoutPage = dynamic_cast< SdPage* >( AllocPage(sal_False) );
SdPage* pRefPage = NULL;
@@ -594,7 +563,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
/**********************************************************************
* MasterPage einfuegen und an der Handzettel-Seite vermerken
**********************************************************************/
- SdPage* pHandoutMPage = (SdPage*) AllocPage(bMasterPage=sal_True);
+ SdPage* pHandoutMPage = (SdPage*) AllocPage(sal_True);
pHandoutMPage->SetSize( pHandoutPage->GetSize() );
pHandoutMPage->SetPageKind(PK_HANDOUT);
pHandoutMPage->SetBorder( pHandoutPage->GetLftBorder(),
@@ -617,7 +586,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
if (nPageCount == 0)
{
- pPage = dynamic_cast< SdPage* >( AllocPage(bMasterPage=sal_False) );
+ pPage = dynamic_cast< SdPage* >( AllocPage(sal_False) );
if( pRefPage )
{
@@ -673,7 +642,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
/**********************************************************************
* MasterPage einfuegen und an der Seite vermerken
**********************************************************************/
- SdPage* pMPage = (SdPage*) AllocPage(bMasterPage=sal_True);
+ SdPage* pMPage = (SdPage*) AllocPage(sal_True);
pMPage->SetSize( pPage->GetSize() );
pMPage->SetBorder( pPage->GetLftBorder(),
pPage->GetUppBorder(),
@@ -687,7 +656,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
/**********************************************************************
* Notizen-Seite einfuegen
**********************************************************************/
- SdPage* pNotesPage = (SdPage*) AllocPage(bMasterPage=sal_False);
+ SdPage* pNotesPage = (SdPage*) AllocPage(sal_False);
if( pRefDocument )
pRefPage = pRefDocument->GetSdPage( 0, PK_NOTES );
@@ -719,7 +688,7 @@ void SdDrawDocument::CreateFirstPages( SdDrawDocument* pRefDocument /* = 0 */ )
/**********************************************************************
* MasterPage einfuegen und an der Notizen-Seite vermerken
**********************************************************************/
- SdPage* pNotesMPage = (SdPage*) AllocPage(bMasterPage=sal_True);
+ SdPage* pNotesMPage = (SdPage*) AllocPage(sal_True);
pNotesMPage->SetSize( pNotesPage->GetSize() );
pNotesMPage->SetPageKind(PK_NOTES);
pNotesMPage->SetBorder( pNotesPage->GetLftBorder(),
@@ -806,7 +775,6 @@ sal_Bool SdDrawDocument::CreateMissingNotesAndHandoutPages()
sal_Bool SdDrawDocument::MovePages(sal_uInt16 nTargetPage)
{
- SdPage* pTargetPage = NULL;
SdPage* pPage = NULL;
sal_uInt16 nPage;
sal_uInt16 nNoOfPages = GetSdPageCount(PK_STANDARD);
@@ -818,14 +786,13 @@ sal_Bool SdDrawDocument::MovePages(sal_uInt16 nTargetPage)
BegUndo(String(SdResId(STR_UNDO_MOVEPAGES)));
// Liste mit selektierten Seiten
- List aPageList;
+ std::vector<SdPage*> aPageList;
for (nPage = 0; nPage < nNoOfPages; nPage++)
{
pPage = GetSdPage(nPage, PK_STANDARD);
+
if (pPage->IsSelected())
- {
- aPageList.Insert(pPage, LIST_APPEND);
- }
+ aPageList.push_back(pPage);
}
// falls noetig, nach vorne hangeln, bis nicht selektierte Seite gefunden
@@ -848,11 +815,10 @@ sal_Bool SdDrawDocument::MovePages(sal_uInt16 nTargetPage)
// vor der ersten Seite einfuegen
if (nPage == (sal_uInt16)-1)
{
- while (aPageList.Count() > 0)
+ std::vector<SdPage*>::reverse_iterator iter;
+ for (iter = aPageList.rbegin(); iter != aPageList.rend(); ++iter)
{
- aPageList.Last();
-
- nPage = ( (SdPage*) aPageList.GetCurObject() )->GetPageNum();
+ nPage = (*iter)->GetPageNum();
if (nPage != 0)
{
SdrPage* pPg = GetPage(nPage);
@@ -865,18 +831,18 @@ sal_Bool SdDrawDocument::MovePages(sal_uInt16 nTargetPage)
MovePage(nPage+1, 2);
bSomethingHappened = sal_True;
}
- aPageList.Remove();
}
}
// hinter <nPage> einfuegen
else
{
- pTargetPage = GetSdPage(nPage, PK_STANDARD);
nTargetPage = nPage;
nTargetPage = 2 * nTargetPage + 1; // PK_STANDARD --> absolut
- while (aPageList.Count() > 0)
+
+ std::vector<SdPage*>::iterator iter;
+ for (iter = aPageList.begin(); iter != aPageList.end(); ++iter)
{
- pPage = (SdPage*)aPageList.GetObject(0);
+ pPage = *iter;
nPage = pPage->GetPageNum();
if (nPage > nTargetPage)
{
@@ -910,7 +876,6 @@ sal_Bool SdDrawDocument::MovePages(sal_uInt16 nTargetPage)
bSomethingHappened = sal_True;
}
}
- aPageList.Remove((sal_uLong)0);
nTargetPage = pPage->GetPageNum();
}
}
@@ -1102,13 +1067,6 @@ SdAnimationInfo* SdDrawDocument::GetShapeUserData(SdrObject& rObject, bool bCrea
return pRet;
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
SdIMapInfo* SdDrawDocument::GetIMapInfo( SdrObject* pObject ) const
{
DBG_ASSERT(pObject, "ohne Objekt keine IMapInfo");
@@ -1129,13 +1087,6 @@ SdIMapInfo* SdDrawDocument::GetIMapInfo( SdrObject* pObject ) const
return pIMapInfo;
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
IMapObject* SdDrawDocument::GetHitIMapObject( SdrObject* pObj,
const Point& rWinPoint,
const ::Window& /* rCmpWnd */ )
@@ -1340,7 +1291,7 @@ void SdDrawDocument::CheckMasterPages()
if( bChanged )
{
- DBG_ERROR( "master pages where in a wrong order" );
+ OSL_FAIL( "master pages where in a wrong order" );
RecalcPageNums( sal_True);
}
}
@@ -1382,7 +1333,6 @@ sal_uInt16 SdDrawDocument::CreatePage (
// Create new standard page and set it up.
pStandardPage = (SdPage*) AllocPage(sal_False);
- // #108658#
// Set the size here since else the presobj autolayout
// will be wrong.
pStandardPage->SetSize( pPreviousStandardPage->GetSize() );
@@ -1427,8 +1377,6 @@ sal_uInt16 SdDrawDocument::CreatePage (
ePageKind,
sStandardPageName,
sNotesPageName,
- eStandardLayout,
- eNotesLayout,
bIsPageBack,
bIsPageObj,
pStandardPage,
@@ -1452,14 +1400,10 @@ sal_uInt16 SdDrawDocument::DuplicatePage (sal_uInt16 nPageNum)
sal_uInt8 aBckgrndObj = rLayerAdmin.GetLayerID(String(SdResId(STR_LAYER_BCKGRNDOBJ)), sal_False);
SetOfByte aVisibleLayers = pActualPage->TRG_GetMasterPageVisibleLayers();
- // Get layout from current page.
- AutoLayout eAutoLayout = pActualPage->GetAutoLayout();
-
return DuplicatePage (
pActualPage, ePageKind,
// No names for the new slides.
String(), String(),
- eAutoLayout, eAutoLayout,
aVisibleLayers.IsSet(aBckgrnd),
aVisibleLayers.IsSet(aBckgrndObj));
}
@@ -1472,8 +1416,6 @@ sal_uInt16 SdDrawDocument::DuplicatePage (
PageKind ePageKind,
const String& sStandardPageName,
const String& sNotesPageName,
- AutoLayout eStandardLayout,
- AutoLayout eNotesLayout,
sal_Bool bIsPageBack,
sal_Bool bIsPageObj,
const sal_Int32 nInsertPosition)
@@ -1507,8 +1449,6 @@ sal_uInt16 SdDrawDocument::DuplicatePage (
ePageKind,
sStandardPageName,
sNotesPageName,
- eStandardLayout,
- eNotesLayout,
bIsPageBack,
bIsPageObj,
pStandardPage,
@@ -1524,8 +1464,6 @@ sal_uInt16 SdDrawDocument::InsertPageSet (
PageKind ePageKind,
const String& sStandardPageName,
const String& sNotesPageName,
- AutoLayout eStandardLayout,
- AutoLayout eNotesLayout,
sal_Bool bIsPageBack,
sal_Bool bIsPageObj,
SdPage* pStandardPage,
@@ -1548,7 +1486,6 @@ sal_uInt16 SdDrawDocument::InsertPageSet (
nNotesPageNum = pPreviousNotesPage->GetPageNum() + 2;
pPreviousStandardPage = (SdPage*) GetPage(nNotesPageNum - 3);
nStandardPageNum = nNotesPageNum - 1;
- eStandardLayout = pPreviousStandardPage->GetAutoLayout();
}
else
{
@@ -1557,7 +1494,6 @@ sal_uInt16 SdDrawDocument::InsertPageSet (
pPreviousNotesPage = (SdPage*) GetPage(nStandardPageNum - 1);
nNotesPageNum = nStandardPageNum + 1;
aNotesPageName = aStandardPageName;
- eNotesLayout = pPreviousNotesPage->GetAutoLayout();
}
OSL_ASSERT(nNotesPageNum==nStandardPageNum+1);
@@ -1629,3 +1565,5 @@ sd::UndoManager* SdDrawDocument::GetUndoManager() const
}
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/drawdoc3.cxx b/sd/source/core/drawdoc3.cxx
index 0abd0ab48..3065cdc4a 100755..100644
--- a/sd/source/core/drawdoc3.cxx
+++ b/sd/source/core/drawdoc3.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,22 +90,6 @@ using namespace ::com::sun::star;
|* Oeffnet ein Bookmark-Dokument
|*
\************************************************************************/
-/*
-SdStorageListener : public BaseImplHelper1 < lang::XEventListener >
-{
- uno::Reference < embed::XStorage >& xStor;
-public:
- SdStorageListener ( uno::Reference < embed::XStorage >& rStor )
- : xStor( rStor )
- {}
-
- void disposing ( const lang::EventObject& aEvent ) throw ( uno::RuntimeException );
-};
-
-void SdStorageListener::disposing( const lang::EventObject& aEvent ) throw ( uno::RuntimeException )
-{
- xStor = NULL;
-}*/
SdDrawDocument* SdDrawDocument::OpenBookmarkDoc(SfxMedium& rMedium)
{
@@ -293,7 +278,7 @@ void SdDrawDocument::IterateBookmarkPages( SdDrawDocument* pBookmarkDoc, List* p
SdDrawDocument::InsertBookmarkAsPage_PageFunctorBase& rPageIterator )
{
//
- // #96029# Refactored copy'n'pasted layout name collection from InsertBookmarkAsPage
+ // Refactored copy'n'pasted layout name collection from InsertBookmarkAsPage
//
int nPos, nEndPos;
@@ -545,7 +530,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
List* pLayoutsToTransfer = new List;
//
- // #96029# Refactored copy'n'pasted layout name collection into IterateBookmarkPages
+ // Refactored copy'n'pasted layout name collection into IterateBookmarkPages
//
InsertBookmarkAsPage_FindDuplicateLayouts aSearchFunctor( pLayoutsToTransfer, pBookmarkDoc,
pBookmarkList, nBMSdPageCount );
@@ -621,12 +606,12 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
aNameList.Insert(new String(pName), nBMSdPage);
}
- // #95677# Have to check for duplicate names here, too
- // #67905# don't change name if source and dest model are the same!
+ // Have to check for duplicate names here, too
+ // don't change name if source and dest model are the same!
if( pBookmarkDoc != this &&
GetPageByName(pName, bIsMasterPage ) != SDRPAGE_NOTFOUND )
{
- // #95991# delay renaming *after* pages are copied (might destroy source otherwise)
+ // delay renaming *after* pages are copied (might destroy source otherwise)
aRenameSet.insert(nBMSdPage);
}
}
@@ -646,7 +631,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
SdPage* pNotesPage = (SdPage*) GetPage(nActualInsertPos+1);
String* pName = (String*) aNameList.GetObject(nBMSdPage);
- // #95991# delay renaming *after* pages are copied (might destroy source otherwise)
+ // delay renaming *after* pages are copied (might destroy source otherwise)
if( aRenameSet.find(nBMSdPage) != aRenameSet.end() )
{
// Seitenname schon vorhanden -> Defaultname
@@ -709,9 +694,9 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
**************************************************************/
sal_Bool bMustRename = sal_False;
- // #95991# delay renaming *after* pages are copied (might destroy source otherwise)
- // #67905# don't change name if source and dest model are the same!
- // #96029# avoid renaming if replacing the same page
+ // delay renaming *after* pages are copied (might destroy source otherwise)
+ // don't change name if source and dest model are the same!
+ // avoid renaming if replacing the same page
String aPgName(*(String*) pBookmarkList->GetObject(nPos));
sal_Bool bIsMasterPage;
sal_uInt16 nPageSameName = GetPageByName(aPgName, bIsMasterPage);
@@ -780,7 +765,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
{
if( bPreservePageNames )
{
- // #96029# Take old slide names for inserted pages
+ // Take old slide names for inserted pages
SdPage* pPage = (SdPage*) GetPage(nActualInsertPos);
pPage->SetName( pStandardPage->GetRealName() );
}
@@ -805,7 +790,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
{
if( bPreservePageNames )
{
- // #96029# Take old slide names for inserted pages
+ // Take old slide names for inserted pages
SdPage* pNewNotesPage = (SdPage*) GetPage(nActualInsertPos+1);
if( pNewNotesPage )
pNewNotesPage->SetName( pStandardPage->GetRealName() );
@@ -849,7 +834,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
SdPage* pTest = (SdPage*) GetMasterPage(nTest);
String aTest(pTest->GetLayoutName());
- // #96029# nInsertPos > 2 is always true when inserting into non-empty models
+ // nInsertPos > 2 is always true when inserting into non-empty models
if ( nInsertPos > 2 &&
aTest == aMPLayout &&
eKind == pTest->GetPageKind() )
@@ -867,7 +852,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
}
}
- // #96029# nInsertPos > 2 is always true when inserting into non-empty models
+ // nInsertPos > 2 is always true when inserting into non-empty models
if (nInsertPos > 0)
{
sal_uInt16 nSdPageStart = (nInsertPos - 1) / 2;
@@ -977,7 +962,7 @@ sal_Bool SdDrawDocument::InsertBookmarkAsPage(
}
}
- // #91146# Make absolutely sure no double masterpages are there
+ // Make absolutely sure no double masterpages are there
RemoveUnnecessaryMasterPages(NULL, sal_True, sal_True);
if( bUndo )
@@ -1146,8 +1131,6 @@ sal_Bool SdDrawDocument::InsertBookmarkAsObject(
delete pView;
- List* pList = pBookmarkList;
-
if (pExchangeList)
{
// Anzahl Objekte nach dem Einfuegen bestimmen
@@ -1168,8 +1151,6 @@ sal_Bool SdDrawDocument::InsertBookmarkAsObject(
pExchangeList->Next();
}
-
- pList = pExchangeList;
}
}
@@ -1223,7 +1204,7 @@ void SdDrawDocument::DisposeLoadedModels()
|*
\************************************************************************/
-FASTBOOL SdDrawDocument::IsReadOnly() const
+bool SdDrawDocument::IsReadOnly() const
{
return sal_False;
}
@@ -1313,7 +1294,7 @@ SvStream* SdDrawDocument::GetDocumentStream(SdrDocumentStreamInfo& rStreamInfo)
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(rtl::OString("sd::SdDrawDocument::GetDocumentStream(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1487,7 +1468,7 @@ void SdDrawDocument::RemoveUnnecessaryMasterPages(SdPage* pMasterPage, sal_Bool
pUndoMgr->AddUndoAction(pMovStyles);
}
- for( SdStyleSheetVector::iterator iter = aRemove.begin(); iter != aRemove.end(); iter++ )
+ for( SdStyleSheetVector::iterator iter = aRemove.begin(); iter != aRemove.end(); ++iter )
static_cast<SdStyleSheetPool*>( mxStyleSheetPool.get())->Remove((*iter).get());
}
}
@@ -1603,7 +1584,7 @@ void SdDrawDocument::SetMasterPage(sal_uInt16 nSdPageNum,
if( mpDocSh )
mpDocSh->SetWaitCursor( sal_False );
- DBG_ERROR( "SdDrawDocument::SetMasterPage() failed!" );
+ OSL_FAIL( "SdDrawDocument::SetMasterPage() failed!" );
return;
}
@@ -1745,9 +1726,8 @@ void SdDrawDocument::SetMasterPage(sal_uInt16 nSdPageNum,
if (pSourceDoc != this)
{
// Aus dem Source-Dokument austragen
- SdrPage* pTest = NULL;
- pTest = pSourceDoc->RemoveMasterPage(pNotesMaster->GetPageNum());
- pTest = pSourceDoc->RemoveMasterPage(pMaster->GetPageNum());
+ pSourceDoc->RemoveMasterPage(pNotesMaster->GetPageNum());
+ pSourceDoc->RemoveMasterPage(pMaster->GetPageNum());
}
/*********************************************************************
@@ -2052,8 +2032,8 @@ void SdDrawDocument::SetMasterPage(sal_uInt16 nSdPageNum,
void SdDrawDocument::Merge(SdrModel& rSourceModel,
sal_uInt16 nFirstPageNum, sal_uInt16 nLastPageNum,
sal_uInt16 nDestPos,
- FASTBOOL bMergeMasterPages, FASTBOOL bAllMasterPages,
- FASTBOOL bUndo, FASTBOOL bTreadSourceAsConst)
+ bool bMergeMasterPages, bool bAllMasterPages,
+ bool bUndo, bool bTreadSourceAsConst)
{
sal_uInt16 nMasterPageCount = GetMasterPageCount();
SdrModel::Merge( rSourceModel, nFirstPageNum, nLastPageNum, nDestPos, bMergeMasterPages, bAllMasterPages, bUndo, bTreadSourceAsConst );
@@ -2071,3 +2051,5 @@ void SdDrawDocument::Merge(SdrModel& rSourceModel,
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/drawdoc4.cxx b/sd/source/core/drawdoc4.cxx
index eced4ea40..48b138ab8 100755..100644
--- a/sd/source/core/drawdoc4.cxx
+++ b/sd/source/core/drawdoc4.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,9 +73,7 @@
#include <editeng/crsditem.hxx>
#include <editeng/udlnitem.hxx>
#include <editeng/cntritem.hxx>
-#ifndef _SVX_EMPHITEM_HXX
#include <editeng/emphitem.hxx>
-#endif
#include <editeng/fontitem.hxx>
#include <editeng/shdditem.hxx>
#include <svx/xbtmpit.hxx>
@@ -270,9 +269,6 @@ void SdDrawDocument::CreateLayoutTemplates()
aBulletItem.SetSymbol( 0x25CF ); // Punkt
rISet.Put(aBulletItem);
-// SfxUInt16Item aBulletStateItem(EE_PARA_BULLETSTATE, 0); // Bullets nicht sichtbar
-// rISet.Put(aBulletStateItem);
-
// Neues BulletItem
pSSPool->PutNumBulletItem( pSheet, aBulletFont );
@@ -314,7 +310,7 @@ void SdDrawDocument::CreateLayoutTemplates()
pISet->Put(SdrShadowXDistItem(200)); // 3 mm Schattendistanz
pISet->Put(SdrShadowYDistItem(200));
- // ---- Objekt ohne Fllung -------------------------------------------
+ // ---- Objekt ohne F�llung -------------------------------------------
aName = String(SdResId(STR_POOLSHEET_OBJWITHOUTFILL));
pSheet = &(pSSPool->Make(aName, SD_STYLE_FAMILY_GRAPHICS, nMask));
@@ -336,7 +332,7 @@ void SdDrawDocument::CreateLayoutTemplates()
pISet->Put(XLineStyleItem(XLINE_NONE));
pISet->Put(XFillStyleItem(XFILL_NONE));
- // ---- Textk”rper ----------------------------------------------------
+ // ---- Textk�rper ----------------------------------------------------
aName = String(SdResId(STR_POOLSHEET_TEXTBODY));
pSheet = &(pSSPool->Make(aName, SD_STYLE_FAMILY_GRAPHICS, nMask));
@@ -349,7 +345,7 @@ void SdDrawDocument::CreateLayoutTemplates()
pISet->Put(SvxFontHeightItem(564, 100, EE_CHAR_FONTHEIGHT)); // 16 pt
- // ---- Textk”rper mit Blocksatz --------------------------------------
+ // ---- Textk�rper mit Blocksatz --------------------------------------
aName = String(SdResId(STR_POOLSHEET_TEXTBODY_JUSTIFY));
pSheet = &(pSSPool->Make(aName, SD_STYLE_FAMILY_GRAPHICS, nMask));
@@ -377,12 +373,6 @@ void SdDrawDocument::CreateLayoutTemplates()
aLRSpaceItem.SetTxtFirstLineOfst(600); // Erstzeileneinzug 6mm, rechts 0
pISet->Put(aLRSpaceItem);
-/* #i35937#
- // SvxLRSpaceItem hart gesetzt: NumBulletItem anpassen
- SvxNumBulletItem aNumBullet( (const SvxNumBulletItem&) pISet->Get(EE_PARA_NUMBULLET) );
- EditEngine::ImportBulletItem( aNumBullet, 0, NULL, &aLRSpaceItem );
- pISet->Put( aNumBullet );
-*/
// ---- Titel ---------------------------------------------------------
aName = String(SdResId(STR_POOLSHEET_TITLE));
@@ -442,13 +432,6 @@ void SdDrawDocument::CreateLayoutTemplates()
SvxLRSpaceItem aLRSpItem( 200, 200, 0, 0, EE_PARA_LRSPACE);
pISet->Put( aLRSpItem ); // Erstzeileneinzug 0 mm, links und rechts 2 mm
-/* #i35937#
- // SvxLRSpaceItem hart gesetzt: NumBulletItem anpassen
- SvxNumBulletItem aNmBullet( (const SvxNumBulletItem&) pISet->Get(EE_PARA_NUMBULLET) );
- EditEngine::ImportBulletItem( aNmBullet, 0, NULL, &aLRSpItem );
- pISet->Put( aNmBullet );
-*/
-
pISet->Put(SvxULSpaceItem(100, 100, EE_PARA_ULSPACE )); // Absatzrand oben/unten 1 mm
pISet->Put(SvxAdjustItem(SVX_ADJUST_CENTER, EE_PARA_JUST ));
@@ -563,7 +546,7 @@ static void implCreateTableTemplate( const Reference< XNameContainer >& xTableFa
}
catch( Exception& )
{
- DBG_ERROR("sd::implCreateTableTemplate(), exception caught!");
+ OSL_FAIL("sd::implCreateTableTemplate(), exception caught!");
}
}
@@ -585,7 +568,6 @@ void SdDrawDocument::CreateDefaultCellStyles()
pSheet = &(pSSPool->Make(aDefaultCellStyleName, SD_STYLE_FAMILY_CELL, nMask));
pSheet->SetHelpId( aHelpFile, HID_SD_CELL_STYLE_DEFAULT );
SfxItemSet& rISet = pSheet->GetItemSet();
-// SfxItemPool* pPool = rISet.GetPool();
String aNullStr;
@@ -621,21 +603,6 @@ void SdDrawDocument::CreateDefaultCellStyles()
rISet.Put( SvxFontHeightItem( 635, 100, EE_CHAR_FONTHEIGHT_CJK ) ); // 18 pt
rISet.Put( SvxFontHeightItem( convertFontHeightToCTL( 635 ), 100, EE_CHAR_FONTHEIGHT_CTL ) ); // 18 pt
-// rISet.Put( SvxWeightItem( WEIGHT_NORMAL, EE_CHAR_WEIGHT ) );
-// rISet.Put( SvxWeightItem( WEIGHT_NORMAL, EE_CHAR_WEIGHT_CJK ) );
-// rISet.Put( SvxWeightItem( WEIGHT_NORMAL, EE_CHAR_WEIGHT_CTL ) );
-
-// rISet.Put( SvxPostureItem( ITALIC_NONE, EE_CHAR_ITALIC ) );
-// rISet.Put( SvxPostureItem( ITALIC_NONE, EE_CHAR_ITALIC_CJK ) );
-// rISet.Put( SvxPostureItem( ITALIC_NONE, EE_CHAR_ITALIC_CTL ) );
-
-// rISet.Put(SvxContourItem(sal_False, EE_CHAR_OUTLINE ));
-// rISet.Put(SvxShadowedItem(sal_False, EE_CHAR_SHADOW ));
-// rISet.Put(SvxUnderlineItem(UNDERLINE_NONE, EE_CHAR_UNDERLINE));
-// rISet.Put(SvxOverlineItem(UNDERLINE_NONE, EE_CHAR_OVERLINE));
-// rISet.Put(SvxCrossedOutItem(STRIKEOUT_NONE, EE_CHAR_STRIKEOUT ));
-// rISet.Put(SvxEmphasisMarkItem(EMPHASISMARK_NONE, EE_CHAR_EMPHASISMARK));
-// rISet.Put(SvxCharReliefItem(RELIEF_NONE, EE_CHAR_RELIEF));
rISet.Put(SvxColorItem(Color(COL_AUTO), EE_CHAR_COLOR ));
// Absatzattribute (Edit Engine)
@@ -653,7 +620,7 @@ void SdDrawDocument::CreateDefaultCellStyles()
rISet.Put( SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_LEFT) );
Color aWhite( COL_WHITE );
- SvxBorderLine aBorderLine( &aWhite, 1, 0, 0 );
+ ::editeng::SvxBorderLine aBorderLine( &aWhite, 1, ::editeng::SOLID );
SvxBoxItem aBoxItem( SDRATTR_TABLE_BORDER );
aBoxItem.SetLine( &aBorderLine, BOX_LINE_TOP );
@@ -667,11 +634,11 @@ void SdDrawDocument::CreateDefaultCellStyles()
// ---- default --------------------------------------------------
- Any aBlue1( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue1") ), aDefaultCellStyleName, RGB_COLORDATA(153,204,255)));
- Any aBlue2( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue2") ), aDefaultCellStyleName, RGB_COLORDATA(0,153,255)));
- Any aBlue3( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue3") ), aDefaultCellStyleName, RGB_COLORDATA(0,102,204)));
+ Any aGray1( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray1") ), aDefaultCellStyleName, RGB_COLORDATA(230,230,230)));
+ Any aGray2( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray2") ), aDefaultCellStyleName, RGB_COLORDATA(204,204,204)));
+ Any aGray3( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray3") ), aDefaultCellStyleName, RGB_COLORDATA(179,179,179)));
- implCreateTableTemplate( xTableFamily, OUString(RTL_CONSTASCII_USTRINGPARAM("default")), aBlue1, aBlue3, aBlue2 );
+ implCreateTableTemplate( xTableFamily, OUString(RTL_CONSTASCII_USTRINGPARAM("default") ), aGray1, aGray3, aGray2 );
// ---- BW ------------------------------------------------
@@ -699,11 +666,11 @@ void SdDrawDocument::CreateDefaultCellStyles()
// ---- Gray ------------------------------------------------
- Any aGray1( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray1") ), aDefaultCellStyleName, RGB_COLORDATA(230,230,230)));
- Any aGray2( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray2") ), aDefaultCellStyleName, RGB_COLORDATA(204,204,204)));
- Any aGray3( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("gray3") ), aDefaultCellStyleName, RGB_COLORDATA(179,179,179)));
+ Any aBlue1( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue1") ), aDefaultCellStyleName, RGB_COLORDATA(153,204,255)));
+ Any aBlue2( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue2") ), aDefaultCellStyleName, RGB_COLORDATA(0,153,255)));
+ Any aBlue3( implMakeSolidCellStyle( pSSPool, OUString( RTL_CONSTASCII_USTRINGPARAM("blue3") ), aDefaultCellStyleName, RGB_COLORDATA(0,102,204)));
- implCreateTableTemplate( xTableFamily, OUString(RTL_CONSTASCII_USTRINGPARAM("gray") ), aGray1, aGray3, aGray2 );
+ implCreateTableTemplate( xTableFamily, OUString(RTL_CONSTASCII_USTRINGPARAM("blue")), aBlue1, aBlue3, aBlue2 );
// ---- Sun ------------------------------------------------
@@ -997,18 +964,18 @@ void SdDrawDocument::SpellObject(SdrTextObj* pObj)
{
sd::ModifyGuard aGuard( this );
SdrModel* pModel = pObj->GetModel();
- sal_Bool bLock = sal_False;
+ bool bLock = sal_False;
if ( pModel )
{
bLock = pModel->isLocked();
- pModel->setLock( sal_True );
+ pModel->setLock(true);
}
// taking text from the outliner
((SdrTextObj*) pObj)->SetOutlinerParaObject( pOutl->CreateParaObject() );
pObj->BroadcastObjectChange();
if ( pModel )
- pModel->setLock( bLock );
+ pModel->setLock(bLock);
}
}
@@ -1072,7 +1039,7 @@ IMPL_LINK(SdDrawDocument, OnlineSpellEventHdl, EditStatus*, pEditStat)
|*
\************************************************************************/
-// #91457# removed link and replaced with Imp method
+// removed link and replaced with Imp method
void SdDrawDocument::ImpOnlineSpellCallback(SpellCallbackInfo* pInfo, SdrObject* pObj, SdrOutliner* pOutl)
{
delete mpOnlineSearchItem;
@@ -1081,7 +1048,7 @@ void SdDrawDocument::ImpOnlineSpellCallback(SpellCallbackInfo* pInfo, SdrObject*
sal_uInt16 nCommand = pInfo->nCommand;
if (nCommand == SPELLCMD_IGNOREWORD
- // #91457# restart when add to dictionary takes place, too.
+ // restart when add to dictionary takes place, too.
|| nCommand == SPELLCMD_ADDTODICTIONARY)
{
if(pObj && pOutl && pObj->ISA(SdrTextObj))
@@ -1199,7 +1166,7 @@ void SdDrawDocument::RenameLayoutTemplate(const String& rOldLayoutName, const St
aOldName.Erase(nPos + sizeof(SD_LT_SEPARATOR) - 1 );
sal_uInt16 nLen = aOldName.Len();
- List aReplList;
+ std::vector<StyleReplaceData> aReplList;
SfxStyleSheetIterator aIter(mxStyleSheetPool.get(), SD_STYLE_FAMILY_MASTERPAGE);
SfxStyleSheetBase* pSheet = aIter.First();
@@ -1213,12 +1180,12 @@ void SdDrawDocument::RenameLayoutTemplate(const String& rOldLayoutName, const St
aSheetName.Erase(0, nLen - sizeof(SD_LT_SEPARATOR) + 1 );
aSheetName.Insert(rNewName, 0);
- StyleReplaceData* pReplData = new StyleReplaceData;
- pReplData->nFamily = pSheet->GetFamily();
- pReplData->nNewFamily = pSheet->GetFamily();
- pReplData->aName = pSheet->GetName();
- pReplData->aNewName = aSheetName;
- aReplList.Insert(pReplData, LIST_APPEND);
+ StyleReplaceData aReplData;
+ aReplData.nFamily = pSheet->GetFamily();
+ aReplData.nNewFamily = pSheet->GetFamily();
+ aReplData.aName = pSheet->GetName();
+ aReplData.aNewName = aSheetName;
+ aReplList.push_back(aReplData);
pSheet->SetName(aSheetName);
}
@@ -1260,13 +1227,9 @@ void SdDrawDocument::RenameLayoutTemplate(const String& rOldLayoutName, const St
if (pOPO)
{
- StyleReplaceData* pReplData = (StyleReplaceData*) aReplList.First();
-
- while( pReplData )
- {
- pOPO->ChangeStyleSheets( pReplData->aName, pReplData->nFamily, pReplData->aNewName, pReplData->nNewFamily );
- pReplData = (StyleReplaceData*) aReplList.Next();
- }
+ std::vector<StyleReplaceData>::iterator it;
+ for (it = aReplList.begin(); it != aReplList.end(); ++it)
+ pOPO->ChangeStyleSheets( it->aName, it->nFamily, it->aNewName, it->nNewFamily );
}
}
break;
@@ -1308,13 +1271,9 @@ void SdDrawDocument::RenameLayoutTemplate(const String& rOldLayoutName, const St
if (pOPO)
{
- StyleReplaceData* pReplData = (StyleReplaceData*) aReplList.First();
-
- while( pReplData )
- {
- pOPO->ChangeStyleSheets( pReplData->aName, pReplData->nFamily, pReplData->aNewName, pReplData->nNewFamily );
- pReplData = (StyleReplaceData*) aReplList.Next();
- }
+ std::vector<StyleReplaceData>::iterator it;
+ for (it = aReplList.begin(); it != aReplList.end(); ++it)
+ pOPO->ChangeStyleSheets( it->aName, it->nFamily, it->aNewName, it->nNewFamily );
}
}
break;
@@ -1346,10 +1305,6 @@ void SdDrawDocument::SetTextDefaults() const
aBulletItem.SetSymbol( 0x25CF ); // Punkt
pItemPool->SetPoolDefaultItem( aBulletItem );
- // Bullets nicht sichtbar
-// SfxUInt16Item aBulletStateItem(EE_PARA_BULLETSTATE, 0);
-// pItemPool->SetPoolDefaultItem( aBulletStateItem );
-
// Neues BulletItem
SvxNumberFormat aNumberFormat(SVX_NUM_CHAR_SPECIAL);
aNumberFormat.SetBulletFont(&aBulletFont);
@@ -1379,12 +1334,6 @@ void SdDrawDocument::SetTextDefaults() const
pItemPool->SetPoolDefaultItem( aNumBulletItem );
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
::com::sun::star::text::WritingMode SdDrawDocument::GetDefaultWritingMode() const
{
const SfxPoolItem* pItem = ( pItemPool ? pItemPool->GetPoolDefaultItem( EE_PARA_WRITINGDIR ) : NULL );
@@ -1399,7 +1348,7 @@ void SdDrawDocument::SetTextDefaults() const
case( FRMDIR_VERT_TOP_RIGHT ): eRet = ::com::sun::star::text::WritingMode_TB_RL; break;
default:
- DBG_ERROR( "Frame direction not supported yet" );
+ OSL_FAIL( "Frame direction not supported yet" );
break;
}
}
@@ -1418,7 +1367,7 @@ void SdDrawDocument::SetDefaultWritingMode(::com::sun::star::text::WritingMode e
case ::com::sun::star::text::WritingMode_RL_TB: nVal = FRMDIR_HORI_RIGHT_TOP; break;
case ::com::sun::star::text::WritingMode_TB_RL: nVal = FRMDIR_VERT_TOP_RIGHT; break;
default:
- DBG_ERROR( "Frame direction not supported yet" );
+ OSL_FAIL( "Frame direction not supported yet" );
return;
}
@@ -1440,7 +1389,7 @@ void SdDrawDocument::getDefaultFonts( Font& rLatinFont, Font& rCJKFont, Font& rC
{
LanguageType eLatin = GetLanguage( EE_CHAR_LANGUAGE );
- // #108374# / #107782#: If the UI language is Korean, the default Latin font has to
+ // If the UI language is Korean, the default Latin font has to
// be queried for Korean, too (the Latin language from the document can't be Korean).
// This is the same logic as in SwDocShell::InitNew.
LanguageType eUiLanguage = Application::GetSettings().GetUILanguage();
@@ -1510,3 +1459,5 @@ ModifyGuard::~ModifyGuard()
if( mpDoc && (mpDoc->IsChanged() != mbIsDocumentChanged) )
mpDoc->SetChanged(mbIsDocumentChanged);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/drawdoc_animations.cxx b/sd/source/core/drawdoc_animations.cxx
index 562db6fb1..1c15344ce 100755..100644
--- a/sd/source/core/drawdoc_animations.cxx
+++ b/sd/source/core/drawdoc_animations.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,3 +63,5 @@ const Reference< XPresentation2 >& SdDrawDocument::getPresentation() const
}
return mxPresentation;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/glob.src b/sd/source/core/glob.src
index 24d4f2231..a38af7312 100644
--- a/sd/source/core/glob.src
+++ b/sd/source/core/glob.src
@@ -28,7 +28,6 @@
#define __RSC
-#include "misc.hxx"
#include "glob.hrc"
#include "sderror.hxx"
diff --git a/sd/source/core/makefile.mk b/sd/source/core/makefile.mk
deleted file mode 100644
index 4100edf49..000000000
--- a/sd/source/core/makefile.mk
+++ /dev/null
@@ -1,78 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=core
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-IENV+=-I..\ui\inc
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES = glob.src
-
-SLOFILES = $(SLO)$/stlsheet.obj \
- $(SLO)$/stlfamily.obj \
- $(SLO)$/stlpool.obj \
- $(SLO)$/drawdoc.obj \
- $(SLO)$/drawdoc2.obj \
- $(SLO)$/drawdoc3.obj \
- $(SLO)$/drawdoc4.obj \
- $(SLO)$/drawdoc_animations.obj\
- $(SLO)$/sdpage.obj \
- $(SLO)$/sdpage2.obj \
- $(SLO)$/sdattr.obj \
- $(SLO)$/sdobjfac.obj \
- $(SLO)$/anminfo.obj \
- $(SLO)$/sdiocmpt.obj \
- $(SLO)$/typemap.obj \
- $(SLO)$/pglink.obj \
- $(SLO)$/cusshow.obj \
- $(SLO)$/PageListWatcher.obj \
- $(SLO)$/sdpage_animations.obj\
- $(SLO)$/CustomAnimationPreset.obj\
- $(SLO)$/CustomAnimationEffect.obj\
- $(SLO)$/TransitionPreset.obj\
- $(SLO)$/undoanim.obj\
- $(SLO)$/EffectMigration.obj\
- $(SLO)$/CustomAnimationCloner.obj\
- $(SLO)$/shapelist.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/core/pglink.cxx b/sd/source/core/pglink.cxx
index f972bf1ae..d02f55138 100755..100644
--- a/sd/source/core/pglink.cxx
+++ b/sd/source/core/pglink.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifndef _SVXLINK_HXX
#include <sfx2/linkmgr.hxx>
-#endif
#include "pglink.hxx"
#include "sdpage.hxx"
@@ -70,8 +69,8 @@ SdPageLink::~SdPageLink()
|*
\************************************************************************/
-void SdPageLink::DataChanged( const String& ,
- const ::com::sun::star::uno::Any& )
+::sfx2::SvBaseLink::UpdateResult SdPageLink::DataChanged(
+ const String&, const ::com::sun::star::uno::Any& )
{
SdDrawDocument* pDoc = (SdDrawDocument*) pPage->GetModel();
sfx2::LinkManager* pLinkManager = pDoc!=NULL ? pDoc->GetLinkManager() : NULL;
@@ -126,6 +125,7 @@ void SdPageLink::DataChanged( const String& ,
pDoc->CloseBookmarkDoc();
}
}
+ return SUCCESS;
}
/*************************************************************************
@@ -145,3 +145,4 @@ void SdPageLink::Closed()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdattr.cxx b/sd/source/core/sdattr.cxx
index 5230b9d29..d7d333458 100755..100644
--- a/sd/source/core/sdattr.cxx
+++ b/sd/source/core/sdattr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -152,3 +153,4 @@ int DiaTimeItem::operator==( const SfxPoolItem& rItem ) const
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdiocmpt.cxx b/sd/source/core/sdiocmpt.cxx
index 3de73f0f2..c85898236 100755..100644
--- a/sd/source/core/sdiocmpt.cxx
+++ b/sd/source/core/sdiocmpt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,3 +135,5 @@ SdIOCompat::~SdIOCompat()
}
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdobjfac.cxx b/sd/source/core/sdobjfac.cxx
index 1fc12d255..d761bed5c 100644
--- a/sd/source/core/sdobjfac.cxx
+++ b/sd/source/core/sdobjfac.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,4 @@ IMPL_LINK( SdObjectFactory, MakeUserData, SdrObjFactory *, pObjFactory )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdpage.cxx b/sd/source/core/sdpage.cxx
index f49cfcb70..8af853fb1 100755..100644
--- a/sd/source/core/sdpage.cxx
+++ b/sd/source/core/sdpage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,9 +55,7 @@
#include <svl/smplhint.hxx>
#include <editeng/adjitem.hxx>
#include <editeng/editobj.hxx>
-#ifndef _SVX_SRIPTTYPEITEM_HXX
#include <editeng/scripttypeitem.hxx>
-#endif
#include <svx/unopage.hxx>
#include <editeng/flditem.hxx>
#include <svx/sdr/contact/displayinfo.hxx>
@@ -67,7 +66,6 @@
#include "../ui/inc/DrawDocShell.hxx"
#include "Outliner.hxx"
#include "app.hrc"
-#include "misc.hxx"
#include "eetext.hxx"
#include "drawdoc.hxx"
#include "sdpage.hxx"
@@ -241,7 +239,7 @@ void SdPage::EnsureMasterPageDefaultBackground()
else
{
// no style found, assert and set at least XFILL_NONE
- OSL_ENSURE(false, "No Style for MasterPageBackground fill found (!)");
+ OSL_FAIL("No Style for MasterPageBackground fill found (!)");
getSdrPageProperties().PutItem(XFillStyleItem(XFILL_NONE));
}
}
@@ -365,7 +363,6 @@ SdrObject* SdPage::CreatePresObj(PresObjKind eObjKind, sal_Bool bVertical, const
// #i105146# We want no content to be displayed for PK_HANDOUT,
// so just never set a page as content
pSdrObj = new SdrPageObj(0);
-// pSdrObj->SetResizeProtect(sal_True);
}
break;
@@ -416,7 +413,7 @@ SdrObject* SdPage::CreatePresObj(PresObjKind eObjKind, sal_Bool bVertical, const
if ( pSdrObj->ISA(SdrTextObj) )
{
- // #96243# Tell the object EARLY that it is vertical to have the
+ // Tell the object EARLY that it is vertical to have the
// defaults for AutoGrowWidth/Height reversed
if(bVertical)
((SdrTextObj*)pSdrObj)->SetVerticalWriting(sal_True);
@@ -432,7 +429,7 @@ SdrObject* SdPage::CreatePresObj(PresObjKind eObjKind, sal_Bool bVertical, const
// Bei Praesentationsobjekten auf der MasterPage soll die
// Groesse vom Benutzwer frei waehlbar sein
- // #96243# potential problem: This action was still NOT
+ // potential problem: This action was still NOT
// adapted for vertical text. This sure needs to be done.
if(bVertical)
aTempAttr.Put(SdrTextAutoGrowWidthItem(sal_False));
@@ -515,8 +512,7 @@ SdrObject* SdPage::CreatePresObj(PresObjKind eObjKind, sal_Bool bVertical, const
}
// Objekt am StyleSheet anmelden
- // #95114# Set style only when one was found (as in 5.2)
- // pSdrObj->NbcSetStyleSheet( GetStyleSheetForPresObj(eObjKind), sal_False );
+ // Set style only when one was found (as in 5.2)
if( mePageKind != PK_HANDOUT )
{
SfxStyleSheet* pSheetForPresObj = GetStyleSheetForPresObj(eObjKind);
@@ -673,7 +669,7 @@ SdStyleSheet* SdPage::getPresentationStyle( sal_uInt32 nHelpId ) const
case HID_PSEUDOSHEET_NOTES: nNameId = STR_LAYOUT_NOTES; break;
default:
- DBG_ERROR( "SdPage::getPresentationStyle(), illegal argument!" );
+ OSL_FAIL( "SdPage::getPresentationStyle(), illegal argument!" );
return 0;
}
aStyleName.Append( String( SdResId( nNameId ) ) );
@@ -718,10 +714,7 @@ void SdPage::Changed(const SdrObject& rObj, SdrUserCallType eType, const Rectang
{
::svl::IUndoManager* pUndoManager = pModel ? static_cast<SdDrawDocument*>(pModel)->GetUndoManager() : 0;
const bool bUndo = pUndoManager && pUndoManager->IsInListAction() && IsInserted();
-/*
- DBG_ASSERT( bUndo || (pUndoManager && pUndoManager->IsDoing()),
- "SdPage::Changed(), model change without undo!?" );
-*/
+
if( bUndo )
pUndoManager->AddUndoAction( new UndoObjectUserCall(*pObj) );
@@ -820,7 +813,7 @@ void SdPage::CreateTitleAndLayout(sal_Bool bInit, sal_Bool bCreate )
pPageObj->SetReferencedPage(0L);
if( bSkip && iter != aAreas.end() )
- iter++;
+ ++iter;
}
}
@@ -919,7 +912,7 @@ SdrObject* SdPage::CreateDefaultPresObj(PresObjKind eObjKind, bool bInsert)
}
else
{
- DBG_ERROR( "SdPage::CreateDefaultPresObj() - can't create a header placeholder for a slide master" );
+ OSL_FAIL( "SdPage::CreateDefaultPresObj() - can't create a header placeholder for a slide master" );
return NULL;
}
}
@@ -967,13 +960,13 @@ SdrObject* SdPage::CreateDefaultPresObj(PresObjKind eObjKind, bool bInsert)
return CreatePresObj( PRESOBJ_SLIDENUMBER, sal_False, aRect, bInsert );
}
- DBG_ERROR("SdPage::CreateDefaultPresObj() - this should not happen!");
+ OSL_FAIL("SdPage::CreateDefaultPresObj() - this should not happen!");
return NULL;
}
}
else
{
- DBG_ERROR("SdPage::CreateDefaultPresObj() - unknown PRESOBJ kind" );
+ OSL_FAIL("SdPage::CreateDefaultPresObj() - unknown PRESOBJ kind" );
return NULL;
}
}
@@ -1610,19 +1603,7 @@ void SdPage::SetAutoLayout(AutoLayout eLayout, sal_Bool bInit, sal_Bool bCreate
if( !bUndo )
SdrObject::Free( pObj );
}
-/* #i108541# keep non empty pres obj as pres obj even if they are not part of the current layout
- else
- {
- if( bUndo )
- {
- pUndoManager->AddUndoAction( new UndoObjectPresentationKind( *pObj ) );
- if( pObj->GetUserCall() )
- pUndoManager->AddUndoAction( new UndoObjectUserCall( *pObj ) );
- }
- maPresentationShapeList.removeShape( *pObj );
- pObj->SetUserCall(0);
- }
-*/
+/* #i108541# keep non empty pres obj as pres obj even if they are not part of the current layout */
}
pObj = pNext;
}
@@ -1678,7 +1659,7 @@ SdrObject* SdPage::NbcRemoveObject(sal_uLong nObjNum)
return FmFormPage::NbcRemoveObject(nObjNum);
}
-// #95876# Also overload ReplaceObject methods to realize when
+// Also overload ReplaceObject methods to realize when
// objects are removed with this mechanism instead of RemoveObject
SdrObject* SdPage::NbcReplaceObject(SdrObject* pNewObj, sal_uLong nObjNum)
{
@@ -1686,7 +1667,7 @@ SdrObject* SdPage::NbcReplaceObject(SdrObject* pNewObj, sal_uLong nObjNum)
return FmFormPage::NbcReplaceObject(pNewObj, nObjNum);
}
-// #95876# Also overload ReplaceObject methods to realize when
+// Also overload ReplaceObject methods to realize when
// objects are removed with this mechanism instead of RemoveObject
SdrObject* SdPage::ReplaceObject(SdrObject* pNewObj, sal_uLong nObjNum)
{
@@ -1711,12 +1692,6 @@ void SdPage::onRemoveObject( SdrObject* pObject )
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetSize(const Size& aSize)
{
Size aOldSize = GetSize();
@@ -1741,13 +1716,6 @@ void SdPage::SetSize(const Size& aSize)
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetBorder(sal_Int32 nLft, sal_Int32 nUpp, sal_Int32 nRgt, sal_Int32 nLwr)
{
if (nLft != GetLftBorder() || nUpp != GetUppBorder() ||
@@ -1757,13 +1725,6 @@ void SdPage::SetBorder(sal_Int32 nLft, sal_Int32 nUpp, sal_Int32 nRgt, sal_Int32
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetLftBorder(sal_Int32 nBorder)
{
if (nBorder != GetLftBorder() )
@@ -1772,13 +1733,6 @@ void SdPage::SetLftBorder(sal_Int32 nBorder)
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetRgtBorder(sal_Int32 nBorder)
{
if (nBorder != GetRgtBorder() )
@@ -1787,13 +1741,6 @@ void SdPage::SetRgtBorder(sal_Int32 nBorder)
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetUppBorder(sal_Int32 nBorder)
{
if (nBorder != GetUppBorder() )
@@ -1802,13 +1749,6 @@ void SdPage::SetUppBorder(sal_Int32 nBorder)
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetLwrBorder(sal_Int32 nBorder)
{
if (nBorder != GetLwrBorder() )
@@ -1917,7 +1857,7 @@ void SdPage::ScaleObjects(const Size& rNewPageSize, const Rectangle& rNewBorderR
if (pObj)
{
- // #88084# remember aTopLeft as original TopLeft
+ // remember aTopLeft as original TopLeft
Point aTopLeft(pObj->GetCurrentBoundRect().TopLeft());
if (!pObj->IsEdgeObj())
@@ -1927,7 +1867,7 @@ void SdPage::ScaleObjects(const Size& rNewPageSize, const Rectangle& rNewBorderR
**************************************************************/
if (mbScaleObjects)
{
- // #88084# use aTopLeft as original TopLeft
+ // use aTopLeft as original TopLeft
aRefPnt = aTopLeft;
}
@@ -2070,7 +2010,7 @@ void SdPage::ScaleObjects(const Size& rNewPageSize, const Rectangle& rNewBorderR
else if ( nScriptType == SCRIPTTYPE_COMPLEX )
nWhich = EE_CHAR_FONTHEIGHT_CTL;
- // #88084# use more modern method to scale the text height
+ // use more modern method to scale the text height
sal_uInt32 nFontHeight = ((SvxFontHeightItem&)pObj->GetMergedItem(nWhich)).GetHeight();
sal_uInt32 nNewFontHeight = sal_uInt32((double)nFontHeight * (double)aFractY);
@@ -2086,8 +2026,8 @@ void SdPage::ScaleObjects(const Size& rNewPageSize, const Rectangle& rNewBorderR
**************************************************************/
Point aNewPos;
- // #76447# corrected scaling; only distances may be scaled
- // #88084# use aTopLeft as original TopLeft
+ // corrected scaling; only distances may be scaled
+ // use aTopLeft as original TopLeft
aNewPos.X() = long((aTopLeft.X() - GetLftBorder()) * (double)aFractX) + nLeft;
aNewPos.Y() = long((aTopLeft.Y() - GetUppBorder()) * (double)aFractY) + nUpper;
@@ -2272,10 +2212,7 @@ SdrObject* SdPage::InsertAutoLayoutShape( SdrObject* pObj, PresObjKind eObjKind,
pUndoManager->AddUndoAction( new UndoObjectUserCall( *pObj ) );
}
-// if ( pObj->ISA(SdrGrafObj) && !pObj->IsEmptyPresObj() )
( /*(SdrGrafObj*)*/ pObj)->AdjustToMaxRect( aRect );
-// else
-// SetLogicRect( pObj, aRect );
pObj->SetUserCall(this);
@@ -2286,7 +2223,7 @@ SdrObject* SdPage::InsertAutoLayoutShape( SdrObject* pObj, PresObjKind eObjKind,
{
pTextObject->SetVerticalWriting( bVertical );
- // #94826# here make sure the correct anchoring is used when the object
+ // here make sure the correct anchoring is used when the object
// is re-used but orientation is changed
if(PRESOBJ_OUTLINE == eObjKind)
pTextObject->SetMergedItem(SdrTextHorzAdjustItem( bVertical ? SDRTEXTHORZADJUST_RIGHT : SDRTEXTHORZADJUST_BLOCK ));
@@ -2440,10 +2377,10 @@ void SdPage::SetObjText(SdrTextObj* pObj, SdrOutliner* pOutliner, PresObjKind eO
pOutl->SetUpdateMode(sal_False);
pOutl->SetParaAttribs( 0, pOutl->GetEmptyItemSet() );
- // #95114# Always set the object's StyleSheet at the Outliner to
+ // Always set the object's StyleSheet at the Outliner to
// use the current objects StyleSheet. Thus it's the same as in
// SetText(...).
- // #95114# Moved this implementation from where SetObjText(...) was called
+ // Moved this implementation from where SetObjText(...) was called
// to inside this method to work even when outliner is fetched here.
pOutl->SetStyleSheet(0, pObj->GetStyleSheet());
@@ -2645,23 +2582,11 @@ const String& SdPage::GetName() const
return maCreatedPageName;
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPage::SetOrientation( Orientation eOrient)
{
meOrientation = eOrient;
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
Orientation SdPage::GetOrientation() const
{
return meOrientation;
@@ -2768,7 +2693,7 @@ SdPage* SdPage::getImplementation( const ::com::sun::star::uno::Reference< ::com
catch( ::com::sun::star::uno::Exception& e )
{
(void)e;
- DBG_ERROR("sd::SdPage::getImplementation(), exception cathced!" );
+ OSL_FAIL("sd::SdPage::getImplementation(), exception cathced!" );
}
return 0;
@@ -2920,9 +2845,7 @@ bool SdPage::RestoreDefaultText( SdrObject* pObj )
if( pOldPara )
{
- //pTextObj->SetVerticalWriting( bVertical );
- //
- // #94826# Here, only the vertical flag for the
+ // Here, only the vertical flag for the
// OutlinerParaObjects needs to be changed. The
// AutoGrowWidth/Height items still exist in the
// not changed object.
@@ -3149,3 +3072,4 @@ bool HeaderFooterSettings::operator==( const HeaderFooterSettings& rSettings ) c
(maDateTimeText == rSettings.maDateTimeText);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdpage2.cxx b/sd/source/core/sdpage2.cxx
index f98756c72..a96de5e5c 100755..100644
--- a/sd/source/core/sdpage2.cxx
+++ b/sd/source/core/sdpage2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,19 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
+
+#include <vector>
+#include <boost/ptr_container/ptr_vector.hpp>
+
#include <sfx2/docfile.hxx>
#include <vcl/svapp.hxx>
#include <editeng/outliner.hxx>
-#ifndef _SVXLINK_HXX
#include <sfx2/linkmgr.hxx>
-#endif
#include <svx/svdotext.hxx>
#include <tools/urlobj.hxx>
#include <editeng/outlobj.hxx>
#include <svl/urihelper.hxx>
#include <editeng/xmlcnitm.hxx>
#include <svx/svditer.hxx>
-#include <tools/list.hxx>
#include "sdresid.hxx"
#include "sdpage.hxx"
@@ -47,15 +49,12 @@
#include "glob.hrc"
#include "drawdoc.hxx"
#include "stlpool.hxx"
-//#include "sdiocmpt.hxx"
#include "pglink.hxx"
-//#include "strmname.h"
#include "anminfo.hxx"
#include "../ui/inc/strings.hrc"
#include "../ui/inc/DrawDocShell.hxx"
-// #90477#
#include <tools/tenccvt.hxx>
#include <svl/itemset.hxx>
@@ -68,7 +67,7 @@ extern void NotifyDocumentEvent( SdDrawDocument* pDocument, const rtl::OUString&
/*************************************************************************
|*
-|* SetPresentationLayout, setzt: Layoutnamen, Masterpage-Verknpfung und
+|* SetPresentationLayout, setzt: Layoutnamen, Masterpage-Verkn�pfung und
|* Vorlagen fuer Praesentationsobjekte
|*
|* Vorraussetzungen: - Die Seite muss bereits das richtige Model kennen!
@@ -150,10 +149,10 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
// Listen mit:
// - Vorlagenzeigern fuer Gliederungstextobjekt (alte und neue Vorlagen)
// -Replacedaten fuer OutlinerParaObject
- List aOutlineStyles;
- List aOldOutlineStyles;
- List aReplList;
- sal_Bool bListsFilled = sal_False;
+ std::vector<SfxStyleSheetBase*> aOutlineStyles;
+ std::vector<SfxStyleSheetBase*> aOldOutlineStyles;
+ boost::ptr_vector<StyleReplaceData> aReplList;
+ bool bListsFilled = false;
sal_uLong nObjCount = GetObjCount();
@@ -182,11 +181,11 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
pSheet = pStShPool->Find(aOldFullName, SD_STYLE_FAMILY_MASTERPAGE);
DBG_ASSERT(pSheet, "alte Gliederungsvorlage nicht gefunden");
- aOldOutlineStyles.Insert(pSheet, LIST_APPEND);
+ aOldOutlineStyles.push_back(pSheet);
pSheet = pStShPool->Find(aFullName, SD_STYLE_FAMILY_MASTERPAGE);
DBG_ASSERT(pSheet, "neue Gliederungsvorlage nicht gefunden");
- aOutlineStyles.Insert(pSheet, LIST_APPEND);
+ aOutlineStyles.push_back(pSheet);
if (bReplaceStyleSheets && pSheet)
{
@@ -196,7 +195,7 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
pReplData->nFamily = pSheet->GetFamily();
pReplData->aNewName = aFullName;
pReplData->aName = aOldFullName;
- aReplList.Insert(pReplData, LIST_APPEND);
+ aReplList.push_back(pReplData);
}
else
{
@@ -207,13 +206,20 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
}
}
- bListsFilled = sal_True;
+ bListsFilled = true;
}
- SfxStyleSheet* pSheet = (SfxStyleSheet*)aOutlineStyles.First();
- SfxStyleSheet* pOldSheet = (SfxStyleSheet*)aOldOutlineStyles.First();
- while (pSheet)
+ SfxStyleSheet* pSheet = NULL;
+ SfxStyleSheet* pOldSheet = NULL;
+
+ std::vector<SfxStyleSheetBase*>::iterator iterOut = aOutlineStyles.begin();
+ std::vector<SfxStyleSheetBase*>::iterator iterOldOut = aOldOutlineStyles.begin();
+
+ while (iterOut != aOutlineStyles.end())
{
+ pSheet = reinterpret_cast<SfxStyleSheet*>(*iterOut);
+ pOldSheet = reinterpret_cast<SfxStyleSheet*>(*iterOldOut);
+
if (pSheet != pOldSheet)
{
pObj->EndListening(*pOldSheet);
@@ -222,19 +228,18 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
pObj->StartListening(*pSheet);
}
- pSheet = (SfxStyleSheet*)aOutlineStyles.Next();
- pOldSheet = (SfxStyleSheet*)aOldOutlineStyles.Next();
+ ++iterOut;
+ ++iterOldOut;
}
OutlinerParaObject* pOPO = ((SdrTextObj*)pObj)->GetOutlinerParaObject();
if ( bReplaceStyleSheets && pOPO )
{
- StyleReplaceData* pReplData = (StyleReplaceData*) aReplList.First();
-
- while( pReplData )
+ boost::ptr_vector<StyleReplaceData>::const_iterator it = aReplList.begin();
+ while (it != aReplList.end())
{
- pOPO->ChangeStyleSheets( pReplData->aName, pReplData->nFamily, pReplData->aNewName, pReplData->nNewFamily );
- pReplData = (StyleReplaceData*) aReplList.Next();
+ pOPO->ChangeStyleSheets( it->aName, it->nFamily, it->aNewName, it->nNewFamily );
+ ++it;
}
}
}
@@ -257,11 +262,6 @@ void SdPage::SetPresentationLayout(const String& rLayoutName,
pObj->SetStyleSheet(pSheet, sal_True);
}
}
-
- for (sal_uLong i = 0; i < aReplList.Count(); i++)
- {
- delete (StyleReplaceData*) aReplList.GetObject(i);
- }
}
@@ -282,15 +282,17 @@ void SdPage::EndListenOutlineText()
DBG_ASSERT(pSPool, "StyleSheetPool nicht gefunden");
String aTrueLayoutName(maLayoutName);
aTrueLayoutName.Erase( aTrueLayoutName.SearchAscii( SD_LT_SEPARATOR ));
- List* pOutlineStyles = pSPool->CreateOutlineSheetList(aTrueLayoutName);
- for (SfxStyleSheet* pSheet = (SfxStyleSheet*)pOutlineStyles->First();
- pSheet;
- pSheet = (SfxStyleSheet*)pOutlineStyles->Next())
- {
- pOutlineTextObj->EndListening(*pSheet);
- }
- delete pOutlineStyles;
+ SfxStyleSheet *pSheet = NULL;
+ std::vector<SfxStyleSheetBase*> aOutlineStyles;
+ pSPool->CreateOutlineSheetList(aTrueLayoutName,aOutlineStyles);
+
+ std::vector<SfxStyleSheetBase*>::iterator iter;
+ for (iter = aOutlineStyles.begin(); iter != aOutlineStyles.end(); ++iter)
+ {
+ pSheet = reinterpret_cast<SfxStyleSheet*>(*iter);
+ pOutlineTextObj->EndListening(*pSheet);
+ }
}
}
@@ -316,9 +318,9 @@ void SdPage::SetModel(SdrModel* pNewModel)
|*
\************************************************************************/
-FASTBOOL SdPage::IsReadOnly() const
+bool SdPage::IsReadOnly() const
{
- return sal_False;
+ return false;
}
/*************************************************************************
@@ -646,3 +648,5 @@ void SdPage::removeAnnotation( const Reference< XAnnotation >& xAnnotation )
NotifyDocumentEvent( static_cast< SdDrawDocument* >( pModel ), rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "OnAnnotationRemoved" ) ), xSource );
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/sdpage_animations.cxx b/sd/source/core/sdpage_animations.cxx
index 284fb05fe..305c96696 100644
--- a/sd/source/core/sdpage_animations.cxx
+++ b/sd/source/core/sdpage_animations.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,7 +32,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/presentation/EffectNodeType.hpp>
#include <comphelper/processfactory.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <editeng/outliner.hxx>
#include "CustomAnimationCloner.hxx"
#include "drawdoc.hxx"
@@ -41,7 +42,6 @@
#include "undoanim.hxx"
#include "EffectMigration.hxx"
-using namespace ::vos;
using ::rtl::OUString;
using namespace ::sd;
using namespace ::com::sun::star::uno;
@@ -161,3 +161,4 @@ void SdPage::cloneAnimations( SdPage& rTargetPage ) const
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/shapelist.cxx b/sd/source/core/shapelist.cxx
index 695c30b05..292f6533b 100755..100644
--- a/sd/source/core/shapelist.cxx
+++ b/sd/source/core/shapelist.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,7 +57,7 @@ void ShapeList::addShape( SdrObject& rObject )
}
else
{
- DBG_ERROR("sd::ShapeList::addShape(), given shape already part of list!");
+ OSL_FAIL("sd::ShapeList::addShape(), given shape already part of list!");
}
}
@@ -79,7 +80,7 @@ SdrObject* ShapeList::removeShape( SdrObject& rObject )
}
else
{
- DBG_ERROR("sd::ShapeList::removeShape(), given shape not part of list!");
+ OSL_FAIL("sd::ShapeList::removeShape(), given shape not part of list!");
}
return 0;
}
@@ -146,7 +147,7 @@ void ShapeList::ObjectInDestruction(const SdrObject& rObject)
}
else
{
- DBG_ERROR("sd::ShapeList::ObjectInDestruction(), got a call from an unknown friend!");
+ OSL_FAIL("sd::ShapeList::ObjectInDestruction(), got a call from an unknown friend!");
}
}
@@ -173,3 +174,5 @@ bool ShapeList::hasMore() const
{
return maIter != maShapeList.end();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/stlfamily.cxx b/sd/source/core/stlfamily.cxx
index 6197c6308..d3f92cef4 100644
--- a/sd/source/core/stlfamily.cxx
+++ b/sd/source/core/stlfamily.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,7 +33,7 @@
#include <com/sun/star/lang/IllegalAccessException.hpp>
#include <comphelper/serviceinfohelper.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <svl/style.hxx>
@@ -50,7 +51,6 @@
#include <map>
using ::rtl::OUString;
-using namespace ::vos;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::container;
@@ -83,12 +83,12 @@ PresStyleMap& SdStyleFamilyImpl::getStyleSheets()
const sal_uInt16 nLen = aLayoutName.Search(String( RTL_CONSTASCII_USTRINGPARAM(SD_LT_SEPARATOR)))+4;
aLayoutName.Erase( nLen );
- if( (maStyleSheets.size() == 0) || !((*maStyleSheets.begin()).second->GetName().Equals( aLayoutName, 0, nLen )) )
+ if( (maStyleSheets.empty()) || !((*maStyleSheets.begin()).second->GetName().Equals( aLayoutName, 0, nLen )) )
{
maStyleSheets.clear();
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == SD_STYLE_FAMILY_MASTERPAGE) && (pStyle->GetName().Equals( aLayoutName, 0, nLen )) )
@@ -166,7 +166,7 @@ SdStyleSheet* SdStyleFamily::GetSheetByName( const OUString& rName ) throw(NoSuc
else
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) && (pStyle->GetApiName() == rName) )
@@ -244,7 +244,7 @@ void SAL_CALL SdStyleFamily::setName( const ::rtl::OUString& ) throw (RuntimeExc
Any SAL_CALL SdStyleFamily::getByName( const OUString& rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
return Any( Reference< XStyle >( static_cast<SfxUnoStyleSheet*>(GetSheetByName( rName )) ) );
}
@@ -253,7 +253,7 @@ Any SAL_CALL SdStyleFamily::getByName( const OUString& rName ) throw(NoSuchEleme
Sequence< OUString > SAL_CALL SdStyleFamily::getElementNames() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -279,14 +279,13 @@ Sequence< OUString > SAL_CALL SdStyleFamily::getElementNames() throw(RuntimeExce
}
}
-// *pNames++ = (*iter++).second->GetApiName();
return aNames;
}
else
{
std::vector< OUString > aNames;
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) )
@@ -300,7 +299,7 @@ Sequence< OUString > SAL_CALL SdStyleFamily::getElementNames() throw(RuntimeExce
sal_Bool SAL_CALL SdStyleFamily::hasByName( const OUString& aName ) throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( aName.getLength() )
@@ -314,7 +313,7 @@ sal_Bool SAL_CALL SdStyleFamily::hasByName( const OUString& aName ) throw(Runtim
else
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) && ( pStyle->GetApiName() == aName ) )
@@ -339,7 +338,7 @@ Type SAL_CALL SdStyleFamily::getElementType() throw(RuntimeException)
sal_Bool SAL_CALL SdStyleFamily::hasElements() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( mnFamily == SD_STYLE_FAMILY_MASTERPAGE )
@@ -349,7 +348,7 @@ sal_Bool SAL_CALL SdStyleFamily::hasElements() throw(RuntimeException)
else
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) )
@@ -366,7 +365,7 @@ sal_Bool SAL_CALL SdStyleFamily::hasElements() throw(RuntimeException)
sal_Int32 SAL_CALL SdStyleFamily::getCount() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
sal_Int32 nCount = 0;
@@ -377,7 +376,7 @@ sal_Int32 SAL_CALL SdStyleFamily::getCount() throw(RuntimeException)
else
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) )
@@ -392,7 +391,7 @@ sal_Int32 SAL_CALL SdStyleFamily::getCount() throw(RuntimeException)
Any SAL_CALL SdStyleFamily::getByIndex( sal_Int32 Index ) throw(IndexOutOfBoundsException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( Index >= 0 )
@@ -404,7 +403,7 @@ Any SAL_CALL SdStyleFamily::getByIndex( sal_Int32 Index ) throw(IndexOutOfBounds
{
PresStyleMap::iterator iter( rStyleSheets.begin() );
while( Index-- && (iter != rStyleSheets.end()) )
- iter++;
+ ++iter;
if( (Index==-1) && (iter != rStyleSheets.end()) )
return Any( Reference< XStyle >( (*iter).second.get() ) );
@@ -413,7 +412,7 @@ Any SAL_CALL SdStyleFamily::getByIndex( sal_Int32 Index ) throw(IndexOutOfBounds
else
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->GetFamily() == mnFamily) )
@@ -434,7 +433,7 @@ Any SAL_CALL SdStyleFamily::getByIndex( sal_Int32 Index ) throw(IndexOutOfBounds
void SAL_CALL SdStyleFamily::insertByName( const OUString& rName, const Any& rElement ) throw(IllegalArgumentException, ElementExistException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if(rName.getLength() == 0)
@@ -452,7 +451,7 @@ void SAL_CALL SdStyleFamily::insertByName( const OUString& rName, const Any& rEl
void SAL_CALL SdStyleFamily::removeByName( const OUString& rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
SdStyleSheet* pStyle = GetSheetByName( rName );
@@ -469,7 +468,7 @@ void SAL_CALL SdStyleFamily::removeByName( const OUString& rName ) throw(NoSuchE
void SAL_CALL SdStyleFamily::replaceByName( const OUString& rName, const Any& aElement ) throw(IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
SdStyleSheet* pOldStyle = GetSheetByName( rName );
@@ -485,7 +484,7 @@ void SAL_CALL SdStyleFamily::replaceByName( const OUString& rName, const Any& aE
Reference< XInterface > SAL_CALL SdStyleFamily::createInstance() throw(Exception, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( mnFamily == SD_STYLE_FAMILY_MASTERPAGE )
@@ -539,7 +538,7 @@ void SAL_CALL SdStyleFamily::removeEventListener( const Reference< XEventListene
Reference<XPropertySetInfo> SdStyleFamily::getPropertySetInfo() throw (RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
return Reference<XPropertySetInfo>();
}
@@ -547,7 +546,7 @@ Reference<XPropertySetInfo> SdStyleFamily::getPropertySetInfo() throw (RuntimeEx
void SdStyleFamily::setPropertyValue( const OUString& , const Any& ) throw (UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
}
// ----------------------------------------------------------
@@ -556,13 +555,12 @@ Any SdStyleFamily::getPropertyValue( const OUString& PropertyName ) throw (Unkno
{
if (PropertyName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("DisplayName") ))
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
OUString sDisplayName;
switch( mnFamily )
{
case SD_STYLE_FAMILY_MASTERPAGE: sDisplayName = getName(); break;
case SD_STYLE_FAMILY_CELL: sDisplayName = String( SdResId(STR_CELL_STYLE_FAMILY) ); break;
-// case SD_STYLE_FAMILY_GRAPHICS:
default: sDisplayName = String( SdResId(STR_GRAPHICS_STYLE_FAMILY) ); break;
}
return Any( sDisplayName );
@@ -577,27 +575,28 @@ Any SdStyleFamily::getPropertyValue( const OUString& PropertyName ) throw (Unkno
void SdStyleFamily::addPropertyChangeListener( const OUString& , const Reference<XPropertyChangeListener>& ) throw (UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
}
// ----------------------------------------------------------
void SdStyleFamily::removePropertyChangeListener( const OUString& , const Reference<XPropertyChangeListener>& ) throw (UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
}
// ----------------------------------------------------------
void SdStyleFamily::addVetoableChangeListener( const OUString& , const Reference<XVetoableChangeListener>& ) throw (UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
}
// ----------------------------------------------------------
void SdStyleFamily::removeVetoableChangeListener( const OUString& , const Reference<XVetoableChangeListener>& ) throw (UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OSL_ENSURE( 0, "###unexpected!" );
+ OSL_FAIL( "###unexpected!" );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/stlpool.cxx b/sd/source/core/stlpool.cxx
index babe9571c..d1bee4455 100755..100644
--- a/sd/source/core/stlpool.cxx
+++ b/sd/source/core/stlpool.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -49,9 +50,7 @@
#include <svl/smplhint.hxx>
#include <editeng/langitem.hxx>
#include <editeng/charreliefitem.hxx>
-#ifndef _SVX_EMPHITEM_HXX
#include <editeng/emphitem.hxx>
-#endif
#include <svx/sdr/table/tabledesign.hxx>
#include <editeng/akrnitem.hxx>
@@ -109,7 +108,6 @@ SdStyleSheetPool::SdStyleSheetPool(SfxItemPool const& _rPool, SdDrawDocument* pD
for( sal_uInt16 nPage = 0; nPage < nCount; ++nPage )
AddStyleFamily( mpDoc->GetMasterSdPage(nPage,PK_STANDARD) );
-// StartListening( *mpDoc );
}
}
@@ -152,21 +150,22 @@ SfxStyleSheetBase* SdStyleSheetPool::GetTitleSheet(const String& rLayoutName)
|*
\************************************************************************/
-List* SdStyleSheetPool::CreateOutlineSheetList (const String& rLayoutName)
+void SdStyleSheetPool::CreateOutlineSheetList (const String& rLayoutName, std::vector<SfxStyleSheetBase*> &rOutlineStyles)
{
String aName(rLayoutName);
aName.AppendAscii( RTL_CONSTASCII_STRINGPARAM( SD_LT_SEPARATOR ));
aName += String(SdResId(STR_LAYOUT_OUTLINE));
- List* pList = new List;
+
for (sal_uInt16 nSheet = 1; nSheet < 10; nSheet++)
{
String aFullName(aName);
aFullName.Append( sal_Unicode( ' ' ));
aFullName.Append( String::CreateFromInt32( (sal_Int32)nSheet ));
SfxStyleSheetBase* pSheet = Find(aFullName, SD_STYLE_FAMILY_MASTERPAGE);
- pList->Insert(pSheet, LIST_APPEND);
+
+ if (pSheet)
+ rOutlineStyles.push_back(pSheet);
}
- return pList;
}
/*************************************************************************
@@ -255,6 +254,8 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
rSet.Put( SvxColorItem( Color(COL_AUTO), EE_CHAR_COLOR) );
rSet.Put( XLineStyleItem(XLINE_NONE) );
rSet.Put( XFillStyleItem(XFILL_NONE) );
+ rSet.Put( SdrTextFitToSizeTypeItem(SDRTEXTFIT_AUTOFIT) );
+ rSet.Put( SdrTextAutoGrowHeightItem(sal_False) );
// #i16874# enable kerning by default but only for new documents
rSet.Put( SvxAutoKernItem( sal_True, EE_CHAR_PAIRKERNING ) );
@@ -266,8 +267,6 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
}
sal_uLong nFontSize = 20;
- short nFirstIndent = -600;
-// sal_uInt16 nIndent = nLevel * 1200;
sal_uInt16 nLower = 100;
switch (nLevel)
@@ -276,7 +275,6 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
{
nFontSize = 32;
nLower = 500;
- nFirstIndent = -900;
}
break;
@@ -284,7 +282,6 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
{
nFontSize = 28;
nLower = 400;
- nFirstIndent = -800;
}
break;
@@ -309,25 +306,9 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
rOutlineSet.Put( SvxFontHeightItem( nFontSize, 100, EE_CHAR_FONTHEIGHT_CJK ) );
rOutlineSet.Put( SvxFontHeightItem( SdDrawDocument::convertFontHeightToCTL( nFontSize ), 100, EE_CHAR_FONTHEIGHT_CTL ) );
- // Einzuege
-/* i35937
- aSvxLRSpaceItem.SetTxtFirstLineOfst(nFirstIndent);
- aSvxLRSpaceItem.SetTxtLeft(nIndent);
- aSvxLRSpaceItem.SetRight(0);
- aSvxLRSpaceItem.SetBulletFI(sal_True);
- pSheet->GetItemSet().Put(aSvxLRSpaceItem);
-*/
- // Zeilendurchschuss (Abstand nach unten)
+ // Line distance (downwards). Stuff around here cleaned up in i35937
aSvxULSpaceItem.SetLower(nLower);
pSheet->GetItemSet().Put(aSvxULSpaceItem);
-
-/* i35937
- if (nLevel == 1)
- {
- SfxUInt16Item aBulletStateItem(EE_PARA_BULLETSTATE, 1); // Bullets sichtbar
- pSheet->GetItemSet().Put(aBulletStateItem);
- }
-*/
}
}
@@ -394,7 +375,6 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
rTitleSet.Put(SvxColorItem( Color(COL_AUTO), EE_CHAR_COLOR ));
rTitleSet.Put(SvxAdjustItem(SVX_ADJUST_CENTER, EE_PARA_JUST ));
rTitleSet.Put( SdrTextVertAdjustItem( SDRTEXTVERTADJUST_CENTER ) );
-// rTitleSet.Put( SfxUInt16Item(EE_PARA_BULLETSTATE, 0) );
// #i16874# enable kerning by default but only for new documents
rTitleSet.Put( SvxAutoKernItem( sal_True, EE_CHAR_PAIRKERNING ) );
@@ -440,7 +420,6 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
rSubtitleSet.Put(SvxColorItem( Color(COL_AUTO), EE_CHAR_COLOR ));
rSubtitleSet.Put(SvxAdjustItem(SVX_ADJUST_CENTER, EE_PARA_JUST ));
rSubtitleSet.Put( SdrTextVertAdjustItem( SDRTEXTVERTADJUST_CENTER ) );
-// rSubtitleSet.Put( SfxUInt16Item(EE_PARA_BULLETSTATE, 0) );
// #i16874# enable kerning by default but only for new documents
rSubtitleSet.Put( SvxAutoKernItem( sal_True, EE_CHAR_PAIRKERNING ) );
aSvxLRSpaceItem.SetTxtLeft(0);
@@ -487,19 +466,11 @@ void SdStyleSheetPool::CreateLayoutStyleSheets(const String& rLayoutName, sal_Bo
rNotesSet.Put( SvxEmphasisMarkItem(EMPHASISMARK_NONE, EE_CHAR_EMPHASISMARK ) );
rNotesSet.Put( SvxCharReliefItem(RELIEF_NONE, EE_CHAR_RELIEF) );
rNotesSet.Put( SvxColorItem( Color(COL_AUTO), EE_CHAR_COLOR ) );
-// rNotesSet.Put( SfxUInt16Item(EE_PARA_BULLETSTATE, 0) );
rNotesSet.Put( SvxLRSpaceItem( 0, 0, 600, -600, EE_PARA_LRSPACE ) );
// #i16874# enable kerning by default but only for new documents
rNotesSet.Put( SvxAutoKernItem( sal_True, EE_CHAR_PAIRKERNING ) );
-/* #i35937#
- SvxNumBulletItem aNumBullet( (const SvxNumBulletItem&) rNotesSet.Get(EE_PARA_NUMBULLET) );
-
- EditEngine::ImportBulletItem( aNumBullet, 0, NULL,
- &(const SvxLRSpaceItem&) rNotesSet.Get( EE_PARA_LRSPACE ) );
-
- ( (SfxItemSet&) rNotesSet).Put( aNumBullet );
-*/
+/* #i35937# */
}
@@ -577,7 +548,7 @@ void SdStyleSheetPool::CopyTableStyles(SdStyleSheetPool& rSourcePool)
if( xSource.is() && xFactory.is() && mxTableFamily.is() )
{
for( sal_Int32 nIndex = 0; nIndex < xSource->getCount(); nIndex++ ) try
- {
+ {
Reference< XStyle > xSourceTableStyle( xSource->getByIndex( nIndex ), UNO_QUERY );
if( xSourceTableStyle.is() )
{
@@ -603,7 +574,7 @@ void SdStyleSheetPool::CopyTableStyles(SdStyleSheetPool& rSourcePool)
}
catch( Exception& )
{
- DBG_ERROR( "sd::SdStyleSheetPool::CopyTableStyles(), exception caught!" );
+ OSL_FAIL( "sd::SdStyleSheetPool::CopyTableStyles(), exception caught!" );
}
if( xTargetStyle.is() )
@@ -620,7 +591,7 @@ void SdStyleSheetPool::CopyTableStyles(SdStyleSheetPool& rSourcePool)
}
catch( Exception& )
{
- DBG_ERROR("sd::SdStyleSheetPool::CopyTableStyles(), exception caught!");
+ OSL_FAIL("sd::SdStyleSheetPool::CopyTableStyles(), exception caught!");
}
}
}
@@ -646,7 +617,7 @@ void SdStyleSheetPool::CopySheets(SdStyleSheetPool& rSourcePool, SfxStyleFamily
xNewSheet->SetMask( xSheet->GetMask() );
- // #91588# Also set parent relation for copied style sheets
+ // Also set parent relation for copied style sheets
String aParent( xSheet->GetParent() );
if( aParent.Len() )
aNewStyles.push_back( std::pair< rtl::Reference< SfxStyleSheetBase >, String >( xNewSheet, aParent ) );
@@ -659,7 +630,7 @@ void SdStyleSheetPool::CopySheets(SdStyleSheetPool& rSourcePool, SfxStyleFamily
// set parents on newly added stylesheets
std::vector< std::pair< rtl::Reference< SfxStyleSheetBase >, String > >::iterator aIter;
- for( aIter = aNewStyles.begin(); aIter != aNewStyles.end(); aIter++ )
+ for( aIter = aNewStyles.begin(); aIter != aNewStyles.end(); ++aIter )
{
DBG_ASSERT( rSourcePool.Find( (*aIter).second, eFamily ), "StyleSheet has invalid parent: Family mismatch" );
(*aIter).first->SetParent( (*aIter).second );
@@ -686,44 +657,51 @@ void SdStyleSheetPool::CopyLayoutSheets(const String& rLayoutName, SdStyleSheetP
String aOutlineTag(SdResId(STR_LAYOUT_OUTLINE));
- List* pNameList = CreateLayoutSheetNames(rLayoutName);
+ std::vector<String> aNameList;
+ CreateLayoutSheetNames(rLayoutName,aNameList);
String sEmpty;
- String* pName = (String*)pNameList->First();
- while (pName)
+ for (std::vector<String>::const_iterator it = aNameList.begin(); it != aNameList.end(); ++it)
{
- pSheet = Find(*pName, SD_STYLE_FAMILY_MASTERPAGE);
+ pSheet = Find(*it, SD_STYLE_FAMILY_MASTERPAGE);
if (!pSheet)
{
- SfxStyleSheetBase* pSourceSheet = rSourcePool.Find(*pName, SD_STYLE_FAMILY_MASTERPAGE);
+ SfxStyleSheetBase* pSourceSheet = rSourcePool.Find(*it, SD_STYLE_FAMILY_MASTERPAGE);
DBG_ASSERT(pSourceSheet, "CopyLayoutSheets: Quellvorlage nicht gefunden");
if (pSourceSheet)
{
// falls einer mit Methusalem-Doks. ankommt
- SfxStyleSheetBase& rNewSheet = Make(*pName, SD_STYLE_FAMILY_MASTERPAGE);
+ SfxStyleSheetBase& rNewSheet = Make(*it, SD_STYLE_FAMILY_MASTERPAGE);
rNewSheet.SetHelpId( sEmpty, pSourceSheet->GetHelpId( sEmpty ) );
rNewSheet.GetItemSet().Put(pSourceSheet->GetItemSet());
rCreatedSheets.push_back( SdStyleSheetRef( static_cast< SdStyleSheet* >( &rNewSheet ) ) );
}
}
- delete pName;
- pName = (String*)pNameList->Next();
}
- delete pNameList;
// Sonderbehandlung fuer Gliederungsvorlagen: Parentbeziehungen aufbauen
- List* pOutlineSheets = CreateOutlineSheetList(rLayoutName);
- SfxStyleSheetBase* pParent = (SfxStyleSheetBase*)pOutlineSheets->First();
- pSheet = (SfxStyleSheetBase*)pOutlineSheets->Next();
- while (pSheet)
+ std::vector<SfxStyleSheetBase*> aOutlineSheets;
+ CreateOutlineSheetList(rLayoutName,aOutlineSheets);
+
+ std::vector<SfxStyleSheetBase*>::iterator it = aOutlineSheets.begin();
+
+ SfxStyleSheetBase* pParent = *it;
+ ++it;
+
+ while (it != aOutlineSheets.end())
{
- // kein Parent?
+ pSheet = *it;
+
+ if (!pSheet)
+ break;
+
if (pSheet->GetParent().Len() == 0)
pSheet->SetParent(pParent->GetName());
+
pParent = pSheet;
- pSheet = (SfxStyleSheetBase*)pOutlineSheets->Next();
+
+ ++it;
}
- delete pOutlineSheets;
}
/*************************************************************************
@@ -733,47 +711,43 @@ void SdStyleSheetPool::CopyLayoutSheets(const String& rLayoutName, SdStyleSheetP
|*
\************************************************************************/
-List* SdStyleSheetPool::CreateLayoutSheetNames(const String& rLayoutName) const
+void SdStyleSheetPool::CreateLayoutSheetNames(const String& rLayoutName, std::vector<String> &aNameList) const
{
String aPrefix(rLayoutName);
String aSep( RTL_CONSTASCII_USTRINGPARAM( SD_LT_SEPARATOR ));
aPrefix.Insert(aSep);
- List* pNameList = new List;
-
String aName(SdResId(STR_LAYOUT_OUTLINE));
- String* pName = NULL;
+ String aStr;
for (sal_uInt16 nLevel = 1; nLevel < 10; nLevel++)
{
- pName = new String(aName);
- pName->Append( sal_Unicode( ' ' ));
- pName->Append( String::CreateFromInt32( sal_Int32( nLevel )));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
+ aStr = String( aPrefix );
+ aStr.Append(aName);
+ aStr.Append( sal_Unicode( ' ' ));
+ aStr.Append( String::CreateFromInt32( sal_Int32( nLevel )));
+ aNameList.push_back(aStr);
}
- pName = new String(SdResId(STR_LAYOUT_TITLE));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
+ aStr = String(SdResId(STR_LAYOUT_TITLE));
+ aStr.Insert(aPrefix, 0);
+ aNameList.push_back(aStr);
- pName = new String(SdResId(STR_LAYOUT_SUBTITLE));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
+ aStr = String(SdResId(STR_LAYOUT_SUBTITLE));
+ aStr.Insert(aPrefix, 0);
+ aNameList.push_back(aStr);
- pName = new String(SdResId(STR_LAYOUT_NOTES));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
+ aStr = String(SdResId(STR_LAYOUT_NOTES));
+ aStr.Insert(aPrefix, 0);
+ aNameList.push_back(aStr);
- pName = new String(SdResId(STR_LAYOUT_BACKGROUNDOBJECTS));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
+ aStr = String(SdResId(STR_LAYOUT_BACKGROUNDOBJECTS));
+ aStr.Insert(aPrefix, 0);
+ aNameList.push_back(aStr);
- pName = new String(SdResId(STR_LAYOUT_BACKGROUND));
- pName->Insert(aPrefix, 0);
- pNameList->Insert(pName, LIST_APPEND);
-
- return pNameList;
+ aStr = String(SdResId(STR_LAYOUT_BACKGROUND));
+ aStr.Insert(aPrefix, 0);
+ aNameList.push_back(aStr);
}
/*************************************************************************
@@ -813,7 +787,6 @@ void SdStyleSheetPool::CreatePseudosIfNecessary()
SfxStyleSheetBase* pSheet = NULL;
SfxStyleSheetBase* pParent = NULL;
- //sal_uInt16 nUsedMask = SFXSTYLEBIT_ALL & ~SFXSTYLEBIT_USERDEF;
sal_uInt16 nUsedMask = SFXSTYLEBIT_USED;
aName = String(SdResId(STR_PSEUDOSHEET_TITLE));
@@ -1046,7 +1019,7 @@ void SdStyleSheetPool::PutNumBulletItem( SfxStyleSheetBase* pSheet,
break;
case HID_PSEUDOSHEET_TITLE:
- /* #84013# title gets same bullet as subtitle and not that page symbol anymore */
+ /* title gets same bullet as subtitle and not that page symbol anymore */
case HID_PSEUDOSHEET_SUBTITLE :
{
// Untertitel-Vorlage
@@ -1378,7 +1351,7 @@ void SAL_CALL SdStyleSheetPool::dispose() throw (RuntimeException)
SdStyleFamilyMap aTempMap;
aTempMap.swap( maStyleFamilyMap );
- for( SdStyleFamilyMap::iterator iter( aTempMap.begin() ); iter != aTempMap.end(); iter++ ) try
+ for( SdStyleFamilyMap::iterator iter( aTempMap.begin() ); iter != aTempMap.end(); ++iter ) try
{
(*iter).second->dispose();
}
@@ -1386,7 +1359,6 @@ void SAL_CALL SdStyleSheetPool::dispose() throw (RuntimeException)
{
}
-// EndListening( *mpDoc );
mpDoc = 0;
Clear();
@@ -1440,3 +1412,5 @@ void SAL_CALL SdStyleSheetPool::release (void) throw ()
}
// --------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/stlsheet.cxx b/sd/source/core/stlsheet.cxx
index 46f96ae28..2f0a03ac9 100755..100644
--- a/sd/source/core/stlsheet.cxx
+++ b/sd/source/core/stlsheet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,7 +34,7 @@
#include <com/sun/star/style/XStyle.hpp>
#include <osl/mutex.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <comphelper/serviceinfohelper.hxx>
#include <boost/bind.hpp>
@@ -69,7 +70,6 @@ using ::rtl::OUString;
using ::osl::MutexGuard;
using ::osl::ClearableMutexGuard;
using ::cppu::OInterfaceContainerHelper;
-using namespace ::vos;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::util;
using namespace ::com::sun::star::lang;
@@ -301,7 +301,6 @@ SfxItemSet& SdStyleSheet::GetItemSet()
// aktuellen Praesentationslayouts: dessen ItemSet returnieren
else
{
-// return (GetRealStyleSheet()->GetItemSet());
SdStyleSheet* pSdSheet = GetRealStyleSheet();
@@ -732,7 +731,7 @@ OUString SdStyleSheet::GetFamilyString( SfxStyleFamily eFamily )
case SD_STYLE_FAMILY_CELL:
return OUString( RTL_CONSTASCII_USTRINGPARAM( "cell" ) );
default:
- DBG_ERROR( "SdStyleSheet::GetFamilyString(), illegal family!" );
+ OSL_FAIL( "SdStyleSheet::GetFamilyString(), illegal family!" );
case SD_STYLE_FAMILY_GRAPHICS:
return OUString( RTL_CONSTASCII_USTRINGPARAM( "graphics" ) );
}
@@ -766,21 +765,6 @@ SdStyleSheet* SdStyleSheet::CreateEmptyUserStyle( SfxStyleSheetBasePool& rPool,
// XInterface
// --------------------------------------------------------------------
-/*
-Any SAL_CALL SdStyleSheet::queryInterface( const ::com::sun::star::uno::Type& aType ) throw (RuntimeException)
-{
- return SdStyleSheetBase::queryInterface( aType );
-}
-
-// --------------------------------------------------------------------
-
-void SAL_CALL SdStyleSheet::acquire( ) throw ()
-{
- SdStyleSheetBase::acquire();
-}
-
-// --------------------------------------------------------------------
-*/
void SAL_CALL SdStyleSheet::release( ) throw ()
{
if (osl_decrementInterlockedCount( &m_refCount ) == 0)
@@ -793,8 +777,8 @@ void SAL_CALL SdStyleSheet::release( ) throw ()
}
catch (RuntimeException const& exc)
{ // don't break throw ()
- OSL_ENSURE(
- false, OUStringToOString(
+ OSL_FAIL(
+ OUStringToOString(
exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
static_cast<void>(exc);
}
@@ -804,31 +788,6 @@ void SAL_CALL SdStyleSheet::release( ) throw ()
}
// --------------------------------------------------------------------
-// XWeak
-// --------------------------------------------------------------------
-/*
-Reference< XAdapter > SAL_CALL SdStyleSheet::queryAdapter( ) throw (RuntimeException)
-{
- return SdStyleSheetBase::queryAdapter();
-}
-
-// --------------------------------------------------------------------
-// XTypeProvider
-// --------------------------------------------------------------------
-
-Sequence< Type > SAL_CALL SdStyleSheet::getTypes( ) throw (RuntimeException)
-{
- return SdStyleSheetBase::getTypes();
-}
-
-// --------------------------------------------------------------------
-
-Sequence< ::sal_Int8 > SAL_CALL SdStyleSheet::getImplementationId( ) throw (RuntimeException)
-{
- return SdStyleSheetBase::getImplementationId();
-}
-*/
-// --------------------------------------------------------------------
// XComponent
// --------------------------------------------------------------------
@@ -955,7 +914,7 @@ void SdStyleSheet::notifyModifyListener()
OUString SAL_CALL SdStyleSheet::getImplementationName() throw(RuntimeException)
{
- return OUString::createFromAscii( "SdStyleSheet" );
+ return OUString( RTL_CONSTASCII_USTRINGPARAM( "SdStyleSheet" ) );
}
// --------------------------------------------------------------------
@@ -992,7 +951,7 @@ Sequence< OUString > SAL_CALL SdStyleSheet::getSupportedServiceNames() throw(Run
OUString SAL_CALL SdStyleSheet::getName() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
return GetApiName();
}
@@ -1001,7 +960,7 @@ OUString SAL_CALL SdStyleSheet::getName() throw(RuntimeException)
void SAL_CALL SdStyleSheet::setName( const OUString& rName ) throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( SetName( rName ) )
@@ -1017,7 +976,7 @@ void SAL_CALL SdStyleSheet::setName( const OUString& rName ) throw(RuntimeExcep
sal_Bool SAL_CALL SdStyleSheet::isUserDefined() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
return IsUserDefined() ? sal_True : sal_False;
}
@@ -1026,7 +985,7 @@ sal_Bool SAL_CALL SdStyleSheet::isUserDefined() throw(RuntimeException)
sal_Bool SAL_CALL SdStyleSheet::isInUse() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
return IsUsed() ? sal_True : sal_False;
}
@@ -1035,7 +994,7 @@ sal_Bool SAL_CALL SdStyleSheet::isInUse() throw(RuntimeException)
OUString SAL_CALL SdStyleSheet::getParentStyle() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( GetParent().Len() )
@@ -1051,14 +1010,14 @@ OUString SAL_CALL SdStyleSheet::getParentStyle() throw(RuntimeException)
void SAL_CALL SdStyleSheet::setParentStyle( const OUString& rParentName ) throw(NoSuchElementException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
if( rParentName.getLength() )
{
const SfxStyles& rStyles = mxPool->GetStyles();
- for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); iter++ )
+ for( SfxStyles::const_iterator iter( rStyles.begin() ); iter != rStyles.end(); ++iter )
{
SdStyleSheet* pStyle = static_cast< SdStyleSheet* >( (*iter).get() );
if( pStyle && (pStyle->nFamily == nFamily) && (pStyle->msApiName == rParentName) )
@@ -1093,7 +1052,7 @@ Reference< XPropertySetInfo > SdStyleSheet::getPropertySetInfo() throw(RuntimeEx
void SAL_CALL SdStyleSheet::setPropertyValue( const OUString& aPropertyName, const Any& aValue ) throw(UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry( aPropertyName );
@@ -1174,7 +1133,7 @@ void SAL_CALL SdStyleSheet::setPropertyValue( const OUString& aPropertyName, con
Any SAL_CALL SdStyleSheet::getPropertyValue( const OUString& PropertyName ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1255,7 +1214,7 @@ Any SAL_CALL SdStyleSheet::getPropertyValue( const OUString& PropertyName ) thro
}
else
{
- DBG_ERROR("SvxShape::GetAnyForItem() Returnvalue has wrong Type!" );
+ OSL_FAIL("SvxShape::GetAnyForItem() Returnvalue has wrong Type!" );
}
}
@@ -1276,7 +1235,7 @@ void SAL_CALL SdStyleSheet::removeVetoableChangeListener( const OUString& , cons
PropertyState SAL_CALL SdStyleSheet::getPropertyState( const OUString& PropertyName ) throw(UnknownPropertyException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1322,8 +1281,6 @@ PropertyState SAL_CALL SdStyleSheet::getPropertyState( const OUString& PropertyN
case SFX_ITEM_DEFAULT:
eState = PropertyState_DEFAULT_VALUE;
break;
-// case SFX_ITEM_DONTCARE:
-// case SFX_ITEM_DISABLED:
default:
eState = PropertyState_AMBIGUOUS_VALUE;
break;
@@ -1357,7 +1314,7 @@ PropertyState SAL_CALL SdStyleSheet::getPropertyState( const OUString& PropertyN
Sequence< PropertyState > SAL_CALL SdStyleSheet::getPropertyStates( const Sequence< OUString >& aPropertyName ) throw(UnknownPropertyException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1377,7 +1334,7 @@ Sequence< PropertyState > SAL_CALL SdStyleSheet::getPropertyStates( const Sequen
void SAL_CALL SdStyleSheet::setPropertyToDefault( const OUString& PropertyName ) throw(UnknownPropertyException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1403,7 +1360,7 @@ void SAL_CALL SdStyleSheet::setPropertyToDefault( const OUString& PropertyName )
Any SAL_CALL SdStyleSheet::getPropertyDefault( const OUString& aPropertyName ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1441,3 +1398,4 @@ const SfxItemPropertySimpleEntry* SdStyleSheet::getPropertyMapEntry( const OUStr
return GetStylePropertySet().getPropertyMapEntry(rPropertyName);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/text/makefile.mk b/sd/source/core/text/makefile.mk
deleted file mode 100644
index 73b3e8a4a..000000000
--- a/sd/source/core/text/makefile.mk
+++ /dev/null
@@ -1,48 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=text
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/textapi.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/core/text/textapi.cxx b/sd/source/core/text/textapi.cxx
index 8aff0cebe..3426ad60e 100755..100644
--- a/sd/source/core/text/textapi.cxx
+++ b/sd/source/core/text/textapi.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -168,7 +169,6 @@ void SAL_CALL TextApiObject::dispose() throw(RuntimeException)
mpSource = 0;
}
- // SvxUnoText::dispose();
}
OutlinerParaObject* TextApiObject::CreateText()
@@ -294,3 +294,5 @@ String TextAPIEditSource::GetText()
}
} // namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/typemap.cxx b/sd/source/core/typemap.cxx
index f812dca67..dc8249b36 100644
--- a/sd/source/core/typemap.cxx
+++ b/sd/source/core/typemap.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -114,7 +115,6 @@
#define SvxNumTypeItem SfxUInt16Item
#define SvxShadowLocationItem SfxUInt16Item
#define SvxDbTypeItem SfxUInt16Item
-//#define SvxChooseControlEnumItem SfxUInt16Item
#define SvxDrawToolEnumItem SfxUInt16Item
#define SvxChooseControlItem SfxEnumItem
#define SvxDrawToolItem SfxUInt16Item
@@ -122,8 +122,6 @@
#define SvxCellVerJustifyEnumItem SfxUInt16Item
#define SvxCellOrientationEnumItem SfxUInt16Item
#define SvxLanguage SfxUInt16Item
-//#define SfxLockBytesItem SfxPoolItem
-#define OfaStringListItem SfxStringListItem
#define avmedia_MediaItem ::avmedia::MediaItem
#include <sfx2/tplpitem.hxx>
#include <svl/ptitem.hxx>
@@ -134,3 +132,4 @@
#define SFX_TYPEMAP
#include "sdslots.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/undo/makefile.mk b/sd/source/core/undo/makefile.mk
deleted file mode 100644
index e9b3753b0..000000000
--- a/sd/source/core/undo/makefile.mk
+++ /dev/null
@@ -1,50 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=undo
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/undomanager.obj \
- $(SLO)$/undofactory.obj \
- $(SLO)$/undoobjects.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/core/undo/undofactory.cxx b/sd/source/core/undo/undofactory.cxx
index f9b2e7b4f..f097fdbb8 100644
--- a/sd/source/core/undo/undofactory.cxx
+++ b/sd/source/core/undo/undofactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ SdrUndoAction* UndoFactory::CreateUndoAttrObject( SdrObject& rObject, bool bStyl
{
return new UndoAttrObject( rObject, bStyleSheet1, bSaveText );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/undo/undomanager.cxx b/sd/source/core/undo/undomanager.cxx
index 83f5fd5a1..8dbb6dd2a 100755..100644
--- a/sd/source/core/undo/undomanager.cxx
+++ b/sd/source/core/undo/undomanager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ void UndoManager::ClearLinkedRedoActions (void)
if (mpLinkedUndoManager != NULL)
mpLinkedUndoManager->ClearRedo();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/undo/undoobjects.cxx b/sd/source/core/undo/undoobjects.cxx
index b5099d7db..110c0c13f 100755..100644
--- a/sd/source/core/undo/undoobjects.cxx
+++ b/sd/source/core/undo/undoobjects.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -445,3 +446,5 @@ void UndoAttrObject::Redo()
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/core/undoanim.cxx b/sd/source/core/undoanim.cxx
index e6878f8aa..5846af0e0 100644
--- a/sd/source/core/undoanim.cxx
+++ b/sd/source/core/undoanim.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,7 +71,7 @@ UndoAnimation::UndoAnimation( SdDrawDocument* pDoc, SdPage* pThePage )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::UndoAnimation::UndoAnimation(), exception caught!");
+ OSL_FAIL("sd::UndoAnimation::UndoAnimation(), exception caught!");
}
}
@@ -99,7 +100,7 @@ void UndoAnimation::Undo()
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::UndoAnimation::Undo(), exception caught!");
+ OSL_FAIL("sd::UndoAnimation::Undo(), exception caught!");
}
}
@@ -115,7 +116,7 @@ void UndoAnimation::Redo()
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::UndoAnimation::Redo(), exception caught!");
+ OSL_FAIL("sd::UndoAnimation::Redo(), exception caught!");
}
}
@@ -294,3 +295,5 @@ String UndoTransition::GetComment() const
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/cgm/sdcgmfilter.cxx b/sd/source/filter/cgm/sdcgmfilter.cxx
index 17b070326..3adc47b14 100755..100644
--- a/sd/source/filter/cgm/sdcgmfilter.cxx
+++ b/sd/source/filter/cgm/sdcgmfilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,7 +95,7 @@ sal_Bool SdCGMFilter::Import()
if( pLibrary && mxModel.is() )
{
- ImportCGM FncImportCGM = reinterpret_cast< ImportCGM >( pLibrary->getFunctionSymbol( ::rtl::OUString::createFromAscii( "ImportCGM" ) ) );
+ ImportCGM FncImportCGM = reinterpret_cast< ImportCGM >( pLibrary->getFunctionSymbol( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "ImportCGM" ) ) ) );
::rtl::OUString aFileURL( mrMedium.GetURLObject().GetMainURL( INetURLObject::NO_DECODE ) );
sal_uInt32 nRetValue;
@@ -138,16 +139,12 @@ sal_Bool SdCGMFilter::Export()
if( pLibrary && mxModel.is() )
{
- ExportCGM FncCGMExport = reinterpret_cast< ExportCGM >( pLibrary->getFunctionSymbol( ::rtl::OUString::createFromAscii( "ExportCGM" ) ) );
+ ExportCGM FncCGMExport = reinterpret_cast< ExportCGM >( pLibrary->getFunctionSymbol( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "ExportCGM" ) ) ) );
if( FncCGMExport )
{
::rtl::OUString aPhysicalName( mrMedium.GetPhysicalName() );
- /* !!!
- if ( pViewShell && pViewShell->GetView() )
- pViewShell->GetView()->SdrEndTextEdit();
- */
CreateStatusIndicator();
bRet = FncCGMExport( aPhysicalName, mxModel, mxStatusIndicator, NULL );
}
@@ -157,3 +154,5 @@ sal_Bool SdCGMFilter::Export()
return bRet;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx
index e7c7ddcd8..b996d205c 100755..100644
--- a/sd/source/filter/eppt/eppt.cxx
+++ b/sd/source/filter/eppt/eppt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,62 +63,13 @@
#include <filter/msfilter/svxmsbas.hxx>
#include <editeng/flditem.hxx>
#include <sfx2/docinf.hxx>
-
-#define PPT_TRANSITION_TYPE_NONE 0
-#define PPT_TRANSITION_TYPE_RANDOM 1
-#define PPT_TRANSITION_TYPE_BLINDS 2
-#define PPT_TRANSITION_TYPE_CHECKER 3
-#define PPT_TRANSITION_TYPE_COVER 4
-#define PPT_TRANSITION_TYPE_DISSOLVE 5
-#define PPT_TRANSITION_TYPE_FADE 6
-#define PPT_TRANSITION_TYPE_PULL 7
-#define PPT_TRANSITION_TYPE_RANDOM_BARS 8
-#define PPT_TRANSITION_TYPE_STRIPS 9
-#define PPT_TRANSITION_TYPE_WIPE 10
-#define PPT_TRANSITION_TYPE_ZOOM 11
-#define PPT_TRANSITION_TYPE_SPLIT 13
-
-// effects, new in xp
-#define PPT_TRANSITION_TYPE_DIAMOND 17
-#define PPT_TRANSITION_TYPE_PLUS 18
-#define PPT_TRANSITION_TYPE_WEDGE 19
-#define PPT_TRANSITION_TYPE_PUSH 20
-#define PPT_TRANSITION_TYPE_COMB 21
-#define PPT_TRANSITION_TYPE_NEWSFLASH 22
-#define PPT_TRANSITION_TYPE_SMOOTHFADE 23
-#define PPT_TRANSITION_TYPE_WHEEL 26
-#define PPT_TRANSITION_TYPE_CIRCLE 27
+#include <oox/export/utils.hxx>
using namespace com::sun::star;
+using namespace ::com::sun::star::uno;
+using namespace ::com::sun::star::presentation;
-static PHLayout pPHLayout[] =
-{
- { EPP_LAYOUT_TITLESLIDE, { 0x0d, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x10, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_True, sal_True },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_BLANCSLIDE, { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_False, sal_False, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x14, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x15, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x15, 0x0d, 0x0e, sal_True, sal_False, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x16, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_False, sal_False },
- { EPP_LAYOUT_RIGHTCOLUMN2ROWS, { 0x0d, 0x0e, 0x13, 0x13, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2ROWSANDTITLE, { 0x0d, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_LEFTCOLUMN2ROWS, { 0x0d, 0x13, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TOPROW2COLUMN, { 0x0d, 0x13, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2ROWSANDTITLE, { 0x0d, 0x0e, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_4OBJECTS, { 0x0d, 0x13, 0x13, 0x13, 0x13, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_False, sal_False },
- { EPP_LAYOUT_ONLYTITLE, { 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_False, sal_False },
- { EPP_LAYOUT_BLANCSLIDE, { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_False, sal_False, sal_False },
- { EPP_LAYOUT_TITLERIGHT2BODIESLEFT, { 0x11, 0x12, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x11, 0x12, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLERIGHTBODYLEFT, { 0x11, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x11, 0x12, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x12, sal_True, sal_True, sal_False },
- { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x16, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x12, sal_True, sal_True, sal_False }
-};
+using ::com::sun::star::beans::XPropertySet;
//============================ PPTWriter ==================================
@@ -125,16 +77,12 @@ PPTWriter::PPTWriter( SvStorageRef& rSvStorage,
::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > & rXModel,
::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator > & rXStatInd,
SvMemoryStream* pVBA, sal_uInt32 nCnvrtFlags ) :
+ PPTWriterBase ( rXModel, rXStatInd ),
+ mnCnvrtFlags ( nCnvrtFlags ),
mbStatus ( sal_False ),
- mbUseNewAnimations ( sal_True ),
+ mbUseNewAnimations ( sal_True ),
mnLatestStatValue ( 0 ),
- maFraction ( 1, 576 ),
- maMapModeSrc ( MAP_100TH_MM ),
- maMapModeDest ( MAP_INCH, Point(), maFraction, maFraction ),
- meLatestPageType ( NORMAL ),
- mXModel ( rXModel ),
- mXStatusIndicator ( rXStatInd ),
- mbStatusIndicator ( sal_False ),
+ mrStg ( rSvStorage ),
mpCurUserStrm ( NULL ),
mpStrm ( NULL ),
mpPicStrm ( NULL ),
@@ -146,38 +94,10 @@ PPTWriter::PPTWriter( SvStorageRef& rSvStorage,
mnPagesWritten ( 0 ),
mnTxId ( 0x7a2f64 )
{
- sal_uInt32 i;
- if ( !ImplInitSOIface() )
- return;
-
- FontCollectionEntry aDefaultFontDesc( String( RTL_CONSTASCII_USTRINGPARAM( "Times New Roman" ) ),
- ::com::sun::star::awt::FontFamily::ROMAN,
- ::com::sun::star::awt::FontPitch::VARIABLE,
- RTL_TEXTENCODING_MS_1252 );
- maFontCollection.GetId( aDefaultFontDesc ); // default is always times new roman
-
- if ( !ImplGetPageByIndex( 0, NOTICE ) )
- return;
- sal_Int32 nWidth = 21000;
- if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Width" ) ) ) )
- mAny >>= nWidth;
- sal_Int32 nHeight = 29700;
- if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Height" ) ) ) )
- mAny >>= nHeight;
-
- maNotesPageSize = ImplMapSize( ::com::sun::star::awt::Size( nWidth, nHeight ) );
+}
- if ( !ImplGetPageByIndex( 0, MASTER ) )
- return;
- nWidth = 28000;
- if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Width" ) ) ) )
- mAny >>= nWidth;
- nHeight = 21000;
- if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Height" ) ) ) )
- mAny >>= nHeight;
- maDestPageSize = ImplMapSize( ::com::sun::star::awt::Size( nWidth, nHeight ) );
-
- mrStg = rSvStorage;
+void PPTWriter::exportPPTPre()
+{
if ( !mrStg.Is() )
return;
@@ -206,30 +126,10 @@ PPTWriter::PPTWriter( SvStorageRef& rSvStorage,
mpPicStrm = mrStg->OpenSotStream( String( RTL_CONSTASCII_USTRINGPARAM( "Pictures" ) ) );
mpPptEscherEx = new PptEscherEx( *mpStrm );
+}
- if ( !ImplGetStyleSheets() )
- return;
-
- if ( !ImplCreateDocument() )
- return;
-
- for ( i = 0; i < mnMasterPages; i++ )
- {
- if ( !ImplCreateMaster( i ) )
- return;
- }
- if ( !ImplCreateMainNotes() )
- return;
- for ( i = 0; i < mnPages; i++ )
- {
- if ( !ImplCreateSlide( i ) )
- return;
- }
- for ( i = 0; i < mnPages; i++ )
- {
- if ( !ImplCreateNotes( i ) )
- return;
- }
+void PPTWriter::exportPPTPost( )
+{
if ( !ImplCloseDocument() )
return;
@@ -244,19 +144,300 @@ PPTWriter::PPTWriter( SvStorageRef& rSvStorage,
}
}
- ImplWriteOLE( nCnvrtFlags );
+ ImplWriteOLE();
- ImplWriteVBA( pVBA );
+ ImplWriteVBA();
if ( !ImplWriteAtomEnding() )
return;
- if ( !ImplCreateDocumentSummaryInformation( nCnvrtFlags ) )
+ if ( !ImplCreateDocumentSummaryInformation() )
return;
mbStatus = sal_True;
};
+// ---------------------------------------------------------------------------------------------
+
+void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStream& rBinaryTagData10Atom );
+
+void PPTWriter::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNum, sal_uInt16 nMode,
+ sal_Bool bHasBackground, Reference< XPropertySet > aXBackgroundPropSet )
+{
+ Any aAny;
+
+ const PHLayout& rLayout = GetLayout( mXPagePropSet );
+ mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_Slide | nPageNum, mpStrm->Tell() );
+ mpPptEscherEx->OpenContainer( EPP_Slide );
+ mpPptEscherEx->AddAtom( 24, EPP_SlideAtom, 2 );
+ *mpStrm << rLayout.nLayout;
+ mpStrm->Write( rLayout.nPlaceHolder, 8 ); // placeholderIDs ( 8Stueck )
+ *mpStrm << (sal_uInt32)(nMasterNum | 0x80000000)// master ID ( ist gleich 0x80000000 bei einer masterpage )
+ << (sal_uInt32)nPageNum + 0x100 // notes ID ( ist gleich null wenn keine notizen vorhanden )
+ << nMode
+ << (sal_uInt16)0; // padword
+
+ mnDiaMode = 0;
+ sal_Bool bVisible = sal_True;
+ ::com::sun::star::presentation::FadeEffect eFe = ::com::sun::star::presentation::FadeEffect_NONE;
+
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Visible" ) ) ) )
+ aAny >>= bVisible;
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Change" ) ) ) )
+ {
+ switch ( *(sal_Int32*)aAny.getValue() )
+ {
+ case 1 : // automatisch
+ mnDiaMode++;
+ case 2 : // halbautomatisch
+ mnDiaMode++;
+ default :
+ case 0 : // manuell
+ break;
+ }
+ }
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Effect" ) ) ) )
+ aAny >>= eFe;
+
+ sal_uInt32 nSoundRef = 0;
+ sal_Bool bIsSound = sal_False;
+ sal_Bool bStopSound = sal_False;
+ sal_Bool bLoopSound = sal_False;
+
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Sound" ) ) ) )
+ {
+ rtl::OUString aSoundURL;
+ if ( aAny >>= aSoundURL )
+ {
+ nSoundRef = maSoundCollection.GetId( aSoundURL );
+ bIsSound = sal_True;
+ }
+ else
+ aAny >>= bStopSound;
+ }
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "LoopSound" ) ) ) )
+ aAny >>= bLoopSound;
+
+ sal_Bool bNeedsSSSlideInfoAtom = ( bVisible == sal_False )
+ || ( mnDiaMode == 2 )
+ || ( bIsSound )
+ || ( bStopSound )
+ || ( eFe != ::com::sun::star::presentation::FadeEffect_NONE );
+ if ( bNeedsSSSlideInfoAtom )
+ {
+ sal_uInt8 nDirection = 0;
+ sal_uInt8 nTransitionType = 0;
+ sal_uInt16 nBuildFlags = 1; // advange by mouseclick
+ sal_Int32 nSlideTime = 0; // muss noch !!!
+ sal_uInt8 nSpeed = 1;
+
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Speed" ) ) ) )
+ {
+ ::com::sun::star::presentation::AnimationSpeed aAs;
+ aAny >>= aAs;
+ nSpeed = (sal_uInt8)aAs;
+ }
+ sal_Int16 nTT = 0;
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TransitionType" ) ) )
+ && ( aAny >>= nTT ) )
+ {
+ sal_Int16 nTST = 0;
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TransitionSubtype" ) ) )
+ && ( aAny >>= nTST ) )
+ nTransitionType = GetTransition( nTT, nTST, eFe, nDirection );
+
+ }
+ if ( !nTransitionType )
+ nTransitionType = GetTransition( eFe, nDirection );
+ if ( mnDiaMode == 2 ) // automatic ?
+ nBuildFlags |= 0x400;
+ if ( bVisible == sal_False )
+ nBuildFlags |= 4;
+ if ( bIsSound )
+ nBuildFlags |= 16;
+ if ( bLoopSound )
+ nBuildFlags |= 64;
+ if ( bStopSound )
+ nBuildFlags |= 256;
+
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Duration" ) ) ) )// duration of this slide
+ nSlideTime = *(sal_Int32*)aAny.getValue() << 10; // in ticks
+
+ mpPptEscherEx->AddAtom( 16, EPP_SSSlideInfoAtom );
+ *mpStrm << nSlideTime // standtime in ticks
+ << nSoundRef
+ << nDirection
+ << nTransitionType
+ << nBuildFlags
+ << nSpeed
+ << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0;
+ }
+
+ ImplCreateHeaderFooters( mXPagePropSet );
+
+ EscherSolverContainer aSolverContainer;
+ mpPptEscherEx->OpenContainer( EPP_PPDrawing );
+ mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
+ mpPptEscherEx->EnterGroup(0,0);
+ ImplWritePage( rLayout, aSolverContainer, NORMAL, sal_False, nPageNum ); // Die Shapes der Seite werden im PPT Dok. erzeugt
+ mpPptEscherEx->LeaveGroup();
+
+ if ( bHasBackground )
+ ImplWriteBackground( aXBackgroundPropSet );
+ else
+ {
+ mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
+ mpPptEscherEx->AddShape( ESCHER_ShpInst_Rectangle, 0xc00 ); // Flags: Connector | Background | HasSpt
+ EscherPropertyContainer aPropOpt;
+ aPropOpt.AddOpt( ESCHER_Prop_fillRectRight, PPTtoEMU( maDestPageSize.Width ) );
+ aPropOpt.AddOpt( ESCHER_Prop_fillRectBottom, PPTtoEMU( maDestPageSize.Width ) );
+ aPropOpt.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x120012 );
+ aPropOpt.AddOpt( ESCHER_Prop_fNoLineDrawDash, 0x80000 );
+ aPropOpt.AddOpt( ESCHER_Prop_bWMode, ESCHER_wDontShow );
+ aPropOpt.AddOpt( ESCHER_Prop_fBackground, 0x10001 ); // if true, this is the background shape
+ aPropOpt.Commit( *mpStrm );
+ mpPptEscherEx->CloseContainer(); // ESCHER_SpContainer
+ }
+
+ aSolverContainer.WriteSolver( *mpStrm );
+
+ mpPptEscherEx->CloseContainer(); // ESCHER_DgContainer
+ mpPptEscherEx->CloseContainer(); // EPP_Drawing
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 1 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
+
+ SvMemoryStream aBinaryTagData10Atom;
+ ImplExportComments( mXDrawPage, aBinaryTagData10Atom );
+ if ( mbUseNewAnimations )
+ {
+ SvMemoryStream amsofbtAnimGroup;
+ ppt::AnimationExporter aExporter( aSolverContainer, maSoundCollection );
+ aExporter.doexport( mXDrawPage, amsofbtAnimGroup );
+ sal_uInt32 nmsofbtAnimGroupSize = amsofbtAnimGroup.Tell();
+ if ( nmsofbtAnimGroupSize )
+ {
+ {
+ EscherExAtom aMagic2( aBinaryTagData10Atom, 0x2eeb );
+ aBinaryTagData10Atom << (sal_uInt32)0x01c45df9
+ << (sal_uInt32)0xe1471b30;
+ }
+ {
+ EscherExAtom aMagic( aBinaryTagData10Atom, 0x2b00 );
+ aBinaryTagData10Atom << (sal_uInt32)0;
+ }
+ aBinaryTagData10Atom.Write( amsofbtAnimGroup.GetData(), amsofbtAnimGroup.Tell() );
+ {
+ EscherExContainer aMagic2( aBinaryTagData10Atom, 0x2b02 );
+ }
+ }
+ }
+ if ( aBinaryTagData10Atom.Tell() )
+ {
+ EscherExContainer aProgTags ( *mpStrm, EPP_ProgTags );
+ EscherExContainer aProgBinaryTag( *mpStrm, EPP_ProgBinaryTag );
+ {
+ EscherExAtom aCString( *mpStrm, EPP_CString );
+ *mpStrm << (sal_uInt32)0x5f005f
+ << (sal_uInt32)0x50005f
+ << (sal_uInt32)0x540050
+ << (sal_uInt16)0x31
+ << (sal_uInt16)0x30;
+ }
+ {
+ EscherExAtom aBinaryTagData( *mpStrm, EPP_BinaryTagData );
+ mpStrm->Write( aBinaryTagData10Atom.GetData(), aBinaryTagData10Atom.Tell() );
+ }
+ }
+ mpPptEscherEx->CloseContainer(); // EPP_Slide
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void PPTWriter::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPropertySet > aXBackgroundPropSet )
+{
+ mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_MainMaster | nPageNum, mpStrm->Tell() );
+ mpPptEscherEx->OpenContainer( EPP_MainMaster );
+ mpPptEscherEx->AddAtom( 24, EPP_SlideAtom, 2 );
+ *mpStrm << (sal_Int32)EPP_LAYOUT_TITLEANDBODYSLIDE // slide layout -> title and body slide
+ << (sal_uInt8)1 << (sal_uInt8)2 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 // placeholderID
+ << (sal_uInt32)0 // master ID ( ist gleich null bei einer masterpage )
+ << (sal_uInt32)0 // notes ID ( ist gleich null wenn keine notizen vorhanden )
+ << (sal_uInt16)0 // Bit 1: Follow master objects, Bit 2: Follow master scheme, Bit 3: Follow master background
+ << (sal_uInt16)0; // padword
+
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xff0000 << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x00ffff << (sal_uInt32)0x0099ff << (sal_uInt32)0xffff00 << (sal_uInt32)0x0000ff << (sal_uInt32)0x969696;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xccffff << (sal_uInt32)0x000000 << (sal_uInt32)0x336666 << (sal_uInt32)0x008080 << (sal_uInt32)0x339933 << (sal_uInt32)0x000080 << (sal_uInt32)0xcc3300 << (sal_uInt32)0x66ccff;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x333333 << (sal_uInt32)0x000000 << (sal_uInt32)0xdddddd << (sal_uInt32)0x808080 << (sal_uInt32)0x4d4d4d << (sal_uInt32)0xeaeaea;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x66ccff << (sal_uInt32)0xff0000 << (sal_uInt32)0xcc00cc << (sal_uInt32)0xc0c0c0;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0xc0c0c0 << (sal_uInt32)0xff6600 << (sal_uInt32)0x0000ff << (sal_uInt32)0x009900;
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0xff9933 << (sal_uInt32)0xccff99 << (sal_uInt32)0xcc00cc << (sal_uInt32)0xb2b2b2;
+
+ for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
+ {
+ if ( nInstance == EPP_TEXTTYPE_notUsed )
+ continue;
+
+ // the auto color is dependent to the page background,so we have to set a page that is in the right context
+ if ( nInstance == EPP_TEXTTYPE_Notes )
+ GetPageByIndex( 0, NOTICE );
+ else
+ GetPageByIndex( 0, MASTER );
+
+ mpPptEscherEx->BeginAtom();
+
+ sal_Bool bFirst = sal_True;
+ sal_Bool bSimpleText = sal_False;
+
+ *mpStrm << (sal_uInt16)5; // paragraph count
+
+ for ( sal_uInt16 nLev = 0; nLev < 5; nLev++ )
+ {
+ if ( nInstance >= EPP_TEXTTYPE_CenterBody )
+ {
+ bFirst = sal_False;
+ bSimpleText = sal_True;
+ *mpStrm << nLev;
+ }
+ mpStyleSheet->mpParaSheet[ nInstance ]->Write( *mpStrm, mpPptEscherEx, nLev, bFirst, bSimpleText, mXPagePropSet );
+ mpStyleSheet->mpCharSheet[ nInstance ]->Write( *mpStrm, mpPptEscherEx, nLev, bFirst, bSimpleText, mXPagePropSet );
+ bFirst = sal_False;
+ }
+ mpPptEscherEx->EndAtom( EPP_TxMasterStyleAtom, 0, nInstance );
+ }
+ GetPageByIndex( nPageNum, MASTER );
+
+ EscherSolverContainer aSolverContainer;
+
+ mpPptEscherEx->OpenContainer( EPP_PPDrawing );
+ mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
+
+ mpPptEscherEx->EnterGroup(0,0);
+ ImplWritePage( GetLayout( 0 ), aSolverContainer, MASTER, sal_True ); // Die Shapes der Seite werden im PPT Dok. erzeugt
+ mpPptEscherEx->LeaveGroup();
+
+ ImplWriteBackground( aXBackgroundPropSet );
+
+ aSolverContainer.WriteSolver( *mpStrm );
+
+ mpPptEscherEx->CloseContainer(); // ESCHER_DgContainer
+ mpPptEscherEx->CloseContainer(); // EPP_Drawing
+ mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 1 );
+ *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
+
+ if ( aBuExMasterStream.Tell() )
+ {
+ ImplProgTagContainer( mpStrm, &aBuExMasterStream );
+ }
+ mpPptEscherEx->CloseContainer(); // EPP_MainMaster
+};
// ---------------------------------------------------------------------------------------------
@@ -275,8 +456,6 @@ PPTWriter::~PPTWriter()
while( aStyleSheetIter < maStyleSheetList.end() )
delete *aStyleSheetIter++;
- for ( pPtr = maSlideNameList.First(); pPtr; pPtr = maSlideNameList.Next() )
- delete (::rtl::OUString*)pPtr;
for ( pPtr = maHyperlink.First(); pPtr; pPtr = maHyperlink.Next() )
delete (EPPTHyperlink*)pPtr;
for ( pPtr = maExOleObj.First(); pPtr; pPtr = maExOleObj.Next() )
@@ -288,13 +467,6 @@ PPTWriter::~PPTWriter()
// ---------------------------------------------------------------------------------------------
-static inline sal_uInt32 PPTtoEMU( sal_Int32 nPPT )
-{
- return (sal_uInt32)( (double)nPPT * 1587.5 );
-}
-
-// ---------------------------------------------------------------------------------------------
-
sal_Bool PPTWriter::ImplCreateCurrentUserStream()
{
mpCurUserStrm = mrStg->OpenSotStream( String( RTL_CONSTASCII_USTRINGPARAM( "Current User" ) ) );
@@ -327,7 +499,7 @@ sal_Bool PPTWriter::ImplCreateCurrentUserStream()
// ---------------------------------------------------------------------------------------------
-sal_Bool PPTWriter::ImplCreateDocumentSummaryInformation( sal_uInt32 nCnvrtFlags )
+sal_Bool PPTWriter::ImplCreateDocumentSummaryInformation()
{
uno::Reference<document::XDocumentPropertiesSupplier> xDPS(
mXModel, uno::UNO_QUERY_THROW);
@@ -357,10 +529,10 @@ sal_Bool PPTWriter::ImplCreateDocumentSummaryInformation( sal_uInt32 nCnvrtFlags
aHyperSeq[j] = pBlob[j];
}
- if ( nCnvrtFlags & 0x8000 )
+ if ( mnCnvrtFlags & 0x8000 )
{
uno::Sequence<sal_uInt8> aThumbSeq;
- if ( ImplGetPageByIndex( 0, NORMAL ) &&
+ if ( GetPageByIndex( 0, NORMAL ) &&
ImplGetPropertyValue( mXPagePropSet,
String( RTL_CONSTASCII_USTRINGPARAM( "PreviewBitmap" ) ) ) )
{
@@ -544,16 +716,16 @@ sal_Bool PPTWriter::ImplCreateDocument()
mpPptEscherEx->PtInsert( EPP_Persist_Document, mpStrm->Tell() );
- mpPptEscherEx->OpenContainer( EPP_HeadersFooters, 3 ); //Master footer (default)
+ mpPptEscherEx->OpenContainer( EPP_HeadersFooters, 3 ); //Master footer (default)
mpPptEscherEx->AddAtom( 4, EPP_HeadersFootersAtom );
*mpStrm << (sal_uInt32)0x25000d;
- if ( ImplGetPageByIndex( 0, MASTER ) )
+ if ( GetPageByIndex( 0, MASTER ) )
ImplCreateHeaderFooterStrings( *mpStrm, mXPagePropSet );
mpPptEscherEx->CloseContainer();
- mpPptEscherEx->OpenContainer( EPP_HeadersFooters, 4 ); //NotesMaster footer (default)
+ mpPptEscherEx->OpenContainer( EPP_HeadersFooters, 4 ); //NotesMaster footer (default)
mpPptEscherEx->AddAtom( 4, EPP_HeadersFootersAtom );
*mpStrm << (sal_uInt32)0x3d000d;
- if ( ImplGetPageByIndex( 0, NOTICE ) )
+ if ( GetPageByIndex( 0, NOTICE ) )
ImplCreateHeaderFooterStrings( *mpStrm, mXPagePropSet );
mpPptEscherEx->CloseContainer();
@@ -563,27 +735,23 @@ sal_Bool PPTWriter::ImplCreateDocument()
{
mpPptEscherEx->AddAtom( 20, EPP_SlidePersistAtom );
mpPptEscherEx->InsertPersistOffset( EPP_MAINSLIDE_PERSIST_KEY | i, mpStrm->Tell() );
- *mpStrm << (sal_uInt32)0 // psrReference - logical reference to the slide persist object ( EPP_MAINSLIDE_PERSIST_KEY )
+ *mpStrm << (sal_uInt32)0 // psrReference - logical reference to the slide persist object ( EPP_MAINSLIDE_PERSIST_KEY )
<< (sal_uInt32)4 // flags - only bit 3 used, if set then slide contains shapes other than placeholders
<< (sal_Int32)0 // numberTexts - number of placeholder texts stored with the persist object. Allows to display outline view without loading the slide persist objects
<< (sal_Int32)i + 0x100 // slideId - Unique slide identifier, used for OLE link monikers for example
<< (sal_uInt32)0; // reserved, usualy 0
- if ( !ImplGetPageByIndex( i, NORMAL ) ) // sehr aufregend: noch einmal ueber alle seiten
+ if ( !GetPageByIndex( i, NORMAL ) ) // sehr aufregend: noch einmal ueber alle seiten
return sal_False;
- ImplSetCurrentStyleSheet( ImplGetMasterIndex( NORMAL ) );
+ SetCurrentStyleSheet( GetMasterIndex( NORMAL ) );
::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed >
aXName( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
if ( aXName.is() )
- {
- ::rtl::OUString aStr = aXName->getName();
- ::rtl::OUString *pUStr = new ::rtl::OUString( aStr );
- maSlideNameList.Insert( pUStr, LIST_APPEND );
- }
+ maSlideNameList.push_back( aXName->getName() );
else
- maSlideNameList.Insert( new ::rtl::OUString(), LIST_APPEND );
+ maSlideNameList.push_back( ::rtl::OUString() );
}
mpPptEscherEx->CloseContainer(); // EPP_SlideListWithText
@@ -640,29 +808,19 @@ sal_Bool PPTWriter::ImplCreateDocument()
if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "FirstPage" ) ) ) )
{
::rtl::OUString aSlideName( *(::rtl::OUString*)mAny.getValue() );
- ::rtl::OUString* pStr;
- for ( pStr = (::rtl::OUString*)maSlideNameList.First(); pStr;
- pStr = (::rtl::OUString*)maSlideNameList.Next(), nStartSlide++ )
+
+ std::vector<rtl::OUString>::const_iterator pIter = std::find(
+ maSlideNameList.begin(),maSlideNameList.end(),aSlideName);
+
+ if (pIter != maSlideNameList.end())
{
- if ( *pStr == aSlideName )
- {
- nStartSlide++;
- nFlags |= 4;
- nEndSlide = (sal_uInt16)mnPages;
- break;
- }
+ nStartSlide = pIter - maSlideNameList.begin() + 1;
+ nFlags |= 4;
+ nEndSlide = (sal_uInt16)mnPages;
}
- if ( !pStr )
- nStartSlide = 0;
}
}
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "DiaName" ) ) ) )
-// {
-// }
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsAlwaysOnTop" ) ) ) )
-// {
-// }
if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsAutomatic" ) ) ) )
{
sal_Bool bBool = sal_False;
@@ -671,7 +829,7 @@ sal_Bool PPTWriter::ImplCreateDocument()
nFlags |= 1;
}
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsEndless" ) ) ) ) // muesste eigendlich heissen IsNotEndless !=)"§()&
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsEndless" ) ) ) ) // muesste eigendlich heissen IsNotEndless !=)"�()&
{
sal_Bool bBool = sal_False;
mAny >>= bBool;
@@ -685,18 +843,7 @@ sal_Bool PPTWriter::ImplCreateDocument()
if ( !bBool )
nFlags |= 0x11;
}
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsMouseVisible" ) ) ) )
-// {
-// }
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "PageRange" ) ) ) )
-// {
-// }
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "StartWithNavigator" ) ) ) )
-// {
-// }
-// if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "UsePen" ) ) ) )
-// {
-// }
+
mpPptEscherEx->AddAtom( 80, EPP_SSDocInfoAtom, 1 );
*mpStrm << nPenColor << nRestartTime << nStartSlide << nEndSlide;
@@ -766,16 +913,13 @@ sal_Bool PPTWriter::ImplCreateDocument()
if ( aXName.is() )
{
::rtl::OUString aSlideName( aXName->getName() );
- sal_uInt32 nPageNumber = 0;
- for ( ::rtl::OUString* pSlideName = (::rtl::OUString*)maSlideNameList.First();
- pSlideName;
- pSlideName = (::rtl::OUString*)maSlideNameList.Next(), nPageNumber++ )
+ std::vector<rtl::OUString>::const_iterator pIter = std::find(
+ maSlideNameList.begin(),maSlideNameList.end(),aSlideName);
+
+ if (pIter != maSlideNameList.end())
{
- if ( *pSlideName == aSlideName )
- {
- *mpStrm << (sal_uInt32)( nPageNumber + 0x100 ); // unique slide id
- break;
- }
+ sal_uInt32 nPageNumber = pIter - maSlideNameList.begin();
+ *mpStrm << (sal_uInt32)( nPageNumber + 0x100 ); // unique slide id
}
}
}
@@ -804,8 +948,7 @@ sal_Bool PPTWriter::ImplCreateDocument()
sal_Bool PPTWriter::ImplCreateHyperBlob( SvMemoryStream& rStrm )
{
sal_uInt32 nCurrentOfs, nParaOfs, nParaCount = 0;
-// SfxOlePropertySection does this...
-// rStrm << (sal_uInt32)0x41; // property type VT_BLOB
+
nParaOfs = rStrm.Tell();
rStrm << (sal_uInt32)0; // property size
rStrm << (sal_uInt32)0; // property count
@@ -883,184 +1026,10 @@ sal_Bool PPTWriter::ImplCreateHyperBlob( SvMemoryStream& rStrm )
return sal_True;
}
-PHLayout& PPTWriter::ImplGetLayout( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const
-{
- ::com::sun::star::uno::Any aAny;
- sal_Int16 nLayout = 20;
- if ( GetPropertyValue( aAny, rXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Layout" ) ) ), sal_True )
- aAny >>= nLayout;
-
- if ( ( nLayout >= 21 ) && ( nLayout <= 26 ) ) // NOTES _> HANDOUT6
- nLayout = 20;
- if ( ( nLayout >= 27 ) && ( nLayout <= 30 ) ) // VERTICAL LAYOUT
- nLayout -= 6;
- else if ( nLayout > 30 )
- nLayout = 20;
- return pPHLayout[ nLayout ];
-}
-
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplCreateMaster( sal_uInt32 nPageNum )
-{
- if ( !ImplGetPageByIndex( nPageNum, MASTER ) )
- return sal_False;
- ImplSetCurrentStyleSheet( nPageNum );
-
- if ( !ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) ) ) // Backgroundshape laden
- return sal_False;
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet;
- if ( !( mAny >>= aXBackgroundPropSet ) )
- return sal_False;
-
- sal_uInt32 nFillColor = 0xffffff;
- sal_uInt32 nFillBackColor = 0x000000;
-
- ::com::sun::star::drawing::FillStyle aFS = ::com::sun::star::drawing::FillStyle_NONE;
- if ( ImplGetPropertyValue( aXBackgroundPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "FillStyle" ) ) ) )
- mAny >>= aFS;
- switch ( aFS )
- {
- case ::com::sun::star::drawing::FillStyle_GRADIENT :
- {
- if ( ImplGetPropertyValue( aXBackgroundPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "FillGradient" ) ) ) )
- {
- nFillColor = EscherPropertyContainer::GetGradientColor( (::com::sun::star::awt::Gradient*)mAny.getValue(), 0 );
- nFillBackColor = EscherPropertyContainer::GetGradientColor( (::com::sun::star::awt::Gradient*)mAny.getValue(), 1 );
- }
- }
- break;
-
- case ::com::sun::star::drawing::FillStyle_SOLID :
- {
- if ( ImplGetPropertyValue( aXBackgroundPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "FillColor" ) ) ) )
- {
- nFillColor = mpPptEscherEx->GetColor( *((sal_uInt32*)mAny.getValue()) );
- nFillBackColor = nFillColor ^ 0xffffff;
- }
- }
- break;
-
- default:
- break;
- }
-
- mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_MainMaster | nPageNum, mpStrm->Tell() );
- mpPptEscherEx->OpenContainer( EPP_MainMaster );
- mpPptEscherEx->AddAtom( 24, EPP_SlideAtom, 2 );
- *mpStrm << (sal_Int32)EPP_LAYOUT_TITLEANDBODYSLIDE // slide layout -> title and body slide
- << (sal_uInt8)1 << (sal_uInt8)2 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0 // placeholderID
- << (sal_uInt32)0 // master ID ( ist gleich null bei einer masterpage )
- << (sal_uInt32)0 // notes ID ( ist gleich null wenn keine notizen vorhanden )
- << (sal_uInt16)0 // Bit 1: Follow master objects, Bit 2: Follow master scheme, Bit 3: Follow master background
- << (sal_uInt16)0; // padword
-
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xff0000 << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x00ffff << (sal_uInt32)0x0099ff << (sal_uInt32)0xffff00 << (sal_uInt32)0x0000ff << (sal_uInt32)0x969696;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xccffff << (sal_uInt32)0x000000 << (sal_uInt32)0x336666 << (sal_uInt32)0x008080 << (sal_uInt32)0x339933 << (sal_uInt32)0x000080 << (sal_uInt32)0xcc3300 << (sal_uInt32)0x66ccff;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x333333 << (sal_uInt32)0x000000 << (sal_uInt32)0xdddddd << (sal_uInt32)0x808080 << (sal_uInt32)0x4d4d4d << (sal_uInt32)0xeaeaea;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x66ccff << (sal_uInt32)0xff0000 << (sal_uInt32)0xcc00cc << (sal_uInt32)0xc0c0c0;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0xc0c0c0 << (sal_uInt32)0xff6600 << (sal_uInt32)0x0000ff << (sal_uInt32)0x009900;
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 6 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0xff9933 << (sal_uInt32)0xccff99 << (sal_uInt32)0xcc00cc << (sal_uInt32)0xb2b2b2;
-
- for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
- {
- if ( nInstance == EPP_TEXTTYPE_notUsed )
- continue;
-
- // the auto color is dependent to the page background,so we have to set a page that is in the right context
- if ( nInstance == EPP_TEXTTYPE_Notes )
- ImplGetPageByIndex( 0, NOTICE );
- else
- ImplGetPageByIndex( 0, MASTER );
-
- mpPptEscherEx->BeginAtom();
-
- sal_Bool bFirst = sal_True;
- sal_Bool bSimpleText = sal_False;
-
- *mpStrm << (sal_uInt16)5; // paragraph count
-
- for ( sal_uInt16 nLev = 0; nLev < 5; nLev++ )
- {
- if ( nInstance >= EPP_TEXTTYPE_CenterBody )
- {
- bFirst = sal_False;
- bSimpleText = sal_True;
- *mpStrm << nLev;
- }
- mpStyleSheet->mpParaSheet[ nInstance ]->Write( *mpStrm, mpPptEscherEx, nLev, bFirst, bSimpleText, mXPagePropSet );
- mpStyleSheet->mpCharSheet[ nInstance ]->Write( *mpStrm, mpPptEscherEx, nLev, bFirst, bSimpleText, mXPagePropSet );
- bFirst = sal_False;
- }
- mpPptEscherEx->EndAtom( EPP_TxMasterStyleAtom, 0, nInstance );
- }
- ImplGetPageByIndex( nPageNum, MASTER );
-
- EscherSolverContainer aSolverContainer;
-
- mpPptEscherEx->OpenContainer( EPP_PPDrawing );
- mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
-
- mpPptEscherEx->EnterGroup(0,0);
- ImplWritePage( pPHLayout[ 0 ], aSolverContainer, MASTER, sal_True ); // Die Shapes der Seite werden im PPT Dok. erzeugt
- mpPptEscherEx->LeaveGroup();
-
- ImplWriteBackground( aXBackgroundPropSet );
-
- aSolverContainer.WriteSolver( *mpStrm );
-
- mpPptEscherEx->CloseContainer(); // ESCHER_DgContainer
- mpPptEscherEx->CloseContainer(); // EPP_Drawing
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 1 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
-
- if ( aBuExMasterStream.Tell() )
- {
- ImplProgTagContainer( mpStrm, &aBuExMasterStream );
- }
- mpPptEscherEx->CloseContainer(); // EPP_MainMaster
- return sal_True;
-};
-
// ---------------------------------------------------------------------------------------------
sal_Bool PPTWriter::ImplCreateMainNotes()
{
- if ( !ImplGetPageByIndex( 0, NOTICE ) )
- return sal_False;
- ImplSetCurrentStyleSheet( 0 );
-
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPageTarget >
- aXMasterPageTarget( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
-
- if ( !aXMasterPageTarget.is() )
- return sal_False;
-
- mXDrawPage = aXMasterPageTarget->getMasterPage();
- if ( !mXDrawPage.is() )
- return sal_False;
-
- mXPropSet = ::com::sun::star::uno::Reference<
- ::com::sun::star::beans::XPropertySet >
- ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXPropSet.is() )
- return sal_False;
-
- mXShapes = ::com::sun::star::uno::Reference<
- ::com::sun::star::drawing::XShapes >
- ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXShapes.is() )
- return sal_False;
-
EscherSolverContainer aSolverContainer;
mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_MainNotes, mpStrm->Tell() );
@@ -1072,20 +1041,20 @@ sal_Bool PPTWriter::ImplCreateMainNotes()
mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
mpPptEscherEx->EnterGroup(0,0);
- ImplWritePage( pPHLayout[ 20 ], aSolverContainer, NOTICE, sal_True );
+ ImplWritePage( GetLayout( 20 ), aSolverContainer, NOTICE, sal_True );
mpPptEscherEx->LeaveGroup();
mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
mpPptEscherEx->AddShape( ESCHER_ShpInst_Rectangle, 0xc00 );
EscherPropertyContainer aPropOpt;
- aPropOpt.AddOpt( ESCHER_Prop_fillColor, 0xffffff ); // stock valued fill color
+ aPropOpt.AddOpt( ESCHER_Prop_fillColor, 0xffffff ); // stock valued fill color
aPropOpt.AddOpt( ESCHER_Prop_fillBackColor, 0 );
aPropOpt.AddOpt( ESCHER_Prop_fillRectRight, 0x68bdde );
aPropOpt.AddOpt( ESCHER_Prop_fillRectBottom, 0x8b9f8e );
aPropOpt.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x120012 );
aPropOpt.AddOpt( ESCHER_Prop_fNoLineDrawDash, 0 );
aPropOpt.AddOpt( ESCHER_Prop_bWMode, ESCHER_wDontShow );
- aPropOpt.AddOpt( ESCHER_Prop_fBackground, 0x10001 ); // if true, this is the background shape
+ aPropOpt.AddOpt( ESCHER_Prop_fBackground, 0x10001 ); // if true, this is the background shape
aPropOpt.Commit( *mpStrm );
mpPptEscherEx->CloseContainer(); // ESCHER_SpContainer
@@ -1119,7 +1088,7 @@ static rtl::OUString getInitials( const rtl::OUString& rName )
// take letter
if( nLength )
{
- sInitials += rtl::OUString( *pStr );
+ sInitials += rtl::OUString( *pStr );
nLength--; pStr++;
}
@@ -1144,7 +1113,7 @@ void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStr
while( xAnnotationEnumeration->hasMoreElements() )
{
- EscherExContainer aComment10( rBinaryTagData10Atom, EPP_Comment10 );
+ EscherExContainer aComment10( rBinaryTagData10Atom, EPP_Comment10 );
{
uno::Reference< office::XAnnotation > xAnnotation( xAnnotationEnumeration->nextElement() );
@@ -1170,7 +1139,7 @@ void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStr
rBinaryTagData10Atom << nIndex++
<< aDateTime.Year
<< aDateTime.Month
- << aDateTime.Day // todo: day of week
+ << aDateTime.Day // todo: day of week
<< aDateTime.Day
<< aDateTime.Hours
<< aDateTime.Minutes
@@ -1188,462 +1157,8 @@ void ImplExportComments( uno::Reference< drawing::XDrawPage > xPage, SvMemoryStr
// ---------------------------------------------------------------------------------------------
-sal_Bool PPTWriter::ImplCreateSlide( sal_uInt32 nPageNum )
+void PPTWriter::ImplWriteNotes( sal_uInt32 nPageNum )
{
- ::com::sun::star::uno::Any aAny;
-
- if ( !ImplGetPageByIndex( nPageNum, NORMAL ) )
- return sal_False;
- sal_uInt32 nMasterID = ImplGetMasterIndex( NORMAL );
- ImplSetCurrentStyleSheet( nMasterID );
- nMasterID |= 0x80000000;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet;
- sal_Bool bHasBackground = GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) );
- if ( bHasBackground )
- bHasBackground = ( aAny >>= aXBackgroundPropSet );
-
- sal_uInt16 nMode = 7; // Bit 1: Follow master objects, Bit 2: Follow master scheme, Bit 3: Follow master background
- if ( bHasBackground )
- nMode &=~4;
-
-/* sj: Don't know what's IsBackgroundVisible for, have to ask cl
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundVisible" ) ) ) )
- {
- sal_Bool bBackgroundVisible;
- if ( aAny >>= bBackgroundVisible )
- {
- if ( bBackgroundVisible )
- nMode &= ~4;
- }
- }
-*/
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundObjectsVisible" ) ) ) )
- {
- sal_Bool bBackgroundObjectsVisible = sal_False;
- if ( aAny >>= bBackgroundObjectsVisible )
- {
- if ( !bBackgroundObjectsVisible )
- nMode &= ~1;
- }
- }
-
- const PHLayout& rLayout = ImplGetLayout( mXPagePropSet );
- mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_Slide | nPageNum, mpStrm->Tell() );
- mpPptEscherEx->OpenContainer( EPP_Slide );
- mpPptEscherEx->AddAtom( 24, EPP_SlideAtom, 2 );
- *mpStrm << rLayout.nLayout;
- mpStrm->Write( rLayout.nPlaceHolder, 8 ); // placeholderIDs ( 8Stueck )
- *mpStrm << (sal_uInt32)nMasterID // master ID ( ist gleich 0x80000000 bei einer masterpage )
- << (sal_uInt32)nPageNum + 0x100 // notes ID ( ist gleich null wenn keine notizen vorhanden )
- << nMode
- << (sal_uInt16)0; // padword
-
- mnDiaMode = 0;
- sal_Bool bVisible = sal_True;
- ::com::sun::star::presentation::FadeEffect eFe = ::com::sun::star::presentation::FadeEffect_NONE;
-
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Visible" ) ) ) )
- aAny >>= bVisible;
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Change" ) ) ) )
- {
- switch ( *(sal_Int32*)aAny.getValue() )
- {
- case 1 : // automatisch
- mnDiaMode++;
- case 2 : // halbautomatisch
- mnDiaMode++;
- default :
- case 0 : // manuell
- break;
- }
- }
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Effect" ) ) ) )
- aAny >>= eFe;
-
- sal_uInt32 nSoundRef = 0;
- sal_Bool bIsSound = sal_False;
- sal_Bool bStopSound = sal_False;
- sal_Bool bLoopSound = sal_False;
-
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Sound" ) ) ) )
- {
- rtl::OUString aSoundURL;
- if ( aAny >>= aSoundURL )
- {
- nSoundRef = maSoundCollection.GetId( aSoundURL );
- bIsSound = sal_True;
- }
- else
- aAny >>= bStopSound;
- }
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "LoopSound" ) ) ) )
- aAny >>= bLoopSound;
-
-
- sal_Bool bNeedsSSSlideInfoAtom = ( bVisible == sal_False )
- || ( mnDiaMode == 2 )
- || ( bIsSound )
- || ( bStopSound )
- || ( eFe != ::com::sun::star::presentation::FadeEffect_NONE );
- if ( bNeedsSSSlideInfoAtom )
- {
- sal_uInt8 nDirection = 0;
- sal_uInt8 nTransitionType = 0;
- sal_uInt16 nBuildFlags = 1; // advange by mouseclick
- sal_Int32 nSlideTime = 0; // muss noch !!!
- sal_uInt8 nSpeed = 1;
-
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Speed" ) ) ) )
- {
- ::com::sun::star::presentation::AnimationSpeed aAs;
- aAny >>= aAs;
- nSpeed = (sal_uInt8)aAs;
- }
- sal_Int16 nTT = 0, nTST = 0;
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TransitionType" ) ) )
- && ( aAny >>= nTT ) )
- {
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TransitionSubtype" ) ) )
- && ( aAny >>= nTST ) )
- {
- switch( nTT )
- {
- case animations::TransitionType::FADE :
- {
- if ( nTST == animations::TransitionSubType::CROSSFADE )
- nTransitionType = PPT_TRANSITION_TYPE_SMOOTHFADE;
- else if ( nTST == animations::TransitionSubType::FADEOVERCOLOR )
- nTransitionType = PPT_TRANSITION_TYPE_FADE;
- }
- break;
- case PPT_TRANSITION_TYPE_COMB :
- {
- nTransitionType = PPT_TRANSITION_TYPE_COMB;
- if ( nTST == animations::TransitionSubType::COMBVERTICAL )
- nDirection++;
- }
- break;
- case animations::TransitionType::PUSHWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_PUSH;
- switch( nTST )
- {
- case animations::TransitionSubType::FROMRIGHT: nDirection = 0; break;
- case animations::TransitionSubType::FROMBOTTOM: nDirection = 1; break;
- case animations::TransitionSubType::FROMLEFT: nDirection = 2; break;
- case animations::TransitionSubType::FROMTOP: nDirection = 3; break;
- }
- }
- break;
- case animations::TransitionType::PINWHEELWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_WHEEL;
- switch( nTST )
- {
- case animations::TransitionSubType::ONEBLADE: nDirection = 1; break;
- case animations::TransitionSubType::TWOBLADEVERTICAL : nDirection = 2; break;
- case animations::TransitionSubType::THREEBLADE : nDirection = 3; break;
- case animations::TransitionSubType::FOURBLADE: nDirection = 4; break;
- case animations::TransitionSubType::EIGHTBLADE: nDirection = 8; break;
- }
- }
- break;
- case animations::TransitionType::FANWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_WEDGE;
- }
- break;
- case animations::TransitionType::ELLIPSEWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_CIRCLE;
- }
- break;
- case animations::TransitionType::FOURBOXWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_PLUS;
- }
- break;
- case animations::TransitionType::IRISWIPE :
- {
- nTransitionType = PPT_TRANSITION_TYPE_DIAMOND;
- }
- break;
- }
- }
- }
- if ( !nTransitionType )
- {
- switch ( eFe )
- {
- default :
- case ::com::sun::star::presentation::FadeEffect_RANDOM :
- nTransitionType = PPT_TRANSITION_TYPE_RANDOM;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_HORIZONTAL_STRIPES :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_VERTICAL_STRIPES :
- nTransitionType = PPT_TRANSITION_TYPE_BLINDS;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_VERTICAL_CHECKERBOARD :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_HORIZONTAL_CHECKERBOARD :
- nTransitionType = PPT_TRANSITION_TYPE_CHECKER;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_UPPERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_UPPERRIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_LOWERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_LOWERRIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_TOP :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_LEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_BOTTOM :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_MOVE_FROM_RIGHT :
- nTransitionType = PPT_TRANSITION_TYPE_COVER;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_DISSOLVE :
- nTransitionType = PPT_TRANSITION_TYPE_DISSOLVE;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_VERTICAL_LINES :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_HORIZONTAL_LINES :
- nTransitionType = PPT_TRANSITION_TYPE_RANDOM_BARS;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_CLOSE_HORIZONTAL :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_OPEN_HORIZONTAL :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_CLOSE_VERTICAL :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_OPEN_VERTICAL :
- nTransitionType = PPT_TRANSITION_TYPE_SPLIT;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_UPPERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_UPPERRIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_LOWERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_LOWERRIGHT :
- nDirection += 4;
- nTransitionType = PPT_TRANSITION_TYPE_STRIPS;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_LOWERRIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_LOWERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_UPPERRIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_UPPERLEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_BOTTOM :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_RIGHT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_TOP :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_UNCOVER_TO_LEFT :
- nTransitionType = PPT_TRANSITION_TYPE_PULL;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_TOP :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_LEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_BOTTOM :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_RIGHT :
- nTransitionType = PPT_TRANSITION_TYPE_WIPE;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_ROLL_FROM_TOP :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_ROLL_FROM_LEFT :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_ROLL_FROM_BOTTOM :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_ROLL_FROM_RIGHT :
- nTransitionType = PPT_TRANSITION_TYPE_WIPE;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_FADE_TO_CENTER :
- nDirection++;
- case ::com::sun::star::presentation::FadeEffect_FADE_FROM_CENTER :
- nTransitionType = PPT_TRANSITION_TYPE_ZOOM;
- break;
-
- case ::com::sun::star::presentation::FadeEffect_NONE :
- nDirection = 2;
- break;
- }
- }
- if ( mnDiaMode == 2 ) // automatic ?
- nBuildFlags |= 0x400;
- if ( bVisible == sal_False )
- nBuildFlags |= 4;
- if ( bIsSound )
- nBuildFlags |= 16;
- if ( bLoopSound )
- nBuildFlags |= 64;
- if ( bStopSound )
- nBuildFlags |= 256;
-
- if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Duration" ) ) ) )// duration of this slide
- nSlideTime = *(sal_Int32*)aAny.getValue() << 10; // in ticks
-
-
- mpPptEscherEx->AddAtom( 16, EPP_SSSlideInfoAtom );
- *mpStrm << nSlideTime // standtime in ticks
- << nSoundRef
- << nDirection
- << nTransitionType
- << nBuildFlags
- << nSpeed
- << (sal_uInt8)0 << (sal_uInt8)0 << (sal_uInt8)0;
- }
-
- ImplCreateHeaderFooters( mXPagePropSet );
-
- EscherSolverContainer aSolverContainer;
- mpPptEscherEx->OpenContainer( EPP_PPDrawing );
- mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
- mpPptEscherEx->EnterGroup(0,0);
- ImplWritePage( rLayout, aSolverContainer, NORMAL, sal_False, nPageNum ); // Die Shapes der Seite werden im PPT Dok. erzeugt
- mpPptEscherEx->LeaveGroup();
-
- if ( bHasBackground )
- ImplWriteBackground( aXBackgroundPropSet );
- else
- {
- mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
- mpPptEscherEx->AddShape( ESCHER_ShpInst_Rectangle, 0xc00 ); // Flags: Connector | Background | HasSpt
- EscherPropertyContainer aPropOpt;
- aPropOpt.AddOpt( ESCHER_Prop_fillRectRight, PPTtoEMU( maDestPageSize.Width ) );
- aPropOpt.AddOpt( ESCHER_Prop_fillRectBottom, PPTtoEMU( maDestPageSize.Width ) );
- aPropOpt.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x120012 );
- aPropOpt.AddOpt( ESCHER_Prop_fNoLineDrawDash, 0x80000 );
- aPropOpt.AddOpt( ESCHER_Prop_bWMode, ESCHER_wDontShow );
- aPropOpt.AddOpt( ESCHER_Prop_fBackground, 0x10001 ); // if true, this is the background shape
- aPropOpt.Commit( *mpStrm );
- mpPptEscherEx->CloseContainer(); // ESCHER_SpContainer
- }
-
- aSolverContainer.WriteSolver( *mpStrm );
-
- mpPptEscherEx->CloseContainer(); // ESCHER_DgContainer
- mpPptEscherEx->CloseContainer(); // EPP_Drawing
- mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 1 );
- *mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
-
- SvMemoryStream aBinaryTagData10Atom;
- ImplExportComments( mXDrawPage, aBinaryTagData10Atom );
- if ( mbUseNewAnimations )
- {
- SvMemoryStream amsofbtAnimGroup;
- ppt::AnimationExporter aExporter( aSolverContainer, maSoundCollection );
- aExporter.doexport( mXDrawPage, amsofbtAnimGroup );
- sal_uInt32 nmsofbtAnimGroupSize = amsofbtAnimGroup.Tell();
- if ( nmsofbtAnimGroupSize )
- {
- {
- EscherExAtom aMagic2( aBinaryTagData10Atom, 0x2eeb );
- aBinaryTagData10Atom << (sal_uInt32)0x01c45df9
- << (sal_uInt32)0xe1471b30;
- }
- {
- EscherExAtom aMagic( aBinaryTagData10Atom, 0x2b00 );
- aBinaryTagData10Atom << (sal_uInt32)0;
- }
- aBinaryTagData10Atom.Write( amsofbtAnimGroup.GetData(), amsofbtAnimGroup.Tell() );
- {
- EscherExContainer aMagic2( aBinaryTagData10Atom, 0x2b02 );
- }
- }
- }
- if ( aBinaryTagData10Atom.Tell() )
- {
- EscherExContainer aProgTags ( *mpStrm, EPP_ProgTags );
- EscherExContainer aProgBinaryTag( *mpStrm, EPP_ProgBinaryTag );
- {
- EscherExAtom aCString( *mpStrm, EPP_CString );
- *mpStrm << (sal_uInt32)0x5f005f
- << (sal_uInt32)0x50005f
- << (sal_uInt32)0x540050
- << (sal_uInt16)0x31
- << (sal_uInt16)0x30;
- }
- {
- EscherExAtom aBinaryTagData( *mpStrm, EPP_BinaryTagData );
- mpStrm->Write( aBinaryTagData10Atom.GetData(), aBinaryTagData10Atom.Tell() );
- }
- }
-/*
- if ( mbUseNewAnimations )
- {
- SvMemoryStream amsofbtAnimGroup;
- ppt::AnimationExporter aExporter( aSolverContainer, maSoundCollection );
- aExporter.doexport( mXDrawPage, amsofbtAnimGroup );
- sal_uInt32 nmsofbtAnimGroupSize = amsofbtAnimGroup.Tell();
- if ( nmsofbtAnimGroupSize )
- {
- EscherExContainer aProgTags ( *mpStrm, EPP_ProgTags );
- EscherExContainer aProgBinaryTag( *mpStrm, EPP_ProgBinaryTag );
- {
- EscherExAtom aCString( *mpStrm, EPP_CString );
- *mpStrm << (sal_uInt32)0x5f005f
- << (sal_uInt32)0x50005f
- << (sal_uInt32)0x540050
- << (sal_uInt16)0x31
- << (sal_uInt16)0x30;
- }
- {
- EscherExAtom aBinaryTagData( *mpStrm, EPP_BinaryTagData );
- {
- {
- EscherExAtom aMagic2( *mpStrm, 0x2eeb );
- *mpStrm << (sal_uInt32)0x01c45df9
- << (sal_uInt32)0xe1471b30;
- }
- {
- EscherExAtom aMagic( *mpStrm, 0x2b00 );
- *mpStrm << (sal_uInt32)0;
- }
- }
- mpStrm->Write( amsofbtAnimGroup.GetData(), amsofbtAnimGroup.Tell() );
- {
- EscherExContainer aMagic2( *mpStrm, 0x2b02 );
- }
- }
- }
- }
-*/
- mpPptEscherEx->CloseContainer(); // EPP_Slide
- return sal_True;
-};
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplCreateNotes( sal_uInt32 nPageNum )
-{
- if ( !ImplGetPageByIndex( nPageNum, NOTICE ) )
- return sal_False;
- ImplSetCurrentStyleSheet( ImplGetMasterIndex( NORMAL ) );
-
-
mpPptEscherEx->PtReplaceOrInsert( EPP_Persist_Notes | nPageNum, mpStrm->Tell() );
mpPptEscherEx->OpenContainer( EPP_Notes );
mpPptEscherEx->AddAtom( 8, EPP_NotesAtom, 1 );
@@ -1659,7 +1174,7 @@ sal_Bool PPTWriter::ImplCreateNotes( sal_uInt32 nPageNum )
mpPptEscherEx->OpenContainer( ESCHER_DgContainer );
mpPptEscherEx->EnterGroup(0,0);
- ImplWritePage( pPHLayout[ 20 ], aSolverContainer, NOTICE, sal_False ); // Die Shapes der Seite werden im PPT Dok. erzeugt
+ ImplWritePage( GetLayout( 20 ), aSolverContainer, NOTICE, sal_False ); // Die Shapes der Seite werden im PPT Dok. erzeugt
mpPptEscherEx->LeaveGroup();
mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
@@ -1683,7 +1198,6 @@ sal_Bool PPTWriter::ImplCreateNotes( sal_uInt32 nPageNum )
mpPptEscherEx->AddAtom( 32, EPP_ColorSchemeAtom, 0, 1 );
*mpStrm << (sal_uInt32)0xffffff << (sal_uInt32)0x000000 << (sal_uInt32)0x808080 << (sal_uInt32)0x000000 << (sal_uInt32)0x99cc00 << (sal_uInt32)0xcc3333 << (sal_uInt32)0xffcccc << (sal_uInt32)0xb2b2b2;
mpPptEscherEx->CloseContainer(); // EPP_Notes
- return sal_True;
};
void PPTWriter::ImplWriteBackground( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet )
@@ -1731,7 +1245,7 @@ void PPTWriter::ImplWriteBackground( ::com::sun::star::uno::Reference< ::com::su
nFillColor = mpPptEscherEx->GetColor( *((sal_uInt32*)mAny.getValue()) );
nFillBackColor = nFillColor ^ 0xffffff;
}
- } // PASSTHROUGH INTENDED
+ } // PASSTHROUGH INTENDED
case ::com::sun::star::drawing::FillStyle_NONE :
default:
aPropOpt.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x120012 );
@@ -1748,18 +1262,18 @@ void PPTWriter::ImplWriteBackground( ::com::sun::star::uno::Reference< ::com::su
mpPptEscherEx->CloseContainer(); // ESCHER_SpContainer
}
-void PPTWriter::ImplWriteVBA( SvMemoryStream* pVBA )
+void PPTWriter::ImplWriteVBA()
{
- if ( pVBA )
+ if ( mpVBA )
{
- pVBA->Seek( STREAM_SEEK_TO_END );
- sal_uInt32 nLen = pVBA->Tell();
+ mpVBA->Seek( STREAM_SEEK_TO_END );
+ sal_uInt32 nLen = mpVBA->Tell();
if ( nLen > 8 )
{
nLen -= 8;
mnVBAOleOfs = mpStrm->Tell();
mpPptEscherEx->BeginAtom();
- mpStrm->Write( (sal_Int8*)pVBA->GetData() + 8, nLen );
+ mpStrm->Write( (sal_Int8*)mpVBA->GetData() + 8, nLen );
mpPptEscherEx->EndAtom( EPP_ExOleObjStg, 0, 1 );
}
}
@@ -1767,11 +1281,11 @@ void PPTWriter::ImplWriteVBA( SvMemoryStream* pVBA )
// ---------------------------------------------------------------------------------------------
-void PPTWriter::ImplWriteOLE( sal_uInt32 nCnvrtFlags )
+void PPTWriter::ImplWriteOLE( )
{
PPTExOleObjEntry* pPtr;
- SvxMSExportOLEObjects aOleExport( nCnvrtFlags );
+ SvxMSExportOLEObjects aOleExport( mnCnvrtFlags );
for ( pPtr = (PPTExOleObjEntry*)maExOleObj.First(); pPtr;
pPtr = (PPTExOleObjEntry*)maExOleObj.Next() )
@@ -1796,17 +1310,17 @@ void PPTWriter::ImplWriteOLE( sal_uInt32 nCnvrtFlags )
SvMemoryStream aStream;
SvStorageRef xCleanStorage( new SvStorage( sal_False, aStream ) );
xTempStorage->CopyTo( xCleanStorage );
- // SJ: #99809# create a dummy content stream, the dummy content is necessary for ppt, but not for
+ // create a dummy content stream, the dummy content is necessary for ppt, but not for
// doc files, so we can't share code.
SotStorageStreamRef xStm = xCleanStorage->OpenSotStream( aPersistStream, STREAM_STD_READWRITE );
- *xStm << (sal_uInt32)0 // no ClipboardId
- << (sal_uInt32)4 // no target device
- << (sal_uInt32)1 // aspect ratio
- << (sal_Int32)-1 // L-Index
- << (sal_uInt32)0 // Advanced Flags
- << (sal_uInt32)0 // compression
- << (sal_uInt32)0 // Size
- << (sal_uInt32)0 // "
+ *xStm << (sal_uInt32)0 // no ClipboardId
+ << (sal_uInt32)4 // no target device
+ << (sal_uInt32)1 // aspect ratio
+ << (sal_Int32)-1 // L-Index
+ << (sal_uInt32)0 // Advanced Flags
+ << (sal_uInt32)0 // compression
+ << (sal_uInt32)0 // Size
+ << (sal_uInt32)0 // "
<< (sal_uInt32)0;
pStrm = xCleanStorage->CreateMemoryStream();
}
@@ -1832,13 +1346,7 @@ void PPTWriter::ImplWriteOLE( sal_uInt32 nCnvrtFlags )
mpPptEscherEx->BeginAtom();
pStrm->Seek( STREAM_SEEK_TO_END );
sal_uInt32 npStrmSize = pStrm->Tell();
- *mpStrm << npStrmSize; // uncompressed size
-
-#ifdef DBG_EXTRACTOLEOBJECTS
- SvFileStream aOut( String::CreateFromAscii( "D:\\OUT.OLE" ), STREAM_TRUNC | STREAM_WRITE );
- pStrm->Seek( 0 );
- aOut.Write( pStrm->GetData(), npStrmSize );
-#endif
+ *mpStrm << npStrmSize; // uncompressed size
pStrm->Seek( 0 );
ZCodec aZCodec( 0x8000, 0x8000 );
@@ -1862,7 +1370,6 @@ sal_Bool PPTWriter::ImplWriteAtomEnding()
#define EPP_LastViewTypeOutlineView 2
#define EPP_LastViewTypeNotes 3
-
sal_uInt32 i, nPos, nOfs, nPersistOfs = mpStrm->Tell();
sal_uInt32 nPersistEntrys = 0;
*mpStrm << (sal_uInt32)0 << (sal_uInt32)0 << (sal_uInt32)0; // Record Header und ersten Eintrag ueberspringen
@@ -1966,488 +1473,6 @@ sal_Bool PPTWriter::ImplWriteAtomEnding()
return sal_True;
}
-// ---------------------------------------------------------------------------------------------
-
-PPTExCharSheet::PPTExCharSheet( int nInstance )
-{
- sal_uInt16 nFontHeight = 24;
-
- for ( int nDepth = 0; nDepth < 5; nDepth++ )
- {
- PPTExCharLevel& rLev = maCharLevel[ nDepth ];
- switch ( nInstance )
- {
- case EPP_TEXTTYPE_Title :
- case EPP_TEXTTYPE_CenterTitle :
- nFontHeight = 44;
- break;
- case EPP_TEXTTYPE_Body :
- case EPP_TEXTTYPE_CenterBody :
- case EPP_TEXTTYPE_HalfBody :
- case EPP_TEXTTYPE_QuarterBody :
- {
- switch ( nDepth )
- {
- case 0 : nFontHeight = 32; break;
- case 1 : nFontHeight = 28; break;
- case 2 : nFontHeight = 24; break;
- default :nFontHeight = 20; break;
- }
- }
- break;
- case EPP_TEXTTYPE_Notes :
- nFontHeight = 12;
- break;
- case EPP_TEXTTYPE_notUsed :
- case EPP_TEXTTYPE_Other :
- nFontHeight = 24;
- break;
- }
- rLev.mnFlags = 0;
- rLev.mnFont = 0;
- rLev.mnAsianOrComplexFont = 0xffff;
- rLev.mnFontHeight = nFontHeight;
- rLev.mnFontColor = 0;
- rLev.mnEscapement = 0;
- }
-}
-
-
-void PPTExCharSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
- FontCollection& rFontCollection, int nLevel )
-{
- PortionObj aPortionObj( rXPropSet, rFontCollection );
-
- PPTExCharLevel& rLev = maCharLevel[ nLevel ];
-
- if ( aPortionObj.meCharColor == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnFontColor = aPortionObj.mnCharColor;
- if ( aPortionObj.meCharEscapement == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnEscapement = aPortionObj.mnCharEscapement;
- if ( aPortionObj.meCharHeight == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnFontHeight = aPortionObj.mnCharHeight;
- if ( aPortionObj.meFontName == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnFont = aPortionObj.mnFont;
- if ( aPortionObj.meAsianOrComplexFont == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnAsianOrComplexFont = aPortionObj.mnAsianOrComplexFont;
- rLev.mnFlags = aPortionObj.mnCharAttr;
-}
-
-void PPTExCharSheet::Write( SvStream& rSt, PptEscherEx*, sal_uInt16 nLev, sal_Bool, sal_Bool bSimpleText,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet )
-{
- const PPTExCharLevel& rLev = maCharLevel[ nLev ];
-
- sal_uInt32 nCharFlags = 0xefffff;
- if ( bSimpleText )
- nCharFlags = 0x7ffff;
-
- rSt << nCharFlags
- << rLev.mnFlags
- << rLev.mnFont;
-
- sal_uInt32 nFontColor = rLev.mnFontColor;
- if ( nFontColor == COL_AUTO )
- {
- sal_Bool bIsDark = sal_False;
- ::com::sun::star::uno::Any aAny;
- if ( PropValue::GetPropertyValue( aAny, rPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundDark" ) ), sal_True ) )
- aAny >>= bIsDark;
- nFontColor = bIsDark ? 0xffffff : 0x000000;
- }
- nFontColor &= 0xffffff;
- nFontColor |= 0xfe000000;
- if ( bSimpleText )
- {
- rSt << rLev.mnFontHeight
- << nFontColor;
- }
- else
- {
- rSt << rLev.mnAsianOrComplexFont
- << (sal_uInt16)0xffff // unbekannt
- << (sal_uInt16)0xffff // unbekannt
- << rLev.mnFontHeight
- << nFontColor
- << rLev.mnEscapement;
- }
-}
-
-PPTExParaSheet::PPTExParaSheet( int nInstance, sal_uInt16 nDefaultTab, PPTExBulletProvider& rProv ) :
- rBuProv ( rProv ),
- mnInstance ( nInstance )
-{
- sal_Bool bHasBullet = sal_False;
-
- sal_uInt16 nUpperDist = 0;
- sal_uInt16 nBulletChar = 0x2022;
- sal_uInt16 nBulletOfs = 0;
- sal_uInt16 nTextOfs = 0;
-
- for ( int nDepth = 0; nDepth < 5; nDepth++ )
- {
- PPTExParaLevel& rLev = maParaLevel[ nDepth ];
- switch ( nInstance )
- {
- case EPP_TEXTTYPE_Title :
- case EPP_TEXTTYPE_CenterTitle :
- break;
- case EPP_TEXTTYPE_Body :
- case EPP_TEXTTYPE_CenterBody :
- case EPP_TEXTTYPE_HalfBody :
- case EPP_TEXTTYPE_QuarterBody :
- {
- bHasBullet = sal_True;
- nUpperDist = 0x14;
- }
- break;
- case EPP_TEXTTYPE_Notes :
- nUpperDist = 0x1e;
- break;
-
-// default :
-// case EPP_TEXTTYPE_notUsed :
-// case EPP_TEXTTYPE_Other :
-// break;
- }
- switch ( nDepth )
- {
- case 0 :
- {
- nBulletChar = 0x2022;
- nBulletOfs = 0;
- nTextOfs = ( bHasBullet ) ? 0xd8 : 0;
- }
- break;
- case 1 :
- {
- nBulletChar = 0x2013;
- nBulletOfs = 0x120;
- nTextOfs = 0x1d4;
- }
- break;
- case 2 :
- {
- nBulletChar = 0x2022;
- nBulletOfs = 0x240;
- nTextOfs = 0x2d0;
- }
- break;
- case 3 :
- {
- nBulletChar = 0x2013;
- nBulletOfs = 0x360;
- nTextOfs = 0x3f0;
- }
- break;
- case 4 :
- {
- nBulletChar = 0xbb;
- nBulletOfs = 0x480;
- nTextOfs = 0x510;
- }
- break;
- }
- rLev.mbIsBullet = bHasBullet;
- rLev.mnBulletChar = nBulletChar;
- rLev.mnBulletFont = 0;
- rLev.mnBulletHeight = 100;
- rLev.mnBulletColor = 0;
- rLev.mnAdjust = 0;
- rLev.mnLineFeed = 100;
- rLev.mnLowerDist = 0;
- rLev.mnUpperDist = nUpperDist;
- rLev.mnTextOfs = nTextOfs;
- rLev.mnBulletOfs = nBulletOfs;
- rLev.mnDefaultTab = nDefaultTab;
- rLev.mnAsianSettings = 2;
- rLev.mnBiDi = 0;
-
- rLev.mbExtendedBulletsUsed = sal_False;
- rLev.mnBulletId = 0xffff;
- rLev.mnBulletStart = 0;
- rLev.mnMappedNumType = 0;
- rLev.mnNumberingType = 0;
- }
-}
-
-void PPTExParaSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
- FontCollection& rFontCollection, int nLevel, const PPTExCharLevel& rCharLevel )
-{
- ParagraphObj aParagraphObj( rXPropSet, rBuProv );
- aParagraphObj.CalculateGraphicBulletSize( rCharLevel.mnFontHeight );
- PPTExParaLevel& rLev = maParaLevel[ nLevel ];
-
- if ( aParagraphObj.meTextAdjust == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnAdjust = aParagraphObj.mnTextAdjust;
- if ( aParagraphObj.meLineSpacing == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- {
- sal_Int16 nLineSpacing = aParagraphObj.mnLineSpacing;
- if ( nLineSpacing > 0 ) // if nLinespacing is < 0 the linespacing is an absolute spacing
- {
- sal_Bool bFixedLineSpacing = sal_False;
- uno::Any aAny = rXPropSet->getPropertyValue( ::rtl::OUString(
- RTL_CONSTASCII_USTRINGPARAM(
- "FontIndependentLineSpacing" ) ) );
- if( !(aAny >>= bFixedLineSpacing) || !bFixedLineSpacing )
- {
- const FontCollectionEntry* pDesc = rFontCollection.GetById( rCharLevel.mnFont );
- if ( pDesc )
- nLineSpacing = (sal_Int16)( (double)nLineSpacing * pDesc->Scaling + 0.5 );
- }
- }
- else
- {
- if ( rCharLevel.mnFontHeight > (sal_uInt16)( ((double)-nLineSpacing) * 0.001 * 72.0 / 2.54 ) ) // 1/100mm to point
- {
- const FontCollectionEntry* pDesc = rFontCollection.GetById( rCharLevel.mnFont );
- if ( pDesc )
- nLineSpacing = (sal_Int16)( (double)100.0 * pDesc->Scaling + 0.5 );
- else
- nLineSpacing = 100;
- }
- else
- nLineSpacing = (sal_Int16)( (double)nLineSpacing / 4.40972 );
- }
- rLev.mnLineFeed = nLineSpacing;
- }
- if ( aParagraphObj.meLineSpacingBottom == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnLowerDist = aParagraphObj.mnLineSpacingBottom;
- if ( aParagraphObj.meLineSpacingTop == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnUpperDist = aParagraphObj.mnLineSpacingTop;
- if ( aParagraphObj.meForbiddenRules == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- {
- rLev.mnAsianSettings &=~1;
- if ( aParagraphObj.mbForbiddenRules )
- rLev.mnAsianSettings |= 1;
- }
- if ( aParagraphObj.meParagraphPunctation == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- {
- rLev.mnAsianSettings &=~4;
- if ( aParagraphObj.mbParagraphPunctation )
- rLev.mnAsianSettings |= 4;
- }
-
- if ( aParagraphObj.meBiDi == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- rLev.mnBiDi = aParagraphObj.mnBiDi;
-
- rLev.mbIsBullet = aParagraphObj.mbIsBullet; //( ( aParagraphObj.nBulletFlags & 1 ) != 0 );
-
- if ( !nLevel )
- {
- if ( ( aParagraphObj.meBullet == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- && aParagraphObj.bExtendedParameters )
- {
- for ( sal_Int16 i = 0; i < 5; i++ )
- {
- PPTExParaLevel& rLevel = maParaLevel[ i ];
- if ( i )
- aParagraphObj.ImplGetNumberingLevel( rBuProv, i, sal_False );
-// rLevel.mbIsBullet = ( ( aParagraphObj.nBulletFlags & 1 ) != 0 );
- rLevel.mnTextOfs = aParagraphObj.nTextOfs;
- rLevel.mnBulletOfs = (sal_uInt16)aParagraphObj.nBulletOfs;
- rLevel.mnBulletChar = aParagraphObj.cBulletId;
- FontCollectionEntry aFontDescEntry( aParagraphObj.aFontDesc.Name, aParagraphObj.aFontDesc.Family,
- aParagraphObj.aFontDesc.Pitch, aParagraphObj.aFontDesc.CharSet );
- rLevel.mnBulletFont = (sal_uInt16)rFontCollection.GetId( aFontDescEntry );
- rLevel.mnBulletHeight = aParagraphObj.nBulletRealSize;
- rLevel.mnBulletColor = aParagraphObj.nBulletColor;
-
- rLevel.mbExtendedBulletsUsed = aParagraphObj.bExtendedBulletsUsed;
- rLevel.mnBulletId = aParagraphObj.nBulletId;
- rLevel.mnNumberingType = aParagraphObj.nNumberingType;
- rLevel.mnBulletStart = aParagraphObj.nStartWith;
- rLevel.mnMappedNumType = aParagraphObj.nMappedNumType;
- }
- }
- }
-}
-
-void PPTExParaSheet::Write( SvStream& rSt, PptEscherEx*, sal_uInt16 nLev, sal_Bool, sal_Bool bSimpleText,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet )
-{
- const PPTExParaLevel& rLev = maParaLevel[ nLev ];
-
- if ( maParaLevel[ 0 ].mbExtendedBulletsUsed || maParaLevel[ 1 ].mbExtendedBulletsUsed ||
- maParaLevel[ 2 ].mbExtendedBulletsUsed || maParaLevel[ 3 ].mbExtendedBulletsUsed ||
- maParaLevel[ 4 ].mbExtendedBulletsUsed )
- {
- SvStream& rOut = rBuProv.aBuExMasterStream;
- if ( !nLev )
- {
- rOut << (sal_uInt32)( ( EPP_PST_ExtendedParagraphMasterAtom << 16 ) | ( mnInstance << 4 ) )
- << (sal_uInt32)( 5 * 16 + 2 )
- << (sal_uInt16)5; // depth
- }
- sal_uInt16 nBulletId = rLev.mnBulletId;
- if ( rLev.mnNumberingType != SVX_NUM_BITMAP )
- nBulletId = 0xffff;
- rOut << (sal_uInt32)0x03800000
- << (sal_uInt16)nBulletId
- << (sal_uInt32)rLev.mnMappedNumType
- << (sal_uInt16)rLev.mnBulletStart
- << (sal_uInt32)0;
- }
-
- sal_uInt32 nParaFlags = 0x3ffdff;
- sal_uInt16 nBulletFlags = ( rLev.mbIsBullet ) ? 0xf : 0xe;
-
- if ( nLev )
- nParaFlags &= 0x207fff;
- if ( bSimpleText )
- nParaFlags &= 0x7fff;
- sal_uInt32 nBulletColor = rLev.mnBulletColor;
- if ( nBulletColor == COL_AUTO )
- {
- sal_Bool bIsDark = sal_False;
- ::com::sun::star::uno::Any aAny;
- if ( PropValue::GetPropertyValue( aAny, rPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundDark" ) ), sal_True ) )
- aAny >>= bIsDark;
- nBulletColor = bIsDark ? 0xffffff : 0x000000;
- }
- nBulletColor &= 0xffffff;
- nBulletColor |= 0xfe000000;
- rSt << nParaFlags
- << nBulletFlags
- << rLev.mnBulletChar
- << rLev.mnBulletFont
- << rLev.mnBulletHeight
- << nBulletColor
- << rLev.mnAdjust
- << rLev.mnLineFeed
- << rLev.mnUpperDist
- << rLev.mnLowerDist
- << rLev.mnTextOfs
- << rLev.mnBulletOfs;
-
- if ( bSimpleText || nLev )
- {
- if ( nParaFlags & 0x200000 )
- rSt << rLev.mnBiDi;
- }
- else
- {
- rSt << rLev.mnDefaultTab
- << (sal_uInt16)0
- << (sal_uInt16)0
- << rLev.mnAsianSettings
- << rLev.mnBiDi;
- }
-}
-
-
-PPTExStyleSheet::PPTExStyleSheet( sal_uInt16 nDefaultTab, PPTExBulletProvider& rBuProv )
-{
- for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
- {
- mpParaSheet[ nInstance ] = ( nInstance == EPP_TEXTTYPE_notUsed ) ? NULL : new PPTExParaSheet( nInstance, nDefaultTab, rBuProv );
- mpCharSheet[ nInstance ] = ( nInstance == EPP_TEXTTYPE_notUsed ) ? NULL : new PPTExCharSheet( nInstance );
- }
-}
-
-PPTExStyleSheet::~PPTExStyleSheet()
-{
- for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
- {
- if ( nInstance == EPP_TEXTTYPE_notUsed )
- continue;
-
- delete mpParaSheet[ nInstance ];
- delete mpCharSheet[ nInstance ];
- }
-}
-
-void PPTExStyleSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
- FontCollection& rFontCollection, int nInstance, int nLevel )
-{
- if ( nInstance == EPP_TEXTTYPE_notUsed )
- return;
- mpCharSheet[ nInstance ]->SetStyleSheet( rXPropSet, rFontCollection, nLevel );
- mpParaSheet[ nInstance ]->SetStyleSheet( rXPropSet, rFontCollection, nLevel, mpCharSheet[ nInstance ]->maCharLevel[ nLevel ] );
-}
-
-sal_Bool PPTExStyleSheet::IsHardAttribute( sal_uInt32 nInstance, sal_uInt32 nLevel, PPTExTextAttr eAttr, sal_uInt32 nValue )
-{
- const PPTExParaLevel& rPara = mpParaSheet[ nInstance ]->maParaLevel[ nLevel ];
- const PPTExCharLevel& rChar = mpCharSheet[ nInstance ]->maCharLevel[ nLevel ];
-
- sal_uInt32 nFlag = 0;
-
- switch ( eAttr )
- {
- case ParaAttr_BulletOn : return ( rPara.mbIsBullet ) ? ( nValue ) ? sal_False : sal_True : ( nValue ) ? sal_True : sal_False;
- case ParaAttr_BuHardFont :
- case ParaAttr_BulletFont : return ( rPara.mnBulletFont != nValue );
- case ParaAttr_BuHardColor :
- case ParaAttr_BulletColor : return ( rPara.mnBulletColor != nValue );
- case ParaAttr_BuHardHeight :
- case ParaAttr_BulletHeight : return ( rPara.mnBulletHeight != nValue );
- case ParaAttr_BulletChar : return ( rPara.mnBulletChar != nValue );
- case ParaAttr_Adjust : return ( rPara.mnAdjust != nValue );
- case ParaAttr_LineFeed : return ( rPara.mnLineFeed != nValue );
- case ParaAttr_UpperDist : return ( rPara.mnUpperDist != nValue );
- case ParaAttr_LowerDist : return ( rPara.mnLowerDist != nValue );
- case ParaAttr_TextOfs : return ( rPara.mnTextOfs != nValue );
- case ParaAttr_BulletOfs : return ( rPara.mnBulletOfs != nValue );
- case ParaAttr_DefaultTab : return ( rPara.mnDefaultTab != nValue );
- case ParaAttr_BiDi : return ( rPara.mnBiDi != nValue );
- case CharAttr_Bold : nFlag = 1; break;
- case CharAttr_Italic : nFlag = 2; break;
- case CharAttr_Underline : nFlag = 4; break;
- case CharAttr_Shadow : nFlag = 16; break;
- case CharAttr_Strikeout : nFlag = 256; break;
- case CharAttr_Embossed : nFlag = 512; break;
- case CharAttr_Font : return ( rChar.mnFont != nValue );
- case CharAttr_AsianOrComplexFont : return ( rChar.mnAsianOrComplexFont != nValue );
- case CharAttr_Symbol : return sal_True;
- case CharAttr_FontHeight : return ( rChar.mnFontHeight != nValue );
- case CharAttr_FontColor : return ( rChar.mnFontColor != nValue );
- case CharAttr_Escapement : return ( rChar.mnEscapement != nValue );
- default:
- break;
- };
- if ( nFlag )
- {
- if ( rChar.mnFlags & nFlag )
- return ( ( nValue & nFlag ) == 0 );
- else
- return ( ( nValue & nFlag ) != 0 );
- }
- return sal_True;
-}
-
-sal_uInt32 PPTExStyleSheet::SizeOfTxCFStyleAtom() const
-{
- return 24;
-}
-
-// the TxCFStyleAtom stores the text properties that are used
-// when creating new objects in PowerPoint.
-
-void PPTExStyleSheet::WriteTxCFStyleAtom( SvStream& rSt )
-{
- const PPTExCharLevel& rCharStyle = mpCharSheet[ EPP_TEXTTYPE_Other ]->maCharLevel[ 0 ];
-
- sal_uInt16 nFlags = 0x60 // ??
- | 0x02 // fontsize;
- | 0x04; // fontcolor
-
- sal_uInt32 nCharFlags = rCharStyle.mnFlags;
- nCharFlags &= CharAttr_Italic | CharAttr_Bold | CharAttr_Underline | CharAttr_Shadow;
-
- rSt << (sal_uInt32)( EPP_TxCFStyleAtom << 16 ) // recordheader
- << SizeOfTxCFStyleAtom() - 8
- << (sal_uInt16)( 0x80 | nCharFlags )
- << (sal_uInt16)nFlags
- << (sal_uInt16)nCharFlags
- << (sal_Int32)-1 // ?
- << rCharStyle.mnFontHeight
- << rCharStyle.mnFontColor;
-}
-
-
-// ---------------------------------------------------------------------------------------------
-
// ---------------------
// - exported function -
// ---------------------
@@ -2463,6 +1488,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool __LOADONCALLAPI ExportPPT( SvStorageRef
pPPTWriter = new PPTWriter( rSvStorage, rXModel, rXStatInd, pVBA, nCnvrtFlags );
if ( pPPTWriter )
{
+ pPPTWriter->exportPPT();
bStatus = ( pPPTWriter->IsValid() == sal_True );
delete pPPTWriter;
}
@@ -2505,3 +1531,4 @@ extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool __LOADONCALLAPI SaveVBA( SfxObjectShell
return sal_False;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/eppt.hxx b/sd/source/filter/eppt/eppt.hxx
index 02e0240c2..a3284bd9f 100755..100644
--- a/sd/source/filter/eppt/eppt.hxx
+++ b/sd/source/filter/eppt/eppt.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -28,9 +29,7 @@
#ifndef _EPPT_HXX_
#define _EPPT_HXX_
#include <vector>
-#ifndef _PptEscherEx_HXX
#include "escherex.hxx"
-#endif
#include <tools/solar.h>
#include <sot/storage.hxx>
#include <tools/gen.hxx>
@@ -40,6 +39,8 @@
#include "pptexanimations.hxx"
#include <pptexsoundcollection.hxx>
+#include "text.hxx"
+
// ------------------------------------------------------------------------
#include <vcl/mapmod.hxx>
@@ -92,340 +93,63 @@
#include <com/sun/star/text/WritingMode.hpp>
#include <com/sun/star/lang/Locale.hpp>
-enum PageType { NORMAL = 0, MASTER = 1, NOTICE = 2, UNDEFINED = 3 };
-
-#define EPP_MAINMASTER_PERSIST_KEY 0x80010000
-#define EPP_MAINNOTESMASTER_PERSIST_KEY 0x80020000
-#define EPP_MAINSLIDE_PERSIST_KEY 0x80030000
-#define EPP_MAINNOTES_PERSIST_KEY 0x80040000
-
-#define EPP_Persist_Document 0x80080000
-#define EPP_Persist_MainMaster 0x80100000
-#define EPP_Persist_MainNotes 0x80200000
-#define EPP_Persist_Slide 0x80400000
-#define EPP_Persist_Notes 0x80800000
-#define EPP_Persist_CurrentPos 0x81000000
-#define EPP_Persist_VBAInfoAtom 0x84000000
-#define EPP_Persist_ExObj 0x88000000
-
-#define EPP_TEXTSTYLE_NORMAL 0x00000001
-#define EPP_TEXTSTYLE_TITLE 0x00000010
-#define EPP_TEXTSTYLE_BODY 0x00000100
-#define EPP_TEXTSTYLE_TEXT 0x00001000
-
-// PLACEMENT_ID
-#define EPP_LAYOUT_TITLESLIDE 0 /* The slide is a title slide */
-#define EPP_LAYOUT_TITLEANDBODYSLIDE 1 /* Title and body slide */
-#define EPP_LAYOUT_TITLEMASTERSLIDE 2 /* Title master slide */
-#define EPP_LAYOUT_MASTERSLIDE 3 /* Master slide layout */
-#define EPP_LAYOUT_MASTERNOTES 4 /* Master notes layout */
-#define EPP_LAYOUT_NOTESTITLEBODY 5 /* Notes title/body layout */
-#define EPP_LAYOUT_HANDOUTLAYOUT 6 /* Handout layout, therefore it doesn't have placeholders except header, footer, and date */
-#define EPP_LAYOUT_ONLYTITLE 7 /* Only title placeholder */
-#define EPP_LAYOUT_2COLUMNSANDTITLE 8 /* Body of the slide has 2 columns and a title */
-#define EPP_LAYOUT_2ROWSANDTITLE 9 /* Slide's body has 2 rows and a title */
-#define EPP_LAYOUT_RIGHTCOLUMN2ROWS 10 /* Body contains 2 columns, right column has 2 rows */
-#define EPP_LAYOUT_LEFTCOLUMN2ROWS 11 /* Body contains 2 columns, left column has 2 rows */
-#define EPP_LAYOUT_BOTTOMROW2COLUMNS 12 /* Body contains 2 rows, bottom row has 2 columns */
-#define EPP_LAYOUT_TOPROW2COLUMN 13 /* Body contains 2 rows, top row has 2 columns */
-#define EPP_LAYOUT_4OBJECTS 14 /* 4 objects */
-#define EPP_LAYOUT_BIGOBJECT 15 /* Big object */
-#define EPP_LAYOUT_BLANCSLIDE 16 /* Blank slide */
-#define EPP_LAYOUT_TITLERIGHTBODYLEFT 17 /* Vertical title on the right, body on the left */
-#define EPP_LAYOUT_TITLERIGHT2BODIESLEFT 18 /* Vertical title on the right, body on the left split into 2 rows */
-
-class Polygon;
-class PptEscherEx;
-class XStatusIndicatorRef;
-
-struct PHLayout
-{
- sal_Int32 nLayout;
- sal_uInt8 nPlaceHolder[ 8 ];
-
- sal_uInt8 nUsedObjectPlaceHolder;
- sal_uInt8 nTypeOfTitle;
- sal_uInt8 nTypeOfOutliner;
-
- sal_Bool bTitlePossible;
- sal_Bool bOutlinerPossible;
- sal_Bool bSecOutlinerPossible;
-};
-
-struct SOParagraph
-{
- sal_Bool bExtendedParameters;
- sal_uInt32 nParaFlags;
- sal_Int16 nBulletFlags;
- String sPrefix;
- String sSuffix;
- String sGraphicUrl; // String auf eine Graphic
- Size aBuGraSize;
- sal_uInt32 nNumberingType; // in wirlichkeit ist dies ein SvxEnum
- sal_uInt32 nHorzAdjust;
- sal_uInt32 nBulletColor;
- sal_Int32 nBulletOfs;
- sal_Int16 nStartWith; // Start der nummerierung
- sal_Int16 nTextOfs;
- sal_Int16 nBulletRealSize; // GroessenVerhaeltnis in Proz
- sal_Int16 nDepth; // aktuelle tiefe
- sal_Unicode cBulletId; // wenn Numbering Type == CharSpecial
- ::com::sun::star::awt::FontDescriptor aFontDesc;
-
- sal_Bool bExtendedBulletsUsed;
- sal_uInt16 nBulletId;
- sal_uInt32 nMappedNumType;
- sal_Bool bNumberingIsNumber;
-
- SOParagraph()
- {
- nDepth = 0;
- bExtendedParameters = sal_False;
- nParaFlags = 0;
- nBulletFlags = 0;
- nBulletOfs = 0;
- nTextOfs = 0;
- bExtendedBulletsUsed = sal_False;
- nBulletId = 0xffff;
- bNumberingIsNumber = sal_True;
- };
-};
-
-// ------------------------------------------------------------------------
-
-class EscherGraphicProvider;
-class PPTExBulletProvider
-{
- friend struct PPTExParaSheet;
-
- protected :
-
- SvMemoryStream aBuExPictureStream;
- SvMemoryStream aBuExOutlineStream;
- SvMemoryStream aBuExMasterStream;
-
- EscherGraphicProvider* pGraphicProv;
-
- public :
-
- sal_uInt16 GetId( const ByteString& rUniqueId, Size& rGraphicSize );
-
- PPTExBulletProvider();
- ~PPTExBulletProvider();
-};
-
-struct FontCollectionEntry
-{
- String Name;
- double Scaling;
- sal_Int16 Family;
- sal_Int16 Pitch;
- sal_Int16 CharSet;
-
- String Original;
- sal_Bool bIsConverted;
-
- FontCollectionEntry( const String& rName, sal_Int16 nFamily, sal_Int16 nPitch, sal_Int16 nCharSet ) :
- Scaling ( 1.0 ),
- Family ( nFamily ),
- Pitch ( nPitch ),
- CharSet ( nCharSet ),
- Original( rName )
- {
- ImplInit( rName );
- };
-
- FontCollectionEntry( const String& rName ) :
- Scaling ( 1.0 ),
- Original( rName )
- {
- ImplInit( rName );
- };
- ~FontCollectionEntry();
-
- private :
-
- FontCollectionEntry() {};
-
- void ImplInit( const String& rName );
-};
-
-class VirtualDevice;
-class FontCollection : private List
-{
- VirtualDevice* pVDev;
- public :
- FontCollection();
- ~FontCollection();
-
- short GetScriptDirection( const String& rText ) const;
- sal_uInt32 GetId( FontCollectionEntry& rFontDescriptor );
- sal_uInt32 GetCount() const { return List::Count(); };
- const FontCollectionEntry* GetById( sal_uInt32 nId );
- FontCollectionEntry& GetLast() { return *(FontCollectionEntry*)List::Last(); };
-};
-
-// ------------------------------------------------------------------------
-
-#define PPTEX_STYLESHEETENTRYS 9
-
-enum PPTExTextAttr
-{
- ParaAttr_BulletOn,
- ParaAttr_BuHardFont,
- ParaAttr_BuHardColor,
- ParaAttr_BuHardHeight,
- ParaAttr_BulletChar,
- ParaAttr_BulletFont,
- ParaAttr_BulletHeight,
- ParaAttr_BulletColor,
- ParaAttr_Adjust,
- ParaAttr_LineFeed,
- ParaAttr_UpperDist,
- ParaAttr_LowerDist,
- ParaAttr_TextOfs,
- ParaAttr_BulletOfs,
- ParaAttr_DefaultTab,
- ParaAttr_AsianLB_1,
- ParaAttr_AsianLB_2,
- ParaAttr_AsianLB_3,
- ParaAttr_BiDi,
- CharAttr_Bold,
- CharAttr_Italic,
- CharAttr_Underline,
- CharAttr_Shadow,
- CharAttr_Strikeout,
- CharAttr_Embossed,
- CharAttr_Font,
- CharAttr_AsianOrComplexFont,
- CharAttr_Symbol,
- CharAttr_FontHeight,
- CharAttr_FontColor,
- CharAttr_Escapement
-};
-
-struct PPTExCharLevel
-{
- sal_uInt16 mnFlags;
- sal_uInt16 mnFont;
- sal_uInt16 mnAsianOrComplexFont;
- sal_uInt16 mnFontHeight;
- sal_uInt16 mnEscapement;
- sal_uInt32 mnFontColor;
-};
-
-struct PPTExCharSheet
-{
- PPTExCharLevel maCharLevel[ 5 ];
-
- PPTExCharSheet( int nInstance );
-
- void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
- FontCollection& rFontCollection, int nLevel );
- void Write( SvStream& rSt, PptEscherEx* pEx, sal_uInt16 nLev, sal_Bool bFirst, sal_Bool bSimpleText,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet );
-
-};
-
-struct PPTExParaLevel
-{
- sal_Bool mbIsBullet;
- sal_uInt16 mnBulletChar;
- sal_uInt16 mnBulletFont;
- sal_uInt16 mnBulletHeight;
- sal_uInt32 mnBulletColor;
-
- sal_uInt16 mnAdjust;
- sal_uInt16 mnLineFeed;
- sal_uInt16 mnUpperDist;
- sal_uInt16 mnLowerDist;
- sal_uInt16 mnTextOfs;
- sal_uInt16 mnBulletOfs;
- sal_uInt16 mnDefaultTab;
-
- sal_Bool mbExtendedBulletsUsed;
- sal_uInt16 mnBulletId;
- sal_uInt16 mnBulletStart;
- sal_uInt32 mnMappedNumType;
- sal_uInt32 mnNumberingType;
- sal_uInt16 mnAsianSettings;
- sal_uInt16 mnBiDi;
-};
-
-struct PPTExParaSheet
-{
- PPTExBulletProvider& rBuProv;
-
- sal_uInt32 mnInstance;
-
- PPTExParaLevel maParaLevel[ 5 ];
- PPTExParaSheet( int nInstance, sal_uInt16 nDefaultTab, PPTExBulletProvider& rProv );
-
- void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
- FontCollection& rFontCollection, int nLevel, const PPTExCharLevel& rCharLevel );
- void Write( SvStream& rSt, PptEscherEx* pEx, sal_uInt16 nLev, sal_Bool bFirst, sal_Bool bSimpleText,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet );
-};
+#include <epptbase.hxx>
-class PPTExStyleSheet
-{
-
- public :
-
- PPTExCharSheet* mpCharSheet[ PPTEX_STYLESHEETENTRYS ];
- PPTExParaSheet* mpParaSheet[ PPTEX_STYLESHEETENTRYS ];
+#define EPP_MAINMASTER_PERSIST_KEY 0x80010000
+#define EPP_MAINNOTESMASTER_PERSIST_KEY 0x80020000
+#define EPP_MAINSLIDE_PERSIST_KEY 0x80030000
+#define EPP_MAINNOTES_PERSIST_KEY 0x80040000
- PPTExStyleSheet( sal_uInt16 nDefaultTab, PPTExBulletProvider& rBuProv );
- ~PPTExStyleSheet();
-
- PPTExParaSheet& GetParaSheet( int nInstance ) { return *mpParaSheet[ nInstance ]; };
- PPTExCharSheet& GetCharSheet( int nInstance ) { return *mpCharSheet[ nInstance ]; };
-
- void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
- FontCollection& rFontCollection, int nInstance, int nLevel );
- sal_Bool IsHardAttribute( sal_uInt32 nInstance, sal_uInt32 nLevel, PPTExTextAttr eAttr, sal_uInt32 nValue );
-
- sal_uInt32 SizeOfTxCFStyleAtom() const;
- void WriteTxCFStyleAtom( SvStream& rSt );
-};
+#define EPP_Persist_Document 0x80080000
+#define EPP_Persist_MainMaster 0x80100000
+#define EPP_Persist_MainNotes 0x80200000
+#define EPP_Persist_Slide 0x80400000
+#define EPP_Persist_Notes 0x80800000
+#define EPP_Persist_CurrentPos 0x81000000
+#define EPP_Persist_VBAInfoAtom 0x84000000
+#define EPP_Persist_ExObj 0x88000000
+#define EPP_TEXTSTYLE_NORMAL 0x00000001
+#define EPP_TEXTSTYLE_TITLE 0x00000010
+#define EPP_TEXTSTYLE_BODY 0x00000100
+#define EPP_TEXTSTYLE_TEXT 0x00001000
struct EPPTHyperlink
{
- String aURL;
- sal_uInt32 nType; // bit 0-7 : type ( 1: click action to a slide )
- // ( 2: hyperlink url )
+ String aURL;
+ sal_uInt32 nType; // bit 0-7 : type ( 1: click action to a slide )
+ // ( 2: hyperlink url )
// bit 8-23: index
// bit 31 : hyperlink is attached to a shape
EPPTHyperlink( const String rURL, sal_uInt32 nT ) :
- aURL ( rURL ),
- nType ( nT ){};
+ aURL ( rURL ),
+ nType ( nT ){};
};
enum PPTExOleObjEntryType
{
- NORMAL_OLE_OBJECT, OCX_CONTROL
+ NORMAL_OLE_OBJECT, OCX_CONTROL
};
struct PPTExOleObjEntry
{
- PPTExOleObjEntryType eType;
- sal_uInt32 nOfsA; // offset to the EPP_ExOleObjAtom in mpExEmbed (set at creation)
- sal_uInt32 nOfsB; // offset to the EPP_ExOleObjStg
+ PPTExOleObjEntryType eType;
+ sal_uInt32 nOfsA; // offset to the EPP_ExOleObjAtom in mpExEmbed (set at creation)
+ sal_uInt32 nOfsB; // offset to the EPP_ExOleObjStg
- ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel > xControlModel;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape;
+ ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel > xControlModel;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape;
PPTExOleObjEntry( PPTExOleObjEntryType eT, sal_uInt32 nOfs ) :
- eType ( eT ),
- nOfsA ( nOfs ) {};
+ eType ( eT ),
+ nOfsA ( nOfs ) {};
};
struct TextRuleEntry
{
- int nPageNumber;
- SvMemoryStream* pOut;
+ int nPageNumber;
+ SvMemoryStream* pOut;
TextRuleEntry( int nPg ) :
nPageNumber( nPg ),
@@ -434,404 +158,134 @@ struct TextRuleEntry
~TextRuleEntry() { delete pOut; };
};
-// ------------------------------------------------------------------------
-
-struct GroupEntry
-{
- sal_uInt32 mnCurrentPos;
- sal_uInt32 mnCount;
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > mXIndexAccess;
- GroupEntry( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex )
- {
- mXIndexAccess = rIndex;
- mnCount =mXIndexAccess->getCount();
- mnCurrentPos = 0;
- };
- GroupEntry( sal_uInt32 nCount )
- {
- mnCount = nCount;
- mnCurrentPos = 0;
- };
- ~GroupEntry(){};
-};
-
-// ------------------------------------------------------------------------
-
-class GroupTable
-{
- protected:
-
- sal_uInt32 mnIndex;
- sal_uInt32 mnCurrentGroupEntry;
- sal_uInt32 mnMaxGroupEntry;
- sal_uInt32 mnGroupsClosed;
- GroupEntry** mpGroupEntry;
-
- void ImplResizeGroupTable( sal_uInt32 nEntrys );
-
- public:
-
- sal_uInt32 GetCurrentGroupIndex() const { return mnIndex; };
- sal_Int32 GetCurrentGroupLevel() const { return mnCurrentGroupEntry - 1; };
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > &
- GetCurrentGroupAccess() const { return mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mXIndexAccess; };
- sal_uInt32 GetGroupsClosed();
- void ResetGroupTable( sal_uInt32 nCount );
- void ClearGroupTable();
- sal_Bool EnterGroup( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex );
- sal_Bool GetNextGroupEntry();
- GroupTable();
- ~GroupTable();
-};
-
-class PropValue
+class TextObjBinary : public TextObj
{
- protected :
-
- ::com::sun::star::uno::Any mAny;
-
- ::com::sun::star::uno::Reference
- < ::com::sun::star::beans::XPropertySet > mXPropSet;
-
- sal_Bool ImplGetPropertyValue( const String& rString );
- sal_Bool ImplGetPropertyValue( const ::com::sun::star::uno::Reference
- < ::com::sun::star::beans::XPropertySet > &, const String& );
-
- public :
-
- static sal_Bool GetPropertyValue(
- ::com::sun::star::uno::Any& rAny,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
- const String& rPropertyName,
- sal_Bool bTestPropertyAvailability = sal_False );
-
- static ::com::sun::star::beans::PropertyState GetPropertyState(
- const ::com::sun::star::uno::Reference < ::com::sun::star::beans::XPropertySet > &,
- const String& rPropertyName );
-};
-
-class PropStateValue : public PropValue
-{
- protected :
-
- ::com::sun::star::beans::PropertyState ePropState;
- ::com::sun::star::uno::Reference
- < ::com::sun::star::beans::XPropertyState > mXPropState;
-
- sal_Bool ImplGetPropertyValue( const String& rString, sal_Bool bGetPropertyState = sal_True );
-
+public:
+ TextObjBinary( ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > &
+ rXText, int nInstance, FontCollection& rFontCollection, PPTExBulletProvider& rBuProv ) : TextObj( rXText, nInstance, rFontCollection, rBuProv ) {}
+ void Write( SvStream* pStrm );
+ void WriteTextSpecInfo( SvStream* pStrm );
};
// ------------------------------------------------------------------------
-struct FieldEntry;
-class PortionObj : public PropStateValue
-{
-
- friend class ParagraphObj;
-
- protected :
-
- void ImplClear();
- void ImplConstruct( const PortionObj& rPortionObj );
- sal_uInt32 ImplGetTextField( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRangeRef,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef, String& rURL );
- sal_uInt32 ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition );
- void ImplGetPortionValues( FontCollection& rFontCollection, sal_Bool bGetPropStateValue = sal_False );
-
- public :
-
- ::com::sun::star::beans::PropertyState meCharColor;
- ::com::sun::star::beans::PropertyState meCharHeight;
- ::com::sun::star::beans::PropertyState meFontName;
- ::com::sun::star::beans::PropertyState meAsianOrComplexFont;
- ::com::sun::star::beans::PropertyState meCharEscapement;
- ::com::sun::star::lang::Locale meCharLocale;
- sal_uInt16 mnCharAttrHard;
-
- sal_uInt32 mnCharColor;
- sal_uInt16 mnCharAttr;
- sal_uInt16 mnCharHeight;
- sal_uInt16 mnFont;
- sal_uInt16 mnAsianOrComplexFont;
- sal_Int16 mnCharEscapement;
-
- sal_uInt32 mnTextSize;
- sal_Bool mbLastPortion;
-
- sal_uInt16* mpText;
- FieldEntry* mpFieldEntry;
-
- PortionObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRangeRef,
- sal_Bool bLast, FontCollection& rFontCollection );
- PortionObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef,
- FontCollection& rFontCollection );
- PortionObj( const PortionObj& rPortionObj );
- ~PortionObj();
-
- void Write( SvStream* pStrm, sal_Bool bLast );
- sal_uInt32 Count() const { return mnTextSize; };
-
- PortionObj& operator=( const PortionObj& rPortionObj );
-};
-
-struct ParaFlags
-{
- sal_Bool bFirstParagraph : 1;
- sal_Bool bLastParagraph : 1;
-
- ParaFlags() { bFirstParagraph = sal_True; bLastParagraph = sal_False; };
-};
-
-class ParagraphObj : public List, public PropStateValue, public SOParagraph
-{
- friend class TextObj;
- friend struct PPTExParaSheet;
-
- MapMode maMapModeSrc;
- MapMode maMapModeDest;
-
- protected :
-
- void ImplConstruct( const ParagraphObj& rParagraphObj );
- void ImplClear();
- sal_uInt32 ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition );
- void ImplGetParagraphValues( PPTExBulletProvider& rBuProv, sal_Bool bGetPropStateValue = sal_False );
- void ImplGetNumberingLevel( PPTExBulletProvider& rBuProv, sal_Int16 nDepth, sal_Bool bIsBullet, sal_Bool bGetPropStateValue = sal_False );
-
- public :
-
- ::com::sun::star::uno::Sequence< ::com::sun::star::style::TabStop > maTabStop;
-
- sal_uInt32 mnTextSize;
-
- sal_Bool mbIsBullet;
- sal_Bool mbFirstParagraph;
- sal_Bool mbLastParagraph;
-
- ::com::sun::star::beans::PropertyState meBullet;
- ::com::sun::star::beans::PropertyState meTextAdjust;
- ::com::sun::star::beans::PropertyState meLineSpacing;
- ::com::sun::star::beans::PropertyState meLineSpacingTop;
- ::com::sun::star::beans::PropertyState meLineSpacingBottom;
- ::com::sun::star::beans::PropertyState meForbiddenRules;
- ::com::sun::star::beans::PropertyState meParagraphPunctation;
- ::com::sun::star::beans::PropertyState meBiDi;
-
- sal_uInt16 mnTextAdjust;
- sal_Int16 mnLineSpacing;
- sal_Int16 mnLineSpacingTop;
- sal_Int16 mnLineSpacingBottom;
- sal_Bool mbForbiddenRules;
- sal_Bool mbParagraphPunctation;
- sal_uInt16 mnBiDi;
-
- ParagraphObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > & rXTextContentRef,
- ParaFlags, FontCollection& rFontCollection,
- PPTExBulletProvider& rBuProv );
- ParagraphObj( const ParagraphObj& rParargraphObj );
- ParagraphObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef,
- PPTExBulletProvider& rBuProv );
-
- void CalculateGraphicBulletSize( sal_uInt16 nFontHeight );
- ~ParagraphObj();
-
- void Write( SvStream* pStrm );
- sal_uInt32 Count() const { return mnTextSize; };
-
- ParagraphObj& operator=( const ParagraphObj& rParagraphObj );
-};
-
-struct ImplTextObj
-{
- sal_uInt32 mnRefCount;
- sal_uInt32 mnTextSize;
- int mnInstance;
- List* mpList;
- sal_Bool mbHasExtendedBullets;
- sal_Bool mbFixedCellHeightUsed;
-
- ImplTextObj( int nInstance );
- ~ImplTextObj();
-};
-
-class TextObj
-{
- mutable ImplTextObj* mpImplTextObj;
- void ImplCalculateTextPositions();
-
- public :
- TextObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > &
- rXText, int nInstance, FontCollection& rFontCollection, PPTExBulletProvider& rBuProv );
- TextObj( const TextObj& rTextObj );
- ~TextObj();
-
- void Write( SvStream* pStrm );
-
- ParagraphObj* First(){ return (ParagraphObj*)mpImplTextObj->mpList->First(); };
- ParagraphObj* Next(){ return(ParagraphObj*)mpImplTextObj->mpList->Next(); };
- sal_uInt32 Count() const { return mpImplTextObj->mnTextSize; };
- int GetInstance() const { return mpImplTextObj->mnInstance; };
- sal_Bool HasExtendedBullets(){ return mpImplTextObj->mbHasExtendedBullets; };
- void WriteTextSpecInfo( SvStream* pStrm );
-
- TextObj& operator=( TextObj& rTextObj );
-};
-
-// ------------------------------------------------------------------------
struct CellBorder;
-class PPTWriter : public GroupTable, public PropValue, public PPTExBulletProvider
+class PPTWriter : public PPTWriterBase, public PPTExBulletProvider
{
- sal_Bool mbStatus;
- sal_Bool mbUseNewAnimations;
- sal_uInt32 mnStatMaxValue;
- sal_uInt32 mnLatestStatValue;
- std::vector< PPTExStyleSheet* > maStyleSheetList;
- PPTExStyleSheet* mpStyleSheet;
-
- EscherGraphicProvider* mpGraphicProvider;
- Fraction maFraction;
- MapMode maMapModeSrc;
- MapMode maMapModeDest;
- ::com::sun::star::awt::Size maDestPageSize;
- ::com::sun::star::awt::Size maNotesPageSize;
- PageType meLatestPageType;
- List maSlideNameList;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > mXModel;
- ::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator > mXStatusIndicator;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPagesSupplier > mXDrawPagesSupplier;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPagesSupplier > mXMasterPagesSupplier;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPages > mXDrawPages;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage > mXDrawPage;
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXPagePropSet;
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXBackgroundPropSet;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes > mXShapes;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > mXShape;
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > mXText; // TextRef des globalen Text
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > mXCursor;
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > mXCursorText; // TextRef des Teilstuecks des Cursors
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXCursorPropSet; // die Properties des Teilstueckes
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextField > mXTextField;
- ::com::sun::star::awt::Size maSize;
- ::com::sun::star::awt::Point maPosition;
- Rectangle maRect;
- ByteString mType;
- sal_Bool mbPresObj;
- sal_Bool mbEmptyPresObj;
- sal_Bool mbStatusIndicator;
- sal_Int32 mnAngle;
- sal_uInt32 mnTextStyle;
-
- sal_Bool mbFontIndependentLineSpacing;
- sal_uInt32 mnTextSize;
-
- SvStorageRef mrStg;
- SvStream* mpCurUserStrm;
- SvStream* mpStrm;
- SvStream* mpPicStrm;
- PptEscherEx* mpPptEscherEx;
-
- List maExOleObj;
- sal_uInt32 mnVBAOleOfs;
- SvMemoryStream* mpVBA;
- sal_uInt32 mnExEmbed;
- SvMemoryStream* mpExEmbed;
-
- sal_uInt32 mnPages; // anzahl einzelner Slides ( ohne masterpages & notes & handout )
- sal_uInt32 mnMasterPages; //
- sal_uInt32 mnDrawings; // anzahl Slides + masterpages + notes + handout
- sal_uInt32 mnPagesWritten;
- sal_uInt32 mnUniqueSlideIdentifier;
- sal_uInt32 mnTxId; // Identifier determined by the HOST (PP) ????
- sal_uInt32 mnDiaMode; // 0 -> manuell
+ sal_uInt32 mnCnvrtFlags;
+ sal_Bool mbStatus;
+ sal_Bool mbUseNewAnimations;
+ sal_uInt32 mnStatMaxValue;
+ sal_uInt32 mnLatestStatValue;
+
+ EscherGraphicProvider* mpGraphicProvider;
+ std::vector<rtl::OUString> maSlideNameList;
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > mXText; // TextRef des globalen Text
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > mXCursor;
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > mXCursorText; // TextRef des Teilstuecks des Cursors
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXCursorPropSet; // die Properties des Teilstueckes
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextField > mXTextField;
+ sal_uInt32 mnTextStyle;
+
+ sal_Bool mbFontIndependentLineSpacing;
+ sal_uInt32 mnTextSize;
+
+ SvStorageRef mrStg;
+ SvStream* mpCurUserStrm;
+ SvStream* mpStrm;
+ SvStream* mpPicStrm;
+ PptEscherEx* mpPptEscherEx;
+
+ List maExOleObj;
+ sal_uInt32 mnVBAOleOfs;
+ SvMemoryStream* mpVBA;
+ sal_uInt32 mnExEmbed;
+ SvMemoryStream* mpExEmbed;
+
+ sal_uInt32 mnDrawings; // anzahl Slides + masterpages + notes + handout
+ sal_uInt32 mnPagesWritten;
+ sal_uInt32 mnUniqueSlideIdentifier;
+ sal_uInt32 mnTxId; // Identifier determined by the HOST (PP) ????
+ sal_uInt32 mnDiaMode; // 0 -> manuell
// 1 -> halbautomatisch
// 2 -> automatisch
- sal_uInt32 mnShapeMasterTitle;
- sal_uInt32 mnShapeMasterBody;
+ sal_uInt32 mnShapeMasterTitle;
+ sal_uInt32 mnShapeMasterBody;
+
+ List maHyperlink;
- List maHyperlink;
+ ppt::ExSoundCollection maSoundCollection;
- FontCollection maFontCollection;
- ppt::ExSoundCollection maSoundCollection;
-
- PHLayout& ImplGetLayout( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const;
- void ImplWriteExtParaHeader( SvMemoryStream& rSt, sal_uInt32 nRef, sal_uInt32 nInstance, sal_uInt32 nSlideId );
-
+ void ImplWriteExtParaHeader( SvMemoryStream& rSt, sal_uInt32 nRef, sal_uInt32 nInstance, sal_uInt32 nSlideId );
- sal_uInt32 ImplProgBinaryTag( SvStream* pOutStrm = NULL );
- sal_uInt32 ImplProgBinaryTagContainer( SvStream* pOutStrm = NULL, SvMemoryStream* pBinTag = NULL );
- sal_uInt32 ImplProgTagContainer( SvStream* pOutStrm = NULL, SvMemoryStream* pBinTag = NULL );
- sal_uInt32 ImplOutlineViewInfoContainer( SvStream* pOutStrm = NULL );
- sal_uInt32 ImplSlideViewInfoContainer( sal_uInt32 nInstance, SvStream* pOutStrm = NULL );
- sal_uInt32 ImplVBAInfoContainer( SvStream* pOutStrm = NULL );
- sal_uInt32 ImplDocumentListContainer( SvStream* pOutStrm = NULL );
- sal_uInt32 ImplMasterSlideListContainer( SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplProgBinaryTag( SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplProgBinaryTagContainer( SvStream* pOutStrm = NULL, SvMemoryStream* pBinTag = NULL );
+ sal_uInt32 ImplProgTagContainer( SvStream* pOutStrm = NULL, SvMemoryStream* pBinTag = NULL );
+ sal_uInt32 ImplOutlineViewInfoContainer( SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplSlideViewInfoContainer( sal_uInt32 nInstance, SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplVBAInfoContainer( SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplDocumentListContainer( SvStream* pOutStrm = NULL );
+ sal_uInt32 ImplMasterSlideListContainer( SvStream* pOutStrm = NULL );
public:
- static void WriteCString( SvStream&, const String&, sal_uInt32 nInstance = 0 );
+ static void WriteCString( SvStream&, const String&, sal_uInt32 nInstance = 0 );
protected:
- sal_Bool ImplCreateDocumentSummaryInformation( sal_uInt32 nCnvrtFlags );
- sal_Bool ImplCreateCurrentUserStream();
- void ImplCreateHeaderFooterStrings( SvStream& rOut,
+ sal_Bool ImplCreateDocumentSummaryInformation();
+ sal_Bool ImplCreateCurrentUserStream();
+ void ImplCreateHeaderFooterStrings( SvStream& rOut,
::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPagePropSet );
- void ImplCreateHeaderFooters( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPagePropSet );
- sal_Bool ImplCreateDocument();
- sal_Bool ImplCreateHyperBlob( SvMemoryStream& rStream );
- sal_uInt32 ImplInsertBookmarkURL( const String& rBookmark, const sal_uInt32 nType,
+ void ImplCreateHeaderFooters( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPagePropSet );
+ virtual sal_Bool ImplCreateDocument();
+ sal_Bool ImplCreateHyperBlob( SvMemoryStream& rStream );
+ sal_uInt32 ImplInsertBookmarkURL( const String& rBookmark, const sal_uInt32 nType,
const String& rStringVer0, const String& rStringVer1, const String& rStringVer2, const String& rStringVer3 );
- sal_Bool ImplCreateMaster( sal_uInt32 nPageNum );
- sal_Bool ImplCreateMainNotes();
- sal_Bool ImplCreateSlide( sal_uInt32 nPageNum );
- sal_Bool ImplCreateNotes( sal_uInt32 nPageNum );
- void ImplWriteBackground( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXBackgroundPropSet );
- void ImplWriteVBA( SvMemoryStream* pVBA );
- void ImplWriteOLE( sal_uInt32 nCnvrtFlags );
- sal_Bool ImplWriteAtomEnding();
-
- sal_Bool ImplInitSOIface();
- sal_Bool ImplSetCurrentStyleSheet( sal_uInt32 nPageNum );
- sal_Bool ImplGetPageByIndex( sal_uInt32 nIndex, PageType );
- sal_Bool ImplGetShapeByIndex( sal_uInt32 nIndex, sal_Bool bGroup = sal_False );
- sal_uInt32 ImplGetMasterIndex( PageType ePageType );
- void ImplFlipBoundingBox( EscherPropertyContainer& rPropOpt );
- sal_Bool ImplGetText();
- sal_Bool ImplCreatePresentationPlaceholder( const sal_Bool bMaster, const PageType PageType,
+ virtual sal_Bool ImplCreateMainNotes();
+ sal_Bool ImplCreateNotes( sal_uInt32 nPageNum );
+ void ImplWriteBackground( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXBackgroundPropSet );
+ void ImplWriteVBA();
+ void ImplWriteOLE();
+ sal_Bool ImplWriteAtomEnding();
+
+ void ImplFlipBoundingBox( EscherPropertyContainer& rPropOpt );
+ sal_Bool ImplGetText();
+ sal_Bool ImplCreatePresentationPlaceholder( const sal_Bool bMaster, const PageType PageType,
const sal_uInt32 StyleInstance, const sal_uInt8 PlaceHolderId );
- sal_Bool ImplGetEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
+ sal_Bool ImplGetEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
::com::sun::star::presentation::AnimationEffect& eEffect,
::com::sun::star::presentation::AnimationEffect& eTextEffect,
- sal_Bool& bHasSound );
- void ImplWriteObjectEffect( SvStream& rSt,
+ sal_Bool& bHasSound );
+ void ImplWriteObjectEffect( SvStream& rSt,
::com::sun::star::presentation::AnimationEffect eEffect,
::com::sun::star::presentation::AnimationEffect eTextEffect,
sal_uInt16 nOrder );
- void ImplWriteClickAction( SvStream& rSt, ::com::sun::star::presentation::ClickAction eAction, sal_Bool bMediaClickAction );
- sal_Bool ImplGetStyleSheets();
- void ImplWriteParagraphs( SvStream& rOutStrm, TextObj& rTextObj );
- void ImplWritePortions( SvStream& rOutStrm, TextObj& rTextObj );
- void ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_uInt32 nAtomInstance,
+ void ImplWriteClickAction( SvStream& rSt, ::com::sun::star::presentation::ClickAction eAction, sal_Bool bMediaClickAction );
+ void ImplWriteParagraphs( SvStream& rOutStrm, TextObj& rTextObj );
+ void ImplWritePortions( SvStream& rOutStrm, TextObj& rTextObj );
+ void ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_uInt32 nAtomInstance,
TextRuleEntry* pTextRule, SvStream& rExtBu, EscherPropertyContainer* );
- void ImplAdjustFirstLineLineSpacing( TextObj& rTextObj, EscherPropertyContainer& rPropOpt );
- void ImplCreateShape( sal_uInt32 nType, sal_uInt32 nFlags, EscherSolverContainer& );
- void ImplCreateTextShape( EscherPropertyContainer&, EscherSolverContainer&, sal_Bool bFill );
+ void ImplAdjustFirstLineLineSpacing( TextObj& rTextObj, EscherPropertyContainer& rPropOpt );
+ void ImplCreateShape( sal_uInt32 nType, sal_uInt32 nFlags, EscherSolverContainer& );
+ void ImplCreateTextShape( EscherPropertyContainer&, EscherSolverContainer&, sal_Bool bFill );
- void ImplWritePage( const PHLayout& rLayout,
+ void ImplWritePage( const PHLayout& rLayout,
EscherSolverContainer& rSolver,
PageType ePageType,
sal_Bool bMaster,
int nPageNumber = 0 );
- void ImplCreateCellBorder( const CellBorder* pCellBorder, sal_Int32 nX1, sal_Int32 nY1, sal_Int32 nX2, sal_Int32 nY2 );
- void ImplCreateTable( com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& rXShape, EscherSolverContainer& aSolverContainer,
+ void ImplCreateCellBorder( const CellBorder* pCellBorder, sal_Int32 nX1, sal_Int32 nY1, sal_Int32 nX2, sal_Int32 nY2 );
+ void ImplCreateTable( com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& rXShape, EscherSolverContainer& aSolverContainer,
EscherPropertyContainer& aPropOpt );
- ::com::sun::star::awt::Point ImplMapPoint( const ::com::sun::star::awt::Point& );
- ::com::sun::star::awt::Size ImplMapSize( const ::com::sun::star::awt::Size& );
- Rectangle ImplMapRectangle( const ::com::sun::star::awt::Rectangle& );
- sal_Bool ImplCloseDocument(); // die font-, hyper-, Soundliste wird geschrieben ..
+ sal_Bool ImplCloseDocument(); // die font-, hyper-, Soundliste wird geschrieben ..
+
+ virtual void ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterID, sal_uInt16 nMode,
+ sal_Bool bHasBackground, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
+ virtual void ImplWriteNotes( sal_uInt32 nPageNum );
+ virtual void ImplWriteSlideMaster( sal_uInt32 nPageNum, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
public:
PPTWriter( SvStorageRef& rSvStorage,
@@ -841,8 +295,12 @@ class PPTWriter : public GroupTable, public PropValue, public PPTExBulletProvide
~PPTWriter();
- sal_Bool IsValid() const { return mbStatus; };
-};
+ sal_Bool IsValid() const { return mbStatus; };
+ virtual void exportPPTPre();
+ virtual void exportPPTPost( );
+};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/epptbase.hxx b/sd/source/filter/eppt/epptbase.hxx
new file mode 100644
index 000000000..79244e8e2
--- /dev/null
+++ b/sd/source/filter/eppt/epptbase.hxx
@@ -0,0 +1,454 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef EPPT_EPPTBASE_HXX
+#define EPPT_EPPTBASE_HXX
+
+#include <vector>
+#include <boost/ptr_container/ptr_vector.hpp>
+
+#include <vcl/mapmod.hxx>
+#include <tools/string.hxx>
+#include <tools/stream.hxx>
+#include <tools/gen.hxx>
+#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/drawing/XDrawPagesSupplier.hpp>
+#include <com/sun/star/drawing/XMasterPagesSupplier.hpp>
+#include <com/sun/star/drawing/XMasterPageTarget.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/presentation/XPresentationSupplier.hpp>
+#include <com/sun/star/presentation/FadeEffect.hpp>
+#include <com/sun/star/task/XStatusIndicatorSupplier.hpp>
+
+#include "grouptable.hxx"
+
+// PLACEMENT_ID
+#define EPP_LAYOUT_TITLESLIDE 0 /* The slide is a title slide */
+#define EPP_LAYOUT_TITLEANDBODYSLIDE 1 /* Title and body slide */
+#define EPP_LAYOUT_TITLEMASTERSLIDE 2 /* Title master slide */
+#define EPP_LAYOUT_MASTERSLIDE 3 /* Master slide layout */
+#define EPP_LAYOUT_MASTERNOTES 4 /* Master notes layout */
+#define EPP_LAYOUT_NOTESTITLEBODY 5 /* Notes title/body layout */
+#define EPP_LAYOUT_HANDOUTLAYOUT 6 /* Handout layout, therefore it doesn't have placeholders except header, footer, and date */
+#define EPP_LAYOUT_ONLYTITLE 7 /* Only title placeholder */
+#define EPP_LAYOUT_2COLUMNSANDTITLE 8 /* Body of the slide has 2 columns and a title */
+#define EPP_LAYOUT_2ROWSANDTITLE 9 /* Slide's body has 2 rows and a title */
+#define EPP_LAYOUT_RIGHTCOLUMN2ROWS 10 /* Body contains 2 columns, right column has 2 rows */
+#define EPP_LAYOUT_LEFTCOLUMN2ROWS 11 /* Body contains 2 columns, left column has 2 rows */
+#define EPP_LAYOUT_BOTTOMROW2COLUMNS 12 /* Body contains 2 rows, bottom row has 2 columns */
+#define EPP_LAYOUT_TOPROW2COLUMN 13 /* Body contains 2 rows, top row has 2 columns */
+#define EPP_LAYOUT_4OBJECTS 14 /* 4 objects */
+#define EPP_LAYOUT_BIGOBJECT 15 /* Big object */
+#define EPP_LAYOUT_BLANCSLIDE 16 /* Blank slide */
+#define EPP_LAYOUT_TITLERIGHTBODYLEFT 17 /* Vertical title on the right, body on the left */
+#define EPP_LAYOUT_TITLERIGHT2BODIESLEFT 18 /* Vertical title on the right, body on the left split into 2 rows */
+
+#define EPP_LAYOUT_SIZE 25
+
+class Polygon;
+class PptEscherEx;
+class XStatusIndicatorRef;
+
+struct PHLayout
+{
+ sal_Int32 nLayout;
+ sal_uInt8 nPlaceHolder[ 8 ];
+
+ sal_uInt8 nUsedObjectPlaceHolder;
+ sal_uInt8 nTypeOfTitle;
+ sal_uInt8 nTypeOfOutliner;
+
+ sal_Bool bTitlePossible;
+ sal_Bool bOutlinerPossible;
+ sal_Bool bSecOutlinerPossible;
+};
+
+enum PageType { NORMAL = 0, MASTER = 1, NOTICE = 2, UNDEFINED = 3, LAYOUT = 4 };
+
+class PropValue
+{
+ protected :
+
+ ::com::sun::star::uno::Any mAny;
+
+ ::com::sun::star::uno::Reference
+ < ::com::sun::star::beans::XPropertySet > mXPropSet;
+
+ sal_Bool ImplGetPropertyValue( const String& rString );
+ sal_Bool ImplGetPropertyValue( const ::com::sun::star::uno::Reference
+ < ::com::sun::star::beans::XPropertySet > &, const String& );
+
+ public :
+
+ PropValue() {}
+
+ PropValue( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > rXPropSet )
+ : mXPropSet( rXPropSet )
+ {}
+
+ ::com::sun::star::uno::Any GetAny() { return mAny; }
+
+ static sal_Bool GetPropertyValue(
+ ::com::sun::star::uno::Any& rAny,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
+ const String& rPropertyName,
+ sal_Bool bTestPropertyAvailability = sal_False );
+
+ static ::com::sun::star::beans::PropertyState GetPropertyState(
+ const ::com::sun::star::uno::Reference < ::com::sun::star::beans::XPropertySet > &,
+ const String& rPropertyName );
+};
+
+class EscherGraphicProvider;
+class PPTExBulletProvider
+{
+ friend struct PPTExParaSheet;
+
+ protected :
+
+ SvMemoryStream aBuExPictureStream;
+ SvMemoryStream aBuExOutlineStream;
+ SvMemoryStream aBuExMasterStream;
+
+ EscherGraphicProvider* pGraphicProv;
+
+ public :
+
+ sal_uInt16 GetId( const ByteString& rUniqueId, Size& rGraphicSize );
+
+ PPTExBulletProvider();
+ ~PPTExBulletProvider();
+};
+
+struct FontCollectionEntry
+{
+ String Name;
+ double Scaling;
+ sal_Int16 Family;
+ sal_Int16 Pitch;
+ sal_Int16 CharSet;
+
+ String Original;
+ sal_Bool bIsConverted;
+
+ FontCollectionEntry( const String& rName, sal_Int16 nFamily, sal_Int16 nPitch, sal_Int16 nCharSet ) :
+ Scaling ( 1.0 ),
+ Family ( nFamily ),
+ Pitch ( nPitch ),
+ CharSet ( nCharSet ),
+ Original( rName )
+ {
+ ImplInit( rName );
+ };
+
+ FontCollectionEntry( const String& rName ) :
+ Scaling ( 1.0 ),
+ Original( rName )
+ {
+ ImplInit( rName );
+ };
+ ~FontCollectionEntry();
+
+ private :
+
+ FontCollectionEntry() {};
+
+ void ImplInit( const String& rName );
+};
+
+class VirtualDevice;
+class FontCollection
+{
+public :
+
+ FontCollection();
+
+ ~FontCollection();
+
+ short GetScriptDirection( const String& rText ) const;
+
+ sal_uInt32 GetId( FontCollectionEntry& rFontDescriptor );
+
+ inline sal_uInt32 GetCount() const { return maFonts.size(); };
+
+ const FontCollectionEntry* GetById( sal_uInt32 nId );
+
+ FontCollectionEntry& GetLast() { return *(maFonts.rbegin()); };
+
+private:
+
+ VirtualDevice* pVDev;
+ boost::ptr_vector<FontCollectionEntry> maFonts;
+};
+
+// ------------------------------------------------------------------------
+
+#define PPTEX_STYLESHEETENTRYS 9
+
+enum PPTExTextAttr
+{
+ ParaAttr_BulletOn,
+ ParaAttr_BuHardFont,
+ ParaAttr_BuHardColor,
+ ParaAttr_BuHardHeight,
+ ParaAttr_BulletChar,
+ ParaAttr_BulletFont,
+ ParaAttr_BulletHeight,
+ ParaAttr_BulletColor,
+ ParaAttr_Adjust,
+ ParaAttr_LineFeed,
+ ParaAttr_UpperDist,
+ ParaAttr_LowerDist,
+ ParaAttr_TextOfs,
+ ParaAttr_BulletOfs,
+ ParaAttr_DefaultTab,
+ ParaAttr_AsianLB_1,
+ ParaAttr_AsianLB_2,
+ ParaAttr_AsianLB_3,
+ ParaAttr_BiDi,
+ CharAttr_Bold,
+ CharAttr_Italic,
+ CharAttr_Underline,
+ CharAttr_Shadow,
+ CharAttr_Strikeout,
+ CharAttr_Embossed,
+ CharAttr_Font,
+ CharAttr_AsianOrComplexFont,
+ CharAttr_Symbol,
+ CharAttr_FontHeight,
+ CharAttr_FontColor,
+ CharAttr_Escapement
+};
+
+struct PPTExCharLevel
+{
+ sal_uInt16 mnFlags;
+ sal_uInt16 mnFont;
+ sal_uInt16 mnAsianOrComplexFont;
+ sal_uInt16 mnFontHeight;
+ sal_uInt16 mnEscapement;
+ sal_uInt32 mnFontColor;
+};
+
+struct PPTExCharSheet
+{
+ PPTExCharLevel maCharLevel[ 5 ];
+
+ PPTExCharSheet( int nInstance );
+
+ void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
+ FontCollection& rFontCollection, int nLevel );
+ void Write( SvStream& rSt, PptEscherEx* pEx, sal_uInt16 nLev, sal_Bool bFirst, sal_Bool bSimpleText,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet );
+
+};
+
+struct PPTExParaLevel
+{
+ sal_Bool mbIsBullet;
+ sal_uInt16 mnBulletChar;
+ sal_uInt16 mnBulletFont;
+ sal_uInt16 mnBulletHeight;
+ sal_uInt32 mnBulletColor;
+
+ sal_uInt16 mnAdjust;
+ sal_Int16 mnOOAdjust;
+ sal_uInt16 mnLineFeed;
+ sal_uInt16 mnUpperDist;
+ sal_uInt16 mnLowerDist;
+ sal_uInt16 mnTextOfs;
+ sal_uInt16 mnBulletOfs;
+ sal_uInt16 mnDefaultTab;
+
+ sal_Bool mbExtendedBulletsUsed;
+ sal_uInt16 mnBulletId;
+ sal_uInt16 mnBulletStart;
+ sal_uInt32 mnMappedNumType;
+ sal_uInt32 mnNumberingType;
+ sal_uInt16 mnAsianSettings;
+ sal_uInt16 mnBiDi;
+};
+
+struct PPTExParaSheet
+{
+ PPTExBulletProvider& rBuProv;
+
+ sal_uInt32 mnInstance;
+
+ PPTExParaLevel maParaLevel[ 5 ];
+ PPTExParaSheet( int nInstance, sal_uInt16 nDefaultTab, PPTExBulletProvider& rProv );
+
+ void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
+ FontCollection& rFontCollection, int nLevel, const PPTExCharLevel& rCharLevel );
+ void Write( SvStream& rSt, PptEscherEx* pEx, sal_uInt16 nLev, sal_Bool bFirst, sal_Bool bSimpleText,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet );
+};
+
+class PPTExStyleSheet
+{
+
+ public :
+
+ PPTExCharSheet* mpCharSheet[ PPTEX_STYLESHEETENTRYS ];
+ PPTExParaSheet* mpParaSheet[ PPTEX_STYLESHEETENTRYS ];
+
+ PPTExStyleSheet( sal_uInt16 nDefaultTab, PPTExBulletProvider& rBuProv );
+ ~PPTExStyleSheet();
+
+ PPTExParaSheet& GetParaSheet( int nInstance ) { return *mpParaSheet[ nInstance ]; };
+ PPTExCharSheet& GetCharSheet( int nInstance ) { return *mpCharSheet[ nInstance ]; };
+
+ void SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > &,
+ FontCollection& rFontCollection, int nInstance, int nLevel );
+ sal_Bool IsHardAttribute( sal_uInt32 nInstance, sal_uInt32 nLevel, PPTExTextAttr eAttr, sal_uInt32 nValue );
+
+ sal_uInt32 SizeOfTxCFStyleAtom() const;
+ void WriteTxCFStyleAtom( SvStream& rSt );
+};
+
+// ------------------------------------------------------------------------
+
+class PPTWriterBase : public PropValue, public GroupTable
+{
+protected:
+ ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > mXModel;
+ ::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator > mXStatusIndicator;
+
+ sal_Bool mbStatusIndicator;
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPagesSupplier > mXDrawPagesSupplier;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPagesSupplier > mXMasterPagesSupplier;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPages > mXDrawPages;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage > mXDrawPage;
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXPagePropSet;
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mXBackgroundPropSet;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes > mXShapes;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > mXShape;
+ ::com::sun::star::awt::Size maSize;
+ ::com::sun::star::awt::Point maPosition;
+ Rectangle maRect;
+ ByteString mType;
+ sal_Bool mbPresObj;
+ sal_Bool mbEmptyPresObj;
+ sal_Int32 mnAngle;
+
+ sal_uInt32 mnPages; // number of Slides ( w/o master pages & notes & handout )
+ sal_uInt32 mnMasterPages;
+
+ Fraction maFraction;
+ MapMode maMapModeSrc;
+ MapMode maMapModeDest;
+ ::com::sun::star::awt::Size maDestPageSize;
+ ::com::sun::star::awt::Size maNotesPageSize;
+
+ PageType meLatestPageType;
+ std::vector< PPTExStyleSheet* > maStyleSheetList;
+ PPTExStyleSheet* mpStyleSheet;
+
+ FontCollection maFontCollection;
+
+ virtual void ImplWriteSlide( sal_uInt32 /* nPageNum */, sal_uInt32 /* nMasterNum */, sal_uInt16 /* nMode */,
+ sal_Bool /* bHasBackground */, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > /* aXBackgroundPropSet */ ) {}
+ virtual void ImplWriteNotes( sal_uInt32 nPageNum ) = 0;
+ virtual void ImplWriteSlideMaster( sal_uInt32 /* nPageNum */, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > /* aXBackgroundPropSet */ ) {}
+ virtual void ImplWriteLayout( sal_Int32 /* nOffset */, sal_uInt32 /* nMasterNum */ ) {}
+
+ virtual void exportPPTPre() {}
+ virtual void exportPPTPost() {}
+
+ virtual sal_Bool ImplCreateDocument()=0;
+ virtual sal_Bool ImplCreateMainNotes()=0;
+
+ sal_Bool GetStyleSheets();
+ sal_Bool GetShapeByIndex( sal_uInt32 nIndex, sal_Bool bGroup = sal_False );
+
+ sal_Bool CreateMainNotes();
+
+ ::com::sun::star::awt::Size MapSize( const ::com::sun::star::awt::Size& );
+ ::com::sun::star::awt::Point MapPoint( const ::com::sun::star::awt::Point& );
+ Rectangle MapRectangle( const ::com::sun::star::awt::Rectangle& );
+
+ sal_Bool ContainsOtherShapeThanPlaceholders( sal_Bool bForOOMLX );
+
+public:
+ PPTWriterBase();
+ PPTWriterBase( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > & rModel,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator > & rStatInd );
+
+ ~PPTWriterBase();
+
+ void exportPPT();
+
+ sal_Bool InitSOIface();
+ sal_Bool GetPageByIndex( sal_uInt32 nIndex, PageType );
+ sal_uInt32 GetMasterIndex( PageType ePageType );
+ sal_Bool SetCurrentStyleSheet( sal_uInt32 nPageNum );
+
+ sal_Bool GetPresObj() { return mbPresObj; }
+
+ PHLayout& GetLayout( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const;
+ PHLayout& GetLayout( sal_Int32 nOffset ) const;
+ sal_Int32 GetLayoutOffset( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const;
+ sal_Int32 GetLayoutOffsetFixed( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const;
+
+ sal_Bool CreateSlide( sal_uInt32 nPageNum );
+ sal_Bool CreateSlideMaster( sal_uInt32 nPageNum );
+ sal_Bool CreateNotes( sal_uInt32 nPageNum );
+
+ static sal_Int8 GetTransition( sal_Int16 nTransitionType, sal_Int16 nTransitionSubtype, ::com::sun::star::presentation::FadeEffect eEffect, sal_uInt8& nDirection );
+ static sal_Int8 GetTransition( ::com::sun::star::presentation::FadeEffect eEffect, sal_uInt8& nDirection );
+};
+
+#define PPT_TRANSITION_TYPE_NONE 0
+#define PPT_TRANSITION_TYPE_RANDOM 1
+#define PPT_TRANSITION_TYPE_BLINDS 2
+#define PPT_TRANSITION_TYPE_CHECKER 3
+#define PPT_TRANSITION_TYPE_COVER 4
+#define PPT_TRANSITION_TYPE_DISSOLVE 5
+#define PPT_TRANSITION_TYPE_FADE 6
+#define PPT_TRANSITION_TYPE_PULL 7
+#define PPT_TRANSITION_TYPE_RANDOM_BARS 8
+#define PPT_TRANSITION_TYPE_STRIPS 9
+#define PPT_TRANSITION_TYPE_WIPE 10
+#define PPT_TRANSITION_TYPE_ZOOM 11
+#define PPT_TRANSITION_TYPE_SPLIT 13
+
+// effects, new in xp
+#define PPT_TRANSITION_TYPE_DIAMOND 17
+#define PPT_TRANSITION_TYPE_PLUS 18
+#define PPT_TRANSITION_TYPE_WEDGE 19
+#define PPT_TRANSITION_TYPE_PUSH 20
+#define PPT_TRANSITION_TYPE_COMB 21
+#define PPT_TRANSITION_TYPE_NEWSFLASH 22
+#define PPT_TRANSITION_TYPE_SMOOTHFADE 23
+#define PPT_TRANSITION_TYPE_WHEEL 26
+#define PPT_TRANSITION_TYPE_CIRCLE 27
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/epptdef.hxx b/sd/source/filter/eppt/epptdef.hxx
index 1cc32fcaa..86df18edb 100755..100644
--- a/sd/source/filter/eppt/epptdef.hxx
+++ b/sd/source/filter/eppt/epptdef.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -261,3 +262,5 @@
#define EPP_SLIDESIZE_TYPECUSTOM 6
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/epptooxml.hxx b/sd/source/filter/eppt/epptooxml.hxx
new file mode 100644
index 000000000..6cd81b349
--- /dev/null
+++ b/sd/source/filter/eppt/epptooxml.hxx
@@ -0,0 +1,183 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef EPPT_POWERPOINT_EXPORT_HXX
+#define EPPT_POWERPOINT_EXPORT_HXX
+
+#include <oox/core/xmlfilterbase.hxx>
+#include <oox/helper/zipstorage.hxx>
+#include <oox/vml/vmldrawing.hxx>
+#include <oox/export/shapes.hxx>
+#include <comphelper/stl_types.hxx>
+#include "epptbase.hxx"
+
+namespace com { namespace sun { namespace star {
+ namespace animations {
+ class XAnimate;
+ class XAnimationNode;
+ }
+}}}
+
+namespace oox {
+ namespace drawingml {
+ class ShapeExport;
+ }
+namespace core {
+
+class PowerPointShapeExport;
+
+struct LayoutInfo
+{
+ std::vector< sal_Int32 > mnFileIdArray;
+};
+
+enum PlaceholderType
+{
+ None,
+ SlideImage,
+ Notes,
+ Header,
+ Footer,
+ SlideNumber,
+ DateAndTime,
+ Outliner,
+ Title,
+ Subtitle
+};
+
+class PowerPointExport : public XmlFilterBase, public PPTWriterBase
+{
+ friend class PowerPointShapeExport;
+public:
+
+ PowerPointExport( const com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > & rxCtxt );
+
+ ~PowerPointExport();
+
+ // from FilterBase
+ virtual bool importDocument() throw();
+ virtual bool exportDocument() throw();
+
+ // only needed for import, leave them empty, refactor later XmlFilterBase to export and import base?
+ virtual sal_Int32 getSchemeClr( sal_Int32 /* nColorSchemeToken */ ) const { return 0; }
+ virtual oox::vml::Drawing* getVmlDrawing() { return NULL; }
+ virtual const oox::drawingml::Theme* getCurrentTheme() const { return NULL; }
+ virtual const oox::drawingml::table::TableStyleListPtr getTableStyles() { return oox::drawingml::table::TableStyleListPtr(); }
+ virtual oox::drawingml::chart::ChartConverter& getChartConverter() { static oox::drawingml::chart::ChartConverter aConverter; return aConverter; }
+
+ static const char* GetSideDirection( sal_uInt8 nDirection );
+ static const char* GetCornerDirection( sal_uInt8 nDirection );
+ static const char* Get8Direction( sal_uInt8 nDirection );
+ static int GetPPTXLayoutId( int nOffset );
+
+protected:
+
+ virtual void ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNum, sal_uInt16 nMode,
+ sal_Bool bHasBackground, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
+ virtual void ImplWriteNotes( sal_uInt32 nPageNum );
+ virtual void ImplWriteSlideMaster( sal_uInt32 nPageNum, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
+ virtual void ImplWriteLayout( sal_Int32 nOffset, sal_uInt32 nMasterNum );
+ void ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMasterNum );
+ void WriteTheme( sal_Int32 nThemeNum );
+
+ virtual sal_Bool ImplCreateDocument();
+ virtual sal_Bool ImplCreateMainNotes();
+ virtual ::oox::ole::VbaProject* implCreateVbaProject() const;
+ sal_Bool WriteNotesMaster();
+
+ void WriteAnimateTo( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Any aValue, const ::rtl::OUString& rAttributeName );
+ void WriteAnimateValues( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimate >& rXAnimate );
+ void WriteAnimationCondition( ::sax_fastparser::FSHelperPtr pFS, ::com::sun::star::uno::Any& rAny, sal_Bool bWriteEvent, sal_Bool bMainSeqChild );
+ void WriteAnimationCondition( ::sax_fastparser::FSHelperPtr pFS, const char* pDelay, const char* pEvent, double fDelay, sal_Bool bHasFDelay );
+ void WriteAnimations( ::sax_fastparser::FSHelperPtr pFS );
+ void WriteAnimationAttributeName( ::sax_fastparser::FSHelperPtr pFS, const ::rtl::OUString& rAttributeName );
+ void WriteAnimationNode( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Bool bMainSeqChild );
+ void WriteAnimationNodeAnimate( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, sal_Bool bMainSeqChild );
+ void WriteAnimationNodeAnimateInside( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Bool bMainSeqChild, sal_Bool bSimple );
+ void WriteAnimationNodeSeq( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, sal_Bool bMainSeqChild );
+ void WriteAnimationNodeEffect( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, sal_Bool bMainSeqChild );
+ void WriteAnimationNodeCommonPropsStart( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& rXNode, sal_Bool bSingle, sal_Bool bMainSeqChild );
+ void WriteAnimationNodeCommonPropsEnd( ::sax_fastparser::FSHelperPtr pFS );
+ void WriteAnimationProperty( ::sax_fastparser::FSHelperPtr pFS, const ::com::sun::star::uno::Any& rAny );
+ void WriteAnimationTarget( ::sax_fastparser::FSHelperPtr pFS, ::com::sun::star::uno::Any aTarget );
+ bool WriteComments( sal_uInt32 nPageNum );
+ void WriteTextStyles( ::sax_fastparser::FSHelperPtr pFS );
+ void WriteTextStyle( ::sax_fastparser::FSHelperPtr pFS, int nInstance, sal_Int32 xmlToken );
+ void WriteTextStyleLevel( ::sax_fastparser::FSHelperPtr pFS, int nInstance, int nLevel );
+ void ImplWriteBackground( ::sax_fastparser::FSHelperPtr pFS, ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
+ void WriteTransition( ::sax_fastparser::FSHelperPtr pFS );
+
+ sal_Int32 GetLayoutFileId( sal_Int32 nOffset, sal_uInt32 nMasterNum );
+
+ // shapes
+ void WriteShapeTree( ::sax_fastparser::FSHelperPtr pFS, PageType ePageType, sal_Bool bMaster );
+
+ sal_uInt32 GetNewSlideId() { return mnSlideIdMax ++; }
+ sal_uInt32 GetNewSlideMasterId() { return mnSlideMasterIdMax ++; }
+ sal_Int32 GetAuthorIdAndLastIndex( ::rtl::OUString sAuthor, sal_Int32& nLastIndex );
+
+private:
+ void AddLayoutIdAndRelation( ::sax_fastparser::FSHelperPtr pFS, sal_Int32 nLayoutFileId );
+
+ virtual ::rtl::OUString implGetImplementationName() const;
+
+ ::boost::shared_ptr< ::oox::drawingml::chart::ChartConverter > mxChartConv;
+
+ ::sax_fastparser::FSHelperPtr mPresentationFS;
+
+ LayoutInfo mLayoutInfo[EPP_LAYOUT_SIZE];
+ std::vector< ::sax_fastparser::FSHelperPtr > mpSlidesFSArray;
+ std::vector< ::sax_fastparser::FSHelperPtr > mpMasterFSArray;
+ sal_Int32 mnLayoutFileIdMax;
+
+ sal_uInt32 mnSlideIdMax;
+ sal_uInt32 mnSlideMasterIdMax;
+ sal_uInt32 mnAnimationNodeIdMax;
+
+ sal_Bool mbCreateNotes;
+
+ static sal_Int32 nStyleLevelToken[5];
+
+ ::oox::drawingml::ShapeExport::ShapeHashMap maShapeMap;
+
+ struct AuthorComments {
+ sal_Int32 nId;
+ sal_Int32 nLastIndex;
+ };
+ typedef ::boost::unordered_map< ::rtl::OUString, struct AuthorComments, comphelper::UStringHash, comphelper::UStringEqual > AuthorsMap;
+ AuthorsMap maAuthors;
+
+ void WriteAuthors();
+};
+
+}
+}
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx
index 8a8c2ceb7..14ac23935 100644
--- a/sd/source/filter/eppt/epptso.cxx
+++ b/sd/source/filter/eppt/epptso.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,10 +30,9 @@
#include "precompiled_sd.hxx"
#include <osl/endian.h>
#include <eppt.hxx>
+#include "text.hxx"
#include "epptdef.hxx"
-#ifndef _PptEscherEx_HXX
#include "escherex.hxx"
-#endif
#include <tools/poly.hxx>
#include <vcl/bmpacc.hxx>
#include <vcl/gradient.hxx>
@@ -44,9 +44,6 @@
#include <vcl/gradient.hxx>
#include <sfx2/app.hxx>
#include <svl/languageoptions.hxx>
-//#ifndef _SVX_XIT_HXX
-//#include <svx/xit.hxx>
-//#endif
#include <editeng/svxenum.hxx>
#include <svx/unoapi.hxx>
#include <svx/svdoashp.hxx>
@@ -54,12 +51,8 @@
#include <com/sun/star/container/XIndexReplace.hpp>
#include <com/sun/star/presentation/XPresentationPage.hpp>
#include <com/sun/star/awt/XFont.hpp>
-#ifndef _COM_SUN_STAR_AWT_XFONTWEIGHT_HPP_
#include <com/sun/star/awt/FontWeight.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XFONTUNDERLINE_HPP_
#include <com/sun/star/awt/FontUnderline.hpp>
-#endif
#include <com/sun/star/style/ParagraphAdjust.hpp>
#include <com/sun/star/style/LineSpacing.hpp>
#include <com/sun/star/style/LineSpacingMode.hpp>
@@ -81,44 +74,24 @@
#include <com/sun/star/embed/Aspects.hpp>
#include <vcl/cvtgrf.hxx>
#include <tools/urlobj.hxx>
-#ifndef _CPPUHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _CPPUHELPER_PROPTYPEHLP_HXX_
#include <cppuhelper/proptypehlp.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX_
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENTBROKER_HXX_
#include <ucbhelper/contentbroker.hxx>
-#endif
-#ifndef _TOOLKIT_UNOHLP_HXX
#include <toolkit/unohlp.hxx>
-#endif
#include <rtl/crc.h>
#include <sot/clsids.hxx>
#include <unotools/ucbstreamhelper.hxx>
#include <com/sun/star/text/FontRelief.hpp>
#include <editeng/frmdiritem.hxx>
-/*
-#include <editeng/outliner.hxx>
-#include <editeng/outlobj.hxx>
-#include <svx/svdmodel.hxx>
-*/
#include <svtools/fltcall.hxx>
#include <com/sun/star/table/XTable.hpp>
#include <com/sun/star/table/XMergeableCell.hpp>
#include <com/sun/star/table/BorderLine.hpp>
#include <set>
-//#include <svx/xbtmpit.hxx>
-
#include "i18npool/mslangid.hxx"
-#include <vos/xception.hxx>
-using namespace vos;
-
using namespace ::com::sun::star;
////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -149,9 +122,6 @@ using namespace ::com::sun::star;
// ---------------------------------------------------------------------------------------------
-com::sun::star::uno::Reference< com::sun::star::i18n::XBreakIterator > xPPTBreakIter;
-com::sun::star::uno::Reference< com::sun::star::i18n::XScriptTypeDetector > xScriptTypeDetector;
-
PPTExBulletProvider::PPTExBulletProvider()
{
pGraphicProv = new EscherGraphicProvider( _E_GRAPH_PROV_USE_INSTANCES | _E_GRAPH_PROV_DO_NOT_ROTATE_METAFILES );
@@ -165,7 +135,6 @@ PPTExBulletProvider::~PPTExBulletProvider()
sal_uInt16 PPTExBulletProvider::GetId( const ByteString& rUniqueId, Size& rGraphicSize )
{
sal_uInt16 nRetValue = 0xffff;
- sal_uInt32 nId = 0;
if ( rUniqueId.Len() )
{
@@ -199,8 +168,7 @@ sal_uInt16 PPTExBulletProvider::GetId( const ByteString& rUniqueId, Size& rGraph
aGraphicObject = GraphicObject( aMappedGraphic );
}
}
-
- nId = pGraphicProv->GetBlibID( aBuExPictureStream, aGraphicObject.GetUniqueID(), aRect, NULL, NULL );
+ sal_uInt32 nId = pGraphicProv->GetBlibID( aBuExPictureStream, aGraphicObject.GetUniqueID(), aRect, NULL, NULL );
if ( nId && ( nId < 0x10000 ) )
nRetValue = (sal_uInt16)nId - 1;
@@ -210,211 +178,6 @@ sal_uInt16 PPTExBulletProvider::GetId( const ByteString& rUniqueId, Size& rGraph
// ---------------------------------------------------------------------------------------------
-GroupTable::GroupTable() :
- mnCurrentGroupEntry ( 0 ),
- mnMaxGroupEntry ( 0 ),
- mnGroupsClosed ( 0 ),
- mpGroupEntry ( NULL )
-{
- ImplResizeGroupTable( 32 );
-}
-
-// ---------------------------------------------------------------------------------------------
-
-GroupTable::~GroupTable()
-{
- for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; delete mpGroupEntry[ i++ ] ) ;
- delete[] mpGroupEntry;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-void GroupTable::ImplResizeGroupTable( sal_uInt32 nEntrys )
-{
- if ( nEntrys > mnMaxGroupEntry )
- {
- mnMaxGroupEntry = nEntrys;
- GroupEntry** pTemp = new GroupEntry*[ nEntrys ];
- for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; i++ )
- pTemp[ i ] = mpGroupEntry[ i ];
- if ( mpGroupEntry )
- delete[] mpGroupEntry;
- mpGroupEntry = pTemp;
- }
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool GroupTable::EnterGroup( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >& rXIndexAccessRef )
-{
- sal_Bool bRet = sal_False;
- if ( rXIndexAccessRef.is() )
- {
- GroupEntry* pNewGroup = new GroupEntry( rXIndexAccessRef );
- if ( pNewGroup->mnCount )
- {
- if ( mnMaxGroupEntry == mnCurrentGroupEntry )
- ImplResizeGroupTable( mnMaxGroupEntry + 8 );
- mpGroupEntry[ mnCurrentGroupEntry++ ] = pNewGroup;
- bRet = sal_True;
- }
- else
- delete pNewGroup;
- }
- return bRet;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_uInt32 GroupTable::GetGroupsClosed()
-{
- sal_uInt32 nRet = mnGroupsClosed;
- mnGroupsClosed = 0;
- return nRet;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-void GroupTable::ClearGroupTable()
-{
- for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; i++, delete mpGroupEntry[ i ] ) ;
- mnCurrentGroupEntry = 0;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-void GroupTable::ResetGroupTable( sal_uInt32 nCount )
-{
- ClearGroupTable();
- mpGroupEntry[ mnCurrentGroupEntry++ ] = new GroupEntry( nCount );
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool GroupTable::GetNextGroupEntry()
-{
- while ( mnCurrentGroupEntry )
- {
- mnIndex = mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mnCurrentPos++;
-
- if ( mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mnCount > mnIndex )
- return sal_True;
-
- delete ( mpGroupEntry[ --mnCurrentGroupEntry ] );
-
- if ( mnCurrentGroupEntry )
- mnGroupsClosed++;
- }
- return sal_False;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-FontCollectionEntry::~FontCollectionEntry()
-{
-}
-
-// ---------------------------------------------------------------------------------------------
-
-void FontCollectionEntry::ImplInit( const String& rName )
-{
- String aSubstName( GetSubsFontName( rName, SUBSFONT_ONLYONE | SUBSFONT_MS ) );
- if ( aSubstName.Len() )
- {
- Name = aSubstName;
- bIsConverted = sal_True;
- }
- else
- {
- Name = rName;
- bIsConverted = sal_False;
- }
-}
-
-FontCollection::~FontCollection()
-{
- for( void* pStr = List::First(); pStr; pStr = List::Next() )
- delete (FontCollectionEntry*)pStr;
- delete pVDev;
- xPPTBreakIter = NULL;
- xScriptTypeDetector = NULL;
-}
-
-FontCollection::FontCollection() :
- pVDev ( NULL )
-{
- com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >
- xMSF = ::comphelper::getProcessServiceFactory();
- com::sun::star::uno::Reference< com::sun::star::uno::XInterface >
- xInterface = xMSF->createInstance( rtl::OUString::createFromAscii( "com.sun.star.i18n.BreakIterator" ) );
- if ( xInterface.is() )
- xPPTBreakIter = com::sun::star::uno::Reference< com::sun::star::i18n::XBreakIterator >
- ( xInterface, com::sun::star::uno::UNO_QUERY );
-
- xInterface = xMSF->createInstance( rtl::OUString::createFromAscii( "com.sun.star.i18n.ScriptTypeDetector" ) );
- if ( xInterface.is() )
- xScriptTypeDetector = com::sun::star::uno::Reference< com::sun::star::i18n::XScriptTypeDetector >
- ( xInterface, com::sun::star::uno::UNO_QUERY );
-}
-
-short FontCollection::GetScriptDirection( const String& rString ) const
-{
- short nRet = com::sun::star::i18n::ScriptDirection::NEUTRAL;
- if ( xScriptTypeDetector.is() )
- {
- const rtl::OUString sT( rString );
- nRet = xScriptTypeDetector->getScriptDirection( sT, 0, com::sun::star::i18n::ScriptDirection::NEUTRAL );
- }
- return nRet;
-}
-
-sal_uInt32 FontCollection::GetId( FontCollectionEntry& rEntry )
-{
- if( rEntry.Name.Len() )
- {
- const sal_uInt32 nFonts = GetCount();
-
- for( sal_uInt32 i = 0; i < nFonts; i++ )
- {
- const FontCollectionEntry* pEntry = GetById( i );
- if( pEntry->Name == rEntry.Name )
- return i;
- }
- Font aFont;
- aFont.SetCharSet( rEntry.CharSet );
- aFont.SetName( rEntry.Original );
-// aFont.SetFamily( rEntry.Family );
-// aFont.SetPitch( rEntry.Pitch );
- aFont.SetHeight( 100 );
-
- if ( !pVDev )
- pVDev = new VirtualDevice;
-
- pVDev->SetFont( aFont );
- FontMetric aMetric( pVDev->GetFontMetric() );
-
- sal_uInt16 nTxtHeight = (sal_uInt16)aMetric.GetAscent() + (sal_uInt16)aMetric.GetDescent();
-
- if ( nTxtHeight )
- {
- double fScaling = (double)nTxtHeight / 120.0;
- if ( ( fScaling > 0.50 ) && ( fScaling < 1.5 ) )
- rEntry.Scaling = fScaling;
- }
-
- List::Insert( new FontCollectionEntry( rEntry ), LIST_APPEND );
- return nFonts;
- }
- return 0;
-}
-
-const FontCollectionEntry* FontCollection::GetById( sal_uInt32 nId )
-{
- return (FontCollectionEntry*)List::GetObject( nId );
-}
-
-// ---------------------------------------------------------------------------------------------
-
sal_uInt32 PPTWriter::ImplVBAInfoContainer( SvStream* pStrm )
{
sal_uInt32 nSize = 28;
@@ -711,7 +474,7 @@ sal_Bool PPTWriter::ImplCloseDocument()
SvMemoryStream aTxMasterStyleAtomStrm( 0x200, 0x200 );
{
EscherExAtom aTxMasterStyleAtom( aTxMasterStyleAtomStrm, EPP_TxMasterStyleAtom, EPP_TEXTTYPE_Other );
- aTxMasterStyleAtomStrm << (sal_uInt16)5; // paragraph count
+ aTxMasterStyleAtomStrm << (sal_uInt16)5; // paragraph count
sal_uInt16 nLev;
sal_Bool bFirst = sal_True;
for ( nLev = 0; nLev < 5; nLev++ )
@@ -730,7 +493,7 @@ sal_Bool PPTWriter::ImplCloseDocument()
+ 8 // 1 FontCollection Container
+ 20 // SrKinsoku Container
+ 18 // 1 TxSiStyleAtom
- + aTxMasterStyleAtomStrm.Tell() // 1 TxMasterStyleAtom;
+ + aTxMasterStyleAtomStrm.Tell() // 1 TxMasterStyleAtom;
+ mpStyleSheet->SizeOfTxCFStyleAtom();
sal_uInt32 nBytesToInsert = nEnvironment + 8;
@@ -964,360 +727,6 @@ sal_Bool PropStateValue::ImplGetPropertyValue( const String& rString, sal_Bool b
// ---------------------------------------------------------------------------------------------
-sal_Bool PPTWriter::ImplInitSOIface()
-{
- while( sal_True )
- {
- mXDrawPagesSupplier = ::com::sun::star::uno::Reference<
- ::com::sun::star::drawing::XDrawPagesSupplier >
- ( mXModel, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXDrawPagesSupplier.is() )
- break;
-
- mXMasterPagesSupplier = ::com::sun::star::uno::Reference<
- ::com::sun::star::drawing::XMasterPagesSupplier >
- ( mXModel, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXMasterPagesSupplier.is() )
- break;
- mXDrawPages = mXMasterPagesSupplier->getMasterPages();
- if ( !mXDrawPages.is() )
- break;
- mnMasterPages = mXDrawPages->getCount();
- mXDrawPages = mXDrawPagesSupplier->getDrawPages();
- if( !mXDrawPages.is() )
- break;
- mnPages = mXDrawPages->getCount();
- if ( !ImplGetPageByIndex( 0, NORMAL ) )
- break;
-
- return sal_True;
- }
- return sal_False;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplSetCurrentStyleSheet( sal_uInt32 nPageNum )
-{
- sal_Bool bRet = sal_False;
- if ( nPageNum >= maStyleSheetList.size() )
- nPageNum = 0;
- else
- bRet = sal_True;
- mpStyleSheet = maStyleSheetList[ nPageNum ];
- return bRet;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplGetPageByIndex( sal_uInt32 nIndex, PageType ePageType )
-{
- while( sal_True )
- {
- if ( ePageType != meLatestPageType )
- {
- switch( ePageType )
- {
- case NORMAL :
- case NOTICE :
- {
- mXDrawPages = mXDrawPagesSupplier->getDrawPages();
- if( !mXDrawPages.is() )
- return sal_False;
- }
- break;
-
- case MASTER :
- {
- mXDrawPages = mXMasterPagesSupplier->getMasterPages();
- if( !mXDrawPages.is() )
- return sal_False;
- }
- break;
- default:
- break;
- }
- meLatestPageType = ePageType;
- }
- ::com::sun::star::uno::Any aAny( mXDrawPages->getByIndex( nIndex ) );
- aAny >>= mXDrawPage;
- if ( !mXDrawPage.is() )
- break;
- if ( ePageType == NOTICE )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::presentation::XPresentationPage >
- aXPresentationPage( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( !aXPresentationPage.is() )
- break;
- mXDrawPage = aXPresentationPage->getNotesPage();
- if ( !mXDrawPage.is() )
- break;
- }
- mXPagePropSet = ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXPagePropSet.is() )
- break;
-
- mXShapes = ::com::sun::star::uno::Reference<
- ::com::sun::star::drawing::XShapes >
- ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( !mXShapes.is() )
- break;
-
- /* try to get the "real" background PropertySet. If the normal page is not supporting this property, it is
- taken the property from the master */
- sal_Bool bHasBackground = GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ), sal_True );
- if ( bHasBackground )
- bHasBackground = ( aAny >>= mXBackgroundPropSet );
- if ( !bHasBackground )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPageTarget >
- aXMasterPageTarget( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( aXMasterPageTarget.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage > aXMasterDrawPage;
- aXMasterDrawPage = aXMasterPageTarget->getMasterPage();
- if ( aXMasterDrawPage.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXMasterPagePropSet;
- aXMasterPagePropSet = ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- ( aXMasterDrawPage, ::com::sun::star::uno::UNO_QUERY );
- if ( aXMasterPagePropSet.is() )
- {
- sal_Bool bBackground = GetPropertyValue( aAny, aXMasterPagePropSet,
- String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) );
- if ( bBackground )
- {
- aAny >>= mXBackgroundPropSet;
- }
- }
- }
- }
- }
- return sal_True;
- }
- return sal_False;
-}
-
-// ---------------------------------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplGetShapeByIndex( sal_uInt32 nIndex, sal_Bool bGroup )
-{
- while(sal_True)
- {
- if ( ( bGroup == sal_False ) || ( GetCurrentGroupLevel() == 0 ) )
- {
- ::com::sun::star::uno::Any aAny( mXShapes->getByIndex( nIndex ) );
- aAny >>= mXShape;
- }
- else
- {
- ::com::sun::star::uno::Any aAny( GetCurrentGroupAccess()->getByIndex( GetCurrentGroupIndex() ) );
- aAny >>= mXShape;
- }
- if ( !mXShape.is() )
- break;
-
- ::com::sun::star::uno::Any aAny( mXShape->queryInterface( ::getCppuType( (const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >*) 0 ) ));
- aAny >>= mXPropSet;
-
- if ( !mXPropSet.is() )
- break;
- maPosition = ImplMapPoint( mXShape->getPosition() );
- maSize = ImplMapSize( mXShape->getSize() );
- maRect = Rectangle( Point( maPosition.X, maPosition.Y ), Size( maSize.Width, maSize.Height ) );
- mType = ByteString( String( mXShape->getShapeType() ), RTL_TEXTENCODING_UTF8 );
- mType.Erase( 0, 13 ); // "com.sun.star." entfernen
- sal_uInt16 nPos = mType.Search( (const char*)"Shape" );
- mType.Erase( nPos, 5 );
-
- mbPresObj = mbEmptyPresObj = sal_False;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsPresentationObject" ) ) ) )
- mAny >>= mbPresObj;
-
- if ( mbPresObj && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsEmptyPresentationObject" ) ) ) )
- mAny >>= mbEmptyPresObj;
-
- mnAngle = ( PropValue::GetPropertyValue( aAny,
- mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "RotateAngle" ) ), sal_True ) )
- ? *((sal_Int32*)aAny.getValue() )
- : 0;
-
- return sal_True;
- }
- return sal_False;
-}
-
-// -----------------------------------------------------------------------
-
-sal_uInt32 PPTWriter::ImplGetMasterIndex( PageType ePageType )
-{
- sal_uInt32 nRetValue = 0;
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPageTarget >
- aXMasterPageTarget( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
-
- if ( aXMasterPageTarget.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage >
- aXDrawPage = aXMasterPageTarget->getMasterPage();
- if ( aXDrawPage.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- aXPropertySet( aXDrawPage, ::com::sun::star::uno::UNO_QUERY );
-
- if ( aXPropertySet.is() )
- {
- if ( ImplGetPropertyValue( aXPropertySet, String( RTL_CONSTASCII_USTRINGPARAM( "Number" ) ) ) )
- nRetValue |= *(sal_Int16*)mAny.getValue();
- if ( nRetValue & 0xffff ) // ueberlauf vermeiden
- nRetValue--;
- }
- }
- }
- if ( ePageType == NOTICE )
- nRetValue += mnMasterPages;
- return nRetValue;
-}
-
-// -----------------------------------------------------------------------
-
-sal_Bool PPTWriter::ImplGetStyleSheets()
-{
- int nInstance, nLevel;
- sal_Bool bRetValue = sal_False;
- sal_uInt32 nPageNum;
-
- for ( nPageNum = 0; nPageNum < mnMasterPages; nPageNum++ )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed >
- aXNamed;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >
- aXNameAccess;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::style::XStyleFamiliesSupplier >
- aXStyleFamiliesSupplier( mXModel, ::com::sun::star::uno::UNO_QUERY );
-
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- aXPropSet( mXModel, ::com::sun::star::uno::UNO_QUERY );
-
- sal_uInt16 nDefaultTab = ( aXPropSet.is() && ImplGetPropertyValue( aXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TabStop" ) ) ) )
- ? (sal_uInt16)( *(sal_Int32*)mAny.getValue() / 4.40972 )
- : 1250;
-
- maStyleSheetList.push_back( new PPTExStyleSheet( nDefaultTab, (PPTExBulletProvider&)*this ) );
- ImplSetCurrentStyleSheet( nPageNum );
- if ( ImplGetPageByIndex( nPageNum, MASTER ) )
- aXNamed = ::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed >
- ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
-
- if ( aXStyleFamiliesSupplier.is() )
- aXNameAccess = aXStyleFamiliesSupplier->getStyleFamilies();
-
- bRetValue = aXNamed.is() && aXNameAccess.is() && aXStyleFamiliesSupplier.is();
- if ( bRetValue )
- {
- for ( nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_CenterTitle; nInstance++ )
- {
- String aStyle;
- String aFamily;
- switch ( nInstance )
- {
- case EPP_TEXTTYPE_CenterTitle :
- case EPP_TEXTTYPE_Title :
- {
- aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "title" ) );
- aFamily = aXNamed->getName();
- }
- break;
- case EPP_TEXTTYPE_Body :
- {
- aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "outline1" ) ); // SD_LT_SEPARATOR
- aFamily = aXNamed->getName();
- }
- break;
- case EPP_TEXTTYPE_Other :
- {
- aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "standard" ) );
- aFamily = String( RTL_CONSTASCII_USTRINGPARAM( "graphics" ) );
- }
- break;
- case EPP_TEXTTYPE_CenterBody :
- {
- aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "subtitle" ) );
- aFamily = aXNamed->getName();
- }
- break;
- }
- if ( aStyle.Len() && aFamily.Len() )
- {
- try
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >xNameAccess;
- if ( aXNameAccess->hasByName( aFamily ) )
- {
- ::com::sun::star::uno::Any aAny( aXNameAccess->getByName( aFamily ) );
- if( aAny.getValue() && ::cppu::extractInterface( xNameAccess, aAny ) )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > aXFamily;
- if ( aAny >>= aXFamily )
- {
- if ( aXFamily->hasByName( aStyle ) )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::style::XStyle > xStyle;
- aAny = aXFamily->getByName( aStyle );
- if( aAny.getValue() && ::cppu::extractInterface( xStyle, aAny ) )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::style::XStyle > aXStyle;
- aAny >>= aXStyle;
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- xPropSet( aXStyle, ::com::sun::star::uno::UNO_QUERY );
- if( xPropSet.is() )
- mpStyleSheet->SetStyleSheet( xPropSet, maFontCollection, nInstance, 0 );
- for ( nLevel = 1; nLevel < 5; nLevel++ )
- {
- if ( nInstance == EPP_TEXTTYPE_Body )
- {
- sal_Unicode cTemp = aStyle.GetChar( aStyle.Len() - 1 );
- aStyle.SetChar( aStyle.Len() - 1, ++cTemp );
- if ( aXFamily->hasByName( aStyle ) )
- {
- aXFamily->getByName( aStyle ) >>= xStyle;
- if( xStyle.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- xPropertySet( xStyle, ::com::sun::star::uno::UNO_QUERY );
- if ( xPropertySet.is() )
- mpStyleSheet->SetStyleSheet( xPropertySet, maFontCollection, nInstance, nLevel );
- }
- }
- }
- else
- mpStyleSheet->SetStyleSheet( xPropSet, maFontCollection, nInstance, nLevel );
- }
- }
- }
- }
- }
- }
- }
- catch( ::com::sun::star::uno::Exception& )
- {
- //
- }
- }
- }
- for ( ; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
- {
-
- }
- }
- }
- return bRetValue;
-}
-
-// -----------------------------------------------------------------------
-
void PPTWriter::ImplWriteParagraphs( SvStream& rOut, TextObj& rTextObj )
{
sal_Bool bFirstParagraph = sal_True;
@@ -1349,7 +758,7 @@ void PPTWriter::ImplWriteParagraphs( SvStream& rOut, TextObj& rTextObj )
fN *= pDesc->Scaling;
nNormalSpacing = (sal_Int16)( fN + 0.5 );
}
- if ( !mbFontIndependentLineSpacing && bFirstParagraph && ( nLineSpacing > nNormalSpacing ) ) // sj: i28747, no replacement for fixed linespacing
+ if ( !mbFontIndependentLineSpacing && bFirstParagraph && ( nLineSpacing > nNormalSpacing ) ) // sj: i28747, no replacement for fixed linespacing
{
nLineSpacing = nNormalSpacing;
nPropertyFlags |= 0x00001000;
@@ -1363,7 +772,7 @@ void PPTWriter::ImplWriteParagraphs( SvStream& rOut, TextObj& rTextObj )
}
else
{
- if ( pPortion && pPortion->mnCharHeight > (sal_uInt16)( ((double)-nLineSpacing) * 0.001 * 72.0 / 2.54 ) ) // 1/100mm to point
+ if ( !pPara->mbFixedLineSpacing && pPortion && pPortion->mnCharHeight > (sal_uInt16)( ((double)-nLineSpacing) * 0.001 * 72.0 / 2.54 ) ) // 1/100mm to point
nLineSpacing = nNormalSpacing;
else
nLineSpacing = (sal_Int16)( (double)nLineSpacing / 4.40972 );
@@ -1388,7 +797,6 @@ void PPTWriter::ImplWriteParagraphs( SvStream& rOut, TextObj& rTextObj )
( mpStyleSheet->IsHardAttribute( nInstance, nDepth, ParaAttr_BiDi, pPara->mnBiDi ) ) )
nPropertyFlags |= 0x00200000;
-
sal_Int32 nBuRealSize = pPara->nBulletRealSize;
sal_Int16 nBulletFlags = pPara->nBulletFlags;
@@ -1483,8 +891,8 @@ void PPTWriter::ImplWritePortions( SvStream& rOut, TextObj& rTextObj )
{
sal_uInt32 nBackgroundColor = 0xffffff;
- if ( !nCharColor ) // special threatment for
- nCharColor = 0xffffff; // black fontcolor
+ if ( !nCharColor ) // special threatment for
+ nCharColor = 0xffffff; // black fontcolor
::com::sun::star::uno::Any aAny;
::com::sun::star::drawing::FillStyle aFS( ::com::sun::star::drawing::FillStyle_NONE );
@@ -1552,7 +960,7 @@ void PPTWriter::ImplWritePortions( SvStream& rOut, TextObj& rTextObj )
// not possible to export the 'embossed' flag
if ( ( GetCurrentGroupLevel() > 0 ) && ( GetCurrentGroupIndex() >= 1 ) )
{
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > aGroupedShape( GetCurrentGroupAccess()->getByIndex( GetCurrentGroupIndex() - 1 ), uno::UNO_QUERY );
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > aGroupedShape( GetCurrentGroupAccess()->getByIndex( GetCurrentGroupIndex() - 1 ), uno::UNO_QUERY );
if( aGroupedShape.is() )
{
::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aPropSetOfNextShape
@@ -1694,1362 +1102,6 @@ void PPTWriter::ImplFlipBoundingBox( EscherPropertyContainer& rPropOpt )
// -----------------------------------------------------------------------
-struct FieldEntry
-{
- sal_uInt32 nFieldType;
- sal_uInt32 nFieldStartPos;
- sal_uInt32 nFieldEndPos;
- String aRepresentation;
- String aFieldUrl;
-
- FieldEntry( sal_uInt32 nType, sal_uInt32 nStart, sal_uInt32 nEnd )
- {
- nFieldType = nType;
- nFieldStartPos = nStart;
- nFieldEndPos = nEnd;
- }
-};
-
-// -----------------------------------------------------------------------
-
-PortionObj::PortionObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
- FontCollection& rFontCollection ) :
- mnCharAttrHard ( 0 ),
- mnCharAttr ( 0 ),
- mnFont ( 0 ),
- mnAsianOrComplexFont( 0xffff ),
- mnTextSize ( 0 ),
- mbLastPortion ( sal_True ),
- mpText ( NULL ),
- mpFieldEntry ( NULL )
-{
- mXPropSet = rXPropSet;
-
- ImplGetPortionValues( rFontCollection, sal_False );
-}
-
-PortionObj::PortionObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRange,
- sal_Bool bLast, FontCollection& rFontCollection ) :
- mnCharAttrHard ( 0 ),
- mnCharAttr ( 0 ),
- mnFont ( 0 ),
- mnAsianOrComplexFont ( 0xffff ),
- mbLastPortion ( bLast ),
- mpText ( NULL ),
- mpFieldEntry ( NULL )
-{
- String aString( rXTextRange->getString() );
- String aURL;
- sal_Bool bRTL_endingParen = sal_False;
-
- mnTextSize = aString.Len();
- if ( bLast )
- mnTextSize++;
-
- if ( mnTextSize )
- {
- mpFieldEntry = NULL;
- sal_uInt32 nFieldType = 0;
-
- mXPropSet = ::com::sun::star::uno::Reference<
- ::com::sun::star::beans::XPropertySet >
- ( rXTextRange, ::com::sun::star::uno::UNO_QUERY );
- mXPropState = ::com::sun::star::uno::Reference<
- ::com::sun::star::beans::XPropertyState >
- ( rXTextRange, ::com::sun::star::uno::UNO_QUERY );
-
- sal_Bool bPropSetsValid = ( mXPropSet.is() && mXPropState.is() );
- if ( bPropSetsValid )
- nFieldType = ImplGetTextField( rXTextRange, mXPropSet, aURL );
- if ( nFieldType )
- {
- mpFieldEntry = new FieldEntry( nFieldType, 0, mnTextSize );
- if ( ( nFieldType >> 28 == 4 ) )
- {
- mpFieldEntry->aRepresentation = aString;
- mpFieldEntry->aFieldUrl = aURL;
- }
- }
- sal_Bool bSymbol = sal_False;
-
- if ( bPropSetsValid && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSet" ) ), sal_False ) )
- {
- sal_Int16 nCharset;
- mAny >>= nCharset;
- if ( nCharset == ::com::sun::star::awt::CharSet::SYMBOL )
- bSymbol = sal_True;
- }
- if ( mpFieldEntry && ( nFieldType & 0x800000 ) ) // placeholder ?
- {
- mnTextSize = 1;
- if ( bLast )
- mnTextSize++;
- mpText = new sal_uInt16[ mnTextSize ];
- mpText[ 0 ] = 0x2a;
- }
- else
- {
- const sal_Unicode* pText = aString.GetBuffer();
- // For i39516 - a closing parenthesis that ends an RTL string is displayed backwards by PPT
- // Solution: add a Unicode Right-to-Left Mark, following the method described in i18024
- if ( bLast && pText[ aString.Len() - 1 ] == sal_Unicode(')') && rFontCollection.GetScriptDirection( aString ) == com::sun::star::i18n::ScriptDirection::RIGHT_TO_LEFT )
- {
- mnTextSize++;
- bRTL_endingParen = sal_True;
- }
- mpText = new sal_uInt16[ mnTextSize ];
- sal_uInt16 nChar;
- for ( int i = 0; i < aString.Len(); i++ )
- {
- nChar = (sal_uInt16)pText[ i ];
- if ( nChar == 0xa )
- nChar++;
- else if ( !bSymbol )
- {
- switch ( nChar )
- {
- // Currency
- case 128: nChar = 0x20AC; break;
- // Punctuation and other
- case 130: nChar = 0x201A; break;// SINGLE LOW-9 QUOTATION MARK
- case 131: nChar = 0x0192; break;// LATIN SMALL LETTER F WITH HOOK
- case 132: nChar = 0x201E; break;// DOUBLE LOW-9 QUOTATION MARK
- // LOW DOUBLE PRIME QUOTATION MARK
- case 133: nChar = 0x2026; break;// HORIZONTAL ELLIPSES
- case 134: nChar = 0x2020; break;// DAGGER
- case 135: nChar = 0x2021; break;// DOUBLE DAGGER
- case 136: nChar = 0x02C6; break;// MODIFIER LETTER CIRCUMFLEX ACCENT
- case 137: nChar = 0x2030; break;// PER MILLE SIGN
- case 138: nChar = 0x0160; break;// LATIN CAPITAL LETTER S WITH CARON
- case 139: nChar = 0x2039; break;// SINGLE LEFT-POINTING ANGLE QUOTATION MARK
- case 140: nChar = 0x0152; break;// LATIN CAPITAL LIGATURE OE
- case 142: nChar = 0x017D; break;// LATIN CAPITAL LETTER Z WITH CARON
- case 145: nChar = 0x2018; break;// LEFT SINGLE QUOTATION MARK
- // MODIFIER LETTER TURNED COMMA
- case 146: nChar = 0x2019; break;// RIGHT SINGLE QUOTATION MARK
- // MODIFIER LETTER APOSTROPHE
- case 147: nChar = 0x201C; break;// LEFT DOUBLE QUOTATION MARK
- // REVERSED DOUBLE PRIME QUOTATION MARK
- case 148: nChar = 0x201D; break;// RIGHT DOUBLE QUOTATION MARK
- // REVERSED DOUBLE PRIME QUOTATION MARK
- case 149: nChar = 0x2022; break;// BULLET
- case 150: nChar = 0x2013; break;// EN DASH
- case 151: nChar = 0x2014; break;// EM DASH
- case 152: nChar = 0x02DC; break;// SMALL TILDE
- case 153: nChar = 0x2122; break;// TRADE MARK SIGN
- case 154: nChar = 0x0161; break;// LATIN SMALL LETTER S WITH CARON
- case 155: nChar = 0x203A; break;// SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
- case 156: nChar = 0x0153; break;// LATIN SMALL LIGATURE OE
- case 158: nChar = 0x017E; break;// LATIN SMALL LETTER Z WITH CARON
- case 159: nChar = 0x0178; break;// LATIN CAPITAL LETTER Y WITH DIAERESIS
-// case 222: nChar = 0x00B6; break;// PILCROW SIGN / PARAGRAPH SIGN
- }
- }
- mpText[ i ] = nChar;
- }
- }
- if ( bRTL_endingParen )
- mpText[ mnTextSize - 2 ] = 0x200F; // Unicode Right-to-Left mark
-
- if ( bLast )
- mpText[ mnTextSize - 1 ] = 0xd;
-
- if ( bPropSetsValid )
- ImplGetPortionValues( rFontCollection, sal_True );
- }
-}
-
-PortionObj::PortionObj( const PortionObj& rPortionObj )
-: PropStateValue( rPortionObj )
-{
- ImplConstruct( rPortionObj );
-}
-
-PortionObj::~PortionObj()
-{
- ImplClear();
-}
-
-void PortionObj::Write( SvStream* pStrm, sal_Bool bLast )
-{
- sal_uInt32 nCount = mnTextSize;
- if ( bLast && mbLastPortion )
- nCount--;
- for ( sal_uInt32 i = 0; i < nCount; i++ )
- *pStrm << (sal_uInt16)mpText[ i ];
-}
-
-void PortionObj::ImplGetPortionValues( FontCollection& rFontCollection, sal_Bool bGetPropStateValue )
-{
-
- sal_Bool bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontName" ) ), bGetPropStateValue );
- meFontName = ePropState;
- if ( bOk )
- {
- FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
- sal_uInt32 nCount = rFontCollection.GetCount();
- mnFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
- if ( mnFont == nCount )
- {
- FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSet" ) ), sal_False ) )
- mAny >>= rFontDesc.CharSet;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamily" ) ), sal_False ) )
- mAny >>= rFontDesc.Family;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitch" ) ), sal_False ) )
- mAny >>= rFontDesc.Pitch;
- }
- }
-
- sal_Int16 nScriptType = SvtLanguageOptions::GetScriptTypeOfLanguage( Application::GetSettings().GetLanguage() );
- if ( mpText && mnTextSize && xPPTBreakIter.is() )
- {
- rtl::OUString sT( mpText, mnTextSize );
- nScriptType = xPPTBreakIter->getScriptType( sT, 0 );
- }
- if ( nScriptType != com::sun::star::i18n::ScriptType::COMPLEX )
- {
- bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontNameAsian" ) ), bGetPropStateValue );
- meAsianOrComplexFont = ePropState;
- if ( bOk )
- {
- FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
- sal_uInt32 nCount = rFontCollection.GetCount();
- mnAsianOrComplexFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
- if ( mnAsianOrComplexFont == nCount )
- {
- FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSetAsian" ) ), sal_False ) )
- mAny >>= rFontDesc.CharSet;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamilyAsian" ) ), sal_False ) )
- mAny >>= rFontDesc.Family;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitchAsian" ) ), sal_False ) )
- mAny >>= rFontDesc.Pitch;
- }
- }
- }
- else
- {
- bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontNameComplex" ) ), bGetPropStateValue );
- meAsianOrComplexFont = ePropState;
- if ( bOk )
- {
- FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
- sal_uInt32 nCount = rFontCollection.GetCount();
- mnAsianOrComplexFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
- if ( mnAsianOrComplexFont == nCount )
- {
- FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSetComplex" ) ), sal_False ) )
- mAny >>= rFontDesc.CharSet;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamilyComplex" ) ), sal_False ) )
- mAny >>= rFontDesc.Family;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitchComplex" ) ), sal_False ) )
- mAny >>= rFontDesc.Pitch;
- }
- }
- }
-
- rtl::OUString aCharHeightName, aCharWeightName, aCharLocaleName, aCharPostureName;
- switch( nScriptType )
- {
- case com::sun::star::i18n::ScriptType::ASIAN :
- {
- aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeightAsian" ) );
- aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeightAsian" ) );
- aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocaleAsian" ) );
- aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPostureAsian" ) );
- break;
- }
- case com::sun::star::i18n::ScriptType::COMPLEX :
- {
- aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeightComplex" ) );
- aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeightComplex" ) );
- aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocaleComplex" ) );
- aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPostureComplex" ) );
- break;
- }
- default:
- {
- aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeight" ) );
- aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeight" ) );
- aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocale" ) );
- aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPosture" ) );
- break;
- }
- }
-
- mnCharHeight = 24;
- if ( GetPropertyValue( mAny, mXPropSet, aCharHeightName, sal_False ) )
- {
- float fVal(0.0);
- if ( mAny >>= fVal )
- {
- mnCharHeight = (sal_uInt16)( fVal + 0.5 );
- meCharHeight = GetPropertyState( mXPropSet, aCharHeightName );
- }
- }
- if ( GetPropertyValue( mAny, mXPropSet, aCharWeightName, sal_False ) )
- {
- float fFloat(0.0);
- if ( mAny >>= fFloat )
- {
- if ( fFloat >= ::com::sun::star::awt::FontWeight::SEMIBOLD )
- mnCharAttr |= 1;
- if ( GetPropertyState( mXPropSet, aCharWeightName ) == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- mnCharAttrHard |= 1;
- }
- }
- if ( GetPropertyValue( mAny, mXPropSet, aCharLocaleName, sal_False ) )
- {
- com::sun::star::lang::Locale eLocale;
- if ( mAny >>= eLocale )
- meCharLocale = eLocale;
- }
- if ( GetPropertyValue( mAny, mXPropSet, aCharPostureName, sal_False ) )
- {
- ::com::sun::star::awt::FontSlant aFS;
- if ( mAny >>= aFS )
- {
- switch( aFS )
- {
- case ::com::sun::star::awt::FontSlant_OBLIQUE :
- case ::com::sun::star::awt::FontSlant_ITALIC :
- mnCharAttr |= 2;
- break;
- default:
- break;
- }
- if ( GetPropertyState( mXPropSet, aCharPostureName ) == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- mnCharAttrHard |= 2;
- }
- }
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharUnderline" ) ), bGetPropStateValue ) )
- {
- sal_Int16 nVal(0);
- mAny >>= nVal;
- switch ( nVal )
- {
- case ::com::sun::star::awt::FontUnderline::SINGLE :
- case ::com::sun::star::awt::FontUnderline::DOUBLE :
- case ::com::sun::star::awt::FontUnderline::DOTTED :
- mnCharAttr |= 4;
- }
- }
- if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- mnCharAttrHard |= 4;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharShadowed" ) ), bGetPropStateValue ) )
- {
- sal_Bool bBool(sal_False);
- mAny >>= bBool;
- if ( bBool )
- mnCharAttr |= 0x10;
- }
- if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- mnCharAttrHard |= 16;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharRelief" ) ), bGetPropStateValue ) )
- {
- sal_Int16 nVal(0);
- mAny >>= nVal;
- if ( nVal != ::com::sun::star::text::FontRelief::NONE )
- mnCharAttr |= 512;
- }
- if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- mnCharAttrHard |= 512;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharColor" ) ), bGetPropStateValue ) )
- {
- sal_uInt32 nSOColor = *( (sal_uInt32*)mAny.getValue() );
- mnCharColor = nSOColor & 0xff00ff00; // green and hibyte
- mnCharColor |= (sal_uInt8)( nSOColor ) << 16; // red and blue is switched
- mnCharColor |= (sal_uInt8)( nSOColor >> 16 );
- }
- meCharColor = ePropState;
-
- mnCharEscapement = 0;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharEscapement" ) ), bGetPropStateValue ) )
- {
- mAny >>= mnCharEscapement;
- if ( mnCharEscapement > 100 )
- mnCharEscapement = 33;
- else if ( mnCharEscapement < -100 )
- mnCharEscapement = -33;
- }
- meCharEscapement = ePropState;
-}
-
-void PortionObj::ImplClear()
-{
- delete (FieldEntry*)mpFieldEntry;
- delete[] mpText;
-}
-
-void PortionObj::ImplConstruct( const PortionObj& rPortionObj )
-{
- mbLastPortion = rPortionObj.mbLastPortion;
- mnTextSize = rPortionObj.mnTextSize;
- mnCharColor = rPortionObj.mnCharColor;
- mnCharEscapement = rPortionObj.mnCharEscapement;
- mnCharAttr = rPortionObj.mnCharAttr;
- mnCharHeight = rPortionObj.mnCharHeight;
- mnFont = rPortionObj.mnFont;
- mnAsianOrComplexFont = rPortionObj.mnAsianOrComplexFont;
-
- if ( rPortionObj.mpText )
- {
- mpText = new sal_uInt16[ mnTextSize ];
- memcpy( mpText, rPortionObj.mpText, mnTextSize << 1 );
- }
- else
- mpText = NULL;
-
- if ( rPortionObj.mpFieldEntry )
- mpFieldEntry = new FieldEntry( *( rPortionObj.mpFieldEntry ) );
- else
- mpFieldEntry = NULL;
-}
-
-sal_uInt32 PortionObj::ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition )
-{
- if ( mpFieldEntry && ( !mpFieldEntry->nFieldStartPos ) )
- {
- mpFieldEntry->nFieldStartPos += nCurrentTextPosition;
- mpFieldEntry->nFieldEndPos += nCurrentTextPosition;
- }
- return mnTextSize;
-}
-
-// -----------------------------------------------------------------------
-// Rueckgabe: 0 = kein TextField
-// bit28->31 text field type :
-// 1 = Date
-// 2 = Time
-// 3 = SlideNumber
-// 4 = Url
-// 5 = DateTime
-// 6 = header
-// 7 = footer
-// bit24->27 text field sub type (optional)
-// 23-> PPT Textfield needs a placeholder
-
-sal_uInt32 PortionObj::ImplGetTextField( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & ,
- const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet, String& rURL )
-{
- sal_uInt32 nRetValue = 0;
- sal_Int32 nFormat;
- ::com::sun::star::uno::Any aAny;
- if ( GetPropertyValue( aAny, rXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TextPortionType" ) ), sal_True ) )
- {
- String aTextFieldType( *(::rtl::OUString*)aAny.getValue() );
- if ( aTextFieldType == String( RTL_CONSTASCII_USTRINGPARAM( "TextField" ) ) )
- {
- if ( GetPropertyValue( aAny, rXPropSet, aTextFieldType, sal_True ) )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextField > aXTextField;
- if ( aAny >>= aXTextField )
- {
- if ( aXTextField.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
- xFieldPropSet( aXTextField, ::com::sun::star::uno::UNO_QUERY );
- if ( xFieldPropSet.is() )
- {
- String aFieldKind( aXTextField->getPresentation( sal_True ) );
- if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Date" ) ) )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
- {
- sal_Bool bBool;
- aAny >>= bBool;
- if ( !bBool ) // Fixed DateFields gibt es in PPT nicht
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Format" ) ) ), sal_True )
- {
- nFormat = *(sal_Int32*)aAny.getValue();
- switch ( nFormat )
- {
- default:
- case 5 :
- case 4 :
- case 2 : nFormat = 0; break;
- case 8 :
- case 9 :
- case 3 : nFormat = 1; break;
- case 7 :
- case 6 : nFormat = 2; break;
- }
- nRetValue |= ( ( ( 1 << 4 ) | nFormat ) << 24 ) | 0x800000;
- }
- }
- }
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "URL" ) ) )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "URL" ) ) ), sal_True )
- rURL = String( *(::rtl::OUString*)aAny.getValue() );
- nRetValue = 4 << 28;
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Page" ) ) )
- {
- nRetValue = 3 << 28 | 0x800000;
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Pages" ) ) )
- {
-
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Time" ) ) )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
- {
- sal_Bool bBool;
- aAny >>= bBool;
- if ( !bBool )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
- {
- nFormat = *(sal_Int32*)aAny.getValue();
- nRetValue |= ( ( ( 2 << 4 ) | nFormat ) << 24 ) | 0x800000;
- }
- }
- }
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "File" ) ) )
- {
-
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Table" ) ) )
- {
-
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "ExtTime" ) ) )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
- {
- sal_Bool bBool;
- aAny >>= bBool;
- if ( !bBool )
- {
- if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Format" ) ) ), sal_True )
- {
- nFormat = *(sal_Int32*)aAny.getValue();
- switch ( nFormat )
- {
- default:
- case 6 :
- case 7 :
- case 8 :
- case 2 : nFormat = 12; break;
- case 3 : nFormat = 9; break;
- case 5 :
- case 4 : nFormat = 10; break;
-
- }
- nRetValue |= ( ( ( 2 << 4 ) | nFormat ) << 24 ) | 0x800000;
- }
- }
- }
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "ExtFile" ) ) )
- {
-
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Author" ) ) )
- {
-
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "DateTime" ) ) )
- {
- nRetValue = 5 << 28 | 0x800000;
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Header" ) ) )
- {
- nRetValue = 6 << 28 | 0x800000;
- }
- else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Footer" ) ) )
- {
- nRetValue = 7 << 28 | 0x800000;
- }
- }
- }
- }
- }
- }
- }
- return nRetValue;
-}
-
-PortionObj& PortionObj::operator=( const PortionObj& rPortionObj )
-{
- if ( this != &rPortionObj )
- {
- ImplClear();
- ImplConstruct( rPortionObj );
- }
- return *this;
-}
-
-// -----------------------------------------------------------------------
-
-ParagraphObj::ParagraphObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
- PPTExBulletProvider& rProv ) :
- maMapModeSrc ( MAP_100TH_MM ),
- maMapModeDest ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 576 ) )
-{
- mXPropSet = rXPropSet;
-
- bExtendedParameters = sal_False;
-
- nDepth = 0;
- nBulletFlags = 0;
- nParaFlags = 0;
-
- ImplGetParagraphValues( rProv, sal_False );
-}
-
- ParagraphObj::ParagraphObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > & rXTextContent,
- ParaFlags aParaFlags, FontCollection& rFontCollection, PPTExBulletProvider& rProv ) :
- maMapModeSrc ( MAP_100TH_MM ),
- maMapModeDest ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 576 ) ),
- mbFirstParagraph ( aParaFlags.bFirstParagraph ),
- mbLastParagraph ( aParaFlags.bLastParagraph )
-{
- bExtendedParameters = sal_False;
-
- nDepth = 0;
- nBulletFlags = 0;
- nParaFlags = 0;
-
- mXPropSet = ::com::sun::star::uno::Reference<
- ::com::sun::star::beans::XPropertySet >
- ( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
-
- mXPropState = ::com::sun::star::uno::Reference<
- ::com::sun::star::beans::XPropertyState >
- ( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
-
- if ( mXPropSet.is() && mXPropState.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess >
- aXTextPortionEA( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
- if ( aXTextPortionEA.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration >
- aXTextPortionE( aXTextPortionEA->createEnumeration() );
- if ( aXTextPortionE.is() )
- {
- while ( aXTextPortionE->hasMoreElements() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > aXCursorText;
- ::com::sun::star::uno::Any aAny( aXTextPortionE->nextElement() );
- if ( aAny >>= aXCursorText )
- {
- PortionObj* pPortionObj = new PortionObj( aXCursorText, !aXTextPortionE->hasMoreElements(), rFontCollection );
- if ( pPortionObj->Count() )
- Insert( pPortionObj, LIST_APPEND );
- else
- delete pPortionObj;
- }
- }
- }
- }
- ImplGetParagraphValues( rProv, sal_True );//
- }
-}
-
-ParagraphObj::ParagraphObj( const ParagraphObj& rObj )
-: List()
-, PropStateValue()
-, SOParagraph()
-{
- ImplConstruct( rObj );
-}
-
-ParagraphObj::~ParagraphObj()
-{
- ImplClear();
-}
-
-void ParagraphObj::Write( SvStream* pStrm )
-{
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- ((PortionObj*)pPtr)->Write( pStrm, mbLastParagraph );
-}
-
-void ParagraphObj::ImplClear()
-{
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- delete (PortionObj*)pPtr;
-}
-
-void ParagraphObj::CalculateGraphicBulletSize( sal_uInt16 nFontHeight )
-{
- if ( ( (SvxExtNumType)nNumberingType == SVX_NUM_BITMAP ) && ( nBulletId != 0xffff ) )
- {
- // calculate the bulletrealsize for this grafik
- if ( aBuGraSize.Width() && aBuGraSize.Height() )
- {
- double fCharHeight = nFontHeight;
- double fLen = aBuGraSize.Height();
- fCharHeight = fCharHeight * 0.2540;
- double fQuo = fLen / fCharHeight;
- nBulletRealSize = (sal_Int16)( fQuo + 0.5 );
- if ( (sal_uInt16)nBulletRealSize > 400 )
- nBulletRealSize = 400;
- }
- }
-}
-
-// from sw/source/filter/ww8/wrtw8num.cxx for default bullets to export to MS intact
-static void lcl_SubstituteBullet(String& rNumStr, rtl_TextEncoding& rChrSet, String& rFontName)
-{
- sal_Unicode cChar = rNumStr.GetChar(0);
- StarSymbolToMSMultiFont *pConvert = CreateStarSymbolToMSMultiFont();
- String sFont = pConvert->ConvertChar(cChar);
- delete pConvert;
- if (sFont.Len())
- {
- rNumStr = static_cast< sal_Unicode >(cChar | 0xF000);
- rFontName = sFont;
- rChrSet = RTL_TEXTENCODING_SYMBOL;
- }
- else if ( (rNumStr.GetChar(0) < 0xE000 || rNumStr.GetChar(0) > 0xF8FF) )
- {
- /*
- Ok we can't fit into a known windows unicode font, but
- we are not in the private area, so we are a
- standardized symbol, so turn off the symbol bit and
- let words own font substitution kick in
- */
- rChrSet = RTL_TEXTENCODING_UNICODE;
- rFontName = ::GetFontToken(rFontName, 0);
- }
- else
- {
- /*
- Well we don't have an available substition, and we're
- in our private area, so give up and show a standard
- bullet symbol
- */
- rFontName.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Wingdings"));
- rNumStr = static_cast< sal_Unicode >(0x6C);
- }
-}
-
-void ParagraphObj::ImplGetNumberingLevel( PPTExBulletProvider& rBuProv, sal_Int16 nNumberingDepth, sal_Bool bIsBullet, sal_Bool bGetPropStateValue )
-{
- ::com::sun::star::uno::Any aAny;
- if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaLeftMargin" ) ) ) )
- {
- sal_Int32 nVal;
- if ( aAny >>= nVal )
- nTextOfs = static_cast< sal_Int16 >( nVal / ( 2540.0 / 576 ) + 0.5 ) ;
- }
- if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaFirstLineIndent" ) ) ) )
- {
- if ( aAny >>= nBulletOfs )
- nBulletOfs = static_cast< sal_Int32 >( nBulletOfs / ( 2540.0 / 576 ) + 0.5 );
- }
- if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "NumberingIsNumber" ) ) ) )
- aAny >>= bNumberingIsNumber;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexReplace > aXIndexReplace;
-
- if ( bIsBullet && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "NumberingRules" ) ), bGetPropStateValue ) )
- {
- if ( ( mAny >>= aXIndexReplace ) && nNumberingDepth < aXIndexReplace->getCount() )
- {
- mAny <<= aXIndexReplace->getByIndex( nNumberingDepth );
- ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>
- aPropertySequence( *( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>*)mAny.getValue() );
-
- const ::com::sun::star::beans::PropertyValue* pPropValue = aPropertySequence.getArray();
-
- sal_Int32 nPropertyCount = aPropertySequence.getLength();
- if ( nPropertyCount )
- {
- bExtendedParameters = sal_True;
- nBulletRealSize = 100;
- nMappedNumType = 0;
-
- String aGraphicURL;
- for ( sal_Int32 i = 0; i < nPropertyCount; i++ )
- {
- const void* pValue = pPropValue[ i ].Value.getValue();
- if ( pValue )
- {
- ::rtl::OUString aPropName( pPropValue[ i ].Name );
- if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "NumberingType" ) ) )
- nNumberingType = *( (sal_Int16*)pValue );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Adjust" ) ) )
- nHorzAdjust = *( (sal_Int16*)pValue );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletChar" ) ) )
- {
- String aString( *( (String*)pValue ) );
- if ( aString.Len() )
- cBulletId = aString.GetChar( 0 );
- }
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletFont" ) ) )
- {
- aFontDesc = *( (::com::sun::star::awt::FontDescriptor*)pValue );
-
- // Our numbullet dialog has set the wrong textencoding for our "StarSymbol" font,
- // instead of a Unicode encoding the encoding RTL_TEXTENCODING_SYMBOL was used.
- // Because there might exist a lot of damaged documemts I added this two lines
- // which fixes the bullet problem for the export.
- if ( aFontDesc.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StarSymbol" ) ) )
- aFontDesc.CharSet = RTL_TEXTENCODING_MS_1252;
-
- }
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GraphicURL" ) ) )
- aGraphicURL = ( *(::rtl::OUString*)pValue );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GraphicSize" ) ) )
- {
- if ( pPropValue[ i ].Value.getValueType() == ::getCppuType( (::com::sun::star::awt::Size*)0) )
- {
- // don't cast awt::Size to Size as on 64-bits they are not the same.
- ::com::sun::star::awt::Size aSize;
- pPropValue[ i ].Value >>= aSize;
- aBuGraSize.nA = aSize.Width;
- aBuGraSize.nB = aSize.Height;
- }
- }
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StartWith" ) ) )
- nStartWith = *( (sal_Int16*)pValue );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "LeftMargin" ) ) )
- nTextOfs = nTextOfs + static_cast< sal_Int16 >( *( (sal_Int32*)pValue ) / ( 2540.0 / 576 ) );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FirstLineOffset" ) ) )
- nBulletOfs += (sal_Int16)( *( (sal_Int32*)pValue ) / ( 2540.0 / 576 ) );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletColor" ) ) )
- {
- sal_uInt32 nSOColor = *( (sal_uInt32*)pValue );
- nBulletColor = nSOColor & 0xff00ff00; // green and hibyte
- nBulletColor |= (sal_uInt8)( nSOColor ) << 16; // red
- nBulletColor |= (sal_uInt8)( nSOColor >> 16 ) | 0xfe000000; // blue
- }
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletRelSize" ) ) )
- {
- nBulletRealSize = *( (sal_Int16*)pValue );
- nParaFlags |= 0x40;
- nBulletFlags |= 8;
- }
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Prefix" ) ) )
- sPrefix = ( *(::rtl::OUString*)pValue );
- else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Suffix" ) ) )
- sSuffix = ( *(::rtl::OUString*)pValue );
-#ifdef DBG_UTIL
- else if ( ! (
- ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "SymbolTextDistance" ) ) )
- || ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Graphic" ) ) ) ) )
- {
- DBG_ERROR( "Unbekanntes Property" );
- }
-#endif
- }
- }
-
- if ( aGraphicURL.Len() )
- {
- if ( aBuGraSize.Width() && aBuGraSize.Height() )
- {
- xub_StrLen nIndex = aGraphicURL.Search( (sal_Unicode)':', 0 );
- if ( nIndex != STRING_NOTFOUND )
- {
- nIndex++;
- if ( aGraphicURL.Len() > nIndex )
- {
- ByteString aUniqueId( aGraphicURL, nIndex, aGraphicURL.Len() - nIndex, RTL_TEXTENCODING_UTF8 );
- if ( aUniqueId.Len() )
- {
- nBulletId = rBuProv.GetId( aUniqueId, aBuGraSize );
- if ( nBulletId != 0xffff )
- bExtendedBulletsUsed = sal_True;
- }
- }
- }
- }
- else
- {
- nNumberingType = SVX_NUM_NUMBER_NONE;
- }
- }
-
- PortionObj* pPortion = (PortionObj*)First();
- CalculateGraphicBulletSize( ( pPortion ) ? pPortion->mnCharHeight : 24 );
-
- switch( (SvxExtNumType)nNumberingType )
- {
- case SVX_NUM_NUMBER_NONE : nParaFlags |= 0xf; break;
-
- case SVX_NUM_CHAR_SPECIAL : // Bullet
- {
- if ( aFontDesc.Name.equalsIgnoreAsciiCaseAscii("starsymbol") ||
- aFontDesc.Name.equalsIgnoreAsciiCaseAscii("opensymbol") )
- {
- String sFontName = aFontDesc.Name;
- String sNumStr = cBulletId;
- rtl_TextEncoding eChrSet = aFontDesc.CharSet;
- lcl_SubstituteBullet(sNumStr,eChrSet,sFontName);
- aFontDesc.Name = sFontName;
- cBulletId = sNumStr.GetChar( 0 );
- aFontDesc.CharSet = eChrSet;
- }
-
- if ( aFontDesc.Name.getLength() )
- {
-/*
- if ( aFontDesc.CharSet != ::com::sun::star::awt::CharSet::SYMBOL )
- {
- switch ( cBulletId )
- {
- // Currency
- case 128: cBulletId = 0x20AC; break;
- // Punctuation and other
- case 130: cBulletId = 0x201A; break;// SINGLE LOW-9 QUOTATION MARK
- case 131: cBulletId = 0x0192; break;// LATIN SMALL LETTER F WITH HOOK
- case 132: cBulletId = 0x201E; break;// DOUBLE LOW-9 QUOTATION MARK
- // LOW DOUBLE PRIME QUOTATION MARK
- case 133: cBulletId = 0x2026; break;// HORIZONTAL ELLIPSES
- case 134: cBulletId = 0x2020; break;// DAGGER
- case 135: cBulletId = 0x2021; break;// DOUBLE DAGGER
- case 136: cBulletId = 0x02C6; break;// MODIFIER LETTER CIRCUMFLEX ACCENT
- case 137: cBulletId = 0x2030; break;// PER MILLE SIGN
- case 138: cBulletId = 0x0160; break;// LATIN CAPITAL LETTER S WITH CARON
- case 139: cBulletId = 0x2039; break;// SINGLE LEFT-POINTING ANGLE QUOTATION MARK
- case 140: cBulletId = 0x0152; break;// LATIN CAPITAL LIGATURE OE
- case 142: cBulletId = 0x017D; break;// LATIN CAPITAL LETTER Z WITH CARON
- case 145: cBulletId = 0x2018; break;// LEFT SINGLE QUOTATION MARK
- // MODIFIER LETTER TURNED COMMA
- case 146: cBulletId = 0x2019; break;// RIGHT SINGLE QUOTATION MARK
- // MODIFIER LETTER APOSTROPHE
- case 147: cBulletId = 0x201C; break;// LEFT DOUBLE QUOTATION MARK
- // REVERSED DOUBLE PRIME QUOTATION MARK
- case 148: cBulletId = 0x201D; break;// RIGHT DOUBLE QUOTATION MARK
- // REVERSED DOUBLE PRIME QUOTATION MARK
- case 149: cBulletId = 0x2022; break;// BULLET
- case 150: cBulletId = 0x2013; break;// EN DASH
- case 151: cBulletId = 0x2014; break;// EM DASH
- case 152: cBulletId = 0x02DC; break;// SMALL TILDE
- case 153: cBulletId = 0x2122; break;// TRADE MARK SIGN
- case 154: cBulletId = 0x0161; break;// LATIN SMALL LETTER S WITH CARON
- case 155: cBulletId = 0x203A; break;// SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
- case 156: cBulletId = 0x0153; break;// LATIN SMALL LIGATURE OE
- case 158: cBulletId = 0x017E; break;// LATIN SMALL LETTER Z WITH CARON
- case 159: cBulletId = 0x0178; break;// LATIN CAPITAL LETTER Y WITH DIAERESIS
-// case 222: cBulletId = 0x00B6; break;// PILCROW SIGN / PARAGRAPH SIGN
- }
- }
-*/
- nParaFlags |= 0x90; // wir geben den Font und den Charset vor
- }
- }
- case SVX_NUM_CHARS_UPPER_LETTER : // zaehlt von a-z, aa - az, ba - bz, ...
- case SVX_NUM_CHARS_LOWER_LETTER :
- case SVX_NUM_ROMAN_UPPER :
- case SVX_NUM_ROMAN_LOWER :
- case SVX_NUM_ARABIC :
- case SVX_NUM_PAGEDESC : // Numerierung aus der Seitenvorlage
- case SVX_NUM_BITMAP :
- case SVX_NUM_CHARS_UPPER_LETTER_N : // zaehlt von a-z, aa-zz, aaa-zzz
- case SVX_NUM_CHARS_LOWER_LETTER_N :
- {
- if ( nNumberingType != SVX_NUM_CHAR_SPECIAL )
- {
- bExtendedBulletsUsed = sal_True;
- if ( nNumberingDepth & 1 )
- cBulletId = 0x2013; // defaulting bullet characters for ppt97
- else if ( nNumberingDepth == 4 )
- cBulletId = 0xbb;
- else
- cBulletId = 0x2022;
-
- switch( (SvxExtNumType)nNumberingType )
- {
- case SVX_NUM_CHARS_UPPER_LETTER :
- case SVX_NUM_CHARS_UPPER_LETTER_N :
- {
- if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
- {
- if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
- nMappedNumType = 0xa0001; // (A)
- else
- nMappedNumType = 0xb0001; // A)
- }
- else
- nMappedNumType = 0x10001; // A.
- }
- break;
- case SVX_NUM_CHARS_LOWER_LETTER :
- case SVX_NUM_CHARS_LOWER_LETTER_N :
- {
- if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
- {
- if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
- nMappedNumType = 0x80001; // (a)
- else
- nMappedNumType = 0x90001; // a)
- }
- else
- nMappedNumType = 0x00001; // a.
- }
- break;
- case SVX_NUM_ROMAN_UPPER :
- {
- if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
- {
- if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
- nMappedNumType = 0xe0001; // (I)
- else
- nMappedNumType = 0xf0001; // I)
- }
- else
- nMappedNumType = 0x70001; // I.
- }
- break;
- case SVX_NUM_ROMAN_LOWER :
- {
- if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
- {
- if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
- nMappedNumType = 0x40001; // (i)
- else
- nMappedNumType = 0x50001; // i)
- }
- else
- nMappedNumType = 0x60001; // i.
- }
- break;
- case SVX_NUM_ARABIC :
- {
- if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
- {
- if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
- nMappedNumType = 0xc0001; // (1)
- else
- nMappedNumType = 0x20001; // 1)
- }
- else
- {
- if ( ! ( sSuffix.Len() + sPrefix.Len() ) )
- nMappedNumType = 0xd0001; // 1
- else
- nMappedNumType = 0x30001; // 1.
- }
- }
- break;
- default:
- break;
- }
- }
- nParaFlags |= 0x2f;
- nBulletFlags |= 6;
- if ( mbIsBullet && bNumberingIsNumber )
- nBulletFlags |= 1;
- }
- }
- }
- }
- }
- nBulletOfs = nTextOfs + nBulletOfs;
- if ( nBulletOfs < 0 )
- nBulletOfs = 0;
-}
-
-void ParagraphObj::ImplGetParagraphValues( PPTExBulletProvider& rBuProv, sal_Bool bGetPropStateValue )
-{
- static String sNumberingLevel ( RTL_CONSTASCII_USTRINGPARAM( "NumberingLevel" ) );
-
- ::com::sun::star::uno::Any aAny;
- if ( GetPropertyValue( aAny, mXPropSet, sNumberingLevel, sal_True ) )
- {
- if ( bGetPropStateValue )
- meBullet = GetPropertyState( mXPropSet, sNumberingLevel );
- nDepth = *( (sal_Int16*)aAny.getValue() );
-
- if ( nDepth < 0 )
- {
- mbIsBullet = sal_False;
- nDepth = 0;
- }
- else
- {
- if ( nDepth > 4 )
- nDepth = 4;
- mbIsBullet = sal_True;
- }
- }
- else
- {
- nDepth = 0;
- mbIsBullet = sal_False;
- }
- ImplGetNumberingLevel( rBuProv, nDepth, mbIsBullet, bGetPropStateValue );
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaTabStops" ) ), bGetPropStateValue ) )
- maTabStop = *( ::com::sun::star::uno::Sequence< ::com::sun::star::style::TabStop>*)mAny.getValue();
- sal_Int16 eTextAdjust( ::com::sun::star::style::ParagraphAdjust_LEFT );
- if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaAdjust" ) ), bGetPropStateValue ) )
- aAny >>= eTextAdjust;
- switch ( (::com::sun::star::style::ParagraphAdjust)eTextAdjust )
- {
- case ::com::sun::star::style::ParagraphAdjust_CENTER :
- mnTextAdjust = 1;
- break;
- case ::com::sun::star::style::ParagraphAdjust_RIGHT :
- mnTextAdjust = 2;
- break;
- case ::com::sun::star::style::ParagraphAdjust_BLOCK :
- mnTextAdjust = 3;
- break;
- default :
- case ::com::sun::star::style::ParagraphAdjust_LEFT :
- mnTextAdjust = 0;
- break;
- }
- meTextAdjust = ePropState;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaLineSpacing" ) ), bGetPropStateValue ) )
- {
- ::com::sun::star::style::LineSpacing aLineSpacing
- = *( (::com::sun::star::style::LineSpacing*)mAny.getValue() );
- switch ( aLineSpacing.Mode )
- {
- case ::com::sun::star::style::LineSpacingMode::MINIMUM :
- case ::com::sun::star::style::LineSpacingMode::LEADING :
- case ::com::sun::star::style::LineSpacingMode::FIX :
- mnLineSpacing = (sal_Int16)(-( aLineSpacing.Height ) );
- break;
-
- case ::com::sun::star::style::LineSpacingMode::PROP :
- default:
- mnLineSpacing = (sal_Int16)( aLineSpacing.Height );
- break;
- }
- }
- meLineSpacing = ePropState;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaBottomMargin" ) ), bGetPropStateValue ) )
- {
- double fSpacing = *( (sal_uInt32*)mAny.getValue() ) + ( 2540.0 / 576.0 ) - 1;
- mnLineSpacingBottom = (sal_Int16)(-( fSpacing * 576.0 / 2540.0 ) );
- }
- meLineSpacingBottom = ePropState;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaTopMargin" ) ), bGetPropStateValue ) )
- {
- double fSpacing = *( (sal_uInt32*)mAny.getValue() ) + ( 2540.0 / 576.0 ) - 1;
- mnLineSpacingTop = (sal_Int16)(-( fSpacing * 576.0 / 2540.0 ) );
- }
- meLineSpacingTop = ePropState;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaIsForbiddenRules" ) ), bGetPropStateValue ) )
- mAny >>= mbForbiddenRules;
- meForbiddenRules = ePropState;
-
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaIsHangingPunctuation" ) ), bGetPropStateValue ) )
- mAny >>= mbParagraphPunctation;
- meParagraphPunctation = ePropState;
-
- mnBiDi = 0;
- if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "WritingMode" ) ), bGetPropStateValue ) )
- {
- sal_Int16 nWritingMode;
- mAny >>= nWritingMode;
-
- SvxFrameDirection eWritingMode( (SvxFrameDirection)nWritingMode );
- if ( ( eWritingMode == FRMDIR_HORI_RIGHT_TOP )
- || ( eWritingMode == FRMDIR_VERT_TOP_RIGHT ) )
- {
- mnBiDi = 1;
- }
- }
- meBiDi = ePropState;
-}
-
-void ParagraphObj::ImplConstruct( const ParagraphObj& rParagraphObj )
-{
- mnTextSize = rParagraphObj.mnTextSize;
- mnTextAdjust = rParagraphObj.mnTextAdjust;
- mnLineSpacing = rParagraphObj.mnLineSpacing;
- mnLineSpacingTop = rParagraphObj.mnLineSpacingTop;
- mnLineSpacingBottom = rParagraphObj.mnLineSpacingBottom;
- mbFirstParagraph = rParagraphObj.mbFirstParagraph;
- mbLastParagraph = rParagraphObj.mbLastParagraph;
- mbParagraphPunctation = rParagraphObj.mbParagraphPunctation;
- mbForbiddenRules = rParagraphObj.mbForbiddenRules;
- mnBiDi = rParagraphObj.mnBiDi;
-
- ParagraphObj& rOther = const_cast<ParagraphObj&>(rParagraphObj);
- for ( const void* pPtr = rOther.First(); pPtr; pPtr = rOther.Next() )
- Insert( new PortionObj( *(const PortionObj*)pPtr ), LIST_APPEND );
-
- maTabStop = rParagraphObj.maTabStop;
- bExtendedParameters = rParagraphObj.bExtendedParameters;
- nParaFlags = rParagraphObj.nParaFlags;
- nBulletFlags = rParagraphObj.nBulletFlags;
- sPrefix = rParagraphObj.sPrefix;
- sSuffix = rParagraphObj.sSuffix;
- sGraphicUrl = rParagraphObj.sGraphicUrl; // String auf eine Graphic
- aBuGraSize = rParagraphObj.aBuGraSize;
- nNumberingType = rParagraphObj.nNumberingType; // in wirlichkeit ist dies ein SvxEnum
- nHorzAdjust = rParagraphObj.nHorzAdjust;
- nBulletColor = rParagraphObj.nBulletColor;
- nBulletOfs = rParagraphObj.nBulletOfs;
- nStartWith = rParagraphObj.nStartWith; // Start der nummerierung
- nTextOfs = rParagraphObj.nTextOfs;
- nBulletRealSize = rParagraphObj.nBulletRealSize; // GroessenVerhaeltnis in Proz
- nDepth = rParagraphObj.nDepth; // aktuelle tiefe
- cBulletId = rParagraphObj.cBulletId; // wenn Numbering Type == CharSpecial
- aFontDesc = rParagraphObj.aFontDesc;
-
- bExtendedBulletsUsed = rParagraphObj.bExtendedBulletsUsed;
- nBulletId = rParagraphObj.nBulletId;
-}
-
-sal_uInt32 ParagraphObj::ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition )
-{
- mnTextSize = 0;
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- mnTextSize += ((PortionObj*)pPtr)->ImplCalculateTextPositions( nCurrentTextPosition + mnTextSize );
- return mnTextSize;
-}
-
-ParagraphObj& ParagraphObj::operator=( const ParagraphObj& rParagraphObj )
-{
- if ( this != &rParagraphObj )
- {
- ImplClear();
- ImplConstruct( rParagraphObj );
- }
- return *this;
-}
-
-// -----------------------------------------------------------------------
-
-ImplTextObj::ImplTextObj( int nInstance )
-{
- mnRefCount = 1;
- mnTextSize = 0;
- mnInstance = nInstance;
- mpList = new List;
- mbHasExtendedBullets = sal_False;
- mbFixedCellHeightUsed = sal_False;
-}
-
-ImplTextObj::~ImplTextObj()
-{
- for ( ParagraphObj* pPtr = (ParagraphObj*)mpList->First(); pPtr; pPtr = (ParagraphObj*)mpList->Next() )
- delete pPtr;
- delete mpList;
-}
-
-TextObj::TextObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > & rXTextRef,
- int nInstance, FontCollection& rFontCollection, PPTExBulletProvider& rProv )
-{
- mpImplTextObj = new ImplTextObj( nInstance );
-
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess >
- aXTextParagraphEA( rXTextRef, ::com::sun::star::uno::UNO_QUERY );
-
- if ( aXTextParagraphEA.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration >
- aXTextParagraphE( aXTextParagraphEA->createEnumeration() );
- if ( aXTextParagraphE.is() )
- {
- ParaFlags aParaFlags;
- while ( aXTextParagraphE->hasMoreElements() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > aXParagraph;
- ::com::sun::star::uno::Any aAny( aXTextParagraphE->nextElement() );
- if ( aAny >>= aXParagraph )
- {
- if ( !aXTextParagraphE->hasMoreElements() )
- aParaFlags.bLastParagraph = sal_True;
- ParagraphObj* pPara = new ParagraphObj( aXParagraph, aParaFlags, rFontCollection, rProv );
- mpImplTextObj->mbHasExtendedBullets |= pPara->bExtendedBulletsUsed;
- mpImplTextObj->mpList->Insert( pPara, LIST_APPEND );
- aParaFlags.bFirstParagraph = sal_False;
- }
- }
- }
- }
- ImplCalculateTextPositions();
-}
-
-TextObj::TextObj( const TextObj& rTextObj )
-{
- mpImplTextObj = rTextObj.mpImplTextObj;
- mpImplTextObj->mnRefCount++;
-}
-
-TextObj::~TextObj()
-{
- if ( ! ( --mpImplTextObj->mnRefCount ) )
- delete mpImplTextObj;
-}
-
-void TextObj::Write( SvStream* pStrm )
-{
- sal_uInt32 nSize, nPos = pStrm->Tell();
- *pStrm << (sal_uInt32)( EPP_TextCharsAtom << 16 ) << (sal_uInt32)0;
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- ((ParagraphObj*)pPtr)->Write( pStrm );
- nSize = pStrm->Tell() - nPos;
- pStrm->SeekRel( - ( (sal_Int32)nSize - 4 ) );
- *pStrm << (sal_uInt32)( nSize - 8 );
- pStrm->SeekRel( nSize - 8 );
-}
-
-void TextObj::ImplCalculateTextPositions()
-{
- mpImplTextObj->mnTextSize = 0;
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- mpImplTextObj->mnTextSize += ((ParagraphObj*)pPtr)->ImplCalculateTextPositions( mpImplTextObj->mnTextSize );
-}
-
-TextObj& TextObj::operator=( TextObj& rTextObj )
-{
- if ( this != &rTextObj )
- {
- if ( ! ( --mpImplTextObj->mnRefCount ) )
- delete mpImplTextObj;
- mpImplTextObj = rTextObj.mpImplTextObj;
- mpImplTextObj->mnRefCount++;
- }
- return *this;
-}
-
-void TextObj::WriteTextSpecInfo( SvStream* pStrm )
-{
- sal_uInt32 nCharactersLeft( Count() );
- if ( nCharactersLeft >= 1 )
- {
- EscherExAtom aAnimationInfoAtom( *pStrm, EPP_TextSpecInfoAtom, 0, 0 );
- for ( ParagraphObj* pPtr = static_cast < ParagraphObj * >( First() ); nCharactersLeft && pPtr; pPtr = static_cast< ParagraphObj* >( Next() ) )
- {
- for ( PortionObj* pPortion = static_cast< PortionObj* >( pPtr->First() ); nCharactersLeft && pPortion; pPortion = static_cast< PortionObj* >( pPtr->Next() ) )
- {
- sal_Int32 nPortionSize = pPortion->mnTextSize >= nCharactersLeft ? nCharactersLeft : pPortion->mnTextSize;
- sal_Int32 nFlags = 7;
- nCharactersLeft -= nPortionSize;
- *pStrm << static_cast< sal_uInt32 >( nPortionSize )
- << nFlags
- << static_cast< sal_Int16 >( 1 ) // spellinfo -> needs rechecking
- << static_cast< sal_Int16 >( MsLangId::convertLocaleToLanguageWithFallback( pPortion->meCharLocale ) )
- << static_cast< sal_Int16 >( 0 ); // alt language
- }
- }
- if ( nCharactersLeft )
- *pStrm << nCharactersLeft << static_cast< sal_Int32 >( 1 ) << static_cast< sal_Int16 >( 1 );
-
- }
-}
-
-// -----------------------------------------------------------------------
-
void PPTWriter::ImplAdjustFirstLineLineSpacing( TextObj& rTextObj, EscherPropertyContainer& rPropOpt )
{
if ( !mbFontIndependentLineSpacing )
@@ -3067,33 +1119,6 @@ void PPTWriter::ImplAdjustFirstLineLineSpacing( TextObj& rTextObj, EscherPropert
if ( ( nLineSpacing > 0 ) && ( nLineSpacing < 100 ) )
{
- /*
- if ( rxText.is() )
- {
- ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape( rxText, ::com::sun::star::uno::UNO_QUERY );
- if ( xShape.is() )
- {
- SdrObject* pObj = GetSdrObjectFromXShape( mXShape );
- if ( pObj )
- {
- const OutlinerParaObject* pParaObj = pObj->GetOutlinerParaObject();
- if ( pParaObj )
- {
- SdrModel* pModel = pObj->GetModel();
- if ( pModel )
- {
- Outliner aOutliner( &pModel->GetItemPool(), pParaObj->GetOutlinerMode() );
- aOutliner.SetText( *pParaObj );
- sal_uLong nTextHeight = aOutliner.GetLineHeight( 0, 0 );
- if ( nTextHeight )
- {
- }
- }
- }
- }
- }
- }
- */
double fCharHeight = pPortion->mnCharHeight;
fCharHeight *= 2540 / 72;
fCharHeight *= 100 - nLineSpacing;
@@ -3124,7 +1149,7 @@ void PPTWriter::ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_u
if ( !mbEmptyPresObj )
{
ParagraphObj* pPara;
- TextObj aTextObj( mXText, nTextInstance, maFontCollection, (PPTExBulletProvider&)*this );
+ TextObjBinary aTextObj( mXText, nTextInstance, maFontCollection, (PPTExBulletProvider&)*this );
// leaving out EPP_TextCharsAtom w/o text - still write out
// attribute info though
@@ -3158,9 +1183,9 @@ void PPTWriter::ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_u
case 2 :
{
rOut << (sal_uInt32)( EPP_DateTimeMCAtom << 16 ) << (sal_uInt32)8
- << (sal_uInt32)( pFieldEntry->nFieldStartPos ) // TxtOffset auf TxtField;
- << (sal_uInt8)( pFieldEntry->nFieldType & 0xff ) // Type
- << (sal_uInt8)0 << (sal_uInt16)0; // PadBytes
+ << (sal_uInt32)( pFieldEntry->nFieldStartPos ) // TxtOffset auf TxtField;
+ << (sal_uInt8)( pFieldEntry->nFieldType & 0xff ) // Type
+ << (sal_uInt8)0 << (sal_uInt16)0; // PadBytes
}
break;
case 3 :
@@ -3175,36 +1200,48 @@ void PPTWriter::ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_u
String aPageUrl;
String aEmpty;
String aFile( pFieldEntry->aFieldUrl );
+ String aTarget( pFieldEntry->aFieldUrl );
INetURLObject aUrl( pFieldEntry->aFieldUrl );
if ( INET_PROT_FILE == aUrl.GetProtocol() )
aFile = aUrl.PathToFileName();
+ else if ( INET_PROT_SMB == aUrl.GetProtocol() )
+ {
+ // Convert smb notation to '\\'
+ aFile = aUrl.GetMainURL( INetURLObject::NO_DECODE );
+ aFile = String( aFile.GetBuffer() + 4 ); // skip the 'smb:' part
+ aFile.SearchAndReplaceAll( '/', '\\' );
+ aTarget = aFile;
+ }
else if ( pFieldEntry->aFieldUrl.GetChar( 0 ) == '#' )
{
String aPage( INetURLObject::decode( pFieldEntry->aFieldUrl, '%', INetURLObject::DECODE_WITH_CHARSET ) );
aPage.Erase( 0, 1 );
- for ( String* pStr = (String*)maSlideNameList.First(); pStr; pStr = (String*)maSlideNameList.Next(), nPageIndex++ )
+
+ rtl::OUString aUPage(aPage);
+ std::vector<rtl::OUString>::const_iterator pIter = std::find(
+ maSlideNameList.begin(),maSlideNameList.end(),aUPage);
+
+ if ( pIter != maSlideNameList.end() )
{
- if ( *pStr == aPage )
- {
- aPageUrl = UniString::CreateFromInt32( 256 + nPageIndex );
- aPageUrl.Append( String( RTL_CONSTASCII_USTRINGPARAM( "," ) ) );
- aPageUrl.Append( String::CreateFromInt32( nPageIndex + 1 ) );
- aPageUrl.Append( String( RTL_CONSTASCII_USTRINGPARAM( ",Slide " ) ) );
- aPageUrl.Append( String::CreateFromInt32( nPageIndex + 1 ) );
- }
+ nPageIndex = pIter - maSlideNameList.begin();
+ aPageUrl = UniString::CreateFromInt32( 256 + nPageIndex );
+ aPageUrl.Append( String( RTL_CONSTASCII_USTRINGPARAM( "," ) ) );
+ aPageUrl.Append( String::CreateFromInt32( nPageIndex + 1 ) );
+ aPageUrl.Append( String( RTL_CONSTASCII_USTRINGPARAM( ",Slide " ) ) );
+ aPageUrl.Append( String::CreateFromInt32( nPageIndex + 1 ) );
}
}
sal_uInt32 nHyperId;
if ( aPageUrl.Len() )
nHyperId = ImplInsertBookmarkURL( aPageUrl, 1 | ( nPageIndex << 8 ) | ( 1 << 31 ), pFieldEntry->aRepresentation, aEmpty, aEmpty, aPageUrl );
else
- nHyperId = ImplInsertBookmarkURL( pFieldEntry->aFieldUrl, 2 | ( nHyperId << 8 ), aFile, pFieldEntry->aFieldUrl, aEmpty, aEmpty );
+ nHyperId = ImplInsertBookmarkURL( pFieldEntry->aFieldUrl, 2 | ( nHyperId << 8 ), aFile, aTarget, aEmpty, aEmpty );
rOut << (sal_uInt32)( ( EPP_InteractiveInfo << 16 ) | 0xf ) << (sal_uInt32)24
<< (sal_uInt32)( EPP_InteractiveInfoAtom << 16 ) << (sal_uInt32)16
- << (sal_uInt32)0 // soundref
- << nHyperId // hyperlink id
- << (sal_uInt8)4 // hyperlink action
+ << (sal_uInt32)0 // soundref
+ << nHyperId // hyperlink id
+ << (sal_uInt8)4 // hyperlink action
<< (sal_uInt8)0 // ole verb
<< (sal_uInt8)0 // jump
<< (sal_uInt8)0 // flags
@@ -3276,7 +1313,7 @@ void PPTWriter::ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_u
}
nParaFlags >>= 16;
- sal_uInt32 nDefaultTabSize = ImplMapSize( ::com::sun::star::awt::Size( 2011, 1 ) ).Width;
+ sal_uInt32 nDefaultTabSize = MapSize( ::com::sun::star::awt::Size( 2011, 1 ) ).Width;
sal_uInt32 nDefaultTabs = abs( maRect.GetWidth() ) / nDefaultTabSize;
if ( nTabs )
nDefaultTabs -= (sal_Int32)( ( ( pTabStop[ nTabs - 1 ].Position / 4.40972 ) + nTextOfs ) / nDefaultTabSize );
@@ -3382,7 +1419,6 @@ void PPTWriter::ImplWriteTextStyleAtom( SvStream& rOut, int nTextInstance, sal_u
nNumberingType = pBulletPara->nMappedNumType;
break;
- // case SVX_NUM_PAGEDESC :
case SVX_NUM_BITMAP :
nNumberingType = 0;
break;
@@ -4001,11 +2037,12 @@ void PPTWriter::ImplWriteClickAction( SvStream& rSt, ::com::sun::star::presentat
{
if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "Bookmark" ) ) ) )
{
- String aBookmark( *(::rtl::OUString*)mAny.getValue() );
+ rtl::OUString aBookmark( *(::rtl::OUString*)mAny.getValue() );
sal_uInt32 nIndex = 0;
- for ( String* pStr = (String*)maSlideNameList.First(); pStr; pStr = (String*)maSlideNameList.Next(), nIndex++ )
+ std::vector<rtl::OUString>::const_iterator pIter;
+ for ( pIter = maSlideNameList.begin(); pIter != maSlideNameList.end(); ++pIter, nIndex++ )
{
- if ( *pStr == aBookmark )
+ if ( *pIter == aBookmark )
{
// Bookmark ist ein link zu einer Dokumentseite
nAction = 4;
@@ -4066,7 +2103,7 @@ void PPTWriter::ImplWriteClickAction( SvStream& rSt, ::com::sun::star::presentat
<< nFlags
<< (sal_uInt32)nHyperLinkType;
- if ( nAction == 2 ) // run program Action
+ if ( nAction == 2 ) // run program Action
{
sal_uInt16 i, nLen = aFile.Len();
rSt << (sal_uInt32)( ( EPP_CString << 16 ) | 0x20 ) << (sal_uInt32)( nLen * 2 );
@@ -4132,7 +2169,7 @@ sal_Bool PPTWriter::ImplCreatePresentationPlaceholder( const sal_Bool bMasterPag
aPropOpt.AddOpt( ESCHER_Prop_fNoLineDrawDash, nLineFlags );
SvMemoryStream aExtBu( 0x200, 0x200 );
- SvMemoryStream aClientTextBox( 0x200, 0x200 );
+ SvMemoryStream aClientTextBox( 0x200, 0x200 );
ImplWriteTextStyleAtom( aClientTextBox, nStyleInstance, 0, NULL, aExtBu, &aPropOpt );
aPropOpt.CreateTextProperties( mXPropSet, mnTxId += 0x60, sal_False, sal_True );
@@ -4143,18 +2180,11 @@ sal_Bool PPTWriter::ImplCreatePresentationPlaceholder( const sal_Bool bMasterPag
mpPptEscherEx->OpenContainer( ESCHER_ClientData );
mpPptEscherEx->AddAtom( 8, EPP_OEPlaceholderAtom );
*mpStrm << (sal_uInt32)0 // PlacementID
- << (sal_uInt8)nPlaceHolderId // PlaceHolderID
- << (sal_uInt8)0 // Size of PlaceHolder ( 0 = FULL, 1 = HALF, 2 = QUARTER )
+ << (sal_uInt8)nPlaceHolderId // PlaceHolderID
+ << (sal_uInt8)0 // Size of PlaceHolder ( 0 = FULL, 1 = HALF, 2 = QUARTER )
<< (sal_uInt16)0; // padword
- mpPptEscherEx->CloseContainer(); // ESCHER_ClientData
-/*
- if ( aExtBu.Tell() )
- {
- if ( !pClientData )
- pClientData = new SvMemoryStream( 0x200, 0x200 );
- ImplProgTagContainer( pClientData, &aExtBu );
- }
-*/
+ mpPptEscherEx->CloseContainer(); // ESCHER_ClientData
+
if ( aClientTextBox.Tell() )
{
*mpStrm << (sal_uInt32)( ( ESCHER_ClientTextbox << 16 ) | 0xf )
@@ -4234,7 +2264,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
nGroups = GetGroupsClosed();
for ( sal_uInt32 i = 0; i < nGroups; i++, mpPptEscherEx->LeaveGroup() ) ;
- if ( ImplGetShapeByIndex( GetCurrentGroupIndex(), sal_True ) )
+ if ( GetShapeByIndex( GetCurrentGroupIndex(), sal_True ) )
{
sal_Bool bIsSound;
sal_Bool bMediaClickAction = sal_False;
@@ -4255,7 +2285,6 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
sal_Bool bPolyPolygon = mType == "drawing.PolyPolygon";
sal_Bool bPolyLine = mType == "drawing.PolyLine";
- List aAdjustmentList;
Rectangle aPolyBoundRect;
const ::com::sun::star::awt::Size aSize100thmm( mXShape->getSize() );
@@ -4304,8 +2333,8 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "BoundRect" ) ) ) )
{
::com::sun::star::awt::Rectangle aRect( *(::com::sun::star::awt::Rectangle*)mAny.getValue() );
- maPosition = ImplMapPoint( ::com::sun::star::awt::Point( aRect.X, aRect.Y ) );
- maSize = ImplMapSize( ::com::sun::star::awt::Size( aRect.Width, aRect.Height ) );
+ maPosition = MapPoint( ::com::sun::star::awt::Point( aRect.X, aRect.Y ) );
+ maSize = MapSize( ::com::sun::star::awt::Size( aRect.Width, aRect.Height ) );
maRect = Rectangle( Point( maPosition.X, maPosition.Y ), Size( maSize.Width, maSize.Height ) );
}
mType = "drawing.dontknow";
@@ -4322,8 +2351,8 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
sal_uInt32 nMirrorFlags;
rtl::OUString sCustomShapeType;
MSO_SPT eShapeType = aPropOpt.GetCustomShapeType( mXShape, nMirrorFlags, sCustomShapeType );
- if ( sCustomShapeType.equalsAscii( "col-502ad400" ) || sCustomShapeType.equalsAscii( "col-60da8460" ) )
- { // sj: creating metafile for customshapes that can't be saved to ms format properly
+ if ( sCustomShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "col-502ad400" ) ) || sCustomShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "col-60da8460" ) ) )
+ { // sj: creating metafile for customshapes that can't be saved to ms format properly
ImplCreateShape( ESCHER_ShpInst_PictureFrame, 0xa00, aSolverContainer );
if ( aPropOpt.CreateGraphicProperties( mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "MetaFile" ) ), sal_False ) )
{
@@ -4332,8 +2361,8 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
if ( pObj )
{
Rectangle aBound = pObj->GetCurrentBoundRect();
- maPosition = ImplMapPoint( ::com::sun::star::awt::Point( aBound.Left(), aBound.Top() ) );
- maSize = ImplMapSize( ::com::sun::star::awt::Size ( aBound.GetWidth(), aBound.GetHeight() ) );
+ maPosition = MapPoint( ::com::sun::star::awt::Point( aBound.Left(), aBound.Top() ) );
+ maSize = MapSize( ::com::sun::star::awt::Size ( aBound.GetWidth(), aBound.GetHeight() ) );
maRect = Rectangle( Point( maPosition.X, maPosition.Y ), Size( maSize.Width, maSize.Height ) );
mnAngle = 0;
}
@@ -4358,7 +2387,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CornerRadius" ) ) ) )
{
mAny >>= nRadius;
- nRadius = ImplMapSize( ::com::sun::star::awt::Size( nRadius, 0 ) ).Width;
+ nRadius = MapSize( ::com::sun::star::awt::Size( nRadius, 0 ) ).Width;
}
if ( nRadius )
{
@@ -4477,7 +2506,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
}
break;
}
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
if ( bNeedText && ImplGetText() )
@@ -4534,7 +2563,6 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
<< (sal_uInt32)4 // index to the persist table
<< (sal_uInt32)0x0012de00;
-
::com::sun::star::awt::Size aSize;
String aControlName;
SvStorageRef xTemp( new SvStorage( new SvMemoryStream(), sal_True ) );
@@ -4621,7 +2649,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
if ( aPropOpt.CreateConnectorProperties( mXShape, aSolverContainer, aNewRect, nSpType, nSpFlags ) == sal_False )
continue;
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
@@ -4636,7 +2664,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
{
::com::sun::star::awt::Rectangle aNewRect;
aPropOpt.CreatePolygonProperties( mXPropSet, ESCHER_CREATEPOLYGON_LINE, sal_False, aNewRect, NULL );
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
if ( ImplGetText() )
@@ -4671,7 +2699,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
ImplCreateShape( ESCHER_ShpInst_NotPrimitive, 0xa00, aSolverContainer ); // Flags: Connector | HasSpt
::com::sun::star::awt::Rectangle aNewRect;
aPropOpt.CreatePolygonProperties( mXPropSet, ESCHER_CREATEPOLYGON_POLYPOLYGON, sal_False, aNewRect, NULL );
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
aPropOpt.CreateFillProperties( mXPropSet, sal_True );
@@ -4690,7 +2718,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
ImplCreateShape( ESCHER_ShpInst_NotPrimitive, 0xa00, aSolverContainer ); // Flags: Connector | HasSpt
::com::sun::star::awt::Rectangle aNewRect;
aPropOpt.CreatePolygonProperties( mXPropSet, ESCHER_CREATEPOLYGON_POLYLINE, sal_False, aNewRect, NULL );
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
aPropOpt.CreateLineProperties( mXPropSet, sal_False );
@@ -4709,7 +2737,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
ImplCreateShape( ESCHER_ShpInst_NotPrimitive, 0xa00, aSolverContainer ); // Flags: Connector | HasSpt
::com::sun::star::awt::Rectangle aNewRect;
aPropOpt.CreatePolygonProperties( mXPropSet, ESCHER_CREATEPOLYGON_POLYLINE, sal_True, aNewRect, NULL );
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
aPropOpt.CreateLineProperties( mXPropSet, sal_False );
@@ -4728,7 +2756,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
ImplCreateShape( ESCHER_ShpInst_NotPrimitive, 0xa00, aSolverContainer ); // Flags: Connector | HasSpt
::com::sun::star::awt::Rectangle aNewRect;
aPropOpt.CreatePolygonProperties( mXPropSet, ESCHER_CREATEPOLYGON_POLYPOLYGON, sal_True, aNewRect, NULL );
- maRect = ImplMapRectangle( aNewRect );
+ maRect = MapRectangle( aNewRect );
maPosition = ::com::sun::star::awt::Point( maRect.Left(), maRect.Top() );
maSize = ::com::sun::star::awt::Size( maRect.GetWidth(), maRect.GetHeight() );
aPropOpt.CreateFillProperties( mXPropSet, sal_True );
@@ -4810,7 +2838,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
bIsTitlePossible = sal_False;
ImplGetText();
- TextObj aTextObj( mXText, EPP_TEXTTYPE_Title, maFontCollection, (PPTExBulletProvider&)*this );
+ TextObjBinary aTextObj( mXText, EPP_TEXTTYPE_Title, maFontCollection, (PPTExBulletProvider&)*this );
if ( ePageType == MASTER )
{
if ( mnTextSize )
@@ -4825,8 +2853,6 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
aPropertyOptions.AddOpt( ESCHER_Prop_LockAgainstGrouping, 0x50001 );
aPropertyOptions.AddOpt( ESCHER_Prop_lTxid, mnTxId += 0x60 );
aPropertyOptions.AddOpt( ESCHER_Prop_AnchorText, ESCHER_AnchorMiddle );
-// aPropertyOptions.AddOpt( ESCHER_Prop_fillColor, nFillColor );
-// aPropertyOptions.AddOpt( ESCHER_Prop_fillBackColor, nFillBackColor );
aPropertyOptions.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x110001 );
aPropertyOptions.AddOpt( ESCHER_Prop_lineColor, 0x8000001 );
aPropertyOptions.AddOpt( ESCHER_Prop_shadowColor, 0x8000002 );
@@ -4851,7 +2877,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
mpPptEscherEx->AddAtom( 4, EPP_TextHeaderAtom );
*mpStrm << (sal_uInt32)EPP_TEXTTYPE_Title;
mpPptEscherEx->AddAtom( mnTextSize << 1, EPP_TextCharsAtom );
- const sal_Unicode* pString = aUString;
+ const sal_Unicode* pString = aUString.getStr();
for ( sal_uInt32 i = 0; i < mnTextSize; i++ )
{
nChar = pString[ i ]; // 0xa -> 0xb weicher Zeilenumbruch
@@ -4906,7 +2932,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
)
{
ImplGetText();
- TextObj aTextObj( mXText, EPP_TEXTTYPE_Body, maFontCollection, (PPTExBulletProvider&)*this );
+ TextObjBinary aTextObj( mXText, EPP_TEXTTYPE_Body, maFontCollection, (PPTExBulletProvider&)*this );
if ( ePageType == MASTER )
{
nPrevTextStyle = EPP_TEXTSTYLE_TITLE;
@@ -4918,8 +2944,6 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
EscherPropertyContainer aPropOpt2;
aPropOpt2.AddOpt( ESCHER_Prop_LockAgainstGrouping, 0x50001 );
aPropOpt2.AddOpt( ESCHER_Prop_lTxid, mnTxId += 0x60 );
-// aPropOpt2.AddOpt( ESCHER_Prop_fillColor, nFillColor );
-// aPropOpt2.AddOpt( ESCHER_Prop_fillBackColor, nFillBackColor );
aPropOpt2.AddOpt( ESCHER_Prop_fNoFillHitTest, 0x110001 );
aPropOpt2.AddOpt( ESCHER_Prop_lineColor, 0x8000001 );
aPropOpt2.AddOpt( ESCHER_Prop_fNoLineDrawDash, 0x90001 );
@@ -5059,17 +3083,13 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
*mpExEmbed << (sal_uInt32)( 1 | ( EPP_ExOleObjAtom << 16 ) )
<< (sal_uInt32)24
- << (sal_uInt32)nAspect // Aspect
+ << (sal_uInt32)nAspect // Aspect
<< (sal_uInt32)0
<< (sal_uInt32)mnExEmbed // index to the persist table
<< (sal_uInt32)0 // subtype
<< (sal_uInt32)0
<< (sal_uInt32)0x0012b600;
-// PPTWriter::WriteCString( *mpExEmbed, "Photo Editor Photo", 1 );
-// PPTWriter::WriteCString( *mpExEmbed, "MSPhotoEd.3", 2 );
-// PPTWriter::WriteCString( *mpExEmbed, "Microsoft Photo Editor 3.0 Photo", 3 );
-
nSize = mpExEmbed->Tell() - nOldPos;
mpExEmbed->Seek( nOldPos - 4 );
*mpExEmbed << nSize;
@@ -5158,7 +3178,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
sal_uInt32 nRefId = ++mnExEmbed;
*mpExEmbed << (sal_uInt16)0xf
- << (sal_uInt16)EPP_ExMCIMovie // PPT_PST_ExAviMovie
+ << (sal_uInt16)EPP_ExMCIMovie // PPT_PST_ExAviMovie
<< (sal_uInt32)0;
sal_uInt32 nSize, nStart = mpExEmbed->Tell();
*mpExEmbed << (sal_uInt16)0
@@ -5169,14 +3189,13 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
<< (sal_uInt16)EPP_ExVideo
<< (sal_uInt32)0;
- *mpExEmbed << (sal_uInt16)0
+ *mpExEmbed << (sal_uInt16)0
<< (sal_uInt16)EPP_ExMediaAtom
<< (sal_uInt32)8
<< nRefId
<< (sal_uInt16)0
<< (sal_uInt16)0x435;
-
sal_uInt16 i, nStringLen = (sal_uInt16)aMediaURL.getLength();
*mpExEmbed << (sal_uInt32)( EPP_CString << 16 ) << (sal_uInt32)( nStringLen * 2 );
for ( i = 0; i < nStringLen; i++ )
@@ -5186,10 +3205,10 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
}
nSize = mpExEmbed->Tell() - nStart;
mpExEmbed->SeekRel( - ( (sal_Int32)nSize + 4 ) );
- *mpExEmbed << nSize; // size of PPT_PST_ExMCIMovie
+ *mpExEmbed << nSize; // size of PPT_PST_ExMCIMovie
mpExEmbed->SeekRel( 0x10 );
nSize -= 20;
- *mpExEmbed << nSize; // PPT_PST_ExMediaAtom
+ *mpExEmbed << nSize; // PPT_PST_ExMediaAtom
mpExEmbed->SeekRel( nSize );
if ( !pClientData )
@@ -5230,7 +3249,6 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
{
continue;
}
- sal_Int32 nPlacementID = -1;
sal_Bool bClientData = ( bEffect || ( eCa != ::com::sun::star::presentation::ClickAction_NONE ) ||
nPlaceHolderAtom || nOlePictureId );
@@ -5238,6 +3256,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
{
if ( nPlaceHolderAtom )
{
+ sal_Int32 nPlacementID = -1;
if ( ( mnTextStyle == EPP_TEXTSTYLE_TITLE ) || ( mnTextStyle == EPP_TEXTSTYLE_BODY ) )
nPlacementID = nIndices++;
else
@@ -5319,7 +3338,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
{
sal_uInt32 nTextType = EPP_TEXTTYPE_Body;
if ( mnTextStyle == EPP_TEXTSTYLE_BODY )
- {
+ {
if ( bSecOutl )
nTextType = EPP_TEXTTYPE_HalfBody;
else if ( mType == "presentation.Subtitle" )
@@ -5486,43 +3505,11 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
// -----------------------------------------------------------------------
-::com::sun::star::awt::Point PPTWriter::ImplMapPoint( const ::com::sun::star::awt::Point& rPoint )
-{
- Point aRet( OutputDevice::LogicToLogic( Point( rPoint.X, rPoint.Y ), maMapModeSrc, maMapModeDest ) );
- return ::com::sun::star::awt::Point( aRet.X(), aRet.Y() );
-}
-
-// -----------------------------------------------------------------------
-
-::com::sun::star::awt::Size PPTWriter::ImplMapSize( const ::com::sun::star::awt::Size& rSize )
-{
- Size aRetSize( OutputDevice::LogicToLogic( Size( rSize.Width, rSize.Height ), maMapModeSrc, maMapModeDest ) );
-
- if ( !aRetSize.Width() )
- aRetSize.Width()++;
- if ( !aRetSize.Height() )
- aRetSize.Height()++;
- return ::com::sun::star::awt::Size( aRetSize.Width(), aRetSize.Height() );
-}
-
-// -----------------------------------------------------------------------
-
-Rectangle PPTWriter::ImplMapRectangle( const ::com::sun::star::awt::Rectangle& rRect )
-{
- ::com::sun::star::awt::Point aPoint( rRect.X, rRect.Y );
- ::com::sun::star::awt::Size aSize( rRect.Width, rRect.Height );
- ::com::sun::star::awt::Point aP( ImplMapPoint( aPoint ) );
- ::com::sun::star::awt::Size aS( ImplMapSize( aSize ) );
- return Rectangle( Point( aP.X, aP.Y ), Size( aS.Width, aS.Height ) );
-}
-
-// -----------------------------------------------------------------------
-
struct CellBorder
{
- sal_Int32 mnPos; // specifies the distance to the top/left position of the table
- sal_Int32 mnLength;
- table::BorderLine maCellBorder;
+ sal_Int32 mnPos; // specifies the distance to the top/left position of the table
+ sal_Int32 mnLength;
+ table::BorderLine maCellBorder;
CellBorder() : mnPos ( 0 ), mnLength( 0 ){};
};
@@ -5542,16 +3529,16 @@ void PPTWriter::ImplCreateCellBorder( const CellBorder* pCellBorder, sal_Int32 n
aPropOptSp.AddOpt( ESCHER_Prop_fNoLineDrawDash, 0xa0008 );
aPropOptSp.AddOpt( ESCHER_Prop_fshadowObscured, 0x20000 );
- sal_uInt32 nBorderColor = pCellBorder->maCellBorder.Color & 0xff00; // green
- nBorderColor |= static_cast< sal_uInt8 >( pCellBorder->maCellBorder.Color ) << 16; // red
- nBorderColor |= static_cast< sal_uInt8 >( pCellBorder->maCellBorder.Color >> 16 ); // blue
+ sal_uInt32 nBorderColor = pCellBorder->maCellBorder.Color & 0xff00; // green
+ nBorderColor |= static_cast< sal_uInt8 >( pCellBorder->maCellBorder.Color ) << 16; // red
+ nBorderColor |= static_cast< sal_uInt8 >( pCellBorder->maCellBorder.Color >> 16 ); // blue
aPropOptSp.AddOpt( ESCHER_Prop_lineColor, nBorderColor );
aPropOptSp.AddOpt( ESCHER_Prop_lineWidth, nLineWidth * 360 );
aPropOptSp.AddOpt( ESCHER_Prop_fc3DLightFace, 0x80000 );
aPropOptSp.Commit( *mpStrm );
mpPptEscherEx->AddAtom( 16, ESCHER_ChildAnchor );
- *mpStrm << nX1
+ *mpStrm << nX1
<< nY1
<< nX2
<< nY2;
@@ -5577,18 +3564,18 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
mpPptEscherEx->OpenContainer( ESCHER_SpgrContainer );
mpPptEscherEx->OpenContainer( ESCHER_SpContainer );
mpPptEscherEx->AddAtom( 16, ESCHER_Spgr, 1 );
- *mpStrm << (sal_Int32)maRect.Left() // Bounding box fuer die Gruppierten shapes an die sie attached werden
+ *mpStrm << (sal_Int32)maRect.Left() // Bounding box fuer die Gruppierten shapes an die sie attached werden
<< (sal_Int32)maRect.Top()
<< (sal_Int32)maRect.Right()
<< (sal_Int32)maRect.Bottom();
sal_uInt32 nShapeId = mpPptEscherEx->GenerateShapeId();
- mpPptEscherEx->AddShape( ESCHER_ShpInst_Min, 0x201, nShapeId ); // Flags: Group | Patriarch
+ mpPptEscherEx->AddShape( ESCHER_ShpInst_Min, 0x201, nShapeId ); // Flags: Group | Patriarch
aSolverContainer.AddShape( rXShape, nShapeId );
EscherPropertyContainer aPropOpt2;
try
{
- static const rtl::OUString sModel( RTL_CONSTASCII_USTRINGPARAM ( "Model" ) );
+ static const rtl::OUString sModel( RTL_CONSTASCII_USTRINGPARAM ( "Model" ) );
static const rtl::OUString sWidth( RTL_CONSTASCII_USTRINGPARAM ( "Width" ) );
static const rtl::OUString sHeight( RTL_CONSTASCII_USTRINGPARAM ( "Height" ) );
@@ -5604,14 +3591,14 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
std::vector< std::pair< sal_Int32, sal_Int32 > > aColumns;
std::vector< std::pair< sal_Int32, sal_Int32 > > aRows;
- awt::Point aPosition( ImplMapPoint( rXShape->getPosition() ) );
+ awt::Point aPosition( MapPoint( rXShape->getPosition() ) );
sal_uInt32 nPosition = aPosition.X;
for ( sal_Int32 x = 0; x < nColumnCount; x++ )
{
uno::Reference< beans::XPropertySet > xPropSet( xColumns->getByIndex( x ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sWidth ) >>= aS.Width;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
aColumns.push_back( std::pair< sal_Int32, sal_Int32 >( nPosition, aM.Width ) );
nPosition += aM.Width;
}
@@ -5622,7 +3609,7 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
uno::Reference< beans::XPropertySet > xPropSet( xRows->getByIndex( y ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sHeight ) >>= aS.Height;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
aRows.push_back( std::pair< sal_Int32, sal_Int32 >( nPosition, aM.Height ) );
nPosition += aM.Height;
}
@@ -5651,7 +3638,6 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
mpPptEscherEx->AddClientAnchor( maRect );
mpPptEscherEx->CloseContainer();
-
uno::Reference< table::XCellRange > xCellRange( xTable, uno::UNO_QUERY_THROW );
for( sal_Int32 nRow = 0; nRow < xRows->getCount(); nRow++ )
{
@@ -5706,7 +3692,7 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
aPropOptSp.Commit( *mpStrm );
mpPptEscherEx->AddAtom( 16, ESCHER_ChildAnchor );
- *mpStrm << nLeft
+ *mpStrm << nLeft
<< nTop
<< nRight
<< nBottom;
@@ -5723,28 +3709,28 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
static const rtl::OUString sTopBorder( String( RTL_CONSTASCII_USTRINGPARAM( "TopBorder" ) ) );
static const rtl::OUString sBottomBorder( String( RTL_CONSTASCII_USTRINGPARAM( "BottomBorder" ) ) );
static const rtl::OUString sLeftBorder( String( RTL_CONSTASCII_USTRINGPARAM( "LeftBorder" ) ) );
- static const rtl::OUString sRightBorder( String( RTL_CONSTASCII_USTRINGPARAM( "RightBorder" ) ) );
- static const rtl::OUString sDiagonalTLBR( RTL_CONSTASCII_USTRINGPARAM ( "DiagonalTLBR" ) );
- static const rtl::OUString sDiagonalBLTR( RTL_CONSTASCII_USTRINGPARAM ( "DiagonalBLTR" ) );
+ static const rtl::OUString sRightBorder( String( RTL_CONSTASCII_USTRINGPARAM( "RightBorder" ) ) );
+ static const rtl::OUString sDiagonalTLBR( RTL_CONSTASCII_USTRINGPARAM ( "DiagonalTLBR" ) );
+ static const rtl::OUString sDiagonalBLTR( RTL_CONSTASCII_USTRINGPARAM ( "DiagonalBLTR" ) );
// creating horz lines
- sal_Int32 nYPos = ImplMapPoint( rXShape->getPosition() ).Y;
+ sal_Int32 nYPos = MapPoint( rXShape->getPosition() ).Y;
for( sal_Int32 nLine = 0; nLine < ( xRows->getCount() + 1 ); nLine++ )
{
- sal_Int32 nXPos = ImplMapPoint( rXShape->getPosition() ).X;
+ sal_Int32 nXPos = MapPoint( rXShape->getPosition() ).X;
std::vector< CellBorder > vCellBorders;
for( sal_Int32 nColumn = 0; nColumn < xColumns->getCount(); nColumn++ )
{
uno::Reference< beans::XPropertySet > xPropSet( xColumns->getByIndex( nColumn ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sWidth ) >>= aS.Width;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
CellBorder aCellBorder;
aCellBorder.mnPos = nXPos;
aCellBorder.mnLength = aM.Width;
if ( nLine < xRows->getCount() )
- { // top border
+ { // top border
uno::Reference< table::XMergeableCell > xCell( xCellRange->getCellByPosition( nColumn, nLine ), uno::UNO_QUERY_THROW );
uno::Reference< beans::XPropertySet > xPropSet2( xCell, uno::UNO_QUERY_THROW );
table::BorderLine aBorderLine;
@@ -5752,7 +3738,7 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
aCellBorder.maCellBorder = aBorderLine;
}
if ( nLine )
- { // bottom border
+ { // bottom border
uno::Reference< table::XMergeableCell > xCell( xCellRange->getCellByPosition( nColumn, nLine - 1 ), uno::UNO_QUERY_THROW );
uno::Reference< beans::XPropertySet > xPropSet2( xCell, uno::UNO_QUERY_THROW );
table::BorderLine aBorderLine;
@@ -5767,36 +3753,36 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
{
ImplCreateCellBorder( &*aCellBorderIter, aCellBorderIter->mnPos, nYPos,
static_cast< sal_Int32 >( aCellBorderIter->mnPos + aCellBorderIter->mnLength ), nYPos );
- aCellBorderIter++;
+ ++aCellBorderIter;
}
if ( nLine < xRows->getCount() )
{
uno::Reference< beans::XPropertySet > xPropSet( xRows->getByIndex( nLine ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sHeight ) >>= aS.Height;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
nYPos += aM.Height;
}
}
// creating vertical lines
- sal_Int32 nXPos = ImplMapPoint( rXShape->getPosition() ).X;
+ sal_Int32 nXPos = MapPoint( rXShape->getPosition() ).X;
for( sal_Int32 nLine = 0; nLine < ( xColumns->getCount() + 1 ); nLine++ )
{
- nYPos = ImplMapPoint( rXShape->getPosition() ).Y;
+ nYPos = MapPoint( rXShape->getPosition() ).Y;
std::vector< CellBorder > vCellBorders;
for( sal_Int32 nRow = 0; nRow < xRows->getCount(); nRow++ )
{
uno::Reference< beans::XPropertySet > xPropSet( xRows->getByIndex( nRow ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sHeight ) >>= aS.Height;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
CellBorder aCellBorder;
aCellBorder.mnPos = nYPos;
aCellBorder.mnLength = aM.Height;
if ( nLine < xColumns->getCount() )
- { // left border
+ { // left border
uno::Reference< table::XMergeableCell > xCell( xCellRange->getCellByPosition( nLine, nRow ), uno::UNO_QUERY_THROW );
uno::Reference< beans::XPropertySet > xCellSet( xCell, uno::UNO_QUERY_THROW );
table::BorderLine aBorderLine;
@@ -5804,7 +3790,7 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
aCellBorder.maCellBorder = aBorderLine;
}
if ( nLine )
- { // right border
+ { // right border
uno::Reference< table::XMergeableCell > xCell( xCellRange->getCellByPosition( nLine - 1, nRow ), uno::UNO_QUERY_THROW );
uno::Reference< beans::XPropertySet > xCellSet( xCell, uno::UNO_QUERY_THROW );
table::BorderLine aBorderLine;
@@ -5819,14 +3805,14 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
{
ImplCreateCellBorder( &*aCellBorderIter, nXPos, aCellBorderIter->mnPos,
nXPos, static_cast< sal_Int32 >( aCellBorderIter->mnPos + aCellBorderIter->mnLength ) );
- aCellBorderIter++;
+ ++aCellBorderIter;
}
if ( nLine < xColumns->getCount() )
{
uno::Reference< beans::XPropertySet > xPropSet( xColumns->getByIndex( nLine ), uno::UNO_QUERY_THROW );
awt::Size aS( 0, 0 );
xPropSet->getPropertyValue( sWidth ) >>= aS.Width;
- awt::Size aM( ImplMapSize( aS ) );
+ awt::Size aM( MapSize( aS ) );
nXPos += aM.Width;
}
}
@@ -5838,3 +3824,45 @@ void PPTWriter::ImplCreateTable( uno::Reference< drawing::XShape >& rXShape, Esc
}
mpPptEscherEx->CloseContainer();
}
+
+//----------------------------------------------------------------------------------------------------------
+
+void TextObjBinary::Write( SvStream* pStrm )
+{
+ sal_uInt32 nSize, nPos = pStrm->Tell();
+ *pStrm << (sal_uInt32)( EPP_TextCharsAtom << 16 ) << (sal_uInt32)0;
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ ((ParagraphObj*)pPtr)->Write( pStrm );
+ nSize = pStrm->Tell() - nPos;
+ pStrm->SeekRel( - ( (sal_Int32)nSize - 4 ) );
+ *pStrm << (sal_uInt32)( nSize - 8 );
+ pStrm->SeekRel( nSize - 8 );
+}
+
+void TextObjBinary::WriteTextSpecInfo( SvStream* pStrm )
+{
+ sal_uInt32 nCharactersLeft( Count() );
+ if ( nCharactersLeft >= 1 )
+ {
+ EscherExAtom aAnimationInfoAtom( *pStrm, EPP_TextSpecInfoAtom, 0, 0 );
+ for ( ParagraphObj* pPtr = static_cast < ParagraphObj * >( First() ); nCharactersLeft && pPtr; pPtr = static_cast< ParagraphObj* >( Next() ) )
+ {
+ for ( PortionObj* pPortion = static_cast< PortionObj* >( pPtr->First() ); nCharactersLeft && pPortion; pPortion = static_cast< PortionObj* >( pPtr->Next() ) )
+ {
+ sal_Int32 nPortionSize = pPortion->mnTextSize >= nCharactersLeft ? nCharactersLeft : pPortion->mnTextSize;
+ sal_Int32 nFlags = 7;
+ nCharactersLeft -= nPortionSize;
+ *pStrm << static_cast< sal_uInt32 >( nPortionSize )
+ << nFlags
+ << static_cast< sal_Int16 >( 1 ) // spellinfo -> needs rechecking
+ << static_cast< sal_Int16 >( MsLangId::convertLocaleToLanguageWithFallback( pPortion->meCharLocale ) )
+ << static_cast< sal_Int16 >( 0 ); // alt language
+ }
+ }
+ if ( nCharactersLeft )
+ *pStrm << nCharactersLeft << static_cast< sal_Int32 >( 1 ) << static_cast< sal_Int16 >( 1 );
+
+ }
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/escherex.cxx b/sd/source/filter/eppt/escherex.cxx
index fddb0b9ff..1327d099d 100755..100644
--- a/sd/source/filter/eppt/escherex.cxx
+++ b/sd/source/filter/eppt/escherex.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#include "precompiled_sd.hxx"
-#ifndef _PptEscherEx_HXX
#include "escherex.hxx"
-#endif
// ---------------------------------------------------------------------------------------------
// ---------------------------------------------------------------------------------------------
@@ -183,11 +182,6 @@ void PptEscherEx::OpenContainer( sal_uInt16 n_EscherContainer, int nRecInstance
}
break;
- case ESCHER_SpContainer :
- {
- }
- break;
-
default:
break;
}
@@ -304,3 +298,5 @@ sal_uInt32 PptEscherEx::EnterGroup( Rectangle* pBoundRect, SvMemoryStream* pClie
}
// ---------------------------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/escherex.hxx b/sd/source/filter/eppt/escherex.hxx
index 64163dec3..4ed7dbf61 100755..100644
--- a/sd/source/filter/eppt/escherex.hxx
+++ b/sd/source/filter/eppt/escherex.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ class PptEscherEx : public EscherEx
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/grouptable.hxx b/sd/source/filter/eppt/grouptable.hxx
new file mode 100644
index 000000000..d9e11661a
--- /dev/null
+++ b/sd/source/filter/eppt/grouptable.hxx
@@ -0,0 +1,86 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef EPPT_GROUP_TABLE
+#define EPPT_GROUP_TABLE
+
+#include <com/sun/star/container/XIndexAccess.hpp>
+
+struct GroupEntry
+{
+ sal_uInt32 mnCurrentPos;
+ sal_uInt32 mnCount;
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > mXIndexAccess;
+
+ GroupEntry( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex )
+ {
+ mXIndexAccess = rIndex;
+ mnCount =mXIndexAccess->getCount();
+ mnCurrentPos = 0;
+ };
+
+ GroupEntry( sal_uInt32 nCount )
+ {
+ mnCount = nCount;
+ mnCurrentPos = 0;
+ };
+
+ ~GroupEntry(){};
+};
+
+class GroupTable
+{
+ protected:
+
+ sal_uInt32 mnIndex;
+ sal_uInt32 mnCurrentGroupEntry;
+ sal_uInt32 mnMaxGroupEntry;
+ sal_uInt32 mnGroupsClosed;
+ GroupEntry** mpGroupEntry;
+
+ void ImplResizeGroupTable( sal_uInt32 nEntrys );
+
+ public:
+
+ sal_uInt32 GetCurrentGroupIndex() const { return mnIndex; };
+ sal_Int32 GetCurrentGroupLevel() const { return mnCurrentGroupEntry - 1; };
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > &
+ GetCurrentGroupAccess() const { return mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mXIndexAccess; };
+ sal_uInt32 GetGroupsClosed();
+ void SkipCurrentGroup();
+ void ResetGroupTable( sal_uInt32 nCount );
+ void ClearGroupTable();
+ sal_Bool EnterGroup( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex );
+ sal_Bool GetNextGroupEntry();
+ GroupTable();
+ ~GroupTable();
+};
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/makefile.mk b/sd/source/filter/eppt/makefile.mk
deleted file mode 100644
index 85a8ee181..000000000
--- a/sd/source/filter/eppt/makefile.mk
+++ /dev/null
@@ -1,52 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=eppt
-ENABLE_EXCEPTIONS=TRUE
-VISIBILITY_HIDDEN=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-
-.IF "$(COM)"=="GCC"
-NOOPTFILES= $(SLO)$/epptso.obj
-.ENDIF
-
-SLOFILES = $(SLO)$/eppt.obj \
- $(SLO)$/epptso.obj \
- $(SLO)$/escherex.obj \
- $(SLO)$/pptexanimations.obj \
- $(SLO)$/pptexsoundcollection.obj
-
-# --- Targets --------------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/filter/eppt/pptexanimations.cxx b/sd/source/filter/eppt/pptexanimations.cxx
index cceeed929..ba37531fc 100644
--- a/sd/source/filter/eppt/pptexanimations.cxx
+++ b/sd/source/filter/eppt/pptexanimations.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -52,7 +53,6 @@
#include <com/sun/star/animations/TransitionSubType.hpp>
#include <com/sun/star/animations/ValuePair.hpp>
#include <com/sun/star/animations/AnimationColorSpace.hpp>
-#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/drawing/FillStyle.hpp>
#include <com/sun/star/drawing/LineStyle.hpp>
#include <com/sun/star/awt/FontWeight.hpp>
@@ -66,9 +66,7 @@
#include <com/sun/star/container/XChild.hpp>
#include <comphelper/processfactory.hxx>
#include <rtl/ustrbuf.hxx>
-#ifndef _RTL_MEMORY_H_
-#include <rtl/memory.hxx>
-#endif
+#include <rtl/memory.h>
#include <vcl/vclenum.hxx>
#include <svx/svdotext.hxx>
@@ -161,10 +159,10 @@ void ImplTranslateAttribute( rtl::OUString& rString, const TranslateMode eTransl
}
}
-sal_uInt32 ImplTranslatePresetSubType( const sal_uInt32 nPresetClass, const sal_uInt32 nPresetId, const rtl::OUString& rPresetSubType )
+sal_uInt32 AnimationExporter::TranslatePresetSubType( const sal_uInt32 nPresetClass, const sal_uInt32 nPresetId, const rtl::OUString& rPresetSubType )
{
- sal_uInt32 nPresetSubType = 0;
- sal_Bool bTranslated = sal_False;
+ sal_uInt32 nPresetSubType = 0;
+ sal_Bool bTranslated = sal_False;
if ( ( nPresetClass == (sal_uInt32)EffectPresetClass::ENTRANCE ) || ( nPresetClass == (sal_uInt32)EffectPresetClass::EXIT ) )
{
@@ -241,10 +239,10 @@ sal_uInt32 ImplTranslatePresetSubType( const sal_uInt32 nPresetClass, const sal_
return nPresetSubType;
}
-const sal_Char* transition::find( const sal_Int16 nType, const sal_Int16 nSubType, const sal_Bool bDirection )
+const sal_Char* AnimationExporter::FindTransitionName( const sal_Int16 nType, const sal_Int16 nSubType, const sal_Bool bDirection )
{
const sal_Char* pRet = NULL;
- int nFit = 0;
+ int nFit = 0;
const transition* p = gTransitions;
while( p->mpName )
@@ -261,7 +259,7 @@ const sal_Char* transition::find( const sal_Int16 nType, const sal_Int16 nSubTyp
pRet = p->mpName;
nFit = nF;
}
- if ( nFit == 7 ) // maximum
+ if ( nFit == 7 ) // maximum
break;
p++;
}
@@ -283,7 +281,7 @@ SvStream& operator<<(SvStream& rOut, AnimationNode& rNode )
}
AnimationExporter::AnimationExporter( const EscherSolverContainer& rSolverContainer, ppt::ExSoundCollection& rExSoundCollection ) :
- mrSolverContainer ( rSolverContainer ),
+ mrSolverContainer ( rSolverContainer ),
mrExSoundCollection ( rExSoundCollection ),
mnCurrentGroup(0)
{
@@ -291,7 +289,7 @@ AnimationExporter::AnimationExporter( const EscherSolverContainer& rSolverContai
// --------------------------------------------------------------------
-static sal_Int16 GetFillMode( const Reference< XAnimationNode >& xNode, const sal_Int16 nFillDefault )
+sal_Int16 AnimationExporter::GetFillMode( const Reference< XAnimationNode >& xNode, const sal_Int16 nFillDefault )
{
sal_Int16 nFill = xNode->getFill();
if ( ( nFill == AnimationFill::DEFAULT ) ||
@@ -398,7 +396,7 @@ void AnimationExporter::processAfterEffectNodes( const Reference< XAnimationNode
while( nLength-- )
{
- if( p->Name.equalsAscii( "master-element" ) )
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "master-element" ) ) )
{
p->Value >>= xMaster;
break;
@@ -420,7 +418,7 @@ void AnimationExporter::processAfterEffectNodes( const Reference< XAnimationNode
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "(@CL)AnimationExporter::processAfterEffectNodes(), exception cought!" );
+ OSL_FAIL( "(@CL)AnimationExporter::processAfterEffectNodes(), exception cought!" );
}
}
@@ -586,14 +584,6 @@ void AnimationExporter::exportNode( SvStream& rStrm, Reference< XAnimationNode >
exportAnimPropertySet( rStrm, xNode );
exportAnimEvent( rStrm, xNode, 0 );
exportAnimValue( rStrm, xNode, sal_False );
-
- /*
- EscherExContainer aContainer( rStrm, DFF_msofbtAnimGroup, 1 );
- exportAnimNode( rStrm, xNode, pParent, nGroupLevel + 1, nFillDefault );
- exportAnimPropertySet( rStrm, xNode );
- exportAnimEvent( rStrm, xNode, 0 );
- exportAnimValue( rStrm, xNode, sal_False );
- */
}
break;
@@ -676,7 +666,7 @@ void AnimationExporter::exportNode( SvStream& rStrm, Reference< XAnimationNode >
}
break;
- case AnimationNodeType::AUDIO : // #i58428#
+ case AnimationNodeType::AUDIO : // #i58428#
{
exportAnimNode( rStrm, xNode, pParent, nGroupLevel, nFillDefault );
exportAnimPropertySet( rStrm, xNode );
@@ -777,22 +767,42 @@ Reference< XAnimationNode > AnimationExporter::createAfterEffectNodeClone( const
Any aEmpty;
xCloneNode->setBegin( aEmpty );
-
return xCloneNode;
}
catch( Exception& e )
{
(void)e;
- DBG_ERROR("(@CL)sd::ppt::AnimationExporter::createAfterEffectNodeClone(), could not create clone!" );
+ OSL_FAIL("(@CL)sd::ppt::AnimationExporter::createAfterEffectNodeClone(), could not create clone!" );
}
return xNode;
}
+sal_Bool AnimationExporter::GetNodeType( const Reference< XAnimationNode >& xNode, sal_Int16& nType )
+{
+ // trying to get the nodetype
+ Sequence< NamedValue > aUserData = xNode->getUserData();
+ if ( aUserData.getLength() )
+ {
+ const NamedValue* p = aUserData.getConstArray();
+ sal_Int32 nLength = aUserData.getLength();
+ while( nLength-- )
+ {
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
+ {
+ if ( p->Value >>= nType )
+ return sal_True;
+ }
+ }
+ }
+
+ return sal_False;
+}
+
void AnimationExporter::exportAnimNode( SvStream& rStrm, const Reference< XAnimationNode >& xNode,
const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >*, const sal_Int32, const sal_Int16 nFillDefault )
{
- EscherExAtom aAnimNodeExAtom( rStrm, DFF_msofbtAnimNode );
- AnimationNode aAnim;
+ EscherExAtom aAnimNodeExAtom( rStrm, DFF_msofbtAnimNode );
+ AnimationNode aAnim;
rtl_zeroMemory( &aAnim, sizeof( aAnim ) );
// attribute Restart
@@ -805,14 +815,12 @@ void AnimationExporter::exportAnimNode( SvStream& rStrm, const Reference< XAnima
case AnimationRestart::NEVER : aAnim.mnRestart = 3; break;
}
- // attribute Fill
-// aAnim.mnFill = GetFillMode( xNode, pParent );
switch( nFillDefault )
{
default:
case AnimationFill::DEFAULT : aAnim.mnFill = 0; break;
case AnimationFill::REMOVE : aAnim.mnFill = 1; break;
- case AnimationFill::FREEZE : // aAnim.mnFill = 2; break;
+ case AnimationFill::FREEZE :
case AnimationFill::HOLD : aAnim.mnFill = 3; break;
case AnimationFill::TRANSITION : aAnim.mnFill = 4; break;
}
@@ -836,39 +844,16 @@ void AnimationExporter::exportAnimNode( SvStream& rStrm, const Reference< XAnima
aAnim.mnGroupType = mso_Anim_GroupType_SEQ;
switch( xNode->getType() )
{
- case AnimationNodeType::PAR : // PASSTROUGH!!! (as it was intended)
+ case AnimationNodeType::PAR : // PASSTROUGH!!! (as it was intended)
aAnim.mnGroupType = mso_Anim_GroupType_PAR;
case AnimationNodeType::SEQ :
{
- // trying to get the nodetype
- Sequence< NamedValue > aUserData = xNode->getUserData();
- if ( aUserData.getLength() )
+ sal_Int16 nType = 0;
+ if( GetNodeType( xNode, nType ) )
+ switch( nType )
{
- const NamedValue* p = aUserData.getConstArray();
- sal_Int32 nLength = aUserData.getLength();
- while( nLength-- )
- {
- if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
- {
- sal_Int16 nType = 0;
- if ( p->Value >>= nType )
- {
- switch( nType )
- {
- case ::com::sun::star::presentation::EffectNodeType::TIMING_ROOT : aAnim.mnNodeType = 0x12; break;
- case ::com::sun::star::presentation::EffectNodeType::MAIN_SEQUENCE : aAnim.mnNodeType = 0x18; break;
- /*
- case ::com::sun::star::presentation::EffectNodeType::ON_CLICK :
- case ::com::sun::star::presentation::EffectNodeType::WITH_PREVIOUS :
- case ::com::sun::star::presentation::EffectNodeType::AFTER_PREVIOUS :
- case ::com::sun::star::presentation::EffectNodeType::INTERACTIVE_SEQUENCE :
- default:
- */
- }
- }
- break;
- }
- }
+ case ::com::sun::star::presentation::EffectNodeType::TIMING_ROOT : aAnim.mnNodeType = 0x12; break;
+ case ::com::sun::star::presentation::EffectNodeType::MAIN_SEQUENCE : aAnim.mnNodeType = 0x18; break;
}
}
break;
@@ -901,54 +886,93 @@ void AnimationExporter::exportAnimNode( SvStream& rStrm, const Reference< XAnima
}
break;
}
+
rStrm << aAnim;
}
+void AnimationExporter::GetUserData( const Sequence< NamedValue >& rUserData, const Any ** pAny, sal_Size nLen )
+{
+ // storing user data into pAny, to allow direct access later
+ rtl_zeroMemory( pAny, nLen );
+ if ( rUserData.getLength() )
+ {
+ const NamedValue* p = rUserData.getConstArray();
+ sal_Int32 nLength = rUserData.getLength();
+ while( nLength-- )
+ {
+ if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
+ {
+ pAny[ DFF_ANIM_NODE_TYPE ] = &(p->Value);
+ }
+ else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-class" ) ) )
+ {
+ pAny[ DFF_ANIM_PRESET_CLASS ] = &(p->Value);
+ }
+ else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-id" ) ) )
+ {
+ pAny[ DFF_ANIM_PRESET_ID ] = &(p->Value);
+ }
+ else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-sub-type" ) ) )
+ {
+ pAny[ DFF_ANIM_PRESET_SUB_TYPE ] = &(p->Value);
+ }
+ else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "master-element" ) ) )
+ {
+ pAny[ DFF_ANIM_AFTEREFFECT ] = &(p->Value);;
+ }
+ p++;
+ }
+ }
+}
+
+sal_uInt32 AnimationExporter::GetPresetID( const rtl::OUString& rPreset, sal_uInt32 nAPIPresetClass, sal_Bool& bPresetId )
+{
+ sal_uInt32 nPresetId = 0;
+ bPresetId = sal_False;
+
+ if ( rPreset.match( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ppt_" ) ), 0 ) )
+ {
+ sal_Int32 nLast = rPreset.lastIndexOf( '_' );
+ if ( ( nLast != -1 ) && ( ( nLast + 1 ) < rPreset.getLength() ) )
+ {
+ rtl::OUString aNumber( rPreset.copy( nLast + 1 ) );
+ nPresetId = aNumber.toInt32();
+ bPresetId = sal_True;
+ }
+ }
+ else
+ {
+ const preset_maping* p = gPresetMaping;
+ while( p->mpStrPresetId && ((p->mnPresetClass != (sal_Int32)nAPIPresetClass) || !rPreset.equalsAscii( p->mpStrPresetId )) )
+ p++;
+
+ if( p->mpStrPresetId )
+ {
+ nPresetId = p->mnPresetId;
+ bPresetId = sal_True;
+ }
+ }
+
+ return nPresetId;
+}
+
sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Reference< XAnimationNode >& xNode )
{
sal_Int16 nNodeType = ::com::sun::star::presentation::EffectNodeType::DEFAULT;
EscherExContainer aAnimPropertySet( rStrm, DFF_msofbtAnimPropertySet );
- const ::com::sun::star::uno::Any* pAny[ DFF_ANIM_PROPERTY_ID_COUNT ];
- rtl_zeroMemory( pAny, sizeof( pAny ) );
Reference< XAnimationNode > xMaster;
- const Any aTrue( makeAny( (sal_Bool)sal_True ) );
Any aMasterRel, aOverride, aRunTimeContext;
// storing user data into pAny, to allow direct access later
- Sequence< NamedValue > aUserData = xNode->getUserData();
- if ( aUserData.getLength() )
- {
- const NamedValue* p = aUserData.getConstArray();
- sal_Int32 nLength = aUserData.getLength();
- while( nLength-- )
- {
- if( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "node-type" ) ) )
- {
- pAny[ DFF_ANIM_NODE_TYPE ] = &(p->Value);
- }
- else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-class" ) ) )
- {
- pAny[ DFF_ANIM_PRESET_CLASS ] = &(p->Value);
- }
- else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-id" ) ) )
- {
- pAny[ DFF_ANIM_PRESET_ID ] = &(p->Value);
- }
- else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preset-sub-type" ) ) )
- {
- pAny[ DFF_ANIM_PRESET_SUB_TYPE ] = &(p->Value);
- }
- else if ( p->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "master-element" ) ) )
- {
- pAny[ DFF_ANIM_AFTEREFFECT ] = &aTrue;
- p->Value >>= xMaster;
- }
- p++;
- }
- }
+ const Sequence< NamedValue > aUserData = xNode->getUserData();
+ const ::com::sun::star::uno::Any* pAny[ DFF_ANIM_PROPERTY_ID_COUNT ];
+ GetUserData( aUserData, pAny, sizeof( pAny ) );
+
+ if( pAny[ DFF_ANIM_AFTEREFFECT ] )
+ ( *pAny[ DFF_ANIM_AFTEREFFECT ] ) >>= xMaster;
// calculate master-rel
if( xMaster.is() )
@@ -978,7 +1002,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
sal_uInt32 nPPTNodeType = DFF_ANIM_NODE_TYPE_ON_CLICK;
switch( nNodeType )
{
- case ::com::sun::star::presentation::EffectNodeType::ON_CLICK : nPPTNodeType = DFF_ANIM_NODE_TYPE_ON_CLICK; break;
+ case ::com::sun::star::presentation::EffectNodeType::ON_CLICK : nPPTNodeType = DFF_ANIM_NODE_TYPE_ON_CLICK; break;
case ::com::sun::star::presentation::EffectNodeType::WITH_PREVIOUS : nPPTNodeType = DFF_ANIM_NODE_TYPE_WITH_PREVIOUS; break;
case ::com::sun::star::presentation::EffectNodeType::AFTER_PREVIOUS : nPPTNodeType = DFF_ANIM_NODE_TYPE_AFTER_PREVIOUS; break;
case ::com::sun::star::presentation::EffectNodeType::MAIN_SEQUENCE : nPPTNodeType = DFF_ANIM_NODE_TYPE_MAIN_SEQUENCE; break;
@@ -993,7 +1017,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
sal_uInt32 nAPIPresetClass = EffectPresetClass::CUSTOM;
sal_uInt32 nPresetClass = DFF_ANIM_PRESS_CLASS_USER_DEFINED;
sal_Bool bPresetClass, bPresetId, bPresetSubType;
- bPresetClass = bPresetId = bPresetSubType = sal_False;
+ bPresetId = bPresetClass = bPresetSubType = sal_False;
if ( pAny[ DFF_ANIM_PRESET_CLASS ] )
{
@@ -1019,30 +1043,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
{
rtl::OUString sPreset;
if ( *pAny[ DFF_ANIM_PRESET_ID ] >>= sPreset )
- {
- if ( sPreset.match( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ppt_" ) ), 0 ) )
- {
- sal_Int32 nLast = sPreset.lastIndexOf( '_' );
- if ( ( nLast != -1 ) && ( ( nLast + 1 ) < sPreset.getLength() ) )
- {
- rtl::OUString aNumber( sPreset.copy( nLast + 1 ) );
- nPresetId = aNumber.toInt32();
- bPresetId = sal_True;
- }
- }
- else
- {
- const preset_maping* p = gPresetMaping;
- while( p->mpStrPresetId && ((p->mnPresetClass != (sal_Int32)nAPIPresetClass) || !sPreset.equalsAscii( p->mpStrPresetId )) )
- p++;
-
- if( p->mpStrPresetId )
- {
- nPresetId = p->mnPresetId;
- bPresetId = sal_True;
- }
- }
- }
+ nPresetId = GetPresetID( sPreset, nAPIPresetClass, bPresetId );
}
if ( pAny[ DFF_ANIM_PRESET_SUB_TYPE ] )
@@ -1050,7 +1051,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
rtl::OUString sPresetSubType;
if ( *pAny[ DFF_ANIM_PRESET_SUB_TYPE ] >>= sPresetSubType )
{
- nPresetSubType = ImplTranslatePresetSubType( nPresetClass, nPresetId, sPresetSubType );
+ nPresetSubType = TranslatePresetSubType( nPresetClass, nPresetId, sPresetSubType );
bPresetSubType = sal_True;
}
}
@@ -1089,9 +1090,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
Reference< XAnimateColor > xColor( xNode, UNO_QUERY );
if( xColor.is() )
{
-// sal_uInt32 nColorSpace = xColor->getColorSpace() == AnimationColorSpace::RGB ? 0 : 1;
-// exportAnimPropertyuInt32( rStrm, DFF_ANIM_COLORSPACE, nColorSpace, TRANSLATE_NONE );
-
+
sal_Bool bDirection = !xColor->getDirection();
exportAnimPropertyuInt32( rStrm, DFF_ANIM_DIRECTION, bDirection, TRANSLATE_NONE );
}
@@ -1127,11 +1126,11 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
}
if ( pAny[ DFF_ANIM_EVENT_FILTER ] )
{
- // TODO DFF_ANIM_EVENT_FILTER
+ // TODO DFF_ANIM_EVENT_FILTER
}
if ( pAny[ DFF_ANIM_VOLUME ] )
{
- // TODO DFF_ANIM_VOLUME
+ // TODO DFF_ANIM_VOLUME
}
return nNodeType;
}
@@ -1289,7 +1288,7 @@ void AnimationExporter::exportAnimEvent( SvStream& rStrm, const Reference< XAnim
switch( i )
{
- case 0 :
+ case 0 :
case 1 :
{
Any aAny;
@@ -1304,7 +1303,6 @@ void AnimationExporter::exportAnimEvent( SvStream& rStrm, const Reference< XAnim
Reference< XEnumeration > xE( xEA->createEnumeration(), UNO_QUERY_THROW );
if ( xE.is() && xE->hasMoreElements() )
{
-// while( xE->hasMoreElements() )
{
Reference< XAnimationNode > xClickNode( xE->nextElement(), UNO_QUERY );
aAny = xClickNode->getBegin();
@@ -1318,7 +1316,7 @@ void AnimationExporter::exportAnimEvent( SvStream& rStrm, const Reference< XAnim
else
{
aAny = xNode->getBegin();
- if ( nFlags & 0x10 ) // replace ON_NEXT with IDEFINITE
+ if ( nFlags & 0x10 ) // replace ON_NEXT with IDEFINITE
{
if ( ( aAny >>= aEvent ) && ( aEvent.Trigger == EventTrigger::ON_NEXT ) )
{
@@ -1413,7 +1411,7 @@ void AnimationExporter::exportAnimEvent( SvStream& rStrm, const Reference< XAnim
}
}
-Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::OUString& rAttributeName ) const
+Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::OUString& rAttributeName )
{
rtl::OUString aDest;
if ( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "X" ) )
@@ -1429,7 +1427,7 @@ Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::
aDest += aStr;
}
}
- else if ( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Rotate" ) ) // "r" or "style.rotation" ?
+ else if ( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Rotate" ) ) // "r" or "style.rotation" ?
|| rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "SkewX" ) )
|| rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Opacity" ) )
|| rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CharHeight" ) )
@@ -1440,7 +1438,7 @@ Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::
aDest += rtl::OUString::valueOf( fNumber );
}
else if ( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Color" ) )
- || rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FillColor" ) ) // "Fillcolor" or "FillColor" ?
+ || rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FillColor" ) ) // "Fillcolor" or "FillColor" ?
|| rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "LineColor" ) )
|| rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CharColor" ) )
)
@@ -1475,7 +1473,7 @@ Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::
if ( rSourceValue >>= eFillStyle )
{
if ( eFillStyle == ::com::sun::star::drawing::FillStyle_NONE )
- aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "none" ) ); // ?
+ aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "none" ) ); // ?
else
aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "solid" ) );
}
@@ -1521,7 +1519,7 @@ Any AnimationExporter::convertAnimateValue( const Any& rSourceValue, const rtl::
if ( eFontSlant == com::sun::star::awt::FontSlant_ITALIC )
aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "italic" ) );
else
- aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "normal" ) ); // ?
+ aDest += rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "normal" ) ); // ?
}
}
else if ( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Visibility" ) ) )
@@ -1551,8 +1549,8 @@ void AnimationExporter::exportAnimateSet( SvStream& rStrm, const Reference< XAni
EscherExContainer aAnimateSet( rStrm, DFF_msofbtAnimateSet, 0 );
{
EscherExAtom aAnimateSetData( rStrm, DFF_msofbtAnimateSetData );
- sal_uInt32 nId1 = 1; // ??
- sal_uInt32 nId2 = 1; // ??
+ sal_uInt32 nId1 = 1; // ??
+ sal_uInt32 nId2 = 1; // ??
rStrm << nId1 << nId2;
}
Any aConvertedValue( convertAnimateValue( xSet->getTo(), xSet->getAttributeName() ) );
@@ -1562,20 +1560,14 @@ void AnimationExporter::exportAnimateSet( SvStream& rStrm, const Reference< XAni
}
}
-sal_uInt32 GetValueTypeForAttributeName( const rtl::OUString& rAttributeName )
+sal_uInt32 AnimationExporter::GetValueTypeForAttributeName( const rtl::OUString& rAttributeName )
{
sal_uInt32 nValueType = 0;
-/*
- AnimationValueType::STRING == 0;
- AnimationValueType::NUMBER == 1;
- AnimationValueType::COLOR == 2;
-*/
-
struct Entry
{
const sal_Char* pName;
- sal_uInt8 nType;
+ sal_uInt8 nType;
};
static const Entry lcl_attributeMap[] =
{
@@ -1630,7 +1622,7 @@ void AnimationExporter::exportAnimate( SvStream& rStrm, const Reference< XAnimat
EscherExContainer aContainer( rStrm, DFF_msofbtAnimate, 0 );
{
- EscherExAtom aAnimateData( rStrm, DFF_msofbtAnimateData );
+ EscherExAtom aAnimateData( rStrm, DFF_msofbtAnimateData );
sal_uInt32 nBits = 0x38;
sal_Int16 nTmp = xAnimate->getCalcMode();
sal_uInt32 nCalcMode = /* (nTmp == AnimationCalcMode::FORMULA) ? 2 : */ (nTmp == AnimationCalcMode::LINEAR) ? 1 : 0;
@@ -1679,7 +1671,7 @@ void AnimationExporter::exportAnimateTarget( SvStream& rStrm, const Reference< X
if ( xAnimate.is() )
{
if ( xAnimate->getAttributeName().getLength() )
- nBits |= 4; // what is attributeName ?, maybe this is set if a DFF_msofbtAnimateAttributeNames is written
+ nBits |= 4; // what is attributeName ?, maybe this is set if a DFF_msofbtAnimateAttributeNames is written
sal_Int16 nAdditiveMode = xAnimate->getAdditive();
if ( nAdditiveMode != AnimationAdditiveMode::BASE )
{
@@ -1709,9 +1701,9 @@ void AnimationExporter::exportAnimateTarget( SvStream& rStrm, const Reference< X
rtl::OUString aAttributeName( xAnimate->getAttributeName() );
if ( nForceAttributeNames )
{
- switch( nForceAttributeNames )
+ if( nForceAttributeNames == 1 )
{
- case 1 : aAttributeName = rtl::OUString::createFromAscii( "r" ); break;
+ aAttributeName = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "r" ));
}
}
sal_Int32 nIndex = 0;
@@ -1737,54 +1729,69 @@ void AnimationExporter::exportAnimateTarget( SvStream& rStrm, const Reference< X
}
}
-void AnimationExporter::exportAnimateTargetElement( SvStream& rStrm, const Any aAny, const sal_Bool bCreate2b01Atom )
+Reference< XShape > AnimationExporter::getTargetElementShape( const Any& rAny, sal_Int32& rBegin, sal_Int32& rEnd, sal_Bool& rParagraphTarget )
{
Reference< XShape > xShape;
- aAny >>= xShape;
- sal_uInt32 nRefMode = 0; // nRefMode == 2 -> Paragraph
- sal_Int32 begin = -1;
- sal_Int32 end = -1;
+ rAny >>= xShape;
+
+ rParagraphTarget = sal_False;
if( !xShape.is() )
{
- ParagraphTarget aParaTarget;
- if( aAny >>= aParaTarget )
- xShape = aParaTarget.Shape;
- if ( xShape.is() )
+ ParagraphTarget aParaTarget;
+ if( rAny >>= aParaTarget )
+ xShape = aParaTarget.Shape;
+ if ( xShape.is() )
+ {
+ // now calculating the character range for the paragraph
+ sal_Int16 nParagraph = aParaTarget.Paragraph;
+ Reference< XSimpleText > xText( xShape, UNO_QUERY );
+ if ( xText.is() )
+ {
+ rParagraphTarget = sal_True;
+ Reference< XEnumerationAccess > xTextParagraphEnumerationAccess( xText, UNO_QUERY );
+ if ( xTextParagraphEnumerationAccess.is() )
{
- // now calculating the character range for the paragraph
- sal_Int16 nParagraph = aParaTarget.Paragraph;
- Reference< XSimpleText > xText( xShape, UNO_QUERY );
- if ( xText.is() )
+ Reference< XEnumeration > xTextParagraphEnumeration( xTextParagraphEnumerationAccess->createEnumeration() );
+ if ( xTextParagraphEnumeration.is() )
{
- nRefMode = 2;
- Reference< XEnumerationAccess > xTextParagraphEnumerationAccess( xText, UNO_QUERY );
- if ( xTextParagraphEnumerationAccess.is() )
+ sal_Int16 nCurrentParagraph;
+ rBegin = rEnd = nCurrentParagraph = 0;
+ while ( xTextParagraphEnumeration->hasMoreElements() )
+ {
+ Reference< XTextRange > xTextRange( xTextParagraphEnumeration->nextElement(), UNO_QUERY );
+ if ( xTextRange.is() )
{
- Reference< XEnumeration > xTextParagraphEnumeration( xTextParagraphEnumerationAccess->createEnumeration() );
- if ( xTextParagraphEnumeration.is() )
- {
- sal_Int16 nCurrentParagraph;
- begin = end = nCurrentParagraph = 0;
- while ( xTextParagraphEnumeration->hasMoreElements() )
- {
- Reference< XTextRange > xTextRange( xTextParagraphEnumeration->nextElement(), UNO_QUERY );
- if ( xTextRange.is() )
- {
- rtl::OUString aParaText( xTextRange->getString() );
- sal_Int32 nLength = aParaText.getLength() + 1;
- end += nLength;
- if ( nCurrentParagraph == nParagraph )
- break;
- nCurrentParagraph++;
- begin += nLength;
- }
- }
- }
+ rtl::OUString aParaText( xTextRange->getString() );
+ sal_Int32 nLength = aParaText.getLength() + 1;
+ rEnd += nLength;
+ if ( nCurrentParagraph == nParagraph )
+ break;
+ nCurrentParagraph++;
+ rBegin += nLength;
}
}
+ }
+ }
}
}
+ }
+
+ return xShape;
+}
+
+void AnimationExporter::exportAnimateTargetElement( SvStream& rStrm, const Any aAny, const sal_Bool bCreate2b01Atom )
+{
+ sal_uInt32 nRefMode = 0; // nRefMode == 2 -> Paragraph
+ sal_Int32 begin = -1;
+ sal_Int32 end = -1;
+ sal_Bool bParagraphTarget;
+
+ Reference< XShape > xShape = getTargetElementShape( aAny, begin, end, bParagraphTarget );
+
+ if( bParagraphTarget )
+ nRefMode = 2;
+
if ( xShape.is() || bCreate2b01Atom )
{
EscherExContainer aAnimateTargetElement( rStrm, DFF_msofbtAnimateTargetElement );
@@ -1792,7 +1799,7 @@ void AnimationExporter::exportAnimateTargetElement( SvStream& rStrm, const Any a
{
EscherExAtom aAnimReference( rStrm, DFF_msofbtAnimReference );
- sal_uInt32 nRefType = 1; // TODO: nRefType == 2 -> Sound;
+ sal_uInt32 nRefType = 1; // TODO: nRefType == 2 -> Sound;
sal_uInt32 nRefId = ((EscherSolverContainer&)mrSolverContainer).GetShapeId( xShape );
rStrm << nRefMode
@@ -1804,7 +1811,7 @@ void AnimationExporter::exportAnimateTargetElement( SvStream& rStrm, const Any a
if ( bCreate2b01Atom )
{
EscherExAtom a2b01Atom( rStrm, 0x2b01 );
- rStrm << (sal_uInt32)1; // ?
+ rStrm << (sal_uInt32)1; // ?
}
}
}
@@ -1912,14 +1919,14 @@ void AnimationExporter::exportTransitionFilter( SvStream& rStrm, const Reference
EscherExContainer aAnimateFilter( rStrm, DFF_msofbtAnimateFilter );
{
EscherExAtom aAnimateFilterData( rStrm, DFF_msofbtAnimateFilterData );
- sal_uInt32 nBits = 3; // bit 0 -> use AnimAttributeValue
+ sal_uInt32 nBits = 3; // bit 0 -> use AnimAttributeValue
// bit 1 -> use nTransition
sal_uInt32 nTransition = xFilter->getMode() ? 0 : 1;
rStrm << nBits
<< nTransition;
}
- const sal_Char* pFilter = transition::find( xFilter->getTransition(), xFilter->getSubtype(), xFilter->getDirection() );
+ const sal_Char* pFilter = FindTransitionName( xFilter->getTransition(), xFilter->getSubtype(), xFilter->getDirection() );
if ( pFilter )
{
const OUString aStr( OUString::createFromAscii( pFilter ) );
@@ -1936,11 +1943,11 @@ void AnimationExporter::exportAnimateMotion( SvStream& rStrm, const Reference< X
{
EscherExContainer aAnimateMotion( rStrm, DFF_msofbtAnimateMotion );
{
- { //SJ: Ignored from import filter
- EscherExAtom aAnimateMotionData( rStrm, DFF_msofbtAnimateMotionData );
+ { //SJ: Ignored from import filter
+ EscherExAtom aAnimateMotionData( rStrm, DFF_msofbtAnimateMotionData );
sal_uInt32 nBits = 0x98;
sal_uInt32 nOrigin = 0x2;
- float fByX = 100.0; // nBits&1
+ float fByX = 100.0; // nBits&1
float fByY = 100.0; // nBits&1
float fFromX = 0.0; // nBits&2
float fFromY = 0.0; // nBits&2
@@ -1948,11 +1955,7 @@ void AnimationExporter::exportAnimateMotion( SvStream& rStrm, const Reference< X
float fToY = 100.0; // nBits&4
rStrm << nBits << fByX << fByY << fFromX << fFromY << fToX << fToY << nOrigin;
}
-/* ?
- {
- EscherExAtom aF137( rStrm, 0xf137 );
- }
-*/
+
OUString aStr;
if ( xMotion->getPath() >>= aStr )
{
@@ -2015,7 +2018,7 @@ void AnimationExporter::exportAnimateTransform( SvStream& rStrm, const Reference
// TODO: ZoomContents:
//if( nBits & 8 )
- //( fprintf( mpFile, " zoomContents=\"%s\"", nZoomContents ? "true" : "false" );
+ //( fprintf( mpFile, " zoomContents=\"%s\"", nZoomContents ? "true" : "false" );
rStrm << nBits << fByX << fByY << fFromX << fFromY << fToX << fToY << nZoomContents;
}
@@ -2065,13 +2068,13 @@ sal_Bool AnimationExporter::getColorAny( const Any& rAny, const sal_Int16 nColor
sal_Int32 nColor = 0;
Sequence< double > aHSL( 3 );
- if ( rAny >>= nColor ) // RGB color
+ if ( rAny >>= nColor ) // RGB color
{
rA = (sal_uInt8)( nColor >> 24 );
rB = (sal_uInt8)( nColor >> 8 );
rC = (sal_uInt8)( nColor );
}
- else if ( rAny >>= aHSL ) // HSL
+ else if ( rAny >>= aHSL ) // HSL
{
rA = (sal_Int32) ( aHSL[ 0 ] * 255.0 / 360.0 );
rB = (sal_Int32) ( aHSL[ 1 ] * 255.0 );
@@ -2137,11 +2140,11 @@ void AnimationExporter::exportIterate( SvStream& rStrm, const Reference< XAnimat
{
EscherExAtom aAnimIteration( rStrm, DFF_msofbtAnimIteration );
- float fInterval = 10.0;
- sal_Int32 nTextUnitEffect = 0;
- sal_Int32 nU1 = 1;
- sal_Int32 nU2 = 1;
- sal_Int32 nU3 = 0xe;
+ float fInterval = 10.0;
+ sal_Int32 nTextUnitEffect = 0;
+ sal_Int32 nU1 = 1;
+ sal_Int32 nU2 = 1;
+ sal_Int32 nU3 = 0xe;
sal_Int16 nIterateType = xIterate->getIterateType();
switch( nIterateType )
@@ -2189,3 +2192,4 @@ void AnimationExporter::exportIterate( SvStream& rStrm, const Reference< XAnimat
} // namespace ppt;
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptexanimations.hxx b/sd/source/filter/eppt/pptexanimations.hxx
index 88baf6cb3..8459d2b3d 100644
--- a/sd/source/filter/eppt/pptexanimations.hxx
+++ b/sd/source/filter/eppt/pptexanimations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,8 @@
#include <com/sun/star/animations/XTimeContainer.hpp>
#include <com/sun/star/drawing/XDrawPage.hpp>
#include <com/sun/star/animations/XAnimate.hpp>
-#ifndef _SD_PPTANIMATIONS_HXX
+#include <com/sun/star/beans/NamedValue.hpp>
#include "../ppt/pptanimations.hxx"
-#endif
#include <pptexsoundcollection.hxx>
#include <filter/msfilter/escherex.hxx>
@@ -41,9 +41,7 @@
#include <stdio.h>
#endif
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
#include <list>
@@ -67,11 +65,11 @@ namespace ppt
typedef boost::shared_ptr< AfterEffectNode > AfterEffectNodePtr;
typedef sal_uInt32 TranslateMode;
-#define TRANSLATE_NONE 0
-#define TRANSLATE_VALUE 1
-#define TRANSLATE_ATTRIBUTE 2
-#define TRANSLATE_MEASURE 4
-#define TRANSLATE_NUMBER_TO_STRING 8
+#define TRANSLATE_NONE 0
+#define TRANSLATE_VALUE 1
+#define TRANSLATE_ATTRIBUTE 2
+#define TRANSLATE_MEASURE 4
+#define TRANSLATE_NUMBER_TO_STRING 8
const int AFTEREFFECT_NONE = 0;
const int AFTEREFFECT_COLOR = 1;
@@ -84,7 +82,6 @@ class AnimationExporter
void writeZString( SvStream& rStrm, const rtl::OUString& rVal );
sal_Bool getColorAny( const ::com::sun::star::uno::Any& rAny, const sal_Int16 nColorSpace, sal_Int32& rMode, sal_Int32& rA, sal_Int32& rB, sal_Int32& rC ) const;
sal_Bool exportAnimProperty( SvStream& rStrm, const sal_uInt16 nPropertyId, const ::com::sun::star::uno::Any& rAny, const TranslateMode eTranslateMode );
- ::com::sun::star::uno::Any convertAnimateValue( const ::com::sun::star::uno::Any& rSource, const rtl::OUString& rAttributeName ) const;
void exportAnimPropertyString( SvStream& rStrm, const sal_uInt16 nPropertyId, const rtl::OUString& rVal, const TranslateMode eTranslateMode );
void exportAnimPropertyFloat( SvStream& rStrm, const sal_uInt16 nPropertyId, const double& rVal, const TranslateMode eTranslateMode );
void exportAnimPropertyuInt32( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt32 nVal, const TranslateMode eTranslateMode );
@@ -130,8 +127,21 @@ public:
void doexport( const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage >& xPage, SvStream& rStrm );
sal_Int32 mnCurrentGroup;
-};
+ // helper methods also used in ooxml export
+ static ::com::sun::star::uno::Any convertAnimateValue( const ::com::sun::star::uno::Any& rSource, const rtl::OUString& rAttributeName );
+ static sal_Bool GetNodeType( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode, sal_Int16& nType );
+ static sal_Int16 GetFillMode( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode, const sal_Int16 nFillDefault );
+ static void GetUserData( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue >& rUserData, const ::com::sun::star::uno::Any ** pAny, sal_Size nLen );
+ static sal_uInt32 TranslatePresetSubType( const sal_uInt32 nPresetClass, const sal_uInt32 nPresetId, const rtl::OUString& rPresetSubType );
+ static sal_uInt32 GetPresetID( const rtl::OUString& rPreset, sal_uInt32 nAPIPresetClass, sal_Bool& bPresetId );
+ static sal_uInt32 GetValueTypeForAttributeName( const rtl::OUString& rAttributeName );
+
+ static const sal_Char* FindTransitionName( const sal_Int16 nType, const sal_Int16 nSubType, const sal_Bool bDirection );
+ static ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > getTargetElementShape( const ::com::sun::star::uno::Any& rAny, sal_Int32& rBegin, sal_Int32& rEnd, sal_Bool& rParagraphTarget );
+};
} // namespace ppt
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptexsoundcollection.cxx b/sd/source/filter/eppt/pptexsoundcollection.cxx
index a1102c968..80bb64216 100644
--- a/sd/source/filter/eppt/pptexsoundcollection.cxx
+++ b/sd/source/filter/eppt/pptexsoundcollection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,15 +31,9 @@
#include <pptexsoundcollection.hxx>
#include "epptdef.hxx"
#include <tools/urlobj.hxx>
-#ifndef _UCBHELPER_CONTENT_HXX_
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENTBROKER_HXX_
#include <ucbhelper/contentbroker.hxx>
-#endif
-#ifndef _CPPUHELPER_PROPTYPEHLP_HXX_
#include <cppuhelper/proptypehlp.hxx>
-#endif
#include <unotools/ucbstreamhelper.hxx>
namespace ppt
@@ -101,7 +96,7 @@ sal_uInt32 ExSoundEntry::GetSize( sal_uInt32 nId ) const
return nSize;
}
-void ExSoundEntry::Write( SvStream& rSt, sal_uInt32 nId )
+void ExSoundEntry::Write( SvStream& rSt, sal_uInt32 nId ) const
{
try
{
@@ -159,27 +154,25 @@ void ExSoundEntry::Write( SvStream& rSt, sal_uInt32 nId )
}
}
-ExSoundCollection::~ExSoundCollection()
-{
- for( void* pPtr = List::First(); pPtr; pPtr = List::Next() )
- delete (ExSoundEntry*)pPtr;
-}
-
sal_uInt32 ExSoundCollection::GetId( const String& rString )
{
sal_uInt32 nSoundId = 0;
if( rString.Len() )
{
- const sal_uInt32 nSoundCount = Count();
+ const sal_uInt32 nSoundCount = maEntries.size();
+ boost::ptr_vector<ExSoundEntry>::const_iterator iter;
- for( ; nSoundId < nSoundCount; nSoundId++ )
- if( ImplGetByIndex( nSoundId )->IsSameURL( rString ) )
+ for (iter = maEntries.begin(); iter != maEntries.end(); ++iter, ++nSoundId)
+ {
+ if (iter->IsSameURL(rString))
break;
+ }
+
if ( nSoundId++ == nSoundCount )
{
ExSoundEntry* pEntry = new ExSoundEntry( rString );
if ( pEntry->GetFileSize() )
- List::Insert( pEntry, LIST_APPEND );
+ maEntries.push_back(pEntry);
else
{
nSoundId = 0; // only insert sounds that are accessible
@@ -190,40 +183,40 @@ sal_uInt32 ExSoundCollection::GetId( const String& rString )
return nSoundId;
}
-const ExSoundEntry* ExSoundCollection::ImplGetByIndex( sal_uInt32 nIndex ) const
-{
- return (ExSoundEntry*)List::GetObject( nIndex );
-}
-
sal_uInt32 ExSoundCollection::GetSize() const
{
sal_uInt32 nSize = 0;
- sal_uInt32 i, nSoundCount = Count();
- if ( nSoundCount )
+ if (!maEntries.empty())
{
nSize += 8 + 12; // size of SoundCollectionContainerHeader + SoundCollAtom
- for ( i = 0; i < nSoundCount; i++ )
- nSize += ImplGetByIndex( i )->GetSize( i + 1 );
+ boost::ptr_vector<ExSoundEntry>::const_iterator iter;
+ sal_uInt32 i = 1;
+ for ( iter = maEntries.begin(); iter != maEntries.end(); ++iter, ++i)
+ nSize += iter->GetSize(i);
}
return nSize;
}
-void ExSoundCollection::Write( SvStream& rSt )
+void ExSoundCollection::Write( SvStream& rSt ) const
{
- sal_uInt32 i, nSoundCount = Count();
- if ( nSoundCount )
+ if (!maEntries.empty())
{
+ sal_uInt32 i = 1;
+ sal_uInt32 nSoundCount = maEntries.size();
+
// create SoundCollection Container
rSt << (sal_uInt16)0xf << (sal_uInt16)EPP_SoundCollection << (sal_uInt32)( GetSize() - 8 );
// create SoundCollAtom ( reference to the next free SoundId );
rSt << (sal_uInt32)( EPP_SoundCollAtom << 16 ) << (sal_uInt32)4 << nSoundCount;
- for ( i = 0; i < nSoundCount; i++ )
- ((ExSoundEntry*)List::GetObject( i ))->Write( rSt, i + 1 );
+ boost::ptr_vector<ExSoundEntry>::const_iterator iter;
+ for ( iter = maEntries.begin(); iter != maEntries.end(); ++iter, ++i)
+ iter->Write(rSt,i);
}
}
} // namespace ppt;
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptexsoundcollection.hxx b/sd/source/filter/eppt/pptexsoundcollection.hxx
index 6e7061576..cf0a37e5f 100644
--- a/sd/source/filter/eppt/pptexsoundcollection.hxx
+++ b/sd/source/filter/eppt/pptexsoundcollection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,13 @@
#ifndef _SD_PPT_EXSOUNDCOLLECTION_HXX
#define _SD_PPT_EXSOUNDCOLLECTION_HXX
+#include <boost/ptr_container/ptr_vector.hpp>
+
#ifdef DBG_ANIM_LOG
#include <stdio.h>
#endif
#include <tools/string.hxx>
#include <tools/stream.hxx>
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
-#include <boost/shared_ptr.hpp>
-#endif
-
-#include <list>
namespace ppt
{
@@ -59,25 +57,26 @@ class ExSoundEntry
// returns the size of a complete SoundContainer
sal_uInt32 GetSize( sal_uInt32 nId ) const;
- void Write( SvStream& rSt, sal_uInt32 nId );
+ void Write( SvStream& rSt, sal_uInt32 nId ) const;
};
-class ExSoundCollection : private List
+class ExSoundCollection
{
- const ExSoundEntry* ImplGetByIndex( sal_uInt32 nId ) const;
-
public:
- ExSoundCollection() {}
- ~ExSoundCollection();
-
sal_uInt32 GetId( const String& );
// returns the size of a complete SoundCollectionContainer
sal_uInt32 GetSize() const;
- void Write( SvStream& rSt );
+ void Write( SvStream& rSt ) const;
+
+private:
+
+ boost::ptr_vector<ExSoundEntry> maEntries;
};
} // namespace ppt
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptx-epptbase.cxx b/sd/source/filter/eppt/pptx-epptbase.cxx
new file mode 100644
index 000000000..25adbbfeb
--- /dev/null
+++ b/sd/source/filter/eppt/pptx-epptbase.cxx
@@ -0,0 +1,1022 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+// MARKER(update_precomp.py): autogen include statement, do not remove
+#include "precompiled_sd.hxx"
+
+#include "eppt.hxx"
+#include "epptdef.hxx"
+
+#include <comphelper/extract.hxx>
+#include <tools/globname.hxx>
+#include <tools/datetime.hxx>
+#include <tools/poly.hxx>
+#include <tools/stream.hxx>
+#include <tools/zcodec.hxx>
+#include <vcl/graph.hxx>
+#include <vcl/bmpacc.hxx>
+#include <vcl/gradient.hxx>
+#include <vcl/virdev.hxx>
+#include <rtl/ustring.hxx>
+#include <svtools/fltcall.hxx>
+#include <svtools/wmf.hxx>
+#include <sfx2/docfile.hxx>
+#include <sfx2/docinf.hxx>
+#include <svx/unoapi.hxx>
+#include <svx/svdobj.hxx>
+#include <svx/svdoole2.hxx>
+#include <svx/svdmodel.hxx>
+#include <svx/svdpage.hxx>
+#include <com/sun/star/view/PaperOrientation.hpp>
+#include <com/sun/star/view/PaperFormat.hpp>
+#include <com/sun/star/document/XDocumentPropertiesSupplier.hpp>
+#include <com/sun/star/office/XAnnotation.hpp>
+#include <com/sun/star/office/XAnnotationAccess.hpp>
+#include <com/sun/star/office/XAnnotationEnumeration.hpp>
+#include <com/sun/star/geometry/RealPoint2D.hpp>
+#include <com/sun/star/util/DateTime.hpp>
+#include <com/sun/star/animations/TransitionType.hpp>
+#include <com/sun/star/animations/TransitionSubType.hpp>
+#include <com/sun/star/awt/FontDescriptor.hpp>
+#include <com/sun/star/awt/FontFamily.hpp>
+#include <com/sun/star/awt/FontPitch.hpp>
+#include <com/sun/star/container/XNamed.hpp>
+#include <com/sun/star/container/XNameAccess.hpp>
+#include <com/sun/star/presentation/XPresentationPage.hpp>
+#include <com/sun/star/text/XSimpleText.hpp>
+#include <com/sun/star/style/XStyle.hpp>
+#include <com/sun/star/style/XStyleFamiliesSupplier.hpp>
+#include <editeng/svxenum.hxx>
+#include <editeng/flditem.hxx>
+#include <sot/storinfo.hxx>
+#include <filter/msfilter/msoleexp.hxx>
+#include <filter/msfilter/msdffimp.hxx>
+#include <filter/msfilter/svxmsbas.hxx>
+
+#ifdef DEBUG
+#define DBG(x) x
+#include <stdio.h>
+#else
+#define DBG(x)
+#endif
+
+using namespace com::sun::star;
+
+using namespace ::com::sun::star::animations;
+using namespace ::com::sun::star::awt::FontFamily;
+using namespace ::com::sun::star::awt::FontPitch;
+using namespace ::com::sun::star::presentation;
+
+using ::com::sun::star::awt::FontDescriptor;
+using ::com::sun::star::beans::XPropertySet;
+using ::com::sun::star::container::XNameAccess;
+using ::com::sun::star::container::XNamed;
+using ::com::sun::star::drawing::XDrawPagesSupplier;
+using ::com::sun::star::drawing::XMasterPagesSupplier;
+using ::com::sun::star::drawing::XShapes;
+using ::com::sun::star::drawing::XMasterPageTarget;
+using ::com::sun::star::drawing::XDrawPage;
+using ::com::sun::star::frame::XModel;
+using ::com::sun::star::style::XStyleFamiliesSupplier;
+using ::com::sun::star::style::XStyle;
+using ::com::sun::star::task::XStatusIndicator;
+using ::com::sun::star::text::XSimpleText;
+using ::com::sun::star::uno::Any;
+using ::com::sun::star::uno::Exception;
+using ::com::sun::star::uno::Reference;
+using ::com::sun::star::uno::UNO_QUERY;
+
+static PHLayout pPHLayout[] =
+{
+ { EPP_LAYOUT_TITLESLIDE, { 0x0d, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x10, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_True, sal_True },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_BLANCSLIDE, { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_False, sal_False, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x14, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x15, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x15, 0x0d, 0x0e, sal_True, sal_False, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x16, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x0e, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_False, sal_False },
+ { EPP_LAYOUT_RIGHTCOLUMN2ROWS, { 0x0d, 0x0e, 0x13, 0x13, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2ROWSANDTITLE, { 0x0d, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_LEFTCOLUMN2ROWS, { 0x0d, 0x13, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TOPROW2COLUMN, { 0x0d, 0x13, 0x13, 0x0e, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2ROWSANDTITLE, { 0x0d, 0x0e, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_4OBJECTS, { 0x0d, 0x13, 0x13, 0x13, 0x13, 0x00, 0x00, 0x00 }, 0x13, 0x0d, 0x0e, sal_True, sal_False, sal_False },
+ { EPP_LAYOUT_ONLYTITLE, { 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_True, sal_False, sal_False },
+ { EPP_LAYOUT_BLANCSLIDE, { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x0e, sal_False, sal_False, sal_False },
+ { EPP_LAYOUT_TITLERIGHT2BODIESLEFT, { 0x11, 0x12, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x14, 0x11, 0x12, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLERIGHTBODYLEFT, { 0x11, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x11, 0x12, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_TITLEANDBODYSLIDE, { 0x0d, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x00, 0x0d, 0x12, sal_True, sal_True, sal_False },
+ { EPP_LAYOUT_2COLUMNSANDTITLE, { 0x0d, 0x16, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00 }, 0x16, 0x0d, 0x12, sal_True, sal_True, sal_False }
+};
+
+#define PPT_WRITER_BASE_INIT_VALUES \
+ maFraction ( 1, 576 ), \
+ maMapModeSrc ( MAP_100TH_MM ), \
+ maMapModeDest ( MAP_INCH, Point(), maFraction, maFraction ), \
+ meLatestPageType ( NORMAL )
+
+PPTWriterBase::PPTWriterBase() :
+ PPT_WRITER_BASE_INIT_VALUES
+{
+ DBG(printf ("PPTWriterBase::PPTWriterBase()\n"));
+}
+
+PPTWriterBase::PPTWriterBase( const Reference< XModel > & rXModel,
+ const Reference< XStatusIndicator > & rXStatInd ) :
+ mXModel ( rXModel ),
+ mXStatusIndicator ( rXStatInd ),
+ mbStatusIndicator ( false ),
+ PPT_WRITER_BASE_INIT_VALUES
+{
+}
+
+// ---------------------------------------------------------------------------------------------
+
+PPTWriterBase::~PPTWriterBase()
+{
+ // Possibly unnecessary sanity check for mXStatusIndicator.is().
+ // In 3.3 we had a bug report of a crash where it was null,
+ // https://bugzilla.novell.com/show_bug.cgi?id=694119 (non-public,
+ // bug report, sorry).
+ if ( mbStatusIndicator && mXStatusIndicator.is() )
+ mXStatusIndicator->end();
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void PPTWriterBase::exportPPT()
+{
+ if ( !InitSOIface() )
+ return;
+
+ FontCollectionEntry aDefaultFontDesc( String( RTL_CONSTASCII_USTRINGPARAM( "Times New Roman" ) ),
+ ROMAN,
+ awt::FontPitch::VARIABLE,
+ RTL_TEXTENCODING_MS_1252 );
+ maFontCollection.GetId( aDefaultFontDesc ); // default is always times new roman
+
+ if ( !GetPageByIndex( 0, NOTICE ) )
+ return;
+
+ sal_Int32 nWidth = 21000;
+ if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Width" ) ) ) )
+ mAny >>= nWidth;
+ sal_Int32 nHeight = 29700;
+ if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Height" ) ) ) )
+ mAny >>= nHeight;
+
+ maNotesPageSize = MapSize( awt::Size( nWidth, nHeight ) );
+
+ if ( !GetPageByIndex( 0, MASTER ) )
+ return;
+
+ nWidth = 28000;
+ if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Width" ) ) ) )
+ mAny >>= nWidth;
+ nHeight = 21000;
+ if ( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Height" ) ) ) )
+ mAny >>= nHeight;
+ maDestPageSize = MapSize( awt::Size( nWidth, nHeight ) );
+
+ DBG(printf( "call exportDocumentPre()\n"));
+ exportPPTPre();
+
+ if ( !GetStyleSheets() )
+ return;
+
+ if ( !ImplCreateDocument() )
+ return;
+
+ sal_uInt32 i;
+
+ for ( i = 0; i < mnPages; i++ )
+ {
+ if ( GetPageByIndex( i, NORMAL ) ) {
+ sal_uInt32 nMasterNum = GetMasterIndex( NORMAL );
+ ImplWriteLayout( GetLayoutOffset( mXPagePropSet ), nMasterNum );
+ }
+ }
+
+ for ( i = 0; i < mnMasterPages; i++ )
+ {
+ if ( !CreateSlideMaster( i ) )
+ return;
+ }
+ if ( !CreateMainNotes() )
+ return;
+
+ for ( i = 0; i < mnPages; i++ )
+ {
+ DBG(printf( "call ImplCreateSlide( %"SAL_PRIuUINT32" )\n", i));
+ if ( !CreateSlide( i ) )
+ return;
+ }
+
+ for ( i = 0; i < mnPages; i++ )
+ {
+ if ( !CreateNotes( i ) )
+ return;
+ }
+
+ DBG(printf( "call exportDocumentPost()\n"));
+ exportPPTPost();
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::InitSOIface()
+{
+ while( sal_True )
+ {
+ mXDrawPagesSupplier = Reference< XDrawPagesSupplier >( mXModel, UNO_QUERY );
+ if ( !mXDrawPagesSupplier.is() )
+ break;
+
+ mXMasterPagesSupplier = Reference< XMasterPagesSupplier >( mXModel, UNO_QUERY );
+ if ( !mXMasterPagesSupplier.is() )
+ break;
+ mXDrawPages = mXMasterPagesSupplier->getMasterPages();
+ if ( !mXDrawPages.is() )
+ break;
+ mnMasterPages = mXDrawPages->getCount();
+ mXDrawPages = mXDrawPagesSupplier->getDrawPages();
+ if( !mXDrawPages.is() )
+ break;
+ mnPages = mXDrawPages->getCount();
+ if ( !GetPageByIndex( 0, NORMAL ) )
+ break;
+
+ return sal_True;
+ }
+ return sal_False;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::GetPageByIndex( sal_uInt32 nIndex, PageType ePageType )
+{
+ while( sal_True )
+ {
+ if ( ePageType != meLatestPageType )
+ {
+ switch( ePageType )
+ {
+ case NORMAL :
+ case NOTICE :
+ {
+ mXDrawPages = mXDrawPagesSupplier->getDrawPages();
+ if( !mXDrawPages.is() )
+ return sal_False;
+ }
+ break;
+
+ case MASTER :
+ {
+ mXDrawPages = mXMasterPagesSupplier->getMasterPages();
+ if( !mXDrawPages.is() )
+ return sal_False;
+ }
+ break;
+ default:
+ break;
+ }
+ meLatestPageType = ePageType;
+ }
+ Any aAny( mXDrawPages->getByIndex( nIndex ) );
+ aAny >>= mXDrawPage;
+ if ( !mXDrawPage.is() )
+ break;
+ if ( ePageType == NOTICE )
+ {
+ Reference< XPresentationPage > aXPresentationPage( mXDrawPage, UNO_QUERY );
+ if ( !aXPresentationPage.is() )
+ break;
+ mXDrawPage = aXPresentationPage->getNotesPage();
+ if ( !mXDrawPage.is() )
+ break;
+ }
+ mXPagePropSet = Reference< XPropertySet >( mXDrawPage, UNO_QUERY );
+ if ( !mXPagePropSet.is() )
+ break;
+
+ mXShapes = Reference< XShapes >( mXDrawPage, UNO_QUERY );
+ if ( !mXShapes.is() )
+ break;
+
+ /* try to get the "real" background PropertySet. If the normal page is not supporting this property, it is
+ taken the property from the master */
+ sal_Bool bHasBackground = GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ), sal_True );
+ if ( bHasBackground )
+ bHasBackground = ( aAny >>= mXBackgroundPropSet );
+ if ( !bHasBackground )
+ {
+ Reference< XMasterPageTarget > aXMasterPageTarget( mXDrawPage, UNO_QUERY );
+ if ( aXMasterPageTarget.is() )
+ {
+ Reference< XDrawPage > aXMasterDrawPage;
+ aXMasterDrawPage = aXMasterPageTarget->getMasterPage();
+ if ( aXMasterDrawPage.is() )
+ {
+ Reference< XPropertySet > aXMasterPagePropSet;
+ aXMasterPagePropSet = Reference< XPropertySet >
+ ( aXMasterDrawPage, UNO_QUERY );
+ if ( aXMasterPagePropSet.is() )
+ {
+ sal_Bool bBackground = GetPropertyValue( aAny, aXMasterPagePropSet,
+ String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) );
+ if ( bBackground )
+ {
+ aAny >>= mXBackgroundPropSet;
+ }
+ }
+ }
+ }
+ }
+ return sal_True;
+ }
+ return sal_False;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::CreateSlide( sal_uInt32 nPageNum )
+{
+ Any aAny;
+
+ if ( !GetPageByIndex( nPageNum, NORMAL ) )
+ return sal_False;
+
+ sal_uInt32 nMasterNum = GetMasterIndex( NORMAL );
+ SetCurrentStyleSheet( nMasterNum );
+
+ Reference< XPropertySet > aXBackgroundPropSet;
+ sal_Bool bHasBackground = GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) );
+ if ( bHasBackground )
+ bHasBackground = ( aAny >>= aXBackgroundPropSet );
+
+ sal_uInt16 nMode = 7; // Bit 1: Follow master objects, Bit 2: Follow master scheme, Bit 3: Follow master background
+ if ( bHasBackground )
+ nMode &=~4;
+
+/* sj: Don't know what's IsBackgroundVisible for, have to ask cl
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundVisible" ) ) ) )
+ {
+ sal_Bool bBackgroundVisible;
+ if ( aAny >>= bBackgroundVisible )
+ {
+ if ( bBackgroundVisible )
+ nMode &= ~4;
+ }
+ }
+*/
+ if ( GetPropertyValue( aAny, mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundObjectsVisible" ) ) ) )
+ {
+ sal_Bool bBackgroundObjectsVisible = sal_False;
+ if ( aAny >>= bBackgroundObjectsVisible )
+ {
+ if ( !bBackgroundObjectsVisible )
+ nMode &= ~1;
+ }
+ }
+
+ ImplWriteSlide( nPageNum, nMasterNum, nMode, bHasBackground, aXBackgroundPropSet );
+
+ return sal_True;
+};
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::CreateNotes( sal_uInt32 nPageNum )
+{
+ if ( !GetPageByIndex( nPageNum, NOTICE ) )
+ return sal_False;
+ SetCurrentStyleSheet( GetMasterIndex( NORMAL ) );
+
+ ImplWriteNotes( nPageNum );
+
+ return sal_True;
+};
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::CreateSlideMaster( sal_uInt32 nPageNum )
+{
+ if ( !GetPageByIndex( nPageNum, MASTER ) )
+ return sal_False;
+ SetCurrentStyleSheet( nPageNum );
+
+ if ( !ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) ) ) // Backgroundshape laden
+ return sal_False;
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > aXBackgroundPropSet;
+ if ( !( mAny >>= aXBackgroundPropSet ) )
+ return sal_False;
+
+ ImplWriteSlideMaster( nPageNum, aXBackgroundPropSet );
+
+ return sal_True;
+};
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Int32 PPTWriterBase::GetLayoutOffset( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const
+{
+ ::com::sun::star::uno::Any aAny;
+ sal_Int32 nLayout = 20;
+ if ( GetPropertyValue( aAny, rXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Layout" ) ) ), sal_True )
+ aAny >>= nLayout;
+
+ DBG(printf("GetLayoutOffset %"SAL_PRIdINT32"\n", nLayout));
+
+ return nLayout;
+}
+
+sal_Int32 PPTWriterBase::GetLayoutOffsetFixed( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const
+{
+ sal_Int32 nLayout = GetLayoutOffset( rXPropSet );
+
+ if ( ( nLayout >= 21 ) && ( nLayout <= 26 ) ) // NOTES _> HANDOUT6
+ nLayout = 20;
+ if ( ( nLayout >= 27 ) && ( nLayout <= 30 ) ) // VERTICAL LAYOUT
+ nLayout -= 6;
+ else if ( nLayout > 30 )
+ nLayout = 20;
+
+ return nLayout;
+}
+
+PHLayout& PPTWriterBase::GetLayout( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& rXPropSet ) const
+{
+ return pPHLayout[ GetLayoutOffsetFixed( rXPropSet ) ];
+}
+
+// ---------------------------------------------------------------------------------------------
+
+PHLayout& PPTWriterBase::GetLayout( sal_Int32 nOffset ) const
+{
+ if( nOffset >= 0 && nOffset < EPP_LAYOUT_SIZE )
+ return pPHLayout[ nOffset ];
+
+ DBG(printf("asked %"SAL_PRIdINT32" for layout outside of 0,%d array scope\n", nOffset, EPP_LAYOUT_SIZE ));
+
+ return pPHLayout[ 0 ];
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_uInt32 PPTWriterBase::GetMasterIndex( PageType ePageType )
+{
+ sal_uInt32 nRetValue = 0;
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPageTarget >
+ aXMasterPageTarget( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
+
+ if ( aXMasterPageTarget.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage >
+ aXDrawPage = aXMasterPageTarget->getMasterPage();
+ if ( aXDrawPage.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
+ aXPropertySet( aXDrawPage, ::com::sun::star::uno::UNO_QUERY );
+
+ if ( aXPropertySet.is() )
+ {
+ if ( ImplGetPropertyValue( aXPropertySet, String( RTL_CONSTASCII_USTRINGPARAM( "Number" ) ) ) )
+ nRetValue |= *(sal_Int16*)mAny.getValue();
+ if ( nRetValue & 0xffff ) // ueberlauf vermeiden
+ nRetValue--;
+ }
+ }
+ }
+ if ( ePageType == NOTICE )
+ nRetValue += mnMasterPages;
+ return nRetValue;
+}
+
+// -----------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::SetCurrentStyleSheet( sal_uInt32 nPageNum )
+{
+ sal_Bool bRet = sal_False;
+ if ( nPageNum >= maStyleSheetList.size() )
+ nPageNum = 0;
+ else
+ bRet = sal_True;
+ mpStyleSheet = maStyleSheetList[ nPageNum ];
+ return bRet;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::GetStyleSheets()
+{
+ int nInstance, nLevel;
+ sal_Bool bRetValue = sal_False;
+ sal_uInt32 nPageNum;
+
+ for ( nPageNum = 0; nPageNum < mnMasterPages; nPageNum++ )
+ {
+ Reference< XNamed >
+ aXNamed;
+
+ Reference< XNameAccess >
+ aXNameAccess;
+
+ Reference< XStyleFamiliesSupplier >
+ aXStyleFamiliesSupplier( mXModel, UNO_QUERY );
+
+ Reference< XPropertySet >
+ aXPropSet( mXModel, UNO_QUERY );
+
+ sal_uInt16 nDefaultTab = ( aXPropSet.is() && ImplGetPropertyValue( aXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TabStop" ) ) ) )
+ ? (sal_uInt16)( *(sal_Int32*)mAny.getValue() / 4.40972 )
+ : 1250;
+
+ maStyleSheetList.push_back( new PPTExStyleSheet( nDefaultTab, (PPTExBulletProvider&)*this ) );
+ SetCurrentStyleSheet( nPageNum );
+ if ( GetPageByIndex( nPageNum, MASTER ) )
+ aXNamed = Reference< XNamed >
+ ( mXDrawPage, UNO_QUERY );
+
+ if ( aXStyleFamiliesSupplier.is() )
+ aXNameAccess = aXStyleFamiliesSupplier->getStyleFamilies();
+
+ bRetValue = aXNamed.is() && aXNameAccess.is() && aXStyleFamiliesSupplier.is();
+ if ( bRetValue )
+ {
+ for ( nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_CenterTitle; nInstance++ )
+ {
+ String aStyle;
+ String aFamily;
+ switch ( nInstance )
+ {
+ case EPP_TEXTTYPE_CenterTitle :
+ case EPP_TEXTTYPE_Title :
+ {
+ aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "title" ) );
+ aFamily = aXNamed->getName();
+ }
+ break;
+ case EPP_TEXTTYPE_Body :
+ {
+ aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "outline1" ) ); // SD_LT_SEPARATOR
+ aFamily = aXNamed->getName();
+ }
+ break;
+ case EPP_TEXTTYPE_Other :
+ {
+ aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "standard" ) );
+ aFamily = String( RTL_CONSTASCII_USTRINGPARAM( "graphics" ) );
+ }
+ break;
+ case EPP_TEXTTYPE_CenterBody :
+ {
+ aStyle = String( RTL_CONSTASCII_USTRINGPARAM( "subtitle" ) );
+ aFamily = aXNamed->getName();
+ }
+ break;
+ }
+ if ( aStyle.Len() && aFamily.Len() )
+ {
+ try
+ {
+ Reference< XNameAccess >xNameAccess;
+ if ( aXNameAccess->hasByName( aFamily ) )
+ {
+ Any aAny( aXNameAccess->getByName( aFamily ) );
+ if( aAny.getValue() && ::cppu::extractInterface( xNameAccess, aAny ) )
+ {
+ Reference< XNameAccess > aXFamily;
+ if ( aAny >>= aXFamily )
+ {
+ if ( aXFamily->hasByName( aStyle ) )
+ {
+ Reference< XStyle > xStyle;
+ aAny = aXFamily->getByName( aStyle );
+ if( aAny.getValue() && ::cppu::extractInterface( xStyle, aAny ) )
+ {
+ Reference< XStyle > aXStyle;
+ aAny >>= aXStyle;
+ Reference< XPropertySet >
+ xPropSet( aXStyle, UNO_QUERY );
+ if( xPropSet.is() )
+ mpStyleSheet->SetStyleSheet( xPropSet, maFontCollection, nInstance, 0 );
+ for ( nLevel = 1; nLevel < 5; nLevel++ )
+ {
+ if ( nInstance == EPP_TEXTTYPE_Body )
+ {
+ sal_Unicode cTemp = aStyle.GetChar( aStyle.Len() - 1 );
+ aStyle.SetChar( aStyle.Len() - 1, ++cTemp );
+ if ( aXFamily->hasByName( aStyle ) )
+ {
+ aXFamily->getByName( aStyle ) >>= xStyle;
+ if( xStyle.is() )
+ {
+ Reference< XPropertySet >
+ xPropertySet( xStyle, UNO_QUERY );
+ if ( xPropertySet.is() )
+ mpStyleSheet->SetStyleSheet( xPropertySet, maFontCollection, nInstance, nLevel );
+ }
+ }
+ }
+ else
+ mpStyleSheet->SetStyleSheet( xPropSet, maFontCollection, nInstance, nLevel );
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ catch( Exception& )
+ {
+ //
+ }
+ }
+ }
+ for ( ; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
+ {
+
+ }
+ }
+ }
+ return bRetValue;
+}
+
+// -----------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::CreateMainNotes()
+{
+ if ( !GetPageByIndex( 0, NOTICE ) )
+ return sal_False;
+ SetCurrentStyleSheet( 0 );
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XMasterPageTarget >
+ aXMasterPageTarget( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
+
+ if ( !aXMasterPageTarget.is() )
+ return sal_False;
+
+ mXDrawPage = aXMasterPageTarget->getMasterPage();
+ if ( !mXDrawPage.is() )
+ return sal_False;
+
+ mXPropSet = ::com::sun::star::uno::Reference<
+ ::com::sun::star::beans::XPropertySet >
+ ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
+ if ( !mXPropSet.is() )
+ return sal_False;
+
+ mXShapes = ::com::sun::star::uno::Reference<
+ ::com::sun::star::drawing::XShapes >
+ ( mXDrawPage, ::com::sun::star::uno::UNO_QUERY );
+ if ( !mXShapes.is() )
+ return sal_False;
+
+ return ImplCreateMainNotes();
+}
+
+// -----------------------------------------------------------------------
+
+awt::Size PPTWriterBase::MapSize( const awt::Size& rSize )
+{
+ Size aRetSize( OutputDevice::LogicToLogic( Size( rSize.Width, rSize.Height ), maMapModeSrc, maMapModeDest ) );
+
+ if ( !aRetSize.Width() )
+ aRetSize.Width()++;
+ if ( !aRetSize.Height() )
+ aRetSize.Height()++;
+ return awt::Size( aRetSize.Width(), aRetSize.Height() );
+}
+
+// -----------------------------------------------------------------------
+
+awt::Point PPTWriterBase::MapPoint( const awt::Point& rPoint )
+{
+ Point aRet( OutputDevice::LogicToLogic( Point( rPoint.X, rPoint.Y ), maMapModeSrc, maMapModeDest ) );
+ return awt::Point( aRet.X(), aRet.Y() );
+}
+
+// -----------------------------------------------------------------------
+
+Rectangle PPTWriterBase::MapRectangle( const awt::Rectangle& rRect )
+{
+ ::com::sun::star::awt::Point aPoint( rRect.X, rRect.Y );
+ ::com::sun::star::awt::Size aSize( rRect.Width, rRect.Height );
+ ::com::sun::star::awt::Point aP( MapPoint( aPoint ) );
+ ::com::sun::star::awt::Size aS( MapSize( aSize ) );
+ return Rectangle( Point( aP.X, aP.Y ), Size( aS.Width, aS.Height ) );
+}
+
+// -----------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::GetShapeByIndex( sal_uInt32 nIndex, sal_Bool bGroup )
+{
+ while(sal_True)
+ {
+ if ( ( bGroup == sal_False ) || ( GetCurrentGroupLevel() == 0 ) )
+ {
+ Any aAny( mXShapes->getByIndex( nIndex ) );
+ aAny >>= mXShape;
+ }
+ else
+ {
+ Any aAny( GetCurrentGroupAccess()->getByIndex( GetCurrentGroupIndex() ) );
+ aAny >>= mXShape;
+ }
+ if ( !mXShape.is() )
+ break;
+
+ Any aAny( mXShape->queryInterface( ::getCppuType( (const Reference< XPropertySet >*) 0 ) ));
+ aAny >>= mXPropSet;
+
+ if ( !mXPropSet.is() )
+ break;
+ maPosition = MapPoint( mXShape->getPosition() );
+ maSize = MapSize( mXShape->getSize() );
+ maRect = Rectangle( Point( maPosition.X, maPosition.Y ), Size( maSize.Width, maSize.Height ) );
+ mType = ByteString( String( mXShape->getShapeType() ), RTL_TEXTENCODING_UTF8 );
+ mType.Erase( 0, 13 ); // "com.sun.star." entfernen
+ sal_uInt16 nPos = mType.Search( (const char*)"Shape" );
+ mType.Erase( nPos, 5 );
+
+ mbPresObj = mbEmptyPresObj = sal_False;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsPresentationObject" ) ) ) )
+ mAny >>= mbPresObj;
+
+ if ( mbPresObj && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsEmptyPresentationObject" ) ) ) )
+ mAny >>= mbEmptyPresObj;
+
+ mnAngle = ( PropValue::GetPropertyValue( aAny,
+ mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "RotateAngle" ) ), sal_True ) )
+ ? *((sal_Int32*)aAny.getValue() )
+ : 0;
+
+ return sal_True;
+ }
+ return sal_False;
+}
+
+// -----------------------------------------------------------------------
+
+sal_Int8 PPTWriterBase::GetTransition( sal_Int16 nTransitionType, sal_Int16 nTransitionSubtype, FadeEffect eEffect, sal_uInt8& nDirection )
+{
+ sal_Int8 nPPTTransitionType = 0;
+ nDirection = 0;
+
+ switch( nTransitionType )
+ {
+ case TransitionType::FADE :
+ {
+ if ( nTransitionSubtype == TransitionSubType::CROSSFADE )
+ nPPTTransitionType = PPT_TRANSITION_TYPE_SMOOTHFADE;
+ else if ( nTransitionSubtype == TransitionSubType::FADEOVERCOLOR )
+ nPPTTransitionType = PPT_TRANSITION_TYPE_FADE;
+ }
+ break;
+ case PPT_TRANSITION_TYPE_COMB :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_COMB;
+ if ( nTransitionSubtype == TransitionSubType::COMBVERTICAL )
+ nDirection++;
+ }
+ break;
+ case TransitionType::PUSHWIPE :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_PUSH;
+ switch( nTransitionSubtype )
+ {
+ case TransitionSubType::FROMRIGHT: nDirection = 0; break;
+ case TransitionSubType::FROMBOTTOM: nDirection = 1; break;
+ case TransitionSubType::FROMLEFT: nDirection = 2; break;
+ case TransitionSubType::FROMTOP: nDirection = 3; break;
+ }
+ }
+ break;
+ case TransitionType::PINWHEELWIPE :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_WHEEL;
+ switch( nTransitionSubtype )
+ {
+ case TransitionSubType::ONEBLADE: nDirection = 1; break;
+ case TransitionSubType::TWOBLADEVERTICAL : nDirection = 2; break;
+ case TransitionSubType::THREEBLADE : nDirection = 3; break;
+ case TransitionSubType::FOURBLADE: nDirection = 4; break;
+ case TransitionSubType::EIGHTBLADE: nDirection = 8; break;
+ }
+ }
+ break;
+ case TransitionType::FANWIPE :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_WEDGE;
+ }
+ break;
+ case TransitionType::ELLIPSEWIPE :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_CIRCLE;
+ }
+ break;
+ case TransitionType::FOURBOXWIPE :
+ {
+ nPPTTransitionType = PPT_TRANSITION_TYPE_PLUS;
+ }
+ break;
+ case TransitionType::IRISWIPE :
+ {
+ switch( nTransitionSubtype ) {
+ case TransitionSubType::RECTANGLE:
+ nPPTTransitionType = PPT_TRANSITION_TYPE_ZOOM;
+ nDirection = (eEffect == FadeEffect_FADE_FROM_CENTER) ? 0 : 1;
+ break;
+ default:
+ nPPTTransitionType = PPT_TRANSITION_TYPE_DIAMOND;
+ break;
+ }
+ }
+ break;
+ }
+
+ return nPPTTransitionType;
+}
+
+sal_Int8 PPTWriterBase::GetTransition( FadeEffect eEffect, sal_uInt8& nDirection )
+{
+ sal_Int8 nPPTTransitionType = 0;
+
+ switch ( eEffect )
+ {
+ default :
+ case FadeEffect_RANDOM :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_RANDOM;
+ break;
+
+ case FadeEffect_HORIZONTAL_STRIPES :
+ nDirection++;
+ case FadeEffect_VERTICAL_STRIPES :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_BLINDS;
+ break;
+
+ case FadeEffect_VERTICAL_CHECKERBOARD :
+ nDirection++;
+ case FadeEffect_HORIZONTAL_CHECKERBOARD :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_CHECKER;
+ break;
+
+ case FadeEffect_MOVE_FROM_UPPERLEFT :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_UPPERRIGHT :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_LOWERLEFT :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_LOWERRIGHT :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_TOP :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_LEFT :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_BOTTOM :
+ nDirection++;
+ case FadeEffect_MOVE_FROM_RIGHT :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_COVER;
+ break;
+
+ case FadeEffect_DISSOLVE :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_DISSOLVE;
+ break;
+
+ case FadeEffect_VERTICAL_LINES :
+ nDirection++;
+ case FadeEffect_HORIZONTAL_LINES :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_RANDOM_BARS;
+ break;
+
+ case FadeEffect_CLOSE_HORIZONTAL :
+ nDirection++;
+ case FadeEffect_OPEN_HORIZONTAL :
+ nDirection++;
+ case FadeEffect_CLOSE_VERTICAL :
+ nDirection++;
+ case FadeEffect_OPEN_VERTICAL :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_SPLIT;
+ break;
+
+ case FadeEffect_FADE_FROM_UPPERLEFT :
+ nDirection++;
+ case FadeEffect_FADE_FROM_UPPERRIGHT :
+ nDirection++;
+ case FadeEffect_FADE_FROM_LOWERLEFT :
+ nDirection++;
+ case FadeEffect_FADE_FROM_LOWERRIGHT :
+ nDirection += 4;
+ nPPTTransitionType = PPT_TRANSITION_TYPE_STRIPS;
+ break;
+
+ case FadeEffect_UNCOVER_TO_LOWERRIGHT :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_LOWERLEFT :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_UPPERRIGHT :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_UPPERLEFT :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_BOTTOM :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_RIGHT :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_TOP :
+ nDirection++;
+ case FadeEffect_UNCOVER_TO_LEFT :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_PULL;
+ break;
+
+ case FadeEffect_FADE_FROM_TOP :
+ nDirection++;
+ case FadeEffect_FADE_FROM_LEFT :
+ nDirection++;
+ case FadeEffect_FADE_FROM_BOTTOM :
+ nDirection++;
+ case FadeEffect_FADE_FROM_RIGHT :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_WIPE;
+ break;
+
+ case FadeEffect_ROLL_FROM_TOP :
+ nDirection++;
+ case FadeEffect_ROLL_FROM_LEFT :
+ nDirection++;
+ case FadeEffect_ROLL_FROM_BOTTOM :
+ nDirection++;
+ case FadeEffect_ROLL_FROM_RIGHT :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_WIPE;
+ break;
+
+ case FadeEffect_FADE_TO_CENTER :
+ nDirection++;
+ case FadeEffect_FADE_FROM_CENTER :
+ nPPTTransitionType = PPT_TRANSITION_TYPE_ZOOM;
+ break;
+
+ case FadeEffect_NONE :
+ nDirection = 2;
+ break;
+ }
+
+ return nPPTTransitionType;
+}
+
+// -----------------------------------------------------------------------
+
+sal_Bool PPTWriterBase::ContainsOtherShapeThanPlaceholders( sal_Bool bForOOMLX )
+{
+ sal_uInt32 nShapes = mXShapes->getCount();
+ sal_Bool bOtherThanPlaceHolders = sal_False;
+
+ if ( nShapes )
+ for ( sal_uInt32 nIndex = 0; ( nIndex < nShapes ) && ( bOtherThanPlaceHolders == sal_False ); nIndex++ ) {
+ if ( GetShapeByIndex( nIndex ) && mType != "drawing.Page" ) {
+ if( bForOOMLX &&
+ ( mType == "presentation.Page" ||
+ mType == "presentation.Notes" ) ) {
+ Reference< XSimpleText > rXText( mXShape, UNO_QUERY );
+
+ if( rXText.is() && rXText->getString().getLength() != 0 )
+ bOtherThanPlaceHolders = sal_True;
+ } else
+ bOtherThanPlaceHolders = sal_True;
+ }
+ DBG(printf("mType == %s\n", mType.GetBuffer()));
+ }
+
+ return bOtherThanPlaceHolders;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
new file mode 100644
index 000000000..39691f4c4
--- /dev/null
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -0,0 +1,2291 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <boost/unordered_map.hpp>
+#include <boost/foreach.hpp>
+#include <stdio.h>
+#include <oox/drawingml/chart/chartconverter.hxx>
+#include <oox/token/tokens.hxx>
+#include <oox/ole/vbaproject.hxx>
+#include <epptooxml.hxx>
+#include <epptdef.hxx>
+#include <oox/export/shapes.hxx>
+
+#include <cppuhelper/implementationentry.hxx>
+#include <cppuhelper/factory.hxx>
+#include <sax/fshelper.hxx>
+#include <rtl/ustrbuf.hxx>
+#include <filter/msfilter/escherex.hxx>
+#include <tools/poly.hxx>
+
+#include <com/sun/star/animations/AnimationAdditiveMode.hpp>
+#include <com/sun/star/animations/AnimationCalcMode.hpp>
+#include <com/sun/star/animations/AnimationFill.hpp>
+#include <com/sun/star/animations/AnimationNodeType.hpp>
+#include <com/sun/star/animations/AnimationRestart.hpp>
+#include <com/sun/star/animations/AnimationValueType.hpp>
+#include <com/sun/star/animations/Event.hpp>
+#include <com/sun/star/animations/EventTrigger.hpp>
+#include <com/sun/star/animations/Timing.hpp>
+#include <com/sun/star/animations/ValuePair.hpp>
+#include <com/sun/star/animations/XAnimateSet.hpp>
+#include <com/sun/star/animations/XAnimationNode.hpp>
+#include <com/sun/star/animations/XAnimationNodeSupplier.hpp>
+#include <com/sun/star/animations/XTransitionFilter.hpp>
+#include <com/sun/star/beans/Property.hpp>
+#include <com/sun/star/beans/XPropertySetInfo.hpp>
+#include <com/sun/star/container/XEnumerationAccess.hpp>
+#include <com/sun/star/drawing/FillStyle.hpp>
+#include <com/sun/star/drawing/RectanglePoint.hpp>
+#include <com/sun/star/geometry/RealPoint2D.hpp>
+#include <com/sun/star/office/XAnnotationEnumeration.hpp>
+#include <com/sun/star/office/XAnnotationAccess.hpp>
+#include <com/sun/star/presentation/AnimationSpeed.hpp>
+#include <com/sun/star/presentation/EffectNodeType.hpp>
+#include <com/sun/star/text/XSimpleText.hpp>
+#include <com/sun/star/util/DateTime.hpp>
+
+#include <oox/export/utils.hxx>
+
+#include "pptexanimations.hxx"
+
+// presentation namespaces
+#define PNMSS FSNS( XML_xmlns, XML_a ), "http://schemas.openxmlformats.org/drawingml/2006/main", \
+ FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main", \
+ FSNS( XML_xmlns, XML_r ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships"
+
+using ::rtl::OString;
+using ::rtl::OUString;
+using ::rtl::OUStringBuffer;
+using namespace ::com::sun::star;
+using namespace ::com::sun::star::animations;
+using namespace ::com::sun::star::beans;
+using namespace ::com::sun::star::container;
+using namespace ::com::sun::star::drawing;
+using namespace ::com::sun::star::geometry;
+using namespace ::com::sun::star::presentation;
+using namespace ::com::sun::star::office;
+using namespace ::com::sun::star::text;
+using namespace ::com::sun::star::uno;
+using namespace ::com::sun::star::util;
+using namespace ::ppt;
+using ::com::sun::star::beans::XPropertySet;
+using ::com::sun::star::beans::XPropertySetInfo;
+using ::com::sun::star::lang::XMultiServiceFactory;
+using ::com::sun::star::container::XIndexAccess;
+using ::com::sun::star::frame::XModel;
+using ::com::sun::star::io::XOutputStream;
+using ::com::sun::star::task::XStatusIndicator;
+using ::com::sun::star::text::XSimpleText;
+using ::sax_fastparser::FastSerializerHelper;
+using ::sax_fastparser::FSHelperPtr;
+
+void dump_pset(Reference< XPropertySet > rXPropSet);
+
+#define IDS(x) (OString(#x " ") + OString::valueOf( mnShapeIdMax++ )).getStr()
+
+namespace oox {
+ using namespace drawingml;
+ namespace core {
+
+class PowerPointShapeExport : public ShapeExport
+{
+ PowerPointExport& mrExport;
+ PageType mePageType;
+ sal_Bool mbMaster;
+public:
+ PowerPointShapeExport( FSHelperPtr pFS, ShapeHashMap* pShapeMap, PowerPointExport* pFB );
+ void SetMaster( sal_Bool bMaster );
+ void SetPageType( PageType ePageType );
+ ShapeExport& WriteNonVisualProperties( Reference< XShape > xShape );
+ ShapeExport& WriteTextShape( Reference< XShape > xShape );
+ ShapeExport& WriteUnknownShape( Reference< XShape > xShape );
+ ShapeExport& WritePlaceholderShape( Reference< XShape > xShape, PlaceholderType ePlaceholder );
+ ShapeExport& WritePageShape( Reference< XShape > xShape, PageType ePageType, sal_Bool bPresObj );
+
+ // helper parts
+ sal_Bool WritePlaceholder( Reference< XShape > xShape, PlaceholderType ePlaceholder, sal_Bool bMaster );
+};
+
+enum PPTXLayout {
+ LAYOUT_BLANK,
+ LAYOUT_TITLE_SLIDE,
+ LAYOUT_TITLE_CONTENT,
+ LAYOUT_TITLE_2CONTENT,
+ LAYOUT_TITLE,
+ LAYOUT_CENTERED_TEXT,
+ LAYOUT_TITLE_2CONTENT_CONTENT,
+ LAYOUT_TITLE_CONTENT_2CONTENT,
+ LAYOUT_TITLE_2CONTENT_OVER_CONTENT,
+ LAYOUT_TITLE_CONTENT_OVER_CONTENT,
+ LAYOUT_TITLE_4CONTENT,
+ LAYOUT_TITLE_6CONTENT,
+ LAYOUT_SIZE
+};
+
+struct PPTXLayoutInfo {
+ int nType;
+ const char* sName;
+ const char* sType;
+};
+
+static PPTXLayoutInfo aLayoutInfo[LAYOUT_SIZE] = {
+ { 20, "Blank Slide", "blank" },
+ { 0, "Title Slide", "tx" },
+ { 1, "Title, Content", "obj" },
+ { 3, "Title, 2 Content", "twoObj" },
+ { 19, "Title Only", "titleOnly" },
+ { 32, "Centered Text", "objOnly" }, // not exactly, but close
+ { 15, "Title, 2 Content and Content", "twoObjAndObj" },
+ { 12, "Title Content and 2 Content", "objAndTwoObj" },
+ { 16, "Title, 2 Content over Content", "twoObjOverTx" }, // not exactly, but close
+ { 14, "Title, Content over Content", "objOverTx" }, // not exactly, but close
+ { 18, "Title, 4 Content", "fourObj" },
+ { 33, "Title, 6 Content", "blank" } // not defined => blank
+};
+
+int PowerPointExport::GetPPTXLayoutId( int nOffset )
+{
+ int nId = LAYOUT_BLANK;
+
+ DBG(printf("GetPPTXLayoutId %d\n", nOffset));
+
+ switch( nOffset ) {
+ case 0:
+ nId = LAYOUT_TITLE_SLIDE;
+ break;
+ case 1:
+ nId = LAYOUT_TITLE_CONTENT;
+ break;
+ case 3:
+ nId = LAYOUT_TITLE_2CONTENT;
+ break;
+ case 19:
+ nId = LAYOUT_TITLE;
+ break;
+ case 15:
+ nId = LAYOUT_TITLE_2CONTENT_CONTENT;
+ break;
+ case 12:
+ nId = LAYOUT_TITLE_CONTENT_2CONTENT;
+ break;
+ case 16:
+ nId = LAYOUT_TITLE_2CONTENT_OVER_CONTENT;
+ break;
+ case 14:
+ nId = LAYOUT_TITLE_CONTENT_OVER_CONTENT;
+ break;
+ case 18:
+ nId = LAYOUT_TITLE_4CONTENT;
+ break;
+ case 32:
+ nId = LAYOUT_CENTERED_TEXT;
+ break;
+ case 33:
+ nId = LAYOUT_TITLE_6CONTENT;
+ break;
+ case 20:
+ default:
+ nId = LAYOUT_BLANK;
+ break;
+ }
+
+ return nId;
+}
+
+PowerPointShapeExport::PowerPointShapeExport( FSHelperPtr pFS, ShapeHashMap* pShapeMap, PowerPointExport* pFB )
+ : ShapeExport( XML_p, pFS, pShapeMap, pFB )
+ , mrExport( *pFB )
+{
+}
+
+void PowerPointShapeExport::SetMaster( sal_Bool bMaster )
+{
+ mbMaster = bMaster;
+}
+
+void PowerPointShapeExport::SetPageType( PageType ePageType )
+{
+ mePageType = ePageType;
+}
+
+ShapeExport& PowerPointShapeExport::WriteNonVisualProperties( Reference< XShape > )
+{
+ GetFS()->singleElementNS( XML_p, XML_nvPr, FSEND );
+
+ return *this;
+}
+
+ShapeExport& PowerPointShapeExport::WriteTextShape( Reference< XShape > xShape )
+{
+ OUString sShapeType = xShape->getShapeType();
+
+ DBG(printf( "shape(text): %s\n", USS(sShapeType) ));
+
+ if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.TextShape" ) ) )
+ {
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.DateTimeShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, DateAndTime, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.FooterShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, Footer, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.HeaderShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, Header, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.NotesShape" ) ) )
+ {
+ if( mePageType == NOTICE && mrExport.GetPresObj() )
+ WritePlaceholderShape( xShape, Notes );
+ else
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.OutlinerShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, Outliner, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.SlideNumberShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, SlideNumber, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.TitleTextShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, Title, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+
+ return *this;
+}
+
+ShapeExport& PowerPointShapeExport::WriteUnknownShape( Reference< XShape > xShape )
+{
+ OUString sShapeType = xShape->getShapeType();
+
+ DBG(printf( "shape(unknown): %s\n", USS(sShapeType) ));
+
+ if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.GroupShape" ) ) )
+ {
+ Reference< XIndexAccess > rXIndexAccess( xShape, UNO_QUERY );
+
+ mrExport.EnterGroup( rXIndexAccess );
+ DBG(printf( "enter group\n" ));
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.PageShape" ) ) )
+ {
+ WritePageShape( xShape, mePageType, mrExport.GetPresObj() );
+ }
+ else if( sShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.SubtitleShape" ) ) )
+ {
+ if( !WritePlaceholder( xShape, Subtitle, mbMaster ) )
+ ShapeExport::WriteTextShape( xShape );
+ }
+
+ return *this;
+}
+
+PowerPointExport::PowerPointExport( const Reference< XComponentContext > & rxCtxt )
+ : XmlFilterBase( rxCtxt ),
+ PPTWriterBase(),
+ mnLayoutFileIdMax( 1 ),
+ mnSlideIdMax( 1 << 8 ),
+ mnSlideMasterIdMax( 1 << 31 ),
+ mnAnimationNodeIdMax( 1 )
+{
+ memset( mLayoutInfo, 0, sizeof(mLayoutInfo) );
+}
+
+PowerPointExport::~PowerPointExport()
+{
+}
+
+bool PowerPointExport::importDocument() throw()
+{
+ return false;
+}
+
+bool PowerPointExport::exportDocument() throw()
+{
+ DrawingML::ResetCounters();
+ maShapeMap.clear ();
+
+ addRelation( US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" ), S( "ppt/presentation.xml" ) );
+
+ mPresentationFS = openFragmentStreamWithSerializer( US( "ppt/presentation.xml" ),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml" ) );
+
+ addRelation( mPresentationFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ),
+ US( "theme/theme1.xml" ) );
+
+ mPresentationFS->startElementNS( XML_p, XML_presentation, PNMSS, FSEND );
+
+ mXModel.set( getModel(), UNO_QUERY );
+ mXStatusIndicator.set( getStatusIndicator(), UNO_QUERY );
+
+ exportPPT();
+
+ mPresentationFS->singleElementNS( XML_p, XML_sldSz,
+ XML_cx, IS( PPTtoEMU( maDestPageSize.Width ) ),
+ XML_cy, IS( PPTtoEMU( maDestPageSize.Height ) ),
+ FSEND );
+ // for some reason if added before slides list it will not load the slides (alas with error reports) in mso
+ mPresentationFS->singleElementNS( XML_p, XML_notesSz,
+ XML_cx, IS( PPTtoEMU( maNotesPageSize.Width ) ),
+ XML_cy, IS( PPTtoEMU( maNotesPageSize.Height ) ),
+ FSEND );
+
+ WriteAuthors();
+
+ mPresentationFS->endElementNS( XML_p, XML_presentation );
+ mPresentationFS.reset();
+
+ commitStorage();
+
+ maShapeMap.clear();
+ maAuthors.clear();
+
+ return true;
+}
+
+::oox::ole::VbaProject* PowerPointExport::implCreateVbaProject() const
+{
+ return new ::oox::ole::VbaProject( getComponentContext(), getModel(), CREATE_OUSTRING( "Impress" ) );
+}
+
+void PowerPointExport::ImplWriteBackground( FSHelperPtr pFS, Reference< XPropertySet > rXPropSet )
+{
+ FillStyle aFillStyle( FillStyle_NONE );
+ if ( ImplGetPropertyValue( rXPropSet, S( "FillStyle" ) ) )
+ mAny >>= aFillStyle;
+
+ if( aFillStyle == FillStyle_NONE ||
+ aFillStyle == FillStyle_GRADIENT ||
+ aFillStyle == FillStyle_HATCH )
+ return;
+
+ pFS->startElementNS( XML_p, XML_bg, FSEND );
+ pFS->startElementNS( XML_p, XML_bgPr, FSEND );
+
+ PowerPointShapeExport( pFS, &maShapeMap, this ).WriteFill( rXPropSet );
+
+ pFS->endElementNS( XML_p, XML_bgPr );
+ pFS->endElementNS( XML_p, XML_bg );
+}
+
+#define MINIMAL_SPTREE "<p:spTree>\
+ <p:nvGrpSpPr>\
+ <p:cNvPr id=\"1\" name=\"\"/>\
+ <p:cNvGrpSpPr/>\
+ <p:nvPr/>\
+ </p:nvGrpSpPr>\
+ <p:grpSpPr>\
+ <a:xfrm>\
+ <a:off x=\"0\" y=\"0\"/>\
+ <a:ext cx=\"0\" cy=\"0\"/>\
+ <a:chOff x=\"0\" y=\"0\"/>\
+ <a:chExt cx=\"0\" cy=\"0\"/>\
+ </a:xfrm>\
+ </p:grpSpPr>\
+ </p:spTree>"
+
+#define MAIN_GROUP \
+ "<p:nvGrpSpPr>\
+ <p:cNvPr id=\"1\" name=\"\"/>\
+ <p:cNvGrpSpPr/>\
+ <p:nvPr/>\
+ </p:nvGrpSpPr>\
+ <p:grpSpPr>\
+ <a:xfrm>\
+ <a:off x=\"0\" y=\"0\"/>\
+ <a:ext cx=\"0\" cy=\"0\"/>\
+ <a:chOff x=\"0\" y=\"0\"/>\
+ <a:chExt cx=\"0\" cy=\"0\"/>\
+ </a:xfrm>\
+ </p:grpSpPr>"
+
+#define GETA(propName) \
+ ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( #propName ) ) )
+
+#define GET(variable, propName) \
+ if ( GETA(propName) ) \
+ mAny >>= variable;
+
+const char* PowerPointExport::GetSideDirection( sal_uInt8 nDirection )
+{
+ const char* pDirection = NULL;
+
+ switch( nDirection ) {
+ case 0:
+ pDirection = "r";
+ break;
+ case 1:
+ pDirection = "d";
+ break;
+ case 2:
+ pDirection = "l";
+ break;
+ case 3:
+ pDirection = "u";
+ break;
+ }
+
+ return pDirection;
+}
+
+const char* PowerPointExport::GetCornerDirection( sal_uInt8 nDirection )
+{
+ const char* pDirection = NULL;
+
+ switch( nDirection ) {
+ case 4:
+ pDirection = "rd";
+ break;
+ case 5:
+ pDirection = "ld";
+ break;
+ case 6:
+ pDirection = "ru";
+ break;
+ case 7:
+ pDirection = "lu";
+ break;
+ }
+
+ return pDirection;
+}
+
+const char* PowerPointExport::Get8Direction( sal_uInt8 nDirection )
+{
+ const char* pDirection = GetSideDirection( nDirection );
+
+ if( !pDirection )
+ pDirection = GetCornerDirection( nDirection );
+
+ return pDirection;
+}
+
+void PowerPointExport::WriteTransition( FSHelperPtr pFS )
+{
+ FadeEffect eFadeEffect = FadeEffect_NONE;
+ GET( eFadeEffect, Effect );
+
+ OSL_TRACE("fade effect %d", eFadeEffect);
+
+ sal_Int16 nTransitionType = 0, nTransitionSubtype = 0;
+ sal_Int8 nPPTTransitionType = 0;
+ sal_uInt8 nDirection = 0;
+
+ if( GETA( TransitionType ) && ( mAny >>= nTransitionType ) &&
+ GETA( TransitionSubtype ) && ( mAny >>= nTransitionSubtype ) )
+ nPPTTransitionType = GetTransition( nTransitionType, nTransitionSubtype, eFadeEffect, nDirection );
+
+ if( !nPPTTransitionType && eFadeEffect != FadeEffect_NONE )
+ nPPTTransitionType = GetTransition( eFadeEffect, nDirection );
+
+ if( nPPTTransitionType ) {
+ AnimationSpeed animationSpeed = AnimationSpeed_MEDIUM;
+ const char* speed = NULL;
+ sal_Int32 advanceTiming = -1;
+ sal_Int32 changeType = 0;
+
+ if( GETA( Speed ) ) {
+ mAny >>= animationSpeed;
+
+ switch( animationSpeed ) {
+ default:
+ case AnimationSpeed_MEDIUM:
+ speed = "med";
+ break;
+ case AnimationSpeed_SLOW:
+ speed = "slow";
+ break;
+ case AnimationSpeed_FAST:
+ break;
+ }
+ }
+
+ if( GETA( Change ) )
+ mAny >>= changeType;
+
+ // 1 means automatic, 2 half automatic - not sure what it means - at least I don't see it in UI
+ if( changeType == 1 && GETA( Duration ) )
+ mAny >>= advanceTiming;
+
+ pFS->startElementNS( XML_p, XML_transition,
+ XML_spd, speed,
+ XML_advTm, advanceTiming != -1 ? I32S( advanceTiming*1000 ) : NULL,
+ FSEND );
+
+ sal_Int32 nTransition = 0;
+ const char* pDirection = NULL;
+ const char* pOrientation = NULL;
+ const char* pThruBlk = NULL;
+ const char* pSpokes = NULL;
+ char pSpokesTmp[2] = "0";
+
+ switch( nPPTTransitionType ) {
+ case PPT_TRANSITION_TYPE_BLINDS:
+ nTransition = XML_blinds;
+ pDirection = ( nDirection == 0) ? "vert" : "horz";
+ break;
+ case PPT_TRANSITION_TYPE_CHECKER:
+ nTransition = XML_checker;
+ pDirection = ( nDirection == 1) ? "vert" : "horz";
+ break;
+ case PPT_TRANSITION_TYPE_CIRCLE:
+ nTransition = XML_circle;
+ break;
+ case PPT_TRANSITION_TYPE_COMB:
+ nTransition = XML_comb;
+ pDirection = ( nDirection == 1) ? "vert" : "horz";
+ break;
+ case PPT_TRANSITION_TYPE_COVER:
+ nTransition = XML_cover;
+ pDirection = Get8Direction( nDirection );
+ break;
+ case PPT_TRANSITION_TYPE_DIAMOND:
+ nTransition = XML_diamond;
+ break;
+ case PPT_TRANSITION_TYPE_DISSOLVE:
+ nTransition = XML_dissolve;
+ break;
+ case PPT_TRANSITION_TYPE_FADE:
+ nTransition = XML_fade;
+ pThruBlk = "true";
+ break;
+ case PPT_TRANSITION_TYPE_SMOOTHFADE:
+ nTransition = XML_fade;
+ break;
+ case PPT_TRANSITION_TYPE_NEWSFLASH:
+ nTransition = XML_newsflash;
+ break;
+ case PPT_TRANSITION_TYPE_PLUS:
+ nTransition = XML_plus;
+ break;
+ case PPT_TRANSITION_TYPE_PULL:
+ nTransition = XML_pull;
+ pDirection = Get8Direction( nDirection );
+ break;
+ case PPT_TRANSITION_TYPE_PUSH:
+ nTransition = XML_push;
+ pDirection = GetSideDirection( nDirection );
+ break;
+ case PPT_TRANSITION_TYPE_RANDOM:
+ nTransition = XML_random;
+ break;
+ case PPT_TRANSITION_TYPE_RANDOM_BARS:
+ nTransition = XML_randomBar;
+ pDirection = ( nDirection == 1) ? "vert" : "horz";
+ break;
+ case PPT_TRANSITION_TYPE_SPLIT:
+ nTransition = XML_split;
+ pDirection = ( nDirection & 1) ? "in" : "out";
+ pOrientation = ( nDirection < 2) ? "horz" : "vert";
+ break;
+ case PPT_TRANSITION_TYPE_STRIPS:
+ nTransition = XML_strips;
+ pDirection = GetCornerDirection( nDirection );
+ break;
+ case PPT_TRANSITION_TYPE_WEDGE:
+ nTransition = XML_wedge;
+ break;
+ case PPT_TRANSITION_TYPE_WHEEL:
+ nTransition = XML_wheel;
+ if( nDirection != 4 && nDirection <= 9 ) {
+ pSpokesTmp[0] = '0' + nDirection;
+ pSpokes = pSpokesTmp;
+ }
+ break;
+ case PPT_TRANSITION_TYPE_WIPE:
+ nTransition = XML_wipe;
+ pDirection = GetSideDirection( nDirection );
+ break;
+ case PPT_TRANSITION_TYPE_ZOOM:
+ nTransition = XML_zoom;
+ pDirection = ( nDirection == 1) ? "in" : "out";
+ break;
+ case PPT_TRANSITION_TYPE_NONE:
+ default:
+ nTransition = 0;
+ }
+
+ if( nTransition )
+ pFS->singleElementNS( XML_p, nTransition,
+ XML_dir, pDirection,
+ XML_orient, pOrientation,
+ XML_spokes, pSpokes,
+ XML_thruBlk, pThruBlk,
+ FSEND );
+
+ pFS->endElementNS( XML_p, XML_transition );
+ }
+}
+
+void PowerPointExport::WriteAnimationProperty( FSHelperPtr pFS, const Any& rAny )
+{
+ if( !rAny.hasValue() )
+ return;
+
+ switch( rAny.getValueType().getTypeClass() ) {
+ case TypeClass_STRING:
+ pFS->singleElementNS( XML_p, XML_strVal,
+ XML_val, USS( *static_cast< const OUString* >( rAny.getValue() ) ),
+ FSEND );
+ break;
+ default:
+ break;
+ }
+}
+
+void PowerPointExport::WriteAnimateValues( FSHelperPtr pFS, const Reference< XAnimate >& rXAnimate )
+{
+ const Sequence< double > aKeyTimes = rXAnimate->getKeyTimes();
+ if( aKeyTimes.getLength() <= 0 )
+ return;
+ const Sequence< Any > aValues = rXAnimate->getValues();
+ const OUString& sFormula = rXAnimate->getFormula();
+ const OUString& rAttributeName = rXAnimate->getAttributeName();
+
+ DBG(printf("animate values, formula: %s\n", USS( sFormula )));
+
+ pFS->startElementNS( XML_p, XML_tavLst, FSEND );
+
+ for( int i = 0; i < aKeyTimes.getLength(); i++ ) {
+ DBG(printf("animate value %d: %f\n", i, aKeyTimes[ i ]));
+ if( aValues[ i ].hasValue() ) {
+ pFS->startElementNS( XML_p, XML_tav,
+ XML_fmla, sFormula.getLength() > 0 ? USS( sFormula ) : NULL,
+ XML_tm, I32S( ( sal_Int32 )( aKeyTimes[ i ]*100000.0 ) ),
+ FSEND );
+ pFS->startElementNS( XML_p, XML_val, FSEND );
+ ValuePair aPair;
+ if( aValues[ i ] >>= aPair ) {
+ WriteAnimationProperty( pFS, AnimationExporter::convertAnimateValue( aPair.First, rAttributeName ) );
+ WriteAnimationProperty( pFS, AnimationExporter::convertAnimateValue( aPair.Second, rAttributeName ) );
+ } else
+ WriteAnimationProperty( pFS, AnimationExporter::convertAnimateValue( aValues[ i ], rAttributeName ) );
+
+ pFS->endElementNS( XML_p, XML_val );
+ pFS->endElementNS( XML_p, XML_tav );
+ }
+ }
+
+ pFS->endElementNS( XML_p, XML_tavLst );
+}
+
+void PowerPointExport::WriteAnimateTo( FSHelperPtr pFS, Any aValue, const OUString& rAttributeName )
+{
+ if( !aValue.hasValue() )
+ return;
+
+ DBG(printf("to attribute name: %s\n", USS( rAttributeName )));
+
+ pFS->startElementNS( XML_p, XML_to, FSEND );
+
+ WriteAnimationProperty( pFS, AnimationExporter::convertAnimateValue( aValue, rAttributeName ) );
+
+ pFS->endElementNS( XML_p, XML_to );
+}
+
+void PowerPointExport::WriteAnimationAttributeName( FSHelperPtr pFS, const OUString& rAttributeName )
+{
+ if( ! rAttributeName.getLength() )
+ return;
+
+ pFS->startElementNS( XML_p, XML_attrNameLst, FSEND );
+
+ DBG(printf("write attribute name: %s\n", USS( rAttributeName )));
+
+ const char* sAttributeName = NULL;
+ if( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Visibility" ) ) ) {
+ sAttributeName = "style.visibility";
+ } else if( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "X" ) ) ) {
+ sAttributeName = "ppt_x";
+ } else if( rAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Y" ) ) ) {
+ sAttributeName = "ppt_y";
+ }
+
+ pFS->startElementNS( XML_p, XML_attrName, FSEND );
+ pFS->writeEscaped( sAttributeName );
+ pFS->endElementNS( XML_p, XML_attrName );
+
+ pFS->endElementNS( XML_p, XML_attrNameLst );
+}
+
+void PowerPointExport::WriteAnimationTarget( FSHelperPtr pFS, Any aTarget )
+{
+ sal_Int32 nBegin = -1, nEnd = -1;
+ sal_Bool bParagraphTarget;
+ Reference< XShape > rXShape = AnimationExporter::getTargetElementShape( aTarget, nBegin, nEnd, bParagraphTarget );
+
+ if( rXShape.is() ) {
+ pFS->startElementNS( XML_p, XML_tgtEl, FSEND );
+ pFS->startElementNS( XML_p, XML_spTgt,
+ XML_spid, I32S( ShapeExport::GetShapeID( rXShape, &maShapeMap ) ),
+ FSEND );
+ if( bParagraphTarget ) {
+ pFS->startElementNS( XML_p, XML_txEl, FSEND );
+ pFS->singleElementNS( XML_p, XML_pRg,
+ XML_st, I32S( nBegin ),
+ XML_end, I32S( nEnd ),
+ FSEND );
+ pFS->endElementNS( XML_p, XML_txEl );
+ }
+ pFS->endElementNS( XML_p, XML_spTgt );
+ pFS->endElementNS( XML_p, XML_tgtEl );
+ }
+}
+
+void PowerPointExport::WriteAnimationNodeAnimate( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32 nXmlNodeType, sal_Bool bMainSeqChild )
+{
+ Reference< XAnimate > rXAnimate( rXNode, UNO_QUERY );
+ if( !rXAnimate.is() )
+ return;
+
+ const char* pCalcMode = NULL;
+ const char* pValueType = NULL;
+ sal_Bool bSimple = ( nXmlNodeType != XML_anim );
+
+ if( !bSimple ) {
+ switch( rXAnimate->getCalcMode() ) {
+ case AnimationCalcMode::DISCRETE:
+ pCalcMode = "discrete";
+ break;
+ case AnimationCalcMode::LINEAR:
+ pCalcMode = "lin";
+ break;
+ }
+
+ switch( AnimationExporter::GetValueTypeForAttributeName( rXAnimate->getAttributeName() ) ) {
+ case AnimationValueType::STRING:
+ pValueType = "str";
+ break;
+ case AnimationValueType::NUMBER:
+ pValueType = "num";
+ break;
+ case AnimationValueType::COLOR:
+ pValueType = "clr";
+ break;
+ }
+ }
+
+ pFS->startElementNS( XML_p, nXmlNodeType,
+ XML_calcmode, pCalcMode,
+ XML_valueType, pValueType,
+ FSEND );
+ WriteAnimationNodeAnimateInside( pFS, rXNode, bMainSeqChild, bSimple );
+ pFS->endElementNS( XML_p, nXmlNodeType );
+}
+
+void PowerPointExport::WriteAnimationNodeAnimateInside( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Bool bMainSeqChild, sal_Bool bSimple )
+{
+ Reference< XAnimate > rXAnimate( rXNode, UNO_QUERY );
+ if( !rXAnimate.is() )
+ return;
+
+ const char* pAdditive = NULL;
+
+ if( !bSimple ) {
+ switch( rXAnimate->getAdditive() ) {
+ case AnimationAdditiveMode::BASE:
+ pAdditive = "base";
+ break;
+ case AnimationAdditiveMode::SUM:
+ pAdditive = "sum";
+ break;
+ case AnimationAdditiveMode::REPLACE:
+ pAdditive = "repl";
+ break;
+ case AnimationAdditiveMode::MULTIPLY:
+ pAdditive = "mult";
+ break;
+ case AnimationAdditiveMode::NONE:
+ pAdditive = "none";
+ break;
+ }
+ }
+
+ pFS->startElementNS( XML_p, XML_cBhvr,
+ XML_additive, pAdditive,
+ FSEND );
+ WriteAnimationNodeCommonPropsStart( pFS, rXNode, sal_True, bMainSeqChild );
+ WriteAnimationTarget( pFS, rXAnimate->getTarget() );
+ WriteAnimationAttributeName( pFS, rXAnimate->getAttributeName() );
+ pFS->endElementNS( XML_p, XML_cBhvr );
+ WriteAnimateValues( pFS, rXAnimate );
+ WriteAnimateTo( pFS, rXAnimate->getTo(), rXAnimate->getAttributeName() );
+}
+
+void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, const char* pDelay, const char* pEvent, double fDelay, sal_Bool bHasFDelay )
+{
+ if( bHasFDelay || pDelay || pEvent ) {
+ if( !pEvent )
+ pFS->singleElementNS( XML_p, XML_cond,
+ XML_delay, bHasFDelay ? I64S( (sal_uInt32) (fDelay*1000.0) ) : pDelay,
+ FSEND );
+ else {
+ pFS->startElementNS( XML_p, XML_cond,
+ XML_delay, bHasFDelay ? I64S( (sal_uInt32) (fDelay*1000.0) ) : pDelay,
+ XML_evt, pEvent,
+ FSEND );
+
+ pFS->startElementNS( XML_p, XML_tgtEl, FSEND );
+ pFS->singleElementNS( XML_p, XML_sldTgt, FSEND );
+ pFS->endElementNS( XML_p, XML_tgtEl );
+
+ pFS->endElementNS( XML_p, XML_cond );
+ }
+ }
+}
+
+void PowerPointExport::WriteAnimationCondition( FSHelperPtr pFS, Any& rAny, sal_Bool bWriteEvent, sal_Bool bMainSeqChild )
+{
+ sal_Bool bHasFDelay = sal_False;
+ double fDelay = 0;
+ Timing eTiming;
+ Event aEvent;
+ const char* pDelay = NULL;
+ const char* pEvent = NULL;
+
+ if( rAny >>= fDelay )
+ bHasFDelay = sal_True;
+ else if( rAny >>= eTiming ) {
+ if( eTiming == Timing_INDEFINITE )
+ pDelay = "indefinite";
+ } else if( rAny >>= aEvent ) {
+ // TODO
+ DBG(printf ("animation condition event: TODO\n"));
+ DBG(printf ("event offset has value: %d triger: %d source has value: %d\n", aEvent.Offset.hasValue(), aEvent.Trigger, aEvent.Source.hasValue()));
+
+ if( !bWriteEvent && aEvent.Trigger == EventTrigger::ON_NEXT && bMainSeqChild )
+ pDelay = "indefinite";
+ else if( bWriteEvent ) {
+ switch( aEvent.Trigger ) {
+ case EventTrigger::ON_NEXT:
+ pEvent = "onNext";
+ break;
+ case EventTrigger::ON_PREV:
+ pEvent = "onPrev";
+ break;
+ case EventTrigger::BEGIN_EVENT:
+ pEvent = "begin";
+ break;
+ case EventTrigger::END_EVENT:
+ pEvent = "end";
+ break;
+ case EventTrigger::ON_BEGIN:
+ pEvent = "onBegin";
+ break;
+ case EventTrigger::ON_END:
+ pEvent = "onEnd";
+ break;
+ case EventTrigger::ON_CLICK:
+ pEvent = "onClick";
+ break;
+ case EventTrigger::ON_DBL_CLICK:
+ pEvent = "onDblClick";
+ break;
+ case EventTrigger::ON_STOP_AUDIO:
+ pEvent = "onStopAudio";
+ break;
+ case EventTrigger::ON_MOUSE_ENTER:
+ pEvent = "onMouseOver"; // not exact?
+ break;
+ case EventTrigger::ON_MOUSE_LEAVE:
+ pEvent = "onMouseOut";
+ break;
+ }
+ }
+
+ if( aEvent.Offset >>= fDelay ) {
+ bHasFDelay = sal_True;
+ DBG(printf ("event offset: %f\n", fDelay));
+ } else if( aEvent.Offset >>= eTiming ) {
+ if( eTiming == Timing_INDEFINITE )
+ pDelay = "indefinite";
+ DBG(printf ("event offset timing: %d\n", eTiming));
+ }
+ }
+
+ WriteAnimationCondition( pFS, pDelay, pEvent, fDelay, bHasFDelay );
+}
+
+void PowerPointExport::WriteAnimationNodeCommonPropsStart( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Bool bSingle, sal_Bool bMainSeqChild )
+{
+ const char* pDuration = NULL;
+ const char* pRestart = NULL;
+ const char* pNodeType = NULL;
+ const char* pPresetClass = NULL;
+ const char* pFill = NULL;
+ double fDuration = 0;
+ Any aAny;
+
+ aAny = rXNode->getDuration();
+ if( aAny.hasValue() ) {
+ Timing eTiming;
+
+ if( aAny >>= eTiming ) {
+ if( eTiming == Timing_INDEFINITE )
+ pDuration = "indefinite";
+ } else
+ aAny >>= fDuration;
+ }
+
+ switch( rXNode->getRestart() ) {
+ case AnimationRestart::ALWAYS:
+ pRestart = "always";
+ break;
+ case AnimationRestart::WHEN_NOT_ACTIVE:
+ pRestart = "whenNotActive";
+ break;
+ case AnimationRestart::NEVER:
+ pRestart = "never";
+ break;
+ }
+
+ const Sequence< NamedValue > aUserData = rXNode->getUserData();
+ const Any* pAny[ DFF_ANIM_PROPERTY_ID_COUNT ];
+ AnimationExporter::GetUserData( aUserData, pAny, sizeof( pAny ) );
+
+ sal_Int16 nType = 0;
+ if( pAny[ DFF_ANIM_NODE_TYPE ] && ( *pAny[ DFF_ANIM_NODE_TYPE ] >>= nType ) ) {
+ switch( nType ) {
+ case EffectNodeType::TIMING_ROOT:
+ pNodeType = "tmRoot";
+ if( !pDuration )
+ pDuration = "indefinite";
+ if( !pRestart )
+ pRestart = "never";
+ break;
+ case EffectNodeType::MAIN_SEQUENCE:
+ pNodeType = "mainSeq";
+ break;
+ case EffectNodeType::ON_CLICK:
+ pNodeType = "clickEffect";
+ break;
+ case EffectNodeType::AFTER_PREVIOUS:
+ pNodeType = "afterEffect";
+ break;
+ case EffectNodeType::WITH_PREVIOUS:
+ pNodeType = "withEffect";
+ break;
+ case EffectNodeType::INTERACTIVE_SEQUENCE:
+ pNodeType = "interactiveSeq";
+ break;
+ }
+ }
+
+ sal_uInt32 nPresetClass = DFF_ANIM_PRESS_CLASS_USER_DEFINED;
+ if ( pAny[ DFF_ANIM_PRESET_CLASS ] ) {
+ if ( *pAny[ DFF_ANIM_PRESET_CLASS ] >>= nPresetClass ) {
+ switch( nPresetClass ) {
+ case EffectPresetClass::ENTRANCE:
+ pPresetClass = "entr";
+ break;
+ case EffectPresetClass::EXIT:
+ pPresetClass = "exit";
+ break;
+ case EffectPresetClass::EMPHASIS:
+ pPresetClass = "emph";
+ break;
+ case EffectPresetClass::MOTIONPATH:
+ pPresetClass = "path";
+ break;
+ case EffectPresetClass::OLEACTION:
+ pPresetClass = "verb"; // ?
+ break;
+ case EffectPresetClass::MEDIACALL:
+ pPresetClass = "mediacall";
+ break;
+ }
+ }
+ }
+
+ sal_uInt32 nPresetId = 0;
+ sal_Bool bPresetId = sal_False;
+ if ( pAny[ DFF_ANIM_PRESET_ID ] ) {
+ rtl::OUString sPreset;
+ if ( *pAny[ DFF_ANIM_PRESET_ID ] >>= sPreset )
+ nPresetId = AnimationExporter::GetPresetID( sPreset, nPresetClass, bPresetId );
+ }
+
+ sal_uInt32 nPresetSubType = 0;
+ sal_Bool bPresetSubType = sal_False;
+ if ( pAny[ DFF_ANIM_PRESET_SUB_TYPE ] ) {
+ rtl::OUString sPresetSubType;
+ if ( *pAny[ DFF_ANIM_PRESET_SUB_TYPE ] >>= sPresetSubType ) {
+ nPresetSubType = AnimationExporter::TranslatePresetSubType( nPresetClass, nPresetId, sPresetSubType );
+ bPresetSubType = sal_True;
+ }
+ }
+
+ if( nType != EffectNodeType::TIMING_ROOT && nType != EffectNodeType::MAIN_SEQUENCE ) {
+ // it doesn't seem to work right on root and mainseq nodes
+ sal_Int16 nFill = AnimationExporter::GetFillMode( rXNode, AnimationFill::AUTO );
+ switch( nFill ) {
+ case AnimationFill::FREEZE:
+ pFill = "freeze";
+ break;
+ case AnimationFill::HOLD:
+ pFill = "hold";
+ break;
+ case AnimationFill::REMOVE:
+ pFill = "remove";
+ break;
+ case AnimationFill::TRANSITION:
+ pFill = "transition";
+ break;
+ }
+ }
+
+ pFS->startElementNS( XML_p, XML_cTn,
+ XML_id, I64S( mnAnimationNodeIdMax ++ ),
+ XML_dur, fDuration != 0 ? I32S( (sal_Int32) ( fDuration * 1000.0 ) ) : pDuration,
+ XML_restart, pRestart,
+ XML_nodeType, pNodeType,
+ XML_fill, pFill,
+ XML_presetClass, pPresetClass,
+ XML_presetID, bPresetId ? I64S( nPresetId ) : NULL,
+ XML_presetSubtype, bPresetSubType ? I64S( nPresetSubType ) : NULL,
+ FSEND );
+
+ aAny = rXNode->getBegin();
+ if( aAny.hasValue() ) {
+ Sequence< Any > aCondSeq;
+
+ pFS->startElementNS( XML_p, XML_stCondLst, FSEND );
+ if( aAny >>= aCondSeq ) {
+ for( int i = 0; i < aCondSeq.getLength(); i ++ )
+ WriteAnimationCondition( pFS, aCondSeq[ i ], sal_False, bMainSeqChild );
+ } else
+ WriteAnimationCondition( pFS, aAny, sal_False, bMainSeqChild );
+ pFS->endElementNS( XML_p, XML_stCondLst );
+ }
+
+ aAny = rXNode->getEnd();
+ if( aAny.hasValue() ) {
+ Sequence< Any > aCondSeq;
+
+ pFS->startElementNS( XML_p, XML_endCondLst, FSEND );
+ if( aAny >>= aCondSeq ) {
+ for( int i = 0; i < aCondSeq.getLength(); i ++ )
+ WriteAnimationCondition( pFS, aCondSeq[ i ], sal_False, bMainSeqChild );
+ } else
+ WriteAnimationCondition( pFS, aAny, sal_False, bMainSeqChild );
+ pFS->endElementNS( XML_p, XML_stCondLst );
+ }
+
+ Reference< XEnumerationAccess > xEnumerationAccess( rXNode, UNO_QUERY );
+ if( xEnumerationAccess.is() ) {
+ Reference< XEnumeration > xEnumeration( xEnumerationAccess->createEnumeration(), UNO_QUERY );
+ if( xEnumeration.is() ) {
+ DBG(printf ("-----\n"));
+
+ pFS->startElementNS( XML_p, XML_childTnLst, FSEND );
+
+ while( xEnumeration->hasMoreElements() ) {
+ Reference< XAnimationNode > xChildNode( xEnumeration->nextElement(), UNO_QUERY );
+ if( xChildNode.is() )
+ WriteAnimationNode( pFS, xChildNode, nType == EffectNodeType::MAIN_SEQUENCE );
+ }
+
+ pFS->endElementNS( XML_p, XML_childTnLst );
+
+ DBG(printf ("-----\n"));
+ }
+ }
+
+ if( bSingle )
+ pFS->endElementNS( XML_p, XML_cTn );
+}
+
+void PowerPointExport::WriteAnimationNodeCommonPropsEnd( FSHelperPtr pFS )
+{
+ pFS->endElementNS( XML_p, XML_cTn );
+}
+
+void PowerPointExport::WriteAnimationNodeSeq( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, sal_Bool bMainSeqChild )
+{
+ DBG(printf ("write animation node SEQ\n"));
+
+ pFS->startElementNS( XML_p, XML_seq, FSEND );
+
+ WriteAnimationNodeCommonPropsStart( pFS, rXNode, sal_True, bMainSeqChild );
+
+ pFS->startElementNS( XML_p, XML_prevCondLst, FSEND );
+ WriteAnimationCondition( pFS, NULL, "onPrev", 0, sal_True );
+ pFS->endElementNS( XML_p, XML_prevCondLst );
+
+ pFS->startElementNS( XML_p, XML_nextCondLst, FSEND );
+ WriteAnimationCondition( pFS, NULL, "onNext", 0, sal_True );
+ pFS->endElementNS( XML_p, XML_nextCondLst );
+
+ pFS->endElementNS( XML_p, XML_seq );
+}
+
+void PowerPointExport::WriteAnimationNodeEffect( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Int32, sal_Bool bMainSeqChild )
+{
+ DBG(printf ("write animation node FILTER\n"));
+
+ Reference< XTransitionFilter > xFilter( rXNode, UNO_QUERY );
+ if ( xFilter.is() ) {
+ const char* pFilter = ppt::AnimationExporter::FindTransitionName( xFilter->getTransition(), xFilter->getSubtype(), xFilter->getDirection() );
+ const char* pDirection = xFilter->getDirection() ? "in" : "out";
+ pFS->startElementNS( XML_p, XML_animEffect,
+ XML_filter, pFilter,
+ XML_transition, pDirection,
+ FSEND );
+
+ WriteAnimationNodeAnimateInside( pFS, rXNode, bMainSeqChild, sal_False );
+
+ pFS->endElementNS( XML_p, XML_animEffect );
+ }
+}
+
+void PowerPointExport::WriteAnimationNode( FSHelperPtr pFS, const Reference< XAnimationNode >& rXNode, sal_Bool bMainSeqChild )
+{
+ DBG(printf ("export node type: %d\n", rXNode->getType()));
+ sal_Int32 xmlNodeType = -1;
+ typedef void (PowerPointExport::*AnimationNodeWriteMethod)( FSHelperPtr, const Reference< XAnimationNode >&, sal_Int32, sal_Bool );
+ AnimationNodeWriteMethod pMethod = NULL;
+
+ switch( rXNode->getType() ) {
+ case AnimationNodeType::PAR:
+ xmlNodeType = XML_par;
+ break;
+ case AnimationNodeType::SEQ:
+ pMethod = &PowerPointExport::WriteAnimationNodeSeq;
+ break;
+ case AnimationNodeType::ANIMATE:
+ xmlNodeType = XML_anim;
+ pMethod = &PowerPointExport::WriteAnimationNodeAnimate;
+ break;
+ case AnimationNodeType::SET:
+ xmlNodeType = XML_set;
+ pMethod = &PowerPointExport::WriteAnimationNodeAnimate;
+ break;
+ case AnimationNodeType::TRANSITIONFILTER:
+ xmlNodeType = XML_animEffect;
+ pMethod = &PowerPointExport::WriteAnimationNodeEffect;
+ break;
+ }
+
+ if( pMethod ) {
+ (this->*(pMethod))( pFS, rXNode, xmlNodeType, bMainSeqChild );
+ return;
+ }
+
+ if( xmlNodeType == -1 )
+ return;
+
+ pFS->startElementNS( XML_p, xmlNodeType, FSEND );
+
+ WriteAnimationNodeCommonPropsStart( pFS, rXNode, sal_True, bMainSeqChild );
+
+ pFS->endElementNS( XML_p, xmlNodeType );
+}
+
+void PowerPointExport::WriteAnimations( FSHelperPtr pFS )
+{
+ Reference< XAnimationNodeSupplier > xNodeSupplier( mXDrawPage, UNO_QUERY );
+ if( xNodeSupplier.is() ) {
+ const Reference< XAnimationNode > xNode( xNodeSupplier->getAnimationNode() );
+ if( xNode.is() ) {
+ Reference< XEnumerationAccess > xEnumerationAccess( xNode, UNO_QUERY );
+ if( xEnumerationAccess.is() ) {
+ Reference< XEnumeration > xEnumeration( xEnumerationAccess->createEnumeration(), UNO_QUERY );
+ if( xEnumeration.is() && xEnumeration->hasMoreElements() ) {
+
+ pFS->startElementNS( XML_p, XML_timing, FSEND );
+ pFS->startElementNS( XML_p, XML_tnLst, FSEND );
+
+ WriteAnimationNode( pFS, xNode, sal_False );
+
+ pFS->endElementNS( XML_p, XML_tnLst );
+ pFS->endElementNS( XML_p, XML_timing );
+ }
+ }
+ }
+ }
+}
+
+
+static OUString lcl_GetInitials( OUString sName )
+{
+ OUStringBuffer sRet;
+
+ if ( sName.getLength() > 0 ) {
+ sRet.append ( sName[0] );
+ sal_Int32 nStart = 0, nOffset;
+
+ while ( ( nOffset = sName.indexOf ( ' ', nStart ) ) != -1 ) {
+ if ( nOffset + 1 < sName.getLength() )
+ sRet.append ( sName[ nOffset + 1 ] );
+ nStart = nOffset + 1;
+ }
+ }
+
+ return sRet.makeStringAndClear();
+}
+
+void PowerPointExport::WriteAuthors()
+{
+ if ( maAuthors.size() <= 0 )
+ return;
+
+ FSHelperPtr pFS = openFragmentStreamWithSerializer( US( "ppt/commentAuthors.xml" ),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.commentAuthors+xml" ) );
+ addRelation( mPresentationFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/commentAuthors" ),
+ US( "commentAuthors.xml" ) );
+
+ pFS->startElementNS( XML_p, XML_cmAuthorLst,
+ FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main",
+ FSEND );
+
+ BOOST_FOREACH( AuthorsMap::value_type i, maAuthors ) {
+ pFS->singleElementNS( XML_p, XML_cmAuthor,
+ XML_id, I32S( i.second.nId ),
+ XML_name, USS( i.first ),
+ XML_initials, USS( lcl_GetInitials( i.first ) ),
+ XML_lastIdx, I32S( i.second.nLastIndex ),
+ XML_clrIdx, I32S( i.second.nId ),
+ FSEND );
+ }
+
+ pFS->endElementNS( XML_p, XML_cmAuthorLst );
+}
+
+sal_Int32 PowerPointExport::GetAuthorIdAndLastIndex( OUString sAuthor, sal_Int32& nLastIndex )
+{
+ if ( maAuthors.count( sAuthor ) <= 0 ) {
+ struct AuthorComments aAuthorComments;
+
+ aAuthorComments.nId = maAuthors.size();
+ aAuthorComments.nLastIndex = 0;
+
+ maAuthors[ sAuthor ] = aAuthorComments;
+ }
+
+ nLastIndex = ++maAuthors[ sAuthor ].nLastIndex;
+
+ return maAuthors[ sAuthor ].nId;
+}
+
+bool PowerPointExport::WriteComments( sal_uInt32 nPageNum )
+{
+ Reference< XAnnotationAccess > xAnnotationAccess( mXDrawPage, uno::UNO_QUERY );
+ if ( xAnnotationAccess.is() )
+ {
+ Reference< XAnnotationEnumeration > xAnnotationEnumeration( xAnnotationAccess->createAnnotationEnumeration() );
+
+ if ( xAnnotationEnumeration->hasMoreElements() )
+ {
+ FSHelperPtr pFS = openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/comments/comment" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.comments+xml" ) );
+
+ pFS->startElementNS( XML_p, XML_cmLst,
+ FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main",
+ FSEND );
+
+ do {
+ Reference< XAnnotation > xAnnotation( xAnnotationEnumeration->nextElement() );
+ DateTime aDateTime( xAnnotation->getDateTime() );
+ RealPoint2D aRealPoint2D( xAnnotation->getPosition() );
+ Reference< XText > xText( xAnnotation->getTextRange() );
+ sal_Int32 nLastIndex;
+ sal_Int32 nId = GetAuthorIdAndLastIndex ( xAnnotation->getAuthor(), nLastIndex );
+ char cDateTime[32];
+
+ snprintf(cDateTime, 31, "%02d-%02d-%02dT%02d:%02d:%02d.%03d", aDateTime.Year, aDateTime.Month, aDateTime.Day, aDateTime.Hours, aDateTime.Minutes, aDateTime.Seconds, aDateTime.HundredthSeconds);
+
+ pFS->startElementNS( XML_p, XML_cm,
+ XML_authorId, I32S( nId ),
+ XML_dt, cDateTime,
+ XML_idx, I32S( nLastIndex ),
+ FSEND );
+
+ pFS->singleElementNS( XML_p, XML_pos,
+ XML_x, I64S( ( (sal_Int64) ( 57600*aRealPoint2D.X + 1270 )/2540.0 ) ),
+ XML_y, I64S( ( (sal_Int64) ( 57600*aRealPoint2D.Y + 1270 )/2540.0 ) ),
+ FSEND );
+
+ pFS->startElementNS( XML_p, XML_text,
+ FSEND );
+ pFS->write( xText->getString() );
+ pFS->endElementNS( XML_p, XML_text );
+
+ pFS->endElementNS( XML_p, XML_cm );
+
+ } while ( xAnnotationEnumeration->hasMoreElements() );
+
+ pFS->endElementNS( XML_p, XML_cmLst );
+
+ return true;
+ }
+ }
+
+ return false;
+}
+
+void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNum, sal_uInt16 /* nMode */,
+ sal_Bool bHasBackground, Reference< XPropertySet > aXBackgroundPropSet )
+{
+ DBG(printf("write slide: %"SAL_PRIuUINT32"\n----------------\n", nPageNum));
+
+ // slides list
+ if( nPageNum == 0 )
+ mPresentationFS->startElementNS( XML_p, XML_sldIdLst, FSEND );
+
+ // add explicit relation of presentation to this slide
+ OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide" ),
+ OUStringBuffer()
+ .appendAscii( "slides/slide" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ mPresentationFS->singleElementNS( XML_p, XML_sldId,
+ XML_id, I32S( GetNewSlideId() ),
+ FSNS( XML_r, XML_id ), USS( sRelId ),
+ FSEND );
+
+ if( nPageNum == mnPages - 1 )
+ mPresentationFS->endElementNS( XML_p, XML_sldIdLst );
+
+ FSHelperPtr pFS = openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/slides/slide" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.slide+xml" ) );
+
+ if( mpSlidesFSArray.size() < mnPages )
+ mpSlidesFSArray.resize( mnPages );
+ mpSlidesFSArray[ nPageNum ] = pFS;
+
+ const char* pShow = NULL;
+
+ if( GETA( Visible ) ) {
+ sal_Bool bShow(sal_False);
+ if( ( mAny >>= bShow ) && !bShow )
+ pShow = "0";
+ }
+
+ pFS->startElementNS( XML_p, XML_sld, PNMSS,
+ XML_show, pShow,
+ FSEND );
+
+ pFS->startElementNS( XML_p, XML_cSld, FSEND );
+
+ // background
+ if( bHasBackground ) {
+ ImplWriteBackground( pFS, aXBackgroundPropSet );
+ }
+
+ WriteShapeTree( pFS, NORMAL, sal_False );
+
+ pFS->endElementNS( XML_p, XML_cSld );
+
+ WriteTransition( pFS );
+ WriteAnimations( pFS );
+
+ pFS->endElementNS( XML_p, XML_sld );
+
+ // add implicit relation to slide layout
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout" ),
+ OUStringBuffer()
+ .appendAscii( "../slideLayouts/slideLayout" )
+ .append( GetLayoutFileId( GetPPTXLayoutId( GetLayoutOffset( mXPagePropSet ) ), nMasterNum ) )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ if ( WriteComments( nPageNum ) )
+ // add implicit relation to slide comments
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" ),
+ OUStringBuffer()
+ .appendAscii( "../comments/comment" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ DBG(printf("----------------\n"));
+}
+
+void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
+{
+ if( !mbCreateNotes || !ContainsOtherShapeThanPlaceholders( sal_True ) )
+ return;
+
+ DBG(printf("write Notes %"SAL_PRIuUINT32"\n----------------\n", nPageNum));
+
+ FSHelperPtr pFS = openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/notesSlides/notesSlide" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.notesSlide+xml" ) );
+
+ pFS->startElementNS( XML_p, XML_notes, PNMSS, FSEND );
+
+ pFS->startElementNS( XML_p, XML_cSld, FSEND );
+
+ WriteShapeTree( pFS, NOTICE, sal_False );
+
+ pFS->endElementNS( XML_p, XML_cSld );
+
+ pFS->endElementNS( XML_p, XML_notes );
+
+ // add implicit relation to slide
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide" ),
+ OUStringBuffer()
+ .appendAscii( "../slides/slide" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ // add slide implicit relation to notes
+ if( mpSlidesFSArray.size() >= nPageNum )
+ addRelation( mpSlidesFSArray[ nPageNum ]->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide" ),
+ OUStringBuffer()
+ .appendAscii( "../notesSlides/notesSlide" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ // add implicit relation to notes master
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster" ),
+ US( "../notesMasters/notesMaster1.xml" ) );
+
+ DBG(printf("----------------\n"));
+}
+
+void PowerPointExport::AddLayoutIdAndRelation( FSHelperPtr pFS, sal_Int32 nLayoutFileId )
+{
+ // add implicit relation of slide master to slide layout
+ OUString sRelId = addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout" ),
+ OUStringBuffer()
+ .appendAscii( "../slideLayouts/slideLayout" )
+ .append( nLayoutFileId )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ pFS->singleElementNS( XML_p, XML_sldLayoutId,
+ XML_id, I64S( GetNewSlideMasterId() ),
+ FSNS( XML_r, XML_id ), USS( sRelId ),
+ FSEND );
+}
+
+sal_Int32 PowerPointExport::nStyleLevelToken[5] =
+{
+ XML_lvl1pPr,
+ XML_lvl2pPr,
+ XML_lvl3pPr,
+ XML_lvl4pPr,
+ XML_lvl5pPr
+};
+
+void PowerPointExport::WriteTextStyleLevel( FSHelperPtr pFS, int nInstance, int nLevel )
+{
+ OSL_ASSERT( nLevel >= 0 && nLevel < 5 );
+ OSL_ASSERT( nInstance >= 0 && nInstance < 9 );
+
+ PPTExParaLevel rParaLevel = mpStyleSheet->GetParaSheet( nInstance ).maParaLevel[ nLevel ];
+
+ pFS->startElementNS( XML_a, PowerPointExport::nStyleLevelToken[ nLevel ],
+ XML_algn, DrawingML::GetAlignment( rParaLevel.mnOOAdjust ),
+ FSEND );
+
+ pFS->endElementNS( XML_a, PowerPointExport::nStyleLevelToken[ nLevel ] );
+}
+
+void PowerPointExport::WriteTextStyle( FSHelperPtr pFS, int nInstance, sal_Int32 xmlToken )
+{
+ pFS->startElementNS( XML_p, xmlToken, FSEND );
+
+ for( int nLevel = 0; nLevel < 5; nLevel ++ )
+ WriteTextStyleLevel( pFS, nInstance, nLevel );
+
+ pFS->endElementNS( XML_p, xmlToken );
+}
+
+void PowerPointExport::WriteTextStyles( FSHelperPtr pFS )
+{
+ pFS->startElementNS( XML_p, XML_txBody, FSEND );
+
+ WriteTextStyle( pFS, EPP_TEXTTYPE_Title, XML_titleStyle );
+ WriteTextStyle( pFS, EPP_TEXTTYPE_Body, XML_bodyStyle );
+ WriteTextStyle( pFS, EPP_TEXTTYPE_Other, XML_otherStyle );
+
+ pFS->endElementNS( XML_p, XML_txBody );
+}
+
+void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPropertySet > aXBackgroundPropSet )
+{
+ DBG(printf("write slide master: %"SAL_PRIuUINT32"\n----------------\n", nPageNum));
+
+ // slides list
+ if( nPageNum == 0 )
+ mPresentationFS->startElementNS( XML_p, XML_sldMasterIdLst, FSEND );
+
+ OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster" ),
+ OUStringBuffer()
+ .appendAscii( "slideMasters/slideMaster" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ mPresentationFS->singleElementNS( XML_p, XML_sldMasterId,
+ XML_id, OString::valueOf( (sal_Int64) GetNewSlideMasterId() ).getStr(),
+ FSNS( XML_r, XML_id ), USS( sRelId ),
+ FSEND );
+
+ if( nPageNum == mnMasterPages - 1 )
+ mPresentationFS->endElementNS( XML_p, XML_sldMasterIdLst );
+
+ FSHelperPtr pFS =
+ openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/slideMasters/slideMaster" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.slideMaster+xml" ) );
+ if( mpMasterFSArray.size() < mnMasterPages )
+ mpMasterFSArray.resize( mnMasterPages );
+ mpMasterFSArray[ nPageNum ] = pFS;
+
+ // write theme per master
+ WriteTheme( nPageNum );
+
+ // add implicit relation to the presentation theme
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ),
+ OUStringBuffer()
+ .appendAscii( "../theme/theme" )
+ .append( (sal_Int32) nPageNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ pFS->startElementNS( XML_p, XML_sldMaster, PNMSS, FSEND );
+
+ pFS->startElementNS( XML_p, XML_cSld, FSEND );
+
+ ImplWriteBackground( pFS, aXBackgroundPropSet );
+ WriteShapeTree( pFS, LAYOUT, sal_True );
+
+ pFS->endElementNS( XML_p, XML_cSld );
+
+ // color map - now it uses colors from hardcoded theme, once we eventually generate theme, this might need update
+ pFS->singleElementNS( XML_p, XML_clrMap,
+ XML_bg1, "lt1",
+ XML_bg2, "lt2",
+ XML_tx1, "dk1",
+ XML_tx2, "dk2",
+ XML_accent1, "accent1",
+ XML_accent2, "accent2",
+ XML_accent3, "accent3",
+ XML_accent4, "accent4",
+ XML_accent5, "accent5",
+ XML_accent6, "accent6",
+ XML_hlink, "hlink",
+ XML_folHlink, "folHlink",
+ FSEND );
+
+ // use master's id type as they have same range, mso does that as well
+ pFS->startElementNS( XML_p, XML_sldLayoutIdLst, FSEND );
+
+ int nCount = 0;
+ for( int i = 0; i < LAYOUT_SIZE; i++) {
+ sal_Int32 nLayoutFileId = GetLayoutFileId( i, nPageNum );
+ if( nLayoutFileId > 0 ) {
+ AddLayoutIdAndRelation( pFS, nLayoutFileId );
+ nCount++;
+ } else {
+ ImplWritePPTXLayout( i, nPageNum );
+ AddLayoutIdAndRelation( pFS, GetLayoutFileId( i, nPageNum ) );
+ }
+ }
+
+ pFS->endElementNS( XML_p, XML_sldLayoutIdLst );
+
+ pFS->endElementNS( XML_p, XML_sldMaster );
+
+ DBG(printf("----------------\n"));
+}
+
+sal_Int32 PowerPointExport::GetLayoutFileId( sal_Int32 nOffset, sal_uInt32 nMasterNum )
+{
+ DBG(printf("GetLayoutFileId offset: %"SAL_PRIdINT32" master: %"SAL_PRIuUINT32"", nOffset, nMasterNum));
+ if( mLayoutInfo[ nOffset ].mnFileIdArray.size() <= nMasterNum )
+ return 0;
+
+ return mLayoutInfo[ nOffset ].mnFileIdArray[ nMasterNum ];
+}
+
+void PowerPointExport::ImplWriteLayout( sal_Int32 /*nOffset*/, sal_uInt32 /*nMasterNum*/ )
+{
+ // we write all the layouts together with master(s)
+ // ImplWritePPTXLayout( GetPPTXLayoutId( nOffset ), nMasterNum );
+}
+
+void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMasterNum )
+{
+ DBG(printf("write layout: %"SAL_PRIdINT32"\n", nOffset));
+
+ Reference< drawing::XDrawPagesSupplier > xDPS( getModel(), uno::UNO_QUERY );
+ Reference< drawing::XDrawPages > xDrawPages( xDPS->getDrawPages(), uno::UNO_QUERY );
+ Reference< drawing::XDrawPage > xSlide;
+ Reference< container::XIndexAccess > xIndexAccess( xDrawPages, uno::UNO_QUERY );
+
+ xSlide = xDrawPages->insertNewByIndex( xIndexAccess->getCount() );
+
+#ifdef DEBUG
+ if( xSlide.is() )
+ printf("new page created\n");
+#endif
+
+ Reference< beans::XPropertySet > xPropSet( xSlide, uno::UNO_QUERY );
+ xPropSet->setPropertyValue( US( "Layout" ), makeAny( short( aLayoutInfo[ nOffset ].nType ) ) );
+ DBG(dump_pset( xPropSet ));
+
+ mXPagePropSet = Reference< XPropertySet >( xSlide, UNO_QUERY );
+ mXShapes = Reference< XShapes >( xSlide, UNO_QUERY );
+
+ if( mLayoutInfo[ nOffset ].mnFileIdArray.size() < mnMasterPages ) {
+ mLayoutInfo[ nOffset ].mnFileIdArray.resize( mnMasterPages );
+ }
+
+ if( mLayoutInfo[ nOffset ].mnFileIdArray[ nMasterNum ] != 0 )
+ return;
+
+ FSHelperPtr pFS
+ = openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/slideLayouts/slideLayout" )
+ .append( (sal_Int32) mnLayoutFileIdMax )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml" ) );
+
+ // add implicit relation of slide layout to slide master
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster" ),
+ OUStringBuffer()
+ .appendAscii( "../slideMasters/slideMaster" )
+ .append( (sal_Int32) nMasterNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ pFS->startElementNS( XML_p, XML_sldLayout,
+ PNMSS,
+ XML_type, aLayoutInfo[ nOffset ].sType,
+ XML_preserve, "1",
+ FSEND );
+
+ pFS->startElementNS( XML_p, XML_cSld,
+ XML_name, aLayoutInfo[ nOffset ].sName,
+ FSEND );
+ //pFS->write( MINIMAL_SPTREE ); // TODO: write actual shape tree
+ WriteShapeTree( pFS, LAYOUT, sal_True );
+
+ pFS->endElementNS( XML_p, XML_cSld );
+
+ pFS->endElementNS( XML_p, XML_sldLayout );
+
+ mLayoutInfo[ nOffset ].mnFileIdArray[ nMasterNum ] = mnLayoutFileIdMax;
+
+ mnLayoutFileIdMax ++;
+
+ xDrawPages->remove( xSlide );
+}
+
+void PowerPointExport::WriteShapeTree( FSHelperPtr pFS, PageType ePageType, sal_Bool bMaster )
+{
+ PowerPointShapeExport aDML( pFS, &maShapeMap, this );
+ aDML.SetMaster( bMaster );
+ aDML.SetPageType( ePageType );
+ sal_uInt32 nShapes;
+
+ pFS->startElementNS( XML_p, XML_spTree, FSEND );
+ pFS->write( MAIN_GROUP );
+
+ ResetGroupTable( nShapes = mXShapes->getCount() );
+
+ while( GetNextGroupEntry() ) {
+
+ sal_uInt32 nGroups = GetGroupsClosed();
+ for ( sal_uInt32 i = 0; i < nGroups; i++ ) {
+ DBG(printf( "leave group\n" ));
+ }
+
+ if ( GetShapeByIndex( GetCurrentGroupIndex(), sal_True ) ) {
+ DBG(printf( "mType: \"%s\"\n", mType.GetBuffer() ));
+ aDML.WriteShape( mXShape );
+ }
+ }
+
+ pFS->endElementNS( XML_p, XML_spTree );
+}
+
+#define BEGIN_SHAPE mpFS->startElementNS( XML_p, XML_sp, FSEND )
+#define END_SHAPE mpFS->endElementNS( XML_p, XML_sp )
+
+ShapeExport& PowerPointShapeExport::WritePageShape( Reference< XShape > xShape, PageType ePageType, sal_Bool bPresObj )
+{
+ if( ( ePageType == NOTICE && bPresObj ) || ePageType == LAYOUT )
+ return WritePlaceholderShape( xShape, SlideImage );
+
+ return WriteTextShape( xShape );
+}
+
+sal_Bool PowerPointShapeExport::WritePlaceholder( Reference< XShape > xShape, PlaceholderType ePlaceholder, sal_Bool bMaster )
+{
+ DBG(printf("WritePlaceholder %d %d\n", bMaster, ShapeExport::NonEmptyText( xShape )));
+ if( bMaster && ShapeExport::NonEmptyText( xShape ) ) {
+ WritePlaceholderShape( xShape, ePlaceholder );
+
+ return sal_True;
+ }
+
+ return sal_False;
+}
+
+ShapeExport& PowerPointShapeExport::WritePlaceholderShape( Reference< XShape > xShape, PlaceholderType ePlaceholder )
+{
+ BEGIN_SHAPE;
+
+ // non visual shape properties
+ mpFS->startElementNS( XML_p, XML_nvSpPr, FSEND );
+ WriteNonVisualDrawingProperties( xShape, IDS( PlaceHolder ) );
+ mpFS->startElementNS( XML_p, XML_cNvSpPr, FSEND );
+ mpFS->singleElementNS( XML_a, XML_spLocks, XML_noGrp, "1", FSEND );
+ mpFS->endElementNS( XML_p, XML_cNvSpPr );
+ mpFS->startElementNS( XML_p, XML_nvPr, FSEND );
+
+ const char* pType = NULL;
+ switch( ePlaceholder ) {
+ case SlideImage:
+ pType = "sldImg";
+ break;
+ case Notes:
+ pType = "body";
+ break;
+ case Header:
+ pType = "hdr";
+ break;
+ case Footer:
+ pType = "ftr";
+ break;
+ case SlideNumber:
+ pType = "sldNum";
+ break;
+ case DateAndTime:
+ pType = "dt";
+ break;
+ case Outliner:
+ pType = "body";
+ break;
+ case Title:
+ pType = "title";
+ break;
+ case Subtitle:
+ pType = "subTitle";
+ break;
+ default:
+ DBG(printf("warning: unhandled placeholder type: %d\n", ePlaceholder));
+ }
+ DBG(printf("write placeholder %s\n", pType));
+ mpFS->singleElementNS( XML_p, XML_ph, XML_type, pType, FSEND );
+ mpFS->endElementNS( XML_p, XML_nvPr );
+ mpFS->endElementNS( XML_p, XML_nvSpPr );
+
+ // visual shape properties
+ mpFS->startElementNS( XML_p, XML_spPr, FSEND );
+ WriteShapeTransformation( xShape, XML_a );
+ WritePresetShape( "rect" );
+ Reference< XPropertySet > xProps( xShape, UNO_QUERY );
+ if( xProps.is() )
+ WriteBlipFill( xProps, S( "GraphicURL" ) );
+ mpFS->endElementNS( XML_p, XML_spPr );
+
+ WriteTextBox( xShape, XML_p );
+
+ END_SHAPE;
+
+ return *this;
+}
+
+#define MINIMAL_THEME " <a:themeElements>\
+ <a:clrScheme name=\"Office\">\
+ <a:dk1>\
+ <a:sysClr val=\"windowText\" lastClr=\"000000\"/>\
+ </a:dk1>\
+ <a:lt1>\
+ <a:sysClr val=\"window\" lastClr=\"FFFFFF\"/>\
+ </a:lt1>\
+ <a:dk2>\
+ <a:srgbClr val=\"1F497D\"/>\
+ </a:dk2>\
+ <a:lt2>\
+ <a:srgbClr val=\"EEECE1\"/>\
+ </a:lt2>\
+ <a:accent1>\
+ <a:srgbClr val=\"4F81BD\"/>\
+ </a:accent1>\
+ <a:accent2>\
+ <a:srgbClr val=\"C0504D\"/>\
+ </a:accent2>\
+ <a:accent3>\
+ <a:srgbClr val=\"9BBB59\"/>\
+ </a:accent3>\
+ <a:accent4>\
+ <a:srgbClr val=\"8064A2\"/>\
+ </a:accent4>\
+ <a:accent5>\
+ <a:srgbClr val=\"4BACC6\"/>\
+ </a:accent5>\
+ <a:accent6>\
+ <a:srgbClr val=\"F79646\"/>\
+ </a:accent6>\
+ <a:hlink>\
+ <a:srgbClr val=\"0000FF\"/>\
+ </a:hlink>\
+ <a:folHlink>\
+ <a:srgbClr val=\"800080\"/>\
+ </a:folHlink>\
+ </a:clrScheme>\
+ <a:fontScheme name=\"Office\">\
+ <a:majorFont>\
+ <a:latin typeface=\"Arial\"/>\
+ <a:ea typeface=\"DejaVu Sans\"/>\
+ <a:cs typeface=\"DejaVu Sans\"/>\
+ </a:majorFont>\
+ <a:minorFont>\
+ <a:latin typeface=\"Arial\"/>\
+ <a:ea typeface=\"DejaVu Sans\"/>\
+ <a:cs typeface=\"DejaVu Sans\"/>\
+ </a:minorFont>\
+ </a:fontScheme>\
+ <a:fmtScheme name=\"Office\">\
+ <a:fillStyleLst>\
+ <a:solidFill>\
+ <a:schemeClr val=\"phClr\"/>\
+ </a:solidFill>\
+ <a:gradFill rotWithShape=\"1\">\
+ <a:gsLst>\
+ <a:gs pos=\"0\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"50000\"/>\
+ <a:satMod val=\"300000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"35000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"37000\"/>\
+ <a:satMod val=\"300000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"100000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"15000\"/>\
+ <a:satMod val=\"350000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ </a:gsLst>\
+ <a:lin ang=\"16200000\" scaled=\"1\"/>\
+ </a:gradFill>\
+ <a:gradFill rotWithShape=\"1\">\
+ <a:gsLst>\
+ <a:gs pos=\"0\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"51000\"/>\
+ <a:satMod val=\"130000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"80000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"93000\"/>\
+ <a:satMod val=\"130000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"100000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"94000\"/>\
+ <a:satMod val=\"135000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ </a:gsLst>\
+ <a:lin ang=\"16200000\" scaled=\"0\"/>\
+ </a:gradFill>\
+ </a:fillStyleLst>\
+ <a:lnStyleLst>\
+ <a:ln w=\"9525\" cap=\"flat\" cmpd=\"sng\" algn=\"ctr\">\
+ <a:solidFill>\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"95000\"/>\
+ <a:satMod val=\"105000\"/>\
+ </a:schemeClr>\
+ </a:solidFill>\
+ <a:prstDash val=\"solid\"/>\
+ </a:ln>\
+ <a:ln w=\"25400\" cap=\"flat\" cmpd=\"sng\" algn=\"ctr\">\
+ <a:solidFill>\
+ <a:schemeClr val=\"phClr\"/>\
+ </a:solidFill>\
+ <a:prstDash val=\"solid\"/>\
+ </a:ln>\
+ <a:ln w=\"38100\" cap=\"flat\" cmpd=\"sng\" algn=\"ctr\">\
+ <a:solidFill>\
+ <a:schemeClr val=\"phClr\"/>\
+ </a:solidFill>\
+ <a:prstDash val=\"solid\"/>\
+ </a:ln>\
+ </a:lnStyleLst>\
+ <a:effectStyleLst>\
+ <a:effectStyle>\
+ <a:effectLst>\
+ <a:outerShdw blurRad=\"40000\" dist=\"20000\" dir=\"5400000\" rotWithShape=\"0\">\
+ <a:srgbClr val=\"000000\">\
+ <a:alpha val=\"38000\"/>\
+ </a:srgbClr>\
+ </a:outerShdw>\
+ </a:effectLst>\
+ </a:effectStyle>\
+ <a:effectStyle>\
+ <a:effectLst>\
+ <a:outerShdw blurRad=\"40000\" dist=\"23000\" dir=\"5400000\" rotWithShape=\"0\">\
+ <a:srgbClr val=\"000000\">\
+ <a:alpha val=\"35000\"/>\
+ </a:srgbClr>\
+ </a:outerShdw>\
+ </a:effectLst>\
+ </a:effectStyle>\
+ <a:effectStyle>\
+ <a:effectLst>\
+ <a:outerShdw blurRad=\"40000\" dist=\"23000\" dir=\"5400000\" rotWithShape=\"0\">\
+ <a:srgbClr val=\"000000\">\
+ <a:alpha val=\"35000\"/>\
+ </a:srgbClr>\
+ </a:outerShdw>\
+ </a:effectLst>\
+ <a:scene3d>\
+ <a:camera prst=\"orthographicFront\">\
+ <a:rot lat=\"0\" lon=\"0\" rev=\"0\"/>\
+ </a:camera>\
+ <a:lightRig rig=\"threePt\" dir=\"t\">\
+ <a:rot lat=\"0\" lon=\"0\" rev=\"1200000\"/>\
+ </a:lightRig>\
+ </a:scene3d>\
+ <a:sp3d>\
+ <a:bevelT w=\"63500\" h=\"25400\"/>\
+ </a:sp3d>\
+ </a:effectStyle>\
+ </a:effectStyleLst>\
+ <a:bgFillStyleLst>\
+ <a:solidFill>\
+ <a:schemeClr val=\"phClr\"/>\
+ </a:solidFill>\
+ <a:gradFill rotWithShape=\"1\">\
+ <a:gsLst>\
+ <a:gs pos=\"0\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"40000\"/>\
+ <a:satMod val=\"350000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"40000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"45000\"/>\
+ <a:shade val=\"99000\"/>\
+ <a:satMod val=\"350000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"100000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"20000\"/>\
+ <a:satMod val=\"255000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ </a:gsLst>\
+ <a:path path=\"circle\">\
+ <a:fillToRect l=\"50000\" t=\"-80000\" r=\"50000\" b=\"180000\"/>\
+ </a:path>\
+ </a:gradFill>\
+ <a:gradFill rotWithShape=\"1\">\
+ <a:gsLst>\
+ <a:gs pos=\"0\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:tint val=\"80000\"/>\
+ <a:satMod val=\"300000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ <a:gs pos=\"100000\">\
+ <a:schemeClr val=\"phClr\">\
+ <a:shade val=\"30000\"/>\
+ <a:satMod val=\"200000\"/>\
+ </a:schemeClr>\
+ </a:gs>\
+ </a:gsLst>\
+ <a:path path=\"circle\">\
+ <a:fillToRect l=\"50000\" t=\"50000\" r=\"50000\" b=\"50000\"/>\
+ </a:path>\
+ </a:gradFill>\
+ </a:bgFillStyleLst>\
+ </a:fmtScheme>\
+ </a:themeElements>"
+
+void PowerPointExport::WriteTheme( sal_Int32 nThemeNum )
+{
+ FSHelperPtr pFS = openFragmentStreamWithSerializer( OUStringBuffer()
+ .appendAscii( "ppt/theme/theme" )
+ .append( (sal_Int32) nThemeNum + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear(),
+ US( "application/vnd.openxmlformats-officedocument.theme+xml" ) );
+
+ pFS->startElementNS( XML_a, XML_theme,
+ FSNS( XML_xmlns, XML_a), "http://schemas.openxmlformats.org/drawingml/2006/main",
+ XML_name, "Office Theme",
+ FSEND );
+
+ pFS->write( MINIMAL_THEME );
+ pFS->endElementNS( XML_a, XML_theme );
+}
+
+sal_Bool PowerPointExport::ImplCreateDocument()
+{
+ mbCreateNotes = sal_False;
+
+ for( sal_uInt32 i = 0; i < mnPages; i++ )
+ {
+ if ( !GetPageByIndex( i, NOTICE ) )
+ return sal_False;
+
+ if( ContainsOtherShapeThanPlaceholders( sal_True ) ) {
+ mbCreateNotes = sal_True;
+ break;
+ }
+ }
+
+ return sal_True;
+}
+
+sal_Bool PowerPointExport::WriteNotesMaster()
+{
+ DBG(printf("write Notes master\n----------------\n"));
+
+ mPresentationFS->startElementNS( XML_p, XML_notesMasterIdLst, FSEND );
+
+ OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster" ),
+ US( "notesMasters/notesMaster1.xml" ) );
+
+ mPresentationFS->singleElementNS( XML_p, XML_notesMasterId,
+ FSNS( XML_r, XML_id ), USS( sRelId ),
+ FSEND );
+
+ mPresentationFS->endElementNS( XML_p, XML_notesMasterIdLst );
+
+ FSHelperPtr pFS =
+ openFragmentStreamWithSerializer( US( "ppt/notesMasters/notesMaster1.xml" ),
+ US( "application/vnd.openxmlformats-officedocument.presentationml.notesMaster+xml" ) );
+ // write theme per master
+ WriteTheme( mnMasterPages );
+
+ // add implicit relation to the presentation theme
+ addRelation( pFS->getOutputStream(),
+ US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ),
+ OUStringBuffer()
+ .appendAscii( "../theme/theme" )
+ .append( (sal_Int32) mnMasterPages + 1 )
+ .appendAscii( ".xml" )
+ .makeStringAndClear() );
+
+ pFS->startElementNS( XML_p, XML_notesMaster, PNMSS, FSEND );
+
+ pFS->startElementNS( XML_p, XML_cSld, FSEND );
+
+ Reference< XPropertySet > aXBackgroundPropSet;
+ if( ImplGetPropertyValue( mXPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Background" ) ) ) &&
+ ( mAny >>= aXBackgroundPropSet ) )
+ ImplWriteBackground( pFS, aXBackgroundPropSet );
+
+ WriteShapeTree( pFS, NOTICE, sal_True );
+
+ pFS->endElementNS( XML_p, XML_cSld );
+
+ // color map - now it uses colors from hardcoded theme, once we eventually generate theme, this might need update
+ pFS->singleElementNS( XML_p, XML_clrMap,
+ XML_bg1, "lt1",
+ XML_bg2, "lt2",
+ XML_tx1, "dk1",
+ XML_tx2, "dk2",
+ XML_accent1, "accent1",
+ XML_accent2, "accent2",
+ XML_accent3, "accent3",
+ XML_accent4, "accent4",
+ XML_accent5, "accent5",
+ XML_accent6, "accent6",
+ XML_hlink, "hlink",
+ XML_folHlink, "folHlink",
+ FSEND );
+
+ pFS->endElementNS( XML_p, XML_notesMaster );
+
+ DBG(printf("----------------\n"));
+
+ return sal_True;
+}
+
+sal_Bool PowerPointExport::ImplCreateMainNotes()
+{
+ if( mbCreateNotes )
+ return WriteNotesMaster();
+
+ return sal_True;
+}
+
+#define IMPL_NAME "com.sun.star.comp.Impress.oox.PowerPointExport"
+
+OUString SAL_CALL PowerPointExport_getImplementationName() throw()
+{
+ return CREATE_OUSTRING( IMPL_NAME );
+}
+
+uno::Sequence< OUString > SAL_CALL PowerPointExport_getSupportedServiceNames() throw()
+{
+ const OUString aServiceName = CREATE_OUSTRING( "com.sun.star.comp.ooxpptx" );
+ const Sequence< OUString > aSeq( &aServiceName, 1 );
+ return aSeq;
+}
+
+uno::Reference< uno::XInterface > SAL_CALL PowerPointExport_createInstance(const uno::Reference< XComponentContext > & rxCtxt ) throw( uno::Exception )
+{
+ return (cppu::OWeakObject*)new PowerPointExport( rxCtxt );
+}
+
+OUString PowerPointExport::implGetImplementationName() const
+{
+ return PowerPointExport_getImplementationName();
+}
+}
+}
+
+// UNO component
+// ------------------------------------------
+// - component_getImplementationEnvironment -
+// ------------------------------------------
+
+static struct cppu::ImplementationEntry g_entries[] =
+{
+ {
+ oox::core::PowerPointExport_createInstance,
+ oox::core::PowerPointExport_getImplementationName,
+ oox::core::PowerPointExport_getSupportedServiceNames,
+ cppu::createSingleComponentFactory,
+ 0 , 0
+ },
+ { 0, 0, 0, 0, 0, 0 }
+};
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /* ppEnv */ )
+{
+ *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
+}
+
+// ------------------------
+// - component_getFactory -
+// ------------------------
+
+SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( const sal_Char* pImplName, void* pServiceManager, void* pRegistryKey )
+{
+ return cppu::component_getFactoryHelper( pImplName, pServiceManager, pRegistryKey , g_entries );
+}
+
+#ifdef __cplusplus
+}
+#endif
+
+DBG(
+void dump_pset(Reference< XPropertySet > rXPropSet)
+{
+ Reference< XPropertySetInfo > info = rXPropSet->getPropertySetInfo ();
+ Sequence< beans::Property > props = info->getProperties ();
+
+ for (int i=0; i < props.getLength (); i++) {
+ OString name = OUStringToOString( props [i].Name, RTL_TEXTENCODING_UTF8);
+ printf ("%30s = ", name.getStr() );
+
+ Any value = rXPropSet->getPropertyValue( props [i].Name );
+
+ OUString strValue;
+ sal_Int32 intValue;
+ bool boolValue;
+ RectanglePoint pointValue;
+
+ if( value >>= strValue )
+ printf ("\"%s\"\n", USS( strValue ) );
+ else if( value >>= intValue )
+ printf ("%"SAL_PRIdINT32" (hex: %"SAL_PRIxUINT32")\n", intValue, intValue);
+ else if( value >>= boolValue )
+ printf ("%d (bool)\n", boolValue);
+ else if( value >>= pointValue )
+ printf ("%d (RectanglePoint)\n", pointValue);
+ else
+ printf ("??? <unhandled type>\n");
+ }
+}
+);
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptx-grouptable.cxx b/sd/source/filter/eppt/pptx-grouptable.cxx
new file mode 100644
index 000000000..fed63ac7b
--- /dev/null
+++ b/sd/source/filter/eppt/pptx-grouptable.cxx
@@ -0,0 +1,142 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include "grouptable.hxx"
+
+using ::com::sun::star::uno::Reference;
+using ::com::sun::star::container::XIndexAccess;
+
+GroupTable::GroupTable() :
+ mnCurrentGroupEntry ( 0 ),
+ mnMaxGroupEntry ( 0 ),
+ mnGroupsClosed ( 0 ),
+ mpGroupEntry ( NULL )
+{
+ ImplResizeGroupTable( 32 );
+}
+
+// ---------------------------------------------------------------------------------------------
+
+GroupTable::~GroupTable()
+{
+ for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; delete mpGroupEntry[ i++ ] ) ;
+ delete[] mpGroupEntry;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void GroupTable::ImplResizeGroupTable( sal_uInt32 nEntrys )
+{
+ if ( nEntrys > mnMaxGroupEntry )
+ {
+ mnMaxGroupEntry = nEntrys;
+ GroupEntry** pTemp = new GroupEntry*[ nEntrys ];
+ for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; i++ )
+ pTemp[ i ] = mpGroupEntry[ i ];
+ if ( mpGroupEntry )
+ delete[] mpGroupEntry;
+ mpGroupEntry = pTemp;
+ }
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool GroupTable::EnterGroup( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >& rXIndexAccessRef )
+{
+ sal_Bool bRet = sal_False;
+ if ( rXIndexAccessRef.is() )
+ {
+ GroupEntry* pNewGroup = new GroupEntry( rXIndexAccessRef );
+ if ( pNewGroup->mnCount )
+ {
+ if ( mnMaxGroupEntry == mnCurrentGroupEntry )
+ ImplResizeGroupTable( mnMaxGroupEntry + 8 );
+ mpGroupEntry[ mnCurrentGroupEntry++ ] = pNewGroup;
+ bRet = sal_True;
+ }
+ else
+ delete pNewGroup;
+ }
+ return bRet;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_uInt32 GroupTable::GetGroupsClosed()
+{
+ sal_uInt32 nRet = mnGroupsClosed;
+ mnGroupsClosed = 0;
+ return nRet;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void GroupTable::ClearGroupTable()
+{
+ for ( sal_uInt32 i = 0; i < mnCurrentGroupEntry; i++, delete mpGroupEntry[ i ] ) ;
+ mnCurrentGroupEntry = 0;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void GroupTable::ResetGroupTable( sal_uInt32 nCount )
+{
+ ClearGroupTable();
+ mpGroupEntry[ mnCurrentGroupEntry++ ] = new GroupEntry( nCount );
+}
+
+// ---------------------------------------------------------------------------------------------
+
+sal_Bool GroupTable::GetNextGroupEntry()
+{
+ while ( mnCurrentGroupEntry )
+ {
+ mnIndex = mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mnCurrentPos++;
+
+ if ( mpGroupEntry[ mnCurrentGroupEntry - 1 ]->mnCount > mnIndex )
+ return sal_True;
+
+ delete ( mpGroupEntry[ --mnCurrentGroupEntry ] );
+
+ if ( mnCurrentGroupEntry )
+ mnGroupsClosed++;
+ }
+ return sal_False;
+}
+
+// ---------------------------------------------------------------------------------------------
+
+void GroupTable::SkipCurrentGroup()
+{
+ if ( mnCurrentGroupEntry )
+ delete ( mpGroupEntry[ --mnCurrentGroupEntry ] );
+}
+
+// ---------------------------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptx-stylesheet.cxx b/sd/source/filter/eppt/pptx-stylesheet.cxx
new file mode 100644
index 000000000..e2878054d
--- /dev/null
+++ b/sd/source/filter/eppt/pptx-stylesheet.cxx
@@ -0,0 +1,509 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <epptbase.hxx>
+#include <epptdef.hxx>
+#include <text.hxx>
+#include <tools/color.hxx>
+#include <editeng/svxenum.hxx>
+
+using namespace ::com::sun::star;
+
+PPTExCharSheet::PPTExCharSheet( int nInstance )
+{
+ sal_uInt16 nFontHeight = 24;
+
+ for ( int nDepth = 0; nDepth < 5; nDepth++ )
+ {
+ PPTExCharLevel& rLev = maCharLevel[ nDepth ];
+ switch ( nInstance )
+ {
+ case EPP_TEXTTYPE_Title :
+ case EPP_TEXTTYPE_CenterTitle :
+ nFontHeight = 44;
+ break;
+ case EPP_TEXTTYPE_Body :
+ case EPP_TEXTTYPE_CenterBody :
+ case EPP_TEXTTYPE_HalfBody :
+ case EPP_TEXTTYPE_QuarterBody :
+ {
+ switch ( nDepth )
+ {
+ case 0 : nFontHeight = 32; break;
+ case 1 : nFontHeight = 28; break;
+ case 2 : nFontHeight = 24; break;
+ default :nFontHeight = 20; break;
+ }
+ }
+ break;
+ case EPP_TEXTTYPE_Notes :
+ nFontHeight = 12;
+ break;
+ case EPP_TEXTTYPE_notUsed :
+ case EPP_TEXTTYPE_Other :
+ nFontHeight = 24;
+ break;
+ }
+ rLev.mnFlags = 0;
+ rLev.mnFont = 0;
+ rLev.mnAsianOrComplexFont = 0xffff;
+ rLev.mnFontHeight = nFontHeight;
+ rLev.mnFontColor = 0;
+ rLev.mnEscapement = 0;
+ }
+}
+
+
+void PPTExCharSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
+ FontCollection& rFontCollection, int nLevel )
+{
+ PortionObj aPortionObj( rXPropSet, rFontCollection );
+
+ PPTExCharLevel& rLev = maCharLevel[ nLevel ];
+
+ if ( aPortionObj.meCharColor == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnFontColor = aPortionObj.mnCharColor;
+ if ( aPortionObj.meCharEscapement == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnEscapement = aPortionObj.mnCharEscapement;
+ if ( aPortionObj.meCharHeight == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnFontHeight = aPortionObj.mnCharHeight;
+ if ( aPortionObj.meFontName == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnFont = aPortionObj.mnFont;
+ if ( aPortionObj.meAsianOrComplexFont == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnAsianOrComplexFont = aPortionObj.mnAsianOrComplexFont;
+ rLev.mnFlags = aPortionObj.mnCharAttr;
+}
+
+void PPTExCharSheet::Write( SvStream& rSt, PptEscherEx*, sal_uInt16 nLev, sal_Bool, sal_Bool bSimpleText,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet )
+{
+ const PPTExCharLevel& rLev = maCharLevel[ nLev ];
+
+ sal_uInt32 nCharFlags = 0xefffff;
+ if ( bSimpleText )
+ nCharFlags = 0x7ffff;
+
+ rSt << nCharFlags
+ << rLev.mnFlags
+ << rLev.mnFont;
+
+ sal_uInt32 nFontColor = rLev.mnFontColor;
+ if ( nFontColor == COL_AUTO )
+ {
+ sal_Bool bIsDark = sal_False;
+ ::com::sun::star::uno::Any aAny;
+ if ( PropValue::GetPropertyValue( aAny, rPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundDark" ) ), sal_True ) )
+ aAny >>= bIsDark;
+ nFontColor = bIsDark ? 0xffffff : 0x000000;
+ }
+ nFontColor &= 0xffffff;
+ nFontColor |= 0xfe000000;
+ if ( bSimpleText )
+ {
+ rSt << rLev.mnFontHeight
+ << nFontColor;
+ }
+ else
+ {
+ rSt << rLev.mnAsianOrComplexFont
+ << (sal_uInt16)0xffff // unbekannt
+ << (sal_uInt16)0xffff // unbekannt
+ << rLev.mnFontHeight
+ << nFontColor
+ << rLev.mnEscapement;
+ }
+}
+
+PPTExParaSheet::PPTExParaSheet( int nInstance, sal_uInt16 nDefaultTab, PPTExBulletProvider& rProv ) :
+ rBuProv ( rProv ),
+ mnInstance ( nInstance )
+{
+ sal_Bool bHasBullet = sal_False;
+
+ sal_uInt16 nUpperDist = 0;
+ sal_uInt16 nBulletChar = 0x2022;
+ sal_uInt16 nBulletOfs = 0;
+ sal_uInt16 nTextOfs = 0;
+
+ for ( int nDepth = 0; nDepth < 5; nDepth++ )
+ {
+ PPTExParaLevel& rLev = maParaLevel[ nDepth ];
+ switch ( nInstance )
+ {
+ case EPP_TEXTTYPE_Title :
+ case EPP_TEXTTYPE_CenterTitle :
+ break;
+ case EPP_TEXTTYPE_Body :
+ case EPP_TEXTTYPE_CenterBody :
+ case EPP_TEXTTYPE_HalfBody :
+ case EPP_TEXTTYPE_QuarterBody :
+ {
+ bHasBullet = sal_True;
+ nUpperDist = 0x14;
+ }
+ break;
+ case EPP_TEXTTYPE_Notes :
+ nUpperDist = 0x1e;
+ break;
+
+ }
+ switch ( nDepth )
+ {
+ case 0 :
+ {
+ nBulletChar = 0x2022;
+ nBulletOfs = 0;
+ nTextOfs = ( bHasBullet ) ? 0xd8 : 0;
+ }
+ break;
+ case 1 :
+ {
+ nBulletChar = 0x2013;
+ nBulletOfs = 0x120;
+ nTextOfs = 0x1d4;
+ }
+ break;
+ case 2 :
+ {
+ nBulletChar = 0x2022;
+ nBulletOfs = 0x240;
+ nTextOfs = 0x2d0;
+ }
+ break;
+ case 3 :
+ {
+ nBulletChar = 0x2013;
+ nBulletOfs = 0x360;
+ nTextOfs = 0x3f0;
+ }
+ break;
+ case 4 :
+ {
+ nBulletChar = 0xbb;
+ nBulletOfs = 0x480;
+ nTextOfs = 0x510;
+ }
+ break;
+ }
+ rLev.mbIsBullet = bHasBullet;
+ rLev.mnBulletChar = nBulletChar;
+ rLev.mnBulletFont = 0;
+ rLev.mnBulletHeight = 100;
+ rLev.mnBulletColor = 0;
+ rLev.mnAdjust = 0;
+ rLev.mnLineFeed = 100;
+ rLev.mnLowerDist = 0;
+ rLev.mnUpperDist = nUpperDist;
+ rLev.mnTextOfs = nTextOfs;
+ rLev.mnBulletOfs = nBulletOfs;
+ rLev.mnDefaultTab = nDefaultTab;
+ rLev.mnAsianSettings = 2;
+ rLev.mnBiDi = 0;
+
+ rLev.mbExtendedBulletsUsed = sal_False;
+ rLev.mnBulletId = 0xffff;
+ rLev.mnBulletStart = 0;
+ rLev.mnMappedNumType = 0;
+ rLev.mnNumberingType = 0;
+ }
+}
+
+void PPTExParaSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
+ FontCollection& rFontCollection, int nLevel, const PPTExCharLevel& rCharLevel )
+{
+ ParagraphObj aParagraphObj( rXPropSet, rBuProv );
+ aParagraphObj.CalculateGraphicBulletSize( rCharLevel.mnFontHeight );
+ PPTExParaLevel& rLev = maParaLevel[ nLevel ];
+
+ if ( aParagraphObj.meTextAdjust == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnAdjust = aParagraphObj.mnTextAdjust;
+ if ( aParagraphObj.meLineSpacing == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ {
+ sal_Int16 nLineSpacing = aParagraphObj.mnLineSpacing;
+ if ( nLineSpacing > 0 ) // if nLinespacing is < 0 the linespacing is an absolute spacing
+ {
+ sal_Bool bFixedLineSpacing = sal_False;
+ uno::Any aAny = rXPropSet->getPropertyValue( ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "FontIndependentLineSpacing" ) ) );
+ if( !(aAny >>= bFixedLineSpacing) || !bFixedLineSpacing )
+ {
+ const FontCollectionEntry* pDesc = rFontCollection.GetById( rCharLevel.mnFont );
+ if ( pDesc )
+ nLineSpacing = (sal_Int16)( (double)nLineSpacing * pDesc->Scaling + 0.5 );
+ }
+ }
+ else
+ {
+ if ( rCharLevel.mnFontHeight > (sal_uInt16)( ((double)-nLineSpacing) * 0.001 * 72.0 / 2.54 ) ) // 1/100mm to point
+ {
+ const FontCollectionEntry* pDesc = rFontCollection.GetById( rCharLevel.mnFont );
+ if ( pDesc )
+ nLineSpacing = (sal_Int16)( (double)100.0 * pDesc->Scaling + 0.5 );
+ else
+ nLineSpacing = 100;
+ }
+ else
+ nLineSpacing = (sal_Int16)( (double)nLineSpacing / 4.40972 );
+ }
+ rLev.mnLineFeed = nLineSpacing;
+ }
+ if ( aParagraphObj.meLineSpacingBottom == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnLowerDist = aParagraphObj.mnLineSpacingBottom;
+ if ( aParagraphObj.meLineSpacingTop == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnUpperDist = aParagraphObj.mnLineSpacingTop;
+ if ( aParagraphObj.meForbiddenRules == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ {
+ rLev.mnAsianSettings &=~1;
+ if ( aParagraphObj.mbForbiddenRules )
+ rLev.mnAsianSettings |= 1;
+ }
+ if ( aParagraphObj.meParagraphPunctation == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ {
+ rLev.mnAsianSettings &=~4;
+ if ( aParagraphObj.mbParagraphPunctation )
+ rLev.mnAsianSettings |= 4;
+ }
+
+ if ( aParagraphObj.meBiDi == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ rLev.mnBiDi = aParagraphObj.mnBiDi;
+
+ rLev.mbIsBullet = aParagraphObj.mbIsBullet; //( ( aParagraphObj.nBulletFlags & 1 ) != 0 );
+
+ if ( !nLevel )
+ {
+ if ( ( aParagraphObj.meBullet == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ && aParagraphObj.bExtendedParameters )
+ {
+ for ( sal_Int16 i = 0; i < 5; i++ )
+ {
+ PPTExParaLevel& rLevel = maParaLevel[ i ];
+ if ( i )
+ aParagraphObj.ImplGetNumberingLevel( rBuProv, i, sal_False );
+ rLevel.mnTextOfs = aParagraphObj.nTextOfs;
+ rLevel.mnBulletOfs = (sal_uInt16)aParagraphObj.nBulletOfs;
+ rLevel.mnBulletChar = aParagraphObj.cBulletId;
+ FontCollectionEntry aFontDescEntry( aParagraphObj.aFontDesc.Name, aParagraphObj.aFontDesc.Family,
+ aParagraphObj.aFontDesc.Pitch, aParagraphObj.aFontDesc.CharSet );
+ rLevel.mnBulletFont = (sal_uInt16)rFontCollection.GetId( aFontDescEntry );
+ rLevel.mnBulletHeight = aParagraphObj.nBulletRealSize;
+ rLevel.mnBulletColor = aParagraphObj.nBulletColor;
+
+ rLevel.mbExtendedBulletsUsed = aParagraphObj.bExtendedBulletsUsed;
+ rLevel.mnBulletId = aParagraphObj.nBulletId;
+ rLevel.mnNumberingType = aParagraphObj.nNumberingType;
+ rLevel.mnBulletStart = aParagraphObj.nStartWith;
+ rLevel.mnMappedNumType = aParagraphObj.nMappedNumType;
+ }
+ }
+ }
+}
+
+void PPTExParaSheet::Write( SvStream& rSt, PptEscherEx*, sal_uInt16 nLev, sal_Bool, sal_Bool bSimpleText,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rPagePropSet )
+{
+ const PPTExParaLevel& rLev = maParaLevel[ nLev ];
+
+ if ( maParaLevel[ 0 ].mbExtendedBulletsUsed || maParaLevel[ 1 ].mbExtendedBulletsUsed ||
+ maParaLevel[ 2 ].mbExtendedBulletsUsed || maParaLevel[ 3 ].mbExtendedBulletsUsed ||
+ maParaLevel[ 4 ].mbExtendedBulletsUsed )
+ {
+ SvStream& rOut = rBuProv.aBuExMasterStream;
+ if ( !nLev )
+ {
+ rOut << (sal_uInt32)( ( EPP_PST_ExtendedParagraphMasterAtom << 16 ) | ( mnInstance << 4 ) )
+ << (sal_uInt32)( 5 * 16 + 2 )
+ << (sal_uInt16)5; // depth
+ }
+ sal_uInt16 nBulletId = rLev.mnBulletId;
+ if ( rLev.mnNumberingType != SVX_NUM_BITMAP )
+ nBulletId = 0xffff;
+ rOut << (sal_uInt32)0x03800000
+ << (sal_uInt16)nBulletId
+ << (sal_uInt32)rLev.mnMappedNumType
+ << (sal_uInt16)rLev.mnBulletStart
+ << (sal_uInt32)0;
+ }
+
+ sal_uInt32 nParaFlags = 0x3ffdff;
+ sal_uInt16 nBulletFlags = ( rLev.mbIsBullet ) ? 0xf : 0xe;
+
+ if ( nLev )
+ nParaFlags &= 0x207fff;
+ if ( bSimpleText )
+ nParaFlags &= 0x7fff;
+ sal_uInt32 nBulletColor = rLev.mnBulletColor;
+ if ( nBulletColor == COL_AUTO )
+ {
+ sal_Bool bIsDark = sal_False;
+ ::com::sun::star::uno::Any aAny;
+ if ( PropValue::GetPropertyValue( aAny, rPagePropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundDark" ) ), sal_True ) )
+ aAny >>= bIsDark;
+ nBulletColor = bIsDark ? 0xffffff : 0x000000;
+ }
+ nBulletColor &= 0xffffff;
+ nBulletColor |= 0xfe000000;
+ rSt << nParaFlags
+ << nBulletFlags
+ << rLev.mnBulletChar
+ << rLev.mnBulletFont
+ << rLev.mnBulletHeight
+ << nBulletColor
+ << rLev.mnAdjust
+ << rLev.mnLineFeed
+ << rLev.mnUpperDist
+ << rLev.mnLowerDist
+ << rLev.mnTextOfs
+ << rLev.mnBulletOfs;
+
+ if ( bSimpleText || nLev )
+ {
+ if ( nParaFlags & 0x200000 )
+ rSt << rLev.mnBiDi;
+ }
+ else
+ {
+ rSt << rLev.mnDefaultTab
+ << (sal_uInt16)0
+ << (sal_uInt16)0
+ << rLev.mnAsianSettings
+ << rLev.mnBiDi;
+ }
+}
+
+
+PPTExStyleSheet::PPTExStyleSheet( sal_uInt16 nDefaultTab, PPTExBulletProvider& rBuProv )
+{
+ for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
+ {
+ mpParaSheet[ nInstance ] = ( nInstance == EPP_TEXTTYPE_notUsed ) ? NULL : new PPTExParaSheet( nInstance, nDefaultTab, rBuProv );
+ mpCharSheet[ nInstance ] = ( nInstance == EPP_TEXTTYPE_notUsed ) ? NULL : new PPTExCharSheet( nInstance );
+ }
+}
+
+PPTExStyleSheet::~PPTExStyleSheet()
+{
+ for ( int nInstance = EPP_TEXTTYPE_Title; nInstance <= EPP_TEXTTYPE_QuarterBody; nInstance++ )
+ {
+ if ( nInstance == EPP_TEXTTYPE_notUsed )
+ continue;
+
+ delete mpParaSheet[ nInstance ];
+ delete mpCharSheet[ nInstance ];
+ }
+}
+
+void PPTExStyleSheet::SetStyleSheet( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
+ FontCollection& rFontCollection, int nInstance, int nLevel )
+{
+ if ( nInstance == EPP_TEXTTYPE_notUsed )
+ return;
+ mpCharSheet[ nInstance ]->SetStyleSheet( rXPropSet, rFontCollection, nLevel );
+ mpParaSheet[ nInstance ]->SetStyleSheet( rXPropSet, rFontCollection, nLevel, mpCharSheet[ nInstance ]->maCharLevel[ nLevel ] );
+}
+
+sal_Bool PPTExStyleSheet::IsHardAttribute( sal_uInt32 nInstance, sal_uInt32 nLevel, PPTExTextAttr eAttr, sal_uInt32 nValue )
+{
+ const PPTExParaLevel& rPara = mpParaSheet[ nInstance ]->maParaLevel[ nLevel ];
+ const PPTExCharLevel& rChar = mpCharSheet[ nInstance ]->maCharLevel[ nLevel ];
+
+ sal_uInt32 nFlag = 0;
+
+ switch ( eAttr )
+ {
+ case ParaAttr_BulletOn : return ( rPara.mbIsBullet ) ? ( nValue ) ? sal_False : sal_True : ( nValue ) ? sal_True : sal_False;
+ case ParaAttr_BuHardFont :
+ case ParaAttr_BulletFont : return ( rPara.mnBulletFont != nValue );
+ case ParaAttr_BuHardColor :
+ case ParaAttr_BulletColor : return ( rPara.mnBulletColor != nValue );
+ case ParaAttr_BuHardHeight :
+ case ParaAttr_BulletHeight : return ( rPara.mnBulletHeight != nValue );
+ case ParaAttr_BulletChar : return ( rPara.mnBulletChar != nValue );
+ case ParaAttr_Adjust : return ( rPara.mnAdjust != nValue );
+ case ParaAttr_LineFeed : return ( rPara.mnLineFeed != nValue );
+ case ParaAttr_UpperDist : return ( rPara.mnUpperDist != nValue );
+ case ParaAttr_LowerDist : return ( rPara.mnLowerDist != nValue );
+ case ParaAttr_TextOfs : return ( rPara.mnTextOfs != nValue );
+ case ParaAttr_BulletOfs : return ( rPara.mnBulletOfs != nValue );
+ case ParaAttr_DefaultTab : return ( rPara.mnDefaultTab != nValue );
+ case ParaAttr_BiDi : return ( rPara.mnBiDi != nValue );
+ case CharAttr_Bold : nFlag = 1; break;
+ case CharAttr_Italic : nFlag = 2; break;
+ case CharAttr_Underline : nFlag = 4; break;
+ case CharAttr_Shadow : nFlag = 16; break;
+ case CharAttr_Strikeout : nFlag = 256; break;
+ case CharAttr_Embossed : nFlag = 512; break;
+ case CharAttr_Font : return ( rChar.mnFont != nValue );
+ case CharAttr_AsianOrComplexFont : return ( rChar.mnAsianOrComplexFont != nValue );
+ case CharAttr_Symbol : return sal_True;
+ case CharAttr_FontHeight : return ( rChar.mnFontHeight != nValue );
+ case CharAttr_FontColor : return ( rChar.mnFontColor != nValue );
+ case CharAttr_Escapement : return ( rChar.mnEscapement != nValue );
+ default:
+ break;
+ };
+ if ( nFlag )
+ {
+ if ( rChar.mnFlags & nFlag )
+ return ( ( nValue & nFlag ) == 0 );
+ else
+ return ( ( nValue & nFlag ) != 0 );
+ }
+ return sal_True;
+}
+
+sal_uInt32 PPTExStyleSheet::SizeOfTxCFStyleAtom() const
+{
+ return 24;
+}
+
+// the TxCFStyleAtom stores the text properties that are used
+// when creating new objects in PowerPoint.
+
+void PPTExStyleSheet::WriteTxCFStyleAtom( SvStream& rSt )
+{
+ const PPTExCharLevel& rCharStyle = mpCharSheet[ EPP_TEXTTYPE_Other ]->maCharLevel[ 0 ];
+
+ sal_uInt16 nFlags = 0x60 // ??
+ | 0x02 // fontsize;
+ | 0x04; // fontcolor
+
+ sal_uInt32 nCharFlags = rCharStyle.mnFlags;
+ nCharFlags &= CharAttr_Italic | CharAttr_Bold | CharAttr_Underline | CharAttr_Shadow;
+
+ rSt << (sal_uInt32)( EPP_TxCFStyleAtom << 16 ) // recordheader
+ << SizeOfTxCFStyleAtom() - 8
+ << (sal_uInt16)( 0x80 | nCharFlags )
+ << (sal_uInt16)nFlags
+ << (sal_uInt16)nCharFlags
+ << (sal_Int32)-1 // ?
+ << rCharStyle.mnFontHeight
+ << rCharStyle.mnFontColor;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/pptx-text.cxx b/sd/source/filter/eppt/pptx-text.cxx
new file mode 100644
index 000000000..8b0b7612e
--- /dev/null
+++ b/sd/source/filter/eppt/pptx-text.cxx
@@ -0,0 +1,1435 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include "text.hxx"
+
+#include <com/sun/star/awt/CharSet.hpp>
+#include <com/sun/star/awt/FontWeight.hpp>
+#include <com/sun/star/awt/FontUnderline.hpp>
+#include <com/sun/star/beans/XPropertyState.hpp>
+#include <com/sun/star/container/XEnumerationAccess.hpp>
+#include <com/sun/star/container/XIndexReplace.hpp>
+#include <com/sun/star/i18n/XBreakIterator.hpp>
+#include <com/sun/star/i18n/ScriptDirection.hpp>
+#include <com/sun/star/i18n/ScriptType.hpp>
+#include <com/sun/star/i18n/XScriptTypeDetector.hpp>
+#include <com/sun/star/text/FontRelief.hpp>
+#include <com/sun/star/text/XTextField.hpp>
+#include <com/sun/star/text/XTextRange.hpp>
+#include <com/sun/star/style/LineSpacing.hpp>
+#include <com/sun/star/style/LineSpacingMode.hpp>
+#include <com/sun/star/style/ParagraphAdjust.hpp>
+#include <com/sun/star/style/TabStop.hpp>
+
+#include <svl/languageoptions.hxx>
+#include <sfx2/app.hxx>
+#include <editeng/svxenum.hxx>
+#include <editeng/frmdir.hxx>
+#include <unotools/fontcvt.hxx>
+#include <vcl/metric.hxx>
+#include <vcl/outdev.hxx>
+#include <vcl/virdev.hxx>
+#include <comphelper/processfactory.hxx>
+#include <oox/export/drawingml.hxx> // for SubstituteBullet
+
+com::sun::star::uno::Reference< com::sun::star::i18n::XBreakIterator > xPPTBreakIter;
+com::sun::star::uno::Reference< com::sun::star::i18n::XScriptTypeDetector > xScriptTypeDetector;
+
+PortionObj::PortionObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
+ FontCollection& rFontCollection ) :
+ mnCharAttrHard ( 0 ),
+ mnCharAttr ( 0 ),
+ mnFont ( 0 ),
+ mnAsianOrComplexFont( 0xffff ),
+ mnTextSize ( 0 ),
+ mbLastPortion ( sal_True ),
+ mpText ( NULL ),
+ mpFieldEntry ( NULL )
+{
+ mXPropSet = rXPropSet;
+
+ ImplGetPortionValues( rFontCollection, sal_False );
+}
+
+PortionObj::PortionObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRange,
+ sal_Bool bLast, FontCollection& rFontCollection ) :
+ mnCharAttrHard ( 0 ),
+ mnCharAttr ( 0 ),
+ mnFont ( 0 ),
+ mnAsianOrComplexFont ( 0xffff ),
+ mbLastPortion ( bLast ),
+ mpText ( NULL ),
+ mpFieldEntry ( NULL )
+{
+ String aString( rXTextRange->getString() );
+ String aURL;
+ sal_Bool bRTL_endingParen = sal_False;
+
+ mnTextSize = aString.Len();
+ if ( bLast )
+ mnTextSize++;
+
+ if ( mnTextSize )
+ {
+ mpFieldEntry = NULL;
+ sal_uInt32 nFieldType = 0;
+
+ mXPropSet = ::com::sun::star::uno::Reference<
+ ::com::sun::star::beans::XPropertySet >
+ ( rXTextRange, ::com::sun::star::uno::UNO_QUERY );
+ mXPropState = ::com::sun::star::uno::Reference<
+ ::com::sun::star::beans::XPropertyState >
+ ( rXTextRange, ::com::sun::star::uno::UNO_QUERY );
+
+ sal_Bool bPropSetsValid = ( mXPropSet.is() && mXPropState.is() );
+ if ( bPropSetsValid )
+ nFieldType = ImplGetTextField( rXTextRange, mXPropSet, aURL );
+ if ( nFieldType )
+ {
+ mpFieldEntry = new FieldEntry( nFieldType, 0, mnTextSize );
+ if ( ( nFieldType >> 28 == 4 ) )
+ {
+ mpFieldEntry->aRepresentation = aString;
+ mpFieldEntry->aFieldUrl = aURL;
+ }
+ }
+ sal_Bool bSymbol = sal_False;
+
+ if ( bPropSetsValid && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSet" ) ), sal_False ) )
+ {
+ sal_Int16 nCharset = 0;
+ mAny >>= nCharset;
+ if ( nCharset == ::com::sun::star::awt::CharSet::SYMBOL )
+ bSymbol = sal_True;
+ }
+ if ( mpFieldEntry && ( nFieldType & 0x800000 ) ) // placeholder ?
+ {
+ mnTextSize = 1;
+ if ( bLast )
+ mnTextSize++;
+ mpText = new sal_uInt16[ mnTextSize ];
+ mpText[ 0 ] = 0x2a;
+ }
+ else
+ {
+ const sal_Unicode* pText = aString.GetBuffer();
+ // For i39516 - a closing parenthesis that ends an RTL string is displayed backwards by PPT
+ // Solution: add a Unicode Right-to-Left Mark, following the method described in i18024
+ if ( bLast && pText[ aString.Len() - 1 ] == sal_Unicode(')') && rFontCollection.GetScriptDirection( aString ) == com::sun::star::i18n::ScriptDirection::RIGHT_TO_LEFT )
+ {
+ mnTextSize++;
+ bRTL_endingParen = sal_True;
+ }
+ mpText = new sal_uInt16[ mnTextSize ];
+ sal_uInt16 nChar;
+ for ( int i = 0; i < aString.Len(); i++ )
+ {
+ nChar = (sal_uInt16)pText[ i ];
+ if ( nChar == 0xa )
+ nChar++;
+ else if ( !bSymbol )
+ {
+ switch ( nChar )
+ {
+ // Currency
+ case 128: nChar = 0x20AC; break;
+ // Punctuation and other
+ case 130: nChar = 0x201A; break;// SINGLE LOW-9 QUOTATION MARK
+ case 131: nChar = 0x0192; break;// LATIN SMALL LETTER F WITH HOOK
+ case 132: nChar = 0x201E; break;// DOUBLE LOW-9 QUOTATION MARK
+ // LOW DOUBLE PRIME QUOTATION MARK
+ case 133: nChar = 0x2026; break;// HORIZONTAL ELLIPSES
+ case 134: nChar = 0x2020; break;// DAGGER
+ case 135: nChar = 0x2021; break;// DOUBLE DAGGER
+ case 136: nChar = 0x02C6; break;// MODIFIER LETTER CIRCUMFLEX ACCENT
+ case 137: nChar = 0x2030; break;// PER MILLE SIGN
+ case 138: nChar = 0x0160; break;// LATIN CAPITAL LETTER S WITH CARON
+ case 139: nChar = 0x2039; break;// SINGLE LEFT-POINTING ANGLE QUOTATION MARK
+ case 140: nChar = 0x0152; break;// LATIN CAPITAL LIGATURE OE
+ case 142: nChar = 0x017D; break;// LATIN CAPITAL LETTER Z WITH CARON
+ case 145: nChar = 0x2018; break;// LEFT SINGLE QUOTATION MARK
+ // MODIFIER LETTER TURNED COMMA
+ case 146: nChar = 0x2019; break;// RIGHT SINGLE QUOTATION MARK
+ // MODIFIER LETTER APOSTROPHE
+ case 147: nChar = 0x201C; break;// LEFT DOUBLE QUOTATION MARK
+ // REVERSED DOUBLE PRIME QUOTATION MARK
+ case 148: nChar = 0x201D; break;// RIGHT DOUBLE QUOTATION MARK
+ // REVERSED DOUBLE PRIME QUOTATION MARK
+ case 149: nChar = 0x2022; break;// BULLET
+ case 150: nChar = 0x2013; break;// EN DASH
+ case 151: nChar = 0x2014; break;// EM DASH
+ case 152: nChar = 0x02DC; break;// SMALL TILDE
+ case 153: nChar = 0x2122; break;// TRADE MARK SIGN
+ case 154: nChar = 0x0161; break;// LATIN SMALL LETTER S WITH CARON
+ case 155: nChar = 0x203A; break;// SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
+ case 156: nChar = 0x0153; break;// LATIN SMALL LIGATURE OE
+ case 158: nChar = 0x017E; break;// LATIN SMALL LETTER Z WITH CARON
+ case 159: nChar = 0x0178; break;// LATIN CAPITAL LETTER Y WITH DIAERESIS
+ }
+ }
+ mpText[ i ] = nChar;
+ }
+ }
+ if ( bRTL_endingParen )
+ mpText[ mnTextSize - 2 ] = 0x200F; // Unicode Right-to-Left mark
+
+ if ( bLast )
+ mpText[ mnTextSize - 1 ] = 0xd;
+
+ if ( bPropSetsValid )
+ ImplGetPortionValues( rFontCollection, sal_True );
+ }
+}
+
+PortionObj::PortionObj( PortionObj& rPortionObj )
+: PropStateValue( rPortionObj )
+{
+ ImplConstruct( rPortionObj );
+}
+
+PortionObj::~PortionObj()
+{
+ ImplClear();
+}
+
+void PortionObj::Write( SvStream* pStrm, sal_Bool bLast )
+{
+ sal_uInt32 nCount = mnTextSize;
+ if ( bLast && mbLastPortion )
+ nCount--;
+ for ( sal_uInt32 i = 0; i < nCount; i++ )
+ *pStrm << (sal_uInt16)mpText[ i ];
+}
+
+void PortionObj::ImplGetPortionValues( FontCollection& rFontCollection, sal_Bool bGetPropStateValue )
+{
+
+ sal_Bool bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontName" ) ), bGetPropStateValue );
+ meFontName = ePropState;
+ if ( bOk )
+ {
+ FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
+ sal_uInt32 nCount = rFontCollection.GetCount();
+ mnFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
+ if ( mnFont == nCount )
+ {
+ FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSet" ) ), sal_False ) )
+ mAny >>= rFontDesc.CharSet;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamily" ) ), sal_False ) )
+ mAny >>= rFontDesc.Family;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitch" ) ), sal_False ) )
+ mAny >>= rFontDesc.Pitch;
+ }
+ }
+
+ sal_Int16 nScriptType = SvtLanguageOptions::GetScriptTypeOfLanguage( Application::GetSettings().GetLanguage() );
+ if ( mpText && mnTextSize && xPPTBreakIter.is() )
+ {
+ rtl::OUString sT( mpText, mnTextSize );
+ nScriptType = xPPTBreakIter->getScriptType( sT, 0 );
+ }
+ if ( nScriptType != com::sun::star::i18n::ScriptType::COMPLEX )
+ {
+ bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontNameAsian" ) ), bGetPropStateValue );
+ meAsianOrComplexFont = ePropState;
+ if ( bOk )
+ {
+ FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
+ sal_uInt32 nCount = rFontCollection.GetCount();
+ mnAsianOrComplexFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
+ if ( mnAsianOrComplexFont == nCount )
+ {
+ FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSetAsian" ) ), sal_False ) )
+ mAny >>= rFontDesc.CharSet;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamilyAsian" ) ), sal_False ) )
+ mAny >>= rFontDesc.Family;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitchAsian" ) ), sal_False ) )
+ mAny >>= rFontDesc.Pitch;
+ }
+ }
+ }
+ else
+ {
+ bOk = ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontNameComplex" ) ), bGetPropStateValue );
+ meAsianOrComplexFont = ePropState;
+ if ( bOk )
+ {
+ FontCollectionEntry aFontDesc( *(::rtl::OUString*)mAny.getValue() );
+ sal_uInt32 nCount = rFontCollection.GetCount();
+ mnAsianOrComplexFont = (sal_uInt16)rFontCollection.GetId( aFontDesc );
+ if ( mnAsianOrComplexFont == nCount )
+ {
+ FontCollectionEntry& rFontDesc = rFontCollection.GetLast();
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontCharSetComplex" ) ), sal_False ) )
+ mAny >>= rFontDesc.CharSet;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontFamilyComplex" ) ), sal_False ) )
+ mAny >>= rFontDesc.Family;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharFontPitchComplex" ) ), sal_False ) )
+ mAny >>= rFontDesc.Pitch;
+ }
+ }
+ }
+
+ rtl::OUString aCharHeightName, aCharWeightName, aCharLocaleName, aCharPostureName;
+ switch( nScriptType )
+ {
+ case com::sun::star::i18n::ScriptType::ASIAN :
+ {
+ aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeightAsian" ) );
+ aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeightAsian" ) );
+ aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocaleAsian" ) );
+ aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPostureAsian" ) );
+ break;
+ }
+ case com::sun::star::i18n::ScriptType::COMPLEX :
+ {
+ aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeightComplex" ) );
+ aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeightComplex" ) );
+ aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocaleComplex" ) );
+ aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPostureComplex" ) );
+ break;
+ }
+ default:
+ {
+ aCharHeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharHeight" ) );
+ aCharWeightName = String( RTL_CONSTASCII_USTRINGPARAM( "CharWeight" ) );
+ aCharLocaleName = String( RTL_CONSTASCII_USTRINGPARAM( "CharLocale" ) );
+ aCharPostureName = String( RTL_CONSTASCII_USTRINGPARAM( "CharPosture" ) );
+ break;
+ }
+ }
+
+ mnCharHeight = 24;
+ if ( GetPropertyValue( mAny, mXPropSet, aCharHeightName, sal_False ) )
+ {
+ float fVal(0.0);
+ if ( mAny >>= fVal )
+ {
+ mnCharHeight = (sal_uInt16)( fVal + 0.5 );
+ meCharHeight = GetPropertyState( mXPropSet, aCharHeightName );
+ }
+ }
+ if ( GetPropertyValue( mAny, mXPropSet, aCharWeightName, sal_False ) )
+ {
+ float fFloat(0.0);
+ if ( mAny >>= fFloat )
+ {
+ if ( fFloat >= ::com::sun::star::awt::FontWeight::SEMIBOLD )
+ mnCharAttr |= 1;
+ if ( GetPropertyState( mXPropSet, aCharWeightName ) == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ mnCharAttrHard |= 1;
+ }
+ }
+ if ( GetPropertyValue( mAny, mXPropSet, aCharLocaleName, sal_False ) )
+ {
+ com::sun::star::lang::Locale eLocale;
+ if ( mAny >>= eLocale )
+ meCharLocale = eLocale;
+ }
+ if ( GetPropertyValue( mAny, mXPropSet, aCharPostureName, sal_False ) )
+ {
+ ::com::sun::star::awt::FontSlant aFS;
+ if ( mAny >>= aFS )
+ {
+ switch( aFS )
+ {
+ case ::com::sun::star::awt::FontSlant_OBLIQUE :
+ case ::com::sun::star::awt::FontSlant_ITALIC :
+ mnCharAttr |= 2;
+ break;
+ default:
+ break;
+ }
+ if ( GetPropertyState( mXPropSet, aCharPostureName ) == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ mnCharAttrHard |= 2;
+ }
+ }
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharUnderline" ) ), bGetPropStateValue ) )
+ {
+ sal_Int16 nVal(0);
+ mAny >>= nVal;
+ switch ( nVal )
+ {
+ case ::com::sun::star::awt::FontUnderline::SINGLE :
+ case ::com::sun::star::awt::FontUnderline::DOUBLE :
+ case ::com::sun::star::awt::FontUnderline::DOTTED :
+ mnCharAttr |= 4;
+ }
+ }
+ if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ mnCharAttrHard |= 4;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharShadowed" ) ), bGetPropStateValue ) )
+ {
+ sal_Bool bBool(sal_False);
+ mAny >>= bBool;
+ if ( bBool )
+ mnCharAttr |= 0x10;
+ }
+ if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ mnCharAttrHard |= 16;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharRelief" ) ), bGetPropStateValue ) )
+ {
+ sal_Int16 nVal(0);
+ mAny >>= nVal;
+ if ( nVal != ::com::sun::star::text::FontRelief::NONE )
+ mnCharAttr |= 512;
+ }
+ if ( ePropState == ::com::sun::star::beans::PropertyState_DIRECT_VALUE )
+ mnCharAttrHard |= 512;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharColor" ) ), bGetPropStateValue ) )
+ {
+ sal_uInt32 nSOColor = *( (sal_uInt32*)mAny.getValue() );
+ mnCharColor = nSOColor & 0xff00ff00; // green and hibyte
+ mnCharColor |= (sal_uInt8)( nSOColor ) << 16; // red and blue is switched
+ mnCharColor |= (sal_uInt8)( nSOColor >> 16 );
+ }
+ meCharColor = ePropState;
+
+ mnCharEscapement = 0;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "CharEscapement" ) ), bGetPropStateValue ) )
+ {
+ mAny >>= mnCharEscapement;
+ if ( mnCharEscapement > 100 )
+ mnCharEscapement = 33;
+ else if ( mnCharEscapement < -100 )
+ mnCharEscapement = -33;
+ }
+ meCharEscapement = ePropState;
+}
+
+void PortionObj::ImplClear()
+{
+ delete (FieldEntry*)mpFieldEntry;
+ delete[] mpText;
+}
+
+void PortionObj::ImplConstruct( PortionObj& rPortionObj )
+{
+ mbLastPortion = rPortionObj.mbLastPortion;
+ mnTextSize = rPortionObj.mnTextSize;
+ mnCharColor = rPortionObj.mnCharColor;
+ mnCharEscapement = rPortionObj.mnCharEscapement;
+ mnCharAttr = rPortionObj.mnCharAttr;
+ mnCharHeight = rPortionObj.mnCharHeight;
+ mnFont = rPortionObj.mnFont;
+ mnAsianOrComplexFont = rPortionObj.mnAsianOrComplexFont;
+
+ if ( rPortionObj.mpText )
+ {
+ mpText = new sal_uInt16[ mnTextSize ];
+ memcpy( mpText, rPortionObj.mpText, mnTextSize << 1 );
+ }
+ else
+ mpText = NULL;
+
+ if ( rPortionObj.mpFieldEntry )
+ mpFieldEntry = new FieldEntry( *( rPortionObj.mpFieldEntry ) );
+ else
+ mpFieldEntry = NULL;
+}
+
+sal_uInt32 PortionObj::ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition )
+{
+ if ( mpFieldEntry && ( !mpFieldEntry->nFieldStartPos ) )
+ {
+ mpFieldEntry->nFieldStartPos += nCurrentTextPosition;
+ mpFieldEntry->nFieldEndPos += nCurrentTextPosition;
+ }
+ return mnTextSize;
+}
+
+// -----------------------------------------------------------------------
+// Rueckgabe: 0 = kein TextField
+// bit28->31 text field type :
+// 1 = Date
+// 2 = Time
+// 3 = SlideNumber
+// 4 = Url
+// 5 = DateTime
+// 6 = header
+// 7 = footer
+// bit24->27 text field sub type (optional)
+// 23-> PPT Textfield needs a placeholder
+
+sal_uInt32 PortionObj::ImplGetTextField( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & ,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet, String& rURL )
+{
+ sal_uInt32 nRetValue = 0;
+ sal_Int32 nFormat;
+ ::com::sun::star::uno::Any aAny;
+ if ( GetPropertyValue( aAny, rXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "TextPortionType" ) ), sal_True ) )
+ {
+ String aTextFieldType( *(::rtl::OUString*)aAny.getValue() );
+ if ( aTextFieldType == String( RTL_CONSTASCII_USTRINGPARAM( "TextField" ) ) )
+ {
+ if ( GetPropertyValue( aAny, rXPropSet, aTextFieldType, sal_True ) )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextField > aXTextField;
+ if ( aAny >>= aXTextField )
+ {
+ if ( aXTextField.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
+ xFieldPropSet( aXTextField, ::com::sun::star::uno::UNO_QUERY );
+ if ( xFieldPropSet.is() )
+ {
+ String aFieldKind( aXTextField->getPresentation( sal_True ) );
+ if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Date" ) ) )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
+ {
+ sal_Bool bBool = sal_False;
+ aAny >>= bBool;
+ if ( !bBool ) // Fixed DateFields gibt es in PPT nicht
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Format" ) ) ), sal_True )
+ {
+ nFormat = *(sal_Int32*)aAny.getValue();
+ switch ( nFormat )
+ {
+ default:
+ case 5 :
+ case 4 :
+ case 2 : nFormat = 0; break;
+ case 8 :
+ case 9 :
+ case 3 : nFormat = 1; break;
+ case 7 :
+ case 6 : nFormat = 2; break;
+ }
+ nRetValue |= ( ( ( 1 << 4 ) | nFormat ) << 24 ) | 0x800000;
+ }
+ }
+ }
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "URL" ) ) )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "URL" ) ) ), sal_True )
+ rURL = String( *(::rtl::OUString*)aAny.getValue() );
+ nRetValue = 4 << 28;
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Page" ) ) )
+ {
+ nRetValue = 3 << 28 | 0x800000;
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Pages" ) ) )
+ {
+
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Time" ) ) )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
+ {
+ sal_Bool bBool = sal_False;
+ aAny >>= bBool;
+ if ( !bBool )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
+ {
+ nFormat = *(sal_Int32*)aAny.getValue();
+ nRetValue |= ( ( ( 2 << 4 ) | nFormat ) << 24 ) | 0x800000;
+ }
+ }
+ }
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "File" ) ) )
+ {
+
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Table" ) ) )
+ {
+
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "ExtTime" ) ) )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "IsFix" ) ) ), sal_True )
+ {
+ sal_Bool bBool = sal_False;
+ aAny >>= bBool;
+ if ( !bBool )
+ {
+ if ( GetPropertyValue( aAny, xFieldPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "Format" ) ) ), sal_True )
+ {
+ nFormat = *(sal_Int32*)aAny.getValue();
+ switch ( nFormat )
+ {
+ default:
+ case 6 :
+ case 7 :
+ case 8 :
+ case 2 : nFormat = 12; break;
+ case 3 : nFormat = 9; break;
+ case 5 :
+ case 4 : nFormat = 10; break;
+
+ }
+ nRetValue |= ( ( ( 2 << 4 ) | nFormat ) << 24 ) | 0x800000;
+ }
+ }
+ }
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "ExtFile" ) ) )
+ {
+
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Author" ) ) )
+ {
+
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "DateTime" ) ) )
+ {
+ nRetValue = 5 << 28 | 0x800000;
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Header" ) ) )
+ {
+ nRetValue = 6 << 28 | 0x800000;
+ }
+ else if ( aFieldKind == String( RTL_CONSTASCII_USTRINGPARAM( "Footer" ) ) )
+ {
+ nRetValue = 7 << 28 | 0x800000;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ return nRetValue;
+}
+
+PortionObj& PortionObj::operator=( PortionObj& rPortionObj )
+{
+ if ( this != &rPortionObj )
+ {
+ ImplClear();
+ ImplConstruct( rPortionObj );
+ }
+ return *this;
+}
+
+ParagraphObj::ParagraphObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSet,
+ PPTExBulletProvider& rProv ) :
+ maMapModeSrc ( MAP_100TH_MM ),
+ maMapModeDest ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 576 ) )
+{
+ mXPropSet = rXPropSet;
+
+ bExtendedParameters = sal_False;
+
+ nDepth = 0;
+ nBulletFlags = 0;
+ nParaFlags = 0;
+
+ ImplGetParagraphValues( rProv, sal_False );
+}
+
+ ParagraphObj::ParagraphObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > & rXTextContent,
+ ParaFlags aParaFlags, FontCollection& rFontCollection, PPTExBulletProvider& rProv ) :
+ maMapModeSrc ( MAP_100TH_MM ),
+ maMapModeDest ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 576 ) ),
+ mbFirstParagraph ( aParaFlags.bFirstParagraph ),
+ mbLastParagraph ( aParaFlags.bLastParagraph )
+{
+ bExtendedParameters = sal_False;
+
+ nDepth = 0;
+ nBulletFlags = 0;
+ nParaFlags = 0;
+
+ mXPropSet = ::com::sun::star::uno::Reference<
+ ::com::sun::star::beans::XPropertySet >
+ ( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
+
+ mXPropState = ::com::sun::star::uno::Reference<
+ ::com::sun::star::beans::XPropertyState >
+ ( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
+
+ if ( mXPropSet.is() && mXPropState.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess >
+ aXTextPortionEA( rXTextContent, ::com::sun::star::uno::UNO_QUERY );
+ if ( aXTextPortionEA.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration >
+ aXTextPortionE( aXTextPortionEA->createEnumeration() );
+ if ( aXTextPortionE.is() )
+ {
+ while ( aXTextPortionE->hasMoreElements() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > aXCursorText;
+ ::com::sun::star::uno::Any aAny( aXTextPortionE->nextElement() );
+ if ( aAny >>= aXCursorText )
+ {
+ PortionObj* pPortionObj = new PortionObj( aXCursorText, !aXTextPortionE->hasMoreElements(), rFontCollection );
+ if ( pPortionObj->Count() )
+ Insert( pPortionObj, LIST_APPEND );
+ else
+ delete pPortionObj;
+ }
+ }
+ }
+ }
+ ImplGetParagraphValues( rProv, sal_True );
+ }
+}
+
+ParagraphObj::ParagraphObj( ParagraphObj& rObj )
+: List()
+, PropStateValue()
+, SOParagraph()
+{
+ ImplConstruct( rObj );
+}
+
+ParagraphObj::~ParagraphObj()
+{
+ ImplClear();
+}
+
+void ParagraphObj::Write( SvStream* pStrm )
+{
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ ((PortionObj*)pPtr)->Write( pStrm, mbLastParagraph );
+}
+
+void ParagraphObj::ImplClear()
+{
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ delete (PortionObj*)pPtr;
+}
+
+void ParagraphObj::CalculateGraphicBulletSize( sal_uInt16 nFontHeight )
+{
+ if ( ( (SvxExtNumType)nNumberingType == SVX_NUM_BITMAP ) && ( nBulletId != 0xffff ) )
+ {
+ // calculate the bulletrealsize for this grafik
+ if ( aBuGraSize.Width() && aBuGraSize.Height() )
+ {
+ double fCharHeight = nFontHeight;
+ double fLen = aBuGraSize.Height();
+ fCharHeight = fCharHeight * 0.2540;
+ double fQuo = fLen / fCharHeight;
+ nBulletRealSize = (sal_Int16)( fQuo + 0.5 );
+ if ( (sal_uInt16)nBulletRealSize > 400 )
+ nBulletRealSize = 400;
+ }
+ }
+}
+
+// from sw/source/filter/ww8/wrtw8num.cxx for default bullets to export to MS intact
+static void lcl_SubstituteBullet(String& rNumStr, rtl_TextEncoding& rChrSet, String& rFontName)
+{
+ sal_Unicode cChar = rNumStr.GetChar(0);
+ StarSymbolToMSMultiFont *pConvert = CreateStarSymbolToMSMultiFont();
+ String sFont = pConvert->ConvertChar(cChar);
+ delete pConvert;
+ if (sFont.Len())
+ {
+ rNumStr = static_cast< sal_Unicode >(cChar | 0xF000);
+ rFontName = sFont;
+ rChrSet = RTL_TEXTENCODING_SYMBOL;
+ }
+ else if ( (rNumStr.GetChar(0) < 0xE000 || rNumStr.GetChar(0) > 0xF8FF) )
+ {
+ /*
+ Ok we can't fit into a known windows unicode font, but
+ we are not in the private area, so we are a
+ standardized symbol, so turn off the symbol bit and
+ let words own font substitution kick in
+ */
+ rChrSet = RTL_TEXTENCODING_UNICODE;
+ rFontName = ::GetFontToken(rFontName, 0);
+ }
+ else
+ {
+ /*
+ Well we don't have an available substition, and we're
+ in our private area, so give up and show a standard
+ bullet symbol
+ */
+ rFontName.AssignAscii(RTL_CONSTASCII_STRINGPARAM("Wingdings"));
+ rNumStr = static_cast< sal_Unicode >(0x6C);
+ }
+}
+
+void ParagraphObj::ImplGetNumberingLevel( PPTExBulletProvider& rBuProv, sal_Int16 nNumberingDepth, sal_Bool bIsBullet, sal_Bool bGetPropStateValue )
+{
+ ::com::sun::star::uno::Any aAny;
+ if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaLeftMargin" ) ) ) )
+ {
+ sal_Int32 nVal(0);
+ if ( aAny >>= nVal )
+ nTextOfs = static_cast< sal_Int16 >( nVal / ( 2540.0 / 576 ) + 0.5 ) ;
+ }
+ if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaFirstLineIndent" ) ) ) )
+ {
+ if ( aAny >>= nBulletOfs )
+ nBulletOfs = static_cast< sal_Int32 >( nBulletOfs / ( 2540.0 / 576 ) + 0.5 );
+ }
+ if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "NumberingIsNumber" ) ) ) )
+ aAny >>= bNumberingIsNumber;
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexReplace > aXIndexReplace;
+
+ if ( bIsBullet && ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "NumberingRules" ) ), bGetPropStateValue ) )
+ {
+ if ( ( mAny >>= aXIndexReplace ) && nNumberingDepth < aXIndexReplace->getCount() )
+ {
+ mAny <<= aXIndexReplace->getByIndex( nNumberingDepth );
+ ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>
+ aPropertySequence( *( ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>*)mAny.getValue() );
+
+ const ::com::sun::star::beans::PropertyValue* pPropValue = aPropertySequence.getArray();
+
+ sal_Int32 nPropertyCount = aPropertySequence.getLength();
+ if ( nPropertyCount )
+ {
+ bExtendedParameters = sal_True;
+ nBulletRealSize = 100;
+ nMappedNumType = 0;
+
+ String aGraphicURL;
+ for ( sal_Int32 i = 0; i < nPropertyCount; i++ )
+ {
+ const void* pValue = pPropValue[ i ].Value.getValue();
+ if ( pValue )
+ {
+ ::rtl::OUString aPropName( pPropValue[ i ].Name );
+ if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "NumberingType" ) ) )
+ nNumberingType = *( (sal_Int16*)pValue );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Adjust" ) ) )
+ nHorzAdjust = *( (sal_Int16*)pValue );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletChar" ) ) )
+ {
+ String aString( *( (String*)pValue ) );
+ if ( aString.Len() )
+ cBulletId = aString.GetChar( 0 );
+ }
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletFont" ) ) )
+ {
+ aFontDesc = *( (::com::sun::star::awt::FontDescriptor*)pValue );
+
+ // Our numbullet dialog has set the wrong textencoding for our "StarSymbol" font,
+ // instead of a Unicode encoding the encoding RTL_TEXTENCODING_SYMBOL was used.
+ // Because there might exist a lot of damaged documemts I added this two lines
+ // which fixes the bullet problem for the export.
+ if ( aFontDesc.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StarSymbol" ) ) )
+ aFontDesc.CharSet = RTL_TEXTENCODING_MS_1252;
+
+ }
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GraphicURL" ) ) )
+ aGraphicURL = ( *(::rtl::OUString*)pValue );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GraphicSize" ) ) )
+ {
+ if ( pPropValue[ i ].Value.getValueType() == ::getCppuType( (::com::sun::star::awt::Size*)0) )
+ {
+ // don't cast awt::Size to Size as on 64-bits they are not the same.
+ ::com::sun::star::awt::Size aSize;
+ pPropValue[ i ].Value >>= aSize;
+ aBuGraSize.nA = aSize.Width;
+ aBuGraSize.nB = aSize.Height;
+ }
+ }
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StartWith" ) ) )
+ nStartWith = *( (sal_Int16*)pValue );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "LeftMargin" ) ) )
+ nTextOfs = nTextOfs + static_cast< sal_Int16 >( *( (sal_Int32*)pValue ) / ( 2540.0 / 576 ) );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FirstLineOffset" ) ) )
+ nBulletOfs += (sal_Int16)( *( (sal_Int32*)pValue ) / ( 2540.0 / 576 ) );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletColor" ) ) )
+ {
+ sal_uInt32 nSOColor = *( (sal_uInt32*)pValue );
+ nBulletColor = nSOColor & 0xff00ff00; // green and hibyte
+ nBulletColor |= (sal_uInt8)( nSOColor ) << 16; // red
+ nBulletColor |= (sal_uInt8)( nSOColor >> 16 ) | 0xfe000000; // blue
+ }
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "BulletRelSize" ) ) )
+ {
+ nBulletRealSize = *( (sal_Int16*)pValue );
+ nParaFlags |= 0x40;
+ nBulletFlags |= 8;
+ }
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Prefix" ) ) )
+ sPrefix = ( *(::rtl::OUString*)pValue );
+ else if ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Suffix" ) ) )
+ sSuffix = ( *(::rtl::OUString*)pValue );
+#ifdef DBG_UTIL
+ else if ( ! (
+ ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "SymbolTextDistance" ) ) )
+ || ( aPropName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Graphic" ) ) ) ) )
+ {
+ OSL_FAIL( "Unbekanntes Property" );
+ }
+#endif
+ }
+ }
+
+ if ( aGraphicURL.Len() )
+ {
+ if ( aBuGraSize.Width() && aBuGraSize.Height() )
+ {
+ xub_StrLen nIndex = aGraphicURL.Search( (sal_Unicode)':', 0 );
+ if ( nIndex != STRING_NOTFOUND )
+ {
+ nIndex++;
+ if ( aGraphicURL.Len() > nIndex )
+ {
+ ByteString aUniqueId( aGraphicURL, nIndex, aGraphicURL.Len() - nIndex, RTL_TEXTENCODING_UTF8 );
+ if ( aUniqueId.Len() )
+ {
+ nBulletId = rBuProv.GetId( aUniqueId, aBuGraSize );
+ if ( nBulletId != 0xffff )
+ bExtendedBulletsUsed = sal_True;
+ }
+ }
+ }
+ }
+ else
+ {
+ nNumberingType = SVX_NUM_NUMBER_NONE;
+ }
+ }
+
+ PortionObj* pPortion = (PortionObj*)First();
+ CalculateGraphicBulletSize( ( pPortion ) ? pPortion->mnCharHeight : 24 );
+
+ switch( (SvxExtNumType)nNumberingType )
+ {
+ case SVX_NUM_NUMBER_NONE : nParaFlags |= 0xf; break;
+
+ case SVX_NUM_CHAR_SPECIAL : // Bullet
+ {
+ if ( aFontDesc.Name.equalsIgnoreAsciiCaseAscii("starsymbol") ||
+ aFontDesc.Name.equalsIgnoreAsciiCaseAscii("opensymbol") )
+ {
+ String sFontName = aFontDesc.Name;
+ String sNumStr = cBulletId;
+ rtl_TextEncoding eChrSet = aFontDesc.CharSet;
+ lcl_SubstituteBullet(sNumStr,eChrSet,sFontName);
+ aFontDesc.Name = sFontName;
+ cBulletId = sNumStr.GetChar( 0 );
+ aFontDesc.CharSet = eChrSet;
+ }
+
+ if ( aFontDesc.Name.getLength() )
+ {
+ nParaFlags |= 0x90; // wir geben den Font und den Charset vor
+ }
+ }
+ case SVX_NUM_CHARS_UPPER_LETTER : // zaehlt von a-z, aa - az, ba - bz, ...
+ case SVX_NUM_CHARS_LOWER_LETTER :
+ case SVX_NUM_ROMAN_UPPER :
+ case SVX_NUM_ROMAN_LOWER :
+ case SVX_NUM_ARABIC :
+ case SVX_NUM_PAGEDESC : // Numerierung aus der Seitenvorlage
+ case SVX_NUM_BITMAP :
+ case SVX_NUM_CHARS_UPPER_LETTER_N : // zaehlt von a-z, aa-zz, aaa-zzz
+ case SVX_NUM_CHARS_LOWER_LETTER_N :
+ {
+ if ( nNumberingType != SVX_NUM_CHAR_SPECIAL )
+ {
+ bExtendedBulletsUsed = sal_True;
+ if ( nNumberingDepth & 1 )
+ cBulletId = 0x2013; // defaulting bullet characters for ppt97
+ else if ( nNumberingDepth == 4 )
+ cBulletId = 0xbb;
+ else
+ cBulletId = 0x2022;
+
+ switch( (SvxExtNumType)nNumberingType )
+ {
+ case SVX_NUM_CHARS_UPPER_LETTER :
+ case SVX_NUM_CHARS_UPPER_LETTER_N :
+ {
+ if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
+ {
+ if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
+ nMappedNumType = 0xa0001; // (A)
+ else
+ nMappedNumType = 0xb0001; // A)
+ }
+ else
+ nMappedNumType = 0x10001; // A.
+ }
+ break;
+ case SVX_NUM_CHARS_LOWER_LETTER :
+ case SVX_NUM_CHARS_LOWER_LETTER_N :
+ {
+ if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
+ {
+ if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
+ nMappedNumType = 0x80001; // (a)
+ else
+ nMappedNumType = 0x90001; // a)
+ }
+ else
+ nMappedNumType = 0x00001; // a.
+ }
+ break;
+ case SVX_NUM_ROMAN_UPPER :
+ {
+ if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
+ {
+ if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
+ nMappedNumType = 0xe0001; // (I)
+ else
+ nMappedNumType = 0xf0001; // I)
+ }
+ else
+ nMappedNumType = 0x70001; // I.
+ }
+ break;
+ case SVX_NUM_ROMAN_LOWER :
+ {
+ if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
+ {
+ if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
+ nMappedNumType = 0x40001; // (i)
+ else
+ nMappedNumType = 0x50001; // i)
+ }
+ else
+ nMappedNumType = 0x60001; // i.
+ }
+ break;
+ case SVX_NUM_ARABIC :
+ {
+ if ( sSuffix == String( RTL_CONSTASCII_USTRINGPARAM( ")" ) ) )
+ {
+ if ( sPrefix == String( RTL_CONSTASCII_USTRINGPARAM( "(" ) ) )
+ nMappedNumType = 0xc0001; // (1)
+ else
+ nMappedNumType = 0x20001; // 1)
+ }
+ else
+ {
+ if ( ! ( sSuffix.Len() + sPrefix.Len() ) )
+ nMappedNumType = 0xd0001; // 1
+ else
+ nMappedNumType = 0x30001; // 1.
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ nParaFlags |= 0x2f;
+ nBulletFlags |= 6;
+ if ( mbIsBullet && bNumberingIsNumber )
+ nBulletFlags |= 1;
+ }
+ }
+ }
+ }
+ }
+ nBulletOfs = nTextOfs + nBulletOfs;
+ if ( nBulletOfs < 0 )
+ nBulletOfs = 0;
+}
+
+void ParagraphObj::ImplGetParagraphValues( PPTExBulletProvider& rBuProv, sal_Bool bGetPropStateValue )
+{
+ static String sNumberingLevel ( RTL_CONSTASCII_USTRINGPARAM( "NumberingLevel" ) );
+
+ ::com::sun::star::uno::Any aAny;
+ if ( GetPropertyValue( aAny, mXPropSet, sNumberingLevel, sal_True ) )
+ {
+ if ( bGetPropStateValue )
+ meBullet = GetPropertyState( mXPropSet, sNumberingLevel );
+ nDepth = *( (sal_Int16*)aAny.getValue() );
+
+ if ( nDepth < 0 )
+ {
+ mbIsBullet = sal_False;
+ nDepth = 0;
+ }
+ else
+ {
+ if ( nDepth > 4 )
+ nDepth = 4;
+ mbIsBullet = sal_True;
+ }
+ }
+ else
+ {
+ nDepth = 0;
+ mbIsBullet = sal_False;
+ }
+ ImplGetNumberingLevel( rBuProv, nDepth, mbIsBullet, bGetPropStateValue );
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaTabStops" ) ), bGetPropStateValue ) )
+ maTabStop = *( ::com::sun::star::uno::Sequence< ::com::sun::star::style::TabStop>*)mAny.getValue();
+ sal_Int16 eTextAdjust( ::com::sun::star::style::ParagraphAdjust_LEFT );
+ if ( GetPropertyValue( aAny, mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "ParaAdjust" ) ), bGetPropStateValue ) )
+ aAny >>= eTextAdjust;
+ switch ( (::com::sun::star::style::ParagraphAdjust)eTextAdjust )
+ {
+ case ::com::sun::star::style::ParagraphAdjust_CENTER :
+ mnTextAdjust = 1;
+ break;
+ case ::com::sun::star::style::ParagraphAdjust_RIGHT :
+ mnTextAdjust = 2;
+ break;
+ case ::com::sun::star::style::ParagraphAdjust_BLOCK :
+ mnTextAdjust = 3;
+ break;
+ default :
+ case ::com::sun::star::style::ParagraphAdjust_LEFT :
+ mnTextAdjust = 0;
+ break;
+ }
+ meTextAdjust = ePropState;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaLineSpacing" ) ), bGetPropStateValue ) )
+ {
+ ::com::sun::star::style::LineSpacing aLineSpacing
+ = *( (::com::sun::star::style::LineSpacing*)mAny.getValue() );
+ switch ( aLineSpacing.Mode )
+ {
+ case ::com::sun::star::style::LineSpacingMode::FIX :
+ mnLineSpacing = (sal_Int16)(-( aLineSpacing.Height ) );
+ mbFixedLineSpacing = sal_True;
+ break;
+ case ::com::sun::star::style::LineSpacingMode::MINIMUM :
+ case ::com::sun::star::style::LineSpacingMode::LEADING :
+ mnLineSpacing = (sal_Int16)(-( aLineSpacing.Height ) );
+ mbFixedLineSpacing = sal_False;
+ break;
+
+ case ::com::sun::star::style::LineSpacingMode::PROP :
+ default:
+ mnLineSpacing = (sal_Int16)( aLineSpacing.Height );
+ break;
+ }
+ }
+ meLineSpacing = ePropState;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaBottomMargin" ) ), bGetPropStateValue ) )
+ {
+ double fSpacing = *( (sal_uInt32*)mAny.getValue() ) + ( 2540.0 / 576.0 ) - 1;
+ mnLineSpacingBottom = (sal_Int16)(-( fSpacing * 576.0 / 2540.0 ) );
+ }
+ meLineSpacingBottom = ePropState;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaTopMargin" ) ), bGetPropStateValue ) )
+ {
+ double fSpacing = *( (sal_uInt32*)mAny.getValue() ) + ( 2540.0 / 576.0 ) - 1;
+ mnLineSpacingTop = (sal_Int16)(-( fSpacing * 576.0 / 2540.0 ) );
+ }
+ meLineSpacingTop = ePropState;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaIsForbiddenRules" ) ), bGetPropStateValue ) )
+ mAny >>= mbForbiddenRules;
+ meForbiddenRules = ePropState;
+
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "ParaIsHangingPunctuation" ) ), bGetPropStateValue ) )
+ mAny >>= mbParagraphPunctation;
+ meParagraphPunctation = ePropState;
+
+ mnBiDi = 0;
+ if ( ImplGetPropertyValue( String( RTL_CONSTASCII_USTRINGPARAM( "WritingMode" ) ), bGetPropStateValue ) )
+ {
+ sal_Int16 nWritingMode = 0;
+ mAny >>= nWritingMode;
+
+ SvxFrameDirection eWritingMode( (SvxFrameDirection)nWritingMode );
+ if ( ( eWritingMode == FRMDIR_HORI_RIGHT_TOP )
+ || ( eWritingMode == FRMDIR_VERT_TOP_RIGHT ) )
+ {
+ mnBiDi = 1;
+ }
+ }
+ meBiDi = ePropState;
+}
+
+void ParagraphObj::ImplConstruct( ParagraphObj& rParagraphObj )
+{
+ mnTextSize = rParagraphObj.mnTextSize;
+ mnTextAdjust = rParagraphObj.mnTextAdjust;
+ mnLineSpacing = rParagraphObj.mnLineSpacing;
+ mnLineSpacingTop = rParagraphObj.mnLineSpacingTop;
+ mnLineSpacingBottom = rParagraphObj.mnLineSpacingBottom;
+ mbFirstParagraph = rParagraphObj.mbFirstParagraph;
+ mbLastParagraph = rParagraphObj.mbLastParagraph;
+ mbParagraphPunctation = rParagraphObj.mbParagraphPunctation;
+ mbForbiddenRules = rParagraphObj.mbForbiddenRules;
+ mnBiDi = rParagraphObj.mnBiDi;
+
+ for ( void* pPtr = rParagraphObj.First(); pPtr; pPtr = rParagraphObj.Next() )
+ Insert( new PortionObj( *(PortionObj*)pPtr ), LIST_APPEND );
+
+ maTabStop = rParagraphObj.maTabStop;
+ bExtendedParameters = rParagraphObj.bExtendedParameters;
+ nParaFlags = rParagraphObj.nParaFlags;
+ nBulletFlags = rParagraphObj.nBulletFlags;
+ sPrefix = rParagraphObj.sPrefix;
+ sSuffix = rParagraphObj.sSuffix;
+ sGraphicUrl = rParagraphObj.sGraphicUrl; // String auf eine Graphic
+ aBuGraSize = rParagraphObj.aBuGraSize;
+ nNumberingType = rParagraphObj.nNumberingType; // in wirlichkeit ist dies ein SvxEnum
+ nHorzAdjust = rParagraphObj.nHorzAdjust;
+ nBulletColor = rParagraphObj.nBulletColor;
+ nBulletOfs = rParagraphObj.nBulletOfs;
+ nStartWith = rParagraphObj.nStartWith; // Start der nummerierung
+ nTextOfs = rParagraphObj.nTextOfs;
+ nBulletRealSize = rParagraphObj.nBulletRealSize; // GroessenVerhaeltnis in Proz
+ nDepth = rParagraphObj.nDepth; // aktuelle tiefe
+ cBulletId = rParagraphObj.cBulletId; // wenn Numbering Type == CharSpecial
+ aFontDesc = rParagraphObj.aFontDesc;
+
+ bExtendedBulletsUsed = rParagraphObj.bExtendedBulletsUsed;
+ nBulletId = rParagraphObj.nBulletId;
+}
+
+::com::sun::star::awt::Size ParagraphObj::ImplMapSize( const ::com::sun::star::awt::Size& rSize )
+{
+ Size aSize( OutputDevice::LogicToLogic( Size( rSize.Width, rSize.Height ), maMapModeSrc, maMapModeDest ) );
+ if ( !aSize.Width() )
+ aSize.Width()++;
+ if ( !aSize.Height() )
+ aSize.Height()++;
+ return ::com::sun::star::awt::Size( aSize.Width(), aSize.Height() );
+}
+
+sal_uInt32 ParagraphObj::ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition )
+{
+ mnTextSize = 0;
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ mnTextSize += ((PortionObj*)pPtr)->ImplCalculateTextPositions( nCurrentTextPosition + mnTextSize );
+ return mnTextSize;
+}
+
+ParagraphObj& ParagraphObj::operator=( ParagraphObj& rParagraphObj )
+{
+ if ( this != &rParagraphObj )
+ {
+ ImplClear();
+ ImplConstruct( rParagraphObj );
+ }
+ return *this;
+}
+
+ImplTextObj::ImplTextObj( int nInstance )
+{
+ mnRefCount = 1;
+ mnTextSize = 0;
+ mnInstance = nInstance;
+ mpList = new List;
+ mbHasExtendedBullets = sal_False;
+ mbFixedCellHeightUsed = sal_False;
+}
+
+ImplTextObj::~ImplTextObj()
+{
+ for ( ParagraphObj* pPtr = (ParagraphObj*)mpList->First(); pPtr; pPtr = (ParagraphObj*)mpList->Next() )
+ delete pPtr;
+ delete mpList;
+}
+
+TextObj::TextObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > & rXTextRef,
+ int nInstance, FontCollection& rFontCollection, PPTExBulletProvider& rProv )
+{
+ mpImplTextObj = new ImplTextObj( nInstance );
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess >
+ aXTextParagraphEA( rXTextRef, ::com::sun::star::uno::UNO_QUERY );
+
+ if ( aXTextParagraphEA.is() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration >
+ aXTextParagraphE( aXTextParagraphEA->createEnumeration() );
+ if ( aXTextParagraphE.is() )
+ {
+ ParaFlags aParaFlags;
+ while ( aXTextParagraphE->hasMoreElements() )
+ {
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > aXParagraph;
+ ::com::sun::star::uno::Any aAny( aXTextParagraphE->nextElement() );
+ if ( aAny >>= aXParagraph )
+ {
+ if ( !aXTextParagraphE->hasMoreElements() )
+ aParaFlags.bLastParagraph = sal_True;
+ ParagraphObj* pPara = new ParagraphObj( aXParagraph, aParaFlags, rFontCollection, rProv );
+ mpImplTextObj->mbHasExtendedBullets |= pPara->bExtendedBulletsUsed;
+ mpImplTextObj->mpList->Insert( pPara, LIST_APPEND );
+ aParaFlags.bFirstParagraph = sal_False;
+ }
+ }
+ }
+ }
+ ImplCalculateTextPositions();
+}
+
+TextObj::TextObj( TextObj& rTextObj )
+{
+ mpImplTextObj = rTextObj.mpImplTextObj;
+ mpImplTextObj->mnRefCount++;
+}
+
+TextObj::~TextObj()
+{
+ if ( ! ( --mpImplTextObj->mnRefCount ) )
+ delete mpImplTextObj;
+}
+
+void TextObj::Write( SvStream* pStrm )
+{
+ sal_uInt32 nSize, nPos = pStrm->Tell();
+ *pStrm << (sal_uInt32)( EPP_TextCharsAtom << 16 ) << (sal_uInt32)0;
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ ((ParagraphObj*)pPtr)->Write( pStrm );
+ nSize = pStrm->Tell() - nPos;
+ pStrm->SeekRel( - ( (sal_Int32)nSize - 4 ) );
+ *pStrm << (sal_uInt32)( nSize - 8 );
+ pStrm->SeekRel( nSize - 8 );
+}
+
+void TextObj::ImplCalculateTextPositions()
+{
+ mpImplTextObj->mnTextSize = 0;
+ for ( void* pPtr = First(); pPtr; pPtr = Next() )
+ mpImplTextObj->mnTextSize += ((ParagraphObj*)pPtr)->ImplCalculateTextPositions( mpImplTextObj->mnTextSize );
+}
+
+TextObj& TextObj::operator=( TextObj& rTextObj )
+{
+ if ( this != &rTextObj )
+ {
+ if ( ! ( --mpImplTextObj->mnRefCount ) )
+ delete mpImplTextObj;
+ mpImplTextObj = rTextObj.mpImplTextObj;
+ mpImplTextObj->mnRefCount++;
+ }
+ return *this;
+}
+
+FontCollectionEntry::~FontCollectionEntry()
+{
+}
+
+void FontCollectionEntry::ImplInit( const String& rName )
+{
+ String aSubstName( GetSubsFontName( rName, SUBSFONT_ONLYONE | SUBSFONT_MS ) );
+ if ( aSubstName.Len() )
+ {
+ Name = aSubstName;
+ bIsConverted = sal_True;
+ }
+ else
+ {
+ Name = rName;
+ bIsConverted = sal_False;
+ }
+}
+
+FontCollection::~FontCollection()
+{
+ delete pVDev;
+ xPPTBreakIter = NULL;
+ xScriptTypeDetector = NULL;
+}
+
+FontCollection::FontCollection() :
+ pVDev ( NULL )
+{
+ com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >
+ xMSF = ::comphelper::getProcessServiceFactory();
+ com::sun::star::uno::Reference< com::sun::star::uno::XInterface >
+ xInterface = xMSF->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.i18n.BreakIterator" ) ) );
+ if ( xInterface.is() )
+ xPPTBreakIter = com::sun::star::uno::Reference< com::sun::star::i18n::XBreakIterator >
+ ( xInterface, com::sun::star::uno::UNO_QUERY );
+
+ xInterface = xMSF->createInstance( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.i18n.ScriptTypeDetector" ) ) );
+ if ( xInterface.is() )
+ xScriptTypeDetector = com::sun::star::uno::Reference< com::sun::star::i18n::XScriptTypeDetector >
+ ( xInterface, com::sun::star::uno::UNO_QUERY );
+}
+
+short FontCollection::GetScriptDirection( const String& rString ) const
+{
+ short nRet = com::sun::star::i18n::ScriptDirection::NEUTRAL;
+ if ( xScriptTypeDetector.is() )
+ {
+ const rtl::OUString sT( rString );
+ nRet = xScriptTypeDetector->getScriptDirection( sT, 0, com::sun::star::i18n::ScriptDirection::NEUTRAL );
+ }
+ return nRet;
+}
+
+sal_uInt32 FontCollection::GetId( FontCollectionEntry& rEntry )
+{
+ if( rEntry.Name.Len() )
+ {
+ const sal_uInt32 nFonts = maFonts.size();
+
+ for( sal_uInt32 i = 0; i < nFonts; i++ )
+ {
+ const FontCollectionEntry* pEntry = GetById( i );
+ if( pEntry->Name == rEntry.Name )
+ return i;
+ }
+ Font aFont;
+ aFont.SetCharSet( rEntry.CharSet );
+ aFont.SetName( rEntry.Original );
+ aFont.SetHeight( 100 );
+
+ if ( !pVDev )
+ pVDev = new VirtualDevice;
+
+ pVDev->SetFont( aFont );
+ FontMetric aMetric( pVDev->GetFontMetric() );
+
+ sal_uInt16 nTxtHeight = (sal_uInt16)aMetric.GetAscent() + (sal_uInt16)aMetric.GetDescent();
+
+ if ( nTxtHeight )
+ {
+ double fScaling = (double)nTxtHeight / 120.0;
+ if ( ( fScaling > 0.50 ) && ( fScaling < 1.5 ) )
+ rEntry.Scaling = fScaling;
+ }
+
+ maFonts.push_back(new FontCollectionEntry(rEntry));
+ return nFonts;
+ }
+ return 0;
+}
+
+const FontCollectionEntry* FontCollection::GetById( sal_uInt32 nId )
+{
+ return nId < maFonts.size() ? &maFonts[nId] : NULL;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/eppt/text.hxx b/sd/source/filter/eppt/text.hxx
new file mode 100644
index 000000000..6a0c9fdbc
--- /dev/null
+++ b/sd/source/filter/eppt/text.hxx
@@ -0,0 +1,270 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef EPPT_TEXT_HXX
+#define EPPT_TEXT_HXX
+
+#include "epptbase.hxx"
+#include "epptdef.hxx"
+
+#include <rtl/textenc.h>
+#include <com/sun/star/awt/FontDescriptor.hpp>
+#include <com/sun/star/lang/Locale.hpp>
+
+namespace com { namespace sun { namespace star {
+namespace awt { class FontDescriptor; }
+namespace beans { class XPropertyState; }
+namespace text { class XTextRange; class XTextContent; class XSimpleText; }
+namespace style { class TabStop; }
+}}}
+
+struct SOParagraph
+{
+ sal_Bool bExtendedParameters;
+ sal_uInt32 nParaFlags;
+ sal_Int16 nBulletFlags;
+ String sPrefix;
+ String sSuffix;
+ String sGraphicUrl; // String auf eine Graphic
+ Size aBuGraSize;
+ sal_uInt32 nNumberingType; // in wirlichkeit ist dies ein SvxEnum
+ sal_uInt32 nHorzAdjust;
+ sal_uInt32 nBulletColor;
+ sal_Int32 nBulletOfs;
+ sal_Int16 nStartWith; // Start der nummerierung
+ sal_Int16 nTextOfs;
+ sal_Int16 nBulletRealSize; // GroessenVerhaeltnis in Proz
+ sal_Int16 nDepth; // aktuelle tiefe
+ sal_Unicode cBulletId; // wenn Numbering Type == CharSpecial
+ ::com::sun::star::awt::FontDescriptor aFontDesc;
+
+ sal_Bool bExtendedBulletsUsed;
+ sal_uInt16 nBulletId;
+ sal_uInt32 nMappedNumType;
+ sal_Bool bNumberingIsNumber;
+
+ SOParagraph()
+ {
+ nDepth = 0;
+ bExtendedParameters = sal_False;
+ nParaFlags = 0;
+ nBulletFlags = 0;
+ nBulletOfs = 0;
+ nTextOfs = 0;
+ bExtendedBulletsUsed = sal_False;
+ nBulletId = 0xffff;
+ bNumberingIsNumber = sal_True;
+ };
+};
+
+class PropStateValue : public PropValue
+{
+ protected :
+
+ ::com::sun::star::beans::PropertyState ePropState;
+ ::com::sun::star::uno::Reference
+ < ::com::sun::star::beans::XPropertyState > mXPropState;
+
+ sal_Bool ImplGetPropertyValue( const String& rString, sal_Bool bGetPropertyState = sal_True );
+
+};
+
+struct FieldEntry
+{
+ sal_uInt32 nFieldType;
+ sal_uInt32 nFieldStartPos;
+ sal_uInt32 nFieldEndPos;
+ String aRepresentation;
+ String aFieldUrl;
+
+ FieldEntry( sal_uInt32 nType, sal_uInt32 nStart, sal_uInt32 nEnd )
+ {
+ nFieldType = nType;
+ nFieldStartPos = nStart;
+ nFieldEndPos = nEnd;
+ }
+};
+
+class PortionObj : public PropStateValue
+{
+
+ friend class ParagraphObj;
+
+ protected :
+
+ void ImplClear();
+ void ImplConstruct( PortionObj& rPortionObj );
+ sal_uInt32 ImplGetTextField( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRangeRef,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef, String& rURL );
+ sal_uInt32 ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition );
+ void ImplGetPortionValues( FontCollection& rFontCollection, sal_Bool bGetPropStateValue = sal_False );
+
+ public :
+
+ ::com::sun::star::beans::PropertyState meCharColor;
+ ::com::sun::star::beans::PropertyState meCharHeight;
+ ::com::sun::star::beans::PropertyState meFontName;
+ ::com::sun::star::beans::PropertyState meAsianOrComplexFont;
+ ::com::sun::star::beans::PropertyState meCharEscapement;
+ ::com::sun::star::lang::Locale meCharLocale;
+ sal_uInt16 mnCharAttrHard;
+
+ sal_uInt32 mnCharColor;
+ sal_uInt16 mnCharAttr;
+ sal_uInt16 mnCharHeight;
+ sal_uInt16 mnFont;
+ sal_uInt16 mnAsianOrComplexFont;
+ sal_Int16 mnCharEscapement;
+
+ sal_uInt32 mnTextSize;
+ sal_Bool mbLastPortion;
+
+ sal_uInt16* mpText;
+ FieldEntry* mpFieldEntry;
+
+ PortionObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & rXTextRangeRef,
+ sal_Bool bLast, FontCollection& rFontCollection );
+ PortionObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef,
+ FontCollection& rFontCollection );
+ PortionObj( PortionObj& rPortionObj );
+ ~PortionObj();
+
+ void Write( SvStream* pStrm, sal_Bool bLast );
+ sal_uInt32 Count() const { return mnTextSize; };
+
+ PortionObj& operator=( PortionObj& rPortionObj );
+};
+
+struct ParaFlags
+{
+ sal_Bool bFirstParagraph : 1;
+ sal_Bool bLastParagraph : 1;
+
+ ParaFlags() { bFirstParagraph = sal_True; bLastParagraph = sal_False; };
+};
+
+class ParagraphObj : public List, public PropStateValue, public SOParagraph
+{
+ friend class TextObj;
+ friend struct PPTExParaSheet;
+
+ MapMode maMapModeSrc;
+ MapMode maMapModeDest;
+
+ protected :
+
+ void ImplConstruct( ParagraphObj& rParagraphObj );
+ void ImplClear();
+ sal_uInt32 ImplCalculateTextPositions( sal_uInt32 nCurrentTextPosition );
+ ::com::sun::star::awt::Size ImplMapSize( const ::com::sun::star::awt::Size& rSize );
+ void ImplGetParagraphValues( PPTExBulletProvider& rBuProv, sal_Bool bGetPropStateValue = sal_False );
+ void ImplGetNumberingLevel( PPTExBulletProvider& rBuProv, sal_Int16 nDepth, sal_Bool bIsBullet, sal_Bool bGetPropStateValue = sal_False );
+
+ public :
+
+ ::com::sun::star::uno::Sequence< ::com::sun::star::style::TabStop > maTabStop;
+
+ sal_uInt32 mnTextSize;
+
+ sal_Bool mbIsBullet;
+ sal_Bool mbFirstParagraph;
+ sal_Bool mbLastParagraph;
+
+ ::com::sun::star::beans::PropertyState meBullet;
+ ::com::sun::star::beans::PropertyState meTextAdjust;
+ ::com::sun::star::beans::PropertyState meLineSpacing;
+ ::com::sun::star::beans::PropertyState meLineSpacingTop;
+ ::com::sun::star::beans::PropertyState meLineSpacingBottom;
+ ::com::sun::star::beans::PropertyState meForbiddenRules;
+ ::com::sun::star::beans::PropertyState meParagraphPunctation;
+ ::com::sun::star::beans::PropertyState meBiDi;
+
+ sal_uInt16 mnTextAdjust;
+ sal_Int16 mnLineSpacing;
+ sal_Bool mbFixedLineSpacing;
+ sal_Int16 mnLineSpacingTop;
+ sal_Int16 mnLineSpacingBottom;
+ sal_Bool mbForbiddenRules;
+ sal_Bool mbParagraphPunctation;
+ sal_uInt16 mnBiDi;
+
+ ParagraphObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > & rXTextContentRef,
+ ParaFlags, FontCollection& rFontCollection,
+ PPTExBulletProvider& rBuProv );
+ ParagraphObj( ParagraphObj& rParargraphObj );
+ ParagraphObj( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > & rXPropSetRef,
+ PPTExBulletProvider& rBuProv );
+
+ void CalculateGraphicBulletSize( sal_uInt16 nFontHeight );
+ ~ParagraphObj();
+
+ void Write( SvStream* pStrm );
+ sal_uInt32 Count() const { return mnTextSize; };
+
+ ParagraphObj& operator=( ParagraphObj& rParagraphObj );
+};
+
+struct ImplTextObj
+{
+ sal_uInt32 mnRefCount;
+ sal_uInt32 mnTextSize;
+ int mnInstance;
+ List* mpList;
+ sal_Bool mbHasExtendedBullets;
+ sal_Bool mbFixedCellHeightUsed;
+
+ ImplTextObj( int nInstance );
+ ~ImplTextObj();
+};
+
+class TextObj
+{
+ ImplTextObj* mpImplTextObj;
+ void ImplCalculateTextPositions();
+
+ public :
+ TextObj( ::com::sun::star::uno::Reference< ::com::sun::star::text::XSimpleText > &
+ rXText, int nInstance, FontCollection& rFontCollection, PPTExBulletProvider& rBuProv );
+ TextObj( TextObj& rTextObj );
+ ~TextObj();
+
+ void Write( SvStream* pStrm );
+
+ ParagraphObj* First(){ return (ParagraphObj*)mpImplTextObj->mpList->First(); };
+ ParagraphObj* Next(){ return(ParagraphObj*)mpImplTextObj->mpList->Next(); };
+ sal_uInt32 Count() const { return mpImplTextObj->mnTextSize; };
+ int GetInstance() const { return mpImplTextObj->mnInstance; };
+ sal_Bool HasExtendedBullets(){ return mpImplTextObj->mbHasExtendedBullets; };
+ void WriteTextSpecInfo( SvStream* pStrm );
+
+ TextObj& operator=( TextObj& rTextObj );
+};
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/grf/sdgrffilter.cxx b/sd/source/filter/grf/sdgrffilter.cxx
index 6ff2444a8..c4879143b 100755..100644
--- a/sd/source/filter/grf/sdgrffilter.cxx
+++ b/sd/source/filter/grf/sdgrffilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -207,18 +208,18 @@ sal_Bool SdGRFFilter::Import()
{
Graphic aGraphic;
const String aFileName( mrMedium.GetURLObject().GetMainURL( INetURLObject::NO_DECODE ) );
- GraphicFilter* pGraphicFilter = GraphicFilter::GetGraphicFilter();
- const sal_uInt16 nFilter = pGraphicFilter->GetImportFormatNumberForTypeName( mrMedium.GetFilter()->GetTypeName() );
+ GraphicFilter& rGraphicFilter = GraphicFilter::GetGraphicFilter();
+ const sal_uInt16 nFilter = rGraphicFilter.GetImportFormatNumberForTypeName( mrMedium.GetFilter()->GetTypeName() );
sal_Bool bRet = sal_False;
// ggf. Filterdialog ausfuehren
- if ( !pGraphicFilter->HasImportDialog( nFilter ) || pGraphicFilter->DoImportDialog( NULL, nFilter ) )
+ if ( !rGraphicFilter.HasImportDialog( nFilter ) || rGraphicFilter.DoImportDialog( NULL, nFilter ) )
{
SvStream* pIStm = mrMedium.GetInStream();
- sal_uInt16 nReturn = pIStm ? pGraphicFilter->ImportGraphic( aGraphic, aFileName, *pIStm, nFilter ) : 1;
+ sal_uInt16 nReturn = pIStm ? rGraphicFilter.ImportGraphic( aGraphic, aFileName, *pIStm, nFilter ) : 1;
if( nReturn )
- HandleGraphicFilterError( nReturn, pGraphicFilter->GetLastError().nStreamError );
+ HandleGraphicFilterError( nReturn, rGraphicFilter.GetLastError().nStreamError );
else
{
if( mrDocument.GetPageCount() == 0L )
@@ -275,7 +276,7 @@ sal_Bool SdGRFFilter::Export()
uno::Reference< lang::XMultiServiceFactory >
xSMgr( ::comphelper::getProcessServiceFactory() );
uno::Reference< uno::XInterface > xComponent
- ( xSMgr->createInstance( rtl::OUString::createFromAscii( "com.sun.star.drawing.GraphicExportFilter" ) ),
+ ( xSMgr->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.drawing.GraphicExportFilter" ) ) ),
uno::UNO_QUERY );
if ( xComponent.is() )
{
@@ -309,11 +310,11 @@ sal_Bool SdGRFFilter::Export()
{
uno::Reference< lang::XComponent > xSource( pPage->getUnoPage(), uno::UNO_QUERY );
SfxItemSet* pSet = mrMedium.GetItemSet();
- GraphicFilter* pGraphicFilter = GraphicFilter::GetGraphicFilter();
- if ( pSet && pGraphicFilter && xSource.is() )
+ if ( pSet && xSource.is() )
{
const String aTypeName( mrMedium.GetFilter()->GetTypeName() );
- const sal_uInt16 nFilter = pGraphicFilter->GetExportFormatNumberForTypeName( aTypeName );
+ GraphicFilter &rGraphicFilter = GraphicFilter::GetGraphicFilter();
+ const sal_uInt16 nFilter = rGraphicFilter.GetExportFormatNumberForTypeName( aTypeName );
if ( nFilter != GRFILTER_FORMAT_NOTFOUND )
{
uno::Reference< task::XInteractionHandler > mXInteractionHandler;
@@ -323,7 +324,7 @@ sal_Bool SdGRFFilter::Export()
rtl::OUString sInteractionHandler( RTL_CONSTASCII_USTRINGPARAM( "InteractionHandler" ) );
rtl::OUString sFilterName( RTL_CONSTASCII_USTRINGPARAM( "FilterName" ) );
- rtl::OUString sShortName( pGraphicFilter->GetExportFormatShortName( nFilter ) );
+ rtl::OUString sShortName( rGraphicFilter.GetExportFormatShortName( nFilter ) );
sal_Bool bFilterNameFound = sal_False;
sal_Int32 i, nCount;
@@ -373,7 +374,7 @@ sal_Bool SdGRFFilter::Export()
if ( !bRet && mXInteractionHandler.is() )
SdGRFFilter::HandleGraphicFilterError(
static_cast< SdGRFFilter_ImplInteractionHdl* >( mXInteractionHandler.get() )->GetErrorCode(),
- pGraphicFilter->GetLastError().nStreamError );
+ rGraphicFilter.GetLastError().nStreamError );
}
}
}
@@ -439,7 +440,7 @@ void SdGRFFilter::SaveGraphic( const ::com::sun::star::uno::Reference< ::com::su
switch( nGraphicType )
{
case ::com::sun::star::graphic::GraphicType::VECTOR:
- aMimeType = OUString::createFromAscii( "image/x-svm" );
+ aMimeType = OUString(RTL_CONSTASCII_USTRINGPARAM( "image/x-svm" ) );
break;
case ::com::sun::star::graphic::GraphicType::PIXEL:
@@ -449,14 +450,12 @@ void SdGRFFilter::SaveGraphic( const ::com::sun::star::uno::Reference< ::com::su
if( bAnimated )
{
- aMimeType = OUString::createFromAscii( "image/gif" );
+ aMimeType = OUString(RTL_CONSTASCII_USTRINGPARAM( "image/gif" ) );
break;
}
}
- // Fallthrough!
-// case ::com::sun::star::graphic::GraphicType::EMPTY:
default:
- aMimeType = OUString::createFromAscii( "image/png" );
+ aMimeType = OUString(RTL_CONSTASCII_USTRINGPARAM( "image/png" ) );
break;
}
}
@@ -477,7 +476,7 @@ void SdGRFFilter::SaveGraphic( const ::com::sun::star::uno::Reference< ::com::su
// populate filter dialog filter list and select default filter to match graphic mime type
- GraphicFilter& rGF = *GraphicFilter::GetGraphicFilter();
+ GraphicFilter& rGF = GraphicFilter::GetGraphicFilter();
Reference<XFilterManager> xFltMgr(xFP, UNO_QUERY);
OUString aDefaultFormatName;
sal_uInt16 nCount = rGF.GetExportFormatCount();
@@ -548,7 +547,7 @@ void SdGRFFilter::SaveGraphic( const ::com::sun::star::uno::Reference< ::com::su
}
catch( Exception& )
{
- DBG_ERROR(
+ OSL_FAIL(
(rtl::OString("SdGRFFilter::SaveGraphic(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -556,3 +555,5 @@ void SdGRFFilter::SaveGraphic( const ::com::sun::star::uno::Reference< ::com::su
RTL_TEXTENCODING_UTF8 )).getStr() );
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/HtmlOptionsDialog.cxx b/sd/source/filter/html/HtmlOptionsDialog.cxx
index 377907682..1b2b3d179 100644
--- a/sd/source/filter/html/HtmlOptionsDialog.cxx
+++ b/sd/source/filter/html/HtmlOptionsDialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,7 +30,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
#include <osl/file.hxx>
-#include <vos/module.hxx>
+#include <osl/module.hxx>
#include <com/sun/star/frame/XModel.hpp>
#include <com/sun/star/document/XViewDataSupplier.hpp>
#include <com/sun/star/container/XIndexAccess.hpp>
@@ -199,7 +200,7 @@ Sequence< PropertyValue > SdHtmlOptionsDialog::getPropertyValues()
sal_Int32 i, nCount;
for ( i = 0, nCount = maMediaDescriptor.getLength(); i < nCount; i++ )
{
- if ( maMediaDescriptor[ i ].Name.equalsAscii( "FilterData" ) )
+ if ( maMediaDescriptor[ i ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FilterData" ) ) )
break;
}
if ( i == nCount )
@@ -221,7 +222,7 @@ void SdHtmlOptionsDialog::setPropertyValues( const Sequence< PropertyValue > & a
sal_Int32 i, nCount;
for ( i = 0, nCount = maMediaDescriptor.getLength(); i < nCount; i++ )
{
- if ( maMediaDescriptor[ i ].Name.equalsAscii( "FilterData" ) )
+ if ( maMediaDescriptor[ i ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FilterData" ) ) )
{
maMediaDescriptor[ i ].Value >>= maFilterDataSequence;
break;
@@ -285,3 +286,5 @@ void SdHtmlOptionsDialog::setSourceDocument( const Reference< XComponent >& xDoc
}
throw IllegalArgumentException();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/buttonset.cxx b/sd/source/filter/html/buttonset.cxx
index 0cb5032eb..5502b3c3f 100644
--- a/sd/source/filter/html/buttonset.cxx
+++ b/sd/source/filter/html/buttonset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -76,7 +77,7 @@ ButtonsImpl::ButtonsImpl( const OUString& rURL )
}
catch( Exception& )
{
- DBG_ERROR("sd::ButtonsImpl::ButtonsImpl(), exception caught!" );
+ OSL_FAIL("sd::ButtonsImpl::ButtonsImpl(), exception caught!" );
}
}
@@ -91,7 +92,7 @@ Reference< XInputStream > ButtonsImpl::getInputStream( const OUString& rName )
}
catch( Exception& )
{
- DBG_ERROR( "sd::ButtonsImpl::getInputStream(), exception caught!" );
+ OSL_FAIL( "sd::ButtonsImpl::getInputStream(), exception caught!" );
}
return xInputStream;
}
@@ -102,7 +103,7 @@ bool ButtonsImpl::getGraphic( const Reference< XGraphicProvider >& xGraphicProvi
if( xInputStream.is() && xGraphicProvider.is() ) try
{
Sequence< PropertyValue > aMediaProperties( 1 );
- aMediaProperties[0].Name = ::rtl::OUString::createFromAscii( "InputStream" );
+ aMediaProperties[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "InputStream" ) );
aMediaProperties[0].Value <<= xInputStream;
Reference< XGraphic > xGraphic( xGraphicProvider->queryGraphic( aMediaProperties ) );
@@ -114,7 +115,7 @@ bool ButtonsImpl::getGraphic( const Reference< XGraphicProvider >& xGraphicProvi
}
catch( Exception& )
{
- DBG_ERROR( "sd::ButtonsImpl::getGraphic(), exception caught!" );
+ OSL_FAIL( "sd::ButtonsImpl::getGraphic(), exception caught!" );
}
return false;
}
@@ -126,7 +127,7 @@ bool ButtonsImpl::copyGraphic( const OUString& rName, const OUString& rPath )
{
osl::File::remove( rPath );
osl::File aOutputFile( rPath );
- if( aOutputFile.open( OpenFlag_Write|OpenFlag_Create ) == osl::FileBase::E_None )
+ if( aOutputFile.open( osl_File_OpenFlag_Write|osl_File_OpenFlag_Create ) == osl::FileBase::E_None )
{
Reference< XOutputStream > xOutput( new comphelper::OSLOutputStreamWrapper( aOutputFile ) );
comphelper::OStorageHelper::CopyInputToOutput( xInput, xOutput );
@@ -135,7 +136,7 @@ bool ButtonsImpl::copyGraphic( const OUString& rName, const OUString& rPath )
}
catch( Exception& )
{
- DBG_ERROR( "sd::ButtonsImpl::copyGraphic(), exception caught!" );
+ OSL_FAIL( "sd::ButtonsImpl::copyGraphic(), exception caught!" );
}
return false;
@@ -182,7 +183,7 @@ void ButtonSetImpl::scanForButtonSets( const OUString& rPath )
osl::DirectoryItem aItem;
while( aDirectory.getNextItem( aItem, 2211 ) == osl::FileBase::E_None )
{
- osl::FileStatus aStatus( FileStatusMask_FileName|FileStatusMask_FileURL );
+ osl::FileStatus aStatus( osl_FileStatus_Mask_FileName|osl_FileStatus_Mask_FileURL );
if( aItem.getFileStatus( aStatus ) == osl::FileBase::E_None )
{
OUString sFileName( aStatus.getFileName() );
@@ -275,7 +276,7 @@ Reference< XGraphicProvider > ButtonSetImpl::getGraphicProvider()
}
catch( Exception& )
{
- DBG_ERROR("sd::ButtonSetImpl::getGraphicProvider(), could not get graphic provider!");
+ OSL_FAIL("sd::ButtonSetImpl::getGraphicProvider(), could not get graphic provider!");
}
}
return mxGraphicProvider;
@@ -307,3 +308,4 @@ bool ButtonSet::exportButton( int nSet, const rtl::OUString& rPath, const rtl::O
return mpImpl->exportButton( nSet, rPath, rName );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/buttonset.hxx b/sd/source/filter/html/buttonset.hxx
index 6cd867bc6..ccb93f27b 100644
--- a/sd/source/filter/html/buttonset.hxx
+++ b/sd/source/filter/html/buttonset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,6 +29,8 @@
#ifndef _SD_HTMLEX_BUTTONSET_HXX
#define _SD_HTMLEX_BUTTONSET_HXX
+#include <sddllapi.h>
+
#include <rtl/ustring.hxx>
#include <boost/scoped_ptr.hpp>
#include <vector>
@@ -35,7 +38,7 @@
class Image;
class ButtonSetImpl;
-class ButtonSet
+class SD_DLLPUBLIC ButtonSet
{
public:
ButtonSet();
@@ -51,3 +54,5 @@ private:
};
#endif // _SD_HTMLEX_BUTTONSET_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/htmlattr.cxx b/sd/source/filter/html/htmlattr.cxx
index 57c984a37..57a7d741b 100755..100644
--- a/sd/source/filter/html/htmlattr.cxx
+++ b/sd/source/filter/html/htmlattr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,7 +44,6 @@
SdHtmlAttrPreview::SdHtmlAttrPreview( Window* pParent, const ResId& rResId )
:Control( pParent, rResId )
{
-// SetMapMode( MAP_100TH_MM );
}
// =====================================================================
@@ -100,3 +100,5 @@ void SdHtmlAttrPreview::SetColors( Color& aBack, Color& aText, Color& aLink,
m_aVLinkColor = aVLink;
m_aALinkColor = aALink;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/htmlattr.hxx b/sd/source/filter/html/htmlattr.hxx
index a93da62b8..97b215e79 100755..100644
--- a/sd/source/filter/html/htmlattr.hxx
+++ b/sd/source/filter/html/htmlattr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,5 @@ public:
};
#endif // _SD_HTMLATTR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/htmlex.cxx b/sd/source/filter/html/htmlex.cxx
index c3d9a52d6..dd5ffc690 100755..100644
--- a/sd/source/filter/html/htmlex.cxx
+++ b/sd/source/filter/html/htmlex.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,9 +40,7 @@
#include <tools/fsys.hxx>
#include <unotools/pathoptions.hxx>
#include <svtools/FilterConfigItem.hxx>
-#ifndef _UNOTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
#include <unotools/localfilehelper.hxx>
#include <com/sun/star/frame/XStorable.hpp>
#include <sfx2/progress.hxx>
@@ -388,7 +387,7 @@ HtmlExport::HtmlExport(
meMode( PUBLISH_HTML ),
mbContentsPage(false),
mnButtonThema(-1),
- mnWidthPixel( PUB_LOWRES_WIDTH ),
+ mnWidthPixel( PUB_MEDRES_WIDTH ),
meFormat( FORMAT_JPG ),
mbNotes(false),
mnCompression( -1 ),
@@ -400,6 +399,7 @@ HtmlExport::HtmlExport(
maHTMLExtension(SdResId(STR_HTMLEXP_DEFAULT_EXTENSION)),
mpHTMLFiles(NULL),
mpImageFiles(NULL),
+ mpThumbnailFiles(NULL),
mpPageNames(NULL),
mpTextFiles(NULL),
maIndexUrl(RTL_CONSTASCII_USTRINGPARAM("index")),
@@ -438,12 +438,13 @@ HtmlExport::~HtmlExport()
// ------------------------------------------------------------------
// Listen loeschen
// ------------------------------------------------------------------
- if(mpImageFiles && mpHTMLFiles && mpPageNames && mpTextFiles)
+ if(mpImageFiles && mpHTMLFiles && mpThumbnailFiles && mpPageNames && mpTextFiles )
{
for ( sal_uInt16 nSdPage = 0; nSdPage < mnSdPageCount; nSdPage++)
{
delete mpImageFiles[nSdPage];
delete mpHTMLFiles[nSdPage];
+ delete mpThumbnailFiles[nSdPage];
delete mpPageNames[nSdPage];
delete mpTextFiles[nSdPage];
}
@@ -451,6 +452,7 @@ HtmlExport::~HtmlExport()
delete[] mpImageFiles;
delete[] mpHTMLFiles;
+ delete[] mpThumbnailFiles;
delete[] mpPageNames;
delete[] mpTextFiles;
}
@@ -637,7 +639,7 @@ void HtmlExport::InitExportParameters( const Sequence< PropertyValue >& rParams
}
else
{
- DBG_ERROR("Unknown property for html export detected!");
+ OSL_FAIL("Unknown property for html export detected!");
}
pParams++;
@@ -655,21 +657,6 @@ void HtmlExport::InitExportParameters( const Sequence< PropertyValue >& rParams
Size aTmpSize( pPage->GetSize() );
double dRatio=((double)aTmpSize.Width())/aTmpSize.Height();
-/*
- switch( mnWidthPixel )
- {
- case 800:
- mnWidthPixel = 640;
- break;
- case 1024:
- mnWidthPixel = 800;
- break;
- case 640:
- default:
- mnWidthPixel = 512;
- break;
- }
-*/
mnHeightPixel = (sal_uInt16)(mnWidthPixel/dRatio);
//------------------------------------------------------------------
@@ -682,7 +669,6 @@ void HtmlExport::InitExportParameters( const Sequence< PropertyValue >& rParams
maIndex = aINetURLObj.GetLastName();
mnSdPageCount = mpDoc->GetSdPageCount( PK_STANDARD );
-// sal_uInt16 nHiddenSlides = 0;
for( sal_uInt16 nPage = 0; nPage < mnSdPageCount; nPage++ )
{
pPage = mpDoc->GetSdPage( nPage, PK_STANDARD );
@@ -757,6 +743,11 @@ void HtmlExport::ExportHtml()
if( !CreateImagesForPresPages() )
break;
+ if( mbContentsPage &&
+ !CreateImagesForPresPages( true ) )
+ break;
+
+
if( !CreateHtmlForPresPages() )
break;
@@ -990,7 +981,7 @@ bool HtmlExport::SavePresentation()
// =====================================================================
// Image-Dateien anlegen
// =====================================================================
-bool HtmlExport::CreateImagesForPresPages()
+bool HtmlExport::CreateImagesForPresPages( bool bThumbnail)
{
try
{
@@ -1007,9 +998,9 @@ bool HtmlExport::CreateImagesForPresPages()
Sequence< PropertyValue > aFilterData(((meFormat==FORMAT_JPG)&&(mnCompression != -1))? 3 : 2);
aFilterData[0].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("PixelWidth") );
- aFilterData[0].Value <<= (sal_Int32)mnWidthPixel;
+ aFilterData[0].Value <<= (sal_Int32)(bThumbnail ? PUB_THUMBNAIL_WIDTH : mnWidthPixel );
aFilterData[1].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("PixelHeight") );
- aFilterData[1].Value <<= (sal_Int32)mnHeightPixel;
+ aFilterData[1].Value <<= (sal_Int32)(bThumbnail ? PUB_THUMBNAIL_HEIGHT : mnHeightPixel);
if((meFormat==FORMAT_JPG)&&(mnCompression != -1))
{
aFilterData[2].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("Quality") );
@@ -1036,7 +1027,11 @@ bool HtmlExport::CreateImagesForPresPages()
SdPage* pPage = maPages[ nSdPage ];
OUString aFull(maExportPath);
- aFull += *mpImageFiles[nSdPage];
+ if (bThumbnail)
+ aFull += *mpThumbnailFiles[nSdPage];
+ else
+ aFull += *mpImageFiles[nSdPage];
+
aDescriptor[0].Value <<= aFull;
@@ -1108,7 +1103,6 @@ bool HtmlExport::CreateHtmlTextForPresPages()
if( mbDocColors )
{
SetDocColors( pPage );
-// maBackColor = pPage->GetPageBackgroundColor();
}
// HTML Kopf
@@ -1495,7 +1489,7 @@ bool HtmlExport::CreateHtmlForPresPages()
{
bool bOk = true;
- List aClickableObjects;
+ std::vector<SdrObject*> aClickableObjects;
for(sal_uInt16 nSdPage = 0; nSdPage < mnSdPageCount && bOk; nSdPage++)
{
@@ -1533,7 +1527,7 @@ bool HtmlExport::CreateHtmlForPresPages()
pInfo->meClickAction == presentation::ClickAction_LASTPAGE)) ||
pIMapInfo)
{
- aClickableObjects.Insert(pObject, LIST_APPEND);
+ aClickableObjects.push_back(pObject);
}
pObject = aIter.Next();
@@ -1544,7 +1538,6 @@ bool HtmlExport::CreateHtmlForPresPages()
else
bMasterDone = true;
}
- sal_uLong nClickableObjectCount = aClickableObjects.Count();
// HTML Head
String aStr(maHTMLHeader);
@@ -1609,7 +1602,7 @@ bool HtmlExport::CreateHtmlForPresPages()
aStr += StringToURL( *mpImageFiles[nSdPage] );
aStr.AppendAscii( "\" alt=\"\"" );
- if (nClickableObjectCount > 0)
+ if (!aClickableObjects.empty())
aStr.AppendAscii( " USEMAP=\"#map0\"" );
aStr.AppendAscii( "></center>\r\n" );
@@ -1634,13 +1627,13 @@ bool HtmlExport::CreateHtmlForPresPages()
}
// ggfs. Imagemap erzeugen
- if (nClickableObjectCount > 0)
+ if (!aClickableObjects.empty())
{
aStr.AppendAscii( "<map name=\"map0\">\r\n" );
- for (sal_uLong nObject = 0; nObject < nClickableObjectCount; nObject++)
+ for (sal_uInt32 nObject = 0, n = aClickableObjects.size(); nObject < n; nObject++)
{
- SdrObject* pObject = (SdrObject*)aClickableObjects.GetObject(nObject);
+ SdrObject* pObject = aClickableObjects[nObject];
SdAnimationInfo* pInfo = mpDoc->GetAnimationInfo(pObject);
SdIMapInfo* pIMapInfo = mpDoc->GetIMapInfo(pObject);
@@ -1854,7 +1847,7 @@ bool HtmlExport::CreateHtmlForPresPages()
aStr.AppendAscii( "</map>\r\n" );
}
- aClickableObjects.Clear();
+ aClickableObjects.clear();
aStr.AppendAscii( "</body>\r\n</html>" );
@@ -1898,7 +1891,7 @@ bool HtmlExport::CreateContentPage()
aStr.AppendAscii( "<h2>" );
- // #92564# Solaris compiler bug workaround
+ // Solaris compiler bug workaround
if( mbFrames )
aStr += CreateLink( maFramePage,
RESTOHTML(STR_HTMLEXP_CLICKSTART) );
@@ -1911,7 +1904,7 @@ bool HtmlExport::CreateContentPage()
aStr.AppendAscii( "<center><table width=\"90%\"><tr>\r\n" );
// Inhaltsverzeichnis
- aStr.AppendAscii( "<td valign=\"top\" align=\"left\" width=\"50%\">\r\n" );
+ aStr.AppendAscii( "<td valign=\"top\" align=\"left\" width=\"25%\">\r\n" );
aStr.AppendAscii( "<h3>" );
aStr += RESTOHTML(STR_HTMLEXP_CONTENTS);
aStr.AppendAscii( "</h3>" );
@@ -1929,7 +1922,7 @@ bool HtmlExport::CreateContentPage()
aStr.AppendAscii( "</td>\r\n" );
// Dokument Infos
- aStr.AppendAscii( "<td valign=\"top\" width=\"50%\">\r\n" );
+ aStr.AppendAscii( "<td valign=\"top\" align=\"left\" width=\"75%\">\r\n" );
if(maAuthor.Len())
{
@@ -1980,6 +1973,21 @@ bool HtmlExport::CreateContentPage()
aStr.AppendAscii( "</a></p>\r\n" );
}
+ for(sal_uInt16 nSdPage = 0; nSdPage < mnSdPageCount; nSdPage++)
+ {
+ String aText;
+
+ aText.AppendAscii( "<img src=\"" );
+ aText += StringToURL( *mpThumbnailFiles[nSdPage] );
+ aText.AppendAscii( "\" width=\"256\" height=\"192\" alt=\"" );
+ aText += StringToHTMLString( *mpPageNames[nSdPage] );
+ aText.AppendAscii( "\">" );
+
+ aStr += CreateLink(*mpHTMLFiles[nSdPage], aText);
+ aStr.AppendAscii( "\r\n" );
+ }
+
+
aStr.AppendAscii( "</td></tr></table></center>\r\n" );
aStr.AppendAscii( "</body>\r\n</html>" );
@@ -2104,6 +2112,7 @@ void HtmlExport::CreateFileNames()
// Listen mit neuen Dateinamen anlegen
mpHTMLFiles = new String*[mnSdPageCount];
mpImageFiles = new String*[mnSdPageCount];
+ mpThumbnailFiles = new String*[mnSdPageCount];
mpPageNames = new String*[mnSdPageCount];
mpTextFiles = new String*[mnSdPageCount];
@@ -2134,6 +2143,15 @@ void HtmlExport::CreateFileNames()
mpImageFiles[nSdPage] = pName;
+ pName = new String( RTL_CONSTASCII_USTRINGPARAM("thumb") );
+ *pName += String::CreateFromInt32(nSdPage);
+ if( meFormat!=FORMAT_JPG )
+ pName->AppendAscii( ".png" );
+ else
+ pName->AppendAscii( ".jpg" );
+
+ mpThumbnailFiles[nSdPage] = pName;
+
pName = new String( RTL_CONSTASCII_USTRINGPARAM("text"));
*pName += String::CreateFromInt32(nSdPage);
*pName += maHTMLExtension;
@@ -2203,50 +2221,6 @@ String HtmlExport::getDocumentTitle()
return mDocTitle;
}
-/*
-var nCurrentPage = 0;
-var nPageCount = JSCRIPT2;
-
-function NavigateAbs( nPage )
-{
- frames[\"show\"].location.href = \"img\" + nPage + \".htm\";
- frames[\"notes\"].location.href = \"note\" + nPage + \".htm\";
- nCurrentPage = nPage;
- if(nCurrentPage==0)
- {
- frames[\"navbar1\"].location.href = \"navbar0.htm\";
- }
- else if(nCurrentPage==nPageCount-1)
- {
- frames[\"navbar1\"].location.href = \"navbar2.htm\";
- }
- else
- frames[\"navbar1\"].location.href = \"navbar1.htm\";
- }
-}
-
-function NavigateRel( nDelta )
-{
- var nPage = parseInt(nCurrentPage) + parseInt(nDelta);
- if( (nPage >= 0) && (nPage < nPageCount) )
- {
- NavigateAbs( nPage );
- }
-}
-
-function ExpandOutline()
-{
- frames[\"navbar2\"].location.href = \"navbar4.htm\";
- frames[\"outline\"].location.href = \"outline1.htm\";
-}
-
-function CollapseOutline()
-{
- frames[\"navbar2\"].location.href = \"navbar3.htm\";
- frames[\"outline\"].location.href = \"outline0.htm\";
-}
-*/
-
static const char* JS_NavigateAbs =
"function NavigateAbs( nPage )\r\n"
"{\r\n"
@@ -3146,7 +3120,7 @@ bool HtmlExport::checkFileExists( Reference< ::com::sun::star::ucb::XSimpleFileA
catch( com::sun::star::uno::Exception& e )
{
(void)e;
- DBG_ERROR((OString("sd::HtmlExport::checkFileExists(), exception caught: ") +
+ OSL_FAIL((OString("sd::HtmlExport::checkFileExists(), exception caught: ") +
rtl::OUStringToOString( comphelper::anyToString( cppu::getCaughtException() ), RTL_TEXTENCODING_UTF8 )).getStr() );
}
@@ -3170,6 +3144,7 @@ bool HtmlExport::checkForExistingFiles()
{
if( (mpImageFiles[nSdPage] && checkFileExists( xFA, *mpImageFiles[nSdPage] )) ||
(mpHTMLFiles[nSdPage] && checkFileExists( xFA, *mpHTMLFiles[nSdPage] )) ||
+ (mpThumbnailFiles[nSdPage] && checkFileExists( xFA, *mpThumbnailFiles[nSdPage] )) ||
(mpPageNames[nSdPage] && checkFileExists( xFA, *mpPageNames[nSdPage] )) ||
(mpTextFiles[nSdPage] && checkFileExists( xFA, *mpTextFiles[nSdPage] )) )
{
@@ -3209,7 +3184,7 @@ bool HtmlExport::checkForExistingFiles()
catch( Exception& e )
{
(void)e;
- DBG_ERROR((OString("sd::HtmlExport::checkForExistingFiles(), exception caught: ") +
+ OSL_FAIL((OString("sd::HtmlExport::checkForExistingFiles(), exception caught: ") +
rtl::OUStringToOString( comphelper::anyToString( cppu::getCaughtException() ), RTL_TEXTENCODING_UTF8 )).getStr() );
bFound = false;
}
@@ -3222,13 +3197,6 @@ bool HtmlExport::checkForExistingFiles()
String HtmlExport::StringToURL( const String& rURL )
{
return rURL;
-/*
- return StringToHTMLString(rURL);
- OUString aURL( StringToHTMLString(rURL) );
-
- aURL = Uri::encode( aURL, rtl_UriCharClassUric, rtl_UriEncodeCheckEscapes, RTL_TEXTENCODING_UTF8);
- return String( aURL );
-*/
}
String HtmlExport::GetButtonName( int nButton ) const
@@ -3390,3 +3358,4 @@ void HtmlErrorContext::SetContext( sal_uInt16 nResId, const String& rURL1, const
// =====================================================================
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/htmlex.hxx b/sd/source/filter/html/htmlex.hxx
index 2401a729a..c67b4d5cf 100755..100644
--- a/sd/source/filter/html/htmlex.hxx
+++ b/sd/source/filter/html/htmlex.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,9 +43,7 @@
#include "ViewShell.hxx"
#include "assclass.hxx"
-#ifndef _SD_RESID_HXX
#include "sdresid.hxx"
-#endif
#include "pubdlg.hxx"
#include <vector>
@@ -59,9 +58,11 @@
#define PUB_HIGHRES_WIDTH 1024
#define PUB_HIGHRES_HEIGHT 768
+#define PUB_THUMBNAIL_WIDTH 256
+#define PUB_THUMBNAIL_HEIGHT 192
+
#define HtmlButtonThemaStr = "private://gallery/hidden/HtmlExportButtons";
-class List;
class SfxProgress;
class SdrOutliner;
class SdPage;
@@ -150,6 +151,7 @@ class HtmlExport
String maHTMLExtension;
String** mpHTMLFiles;
String** mpImageFiles;
+ String** mpThumbnailFiles;
String** mpPageNames;
String** mpTextFiles;
@@ -167,7 +169,7 @@ class HtmlExport
void SetDocColors( SdPage* pPage = NULL );
- bool CreateImagesForPresPages();
+ bool CreateImagesForPresPages( bool bThumbnails = false );
bool CreateHtmlTextForPresPages();
bool CreateHtmlForPresPages();
bool CreateContentPage();
@@ -237,3 +239,5 @@ class HtmlExport
};
#endif // _SD_HTMLEX_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/makefile.mk b/sd/source/filter/html/makefile.mk
deleted file mode 100644
index dc2287643..000000000
--- a/sd/source/filter/html/makefile.mk
+++ /dev/null
@@ -1,68 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=html
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE;
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-INCPRE += ..$/..$/ui$/inc
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/HtmlOptionsDialog.obj\
- $(SLO)$/buttonset.obj \
- $(SLO)$/sdhtmlfilter.obj \
- $(SLO)$/htmlex.obj \
- $(SLO)$/htmlattr.obj \
- $(SLO)$/pubdlg.obj
-
-SRS1NAME=$(TARGET)
-SRC1FILES = pubdlg.src
-
-LIB1TARGET= $(SLB)$/$(TARGET).lib
-LIB1OBJFILES = \
- $(SLO)$/HtmlOptionsDialog.obj\
- $(SLO)$/sdhtmlfilter.obj \
- $(SLO)$/buttonset.obj \
- $(SLO)$/htmlex.obj
-
-LIB2TARGET= $(SLB)$/$(TARGET)_ui.lib
-LIB2OBJFILES = \
- $(SLO)$/htmlattr.obj \
- $(SLO)$/buttonset.obj \
- $(SLO)$/pubdlg.obj
-
-# --- Targets --------------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/filter/html/pubdlg.cxx b/sd/source/filter/html/pubdlg.cxx
index e0cc141e2..3b342a72f 100755..100644
--- a/sd/source/filter/html/pubdlg.cxx
+++ b/sd/source/filter/html/pubdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,9 +36,7 @@
#include <unotools/ucbstreamhelper.hxx>
#include <vcl/lstbox.hxx>
#include <svtools/FilterConfigItem.hxx>
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
#include <vcl/fixed.hxx>
#include <vcl/combobox.hxx>
#include <svtools/svmedit.hxx>
@@ -52,7 +51,6 @@
#include <svtools/colrdlg.hxx>
#include <editeng/colritem.hxx>
#include <tools/urlobj.hxx>
-#include <tools/list.hxx>
#include <sdiocmpt.hxx>
#include <sfx2/docfile.hxx>
#include <sfx2/app.hxx>
@@ -69,10 +67,11 @@
#include "buttonset.hxx"
using namespace std;
-using namespace rtl;
using namespace com::sun::star::uno;
using namespace com::sun::star::beans;
+using ::rtl::OUString;
+
extern void InterpolateFixedBitmap( FixedBitmap * pBitmap );
// Kennung fuer die Config Datei mit den Html Einstellungen
@@ -175,7 +174,6 @@ SdPublishingDesign::SdPublishingDesign()
m_aAuthor += (String)aUserOptions.GetLastName();
m_aEMail = aUserOptions.GetEmail();
m_bDownload = sal_False;
-//-/ m_bCreated = sal_True;
m_nButtonThema = -1;
m_bUserAttr = sal_False;
@@ -220,7 +218,6 @@ int SdPublishingDesign::operator ==(const SdPublishingDesign & rDesign) const
m_aWWW == rDesign.m_aWWW &&
m_aMisc == rDesign.m_aMisc &&
m_bDownload == rDesign.m_bDownload &&
-//-/ m_bCreated == rDesign.m_bCreated &&
m_nButtonThema == rDesign.m_nButtonThema &&
m_bUserAttr == rDesign.m_bUserAttr &&
m_aBackColor == rDesign.m_aBackColor &&
@@ -467,13 +464,9 @@ SdPublishingDlg::SdPublishingDlg(Window* pWindow, DocumentType eDocType)
pPage5_Buttons->SetLineCount( 4 );
pPage5_Buttons->SetExtraSpacing( 1 );
- for( sal_uInt16 nIndex = 0; nIndex < m_pDesignList->Count(); nIndex++ )
- {
- SdPublishingDesign *pDesign = (SdPublishingDesign*)
- m_pDesignList->GetObject(nIndex);
-
- pPage1_Designs->InsertEntry(pDesign->m_aDesignName);
- }
+ boost::ptr_vector<SdPublishingDesign>::iterator it;
+ for( it = m_aDesignList.begin(); it != m_aDesignList.end(); ++it )
+ pPage1_Designs->InsertEntry(it->m_aDesignName);
pPage6_Preview->SetBorderStyle(WINDOW_BORDER_MONO);
@@ -489,13 +482,6 @@ SdPublishingDlg::SdPublishingDlg(Window* pWindow, DocumentType eDocType)
// =====================================================================
SdPublishingDlg::~SdPublishingDlg()
{
- if( m_pDesignList )
- {
- for( sal_uInt16 nIndex = 0; nIndex < m_pDesignList->Count(); nIndex++ )
- delete (SdPublishingDesign*)m_pDesignList->GetObject(nIndex);
- }
-
- delete m_pDesignList;
RemovePages();
}
@@ -640,8 +626,6 @@ void SdPublishingDlg::CreatePages()
if(m_bImpress)
aAssistentFunc.InsertControl(4,
pPage4_Download = new CheckBox(this,SdResId(PAGE4_DOWNLOAD)));
-//-/ aAssistentFunc.InsertControl(4,
-//-/ pPage4_Created = new CheckBox(this,SdResId(PAGE4_CREATED)));
// Seite 5
aAssistentFunc.InsertControl(5,
@@ -767,7 +751,6 @@ void SdPublishingDlg::RemovePages()
delete pPage4_Misc;
if(m_bImpress)
delete pPage4_Download;
-//-/ delete pPage4_Created;
delete pPage5_Bmp;
delete pPage5_Titel;
@@ -905,7 +888,7 @@ void SdPublishingDlg::GetParameterSequence( Sequence< PropertyValue >& rParams )
aValue.Value <<= OUString( pPage4_Email->GetText() );
aProps.push_back( aValue );
- // #92433# try to guess protocol for user's homepage
+ // try to guess protocol for user's homepage
INetURLObject aHomeURL( pPage4_WWW->GetText(),
INET_PROT_HTTP, // default proto is HTTP
INetURLObject::ENCODE_ALL );
@@ -965,13 +948,12 @@ void SdPublishingDlg::GetParameterSequence( Sequence< PropertyValue >& rParams )
}
// Seite 6
-// aSet.Put(SfxBoolItem(ATTR_PUBLISH_SLIDESOUND,pPage6_Sound->IsChecked()));
rParams.realloc( aProps.size() );
PropertyValue* pParams = rParams.getArray();
- for( std::vector< PropertyValue >::iterator i = aProps.begin(); i != aProps.end(); i++ )
+ for( std::vector< PropertyValue >::iterator i = aProps.begin(); i != aProps.end(); ++i )
{
*pParams++ = (*i);
}
@@ -1003,7 +985,7 @@ IMPL_LINK( SdPublishingDlg, DesignHdl, RadioButton *, pButton )
pPage1_Designs->SelectEntryPos(0);
sal_uInt16 nPos = pPage1_Designs->GetSelectEntryPos();
- m_pDesign = (SdPublishingDesign*)m_pDesignList->GetObject(nPos);
+ m_pDesign = &m_aDesignList[nPos];
DBG_ASSERT(m_pDesign, "Kein Design? Das darf nicht sein! (CL)");
if(m_pDesign)
@@ -1019,7 +1001,7 @@ IMPL_LINK( SdPublishingDlg, DesignHdl, RadioButton *, pButton )
IMPL_LINK( SdPublishingDlg, DesignSelectHdl, ListBox *, EMPTYARG )
{
sal_uInt16 nPos = pPage1_Designs->GetSelectEntryPos();
- m_pDesign = (SdPublishingDesign*)m_pDesignList->GetObject(nPos);
+ m_pDesign = &m_aDesignList[nPos];
DBG_ASSERT(m_pDesign, "Kein Design? Das darf nicht sein! (CL)");
if(m_pDesign)
@@ -1036,20 +1018,17 @@ IMPL_LINK( SdPublishingDlg, DesignSelectHdl, ListBox *, EMPTYARG )
IMPL_LINK( SdPublishingDlg, DesignDeleteHdl, PushButton *, EMPTYARG )
{
sal_uInt16 nPos = pPage1_Designs->GetSelectEntryPos();
- SdPublishingDesign* pDesign = (SdPublishingDesign*)
- m_pDesignList->GetObject(nPos);
- DBG_ASSERT(pDesign, "Kein Design? Das darf nicht sein! (CL)");
- if(pDesign)
- {
- m_pDesignList->Remove(pDesign);
- pPage1_Designs->RemoveEntry(nPos);
- }
+ boost::ptr_vector<SdPublishingDesign>::iterator iter = m_aDesignList.begin()+nPos;
+
+ DBG_ASSERT(iter != m_aDesignList.end(), "Kein Design? Das darf nicht sein! (CL)");
+
+ pPage1_Designs->RemoveEntry(nPos);
- if(m_pDesign == pDesign)
+ if(m_pDesign == &(*iter))
DesignHdl( pPage1_NewDesign );
- delete pDesign;
+ m_aDesignList.erase(iter);
m_bDesignListDirty = sal_True;
@@ -1059,7 +1038,7 @@ IMPL_LINK( SdPublishingDlg, DesignDeleteHdl, PushButton *, EMPTYARG )
}
// =====================================================================
-// Clickhandler fuer das ändern des Servertyps
+// Clickhandler fuer das �ndern des Servertyps
// =====================================================================
IMPL_LINK( SdPublishingDlg, WebServerHdl, RadioButton *, pButton )
{
@@ -1089,12 +1068,6 @@ IMPL_LINK( SdPublishingDlg, GfxFormatHdl, RadioButton *, pButton )
// =====================================================================
IMPL_LINK( SdPublishingDlg, BaseHdl, RadioButton *, EMPTYARG )
{
-/*
- if(pButton == pPage3_Standard)
- pPage3_Frames->Check( pButton == pPage3 );
- else
- pPage3_Standard->Check(sal_False);
-*/
UpdatePage();
return 0;
@@ -1238,32 +1211,26 @@ IMPL_LINK( SdPublishingDlg, FinishHdl, OKButton *, EMPTYARG )
{
pDesign->m_aDesignName = aDlg.GetDesignName();
- SdPublishingDesign* pSameNameDes = NULL;
- sal_uInt16 nIndex;
- for( nIndex = 0; nIndex < m_pDesignList->Count(); nIndex++ )
+ boost::ptr_vector<SdPublishingDesign>::iterator iter;
+ for (iter = m_aDesignList.begin(); iter != m_aDesignList.end(); ++iter)
{
- pSameNameDes = (SdPublishingDesign*)
- m_pDesignList->GetObject(nIndex);
- if(pSameNameDes->m_aDesignName == pDesign->m_aDesignName)
+ if (iter->m_aDesignName == pDesign->m_aDesignName)
break;
}
- if(nIndex < m_pDesignList->Count())
+ if (iter != m_aDesignList.end())
{
ErrorBox aErrorBox(this, WB_YES_NO,
String(SdResId(STR_PUBDLG_SAMENAME)));
bRetry = aErrorBox.Execute() == RET_NO;
if(!bRetry)
- {
- m_pDesignList->Remove(pSameNameDes);
- delete pSameNameDes;
- }
+ m_aDesignList.erase(iter);
}
if(!bRetry)
{
- m_pDesignList->Insert(pDesign);
+ m_aDesignList.push_back(pDesign);
m_bDesignListDirty = sal_True;
pDesign = NULL;
}
@@ -1313,7 +1280,7 @@ void SdPublishingDlg::UpdatePage()
pPage1_DelDesign->Disable();
}
- if(m_pDesignList && m_pDesignList->Count() == 0)
+ if(m_aDesignList.empty())
pPage1_OldDesign->Disable();
break;
case 2:
@@ -1517,7 +1484,6 @@ void SdPublishingDlg::SetDesign( SdPublishingDesign* pDesign )
pPage4_Misc->SetText(pDesign->m_aMisc);
if(m_bImpress)
pPage4_Download->Check(pDesign->m_bDownload);
-//-/ pPage4_Created->Check(pDesign->m_bCreated);
pPage5_TextOnly->Check(pDesign->m_nButtonThema == -1);
if(pDesign->m_nButtonThema != -1)
@@ -1582,7 +1548,6 @@ void SdPublishingDlg::GetDesign( SdPublishingDesign* pDesign )
pDesign->m_aWWW = pPage4_WWW->GetText();
pDesign->m_aMisc = pPage4_Misc->GetText();
pDesign->m_bDownload = m_bImpress?pPage4_Download->IsChecked():sal_False;
-//-/ pDesign->m_bCreated = pPage4_Created->IsChecked();
if(pPage5_TextOnly->IsChecked())
pDesign->m_nButtonThema = -1;
@@ -1624,8 +1589,6 @@ sal_Bool SdPublishingDlg::Load()
{
m_bDesignListDirty = sal_False;
- m_pDesignList = new List();
-
INetURLObject aURL( SvtPathOptions().GetUserConfigPath() );
aURL.Append( UniString::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "designs.sod" ) ) );
@@ -1668,7 +1631,7 @@ sal_Bool SdPublishingDlg::Load()
SdPublishingDesign* pDesign = new SdPublishingDesign();
*pStream >> *pDesign;
- m_pDesignList->Insert(pDesign);
+ m_aDesignList.push_back(pDesign);
}
return( pStream->GetError() == SVSTREAM_OK );
@@ -1696,17 +1659,13 @@ sal_Bool SdPublishingDlg::Save()
{
SdIOCompat aIO(*pStream, STREAM_WRITE, 0);
- sal_uInt16 nDesigns = (sal_uInt16) m_pDesignList->Count();
+ sal_uInt16 nDesigns = (sal_uInt16) m_aDesignList.size();
*pStream << nDesigns;
for( sal_uInt16 nIndex = 0;
pStream->GetError() == SVSTREAM_OK && nIndex < nDesigns;
nIndex++ )
- {
- SdPublishingDesign* pDesign = (SdPublishingDesign*)
- m_pDesignList->GetObject(nIndex);
- *pStream << *pDesign;
- }
+ *pStream << m_aDesignList[nIndex];
}
aMedium.Close();
@@ -1718,10 +1677,6 @@ sal_Bool SdPublishingDlg::Save()
// *********************************************************************
// SdDesignNameDlg Methoden
// *********************************************************************
-
-// =====================================================================
-//
-// =====================================================================
SdDesignNameDlg::SdDesignNameDlg(Window* pWindow, const String& aName):
ModalDialog (pWindow, SdResId( DLG_DESIGNNAME )),
m_aEdit (this, SdResId(EDT_NAME)),
@@ -1734,17 +1689,11 @@ SdDesignNameDlg::SdDesignNameDlg(Window* pWindow, const String& aName):
m_aBtnOK.Enable(aName.Len() != 0);
}
-// =====================================================================
-//
-// =====================================================================
String SdDesignNameDlg::GetDesignName()
{
return m_aEdit.GetText();
}
-// =====================================================================
-//
-// =====================================================================
IMPL_LINK( SdDesignNameDlg, ModifyHdl, Edit*, EMPTYARG )
{
m_aBtnOK.Enable(m_aEdit.GetText().Len() != 0);
@@ -1754,3 +1703,4 @@ IMPL_LINK( SdDesignNameDlg, ModifyHdl, Edit*, EMPTYARG )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/html/sdhtmlfilter.cxx b/sd/source/filter/html/sdhtmlfilter.cxx
index d263c620c..ce59fd03b 100644
--- a/sd/source/filter/html/sdhtmlfilter.cxx
+++ b/sd/source/filter/html/sdhtmlfilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -84,3 +85,5 @@ sal_Bool SdHTMLFilter::Export()
return true;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/makefile.mk b/sd/source/filter/makefile.mk
deleted file mode 100644
index 554b1c536..000000000
--- a/sd/source/filter/makefile.mk
+++ /dev/null
@@ -1,55 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-PRJNAME=sd
-TARGET=filter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-.IF "$(dbg_anim_log)"!="" || "$(DBG_ANIM_LOG)"!=""
-CDEFS+= -DDBG_ANIM_LOG
-.ENDIF
-
-# --- Files --------------------------------------------------------
-
-SLOFILES =\
- $(SLO)$/sdfilter.obj \
- $(SLO)$/sdpptwrp.obj
-
-EXCEPTIONSFILES= \
- $(SLO)$/pptin.obj \
- $(SLO)$/sdfilter.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/filter/ppt/makefile.mk b/sd/source/filter/ppt/makefile.mk
deleted file mode 100644
index bb0067514..000000000
--- a/sd/source/filter/ppt/makefile.mk
+++ /dev/null
@@ -1,57 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=ppt
-ENABLE_EXCEPTIONS=TRUE
-VISIBILITY_HIDDEN=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-.IF "$(dbg_anim_log)"!="" || "$(DBG_ANIM_LOG)"!=""
-CDEFS+= -DDBG_ANIM_LOG
-.ENDIF
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/propread.obj \
- $(SLO)$/pptin.obj \
- $(SLO)$/pptinanimations.obj \
- $(SLO)$/pptatom.obj \
- $(SLO)$/ppt97animations.obj
-
-# --- Targets --------------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/filter/ppt/ppt97animations.cxx b/sd/source/filter/ppt/ppt97animations.cxx
index f430b0dcc..197ee72f5 100755..100644
--- a/sd/source/filter/ppt/ppt97animations.cxx
+++ b/sd/source/filter/ppt/ppt97animations.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -219,17 +220,17 @@ void Ppt97Animation::SetAnimateAssociatedShape( bool bAnimate )
if( !bAnimate )
{
//the appear effect cannot be animated without text
- if( this->GetPresetId().equals( ::rtl::OUString::createFromAscii("ooo-entrance-appear") ) )
+ if( this->GetPresetId().equals( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-appear")) ) )
return;
//the random effect may be the appear effect and than has the same problem
- if( this->GetPresetId().equals( ::rtl::OUString::createFromAscii("ooo-entrance-random") ) )
+ if( this->GetPresetId().equals( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-random")) ) )
{
//this case is not 100% correct -> feel free to complete
//i consider this case as seldom and not that problematic and a simple correct fix is not in sight
DBG_WARNING("you tried to deselect the animation of the form for random animation-> this has been refused");
return;
}
-
+
}
if(bAnimate)
@@ -299,26 +300,22 @@ void Ppt97Animation::UpdateCacheData() const
switch( m_aAtom.nFlyMethod )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_APPEAR;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-appear"); // --- appear ---
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-appear")); // --- appear ---
break;
case 0x01:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_RANDOM;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-random"); // --- random ---
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-random")); // --- random ---
break;
case 0x02: // --- blinds effect ---
{
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_VERTICAL_STRIPES;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-venetian-blinds");
- m_aSubType = ::rtl::OUString::createFromAscii("horizontal"); // horizontal
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-venetian-blinds"));
+ m_aSubType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("horizontal")); // horizontal
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_HORIZONTAL_STRIPES;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-venetian-blinds");
- m_aSubType = ::rtl::OUString::createFromAscii("vertical"); // vertical
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-venetian-blinds"));
+ m_aSubType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vertical")); // vertical
break;
}
}
@@ -328,35 +325,30 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_HORIZONTAL_CHECKERBOARD;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-checkerboard");
- m_aSubType = ::rtl::OUString::createFromAscii("across"); // vertical ???
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-checkerboard"));
+ m_aSubType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("across")); // vertical ???
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_VERTICAL_CHECKERBOARD;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-checkerboard");
- m_aSubType = ::rtl::OUString::createFromAscii("downward"); // horizontal ???
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-checkerboard"));
+ m_aSubType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("downward")); // horizontal ???
break;
}
}
break;
case 0x05:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_DISSOLVE; // --- dissolve ----
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-dissolve-in");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-dissolve-in"));
break;
case 0x08: // --- (hor/ver) lines ---
{
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_HORIZONTAL_LINES;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-random-bars");
- m_aSubType = ::rtl::OUString::createFromAscii("vertical"); // horizontal ???
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-random-bars"));
+ m_aSubType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vertical")); // horizontal ???
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_VERTICAL_LINES;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-random-bars");
- m_aSubType = rtl::OUString::createFromAscii("horizontal"); // vertical ???
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-random-bars"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("horizontal")); // vertical ???
break;
}
}
@@ -366,24 +358,20 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x4:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_LOWERRIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-diagonal-squares");
- m_aSubType = rtl::OUString::createFromAscii("left-to-top"); // to left top
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-diagonal-squares"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("left-to-top")); // to left top
break;
case 0x5:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_LOWERLEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-diagonal-squares");
- m_aSubType = rtl::OUString::createFromAscii("right-to-top"); // to right top
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-diagonal-squares"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("right-to-top")); // to right top
break;
case 0x6:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_UPPERRIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-diagonal-squares");
- m_aSubType = rtl::OUString::createFromAscii("left-to-bottom"); // to left bottom
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-diagonal-squares"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("left-to-bottom")); // to left bottom
break;
case 0x7:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_UPPERLEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-diagonal-squares");
- m_aSubType = rtl::OUString::createFromAscii("right-to-bottom"); // to right bottom
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-diagonal-squares"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("right-to-bottom")); // to right bottom
break;
}
}
@@ -393,24 +381,20 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_RIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-wipe");
- m_aSubType = rtl::OUString::createFromAscii("from-right"); // from right
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-wipe"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-right")); // from right
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_BOTTOM;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-wipe");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom"); // from bottom
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-wipe"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom")); // from bottom
break;
case 0x2:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_LEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-wipe");
- m_aSubType = rtl::OUString::createFromAscii("from-left"); // from left
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-wipe"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-left")); // from left
break;
case 0x3:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_TOP;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-wipe");
- m_aSubType = rtl::OUString::createFromAscii("from-top"); // from top
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-wipe"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top")); // from top
break;
}
}
@@ -420,14 +404,12 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-box");
- m_aSubType = rtl::OUString::createFromAscii("out"); // from center
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-box"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("out")); // from center
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_TO_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-box");
- m_aSubType = rtl::OUString::createFromAscii("in"); // to center
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-box"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("in")); // to center
break;
}
}
@@ -437,161 +419,128 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_LEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-left");
-
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-left"));
+
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_TOP;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-top");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top"));
break;
case 0x2:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_RIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-right"));
break;
case 0x3:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_BOTTOM;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom"));
break;
case 0x4:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_UPPERLEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-top-left");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top-left"));
break;
case 0x5:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_UPPERRIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-top-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top-right"));
break;
case 0x6:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_LOWERLEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom-left");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom-left"));
break;
case 0x7:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_LOWERRIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom-right"));
break;
case 0x8: // -- short text effects --
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_SHORT_FROM_LEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-peek-in");
- m_aSubType = rtl::OUString::createFromAscii("from-left");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-peek-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-left"));
break;
case 0x9:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_SHORT_FROM_BOTTOM;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-peek-in");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-peek-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom"));
break;
case 0xa:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_SHORT_FROM_RIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-peek-in");
- m_aSubType = rtl::OUString::createFromAscii("from-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-peek-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-right"));
break;
case 0xb:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_SHORT_FROM_TOP;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-peek-in");
- m_aSubType = rtl::OUString::createFromAscii("from-top");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-peek-in"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top"));
break;
case 0xc: // -- slow text effects --
{
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_LEFT;
- //rSpeed = ::com::sun::star::presentation::AnimationSpeed_SLOW;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in-slow");
- m_aSubType = rtl::OUString::createFromAscii("from-left");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in-slow"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-left"));
}
break;
case 0xd:
{
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_TOP;
- //rSpeed = ::com::sun::star::presentation::AnimationSpeed_SLOW;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in-slow");
- m_aSubType = rtl::OUString::createFromAscii("from-top");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in-slow"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top"));
}
break;
case 0xe:
{
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_RIGHT;
- //rSpeed = ::com::sun::star::presentation::AnimationSpeed_SLOW;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in-slow");
- m_aSubType = rtl::OUString::createFromAscii("from-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in-slow"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-right"));
}
break;
case 0xf:
{
- //eRetval = ::com::sun::star::presentation::AnimationEffect_MOVE_FROM_BOTTOM;
- //rSpeed = ::com::sun::star::presentation::AnimationSpeed_SLOW;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-fly-in-slow");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-fly-in-slow"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom"));
}
break;
case 0x10: // --- zoom ---
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("in");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("in"));
break;
case 0x11:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("in-slightly");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("in-slightly"));
break;
case 0x12:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_TO_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("out");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("out"));
break;
case 0x13:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_TO_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("out-slightly");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("out-slightly"));
break;
case 0x14:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_FROM_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("in-from-screen-center");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("in-from-screen-center"));
break;
case 0x15:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_FADE_TO_CENTER;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-zoom");
- m_aSubType = rtl::OUString::createFromAscii("out-from-screen-center");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-zoom"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("out-from-screen-center"));
break;
case 0x16: // --- stretch ---
- //eRetval = ::com::sun::star::presentation::AnimationEffect_HORIZONTAL_STRETCH;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-stretchy");
- m_aSubType = rtl::OUString::createFromAscii("across");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-stretchy"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("across"));
break;
case 0x17:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_STRETCH_FROM_LEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-stretchy");
- m_aSubType = rtl::OUString::createFromAscii("from-left");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-stretchy"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-left"));
break;
case 0x18:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_STRETCH_FROM_TOP;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-stretchy");
- m_aSubType = rtl::OUString::createFromAscii("from-top");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-stretchy"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-top"));
break;
case 0x19:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_STRETCH_FROM_RIGHT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-stretchy");
- m_aSubType = rtl::OUString::createFromAscii("from-right");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-stretchy"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-right"));
break;
case 0x1a:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_STRETCH_FROM_BOTTOM;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-stretchy");
- m_aSubType = rtl::OUString::createFromAscii("from-bottom");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-stretchy"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("from-bottom"));
break;
case 0x1b: // --- rotate ---
- //eRetval = ::com::sun::star::presentation::AnimationEffect_HORIZONTAL_ROTATE;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-swivel");
- m_aSubType = rtl::OUString::createFromAscii("vertical");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-swivel"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vertical"));
break;
case 0x1c: // --- spirale ---
- //eRetval = ::com::sun::star::presentation::AnimationEffect_SPIRALOUT_LEFT;
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-spiral-in");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-spiral-in"));
break;
}
}
@@ -601,31 +550,27 @@ void Ppt97Animation::UpdateCacheData() const
switch ( m_aAtom.nFlyDirection )
{
case 0x0:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_OPEN_VERTICAL ; // ???
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-split");
- m_aSubType = rtl::OUString::createFromAscii("horizontal-out"); //horizontal open
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-split"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("horizontal-out")); //horizontal open
break;
case 0x1:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_CLOSE_VERTICAL; // ???
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-split");
- m_aSubType = rtl::OUString::createFromAscii("horizontal-in"); //horizontal close
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-split"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("horizontal-in")); //horizontal close
break;
case 0x2:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_OPEN_HORIZONTAL; // ???
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-split");
- m_aSubType = rtl::OUString::createFromAscii("vertical-out"); // vertical open
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-split"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vertical-out")); // vertical open
break;
case 0x3:
- //eRetval = ::com::sun::star::presentation::AnimationEffect_CLOSE_HORIZONTAL; // ???
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-split");
- m_aSubType = rtl::OUString::createFromAscii("vertical-in"); // vertical close
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-split"));
+ m_aSubType = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vertical-in")); // vertical close
break;
}
}
break;
case 0x0e: // --- blink ---
{
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-flash-once");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-flash-once"));
switch ( m_aAtom.nFlyDirection )
{
case 0x0: //fast
@@ -645,8 +590,8 @@ void Ppt97Animation::UpdateCacheData() const
break;
default:
{
- m_aPresetId = ::rtl::OUString::createFromAscii("ooo-entrance-appear");
- DBG_ERROR("no effect mapped");
+ m_aPresetId = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo-entrance-appear"));
+ OSL_FAIL("no effect mapped");
}
break;
}
@@ -660,20 +605,20 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
return;
if( !pObj || !pObj->GetPage() )
{
- DBG_ERROR("no valid SdrObject or page found for ppt import");
+ OSL_FAIL("no valid SdrObject or page found for ppt import");
return;
}
uno::Reference< drawing::XShape > xShape = GetXShapeForSdrObject( pObj );
if( !xShape.is() )
{
- DBG_ERROR("no XShape interface found for ppt import");
+ OSL_FAIL("no XShape interface found for ppt import");
return;
}
::sd::MainSequencePtr pMainSequence = static_cast<SdPage*>(pObj->GetPage())->getMainSequence();
if( !pMainSequence.get() )
{
- DBG_ERROR("no MainSequence found for ppt import");
+ OSL_FAIL("no MainSequence found for ppt import");
return;
}
@@ -681,7 +626,7 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
::sd::CustomAnimationPresetPtr pPreset( rPresets.getEffectDescriptor( this->GetPresetId() ) );
if( !pPreset.get() )
{
- DBG_ERROR("no suiteable preset found for ppt import");
+ OSL_FAIL("no suiteable preset found for ppt import");
return;
}
@@ -705,7 +650,7 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
// some effects need a different duration than that of the mapped preset effect
double fDurationInSeconds = 1.0;//in secunden
if( this->GetSpecialDuration( fDurationInSeconds ) )
- pEffect->setDuration( fDurationInSeconds );
+ pEffect->setDuration( fDurationInSeconds );
// set after effect
if( this->HasAfterEffect() )
@@ -723,11 +668,11 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
// text iteration
pEffect->setIterateType( this->GetTextAnimationType() );
-
+
// some effects need a different delay between text iteration than that of the mapped preset effect
double fTextIterationDelay = 1.0;
if( this->GetSpecialTextIterationDelay( fTextIterationDelay ) )
- pEffect->setIterateInterval( fTextIterationDelay );
+ pEffect->setIterateInterval( fTextIterationDelay );
// is the effect started on click or after the last effect (Another possible value is EffectNodeType::WITH_PREVIOUS )
pEffect->setNodeType( this->GetEffectNodeType() );
@@ -754,19 +699,19 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
double fDelaySeconds = this->GetDelayTimeInSeconds();
sal_Bool bAnimateAssociatedShape = this->HasAnimateAssociatedShape();//or only text
sal_Bool bTextReverse = this->HasReverseOrder();
-
+
// now create effects for each paragraph
- ::sd::CustomAnimationTextGroupPtr pGroup = pMainSequence->
+ ::sd::CustomAnimationTextGroupPtr pGroup = pMainSequence->
createTextGroup( pEffect, nParagraphLevel, fDelaySeconds, bAnimateAssociatedShape, bTextReverse );
-
+
if( pGroup )
{
const ::sd::EffectSequence& rEffects = pGroup->getEffects();
::sd::EffectSequence::const_iterator aIter = rEffects.begin();
-
+
::sd::CustomAnimationEffectPtr pLastEffect;
sal_Int32 nIndex = 0;
- for( ; aIter != rEffects.end(); aIter++ )
+ for( ; aIter != rEffects.end(); ++aIter )
{
::sd::CustomAnimationEffectPtr pGroupEffect(*aIter);
@@ -797,3 +742,5 @@ void Ppt97Animation::createAndSetCustomAnimationEffect( SdrObject* pObj )
}
pMainSequence->rebuild();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/ppt97animations.hxx b/sd/source/filter/ppt/ppt97animations.hxx
index f939a813f..fdae3645a 100755..100644
--- a/sd/source/filter/ppt/ppt97animations.hxx
+++ b/sd/source/filter/ppt/ppt97animations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -128,9 +129,6 @@ private: //private methods
bool HasAfterEffect() const;
bool HasAfterEffect_ChangeColor() const;
bool HasAfterEffect_DimAtNextEffect() const;
-#ifdef FUTURE
- bool HasAfterEffect_DimAfterEffect() const;
-#endif
bool HasStopPreviousSound() const;
bool HasReverseOrder() const; //true if the text paragraphs should be animated in reverse order
sal_Int32 GetParagraphLevel() const; //paragraph level that is animated ( that paragraph and higher levels )
@@ -157,3 +155,5 @@ private: //private member
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptanimations.hxx b/sd/source/filter/ppt/pptanimations.hxx
index e66353b6e..df7f107e2 100644
--- a/sd/source/filter/ppt/pptanimations.hxx
+++ b/sd/source/filter/ppt/pptanimations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -557,3 +558,5 @@ static const preset_maping gPresetMaping[] =
} // namespace ppt
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptatom.cpp b/sd/source/filter/ppt/pptatom.cxx
index 84341dce1..dc309652a 100755..100644
--- a/sd/source/filter/ppt/pptatom.cpp
+++ b/sd/source/filter/ppt/pptatom.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -49,13 +50,13 @@ Atom::Atom( const DffRecordHeader& rRecordHeader, SvStream& rStream )
Atom* pLastAtom = NULL;
- // retrieve file size (to allow sanity checks)
+ // retrieve file size (to allow sanity checks)
const sal_Size nStreamPos = mrStream.Tell();
mrStream.Seek( STREAM_SEEK_TO_END );
const sal_Size nStreamSize = mrStream.Tell();
mrStream.Seek( nStreamPos );
- while( (mrStream.GetError() == 0 )
+ while( (mrStream.GetError() == 0 )
&& ( mrStream.Tell() < nStreamSize )
&& ( mrStream.Tell() < maRecordHeader.GetRecEndFilePos() ) )
{
@@ -117,3 +118,5 @@ const Atom* Atom::findNextChildAtom( sal_uInt16 nRecType, const Atom* pLast ) co
return pChild;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptatom.hxx b/sd/source/filter/ppt/pptatom.hxx
index 21fbcc784..235247572 100755..100644
--- a/sd/source/filter/ppt/pptatom.hxx
+++ b/sd/source/filter/ppt/pptatom.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,3 +140,5 @@ inline sal_uInt32 Atom::getLength() const
} // namespace ppt
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx
index d34511bb4..eaa0a0cce 100755..100644
--- a/sd/source/filter/ppt/pptin.cxx
+++ b/sd/source/filter/ppt/pptin.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -238,8 +239,6 @@ ImplSdPPTImport::ImplSdPPTImport( SdDrawDocument* pDocument, SvStorage& rStorage
ImplSdPPTImport::~ImplSdPPTImport()
{
- for ( void* pPtr = maSlideNameList.First(); pPtr; pPtr = maSlideNameList.Next() )
- delete (String*)pPtr;
delete pStData;
}
@@ -254,7 +253,7 @@ sal_Bool ImplSdPPTImport::Import()
if ( !bOk )
return sal_False;
- pSdrModel->setLock( sal_True );
+ pSdrModel->setLock(true);
pSdrModel->EnableUndo(false);
SdrOutliner& rOutl = mpDoc->GetDrawOutliner();
@@ -299,8 +298,6 @@ sal_Bool ImplSdPPTImport::Import()
if ( nSlideCount && pSection->GetProperty( PID_HEADINGPAIR, aPropItem ) )
{
sal_uInt32 nSlideTitleIndex = 0, nSlideTitleCount = 0;
- sal_uInt32 nFontIndex, nFontCount = 0;
- sal_uInt32 nDesignTemplateIndex, nDesignTemplateCount = 0;
sal_uInt32 i, nTemp, nEntryCount = 0;
String aUString;
@@ -325,16 +322,6 @@ sal_Bool ImplSdPPTImport::Import()
nSlideTitleCount = nTemp;
nSlideTitleIndex = nEntryCount;
}
- else if ( aUString.EqualsAscii("Fonts Used") )
- {
- nFontCount = nTemp;
- nFontIndex = nEntryCount;
- }
- else if ( aUString.EqualsAscii("Design Template") )
- {
- nDesignTemplateCount = nTemp;
- nDesignTemplateIndex = nEntryCount;
- }
nEntryCount += nTemp;
}
}
@@ -355,22 +342,19 @@ sal_Bool ImplSdPPTImport::Import()
{
if ( !aPropItem.Read( aUString, nType, sal_False ) )
break;
- String* pString = new String( aUString );
- if ( pString->EqualsAscii( "No Slide Title" ))
- *pString = String();
+
+ String aString( aUString );
+ if ( aString.EqualsAscii( "No Slide Title" ))
+ aString = String();
else
{
- void* pPtr;
- for ( pPtr = maSlideNameList.First(); pPtr; pPtr = maSlideNameList.Next() )
- {
- if ( *((String*)pPtr ) == *pString )
- {
- *pString = String();
- break;
- }
- }
+ std::vector<String>::const_iterator pIter =
+ std::find(maSlideNameList.begin(),maSlideNameList.end(),aString);
+
+ if (pIter != maSlideNameList.end())
+ aString = String();
}
- maSlideNameList.Insert( pString, LIST_APPEND );
+ maSlideNameList.push_back( aString );
}
}
}
@@ -388,10 +372,11 @@ sal_Bool ImplSdPPTImport::Import()
Dictionary aDict;
if ( pSection->GetDictionary( aDict ) )
{
- sal_uInt32 nPropId = aDict.GetProperty( rtl::OUString::createFromAscii("_PID_HLINKS" ));
- if ( nPropId )
+ Dictionary::const_iterator iter = aDict.find( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_PID_HLINKS" )));
+
+ if ( iter != aDict.end() )
{
- if ( pSection->GetProperty( nPropId, aPropItem ) )
+ if ( pSection->GetProperty( iter->second, aPropItem ) )
{
aPropItem.Seek( STREAM_SEEK_TO_BEGIN );
aPropItem >> nType;
@@ -429,6 +414,11 @@ sal_Bool ImplSdPPTImport::Import()
aPropItem >> pHyperlink->nInfo;
if ( !aPropItem.Read( pHyperlink->aTarget, VT_EMPTY ) )
break;
+
+ // Convert '\\' notation to 'smb://'
+ INetURLObject aUrl( pHyperlink->aTarget, INET_PROT_FILE );
+ pHyperlink->aTarget = aUrl.GetMainURL( INetURLObject::NO_DECODE );
+
if ( !aPropItem.Read( pHyperlink->aSubAdress, VT_EMPTY ) )
break;
pHyperlink->nStartPos = pHyperlink->nEndPos = -1;
@@ -474,14 +464,13 @@ sal_Bool ImplSdPPTImport::Import()
for ( nToken = 0; nToken < nTokenCount; nToken++ )
{
String aToken( aString.GetToken( nToken, (sal_Unicode)',' ) );
- for ( void* pPtr = maSlideNameList.First(); pPtr; pPtr = maSlideNameList.Next() )
+ std::vector<String>::const_iterator pIter =
+ std::find(maSlideNameList.begin(),maSlideNameList.end(),aToken);
+
+ if (pIter != maSlideNameList.end())
{
- if ( *(String*)pPtr == aToken )
- {
- nPageNumber = maSlideNameList.GetCurPos();
- bSucceeded = sal_True;
- break;
- }
+ nPageNumber = pIter - maSlideNameList.begin();
+ bSucceeded = sal_True;
}
}
}
@@ -503,8 +492,8 @@ sal_Bool ImplSdPPTImport::Import()
}
if ( bSucceeded )
{
- if ( nPageNumber < maSlideNameList.Count() )
- pHyperlink->aConvSubString = *(String*)maSlideNameList.GetObject( nPageNumber );
+ if ( nPageNumber < maSlideNameList.size() )
+ pHyperlink->aConvSubString = maSlideNameList[ nPageNumber ];
if ( !pHyperlink->aConvSubString.Len() )
{
pHyperlink->aConvSubString = String( SdResId( STR_PAGE ) );
@@ -513,7 +502,7 @@ sal_Bool ImplSdPPTImport::Import()
}
}
}
- aHyperList.Insert( pHyperlink, LIST_APPEND );
+ aHyperList.push_back( pHyperlink );
}
if ( i != nPropCount )
delete pHyperlink;
@@ -535,15 +524,16 @@ sal_Bool ImplSdPPTImport::Import()
if ( SeekToRec( rStCtrl, PPT_PST_ExObjList, maDocHd.GetRecEndFilePos(), &aHyperHd ) )
{
sal_uInt32 nExObjHyperListLen = aHyperHd.GetRecEndFilePos();
- for ( void* pPtr = aHyperList.First(); pPtr; pPtr = aHyperList.Next() )
+ for ( size_t i = 0, n = aHyperList.size(); i < n; ++i )
{
+ SdHyperlinkEntry* pPtr = aHyperList[ i ];
DffRecordHeader aHyperE;
if ( !SeekToRec( rStCtrl, PPT_PST_ExHyperlink, nExObjHyperListLen, &aHyperE ) )
break;
if ( !SeekToRec( rStCtrl, PPT_PST_ExHyperlinkAtom, nExObjHyperListLen, NULL, 0 ) )
break;
rStCtrl.SeekRel( 8 );
- rStCtrl >> ((SdHyperlinkEntry*)pPtr)->nIndex;
+ rStCtrl >> pPtr->nIndex;
aHyperE.SeekToEndOfRecord( rStCtrl );
}
}
@@ -647,12 +637,7 @@ sal_Bool ImplSdPPTImport::Import()
{
sal_uInt32 nTitleInstance = TSS_TYPE_PAGETITLE;
sal_uInt32 nOutlinerInstance = TSS_TYPE_BODY;
-// sal_Bool bSwapStyleSheet = pSlideLayout->eLayout == PPT_LAYOUT_TITLEMASTERSLIDE;
-// if ( bSwapStyleSheet )
-// {
-// nTitleInstance = TSS_TYPE_TITLE;
-// nOutlinerInstance = TSS_TYPE_SUBTITLE;
-// }
+
/////////////////////
// titelstylesheet //
/////////////////////
@@ -772,7 +757,7 @@ sal_Bool ImplSdPPTImport::Import()
if ( SeekToAktPage( &aPageHd ) )
{
if ( mbTracing )
- mpTracer->AddAttribute( rtl::OUString::createFromAscii( "MasterPage" ), rtl::OUString::valueOf( (sal_Int32) (nAktPageNum + 1) ) );
+ mpTracer->AddAttribute( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "MasterPage" )), rtl::OUString::valueOf( (sal_Int32) (nAktPageNum + 1) ) );
while( ( rStCtrl.GetError() == 0 ) && ( rStCtrl.Tell() < aPageHd.GetRecEndFilePos() ) )
{
@@ -850,7 +835,7 @@ sal_Bool ImplSdPPTImport::Import()
aHd.SeekToEndOfRecord( rStCtrl );
}
if ( mbTracing )
- mpTracer->RemoveAttribute( rtl::OUString::createFromAscii( "MasterPage" ) );
+ mpTracer->RemoveAttribute( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "MasterPage" )) );
}
rStCtrl.Seek( nFPosMerk );
ImportPageEffect( (SdPage*)pMPage, bNewAnimationsUsed );
@@ -878,7 +863,7 @@ sal_Bool ImplSdPPTImport::Import()
}
else
{
- // without StyleSheet, set attributes directly. This
+ // without StyleSheet, set attributes directly. This
// should not be done at all and is an error (will be asserted by SdrPage)
pMPage->getSdrPageProperties().ClearItem();
pMPage->getSdrPageProperties().PutItemSet(pObj->GetMergedItemSet());
@@ -952,13 +937,6 @@ sal_Bool ImplSdPPTImport::Import()
rStCtrl >> aProgTagContentHd;
switch( aProgTagContentHd.nRecType )
{
-/*
- case PPT_PST_CommentContainer :
- {
-
- }
- break;
-*/
case DFF_msofbtAnimGroup :
{
::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage > xPage( pPage->getUnoPage(), ::com::sun::star::uno::UNO_QUERY );
@@ -1208,16 +1186,16 @@ sal_Bool ImplSdPPTImport::Import()
}
sal_uInt32 nSlideCount = GetPageCount();
- for ( i = 0; ( i < nSlideCount) && ( i < maSlideNameList.Count() ); i++ )
+ for ( i = 0; ( i < nSlideCount) && ( i < maSlideNameList.size() ); i++ )
{
SdPage* pPage = mpDoc->GetSdPage( i, PK_STANDARD );
- String* pName = (String*)maSlideNameList.GetObject( i );
- if ( pPage && pName )
+ String &aName = maSlideNameList[ i ];
+ if ( pPage )
{
- if ( pName->Len() )
- pPage->SetName( *pName );
+ if ( aName.Len() )
+ pPage->SetName( aName );
else
- *pName = pPage->GetName();
+ aName = pPage->GetName();
}
}
if ( mbDocumentFound )
@@ -1228,13 +1206,9 @@ sal_Bool ImplSdPPTImport::Import()
::sd::FrameView* pFrameView = mpDoc->GetFrameView( 0 );
if ( !pFrameView )
{
- List* pFrameViewList = mpDoc->GetFrameViewList();
- if ( pFrameViewList )
- {
- pFrameView = new ::sd::FrameView( mpDoc );
- if ( pFrameView )
- pFrameViewList->Insert( pFrameView );
- }
+ std::vector<sd::FrameView*> &rViews = mpDoc->GetFrameViewList();
+ pFrameView = new ::sd::FrameView( mpDoc );
+ rViews.push_back( pFrameView );
}
if ( pFrameView )
{
@@ -1342,15 +1316,15 @@ sal_Bool ImplSdPPTImport::Import()
// this is defaulted, maybe there is no SSDocInfoAtom
String aCustomShow;
sal_uInt32 nFlags = 1; // Bit 0: Auto advance
- sal_uInt32 nPenColor = 0x1000000;
- sal_Int32 nRestartTime = 0x7fffffff;
sal_uInt16 nStartSlide = 0;
- sal_Int16 nEndSlide = 0;
// read the pres. configuration
rStCtrl.Seek( maDocHd.GetRecBegFilePos() + 8 );
if ( SeekToRec( rStCtrl, PPT_PST_SSDocInfoAtom, maDocHd.GetRecEndFilePos(), &aCustomShowHeader ) )
{
+ sal_uInt32 nPenColor = 0x1000000;
+ sal_Int32 nRestartTime = 0x7fffffff;
+ sal_Int16 nEndSlide = 0;
rStCtrl >> nPenColor
>> nRestartTime
>> nStartSlide
@@ -1394,8 +1368,7 @@ sal_Bool ImplSdPPTImport::Import()
rPresSettings.mbCustomShow = ( nFlags & 8 ) != 0;
rPresSettings.mbEndless = ( nFlags & 0x80 ) != 0;
rPresSettings.mbFullScreen = ( nFlags & 0x10 ) == 0;
-// rPresSettings.mnPauseTimeout;
-// rPresSettings.mbShowLogo;
+
if ( nStartSlide && ( nStartSlide <= GetPageCount() ) )
{
SdPage* pPage = mpDoc->GetSdPage( nStartSlide - 1, PK_STANDARD );
@@ -1414,7 +1387,7 @@ sal_Bool ImplSdPPTImport::Import()
sfx2::LoadOlePropertySet(xDocProps, &mrStorage);
xDocProps->setTemplateName(::rtl::OUString());
- pSdrModel->setLock( sal_False );
+ pSdrModel->setLock(false);
pSdrModel->EnableUndo(true);
return bOk;
}
@@ -1621,7 +1594,11 @@ void ImplSdPPTImport::ImportPageEffect( SdPage* pPage, const sal_Bool bNewAnimat
if ( nDirection == 0 )
pPage->SetFadeEffect( ::com::sun::star::presentation::FadeEffect_NONE ); // Direkt
else if ( nDirection == 1 )
- pPage->SetFadeEffect( ::com::sun::star::presentation::FadeEffect_NONE ); // Direkt ueber Schwarz
+ {
+ pPage->setTransitionType( animations::TransitionType::BARWIPE );
+ pPage->setTransitionSubtype( animations::TransitionSubType::FADEOVERCOLOR );
+ pPage->setTransitionFadeColor( 0 );
+ }
}
else
pPage->setTransitionType( 0 );
@@ -1775,12 +1752,8 @@ void ImplSdPPTImport::ImportPageEffect( SdPage* pPage, const sal_Bool bNewAnimat
break;
case PPT_TRANSITION_TYPE_NEWSFLASH :
{
- pPage->setTransitionType( animations::TransitionType::FOURBOXWIPE );
- pPage->setTransitionSubtype( animations::TransitionSubType::CORNERSOUT );
-/*
pPage->setTransitionType( animations::TransitionType::ZOOM );
pPage->setTransitionSubtype( animations::TransitionSubType::ROTATEIN );
-*/
}
break;
case PPT_TRANSITION_TYPE_SMOOTHFADE :
@@ -1806,9 +1779,6 @@ void ImplSdPPTImport::ImportPageEffect( SdPage* pPage, const sal_Bool bNewAnimat
else
pPage->SetPresChange( mePresChange );
-// if ( nBuildFlags & 1 ) // slidechange by mouseclick
-// pPage->SetPresChange( mePresChange );
-
if ( nBuildFlags & 4 )
pPage->SetExcluded( sal_True ); // Dia nicht anzeigen
if ( nBuildFlags & 16 )
@@ -1879,7 +1849,7 @@ void ImplSdPPTImport::ImportPageEffect( SdPage* pPage, const sal_Bool bNewAnimat
tAnimationVector::iterator aIter( aAnimationsOnThisPage.begin() );
const tAnimationVector::iterator aEnd( aAnimationsOnThisPage.end() );
- for( ;aIter != aEnd; aIter++ )
+ for( ;aIter != aEnd; ++aIter )
{
Ppt97AnimationPtr pPpt97Animation = (*aIter).second;;
if( pPpt97Animation.get() )
@@ -1942,27 +1912,24 @@ String ImplSdPPTImport::ReadSound(sal_uInt32 nSoundRef) const
// existiert. Wenn nicht, exportiere diese
// in unser lokales Sound-Verzeichnis.
sal_Bool bSoundExists = sal_False;
- List* pSoundList = new List();
+ ::std::vector< String > aSoundList;
- GalleryExplorer::FillObjList( GALLERY_THEME_SOUNDS, *pSoundList );
- GalleryExplorer::FillObjList( GALLERY_THEME_USERSOUNDS, *pSoundList );
+ GalleryExplorer::FillObjList( GALLERY_THEME_SOUNDS, aSoundList );
+ GalleryExplorer::FillObjList( GALLERY_THEME_USERSOUNDS, aSoundList );
- for( sal_uLong n = 0; ( n < pSoundList->Count() ) && !bSoundExists; n++ )
+ for( size_t n = 0; ( n < aSoundList.size() ) && !bSoundExists; n++ )
{
- INetURLObject aURL( *(String*)pSoundList->GetObject( n ) );
+ INetURLObject aURL( aSoundList[ n ] );
String aSoundName( aURL.GetName() );
if( aSoundName == aRetval )
{
- aRetval = *(String*)pSoundList->GetObject( n );
+ aRetval = aSoundList[ n ];
bSoundExists = sal_True;
}
}
- for ( void* pPtr = pSoundList->First(); pPtr; pPtr = pSoundList->Next() )
- delete (String*)pPtr;
-
- delete pSoundList;
+ aSoundList.clear();
if ( !bSoundExists )
{
@@ -2088,18 +2055,10 @@ void ImplSdPPTImport::FillSdAnimationInfo( SdAnimationInfo* pInfo, PptInteractiv
pInfo->SetBookmark( ReadSound( pIAtom->nSoundRef ) ); // Pfad zum Soundfile in MSDOS-Notation
pInfo->meClickAction = ::com::sun::star::presentation::ClickAction_SOUND; // RunProgramAction
}
-// if ( nFlags & 0x01 ) // koennen wir nicht ( beim Anklicken markieren )
+
switch ( pIAtom->nAction )
{
-// case 0x01 : // MacroAction
-// {
-// pInfo->meClickAction = ::com::sun::star::presentation::::com::sun::star::presentation::ClickAction_MACRO;
-// // aMacro liegt in folgender Form vor:
-// // "Macroname.Modulname.Libname.Dokumentname" oder
-// // "Macroname.Modulname.Libname.Applikationsname"
-// pInfo->maBookmark = aMacroName;
-// }
-// break;
+
case 0x02 : // RunProgramAction
{
pInfo->meClickAction = ::com::sun::star::presentation::ClickAction_PROGRAM;
@@ -2136,11 +2095,12 @@ void ImplSdPPTImport::FillSdAnimationInfo( SdAnimationInfo* pInfo, PptInteractiv
break;
case 0x04 :
{
- SdHyperlinkEntry* pPtr;
- for ( pPtr = (SdHyperlinkEntry*)aHyperList.First(); pPtr; pPtr = (SdHyperlinkEntry*)aHyperList.Next() )
- {
- if ( pPtr->nIndex == pIAtom->nExHyperlinkId )
+ SdHyperlinkEntry* pPtr = NULL;
+ for ( size_t i = 0, n = aHyperList.size(); i < n; ++i ) {
+ if ( aHyperList[ i ]->nIndex == pIAtom->nExHyperlinkId ) {
+ pPtr = aHyperList[ i ];
break;
+ }
}
if ( pPtr )
{
@@ -2760,3 +2720,5 @@ extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL ImportPPT( const ::rtl::OUStri
return bRet;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptin.hxx b/sd/source/filter/ppt/pptin.hxx
index 743f852b9..2947c5c9f 100755..100644
--- a/sd/source/filter/ppt/pptin.hxx
+++ b/sd/source/filter/ppt/pptin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,7 +61,7 @@ class ImplSdPPTImport : public SdrPowerPointImport
SvStorage& mrStorage;
// SvStream* mpPicStream;
DffRecordHeader maDocHd;
- List maSlideNameList;
+ std::vector<String> maSlideNameList;
sal_Bool mbDocumentFound;
sal_uInt32 mnFilterOptions;
SdDrawDocument* mpDoc;
@@ -103,3 +104,5 @@ class SdPPTImport
};
#endif // _SD_PPTIN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptinanimations.cxx b/sd/source/filter/ppt/pptinanimations.cxx
index 4c113f2b0..62a836a18 100755..100644
--- a/sd/source/filter/ppt/pptinanimations.cxx
+++ b/sd/source/filter/ppt/pptinanimations.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -244,7 +245,6 @@ void AnimationImporter::import( const Reference< XDrawPage >& xPage, const DffRe
{
#ifdef DBG_ANIM_LOG
mpFile = fopen( "c:\\output.xml", "w+" );
- //mpFile = stdout;
#endif
dump("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
@@ -300,10 +300,6 @@ Reference< XAnimationNode > AnimationImporter::createNode( const Atom* pAtom, co
switch( rNode.mnNodeType )
{
case mso_Anim_Behaviour_FILTER:
-/*
- pServiceName = "com.sun.star.animations.TransitionFilter";
- break;
-*/
case mso_Anim_Behaviour_ANIMATION:
if( pAtom->hasChildAtom( DFF_msofbtAnimateSet ) )
pServiceName = "com.sun.star.animations.AnimateSet";
@@ -532,7 +528,7 @@ void AnimationImporter::importAnimationContainer( const Atom* pAtom, const Refer
}
else
{
- DBG_ERROR( "unknown node atom!" );
+ OSL_FAIL( "unknown node atom!" );
dump_atom_header( pAtom, true, false );
dump_atom( pAtom );
dump_atom_header( pAtom, false, false );
@@ -560,7 +556,7 @@ void AnimationImporter::importAnimationContainer( const Atom* pAtom, const Refer
break;
default:
- DBG_ERROR( "unknown group atom!" );
+ OSL_FAIL( "unknown group atom!" );
dump_atom_header( pAtom, true, false );
dump_atom( pAtom );
@@ -644,7 +640,7 @@ void AnimationImporter::fixMainSequenceTiming( const ::com::sun::star::uno::Refe
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::AnimationImporter::fixMainSequenceTiming(), exception caught!" );
+ OSL_FAIL("sd::AnimationImporter::fixMainSequenceTiming(), exception caught!" );
}
}
@@ -670,7 +666,7 @@ void AnimationImporter::fixInteractiveSequenceTiming( const ::com::sun::star::un
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::AnimationImporter::fixInteractiveSequenceTiming(), exception caught!" );
+ OSL_FAIL("sd::AnimationImporter::fixInteractiveSequenceTiming(), exception caught!" );
}
}
@@ -692,7 +688,7 @@ bool AnimationImporter::convertAnimationNode( const Reference< XAnimationNode >&
OUString aAttributeName( xAnimate->getAttributeName() );
- if( (nNodeType == AnimationNodeType::SET) && aAttributeName.equalsAscii( "fill.on" ) )
+ if( (nNodeType == AnimationNodeType::SET) && aAttributeName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "fill.on" ) ) )
return false;
const ImplAttributeNameConversion* p = gImplConversionList;
@@ -975,7 +971,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "solid" ) ? FillStyle_SOLID : FillStyle_NONE;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "solid" ) ) ? FillStyle_SOLID : FillStyle_NONE;
bRet = true;
}
}
@@ -986,7 +982,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "true" ) ? ::com::sun::star::drawing::LineStyle_SOLID : ::com::sun::star::drawing::LineStyle_NONE;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "true" ) ) ? ::com::sun::star::drawing::LineStyle_SOLID : ::com::sun::star::drawing::LineStyle_NONE;
bRet = true;
}
}
@@ -997,7 +993,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "bold" ) ? com::sun::star::awt::FontWeight::BOLD : com::sun::star::awt::FontWeight::NORMAL;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "bold" ) ) ? com::sun::star::awt::FontWeight::BOLD : com::sun::star::awt::FontWeight::NORMAL;
bRet = true;
}
}
@@ -1008,7 +1004,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "italic" ) ? com::sun::star::awt::FontSlant_ITALIC : com::sun::star::awt::FontSlant_NONE;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "italic" ) ) ? com::sun::star::awt::FontSlant_ITALIC : com::sun::star::awt::FontSlant_NONE;
bRet = true;
}
}
@@ -1019,7 +1015,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "true" ) ? com::sun::star::awt::FontUnderline::SINGLE : com::sun::star::awt::FontUnderline::NONE;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "true" ) ) ? com::sun::star::awt::FontUnderline::SINGLE : com::sun::star::awt::FontUnderline::NONE;
bRet = true;
}
}
@@ -1042,7 +1038,7 @@ bool AnimationImporter::convertAnimationValue( MS_AttributeNames eAttribute, Any
OUString aString;
if( rValue >>= aString )
{
- rValue <<= aString.equalsAscii( "visible" ) ? sal_True : sal_False;
+ rValue <<= aString.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "visible" ) ) ? sal_True : sal_False;
bRet = true;
}
}
@@ -1376,25 +1372,8 @@ void AnimationImporter::fillNode( Reference< XAnimationNode >& xNode, const Anim
}
}
-/* todo
- Reference< XAudio > xAudio( xNode, UNO_QUERY );
- if( xAudio.is() )
- {
- if( rSet.hasProperty( DFF_ANIM_ENDAFTERSLIDE ) )
- {
- sal_Int16 nEndAfterSlide = 0;
- if( rSet.getProperty( DFF_ANIM_ENDAFTERSLIDE ) >>= nEndAfterSlide )
- xAudio->setEndAfterSlide( nEndAfterSlide );
- }
- if( rSet.hasProperty( DFF_ANIM_VOLUME ) )
- {
- double fVolume = 1.0;
- rSet.getProperty( DFF_ANIM_VOLUME ) >>= fVolume;
- xAudio->setVolume( fVolume );
- }
- }
-*/
+// TODO: DFF_ANIM_ENDAFTERSLIDE / DFF_ANIM_VOLUME handling. git history has sample code
Reference< XAnimateColor > xColor( xNode, UNO_QUERY );
if( xColor.is() )
{
@@ -1445,7 +1424,7 @@ void AnimationImporter::importTimeContainer( const Atom* pAtom, const Reference<
{
if( pChildAtom->hasChildAtom( DFF_msofbtAnimCommand ) )
{
- const OUString aServiceName( OUString::createFromAscii("com.sun.star.animations.Command") );
+ const OUString aServiceName( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.animations.Command")) );
Reference< XAnimationNode > xChildNode( ::comphelper::getProcessServiceFactory()->createInstance(aServiceName), UNO_QUERY );
importAnimationNodeContainer( pChildAtom, xChildNode );
Reference< XTimeContainer > xParentContainer( xNode, UNO_QUERY );
@@ -1647,7 +1626,7 @@ void AnimationImporter::importAnimateFilterContainer( const Atom* pAtom, const R
}
else
{
- DBG_ERROR( "unknown transition!" );
+ OSL_FAIL( "unknown transition!" );
}
}
}
@@ -1875,7 +1854,7 @@ Any AnimationImporter::implGetColorAny( sal_Int32 nMode, sal_Int32 nA, sal_Int3
dump( "%ld", nA );
dump( ",%ld", nB );
dump( ",%ld)", nC );
- DBG_ERROR( "ppt::implGetColorAny(), unhandled color type" );
+ OSL_FAIL( "ppt::implGetColorAny(), unhandled color type" );
Any aAny;
return aAny;
@@ -2289,7 +2268,7 @@ void AnimationImporter::importCommandContainer( const Atom* pAtom, const Referen
xCommand->setCommand( nCommand );
if( nCommand == EffectCommands::CUSTOM )
{
- DBG_ERROR("sd::AnimationImporter::importCommandContainer(), unknown command!");
+ OSL_FAIL("sd::AnimationImporter::importCommandContainer(), unknown command!");
aParamValue.Name = OUString(RTL_CONSTASCII_USTRINGPARAM("UserDefined"));
aParamValue.Value <<= aParam;
}
@@ -2572,7 +2551,7 @@ bool AnimationImporter::importAttributeNamesContainer( const Atom* pAtom, OUStri
}
else
{
- DBG_ERROR( "error during ppt::AnimationImporter::importAttributeName()!" );
+ OSL_FAIL( "error during ppt::AnimationImporter::importAttributeName()!" );
}
pAttributeValueAtom = pAtom->findNextChildAtom( DFF_msofbtAnimAttributeValue, pAttributeValueAtom );
@@ -2941,7 +2920,7 @@ void AnimationImporter::importAnimationEvents( const Atom* pAtom, const Referenc
break;
default:
{
- DBG_ERROR("unknown atom inside ppt::AnimationImporter::importAnimationEvents()!");
+ OSL_FAIL("unknown atom inside ppt::AnimationImporter::importAnimationEvents()!");
}
}
@@ -3066,7 +3045,6 @@ sal_Int32 AnimationImporter::importTargetElementContainer( const Atom* pAtom, An
switch( nRefMode )
{
-// default case 0: rSubType = ShapeAnimationSubType::AS_WHOLE; break;
case 6: rSubType = ShapeAnimationSubType::ONLY_BACKGROUND; break;
case 8: rSubType = ShapeAnimationSubType::ONLY_TEXT; break;
case 2: // one paragraph
@@ -3128,33 +3106,19 @@ sal_Int32 AnimationImporter::importTargetElementContainer( const Atom* pAtom, An
}
break;
default:
- DBG_ERROR("unknown reference type");
+ OSL_FAIL("unknown reference type");
}
-
-// dump( " ref=\"%s\"", nRefMode == 3 ? "source" : ( nRefMode == 0 ? "target" : "unknown" ) );
-// dump( " type=\"%s\"", nRefType == 1 ? "shape" : ( nRefType == 2 ? "sound": "unknown" ) );
-// dump( " id=\"%lu\"", (sal_Int32)nRefId );
-#ifdef DBG_ANIM_LOG
- if((begin != -1) || (end != -1) )
- {
-// dump( " text_begin=\"%ld\"", begin );
-// dump( " text_end=\"%ld\"", end );
- }
-#endif
}
break;
case 0x2b01:
{
sal_Int32 nU1;
mrStCtrl >> nU1;
-
- // HINT: nU1 == 1 : target document. ?
-// dump( " unknown_0x2b01=\"%#lx\"", nU1 );
}
break;
default:
- DBG_ERROR("unknwon atom inside ppt::AnimationImporter::importTargetElementContainer()!");
+ OSL_FAIL("unknwon atom inside ppt::AnimationImporter::importTargetElementContainer()!");
break;
}
@@ -3185,7 +3149,7 @@ void AnimationImporter::importPropertySetContainer( const Atom* pAtom, PropertyS
}
else
{
- DBG_ERROR("unknwon atom inside ppt::AnimationImporter::importPropertySetContainer()!");
+ OSL_FAIL("unknwon atom inside ppt::AnimationImporter::importPropertySetContainer()!");
}
pChildAtom = pAtom->findNextChildAtom( pChildAtom );
@@ -3202,8 +3166,6 @@ void AnimationImporter::dump_atom_header( const Atom* pAtom, bool bOpen, bool bA
{
const char* pTitle;
- bool bUnknown = false;
-
switch( pAtom->getType() )
{
case DFF_msofbtAnimEvent: pTitle = "AnimEvent"; break;
@@ -3542,7 +3504,6 @@ void AnimationImporter::dump( const PropertySet& rSet )
break;
case DFF_ANIM_DIRECTION:
-// case DFF_ANIM_MASTERREL:
{
sal_Bool bDirection;
if( aAny >>= bDirection )
@@ -3740,7 +3701,7 @@ void AnimationImporter::dump( const PropertySet& rSet )
case DFF_ANIM_VOLUME:
{
- double fVolume;
+ double fVolume(0.0);
if( aAny >>= fVolume )
{
fprintf( mpFile, " volume=\"%g%%\"", (double)(fVolume * 100.0) );
@@ -3770,7 +3731,7 @@ void AnimationImporter::dump( const PropertySet& rSet )
fprintf( mpFile, "\"" );
}
- aIter++;
+ ++aIter;
}
}
@@ -3888,3 +3849,4 @@ void AnimationImporter::dump( const char * , const rtl::OUString& )
} // namespace ppt;
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/pptinanimations.hxx b/sd/source/filter/ppt/pptinanimations.hxx
index 51ba098f4..c984bea6d 100755..100644
--- a/sd/source/filter/ppt/pptinanimations.hxx
+++ b/sd/source/filter/ppt/pptinanimations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -129,3 +130,5 @@ private:
} // namespace ppt
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/propread.cxx b/sd/source/filter/ppt/propread.cxx
index 39b2e6f15..f5fda2286 100644
--- a/sd/source/filter/ppt/propread.cxx
+++ b/sd/source/filter/ppt/propread.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,22 +34,6 @@
#include "rtl/tencinfo.h"
#include "rtl/textenc.h"
-// ------------------------------------------------------------------------
-
-struct PropEntry
-{
- sal_uInt32 mnId;
- sal_uInt32 mnSize;
- sal_uInt16 mnTextEnc;
- sal_uInt8* mpBuf;
-
- PropEntry( sal_uInt32 nId, const sal_uInt8* pBuf, sal_uInt32 nBufSize, sal_uInt16 nTextEnc );
- PropEntry( const PropEntry& rProp );
- ~PropEntry() { delete[] mpBuf; } ;
-
- const PropEntry& operator=(const PropEntry& rPropEntry);
-};
-
PropEntry::PropEntry( sal_uInt32 nId, const sal_uInt8* pBuf, sal_uInt32 nBufSize, sal_uInt16 nTextEnc ) :
mnId ( nId ),
mnSize ( nBufSize ),
@@ -155,7 +140,7 @@ sal_Bool PropItem::Read( String& rString, sal_uInt32 nStringType, sal_Bool bAlig
}
catch( const std::bad_alloc& )
{
- DBG_ERROR( "sd PropItem::Read bad alloc" );
+ OSL_FAIL( "sd PropItem::Read bad alloc" );
}
}
if ( bAlign )
@@ -184,7 +169,7 @@ sal_Bool PropItem::Read( String& rString, sal_uInt32 nStringType, sal_Bool bAlig
}
catch( const std::bad_alloc& )
{
- DBG_ERROR( "sd PropItem::Read bad alloc" );
+ OSL_FAIL( "sd PropItem::Read bad alloc" );
}
}
if ( bAlign && ( nItemSize & 1 ) )
@@ -217,80 +202,12 @@ PropItem& PropItem::operator=( PropItem& rPropItem )
// -----------------------------------------------------------------------
-struct Dict
-{
- sal_uInt32 mnId;
- String aString;
-
- Dict( sal_uInt32 nId, String rString ) { mnId = nId; aString = rString; };
-};
-
-// -----------------------------------------------------------------------
-
-Dictionary::~Dictionary()
-{
- for ( void* pPtr = First(); pPtr; pPtr = Next() )
- delete (Dict*)pPtr;
-}
-
-// -----------------------------------------------------------------------
-
-void Dictionary::AddProperty( sal_uInt32 nId, const String& rString )
-{
- if ( rString.Len() ) // eindeutige namen bei properties
- {
- // pruefen, ob es die Propertybeschreibung in der Dictionary schon gibt
- for ( Dict* pDict = (Dict*)First(); pDict; pDict = (Dict*)Next() )
- {
- if ( pDict->mnId == nId )
- {
- pDict->aString = rString;
- return;
- }
- }
- Insert( new Dict( nId, rString ), LIST_APPEND );
- }
-}
-
-// -----------------------------------------------------------------------
-
-sal_uInt32 Dictionary::GetProperty( const String& rString )
-{
- for ( Dict* pDict = (Dict*)First(); pDict; pDict = (Dict*)Next() )
- {
- if ( pDict->aString == rString )
- return pDict->mnId;
- }
- return 0;
-}
-
-// -----------------------------------------------------------------------
-
-Dictionary& Dictionary::operator=( Dictionary& rDictionary )
-{
- void* pPtr;
-
- if ( this != &rDictionary )
- {
- for ( pPtr = First(); pPtr; pPtr = Next() )
- delete (Dict*)pPtr;
-
- for ( pPtr = rDictionary.First(); pPtr; pPtr = rDictionary.Next() )
- Insert( new Dict( ((Dict*)pPtr)->mnId, ((Dict*)pPtr)->aString ), LIST_APPEND );
- }
- return *this;
-}
-
-// -----------------------------------------------------------------------
-
-Section::Section( Section& rSection )
-: List()
+Section::Section( const Section& rSection )
+ : mnTextEnc(rSection.mnTextEnc),
+ maEntries(rSection.maEntries.clone())
{
- mnTextEnc = rSection.mnTextEnc;
for ( int i = 0; i < 16; i++ )
aFMTID[ i ] = rSection.aFMTID[ i ];
- for ( PropEntry* pProp = (PropEntry*)rSection.First(); pProp; pProp = (PropEntry*)rSection.Next() )
- Insert( new PropEntry( *pProp ), LIST_APPEND );
}
// -----------------------------------------------------------------------
@@ -306,19 +223,20 @@ Section::Section( const sal_uInt8* pFMTID )
sal_Bool Section::GetProperty( sal_uInt32 nId, PropItem& rPropItem )
{
- PropEntry* pProp;
if ( nId )
{
- for ( pProp = (PropEntry*)First(); pProp; pProp = (PropEntry*)Next() )
+ boost::ptr_vector<PropEntry>::const_iterator iter;
+ for (iter = maEntries.begin(); iter != maEntries.end(); ++iter)
{
- if ( pProp->mnId == nId )
+ if (iter->mnId == nId)
break;
}
- if ( pProp )
+
+ if (iter != maEntries.end())
{
rPropItem.Clear();
rPropItem.SetTextEncoding( mnTextEnc );
- rPropItem.Write( pProp->mpBuf, pProp->mnSize );
+ rPropItem.Write( iter->mpBuf,iter->mnSize );
rPropItem.Seek( STREAM_SEEK_TO_BEGIN );
return sal_True;
}
@@ -338,18 +256,19 @@ void Section::AddProperty( sal_uInt32 nId, const sal_uInt8* pBuf, sal_uInt32 nBu
nId = 0;
// keine doppelten PropId's zulassen, sortieren
- for ( sal_uInt32 i = 0; i < Count(); i++ )
+ boost::ptr_vector<PropEntry>::iterator iter;
+ for ( iter = maEntries.begin(); iter != maEntries.end(); ++iter )
{
- PropEntry* pPropEntry = (PropEntry*)GetObject( i );
- if ( pPropEntry->mnId == nId )
- delete (PropEntry*)Replace( new PropEntry( nId, pBuf, nBufSize, mnTextEnc ), i );
- else if ( pPropEntry->mnId > nId )
- Insert( new PropEntry( nId, pBuf, nBufSize, mnTextEnc ), i );
+ if ( iter->mnId == nId )
+ maEntries.replace( iter, new PropEntry( nId, pBuf, nBufSize, mnTextEnc ));
+ else if ( iter->mnId > nId )
+ maEntries.insert( iter, new PropEntry( nId, pBuf, nBufSize, mnTextEnc ));
else
continue;
return;
}
- Insert( new PropEntry( nId, pBuf, nBufSize, mnTextEnc ), LIST_APPEND );
+
+ maEntries.push_back( new PropEntry( nId, pBuf, nBufSize, mnTextEnc ) );
}
// -----------------------------------------------------------------------
@@ -358,18 +277,17 @@ sal_Bool Section::GetDictionary( Dictionary& rDict )
{
sal_Bool bRetValue = sal_False;
- Dictionary aDict;
- PropEntry* pProp;
-
- for ( pProp = (PropEntry*)First(); pProp; pProp = (PropEntry*)Next() )
+ boost::ptr_vector<PropEntry>::iterator iter;
+ for (iter = maEntries.begin(); iter != maEntries.end(); ++iter)
{
- if ( pProp->mnId == 0 )
+ if ( iter->mnId == 0 )
break;
}
- if ( pProp )
+
+ if ( iter != maEntries.end() )
{
sal_uInt32 nDictCount, nId, nSize, nPos;
- SvMemoryStream aStream( (sal_Int8*)pProp->mpBuf, pProp->mnSize, STREAM_READ );
+ SvMemoryStream aStream( (sal_Int8*)iter->mpBuf, iter->mnSize, STREAM_READ );
aStream.Seek( STREAM_SEEK_TO_BEGIN );
aStream >> nDictCount;
for ( sal_uInt32 i = 0; i < nDictCount; i++ )
@@ -398,29 +316,20 @@ sal_Bool Section::GetDictionary( Dictionary& rDict )
}
catch( const std::bad_alloc& )
{
- DBG_ERROR( "sd Section::GetDictionary bad alloc" );
+ OSL_FAIL( "sd Section::GetDictionary bad alloc" );
}
if ( !aString.Len() )
break;
- aDict.AddProperty( nId, aString );
+ rDict.insert( std::make_pair(aString,nId) );
}
bRetValue = sal_True;
}
}
- rDict = aDict;
return bRetValue;
}
// -----------------------------------------------------------------------
-Section::~Section()
-{
- for ( PropEntry* pProp = (PropEntry*)First(); pProp; pProp = (PropEntry*)Next() )
- delete pProp;
-}
-
-// -----------------------------------------------------------------------
-
void Section::Read( SvStorageStream *pStrm )
{
sal_uInt32 i, nSecOfs, nSecSize, nPropCount, nPropId, nPropOfs, nPropType, nPropSize, nCurrent, nVectorCount, nTemp, nStrmSize;
@@ -502,8 +411,12 @@ void Section::Read( SvStorageStream *pStrm )
break;
case VT_LPWSTR :
+ {
*pStrm >> nTemp;
- nPropSize += ( nTemp << 1 ) + 4;
+ // looks like these are aligned to 4 bytes
+ sal_uInt32 nLength = nPropOfs + nSecOfs + nPropSize + ( nTemp << 1 ) + 4;
+ nPropSize += ( nTemp << 1 ) + 4 + (nLength % 4);
+ }
break;
case VT_BLOB_OBJECT :
@@ -539,6 +452,9 @@ void Section::Read( SvStorageStream *pStrm )
break;
}
pStrm->Seek( nPropOfs + nSecOfs );
+ // make sure we don't overflow the section size
+ if( nPropSize > nSecSize - nSecOfs )
+ nPropSize = nSecSize - nSecOfs;
sal_uInt8* pBuf = new sal_uInt8[ nPropSize ];
pStrm->Read( pBuf, nPropSize );
AddProperty( nPropId, pBuf, nPropSize );
@@ -602,18 +518,13 @@ void Section::Read( SvStorageStream *pStrm )
// -----------------------------------------------------------------------
-Section& Section::operator=( Section& rSection )
+Section& Section::operator=( const Section& rSection )
{
- PropEntry* pProp;
-
if ( this != &rSection )
{
memcpy( (void*)aFMTID, (void*)rSection.aFMTID, 16 );
- for ( pProp = (PropEntry*)First(); pProp; pProp = (PropEntry*)Next() )
- delete pProp;
- Clear();
- for ( pProp = (PropEntry*)rSection.First(); pProp; pProp = (PropEntry*)rSection.Next() )
- Insert( new PropEntry( *pProp ), LIST_APPEND );
+
+ maEntries = rSection.maEntries.clone();
}
return *this;
}
@@ -643,38 +554,28 @@ PropRead::PropRead( SvStorage& rStorage, const String& rName ) :
void PropRead::AddSection( Section& rSection )
{
- Insert( new Section( rSection ), LIST_APPEND );
+ maSections.push_back( new Section( rSection ) );
}
// -----------------------------------------------------------------------
const Section* PropRead::GetSection( const sal_uInt8* pFMTID )
{
- Section* pSection;
-
- for ( pSection = (Section*)First(); pSection; pSection = (Section*)Next() )
+ boost::ptr_vector<Section>::iterator it;
+ for ( it = maSections.begin(); it != maSections.end(); ++it)
{
- if ( memcmp( pSection->GetFMTID(), pFMTID, 16 ) == 0 )
- break;
+ if ( memcmp( it->GetFMTID(), pFMTID, 16 ) == 0 )
+ return &(*it);
}
- return pSection;
-}
-
-// -----------------------------------------------------------------------
-
-PropRead::~PropRead()
-{
- for ( Section* pSection = (Section*)First(); pSection; pSection = (Section*)Next() )
- delete pSection;
+ return NULL;
}
// -----------------------------------------------------------------------
void PropRead::Read()
{
- for ( Section* pSection = (Section*)First(); pSection; pSection = (Section*)Next() )
- delete pSection;
- Clear();
+ maSections.clear();
+
if ( mbStatus )
{
sal_uInt32 nSections;
@@ -708,10 +609,8 @@ void PropRead::Read()
// -----------------------------------------------------------------------
-PropRead& PropRead::operator=( PropRead& rPropRead )
+PropRead& PropRead::operator=( const PropRead& rPropRead )
{
- Section* pSection;
-
if ( this != &rPropRead )
{
mbStatus = rPropRead.mbStatus;
@@ -723,11 +622,9 @@ PropRead& PropRead::operator=( PropRead& rPropRead )
mnVersionHi = rPropRead.mnVersionHi;
memcpy( mApplicationCLSID, rPropRead.mApplicationCLSID, 16 );
- for ( pSection = (Section*)First(); pSection; pSection = (Section*)Next() )
- delete pSection;
- Clear();
- for ( pSection = (Section*)rPropRead.First(); pSection; pSection = (Section*)rPropRead.Next() )
- Insert( new Section( *pSection ), LIST_APPEND );
+ maSections = rPropRead.maSections.clone();
}
return *this;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/ppt/propread.hxx b/sd/source/filter/ppt/propread.hxx
index f2234c7ea..e0d6b9738 100755..100644
--- a/sd/source/filter/ppt/propread.hxx
+++ b/sd/source/filter/ppt/propread.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,10 +29,12 @@
#ifndef _PROPREAD_HXX_
#define _PROPREAD_HXX_
+#include <map>
+#include <boost/ptr_container/ptr_vector.hpp>
+
#include <tools/solar.h>
#include <sot/storage.hxx>
#include <tools/gen.hxx>
-#include <tools/list.hxx>
#include <tools/stream.hxx>
#include <tools/datetime.hxx>
@@ -107,6 +110,22 @@
// ------------------------------------------------------------------------
+typedef std::map<String,sal_uInt32> Dictionary;
+
+struct PropEntry
+{
+ sal_uInt32 mnId;
+ sal_uInt32 mnSize;
+ sal_uInt16 mnTextEnc;
+ sal_uInt8* mpBuf;
+
+ PropEntry( sal_uInt32 nId, const sal_uInt8* pBuf, sal_uInt32 nBufSize, sal_uInt16 nTextEnc );
+ PropEntry( const PropEntry& rProp );
+ ~PropEntry() { delete[] mpBuf; } ;
+
+ const PropEntry& operator=(const PropEntry& rPropEntry);
+};
+
class PropItem : public SvMemoryStream
{
sal_uInt16 mnTextEnc;
@@ -124,24 +143,10 @@ class PropItem : public SvMemoryStream
// ------------------------------------------------------------------------
-class Dictionary : protected List
-{
- friend class Section;
-
- void AddProperty( sal_uInt32 nId, const String& rString );
-
- public :
- Dictionary(){};
- ~Dictionary();
- Dictionary& operator=( Dictionary& rDictionary );
- sal_uInt32 GetProperty( const String& rPropName );
-};
-
-// ------------------------------------------------------------------------
-
-class Section : private List
+class Section
{
sal_uInt16 mnTextEnc;
+ boost::ptr_vector<PropEntry> maEntries;
protected:
@@ -151,10 +156,9 @@ class Section : private List
public:
Section( const sal_uInt8* pFMTID );
- Section( Section& rSection );
- ~Section();
+ Section( const Section& rSection );
- Section& operator=( Section& rSection );
+ Section& operator=( const Section& rSection );
sal_Bool GetProperty( sal_uInt32 nId, PropItem& rPropItem );
sal_Bool GetDictionary( Dictionary& rDict );
const sal_uInt8* GetFMTID() const { return aFMTID; };
@@ -163,7 +167,7 @@ class Section : private List
// ------------------------------------------------------------------------
-class PropRead : private List
+class PropRead
{
sal_Bool mbStatus;
SvStorageStreamRef mpSvStream;
@@ -173,14 +177,14 @@ class PropRead : private List
sal_uInt16 mnVersionLo;
sal_uInt16 mnVersionHi;
sal_uInt8 mApplicationCLSID[ 16 ];
+ boost::ptr_vector<Section> maSections;
void AddSection( Section& rSection );
public:
PropRead( SvStorage& rSvStorage, const String& rName );
- ~PropRead();
- PropRead& operator=( PropRead& rPropRead );
+ PropRead& operator=( const PropRead& rPropRead );
const Section* GetSection( const sal_uInt8* pFMTID );
sal_Bool IsValid() const { return mbStatus; };
void Read();
@@ -189,3 +193,4 @@ class PropRead : private List
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/sdfilter.cxx b/sd/source/filter/sdfilter.cxx
index 62ac970fd..1ff3487ea 100644
--- a/sd/source/filter/sdfilter.cxx
+++ b/sd/source/filter/sdfilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,7 +79,7 @@ SdFilter::~SdFilter()
::rtl::OUString SdFilter::ImplGetFullLibraryName( const ::rtl::OUString& rLibraryName ) const
{
- String aTemp( ::rtl::OUString::createFromAscii( SVLIBRARY( "?" ) ) );
+ String aTemp(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SVLIBRARY("?"))));
xub_StrLen nIndex = aTemp.Search( (sal_Unicode)'?' );
aTemp.Replace( nIndex, 1, rLibraryName );
::rtl::OUString aLibraryName( aTemp );
@@ -92,7 +93,8 @@ extern "C" { static void SAL_CALL thisModule() {} }
::osl::Module* SdFilter::OpenLibrary( const ::rtl::OUString& rLibraryName ) const
{
std::auto_ptr< osl::Module > mod(new osl::Module);
- return mod->loadRelative(&thisModule, ImplGetFullLibraryName(rLibraryName))
+ return mod->loadRelative(&thisModule, ImplGetFullLibraryName(rLibraryName),
+ SAL_LOADMODULE_GLOBAL | SAL_LOADMODULE_LAZY)
? mod.release() : 0;
}
@@ -107,27 +109,6 @@ void SdFilter::CreateStatusIndicator()
if ( pStatusBarItem )
pStatusBarItem->GetValue() >>= mxStatusIndicator;
-// try
-// {
-// if (mxModel.is())
-// {
-// Reference< XController > xController( mxModel->getCurrentController());
-// if( xController.is())
-// {
-// Reference< XFrame > xFrame( xController->getFrame());
-// if( xFrame.is())
-// {
-// Reference< XStatusIndicatorFactory > xFactory( xFrame, UNO_QUERY );
-// if( xFactory.is())
-// {
-// mxStatusIndicator = xFactory->createStatusIndicator();
-// }
-// }
-// }
-// }
-// }
-// catch( Exception& )
-// {
-// }
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/sdpptwrp.cxx b/sd/source/filter/sdpptwrp.cxx
index 1f31f59b8..3d4ee83ff 100755..100644
--- a/sd/source/filter/sdpptwrp.cxx
+++ b/sd/source/filter/sdpptwrp.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -99,7 +100,7 @@ sal_Bool SdPPTFilter::Import()
if( pDocStream )
{
pDocStream->SetVersion( pStorage->GetVersion() );
- pDocStream->SetKey( pStorage->GetKey() );
+ pDocStream->SetCryptMaskKey(pStorage->GetKey());
String aTraceConfigPath( RTL_CONSTASCII_USTRINGPARAM( "Office.Tracing/Import/PowerPoint" ) );
Sequence< PropertyValue > aConfigData( 1 );
@@ -143,12 +144,8 @@ sal_Bool SdPPTFilter::Export()
if( mxModel.is() )
{
SotStorageRef xStorRef = new SotStorage( mrMedium.GetOutStream(), sal_False );
- ExportPPT PPTExport = reinterpret_cast<ExportPPT>(pLibrary->getFunctionSymbol( ::rtl::OUString::createFromAscii("ExportPPT") ));
+ ExportPPT PPTExport = reinterpret_cast<ExportPPT>(pLibrary->getFunctionSymbol( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ExportPPT")) ));
- /* !!!
- if ( pViewShell && pViewShell->GetView() )
- pViewShell->GetView()->SdrEndTextEdit();
- */
if( PPTExport && xStorRef.Is() )
{
sal_uInt32 nCnvrtFlags = 0;
@@ -189,7 +186,7 @@ void SdPPTFilter::PreSaveBasic()
::osl::Module* pLibrary = OpenLibrary( mrMedium.GetFilter()->GetUserData() );
if( pLibrary )
{
- SaveVBA pSaveVBA= reinterpret_cast<SaveVBA>(pLibrary->getFunctionSymbol( ::rtl::OUString::createFromAscii("SaveVBA") ));
+ SaveVBA pSaveVBA= reinterpret_cast<SaveVBA>(pLibrary->getFunctionSymbol( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SaveVBA")) ));
if( pSaveVBA )
{
pSaveVBA( (SfxObjectShell&) mrDocShell, pBas );
@@ -197,3 +194,5 @@ void SdPPTFilter::PreSaveBasic()
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/xml/makefile.mk b/sd/source/filter/xml/makefile.mk
deleted file mode 100644
index 3abe1f6bd..000000000
--- a/sd/source/filter/xml/makefile.mk
+++ /dev/null
@@ -1,47 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=xml
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/sdtransform.obj \
- $(SLO)$/sdxmlwrp.obj
-
-# --- Targets --------------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/filter/xml/sdtransform.cxx b/sd/source/filter/xml/sdtransform.cxx
index 2d888ad88..1cf87f22b 100644
--- a/sd/source/filter/xml/sdtransform.cxx
+++ b/sd/source/filter/xml/sdtransform.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -195,17 +196,6 @@ void SdTransformOOo2xDocument::transformShape( SdrObject& rObj )
void SdTransformOOo2xDocument::transformTextShape( SdrTextObj& rTextShape )
{
-/*
- const SfxItemSet& rSet = rTextShape.GetMergedItemSet();
-
- if( (rSet.GetItemState( EE_PARA_LRSPACE ) == SFX_ITEM_SET) && (rSet.GetItemState( EE_PARA_NUMBULLET ) == SFX_ITEM_SET) )
- {
- SvxLRSpaceItem aItem( *static_cast<const SvxLRSpaceItem*>(rSet.GetItem( EE_PARA_LRSPACE )) );
- aItem.SetLeftValue( 0 );
- aItem.SetTxtFirstLineOfst( 0 );
- rTextShape.SetMergedItem( aItem );
- }
-*/
if(!rTextShape.IsEmptyPresObj())
{
@@ -216,8 +206,6 @@ void SdTransformOOo2xDocument::transformTextShape( SdrTextObj& rTextShape )
sal_uInt32 nCount = mrOutliner.GetParagraphCount();
- //Paragraph* pPara = NULL;
-
bool bChange = false;
for(sal_uInt16 nPara = 0; nPara < nCount; nPara++)
@@ -320,7 +308,7 @@ bool SdTransformOOo2xDocument::getBulletState( const SfxItemSet& rSet, sal_uInt1
bool SdTransformOOo2xDocument::transformItemSet( SfxItemSet& rSet, bool bNumbering )
{
bool bRet = false;
- if( bNumbering /* && (rSet.GetItemState( EE_PARA_LRSPACE ) == SFX_ITEM_SET) && (rSet.GetItemState( EE_PARA_NUMBULLET ) == SFX_ITEM_SET) */ )
+ if( bNumbering )
{
SvxLRSpaceItem aItem( *static_cast<const SvxLRSpaceItem*>(rSet.GetItem( EE_PARA_LRSPACE )) );
if( (aItem.GetLeft() != 0) || (aItem.GetTxtFirstLineOfst() != 0) )
@@ -374,3 +362,5 @@ bool SdTransformOOo2xDocument::removeAlienAttributes( SfxItemSet& rSet, sal_uInt
}
return false;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/filter/xml/sdxmlwrp.cxx b/sd/source/filter/xml/sdxmlwrp.cxx
index c40480ac1..1d0e1de7e 100755..100644
--- a/sd/source/filter/xml/sdxmlwrp.cxx
+++ b/sd/source/filter/xml/sdxmlwrp.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,7 +67,7 @@
#include <comphelper/propertysetinfo.hxx>
#include <unotools/saveopt.hxx>
-// #80365# include necessary for XML progress bar at load time
+// include necessary for XML progress bar at load time
#include <svl/itemset.hxx>
#include <svl/stritem.hxx>
#include <svtools/sfxecode.hxx>
@@ -100,7 +101,7 @@ extern void TransformOOo2xDocument( SdDrawDocument* pDocument );
#define MAP_LEN(x) x, sizeof(x) - 1
-#define XML_STRING(i, x) sal_Char __READONLY_DATA i[sizeof(x)] = x
+#define XML_STRING(i, x) sal_Char const i[sizeof(x)] = x
XML_STRING( sXML_metaStreamName, "meta.xml");
XML_STRING( sXML_styleStreamName, "styles.xml" );
@@ -231,7 +232,7 @@ sal_Int32 ReadThroughComponent(
// get parser
Reference< xml::sax::XParser > xParser(
rFactory->createInstance(
- OUString::createFromAscii("com.sun.star.xml.sax.Parser") ),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.sax.Parser")) ),
UNO_QUERY );
DBG_ASSERT( xParser.is(), "Can't create parser" );
if( !xParser.is() )
@@ -286,7 +287,7 @@ sal_Int32 ReadThroughComponent(
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "SAX parse exception catched while importing:\n" );
aError += ByteString( String( r.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
String sErr( String::CreateFromInt32( r.LineNumber ));
@@ -320,7 +321,7 @@ sal_Int32 ReadThroughComponent(
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "SAX exception catched while importing:\n" );
aError += ByteString( String( r.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
return SD_XML_READERROR;
}
@@ -330,7 +331,7 @@ sal_Int32 ReadThroughComponent(
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "Zip exception catched while importing:\n" );
aError += ByteString( String( r.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
return ERRCODE_IO_BROKENPACKAGE;
}
@@ -340,7 +341,7 @@ sal_Int32 ReadThroughComponent(
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "IO exception catched while importing:\n" );
aError += ByteString( String( r.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
return SD_XML_READERROR;
}
@@ -350,7 +351,7 @@ sal_Int32 ReadThroughComponent(
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "uno exception catched while importing:\n" );
aError += ByteString( String( r.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
return SD_XML_READERROR;
}
@@ -492,7 +493,7 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
/** property map for export info set */
PropertyMapEntry aImportInfoMap[] =
{
- // #80365# necessary properties for XML progress bar at load time
+ // necessary properties for XML progress bar at load time
{ MAP_LEN( "ProgressRange" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
{ MAP_LEN( "ProgressMax" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
{ MAP_LEN( "ProgressCurrent" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
@@ -520,7 +521,7 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
};
uno::Reference< beans::XPropertySet > xInfoSet( GenericPropertySet_CreateInstance( new PropertySetInfo( aImportInfoMap ) ) );
- xInfoSet->setPropertyValue( OUString::createFromAscii( "Preview" ), uno::makeAny( mrDocShell.GetDoc()->IsStarDrawPreviewMode() ) );
+ xInfoSet->setPropertyValue( OUString(RTL_CONSTASCII_USTRINGPARAM( "Preview" )), uno::makeAny( mrDocShell.GetDoc()->IsStarDrawPreviewMode() ) );
// ---- get BuildId from parent container if available
@@ -552,7 +553,7 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
// -------------------------------------
- // #80365# try to get an XStatusIndicator from the Medium
+ // try to get an XStatusIndicator from the Medium
if( mbShowProgress )
{
SfxItemSet* pSet = mrMedium.GetItemSet();
@@ -624,7 +625,7 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
aName = pDocHierarchItem->GetValue();
}
else
- aName = ::rtl::OUString::createFromAscii( "dummyObjectName" );
+ aName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "dummyObjectName" ));
if( aName.getLength() )
{
@@ -719,7 +720,6 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
switch( nRet )
{
case 0: break;
- // case ERRCODE_SFX_WRONGPASSWORD: break;
case SD_XML_READERROR: break;
case ERRCODE_IO_BROKENPACKAGE:
if( xStorage.is() )
@@ -772,7 +772,7 @@ sal_Bool SdXMLFilter::Import( ErrCode& nError )
}
catch( Exception& )
{
- DBG_ERROR("sd::SdXMLFilter::Import(), exception during clearing of unused named items");
+ OSL_FAIL("sd::SdXMLFilter::Import(), exception during clearing of unused named items");
}
}
@@ -857,7 +857,7 @@ sal_Bool SdXMLFilter::Export()
if( !mxModel.is() )
{
- DBG_ERROR("Got NO Model in XMLExport");
+ OSL_FAIL("Got NO Model in XMLExport");
return sal_False;
}
@@ -871,7 +871,7 @@ sal_Bool SdXMLFilter::Export()
if( !xServiceInfo.is() || !xServiceInfo->supportsService( OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.drawing.GenericDrawingDocument" ) ) ) )
{
- DBG_ERROR( "Model is no DrawingDocument in XMLExport" );
+ OSL_FAIL( "Model is no DrawingDocument in XMLExport" );
return sal_False;
}
@@ -879,7 +879,7 @@ sal_Bool SdXMLFilter::Export()
if( !xServiceFactory.is() )
{
- DBG_ERROR( "got no service manager" );
+ OSL_FAIL( "got no service manager" );
return sal_False;
}
@@ -887,7 +887,7 @@ sal_Bool SdXMLFilter::Export()
if( !xWriter.is() )
{
- DBG_ERROR( "com.sun.star.xml.sax.Writer service missing" );
+ OSL_FAIL( "com.sun.star.xml.sax.Writer service missing" );
return sal_False;
}
uno::Reference<xml::sax::XDocumentHandler> xHandler( xWriter, uno::UNO_QUERY );
@@ -895,7 +895,6 @@ sal_Bool SdXMLFilter::Export()
/** property map for export info set */
PropertyMapEntry aExportInfoMap[] =
{
- // #82003#
{ MAP_LEN( "ProgressRange" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
{ MAP_LEN( "ProgressMax" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
{ MAP_LEN( "ProgressCurrent" ), 0, &::getCppuType((const sal_Int32*)0), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0},
@@ -979,7 +978,6 @@ sal_Bool SdXMLFilter::Export()
xGrfResolver = pGraphicHelper;
}
- // #82003#
if(mbShowProgress)
{
CreateStatusIndicator();
@@ -1094,7 +1092,6 @@ sal_Bool SdXMLFilter::Export()
}
while( bDocRet && pServices->mpService );
- // #82003#
if(mbShowProgress)
{
if(mxStatusIndicator.is())
@@ -1102,12 +1099,12 @@ sal_Bool SdXMLFilter::Export()
}
}
}
- catch(uno::Exception e)
+ catch(uno::Exception &e)
{
#if OSL_DEBUG_LEVEL > 1
ByteString aError( "uno Exception caught while exporting:\n" );
aError += ByteString( String( e.Message), RTL_TEXTENCODING_ASCII_US );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
#endif
bDocRet = sal_False;
}
@@ -1122,3 +1119,5 @@ sal_Bool SdXMLFilter::Export()
return bDocRet;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/helper/makefile.mk b/sd/source/helper/makefile.mk
deleted file mode 100644
index 7c87f3e67..000000000
--- a/sd/source/helper/makefile.mk
+++ /dev/null
@@ -1,47 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-PRJNAME=sd
-TARGET=helper
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-# --- Files --------------------------------------------------------
-
-SLOFILES =\
- $(SLO)$/simplereferencecomponent.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/helper/simplereferencecomponent.cxx b/sd/source/helper/simplereferencecomponent.cxx
index 1326314c5..e7e391b53 100644
--- a/sd/source/helper/simplereferencecomponent.cxx
+++ b/sd/source/helper/simplereferencecomponent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifndef _SALHELPER_SIMPLEREFERENCECOMPONENT_HXX_
#include "helper/simplereferencecomponent.hxx"
-#endif
#include "com/sun/star/uno/RuntimeException.hpp"
#include "osl/diagnose.h"
@@ -76,7 +75,7 @@ void SimpleReferenceComponent::release()
{
#if OSL_DEBUG_LEVEL > 0
rtl::OString msg( rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_ASCII_US ) );
- OSL_ENSURE( 0, msg.getStr() );
+ OSL_FAIL( msg.getStr() );
#endif
}
}
@@ -138,3 +137,5 @@ void SimpleReferenceComponent::operator delete(void * pPtr,
::operator delete(pPtr, rNothrow);
#endif // WNT
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
index 2932877b8..4bfc5331f 100755..100644
--- a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
+++ b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -280,7 +281,7 @@ Reference<XAccessible> SAL_CALL
return mxAccessibleOLEObject;
throw lang::IndexOutOfBoundsException (
- ::rtl::OUString::createFromAscii ("no child with index ")
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("no child with index ") ))
+ rtl::OUString::valueOf(nIndex),
NULL);
}
@@ -840,3 +841,5 @@ void
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx b/sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx
index f8524ebbb..6a94e9192 100644
--- a/sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx
+++ b/sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,7 +61,7 @@
#include "accessibility.hrc"
#include "sdresid.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
using ::rtl::OUString;
using namespace ::com::sun::star;
@@ -259,7 +260,7 @@ uno::Reference<XAccessible> SAL_CALL
}
else
throw lang::IndexOutOfBoundsException (
- ::rtl::OUString::createFromAscii ("no accessible child with index ")
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("no accessible child with index "))
+ rtl::OUString::valueOf(nIndex),
static_cast<uno::XWeak*>(this));
}
@@ -403,26 +404,26 @@ void SAL_CALL
if( aServices.getLength() >= 2 &&
aServices[1] == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.PresentationView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sName = String( SdResId(SID_SD_A11Y_I_DRAWVIEW_N) );
}
else
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sName = String( SdResId(SID_SD_A11Y_D_DRAWVIEW_N) );
}
}
else if (sFirstService == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.NotesView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sName = String( SdResId(SID_SD_A11Y_I_NOTESVIEW_N) );
}
else if (sFirstService == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.HandoutView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sName = String( SdResId(SID_SD_A11Y_I_HANDOUTVIEW_N) );
}
@@ -460,26 +461,26 @@ void SAL_CALL
if( aServices.getLength() >= 2 &&
aServices[1] == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.PresentationView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sDescription = String( SdResId(SID_SD_A11Y_I_DRAWVIEW_D) );
}
else
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sDescription = String( SdResId(SID_SD_A11Y_D_DRAWVIEW_D) );
}
}
else if (sFirstService == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.NotesView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sDescription = String( SdResId(SID_SD_A11Y_I_NOTESVIEW_D) );
}
else if (sFirstService == OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.HandoutView")))
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sDescription = String( SdResId(SID_SD_A11Y_I_HANDOUTVIEW_D) );
}
@@ -504,7 +505,7 @@ sal_Bool
AccessibleDrawDocumentView::implIsSelected( sal_Int32 nAccessibleChildIndex )
throw (uno::RuntimeException)
{
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
uno::Reference< view::XSelectionSupplier > xSel( mxController, uno::UNO_QUERY );
sal_Bool bRet = sal_False;
@@ -549,9 +550,8 @@ void
AccessibleDrawDocumentView::implSelect( sal_Int32 nAccessibleChildIndex, sal_Bool bSelect )
throw (lang::IndexOutOfBoundsException, uno::RuntimeException)
{
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
uno::Reference< view::XSelectionSupplier > xSel( mxController, uno::UNO_QUERY );
- AccessibleShape* pAccessibleChild;
if( xSel.is() )
{
@@ -572,10 +572,7 @@ void
AccessibleShape* pAcc = AccessibleShape::getImplementation( getAccessibleChild( i ) );
if( pAcc && pAcc->GetXShape().is() )
- {
xShapes->add( pAcc->GetXShape() );
- pAccessibleChild = pAcc;
- }
}
if( xShapes->getCount() )
@@ -592,7 +589,6 @@ void
AccessibleShape* pAcc = AccessibleShape::getImplementation(
getAccessibleChild( nAccessibleChildIndex ));
- pAccessibleChild = pAcc;
// Add or remove the shape that is made accessible from the
// selection of the controller.
@@ -740,3 +736,5 @@ void AccessibleDrawDocumentView::UpdateAccessibleName (void)
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx b/sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx
index a3e2756ef..d20e1a688 100755..100644
--- a/sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx
+++ b/sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <editeng/unoedhlp.hxx>
#include <svx/svdoutl.hxx>
-#ifndef SD_ACCESSIBILITY_ACCESSIBLE_OUTLINE_EDIT_SOURCE_HXX
#include <AccessibleOutlineEditSource.hxx>
-#endif
#include "OutlineView.hxx"
#include <svx/sdrpaintwindow.hxx>
@@ -223,3 +222,5 @@ namespace accessibility
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleOutlineView.cxx b/sd/source/ui/accessibility/AccessibleOutlineView.cxx
index b2dcd2c00..46ab61da1 100644
--- a/sd/source/ui/accessibility/AccessibleOutlineView.cxx
+++ b/sd/source/ui/accessibility/AccessibleOutlineView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,17 +36,11 @@
#include <com/sun/star/frame/XFrame.hpp>
#include <com/sun/star/document/XEventBroadcaster.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
-#ifndef _COM_SUN_STAR_ACCESSIBLE_ACCESSIBLEEVENTID_HPP_
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
-#endif
#include <com/sun/star/lang/IndexOutOfBoundsException.hpp>
-#ifndef _COM_SUN_STAR_LANG_XMULSTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
#include <rtl/ustring.h>
-#ifndef _SFXFRAME_HXX
#include<sfx2/viewfrm.hxx>
-#endif
#include <svx/AccessibleShape.hxx>
@@ -65,7 +60,7 @@
#include "accessibility.hrc"
#include "sdresid.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
using namespace ::com::sun::star;
using namespace ::com::sun::star::accessibility;
@@ -83,7 +78,7 @@ AccessibleOutlineView::AccessibleOutlineView (
: AccessibleDocumentViewBase (pSdWindow, pViewShell, rxController, rxParent),
maTextHelper( ::std::auto_ptr< SvxEditSource >( NULL ) )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// Beware! Here we leave the paths of the UNO API and descend into the
// depths of the core. Necessary for making the edit engine accessible.
@@ -116,7 +111,7 @@ AccessibleOutlineView::~AccessibleOutlineView (void)
void AccessibleOutlineView::Init (void)
{
- // #105479# Set event source _before_ starting to listen
+ // Set event source _before_ starting to listen
maTextHelper.SetEventSource(this);
AccessibleDocumentViewBase::Init ();
@@ -199,7 +194,7 @@ void AccessibleOutlineView::FireEvent(const AccessibleEventObject& aEvent )
void AccessibleOutlineView::Activated (void)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// delegate listener handling to children manager.
maTextHelper.SetFocus(sal_True);
@@ -207,7 +202,7 @@ void AccessibleOutlineView::Activated (void)
void AccessibleOutlineView::Deactivated (void)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// delegate listener handling to children manager.
maTextHelper.SetFocus(sal_False);
@@ -259,7 +254,7 @@ void SAL_CALL
AccessibleOutlineView::CreateAccessibleName (void)
throw (::com::sun::star::uno::RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return String( SdResId(SID_SD_A11Y_I_OUTLINEVIEW_N) );
}
@@ -272,17 +267,19 @@ void SAL_CALL
AccessibleOutlineView::CreateAccessibleDescription (void)
throw (::com::sun::star::uno::RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return String( SdResId(SID_SD_A11Y_I_OUTLINEVIEW_D) );
}
void AccessibleOutlineView::UpdateChildren()
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// Update visible children
maTextHelper.UpdateChildren();
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessiblePageShape.cxx b/sd/source/ui/accessibility/AccessiblePageShape.cxx
index e446d4178..827f2a2d4 100644
--- a/sd/source/ui/accessibility/AccessiblePageShape.cxx
+++ b/sd/source/ui/accessibility/AccessiblePageShape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,12 +31,8 @@
#include "AccessiblePageShape.hxx"
#include <svx/AccessibleShapeInfo.hxx>
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLE_ROLE_HPP_
#include <com/sun/star/accessibility/AccessibleRole.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLE_STATE_TYPE_HPP_
#include <com/sun/star/accessibility/AccessibleStateType.hpp>
-#endif
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/container/XChild.hpp>
#include <com/sun/star/drawing/XShapes.hpp>
@@ -106,7 +103,7 @@ uno::Reference<XAccessible> SAL_CALL
throw (::com::sun::star::uno::RuntimeException)
{
throw lang::IndexOutOfBoundsException (
- ::rtl::OUString::createFromAscii ("page shape has no children"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("page shape has no children") ),
static_cast<uno::XWeak*>(this));
}
@@ -199,7 +196,7 @@ sal_Int32 SAL_CALL AccessiblePageShape::getForeground (void)
if (aSet.is())
{
uno::Any aColor;
- aColor = aSet->getPropertyValue (::rtl::OUString::createFromAscii ("LineColor"));
+ aColor = aSet->getPropertyValue (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LineColor")));
aColor >>= nColor;
}
}
@@ -250,7 +247,7 @@ sal_Int32 SAL_CALL AccessiblePageShape::getBackground (void)
if (xBGSet.is())
{
uno::Any aColor;
- aColor = xBGSet->getPropertyValue (::rtl::OUString::createFromAscii ("FillColor"));
+ aColor = xBGSet->getPropertyValue (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FillColor")));
aColor >>= nColor;
}
else
@@ -375,3 +372,4 @@ void AccessiblePageShape::dispose (void)
} // end of namespace accessibility
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessiblePresentationGraphicShape.cxx b/sd/source/ui/accessibility/AccessiblePresentationGraphicShape.cxx
index 0d3882eca..9e8cb2add 100644
--- a/sd/source/ui/accessibility/AccessiblePresentationGraphicShape.cxx
+++ b/sd/source/ui/accessibility/AccessiblePresentationGraphicShape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,11 +109,11 @@ AccessiblePresentationGraphicShape::~AccessiblePresentationGraphicShape (void)
switch (nShapeType)
{
case PRESENTATION_GRAPHIC_OBJECT:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationGraphicShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(("PresentationGraphicShape"))));
break;
default:
aDG.Initialize (
- ::rtl::OUString::createFromAscii ("Unknown accessible presentation graphic shape"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Unknown accessible presentation graphic shape")));
uno::Reference<drawing::XShapeDescriptor> xDescriptor (mxShape, uno::UNO_QUERY);
if (xDescriptor.is())
{
@@ -125,3 +126,5 @@ AccessiblePresentationGraphicShape::~AccessiblePresentationGraphicShape (void)
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessiblePresentationOLEShape.cxx b/sd/source/ui/accessibility/AccessiblePresentationOLEShape.cxx
index 74fb38c1a..0723ecf88 100644
--- a/sd/source/ui/accessibility/AccessiblePresentationOLEShape.cxx
+++ b/sd/source/ui/accessibility/AccessiblePresentationOLEShape.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -49,28 +50,19 @@ AccessiblePresentationOLEShape::AccessiblePresentationOLEShape (
{
}
-
-
-
AccessiblePresentationOLEShape::~AccessiblePresentationOLEShape (void)
{
}
-
-
-
//===== XServiceInfo ========================================================
-
-::rtl::OUString SAL_CALL
+
+::rtl::OUString SAL_CALL
AccessiblePresentationOLEShape::getImplementationName (void)
throw (::com::sun::star::uno::RuntimeException)
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AccessiblePresentationOLEShape"));
}
-
-
-
/// Set this object's name if it is different to the current name.
::rtl::OUString
AccessiblePresentationOLEShape::CreateAccessibleBaseName (void)
@@ -102,9 +94,6 @@ AccessiblePresentationOLEShape::~AccessiblePresentationOLEShape (void)
return sName;
}
-
-
-
::rtl::OUString
AccessiblePresentationOLEShape::CreateAccessibleDescription (void)
throw (::com::sun::star::uno::RuntimeException)
@@ -115,25 +104,25 @@ AccessiblePresentationOLEShape::~AccessiblePresentationOLEShape (void)
switch (nShapeType)
{
case PRESENTATION_OLE:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationOLEShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("PresentationOLEShape")));
//SVX_RESSTR(RID_SVXSTR_A11Y_ST_RECTANGLE));
- aDG.AddProperty (OUString::createFromAscii ("CLSID"),
+ aDG.AddProperty (OUString(RTL_CONSTASCII_USTRINGPARAM ("CLSID")),
DescriptionGenerator::STRING);
break;
case PRESENTATION_CHART:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationChartShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationChartShape")));
//SVX_RESSTR(RID_SVXSTR_A11Y_ST_RECTANGLE));
- aDG.AddProperty (OUString::createFromAscii ("CLSID"),
+ aDG.AddProperty (OUString(RTL_CONSTASCII_USTRINGPARAM("CLSID")),
DescriptionGenerator::STRING);
break;
case PRESENTATION_TABLE:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationTableShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationTableShape")));
//SVX_RESSTR(RID_SVXSTR_A11Y_ST_RECTANGLE));
- aDG.AddProperty (OUString::createFromAscii ("CLSID"),
+ aDG.AddProperty (OUString(RTL_CONSTASCII_USTRINGPARAM("CLSID")),
DescriptionGenerator::STRING);
break;
default:
- aDG.Initialize (::rtl::OUString::createFromAscii ("Unknown accessible presentation OLE shape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Unknown accessible presentation OLE shape")));
uno::Reference<drawing::XShapeDescriptor> xDescriptor (mxShape, uno::UNO_QUERY);
if (xDescriptor.is())
{
@@ -146,3 +135,5 @@ AccessiblePresentationOLEShape::~AccessiblePresentationOLEShape (void)
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessiblePresentationShape.cxx b/sd/source/ui/accessibility/AccessiblePresentationShape.cxx
index bded19a1f..36d4f9cba 100644
--- a/sd/source/ui/accessibility/AccessiblePresentationShape.cxx
+++ b/sd/source/ui/accessibility/AccessiblePresentationShape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -135,37 +136,37 @@ AccessiblePresentationShape::~AccessiblePresentationShape (void)
switch (nShapeType)
{
case PRESENTATION_TITLE:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationTitleShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationTitleShape")));
break;
case PRESENTATION_OUTLINER:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationOutlinerShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationOutlinerShape")));
break;
case PRESENTATION_SUBTITLE:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationSubtitleShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationSubtitleShape")));
break;
case PRESENTATION_PAGE:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationPageShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationPageShape")));
break;
case PRESENTATION_NOTES:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationNotesShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationNotesShape")));
break;
case PRESENTATION_HANDOUT:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationHandoutShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationHandoutShape")));
break;
case PRESENTATION_HEADER:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationHeaderShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationHeaderShape")));
break;
case PRESENTATION_FOOTER:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationFooterShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationFooterShape")));
break;
case PRESENTATION_DATETIME:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationDateAndTimeShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationDateAndTimeShape")));
break;
case PRESENTATION_PAGENUMBER:
- aDG.Initialize (::rtl::OUString::createFromAscii ("PresentationPageNumberShape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationPageNumberShape")));
break;
default:
- aDG.Initialize (::rtl::OUString::createFromAscii ("Unknown accessible presentation shape"));
+ aDG.Initialize (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Unknown accessible presentation shape")));
uno::Reference<drawing::XShapeDescriptor> xDescriptor (mxShape, uno::UNO_QUERY);
if (xDescriptor.is())
{
@@ -178,3 +179,5 @@ AccessiblePresentationShape::~AccessiblePresentationShape (void)
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleScrollPanel.cxx b/sd/source/ui/accessibility/AccessibleScrollPanel.cxx
index 93f16bb19..62af8aa16 100644
--- a/sd/source/ui/accessibility/AccessibleScrollPanel.cxx
+++ b/sd/source/ui/accessibility/AccessibleScrollPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,7 +37,7 @@
#include <com/sun/star/accessibility/AccessibleStateType.hpp>
#include <unotools/accessiblestatesethelper.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
using ::rtl::OUString;
@@ -76,7 +77,7 @@ sal_Int32 SAL_CALL
throw (RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
sal_Int32 nChildCount (mrTreeNode.GetControlContainer().GetControlCount());
if (GetScrollPanel().IsVerticalScrollBarVisible())
@@ -96,7 +97,7 @@ Reference<XAccessible> SAL_CALL
RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
Reference<XAccessible> xChild;
@@ -149,3 +150,5 @@ ScrollPanel& AccessibleScrollPanel::GetScrollPanel (void) const
}
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx b/sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx
index 91ee29fd9..ffe4e092a 100755..100644
--- a/sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx
+++ b/sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,7 +115,7 @@ void AccessibleSlideSorterObject::FireAccessibleEvent (
void SAL_CALL AccessibleSlideSorterObject::disposing (void)
{
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
// Send a disposing to all listeners.
if (mnClientId != 0)
@@ -174,7 +175,7 @@ sal_Int32 SAL_CALL AccessibleSlideSorterObject::getAccessibleIndexInParent()
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
sal_Int32 nIndexInParent(-1);
if (mxParent.is())
@@ -224,7 +225,7 @@ sal_Int16 SAL_CALL AccessibleSlideSorterObject::getAccessibleRole (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
SdPage* pPage = GetPage();
if (pPage != NULL)
@@ -252,7 +253,7 @@ Reference<XAccessibleStateSet> SAL_CALL
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
::utl::AccessibleStateSetHelper* pStateSet = new ::utl::AccessibleStateSetHelper();
if (mxParent.is())
@@ -385,7 +386,7 @@ awt::Rectangle SAL_CALL AccessibleSlideSorterObject::getBounds (void)
{
ThrowIfDisposed ();
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
Rectangle aBBox (
mrSlideSorter.GetView().GetLayouter().GetPageObjectLayouter()->GetBoundingBox(
@@ -433,7 +434,7 @@ awt::Point SAL_CALL AccessibleSlideSorterObject::getLocationOnScreen (void)
{
ThrowIfDisposed ();
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
awt::Point aLocation (getLocation());
@@ -581,3 +582,5 @@ SdPage* AccessibleSlideSorterObject::GetPage (void) const
} // end of namespace ::accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleSlideSorterView.cxx b/sd/source/ui/accessibility/AccessibleSlideSorterView.cxx
index 4b3a61a93..6552c6927 100644
--- a/sd/source/ui/accessibility/AccessibleSlideSorterView.cxx
+++ b/sd/source/ui/accessibility/AccessibleSlideSorterView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,6 +94,7 @@ public:
DECL_LINK(SelectionChangeListener, void*);
DECL_LINK(BroadcastSelectionChange, void*);
DECL_LINK(FocusChangeListener, void*);
+ DECL_LINK(VisibilityChangeListener, void*);
DECL_LINK(UpdateChildrenCallback, void*);
private:
@@ -122,7 +124,6 @@ AccessibleSlideSorterView::AccessibleSlideSorterView(
const Reference<XAccessible>& rxParent,
::Window* pContentWindow)
: AccessibleSlideSorterViewBase(MutexOwner::maMutex),
- mpImpl(new Implementation(*this,rSlideSorter,pContentWindow)),
mrSlideSorter(rSlideSorter),
mxParent(rxParent),
mnClientId(0),
@@ -133,6 +134,16 @@ AccessibleSlideSorterView::AccessibleSlideSorterView(
+
+void AccessibleSlideSorterView::Init()
+{
+ mpImpl.reset(new Implementation(*this,mrSlideSorter,mpContentWindow));
+}
+
+
+
+
+
AccessibleSlideSorterView::~AccessibleSlideSorterView (void)
{
Destroyed ();
@@ -236,7 +247,7 @@ Reference<XAccessible > SAL_CALL AccessibleSlideSorterView::getAccessibleParent
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
Reference<XAccessible> xParent;
if (mpContentWindow != NULL)
@@ -254,7 +265,7 @@ sal_Int32 SAL_CALL AccessibleSlideSorterView::getAccessibleIndexInParent (void)
{
OSL_ASSERT(getAccessibleParent().is());
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
sal_Int32 nIndexInParent(-1);
@@ -292,7 +303,7 @@ sal_Int16 SAL_CALL AccessibleSlideSorterView::getAccessibleRole (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
return String(SdResId(SID_SD_A11Y_I_SLIDEVIEW_D));
}
@@ -304,7 +315,7 @@ sal_Int16 SAL_CALL AccessibleSlideSorterView::getAccessibleRole (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
return String(SdResId(SID_SD_A11Y_I_SLIDEVIEW_N));
}
@@ -327,7 +338,7 @@ Reference<XAccessibleStateSet > SAL_CALL
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
::utl::AccessibleStateSetHelper* pStateSet = new ::utl::AccessibleStateSetHelper();
pStateSet->AddState(AccessibleStateType::FOCUSABLE);
@@ -446,7 +457,7 @@ Reference<XAccessible> SAL_CALL
{
ThrowIfDisposed();
Reference<XAccessible> xAccessible;
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
const Point aTestPoint (aPoint.X, aPoint.Y);
::sd::slidesorter::model::SharedPageDescriptor pHitDescriptor (
@@ -465,7 +476,7 @@ awt::Rectangle SAL_CALL AccessibleSlideSorterView::getBounds (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
awt::Rectangle aBBox;
if (mpContentWindow != NULL)
@@ -511,7 +522,7 @@ awt::Point SAL_CALL AccessibleSlideSorterView::getLocationOnScreen()
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
awt::Point aParentLocationOnScreen;
Reference<XAccessible> xParent (getAccessibleParent());
@@ -556,7 +567,7 @@ void SAL_CALL AccessibleSlideSorterView::grabFocus (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
if (mpContentWindow)
mpContentWindow->GrabFocus();
@@ -595,7 +606,7 @@ void SAL_CALL AccessibleSlideSorterView::selectAccessibleChild (sal_Int32 nChild
RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
AccessibleSlideSorterObject* pChild = mpImpl->GetAccessibleChild(nChildIndex);
if (pChild != NULL)
@@ -613,7 +624,7 @@ sal_Bool SAL_CALL AccessibleSlideSorterView::isAccessibleChildSelected (sal_Int3
{
ThrowIfDisposed();
sal_Bool bIsSelected = sal_False;
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
AccessibleSlideSorterObject* pChild = mpImpl->GetAccessibleChild(nChildIndex);
if (pChild != NULL)
@@ -632,7 +643,7 @@ void SAL_CALL AccessibleSlideSorterView::clearAccessibleSelection (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
mrSlideSorter.GetController().GetPageSelector().DeselectAllPages();
}
@@ -644,7 +655,7 @@ void SAL_CALL AccessibleSlideSorterView::selectAllAccessibleChildren (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
mrSlideSorter.GetController().GetPageSelector().SelectAllPages();
}
@@ -656,7 +667,7 @@ sal_Int32 SAL_CALL AccessibleSlideSorterView::getSelectedAccessibleChildCount (v
throw (uno::RuntimeException)
{
ThrowIfDisposed ();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return mrSlideSorter.GetController().GetPageSelector().GetSelectedPageCount();
}
@@ -668,7 +679,7 @@ Reference<XAccessible > SAL_CALL
throw (lang::IndexOutOfBoundsException, uno::RuntimeException)
{
ThrowIfDisposed ();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
Reference<XAccessible> xChild;
::sd::slidesorter::controller::PageSelector& rSelector (
@@ -701,7 +712,7 @@ void SAL_CALL AccessibleSlideSorterView::deselectAccessibleChild (sal_Int32 nChi
RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
AccessibleSlideSorterObject* pChild = mpImpl->GetAccessibleChild(nChildIndex);
if (pChild != NULL)
@@ -853,6 +864,11 @@ void AccessibleSlideSorterView::Implementation::UpdateChildren (void)
// Create new children for the modified visible range.
maPageObjects.resize(mrSlideSorter.GetModel().GetPageCount());
+
+ // No Visible children
+ if (mnFirstVisibleChild == -1 && mnLastVisibleChild == -1)
+ return;
+
for (sal_Int32 nIndex(mnFirstVisibleChild); nIndex<=mnLastVisibleChild; ++nIndex)
GetAccessibleChild(nIndex);
}
@@ -960,7 +976,7 @@ void AccessibleSlideSorterView::Implementation::ConnectListeners (void)
mrSlideSorter.GetController().GetFocusManager().AddFocusChangeListener(
LINK(this,AccessibleSlideSorterView::Implementation,FocusChangeListener));
mrSlideSorter.GetView().AddVisibilityChangeListener(
- LINK(this,AccessibleSlideSorterView::Implementation,UpdateChildrenCallback));
+ LINK(this,AccessibleSlideSorterView::Implementation,VisibilityChangeListener));
}
@@ -973,7 +989,7 @@ void AccessibleSlideSorterView::Implementation::ReleaseListeners (void)
mrSlideSorter.GetController().GetSelectionManager()->RemoveSelectionChangeListener(
LINK(this,AccessibleSlideSorterView::Implementation,SelectionChangeListener));
mrSlideSorter.GetView().RemoveVisibilityChangeListener(
- LINK(this,AccessibleSlideSorterView::Implementation,UpdateChildrenCallback));
+ LINK(this,AccessibleSlideSorterView::Implementation,VisibilityChangeListener));
if (mpWindow != NULL)
mpWindow->RemoveEventListener(
@@ -1122,4 +1138,15 @@ IMPL_LINK(AccessibleSlideSorterView::Implementation, UpdateChildrenCallback, voi
+IMPL_LINK(AccessibleSlideSorterView::Implementation, VisibilityChangeListener, void*, EMPTYARG )
+{
+ UpdateChildren();
+ return 1;
+}
+
+
+
+
} // end of namespace ::accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleTreeNode.cxx b/sd/source/ui/accessibility/AccessibleTreeNode.cxx
index 6c503c7db..bbac6af5d 100755..100644
--- a/sd/source/ui/accessibility/AccessibleTreeNode.cxx
+++ b/sd/source/ui/accessibility/AccessibleTreeNode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -160,7 +161,7 @@ sal_Int32 SAL_CALL AccessibleTreeNode::getAccessibleChildCount (void)
throw (RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return mrTreeNode.GetControlContainer().GetControlCount();
}
@@ -172,7 +173,7 @@ Reference<XAccessible > SAL_CALL
throw (lang::IndexOutOfBoundsException, RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
if (nIndex<0 || (sal_uInt32)nIndex>=mrTreeNode.GetControlContainer().GetControlCount())
throw lang::IndexOutOfBoundsException();
@@ -193,7 +194,7 @@ Reference<XAccessible > SAL_CALL AccessibleTreeNode::getAccessibleParent (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return mxParent;
}
@@ -205,7 +206,7 @@ sal_Int32 SAL_CALL AccessibleTreeNode::getAccessibleIndexInParent (void)
{
OSL_ASSERT(getAccessibleParent().is());
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
sal_Int32 nIndexInParent(-1);
@@ -274,7 +275,7 @@ Reference<XAccessibleStateSet > SAL_CALL
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return mrStateSet.get();
}
@@ -418,7 +419,7 @@ Reference<XAccessible> SAL_CALL
{
ThrowIfDisposed();
Reference<XAccessible> xChildAtPoint;
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
sal_Int32 nChildCount = getAccessibleChildCount();
for (sal_Int32 nIndex=0; nIndex<nChildCount; ++nIndex)
@@ -502,7 +503,7 @@ awt::Point SAL_CALL AccessibleTreeNode::getLocationOnScreen()
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aSolarGuard;
awt::Point aLocationOnScreen;
::Window* pWindow = mrTreeNode.GetWindow();
@@ -534,7 +535,7 @@ void SAL_CALL AccessibleTreeNode::grabFocus (void)
throw (uno::RuntimeException)
{
ThrowIfDisposed();
- const vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
if (mrTreeNode.GetWindow() != NULL)
mrTreeNode.GetWindow()->GrabFocus();
@@ -699,3 +700,5 @@ IMPL_LINK(AccessibleTreeNode, WindowEventListener, VclWindowEvent*, pEvent)
}
} // end of namespace ::accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/AccessibleViewForwarder.cxx b/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
index ae9ba6657..5ca1262c1 100755..100644
--- a/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
+++ b/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifndef _SVX_ACCESSIBILITY_ACCESSIBLE_VIEW_FORWARDER_HXX
#include "AccessibleViewForwarder.hxx"
-#endif
#include <svx/svdpntv.hxx>
#include <vcl/outdev.hxx>
#include <svx/sdrpaintwindow.hxx>
@@ -170,3 +169,5 @@ Size AccessibleViewForwarder::PixelToLogic (const Size& rSize) const
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/SdShapeTypes.cxx b/sd/source/ui/accessibility/SdShapeTypes.cxx
index 84305e7e0..a2cfee7bc 100644
--- a/sd/source/ui/accessibility/SdShapeTypes.cxx
+++ b/sd/source/ui/accessibility/SdShapeTypes.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,79 +70,75 @@ AccessibleShape*
}
}
-
-
-
-ShapeTypeDescriptor aSdShapeTypeList[] = {
- ShapeTypeDescriptor (
- PRESENTATION_OUTLINER,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.OutlinerShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_SUBTITLE,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.SubtitleShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_GRAPHIC_OBJECT,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.GraphicObjectShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_PAGE,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.PageShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_OLE,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.OLE2Shape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_CHART,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.ChartShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_TABLE,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.TableShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_NOTES,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.NotesShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_TITLE,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.TitleTextShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_HANDOUT,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.HandoutShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_HEADER,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.HeaderShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_FOOTER,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.FooterShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_DATETIME,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.DateTimeShape"),
- CreateSdAccessibleShape ),
- ShapeTypeDescriptor (
- PRESENTATION_PAGENUMBER,
- ::rtl::OUString::createFromAscii ("com.sun.star.presentation.SlideNumberShape"),
- CreateSdAccessibleShape )
-};
-
-
-
-
void RegisterImpressShapeTypes (void)
{
+ /** List of shape type descriptors corresponding to the
+ <type>SdShapeTypes</type> enum.
+ */
+ ShapeTypeDescriptor aSdShapeTypeList[] = {
+ ShapeTypeDescriptor (
+ PRESENTATION_OUTLINER,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.OutlinerShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_SUBTITLE,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.SubtitleShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_GRAPHIC_OBJECT,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.GraphicObjectShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_PAGE,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.PageShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_OLE,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.OLE2Shape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_CHART,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.ChartShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_TABLE,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.TableShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_NOTES,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ("com.sun.star.presentation.NotesShape"))),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_TITLE,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.TitleTextShape")),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_HANDOUT,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.HandoutShape")),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_HEADER,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.HeaderShape")),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_FOOTER,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.FooterShape")),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_DATETIME,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.DateTimeShape")),
+ CreateSdAccessibleShape ),
+ ShapeTypeDescriptor (
+ PRESENTATION_PAGENUMBER,
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.presentation.SlideNumberShape")),
+ CreateSdAccessibleShape )
+ };
+
ShapeTypeHandler::Instance().AddShapeTypeList (
PRESENTATION_PAGENUMBER - PRESENTATION_OUTLINER + 1,
aSdShapeTypeList);
}
-
-
-
} // end of namespace accessibility
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/accessibility/makefile.mk b/sd/source/ui/accessibility/makefile.mk
deleted file mode 100755
index 25d79aa7f..000000000
--- a/sd/source/ui/accessibility/makefile.mk
+++ /dev/null
@@ -1,71 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=accessibility
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/slidesorter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/AccessibleDocumentViewBase.obj \
- $(SLO)$/AccessibleDrawDocumentView.obj \
- $(SLO)$/AccessibleOutlineView.obj \
- $(SLO)$/AccessiblePresentationShape.obj \
- $(SLO)$/AccessiblePresentationGraphicShape.obj \
- $(SLO)$/AccessiblePresentationOLEShape.obj \
- $(SLO)$/AccessibleViewForwarder.obj \
- $(SLO)$/AccessibleOutlineEditSource.obj \
- $(SLO)$/AccessiblePageShape.obj \
- $(SLO)$/AccessibleScrollPanel.obj \
- $(SLO)$/AccessibleSlideSorterView.obj \
- $(SLO)$/AccessibleSlideSorterObject.obj \
- $(SLO)$/AccessibleTreeNode.obj \
- $(SLO)$/SdShapeTypes.obj
-
-
-EXCEPTIONSFILES=
-
-SRS2NAME = accessibility
-SRC2FILES = accessibility.src
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/animations/CustomAnimation.hrc b/sd/source/ui/animations/CustomAnimation.hrc
index 6016a800a..cd6a4b50b 100644
--- a/sd/source/ui/animations/CustomAnimation.hrc
+++ b/sd/source/ui/animations/CustomAnimation.hrc
@@ -56,25 +56,15 @@
#define RID_CUSTOMANIMATION_FONTSTYLE_POPUP RID_CUSTOMANIMATION_START+12
#define IMG_CUSTOMANIMATION_ON_CLICK RID_CUSTOMANIMATION_START+0
-#define IMG_CUSTOMANIMATION_ON_CLICK_H RID_CUSTOMANIMATION_START+1
-#define IMG_CUSTOMANIMATION_AFTER_PREVIOUS RID_CUSTOMANIMATION_START+2
-#define IMG_CUSTOMANIMATION_AFTER_PREVIOUS_H RID_CUSTOMANIMATION_START+3
-#define IMG_CUSTOMANIMATION_ENTRANCE_EFFECT RID_CUSTOMANIMATION_START+4
-#define IMG_CUSTOMANIMATION_ENTRANCE_EFFECT_H RID_CUSTOMANIMATION_START+5
-#define IMG_CUSTOMANIMATION_EMPHASIS_EFFECT RID_CUSTOMANIMATION_START+6
-#define IMG_CUSTOMANIMATION_EMPHASIS_EFFECT_H RID_CUSTOMANIMATION_START+7
-#define IMG_CUSTOMANIMATION_EXIT_EFFECT RID_CUSTOMANIMATION_START+8
-#define IMG_CUSTOMANIMATION_EXIT_EFFECT_H RID_CUSTOMANIMATION_START+9
-#define IMG_CUSTOMANIMATION_MOTION_PATH RID_CUSTOMANIMATION_START+10
-#define IMG_CUSTOMANIMATION_MOTION_PATH_H RID_CUSTOMANIMATION_START+11
-#define IMG_CUSTOMANIMATION_OLE RID_CUSTOMANIMATION_START+12
-#define IMG_CUSTOMANIMATION_OLE_H RID_CUSTOMANIMATION_START+13
-#define IMG_CUSTOMANIMATION_MEDIA_PLAY RID_CUSTOMANIMATION_START+14
-#define IMG_CUSTOMANIMATION_MEDIA_PLAY_H RID_CUSTOMANIMATION_START+15
-#define IMG_CUSTOMANIMATION_MEDIA_PAUSE RID_CUSTOMANIMATION_START+16
-#define IMG_CUSTOMANIMATION_MEDIA_PAUSE_H RID_CUSTOMANIMATION_START+17
-#define IMG_CUSTOMANIMATION_MEDIA_STOP RID_CUSTOMANIMATION_START+18
-#define IMG_CUSTOMANIMATION_MEDIA_STOP_H RID_CUSTOMANIMATION_START+19
+#define IMG_CUSTOMANIMATION_AFTER_PREVIOUS RID_CUSTOMANIMATION_START+1
+#define IMG_CUSTOMANIMATION_ENTRANCE_EFFECT RID_CUSTOMANIMATION_START+2
+#define IMG_CUSTOMANIMATION_EMPHASIS_EFFECT RID_CUSTOMANIMATION_START+3
+#define IMG_CUSTOMANIMATION_EXIT_EFFECT RID_CUSTOMANIMATION_START+4
+#define IMG_CUSTOMANIMATION_MOTION_PATH RID_CUSTOMANIMATION_START+5
+#define IMG_CUSTOMANIMATION_OLE RID_CUSTOMANIMATION_START+6
+#define IMG_CUSTOMANIMATION_MEDIA_PLAY RID_CUSTOMANIMATION_START+7
+#define IMG_CUSTOMANIMATION_MEDIA_PAUSE RID_CUSTOMANIMATION_START+8
+#define IMG_CUSTOMANIMATION_MEDIA_STOP RID_CUSTOMANIMATION_START+9
#define STR_CUSTOMANIMATION_DURATION_VERY_SLOW RID_CUSTOMANIMATION_START+0
#define STR_CUSTOMANIMATION_DURATION_SLOW RID_CUSTOMANIMATION_START+1
diff --git a/sd/source/ui/animations/CustomAnimation.src b/sd/source/ui/animations/CustomAnimation.src
index adc0c2be9..dc4a46899 100644
--- a/sd/source/ui/animations/CustomAnimation.src
+++ b/sd/source/ui/animations/CustomAnimation.src
@@ -397,99 +397,47 @@ Image IMG_CUSTOMANIMATION_ON_CLICK
ImageBitmap = Bitmap { File = "click_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_ON_CLICK_H
-{
- ImageBitmap = Bitmap { File = "click_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_AFTER_PREVIOUS
{
ImageBitmap = Bitmap { File = "time_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_AFTER_PREVIOUS_H
-{
- ImageBitmap = Bitmap { File = "time_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_ENTRANCE_EFFECT
{
ImageBitmap = Bitmap { File = "effect_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_ENTRANCE_EFFECT_H
-{
- ImageBitmap = Bitmap { File = "effect_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_EMPHASIS_EFFECT
{
ImageBitmap = Bitmap { File = "effectshape_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_EMPHASIS_EFFECT_H
-{
- ImageBitmap = Bitmap { File = "effectshape_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_EXIT_EFFECT
{
ImageBitmap = Bitmap { File = "effectfade_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_EXIT_EFFECT_H
-{
- ImageBitmap = Bitmap { File = "effectfade_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_MOTION_PATH
{
ImageBitmap = Bitmap { File = "effectpath_16.png" ; };
};
-Image IMG_CUSTOMANIMATION_MOTION_PATH_H
-{
- ImageBitmap = Bitmap { File = "effectpath_16_h.png" ; };
-};
-
Image IMG_CUSTOMANIMATION_OLE
{
ImageBitmap = Bitmap { File = "effectole_16.png"; } ;
};
-Image IMG_CUSTOMANIMATION_OLE_H
-{
- ImageBitmap = Bitmap { File = "effectole_16_h.png"; } ;
-};
-
Image IMG_CUSTOMANIMATION_MEDIA_PLAY
{
ImageBitmap = Bitmap { File = "playblue_16.png"; } ;
};
-Image IMG_CUSTOMANIMATION_MEDIA_PLAY_H
-{
- ImageBitmap = Bitmap { File = "playblue_16_h.png"; } ;
-};
-
Image IMG_CUSTOMANIMATION_MEDIA_PAUSE
{
ImageBitmap = Bitmap { File = "breakplayingblue_16.png"; } ;
};
-Image IMG_CUSTOMANIMATION_MEDIA_PAUSE_H
-{
- ImageBitmap = Bitmap { File = "breakplayingblue_16_h.png"; } ;
-};
-
Image IMG_CUSTOMANIMATION_MEDIA_STOP
{
ImageBitmap = Bitmap { File = "stopplayingblue_16.png"; } ;
};
-
-Image IMG_CUSTOMANIMATION_MEDIA_STOP_H
-{
- ImageBitmap = Bitmap { File = "stopplayingblue_16_h.png"; } ;
-};
-
-
diff --git a/sd/source/ui/animations/CustomAnimationCreateDialog.cxx b/sd/source/ui/animations/CustomAnimationCreateDialog.cxx
index 9afec7228..896ea1375 100755..100644
--- a/sd/source/ui/animations/CustomAnimationCreateDialog.cxx
+++ b/sd/source/ui/animations/CustomAnimationCreateDialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,20 +29,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifndef _COM_SUN_STAR_UTIL_XCOLLATOR_HPP_
#include <com/sun/star/i18n/XCollator.hpp>
-#endif
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#include <vcl/svapp.hxx>
#include <vcl/tabctrl.hxx>
#include <vcl/tabpage.hxx>
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
#include <vcl/fixed.hxx>
#include <vcl/lstbox.hxx>
#include <vcl/combobox.hxx>
@@ -53,12 +48,8 @@
#include <unotools/viewoptions.hxx>
#include <com/sun/star/presentation/EffectNodeType.hpp>
#include "CustomAnimationCreateDialog.hxx"
-#ifndef _SD_CUSTOMANIMATIONCREATEDIALOG_HRC
#include "CustomAnimationCreateDialog.hrc"
-#endif
-#ifndef _SD_CUSTOMANIMATION_HRC
#include "CustomAnimation.hrc"
-#endif
#include "CustomAnimationPane.hxx"
#include "optsitem.hxx"
#include "sddll.hxx"
@@ -239,7 +230,7 @@ ImplStlEffectCategorySortHelper::ImplStlEffectCategorySortHelper()
uno::Reference<lang::XMultiServiceFactory> xFac( ::comphelper::getProcessServiceFactory() );
if( xFac.is() )
{
- mxCollator.set( xFac->createInstance( ::rtl::OUString::createFromAscii( "com.sun.star.i18n.Collator" ) ), uno::UNO_QUERY );
+ mxCollator.set( xFac->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.i18n.Collator" )) ), uno::UNO_QUERY );
if( mxCollator.is() )
{
@@ -525,7 +516,9 @@ CustomAnimationCreateDialog::CustomAnimationCreateDialog( Window* pParent, Custo
{
mpTabControl = new TabControl( this, SdResId( 1 ) );
mpOKButton = new OKButton(this, SdResId( 1 ) ) ;
+ mpOKButton->SetStyle(WB_DEFBUTTON);
mpCancelButton = new CancelButton(this, SdResId( 1 ) );
+ mpCancelButton->SetStyle(WB_DEFBUTTON);
mpHelpButton = new HelpButton(this, SdResId( 1 ) );
FreeResource();
@@ -599,7 +592,6 @@ CustomAnimationCreateTabPage* CustomAnimationCreateDialog::getCurrentPage() cons
case RID_TP_CUSTOMANIMATION_EMPHASIS: return mpTabPages[EMPHASIS];
case RID_TP_CUSTOMANIMATION_EXIT: return mpTabPages[EXIT];
case RID_TP_CUSTOMANIMATION_MISCEFFECTS:return mpTabPages[MISCEFFECTS];
- //case RID_TP_CUSTOMANIMATION_MOTIONPATH:
default:
return mpTabPages[MOTIONPATH];
}
@@ -711,3 +703,5 @@ void CustomAnimationCreateDialog::storePosition()
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationCreateDialog.hxx b/sd/source/ui/animations/CustomAnimationCreateDialog.hxx
index b129ec0ea..62a2625dc 100644
--- a/sd/source/ui/animations/CustomAnimationCreateDialog.hxx
+++ b/sd/source/ui/animations/CustomAnimationCreateDialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ private:
}
#endif // _SD_CUSTOMANIMATIONCREATEDIALOG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationDialog.cxx b/sd/source/ui/animations/CustomAnimationDialog.cxx
index fb3a4f4f1..865cf4789 100755..100644
--- a/sd/source/ui/animations/CustomAnimationDialog.cxx
+++ b/sd/source/ui/animations/CustomAnimationDialog.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -42,13 +43,9 @@
#include <com/sun/star/media/XManager.hpp>
#include <com/sun/star/media/XPlayer.hpp>
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#include <unotools/pathoptions.hxx>
#include <vcl/tabctrl.hxx>
#include <vcl/tabpage.hxx>
@@ -65,9 +62,7 @@
#include <svtools/ctrltool.hxx>
#include <sfx2/objsh.hxx>
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/dialmgr.hxx>
#include <editeng/flstitem.hxx>
#include <svx/drawitem.hxx>
@@ -75,19 +70,13 @@
#include <svx/xtable.hxx>
#include <svx/gallery.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include "sdresid.hxx"
#include "glob.hrc"
#include "CustomAnimationDialog.hxx"
-#ifndef _SD_CUSTOMANIMATIONDIALOG_HRC
#include "CustomAnimationDialog.hrc"
-#endif
-#ifndef _SD_CUSTOMANIMATION_HRC
#include "CustomAnimation.hrc"
-#endif
#include "STLPropertySet.hxx"
#include <avmedia/mediawindow.hxx>
@@ -1156,7 +1145,7 @@ private:
void onSoundPreview();
private:
- List maSoundList;
+ ::std::vector< String > maSoundList;
sal_Bool mbHasText;
const STLPropertySet* mpSet;
@@ -1216,18 +1205,6 @@ CustomAnimationEffectTabPage::CustomAnimationEffectTabPage( Window* pParent, con
mpCBSmoothStart = new CheckBox( this, SdResId( CB_SMOOTH_START ) );
mpCBSmoothEnd = new CheckBox( this, SdResId( CB_SMOOTH_END ) );
mpCBAutoRestart = new CheckBox( this, SdResId( CB_AUTORESTART ) );
-/*
- mpFLPlay = new FixedLine( this, SdResId( FL_PLAY ) );
- mpRBFromStart = new RadioButton( this, SdResId( RB_FROM_START ) );
- mpRBFromLast = new RadioButton( this, SdResId( RB_FROM_LAST ) );
- mpRBFromTime = new RadioButton( this, SdResId( RB_FROM_TIME ) );
- mpMFStartTime = new MetricField( this, SdResId( MF_START_TIME ) );
- mpFLStop = new FixedLine( this, SdResId( FL_STOP ) );
- mpRBStopOnClick = new RadioButton( this, SdResId( RB_STOP_ON_CLICK ) );
- mpRBStopOnNextSlide = new RadioButton( this, SdResId( RB_STOP_ON_NEXT_SLIDE ) );
- mpRBStopAfterSlides = new RadioButton( this, SdResId( RB_STOP_AFTER_N_SLIDES ) );
- mpMFStopAfterSlides = new MetricField( this, SdResId( MF_STOP_AFTER_SLIDES ) );
-*/
mpFLEnhancements = new FixedLine( this, SdResId( FL_ENHANCEMENTS ) );
mpFTSound = new FixedText( this, SdResId( FT_SOUND ) );
mpLBSound = new ListBox( this, SdResId( LB_SOUND ) );
@@ -1489,10 +1466,10 @@ CustomAnimationEffectTabPage::CustomAnimationEffectTabPage( Window* pParent, con
const String aTmp( aSoundURL );
sal_uLong i;
- for( i = 0; i < maSoundList.Count(); i++ )
+ for( i = 0; i < maSoundList.size(); i++ )
{
- String* pString = (String*)maSoundList.GetObject( i );
- if( *pString == aTmp )
+ String aString = maSoundList[ i ];
+ if( aString == aTmp )
{
nPos = (sal_uInt16)i+2;
break;
@@ -1501,8 +1478,8 @@ CustomAnimationEffectTabPage::CustomAnimationEffectTabPage( Window* pParent, con
if( nPos == 0 )
{
- nPos = (sal_uInt16)maSoundList.Count()+2;
- maSoundList.Insert( new String( aTmp ), LIST_APPEND );
+ nPos = (sal_uInt16)maSoundList.size()+2;
+ maSoundList.push_back( String( aTmp ) );
INetURLObject aURL( aTmp );
nPos = mpLBSound->InsertEntry( aURL.GetBase(), nPos );
}
@@ -1740,7 +1717,7 @@ void CustomAnimationEffectTabPage::update( STLPropertySet* pSet )
}
else
{
- OUString aSoundURL( *(String*)maSoundList.GetObject( nPos-2 ) );
+ OUString aSoundURL( maSoundList[ nPos-2 ] );
aNewSoundURL = makeAny( aSoundURL );
}
@@ -1759,10 +1736,10 @@ void CustomAnimationEffectTabPage::fillSoundListBox()
mpLBSound->InsertEntry( String( SdResId( STR_CUSTOMANIMATION_NO_SOUND ) ) );
mpLBSound->InsertEntry( String( SdResId( STR_CUSTOMANIMATION_STOP_PREVIOUS_SOUND ) ) );
- for( sal_uLong i = 0; i < maSoundList.Count(); i++ )
+ for( size_t i = 0; i < maSoundList.size(); i++ )
{
- String* pString = (String*)maSoundList.GetObject( i );
- INetURLObject aURL( *pString );
+ String aString = maSoundList[ i ];
+ INetURLObject aURL( aString );
mpLBSound->InsertEntry( aURL.GetBase() );
}
mpLBSound->InsertEntry( String( SdResId( STR_CUSTOMANIMATION_BROWSE_SOUND ) ) );
@@ -1770,12 +1747,7 @@ void CustomAnimationEffectTabPage::fillSoundListBox()
void CustomAnimationEffectTabPage::clearSoundListBox()
{
- const sal_uInt32 nCount = maSoundList.Count();
- sal_uInt32 i;
- for( i = 0; i < nCount; i++ )
- delete (String*)maSoundList.GetObject( i );
- maSoundList.Clear();
-
+ maSoundList.clear();
mpLBSound->Clear();
}
@@ -1784,11 +1756,11 @@ sal_Int32 CustomAnimationEffectTabPage::getSoundObject( const String& rStr )
String aStrIn( rStr );
aStrIn.ToLowerAscii();
- sal_uInt32 i;
- const sal_uInt32 nCount = maSoundList.Count();
+ size_t i;
+ const size_t nCount = maSoundList.size();
for( i = 0; i < nCount; i++ )
{
- String aTmpStr( *(String*)maSoundList.GetObject( i ) );
+ String aTmpStr( maSoundList[ i ] );
aTmpStr.ToLowerAscii();
if( aTmpStr == aStrIn )
@@ -1859,14 +1831,14 @@ void CustomAnimationEffectTabPage::onSoundPreview()
if( nPos >= 2 ) try
{
- const OUString aSoundURL( *(String*)maSoundList.GetObject( nPos-2 ) );
- mxPlayer.set( avmedia::MediaWindow::createPlayer( aSoundURL ), uno::UNO_QUERY_THROW );
+ const OUString aSoundURL( maSoundList[ nPos-2 ] );
+ mxPlayer.set( avmedia::MediaWindow::createPlayer( aSoundURL ), uno::UNO_QUERY_THROW );
mxPlayer->start();
}
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR("CustomAnimationEffectTabPage::onSoundPreview(), exception caught!" );
+ OSL_FAIL("CustomAnimationEffectTabPage::onSoundPreview(), exception caught!" );
}
}
@@ -2067,7 +2039,7 @@ CustomAnimationDurationTabPage::CustomAnimationDurationTabPage(Window* pParent,
String aDescription( getShapeDescription( xShape, true ) );
sal_uInt16 nPos = mpLBTrigger->InsertEntry( aDescription );
- mpLBTrigger->SetEntryData( nPos, (void*)nShape );
+ mpLBTrigger->SetEntryData( nPos, (void*)(sal_IntPtr)nShape );
if( xShape == xTrigger )
mpLBTrigger->SelectEntryPos( nPos );
}
@@ -2636,3 +2608,5 @@ PropertySubControl* PropertySubControl::create( sal_Int32 nType, Window* pParent
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationDialog.hxx b/sd/source/ui/animations/CustomAnimationDialog.hxx
index 9f18bcecf..a5f8cc1ca 100755..100644
--- a/sd/source/ui/animations/CustomAnimationDialog.hxx
+++ b/sd/source/ui/animations/CustomAnimationDialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -184,3 +185,5 @@ private:
}
#endif // _SD_CUSTOMANIMATIONDIALOG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationList.cxx b/sd/source/ui/animations/CustomAnimationList.cxx
index d1924a647..a1e64d212 100755..100644
--- a/sd/source/ui/animations/CustomAnimationList.cxx
+++ b/sd/source/ui/animations/CustomAnimationList.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -40,14 +41,9 @@
#include <com/sun/star/drawing/XDrawPage.hpp>
#include <svx/ShapeTypeHandler.hxx>
#include "CustomAnimationList.hxx"
-#ifndef _SD_CUSTOMANIMATIONPANE_HRC
#include "CustomAnimationPane.hrc"
-#endif
-#ifndef _SD_CUSTOMANIMATION_HRC
#include "CustomAnimation.hrc"
-#endif
#include "CustomAnimationPreset.hxx"
-#include <svtools/treelist.hxx>
#include <vcl/svapp.hxx>
#include "sdresid.hxx"
@@ -193,7 +189,7 @@ static OUString getDescription( const Any& rTarget, bool bWithText = true )
{
Reference< XTextRange > xParagraph;
xEnumeration->nextElement() >>= xParagraph;
-
+
if( xParagraph.is() )
aDescription = xParagraph->getString();
}
@@ -260,7 +256,6 @@ void CustomAnimationListEntryItem::InitViewData( SvLBox* pView, SvLBoxEntry* pEn
void CustomAnimationListEntryItem::Paint( const Point& rPos, SvLBox& rDev, sal_uInt16, SvLBoxEntry* pEntry )
{
- const bool bHighContrast = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
SvViewDataItem* pViewData = mpParent->GetViewDataItem( pEntry, this );
@@ -270,11 +265,11 @@ void CustomAnimationListEntryItem::Paint( const Point& rPos, SvLBox& rDev, sal_u
sal_Int16 nNodeType = mpEffect->getNodeType();
if( nNodeType == EffectNodeType::ON_CLICK )
{
- rDev.DrawImage( aPos, mpParent->getImage( IMG_CUSTOMANIMATION_ON_CLICK, bHighContrast ) );
+ rDev.DrawImage( aPos, mpParent->getImage( IMG_CUSTOMANIMATION_ON_CLICK ) );
}
else if( nNodeType == EffectNodeType::AFTER_PREVIOUS )
{
- rDev.DrawImage( aPos, mpParent->getImage( IMG_CUSTOMANIMATION_AFTER_PREVIOUS, bHighContrast ) );
+ rDev.DrawImage( aPos, mpParent->getImage( IMG_CUSTOMANIMATION_AFTER_PREVIOUS ) );
}
aPos.X() += 19;
@@ -292,7 +287,7 @@ void CustomAnimationListEntryItem::Paint( const Point& rPos, SvLBox& rDev, sal_u
{
case EffectCommands::TOGGLEPAUSE: nImage = IMG_CUSTOMANIMATION_MEDIA_PAUSE; break;
case EffectCommands::STOP: nImage = IMG_CUSTOMANIMATION_MEDIA_STOP; break;
- case EffectCommands::PLAY:
+ case EffectCommands::PLAY:
default: nImage = IMG_CUSTOMANIMATION_MEDIA_PLAY; break;
}
break;
@@ -301,7 +296,7 @@ void CustomAnimationListEntryItem::Paint( const Point& rPos, SvLBox& rDev, sal_u
if( nImage != 0xffff )
{
- const Image& rImage = mpParent->getImage( nImage, bHighContrast );
+ const Image& rImage = mpParent->getImage( nImage );
Point aImagePos( aPos );
aImagePos.Y() += ( aSize.Height() - rImage.GetSizePixel().Height() ) >> 1;
rDev.DrawImage( aImagePos, rImage );
@@ -409,12 +404,6 @@ void CustomAnimationTriggerEntryItem::InitViewData( SvLBox* pView, SvLBoxEntry*
if( aSize.Height() < 19 )
aSize.Height() = 19;
pViewData->aSize = aSize;
-
-/*
- SvViewData* pViewData = pView->GetViewData( pEntry );
- if( pViewData )
- pViewData->SetSelectable(false);
-*/
}
// --------------------------------------------------------------------
@@ -487,12 +476,9 @@ CustomAnimationList::CustomAnimationList( ::Window* pParent, const ResId& rResId
// --------------------------------------------------------------------
-const Image& CustomAnimationList::getImage( sal_uInt16 nId, bool bHighContrast )
+const Image& CustomAnimationList::getImage( sal_uInt16 nId )
{
- DBG_ASSERT( (nId >= IMG_CUSTOMANIMATION_ON_CLICK) && (nId <= IMG_CUSTOMANIMATION_MEDIA_STOP), "sd::CustomAnimationList::getImage(), illegal index!" );
-
- if( bHighContrast )
- nId += 1;
+ DBG_ASSERT( (nId >= IMG_CUSTOMANIMATION_ON_CLICK) && (nId <= IMG_CUSTOMANIMATION_MEDIA_STOP), "sd::CustomAnimationList::getImage(), illegal index!" );
Image& rImage = maImages[nId - IMG_CUSTOMANIMATION_ON_CLICK];
@@ -522,14 +508,14 @@ void CustomAnimationList::KeyInput( const KeyEvent& rKEvt )
{
case KEY_DELETE: mpController->onContextMenu( CM_REMOVE ); return;
case KEY_INSERT: mpController->onContextMenu( CM_CREATE ); return;
- case KEY_SPACE:
+ case KEY_SPACE:
{
const Point aPos;
- const CommandEvent aCEvt( aPos, COMMAND_CONTEXTMENU );
+ const CommandEvent aCEvt( aPos, COMMAND_CONTEXTMENU );
Command( aCEvt );
return;
}
-
+
}
::SvTreeListBox::KeyInput( rKEvt );
@@ -545,7 +531,7 @@ void CustomAnimationList::select( CustomAnimationEffectPtr pEffect, bool bSelect
while( pEntry )
{
if( pEntry->getEffect() == pEffect )
- {
+ {
Select( pEntry, bSelect );
break;
}
@@ -696,31 +682,6 @@ void CustomAnimationList::update()
// --------------------------------------------------------------------
-/*
-void CustomAnimationList::update( CustomAnimationEffectPtr pEffect )
-{
- SvLBoxEntry* pEntry = First();
- while( pEntry )
- {
- if( static_cast< CustomAnimationEffectPtr * >( pEntry->GetUserData() )->get() == pEffect.get() )
- {
- CustomAnimationPresetsPtr pPresets = mpController->getPresets();
- const CustomAnimationPresetPtr pPreset = pPresets->getEffectDescriptor( pEffect->getPresetId() );
- if( pPreset.get() )
- pEffect->setName( pPresets->getUINameForPresetId( pPreset->getPresetId() ) );
- else
- pEffect->setName( pEffect->getPresetId() );
- break;
- }
- pEntry = Next( pEntry );
- }
-
- Invalidate();
-}
-*/
-
-// --------------------------------------------------------------------
-
void CustomAnimationList::append( CustomAnimationEffectPtr pEffect )
{
// create a ui description
@@ -766,34 +727,9 @@ void CustomAnimationList::append( CustomAnimationEffectPtr pEffect )
catch( Exception& e )
{
(void)e;
- DBG_ERROR("sd::CustomAnimationList::append(), exception catched!" );
- }
-}
-
-// --------------------------------------------------------------------
-
-/*
-void CustomAnimationList::remove( CustomAnimationEffectPtr pEffect )
-{
- SvLBoxEntry* pEntry = First();
- while( pEntry )
- {
- if( static_cast< CustomAnimationEffectPtr * >( pEntry->GetUserData() )->get() == pEffect.get() )
- {
- GetModel()->Remove( pEntry );
- if( pEntry == mpLastParentEntry )
- {
- mpLastParentEntry = 0;
- mxLastTargetShape = 0;
- }
- break;
- }
- pEntry = Next( pEntry );
+ OSL_FAIL("sd::CustomAnimationList::append(), exception catched!" );
}
-
- Invalidate();
}
-*/
// --------------------------------------------------------------------
@@ -847,7 +783,7 @@ void CustomAnimationList::onSelectionChanged( Any aSelection )
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationList::onSelectionChanged(), Exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationList::onSelectionChanged(), Exception catched!" );
}
}
@@ -1016,3 +952,5 @@ void CustomAnimationList::Paint( const Rectangle& rRect )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationList.hxx b/sd/source/ui/animations/CustomAnimationList.hxx
index 2ccb47c90..24ef25eae 100755..100644
--- a/sd/source/ui/animations/CustomAnimationList.hxx
+++ b/sd/source/ui/animations/CustomAnimationList.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#include <svtools/svtreebx.hxx>
#include <CustomAnimationEffect.hxx>
#include "CustomAnimationPreset.hxx"
-#ifndef _SD_CUSTOMANIMATION_HRC
#include "CustomAnimation.hrc"
-#endif
namespace sd {
@@ -68,14 +67,8 @@ public:
/** populates the list with all effects from the given MainSequence */
void update( MainSequencePtr pMainSequence );
- /** updates the given effect in the list */
-// void update( CustomAnimationEffectPtr pEffect );
-
void update();
- /** removes the given effect to the list*/
-// void remove( CustomAnimationEffectPtr pEffect );
-
EffectSequence getSelection() const;
// events
@@ -92,12 +85,11 @@ public:
virtual void KeyInput( const KeyEvent& rKEvt );
-// virtual SvLBoxEntry* CreateEntry() const;
virtual void SetTabs();
virtual void notify_change();
- const Image& getImage( sal_uInt16 nId, bool bHighContrast );
+ const Image& getImage( sal_uInt16 nId );
bool isExpanded( const CustomAnimationEffectPtr& pEffect ) const;
@@ -116,7 +108,7 @@ private:
Image maImgEmpty;
- Image maImages[ IMG_CUSTOMANIMATION_MEDIA_STOP_H - IMG_CUSTOMANIMATION_ON_CLICK + 1];
+ Image maImages[ IMG_CUSTOMANIMATION_MEDIA_STOP - IMG_CUSTOMANIMATION_ON_CLICK + 1];
::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > mxLastTargetShape;
sal_Int32 mnLastGroupId;
@@ -128,3 +120,4 @@ private:
#endif // _SD_CUSTOMANIMATIONLIST_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationPane.cxx b/sd/source/ui/animations/CustomAnimationPane.cxx
index af7d7cb52..40feb6dd9 100755..100644
--- a/sd/source/ui/animations/CustomAnimationPane.cxx
+++ b/sd/source/ui/animations/CustomAnimationPane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -239,7 +240,7 @@ CustomAnimationPane::CustomAnimationPane( ::Window* pParent, ViewShellBase& rBas
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPane::CustomAnimationPane(), Exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationPane::CustomAnimationPane(), Exception cought!" );
}
// get current page and update custom animation list
@@ -261,7 +262,7 @@ CustomAnimationPane::~CustomAnimationPane()
MotionPathTagVector aTags;
aTags.swap( maMotionPathTags );
MotionPathTagVector::iterator aIter;
- for( aIter = aTags.begin(); aIter != aTags.end(); aIter++ )
+ for( aIter = aTags.begin(); aIter != aTags.end(); ++aIter )
(*aIter)->Dispose();
delete mpFLModify;
@@ -753,8 +754,6 @@ void CustomAnimationPane::updateControls()
mpLBStart->Enable(nSelectionCount > 0);
mpPBPropertyMore->Enable(nSelectionCount > 0);
-// mpPBPlay->Enable(nSelectionCount > 0);
-
mpFTProperty->SetText( maStrProperty );
mnPropertyType = nPropertyTypeNone;
@@ -823,9 +822,6 @@ void CustomAnimationPane::updateControls()
mpPBPropertyMore->Enable( sal_False );
}
- //
- // ---
- //
sal_uInt16 nPos = 0xffff;
sal_Int16 nNodeType = pEffect->getNodeType();
@@ -960,7 +956,7 @@ static bool updateMotionPathImpl( CustomAnimationPane& rPane, ::sd::View& rView,
rtl::Reference< MotionPathTag > xMotionPathTag;
// first try to find if there is already a tag for this
MotionPathTagVector::iterator aMIter( rOldTags.begin() );
- for( ; aMIter != rOldTags.end(); aMIter++ )
+ for( ; aMIter != rOldTags.end(); ++aMIter )
{
rtl::Reference< MotionPathTag > xTag( (*aMIter) );
if( xTag->getEffect() == pEffect )
@@ -1051,7 +1047,7 @@ void CustomAnimationPane::onSelectionChanged()
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationPane::onSelectionChanged(), Exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPane::onSelectionChanged(), Exception catched!" );
}
}
}
@@ -1371,8 +1367,6 @@ STLPropertySet* CustomAnimationPane::createSelectionSet()
addValue( pSet, nHandleTrigger, makeAny( pIS->getTriggerShape() ) );
}
- //
-
CustomAnimationPresetPtr pDescriptor = rPresets.getEffectDescriptor( pEffect->getPresetId() );
if( pDescriptor.get() )
{
@@ -1781,7 +1775,7 @@ void CustomAnimationPane::onChangeCurrentPage()
}
catch( Exception& )
{
- DBG_ERROR( "sd::CustomAnimationPane::onChangeCurrentPage(), exception catched!" );
+ OSL_FAIL( "sd::CustomAnimationPane::onChangeCurrentPage(), exception catched!" );
}
}
@@ -1841,7 +1835,7 @@ bool getTextSelection( const Any& rSelection, Reference< XShape >& xShape, std::
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPane::getTextSelection(), exception cought!" );
+ OSL_FAIL( "sd::CustomAnimationPane::getTextSelection(), exception cought!" );
}
return false;
@@ -1900,7 +1894,7 @@ void CustomAnimationPane::onChange( bool bCreate )
aParaTarget.Shape = xShape;
std::list< sal_Int16 >::iterator aIter( aParaList.begin() );
- for( ; aIter != aParaList.end(); aIter++ )
+ for( ; aIter != aParaList.end(); ++aIter )
{
aParaTarget.Paragraph = (*aIter);
aTargets.push_back( makeAny( aParaTarget ) );
@@ -1909,7 +1903,7 @@ void CustomAnimationPane::onChange( bool bCreate )
}
else
{
- DBG_ERROR("sd::CustomAnimationPane::onChange(), unknown view selection!" );
+ OSL_FAIL("sd::CustomAnimationPane::onChange(), unknown view selection!" );
return;
}
}
@@ -1949,7 +1943,7 @@ void CustomAnimationPane::onChange( bool bCreate )
std::vector< Any >::iterator aIter( aTargets.begin() );
const std::vector< Any >::iterator aEnd( aTargets.end() );
bool bFirst = true;
- for( ; aIter != aEnd; aIter++ )
+ for( ; aIter != aEnd; ++aIter )
{
CustomAnimationEffectPtr pCreated = mpMainSequence->append( pDescriptor, (*aIter), fDuration );
@@ -2284,9 +2278,9 @@ void CustomAnimationPane::moveSelection( bool bUp )
if( aInsertPos != rEffectSequence.begin() )
{
- aInsertPos--;
+ --aInsertPos;
while( (aInsertPos != rEffectSequence.begin()) && !mpCustomAnimationList->isExpanded(*aInsertPos))
- aInsertPos--;
+ --aInsertPos;
rEffectSequence.insert( aInsertPos, pEffect );
}
@@ -2314,9 +2308,9 @@ void CustomAnimationPane::moveSelection( bool bUp )
if( aInsertPos != rEffectSequence.end() )
{
- aInsertPos++;
+ ++aInsertPos;
while( (aInsertPos != rEffectSequence.end()) && !mpCustomAnimationList->isExpanded(*aInsertPos))
- aInsertPos++;
+ ++aInsertPos;
rEffectSequence.insert( aInsertPos, pEffect );
}
@@ -2346,7 +2340,7 @@ void CustomAnimationPane::onPreview( bool bForcePreview )
{
rtl::Reference< MotionPathTag > xMotionPathTag;
MotionPathTagVector::iterator aIter;
- for( aIter = maMotionPathTags.begin(); aIter != maMotionPathTags.end(); aIter++ )
+ for( aIter = maMotionPathTags.begin(); aIter != maMotionPathTags.end(); ++aIter )
{
if( (*aIter)->isSelected() )
{
@@ -2497,3 +2491,5 @@ void CustomAnimationPane::updatePathFromMotionPathTag( const rtl::Reference< Mot
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/CustomAnimationPane.hxx b/sd/source/ui/animations/CustomAnimationPane.hxx
index 85698326d..58b277e0b 100755..100644
--- a/sd/source/ui/animations/CustomAnimationPane.hxx
+++ b/sd/source/ui/animations/CustomAnimationPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -188,3 +189,5 @@ private:
}
#endif // _SD_CUSTOMANIMATIONPANE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/DialogListBox.cxx b/sd/source/ui/animations/DialogListBox.cxx
index 551217a03..a58f677b5 100755..100644
--- a/sd/source/ui/animations/DialogListBox.cxx
+++ b/sd/source/ui/animations/DialogListBox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -338,3 +339,5 @@ long DialogListBox::Notify( NotifyEvent& rNEvt )
}
} // namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/STLPropertySet.cxx b/sd/source/ui/animations/STLPropertySet.cxx
index 7c01c0815..5427fc5ae 100644
--- a/sd/source/ui/animations/STLPropertySet.cxx
+++ b/sd/source/ui/animations/STLPropertySet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,7 +63,7 @@ void STLPropertySet::setPropertyValue( sal_Int32 nHandle, const Any& rValue, sal
}
else
{
- DBG_ERROR( "sd::STLPropertySet::setPropertyValue(), unknown property!" );
+ OSL_FAIL( "sd::STLPropertySet::setPropertyValue(), unknown property!" );
}
}
@@ -75,7 +76,7 @@ Any STLPropertySet::getPropertyValue( sal_Int32 nHandle ) const
}
else
{
- DBG_ERROR( "sd::STLPropertySet::setPropertyValue(), unknown property!" );
+ OSL_FAIL( "sd::STLPropertySet::setPropertyValue(), unknown property!" );
Any aAny;
return aAny;
@@ -91,7 +92,7 @@ sal_Int32 STLPropertySet::getPropertyState( sal_Int32 nHandle ) const
}
else
{
- DBG_ERROR( "sd::STLPropertySet::setPropertyState(), unknown property!" );
+ OSL_FAIL( "sd::STLPropertySet::setPropertyState(), unknown property!" );
return STLPropertyState_AMBIGUOUS;
}
}
@@ -105,7 +106,7 @@ void STLPropertySet::setPropertyState( sal_Int32 nHandle, sal_Int32 nState )
}
else
{
- DBG_ERROR( "sd::STLPropertySet::setPropertyState(), unknown property!" );
+ OSL_FAIL( "sd::STLPropertySet::setPropertyState(), unknown property!" );
}
}
@@ -122,3 +123,5 @@ bool STLPropertySet::findProperty( sal_Int32 nHandle, PropertyMapConstIter& rIte
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/STLPropertySet.hxx b/sd/source/ui/animations/STLPropertySet.hxx
index fa4ed1d6b..0214611e5 100644
--- a/sd/source/ui/animations/STLPropertySet.hxx
+++ b/sd/source/ui/animations/STLPropertySet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <com/sun/star/beans/PropertyValue.hpp>
-#ifndef _UTL_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
#include <list>
#include <map>
@@ -84,3 +83,5 @@ private:
}
#endif // _SD_STLPROPERTYSET_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/SlideTransitionPane.cxx b/sd/source/ui/animations/SlideTransitionPane.cxx
index 1e430aafe..957474788 100755..100644
--- a/sd/source/ui/animations/SlideTransitionPane.cxx
+++ b/sd/source/ui/animations/SlideTransitionPane.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -44,9 +45,7 @@
#include "DrawController.hxx"
#include <com/sun/star/beans/XPropertySet.hpp>
-#ifndef _SVT_CONTROLDIMS_HRC_
#include <svtools/controldims.hrc>
-#endif
#include <svx/gallery.hxx>
#include <unotools/pathoptions.hxx>
#include <vcl/msgbox.hxx>
@@ -496,7 +495,6 @@ SlideTransitionPane::SlideTransitionPane(
// update control states before adding handlers
updateLayout();
- // updateSoundList();
updateControls();
// set handlers
@@ -546,7 +544,6 @@ void SlideTransitionPane::onChangeCurrentPage()
{
::sd::slidesorter::SlideSorterViewShell * pSlideSorterViewShell
= ::sd::slidesorter::SlideSorterViewShell::GetSlideSorter(mrBase);
-// DBG_ASSERT( pSlideSorterViewShell, "No Slide-Sorter available" );
::boost::shared_ptr<sd::slidesorter::SlideSorterViewShell::PageSelection> pSelection;
if( pSlideSorterViewShell )
@@ -890,30 +887,23 @@ void SlideTransitionPane::updateControlState()
maPB_APPLY_TO_ALL.Enable( mbHasSelection );
maPB_PLAY.Enable( mbHasSelection );
-// maPB_SLIDE_SHOW.Enable( sal_True );
maCB_AUTO_PREVIEW.Enable( mbHasSelection );
}
void SlideTransitionPane::updateSoundList()
{
- List aSoundList;
+ ::std::vector< String > aSoundList;
GalleryExplorer::FillObjList( GALLERY_THEME_SOUNDS, aSoundList );
GalleryExplorer::FillObjList( GALLERY_THEME_USERSOUNDS, aSoundList );
- sal_uInt32 nCount = aSoundList.Count();
+ size_t nCount = aSoundList.size();
maSoundList.clear();
maSoundList.reserve( nCount );
- for( sal_uInt32 i=0; i<nCount; ++i )
+ for( size_t i =0 ; i < nCount; ++i )
{
- String * pEntry = reinterpret_cast< String * >( aSoundList.GetObject( i ));
- if( pEntry )
- {
- // store copy of string in member list
- maSoundList.push_back( *pEntry );
- // delete pointer in temporary List
- delete pEntry;
- }
+ // store copy of string in member list
+ maSoundList.push_back( aSoundList[ i ] );
}
lcl_FillSoundListBox( maSoundList, maLB_SOUND );
@@ -1041,9 +1031,7 @@ impl::TransitionEffect SlideTransitionPane::getTransitionEffectFromControls() co
aResult.mePresChange = PRESCHANGE_AUTO;
if( maMF_ADVANCE_AUTO_AFTER.IsEnabled())
{
-// sal_uInt16 nDigits = maMF_ADVANCE_AUTO_AFTER.GetDecimalDigits();
aResult.mnTime = static_cast<long>(maMF_ADVANCE_AUTO_AFTER.GetValue());
- // / static_cast< sal_uInt16 >( pow( 10.0, static_cast< double >( nDigits )));
aResult.mbTimeAmbiguous = false;
}
}
@@ -1319,3 +1307,5 @@ IMPL_LINK( SlideTransitionPane, LateInitCallback, Timer*, EMPTYARG )
} // namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/SlideTransitionPane.hxx b/sd/source/ui/animations/SlideTransitionPane.hxx
index f8a573162..99f6118e5 100644
--- a/sd/source/ui/animations/SlideTransitionPane.hxx
+++ b/sd/source/ui/animations/SlideTransitionPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -149,3 +150,5 @@ private:
// SD_SLIDETRANSITIONPANE_HXX
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/makefile.mk b/sd/source/ui/animations/makefile.mk
deleted file mode 100755
index db010bf4e..000000000
--- a/sd/source/ui/animations/makefile.mk
+++ /dev/null
@@ -1,65 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=animui
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES =\
- CustomAnimationPane.src\
- CustomAnimationDialog.src\
- CustomAnimationCreateDialog.src\
- SlideTransitionPane.src\
- CustomAnimation.src
-
-SLOFILES = \
- $(SLO)$/CustomAnimationCreateDialog.obj\
- $(SLO)$/CustomAnimationDialog.obj\
- $(SLO)$/CustomAnimationPane.obj \
- $(SLO)$/CustomAnimationList.obj \
- $(SLO)$/DialogListBox.obj \
- $(SLO)$/SlideTransitionPane.obj \
- $(SLO)$/STLPropertySet.obj \
- $(SLO)$/motionpathtag.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
-
diff --git a/sd/source/ui/animations/motionpathtag.cxx b/sd/source/ui/animations/motionpathtag.cxx
index 76a33d227..eb58d7c4d 100755..100644
--- a/sd/source/ui/animations/motionpathtag.cxx
+++ b/sd/source/ui/animations/motionpathtag.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -798,7 +799,7 @@ bool MotionPathTag::OnMove( const KeyEvent& rKEvt )
if(mrView.IsDragObj())
{
- FASTBOOL bWasNoSnap = mrView.GetDragStat().IsNoSnap();
+ bool bWasNoSnap = mrView.GetDragStat().IsNoSnap();
sal_Bool bWasSnapEnabled = mrView.IsSnapEnabled();
// switch snapping off
@@ -1128,9 +1129,6 @@ void MotionPathTag::DeleteMarkedPoints()
{
mrView.BrkAction();
- // Description
-// BegUndo(ImpGetResStr(STR_EditDelete),GetDescriptionOfMarkedPoints(),SDRREPFUNC_OBJ_DELETE);
-
SdrUShortCont* pPts = mpMark->GetMarkedPoints();
if( pPts )
@@ -1140,22 +1138,14 @@ void MotionPathTag::DeleteMarkedPoints()
{
if( aEditor.GetPolyPolygon().count() )
{
-// AddUndo(GetModel()->GetSdrUndoFactory().CreateUndoGeoObject(*pPath ));
mpPathObj->SetPathPoly( aEditor.GetPolyPolygon() );
}
- else
- {
-// AddUndo( GetModel()->GetSdrUndoFactory().CreateUndoDeleteObject(*pPath ) );
-// pM->GetPageView()->GetObjList()->RemoveObject(pObj->GetOrdNum());
- }
mrView.UnmarkAllPoints();
mrView.MarkListHasChanged();
mrView.updateHandles();
}
}
-
-// EndUndo();
}
}
@@ -1201,7 +1191,6 @@ void MotionPathTag::SetMarkedSegmentsKind(SdrPathSegmentKind eKind)
PolyPolygonEditor aEditor( mpPathObj->GetPathPoly(), mpPathObj->IsClosed() );
if(aEditor.SetSegmentsKind( eKind, pPts->getContainer()) )
{
-// AddUndo(GetModel()->GetSdrUndoFactory().CreateUndoGeoObject(*pPath));
mpPathObj->SetPathPoly(aEditor.GetPolyPolygon());
mrView.MarkListHasChanged();
mrView.updateHandles();
@@ -1255,7 +1244,6 @@ void MotionPathTag::SetMarkedPointsSmooth(SdrPathSmoothKind eKind)
PolyPolygonEditor aEditor( mpPathObj->GetPathPoly(), mpPathObj->IsClosed() );
if(aEditor.SetPointsSmooth( eFlags, pPts->getContainer() ) )
{
-// AddUndo(GetModel()->GetSdrUndoFactory().CreateUndoGeoObject(*pPath));
mpPathObj->SetPathPoly(aEditor.GetPolyPolygon());
mrView.MarkListHasChanged();
mrView.updateHandles();
@@ -1325,3 +1313,4 @@ void SAL_CALL MotionPathTag::release( ) throw ()
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/animations/motionpathtag.hxx b/sd/source/ui/animations/motionpathtag.hxx
index 5d98b6409..c0f1df430 100755..100644
--- a/sd/source/ui/animations/motionpathtag.hxx
+++ b/sd/source/ui/animations/motionpathtag.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -131,3 +132,4 @@ private:
#endif // _SD_MOTIONPATHTAG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx
index cb07bce04..241b4d9cc 100755..100644
--- a/sd/source/ui/annotations/annotationmanager.cxx
+++ b/sd/source/ui/annotations/annotationmanager.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -30,7 +31,6 @@
#include "sddll.hxx"
-//#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/beans/XMultiPropertyStates.hpp>
#include <com/sun/star/frame/XController.hpp>
#include <com/sun/star/frame/XModel.hpp>
@@ -42,6 +42,7 @@
#include <vcl/menu.hxx>
#include <vcl/msgbox.hxx>
+#include <sal/macros.h>
#include <svl/style.hxx>
#include <svl/itempool.hxx>
#include <unotools/useroptions.hxx>
@@ -151,12 +152,12 @@ static SfxDispatcher* getDispatcher( ViewShellBase& rBase )
}
com::sun::star::util::DateTime getCurrentDateTime()
-{
+{
TimeValue osltime;
osl_getSystemTime( &osltime );
oslDateTime osldt;
osl_getDateTimeFromTimeValue( &osltime, &osldt );
- return com::sun::star::util::DateTime( 0, osldt.Seconds, osldt.Minutes, osldt.Hours, osldt.Day, osldt.Month, osldt.Year );
+ return com::sun::star::util::DateTime( 0, osldt.Seconds, osldt.Minutes, osldt.Hours, osldt.Day, osldt.Month, osldt.Year );
}
OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotation )
@@ -164,7 +165,8 @@ OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotatio
OUString sRet;
if( xAnnotation.is() )
{
- const LocaleDataWrapper& rLocalData = SvtSysLocale().GetLocaleData();
+ const SvtSysLocale aSysLocale;
+ const LocaleDataWrapper& rLocalData = aSysLocale.GetLocaleData();
com::sun::star::util::DateTime aDateTime( xAnnotation->getDateTime() );
@@ -177,10 +179,10 @@ OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotatio
else
if (aDate.IsValid() )
sRet = sRet + rLocalData.getDate(aDate);
-
- Time aTime( aDateTime.Hours, aDateTime.Minutes, aDateTime.Seconds, aDateTime.HundredthSeconds );
+
+ Time aTime( aDateTime.Hours, aDateTime.Minutes, aDateTime.Seconds, aDateTime.HundredthSeconds );
if(aTime.GetTime() != 0)
- sRet = sRet + rtl::OUString::createFromAscii(" ") + rLocalData.getTime( aTime,false );
+ sRet = sRet + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ")) + rLocalData.getTime( aTime,false );
}
return sRet;
}
@@ -196,7 +198,7 @@ AnnotationManagerImpl::AnnotationManagerImpl( ViewShellBase& rViewShellBase )
{
SdOptions* pOptions = SD_MOD()->GetSdOptions(mpDoc->GetDocumentType());
if( pOptions )
- mbShowAnnotations = pOptions->IsShowComments() == sal_True;
+ mbShowAnnotations = pOptions->IsShowComments() == sal_True;
}
// --------------------------------------------------------------------
@@ -206,13 +208,13 @@ void AnnotationManagerImpl::init()
// get current controller and initialize listeners
try
{
- addListener();
+ addListener();
mxView = Reference< XDrawView >::query(mrBase.GetController());
}
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::AnnotationManagerImpl::AnnotationManagerImpl(), Exception caught!" );
+ OSL_FAIL( "sd::AnnotationManagerImpl::AnnotationManagerImpl(), Exception caught!" );
}
try
@@ -223,7 +225,7 @@ void AnnotationManagerImpl::init()
}
catch( Exception& )
{
- }
+ }
}
// --------------------------------------------------------------------
@@ -239,7 +241,7 @@ void SAL_CALL AnnotationManagerImpl::disposing ()
}
catch( Exception& )
{
- }
+ }
removeListener();
DisposeTags();
@@ -280,9 +282,9 @@ void AnnotationManagerImpl::ShowAnnotations( bool bShow )
SdOptions* pOptions = SD_MOD()->GetSdOptions(mpDoc->GetDocumentType());
if( pOptions )
- pOptions->SetShowComments( mbShowAnnotations ? sal_True : sal_False );
-
- UpdateTags();
+ pOptions->SetShowComments( mbShowAnnotations ? sal_True : sal_False );
+
+ UpdateTags();
}
}
@@ -303,7 +305,7 @@ void AnnotationManagerImpl::ExecuteAnnotation(SfxRequest& rReq )
case SID_PREVIOUS_POSTIT:
case SID_NEXT_POSTIT:
SelectNextAnnotation( rReq.GetSlot() == SID_NEXT_POSTIT );
- break;
+ break;
case SID_REPLYTO_POSTIT:
ExecuteReplyToAnnotation( rReq );
break;
@@ -318,7 +320,7 @@ void AnnotationManagerImpl::ExecuteAnnotation(SfxRequest& rReq )
void AnnotationManagerImpl::ExecuteInsertAnnotation(SfxRequest& /*rReq*/)
{
ShowAnnotations(true);
- InsertAnnotation();
+ InsertAnnotation();
}
// --------------------------------------------------------------------
@@ -345,12 +347,12 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq)
}
}
break;
- case SID_DELETE_POSTIT:
- {
+ case SID_DELETE_POSTIT:
+ {
Reference< XAnnotation > xAnnotation;
if( rReq.GetSlot() == SID_DELETE_POSTIT )
- {
+ {
if( pArgs )
{
const SfxPoolItem* pPoolItem = NULL;
@@ -358,10 +360,10 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq)
( ( const SfxUnoAnyItem* ) pPoolItem )->GetValue() >>= xAnnotation;
}
}
-
- if( !xAnnotation.is() )
+
+ if( !xAnnotation.is() )
GetSelectedAnnotation( xAnnotation );
-
+
DeleteAnnotation( xAnnotation );
}
break;
@@ -379,24 +381,24 @@ void AnnotationManagerImpl::InsertAnnotation()
{
if( mpDoc->IsUndoEnabled() )
mpDoc->BegUndo( String( SdResId( STR_ANNOTATION_UNDO_INSERT ) ) );
-
+
// find free space for new annotation
int y = 0, x = 0;
-
+
AnnotationVector aAnnotations( pPage->getAnnotations() );
if( !aAnnotations.empty() )
- {
+ {
const int page_width = pPage->GetSize().Width();
const int width = 1000;
const int height = 800;
Rectangle aTagRect;
-
+
while( true )
- {
+ {
Rectangle aNewRect( x, y, x + width - 1, y + height - 1 );
bool bFree = true;
-
- for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
+
+ for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); ++iter )
{
RealPoint2D aPoint( (*iter)->getPosition() );
aTagRect.nLeft = sal::static_int_cast< long >( aPoint.X * 100.0 );
@@ -418,32 +420,32 @@ void AnnotationManagerImpl::InsertAnnotation()
{
x = 0;
y += height;
- }
+ }
}
else
{
break;
}
}
- }
-
+ }
+
Reference< XAnnotation > xAnnotation;
pPage->createAnnotation( xAnnotation );
-
+
// set current author to new annotation
SvtUserOptions aUserOptions;
xAnnotation->setAuthor( aUserOptions.GetFullName() );
-
+
// set current time to new annotation
xAnnotation->setDateTime( getCurrentDateTime() );
-
+
// set position
RealPoint2D aPos( ((double)x) / 100.0, ((double)y) / 100.0 );
xAnnotation->setPosition( aPos );
if( mpDoc->IsUndoEnabled() )
mpDoc->EndUndo();
-
+
UpdateTags(true);
SelectAnnotation( xAnnotation, true );
}
@@ -488,32 +490,32 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
sQuote = String( RTL_CONSTASCII_USTRINGPARAM( "..." ) );
aStr.Append( sQuote );
aStr.Append( String(RTL_CONSTASCII_USTRINGPARAM("\"\n") ) );
-
+
sal_uInt16 nParaCount = aStr.GetTokenCount( '\n' );
for( sal_uInt16 nPara = 0; nPara < nParaCount; nPara++ )
pOutliner->Insert( aStr.GetToken( nPara, '\n' ), LIST_APPEND, -1 );
-
+
if( pOutliner->GetParagraphCount() > 1 )
{
SfxItemSet aAnswerSet( pOutliner->GetEmptyItemSet() );
- aAnswerSet.Put(SvxPostureItem(ITALIC_NORMAL,EE_CHAR_ITALIC));
-
+ aAnswerSet.Put(SvxPostureItem(ITALIC_NORMAL,EE_CHAR_ITALIC));
+
ESelection aSel;
aSel.nEndPara = (sal_uInt16)pOutliner->GetParagraphCount()-2;
aSel.nEndPos = pOutliner->GetText( pOutliner->GetParagraph( aSel.nEndPara ) ).Len();
-
+
pOutliner->QuickSetAttribs( aAnswerSet, aSel );
}
-
+
std::auto_ptr< OutlinerParaObject > pOPO( pOutliner->CreateParaObject() );
pTextApi->SetText( *pOPO.get() );
-
+
SvtUserOptions aUserOptions;
- xAnnotation->setAuthor( aUserOptions.GetFullName() );
+ xAnnotation->setAuthor( aUserOptions.GetFullName() );
// set current time to reply
xAnnotation->setDateTime( getCurrentDateTime() );
-
+
UpdateTags(true);
SelectAnnotation( xAnnotation, true );
}
@@ -522,7 +524,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
// --------------------------------------------------------------------
void AnnotationManagerImpl::DeleteAnnotation( Reference< XAnnotation > xAnnotation )
-{
+{
SdPage* pPage = GetCurrentPage();
if( xAnnotation.is() && pPage )
@@ -548,11 +550,11 @@ void AnnotationManagerImpl::DeleteAnnotationsByAuthor( const rtl::OUString& sAut
do
{
pPage = GetNextPage( pPage, true );
-
+
if( pPage && !pPage->getAnnotations().empty() )
- {
+ {
AnnotationVector aAnnotations( pPage->getAnnotations() );
- for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
+ for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); ++iter )
{
Reference< XAnnotation > xAnnotation( *iter );
if( xAnnotation->getAuthor() == sAuthor )
@@ -578,14 +580,14 @@ void AnnotationManagerImpl::DeleteAllAnnotations()
do
{
pPage = GetNextPage( pPage, true );
-
+
if( pPage && !pPage->getAnnotations().empty() )
- {
+ {
AnnotationVector aAnnotations( pPage->getAnnotations() );
- for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
+ for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); ++iter )
{
- pPage->removeAnnotation( (*iter) );
+ pPage->removeAnnotation( (*iter) );
}
}
}
@@ -602,31 +604,31 @@ void AnnotationManagerImpl::DeleteAllAnnotations()
void AnnotationManagerImpl::GetAnnotationState(SfxItemSet& rSet)
{
SdPage* pCurrentPage = GetCurrentPage();
-
+
const bool bReadOnly = mrBase.GetDocShell()->IsReadOnly();
const bool bWrongPageKind = (pCurrentPage == 0) || (pCurrentPage->GetPageKind() != PK_STANDARD);
-
+
const SvtSaveOptions::ODFDefaultVersion nCurrentODFVersion( SvtSaveOptions().GetODFDefaultVersion() );
if( bReadOnly || bWrongPageKind || (nCurrentODFVersion != SvtSaveOptions::ODFVER_LATEST) )
- rSet.DisableItem( SID_INSERT_POSTIT );
+ rSet.DisableItem( SID_INSERT_POSTIT );
rSet.Put(SfxBoolItem(SID_SHOW_POSTIT, mbShowAnnotations));
-
+
Reference< XAnnotation > xAnnotation;
GetSelectedAnnotation( xAnnotation );
-
+
if( !xAnnotation.is() || bReadOnly )
- rSet.DisableItem( SID_DELETE_POSTIT );
+ rSet.DisableItem( SID_DELETE_POSTIT );
SdPage* pPage = 0;
-
+
bool bHasAnnotations = false;
do
{
pPage = GetNextPage( pPage, true );
-
- if( pPage && !pPage->getAnnotations().empty() )
+
+ if( pPage && !pPage->getAnnotations().empty() )
bHasAnnotations = true;
}
while( pPage && !bHasAnnotations );
@@ -634,7 +636,7 @@ void AnnotationManagerImpl::GetAnnotationState(SfxItemSet& rSet)
if( !bHasAnnotations || bReadOnly )
{
rSet.DisableItem( SID_DELETEALL_POSTIT );
- }
+ }
if( bWrongPageKind || !bHasAnnotations )
{
@@ -661,11 +663,11 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
{
if( xCurrent.is() )
{
- for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
+ for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); ++iter )
{
if( (*iter) == xCurrent )
{
- iter++;
+ ++iter;
if( iter != aAnnotations.end() )
{
SelectAnnotation( (*iter) );
@@ -682,26 +684,25 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
}
}
else
- {
+ {
if( xCurrent.is() )
{
- for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
- {
- if( (*iter) == xCurrent )
- {
- if( iter != aAnnotations.begin() )
- {
- iter--;
+ for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); ++iter )
+ {
+ if( (*iter) == xCurrent )
+ {
+ if( iter != aAnnotations.begin() )
+ {
+ --iter;
SelectAnnotation( (*iter) );
return;
-
- }
- break;
- }
- }
+ }
+ break;
+ }
+ }
}
else if( !aAnnotations.empty() )
- {
+ {
AnnotationVector::iterator iter( aAnnotations.end() );
SelectAnnotation( *(--iter) );
return;
@@ -714,8 +715,8 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
do
{
pPage = GetNextPage( pPage, bForeward );
-
- if( pPage && !pPage->getAnnotations().empty() )
+
+ if( pPage && !pPage->getAnnotations().empty() )
{
// switch to next/previous slide with annotations
::boost::shared_ptr<DrawViewShell> pDrawViewShell(::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell()));
@@ -723,17 +724,17 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
{
pDrawViewShell->ChangeEditMode(pPage->IsMasterPage() ? EM_MASTERPAGE : EM_PAGE, sal_False);
pDrawViewShell->SwitchPage((pPage->GetPageNum() - 1) >> 1);
-
+
SfxDispatcher* pDispatcher = getDispatcher( mrBase );
if( pDispatcher )
pDispatcher->Execute( bForeward ? SID_NEXT_POSTIT : SID_PREVIOUS_POSTIT );
-
+
return;
- }
+ }
}
}
while( pPage );
-
+
// The question text depends on the search direction.
bool bImpress = mpDoc->GetDocumentType() == DOCUMENT_TYPE_IMPRESS;
sal_uInt16 nStringId;
@@ -778,14 +779,14 @@ void AnnotationManagerImpl::onTagDeselected( AnnotationTag& rTag )
// --------------------------------------------------------------------
void AnnotationManagerImpl::SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit /* = sal_False */ )
-{
+{
mxSelectedAnnotation = xAnnotation;
-
+
for( AnnotationTagVector::iterator iter( maTagVector.begin() ); iter != maTagVector.end(); iter++ )
{
if( (*iter)->GetAnnotation() == xAnnotation )
{
- SmartTagReference xTag( (*iter).get() );
+ SmartTagReference xTag( (*iter).get() );
mrBase.GetMainViewShell()->GetView()->getSmartTags().select( xTag );
(*iter)->OpenPopup( bEdit );
break;
@@ -809,8 +810,8 @@ void AnnotationManagerImpl::invalidateSlots()
pBindings->Invalidate( SID_DELETE_POSTIT );
pBindings->Invalidate( SID_DELETEALL_POSTIT );
pBindings->Invalidate( SID_PREVIOUS_POSTIT );
- pBindings->Invalidate( SID_NEXT_POSTIT );
- pBindings->Invalidate( SID_UNDO );
+ pBindings->Invalidate( SID_NEXT_POSTIT );
+ pBindings->Invalidate( SID_UNDO );
pBindings->Invalidate( SID_REDO );
}
}
@@ -826,13 +827,13 @@ void AnnotationManagerImpl::onSelectionChanged()
if( xPage != mxCurrentPage )
{
mxCurrentPage = xPage;
-
+
UpdateTags(true);
- }
+ }
}
catch( Exception& )
{
- DBG_ERROR( "sd::AnnotationManagerImpl::onSelectionChanged(), exception caught!" );
+ OSL_FAIL( "sd::AnnotationManagerImpl::onSelectionChanged(), exception caught!" );
}
}
@@ -856,15 +857,15 @@ IMPL_LINK(AnnotationManagerImpl,UpdateTagsHdl, void *, EMPTYARG)
{
mnUpdateTagsEvent = 0;
DisposeTags();
-
+
if( mbShowAnnotations )
CreateTags();
-
+
if( mrBase.GetDrawView() )
- static_cast< ::sd::View* >( mrBase.GetDrawView() )->updateHandles();
+ static_cast< ::sd::View* >( mrBase.GetDrawView() )->updateHandles();
invalidateSlots();
-
+
return 0;
}
@@ -885,16 +886,16 @@ void AnnotationManagerImpl::CreateTags()
Color aColor( GetColorLight( mpDoc->GetAnnotationAuthorIndex( xAnnotation->getAuthor() ) ) );
rtl::Reference< AnnotationTag > xTag( new AnnotationTag( *this, *mrBase.GetMainViewShell()->GetView(), xAnnotation, aColor, nIndex++, maFont ) );
maTagVector.push_back(xTag);
-
+
if( xAnnotation == mxSelectedAnnotation )
{
xSelectedTag = xTag;
}
}
-
+
if( xSelectedTag.is() )
{
- SmartTagReference xTag( xSelectedTag.get() );
+ SmartTagReference xTag( xSelectedTag.get() );
mrBase.GetMainViewShell()->GetView()->getSmartTags().select( xTag );
}
else
@@ -905,7 +906,7 @@ void AnnotationManagerImpl::CreateTags()
}
catch( Exception& )
{
- DBG_ERROR( "sd::AnnotationManagerImpl::onSelectionChanged(), exception caught!" );
+ OSL_FAIL( "sd::AnnotationManagerImpl::onSelectionChanged(), exception caught!" );
}
}
@@ -971,59 +972,35 @@ IMPL_LINK(AnnotationManagerImpl,EventMultiplexerListener,
}
return 0;
}
-#if 0
-OUString AnnotationManagerImpl::GetHelpText( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation >& xAnnotation )
-{
- OUString sRet;
- if( xAnnotation.is() )
- {
- OUString sAuthor( xAnnotation->getAuthor() );
- if( sAuthor.getLength() != 0 )
- {
- sRet += sAuthor;
- }
- sRet += OUString( RTL_CONSTASCII_USTRINGPARAM( " [" ) );
-
- sRet += getAnnotationDateTimeString( xAnnotation );
- sRet += OUString( RTL_CONSTASCII_USTRINGPARAM( "]\n" ) );
-
- Reference< XText > xText( xAnnotation->getTextRange() );
- if( xText.is() )
- sRet += xText->getString();
- }
-
- return sRet;
-}
-#endif
void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation > xAnnotation, ::Window* pParent, const Rectangle& rContextRect, bool bButtonMenu /* = false */ )
{
SfxDispatcher* pDispatcher( getDispatcher( mrBase ) );
if( !pDispatcher )
return;
-
+
const bool bReadOnly = mrBase.GetDocShell()->IsReadOnly();
-
+
AnnotationWindow* pAnnotationWindow = bButtonMenu ? 0 : dynamic_cast< AnnotationWindow* >( pParent );
-
+
if( bReadOnly && !pAnnotationWindow )
return;
-
+
std::auto_ptr< PopupMenu > pMenu( new PopupMenu( SdResId( pAnnotationWindow ? RID_ANNOTATION_CONTEXTMENU : RID_ANNOTATION_TAG_CONTEXTMENU ) ) );
SvtUserOptions aUserOptions;
- OUString sCurrentAuthor( aUserOptions.GetFullName() );
+ OUString sCurrentAuthor( aUserOptions.GetFullName() );
OUString sAuthor( xAnnotation->getAuthor() );
-
+
String aStr( pMenu->GetItemText( SID_DELETEALLBYAUTHOR_POSTIT ) ), aReplace( sAuthor );
if( aReplace.Len() == 0 )
aReplace = String( SdResId( STR_ANNOTATION_NOAUTHOR ) );
aStr.SearchAndReplaceAscii("%1", aReplace);
pMenu->SetItemText( SID_DELETEALLBYAUTHOR_POSTIT, aStr );
pMenu->EnableItem( SID_REPLYTO_POSTIT, (sAuthor != sCurrentAuthor) && !bReadOnly );
- pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? sal_True : sal_False );
- pMenu->EnableItem( SID_DELETEALLBYAUTHOR_POSTIT, !bReadOnly );
- pMenu->EnableItem( SID_DELETEALL_POSTIT, !bReadOnly );
+ pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? sal_True : sal_False );
+ pMenu->EnableItem( SID_DELETEALLBYAUTHOR_POSTIT, !bReadOnly );
+ pMenu->EnableItem( SID_DELETEALL_POSTIT, !bReadOnly );
if( pAnnotationWindow )
{
@@ -1065,26 +1042,25 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( pAnnotationWindow ) );
pMenu->EnableItem( SID_PASTE, aDataHelper.GetFormatCount() != 0 );
}
-
+
pMenu->EnableItem( SID_COPY, pAnnotationWindow->getView()->HasSelection() );
}
sal_uInt16 nId = 0;
-
+
// set slot images
Reference< ::com::sun::star::frame::XFrame > xFrame( mrBase.GetMainViewShell()->GetViewFrame()->GetFrame().GetFrameInterface() );
if( xFrame.is() )
{
- const bool bHighContrast = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
for( sal_uInt16 nPos = 0; nPos < pMenu->GetItemCount(); nPos++ )
{
- nId = pMenu->GetItemId( nPos );
+ nId = pMenu->GetItemId( nPos );
if( pMenu->IsItemEnabled( nId ) )
{
OUString sSlotURL( RTL_CONSTASCII_USTRINGPARAM( "slot:" ));
sSlotURL += OUString::valueOf( sal_Int32( nId ));
-
- Image aImage( GetImage( xFrame, sSlotURL, false, bHighContrast ) );
+
+ Image aImage( GetImage( xFrame, sSlotURL, false ) );
if( !!aImage )
pMenu->SetItemImage( nId, aImage );
}
@@ -1114,10 +1090,10 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
}
case SID_DELETEALL_POSTIT:
pDispatcher->Execute( SID_DELETEALL_POSTIT );
- break;
+ break;
case SID_COPY:
case SID_PASTE:
- case SID_ATTR_CHAR_WEIGHT:
+ case SID_ATTR_CHAR_WEIGHT:
case SID_ATTR_CHAR_POSTURE:
case SID_ATTR_CHAR_UNDERLINE:
case SID_ATTR_CHAR_STRIKEOUT:
@@ -1138,7 +1114,7 @@ Color AnnotationManagerImpl::GetColor(sal_uInt16 aAuthorIndex)
COL_AUTHOR4_NORMAL, COL_AUTHOR5_NORMAL, COL_AUTHOR6_NORMAL,
COL_AUTHOR7_NORMAL, COL_AUTHOR8_NORMAL, COL_AUTHOR9_NORMAL };
- return Color( aArrayNormal[ aAuthorIndex % (sizeof( aArrayNormal )/ sizeof( aArrayNormal[0] ))]);
+ return Color( aArrayNormal[ aAuthorIndex % (SAL_N_ELEMENTS(aArrayNormal))]);
}
else
return Color(COL_WHITE);
@@ -1153,7 +1129,7 @@ Color AnnotationManagerImpl::GetColorLight(sal_uInt16 aAuthorIndex)
COL_AUTHOR4_LIGHT, COL_AUTHOR5_LIGHT, COL_AUTHOR6_LIGHT,
COL_AUTHOR7_LIGHT, COL_AUTHOR8_LIGHT, COL_AUTHOR9_LIGHT };
- return Color( aArrayLight[ aAuthorIndex % (sizeof( aArrayLight )/ sizeof( aArrayLight[0] ))]);
+ return Color( aArrayLight[ aAuthorIndex % (SAL_N_ELEMENTS(aArrayLight))]);
}
else
return Color(COL_WHITE);
@@ -1168,7 +1144,7 @@ Color AnnotationManagerImpl::GetColorDark(sal_uInt16 aAuthorIndex)
COL_AUTHOR4_DARK, COL_AUTHOR5_DARK, COL_AUTHOR6_DARK,
COL_AUTHOR7_DARK, COL_AUTHOR8_DARK, COL_AUTHOR9_DARK };
- return Color( aArrayAnkor[ aAuthorIndex % (sizeof( aArrayAnkor ) / sizeof( aArrayAnkor[0] ))]);
+ return Color( aArrayAnkor[ aAuthorIndex % (SAL_N_ELEMENTS(aArrayAnkor))]);
}
else
return Color(COL_WHITE);
@@ -1178,14 +1154,14 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
{
if( pPage == 0 )
return bForeward ? GetFirstPage() : GetLastPage();
-
+
sal_uInt16 nPageNum = (pPage->GetPageNum() - 1) >> 1;
// first all non master pages
if( !pPage->IsMasterPage() )
{
if( bForeward )
- {
+ {
if( nPageNum >= mpDoc->GetSdPageCount(PK_STANDARD)-1 )
{
// we reached end of draw pages, start with master pages (skip handout master for draw)
@@ -1197,15 +1173,15 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
{
if( nPageNum == 0 )
return 0; // we are already on the first draw page, finished
-
- nPageNum--;
+
+ nPageNum--;
}
return mpDoc->GetSdPage(nPageNum, PK_STANDARD);
}
else
{
if( bForeward )
- {
+ {
if( nPageNum >= mpDoc->GetMasterSdPageCount(PK_STANDARD)-1 )
{
return 0; // we reached the end, there is nothing more to see here
@@ -1218,12 +1194,12 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
{
// we reached beginning of master pages, start with end if pages
return mpDoc->GetSdPage( mpDoc->GetSdPageCount(PK_STANDARD)-1, PK_STANDARD );
- }
-
- nPageNum--;
+ }
+
+ nPageNum--;
}
return mpDoc->GetMasterSdPage(nPageNum,PK_STANDARD);
- }
+ }
}
SdPage* AnnotationManagerImpl::GetFirstPage()
@@ -1239,11 +1215,6 @@ SdPage* AnnotationManagerImpl::GetLastPage()
SdPage* AnnotationManagerImpl::GetCurrentPage()
{
-/*
- ::boost::shared_ptr<DrawViewShell> pDrawViewShell(::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell()));
- if (pDrawViewShell.get() != NULL)
- return pDrawViewShell->GetActualPage();
-*/
return mrBase.GetMainViewShell()->getCurrentPage();
}
@@ -1271,3 +1242,5 @@ void AnnotationManager::GetAnnotationState(SfxItemSet& rItemSet)
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationmanagerimpl.hxx b/sd/source/ui/annotations/annotationmanagerimpl.hxx
index e7c655324..e913bff22 100755..100644
--- a/sd/source/ui/annotations/annotationmanagerimpl.hxx
+++ b/sd/source/ui/annotations/annotationmanagerimpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,7 +70,6 @@ public:
virtual void SAL_CALL notifyEvent( const ::com::sun::star::document::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw (::com::sun::star::uno::RuntimeException);
- //
void ExecuteAnnotation (SfxRequest& rRequest);
void GetAnnotationState (SfxItemSet& rItemSet);
@@ -99,9 +99,7 @@ public:
void onTagDeselected( AnnotationTag& rTag );
void onSelectionChanged();
-#if 0
- rtl::OUString GetHelpText( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation >& xAnnotation );
-#endif
+
void addListener();
void removeListener();
@@ -142,3 +140,5 @@ private:
}
#endif // _SD_ANNOTATIONMANAGER_IMPL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationtag.cxx b/sd/source/ui/annotations/annotationtag.cxx
index 93f8c663f..cd9a9c5d3 100755..100644
--- a/sd/source/ui/annotations/annotationtag.cxx
+++ b/sd/source/ui/annotations/annotationtag.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,7 +60,6 @@
using ::rtl::OUString;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
-//using namespace ::com::sun::star::util;
using namespace ::com::sun::star::drawing;
using namespace ::com::sun::star::office;
using namespace ::com::sun::star::geometry;
@@ -342,13 +342,7 @@ bool AnnotationTag::MouseButtonDown( const MouseEvent& rMEvt, SmartHdl& /*rHdl*/
mrView.getSmartTags().select( xTag );
bRet = true;
}
- /*
- if( rMEvt.IsLeft() && (rMEvt.GetClicks() == 2) )
- {
- // double click;
- return true;
- }
- else */
+
if( rMEvt.IsLeft() && !rMEvt.IsRight() )
{
Window* pWindow = mrView.GetViewShell()->GetActiveWindow();
@@ -414,25 +408,7 @@ bool AnnotationTag::KeyInput( const KeyEvent& rKEvt )
/** returns true if the SmartTag consumes this event. */
bool AnnotationTag::RequestHelp( const HelpEvent& /*rHEvt*/ )
{
-/*
- ::Window* pWindow = mrView.GetViewShell()->GetActiveWindow();
- if( mxAnnotation.is() && pWindow )
- {
- OUString aHelpText( mrManager.GetHelpText( mxAnnotation ) );
- RealPoint2D aPosition( mxAnnotation->getPosition() );
- Point aPos( pWindow->LogicToPixel( Point( static_cast<long>(aPosition.X * 100.0), static_cast<long>(aPosition.Y * 100.0) ) ) );
-
- Rectangle aRect( aPos, maSize );
-
- if (Help::IsBalloonHelpEnabled())
- Help::ShowBalloon( pWindow, aPos, aRect, aHelpText);
- else if (Help::IsQuickHelpEnabled())
- Help::ShowQuickHelp( pWindow, aRect, aHelpText);
-
- return true;
- }
-*/
return false;
}
@@ -788,3 +764,4 @@ IMPL_LINK( AnnotationTag, ClosePopupHdl, void *, EMPTYARG )
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationtag.hxx b/sd/source/ui/annotations/annotationtag.hxx
index 33baec8d0..5a943aeeb 100755..100644
--- a/sd/source/ui/annotations/annotationtag.hxx
+++ b/sd/source/ui/annotations/annotationtag.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -105,3 +106,4 @@ private:
#endif // _SD_ANNOTATIONTAG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationwindow.cxx b/sd/source/ui/annotations/annotationwindow.cxx
index 37f24c563..12e8617e3 100755..100644
--- a/sd/source/ui/annotations/annotationwindow.cxx
+++ b/sd/source/ui/annotations/annotationwindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/************************************************************************* *
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -242,9 +243,6 @@ void AnnotationTextWindow::GetFocus()
void AnnotationTextWindow::LoseFocus()
{
-// if ( mpAnnotationWindow )
-// mpAnnotationWindow->UpdateAnnotation();
-
Window::LoseFocus();
}
@@ -323,9 +321,6 @@ void AnnotationWindow::InitControls()
mpMeta->AlwaysDisableInput(true);
mpMeta->SetCallHandlersOnInputDisabled(true);
-// mpMeta->AddEventListener( LINK( mpPostItTxt, PostItTxt, WindowEventListener ) );
-// AddEventListener( LINK( mpTextWindow, PostItTxt, WindowEventListener ) );
-
// we should leave this setting alone, but for this we need a better layout algo
// with variable meta size height
AllSettings aSettings = mpMeta->GetSettings();
@@ -352,10 +347,6 @@ void AnnotationWindow::InitControls()
mpTextWindow->SetOutlinerView(mpOutlinerView);
mpOutlinerView->SetOutputArea( PixelToLogic( Rectangle(0,0,1,1) ) );
-// SfxItemSet item(DocShell()->GetPool());
-// item.Put(SvxFontHeightItem(352,100,EE_CHAR_FONTHEIGHT));
-// mpOutlinerView->SetAttribs(item);
-
// TODO: ??
EEHorizontalTextDirection aDefHoriTextDir = Application::GetSettings().GetLayoutRTL() ? EE_HTEXTDIR_R2L : EE_HTEXTDIR_L2R;
mpOutliner->SetDefaultHorizontalTextDirection( aDefHoriTextDir );
@@ -366,22 +357,10 @@ void AnnotationWindow::InitControls()
mpVScrollbar->EnableRTL( false );
mpVScrollbar->SetScrollHdl(LINK(this, AnnotationWindow, ScrollHdl));
mpVScrollbar->EnableDrag();
-// mpVScrollbar->AddEventListener( LINK( this, AnnotationWindow, WindowEventListener ) );
sal_uLong nCntrl = mpOutliner->GetControlWord();
nCntrl |= EE_CNTRL_PASTESPECIAL | EE_CNTRL_AUTOCORRECT | EV_CNTRL_AUTOSCROLL | EE_CNTRL_NOCOLORS;
-/*
- if (pVOpt->IsFieldShadings())
- nCntrl |= EE_CNTRL_MARKFIELDS;
- else
- nCntrl &= ~EE_CNTRL_MARKFIELDS;
- if (pVOpt->IsOnlineSpell())
- nCntrl |= EE_CNTRL_ONLINESPELLING;
- else
- nCntrl &= ~EE_CNTRL_ONLINESPELLING;
-*/
mpOutliner->SetControlWord(nCntrl);
-// mpOutliner->SetFlatMode( sal_True );
Engine()->SetModifyHdl( Link() );
Engine()->EnableUndo( sal_False );
@@ -410,8 +389,6 @@ void AnnotationWindow::Rescale()
{
MapMode aMode(MAP_100TH_MM);
aMode.SetOrigin( Point() );
- //aMode.SetScaleX( aMode.GetScaleX() * Fraction( 8, 10 ) );
- //aMode.SetScaleY( aMode.GetScaleY() * Fraction( 8, 10 ) );
mpOutliner->SetRefMapMode( aMode );
SetMapMode( aMode );
mpTextWindow->SetMapMode( aMode );
@@ -504,7 +481,7 @@ void AnnotationWindow::ResizeIfNeccessary(long aOldHeight, long aNewHeight)
}
}
-void AnnotationWindow::SetLanguage(const SvxLanguageItem aNewItem)
+void AnnotationWindow::SetLanguage(const SvxLanguageItem &aNewItem)
{
Engine()->SetModifyHdl( Link() );
ESelection aOld = getView()->GetSelection();
@@ -551,7 +528,6 @@ IMPL_LINK(AnnotationWindow, ModifyHdl, void*, EMPTYARG)
sal_Int32 AnnotationWindow::GetScrollbarWidth()
{
return 16;
-// return mpView->GetWrtShell().GetViewOptions()->GetZoom() / 10;
}
SvxLanguageItem AnnotationWindow::GetLanguage(void)
@@ -846,3 +822,5 @@ void AnnotationWindow::ExecuteSlot( sal_uInt16 nSID )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/annotationwindow.hxx b/sd/source/ui/annotations/annotationwindow.hxx
index 718b9ada6..03c70cf2b 100755..100644
--- a/sd/source/ui/annotations/annotationwindow.hxx
+++ b/sd/source/ui/annotations/annotationwindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -148,7 +149,7 @@ class AnnotationWindow : public FloatingWindow
bool IsProtected() { return mbProtected; }
- void SetLanguage(const SvxLanguageItem aNewItem);
+ void SetLanguage(const SvxLanguageItem &aNewItem);
sal_Int32 GetScrollbarWidth();
@@ -173,3 +174,5 @@ class AnnotationWindow : public FloatingWindow
} // namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/annotations/makefile.mk b/sd/source/ui/annotations/makefile.mk
deleted file mode 100644
index 40a5c9181..000000000
--- a/sd/source/ui/annotations/makefile.mk
+++ /dev/null
@@ -1,56 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=uiannotations
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES =\
- annotations.src
-
-SLOFILES = \
- $(SLO)$/annotationwindow.obj \
- $(SLO)$/annotationtag.obj \
- $(SLO)$/annotationmanager.obj
-
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/ui/app/app.src b/sd/source/ui/app/app.src
index 443308278..36c224bab 100644
--- a/sd/source/ui/app/app.src
+++ b/sd/source/ui/app/app.src
@@ -30,6 +30,5 @@
#include "res_bmp.hrc"
#include <svx/dialogs.hrc>
#include "cfgids.hxx"
-#include "misc.hxx"
#include <svx/svxids.hrc>
diff --git a/sd/source/ui/app/makefile.mk b/sd/source/ui/app/makefile.mk
deleted file mode 100755
index 8c66ae2ee..000000000
--- a/sd/source/ui/app/makefile.mk
+++ /dev/null
@@ -1,112 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=app
-
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-NO_HID_FILES=app.src
-.EXPORT : NO_HID_FILES
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- app.src \
- toolbox.src \
- strings.src \
- res_bmp.src \
- popup.src \
- sdstring.src
-
-#OBJFILES = \
-# $(OBJ)$/sdlib.obj \
-# $(OBJ)$/sdresid.obj \
-
-SLOFILES = \
- $(SLO)$/sdmod.obj \
- $(SLO)$/sdmod1.obj \
- $(SLO)$/sdmod2.obj \
- $(SLO)$/sddll.obj \
- $(SLO)$/sddll1.obj \
- $(SLO)$/sddll2.obj \
- $(SLO)$/tbxww.obj \
- $(SLO)$/optsitem.obj \
- $(SLO)$/sdresid.obj \
- $(SLO)$/sdpopup.obj \
- $(SLO)$/sdxfer.obj \
- $(SLO)$/tmplctrl.obj
-
-EXCEPTIONSFILES= \
- $(SLO)$/sddll1.obj \
- $(SLO)$/sddll2.obj \
- $(SLO)$/sdxfer.obj \
- $(SLO)$/sdmod1.obj \
- $(SLO)$/tbxww.obj \
- $(SLO)$/tmplctrl.obj
-
-.IF "$(GUI)" == "WNT"
-
-NOOPTFILES=\
- $(SLO)$/optsitem.obj
-
-.ENDIF
-
-# --- Tagets -------------------------------------------------------
-
-all: \
- $(INCCOM)$/sddll0.hxx \
- ALLTAR
-
-$(INCCOM)$/sddll0.hxx: makefile.mk
- @echo $@
-.IF "$(GUI)"=="UNX"
- echo \#define DLL_NAME \"libsd$(DLLPOSTFIX)$(DLLPOST)\" >$@
-.ELSE # "$(GUI)"=="UNX"
- echo \#define DLL_NAME \"sd$(DLLPOSTFIX).DLL\" >$@
-.ENDIF # "$(GUI)"=="UNX"
-
-LOCALIZE_ME = tbxids_tmpl.src menuids2_tmpl.src menu_tmpl.src menuids_tmpl.src menuids4_tmpl.src popup2_tmpl.src toolbox2_tmpl.src menuportal_tmpl.src menuids3_tmpl.src
-
-
-.INCLUDE : target.mk
-
-$(SRS)$/app.srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
-
-
-$(SRS)$/$(SRS1NAME).srs : $(LOCALIZE_ME_DEST)
-
diff --git a/sd/source/ui/app/menuids2_tmpl.src b/sd/source/ui/app/menuids2_tmpl.src
index 33ae6fe1e..ce8809f85 100755..100644
--- a/sd/source/ui/app/menuids2_tmpl.src
+++ b/sd/source/ui/app/menuids2_tmpl.src
@@ -24,7 +24,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-#include "misc.hxx"
#ifndef _MENUIDS2_SRC
#define _MENUIDS2_SRC
@@ -211,7 +210,6 @@
Text [ en-US ] = "~Rulers" ; \
};
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_NOTESMODE \
MenuItem\
{\
@@ -221,7 +219,6 @@
Text [ en-US ] = "~Notes View" ; \
};
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_HANDOUTMODE \
MenuItem\
{\
@@ -668,7 +665,6 @@
//
// Praesentations-Menu
//
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_SLIDESHOW \
Identifier = 26 ; \
HelpID = "what a hack!" ; \
@@ -715,7 +711,6 @@
Text [ en-US ] = "~AutoCorrect..." ; \
};
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_PRESENTATION_DLG \
MenuItem\
{\
@@ -724,7 +719,6 @@
Text [ en-US ] = "~Slide Show Settings..." ; \
};
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_CUSTOMSHOW_DLG \
MenuItem\
{\
diff --git a/sd/source/ui/app/menuids3_tmpl.src b/sd/source/ui/app/menuids3_tmpl.src
index 3d49d1ae5..7e8171267 100644
--- a/sd/source/ui/app/menuids3_tmpl.src
+++ b/sd/source/ui/app/menuids3_tmpl.src
@@ -81,7 +81,6 @@
{\
Identifier = SID_CONVERT_TO_3D_LATHE_FAST ; \
HelpId = CMD_SID_CONVERT_TO_3D_LATHE_FAST ; \
- /* ### ACHTUNG: Neuer Text in Resource? In 3~D-Rotationskörper : In 3~D-Rotationsk÷rper */\
Text [ en-US ] = "To 3D ~Rotation Object" ; \
};
diff --git a/sd/source/ui/app/menuids_tmpl.src b/sd/source/ui/app/menuids_tmpl.src
index a5496dd2d..8663c41cc 100644
--- a/sd/source/ui/app/menuids_tmpl.src
+++ b/sd/source/ui/app/menuids_tmpl.src
@@ -43,7 +43,6 @@
Text [ en-US ] = "~Distribution..." ; \
};
-/* ### ACHTUNG: Neuer Text in Resource! */
#define MN_DRAWINGMODE \
MenuItem\
{\
@@ -76,11 +75,7 @@
{\
Identifier = SID_PRESENTATION ; \
HelpId = CMD_SID_PRESENTATION ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Bildschirmpräsentation : ~Bildschirmpräsentation... */\
- /* ### ACHTUNG: Neuer Text in Resource? ~Bildschirmpräsentation : ~Bildschirmpräsentation... */\
- /* ### ACHTUNG: Neuer Text in Resource? ~Bildschirmpräsentation : ~Bildschirmprõsentation */\
Text [ en-US ] = "Slide Sho~w" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Bildschirmpräsentation starten : Bildschirmprõsentation starten */\
};
#define MN_CAPTUREPOINT \
@@ -88,8 +83,6 @@
{\
Identifier = SID_CAPTUREPOINT ; \
HelpId = CMD_SID_CAPTUREPOINT ; \
- /* ### ACHTUNG: Neuer Text in Resource? F~angpunkt/-linie einfügen... : F~angpunkt/-linie einf³gen... */\
- /* ### ACHTUNG: Neuer Text in Resource? Fangpunkt oder -linie einfügen : Fangpunkt oder -linie einf³gen */\
Text [ en-US ] = "~Insert Snap Point/Line..." ; \
};
@@ -98,7 +91,6 @@
{\
Identifier = SID_SET_SNAPITEM ; \
HelpId = CMD_SID_SET_SNAPITEM ; \
- /* ### ACHTUNG: Neuer Text in Resource? Fangobjekt bearbeiten oder löschen : Fangobjekt bearbeiten oder l÷schen */\
Text [ en-US ] = "~Edit..." ; \
};
@@ -107,8 +99,6 @@
{\
Identifier = SID_DELETE_SNAPITEM ; \
HelpId = CMD_SID_DELETE_SNAPITEM ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Löschen : ~L÷schen */\
- /* ### ACHTUNG: Neuer Text in Resource? Fangobjekt löschen : Fangobjekt l÷schen */\
Text [ en-US ] = "~Delete" ; \
};
@@ -126,7 +116,6 @@
{\
Identifier = SID_PAGESETUP ; \
HelpId = CMD_SID_PAGESETUP ; \
- /* ### ACHTUNG: Neuer Text in Resource? Seitengröße, Ausrichtung, Rahmen festlegen : Seitengr÷˜e, Ausrichtung, Rahmen festlegen */\
Text [ en-US ] = "~Page Setup..." ; \
};
@@ -306,6 +295,14 @@
Text [ en-US ] = "~Text..." ; \
};
+#define MN_OUTLINE_TEXT_AUTOFIT \
+ MenuItem\
+ {\
+ Identifier = SID_OUTLINE_TEXT_AUTOFIT ; \
+ HelpID = CMD_SID_OUTLINE_TEXT_AUTOFIT ; \
+ Text [ en-US ] = "~Autofit Text" ; \
+ };
+
#define MN_CONNECTION \
MenuItem\
{\
@@ -319,7 +316,6 @@
{\
Identifier = SID_CONNECTION_NEW_ROUTING ; \
HelpId = CMD_SID_CONNECTION_NEW_ROUTING ; \
- /* ### ACHTUNG: Neuer Text in Resource? Linienverlauf ~zurücksetzen : Linienverlauf ~zur³cksetzen */\
Text [ en-US ] = "Reset ~Routing" ; \
};
@@ -328,7 +324,6 @@
{\
Identifier = SID_MEASURE_DLG ; \
HelpId = CMD_SID_MEASURE_DLG ; \
- /* ### ACHTUNG: Neuer Text in Resource? Bema~ßung... : Bema~˜ung... */\
Text [ en-US ] = "Dimen~sions..." ; \
};
@@ -421,7 +416,6 @@
Identifier = SID_CHAR_DLG ; \
HelpId = CMD_SID_CHAR_DLG ; \
Text [ en-US ] = "C~haracter..." ; \
- /* ### ACHTUNG: Neuer Text in Resource? Zeichenattribute für den selektierten Bereich auswählen : Zeichenattribute f³r den selektierten Bereich auswõhlen */\
};
#define MN_CHAR_PARAGRAPH \
@@ -443,7 +437,6 @@
{\
Identifier = SID_ATTR_CHAR_FONTHEIGHT ; \
HelpId = CMD_SID_ATTR_CHAR_FONTHEIGHT ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Größe : ~Gr÷˜e */\
Text [ en-US ] = "~Size" ; \
};\
MenuItem\
@@ -646,7 +639,6 @@
{\
Identifier = SID_OBJECT_CLOSE ; \
HelpId = CMD_SID_OBJECT_CLOSE ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Objekt schließen : ~Objekt schlie˜en */\
Text [ en-US ] = "Close ~Object" ; \
};
@@ -668,14 +660,12 @@
{\
Identifier = SID_BEZIER_INSERT ; \
HelpId = CMD_SID_BEZIER_INSERT ; \
- /* ### ACHTUNG: Neuer Text in Resource? Punkte ~einfügen : Punkte ~einf³gen */\
Text [ en-US ] = "Insert ~Points" ; \
};\
MenuItem\
{\
Identifier = SID_BEZIER_DELETE ; \
HelpId = CMD_SID_BEZIER_DELETE ; \
- /* ### ACHTUNG: Neuer Text in Resource? Punkte l~öschen : Punkte l~÷schen */\
Text [ en-US ] = "~Delete Points" ; \
};\
SEPARATOR\
@@ -683,7 +673,6 @@
{\
Identifier = SID_BEZIER_CLOSE ; \
HelpId = CMD_SID_BEZIER_CLOSE ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Objekt schließen : ~Objekt schlie˜en */\
Text [ en-US ] = "Close ~Object" ; \
};\
MenuItem\
@@ -732,7 +721,6 @@
Identifier = SID_GROUP ; \
HelpId = CMD_SID_GROUP ; \
Text [ en-US ] = "~Group" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Ausgewählte Objekte gruppieren : Ausgewõhlte Objekte gruppieren */\
};
#define MN_UNGROUP \
@@ -749,7 +737,6 @@
Identifier = SID_COMBINE ; \
HelpId = CMD_SID_COMBINE ; \
Text [ en-US ] = "Comb~ine" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Ausgewählte Objekte kombinieren : Ausgewõhlte Objekte kombinieren */\
};
#define MN_DISMANTLE \
@@ -766,7 +753,6 @@
Identifier = SID_ENTER_GROUP ; \
HelpId = CMD_SID_ENTER_GROUP ; \
Text [ en-US ] = "~Enter Group" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Objekte der Gruppierung können bearbeitet werden : Objekte der Gruppierung k÷nnen bearbeitet werden */\
};
#define MN_LEAVE_GROUP \
@@ -775,7 +761,6 @@
Identifier = SID_LEAVE_GROUP ; \
HelpId = CMD_SID_LEAVE_GROUP ; \
Text [ en-US ] = "E~xit Group" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Objekte der Gruppierung können nicht mehr bearbeitet werden : Objekte der Gruppierung k÷nnen nicht mehr bearbeitet werden */\
};
#define MN_NAME_GROUP \
@@ -825,8 +810,6 @@
{\
Identifier = SID_PRESENTATIONOBJECT ; \
HelpId = CMD_SID_PRESENTATIONOBJECT ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Präsentationsobjekt... : ~Prõsentationsobjekt... */\
- /* ### ACHTUNG: Neuer Text in Resource? Selektiertes Präsentationsobjekt bearbeiten : Selektiertes Prõsentationsobjekt bearbeiten */\
Text [ en-US ] = "Presentation ~Object..." ; \
};
@@ -836,9 +819,7 @@
{\
Identifier = SID_DELETE ; \
HelpId = CMD_SID_DELETE ; \
- /* ### ACHTUNG: Neuer Text in Resource? L~öschen : L~÷schen */\
Text [ en-US ] = "~Delete" ; \
- /* ### ACHTUNG: Neuer Text in Resource? Alle selektierten Objekte löschen : Alle selektierten Objekte l÷schen */\
};
@@ -904,7 +885,6 @@
{\
Identifier = SID_GLUE_INSERT_POINT ; \
HelpId = CMD_SID_GLUE_INSERT_POINT ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Punkt einfügen : ~Punkt einf³gen */\
Text [ en-US ] = "Insert ~Point" ; \
};
@@ -1007,7 +987,7 @@
{\
Identifier = SID_GRID_VISIBLE ; \
HelpId = CMD_SID_GRID_VISIBLE ; \
- Text [ en-US ] = "~Visible Grid" ; \
+ Text [ en-US ] = "~Display Grid" ; \
};
#define MN_GRID_USE\
@@ -1048,8 +1028,7 @@
{\
Identifier = SID_HELPLINES_VISIBLE ; \
HelpId = CMD_SID_HELPLINES_VISIBLE ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Fanglinien sichtbar : ~Hilfslinien sichtbar */\
- Text [ en-US ] = "~Snap Lines Visible" ; \
+ Text [ en-US ] = "~Display Snap Lines" ; \
};
#define MN_HELPLINES_USE\
@@ -1057,7 +1036,7 @@
{\
Identifier = SID_HELPLINES_USE ; \
HelpId = CMD_SID_HELPLINES_USE ; \
- Text [ en-US ] = "Snap to Snap Lines"; \
+ Text [ en-US ] = "~Snap to Snap Lines"; \
};
#define MN_HELPLINES_FRONT\
@@ -1065,8 +1044,7 @@
{\
Identifier = SID_HELPLINES_FRONT ; \
HelpId = CMD_SID_HELPLINES_FRONT ; \
- /* ### ACHTUNG: Neuer Text in Resource? Fanglini~en vorn : H~ilfslinien vorn */\
- Text [ en-US ] = "Snap Lines to Front" ; \
+ Text [ en-US ] = "Snap Lines to ~Front" ; \
};
#define MN_HELPLINES \
@@ -1155,7 +1133,6 @@
{\
Identifier = DUMMY + 4 ; \
Command = ".uno:ColorResMenu" ; \
- /* ### ACHTUNG: Neuer Text in Resource? ~Farbauflösung : ~Farbaufl÷sung */\
SubMenu = Menu\
{\
ItemList = \
diff --git a/sd/source/ui/app/menuportal_tmpl.src b/sd/source/ui/app/menuportal_tmpl.src
index cdc1a705e..1ada91301 100644
--- a/sd/source/ui/app/menuportal_tmpl.src
+++ b/sd/source/ui/app/menuportal_tmpl.src
@@ -137,7 +137,6 @@ Menu SD_MENU_PORTAL
MI ( ITEM_VIEW_TOGGLEFUNCTIONBAR )
MI ( ITEM_VIEW_TOGGLEOBJECTBAR )
MN_TOGGLETOOLBAR
- MI ( ITEM_INSERT_HYPERLINK_INSERT )
MN_TOGGLEOPTIONBAR
#if SD_MENU_PORTAL == RID_DRAW_PORTALMENU
MN_TOGGLECOMMONTASKBAR
diff --git a/sd/source/ui/app/optsitem.cxx b/sd/source/ui/app/optsitem.cxx
index e10c318e5..05e4b20f1 100644
--- a/sd/source/ui/app/optsitem.cxx
+++ b/sd/source/ui/app/optsitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <svx/svdmodel.hxx>
#include <sfx2/app.hxx>
#include <sfx2/sfx.hrc>
-#ifndef _SV_SALBTYPE_HRC //autogen
#include <vcl/salbtype.hxx>
-#endif
#include <unotools/syslocale.hxx>
#include "app.hxx"
@@ -166,7 +165,7 @@ void SdOptionsGeneric::Commit( SdOptionsItem& rCfgItem ) const
rCfgItem.PutProperties( aNames, aValues );
else
{
- DBG_ERROR( "PutProperties failed" );
+ OSL_FAIL( "PutProperties failed" );
}
}
}
@@ -362,7 +361,7 @@ SfxPoolItem* SdOptionsLayoutItem::Clone( SfxItemPool* ) const
int SdOptionsLayoutItem::operator==( const SfxPoolItem& rAttr ) const
{
const bool bSameType = SfxPoolItem::operator==( rAttr );
- DBG_ASSERT( bSameType, "SdOptionsLayoutItem::operator==(), differen pool item type!" );
+ DBG_ASSERT( bSameType, "SdOptionsLayoutItem::operator==(), different pool item type!" );
return bSameType && ( maOptionsLayout == static_cast< const SdOptionsLayoutItem& >( rAttr ).maOptionsLayout );
}
@@ -465,7 +464,7 @@ SfxPoolItem* SdOptionsContentsItem::Clone( SfxItemPool* ) const
int SdOptionsContentsItem::operator==( const SfxPoolItem& rAttr ) const
{
const bool bSameType = SfxPoolItem::operator==(rAttr);
- DBG_ASSERT( bSameType, "SdOptionsContentsItem::operator==(), differen pool item type!" );
+ DBG_ASSERT( bSameType, "SdOptionsContentsItem::operator==(), different pool item type!" );
return bSameType && ( maOptionsContents == static_cast<const SdOptionsContentsItem&>( rAttr ).maOptionsContents );
}
@@ -487,7 +486,6 @@ SdOptionsMisc::SdOptionsMisc( sal_uInt16 nConfigId, sal_Bool bUseConfig ) :
B2U( "Office.Draw/Misc" ) :
B2U( "Office.Impress/Misc" ) ) :
OUString() ),
- // #97016#
nDefaultObjectSizeWidth(8000),
nDefaultObjectSizeHeight(5000),
bStartWithTemplate( sal_True ),
@@ -505,7 +503,6 @@ SdOptionsMisc::SdOptionsMisc( sal_uInt16 nConfigId, sal_Bool bUseConfig ) :
bSolidDragging( sal_True ),
bSolidMarkHdl( sal_True ),
bSummationOfParagraphs( sal_False ),
- // #90356#
bShowUndoDeleteWarning( sal_True ),
bSlideshowRespectZOrder( sal_True ),
bShowComments( sal_True ),
@@ -542,11 +539,9 @@ sal_Bool SdOptionsMisc::operator==( const SdOptionsMisc& rOpt ) const
IsSummationOfParagraphs() == rOpt.IsSummationOfParagraphs() &&
IsSolidDragging() == rOpt.IsSolidDragging() &&
IsSolidMarkHdl() == rOpt.IsSolidMarkHdl() &&
- // #90356#
IsShowUndoDeleteWarning() == rOpt.IsShowUndoDeleteWarning() &&
IsSlideshowRespectZOrder() == rOpt.IsSlideshowRespectZOrder() &&
GetPrinterIndependentLayout() == rOpt.GetPrinterIndependentLayout() &&
- // #97016#
GetDefaultObjectSizeWidth() == rOpt.GetDefaultObjectSizeWidth() &&
GetDefaultObjectSizeHeight() == rOpt.GetDefaultObjectSizeHeight() &&
@@ -578,7 +573,6 @@ void SdOptionsMisc::GetPropNameArray( const char**& ppNames, sal_uLong& rCount )
"Preview",
"ModifyWithAttributes",
"SimpleHandles",
- // #97016#
"DefaultObjectSize/Width",
"DefaultObjectSize/Height",
@@ -590,7 +584,6 @@ void SdOptionsMisc::GetPropNameArray( const char**& ppNames, sal_uLong& rCount )
"NewDoc/AutoPilot",
"Start/CurrentPage",
"Compatibility/AddBetween",
- // #90356#
"ShowUndoDeleteWarning",
"SlideshowRespectZOrder",
@@ -621,10 +614,8 @@ sal_Bool SdOptionsMisc::ReadData( const Any* pValues )
if( pValues[6].hasValue() ) SetBigHandles( *(sal_Bool*) pValues[ 6 ].getValue() );
if( pValues[7].hasValue() ) SetDoubleClickTextEdit( *(sal_Bool*) pValues[ 7 ].getValue() );
if( pValues[8].hasValue() ) SetClickChangeRotation( *(sal_Bool*) pValues[ 8 ].getValue() );
- // if( pValues[9].hasValue() ) SetPreviewQuality( FRound( *(double*) pValues[ 9 ].getValue() ) );
if( pValues[10].hasValue() ) SetSolidDragging( *(sal_Bool*) pValues[ 10 ].getValue() );
if( pValues[11].hasValue() ) SetSolidMarkHdl( *(sal_Bool*) pValues[ 11 ].getValue() );
- // #97016#
if( pValues[12].hasValue() ) SetDefaultObjectSizeWidth( *(sal_uInt32*) pValues[ 12 ].getValue() );
if( pValues[13].hasValue() ) SetDefaultObjectSizeHeight( *(sal_uInt32*) pValues[ 13 ].getValue() );
if( pValues[14].hasValue() ) SetPrinterIndependentLayout( *(sal_uInt16*) pValues[ 14 ].getValue() );
@@ -641,7 +632,6 @@ sal_Bool SdOptionsMisc::ReadData( const Any* pValues )
SetStartWithActualPage( *(sal_Bool*) pValues[ 17 ].getValue() );
if( pValues[18].hasValue() )
SetSummationOfParagraphs( *(sal_Bool*) pValues[ 18 ].getValue() );
- // #90356#
if( pValues[19].hasValue() )
SetShowUndoDeleteWarning( *(sal_Bool*) pValues[ 19 ].getValue() );
@@ -687,7 +677,6 @@ sal_Bool SdOptionsMisc::WriteData( Any* pValues ) const
pValues[ 9 ] <<= (double)0;// GetPreviewQuality();
pValues[ 10 ] <<= IsSolidDragging();
pValues[ 11 ] <<= IsSolidMarkHdl();
- // #97016#
pValues[ 12 ] <<= GetDefaultObjectSizeWidth();
pValues[ 13 ] <<= GetDefaultObjectSizeHeight();
pValues[ 14 ] <<= GetPrinterIndependentLayout();
@@ -699,7 +688,6 @@ sal_Bool SdOptionsMisc::WriteData( Any* pValues ) const
pValues[ 16 ] <<= IsStartWithTemplate();
pValues[ 17 ] <<= IsStartWithActualPage();
pValues[ 18 ] <<= IsSummationOfParagraphs();
- // #90356#
pValues[ 19 ] <<= IsShowUndoDeleteWarning();
pValues[ 20 ] <<= IsSlideshowRespectZOrder();
@@ -739,10 +727,8 @@ SdOptionsMiscItem::SdOptionsMiscItem( sal_uInt16 _nWhich, SdOptions* pOpts, ::sd
maOptionsMisc.SetStartWithTemplate( pOpts->IsStartWithTemplate() );
maOptionsMisc.SetStartWithActualPage( pOpts->IsStartWithActualPage() );
maOptionsMisc.SetSummationOfParagraphs( pOpts->IsSummationOfParagraphs() );
- // #90356#
maOptionsMisc.SetShowUndoDeleteWarning( pOpts->IsShowUndoDeleteWarning() );
maOptionsMisc.SetPrinterIndependentLayout( pOpts->GetPrinterIndependentLayout() );
- // #97016#
maOptionsMisc.SetDefaultObjectSizeWidth( pOpts->GetDefaultObjectSizeWidth() );
maOptionsMisc.SetDefaultObjectSizeHeight( pOpts->GetDefaultObjectSizeHeight() );
@@ -805,7 +791,7 @@ SfxPoolItem* SdOptionsMiscItem::Clone( SfxItemPool* ) const
int SdOptionsMiscItem::operator==( const SfxPoolItem& rAttr ) const
{
const bool bSameType = SfxPoolItem::operator==(rAttr);
- DBG_ASSERT( bSameType, "SdOptionsMiscItem::operator==(), differen pool item type!" );
+ DBG_ASSERT( bSameType, "SdOptionsMiscItem::operator==(), different pool item type!" );
return bSameType && ( maOptionsMisc == static_cast< const SdOptionsMiscItem& >(rAttr).maOptionsMisc );
}
@@ -830,11 +816,9 @@ void SdOptionsMiscItem::SetOptions( SdOptions* pOpts ) const
pOpts->SetSummationOfParagraphs( maOptionsMisc.IsSummationOfParagraphs() );
pOpts->SetSolidDragging( maOptionsMisc.IsSolidDragging() );
pOpts->SetSolidMarkHdl( maOptionsMisc.IsSolidMarkHdl() );
- // #90356#
pOpts->SetShowUndoDeleteWarning( maOptionsMisc.IsShowUndoDeleteWarning() );
pOpts->SetPrinterIndependentLayout( maOptionsMisc.GetPrinterIndependentLayout() );
pOpts->SetShowComments( maOptionsMisc.IsShowComments() );
- // #97016#
pOpts->SetDefaultObjectSizeWidth( maOptionsMisc.GetDefaultObjectSizeWidth() );
pOpts->SetDefaultObjectSizeHeight( maOptionsMisc.GetDefaultObjectSizeHeight() );
@@ -1009,7 +993,7 @@ SfxPoolItem* SdOptionsSnapItem::Clone( SfxItemPool* ) const
int SdOptionsSnapItem::operator==( const SfxPoolItem& rAttr ) const
{
const bool bSameType = SfxPoolItem::operator==(rAttr);
- DBG_ASSERT( bSameType, "SdOptionsSnapItem::operator==(), differen pool item type!" );
+ DBG_ASSERT( bSameType, "SdOptionsSnapItem::operator==(), different pool item type!" );
return bSameType && ( maOptionsSnap == static_cast< const SdOptionsSnapItem& >(rAttr).maOptionsSnap );
}
@@ -1539,7 +1523,7 @@ SfxPoolItem* SdOptionsPrintItem::Clone( SfxItemPool* ) const
int SdOptionsPrintItem::operator==( const SfxPoolItem& rAttr ) const
{
const bool bSameType = SfxPoolItem::operator==(rAttr);
- DBG_ASSERT( bSameType, "SdOptionsPrintItem::operator==(), differen pool item type!" );
+ DBG_ASSERT( bSameType, "SdOptionsPrintItem::operator==(), different pool item type!" );
return bSameType && ( maOptionsPrint == static_cast< const SdOptionsPrintItem& >( rAttr ).maOptionsPrint );
}
@@ -1619,3 +1603,5 @@ void SdOptions::StoreConfig( sal_uLong nOptionsRange )
if( nOptionsRange & SD_OPTIONS_PRINT )
SdOptionsPrint::Store();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/popup.src b/sd/source/ui/app/popup.src
index 6f30c56a9..c6ed5f8e6 100644
--- a/sd/source/ui/app/popup.src
+++ b/sd/source/ui/app/popup.src
@@ -430,21 +430,18 @@ Menu RID_LAYERTAB_POPUP
{
Identifier = SID_INSERTLAYER ;
HelpId = CMD_SID_INSERTLAYER ;
- /* ### ACHTUNG: Neuer Text in Resource? ~Ebene einfügen... : ~Ebene einf³gen... */
Text [ en-US ] = "~Insert Layer..." ;
};
MenuItem
{
Identifier = SID_MODIFYLAYER ;
HelpId = CMD_SID_MODIFYLAYER ;
- /* ### ACHTUNG: Neuer Text in Resource? E~bene ändern... : E~bene õndern... */
Text [ en-US ] = "Modify La~yer..." ;
};
MenuItem
{
Identifier = SID_DELETE_LAYER ;
HelpId = CMD_SID_DELETE_LAYER ;
- /* ### ACHTUNG: Neuer Text in Resource? Ebe~ne löschen... : Ebe~ne l÷schen... */
Text [ en-US ] = "Delete ~Layer..." ;
};
MN_RENAME_LAYER
diff --git a/sd/source/ui/app/popup2_tmpl.src b/sd/source/ui/app/popup2_tmpl.src
index f70e309af..d3fe0b4b5 100644
--- a/sd/source/ui/app/popup2_tmpl.src
+++ b/sd/source/ui/app/popup2_tmpl.src
@@ -79,6 +79,49 @@
};
//
+// OUTLINETEXTOBJ_POPUP
+//
+#if SD_POPUP == RID_DRAW_TEXTOBJ_POPUP
+ Menu RID_DRAW_OUTLINETEXTOBJ_POPUP
+#elif SD_POPUP == RID_GRAPHIC_TEXTOBJ_POPUP
+ Menu RID_GRAPHIC_OUTLINETEXTOBJ_POPUP
+#endif
+{
+ ItemList =
+ {
+ MN_SET_DEFAULT
+ SEPARATOR
+ MN_LINE
+ MN_AREA
+ MN_TEXTATTR
+ MN_OUTLINE_TEXT_AUTOFIT
+ MN_TRANSFORM
+ MN_FONTWORK
+ SEPARATOR
+ MN_CHAR_PARAGRAPH
+ SEPARATOR
+ MN_POSITION
+ MN_OBJECT_ALIGN
+ MN_DISTRIBUTE
+ MNSUB_CONVERT
+
+ //-#i68101#----------------------
+ SEPARATOR
+ MN_OBJECT_TITLE_DESCRIPTION
+ MN_NAME_GROUP
+ //-#i68101#----------------------
+
+#if SD_POPUP == RID_DRAW_TEXTOBJ_POPUP
+ SEPARATOR
+ MN_EFFECT
+ MN_ACTION
+#endif
+ SEPARATOR
+ MN_STYLEDT
+ };
+};
+
+//
// GEOMOBJ_POPUP
//
#if SD_POPUP == RID_DRAW_TEXTOBJ_POPUP
diff --git a/sd/source/ui/app/res_bmp.src b/sd/source/ui/app/res_bmp.src
index da6648206..a03fb1671 100755..100644
--- a/sd/source/ui/app/res_bmp.src
+++ b/sd/source/ui/app/res_bmp.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -35,165 +35,82 @@ Bitmap BMP_LAYOUT_EMPTY
{
File = "layout_empty.png";
};
-Bitmap BMP_LAYOUT_EMPTY_H
-{
- File = "layout_empty_h.png";
-};
Bitmap BMP_LAYOUT_HEAD01
{
File = "layout_head01.png";
};
-Bitmap BMP_LAYOUT_HEAD01_H
-{
- File = "layout_head01_h.png";
-};
Bitmap BMP_LAYOUT_HEAD02
{
File = "layout_head02.png";
};
-Bitmap BMP_LAYOUT_HEAD02_H
-{
- File = "layout_head02_h.png";
-};
Bitmap BMP_LAYOUT_HEAD02A
{
File = "layout_head02a.png";
};
-Bitmap BMP_LAYOUT_HEAD02A_H
-{
- File = "layout_head02a_h.png";
-};
Bitmap BMP_LAYOUT_HEAD02B
{
File = "layout_head02b.png";
};
-Bitmap BMP_LAYOUT_HEAD02B_H
-{
- File = "layout_head02b_h.png";
-};
Bitmap BMP_LAYOUT_HEAD03
{
File = "layout_head03.png";
};
-Bitmap BMP_LAYOUT_HEAD03_H
-{
- File = "layout_head03_h.png";
-};
Bitmap BMP_LAYOUT_HEAD03A
{
File = "layout_head03a.png";
};
-Bitmap BMP_LAYOUT_HEAD03A_H
-{
- File = "layout_head03a_h.png";
-};
Bitmap BMP_LAYOUT_HEAD03B
{
File = "layout_head03b.png";
};
-Bitmap BMP_LAYOUT_HEAD03B_H
-{
- File = "layout_head03b_h.png";
-};
Bitmap BMP_LAYOUT_HEAD03C
{
File = "layout_head03c.png";
};
-Bitmap BMP_LAYOUT_HEAD03C_H
-{
- File = "layout_head03c_h.png";
-};
Bitmap BMP_LAYOUT_HEAD04
{
File = "layout_head04.png";
};
-Bitmap BMP_LAYOUT_HEAD04_H
-{
- File = "layout_head04_h.png";
-};
Bitmap BMP_LAYOUT_HEAD06
{
File = "layout_head06.png";
};
-Bitmap BMP_LAYOUT_HEAD06_H
-{
- File = "layout_head06_h.png";
-};
Bitmap BMP_LAYOUT_TEXTONLY
{
File = "layout_textonly.png";
};
-Bitmap BMP_LAYOUT_TEXTONLY_H
-{
- File = "layout_textonly_h.png";
-};
Bitmap BMP_LAYOUT_VERTICAL01
{
File = "layout_vertical01.png";
};
-Bitmap BMP_LAYOUT_VERTICAL01_H
-{
- File = "layout_vertical01_h.png";
-};
Bitmap BMP_LAYOUT_VERTICAL02
{
File = "layout_vertical02.png";
};
-Bitmap BMP_LAYOUT_VERTICAL02_H
-{
- File = "layout_vertical02_h.png";
-};
-
Bitmap BMP_FOILH_01
{
File = "foilh01.png";
};
-Bitmap BMP_FOILH_01_H
-{
- File = "foilh01_h.png";
-};
Bitmap BMP_FOILH_02
{
File = "foilh02.png";
};
-Bitmap BMP_FOILH_02_H
-{
- File = "foilh02_h.png";
-};
Bitmap BMP_FOILH_03
{
File = "foilh03.png";
};
-Bitmap BMP_FOILH_03_H
-{
- File = "foilh03_h.png";
-};
Bitmap BMP_FOILH_04
{
File = "foilh04.png";
};
-Bitmap BMP_FOILH_04_H
-{
- File = "foilh04_h.png";
-};
Bitmap BMP_FOILH_06
{
File = "foilh06.png";
};
-Bitmap BMP_FOILH_06_H
-{
- File = "foilh06_h.png";
-};
Bitmap BMP_FOILH_09
{
File = "foilh09.png";
};
-Bitmap BMP_FOILH_09_H
-{
- File = "foilh09_h.png";
-};
-
-
Bitmap BMP_PLACEHOLDER_CHART_SMALL
{
File = "placeholder_chart_small.png";
@@ -264,139 +181,72 @@ Bitmap BMP_FOILN_01
{
File = "foiln01.bmp" ;
};
-Bitmap BMP_FOILN_01_H
-{
- File = "foiln01_h.bmp" ;
-};
+
Bitmap BMP_PAGE
{
File = "page.bmp" ;
};
-Bitmap BMP_PAGE_H
-{
- File = "page_h.bmp" ;
-};
+
Bitmap BMP_PAGE_EXCLUDED
{
File = "pageexcl.bmp" ;
};
-Bitmap BMP_PAGE_EXCLUDED_H
-{
- File = "pageexcl_h.bmp" ;
-};
+
Bitmap BMP_PAGEOBJS_EXCLUDED
{
File = "pagobjex.bmp" ;
};
-Bitmap BMP_PAGEOBJS_EXCLUDED_H
-{
- File = "pagobjex_h.bmp" ;
-};
+
Bitmap BMP_PAGEOBJS
{
File = "pageobjs.bmp" ;
};
-Bitmap BMP_PAGEOBJS_H
-{
- File = "pageobjs_h.bmp" ;
-};
+
Bitmap BMP_OBJECTS
{
File = "objects.bmp" ;
};
-Bitmap BMP_OBJECTS_H
-{
- File = "objects_h.bmp" ;
-};
+
Bitmap BMP_OLE
{
File = "ole.bmp" ;
};
-Bitmap BMP_OLE_H
-{
- File = "ole_h.bmp" ;
-};
+
Bitmap BMP_GROUP
{
File = "group.bmp" ;
};
-Bitmap BMP_GROUP_H
-{
- File = "group_h.bmp" ;
-};
+
Bitmap BMP_DOC_OPEN
{
File = "docopen.bmp" ;
};
-Bitmap BMP_DOC_OPEN_H
-{
- File = "docopen_h.bmp" ;
-};
+
Bitmap BMP_DOC_CLOSED
{
File = "docclose.bmp" ;
};
-Bitmap BMP_DOC_CLOSED_H
-{
- File = "docclose_h.bmp" ;
-};
+
Bitmap BMP_DOC_TEXT
{
File = "doctext.bmp" ;
};
-Bitmap BMP_DOC_TEXT_H
-{
- File = "doctext_h.bmp" ;
-};
+
Bitmap BMP_EXPAND
{
File = "plus.bmp" ;
};
-Bitmap BMP_EXPAND_H
-{
- File = "plus_h.bmp" ;
-};
+
Bitmap BMP_COLLAPSE
{
File = "minus.bmp" ;
};
-Bitmap BMP_COLLAPSE_H
-{
- File = "minus_h.bmp" ;
-};
+
Bitmap BMP_GRAPHIC
{
File = "graphic.bmp" ;
};
-Bitmap BMP_GRAPHIC_H
-{
- File = "graphic_h.bmp" ;
-};
-Image IMG_PIPETTE_H
-{
- ImageBitmap = Bitmap { File = "pipette_h.bmp" ; };
- MaskColor = IMAGE_MASK_STDCOLOR_HC ;
-};
-Image IMG_GET1OBJECT_H
-{
- ImageBitmap = Bitmap { File = "get1obj_h.bmp" ; };
- MaskColor = IMAGE_MASK_STDCOLOR_HC ;
-};
-Image IMG_GETALLOBJECT_H
-{
- ImageBitmap = Bitmap { File = "getallob_h.bmp" ; };
- MaskColor = IMAGE_MASK_STDCOLOR_HC ;
-};
-Image IMG_REMOVEBMP_H
-{
- ImageBitmap = Bitmap { File = "del1bmp_h.bmp" ; };
- MaskColor = IMAGE_MASK_STDCOLOR_HC ;
-};
-Image IMG_REMOVEALLBMP_H
-{
- ImageBitmap = Bitmap { File = "delall_h.bmp" ; };
- MaskColor = IMAGE_MASK_STDCOLOR_HC ;
-};
+
#define SfxStyleFamiliesRes1\
Text [ en-US ] = "Graphics Styles" ;\
@@ -424,29 +274,29 @@ SfxStyleFamilies DLG_STYLE_DESIGNER
{
SfxStyleFamiliesRes1
StyleFamily = SFX_STYLE_FAMILY_PARA ;
- FilterList =
+ FilterList [ en-US ] =
{
- < STR_STYLE_FILTER_ALL ; SFXSTYLEBIT_ALL ; > ;
- < STR_STYLE_FILTER_USED ; SFXSTYLEBIT_USED ; > ;
- < STR_STYLE_FILTER_USERDEF ; SFXSTYLEBIT_USERDEF ; > ;
+ < "All Styles" ; SFXSTYLEBIT_ALL ; > ;
+ < "Applied Styles" ; SFXSTYLEBIT_USED ; > ;
+ < "Custom Styles" ; SFXSTYLEBIT_USERDEF ; > ;
};
};
SfxStyleFamilyItem RID_PRESENTATIONSTYLEFAMILY
{
SfxStyleFamiliesRes2
StyleFamily = SFX_STYLE_FAMILY_PSEUDO ;
- FilterList =
+ FilterList [ en-US ] =
{
- < STR_STYLE_FILTER_ALL ; SFXSTYLEBIT_ALL ; > ;
+ < "All Styles" ; SFXSTYLEBIT_ALL ; > ;
};
- };
+ };
};
#define STYLE_IMAGE_LISTEF \
IdList = \
{ \
- 1; 2; \
+ 1; \
}; \
- IdCount = 2;
+ IdCount = 1;
ImageList 1 // == BMP_COLOR_NORMAL + 1
{
@@ -454,12 +304,6 @@ SfxStyleFamilies DLG_STYLE_DESIGNER
MaskColor = IMAGE_MASK_STDCOLOR;
STYLE_IMAGE_LISTEF
};
- ImageList 2 // == BMP_COLOR_HIGHCONTRAST + 1
- {
- Prefix = "sfh";
- MaskColor = IMAGE_MASK_STDCOLOR_HC;
- STYLE_IMAGE_LISTEF
- };
#undef STYLE_IMAGE_LISTEF
};
@@ -467,22 +311,27 @@ Bitmap BMP_PRESOBJ_GRAPHIC
{
File = "image.bmp" ;
};
+
Bitmap BMP_PRESOBJ_OBJECT
{
File = "object.bmp" ;
};
+
Bitmap BMP_PRESOBJ_CHART
{
File = "chart.bmp" ;
};
+
Bitmap BMP_PRESOBJ_ORGCHART
{
File = "orgchart.bmp" ;
};
+
Bitmap BMP_PRESOBJ_TABLE
{
File = "table.bmp" ;
};
+
Bitmap BMP_WAIT_ICON
{
File = "waiticon.bmp";
@@ -494,15 +343,8 @@ Bitmap BMP_FADE_EFFECT_INDICATOR
{
File = "fade_effect_indicator.bmp";
};
-Bitmap BMP_FADE_EFFECT_INDICATOR_H
-{
- File = "fade_effect_indicator_hc.bmp";
-};
+
Bitmap BMP_COMMENTS_INDICATOR
{
File = "comments_indicator.bmp";
};
-Bitmap BMP_COMMENTS_INDICATOR_H
-{
- File = "comments_indicator_hc.bmp";
-};
diff --git a/sd/source/ui/app/sddll.cxx b/sd/source/ui/app/sddll.cxx
index a2c27ff2d..9eaf8338c 100644
--- a/sd/source/ui/app/sddll.cxx
+++ b/sd/source/ui/app/sddll.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -149,3 +150,4 @@ void SdDLL::Exit()
(*ppShlPtr) = NULL;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sddll1.cxx b/sd/source/ui/app/sddll1.cxx
index c197fb8d3..b1228c6df 100755..100644
--- a/sd/source/ui/app/sddll1.cxx
+++ b/sd/source/ui/app/sddll1.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,7 +96,7 @@ void SdDLL::RegisterFactorys()
void SdDLL::RegisterInterfaces()
{
- // Modul
+ // Module
SfxModule* pMod = SD_MOD();
SdModule::RegisterInterface(pMod);
@@ -132,3 +133,5 @@ void SdDLL::RegisterInterfaces()
// controls.
::sd::toolpanel::ToolPanelViewShell::RegisterControls();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sddll2.cxx b/sd/source/ui/app/sddll2.cxx
index 567edcbd9..b6fe3b036 100755..100644
--- a/sd/source/ui/app/sddll2.cxx
+++ b/sd/source/ui/app/sddll2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,7 +44,6 @@
#include <svx/fontwork.hxx>
#include <svx/colrctrl.hxx>
#include <svx/verttexttbxctrl.hxx>
-#include <svx/hyprlink.hxx>
#include <svx/hyperdlg.hxx>
#include <svx/fillctrl.hxx>
#include <svx/linectrl.hxx>
@@ -134,7 +134,6 @@ void SdDLL::RegisterControllers()
SvxBmpMaskChildWindow::RegisterChildWindow(0, pMod);
GalleryChildWindow::RegisterChildWindow(0, pMod);
SvxIMapDlgChildWindow::RegisterChildWindow(0, pMod);
- SvxHyperlinkDlgWrapper::RegisterChildWindow(0, pMod, SFX_CHILDWIN_FORCEDOCK);
SvxHlinkDlgWrapper::RegisterChildWindow(0, pMod);
::sd::SpellDialogChildWindow::RegisterChildWindow(0, pMod);
::avmedia::MediaPlayer::RegisterChildWindow(0, pMod);
@@ -151,7 +150,6 @@ void SdDLL::RegisterControllers()
SvxStyleToolBoxControl::RegisterControl(0, pMod);
SvxFontNameToolBoxControl::RegisterControl(0, pMod);
-// SvxFontHeightToolBoxControl::RegisterControl(0, pMod);
SvxFontColorToolBoxControl::RegisterControl(0, pMod);
SvxGrafFilterToolBoxControl::RegisterControl( SID_GRFFILTER, pMod );
@@ -176,7 +174,6 @@ void SdDLL::RegisterControllers()
SvxZoomStatusBarControl::RegisterControl( SID_ATTR_ZOOM, pMod );
SvxPosSizeStatusBarControl::RegisterControl( SID_ATTR_SIZE, pMod );
SvxModifyControl::RegisterControl( SID_DOC_MODIFIED, pMod );
- //SvxInsertStatusBarControl::RegisterControl(0, pModd);
SvxZoomSliderControl::RegisterControl( SID_ATTR_ZOOMSLIDER, pMod );
// MenuControls fuer PopupMenu
@@ -206,7 +203,6 @@ void SdDLL::RegisterControllers()
SvxFrameLineColorToolBoxControl::RegisterControl(SID_FRAME_LINECOLOR, pMod );
SvxFrameToolBoxControl::RegisterControl(SID_ATTR_BORDER, pMod );
SvxSubToolBoxControl::RegisterControl(SID_OPTIMIZE_TABLE, pMod);
-
-// SdLayoutControl::RegisterControl( SID_ASSIGN_LAYOUT, pMod );
-// SdLayoutControl::RegisterControl( SID_INSERTPAGE, pMod );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdmod.cxx b/sd/source/ui/app/sdmod.cxx
index 4bd71b8dd..ecc617f21 100755..100644
--- a/sd/source/ui/app/sdmod.cxx
+++ b/sd/source/ui/app/sdmod.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#include "precompiled_sd.hxx"
#include <unotools/pathoptions.hxx>
#include <svl/languageoptions.hxx>
-#ifndef _UNOTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
#include <tools/urlobj.hxx>
#include <vcl/virdev.hxx>
#include <sfx2/app.hxx>
@@ -103,7 +102,7 @@ SdModule::SdModule(SfxObjectFactory* pFact1, SfxObjectFactory* pFact2 )
pSearchItem = new SvxSearchItem(SID_SEARCH_ITEM);
pSearchItem->SetAppFlag(SVX_SEARCHAPP_DRAW);
StartListening( *SFX_APP() );
- SvxErrorHandler::Get();
+ SvxErrorHandler::ensure();
mpErrorHdl = new SfxErrorHandler( RID_SD_ERRHDL,
ERRCODE_AREA_SD,
ERRCODE_AREA_SD_END,
@@ -257,10 +256,6 @@ SvStorageStreamRef SdModule::GetOptionStream( const String& rOptionName,
return xStm;
}
-/*************************************************************************
-|*
-\************************************************************************/
-
SvNumberFormatter* SdModule::GetNumberFormatter()
{
if( !pNumberFormatter )
@@ -269,10 +264,6 @@ SvNumberFormatter* SdModule::GetNumberFormatter()
return pNumberFormatter;
}
-/*************************************************************************
-|*
-\************************************************************************/
-
OutputDevice* SdModule::GetVirtualRefDevice (void)
{
return mpVirtualRefDevice;
@@ -285,3 +276,5 @@ OutputDevice* SdModule::GetRefDevice (::sd::DrawDocShell& )
{
return GetVirtualRefDevice();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdmod1.cxx b/sd/source/ui/app/sdmod1.cxx
index 672a295c7..39fe99981 100755..100644
--- a/sd/source/ui/app/sdmod1.cxx
+++ b/sd/source/ui/app/sdmod1.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,9 +69,7 @@
#include "sdresid.hxx"
#include "OutlineViewShell.hxx"
#include "ViewShellBase.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "FactoryIds.hxx"
#include "sdabstdlg.hxx"
#include <memory>
@@ -221,7 +220,7 @@ void SdModule::Execute(SfxRequest& rReq)
case SID_NEWSD:
{
SfxFrame* pFrame = ExecuteNewDocument( rReq );
- // #94442# if a frame was created, set it as return value
+ // if a frame was created, set it as return value
if(pFrame)
rReq.SetReturnValue(SfxFrameItem(0, pFrame));
}
@@ -656,7 +655,7 @@ SfxFrame* SdModule::ExecuteNewDocument( SfxRequest& rReq )
if ( pFrameItem )
pFrame = &pFrameItem->GetFrame()->GetFrame();
}
- catch (::com::sun::star::uno::Exception e)
+ catch (::com::sun::star::uno::Exception &e)
{
DBG_ASSERT (sal_False, "caught IllegalArgumentException while loading document from Impress autopilot");
}
@@ -740,7 +739,7 @@ SfxFrame* SdModule::ExecuteNewDocument( SfxRequest& rReq )
pDocShell->SetUseUserData(sal_True);
- // #94652# clear UNDO stack after autopilot
+ // clear UNDO stack after autopilot
pDocShell->ClearUndoBuffer();
bMakeLayoutVisible = true;
@@ -979,7 +978,7 @@ OutlineToImpressFinalizer::OutlineToImpressFinalizer (
&nReadByteCount));
// Check the error code and stop copying the stream data when an
- // error has occured.
+ // error has occurred.
switch (nErrorCode)
{
case ERRCODE_NONE:
@@ -1025,14 +1024,6 @@ void OutlineToImpressFinalizer::operator() (bool)
// have any information about a BaseURL!
if ( pOutlineShell->Read(*mpStream, String(), EE_FORMAT_RTF) == 0 )
{
-/*
- sd::OutlineViewPageChangesGuard aGuard( pView );
-
- // Remove the first empty pages
- sal_uInt16 nPageCount = mrDocument.GetPageCount();
- mrDocument.RemovePage( --nPageCount ); // notes page
- mrDocument.RemovePage( --nPageCount ); // standard page
-*/
}
// Call UpdatePreview once for every slide to resync the
@@ -1054,7 +1045,7 @@ void OutlineToImpressFinalizer::operator() (bool)
}
- // #97231# Undo-Stack needs to be cleared, else the user may remove the
+ // Undo-Stack needs to be cleared, else the user may remove the
// only drawpage and this is a state we cannot handle ATM.
::sd::DrawDocShell* pDocShell = mrDocument.GetDocSh();
if( pDocShell )
@@ -1063,3 +1054,5 @@ void OutlineToImpressFinalizer::operator() (bool)
} // end of anonymous namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdmod2.cxx b/sd/source/ui/app/sdmod2.cxx
index 50cefd8a8..5873a9754 100755..100644
--- a/sd/source/ui/app/sdmod2.cxx
+++ b/sd/source/ui/app/sdmod2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,9 +63,7 @@
#include "strings.hrc"
#include "res_bmp.hrc"
#include "ViewShell.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "sdattr.hxx"
#include "tpoption.hrc"
#include "optsitem.hxx"
@@ -402,7 +401,7 @@ IMPL_LINK(SdModule, CalcFieldValueHdl, EditFieldInfo*, pInfo)
}
else
{
- DBG_ERROR("sd::SdModule::CalcFieldValueHdl(), unknown field type!");
+ OSL_FAIL("sd::SdModule::CalcFieldValueHdl(), unknown field type!");
}
if( aRepresentation.Len() == 0 ) // TODO: Edit engine doesn't handle empty fields?
@@ -555,7 +554,6 @@ void SdModule::ApplyItemSet( sal_uInt16 nSlot, const SfxItemSet& rSet )
sal_Bool bNewPrintOptions = sal_False;
sal_Bool bMiscOptions = sal_False;
- ::sd::FrameView* pFrameView = NULL;
::sd::DrawDocShell* pDocSh = PTR_CAST(::sd::DrawDocShell, SfxObjectShell::Current() );
SdDrawDocument* pDoc = NULL;
// Hier wird der DocType vom Optionsdialog gesetzt (nicht Dokument!)
@@ -569,11 +567,6 @@ void SdModule::ApplyItemSet( sal_uInt16 nSlot, const SfxItemSet& rSet )
{
pDoc = pDocSh->GetDoc();
- // Wenn der Optionsdialog zum Dokumenttyp identisch ist,
- // kann auch die FrameView mit uebergeben werden:
- if( pDoc && eDocType == pDoc->GetDocumentType() )
- pFrameView = pDocSh->GetFrameView();
-
pViewShell = pDocSh->GetViewShell();
if (pViewShell != NULL)
pViewShell->WriteFrameViewData();
@@ -621,7 +614,7 @@ void SdModule::ApplyItemSet( sal_uInt16 nSlot, const SfxItemSet& rSet )
sal_Int32 nY = ( (SfxInt32Item*) pItem )->GetValue();
pOptions->SetScale( nX, nY );
- // #92067# Apply to document only if doc type match
+ // Apply to document only if doc type match
if( pDocSh && pDoc && eDocType == pDoc->GetDocumentType() )
{
pDoc->SetUIScale( Fraction( nX, nY ) );
@@ -746,7 +739,7 @@ void SdModule::ApplyItemSet( sal_uInt16 nSlot, const SfxItemSet& rSet )
if (pViewShell)
{
- // #74495# make sure no one is in text edit mode, cause there
+ // make sure no one is in text edit mode, cause there
// are some pointers remembered else (!)
if(pViewShell->GetView())
pViewShell->GetView()->SdrEndTextEdit();
@@ -833,3 +826,5 @@ SfxTabPage* SdModule::CreateTabPage( sal_uInt16 nId, Window* pParent, const SfxI
return pRet;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdpopup.cxx b/sd/source/ui/app/sdpopup.cxx
index 6172ac245..8b6ff26f9 100755..100644
--- a/sd/source/ui/app/sdpopup.cxx
+++ b/sd/source/ui/app/sdpopup.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -296,7 +297,7 @@ SvxFieldData* SdFieldPopup::GetField()
if( pDocSh->HasName() )
aName = pDocSh->GetMedium()->GetName();
- // #91225# Get current filename, not the one stored in the old field
+ // Get current filename, not the one stored in the old field
pNewField = new SvxExtFileField( aName );
( (SvxExtFileField*) pNewField )->SetType( eType );
( (SvxExtFileField*) pNewField )->SetFormat( eFormat );
@@ -325,7 +326,7 @@ SvxFieldData* SdFieldPopup::GetField()
if( pAuthorField->GetFormat() != eFormat ||
pAuthorField->GetType() != eType )
{
- // #91225# Get current state of address, not the old one
+ // Get current state of address, not the old one
SvtUserOptions aUserOptions;
pNewField = new SvxAuthorField( aUserOptions.GetFirstName(), aUserOptions.GetLastName(), aUserOptions.GetID() );
( (SvxAuthorField*) pNewField )->SetType( eType );
@@ -336,3 +337,4 @@ SvxFieldData* SdFieldPopup::GetField()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdresid.cxx b/sd/source/ui/app/sdresid.cxx
index 610a5b9e1..974d1e3a5 100755..100644
--- a/sd/source/ui/app/sdresid.cxx
+++ b/sd/source/ui/app/sdresid.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,3 +45,4 @@ SdResId::SdResId(sal_uInt16 nId) :
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/sdxfer.cxx b/sd/source/ui/app/sdxfer.cxx
index 83ad2d110..27f4e6f5c 100755..100644
--- a/sd/source/ui/app/sdxfer.cxx
+++ b/sd/source/ui/app/sdxfer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,11 +32,9 @@
#include <com/sun/star/embed/XEmbedPersist.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
#include <com/sun/star/lang/XComponent.hpp>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <unotools/ucbstreamhelper.hxx>
-#ifndef _UNTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
#include <editeng/eeitem.hxx>
#include <editeng/flditem.hxx>
#include <svx/svdpagv.hxx>
@@ -55,9 +54,6 @@
#include <svl/urlbmk.hxx>
#include <editeng/outliner.hxx>
-//#ifndef _SVDETC_HXX //autogen
-//#include <svx/svdetc.hxx>
-//#endif
#include <com/sun/star/form/FormButtonType.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <unotools/streamwrap.hxx>
@@ -67,6 +63,7 @@
#include <svx/svditer.hxx>
#include <sfx2/docfile.hxx>
#include <comphelper/storagehelper.hxx>
+#include <comphelper/servicehelper.hxx>
#include <svtools/embedtransfer.hxx>
#include "DrawDocShell.hxx"
#include "View.hxx"
@@ -144,7 +141,7 @@ SdTransferable::~SdTransferable()
if( mpSdView )
EndListening( *const_cast< sd::View *>( mpSdView) );
- Application::GetSolarMutex().acquire();
+ SolarMutexGuard aSolarGuard;
ObjectReleased();
@@ -175,7 +172,6 @@ SdTransferable::~SdTransferable()
delete mpVDev;
delete mpObjDesc;
- Application::GetSolarMutex().release();
}
// -----------------------------------------------------------------------------
@@ -313,7 +309,7 @@ void SdTransferable::CreateData()
if( !maDocShellRef.Is() )
{
- DBG_ERROR( "SdTransferable::CreateData(), failed to create a model with persist, clipboard operation will fail for OLE objects!" );
+ OSL_FAIL( "SdTransferable::CreateData(), failed to create a model with persist, clipboard operation will fail for OLE objects!" );
mbOwnDocument = sal_True;
}
@@ -604,10 +600,6 @@ sal_Bool SdTransferable::GetData( const DataFlavor& rFlavor )
// -----------------------------------------------------------------------------
-/* testcode
-#include <sfx2/docfile.hxx>
-*/
-
sal_Bool SdTransferable::WriteObject( SotStorageStreamRef& rxOStm, void* pObject, sal_uInt32 nObjectType, const DataFlavor& )
{
sal_Bool bRet = sal_False;
@@ -633,23 +625,12 @@ sal_Bool SdTransferable::WriteObject( SotStorageStreamRef& rxOStm, void* pObject
rxOStm->Commit();
}
- /* testcode
- {
- const rtl::OUString aURL( RTL_CONSTASCII_USTRINGPARAM( "file:///e:/test.xml" ) );
- SfxMedium aMedium( aURL, STREAM_WRITE | STREAM_TRUNC, sal_True );
- aMedium.IsRemote();
- com::sun::star::uno::Reference<com::sun::star::io::XOutputStream> xDocOut( new utl::OOutputStreamWrapper( *aMedium.GetOutStream() ) );
- if( SvxDrawingLayerExport( pDoc, xDocOut, xComponent, (pDoc->GetDocumentType() == DOCUMENT_TYPE_IMPRESS) ? "com.sun.star.comp.Impress.XMLClipboardExporter" : "com.sun.star.comp.DrawingLayer.XMLExporter" ) )
- aMedium.Commit();
- }
- */
-
xComponent->dispose();
bRet = ( rxOStm->GetError() == ERRCODE_NONE );
}
catch( Exception& )
{
- DBG_ERROR( "sd::SdTransferable::WriteObject(), exception catched!" );
+ OSL_FAIL( "sd::SdTransferable::WriteObject(), exception catched!" );
bRet = sal_False;
}
}
@@ -741,7 +722,6 @@ void SdTransferable::SetPageBookmarks( const List& rPageBookmarks, sal_Bool bPer
if( mpSdViewIntern )
mpSdViewIntern->HideSdrPage();
- // #116168#
mpSdDrawDocument->ClearModel(sal_False);
mpPageDocShell = NULL;
@@ -798,22 +778,14 @@ sal_Int64 SAL_CALL SdTransferable::getSomething( const ::com::sun::star::uno::Se
return nRet;
}
-// -----------------------------------------------------------------------------
+namespace
+{
+ class theSdTransferableUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSdTransferableUnoTunnelId > {};
+}
const ::com::sun::star::uno::Sequence< sal_Int8 >& SdTransferable::getUnoTunnelId()
{
- static ::com::sun::star::uno::Sequence< sal_Int8 > aSeq;
-
- if( !aSeq.getLength() )
- {
- static osl::Mutex aCreateMutex;
- osl::MutexGuard aGuard( aCreateMutex );
-
- aSeq.realloc( 16 );
- rtl_createUuid( reinterpret_cast< sal_uInt8* >( aSeq.getArray() ), 0, sal_True );
- }
-
- return aSeq;
+ return theSdTransferableUnoTunnelId::get().getSeq();
}
// -----------------------------------------------------------------------------
@@ -879,3 +851,5 @@ sal_Bool SdTransferable::SetTableRTF( SdDrawDocument* pModel, const DataFlavor&
return sal_False;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/strings.src b/sd/source/ui/app/strings.src
index e863f28d6..e863f28d6 100755..100644
--- a/sd/source/ui/app/strings.src
+++ b/sd/source/ui/app/strings.src
diff --git a/sd/source/ui/app/tbxww.cxx b/sd/source/ui/app/tbxww.cxx
index 62072d66f..e2562e9d7 100755..100644
--- a/sd/source/ui/app/tbxww.cxx
+++ b/sd/source/ui/app/tbxww.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -34,9 +35,7 @@
#include <svx/grafctrl.hxx>
#include <svl/cjkoptions.hxx>
#include <sfx2/viewsh.hxx>
-#ifndef _SFX_IMAGEMGR_HXX
#include <sfx2/imagemgr.hxx>
-#endif
#include <rtl/ustring.hxx>
#include <rtl/ustrbuf.hxx>
@@ -56,140 +55,6 @@ SFX_IMPL_TOOLBOX_CONTROL( SdTbxControl, TbxImageItem )
/*************************************************************************
|*
-|* PopUp-Window
-|*
-\************************************************************************/
-/*
-SdPopupWindowTbx::SdPopupWindowTbx( sal_uInt16 nId, WindowAlign eAlign,
- SdResId aRIdWin, SdResId aRIdTbx,
- SfxBindings& rBindings ) :
- SfxPopupWindow ( nId, aRIdWin, rBindings ),
- aTbx ( this, GetBindings(), aRIdTbx ),
- aSdResIdWin ( aRIdWin ),
- aSdResIdTbx ( aRIdTbx ),
- eTbxAlign ( eAlign )
-{
- aTbx.UseDefault();
- aSelectLink = aTbx.GetToolBox().GetSelectHdl();
- aTbx.GetToolBox().SetSelectHdl( LINK( this, SdPopupWindowTbx, TbxSelectHdl ) );
-
- FreeResource();
-
- if( ( eAlign == WINDOWALIGN_TOP ) || ( eAlign == WINDOWALIGN_BOTTOM ) )
- {
- if ( aSdResIdWin.GetId() != RID_TEXT )
- aTbx.GetToolBox().SetAlign( WINDOWALIGN_LEFT );
-
- SetText( String() );
- }
-
- AdaptToCTL();
-}
-
-
-void SdPopupWindowTbx::AdaptToCTL (void)
-{
- Size aSize = aTbx.CalcWindowSizePixel();
- if (aSdResIdWin.GetId() == RID_TEXT)
- {
- SvtCJKOptions aCJKOptions;
- if ( ! aCJKOptions.IsVerticalTextEnabled())
- {
- ToolBox& aToolBox = aTbx.GetToolBox();
-
- // Iterate over all tool box items and remove those that are
- // specific to complex text layout.
- sal_uInt16 i=0;
- while (i < aToolBox.GetItemCount())
- {
- sal_uInt16 nIndex = aToolBox.GetItemId(i);
- switch (nIndex)
- {
- case 0: // Line break.
- case SID_ATTR_CHAR_VERTICAL:
- case SID_TEXT_FITTOSIZE_VERTICAL:
- case SID_DRAW_CAPTION_VERTICAL:
- case SID_DRAW_FONTWORK_VERTICAL:
- aToolBox.RemoveItem (i);
- break;
-
- default:
- // Leave the item unmodified. Advance to the next one.
- i+=1;
- }
- }
- aToolBox.RecalcItems();
- // Why is this necessary?
- aToolBox.SetLineCount(1);
- sal_uInt16 nLineCount = aToolBox.GetLineCount();
- aSize = aToolBox.CalcWindowSizePixel(nLineCount);
- }
- }
- aTbx.SetPosSizePixel( Point(), aSize );
- SetOutputSizePixel( aSize );
-}
-*/
-
-/*-------------------------------------------------------------------------*/
-/*
-SdPopupWindowTbx::~SdPopupWindowTbx()
-{
-}
-*/
-/*-------------------------------------------------------------------------*/
-/*
-SfxPopupWindow* SdPopupWindowTbx::Clone() const
-{
- SfxBindings& rBindings = (SfxBindings&)GetBindings();
-
- return( new SdPopupWindowTbx( GetId(), eTbxAlign,
- aSdResIdWin, aSdResIdTbx, rBindings ) );
-
- //return( SfxPopupWindow::Clone() );
-}
-*/
-/*-------------------------------------------------------------------------*/
-/*
-void SdPopupWindowTbx::Update()
-{
- AdaptToCTL();
-
- ToolBox *pBox = &aTbx.GetToolBox();
- aTbx.Activate( pBox );
- aTbx.Deactivate( pBox );
-}
-*/
-/*-------------------------------------------------------------------------*/
-/*
-void SdPopupWindowTbx::PopupModeEnd()
-{
- aTbx.GetToolBox().EndSelection();
-
- SfxPopupWindow::PopupModeEnd();
-}
-*/
-/*-------------------------------------------------------------------------*/
-/*
-IMPL_LINK( SdPopupWindowTbx, TbxSelectHdl, ToolBox*, pBox)
-{
- if( IsInPopupMode() )
- EndPopupMode();
-
- aSelectLink.Call( &aTbx.GetToolBox() );
-
- if ( pBox->GetModifier() & KEY_MOD1 )
- {
- // #99013# if selected with control key, return focus to current view
- Window* pShellWnd = SfxViewShell::Current()->GetWindow();
- if ( pShellWnd )
- pShellWnd->GrabFocus();
- }
-
- return( 0L );
-}
-*/
-/*************************************************************************
-|*
|* Klasse fuer Toolbox
|*
\************************************************************************/
@@ -289,9 +154,8 @@ void SdTbxControl::StateChanged( sal_uInt16 nSId,
if( eState == SFX_ITEM_AVAILABLE )
{
TbxImageItem* pItem = PTR_CAST( TbxImageItem, pState );
- //DBG_ASSERT( pItem, "TbxImageItem erwartet!" );
// Im StarDesktop kann jetzt auch ein anderes Item ankommen,
- // das nicht ausgewertet werden darf (#33802# und #33838#)
+ // das nicht ausgewertet werden darf
if( pItem )
{
ToolBox& rTbx = GetToolBox();
@@ -305,10 +169,10 @@ void SdTbxControl::StateChanged( sal_uInt16 nSId,
{
rtl::OUString aSlotURL( RTL_CONSTASCII_USTRINGPARAM( "slot:" ));
aSlotURL += rtl::OUString::valueOf( sal_Int32( nImage ));
- Image aImage = GetImage( m_xFrame,
+ Image aImage = GetImage( m_xFrame,
aSlotURL,
- hasBigImages(),
- GetToolBox().GetSettings().GetStyleSettings().GetHighContrastMode() );
+ hasBigImages()
+ );
// !-Operator prueft, ob Image nicht vorhanden ist
if( !!aImage )
@@ -460,9 +324,6 @@ sal_Bool SdTbxControl::IsCheckable( sal_uInt16 nSId )
case SID_CONNECTOR_LINES_CIRCLE_END:
case SID_CONNECTOR_LINES_CIRCLES:
-
-
- //case SID_ZOOM_OUT:
return( sal_True );
}
return( sal_False );
@@ -470,3 +331,4 @@ sal_Bool SdTbxControl::IsCheckable( sal_uInt16 nSId )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/app/tmplctrl.cxx b/sd/source/ui/app/tmplctrl.cxx
index 3a3e57cd9..83824d218 100755..100644
--- a/sd/source/ui/app/tmplctrl.cxx
+++ b/sd/source/ui/app/tmplctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -158,3 +159,4 @@ void SdTemplateControl::Command( const CommandEvent& rCEvt )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/controller/makefile.mk b/sd/source/ui/controller/makefile.mk
deleted file mode 100755
index 4e37fbd5e..000000000
--- a/sd/source/ui/controller/makefile.mk
+++ /dev/null
@@ -1,54 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2008 by Sun Microsystems, Inc.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# $RCSfile: makefile.mk,v $
-#
-# $Revision: 1.21 $
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=controller
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/slidelayoutcontroller.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/ui/controller/slidelayoutcontroller.cxx b/sd/source/ui/controller/slidelayoutcontroller.cxx
index c804fcf07..b6e6e29cc 100644
--- a/sd/source/ui/controller/slidelayoutcontroller.cxx
+++ b/sd/source/ui/controller/slidelayoutcontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -23,7 +24,7 @@
* <http://www.openoffice.org/license.html>
* for a copy of the LGPLv3 License.
*
- ************************************************************************/
+ ************************************************************************/
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
@@ -39,7 +40,7 @@
#include <memory>
#include <boost/scoped_ptr.hpp>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <vcl/toolbox.hxx>
@@ -102,7 +103,6 @@ private:
struct snewfoil_value_info
{
sal_uInt16 mnBmpResId;
- sal_uInt16 mnHCBmpResId;
sal_uInt16 mnStrResId;
WritingMode meWritingMode;
AutoLayout maAutoLayout;
@@ -110,68 +110,61 @@ struct snewfoil_value_info
static snewfoil_value_info notes[] =
{
- {BMP_FOILN_01, BMP_FOILN_01_H, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
- AUTOLAYOUT_NOTES},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
+ {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB, AUTOLAYOUT_NOTES},
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
};
static snewfoil_value_info handout[] =
{
- {BMP_FOILH_01, BMP_FOILH_01_H, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT1},
- {BMP_FOILH_02, BMP_FOILH_02_H, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT2},
- {BMP_FOILH_03, BMP_FOILH_03_H, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT3},
- {BMP_FOILH_04, BMP_FOILH_04_H, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT4},
- {BMP_FOILH_06, BMP_FOILH_06_H, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT6},
- {BMP_FOILH_09, BMP_FOILH_09_H, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB,
- AUTOLAYOUT_HANDOUT9},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
+ {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT1},
+ {BMP_FOILH_02, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT2},
+ {BMP_FOILH_03, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT3},
+ {BMP_FOILH_04, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT4},
+ {BMP_FOILH_06, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT6},
+ {BMP_FOILH_09, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT9},
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
};
static snewfoil_value_info standard[] =
{
- {BMP_LAYOUT_EMPTY, BMP_LAYOUT_EMPTY_H, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB, AUTOLAYOUT_NONE},
- {BMP_LAYOUT_HEAD03, BMP_LAYOUT_HEAD03_H, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB, AUTOLAYOUT_TITLE},
- {BMP_LAYOUT_HEAD02, BMP_LAYOUT_HEAD02_H, STR_AUTOLAYOUT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_ENUM},
- {BMP_LAYOUT_HEAD02A, BMP_LAYOUT_HEAD02A_H, STR_AUTOLAYOUT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2TEXT},
- {BMP_LAYOUT_HEAD01, BMP_LAYOUT_HEAD01_H, STR_AUTOLAYOUT_ONLY_TITLE, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TITLE},
- {BMP_LAYOUT_TEXTONLY, BMP_LAYOUT_TEXTONLY_H, STR_AUTOLAYOUT_ONLY_TEXT, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TEXT},
- {BMP_LAYOUT_HEAD03B, BMP_LAYOUT_HEAD03B_H, STR_AUTOLAYOUT_2CONTENT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2OBJTEXT},
- {BMP_LAYOUT_HEAD03C, BMP_LAYOUT_HEAD03C_H, STR_AUTOLAYOUT_CONTENT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_TEXT2OBJ},
- {BMP_LAYOUT_HEAD03A, BMP_LAYOUT_HEAD03A_H, STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT},
- {BMP_LAYOUT_HEAD02B, BMP_LAYOUT_HEAD02B_H, STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT},
- {BMP_LAYOUT_HEAD04, BMP_LAYOUT_HEAD04_H, STR_AUTOLAYOUT_4CONTENT, WritingMode_LR_TB, AUTOLAYOUT_4OBJ},
- {BMP_LAYOUT_HEAD06, BMP_LAYOUT_HEAD06_H, STR_AUTOLAYOUT_6CONTENT, WritingMode_LR_TB, AUTOLAYOUT_6CLIPART},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
+ {BMP_LAYOUT_EMPTY, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB, AUTOLAYOUT_NONE },
+ {BMP_LAYOUT_HEAD03, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB, AUTOLAYOUT_TITLE },
+ {BMP_LAYOUT_HEAD02, STR_AUTOLAYOUT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_ENUM },
+ {BMP_LAYOUT_HEAD02A, STR_AUTOLAYOUT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2TEXT },
+ {BMP_LAYOUT_HEAD01, STR_AUTOLAYOUT_ONLY_TITLE, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TITLE },
+ {BMP_LAYOUT_TEXTONLY, STR_AUTOLAYOUT_ONLY_TEXT, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TEXT },
+ {BMP_LAYOUT_HEAD03B, STR_AUTOLAYOUT_2CONTENT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2OBJTEXT },
+ {BMP_LAYOUT_HEAD03C, STR_AUTOLAYOUT_CONTENT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_TEXT2OBJ },
+ {BMP_LAYOUT_HEAD03A, STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT },
+ {BMP_LAYOUT_HEAD02B, STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT },
+ {BMP_LAYOUT_HEAD04, STR_AUTOLAYOUT_4CONTENT, WritingMode_LR_TB, AUTOLAYOUT_4OBJ },
+ {BMP_LAYOUT_HEAD06, STR_AUTOLAYOUT_6CONTENT, WritingMode_LR_TB, AUTOLAYOUT_6CLIPART },
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
};
static snewfoil_value_info v_standard[] =
{
// vertical
- {BMP_LAYOUT_VERTICAL02, BMP_LAYOUT_VERTICAL02_H, STR_AL_VERT_TITLE_TEXT_CHART, WritingMode_TB_RL,AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART},
- {BMP_LAYOUT_VERTICAL01, BMP_LAYOUT_VERTICAL01_H, STR_AL_VERT_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE},
- {BMP_LAYOUT_HEAD02, BMP_LAYOUT_HEAD02_H, STR_AL_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE},
- {BMP_LAYOUT_HEAD02A, BMP_LAYOUT_HEAD02A_H, STR_AL_TITLE_VERT_OUTLINE_CLIPART, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
+ {BMP_LAYOUT_VERTICAL02, STR_AL_VERT_TITLE_TEXT_CHART, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART },
+ {BMP_LAYOUT_VERTICAL01, STR_AL_VERT_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE },
+ {BMP_LAYOUT_HEAD02, STR_AL_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE },
+ {BMP_LAYOUT_HEAD02A, STR_AL_TITLE_VERT_OUTLINE_CLIPART, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART },
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
};
// -----------------------------------------------------------------------
-static void fillLayoutValueSet( ValueSet* pValue, snewfoil_value_info* pInfo, const bool bHighContrast )
+static void fillLayoutValueSet( ValueSet* pValue, snewfoil_value_info* pInfo )
{
Size aLayoutItemSize;
for( ; pInfo->mnBmpResId; pInfo++ )
{
- String aText( SdResId( pInfo->mnStrResId ) );
- BitmapEx aBmp( SdResId( (bHighContrast ? pInfo->mnHCBmpResId : pInfo->mnBmpResId) ) );
+ String aText( SdResId( pInfo->mnStrResId ) );
+ BitmapEx aBmp( SdResId( pInfo->mnBmpResId ) );
pValue->InsertItem( static_cast<sal_uInt16>(pInfo->maAutoLayout)+1, aBmp, aText );
- aLayoutItemSize.Width() = std::max( aLayoutItemSize.Width(), aBmp.GetSizePixel().Width() );
+ aLayoutItemSize.Width() = std::max( aLayoutItemSize.Width(), aBmp.GetSizePixel().Width() );
aLayoutItemSize.Height() = std::max( aLayoutItemSize.Height(), aBmp.GetSizePixel().Height() );
}
@@ -208,7 +201,6 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
String aTitle1( SdResId( STR_GLUE_ESCDIR_HORZ ) );
String aTitle2( SdResId( STR_GLUE_ESCDIR_VERT ) );
- const bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
SvtLanguageOptions aLanguageOptions;
const bool bVerticalEnabled = aLanguageOptions.IsVerticalTextEnabled();
@@ -229,7 +221,7 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
mpLayoutSet1->SetColCount( nColCount );
- fillLayoutValueSet( mpLayoutSet1, pInfo, bHighContrast );
+ fillLayoutValueSet( mpLayoutSet1, pInfo );
Size aSize( mpLayoutSet1->GetOutputSizePixel() );
aSize.Width() += (mpLayoutSet1->GetColCount() + 1) * LAYOUT_BORDER_PIX;
@@ -243,14 +235,13 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
if( bVerticalEnabled && (eMode == DrawViewMode_DRAW) )
{
mpLayoutSet2 = new ValueSet( this, WB_TABSTOP | WB_MENUSTYLEVALUESET | WB_FLATVALUESET | WB_NOBORDER | WB_NO_DIRECTSELECT );
- // mpLayoutSet2->SetHelpId( HID_VALUESET_EXTRUSION_LIGHTING );
mpLayoutSet2->SetSelectHdl( LINK( this, LayoutToolbarMenu, SelectHdl ) );
mpLayoutSet2->SetColCount( 4 );
mpLayoutSet2->EnableFullItemMode( sal_False );
mpLayoutSet2->SetColor( GetControlBackground() );
- fillLayoutValueSet( mpLayoutSet2, &v_standard[0], bHighContrast );
+ fillLayoutValueSet( mpLayoutSet2, &v_standard[0] );
aSize = mpLayoutSet2->GetOutputSizePixel();
aSize.Width() += (mpLayoutSet2->GetColCount() + 1) * LAYOUT_BORDER_PIX;
@@ -273,7 +264,7 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
sSlotStr = OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:DuplicatePage" ) );
else
sSlotStr = OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:Undo" ) );
- aSlotImage = ::GetImage( mxFrame, sSlotStr, sal_False, bHighContrast );
+ aSlotImage = ::GetImage( mxFrame, sSlotStr, sal_False );
String sSlotTitle;
if( bInsertPage )
@@ -417,3 +408,5 @@ Sequence< OUString > SAL_CALL SlideLayoutController::getSupportedServiceNames(
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/controller/slidelayoutcontroller.hxx b/sd/source/ui/controller/slidelayoutcontroller.hxx
index 8d1e6aee6..be70c0289 100644
--- a/sd/source/ui/controller/slidelayoutcontroller.hxx
+++ b/sd/source/ui/controller/slidelayoutcontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ private:
}
#endif // __SD_SLIDELAYOUTCONTROLLER_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/AnimationChildWindow.cxx b/sd/source/ui/dlg/AnimationChildWindow.cxx
index 5b84fc45c..c4c5981b2 100755..100644
--- a/sd/source/ui/dlg/AnimationChildWindow.cxx
+++ b/sd/source/ui/dlg/AnimationChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,21 +62,10 @@ AnimationChildWindow::AnimationChildWindow(
eChildAlignment = SFX_ALIGN_NOALIGNMENT;
pAnimWin->Initialize( pInfo );
- /*
- if ( pInfo->aSize.Width() != 0 && pInfo->aSize.Height() != 0 )
- {
- pWindow->SetPosSizePixel( pInfo->aPos, pInfo->aSize );
- }
- else
- pWindow->SetPosPixel(SFX_APPWINDOW->OutputToScreenPixel(
- SFX_APPWINDOW->GetClientAreaPixel().TopLeft()));
- if ( pInfo->nFlags & SFX_CHILDWIN_ZOOMIN )
- pAnimWin->ZoomIn();
-
- pAnimWin->aFltWinSize = pWindow->GetSizePixel();
- */
SetHideNotDelete( sal_True );
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/LayerDialogChildWindow.cxx b/sd/source/ui/dlg/LayerDialogChildWindow.cxx
index a8c92efd4..00fdc406b 100755..100644
--- a/sd/source/ui/dlg/LayerDialogChildWindow.cxx
+++ b/sd/source/ui/dlg/LayerDialogChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,3 +83,5 @@ LayerDialogChildWindow::~LayerDialogChildWindow (void)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/LayerDialogContent.cxx b/sd/source/ui/dlg/LayerDialogContent.cxx
index d5f04f9f3..ecd1ec3c7 100755..100644
--- a/sd/source/ui/dlg/LayerDialogContent.cxx
+++ b/sd/source/ui/dlg/LayerDialogContent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -104,3 +105,5 @@ void LayerDialogContent::Resize (void)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/LayerTabBar.cxx b/sd/source/ui/dlg/LayerTabBar.cxx
index cd7b9e356..af5ccf16a 100755..100644
--- a/sd/source/ui/dlg/LayerTabBar.cxx
+++ b/sd/source/ui/dlg/LayerTabBar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,20 +97,12 @@ LayerTabBar::~LayerTabBar()
{
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::Select()
{
SfxDispatcher* pDispatcher = pDrViewSh->GetViewFrame()->GetDispatcher();
pDispatcher->Execute(SID_SWITCHLAYER, SFX_CALLMODE_ASYNCHRON);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::MouseButtonDown(const MouseEvent& rMEvt)
{
sal_Bool bSetPageID=sal_False;
@@ -143,10 +136,6 @@ void LayerTabBar::MouseButtonDown(const MouseEvent& rMEvt)
TabBar::MouseButtonDown(rMEvt);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::DoubleClick()
{
if (GetCurPageId() != 0)
@@ -202,10 +191,6 @@ sal_Int8 LayerTabBar::ExecuteDrop( const ExecuteDropEvent& rEvt )
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::Command(const CommandEvent& rCEvt)
{
if ( rCEvt.GetCommand() == COMMAND_CONTEXTMENU )
@@ -215,10 +200,6 @@ void LayerTabBar::Command(const CommandEvent& rCEvt)
}
}
-
-/*************************************************************************
-|*
-\************************************************************************/
long LayerTabBar::StartRenaming()
{
sal_Bool bOK = sal_True;
@@ -249,10 +230,6 @@ long LayerTabBar::StartRenaming()
return(bOK);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
long LayerTabBar::AllowRenaming()
{
sal_Bool bOK = sal_True;
@@ -294,10 +271,6 @@ long LayerTabBar::AllowRenaming()
return(bOK);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::EndRenaming()
{
if( !IsEditModeCanceled() )
@@ -347,11 +320,6 @@ void LayerTabBar::EndRenaming()
}
}
-
-/*************************************************************************
-|*
-\************************************************************************/
-
void LayerTabBar::ActivatePage()
{
if ( /*IsInSwitching*/ 1 && pDrViewSh!=NULL)
@@ -381,3 +349,5 @@ void LayerTabBar::SendDeactivatePageEvent (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/NavigatorChildWindow.cxx b/sd/source/ui/dlg/NavigatorChildWindow.cxx
index a769f898f..9fe363e7f 100755..100644
--- a/sd/source/ui/dlg/NavigatorChildWindow.cxx
+++ b/sd/source/ui/dlg/NavigatorChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ NavigatorChildWindow::NavigatorChildWindow (
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/PaneChildWindows.cxx b/sd/source/ui/dlg/PaneChildWindows.cxx
index ab4e330d6..138e9559c 100755..100644
--- a/sd/source/ui/dlg/PaneChildWindows.cxx
+++ b/sd/source/ui/dlg/PaneChildWindows.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -161,7 +162,7 @@ ToolPanelChildWindow::ToolPanelChildWindow( ::Window* i_pParentWindow, sal_uInt1
// activates the task pane, so it is really filled with content (in opposite to the other SFX applications, the
// child window registered for SID_TASKPANE is not responsible for its content, but here in SD, it's the ToolPanelViewShell
// which has this responsibility. And this view shell is created implicitly via the resource framework.)
- // #i113788# / 2010-09-03 / frank.schoenheit@oracle.com
+ // #i113788#
SfxDockingWindow* pDockingWindow = dynamic_cast< SfxDockingWindow* >( GetWindow() );
ViewShellBase* pViewShellBase = ViewShellBase::GetViewShellBase( pDockingWindow->GetBindings().GetDispatcher()->GetFrame() );
ENSURE_OR_RETURN_VOID( pViewShellBase != NULL, "ToolPanelChildWindow::ToolPanelChildWindow: no view shell access!" );
@@ -232,3 +233,5 @@ void ToolPanelChildWindow::ActivateToolPanel( const ::rtl::OUString& i_rPanelURL
}
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/PaneDockingWindow.cxx b/sd/source/ui/dlg/PaneDockingWindow.cxx
index f05e82323..914aa7020 100644
--- a/sd/source/ui/dlg/PaneDockingWindow.cxx
+++ b/sd/source/ui/dlg/PaneDockingWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -145,3 +146,5 @@ PaneDockingWindow::Orientation PaneDockingWindow::GetOrientation (void) const
}
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/PaneShells.cxx b/sd/source/ui/dlg/PaneShells.cxx
index 3b3589d66..7b43450ab 100755..100644
--- a/sd/source/ui/dlg/PaneShells.cxx
+++ b/sd/source/ui/dlg/PaneShells.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,7 +61,7 @@ TYPEINIT1(LeftImpressPaneShell, SfxShell);
LeftImpressPaneShell::LeftImpressPaneShell (void)
: SfxShell()
{
- SetName(rtl::OUString::createFromAscii("LeftImpressPane"));
+ SetName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LeftImpressPane")));
}
@@ -96,7 +97,7 @@ TYPEINIT1(LeftDrawPaneShell, SfxShell);
LeftDrawPaneShell::LeftDrawPaneShell (void)
: SfxShell()
{
- SetName(rtl::OUString::createFromAscii("LeftDrawPane"));
+ SetName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LeftDrawPane")));
}
@@ -129,7 +130,7 @@ TYPEINIT1( ToolPanelPaneShell, SfxShell );
ToolPanelPaneShell::ToolPanelPaneShell()
:SfxShell()
{
- SetName( ::rtl::OUString::createFromAscii( "ToolPanel" ) );
+ SetName( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "ToolPanel" )) );
}
ToolPanelPaneShell::~ToolPanelPaneShell(void)
@@ -137,3 +138,5 @@ ToolPanelPaneShell::~ToolPanelPaneShell(void)
}
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/SpellDialogChildWindow.cxx b/sd/source/ui/dlg/SpellDialogChildWindow.cxx
index cdfaa9b73..c74a2829d 100755..100644
--- a/sd/source/ui/dlg/SpellDialogChildWindow.cxx
+++ b/sd/source/ui/dlg/SpellDialogChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -211,3 +212,5 @@ void SpellDialogChildWindow::ProvideOutliner (void)
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/TemplateScanner.cxx b/sd/source/ui/dlg/TemplateScanner.cxx
index 5ba718381..360d9e645 100644
--- a/sd/source/ui/dlg/TemplateScanner.cxx
+++ b/sd/source/ui/dlg/TemplateScanner.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,13 +31,11 @@
#include "TemplateScanner.hxx"
-#ifndef _COMPHELPER_SERVICEFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#include <comphelper/documentconstants.hxx>
#include <tools/debug.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <com/sun/star/frame/XDocumentTemplates.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
@@ -52,19 +51,19 @@ using namespace ::com::sun::star::uno;
namespace {
-const ::rtl::OUString TITLE = ::rtl::OUString::createFromAscii ("Title");
-const ::rtl::OUString TARGET_DIR_URL = ::rtl::OUString::createFromAscii ("TargetDirURL");
-const ::rtl::OUString DESCRIPTION = ::rtl::OUString::createFromAscii ("TypeDescription");
-const ::rtl::OUString TARGET_URL = ::rtl::OUString::createFromAscii ("TargetURL");
+const ::rtl::OUString TITLE(RTL_CONSTASCII_USTRINGPARAM ("Title"));
+const ::rtl::OUString TARGET_DIR_URL(RTL_CONSTASCII_USTRINGPARAM ("TargetDirURL"));
+const ::rtl::OUString DESCRIPTION(RTL_CONSTASCII_USTRINGPARAM ("TypeDescription"));
+const ::rtl::OUString TARGET_URL(RTL_CONSTASCII_USTRINGPARAM ("TargetURL"));
-const ::rtl::OUString DOCTEMPLATES = ::rtl::OUString::createFromAscii ("com.sun.star.frame.DocumentTemplates");
+const ::rtl::OUString DOCTEMPLATES(RTL_CONSTASCII_USTRINGPARAM ("com.sun.star.frame.DocumentTemplates"));
// These strings are used to find impress templates in the tree of
// template files. Should probably be determined dynamically.
-const ::rtl::OUString IMPRESS_BIN_TEMPLATE = ::rtl::OUString::createFromAscii ("application/vnd.stardivision.impress");
+const ::rtl::OUString IMPRESS_BIN_TEMPLATE(RTL_CONSTASCII_USTRINGPARAM ("application/vnd.stardivision.impress"));
const ::rtl::OUString IMPRESS_XML_TEMPLATE = MIMETYPE_VND_SUN_XML_IMPRESS;
// The following id comes from the bugdoc in #i2764#.
-const ::rtl::OUString IMPRESS_XML_TEMPLATE_B = ::rtl::OUString::createFromAscii ("Impress 2.0");
+const ::rtl::OUString IMPRESS_XML_TEMPLATE_B(RTL_CONSTASCII_USTRINGPARAM ("Impress 2.0"));
const ::rtl::OUString IMPRESS_XML_TEMPLATE_OASIS = MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION;
@@ -90,9 +89,11 @@ public:
// Reference<sdbc::XResultSet> mxFolderResultSet;
Reference<com::sun::star::ucb::XCommandEnvironment> mxFolderEnvironment;
- class Comparator { public:
- bool operator() (const FolderDescriptor& r1, const FolderDescriptor& r2)
- { return r1.mnPriority < r2.mnPriority; }
+ class Comparator
+ {
+ public:
+ bool operator() (const FolderDescriptor& r1, const FolderDescriptor& r2) const
+ { return r1.mnPriority < r2.mnPriority; }
};
};
@@ -105,19 +106,19 @@ int Classify (const ::rtl::OUString&, const ::rtl::OUString& rsURL)
if (rsURL.getLength() == 0)
nPriority = 100;
- else if (rsURL.indexOf(::rtl::OUString::createFromAscii("presnt"))>=0)
+ else if (rsURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("presnt")))>=0)
{
nPriority = 30;
}
- else if (rsURL.indexOf(::rtl::OUString::createFromAscii("layout"))>=0)
+ else if (rsURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("layout")))>=0)
{
nPriority = 20;
}
- else if (rsURL.indexOf(::rtl::OUString::createFromAscii("educate"))>=0)
+ else if (rsURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("educate")))>=0)
{
nPriority = 40;
}
- else if (rsURL.indexOf(::rtl::OUString::createFromAscii("finance"))>=0)
+ else if (rsURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("finance")))>=0)
{
nPriority = 40;
}
@@ -170,7 +171,7 @@ TemplateScanner::~TemplateScanner (void)
// Delete all entries of the template list that have not been
// transferred to another object.
std::vector<TemplateDir*>::iterator I;
- for (I=maFolderList.begin(); I!=maFolderList.end(); I++)
+ for (I=maFolderList.begin(); I!=maFolderList.end(); ++I)
if (*I != NULL)
delete *I;
}
@@ -279,7 +280,7 @@ TemplateScanner::State TemplateScanner::ScanEntry (void)
}
else
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
maFolderList.push_back(mpTemplateDirectory);
}
@@ -491,3 +492,5 @@ const TemplateEntry* TemplateScanner::GetLastAddedEntry (void) const
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/animobjs.cxx b/sd/source/ui/dlg/animobjs.cxx
index 312610c8c..4d6daeb87 100755..100644
--- a/sd/source/ui/dlg/animobjs.cxx
+++ b/sd/source/ui/dlg/animobjs.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -55,9 +56,7 @@
#include "res_bmp.hrc"
#include "ViewShell.hxx"
-#ifndef _SV_SVAPP_HXX_
#include <vcl/svapp.hxx>
-#endif
#include <string>
#include <algorithm>
@@ -117,7 +116,6 @@ void SdDisplay::Paint( const Rectangle& )
aPt.Y() = ( aSize.Height() - aBmpSize.Height() ) / 2;
aBitmapEx.Draw( this, aPt, aBmpSize );
- //DrawBitmap( aPt, aBmpSize, *pBitmap );
}
// -----------------------------------------------------------------------
@@ -135,8 +133,8 @@ void SdDisplay::DataChanged( const DataChangedEvent& rDCEvt )
{
const StyleSettings& rStyles = Application::GetSettings().GetStyleSettings();
SetBackground( Wallpaper( Color( rStyles.GetFieldColor() ) ) );
- SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode()
- ? ViewShell::OUTPUT_DRAWMODE_CONTRAST
+ SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode()
+ ? ViewShell::OUTPUT_DRAWMODE_CONTRAST
: ViewShell::OUTPUT_DRAWMODE_COLOR );
}
}
@@ -182,11 +180,6 @@ AnimationWindow::AnimationWindow( SfxBindings* pInBindings,
aCtlDisplay.SetAccessibleName(String (SdResId(STR_DISPLAY)));
FreeResource();
- aBtnGetOneObject.SetModeImage( Image( SdResId( IMG_GET1OBJECT_H ) ), BMP_COLOR_HIGHCONTRAST );
- aBtnGetAllObjects.SetModeImage( Image( SdResId( IMG_GETALLOBJECT_H ) ), BMP_COLOR_HIGHCONTRAST );
- aBtnRemoveBitmap.SetModeImage( Image( SdResId( IMG_REMOVEBMP_H ) ), BMP_COLOR_HIGHCONTRAST );
- aBtnRemoveAll.SetModeImage( Image( SdResId( IMG_REMOVEALLBMP_H ) ), BMP_COLOR_HIGHCONTRAST );
-
// neues Dokument mit Seite erzeugen
pMyDoc = new SdDrawDocument(DOCUMENT_TYPE_IMPRESS, NULL);
SdPage* pPage = (SdPage*) pMyDoc->AllocPage(sal_False);
@@ -435,7 +428,7 @@ IMPL_LINK( AnimationWindow, ClickGetObjectHdl, void *, pBtn )
// Code jetzt in AddObj()
SfxBoolItem aItem( SID_ANIMATOR_ADD, sal_True );
- GetBindings().GetDispatcher()->Execute(
+ GetBindings().GetDispatcher()->Execute(
SID_ANIMATOR_ADD, SFX_CALLMODE_SLOT | SFX_CALLMODE_RECORD, &aItem, 0L );
return( 0L );
}
@@ -539,7 +532,7 @@ IMPL_LINK( AnimationWindow, ClickCreateGroupHdl, void *, EMPTYARG )
// Code jetzt in CreatePresObj()
SfxBoolItem aItem( SID_ANIMATOR_CREATE, sal_True );
- GetBindings().GetDispatcher()->Execute(
+ GetBindings().GetDispatcher()->Execute(
SID_ANIMATOR_CREATE, SFX_CALLMODE_SLOT | SFX_CALLMODE_RECORD, &aItem, 0L );
return( 0L );
}
@@ -603,10 +596,10 @@ void AnimationWindow::UpdateControl( sal_uLong nListPos, sal_Bool bDisableCtrls
const StyleSettings& rStyles = Application::GetSettings().GetStyleSettings();
aVD.SetBackground( Wallpaper( rStyles.GetFieldColor() ) );
aVD.SetDrawMode( rStyles.GetHighContrastMode()
- ? ViewShell::OUTPUT_DRAWMODE_CONTRAST
+ ? ViewShell::OUTPUT_DRAWMODE_CONTRAST
: ViewShell::OUTPUT_DRAWMODE_COLOR );
aVD.Erase();
- pObject->SingleObjectPainter( aVD ); // #110094#-17
+ pObject->SingleObjectPainter( aVD );
aBmp = BitmapEx( aVD.GetBitmap( aObjRect.TopLeft(), aObjSize ) );
}
@@ -639,8 +632,6 @@ void AnimationWindow::UpdateControl( sal_uLong nListPos, sal_Bool bDisableCtrls
}
else
{
- //aFiCount.SetText( String( SdResId( STR_NULL ) ) );
-
// Wenn kein Objekt in der Liste ist
aBtnFirst.Enable( sal_False );
aBtnReverse.Enable( sal_False );
@@ -748,7 +739,6 @@ Fraction AnimationWindow::GetScale()
void AnimationWindow::Resize()
{
- //if( !IsZoomedIn() )
if ( !IsFloatingMode() ||
!GetFloatingWindow()->IsRollUp() )
{
@@ -764,7 +754,6 @@ void AnimationWindow::Resize()
aCtlDisplay.SetOutputSizePixel( aDisplaySize );
Point aPt;
- // aPt.X() = aDiffSize.Width() / 2;
aPt.Y() = aDiffSize.Height();
// Verschieben der anderen Controls
@@ -842,8 +831,6 @@ void AnimationWindow::Resize()
aGrpAnimation.Show();
aSize = aWinSize;
-
- //aFltWinSize = GetSizePixel();
}
SfxDockingWindow::Resize();
}
@@ -860,7 +847,7 @@ sal_Bool AnimationWindow::Close()
{
SfxBoolItem aItem( SID_ANIMATION_OBJECTS, sal_False );
- GetBindings().GetDispatcher()->Execute(
+ GetBindings().GetDispatcher()->Execute(
SID_ANIMATION_OBJECTS, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD, &aItem, 0L );
SfxDockingWindow::Close();
@@ -1228,8 +1215,6 @@ void AnimationWindow::CreateAnimObj (::sd::View& rView )
break;
}
- //aRect.SetPos(aWindowCenter + Point(aOffset.Width(), aOffset.Height()));
- //pClone->SetSnapRect( aRect );
// SetSnapRect ist fuer Ellipsen leider nicht implementiert !!!
Point aMovePt( aWindowCenter + Point( aOffset.Width(), aOffset.Height() ) - aRect.TopLeft() );
Size aMoveSize( aMovePt.X(), aMovePt.Y() );
@@ -1290,7 +1275,7 @@ void AnimationWindow::DataChanged( const DataChangedEvent& rDCEvt )
AnimationControllerItem::AnimationControllerItem(
sal_uInt16 _nId,
AnimationWindow* pAnimWin,
- SfxBindings* _pBindings)
+ SfxBindings* _pBindings)
: SfxControllerItem( _nId, *_pBindings ),
pAnimationWin( pAnimWin )
{
@@ -1314,3 +1299,5 @@ void AnimationControllerItem::StateChanged( sal_uInt16 nSId,
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/animobjs.src b/sd/source/ui/dlg/animobjs.src
index e61321679..60fd6b751 100755..100644
--- a/sd/source/ui/dlg/animobjs.src
+++ b/sd/source/ui/dlg/animobjs.src
@@ -71,7 +71,6 @@ DockingWindow FLT_WIN_ANIMATION
Pos = MAP_APPFONT ( 6 + MIN_BUTTON_WIDTH , 100 ) ;
Size = MIN_BUTTON_SIZE
Symbol = IMAGEBUTTON_REVERSEPLAY ;
- /* ### ACHTUNG: Neuer Text in Resource? Rückwärts : R³ckwõrts */
QuickHelpText [ en-US ] = "Backwards" ;
};
ImageButton BTN_STOP
@@ -169,7 +168,6 @@ DockingWindow FLT_WIN_ANIMATION
< "1000" ; > ;
< "Max." ; > ;
};
- /* ### ACHTUNG: Neuer Text in Resource? Anzahl der Durchläufe : Anzahl der Durchlõufe */
QuickHelpText [ en-US ] = "Loop Count" ;
};
ImageButton BTN_GET_ONE_OBJECT
@@ -186,7 +184,6 @@ DockingWindow FLT_WIN_ANIMATION
MaskColor = IMAGE_MASK_STDCOLOR;
};
TabStop = TRUE ;
- /* ### ACHTUNG: Neuer Text in Resource? Objekt übernehmen : Objekt ³bernehmen */
QuickHelpText [ en-US ] = "Apply Object" ;
};
ImageButton BTN_GET_ALL_OBJECTS
@@ -203,7 +200,6 @@ DockingWindow FLT_WIN_ANIMATION
MaskColor = IMAGE_MASK_STDCOLOR;
};
TabStop = TRUE ;
- /* ### ACHTUNG: Neuer Text in Resource? Objekte einzeln übernehmen : Objekte einzeln ³bernehmen */
QuickHelpText [ en-US ] = "Apply Objects Individually" ;
};
ImageButton BTN_REMOVE_BITMAP
@@ -220,7 +216,6 @@ DockingWindow FLT_WIN_ANIMATION
MaskColor = IMAGE_MASK_STDCOLOR;
};
TabStop = TRUE ;
- /* ### ACHTUNG: Neuer Text in Resource? Aktuelles Bild löschen : Aktuelles Bild l÷schen */
QuickHelpText [ en-US ] = "Delete Current Image" ;
};
ImageButton BTN_REMOVE_ALL
@@ -237,7 +232,6 @@ DockingWindow FLT_WIN_ANIMATION
MaskColor = IMAGE_MASK_STDCOLOR;
};
TabStop = TRUE ;
- /* ### ACHTUNG: Neuer Text in Resource? Alle Bilder löschen : Alle Bilder l÷schen */
QuickHelpText [ en-US ] = "Delete All Images" ;
};
FixedText FT_COUNT
diff --git a/sd/source/ui/dlg/assclass.cxx b/sd/source/ui/dlg/assclass.cxx
index 4955aafbe..a299d39ab 100755..100644
--- a/sd/source/ui/dlg/assclass.cxx
+++ b/sd/source/ui/dlg/assclass.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -28,50 +29,37 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-
-#include <tools/list.hxx>
#include <tools/debug.hxx>
#include <vcl/ctrl.hxx>
#include "assclass.hxx"
-
Assistent::Assistent(int nNoOfPages)
+ : mnPages(nNoOfPages), mnCurrentPage(1)
{
- mnPages=nNoOfPages;
- if(mnPages>MAX_PAGES)
- {
- mnPages=MAX_PAGES;
- }
+ if(mnPages > MAX_PAGES)
+ mnPages = MAX_PAGES;
- mpPageStatus = new bool[mnPages];
+ mpPageStatus.reset(new bool[mnPages]);
- for(sal_uInt8 i=0;i<mnPages;i++)
- {
- mpPages[i]=new List();
- mpPageStatus[i] = sal_True;
- }
- mnCurrentPage=1;
+ for(int i=0; i < mnPages; ++i)
+ mpPageStatus[i] = true;
}
-
-
bool Assistent::InsertControl(int nDestPage,Control* pUsedControl)
{
DBG_ASSERT( (nDestPage > 0) && (nDestPage <= mnPages), "Seite nicht vorhanden!");
+
if((nDestPage>0)&&(nDestPage<=mnPages))
{
- mpPages[nDestPage-1]->Insert(pUsedControl,LIST_APPEND);
+ maPages[nDestPage-1].push_back(pUsedControl);
pUsedControl->Hide();
pUsedControl->Disable();
return true;
}
- else
- {
- return false;
- }
-}
+ return false;
+}
bool Assistent::NextPage()
{
@@ -84,6 +72,7 @@ bool Assistent::NextPage()
if(nPage <= mnPages)
return GotoPage(nPage);
}
+
return false;
}
@@ -109,88 +98,67 @@ bool Assistent::GotoPage(const int nPageToGo)
if((nPageToGo>0)&&(nPageToGo<=mnPages)&&mpPageStatus[nPageToGo-1])
{
- int i;
- Control* pCurControl;
int nIndex=mnCurrentPage-1;
- for(i=0;i<(int)mpPages[nIndex]->Count();i++)
+ std::vector<Control*>::iterator iter = maPages[nIndex].begin();
+ std::vector<Control*>::iterator iterEnd = maPages[nIndex].end();
+
+ for(; iter != iterEnd; ++iter)
{
- pCurControl=(Control*)mpPages[nIndex]->GetObject(i);
- pCurControl->Disable();
- pCurControl->Hide();
- //schaltet die Controls der vorherigen Seite
- //zurueck
+ (*iter)->Disable();
+ (*iter)->Hide();
}
+
mnCurrentPage=nPageToGo;
nIndex=mnCurrentPage-1;
- for(i=0;i<(int)mpPages[nIndex]->Count();i++)
- {
- pCurControl=(Control*)mpPages[nIndex]->GetObject(i);
- pCurControl->Enable();
- pCurControl->Show();
- //zeigt die neue Seite im Fenster an
+ iter = maPages[nIndex].begin();
+ iterEnd = maPages[nIndex].end();
+
+ for(; iter != iterEnd; ++iter)
+ {
+ (*iter)->Enable();
+ (*iter)->Show();
}
+
return true;
}
- else
- {
- return false;
- }
+
+ return false;
}
-bool Assistent::IsLastPage()
+bool Assistent::IsLastPage() const
{
- if(mnCurrentPage==mnPages)
- {
+ if(mnCurrentPage == mnPages)
return true;
- }
- else
- {
- int nPage = mnCurrentPage+1;
- while(nPage <= mnPages && !mpPageStatus[nPage-1])
- nPage++;
- return nPage > mnPages;
- }
+ int nPage = mnCurrentPage+1;
+ while(nPage <= mnPages && !mpPageStatus[nPage-1])
+ nPage++;
+
+ return nPage > mnPages;
}
-bool Assistent::IsFirstPage()
+bool Assistent::IsFirstPage() const
{
- if(mnCurrentPage==1)
- {
+ if(mnCurrentPage == 1)
return true;
- }
- else
- {
- int nPage = mnCurrentPage-1;
- while(nPage > 0 && !mpPageStatus[nPage-1])
- nPage--;
-
- return nPage == 0;
- }
-}
-
+ int nPage = mnCurrentPage-1;
+ while(nPage > 0 && !mpPageStatus[nPage-1])
+ nPage--;
-int Assistent::GetCurrentPage()
-{
- return mnCurrentPage;
+ return nPage == 0;
}
-Assistent::~Assistent()
+int Assistent::GetCurrentPage() const
{
- for( int i=0;i<mnPages;i++)
- {
- delete mpPages[i];
- }
-
- delete [] mpPageStatus;
+ return mnCurrentPage;
}
-bool Assistent::IsEnabled( int nPage )
+bool Assistent::IsEnabled( int nPage ) const
{
DBG_ASSERT( (nPage>0) && (nPage <= mnPages), "Seite nicht vorhanden!" );
@@ -218,3 +186,5 @@ void Assistent::DisablePage( int nPage )
GotoPage(1);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/brkdlg.cxx b/sd/source/ui/dlg/brkdlg.cxx
index 853d84d5e..a9cff73f7 100755..100644
--- a/sd/source/ui/dlg/brkdlg.cxx
+++ b/sd/source/ui/dlg/brkdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -185,3 +186,5 @@ IMPL_LINK( BreakDlg, InitialUpdate, Timer*, EMPTYARG )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/celltempl.cxx b/sd/source/ui/dlg/celltempl.cxx
index 3fe529a20..c5eea8f99 100755..100644
--- a/sd/source/ui/dlg/celltempl.cxx
+++ b/sd/source/ui/dlg/celltempl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -118,3 +119,5 @@ const SfxItemSet* SdPresCellTemplateDlg::GetRefreshedSet()
return pRet;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/copydlg.cxx b/sd/source/ui/dlg/copydlg.cxx
index 47dd23d26..f45ababa5 100755..100644
--- a/sd/source/ui/dlg/copydlg.cxx
+++ b/sd/source/ui/dlg/copydlg.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -64,10 +65,10 @@ namespace sd {
\************************************************************************/
CopyDlg::CopyDlg(
- ::Window* pWindow,
+ ::Window* pWindow,
const SfxItemSet& rInAttrs,
- XColorTable* pColTab,
- ::sd::View* pInView )
+ XColorTable* pColTab,
+ ::sd::View* pInView )
: SfxModalDialog ( pWindow, SdResId( DLG_COPY ) ),
maFtCopies ( this, SdResId( FT_COPIES ) ),
maNumFldCopies ( this, SdResId( NUM_FLD_COPIES ) ),
@@ -101,7 +102,6 @@ CopyDlg::CopyDlg(
FreeResource();
// Set up the view data button (image and accessible name).
- maBtnSetViewData.SetModeImage( Image( SdResId( IMG_PIPETTE_H ) ), BMP_COLOR_HIGHCONTRAST );
maBtnSetViewData.SetAccessibleName (maBtnSetViewData.GetQuickHelpText());
// Farbtabellen
@@ -355,3 +355,5 @@ IMPL_LINK( CopyDlg, SetDefault, void*, EMPTYARG )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/custsdlg.cxx b/sd/source/ui/dlg/custsdlg.cxx
index ce23c8d24..b503f27ac 100755..100644
--- a/sd/source/ui/dlg/custsdlg.cxx
+++ b/sd/source/ui/dlg/custsdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -558,3 +559,4 @@ IMPL_LINK( SdDefineCustomShowDlg, OKHdl, Button *, EMPTYARG )
return 0;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/custsdlg.src b/sd/source/ui/dlg/custsdlg.src
index 13bb64ada..13bb64ada 100755..100644
--- a/sd/source/ui/dlg/custsdlg.src
+++ b/sd/source/ui/dlg/custsdlg.src
diff --git a/sd/source/ui/dlg/diactrl.cxx b/sd/source/ui/dlg/diactrl.cxx
index 820caf934..a2a0e4a60 100755..100644
--- a/sd/source/ui/dlg/diactrl.cxx
+++ b/sd/source/ui/dlg/diactrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -177,3 +178,4 @@ Window* SdTbxCtlDiaPages::CreateItemWindow( Window* pParent )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlg_char.src b/sd/source/ui/dlg/dlg_char.src
index a04db7cc2..684c948c7 100644
--- a/sd/source/ui/dlg/dlg_char.src
+++ b/sd/source/ui/dlg/dlg_char.src
@@ -84,7 +84,6 @@ TabDialog TAB_CHAR
{
Pos = MAP_APPFONT ( 169 , 151 ) ;
Size = MAP_APPFONT ( 50 , 14 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Zurück : Zur³ck */
Text [ en-US ] = "Return" ;
TabStop = TRUE ;
};
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index 9a289028d..5ee4d8e40 100755..100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -33,7 +34,7 @@
#endif
#include <com/sun/star/presentation/ClickAction.hpp>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/msgbox.hxx>
#include <vcl/lstbox.hxx>
#include <vcl/combobox.hxx>
@@ -74,21 +75,19 @@
#include "dlgass.hrc"
#include "dlgass.hxx"
#include "dlgctrls.hxx"
-#ifndef _SD_CFGID_HXX
#include "strings.hrc"
-#endif
-#ifndef _DATETIMEITEM_HXX
#include "dlgassim.hxx"
-#endif
#include "TemplateScanner.hxx"
#include "WindowUpdater.hxx"
#include <comphelper/processfactory.hxx>
+#include <vector>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::sd;
+using ::std::vector;
void InterpolateFixedBitmap( FixedBitmap * pBitmap )
{
@@ -120,8 +119,6 @@ public:
String maPath;
};
-DECLARE_LIST( PasswordEntryList, PasswordEntry * )
-
// ====================================================================
/** A simple wrapper that looks like a PushButton and is used to force the
@@ -211,7 +208,7 @@ public:
String GetPassword( const String rPath );
void DeletePassords();
- PasswordEntryList maPasswordList;
+ vector< PasswordEntry* > maPasswordList;
String maDocFile;
String maLayoutFile;
@@ -441,13 +438,13 @@ AssistentDlgImpl::AssistentDlgImpl( ::Window* pWindow, const Link& rFinishLink,
String sText (GetUiTextForCommand(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Open"))));
// Remove the mnemonic and add a leading space so that icon and text
// are not too close together.
- sText.SearchAndReplaceAll(String(RTL_CONSTASCII_STRINGPARAM("~")),String());
- sText.Insert(String(RTL_CONSTASCII_STRINGPARAM(" ")),0);
+ sText.SearchAndReplaceAll(String(RTL_CONSTASCII_USTRINGPARAM("~")),String());
+ sText.Insert(String(RTL_CONSTASCII_USTRINGPARAM(" ")),0);
mpPage1OpenPB->SetText(sText);
// Place icon left of text and both centered in the button.
mpPage1OpenPB->SetModeImage(
- GetUiIconForCommand(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Open"))),
- BMP_COLOR_NORMAL);
+ GetUiIconForCommand(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Open")))
+ );
mpPage1OpenPB->EnableImageDisplay(sal_True);
mpPage1OpenPB->EnableTextDisplay(sal_True);
mpPage1OpenPB->SetImageAlign(IMAGEALIGN_LEFT);
@@ -466,7 +463,6 @@ AssistentDlgImpl::AssistentDlgImpl( ::Window* pWindow, const Link& rFinishLink,
mpPage1OpenLB->SetSelectHdl(LINK(this,AssistentDlgImpl,SelectFileHdl));
mpPage1OpenLB->SetDoubleClickHdl(rFinishLink);
mpPage1OpenPB->SetClickHdl(LINK(this,AssistentDlgImpl,OpenButtonHdl));
- // mpPage1OpenLB->InsertEntry(String(SdResId(STR_WIZARD_POSITION)));
// Seite 2
maAssistentFunc.InsertControl(2, &maPreview );
@@ -532,7 +528,6 @@ AssistentDlgImpl::AssistentDlgImpl( ::Window* pWindow, const Link& rFinishLink,
mpPage3LogoCB = new CheckBox( pWindow, SdResId( CB_PAGE3_LOGO) ));
mpPage3EffectLB->Fill();
-// mpPage3EffectLB->SelectEffect( presentation::FadeEffect_NONE );
mpPage3EffectLB->SetSelectHdl( LINK(this,AssistentDlgImpl,SelectEffectHdl ));
mpPage3EffectLB->SetDropDownLineCount( 12 );
@@ -644,11 +639,11 @@ AssistentDlgImpl::AssistentDlgImpl( ::Window* pWindow, const Link& rFinishLink,
TemplateEntry* pStandardTemplateEntry = 0;
std::vector<TemplateDir*>::iterator I;
- for (I=maPresentList.begin(); I!=maPresentList.end(); I++)
+ for (I=maPresentList.begin(); I!=maPresentList.end(); ++I)
{
TemplateDir* pDir = *I;
std::vector<TemplateEntry*>::iterator J;
- for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); J++)
+ for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); ++J)
{
TemplateEntry* pEntry = *J;
if(pEntry->msPath == aStandardTemplate)
@@ -685,9 +680,9 @@ AssistentDlgImpl::~AssistentDlgImpl()
// Delete the template file infos.
std::vector<TemplateDir*>::iterator I;
std::vector<TemplateEntry*>::iterator J;
- for (I=maPresentList.begin(); I!=maPresentList.end(); I++)
+ for (I=maPresentList.begin(); I!=maPresentList.end(); ++I)
{
- for (J=(*I)->maEntries.begin(); J!=(*I)->maEntries.end(); J++)
+ for (J=(*I)->maEntries.begin(); J!=(*I)->maEntries.end(); ++J)
delete (*J);
delete (*I);
}
@@ -749,7 +744,7 @@ AssistentDlgImpl::~AssistentDlgImpl()
// Delete the file history list.
std::vector<String*>::iterator I2;
- for (I2=maOpenFilesList.begin(); I2!=maOpenFilesList.end(); I2++)
+ for (I2=maOpenFilesList.begin(); I2!=maOpenFilesList.end(); ++I2)
delete *I2;
}
@@ -757,14 +752,11 @@ void AssistentDlgImpl::CloseDocShell()
{
if(xDocShell.Is())
{
- //uno::Reference< lang::XComponent > xModel( xDocShell->GetModel(), uno::UNO_QUERY );
uno::Reference< util::XCloseable > xCloseable( xDocShell->GetModel(), uno::UNO_QUERY );
- //if( xModel.is() )
if( xCloseable.is() )
{
xCloseable->close( sal_True );
xDocShell = NULL;
- //xModel->dispose();
}
else
{
@@ -889,7 +881,7 @@ void AssistentDlgImpl::TemplateScanDone (
std::vector<TemplateDir*>& rTemplateFolder)
{
// This method is called from a thread. Therefore we get the solar mutex.
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// Copy the contents of the given template folders to a local list.
maPresentList.swap (rTemplateFolder);
@@ -899,7 +891,7 @@ void AssistentDlgImpl::TemplateScanDone (
mpPage1RegionLB->Clear();
std::vector<TemplateDir*>::iterator I;
int i;
- for (i=0,I=maPresentList.begin(); I!=maPresentList.end(); I++,i++)
+ for (i=0,I=maPresentList.begin(); I!=maPresentList.end(); ++I,++i)
{
TemplateDir* pDir = *I;
if (pDir == NULL)
@@ -924,7 +916,7 @@ void AssistentDlgImpl::TemplateScanDone (
// Fill in the list box on the second page.
nFirstEntry = 0;
mpPage2RegionLB->Clear();
- for (i=0,I=maPresentList.begin(); I!=maPresentList.end(); I++,i++)
+ for (i=0,I=maPresentList.begin(); I!=maPresentList.end(); ++I,++i)
{
TemplateDir* pDir = *I;
if (pDir == NULL)
@@ -1044,7 +1036,6 @@ String AssistentDlgImpl::GetLayoutFileName()
SfxObjectShellLock AssistentDlgImpl::GetDocument()
{
-// mbPreview = sal_False; // Document nicht anzeigen
UpdatePreview(sal_False); // aber komplett laden
UpdatePageList();
@@ -1094,7 +1085,7 @@ SfxObjectShellLock AssistentDlgImpl::GetDocument()
}
else
{
- DBG_ERROR("sd::AssistentDlgImpl::GetDocument(), no template?");
+ OSL_FAIL("sd::AssistentDlgImpl::GetDocument(), no template?");
}
SfxObjectShellLock xRet = xDocShell;
@@ -1383,14 +1374,14 @@ void AssistentDlgImpl::SelectTemplateRegion( const String& rRegion )
{
mpPage1TemplateLB->Clear();
std::vector<TemplateDir*>::iterator I;
- for (I=maPresentList.begin(); I!=maPresentList.end(); I++)
+ for (I=maPresentList.begin(); I!=maPresentList.end(); ++I)
{
TemplateDir * pDir = *I;
mpTemplateRegion = *I;
if (pDir->msRegion.Equals( rRegion ) )
{
std::vector<TemplateEntry*>::iterator J;
- for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); J++)
+ for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); ++J)
mpPage1TemplateLB->InsertEntry ((*J)->msTitle);
mpPage1TemplateLB->Update();
if(GetStartType() == ST_TEMPLATE)
@@ -1408,7 +1399,7 @@ void AssistentDlgImpl::SelectLayoutRegion( const String& rRegion )
mpPage2LayoutLB->Clear();
mpPage2LayoutLB->InsertEntry(String(SdResId(STR_WIZARD_ORIGINAL)));
std::vector<TemplateDir*>::iterator I;
- for (I=maPresentList.begin(); I!=maPresentList.end(); I++)
+ for (I=maPresentList.begin(); I!=maPresentList.end(); ++I)
{
TemplateDir * pDir = *I;
mpLayoutRegion = *I;
@@ -1416,7 +1407,7 @@ void AssistentDlgImpl::SelectLayoutRegion( const String& rRegion )
if (pDir->msRegion.Equals (rRegion))
{
std::vector<TemplateEntry*>::iterator J;
- for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); J++)
+ for (J=pDir->maEntries.begin(); J!=pDir->maEntries.end(); ++J)
mpPage2LayoutLB->InsertEntry ((*J)->msTitle);
mpPage2LayoutLB->Update();
break;
@@ -1649,7 +1640,7 @@ void AssistentDlgImpl::UpdatePreview( sal_Bool bDocPreview )
}
else
{
- DBG_ERROR("sd::AssistentDlgImpl::UpdatePreview(), no document for preview?");
+ OSL_FAIL("sd::AssistentDlgImpl::UpdatePreview(), no document for preview?");
}
mbUserDataDirty = sal_True;
@@ -1685,21 +1676,21 @@ void AssistentDlgImpl::SavePassword( SfxObjectShellLock xDoc, const String& rPat
if(aPass.Len() == 0)
return;
- PasswordEntry* pEntry = maPasswordList.First();
- while(pEntry)
+ PasswordEntry* pEntry = NULL;
+ for ( size_t i = 0, n = maPasswordList.size(); i < n; ++i )
{
- if(pEntry->maPath == rPath)
+ if ( maPasswordList[ i ]->maPath == rPath )
+ {
+ pEntry = maPasswordList[ i ];
break;
-
- pEntry = maPasswordList.Next();
-
+ }
}
if(pEntry == NULL)
{
pEntry = new PasswordEntry();
pEntry->maPath = rPath;
- maPasswordList.Insert( pEntry );
+ maPasswordList.push_back( pEntry );
}
if(pEntry)
@@ -1719,26 +1710,20 @@ void AssistentDlgImpl::RestorePassword( SfxItemSet* pSet, const String& rPath )
String AssistentDlgImpl::GetPassword( const String rPath )
{
- PasswordEntry* pEntry = maPasswordList.First();
- while(pEntry)
+ for ( size_t i = 0, n = maPasswordList.size(); i < n; ++i )
{
+ PasswordEntry* pEntry = maPasswordList[ i ];
if(pEntry->maPath == rPath)
return pEntry->maPassword;
-
- pEntry = maPasswordList.Next();
}
-
return String();
}
void AssistentDlgImpl::DeletePassords()
{
- PasswordEntry* pEntry = maPasswordList.First();
- while(pEntry)
- {
- delete pEntry;
- pEntry = maPasswordList.Next();
- }
+ for ( size_t i = 0, n = maPasswordList.size(); i < n; ++i )
+ delete maPasswordList[ i ];
+ maPasswordList.clear();
}
sal_Bool AssistentDlgImpl::IsOwnFormat( const String& rPath )
@@ -1794,7 +1779,7 @@ String AssistentDlgImpl::GetUiTextForCommand (const ::rtl::OUString& sCommandURL
for (sal_Int32 i=0; i<nCount; i++)
{
::rtl::OUString sPropertyName (aProperties[i].Name);
- if (sPropertyName.equalsAscii("Label"))
+ if (sPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Label")))
{
aProperties[i].Value >>= sString;
break;
@@ -2041,3 +2026,5 @@ void NextButton::Enable (bool bEnable)
maNextButton1.Enable(bEnable);
maNextButton2.Enable(bEnable);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgassim.cxx b/sd/source/ui/dlg/dlgassim.cxx
index b7e1d6dd2..a50a6ebe6 100755..100644
--- a/sd/source/ui/dlg/dlgassim.cxx
+++ b/sd/source/ui/dlg/dlgassim.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -51,7 +52,7 @@ SdPageListControl::SdPageListControl(
// Tree-ListBox mit Linien versehen
SetStyle( GetStyle() | WB_TABSTOP | WB_BORDER | WB_HASLINES |
WB_HASBUTTONS | WB_HASLINESATROOT |
- WB_HSCROLL | // #31562#
+ WB_HSCROLL |
WB_HASBUTTONSATROOT );
SetNodeDefaultImages ();
@@ -207,3 +208,4 @@ void SdPageListControl::DataChanged( const DataChangedEvent& rDCEvt )
SvTreeListBox::DataChanged( rDCEvt );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgassim.hxx b/sd/source/ui/dlg/dlgassim.hxx
index d612e44cc..ee0f4734a 100755..100644
--- a/sd/source/ui/dlg/dlgassim.hxx
+++ b/sd/source/ui/dlg/dlgassim.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -56,15 +57,4 @@ public:
};
-class TemplateCacheInfo;
-
-DECLARE_LIST( TemplateCacheInfoList, TemplateCacheInfo * )
-
-class TemplateCacheDirEntry
-{
-public:
- String m_aPath;
- TemplateCacheInfoList m_aFiles;
-};
-
-DECLARE_LIST( TemplateCacheDirEntryList, TemplateCacheDirEntry * )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgchar.cxx b/sd/source/ui/dlg/dlgchar.cxx
index 320838357..7ec013f27 100755..100644
--- a/sd/source/ui/dlg/dlgchar.cxx
+++ b/sd/source/ui/dlg/dlgchar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,4 @@ void SdCharDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgctrls.cxx b/sd/source/ui/dlg/dlgctrls.cxx
index 987b330e7..677e94c96 100755..100644
--- a/sd/source/ui/dlg/dlgctrls.cxx
+++ b/sd/source/ui/dlg/dlgctrls.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,7 +66,7 @@ void FadeEffectLB::Fill()
const TransitionPresetList& rPresetList = TransitionPreset::getTransitionPresetList();
TransitionPresetList::const_iterator aIter;
- for( aIter = rPresetList.begin(); aIter != rPresetList.end(); aIter++ )
+ for( aIter = rPresetList.begin(); aIter != rPresetList.end(); ++aIter )
{
pPreset = (*aIter);
const OUString aUIName( pPreset->getUIName() );
@@ -79,23 +80,6 @@ void FadeEffectLB::Fill()
SelectEntryPos(0);
}
-// -----------------------------------------------------------------------------
-
-/*
-void FadeEffectLB::SelectEffect( presentation::FadeEffect eFE )
-{
- sal_Bool bFound = sal_False;
-
- for( long i = 0, nCount = sizeof( aEffects ) / sizeof( FadeEffectPair ); ( i < nCount ) && !bFound; i++ )
- {
- if( aEffects[ i ].meFE == eFE )
- {
- SelectEntryPos( (sal_uInt16) i );
- bFound = sal_True;
- }
- }
-}
-*/
// -----------------------------------------------------------------------------
@@ -120,3 +104,5 @@ void FadeEffectLB::applySelected( SdPage* pSlide ) const
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgfield.cxx b/sd/source/ui/dlg/dlgfield.cxx
index 4eb150515..ebe9bae65 100755..100644
--- a/sd/source/ui/dlg/dlgfield.cxx
+++ b/sd/source/ui/dlg/dlgfield.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,7 +155,7 @@ SvxFieldData* SdModifyFieldDlg::GetField()
if( pDocSh->HasName() )
aName = pDocSh->GetMedium()->GetName();
- // #91225# Get current filename, not the one stored in the old field
+ // Get current filename, not the one stored in the old field
pNewField = new SvxExtFileField( aName );
( (SvxExtFileField*) pNewField )->SetType( eType );
( (SvxExtFileField*) pNewField )->SetFormat( eFormat );
@@ -172,7 +173,7 @@ SvxFieldData* SdModifyFieldDlg::GetField()
eFormat = (SvxAuthorFormat) ( aLbFormat.GetSelectEntryPos() );
- // #91225# Get current state of address, not the old one
+ // Get current state of address, not the old one
SvtUserOptions aUserOptions;
pNewField = new SvxAuthorField( aUserOptions.GetFirstName(), aUserOptions.GetLastName(), aUserOptions.GetID() );
( (SvxAuthorField*) pNewField )->SetType( eType );
@@ -183,12 +184,6 @@ SvxFieldData* SdModifyFieldDlg::GetField()
return( pNewField );
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdModifyFieldDlg::FillFormatList()
{
LanguageType eLangType = maLbLanguage.GetSelectLanguage();
@@ -364,3 +359,4 @@ SfxItemSet SdModifyFieldDlg::GetItemSet()
return aOutput;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgolbul.cxx b/sd/source/ui/dlg/dlgolbul.cxx
index 3adba08ef..20f871a32 100755..100644
--- a/sd/source/ui/dlg/dlgolbul.cxx
+++ b/sd/source/ui/dlg/dlgolbul.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include "OutlineBulletDlg.hxx"
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <sfx2/objsh.hxx>
#include <svx/drawitem.hxx>
#include <editeng/bulitem.hxx>
@@ -52,9 +51,7 @@
#include <svl/style.hxx>
#include <drawdoc.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "glob.hrc"
#include "dlgolbul.hrc"
@@ -135,17 +132,6 @@ OutlineBulletDlg::OutlineBulletDlg(
aInputSet.Put(*pItem, EE_PARA_NUMBULLET);
}
- /* debug
- if( SFX_ITEM_SET == aInputSet.GetItemState(EE_PARA_NUMBULLET, sal_False, &pItem ))
- {
- SvxNumRule& rItem = *((SvxNumBulletItem*)pItem)->GetNumRule();
- for( int i = 0; i < 9; i++ )
- {
- SvxNumberFormat aNumberFormat = rItem.GetLevel(i);
- }
- }
- */
-
if(bTitle && aInputSet.GetItemState(EE_PARA_NUMBULLET,sal_True) == SFX_ITEM_ON )
{
SvxNumBulletItem* pItem = (SvxNumBulletItem*)aInputSet.GetItem(EE_PARA_NUMBULLET,sal_True);
@@ -218,15 +204,9 @@ const SfxItemSet* OutlineBulletDlg::GetOutputItemSet() const
{
SdBulletMapper::MapFontsInNumRule( *((SvxNumBulletItem*)pItem)->GetNumRule(), *pOutputSet );
-/* #i35937#
- SfxUInt16Item aBulletState( EE_PARA_BULLETSTATE, 1 );
- pOutputSet->Put(aBulletState);
-*/
+// #i35937 - removed EE_PARA_BULLETSTATE setting
}
-/* #i35937#
- SdBulletMapper::PostMapNumBulletForDialog( *pOutputSet );
-*/
if(bTitle && pOutputSet->GetItemState(EE_PARA_NUMBULLET,sal_True) == SFX_ITEM_ON )
{
@@ -240,3 +220,5 @@ const SfxItemSet* OutlineBulletDlg::GetOutputItemSet() const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgpage.cxx b/sd/source/ui/dlg/dlgpage.cxx
index e56b2b635..fc02fde41 100755..100644
--- a/sd/source/ui/dlg/dlgpage.cxx
+++ b/sd/source/ui/dlg/dlgpage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,15 +34,11 @@
#endif
#include <svl/intitem.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <svx/tabarea.hxx>
#include <svx/drawitem.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "dlgpage.hxx"
#include "DrawDocShell.hxx"
@@ -116,3 +113,4 @@ void SdPageDlg::PageCreated(sal_uInt16 nId, SfxTabPage& rPage)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgpage.src b/sd/source/ui/dlg/dlgpage.src
index 5cd433799..e640c70d6 100644
--- a/sd/source/ui/dlg/dlgpage.src
+++ b/sd/source/ui/dlg/dlgpage.src
@@ -79,7 +79,6 @@ TabDialog TAB_PAGE
{
Pos = MAP_APPFONT ( 169 , 151 ) ;
Size = MAP_APPFONT ( 50 , 14 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Zurück : Zur³ck */
Text [ en-US ] = "Return" ;
TabStop = TRUE ;
};
diff --git a/sd/source/ui/dlg/dlgsnap.cxx b/sd/source/ui/dlg/dlgsnap.cxx
index e27dd81da..a44c74f3f 100755..100644
--- a/sd/source/ui/dlg/dlgsnap.cxx
+++ b/sd/source/ui/dlg/dlgsnap.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -53,9 +54,9 @@
\************************************************************************/
SdSnapLineDlg::SdSnapLineDlg(
- ::Window* pWindow,
+ ::Window* pWindow,
const SfxItemSet& rInAttrs,
- ::sd::View* pView)
+ ::sd::View* pView)
: ModalDialog (pWindow, SdResId(DLG_SNAPLINE)),
aFlPos (this, SdResId(FL_POSITION)),
aFtX (this, SdResId(FT_X)),
@@ -73,10 +74,6 @@ SdSnapLineDlg::SdSnapLineDlg(
eUIUnit(pView->GetDoc()->GetUIUnit()),
aUIScale(pView->GetDoc()->GetUIScale())
{
- aRbPoint.SetModeRadioImage( Image( SdResId( BMP_POINT_H ) ), BMP_COLOR_HIGHCONTRAST );
- aRbVert.SetModeRadioImage( Image( SdResId( BMP_VERTICAL_H ) ), BMP_COLOR_HIGHCONTRAST );
- aRbHorz.SetModeRadioImage( Image( SdResId( BMP_HORIZONTAL_H ) ), BMP_COLOR_HIGHCONTRAST );
-
FreeResource();
aRbHorz.SetClickHdl(LINK(this, SdSnapLineDlg, ClickHdl));
@@ -97,7 +94,7 @@ SdSnapLineDlg::SdSnapLineDlg(
SfxMapUnit ePoolUnit = pPool->GetMetric( SID_ATTR_FILL_HATCH );
// #i48497# Consider page origin
- SdrPageView* pPV = pView->GetSdrPageView();
+ SdrPageView* pPV = pView->GetSdrPageView();
Point aLeftTop(aWorkArea.Left()+1, aWorkArea.Top()+1);
pPV->LogicToPagePos(aLeftTop);
Point aRightBottom(aWorkArea.Right()-2, aWorkArea.Bottom()-2);
@@ -233,3 +230,4 @@ void SdSnapLineDlg::SetInputFields(sal_Bool bEnableX, sal_Bool bEnableY)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/dlgsnap.src b/sd/source/ui/dlg/dlgsnap.src
index 31fea0d3b..45938c433 100644
--- a/sd/source/ui/dlg/dlgsnap.src
+++ b/sd/source/ui/dlg/dlgsnap.src
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -62,7 +62,6 @@ ModalDialog DLG_SNAPLINE
HelpID = "sd:PushButton:DLG_SNAPLINE:BTN_DELETE";
Pos = MAP_APPFONT ( 88 , 63 ) ;
Size = MAP_APPFONT ( 46 , 14 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? ~Löschen : ~L÷schen */
Text [ en-US ] = "~Delete" ;
TabStop = TRUE ;
};
@@ -165,50 +164,4 @@ ModalDialog DLG_SNAPLINE
ImageBitmap = Bitmap { File = "hlplhorz.bmp" ; };
};
};
-
- Image BMP_POINT_H
- {
- MaskColor = IMAGE_MASK_STDCOLOR_HC;
- ImageBitmap = Bitmap { File = "hlppoint_h.bmp" ; };
- };
-
- Image BMP_VERTICAL_H
- {
- MaskColor = IMAGE_MASK_STDCOLOR_HC;
- ImageBitmap = Bitmap { File = "hlplvert_h.bmp" ; };
- };
-
- Image BMP_HORIZONTAL_H
- {
- MaskColor = IMAGE_MASK_STDCOLOR_HC;
- ImageBitmap = Bitmap { File = "hlplhorz_h.bmp" ; };
- };
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/sd/source/ui/dlg/docprev.cxx b/sd/source/ui/dlg/docprev.cxx
index e6b1a06d3..4fbd3b977 100755..100644
--- a/sd/source/ui/dlg/docprev.cxx
+++ b/sd/source/ui/dlg/docprev.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -237,7 +238,7 @@ void SdDocPreviewWin::updateViewSettings()
aVDev.SetMapMode( aMap );
- // #109058# Disable output, as we only want to record a metafile
+ // Disable output, as we only want to record a metafile
aVDev.EnableOutput( sal_False );
pMtf->Record( &aVDev );
@@ -303,3 +304,5 @@ void SdDocPreviewWin::DataChanged( const DataChangedEvent& rDCEvt )
updateViewSettings();
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/filedlg.cxx b/sd/source/ui/dlg/filedlg.cxx
index edcd4b54a..8dd347a68 100755..100644
--- a/sd/source/ui/dlg/filedlg.cxx
+++ b/sd/source/ui/dlg/filedlg.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,8 +44,8 @@
#include <vcl/msgbox.hxx>
#include <sal/types.h>
#include <tools/urlobj.hxx>
-#include <vos/thread.hxx>
-#include <vos/mutex.hxx>
+#include <osl/thread.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <sfx2/filedlghelper.hxx>
#include <avmedia/mediawindow.hxx>
@@ -99,9 +100,9 @@ public:
// ------------------------------------------------------------------------
void SAL_CALL SdFileDialog_Imp::ControlStateChanged( const css::ui::dialogs::FilePickerEvent& aEvent )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
- switch( aEvent.ElementId )
+ switch( aEvent.ElementId )
{
case css::ui::dialogs::CommonFilePickerElementIds::LISTBOX_FILTER:
CheckSelectionState();
@@ -110,7 +111,7 @@ void SAL_CALL SdFileDialog_Imp::ControlStateChanged( const css::ui::dialogs::Fil
case css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY:
if( mxControlAccess.is() )
{
- if( mnPlaySoundEvent )
+ if( mnPlaySoundEvent )
Application::RemoveUserEvent( mnPlaySoundEvent );
mnPlaySoundEvent = Application::PostUserEvent( LINK( this, SdFileDialog_Imp, PlayMusicHdl ) );
@@ -126,7 +127,7 @@ IMPL_LINK( SdFileDialog_Imp, PlayMusicHdl, void *, EMPTYARG )
mnPlaySoundEvent = 0;
if (mxPlayer.is())
- {
+ {
if (mxPlayer->isPlaying())
mxPlayer->stop();
mxPlayer.clear();
@@ -136,15 +137,15 @@ IMPL_LINK( SdFileDialog_Imp, PlayMusicHdl, void *, EMPTYARG )
{
try
{
- mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
+ mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
String( SdResId( STR_PLAY ) ) );
-
+
mbLabelPlaying = sal_False;
}
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot access play button" );
+ OSL_FAIL( "Cannot access play button" );
#endif
}
}
@@ -170,15 +171,15 @@ IMPL_LINK( SdFileDialog_Imp, PlayMusicHdl, void *, EMPTYARG )
{
try
{
- mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
+ mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
String( SdResId( STR_STOP ) ) );
-
+
mbLabelPlaying = sal_True;
}
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot access play button" );
+ OSL_FAIL( "Cannot access play button" );
#endif
}
}
@@ -191,10 +192,10 @@ IMPL_LINK( SdFileDialog_Imp, PlayMusicHdl, void *, EMPTYARG )
// ------------------------------------------------------------------------
IMPL_LINK( SdFileDialog_Imp, IsMusicStoppedHdl, void *, EMPTYARG )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if (
- mxPlayer.is() && mxPlayer->isPlaying() &&
+ mxPlayer.is() && mxPlayer->isPlaying() &&
mxPlayer->getMediaTime() < mxPlayer->getDuration()
)
{
@@ -207,14 +208,14 @@ IMPL_LINK( SdFileDialog_Imp, IsMusicStoppedHdl, void *, EMPTYARG )
{
try
{
- mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
+ mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
String( SdResId( STR_PLAY ) ) );
mbLabelPlaying = sal_False;
}
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot access play button" );
+ OSL_FAIL( "Cannot access play button" );
#endif
}
}
@@ -239,7 +240,7 @@ void SdFileDialog_Imp::CheckSelectionState()
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot access \"selection\" checkbox" );
+ OSL_FAIL( "Cannot access \"selection\" checkbox" );
#endif
}
}
@@ -247,7 +248,7 @@ void SdFileDialog_Imp::CheckSelectionState()
//-----------------------------------------------------------------------------
SdFileDialog_Imp::SdFileDialog_Imp( const short nDialogType,
- sal_Bool bUsableSelection ) :
+ sal_Bool bUsableSelection ) :
FileDialogHelper( nDialogType, 0 ),
mnPlaySoundEvent( 0 ),
mbUsableSelection( bUsableSelection ),
@@ -267,13 +268,13 @@ SdFileDialog_Imp::SdFileDialog_Imp( const short nDialogType,
{
try
{
- mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
+ mxControlAccess->setLabel( css::ui::dialogs::ExtendedFilePickerElementIds::PUSHBUTTON_PLAY,
String( SdResId( STR_PLAY ) ) );
}
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot set play button label" );
+ OSL_FAIL( "Cannot set play button label" );
#endif
}
}
@@ -286,7 +287,7 @@ SdFileDialog_Imp::SdFileDialog_Imp( const short nDialogType,
catch( css::lang::IllegalArgumentException )
{
#ifdef DBG_UTIL
- DBG_ERROR( "Cannot disable selection checkbox" );
+ OSL_FAIL( "Cannot disable selection checkbox" );
#endif
}
}
@@ -297,14 +298,14 @@ SdFileDialog_Imp::SdFileDialog_Imp( const short nDialogType,
// ------------------------------------------------------------------------
SdFileDialog_Imp::~SdFileDialog_Imp()
{
- if( mnPlaySoundEvent )
+ if( mnPlaySoundEvent )
Application::RemoveUserEvent( mnPlaySoundEvent );
}
// ------------------------------------------------------------------------
ErrCode SdFileDialog_Imp::Execute()
{
- // make sure selection checkbox is disabled if
+ // make sure selection checkbox is disabled if
// HTML is current filter!
CheckSelectionState();
return FileDialogHelper::Execute();
@@ -366,3 +367,5 @@ void SdOpenSoundFileDialog::SetPath( const String& rPath )
{
mpImpl->SetDisplayDirectory( rPath );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/gluectrl.cxx b/sd/source/ui/dlg/gluectrl.cxx
index 2a86d92c5..1b12890ee 100755..100644
--- a/sd/source/ui/dlg/gluectrl.cxx
+++ b/sd/source/ui/dlg/gluectrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,7 +30,7 @@
#include "precompiled_sd.hxx"
-#include <string> // HACK: prevent conflict between STLPORT and Workshop headers
+#include <string>
#include <svx/dialogs.hrc>
#include <svx/svdglue.hxx>
@@ -202,12 +203,6 @@ void SdTbxCtlGlueEscDir::StateChanged( sal_uInt16 nSId,
SfxToolBoxControl::StateChanged( nSId, eState, pState );
}
-/*************************************************************************
-|*
-|* No Comment
-|*
-\************************************************************************/
-
Window* SdTbxCtlGlueEscDir::CreateItemWindow( Window *pParent )
{
if( GetSlotId() == SID_GLUE_ESCDIR )
@@ -234,3 +229,5 @@ sal_uInt16 SdTbxCtlGlueEscDir::GetEscDirPos( sal_uInt16 nEscDir )
}
return( 99 );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/headerfooterdlg.cxx b/sd/source/ui/dlg/headerfooterdlg.cxx
index f263b09f0..99b144958 100755..100644
--- a/sd/source/ui/dlg/headerfooterdlg.cxx
+++ b/sd/source/ui/dlg/headerfooterdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#undef SD_DLLIMPLEMENTATION
#endif
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <editeng/eeitem.hxx>
#include <editeng/flditem.hxx>
#include <editeng/langitem.hxx>
@@ -43,9 +42,7 @@
#include <editeng/editeng.hxx>
#include <sfx2/viewfrm.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include <vcl/fixed.hxx>
#include <vcl/button.hxx>
@@ -64,9 +61,7 @@
// preview control for presentation layout
///////////////////////////////////////////////////////////////////////
#include <vcl/ctrl.hxx>
-#ifndef _SV_COLOR_HXX
#include <tools/color.hxx>
-#endif
#include <i18npool/mslangid.hxx>
#include <svtools/colorcfg.hxx>
#include <svx/xlndsit.hxx>
@@ -590,7 +585,7 @@ void HeaderFooterTabPage::FillFormatList( int eFormat )
{
String aStr( SvxDateTimeField::GetFormatted( aDate, aTime, nDateTimeFormats[nFormat], *(SD_MOD()->GetNumberFormatter()), eLanguage ) );
sal_uInt16 nEntry = maCBDateTimeFormat.InsertEntry( aStr );
- maCBDateTimeFormat.SetEntryData( nEntry, (void*)nDateTimeFormats[nFormat] );
+ maCBDateTimeFormat.SetEntryData( nEntry, (void*)(sal_IntPtr)nDateTimeFormats[nFormat] );
if( nDateTimeFormats[nFormat] == eFormat )
{
maCBDateTimeFormat.SelectEntryPos( nEntry );
@@ -953,3 +948,5 @@ void PresLayoutPreview::Paint( const Rectangle& )
Pop();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/ins_paste.cxx b/sd/source/ui/dlg/ins_paste.cxx
index c08c70221..7bc1d0236 100755..100644
--- a/sd/source/ui/dlg/ins_paste.cxx
+++ b/sd/source/ui/dlg/ins_paste.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,10 +29,6 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifdef SD_DLLIMPLEMENTATION
-#undef SD_DLLIMPLEMENTATION
-#endif
-
#include "ins_paste.hrc"
#include "ins_paste.hxx"
@@ -64,3 +61,5 @@ sal_Bool SdInsertPasteDlg::IsInsertBefore() const
{
return( aRbBefore.IsChecked() );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/inspagob.cxx b/sd/source/ui/dlg/inspagob.cxx
index 6f1cea72e..8bc30e75b 100755..100644
--- a/sd/source/ui/dlg/inspagob.cxx
+++ b/sd/source/ui/dlg/inspagob.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -110,11 +111,7 @@ void SdInsertPagesObjsDlg::Reset()
Color aColor( COL_WHITE );
Bitmap aBmpText( SdResId( BMP_DOC_TEXT ) );
Image aImgText( aBmpText, aColor );
- Bitmap aBmpTextH( SdResId( BMP_DOC_TEXT_H ) );
- Image aImgTextH( aBmpTextH, Color( COL_BLACK ) );
- SvLBoxEntry* pEntry = aLbTree.InsertEntry( rName, aImgText, aImgText );
- aLbTree.SetExpandedEntryBmp( pEntry, aImgTextH, BMP_COLOR_HIGHCONTRAST );
- aLbTree.SetCollapsedEntryBmp( pEntry, aImgTextH, BMP_COLOR_HIGHCONTRAST );
+ aLbTree.InsertEntry( rName, aImgText, aImgText );
}
aCbxMasters.Check( sal_True );
@@ -142,7 +139,7 @@ List* SdInsertPagesObjsDlg::GetList( sal_uInt16 nType )
// wird das gesamte Dokument (und nicht mehr!) eingefuegt.
if( aLbTree.GetSelectionCount() == 0 ||
( aLbTree.IsSelected( aLbTree.First() ) ) )
- return( NULL ); // #37350#
+ return( NULL );
}
return( aLbTree.GetSelectEntryList( nType ) );
}
@@ -186,3 +183,4 @@ IMPL_LINK( SdInsertPagesObjsDlg, SelectObjectHdl, void *, EMPTYARG )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/inspagob.src b/sd/source/ui/dlg/inspagob.src
index 1a256abe3..10e2e9753 100644
--- a/sd/source/ui/dlg/inspagob.src
+++ b/sd/source/ui/dlg/inspagob.src
@@ -34,7 +34,6 @@ ModalDialog DLG_INSERT_PAGES_OBJS
OutputSize = TRUE ;
SVLook = TRUE ;
Size = MAP_APPFONT ( 200 , 128 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Seiten/Objekte einfügen : Seiten/Objekte einf³gen */
Moveable = TRUE ;
Text [ en-US ] = "Insert Slides/Objects" ;
OKButton BTN_OK
diff --git a/sd/source/ui/dlg/layeroptionsdlg.cxx b/sd/source/ui/dlg/layeroptionsdlg.cxx
index 9a5f42c71..00fa443e1 100644
--- a/sd/source/ui/dlg/layeroptionsdlg.cxx
+++ b/sd/source/ui/dlg/layeroptionsdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,6 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifdef SD_DLLIMPLEMENTATION
-#undef SD_DLLIMPLEMENTATION
-#endif
#include <svl/itemset.hxx>
#include "strings.hrc"
@@ -83,3 +81,5 @@ void SdInsertLayerDlg::GetAttr( SfxItemSet& rAttrs )
rAttrs.Put( SdAttrLayerPrintable( maCbxPrintable.IsChecked() ) );
rAttrs.Put( SdAttrLayerLocked( maCbxLocked.IsChecked() ) );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/makefile.mk b/sd/source/ui/dlg/makefile.mk
deleted file mode 100755
index ef763dc87..000000000
--- a/sd/source/ui/dlg/makefile.mk
+++ /dev/null
@@ -1,193 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=dlg
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES =\
- masterlayoutdlg.src\
- headerfooterdlg.src\
- ins_paste.src\
- inspagob.src\
- present.src\
- dlg_char.src\
- paragr.src\
- tabtempl.src\
- dlgpage.src\
- tpaction.src\
- animobjs.src\
- prltempl.src\
- prntopts.src\
- dlgsnap.src\
- copydlg.src\
- tpoption.src\
- dlgass.src\
- navigatr.src\
- sdpreslt.src\
- morphdlg.src\
- dlgfield.src\
- custsdlg.src\
- brkdlg.src\
- vectdlg.src\
- dlgolbul.src \
- LayerDialog.src \
- PaneDockingWindow.src \
- layeroptionsdlg.src
-
-SLOFILES = \
- $(SLO)$/inspagob.obj \
- $(SLO)$/ins_paste.obj \
- $(SLO)$/present.obj \
- $(SLO)$/dlgctrls.obj \
- $(SLO)$/dlgchar.obj \
- $(SLO)$/paragr.obj \
- $(SLO)$/tabtempl.obj \
- $(SLO)$/dlgpage.obj \
- $(SLO)$/diactrl.obj \
- $(SLO)$/gluectrl.obj \
- $(SLO)$/sdtreelb.obj \
- $(SLO)$/animobjs.obj \
- $(SLO)$/prltempl.obj \
- $(SLO)$/prntopts.obj \
- $(SLO)$/dlgsnap.obj \
- $(SLO)$/copydlg.obj \
- $(SLO)$/dlgolbul.obj \
- $(SLO)$/tpaction.obj \
- $(SLO)$/tpoption.obj \
- $(SLO)$/filedlg.obj \
- $(SLO)$/unchss.obj \
- $(SLO)$/dlgassim.obj \
- $(SLO)$/dlgass.obj \
- $(SLO)$/assclass.obj \
- $(SLO)$/navigatr.obj \
- $(SLO)$/sdpreslt.obj \
- $(SLO)$/morphdlg.obj \
- $(SLO)$/dlgfield.obj \
- $(SLO)$/custsdlg.obj \
- $(SLO)$/brkdlg.obj \
- $(SLO)$/vectdlg.obj \
- $(SLO)$/docprev.obj \
- $(SLO)$/SpellDialogChildWindow.obj \
- $(SLO)$/AnimationChildWindow.obj \
- $(SLO)$/LayerDialogChildWindow.obj \
- $(SLO)$/LayerDialogContent.obj \
- $(SLO)$/LayerTabBar.obj \
- $(SLO)$/NavigatorChildWindow.obj \
- $(SLO)$/TemplateScanner.obj \
- $(SLO)$/sduiexp.obj \
- $(SLO)$/sddlgfact.obj \
- $(SLO)$/sdabstdlg.obj \
- $(SLO)$/PaneChildWindows.obj \
- $(SLO)$/PaneDockingWindow.obj \
- $(SLO)$/PaneShells.obj
-
-LIB1TARGET= $(SLB)$/$(TARGET).lib
-
-LIB1OBJFILES= \
- $(SLO)$/dlgctrls.obj \
- $(SLO)$/diactrl.obj \
- $(SLO)$/gluectrl.obj \
- $(SLO)$/sdtreelb.obj \
- $(SLO)$/animobjs.obj \
- $(SLO)$/filedlg.obj \
- $(SLO)$/unchss.obj \
- $(SLO)$/assclass.obj \
- $(SLO)$/navigatr.obj \
- $(SLO)$/docprev.obj \
- $(SLO)$/ins_paste.obj \
- $(SLO)$/AnimationChildWindow.obj \
- $(SLO)$/LayerDialogChildWindow.obj \
- $(SLO)$/LayerDialogContent.obj \
- $(SLO)$/LayerTabBar.obj \
- $(SLO)$/NavigatorChildWindow.obj \
- $(SLO)$/SpellDialogChildWindow.obj \
- $(SLO)$/TemplateScanner.obj \
- $(SLO)$/sdabstdlg.obj \
- $(SLO)$/PaneChildWindows.obj \
- $(SLO)$/PaneDockingWindow.obj \
- $(SLO)$/PaneShells.obj
-
-
-LIB2TARGET= $(SLB)$/sdui.lib
-
-LIB2OBJFILES= \
- $(SLO)$/masterlayoutdlg.obj\
- $(SLO)$/headerfooterdlg.obj\
- $(SLO)$/sduiexp.obj \
- $(SLO)$/sddlgfact.obj \
- $(SLO)$/brkdlg.obj \
- $(SLO)$/copydlg.obj \
- $(SLO)$/custsdlg.obj \
- $(SLO)$/dlgchar.obj \
- $(SLO)$/dlgass.obj \
- $(SLO)$/dlgassim.obj \
- $(SLO)$/dlgfield.obj \
- $(SLO)$/dlgpage.obj \
- $(SLO)$/dlgsnap.obj \
- $(SLO)$/ins_paste.obj \
- $(SLO)$/inspagob.obj \
- $(SLO)$/morphdlg.obj \
- $(SLO)$/dlgolbul.obj \
- $(SLO)$/paragr.obj \
- $(SLO)$/present.obj \
- $(SLO)$/prltempl.obj \
- $(SLO)$/sdpreslt.obj \
- $(SLO)$/tabtempl.obj \
- $(SLO)$/tpaction.obj \
- $(SLO)$/tpoption.obj \
- $(SLO)$/vectdlg.obj \
- $(SLO)$/prntopts.obj \
- $(SLO)$/layeroptionsdlg.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
-$(INCCOM)$/sduilib.hxx: makefile.mk
-.IF "$(GUI)"=="UNX"
- $(RM) $@
- echo \#define DLL_NAME \"libsdui$(DLLPOSTFIX)$(DLLPOST)\" >$@
-.ELSE
- echo $(EMQ)#define DLL_NAME $(EMQ)"sdui$(DLLPOSTFIX)$(DLLPOST)$(EMQ)" >$@
-.ENDIF
-
-$(SLO)$/sdabstdlg.obj : $(INCCOM)$/sduilib.hxx
-
diff --git a/sd/source/ui/dlg/masterlayoutdlg.cxx b/sd/source/ui/dlg/masterlayoutdlg.cxx
index 16bb718a0..05d0d4131 100755..100644
--- a/sd/source/ui/dlg/masterlayoutdlg.cxx
+++ b/sd/source/ui/dlg/masterlayoutdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,13 +33,9 @@
#undef SD_DLLIMPLEMENTATION
#endif
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "strings.hrc"
#include "dialogs.hrc"
@@ -68,7 +65,7 @@ MasterLayoutDialog::MasterLayoutDialog( Window* pParent, SdDrawDocument* pDoc, S
if( mpCurrentPage == 0 )
{
mpCurrentPage = pDoc->GetMasterSdPage( 0, PK_STANDARD );
- DBG_ERROR( "MasterLayoutDialog::MasterLayoutDialog() - no current page?" );
+ OSL_FAIL( "MasterLayoutDialog::MasterLayoutDialog() - no current page?" );
}
switch( mpCurrentPage->GetPageKind() )
@@ -177,3 +174,5 @@ void MasterLayoutDialog::remove( PresObjKind eKind )
SdrObject::Free(pObject);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/morphdlg.cxx b/sd/source/ui/dlg/morphdlg.cxx
index 40e268345..24f1bd5b8 100755..100644
--- a/sd/source/ui/dlg/morphdlg.cxx
+++ b/sd/source/ui/dlg/morphdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,26 +50,12 @@
namespace sd {
-
-/******************************************************************************/
-
-
#define FADE_STEP "FadeSteps"
#define FADE_ATTRIB "FadeAttributes"
#define FADE_ORIENT "FadeOrientation"
#define FADE_TRUE "true"
#define FADE_FALSE "false"
-
-/******************************************************************************/
-
-
-/******************************************************************************
-|*
-|*
-|*
-\******************************************************************************/
-
MorphDlg::MorphDlg( ::Window* pParent, const SdrObject* pObj1, const SdrObject* pObj2 ) :
ModalDialog ( pParent, SdResId( DLG_MORPH ) ),
aGrpPreset ( this, SdResId( GRP_PRESET ) ),
@@ -102,24 +89,10 @@ MorphDlg::MorphDlg( ::Window* pParent, const SdrObject* pObj1, const SdrObject*
}
}
-
-/******************************************************************************
-|*
-|*
-|*
-\******************************************************************************/
-
MorphDlg::~MorphDlg()
{
}
-
-/******************************************************************************
-|*
-|*
-|*
-\******************************************************************************/
-
void MorphDlg::LoadSettings()
{
SvStorageStreamRef xIStm( SD_MOD()->GetOptionStream( UniString::CreateFromAscii(
@@ -164,3 +137,5 @@ void MorphDlg::SaveSettings() const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/morphdlg.src b/sd/source/ui/dlg/morphdlg.src
index 9d413e923..466877800 100644
--- a/sd/source/ui/dlg/morphdlg.src
+++ b/sd/source/ui/dlg/morphdlg.src
@@ -41,7 +41,6 @@ ModalDialog DLG_MORPH
OutputSize = TRUE ;
SVLook = TRUE ;
Size = MAP_APPFONT ( 196 , 68 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Überblenden : šberblenden */
Moveable = TRUE ;
Closeable = TRUE ;
OKButton BTN_OK
@@ -94,7 +93,6 @@ ModalDialog DLG_MORPH
HelpID = "sd:CheckBox:DLG_MORPH:CBX_ATTRIBUTES";
Pos = MAP_APPFONT ( 12 , 29 ) ;
Size = MAP_APPFONT ( 121 , 12 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Attributierung überblenden : Attributierung ³berblenden */
TabStop = TRUE ;
Text [ en-US ] = "Cross-fade attributes" ;
};
diff --git a/sd/source/ui/dlg/navigatr.cxx b/sd/source/ui/dlg/navigatr.cxx
index 92066fcf0..c5f834596 100755..100644
--- a/sd/source/ui/dlg/navigatr.cxx
+++ b/sd/source/ui/dlg/navigatr.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -87,7 +88,6 @@ SdNavigatorWin::SdNavigatorWin(
, meDragType ( NAVIGATOR_DRAGTYPE_EMBEDDED )
, mpBindings ( pInBindings )
, maImageList ( SdResId( IL_NAVIGATR ) )
-, maImageListH ( SdResId( ILH_NAVIGATR ) )
{
maTlbObjects.SetViewFrame( mpBindings->GetDispatcher()->GetFrame() );
@@ -97,7 +97,6 @@ SdNavigatorWin::SdNavigatorWin(
mpNavigatorCtrlItem = new SdNavigatorControllerItem( SID_NAVIGATOR_STATE, this, mpBindings );
mpPageNameCtrlItem = new SdPageNameControllerItem( SID_NAVIGATOR_PAGENAME, this, mpBindings );
- mpDocList = new List();
ApplyImageList(); // load images *before* calculating sizes to get something useful !!!
@@ -156,13 +155,6 @@ SdNavigatorWin::~SdNavigatorWin()
{
delete mpNavigatorCtrlItem;
delete mpPageNameCtrlItem;
-
- // Liste der DocInfos loeschen
- long nCount = mpDocList->Count();
- while( nCount-- )
- delete (NavDocInfo*) mpDocList->Remove( (sal_uLong)0 );
-
- delete mpDocList;
}
// -----------------------------------------------------------------------
@@ -396,7 +388,7 @@ IMPL_LINK( SdNavigatorWin, ClickObjectHdl, void *, EMPTYARG )
mpBindings->GetDispatcher()->Execute(
SID_NAVIGATOR_OBJECT, SFX_CALLMODE_SLOT | SFX_CALLMODE_RECORD, &aItem, 0L );
- // #98821# moved here from SetGetFocusHdl. Reset the
+ // moved here from SetGetFocusHdl. Reset the
// focus only if something has been selected in the
// document.
SfxViewShell* pCurSh = SfxViewShell::Current();
@@ -517,8 +509,8 @@ IMPL_LINK( SdNavigatorWin, ShapeFilterCallback, Menu *, pMenu )
break;
default:
- OSL_ENSURE(
- false, "SdNavigatorWin::ShapeFilterCallback called for unknown menu entry");
+ OSL_FAIL(
+ "SdNavigatorWin::ShapeFilterCallback called for unknown menu entry");
break;
}
@@ -695,9 +687,7 @@ void SdNavigatorWin::RefreshDocumentLB( const String* pDocName )
maLbDocs.Clear();
// Liste der DocInfos loeschen
- long nCount = mpDocList->Count();
- while( nCount-- )
- delete (NavDocInfo*) mpDocList->Remove( (sal_uLong)0 );
+ maDocList.clear();
if( mbDocImported )
maLbDocs.InsertEntry( aStr, 0 );
@@ -710,14 +700,15 @@ void SdNavigatorWin::RefreshDocumentLB( const String* pDocName )
::sd::DrawDocShell* pDocShell = PTR_CAST(::sd::DrawDocShell, pSfxDocShell );
if( pDocShell && !pDocShell->IsInDestruction() && ( pDocShell->GetCreateMode() != SFX_CREATE_MODE_EMBEDDED ) )
{
- NavDocInfo* pInfo = new NavDocInfo();
- pInfo->mpDocShell = pDocShell;
+ NavDocInfo aInfo ;
+ aInfo.mpDocShell = pDocShell;
- aStr = pDocShell->GetMedium()->GetName();
+ SfxMedium *pMedium = pDocShell->GetMedium();
+ aStr = pMedium ? pMedium->GetName() : String();
if( aStr.Len() )
- pInfo->SetName();
+ aInfo.SetName();
else
- pInfo->SetName( sal_False );
+ aInfo.SetName( sal_False );
// z.Z. wird wieder der Name der Shell genommen (also ohne Pfad)
// da Koose es als Fehler ansieht, wenn er Pfad in URL-Notation
// angezeigt wird!
@@ -725,13 +716,12 @@ void SdNavigatorWin::RefreshDocumentLB( const String* pDocName )
maLbDocs.InsertEntry( aStr, LISTBOX_APPEND );
- //
if( pDocShell == pCurrentDocShell )
- pInfo->SetActive();
+ aInfo.SetActive();
else
- pInfo->SetActive( sal_False );
+ aInfo.SetActive( sal_False );
- mpDocList->Insert( pInfo, LIST_APPEND );
+ maDocList.push_back( aInfo );
}
pSfxDocShell = SfxObjectShell::GetNext( *pSfxDocShell, 0 , sal_False );
}
@@ -753,7 +743,7 @@ sal_uInt16 SdNavigatorWin::GetDragTypeSdResId( NavigatorDragType eDT, sal_Bool b
return( bImage ? TBI_EMBEDDED : STR_DRAGTYPE_EMBEDDED );
case NAVIGATOR_DRAGTYPE_LINK:
return( bImage ? TBI_LINK : STR_DRAGTYPE_LINK );
- default: DBG_ERROR( "Keine Resource fuer DragType vorhanden!" );
+ default: OSL_FAIL( "Keine Resource fuer DragType vorhanden!" );
}
return( 0 );
}
@@ -762,7 +752,7 @@ sal_uInt16 SdNavigatorWin::GetDragTypeSdResId( NavigatorDragType eDT, sal_Bool b
NavDocInfo* SdNavigatorWin::GetDocInfo()
{
- long nPos = maLbDocs.GetSelectEntryPos();
+ sal_uInt32 nPos = maLbDocs.GetSelectEntryPos();
if( mbDocImported )
{
@@ -773,9 +763,7 @@ NavDocInfo* SdNavigatorWin::GetDocInfo()
nPos--;
}
- NavDocInfo* pInfo = (NavDocInfo*)mpDocList->GetObject( nPos );
-
- return( pInfo );
+ return nPos < maDocList.size() ? &(maDocList[ nPos ]) : NULL;
}
/*************************************************************************
@@ -869,11 +857,9 @@ void SdNavigatorWin::SetDragImage()
void SdNavigatorWin::ApplyImageList()
{
- const bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
- maToolbox.SetImageList( bHighContrast ? maImageListH : maImageList );
- maToolbox.SetItemImage(TBI_SHAPE_FILTER, BitmapEx(SdResId( bHighContrast ? BMP_GRAPHIC_H : BMP_GRAPHIC)));
+ maToolbox.SetImageList( maImageList );
+ maToolbox.SetItemImage( TBI_SHAPE_FILTER, BitmapEx( SdResId( BMP_GRAPHIC ) ) );
SetDragImage();
}
@@ -1007,3 +993,5 @@ void SdPageNameControllerItem::StateChanged( sal_uInt16 nSId,
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/navigatr.src b/sd/source/ui/dlg/navigatr.src
index 5b170a5ae..b2dbf9e82 100755..100644
--- a/sd/source/ui/dlg/navigatr.src
+++ b/sd/source/ui/dlg/navigatr.src
@@ -85,8 +85,6 @@ Window FLT_NAVIGATOR
Identifier = TBI_NEXT ;
HelpId = HID_SD_NAVIGATOR_TBI_NEXT ;
//Symbol = IMAGEBUTTON_NEXT ;
- /* ### ACHTUNG: Neuer Text in Resource? Nächste Seite : Nõchste Seite */
- /* ### ACHTUNG: Neuer Text in Resource? Zur nächsten Seite springen : Zur nõchsten Seite springen */
Text [ en-US ] = "Next Slide" ;
};
ToolBoxItem
@@ -106,7 +104,6 @@ Window FLT_NAVIGATOR
HelpId = HID_SD_NAVIGATOR_TBI_DRAGTYPE ;
DropDown = TRUE ;
//Left = FALSE;
- /* ### ACHTUNG: Neuer Text in Resource? Modus für Drag & Drop auswählen : Modus f³r Drag & Drop auswõhlen */
Text [ en-US ] = "Drag Mode" ;
};
ToolBoxItem
@@ -127,7 +124,6 @@ Window FLT_NAVIGATOR
TabStop = TRUE ;
DropDown = TRUE ;
QuickHelpText [ en-US ] = "Documents" ;
- /* ### ACHTUNG: Neuer Text in Resource? Geöffnete Dokumente : Ge÷ffnete Dokumente */
};
#define NAVIGATR_IDLIST \
@@ -152,12 +148,6 @@ Window FLT_NAVIGATOR
MaskColor = IMAGE_STDBTN_COLOR ;
NAVIGATR_IDLIST
};
- ImageList ILH_NAVIGATR
- {
- Prefix = "nvh";
- MaskColor = IMAGE_STDBTN_COLOR ;
- NAVIGATR_IDLIST
- };
};
String STR_OBJECTS_TREE
diff --git a/sd/source/ui/dlg/paragr.cxx b/sd/source/ui/dlg/paragr.cxx
index bdc9355bd..9bc3f48dc 100755..100644
--- a/sd/source/ui/dlg/paragr.cxx
+++ b/sd/source/ui/dlg/paragr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,7 +95,7 @@ SfxTabPage* SdParagraphNumTabPage::Create(Window *pParent, const SfxItemSet & rA
sal_uInt16* SdParagraphNumTabPage::GetRanges()
{
- static sal_uInt16 __FAR_DATA aRange[] =
+ static sal_uInt16 aRange[] =
{
ATTR_PARANUMBERING_START, ATTR_PARANUMBERING_END,
0
@@ -190,3 +191,19 @@ SdParagraphDlg::SdParagraphDlg( Window* pParent, const SfxItemSet* pAttr )
AddTabPage( RID_SVXPAGE_TABULATOR );
}
+
+void SdParagraphDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
+{
+ SfxAllItemSet aSet(*(GetInputSetImpl()->GetPool()));
+ switch( nId )
+ {
+ case RID_SVXPAGE_STD_PARAGRAPH:
+ aSet.Put(SfxUInt32Item(SID_SVXSTDPARAGRAPHTABPAGE_ABSLINEDIST, MM50/2));
+ rPage.PageCreated(aSet);
+ break;
+ default:
+ break;
+ }
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/present.cxx b/sd/source/ui/dlg/present.cxx
index 23ed6f788..f164dcfae 100755..100644
--- a/sd/source/ui/dlg/present.cxx
+++ b/sd/source/ui/dlg/present.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -323,3 +324,4 @@ IMPL_LINK( SdStartPresentationDlg, ChangePauseHdl, void *, EMPTYARG )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/present.src b/sd/source/ui/dlg/present.src
index 5dd23ec5c..a584f5953 100644
--- a/sd/source/ui/dlg/present.src
+++ b/sd/source/ui/dlg/present.src
@@ -37,7 +37,6 @@ ModalDialog DLG_START_PRESENTATION
OutputSize = TRUE ;
SVLook = TRUE ;
Size = MAP_APPFONT ( 256, 205 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Bildschirmpräsentation : Bildschirmprõsentation */
Text [ en-US ] = "Slide Show" ;
Moveable = TRUE ;
@@ -242,7 +241,6 @@ ModalDialog DLG_START_PRESENTATION
HelpID = "sd:CheckBox:DLG_START_PRESENTATION:CBX_ALWAYS_ON_TOP";
Pos = MAP_APPFONT ( 108, 156 ) ;
Size = MAP_APPFONT ( 145, 12 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Präsentation immer im ~Vordergrund : Prõsentation immer im ~Vordergrund */
TabStop = TRUE ;
Text [ en-US ] = "Presentation always ~on top" ;
};
diff --git a/sd/source/ui/dlg/prltempl.cxx b/sd/source/ui/dlg/prltempl.cxx
index fc41a5441..0493c18b7 100755..100644
--- a/sd/source/ui/dlg/prltempl.cxx
+++ b/sd/source/ui/dlg/prltempl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,6 @@
#include "prltempl.hxx"
#include "prltempl.hrc"
#include "enumdlg.hrc"
-//#include "enumdlg.hxx"
#include "bulmaper.hxx"
#include <svl/intitem.hxx>
#include <svx/svxgrahicitem.hxx>
@@ -181,7 +181,7 @@ SdPresLayoutTemplateDlg::SdPresLayoutTemplateDlg( SfxObjectShell* pDocSh,
break;
}
- // #112490# the tabpages Alignment, Tabs and Asian Typography are very
+ // the tabpages Alignment, Tabs and Asian Typography are very
// usefull, except for the background style
if( DlgId.GetId() != TAB_PRES_LAYOUT_TEMPLATE_BACKGROUND )
{
@@ -285,7 +285,7 @@ void SdPresLayoutTemplateDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
break;
case RID_SVXPAGE_SHADOW:
- aSet.Put (SvxColorTableItem(pColorTab,SID_COLOR_TABLE)); //add CHINA001
+ aSet.Put (SvxColorTableItem(pColorTab,SID_COLOR_TABLE));
aSet.Put (SfxUInt16Item(SID_PAGE_TYPE,nPageType));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nDlgType));
rPage.PageCreated(aSet);
@@ -355,3 +355,4 @@ sal_uInt16 SdPresLayoutTemplateDlg::GetOutlineLevel() const
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/prntopts.cxx b/sd/source/ui/dlg/prntopts.cxx
index 39b026c49..299c093a9 100755..100644
--- a/sd/source/ui/dlg/prntopts.cxx
+++ b/sd/source/ui/dlg/prntopts.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -259,9 +260,6 @@ void SdPrintOptions::updateControls()
aCbxPagename.Enable( !aRbtBooklet.IsChecked() && (aCbxDraw.IsChecked() || aCbxNotes.IsChecked() || aCbxOutline.IsChecked()) );
}
-/* -----------------------------04.05.01 10:53--------------------------------
-
- ---------------------------------------------------------------------------*/
void lcl_MoveRB_Impl(Window& rBtn, long nXDiff)
{
Point aPos(rBtn.GetPosPixel());
@@ -312,3 +310,4 @@ void SdPrintOptions::PageCreated (SfxAllItemSet
#endif
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sdabstdlg.cxx b/sd/source/ui/dlg/sdabstdlg.cxx
index f0c6d816a..c4daa172a 100644
--- a/sd/source/ui/dlg/sdabstdlg.cxx
+++ b/sd/source/ui/dlg/sdabstdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,10 +30,10 @@
#include "precompiled_sd.hxx"
#include "sdabstdlg.hxx"
-#include "sduilib.hxx"
#include <osl/module.hxx>
#include <tools/string.hxx>
+#include <vcl/unohelp.hxx>
typedef SdAbstractDialogFactory* (__LOADONCALLAPI *SdFuncPtrCreateDialogFactory)();
@@ -42,12 +43,14 @@ SdAbstractDialogFactory* SdAbstractDialogFactory::Create()
{
SdFuncPtrCreateDialogFactory fp = 0;
static ::osl::Module aDialogLibrary;
- if ( aDialogLibrary.is() || aDialogLibrary.loadRelative( &thisModule, String( RTL_CONSTASCII_USTRINGPARAM( DLL_NAME ) ) ) )
+ static const ::rtl::OUString sLibName(::vcl::unohelper::CreateLibraryName("sdui", sal_True));
+ if ( aDialogLibrary.is() || aDialogLibrary.loadRelative( &thisModule, sLibName ) )
fp = ( SdAbstractDialogFactory* (__LOADONCALLAPI*)() )
- aDialogLibrary.getFunctionSymbol( ::rtl::OUString::createFromAscii("CreateDialogFactory") );
+ aDialogLibrary.getFunctionSymbol( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CreateDialogFactory")) );
if ( fp )
return fp();
return 0;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sddlgfact.cxx b/sd/source/ui/dlg/sddlgfact.cxx
index d4f96f666..90c60c9b0 100755..100644
--- a/sd/source/ui/dlg/sddlgfact.cxx
+++ b/sd/source/ui/dlg/sddlgfact.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -562,3 +563,4 @@ AbstractHeaderFooterDialog* SdAbstractDialogFactory_Impl::CreateHeaderFooterDial
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sddlgfact.hxx b/sd/source/ui/dlg/sddlgfact.hxx
index 0dee2f7b8..d227e774f 100755..100644
--- a/sd/source/ui/dlg/sddlgfact.hxx
+++ b/sd/source/ui/dlg/sddlgfact.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -298,3 +299,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sdpreslt.cxx b/sd/source/ui/dlg/sdpreslt.cxx
index 7ede5b53e..7668941f1 100755..100644
--- a/sd/source/ui/dlg/sdpreslt.cxx
+++ b/sd/source/ui/dlg/sdpreslt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -244,7 +245,7 @@ IMPL_LINK(SdPresLayoutDlg, ClickLoadHdl, void *, EMPTYARG)
}
sal_uInt16 nResult = pDlg->Execute();
- // #96072# OJ: Inserted update to force repaint
+ // Inserted update to force repaint
Update();
String aFile;
@@ -271,9 +272,6 @@ IMPL_LINK(SdPresLayoutDlg, ClickLoadHdl, void *, EMPTYARG)
}
delete pDlg;
-// if (!bCancel)
-// EndDialog(RET_OK);
-
if( !bCancel )
{
// Pruefen, ob Vorlage schon vorhanden
@@ -308,12 +306,6 @@ IMPL_LINK(SdPresLayoutDlg, ClickLoadHdl, void *, EMPTYARG)
{
::sd::DrawDocShell* pTemplDocSh= pTemplDoc->GetDocSh();
-/* SdPage* pMaster = pTemplDoc->GetMasterSdPage( 0, PK_STANDARD );
- mpLayoutNames->Insert( new String( maName ), LIST_APPEND );
-
- Bitmap aBitmap( pTemplDocSh->GetPagePreviewBitmap( pMaster, 90 ) );
- maVS.InsertItem( (sal_uInt16) mpLayoutNames->Count(), aBitmap, maName);
-*/
sal_uInt16 nCount = pTemplDoc->GetMasterPageCount();
for (sal_uInt16 nLayout = 0; nLayout < nCount; nLayout++)
@@ -355,3 +347,5 @@ IMPL_LINK(SdPresLayoutDlg, ClickLoadHdl, void *, EMPTYARG)
return( 0 );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sdpreslt.src b/sd/source/ui/dlg/sdpreslt.src
index 331998875..5095e6436 100644
--- a/sd/source/ui/dlg/sdpreslt.src
+++ b/sd/source/ui/dlg/sdpreslt.src
@@ -40,7 +40,6 @@ ModalDialog DLG_PRESLT
{
Pos = MAP_APPFONT ( 6 , 3 ) ;
Size = MAP_APPFONT ( 110 , 10 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Wählen Sie eine ~Seitenvorlage : Wõhlen Sie eine ~Seitenvorlage */
Text [ en-US ] = "~Select a slide design" ;
};
Control VS_LAYOUT
diff --git a/sd/source/ui/dlg/sdtreelb.cxx b/sd/source/ui/dlg/sdtreelb.cxx
index 8ec67bba1..bd6e2fae8 100755..100644
--- a/sd/source/ui/dlg/sdtreelb.cxx
+++ b/sd/source/ui/dlg/sdtreelb.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -49,14 +50,13 @@
#include "sdpage.hxx"
#include "sdresid.hxx"
#include "navigatr.hxx"
-#ifndef _SD_CFGID_HXX
#include "strings.hrc"
-#endif
#include "res_bmp.hrc"
#include <com/sun/star/embed/XEmbedPersist.hpp>
#include <svtools/embedtransfer.hxx>
#include <tools/diagnose_ex.h>
+#include <comphelper/servicehelper.hxx>
#include <ViewShell.hxx>
using namespace com::sun::star;
@@ -73,22 +73,14 @@ public:
Image maImgPageObjs;
Image maImgObjects;
Image maImgGroup;
-
- // High contrast icons.
- Image maImgPageH;
- Image maImgPageExclH;
- Image maImgPageObjsExclH;
- Image maImgPageObjsH;
- Image maImgObjectsH;
- Image maImgGroupH;
};
sal_Bool SD_DLLPRIVATE SdPageObjsTLB::bIsInDrag = sal_False;
sal_Bool SdPageObjsTLB::IsInDrag()
-{
- return bIsInDrag;
+{
+ return bIsInDrag;
}
sal_uInt32 SdPageObjsTLB::SdPageObjsTransferable::mnListBoxDropFormatId = SAL_MAX_UINT32;
@@ -97,8 +89,8 @@ sal_uInt32 SdPageObjsTLB::SdPageObjsTransferable::mnListBoxDropFormatId = SAL_MA
// - SdPageObjsTLB::SdPageObjsTransferable -
// -----------------------------------------
-SdPageObjsTLB::SdPageObjsTransferable::SdPageObjsTransferable(
- SdPageObjsTLB& rParent,
+SdPageObjsTLB::SdPageObjsTransferable::SdPageObjsTransferable(
+ SdPageObjsTLB& rParent,
const INetBookmark& rBookmark,
::sd::DrawDocShell& rDocShell,
NavigatorDragType eDragType,
@@ -110,7 +102,7 @@ SdPageObjsTLB::SdPageObjsTransferable::SdPageObjsTransferable(
meDragType( eDragType ),
maTreeListBoxData( rTreeListBoxData )
{
-}
+}
@@ -122,7 +114,7 @@ SdPageObjsTLB::SdPageObjsTransferable::~SdPageObjsTransferable()
// -----------------------------------------------------------------------------
void SdPageObjsTLB::SdPageObjsTransferable::AddSupportedFormats()
-{
+{
AddFormat(SOT_FORMATSTR_ID_NETSCAPE_BOOKMARK);
AddFormat(SOT_FORMATSTR_ID_TREELISTBOX);
AddFormat(GetListBoxDropFormatId());
@@ -186,22 +178,14 @@ sal_Int64 SAL_CALL SdPageObjsTLB::SdPageObjsTransferable::getSomething( const ::
return nRet;
}
-// -----------------------------------------------------------------------------
+namespace
+{
+ class theSdPageObjsTLBUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSdPageObjsTLBUnoTunnelId > {};
+}
const ::com::sun::star::uno::Sequence< sal_Int8 >& SdPageObjsTLB::SdPageObjsTransferable::getUnoTunnelId()
{
- static ::com::sun::star::uno::Sequence< sal_Int8 > aSeq;
-
- if( !aSeq.getLength() )
- {
- static osl::Mutex aCreateMutex;
- osl::MutexGuard aGuard( aCreateMutex );
-
- aSeq.realloc( 16 );
- rtl_createUuid( reinterpret_cast< sal_uInt8* >( aSeq.getArray() ), 0, sal_True );
- }
-
- return aSeq;
+ return theSdPageObjsTLBUnoTunnelId::get().getSeq();
}
// -----------------------------------------------------------------------------
@@ -228,9 +212,9 @@ sal_uInt32 SdPageObjsTLB::SdPageObjsTransferable::GetListBoxDropFormatId (void)
{
if (mnListBoxDropFormatId == SAL_MAX_UINT32)
mnListBoxDropFormatId = SotExchange::RegisterFormatMimeType(
- ::rtl::OUString::createFromAscii(
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
"application/x-openoffice-treelistbox-moveonly;"
- "windows_formatname=\"SV_LBOX_DD_FORMAT_MOVE\""));
+ "windows_formatname=\"SV_LBOX_DD_FORMAT_MOVE\"")));
return mnListBoxDropFormatId;
}
@@ -240,7 +224,7 @@ sal_uInt32 SdPageObjsTLB::SdPageObjsTransferable::GetListBoxDropFormatId (void)
|*
\************************************************************************/
-SdPageObjsTLB::SdPageObjsTLB( Window* pParentWin, const SdResId& rSdResId )
+SdPageObjsTLB::SdPageObjsTLB( Window* pParentWin, const SdResId& rSdResId )
: SvTreeListBox ( pParentWin, rSdResId )
, mpParent ( pParentWin )
, mpDoc ( NULL )
@@ -249,8 +233,6 @@ SdPageObjsTLB::SdPageObjsTLB( Window* pParentWin, const SdResId& rSdResId )
, mpOwnMedium ( NULL )
, maImgOle ( BitmapEx( SdResId( BMP_OLE ) ) )
, maImgGraphic ( BitmapEx( SdResId( BMP_GRAPHIC ) ) )
-, maImgOleH ( BitmapEx( SdResId( BMP_OLE_H ) ) )
-, maImgGraphicH ( BitmapEx( SdResId( BMP_GRAPHIC_H ) ) )
, mbLinkableSelected ( sal_False )
, mpDropNavWin ( NULL )
, mbShowAllShapes ( false )
@@ -260,16 +242,12 @@ SdPageObjsTLB::SdPageObjsTLB( Window* pParentWin, const SdResId& rSdResId )
// Tree-ListBox mit Linien versehen
SetStyle( GetStyle() | WB_TABSTOP | WB_BORDER | WB_HASLINES |
WB_HASBUTTONS | // WB_HASLINESATROOT |
- WB_HSCROLL | // #31562#
+ WB_HSCROLL |
WB_HASBUTTONSATROOT |
WB_QUICK_SEARCH /* i31275 */ );
SetNodeBitmaps( Bitmap( SdResId( BMP_EXPAND ) ),
Bitmap( SdResId( BMP_COLLAPSE ) ) );
- SetNodeBitmaps( Bitmap( SdResId( BMP_EXPAND_H ) ),
- Bitmap( SdResId( BMP_COLLAPSE_H ) ),
- BMP_COLOR_HIGHCONTRAST );
-
SetDragDropMode(
SV_DRAGDROP_CTRL_MOVE | SV_DRAGDROP_CTRL_COPY |
SV_DRAGDROP_APP_MOVE | SV_DRAGDROP_APP_COPY | SV_DRAGDROP_APP_DROP );
@@ -462,20 +440,11 @@ void SdPageObjsTLB::Fill( const SdDrawDocument* pInDoc, SfxMedium* pInMedium,
Image aImgDocOpen=Image( BitmapEx( SdResId( BMP_DOC_OPEN ) ) );
Image aImgDocClosed=Image( BitmapEx( SdResId( BMP_DOC_CLOSED ) ) );
- Image aImgDocOpenH=Image( BitmapEx( SdResId( BMP_DOC_OPEN_H ) ) );
- Image aImgDocClosedH=Image( BitmapEx( SdResId( BMP_DOC_CLOSED_H ) ) );
// Dokumentnamen einfuegen
- SvLBoxEntry* pFileEntry = InsertEntry( maDocName,
- aImgDocOpen,
- aImgDocClosed,
- NULL,
- sal_True,
- LIST_APPEND,
- reinterpret_cast< void* >( 1 ) );
-
- SetExpandedEntryBmp( pFileEntry, aImgDocOpenH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pFileEntry, aImgDocClosedH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry( maDocName, aImgDocOpen, aImgDocClosed, NULL, sal_True, LIST_APPEND,
+ reinterpret_cast< void* >( 1 )
+ );
}
@@ -508,15 +477,6 @@ void SdPageObjsTLB::AddShapeList (
LIST_APPEND,
pUserData);
- SetExpandedEntryBmp(
- pEntry,
- bIsExcluded ? rIconProvider.maImgPageExclH : rIconProvider.maImgPageH,
- BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp(
- pEntry,
- bIsExcluded ? rIconProvider.maImgPageExclH : rIconProvider.maImgPageH,
- BMP_COLOR_HIGHCONTRAST );
-
SdrObjListIter aIter(
rList,
!rList.HasObjectNavigationOrder() /* use navigation order, if available */,
@@ -535,19 +495,27 @@ void SdPageObjsTLB::AddShapeList (
{
if( pObj->GetObjInventor() == SdrInventor && pObj->GetObjIdentifier() == OBJ_OLE2 )
{
- SvLBoxEntry* pNewEntry = InsertEntry( aStr, maImgOle, maImgOle, pEntry,
- sal_False, LIST_APPEND, pObj);
-
- SetExpandedEntryBmp( pNewEntry, maImgOleH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, maImgOleH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(
+ aStr,
+ maImgOle,
+ maImgOle,
+ pEntry,
+ sal_False,
+ LIST_APPEND,
+ pObj
+ );
}
else if( pObj->GetObjInventor() == SdrInventor && pObj->GetObjIdentifier() == OBJ_GRAF )
{
- SvLBoxEntry* pNewEntry = InsertEntry( aStr, maImgGraphic, maImgGraphic, pEntry,
- sal_False, LIST_APPEND, pObj );
-
- SetExpandedEntryBmp( pNewEntry, maImgGraphicH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, maImgGraphicH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(
+ aStr,
+ maImgGraphic,
+ maImgGraphic,
+ pEntry,
+ sal_False,
+ LIST_APPEND,
+ pObj
+ );
}
else if (pObj->IsGroupObject())
{
@@ -557,15 +525,20 @@ void SdPageObjsTLB::AddShapeList (
aStr,
false,
pEntry,
- rIconProvider);
+ rIconProvider
+ );
}
else
{
- SvLBoxEntry* pNewEntry = InsertEntry( aStr, rIconProvider.maImgObjects, rIconProvider.maImgObjects, pEntry,
- sal_False, LIST_APPEND, pObj );
-
- SetExpandedEntryBmp( pNewEntry, rIconProvider.maImgObjectsH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, rIconProvider.maImgObjectsH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(
+ aStr,
+ rIconProvider.maImgObjects,
+ rIconProvider.maImgObjects,
+ pEntry,
+ sal_False,
+ LIST_APPEND,
+ pObj
+ );
}
}
}
@@ -578,14 +551,6 @@ void SdPageObjsTLB::AddShapeList (
SetCollapsedEntryBmp(
pEntry,
bIsExcluded ? rIconProvider.maImgPageObjsExcl : rIconProvider.maImgPageObjs);
- SetExpandedEntryBmp(
- pEntry,
- bIsExcluded ? rIconProvider.maImgPageObjsExclH : rIconProvider.maImgPageObjsH,
- BMP_COLOR_HIGHCONTRAST);
- SetCollapsedEntryBmp(
- pEntry,
- bIsExcluded ? rIconProvider.maImgPageObjsExclH : rIconProvider.maImgPageObjsH,
- BMP_COLOR_HIGHCONTRAST);
}
}
@@ -746,12 +711,9 @@ void SdPageObjsTLB::RequestingChilds( SvLBoxEntry* pFileEntry )
SdPage* pPage = NULL;
SvLBoxEntry* pPageEntry = NULL;
- Image aImgPage=Image( BitmapEx( SdResId( BMP_PAGE ) ) );
- Image aImgPageObjs=Image( BitmapEx( SdResId( BMP_PAGEOBJS ) ) );
- Image aImgObjects=Image( BitmapEx( SdResId( BMP_OBJECTS ) ) );
- Image aImgPageH=Image( BitmapEx( SdResId( BMP_PAGE_H ) ) );
- Image aImgPageObjsH=Image( BitmapEx( SdResId( BMP_PAGEOBJS_H ) ) );
- Image aImgObjectsH=Image( BitmapEx( SdResId( BMP_OBJECTS_H ) ) );
+ Image aImgPage = Image( BitmapEx( SdResId( BMP_PAGE ) ) );
+ Image aImgPageObjs = Image( BitmapEx( SdResId( BMP_PAGEOBJS ) ) );
+ Image aImgObjects = Image( BitmapEx( SdResId( BMP_OBJECTS ) ) );
// document name already inserted
@@ -772,9 +734,6 @@ void SdPageObjsTLB::RequestingChilds( SvLBoxEntry* pFileEntry )
LIST_APPEND,
reinterpret_cast< void* >( 1 ) );
- SetExpandedEntryBmp( pPageEntry, aImgPageH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pPageEntry, aImgPageH, BMP_COLOR_HIGHCONTRAST );
-
SdrObjListIter aIter( *pPage, IM_DEEPWITHGROUPS );
while( aIter.IsMore() )
@@ -785,34 +744,22 @@ void SdPageObjsTLB::RequestingChilds( SvLBoxEntry* pFileEntry )
{
if( pObj->GetObjInventor() == SdrInventor && pObj->GetObjIdentifier() == OBJ_OLE2 )
{
- SvLBoxEntry* pNewEntry = InsertEntry(aStr, maImgOle, maImgOle, pPageEntry);
-
-
- SetExpandedEntryBmp( pNewEntry, maImgOleH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, maImgOleH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(aStr, maImgOle, maImgOle, pPageEntry);
}
else if( pObj->GetObjInventor() == SdrInventor && pObj->GetObjIdentifier() == OBJ_GRAF )
{
- SvLBoxEntry* pNewEntry = InsertEntry(aStr, maImgGraphic, maImgGraphic, pPageEntry);
-
- SetExpandedEntryBmp( pNewEntry, maImgGraphicH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, maImgGraphicH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(aStr, maImgGraphic, maImgGraphic, pPageEntry);
}
else
{
- SvLBoxEntry* pNewEntry = InsertEntry(aStr, aImgObjects, aImgObjects, pPageEntry);
-
- SetExpandedEntryBmp( pNewEntry, aImgObjectsH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pNewEntry, aImgObjectsH, BMP_COLOR_HIGHCONTRAST );
+ InsertEntry(aStr, aImgObjects, aImgObjects, pPageEntry);
}
}
}
if( pPageEntry->HasChilds() )
{
- SetExpandedEntryBmp( pPageEntry, aImgPageObjs );
+ SetExpandedEntryBmp( pPageEntry, aImgPageObjs );
SetCollapsedEntryBmp( pPageEntry, aImgPageObjs );
- SetExpandedEntryBmp( pPageEntry, aImgPageObjsH, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pPageEntry, aImgPageObjsH, BMP_COLOR_HIGHCONTRAST );
}
}
nPage++;
@@ -884,7 +831,7 @@ SdDrawDocument* SdPageObjsTLB::GetBookmarkDoc(SfxMedium* pMed)
/*************************************************************************
|*
-|* Bookmark-Dokument schlieáen und loeschen
+|* Bookmark-Dokument schlie�en und loeschen
|*
\************************************************************************/
@@ -918,12 +865,6 @@ void SdPageObjsTLB::CloseBookmarkDoc()
mpBookmarkDoc = NULL;
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void SdPageObjsTLB::SelectHdl()
{
SvLBoxEntry* pEntry = FirstSelected();
@@ -1048,7 +989,7 @@ void SdPageObjsTLB::DoDrag()
sal_Int8 nDNDActions = DND_ACTION_COPYMOVE;
if( eDragType == NAVIGATOR_DRAGTYPE_LINK )
- nDNDActions = DND_ACTION_LINK; // #93240# Either COPY *or* LINK, never both!
+ nDNDActions = DND_ACTION_LINK; // Either COPY *or* LINK, never both!
SvTreeListBox::ReleaseMouse();
@@ -1337,7 +1278,7 @@ SvLBoxEntry* SdPageObjsTLB::GetDropTarget (const Point& rLocation)
if (pEntry == NULL)
return NULL;
- OSL_TRACE("entry is %s",
+ OSL_TRACE("entry is %s",
::rtl::OUStringToOString(GetEntryText(pEntry), RTL_TEXTENCODING_UTF8).getStr());
if (GetParent(pEntry) == NULL)
{
@@ -1361,7 +1302,7 @@ SvLBoxEntry* SdPageObjsTLB::GetDropTarget (const Point& rLocation)
else
break;
}
- OSL_TRACE("returning %s",
+ OSL_TRACE("returning %s",
::rtl::OUStringToOString(GetEntryText(pEntry), RTL_TEXTENCODING_UTF8).getStr());
}
@@ -1449,13 +1390,8 @@ SdPageObjsTLB::IconProvider::IconProvider (void)
maImgPageObjsExcl( BitmapEx( SdResId( BMP_PAGEOBJS_EXCLUDED ) ) ),
maImgPageObjs( BitmapEx( SdResId( BMP_PAGEOBJS ) ) ),
maImgObjects( BitmapEx( SdResId( BMP_OBJECTS ) ) ),
- maImgGroup( BitmapEx( SdResId( BMP_GROUP ) ) ),
-
- maImgPageH( BitmapEx( SdResId( BMP_PAGE_H ) ) ),
- maImgPageExclH( BitmapEx( SdResId( BMP_PAGE_EXCLUDED_H ) ) ),
- maImgPageObjsExclH( BitmapEx( SdResId( BMP_PAGEOBJS_EXCLUDED_H ) ) ),
- maImgPageObjsH( BitmapEx( SdResId( BMP_PAGEOBJS_H ) ) ),
- maImgObjectsH( BitmapEx( SdResId( BMP_OBJECTS_H ) ) ),
- maImgGroupH( BitmapEx( SdResId( BMP_GROUP_H ) ) )
+ maImgGroup( BitmapEx( SdResId( BMP_GROUP ) ) )
{
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/sduiexp.cxx b/sd/source/ui/dlg/sduiexp.cxx
index 6f94ff853..3f538839a 100644
--- a/sd/source/ui/dlg/sduiexp.cxx
+++ b/sd/source/ui/dlg/sduiexp.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,21 +36,13 @@
#include "sddlgfact.hxx"
#include "sal/types.h"
-namespace sdui
-{
- static SdAbstractDialogFactory_Impl* pFactory=NULL;
- SdAbstractDialogFactory_Impl* GetFactory()
- {
- if ( !pFactory )
- pFactory = new SdAbstractDialogFactory_Impl;
- return pFactory;
- }
-}
-
extern "C"
{
SAL_DLLPUBLIC_EXPORT SdAbstractDialogFactory* CreateDialogFactory()
{
- return ::sdui::GetFactory();
+ static SdAbstractDialogFactory_Impl aFactory;
+ return &aFactory;
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/tabtempl.cxx b/sd/source/ui/dlg/tabtempl.cxx
index 88dd8e07a..1e4b0d815 100755..100644
--- a/sd/source/ui/dlg/tabtempl.cxx
+++ b/sd/source/ui/dlg/tabtempl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -148,7 +149,7 @@ void SdTabTemplateDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
break;
case RID_SVXPAGE_SHADOW:
- aSet.Put (SvxColorTableItem(pColorTab,SID_COLOR_TABLE)); //add CHINA001
+ aSet.Put (SvxColorTableItem(pColorTab,SID_COLOR_TABLE));
aSet.Put (SfxUInt16Item(SID_PAGE_TYPE,nPageType));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nDlgType));
rPage.PageCreated(aSet);
@@ -221,3 +222,4 @@ const SfxItemSet* SdTabTemplateDlg::GetRefreshedSet()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/tabtempl.src b/sd/source/ui/dlg/tabtempl.src
index 558fd3811..5d9134d06 100644
--- a/sd/source/ui/dlg/tabtempl.src
+++ b/sd/source/ui/dlg/tabtempl.src
@@ -51,7 +51,6 @@ TabDialog TAB_TEMPLATE
PageItem
{
Identifier = RID_SVXPAGE_AREA ;
- /* ### ACHTUNG: Neuer Text in Resource? Fläche : Flõche */
Text [ en-US ] = "Area" ;
PageResID = RID_SVXPAGE_AREA ;
};
@@ -81,7 +80,6 @@ TabDialog TAB_TEMPLATE
PageItem
{
Identifier = RID_SVXPAGE_STD_PARAGRAPH ;
- /* ### ACHTUNG: Neuer Text in Resource? Einzüge und Abstände : Einz³ge und Abstõnde */
Text [ en-US ] = "Indents & Spacing" ;
PageResID = RID_SVXPAGE_STD_PARAGRAPH ;
};
@@ -100,7 +98,6 @@ TabDialog TAB_TEMPLATE
PageItem
{
Identifier = RID_SVXPAGE_MEASURE ;
- /* ### ACHTUNG: Neuer Text in Resource? Bemaßung : Bema˜ung */
Text [ en-US ] = "Dimensioning" ;
PageResID = RID_SVXPAGE_MEASURE ;
};
@@ -151,7 +148,6 @@ TabDialog TAB_TEMPLATE
{
Pos = MAP_APPFONT ( 169 , 151 ) ;
Size = MAP_APPFONT ( 50 , 14 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Zurück : Zur³ck */
Text [ en-US ] = "Back" ;
TabStop = TRUE ;
};
diff --git a/sd/source/ui/dlg/tpaction.cxx b/sd/source/ui/dlg/tpaction.cxx
index 90db23db3..ecfc89c79 100755..100644
--- a/sd/source/ui/dlg/tpaction.cxx
+++ b/sd/source/ui/dlg/tpaction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,9 +37,7 @@
#include <com/sun/star/presentation/AnimationEffect.hpp>
#include <com/sun/star/presentation/ClickAction.hpp>
#include <com/sun/star/presentation/AnimationSpeed.hpp>
-#ifndef _COM_SUN_STAR_EMBED_VERBDESCR_HPP_
#include <com/sun/star/embed/VerbDescriptor.hpp>
-#endif
#include <com/sun/star/embed/EmbedStates.hpp>
#include <com/sun/star/uri/XUriReferenceFactory.hpp>
#include <com/sun/star/uri/XVndSunStarScriptUrl.hpp>
@@ -195,7 +194,7 @@ void SdTPAction::SetView( const ::sd::View* pSdView )
}
else
{
- DBG_ERROR("sd::SdTPAction::SetView(), no docshell or viewshell?");
+ OSL_FAIL("sd::SdTPAction::SetView(), no docshell or viewshell?");
}
}
@@ -229,11 +228,6 @@ void SdTPAction::Construct()
{
pGrafObj = (SdrGrafObj*) pObj;
}
-// // VCXControl ?
-// else if( pObj->IsA( TYPE( VCSbxDrawObject ) ) )
-// {
-// bDisableAll = sal_True;
-// }
}
}
if( pGrafObj )
@@ -335,7 +329,7 @@ sal_Bool SdTPAction::FillItemSet( SfxItemSet& rAttrs )
}
else
{
- DBG_ERROR("sd::SdTPAction::FillItemSet(), I need a medium!");
+ OSL_FAIL("sd::SdTPAction::FillItemSet(), I need a medium!");
}
}
@@ -487,8 +481,8 @@ void SdTPAction::OpenFileDialog()
aFileDialog.SetDisplayDirectory( aFile );
- // The following is a fix for #1008001# and a workarround for
- // #i4306#: The addition of the implicitely existing "all files"
+ // The following is a workarround for #i4306#:
+ // The addition of the implicitely existing "all files"
// filter makes the (Windows system) open file dialog follow
// links on the desktop to directories.
aFileDialog.AddFilter (
@@ -921,8 +915,9 @@ sal_uInt16 SdTPAction::GetClickActionSdResId( presentation::ClickAction eCA )
case presentation::ClickAction_SOUND: return STR_CLICK_ACTION_SOUND;
case presentation::ClickAction_VERB: return STR_CLICK_ACTION_VERB;
case presentation::ClickAction_STOPPRESENTATION: return STR_CLICK_ACTION_STOPPRESENTATION;
- default: DBG_ERROR( "Keine StringResource fuer ClickAction vorhanden!" );
+ default: OSL_FAIL( "Keine StringResource fuer ClickAction vorhanden!" );
}
return( 0 );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/tpaction.src b/sd/source/ui/dlg/tpaction.src
index e08f6401c..e08f6401c 100755..100644
--- a/sd/source/ui/dlg/tpaction.src
+++ b/sd/source/ui/dlg/tpaction.src
diff --git a/sd/source/ui/dlg/tpoption.cxx b/sd/source/ui/dlg/tpoption.cxx
index 2410e76c2..dd7c931f0 100755..100644
--- a/sd/source/ui/dlg/tpoption.cxx
+++ b/sd/source/ui/dlg/tpoption.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -100,9 +101,6 @@ sal_Bool SdTpOptionsSnap::FillItemSet( SfxItemSet& rAttrs )
{
SvxGridTabPage::FillItemSet(rAttrs);
SdOptionsSnapItem* pOptsItem = NULL;
-// if(SFX_ITEM_SET != rAttrs.GetItemState( ATTR_OPTIONS_SNAP, sal_False, (const SfxPoolItem**)&pOptsItem ))
-// pExampleSet->GetItemState( ATTR_OPTIONS_SNAP, sal_False, (const SfxPoolItem**)&pOptsItem );
-
SdOptionsSnapItem aOptsItem( ATTR_OPTIONS_SNAP );
aOptsItem.GetOptionsSnap().SetSnapHelplines( aCbxSnapHelplines.IsChecked() );
@@ -187,7 +185,6 @@ sal_Bool SdTpOptionsContents::FillItemSet( SfxItemSet& rAttrs )
if( aCbxRuler.GetSavedValue() != aCbxRuler.IsChecked() ||
aCbxMoveOutline.GetSavedValue() != aCbxMoveOutline.IsChecked() ||
aCbxDragStripes.GetSavedValue() != aCbxDragStripes.IsChecked() ||
- //aCbxHelplines.GetSavedValue() != aCbxHelplines.IsChecked() ||
aCbxHandlesBezier.GetSavedValue() != aCbxHandlesBezier.IsChecked() )
{
SdOptionsLayoutItem aOptsItem( ATTR_OPTIONS_LAYOUT );
@@ -196,7 +193,6 @@ sal_Bool SdTpOptionsContents::FillItemSet( SfxItemSet& rAttrs )
aOptsItem.GetOptionsLayout().SetMoveOutline( aCbxMoveOutline.IsChecked() );
aOptsItem.GetOptionsLayout().SetDragStripes( aCbxDragStripes.IsChecked() );
aOptsItem.GetOptionsLayout().SetHandlesBezier( aCbxHandlesBezier.IsChecked() );
- //aOptsItem.GetOptionsLayout().SetHelplines( aCbxHelplines.IsChecked() );
rAttrs.Put( aOptsItem );
bModified = sal_True;
@@ -218,13 +214,11 @@ void SdTpOptionsContents::Reset( const SfxItemSet& rAttrs )
aCbxMoveOutline.Check( aLayoutItem.GetOptionsLayout().IsMoveOutline() );
aCbxDragStripes.Check( aLayoutItem.GetOptionsLayout().IsDragStripes() );
aCbxHandlesBezier.Check( aLayoutItem.GetOptionsLayout().IsHandlesBezier() );
- //aCbxHelplines.Check( aLayoutItem.GetOptionsLayout().IsHelplines() );
aCbxRuler.SaveValue();
aCbxMoveOutline.SaveValue();
aCbxDragStripes.SaveValue();
aCbxHandlesBezier.SaveValue();
- //aCbxHelplines.SaveValue();
}
// -----------------------------------------------------------------------
@@ -556,7 +550,6 @@ void SdTpOptionsMisc::Reset( const SfxItemSet& rAttrs )
aCbScale.SetText( GetScale( nX, nY ) );
- // #92067# broken feature disabled for 6.0
aFtOriginal.Hide();
aFtEquivalent.Hide();
aMtrFldOriginalWidth.Hide();
@@ -731,7 +724,7 @@ IMPL_LINK( SdTpOptionsMisc, ModifyOriginalScaleHdl, void *, EMPTYARG )
aFract = Fraction( aFract1.GetDenominator(), aFract1.GetNumerator() );
nValue = aFract;
- // #92067# Swap nominator and denominator
+ // Swap nominator and denominator
aCbScale.SetText( GetScale( nValue, 1 ) );
}
else
@@ -741,7 +734,7 @@ IMPL_LINK( SdTpOptionsMisc, ModifyOriginalScaleHdl, void *, EMPTYARG )
if( fValue > (double)nValue )
nValue++;
- // #92067# Swap nominator and denominator
+ // Swap nominator and denominator
aCbScale.SetText( GetScale( 1, nValue ) );
}
return( 0L );
@@ -804,7 +797,7 @@ void SdTpOptionsMisc::UpdateCompatibilityControls (void)
break;
Reference<frame::XDesktop> xDesktop (xFactory->createInstance (
- ::rtl::OUString::createFromAscii("com.sun.star.frame.Desktop")), UNO_QUERY);
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop"))), UNO_QUERY);
if ( ! xDesktop.is())
break;
@@ -856,3 +849,4 @@ void SdTpOptionsMisc::PageCreated (SfxAllItemSet aSet)
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/tpoption.src b/sd/source/ui/dlg/tpoption.src
index 23c8d9d6b..59baa9cae 100644
--- a/sd/source/ui/dlg/tpoption.src
+++ b/sd/source/ui/dlg/tpoption.src
@@ -47,7 +47,7 @@ TabPage TP_OPTIONS_CONTENTS
{
HelpID = "sd:CheckBox:TP_OPTIONS_CONTENTS:CBX_RULER";
Pos = MAP_APPFONT ( 12 , 83 - 69 ) ;
- Size = MAP_APPFONT ( 242 , 10 ) ;
+ Size = MAP_APPFONT ( 160 , 10 ) ;
TabStop = TRUE ;
Text [ en-US ] = "~Rulers visible" ;
};
@@ -55,15 +55,15 @@ TabPage TP_OPTIONS_CONTENTS
{
HelpID = "sd:CheckBox:TP_OPTIONS_CONTENTS:CBX_HELPLINES";
Pos = MAP_APPFONT ( 12 , 97 - 69 ) ;
- Size = MAP_APPFONT ( 242 , 10 ) ;
+ Size = MAP_APPFONT ( 160 , 10 ) ;
TabStop = TRUE ;
- Text [ en-US ] = "~Guides when moving" ;
+ Text [ en-US ] = "~Snap Lines when moving" ;
};
CheckBox CBX_HANDLES_BEZIER
{
HelpID = "sd:CheckBox:TP_OPTIONS_CONTENTS:CBX_HANDLES_BEZIER";
Pos = MAP_APPFONT ( 12 , 111 - 69 ) ;
- Size = MAP_APPFONT ( 242 , 10 ) ;
+ Size = MAP_APPFONT ( 160 , 10 ) ;
TabStop = TRUE ;
Text [ en-US ] = "~All control points in Bézier editor" ;
};
@@ -71,7 +71,7 @@ TabPage TP_OPTIONS_CONTENTS
{
HelpID = "sd:CheckBox:TP_OPTIONS_CONTENTS:CBX_MOVE_OUTLINE";
Pos = MAP_APPFONT ( 12 , 125 - 69 ) ;
- Size = MAP_APPFONT ( 242 , 10 ) ;
+ Size = MAP_APPFONT ( 160 , 10 ) ;
TabStop = TRUE ;
Text [ en-US ] = "~Contour of each individual object" ;
};
diff --git a/sd/source/ui/dlg/unchss.cxx b/sd/source/ui/dlg/unchss.cxx
index 080a2bee7..fe8067fe4 100755..100644
--- a/sd/source/ui/dlg/unchss.cxx
+++ b/sd/source/ui/dlg/unchss.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -176,3 +177,5 @@ String StyleSheetUndoAction::GetComment() const
{
return aComment;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/vectdlg.cxx b/sd/source/ui/dlg/vectdlg.cxx
index 99f984dc1..fb3e07265 100755..100644
--- a/sd/source/ui/dlg/vectdlg.cxx
+++ b/sd/source/ui/dlg/vectdlg.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -57,7 +58,7 @@
// - SdVectorizeDlg -
// ------------------
-SdVectorizeDlg::SdVectorizeDlg(
+SdVectorizeDlg::SdVectorizeDlg(
Window* pParent, const Bitmap& rBmp, ::sd::DrawDocShell* pDocShell ) :
ModalDialog ( pParent, SdResId( DLG_VECTORIZE ) ),
mpDocSh ( pDocShell ),
@@ -228,7 +229,7 @@ void SdVectorizeDlg::Calculate( Bitmap& rBmp, GDIMetaFile& rMtf )
aTmp.ReleaseAccess( pRAcc );
- for( sal_uLong n = 0UL, nCount = rMtf.GetActionCount(); n < nCount; n++ )
+ for( size_t n = 0, nCount = rMtf.GetActionSize(); n < nCount; n++ )
aNewMtf.AddAction( rMtf.GetAction( n )->Clone() );
aMap.SetScaleX( aMap.GetScaleX() * aScale );
@@ -395,3 +396,5 @@ void SdVectorizeDlg::SaveSettings() const
*xOStm << (sal_uInt16) aMtFillHoles.GetValue() << aCbFillHoles.IsChecked();
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/dlg/vectdlg.src b/sd/source/ui/dlg/vectdlg.src
index 385f162be..909dc878c 100755..100644
--- a/sd/source/ui/dlg/vectdlg.src
+++ b/sd/source/ui/dlg/vectdlg.src
@@ -30,12 +30,6 @@
#include "vectdlg.hrc"
#include "helpids.h"
-/******************************************************************************
-|*
-|*
-|*
-\******************************************************************************/
-
ModalDialog DLG_VECTORIZE
{
HelpID = HID_VECTORIZE_DLG;
@@ -132,7 +126,7 @@ ModalDialog DLG_VECTORIZE
Last = 32 ;
SpinSize = 1 ;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " Pixel" ;
+ CustomUnitText [ en-US ] = " Pixel" ;
};
CheckBox CB_FILLHOLES
@@ -167,7 +161,7 @@ ModalDialog DLG_VECTORIZE
Last = 128;
SpinSize = 1;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " Pixel" ;
+ CustomUnitText [ en-US ] = " Pixel" ;
};
FixedText FT_ORIGINAL
diff --git a/sd/source/ui/docshell/docshel2.cxx b/sd/source/ui/docshell/docshel2.cxx
index e8faede8a..82f261ed6 100755..100644
--- a/sd/source/ui/docshell/docshel2.cxx
+++ b/sd/source/ui/docshell/docshel2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,16 +38,12 @@
#include "helpids.h"
#include "ViewShell.hxx"
#include "drawview.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "drawdoc.hxx"
#include "sdpage.hxx"
#include "View.hxx"
#include "ClientView.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "strings.hrc"
#include "res_bmp.hrc"
#include "sdresid.hxx"
@@ -82,11 +79,11 @@ void DrawDocShell::Draw(OutputDevice* pOut, const JobSetup&, sal_uInt16 nAspect)
SdPage* pSelectedPage = NULL;
- List* pFrameViewList = mpDoc->GetFrameViewList();
- if( pFrameViewList && pFrameViewList->Count() )
+ const std::vector<sd::FrameView*> &rViews = mpDoc->GetFrameViewList();
+ if( !rViews.empty() )
{
- FrameView* pFrameView = (FrameView*)pFrameViewList->GetObject(0);
- if( pFrameView && pFrameView->GetPageKind() == PK_STANDARD )
+ sd::FrameView* pFrameView = rViews[0];
+ if( pFrameView->GetPageKind() == PK_STANDARD )
{
sal_uInt16 nSelectedPage = pFrameView->GetSelectedPage();
pSelectedPage = mpDoc->GetSdPage(nSelectedPage, PK_STANDARD);
@@ -96,7 +93,6 @@ void DrawDocShell::Draw(OutputDevice* pOut, const JobSetup&, sal_uInt16 nAspect)
if( NULL == pSelectedPage )
{
SdPage* pPage = NULL;
- sal_uInt16 nSelectedPage = 0;
sal_uInt16 nPageCnt = (sal_uInt16) mpDoc->GetSdPageCount(PK_STANDARD);
for (sal_uInt16 i = 0; i < nPageCnt; i++)
@@ -104,10 +100,7 @@ void DrawDocShell::Draw(OutputDevice* pOut, const JobSetup&, sal_uInt16 nAspect)
pPage = mpDoc->GetSdPage(i, PK_STANDARD);
if ( pPage->IsSelected() )
- {
- nSelectedPage = i;
pSelectedPage = pPage;
- }
}
if( NULL == pSelectedPage )
@@ -143,33 +136,8 @@ void DrawDocShell::Draw(OutputDevice* pOut, const JobSetup&, sal_uInt16 nAspect)
delete pView;
-// Fuer Testzwecke: Bitte nicht entfernen!
-//
-// GDIMetaFile* pMtf = pOut->GetConnectMetaFile();
-//
-// if( pMtf )
-// {
-// String aURLStr;
-//
-// if( ::utl::LocalFileHelper::ConvertPhysicalNameToURL( String( RTL_CONSTASCII_USTRINGPARAM( "d:\\gdi.mtf" ) ), aURLStr ) )
-// {
-// SvStream* pOStm = ::utl::UcbStreamHelper::CreateStream( aURLStr, STREAM_WRITE | STREAM_TRUNC );
-//
-// if( pOStm )
-// {
-// *pOStm << *pMtf;
-// delete pOStm;
-// }
-// }
-// }
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
Rectangle DrawDocShell::GetVisArea(sal_uInt16 nAspect) const
{
Rectangle aVisArea;
@@ -228,12 +196,6 @@ void DrawDocShell::Disconnect(ViewShell* pViewSh)
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
FrameView* DrawDocShell::GetFrameView()
{
FrameView* pFrameView = NULL;
@@ -331,7 +293,6 @@ Bitmap DrawDocShell::GetPagePreviewBitmap(SdPage* pPage, sal_uInt16 nMaxEdgePixe
if ( pPageView->GetLockedLayers() != pFrameView->GetLockedLayers() )
pPageView->SetLockedLayers( pFrameView->GetLockedLayers() );
- // if ( pPageView->GetHelpLines() != pFrameView->GetHelpLines() )
pPageView->SetHelpLines( pFrameView->GetStandardHelpLines() );
}
@@ -341,7 +302,7 @@ Bitmap DrawDocShell::GetPagePreviewBitmap(SdPage* pPage, sal_uInt16 nMaxEdgePixe
pView->CompleteRedraw( &aVDev, Rectangle( aNullPt, aSize ) );
- // #111097# IsRedrawReady() always gives sal_True while ( !pView->IsRedrawReady() ) {}
+ // IsRedrawReady() always gives sal_True while ( !pView->IsRedrawReady() ) {}
delete pView;
aVDev.SetMapMode( MapMode() );
@@ -507,3 +468,5 @@ IMPL_LINK( DrawDocShell, RenameSlideHdl, AbstractSvxNameDialog*, pDialog )
return IsNewPageNameValid( aNewName );
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/docshell/docshel3.cxx b/sd/source/ui/docshell/docshel3.cxx
index 73f974d5f..a6e148d59 100755..100644
--- a/sd/source/ui/docshell/docshel3.cxx
+++ b/sd/source/ui/docshell/docshel3.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,12 +33,8 @@
#include "app.hrc"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <svx/ofaitem.hxx>
#include <svx/svxerr.hxx>
@@ -126,7 +123,7 @@ void DrawDocShell::Execute( SfxRequest& rReq )
{
if( dynamic_cast< FuSearch* >(mxDocShellFunction.get()) )
{
- // Suchen&Ersetzen in allen DocShells beenden
+ // End Search&Replace in all docshells
SfxObjectShell* pFirstShell = SfxObjectShell::GetFirst();
SfxObjectShell* pShell = pFirstShell;
@@ -187,7 +184,6 @@ void DrawDocShell::Execute( SfxRequest& rReq )
case SID_CLOSEDOC:
{
-// SfxObjectShell::DoClose();
ExecuteSlot(rReq, SfxObjectShell::GetStaticInterface());
}
break;
@@ -257,3 +253,5 @@ void DrawDocShell::SetDocShellFunction( const ::sd::FunctionReference& xFunction
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/docshell/docshel4.cxx b/sd/source/ui/docshell/docshel4.cxx
index 257117895..9f9d8a5ec 100755..100644
--- a/sd/source/ui/docshell/docshel4.cxx
+++ b/sd/source/ui/docshell/docshel4.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <tools/urlobj.hxx>
#include <sfx2/progress.hxx>
#include <vcl/waitobj.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <editeng/flstitem.hxx>
#include <editeng/eeitem.hxx>
#include <svl/aeitem.hxx>
@@ -43,27 +42,18 @@
#include <sot/storage.hxx>
#include <sfx2/docfile.hxx>
#include <sfx2/docfilt.hxx>
-#ifndef _DISPATCH_HXX //autogen
#include <sfx2/dispatch.hxx>
-#endif
#include <svx/svdotext.hxx>
#include <svl/style.hxx>
#include <sfx2/printer.hxx>
#include <svtools/ctrltool.hxx>
-#ifndef _SFX_ECODE_HXX //autogen
#include <svtools/sfxecode.hxx>
-#endif
#include <sot/clsids.hxx>
#include <sot/formats.hxx>
#include <sfx2/request.hxx>
-#ifdef TF_STARONE
-#include "unomodel.hxx"
-#endif
-
#include <unotools/fltrcfg.hxx>
#include <sfx2/frame.hxx>
#include <sfx2/viewfrm.hxx>
-//#include <svx/svxmsbas.hxx>
#include <unotools/saveopt.hxx>
#include <com/sun/star/drawing/XDrawPage.hpp>
#include <com/sun/star/drawing/XDrawView.hpp>
@@ -73,9 +63,7 @@
#include "glob.hrc"
#include "strings.hrc"
#include "strmname.h"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "optsitem.hxx"
#include "Outliner.hxx"
#include "sdattr.hxx"
@@ -197,21 +185,11 @@ void DrawDocShell::UpdateFontList()
PutItem( aFontListItem );
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
Printer* DrawDocShell::GetDocumentPrinter()
{
return GetPrinter(sal_False);
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
void DrawDocShell::OnDocumentPrinterChanged(Printer* pNewPrinter)
{
// if we already have a printer, see if its the same
@@ -237,11 +215,6 @@ void DrawDocShell::OnDocumentPrinterChanged(Printer* pNewPrinter)
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
void DrawDocShell::UpdateRefDevice()
{
if( mpDoc )
@@ -348,7 +321,7 @@ sal_Bool DrawDocShell::Load( SfxMedium& rMedium )
{
UpdateTablePointers();
- // #108451# If we're an embedded OLE object, use tight bounds
+ // If we're an embedded OLE object, use tight bounds
// for our visArea. No point in showing the user lots of empty
// space. Had to remove the check for empty VisArea below,
// since XML load always sets a VisArea before.
@@ -404,31 +377,6 @@ sal_Bool DrawDocShell::LoadFrom( SfxMedium& rMedium )
sal_Bool bRet = sal_False;
- /*
- // #90691# return to old behaviour (before #80365#): construct own medium
- SfxMedium aMedium(xStorage);
-
- // #90691# for having a progress bar nonetheless for XML copy it
- // from the local DocShell medium (GetMedium()) to the constructed one
- SfxMedium* pLocalMedium = GetMedium();
- if(pLocalMedium)
- {
- SfxItemSet* pLocalItemSet = pLocalMedium->GetItemSet();
- SfxItemSet* pDestItemSet = aMedium.GetItemSet();
-
- if(pLocalItemSet && pDestItemSet)
- {
- const SfxUnoAnyItem* pItem = static_cast<
- const SfxUnoAnyItem*>(
- pLocalItemSet->GetItem(SID_PROGRESS_STATUSBAR_CONTROL));
-
- if(pItem)
- {
- pDestItemSet->Put(*pItem);
- }
- }
- } */
-
mpDoc->NewOrLoadCompleted( NEW_DOC );
mpDoc->CreateFirstPages();
mpDoc->StopWorkStartupDelay();
@@ -454,6 +402,37 @@ sal_Bool DrawDocShell::LoadFrom( SfxMedium& rMedium )
/*************************************************************************
|*
+|* ImportFrom: load from 3rd party format
+|*
+\************************************************************************/
+
+sal_Bool DrawDocShell::ImportFrom( SfxMedium &rMedium, bool bInsert )
+{
+ const sal_Bool bRet=SfxObjectShell::ImportFrom(rMedium, bInsert);
+
+ SfxItemSet* pSet = rMedium.GetItemSet();
+ if( pSet )
+ {
+ if( SFX_ITEM_SET == pSet->GetItemState(SID_DOC_STARTPRESENTATION)&&
+ ( (SfxBoolItem&) ( pSet->Get( SID_DOC_STARTPRESENTATION ) ) ).GetValue() )
+ {
+ mpDoc->SetStartWithPresentation( true );
+
+ // tell SFX to change viewshell when in preview mode
+ if( IsPreview() )
+ {
+ SfxItemSet *pMediumSet = GetMedium()->GetItemSet();
+ if( pMediumSet )
+ pMediumSet->Put( SfxUInt16Item( SID_VIEW_ID, 1 ) );
+ }
+ }
+ }
+
+ return bRet;
+}
+
+/*************************************************************************
+|*
|* ConvertFrom: aus Fremdformat laden
|*
\************************************************************************/
@@ -484,7 +463,9 @@ sal_Bool DrawDocShell::ConvertFrom( SfxMedium& rMedium )
}
}
- if( aFilterName == pFilterPowerPoint97 || aFilterName == pFilterPowerPoint97Template)
+ if( aFilterName == pFilterPowerPoint97
+ || aFilterName == pFilterPowerPoint97Template
+ || aFilterName == pFilterPowerPoint97AutoPlay)
{
mpDoc->StopWorkStartupDelay();
bRet = SdPPTFilter( rMedium, *this, sal_True ).Import();
@@ -561,7 +542,7 @@ sal_Bool DrawDocShell::Save()
if( bRet )
{
- // #86834# Call UpdateDocInfoForSave() before export
+ // Call UpdateDocInfoForSave() before export
UpdateDocInfoForSave();
bRet = SdXMLFilter( *GetMedium(), *this, sal_True, SDXMLMODE_Normal, SotStorage::GetVersion( GetMedium()->GetStorage() ) ).Export();
@@ -589,7 +570,7 @@ sal_Bool DrawDocShell::SaveAs( SfxMedium& rMedium )
if( bRet )
{
- // #86834# Call UpdateDocInfoForSave() before export
+ // Call UpdateDocInfoForSave() before export
UpdateDocInfoForSave();
bRet = SdXMLFilter( rMedium, *this, sal_True, SDXMLMODE_Normal, SotStorage::GetVersion( rMedium.GetStorage() ) ).Export();
}
@@ -872,7 +853,7 @@ sal_Bool DrawDocShell::GotoBookmark(const String& rBookmark)
// Make the bookmarked page the current page. This is done
// by using the API because this takes care of all the
// little things to be done. Especially writing the view
- // data to the frame view (see bug #107803#).
+ // data to the frame view.
sal_uInt16 nSdPgNum = (nPageNumber - 1) / 2;
Reference<drawing::XDrawView> xController (rBase.GetController(), UNO_QUERY);
if (xController.is())
@@ -1027,3 +1008,5 @@ void DrawDocShell::OpenBookmark( const String& rBookmarkURL )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/docshell/docshell.cxx b/sd/source/ui/docshell/docshell.cxx
index 28528ea5a..58479bb17 100755..100644
--- a/sd/source/ui/docshell/docshell.cxx
+++ b/sd/source/ui/docshell/docshell.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -29,24 +30,19 @@
#include "precompiled_sd.hxx"
#include "DrawDocShell.hxx"
-#include <tools/pstm.hxx>
#include <vcl/svapp.hxx>
#include <sfx2/docfac.hxx>
#include <sfx2/objface.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svl/srchitem.hxx>
#include <svx/srchdlg.hxx>
#include <editeng/flstitem.hxx>
#include <svl/eitem.hxx>
#include <svl/intitem.hxx>
#include <sfx2/printer.hxx>
-#ifndef _SFX_DOCFILE_HXX //autogen
#include <sfx2/docfile.hxx>
-#endif
#include <svx/drawitem.hxx>
#include <editeng/flstitem.hxx>
#include <svx/drawitem.hxx>
@@ -56,9 +52,7 @@
#include <svl/itempool.hxx>
#include <svtools/ctrltool.hxx>
#include <svtools/filter.hxx>
-#ifndef _SO_CLSIDS_HXX
#include <sot/clsids.hxx>
-#endif
#include <svl/cjkoptions.hxx>
#include <svl/visitem.hxx>
@@ -80,13 +74,9 @@
#include "fusearch.hxx"
#include "ViewShell.hxx"
#include "sdresid.hxx"
-#ifndef SD_FU_SLIDE_SHOW_DLG_HXX
#include "slideshow.hxx"
-#endif
#include "drawview.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "unomodel.hxx"
#include "undo/undomanager.hxx"
#include "undo/undofactory.hxx"
@@ -100,7 +90,6 @@ using namespace sd;
SFX_IMPL_INTERFACE(DrawDocShell, SfxObjectShell, SdResId(0))
{
SFX_CHILDWINDOW_REGISTRATION(SvxSearchDialogWrapper::GetChildWindowId());
- SFX_CHILDWINDOW_REGISTRATION(SID_HYPERLINK_INSERT);
}
@@ -359,44 +348,32 @@ void DrawDocShell::GetState(SfxItemSet &rSet)
void DrawDocShell::InPlaceActivate( sal_Bool bActive )
{
+ ViewShell* pViewSh = NULL;
+ SfxViewShell* pSfxViewSh = NULL;
+ SfxViewFrame* pSfxViewFrame = SfxViewFrame::GetFirst(this, false);
+ std::vector<FrameView*> &rViews = mpDoc->GetFrameViewList();
+
if( !bActive )
{
- FrameView* pFrameView = NULL;
- List* pFrameViewList = mpDoc->GetFrameViewList();
-
- DBG_ASSERT( pFrameViewList, "No FrameViewList?" );
- if( pFrameViewList )
- {
- sal_uInt32 i;
- for ( i = 0; i < pFrameViewList->Count(); i++)
- {
- // Ggf. FrameViews loeschen
- pFrameView = (FrameView*) pFrameViewList->GetObject(i);
-
- if (pFrameView)
- delete pFrameView;
- }
+ std::vector<FrameView*>::iterator pIter;
+ for ( pIter = rViews.begin(); pIter != rViews.end(); ++pIter )
+ delete *pIter;
- pFrameViewList->Clear();
+ rViews.clear();
- ViewShell* pViewSh = NULL;
- SfxViewShell* pSfxViewSh = NULL;
- SfxViewFrame* pSfxViewFrame = SfxViewFrame::GetFirst(this, false);
+ while (pSfxViewFrame)
+ {
+ // Anzahl FrameViews ermitteln
+ pSfxViewSh = pSfxViewFrame->GetViewShell();
+ pViewSh = PTR_CAST( ViewShell, pSfxViewSh );
- while (pSfxViewFrame)
+ if ( pViewSh && pViewSh->GetFrameView() )
{
- // Anzahl FrameViews ermitteln
- pSfxViewSh = pSfxViewFrame->GetViewShell();
- pViewSh = PTR_CAST( ViewShell, pSfxViewSh );
-
- if ( pViewSh && pViewSh->GetFrameView() )
- {
- pViewSh->WriteFrameViewData();
- pFrameViewList->Insert( new FrameView( mpDoc, pViewSh->GetFrameView() ) );
- }
-
- pSfxViewFrame = SfxViewFrame::GetNext(*pSfxViewFrame, this, false);
+ pViewSh->WriteFrameViewData();
+ rViews.push_back( new FrameView( mpDoc, pViewSh->GetFrameView() ) );
}
+
+ pSfxViewFrame = SfxViewFrame::GetNext(*pSfxViewFrame, this, false);
}
}
@@ -404,29 +381,18 @@ void DrawDocShell::InPlaceActivate( sal_Bool bActive )
if( bActive )
{
- List* pFrameViewList = mpDoc->GetFrameViewList();
-
- DBG_ASSERT( pFrameViewList, "No FrameViewList?" );
- if( pFrameViewList )
+ for( sal_uInt32 i = 0; pSfxViewFrame && (i < rViews.size()); i++ )
{
- ViewShell* pViewSh = NULL;
- SfxViewShell* pSfxViewSh = NULL;
- SfxViewFrame* pSfxViewFrame = SfxViewFrame::GetFirst(this, false);
+ // Anzahl FrameViews ermitteln
+ pSfxViewSh = pSfxViewFrame->GetViewShell();
+ pViewSh = PTR_CAST( ViewShell, pSfxViewSh );
- sal_uInt32 i;
- for( i = 0; pSfxViewFrame && (i < pFrameViewList->Count()); i++ )
+ if ( pViewSh )
{
- // Anzahl FrameViews ermitteln
- pSfxViewSh = pSfxViewFrame->GetViewShell();
- pViewSh = PTR_CAST( ViewShell, pSfxViewSh );
-
- if ( pViewSh )
- {
- pViewSh->ReadFrameViewData( (FrameView*)pFrameViewList->GetObject(i) );
- }
-
- pSfxViewFrame = SfxViewFrame::GetNext(*pSfxViewFrame, this, false);
+ pViewSh->ReadFrameViewData( rViews[ i ] );
}
+
+ pSfxViewFrame = SfxViewFrame::GetNext(*pSfxViewFrame, this, false);
}
}
}
@@ -487,12 +453,6 @@ void DrawDocShell::UpdateTablePointers()
UpdateFontList();
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawDocShell::CancelSearching()
{
if( dynamic_cast<FuSearch*>( mxDocShellFunction.get() ) )
@@ -537,8 +497,8 @@ void DrawDocShell::SetModified( sal_Bool bSet /* = sal_True */ )
{
SfxObjectShell::SetModified( bSet );
- // #100237# change model state, too
- // #103182# only set the changed state if modification is enabled
+ // change model state, too
+ // only set the changed state if modification is enabled
if( IsEnableSetModified() )
{
if ( mpDoc )
@@ -554,7 +514,7 @@ void DrawDocShell::SetModified( sal_Bool bSet /* = sal_True */ )
|*
\************************************************************************/
-// #91457# ExecuteSpellPopup now handled by DrawDocShell. This is necessary
+// ExecuteSpellPopup now handled by DrawDocShell. This is necessary
// to get hands on the outliner and the text object.
IMPL_LINK(DrawDocShell, OnlineSpellCallback, SpellCallbackInfo*, pInfo)
{
@@ -599,10 +559,12 @@ void DrawDocShell::ClearUndoBuffer()
}
pSfxViewFrame = SfxViewFrame::GetNext(*pSfxViewFrame, this, false);
}
-
+
::svl::IUndoManager* pUndoManager = GetUndoManager();
if(pUndoManager && pUndoManager->GetUndoActionCount())
pUndoManager->Clear();
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/docshell/grdocsh.cxx b/sd/source/ui/docshell/grdocsh.cxx
index fe55c8ad7..c7620d379 100755..100644
--- a/sd/source/ui/docshell/grdocsh.cxx
+++ b/sd/source/ui/docshell/grdocsh.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <sfx2/app.hxx>
#include <svl/srchitem.hxx>
#include <tools/globname.hxx>
-#ifndef _SO_CLSIDS_HXX //autogen
#include <sot/clsids.hxx>
-#endif
#include <sfx2/objface.hxx>
@@ -61,7 +58,6 @@ TYPEINIT1(GraphicDocShell, DrawDocShell);
SFX_IMPL_INTERFACE(GraphicDocShell, SfxObjectShell, SdResId(0))
{
SFX_CHILDWINDOW_REGISTRATION(SID_SEARCH_DLG);
- SFX_CHILDWINDOW_REGISTRATION( SID_HYPERLINK_INSERT );
}
SFX_IMPL_OBJECTFACTORY( GraphicDocShell, SvGlobalName(SO3_SDRAW_CLASSID_60), SFXOBJECTSHELL_STD_NORMAL, "sdraw" )
@@ -88,3 +84,5 @@ GraphicDocShell::~GraphicDocShell()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/docshell/makefile.mk b/sd/source/ui/docshell/makefile.mk
deleted file mode 100644
index 5b4ed1995..000000000
--- a/sd/source/ui/docshell/makefile.mk
+++ /dev/null
@@ -1,56 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=docshell
-ENABLE_EXCEPTIONS=TRUE
-
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/docshell.obj \
- $(SLO)$/docshel2.obj \
- $(SLO)$/docshel3.obj \
- $(SLO)$/docshel4.obj \
- $(SLO)$/sdclient.obj \
- $(SLO)$/grdocsh.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/docshell/sdclient.cxx b/sd/source/ui/docshell/sdclient.cxx
index 9f859c393..37259d987 100644
--- a/sd/source/ui/docshell/sdclient.cxx
+++ b/sd/source/ui/docshell/sdclient.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,15 +37,6 @@
#include <toolkit/helper/vclunohelper.hxx>
-
-#include "misc.hxx"
-
-#ifdef STARIMAGE_AVAILABLE
-#ifndef _SIMDLL_HXX
-#include <sim2/simdll.hxx>
-#endif
-#endif
-
#include "strings.hrc"
#include "ViewShell.hxx"
#include "DrawViewShell.hxx"
@@ -149,12 +141,6 @@ void Client::ObjectAreaChanged()
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void Client::ViewChanged()
{
if ( GetAspect() == embed::Aspects::MSOLE_ICON )
@@ -231,3 +217,4 @@ void Client::MakeVisible()
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ChangeRequestQueue.cxx b/sd/source/ui/framework/configuration/ChangeRequestQueue.cxx
index e0a6c3735..2c8777d1c 100644
--- a/sd/source/ui/framework/configuration/ChangeRequestQueue.cxx
+++ b/sd/source/ui/framework/configuration/ChangeRequestQueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,3 +37,5 @@ ChangeRequestQueue::ChangeRequestQueue (void)
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ChangeRequestQueue.hxx b/sd/source/ui/framework/configuration/ChangeRequestQueue.hxx
index 87d20588c..8f89073e6 100644
--- a/sd/source/ui/framework/configuration/ChangeRequestQueue.hxx
+++ b/sd/source/ui/framework/configuration/ChangeRequestQueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.cxx b/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.cxx
index 9f1aac9b3..9a4c9c889 100755..100644
--- a/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.cxx
+++ b/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -235,3 +236,5 @@ void ChangeRequestQueueProcessor::Clear (void)
} } // end of namespace sd::framework::configuration
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.hxx b/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.hxx
index fc18a3a59..de8269b96 100755..100644
--- a/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.hxx
+++ b/sd/source/ui/framework/configuration/ChangeRequestQueueProcessor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,3 +135,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/Configuration.cxx b/sd/source/ui/framework/configuration/Configuration.cxx
index 2b4a6697f..e7f14be90 100644
--- a/sd/source/ui/framework/configuration/Configuration.cxx
+++ b/sd/source/ui/framework/configuration/Configuration.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,8 +99,8 @@ OUString Configuration_getImplementationName (void) throw(RuntimeException)
Sequence<rtl::OUString> SAL_CALL Configuration_getSupportedServiceNames (void)
throw (RuntimeException)
{
- static const OUString sServiceName(OUString::createFromAscii(
- "com.sun.star.drawing.framework.Configuration"));
+ static const OUString sServiceName(OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "com.sun.star.drawing.framework.Configuration")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -295,8 +296,8 @@ OUString SAL_CALL Configuration::getName (void)
OUString aString;
if (rBHelper.bDisposed || rBHelper.bInDispose)
- aString += OUString::createFromAscii("DISPOSED ");
- aString += OUString::createFromAscii("Configuration[");
+ aString += OUString(RTL_CONSTASCII_USTRINGPARAM("DISPOSED "));
+ aString += OUString(RTL_CONSTASCII_USTRINGPARAM("Configuration["));
ResourceContainer::const_iterator iResource;
for (iResource=mpResourceContainer->begin();
@@ -304,10 +305,10 @@ OUString SAL_CALL Configuration::getName (void)
++iResource)
{
if (iResource != mpResourceContainer->begin())
- aString += OUString::createFromAscii(", ");
+ aString += OUString(RTL_CONSTASCII_USTRINGPARAM(", "));
aString += FrameworkHelper::ResourceIdToString(*iResource);
}
- aString += OUString::createFromAscii("]");
+ aString += OUString(RTL_CONSTASCII_USTRINGPARAM("]"));
return aString;
}
@@ -418,3 +419,5 @@ bool AreConfigurationsEquivalent (
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationClassifier.cxx b/sd/source/ui/framework/configuration/ConfigurationClassifier.cxx
index c08e6ff59..52ac65423 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationClassifier.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationClassifier.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -236,3 +237,5 @@ void ConfigurationClassifier::TraceResourceIdVector (
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationClassifier.hxx b/sd/source/ui/framework/configuration/ConfigurationClassifier.hxx
index 4fb9394bc..5b0440774 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationClassifier.hxx
+++ b/sd/source/ui/framework/configuration/ConfigurationClassifier.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -181,3 +182,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationController.cxx b/sd/source/ui/framework/configuration/ConfigurationController.cxx
index 4329c575e..a4f8b7b34 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationController.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,7 +47,7 @@
#include <com/sun/star/util/XURLTransformer.hpp>
#include <comphelper/stl_types.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
using namespace ::com::sun::star;
@@ -83,8 +84,8 @@ OUString ConfigurationController_getImplementationName (void) throw(RuntimeExcep
Sequence<rtl::OUString> SAL_CALL ConfigurationController_getSupportedServiceNames (void)
throw (RuntimeException)
{
- static const OUString sServiceName(OUString::createFromAscii(
- "com.sun.star.drawing.framework.ConfigurationController"));
+ static const OUString sServiceName(OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "com.sun.star.drawing.framework.ConfigurationController")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -205,7 +206,7 @@ void SAL_CALL ConfigurationController::disposing (void)
aEvent.Source = uno::Reference<uno::XInterface>((cppu::OWeakObject*)this);
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
mpImplementation->mpBroadcaster->DisposeAndClear();
}
@@ -655,7 +656,7 @@ void SAL_CALL ConfigurationController::initialize (const Sequence<Any>& aArgumen
if (aArguments.getLength() == 1)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
mpImplementation.reset(new Implementation(
*this,
@@ -724,3 +725,5 @@ ConfigurationController::Implementation::~Implementation (void)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.cxx b/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.cxx
index 416760c10..3f339e31b 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,7 +58,7 @@ void ConfigurationControllerBroadcaster::AddListener(
{
if ( ! rxListener.is())
throw lang::IllegalArgumentException(
- OUString::createFromAscii("invalid listener"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("invalid listener")),
mxConfigurationController,
0);
@@ -77,7 +78,7 @@ void ConfigurationControllerBroadcaster::RemoveListener(
{
if ( ! rxListener.is())
throw lang::IllegalArgumentException(
- OUString::createFromAscii("invalid listener"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("invalid listener")),
mxConfigurationController,
0);
@@ -229,3 +230,4 @@ void ConfigurationControllerBroadcaster::DisposeAndClear (void)
} } // end of namespace sd::framework
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.hxx b/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.hxx
index d29b06125..ed5d80db8 100644
--- a/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.hxx
+++ b/sd/source/ui/framework/configuration/ConfigurationControllerBroadcaster.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,7 +35,7 @@
#include <comphelper/stl_types.hxx>
#include <vector>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace css = ::com::sun::star;
@@ -126,7 +127,7 @@ private:
css::uno::Any maUserData;
};
typedef ::std::vector<ListenerDescriptor> ListenerList;
- typedef ::std::hash_map
+ typedef ::boost::unordered_map
<rtl::OUString,
ListenerList,
::comphelper::UStringHash,
@@ -149,3 +150,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.cxx b/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.cxx
index 8f7d055e8..58b67aaaf 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -219,7 +220,9 @@ void ConfigurationControllerResourceManager::DeactivateResource (
if ( ! rxResourceId.is())
return;
+#if defined VERBOSE && VERBOSE>=1
bool bSuccess (false);
+#endif
try
{
// 1. Remove resource from URL->Object map.
@@ -253,7 +256,9 @@ void ConfigurationControllerResourceManager::DeactivateResource (
}
}
+#if defined VERBOSE && VERBOSE>=1
bSuccess = true;
+#endif
}
}
catch (RuntimeException&)
@@ -350,3 +355,4 @@ bool ConfigurationControllerResourceManager::ResourceComparator::operator() (
} } // end of namespace sd::framework
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.hxx b/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.hxx
index 9743e1a75..aa69b957c 100644
--- a/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.hxx
+++ b/sd/source/ui/framework/configuration/ConfigurationControllerResourceManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -143,3 +144,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationTracer.cxx b/sd/source/ui/framework/configuration/ConfigurationTracer.cxx
index 1d19026be..3cba1455f 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationTracer.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationTracer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,7 +69,7 @@ void ConfigurationTracer::TraceBoundResources (
{
Sequence<Reference<XResourceId> > aResourceList (
rxConfiguration->getResources(rxResourceId, ::rtl::OUString(), AnchorBindingMode_DIRECT));
- const ::rtl::OUString sIndentation (::rtl::OUString::createFromAscii(" "));
+ const ::rtl::OUString sIndentation (RTL_CONSTASCII_USTRINGPARAM(" "));
for (sal_Int32 nIndex=0; nIndex<aResourceList.getLength(); ++nIndex)
{
::rtl::OUString sLine (aResourceList[nIndex]->getResourceURL());
@@ -81,3 +82,5 @@ void ConfigurationTracer::TraceBoundResources (
#endif
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationTracer.hxx b/sd/source/ui/framework/configuration/ConfigurationTracer.hxx
index 4fd464bc8..e30e15328 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationTracer.hxx
+++ b/sd/source/ui/framework/configuration/ConfigurationTracer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationUpdater.cxx b/sd/source/ui/framework/configuration/ConfigurationUpdater.cxx
index 28a502488..7a01659fb 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationUpdater.cxx
+++ b/sd/source/ui/framework/configuration/ConfigurationUpdater.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -212,7 +213,7 @@ void ConfigurationUpdater::UpdateConfiguration (void)
if (mnLockCount == 0)
UpdateCore(aClassifier);
}
- catch(RuntimeException)
+ catch(const RuntimeException&)
{
}
@@ -235,7 +236,7 @@ void ConfigurationUpdater::UpdateConfiguration (void)
#endif
}
}
- catch (RuntimeException e)
+ catch(const RuntimeException &)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -256,7 +257,7 @@ void ConfigurationUpdater::CleanRequestedConfiguration (void)
// Request the deactivation of pure anchors that have no child.
vector<Reference<XResourceId> > aResourcesToDeactivate;
CheckPureAnchors(mxRequestedConfiguration, aResourcesToDeactivate);
- if (aResourcesToDeactivate.size() > 0)
+ if (!aResourcesToDeactivate.empty())
{
Reference<XConfigurationController> xCC (
mxControllerManager->getConfigurationController());
@@ -327,10 +328,10 @@ void ConfigurationUpdater::UpdateCore (const ConfigurationClassifier& rClassifie
// Deactivate pure anchors that have no child.
vector<Reference<XResourceId> > aResourcesToDeactivate;
CheckPureAnchors(mxCurrentConfiguration, aResourcesToDeactivate);
- if (aResourcesToDeactivate.size() > 0)
+ if (!aResourcesToDeactivate.empty())
mpResourceManager->DeactivateResources(aResourcesToDeactivate, mxCurrentConfiguration);
}
- catch(RuntimeException)
+ catch(const RuntimeException&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -466,3 +467,5 @@ IMPL_LINK(ConfigurationUpdater, TimeoutHandler, Timer*, EMPTYARG)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ConfigurationUpdater.hxx b/sd/source/ui/framework/configuration/ConfigurationUpdater.hxx
index ac5b57a4d..e6ccd56a6 100755..100644
--- a/sd/source/ui/framework/configuration/ConfigurationUpdater.hxx
+++ b/sd/source/ui/framework/configuration/ConfigurationUpdater.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -213,3 +214,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.cxx b/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.cxx
index eeba7cc75..c1a1b8fd1 100644
--- a/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.cxx
+++ b/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,8 +86,8 @@ void SAL_CALL GenericConfigurationChangeRequest::execute (
OUString SAL_CALL GenericConfigurationChangeRequest::getName (void)
throw (RuntimeException)
{
- return OUString::createFromAscii("GenericConfigurationChangeRequest ")
- + OUString::createFromAscii(meMode==Activation ? "activate " : "deactivate ")
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("GenericConfigurationChangeRequest "))
+ + (meMode==Activation ? OUString(RTL_CONSTASCII_USTRINGPARAM("activate ")) : OUString(RTL_CONSTASCII_USTRINGPARAM("deactivate ")))
+ FrameworkHelper::ResourceIdToString(mxResourceId);
}
@@ -102,3 +103,4 @@ void SAL_CALL GenericConfigurationChangeRequest::setName (const OUString& rsName
} } // end of namespace sd::framework
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.hxx b/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.hxx
index 03a7e52d9..33d4971fe 100644
--- a/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.hxx
+++ b/sd/source/ui/framework/configuration/GenericConfigurationChangeRequest.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -121,3 +122,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx b/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx
index 942eca26b..8ddfc5677 100644
--- a/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx
+++ b/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -228,3 +229,5 @@ Reference<XResourceFactory> ResourceFactoryManager::FindFactory (const OUString&
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ResourceFactoryManager.hxx b/sd/source/ui/framework/configuration/ResourceFactoryManager.hxx
index d8ad8c9aa..fda86ae5f 100644
--- a/sd/source/ui/framework/configuration/ResourceFactoryManager.hxx
+++ b/sd/source/ui/framework/configuration/ResourceFactoryManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,7 +35,7 @@
#include <com/sun/star/util/XURLTransformer.hpp>
#include <osl/mutex.hxx>
#include <comphelper/stl_types.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace css = ::com::sun::star;
@@ -93,7 +94,7 @@ public:
private:
::osl::Mutex maMutex;
- typedef ::std::hash_map<
+ typedef ::boost::unordered_map<
::rtl::OUString,
css::uno::Reference<css::drawing::framework::XResourceFactory>,
::comphelper::UStringHash,
@@ -126,3 +127,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/ResourceId.cxx b/sd/source/ui/framework/configuration/ResourceId.cxx
index ab46f7da5..e1f23b8a5 100755..100644
--- a/sd/source/ui/framework/configuration/ResourceId.cxx
+++ b/sd/source/ui/framework/configuration/ResourceId.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,7 +75,7 @@ Sequence<rtl::OUString> SAL_CALL ResourceId_getSupportedServiceNames (void)
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.framework.ResourceId"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.ResourceId")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -624,3 +625,5 @@ void ResourceId::ParseResourceURL (void)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/UpdateRequest.cxx b/sd/source/ui/framework/configuration/UpdateRequest.cxx
index 3f092d327..6b7cab8b8 100644
--- a/sd/source/ui/framework/configuration/UpdateRequest.cxx
+++ b/sd/source/ui/framework/configuration/UpdateRequest.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,7 +70,7 @@ void SAL_CALL UpdateRequest::execute (const Reference<XConfiguration>& rxConfigu
OUString SAL_CALL UpdateRequest::getName (void)
throw (RuntimeException)
{
- return OUString::createFromAscii("UpdateRequest");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("UpdateRequest"));
}
@@ -84,3 +85,4 @@ void SAL_CALL UpdateRequest::setName (const OUString& rsName)
} } // end of namespace sd::framework
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/UpdateRequest.hxx b/sd/source/ui/framework/configuration/UpdateRequest.hxx
index 870315831..730bcd798 100644
--- a/sd/source/ui/framework/configuration/UpdateRequest.hxx
+++ b/sd/source/ui/framework/configuration/UpdateRequest.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/configuration/makefile.mk b/sd/source/ui/framework/configuration/makefile.mk
deleted file mode 100644
index cdc41491b..000000000
--- a/sd/source/ui/framework/configuration/makefile.mk
+++ /dev/null
@@ -1,63 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=framework_configuration
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/ChangeRequestQueue.obj \
- $(SLO)$/ChangeRequestQueueProcessor.obj \
- $(SLO)$/Configuration.obj \
- $(SLO)$/ConfigurationClassifier.obj \
- $(SLO)$/ConfigurationController.obj \
- $(SLO)$/ConfigurationControllerBroadcaster.obj \
- $(SLO)$/ConfigurationControllerResourceManager.obj \
- $(SLO)$/ConfigurationTracer.obj \
- $(SLO)$/ConfigurationUpdater.obj \
- $(SLO)$/GenericConfigurationChangeRequest.obj \
- $(SLO)$/ResourceId.obj \
- $(SLO)$/ResourceFactoryManager.obj \
- $(SLO)$/UpdateRequest.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/framework/factories/BasicPaneFactory.cxx b/sd/source/ui/framework/factories/BasicPaneFactory.cxx
index eb35b1b74..5d757115b 100755..100644
--- a/sd/source/ui/framework/factories/BasicPaneFactory.cxx
+++ b/sd/source/ui/framework/factories/BasicPaneFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -118,7 +119,7 @@ Sequence<rtl::OUString> SAL_CALL BasicPaneFactory_getSupportedServiceNames (void
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.framework.BasicPaneFactory"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.BasicPaneFactory")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -328,8 +329,8 @@ Reference<XResource> SAL_CALL BasicPaneFactory::createResource (
// The requested pane can not be created by any of the factories
// managed by the called BasicPaneFactory object.
throw lang::IllegalArgumentException(
- ::rtl::OUString::createFromAscii(
- "BasicPaneFactory::createPane() called for unknown resource id"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "BasicPaneFactory::createPane() called for unknown resource id")),
NULL,
0);
}
@@ -387,8 +388,8 @@ void SAL_CALL BasicPaneFactory::releaseResource (
// created by any of the factories managed by the called
// BasicPaneFactory object.
throw lang::IllegalArgumentException(
- ::rtl::OUString::createFromAscii(
- "BasicPaneFactory::releasePane() called for pane that that was not created by same factory."),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "BasicPaneFactory::releasePane() called for pane that that was not created by same factory.")),
NULL,
0);
}
@@ -413,11 +414,6 @@ void SAL_CALL BasicPaneFactory::notifyConfigurationChange (
// problems after reload (missing resizes for the side panes).
if (mbFirstUpdateSeen)
{
- if (mpUpdateLockManager.get()!=NULL)
- {
- // ::osl::Guard< ::osl::Mutex > aGuard (::osl::Mutex::getGlobalMutex());
- // mpUpdateLockManager->Lock();
- }
}
else
mbFirstUpdateSeen = true;
@@ -431,8 +427,6 @@ void SAL_CALL BasicPaneFactory::notifyConfigurationChange (
if (mpUpdateLockManager.get() != NULL)
{
::osl::Guard< ::osl::Mutex > aGuard (::osl::Mutex::getGlobalMutex());
- // if (mpUpdateLockManager->IsLocked())
- // mpUpdateLockManager->Unlock();
}
break;
}
@@ -566,3 +560,5 @@ void BasicPaneFactory::ThrowIfDisposed (void) const
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/BasicPaneFactory.hxx b/sd/source/ui/framework/factories/BasicPaneFactory.hxx
index 9ce59689f..9eb311770 100755..100644
--- a/sd/source/ui/framework/factories/BasicPaneFactory.hxx
+++ b/sd/source/ui/framework/factories/BasicPaneFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -166,3 +167,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/BasicToolBarFactory.cxx b/sd/source/ui/framework/factories/BasicToolBarFactory.cxx
index 3301f4b2b..01b1761d5 100755..100644
--- a/sd/source/ui/framework/factories/BasicToolBarFactory.cxx
+++ b/sd/source/ui/framework/factories/BasicToolBarFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,7 +67,7 @@ Sequence<rtl::OUString> SAL_CALL BasicToolBarFactory_getSupportedServiceNames (v
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.framework.BasicToolBarFactory"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.BasicToolBarFactory")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -243,3 +244,5 @@ void BasicToolBarFactory::ThrowIfDisposed (void) const
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/BasicToolBarFactory.hxx b/sd/source/ui/framework/factories/BasicToolBarFactory.hxx
index 8b98a3d15..487bc41e0 100755..100644
--- a/sd/source/ui/framework/factories/BasicToolBarFactory.hxx
+++ b/sd/source/ui/framework/factories/BasicToolBarFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116,3 +117,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/BasicViewFactory.cxx b/sd/source/ui/framework/factories/BasicViewFactory.cxx
index f61295043..b881fa688 100644
--- a/sd/source/ui/framework/factories/BasicViewFactory.cxx
+++ b/sd/source/ui/framework/factories/BasicViewFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,7 +88,7 @@ Sequence<rtl::OUString> SAL_CALL BasicViewFactory_getSupportedServiceNames (void
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.framework.BasicViewFactory"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.BasicViewFactory")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -615,3 +616,5 @@ void BasicViewFactory::ActivateCenterView (
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/BasicViewFactory.hxx b/sd/source/ui/framework/factories/BasicViewFactory.hxx
index 87cf18c94..6ec6aa7ee 100755..100644
--- a/sd/source/ui/framework/factories/BasicViewFactory.hxx
+++ b/sd/source/ui/framework/factories/BasicViewFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,3 +158,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/ChildWindowPane.cxx b/sd/source/ui/framework/factories/ChildWindowPane.cxx
index 5988d3916..2a334123d 100755..100644
--- a/sd/source/ui/framework/factories/ChildWindowPane.cxx
+++ b/sd/source/ui/framework/factories/ChildWindowPane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -249,3 +250,5 @@ void SAL_CALL ChildWindowPane::disposing (const lang::EventObject& rEvent)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/ChildWindowPane.hxx b/sd/source/ui/framework/factories/ChildWindowPane.hxx
index c3210fb20..c1383b6d8 100755..100644
--- a/sd/source/ui/framework/factories/ChildWindowPane.hxx
+++ b/sd/source/ui/framework/factories/ChildWindowPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,21 +32,11 @@
#include "framework/Pane.hxx"
#include "PaneShells.hxx"
-#ifndef _COM_SUN_STAR_LANG_XEVENTLISTENER_HPP_
#include <com/sun/star/lang/XEventListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DRAWING_FRAMEWORK_XRESOURCEID_HPP_
#include <com/sun/star/drawing/framework/XResourceId.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
#include <tools/link.hxx>
#include <memory>
@@ -130,3 +121,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/FrameWindowPane.cxx b/sd/source/ui/framework/factories/FrameWindowPane.cxx
index 31707e9fb..436f32870 100644
--- a/sd/source/ui/framework/factories/FrameWindowPane.cxx
+++ b/sd/source/ui/framework/factories/FrameWindowPane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ sal_Bool SAL_CALL FrameWindowPane::isAnchorOnly (void)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/FrameWindowPane.hxx b/sd/source/ui/framework/factories/FrameWindowPane.hxx
index 017fc7414..c8ea711ad 100755..100644
--- a/sd/source/ui/framework/factories/FrameWindowPane.hxx
+++ b/sd/source/ui/framework/factories/FrameWindowPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "framework/Pane.hxx"
-#ifndef _COM_SUN_STAR_DRAWING_FRAMEWORK_XRESOURCEID_HPP_
#include <com/sun/star/drawing/framework/XResourceId.hpp>
-#endif
namespace sd { namespace framework {
@@ -61,3 +60,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/FullScreenPane.cxx b/sd/source/ui/framework/factories/FullScreenPane.cxx
index c03bf9ce7..e2bbd185e 100755..100644
--- a/sd/source/ui/framework/factories/FullScreenPane.cxx
+++ b/sd/source/ui/framework/factories/FullScreenPane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -254,7 +255,7 @@ Reference<rendering::XCanvas> FullScreenPane::CreateCanvas (void)
mxComponentContext->getServiceManager(), UNO_QUERY_THROW);
return Reference<rendering::XCanvas>(
xFactory->createInstanceWithArguments(
- OUString::createFromAscii("com.sun.star.rendering.SpriteCanvas.VCL"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.rendering.SpriteCanvas.VCL")),
aArg),
UNO_QUERY);
}
@@ -292,3 +293,5 @@ void FullScreenPane::ExtractArguments (
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/FullScreenPane.hxx b/sd/source/ui/framework/factories/FullScreenPane.hxx
index 7e71abb84..f15ba2680 100644
--- a/sd/source/ui/framework/factories/FullScreenPane.hxx
+++ b/sd/source/ui/framework/factories/FullScreenPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -103,3 +104,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/Pane.cxx b/sd/source/ui/framework/factories/Pane.cxx
index 702495eb7..81ad1157a 100755..100644
--- a/sd/source/ui/framework/factories/Pane.cxx
+++ b/sd/source/ui/framework/factories/Pane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,12 +30,12 @@
#include "framework/Pane.hxx"
-#include <rtl/uuid.h>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <toolkit/helper/vclunohelper.hxx>
#include <vcl/window.hxx>
#include <cppcanvas/vclfactory.hxx>
+#include <comphelper/servicehelper.hxx>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -194,24 +195,15 @@ sal_Bool SAL_CALL Pane::isAnchorOnly (void)
//----- XUnoTunnel ------------------------------------------------------------
-const Sequence<sal_Int8>& Pane::getUnoTunnelId (void)
+namespace
{
- static Sequence<sal_Int8>* pSequence = NULL;
- if (pSequence == NULL)
- {
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
- if (pSequence == NULL)
- {
- static ::com::sun::star::uno::Sequence<sal_Int8> aSequence (16);
- rtl_createUuid((sal_uInt8*)aSequence.getArray(), 0, sal_True);
- pSequence = &aSequence;
- }
- }
- return *pSequence;
+ class thePaneUnoTunnelId : public rtl::Static< UnoTunnelIdInit, thePaneUnoTunnelId > {};
}
-
-
+const Sequence<sal_Int8>& Pane::getUnoTunnelId (void)
+{
+ return thePaneUnoTunnelId::get().getSeq();
+}
sal_Int64 SAL_CALL Pane::getSomething (const Sequence<sal_Int8>& rId)
throw (RuntimeException)
@@ -265,3 +257,5 @@ void Pane::ThrowIfDisposed (void) const
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/PresentationFactory.cxx b/sd/source/ui/framework/factories/PresentationFactory.cxx
index 623eddf13..9c3402b7f 100755..100644
--- a/sd/source/ui/framework/factories/PresentationFactory.cxx
+++ b/sd/source/ui/framework/factories/PresentationFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,7 +140,7 @@ Sequence<rtl::OUString> SAL_CALL PresentationFactoryProvider_getSupportedService
//===== PresentationFactory ===================================================
const ::rtl::OUString PresentationFactory::msPresentationViewURL(
- OUString::createFromAscii("private:resource/view/Presentation"));
+ RTL_CONSTASCII_USTRINGPARAM("private:resource/view/Presentation"));
PresentationFactory::PresentationFactory (
@@ -321,3 +322,5 @@ void SAL_CALL PresentationFactoryProvider::initialize(
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/TaskPanelFactory.cxx b/sd/source/ui/framework/factories/TaskPanelFactory.cxx
index b518b51ae..f85573919 100755..100644
--- a/sd/source/ui/framework/factories/TaskPanelFactory.cxx
+++ b/sd/source/ui/framework/factories/TaskPanelFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,7 +66,7 @@ Sequence<rtl::OUString> SAL_CALL TaskPanelFactory_getSupportedServiceNames (void
throw (RuntimeException)
{
static const OUString sServiceName(
- OUString::createFromAscii("com.sun.star.drawing.framework.TaskPanelFactory"));
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.TaskPanelFactory"));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -271,7 +272,7 @@ void SAL_CALL TaskPanelFactory::releaseResource (
}
else
{
- OSL_ENSURE( false, "TaskPanelFactory::releaseResource: don't know what to do with this resource!" );
+ OSL_FAIL( "TaskPanelFactory::releaseResource: don't know what to do with this resource!" );
}
}
}
@@ -321,3 +322,5 @@ Reference<XResourceId> SAL_CALL TaskPanelResource::getResourceId ()
} // end of anonymous namespace
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/TaskPanelFactory.hxx b/sd/source/ui/framework/factories/TaskPanelFactory.hxx
index 347e89c4d..d316bb927 100755..100644
--- a/sd/source/ui/framework/factories/TaskPanelFactory.hxx
+++ b/sd/source/ui/framework/factories/TaskPanelFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,3 +95,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/ViewShellWrapper.cxx b/sd/source/ui/framework/factories/ViewShellWrapper.cxx
index faac4af35..f235090dd 100755..100644
--- a/sd/source/ui/framework/factories/ViewShellWrapper.cxx
+++ b/sd/source/ui/framework/factories/ViewShellWrapper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,12 +37,12 @@
#include <com/sun/star/drawing/framework/XPane.hpp>
#include <com/sun/star/lang/DisposedException.hpp>
-#include <rtl/uuid.h>
#include <toolkit/helper/vclunohelper.hxx>
#include <comphelper/sequence.hxx>
+#include <comphelper/servicehelper.hxx>
#include <cppuhelper/typeprovider.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <tools/diagnose_ex.h>
@@ -176,20 +177,14 @@ sal_Bool SAL_CALL ViewShellWrapper::relocateToAnchor (
//----- XUnoTunnel ------------------------------------------------------------
+namespace
+{
+ class theViewShellWrapperUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theViewShellWrapperUnoTunnelId> {};
+}
+
const Sequence<sal_Int8>& ViewShellWrapper::getUnoTunnelId (void)
{
- static Sequence<sal_Int8>* pSequence = NULL;
- if (pSequence == NULL)
- {
- const ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
- if (pSequence == NULL)
- {
- static ::com::sun::star::uno::Sequence<sal_Int8> aSequence (16);
- rtl_createUuid((sal_uInt8*)aSequence.getArray(), 0, sal_True);
- pSequence = &aSequence;
- }
- }
- return *pSequence;
+ return theViewShellWrapperUnoTunnelId::get().getSeq();
}
@@ -267,3 +262,5 @@ void SAL_CALL ViewShellWrapper::disposing (const lang::EventObject& rEvent)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/factories/makefile.mk b/sd/source/ui/framework/factories/makefile.mk
deleted file mode 100644
index 23e780ba1..000000000
--- a/sd/source/ui/framework/factories/makefile.mk
+++ /dev/null
@@ -1,60 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=framework_factories
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/BasicPaneFactory.obj \
- $(SLO)$/BasicToolBarFactory.obj \
- $(SLO)$/BasicViewFactory.obj \
- $(SLO)$/ChildWindowPane.obj \
- $(SLO)$/FrameWindowPane.obj \
- $(SLO)$/FullScreenPane.obj \
- $(SLO)$/Pane.obj \
- $(SLO)$/PresentationFactory.obj \
- $(SLO)$/TaskPanelFactory.obj \
- $(SLO)$/ViewShellWrapper.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/framework/module/CenterViewFocusModule.cxx b/sd/source/ui/framework/module/CenterViewFocusModule.cxx
index 1b3f24187..0c0ff3f7c 100644
--- a/sd/source/ui/framework/module/CenterViewFocusModule.cxx
+++ b/sd/source/ui/framework/module/CenterViewFocusModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -193,3 +194,5 @@ void SAL_CALL CenterViewFocusModule::disposing (
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/CenterViewFocusModule.hxx b/sd/source/ui/framework/module/CenterViewFocusModule.hxx
index c099d9ea7..b43196f07 100644
--- a/sd/source/ui/framework/module/CenterViewFocusModule.hxx
+++ b/sd/source/ui/framework/module/CenterViewFocusModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -110,3 +111,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/DrawModule.cxx b/sd/source/ui/framework/module/DrawModule.cxx
index 9f3e695e8..ad39ac9d8 100644
--- a/sd/source/ui/framework/module/DrawModule.cxx
+++ b/sd/source/ui/framework/module/DrawModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,5 @@ void DrawModule::Initialize (Reference<frame::XController>& rxController)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ImpressModule.cxx b/sd/source/ui/framework/module/ImpressModule.cxx
index a635e3fa2..c0543c57a 100755..100644
--- a/sd/source/ui/framework/module/ImpressModule.cxx
+++ b/sd/source/ui/framework/module/ImpressModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,3 +62,5 @@ void ImpressModule::Initialize (Reference<frame::XController>& rxController)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ModuleController.cxx b/sd/source/ui/framework/module/ModuleController.cxx
index 1838a49b9..d153346e5 100755..100644
--- a/sd/source/ui/framework/module/ModuleController.cxx
+++ b/sd/source/ui/framework/module/ModuleController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,7 +34,7 @@
#include <comphelper/processfactory.hxx>
#include <comphelper/stl_types.hxx>
#include <boost/bind.hpp>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <tools/diagnose_ex.h>
@@ -55,7 +56,7 @@ static const sal_uInt32 snStartupPropertyCount (1);
class ModuleController::ResourceToFactoryMap
- : public ::std::hash_map<
+ : public ::boost::unordered_map<
rtl::OUString,
rtl::OUString,
::comphelper::UStringHash,
@@ -67,7 +68,7 @@ public:
class ModuleController::LoadedFactoryContainer
- : public ::std::hash_map<
+ : public ::boost::unordered_map<
rtl::OUString,
WeakReference<XInterface>,
::comphelper::UStringHash,
@@ -103,7 +104,7 @@ Sequence<rtl::OUString> SAL_CALL ModuleController_getSupportedServiceNames (void
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.framework.ModuleController"));
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.ModuleController"));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -158,15 +159,15 @@ void ModuleController::LoadFactories (const Reference<XComponentContext>& rxCont
{
ConfigurationAccess aConfiguration (
rxContext,
- OUString::createFromAscii("/org.openoffice.Office.Impress/"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Impress/")),
ConfigurationAccess::READ_ONLY);
Reference<container::XNameAccess> xFactories (
aConfiguration.GetConfigurationNode(
- OUString::createFromAscii("MultiPaneGUI/Framework/ResourceFactories")),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("MultiPaneGUI/Framework/ResourceFactories"))),
UNO_QUERY);
::std::vector<rtl::OUString> aProperties (snFactoryPropertyCount);
- aProperties[0] = OUString::createFromAscii("ServiceName");
- aProperties[1] = OUString::createFromAscii("ResourceList");
+ aProperties[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("ServiceName"));
+ aProperties[1] = OUString(RTL_CONSTASCII_USTRINGPARAM("ResourceList"));
ConfigurationAccess::ForAll(
xFactories,
aProperties,
@@ -194,7 +195,7 @@ void ModuleController::ProcessFactory (const ::std::vector<Any>& rValues)
::std::vector<rtl::OUString> aURLs;
tools::ConfigurationAccess::FillList(
xResources,
- OUString::createFromAscii("URL"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("URL")),
aURLs);
#if defined VERBOSE && VERBOSE>0
@@ -222,14 +223,14 @@ void ModuleController::InstantiateStartupServices (void)
try
{
tools::ConfigurationAccess aConfiguration (
- OUString::createFromAscii("/org.openoffice.Office.Impress/"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("/org.openoffice.Office.Impress/")),
tools::ConfigurationAccess::READ_ONLY);
Reference<container::XNameAccess> xFactories (
aConfiguration.GetConfigurationNode(
- OUString::createFromAscii("MultiPaneGUI/Framework/StartupServices")),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("MultiPaneGUI/Framework/StartupServices"))),
UNO_QUERY);
::std::vector<rtl::OUString> aProperties (snStartupPropertyCount);
- aProperties[0] = OUString::createFromAscii("ServiceName");
+ aProperties[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("ServiceName"));
tools::ConfigurationAccess::ForAll(
xFactories,
aProperties,
@@ -343,3 +344,5 @@ void SAL_CALL ModuleController::initialize (const Sequence<Any>& aArguments)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/PresentationModule.cxx b/sd/source/ui/framework/module/PresentationModule.cxx
index 2fc1a7833..2076e7b5d 100755..100644
--- a/sd/source/ui/framework/module/PresentationModule.cxx
+++ b/sd/source/ui/framework/module/PresentationModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,3 +46,5 @@ void PresentationModule::Initialize (Reference<frame::XController>& rxController
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ReadOnlyModeObserver.cxx b/sd/source/ui/framework/module/ReadOnlyModeObserver.cxx
index 1bc567ac8..3d827f437 100755..100644
--- a/sd/source/ui/framework/module/ReadOnlyModeObserver.cxx
+++ b/sd/source/ui/framework/module/ReadOnlyModeObserver.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,7 +66,7 @@ ReadOnlyModeObserver::ReadOnlyModeObserver (
mpBroadcaster(new ModifyBroadcaster(maMutex))
{
// Create a URL object for the slot name.
- maSlotNameURL.Complete = OUString::createFromAscii(".uno:EditDoc");
+ maSlotNameURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:EditDoc"));
uno::Reference<lang::XMultiServiceFactory> xServiceManager (
::comphelper::getProcessServiceFactory());
if (xServiceManager.is())
@@ -218,3 +219,5 @@ void SAL_CALL ReadOnlyModeObserver::notifyConfigurationChange (
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx b/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx
index d4b0314aa..60519054b 100755..100644
--- a/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx
+++ b/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -137,3 +138,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ResourceManager.cxx b/sd/source/ui/framework/module/ResourceManager.cxx
index 8050fc058..bc19cdb5c 100755..100644
--- a/sd/source/ui/framework/module/ResourceManager.cxx
+++ b/sd/source/ui/framework/module/ResourceManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -292,3 +293,5 @@ void SAL_CALL ResourceManager::disposing (
}
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ResourceManager.hxx b/sd/source/ui/framework/module/ResourceManager.hxx
index dd7cd9e0c..2f280a29b 100755..100644
--- a/sd/source/ui/framework/module/ResourceManager.hxx
+++ b/sd/source/ui/framework/module/ResourceManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -131,3 +132,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ShellStackGuard.cxx b/sd/source/ui/framework/module/ShellStackGuard.cxx
index 47acc5b88..441c609f6 100644
--- a/sd/source/ui/framework/module/ShellStackGuard.cxx
+++ b/sd/source/ui/framework/module/ShellStackGuard.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -190,3 +191,5 @@ bool ShellStackGuard::IsPrinting (void) const
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ShellStackGuard.hxx b/sd/source/ui/framework/module/ShellStackGuard.hxx
index a60c1caa2..dab10c201 100755..100644
--- a/sd/source/ui/framework/module/ShellStackGuard.hxx
+++ b/sd/source/ui/framework/module/ShellStackGuard.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,3 +115,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/SlideSorterModule.cxx b/sd/source/ui/framework/module/SlideSorterModule.cxx
index 3a836e5fb..fa753b10a 100644
--- a/sd/source/ui/framework/module/SlideSorterModule.cxx
+++ b/sd/source/ui/framework/module/SlideSorterModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -153,3 +154,5 @@ void SlideSorterModule::UpdateViewTabBar (const Reference<XTabBar>& rxTabBar)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/SlideSorterModule.hxx b/sd/source/ui/framework/module/SlideSorterModule.hxx
index d36510e60..9e2945f15 100644
--- a/sd/source/ui/framework/module/SlideSorterModule.hxx
+++ b/sd/source/ui/framework/module/SlideSorterModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ToolBarModule.cxx b/sd/source/ui/framework/module/ToolBarModule.cxx
index 6b154d7ae..77a01e41a 100644
--- a/sd/source/ui/framework/module/ToolBarModule.cxx
+++ b/sd/source/ui/framework/module/ToolBarModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -232,3 +233,5 @@ void SAL_CALL ToolBarModule::disposing (const lang::EventObject& rEvent)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ToolBarModule.hxx b/sd/source/ui/framework/module/ToolBarModule.hxx
index 47228ee97..57a3e7fdb 100644
--- a/sd/source/ui/framework/module/ToolBarModule.hxx
+++ b/sd/source/ui/framework/module/ToolBarModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -100,3 +101,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ToolPanelModule.cxx b/sd/source/ui/framework/module/ToolPanelModule.cxx
index ed9447efa..256319628 100644
--- a/sd/source/ui/framework/module/ToolPanelModule.cxx
+++ b/sd/source/ui/framework/module/ToolPanelModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: ToolPanelModule.cxx,v $
- * $Revision: 1.4 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -163,3 +161,5 @@ void ToolPanelModule::Initialize (const Reference<frame::XController>& rxControl
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ToolPanelModule.hxx b/sd/source/ui/framework/module/ToolPanelModule.hxx
index 34b0ecf42..861bcf93a 100644
--- a/sd/source/ui/framework/module/ToolPanelModule.hxx
+++ b/sd/source/ui/framework/module/ToolPanelModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -47,3 +48,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ViewTabBarModule.cxx b/sd/source/ui/framework/module/ViewTabBarModule.cxx
index 7bc49d6ba..c701a3fcf 100644
--- a/sd/source/ui/framework/module/ViewTabBarModule.cxx
+++ b/sd/source/ui/framework/module/ViewTabBarModule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -218,3 +219,5 @@ void ViewTabBarModule::UpdateViewTabBar (const Reference<XTabBar>& rxTabBar)
} } // end of namespace sd::framework
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/ViewTabBarModule.hxx b/sd/source/ui/framework/module/ViewTabBarModule.hxx
index 559724232..aa7686109 100644
--- a/sd/source/ui/framework/module/ViewTabBarModule.hxx
+++ b/sd/source/ui/framework/module/ViewTabBarModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -105,3 +106,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/module/makefile.mk b/sd/source/ui/framework/module/makefile.mk
deleted file mode 100755
index bec9b1a04..000000000
--- a/sd/source/ui/framework/module/makefile.mk
+++ /dev/null
@@ -1,62 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=framework_module
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/CenterViewFocusModule.obj \
- $(SLO)$/DrawModule.obj \
- $(SLO)$/ImpressModule.obj \
- $(SLO)$/ModuleController.obj \
- $(SLO)$/PresentationModule.obj \
- $(SLO)$/ReadOnlyModeObserver.obj \
- $(SLO)$/ResourceManager.obj \
- $(SLO)$/ShellStackGuard.obj \
- $(SLO)$/SlideSorterModule.obj \
- $(SLO)$/ToolPanelModule.obj \
- $(SLO)$/ToolBarModule.obj \
- $(SLO)$/ViewTabBarModule.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/framework/tools/FrameworkHelper.cxx b/sd/source/ui/framework/tools/FrameworkHelper.cxx
index 5bc3e1fab..e9574bd2e 100755..100644
--- a/sd/source/ui/framework/tools/FrameworkHelper.cxx
+++ b/sd/source/ui/framework/tools/FrameworkHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,6 +54,7 @@
#include <osl/doublecheckedlocking.h>
#include <osl/getglobalmutex.hxx>
#include <tools/diagnose_ex.h>
+#include <boost/unordered_map.hpp>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -174,84 +176,84 @@ namespace sd { namespace framework {
// Pane URLS.
const OUString FrameworkHelper::msPaneURLPrefix(
- OUString::createFromAscii("private:resource/pane/"));
+ RTL_CONSTASCII_USTRINGPARAM("private:resource/pane/"));
const OUString FrameworkHelper::msCenterPaneURL(
- msPaneURLPrefix + OUString::createFromAscii("CenterPane"));
+ msPaneURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("CenterPane")));
const OUString FrameworkHelper::msFullScreenPaneURL(
- msPaneURLPrefix + OUString::createFromAscii("FullScreenPane"));
+ msPaneURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("FullScreenPane")));
const OUString FrameworkHelper::msLeftImpressPaneURL(
- msPaneURLPrefix + OUString::createFromAscii("LeftImpressPane"));
+ msPaneURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("LeftImpressPane")));
const OUString FrameworkHelper::msLeftDrawPaneURL(
- msPaneURLPrefix + OUString::createFromAscii("LeftDrawPane"));
+ msPaneURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("LeftDrawPane")));
const OUString FrameworkHelper::msRightPaneURL(
- msPaneURLPrefix + OUString::createFromAscii("RightPane"));
+ msPaneURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("RightPane")));
// View URLs.
const OUString FrameworkHelper::msViewURLPrefix(
- OUString::createFromAscii("private:resource/view/"));
+ RTL_CONSTASCII_USTRINGPARAM("private:resource/view/"));
const OUString FrameworkHelper::msImpressViewURL(
- msViewURLPrefix + OUString::createFromAscii("ImpressView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("ImpressView")));
const OUString FrameworkHelper::msDrawViewURL(
- msViewURLPrefix + OUString::createFromAscii("GraphicView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("GraphicView")));
const OUString FrameworkHelper::msOutlineViewURL(
- msViewURLPrefix + OUString::createFromAscii("OutlineView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("OutlineView")));
const OUString FrameworkHelper::msNotesViewURL(
- msViewURLPrefix + OUString::createFromAscii("NotesView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("NotesView")));
const OUString FrameworkHelper::msHandoutViewURL(
- msViewURLPrefix + OUString::createFromAscii("HandoutView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("HandoutView")));
const OUString FrameworkHelper::msSlideSorterURL(
- msViewURLPrefix + OUString::createFromAscii("SlideSorter"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("SlideSorter")));
const OUString FrameworkHelper::msPresentationViewURL(
- msViewURLPrefix + OUString::createFromAscii("PresentationView"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("PresentationView")));
const OUString FrameworkHelper::msTaskPaneURL(
- msViewURLPrefix + OUString::createFromAscii("TaskPane"));
+ msViewURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("TaskPane")));
// Tool bar URLs.
const OUString FrameworkHelper::msToolBarURLPrefix(
- OUString::createFromAscii("private:resource/toolbar/"));
+ RTL_CONSTASCII_USTRINGPARAM("private:resource/toolbar/"));
const OUString FrameworkHelper::msViewTabBarURL(
- msToolBarURLPrefix + OUString::createFromAscii("ViewTabBar"));
+ msToolBarURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("ViewTabBar")));
// Task panel URLs.
const ::rtl::OUString FrameworkHelper::msTaskPanelURLPrefix(
- OUString::createFromAscii("private:resource/toolpanel/DrawingFramework/"));
+ RTL_CONSTASCII_USTRINGPARAM("private:resource/toolpanel/DrawingFramework/"));
const ::rtl::OUString FrameworkHelper::msMasterPagesTaskPanelURL(
- msTaskPanelURLPrefix + OUString::createFromAscii("MasterPages"));
+ msTaskPanelURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("MasterPages")));
const ::rtl::OUString FrameworkHelper::msLayoutTaskPanelURL(
- msTaskPanelURLPrefix + OUString::createFromAscii("Layouts"));
+ msTaskPanelURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("Layouts")));
const ::rtl::OUString FrameworkHelper::msTableDesignPanelURL(
- msTaskPanelURLPrefix + OUString::createFromAscii("TableDesign"));
+ msTaskPanelURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("TableDesign")));
const ::rtl::OUString FrameworkHelper::msCustomAnimationTaskPanelURL(
- msTaskPanelURLPrefix + OUString::createFromAscii("CustomAnimations"));
+ msTaskPanelURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("CustomAnimations")));
const ::rtl::OUString FrameworkHelper::msSlideTransitionTaskPanelURL(
- msTaskPanelURLPrefix + OUString::createFromAscii("SlideTransitions"));
+ msTaskPanelURLPrefix + OUString(RTL_CONSTASCII_USTRINGPARAM("SlideTransitions")));
// Event URLs.
const OUString FrameworkHelper::msResourceActivationRequestEvent(
- OUString::createFromAscii("ResourceActivationRequested"));
+ RTL_CONSTASCII_USTRINGPARAM("ResourceActivationRequested"));
const OUString FrameworkHelper::msResourceDeactivationRequestEvent(
- OUString::createFromAscii("ResourceDeactivationRequest"));
+ RTL_CONSTASCII_USTRINGPARAM("ResourceDeactivationRequest"));
const OUString FrameworkHelper::msResourceActivationEvent(
- OUString::createFromAscii("ResourceActivation"));
+ RTL_CONSTASCII_USTRINGPARAM("ResourceActivation"));
const OUString FrameworkHelper::msResourceDeactivationEvent(
- OUString::createFromAscii("ResourceDeactivation"));
+ RTL_CONSTASCII_USTRINGPARAM("ResourceDeactivation"));
const OUString FrameworkHelper::msConfigurationUpdateStartEvent(
- OUString::createFromAscii("ConfigurationUpdateStart"));
+ RTL_CONSTASCII_USTRINGPARAM("ConfigurationUpdateStart"));
const OUString FrameworkHelper::msConfigurationUpdateEndEvent(
- OUString::createFromAscii("ConfigurationUpdateEnd"));
+ RTL_CONSTASCII_USTRINGPARAM("ConfigurationUpdateEnd"));
// Service names of controllers.
const OUString FrameworkHelper::msModuleControllerService(
- OUString::createFromAscii("com.sun.star.drawing.framework.ModuleController"));
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.ModuleController"));
const OUString FrameworkHelper::msConfigurationControllerService(
- OUString::createFromAscii("com.sun.star.drawing.framework.ConfigurationController"));
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.framework.ConfigurationController"));
//----- helper ----------------------------------------------------------------
namespace
@@ -300,7 +302,7 @@ namespace
drawing framework and the enums defined in the ViewShell class.
*/
class FrameworkHelper::ViewURLMap
- : public ::std::hash_map<
+ : public ::boost::unordered_map<
rtl::OUString,
ViewShell::ShellType,
::comphelper::UStringHash,
@@ -800,7 +802,7 @@ class FlagUpdater
{
public:
FlagUpdater (bool& rFlag) : mrFlag(rFlag) {}
- void operator() (bool) {mrFlag = true;}
+ void operator() (bool) const {mrFlag = true;}
private:
bool& mrFlag;
};
@@ -835,7 +837,7 @@ void FrameworkHelper::WaitForEvent (const OUString& rsEventType) const
if( (osl_getGlobalTimer() - nStartTime) > 60000 )
{
- DBG_ERROR("FrameworkHelper::WaitForEvent(), no event for a minute? giving up!");
+ OSL_FAIL("FrameworkHelper::WaitForEvent(), no event for a minute? giving up!");
break;
}
}
@@ -906,7 +908,7 @@ OUString FrameworkHelper::ResourceIdToString (const Reference<XResourceId>& rxRe
Sequence<OUString> aAnchorURLs (rxResourceId->getAnchorURLs());
for (sal_Int32 nIndex=0; nIndex<aAnchorURLs.getLength(); ++nIndex)
{
- sString += OUString::createFromAscii(" | ");
+ sString += OUString(RTL_CONSTASCII_USTRINGPARAM(" | "));
sString += aAnchorURLs[nIndex];
}
}
@@ -1232,3 +1234,5 @@ void LifetimeController::Update (void)
} // end of anonymous namespace.
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/framework/tools/makefile.mk b/sd/source/ui/framework/tools/makefile.mk
deleted file mode 100644
index b09d0fa19..000000000
--- a/sd/source/ui/framework/tools/makefile.mk
+++ /dev/null
@@ -1,51 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=framework_tools
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/FrameworkHelper.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/func/bulmaper.cxx b/sd/source/ui/func/bulmaper.cxx
index 3286571dc..a38f5d93d 100755..100644
--- a/sd/source/ui/func/bulmaper.cxx
+++ b/sd/source/ui/func/bulmaper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,13 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-#ifdef SD_DLLIMPLEMENTATION
-#undef SD_DLLIMPLEMENTATION
-#endif
-
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
//-> Fonts & Items
#include <vcl/font.hxx>
@@ -61,51 +56,6 @@
#define GetWhich(nSlot) rSet.GetPool()->GetWhich( nSlot )
-/* #i35937#
-
-void SdBulletMapper::PreMapNumBulletForDialog( SfxItemSet& rSet )
-{
- if( SFX_ITEM_SET == rSet.GetItemState( EE_PARA_NUMBULLET, sal_False ) )
- {
- SvxNumRule* pRule = ((SvxNumBulletItem*)rSet.GetItem( EE_PARA_NUMBULLET ))->GetNumRule();
-
- if(pRule && pRule->GetNumRuleType() == SVX_RULETYPE_PRESENTATION_NUMBERING)
- {
- // 10er Bullet Item auf 9er Item mappen
- SvxNumRule aNewRule( pRule->GetFeatureFlags(), 9, sal_False, SVX_RULETYPE_PRESENTATION_NUMBERING );
-
- for( sal_uInt16 i = 0; i < 9; i++ )
- aNewRule.SetLevel(i, pRule->GetLevel(i));
-
- rSet.Put( SvxNumBulletItem( aNewRule, EE_PARA_NUMBULLET ) );
- }
- }
-}
-
-void SdBulletMapper::PostMapNumBulletForDialog( SfxItemSet& rSet )
-{
- if( SFX_ITEM_SET == rSet.GetItemState( EE_PARA_NUMBULLET, sal_False ) )
- {
- SvxNumRule* pRule = ((SvxNumBulletItem*)rSet.GetItem( EE_PARA_NUMBULLET ))->GetNumRule();
-
- if(pRule)
- {
- pRule->UnLinkGraphics();
- if(pRule->GetNumRuleType() == SVX_RULETYPE_PRESENTATION_NUMBERING)
- {
- // 9er Bullet Item auf 10er Item mappen
- SvxNumRule aNewRule( pRule->GetFeatureFlags(), 10, sal_False, SVX_RULETYPE_PRESENTATION_NUMBERING );
-
- for( sal_uInt16 i = 0; i < 9; i++ )
- aNewRule.SetLevel(i, pRule->GetLevel(i));
-
- rSet.Put( SvxNumBulletItem( aNewRule, EE_PARA_NUMBULLET ) );
- }
- }
- }
-}
-*/
-
void SdBulletMapper::MapFontsInNumRule( SvxNumRule& aNumRule, const SfxItemSet& rSet )
{
const sal_uInt16 nCount = aNumRule.GetLevelCount();
@@ -177,7 +127,6 @@ void SdBulletMapper::MapFontsInNumRule( SvxNumRule& aNumRule, const SfxItemSet&
aMyFont.SetShadow(rSItem.GetValue());
aNewLevel.SetBulletFont(&aMyFont);
-// aNewLevel.SetBulletRelSize( 75 );
aNumRule.SetLevel(nLevel, aNewLevel );
}
else if( rSrcLevel.GetNumberingType() == com::sun::star::style::NumberingType::CHAR_SPECIAL )
@@ -189,3 +138,5 @@ void SdBulletMapper::MapFontsInNumRule( SvxNumRule& aNumRule, const SfxItemSet&
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuarea.cxx b/sd/source/ui/func/fuarea.cxx
index a2c314e76..6a770f2ef 100755..100644
--- a/sd/source/ui/func/fuarea.cxx
+++ b/sd/source/ui/func/fuarea.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115,3 +116,5 @@ void FuArea::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fubullet.cxx b/sd/source/ui/func/fubullet.cxx
index d7f44dc01..16547e51f 100755..100644
--- a/sd/source/ui/func/fubullet.cxx
+++ b/sd/source/ui/func/fubullet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "fubullet.hxx"
-#ifndef _BINDING_HXX //autogen
#include <sfx2/bindings.hxx>
-#endif
#include <editeng/eeitem.hxx>
#include <svl/poolitem.hxx>
#include <editeng/fontitem.hxx>
@@ -358,3 +357,5 @@ void FuBullet::GetSlotState( SfxItemSet& rSet, ViewShell* pViewShell, SfxViewFra
}
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuchar.cxx b/sd/source/ui/func/fuchar.cxx
index 9173d29db..28951be9e 100755..100644
--- a/sd/source/ui/func/fuchar.cxx
+++ b/sd/source/ui/func/fuchar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -145,3 +146,5 @@ void FuChar::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fucon3d.cxx b/sd/source/ui/func/fucon3d.cxx
index afd3ec7d6..bc1cb14a0 100755..100644
--- a/sd/source/ui/func/fucon3d.cxx
+++ b/sd/source/ui/func/fucon3d.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,7 +57,6 @@
#include "ToolBarManager.hxx"
#include <svx/svx3ditems.hxx>
-// #97016#
#include <svx/polysc3d.hxx>
#include <basegfx/polygon/b2dpolygontools.hxx>
@@ -103,7 +103,6 @@ void FuConstruct3dObject::DoExecute( SfxRequest& rReq )
|*
\************************************************************************/
-// #97016#
E3dCompoundObject* FuConstruct3dObject::ImpCreateBasic3DShape()
{
E3dCompoundObject* p3DObj = NULL;
@@ -260,7 +259,6 @@ E3dCompoundObject* FuConstruct3dObject::ImpCreateBasic3DShape()
return p3DObj;
}
-// #97016#
void FuConstruct3dObject::ImpPrepareBasic3DShape(E3dCompoundObject* p3DObj, E3dScene *pScene)
{
Camera3D &aCamera = (Camera3D&) pScene->GetCamera ();
@@ -288,7 +286,6 @@ void FuConstruct3dObject::ImpPrepareBasic3DShape(E3dCompoundObject* p3DObj, E3dS
case SID_3D_SPHERE:
{
-// pScene->RotateX(DEG2RAD(60));
}
break;
@@ -303,13 +300,11 @@ void FuConstruct3dObject::ImpPrepareBasic3DShape(E3dCompoundObject* p3DObj, E3dS
case SID_3D_CONE:
case SID_3D_PYRAMID:
{
-// pScene->RotateX(DEG2RAD(25));
}
break;
case SID_3D_TORUS:
{
-// pScene->RotateX(DEG2RAD(15));
aTransformation.rotate(DEG2RAD(90), 0.0, 0.0);
}
break;
@@ -341,11 +336,9 @@ sal_Bool FuConstruct3dObject::MouseButtonDown(const MouseEvent& rMEvt)
WaitObject aWait( (Window*)mpViewShell->GetActiveWindow() );
- // #97016#
p3DObj = ImpCreateBasic3DShape();
E3dScene* pScene = mpView->SetCurrent3DObj(p3DObj);
- // #97016#
ImpPrepareBasic3DShape(p3DObj, pScene);
bReturn = mpView->BegCreatePreparedObject(aPnt, nDrgLog, pScene);
@@ -440,17 +433,8 @@ void FuConstruct3dObject::Deactivate()
FuConstruct::Deactivate();
}
-// #97016#
SdrObject* FuConstruct3dObject::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle)
{
- // case SID_3D_CUBE:
- // case SID_3D_SHELL:
- // case SID_3D_SPHERE:
- // case SID_3D_TORUS:
- // case SID_3D_HALF_SPHERE:
- // case SID_3D_CYLINDER:
- // case SID_3D_CONE:
- // case SID_3D_PYRAMID:
E3dCompoundObject* p3DObj = ImpCreateBasic3DShape();
@@ -464,7 +448,6 @@ SdrObject* FuConstruct3dObject::CreateDefaultObject(const sal_uInt16 nID, const
Rectangle a3DRect(0, 0, (long)fW, (long)fH);
E3dScene* pScene = new E3dPolyScene(mpView->Get3DDefaultAttributes());
- // mpView->InitScene(pScene, fW, fH, aVolume.MaxVec().Z() + ((fW + fH) / 4.0));
// copied code from E3dView::InitScene
double fCamZ(aVolume.getMaxZ() + ((fW + fH) / 4.0));
Camera3D aCam(pScene->GetCamera());
@@ -522,10 +505,12 @@ SdrObject* FuConstruct3dObject::CreateDefaultObject(const sal_uInt16 nID, const
}
}
- // #97016#, #98245# use changed rectangle, not original one
+ // use changed rectangle, not original one
pScene->SetLogicRect(aRect);
return pScene;
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconarc.cxx b/sd/source/ui/func/fuconarc.cxx
index 83c350f04..2ddaa22ce 100755..100644
--- a/sd/source/ui/func/fuconarc.cxx
+++ b/sd/source/ui/func/fuconarc.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,7 +52,6 @@
#include "ViewShellBase.hxx"
#include "ToolBarManager.hxx"
-// #97016#
#include <svx/sxciaitm.hxx>
namespace sd {
@@ -143,7 +143,6 @@ sal_Bool FuConstructArc::MouseButtonDown( const MouseEvent& rMEvt )
SfxItemSet aAttr(mpDoc->GetPool());
SetStyleSheet(aAttr, pObj);
-//-/ pObj->NbcSetAttributes(aAttr, sal_False);
pObj->SetMergedItemSet(aAttr);
}
@@ -261,7 +260,6 @@ void FuConstructArc::Activate()
mpView->SetCurrentObj((sal_uInt16)aObjKind);
FuConstruct::Activate();
-// FuDraw::Activate();
}
/*************************************************************************
@@ -273,22 +271,10 @@ void FuConstructArc::Activate()
void FuConstructArc::Deactivate()
{
FuConstruct::Deactivate();
-// FuDraw::Deactivate();
}
-// #97016#
SdrObject* FuConstructArc::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle)
{
- // case SID_DRAW_ARC:
- // case SID_DRAW_CIRCLEARC:
- // case SID_DRAW_PIE:
- // case SID_DRAW_PIE_NOFILL:
- // case SID_DRAW_CIRCLEPIE:
- // case SID_DRAW_CIRCLEPIE_NOFILL:
- // case SID_DRAW_ELLIPSECUT:
- // case SID_DRAW_ELLIPSECUT_NOFILL:
- // case SID_DRAW_CIRCLECUT:
- // case SID_DRAW_CIRCLECUT_NOFILL:
SdrObject* pObj = SdrObjFactory::MakeNewObject(
mpView->GetCurrentObjInventor(), mpView->GetCurrentObjIdentifier(),
@@ -329,7 +315,7 @@ SdrObject* FuConstructArc::CreateDefaultObject(const sal_uInt16 nID, const Recta
}
else
{
- DBG_ERROR("Object is NO circle object");
+ OSL_FAIL("Object is NO circle object");
}
}
@@ -337,3 +323,5 @@ SdrObject* FuConstructArc::CreateDefaultObject(const sal_uInt16 nID, const Recta
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconbez.cxx b/sd/source/ui/func/fuconbez.cxx
index 5575de9e2..2708ec363 100755..100644
--- a/sd/source/ui/func/fuconbez.cxx
+++ b/sd/source/ui/func/fuconbez.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -383,7 +384,6 @@ void FuConstructBezierPolygon::SetEditMode(sal_uInt16 nMode)
rBindings.Invalidate(SID_BEZIER_INSERT);
}
-// #97016#
SdrObject* FuConstructBezierPolygon::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle)
{
// case SID_DRAW_POLYGON:
@@ -524,7 +524,7 @@ SdrObject* FuConstructBezierPolygon::CreateDefaultObject(const sal_uInt16 nID, c
}
else
{
- DBG_ERROR("Object is NO path object");
+ OSL_FAIL("Object is NO path object");
}
pObj->SetLogicRect(rRectangle);
@@ -536,3 +536,5 @@ SdrObject* FuConstructBezierPolygon::CreateDefaultObject(const sal_uInt16 nID, c
} // end of namespace sd
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconcs.cxx b/sd/source/ui/func/fuconcs.cxx
index 95eb7dfd2..35717396e 100755..100644
--- a/sd/source/ui/func/fuconcs.cxx
+++ b/sd/source/ui/func/fuconcs.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,15 +60,12 @@
#include <svx/svdoashp.hxx>
#include <svx/sdtagitm.hxx>
-// #88751#
#include <svx/svdocapt.hxx>
-// #97016#
#include <svx/svdomeas.hxx>
#include "ViewShell.hxx"
#include "ViewShellBase.hxx"
#include "ToolBarManager.hxx"
-// #109583#
#include <editeng/writingmodeitem.hxx>
#include <svx/gallery.hxx>
#include <svl/itempool.hxx>
@@ -314,7 +312,6 @@ void FuConstructCustomShape::SetAttributes( SdrObject* pObj )
}
}
-// #97016#
SdrObject* FuConstructCustomShape::CreateDefaultObject(const sal_uInt16, const Rectangle& rRectangle)
{
SdrObject* pObj = SdrObjFactory::MakeNewObject(
@@ -342,3 +339,5 @@ bool FuConstructCustomShape::doConstructOrthogonal() const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconnct.cxx b/sd/source/ui/func/fuconnct.cxx
index 522d54eaf..9650fa422 100644
--- a/sd/source/ui/func/fuconnct.cxx
+++ b/sd/source/ui/func/fuconnct.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,3 +90,5 @@ void FuConnectionDlg::DoExecute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconrec.cxx b/sd/source/ui/func/fuconrec.cxx
index 639055b05..19d108f2f 100755..100644
--- a/sd/source/ui/func/fuconrec.cxx
+++ b/sd/source/ui/func/fuconrec.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,15 +56,12 @@
#include <editeng/adjitem.hxx>
#include <svx/xtable.hxx>
-// #88751#
#include <svx/svdocapt.hxx>
-// #97016#
#include <svx/svdomeas.hxx>
#include "ViewShell.hxx"
#include "ViewShellBase.hxx"
#include "ToolBarManager.hxx"
-// #109583#
#include <editeng/writingmodeitem.hxx>
#include <basegfx/polygon/b2dpolygontools.hxx>
#include <basegfx/polygon/b2dpolygon.hxx>
@@ -277,7 +275,7 @@ sal_Bool FuConstructRectangle::MouseButtonUp(const MouseEvent& rMEvt)
pObj->SetLayer(rAdmin.GetLayerID(aStr, sal_False));
}
- // #88751# init text position when vertica caption object is created
+ // init text position when vertica caption object is created
if(pObj->ISA(SdrCaptionObj) && SID_DRAW_CAPTION_VERTICAL == nSlotId)
{
// draw text object, needs to be initialized when vertical text is used
@@ -286,7 +284,6 @@ sal_Bool FuConstructRectangle::MouseButtonUp(const MouseEvent& rMEvt)
aSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_CENTER));
aSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT));
- // #109583#
// Correct the value of SDRATTR_TEXTDIRECTION to avoid SetItemSet
// calling SetVerticalWriting() again since this item may not yet
// be set at the object and thus may differ from verical state of
@@ -547,7 +544,7 @@ void FuConstructRectangle::SetAttributes(SfxItemSet& rAttr, SdrObject* pObj)
rAttr.Put( SdrTextAutoGrowHeightItem( sal_True ) );
rAttr.Put( SdrTextAutoGrowWidthItem( sal_True ) );
- // #103516# Support full with for vertical caption objects, too
+ // Support full with for vertical caption objects, too
if(SID_DRAW_CAPTION == nSlotId)
rAttr.Put( SdrTextHorzAdjustItem( SDRTEXTHORZADJUST_BLOCK ) );
else
@@ -804,7 +801,6 @@ void FuConstructRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj)
}
}
-// #97016#
SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle)
{
DBG_ASSERT( (nID != SID_DRAW_FONTWORK) && (nID != SID_DRAW_FONTWORK_VERTICAL ), "FuConstRectangle::CreateDefaultObject can not create Fontwork shapes!" );
@@ -907,7 +903,7 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
}
else
{
- DBG_ERROR("Object is NO line object");
+ OSL_FAIL("Object is NO line object");
}
break;
@@ -923,7 +919,7 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
}
else
{
- DBG_ERROR("Object is NO measure object");
+ OSL_FAIL("Object is NO measure object");
}
break;
@@ -965,7 +961,7 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
}
else
{
- DBG_ERROR("Object is NO connector object");
+ OSL_FAIL("Object is NO connector object");
}
break;
@@ -987,7 +983,7 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
pObj->SetMergedItemSet(aSet);
}
- // For task #105815# the default text is not inserted anymore.
+ // The default text is not inserted anymore.
// String aText(SdResId(STR_POOLSHEET_TEXT));
// ((SdrCaptionObj*)pObj)->SetText(aText);
@@ -997,7 +993,7 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
}
else
{
- DBG_ERROR("Object is NO caption object");
+ OSL_FAIL("Object is NO caption object");
}
break;
@@ -1022,3 +1018,5 @@ SdrObject* FuConstructRectangle::CreateDefaultObject(const sal_uInt16 nID, const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconstr.cxx b/sd/source/ui/func/fuconstr.cxx
index 3c235b61c..14c7c5eeb 100755..100644
--- a/sd/source/ui/func/fuconstr.cxx
+++ b/sd/source/ui/func/fuconstr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,10 +93,6 @@ sal_Bool FuConstruct::MouseButtonDown(const MouseEvent& rMEvt)
if ( mpView->IsAction() )
{
- // #90235# this extra triggering is an error and leads to
- // erasing the last two points when creating a polygon.
- // if ( rMEvt.IsRight() )
- // mpView->BckAction();
return sal_True;
}
@@ -452,3 +449,5 @@ void FuConstruct::SetStyleSheet( SfxItemSet& rAttr, SdrObject* pObj,
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuconuno.cxx b/sd/source/ui/func/fuconuno.cxx
index 606250477..e8c29a551 100755..100644
--- a/sd/source/ui/func/fuconuno.cxx
+++ b/sd/source/ui/func/fuconuno.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,9 +48,7 @@ class SbModule;
#include "glob.hrc"
#include "ViewShell.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "ViewShellBase.hxx"
#include "ToolBarManager.hxx"
#include "drawdoc.hxx"
@@ -201,7 +200,6 @@ void FuConstructUnoControl::Deactivate()
mpWindow->SetPointer( aOldPointer );
}
-// #97016#
SdrObject* FuConstructUnoControl::CreateDefaultObject(const sal_uInt16, const Rectangle& rRectangle)
{
// case SID_FM_CREATE_CONTROL:
@@ -219,3 +217,5 @@ SdrObject* FuConstructUnoControl::CreateDefaultObject(const sal_uInt16, const Re
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fucopy.cxx b/sd/source/ui/func/fucopy.cxx
index cb81387d5..e8641a52e 100755..100644
--- a/sd/source/ui/func/fucopy.cxx
+++ b/sd/source/ui/func/fucopy.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -313,3 +314,5 @@ void FuCopy::DoExecute( SfxRequest& rReq )
}
} // end of namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fucushow.cxx b/sd/source/ui/func/fucushow.cxx
index e0e235dc4..5585b1843 100755..100644
--- a/sd/source/ui/func/fucushow.cxx
+++ b/sd/source/ui/func/fucushow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,5 @@ void FuCustomShowDlg::DoExecute( SfxRequest& )
}
} // end of namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fudraw.cxx b/sd/source/ui/func/fudraw.cxx
index db61065fd..be9ca61b1 100755..100644
--- a/sd/source/ui/func/fudraw.cxx
+++ b/sd/source/ui/func/fudraw.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,9 +65,7 @@
#include "ViewShell.hxx"
#include "FrameView.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "DrawDocShell.hxx"
#include "Client.hxx"
@@ -118,7 +117,7 @@ FuDraw::~FuDraw()
sal_Bool FuDraw::MouseButtonDown(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
sal_Bool bReturn = sal_False;
@@ -131,9 +130,7 @@ sal_Bool FuDraw::MouseButtonDown(const MouseEvent& rMEvt)
{
FrameView* pFrameView = mpViewShell->GetFrameView();
-// sal_Bool bOrtho = mpView->IsOrthoDesired() || pFrameView->IsOrtho();
-// bOrtho = bOrtho != rMEvt.IsShift();
- sal_Bool bOrtho = sal_False;
+ bool bOrtho = sal_False;
sal_Bool bRestricted = sal_True;
@@ -221,7 +218,7 @@ sal_Bool FuDraw::MouseButtonDown(const MouseEvent& rMEvt)
SdrPageView* pPV = 0;
sal_uInt16 nHitLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(HITPIX,0)).Width() );
- // #76572# look only for HelpLines when they are visible (!)
+ // look only for HelpLines when they are visible (!)
sal_Bool bHelpLine(sal_False);
if(mpView->IsHlplVisible())
bHelpLine = mpView->PickHelpLine(aMDPos, nHitLog, *mpWindow, nHelpLine, pPV);
@@ -253,9 +250,7 @@ sal_Bool FuDraw::MouseMove(const MouseEvent& rMEvt)
FrameView* pFrameView = mpViewShell->GetFrameView();
Point aPos = mpWindow->PixelToLogic( rMEvt.GetPosPixel() );
-// sal_Bool bOrtho = mpView->IsOrthoDesired() || pFrameView->IsOrtho();
-// bOrtho = bOrtho != rMEvt.IsShift();
- sal_Bool bOrtho = sal_False;
+ bool bOrtho = sal_False;
sal_Bool bRestricted = sal_True;
@@ -439,7 +434,7 @@ sal_Bool FuDraw::KeyInput(const KeyEvent& rKEvt)
// nicht mehr versucht wird, ein Grafik-Objekt
// zu restaurieren, das gar nicht mehr existiert.
// Alle anderen OLE-Objekte sind davon nicht
- // betroffen (KA 06.10.95)
+ // betroffen
OSL_ASSERT (mpViewShell->GetViewShell()!=NULL);
Client* pIPClient = static_cast<Client*>(
mpViewShell->GetViewShell()->GetIPClient());
@@ -462,7 +457,7 @@ sal_Bool FuDraw::KeyInput(const KeyEvent& rKEvt)
if ( !aCode.IsMod1() && !aCode.IsMod2() )
{
- // #105336# Moved next line which was a bugfix itself into
+ // Moved next line which was a bugfix itself into
// the scope which really does the object selection travel
// and thus is allowed to call SelectionHasChanged().
@@ -474,13 +469,12 @@ sal_Bool FuDraw::KeyInput(const KeyEvent& rKEvt)
// changeover to the next object
if(!mpView->MarkNextObj( !aCode.IsShift() ))
{
- // #97016# No next object: go over open end and
+ // No next object: go over open end and
// get first from the other side
mpView->UnmarkAllObj();
mpView->MarkNextObj(!aCode.IsShift());
}
- // #97016# II
if(mpView->AreObjectsMarked())
mpView->MakeVisible(mpView->GetAllMarkedRect(), *mpWindow);
@@ -495,11 +489,10 @@ sal_Bool FuDraw::KeyInput(const KeyEvent& rKEvt)
if ( aCode.IsMod1() )
{
- // #97016# mark last object
+ // mark last object
mpView->UnmarkAllObj();
mpView->MarkNextObj(sal_False);
- // #97016# II
if(mpView->AreObjectsMarked())
mpView->MakeVisible(mpView->GetAllMarkedRect(), *mpWindow);
@@ -514,11 +507,10 @@ sal_Bool FuDraw::KeyInput(const KeyEvent& rKEvt)
if ( aCode.IsMod1() )
{
- // #97016# mark first object
+ // mark first object
mpView->UnmarkAllObj();
mpView->MarkNextObj(sal_True);
- // #97016# II
if(mpView->AreObjectsMarked())
mpView->MakeVisible(mpView->GetAllMarkedRect(), *mpWindow);
@@ -844,9 +836,8 @@ void FuDraw::DoubleClick(const MouseEvent& rMEvt)
if ( !pDocSh->IsUIActive() )
{
/**********************************************************
- * aktivate OLE-object
+ * activate OLE-object
**********************************************************/
- //HMHmpView->HideMarkHdl();
mpViewShell->ActivateObject( (SdrOle2Obj*) pObj, 0);
}
}
@@ -1115,7 +1106,6 @@ bool FuDraw::cancel()
}
else if ( mpView->AreObjectsMarked() )
{
- // #97016# II
const SdrHdlList& rHdlList = mpView->GetHdlList();
SdrHdl* pHdl = rHdlList.GetFocusHdl();
@@ -1140,3 +1130,5 @@ bool FuDraw::cancel()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fudspord.cxx b/sd/source/ui/func/fudspord.cxx
index 297b11877..75cdb19bd 100755..100644
--- a/sd/source/ui/func/fudspord.cxx
+++ b/sd/source/ui/func/fudspord.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,9 +40,7 @@
#include "fupoor.hxx"
#include "ViewShell.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
namespace sd {
@@ -95,7 +94,7 @@ FunctionReference FuDisplayOrder::Create( ViewShell* pViewSh, ::sd::Window* pWin
sal_Bool FuDisplayOrder::MouseButtonDown(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
return sal_True;
@@ -144,7 +143,7 @@ sal_Bool FuDisplayOrder::MouseMove(const MouseEvent& rMEvt)
sal_Bool FuDisplayOrder::MouseButtonUp(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
SdrPageView* pPV = NULL;
@@ -192,3 +191,5 @@ void FuDisplayOrder::Deactivate()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuediglu.cxx b/sd/source/ui/func/fuediglu.cxx
index 3d2256134..da905df31 100755..100644
--- a/sd/source/ui/func/fuediglu.cxx
+++ b/sd/source/ui/func/fuediglu.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,13 +39,9 @@
#include "app.hrc"
#include "strings.hrc"
#include "res_bmp.hrc"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "View.hxx"
#include "ViewShell.hxx"
#include "ViewShellBase.hxx"
@@ -462,3 +459,5 @@ void FuEditGluePoints::ReceiveRequest(SfxRequest& rReq)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuexpand.cxx b/sd/source/ui/func/fuexpand.cxx
index 4a437969f..4013d3a55 100755..100644
--- a/sd/source/ui/func/fuexpand.cxx
+++ b/sd/source/ui/func/fuexpand.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -197,8 +198,7 @@ void FuExpandPage::DoExecute( SfxRequest& )
// Title-Textobjekt erstellen
SdrTextObj* pTextObj = (SdrTextObj*) pPage->GetPresObj(PRESOBJ_TITLE);
-
-//
+
OutlinerParaObject* pOutlinerParaObject = pOutl->CreateParaObject( (sal_uInt16) nParaPos, 1);
pOutlinerParaObject->SetOutlinerMode(OUTLINERMODE_TITLEOBJECT);
@@ -233,7 +233,6 @@ void FuExpandPage::DoExecute( SfxRequest& )
OutlinerParaObject* pOPO = pOutl->CreateParaObject( (sal_uInt16) nParaPos, (sal_uInt16) nChildCount);
-// --
SdrOutliner* pTempOutl = SdrMakeOutliner( OUTLINERMODE_OUTLINEOBJECT, mpDoc );
pTempOutl->SetText( *pOPO );
@@ -250,7 +249,6 @@ void FuExpandPage::DoExecute( SfxRequest& )
pOPO = pTempOutl->CreateParaObject();
delete pTempOutl;
-// --
pOutlineObj->SetOutlinerParaObject( pOPO );
pOutlineObj->SetEmptyPresObj(sal_False);
@@ -276,3 +274,5 @@ void FuExpandPage::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuformatpaintbrush.cxx b/sd/source/ui/func/fuformatpaintbrush.cxx
index ab13e7704..6968784d7 100755..100644
--- a/sd/source/ui/func/fuformatpaintbrush.cxx
+++ b/sd/source/ui/func/fuformatpaintbrush.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,9 +54,7 @@
#include "Outliner.hxx"
#include "ViewShellBase.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
namespace sd {
@@ -293,3 +292,5 @@ void FuFormatPaintBrush::Paste( bool bNoCharacterFormats, bool bNoParagraphForma
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuhhconv.cxx b/sd/source/ui/func/fuhhconv.cxx
index ce28b1e77..b9c6e2222 100755..100644
--- a/sd/source/ui/func/fuhhconv.cxx
+++ b/sd/source/ui/func/fuhhconv.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -229,7 +230,7 @@ void FuHangulHanjaConversion::StartChineseConversion()
{
Reference< ui::dialogs::XExecutableDialog > xDialog(
xMCF->createInstanceWithContext(
- rtl::OUString::createFromAscii("com.sun.star.linguistic2.ChineseTranslationDialog")
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.linguistic2.ChineseTranslationDialog"))
, xContext), UNO_QUERY);
Reference< lang::XInitialization > xInit( xDialog, UNO_QUERY );
if( xInit.is() )
@@ -239,7 +240,7 @@ void FuHangulHanjaConversion::StartChineseConversion()
Sequence<Any> aSeq(1);
Any* pArray = aSeq.getArray();
PropertyValue aParam;
- aParam.Name = rtl::OUString::createFromAscii("ParentWindow");
+ aParam.Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ParentWindow"));
aParam.Value <<= makeAny(xDialogParentWindow);
pArray[0] <<= makeAny(aParam);
xInit->initialize( aSeq );
@@ -288,3 +289,5 @@ void FuHangulHanjaConversion::StartChineseConversion()
}
}
} // end of namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuinsert.cxx b/sd/source/ui/func/fuinsert.cxx
index 6809328dd..3d958b50d 100755..100644
--- a/sd/source/ui/func/fuinsert.cxx
+++ b/sd/source/ui/func/fuinsert.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,14 +49,14 @@
#include <sfx2/request.hxx>
#include <svl/globalnameitem.hxx>
#include <unotools/pathoptions.hxx>
+#include <svtools/miscopt.hxx>
#include <svx/pfiledlg.hxx>
#include <svx/dialogs.hrc>
#include <sfx2/linkmgr.hxx>
+#include <svx/linkwarn.hxx>
#include <svx/svdetc.hxx>
#include <avmedia/mediawindow.hxx>
-#ifndef _UNOTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
#include <sfx2/printer.hxx>
#include <sot/clsids.hxx>
#include <svtools/sfxecode.hxx>
@@ -65,21 +66,16 @@
#include <svx/svdograf.hxx>
#include <svx/svdoole2.hxx>
#include <svx/svdomedia.hxx>
-#ifndef _EDITENG_HXX //autogen
#include <editeng/editeng.hxx>
-#endif
#include <sot/storage.hxx>
#include <sot/formats.hxx>
#include <svx/svdpagv.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <sfx2/opengrf.hxx>
#include <sfx2/viewfrm.hxx>
#include "app.hrc"
-#include "misc.hxx"
#include "sdresid.hxx"
#include "View.hxx"
#include "app.hxx"
@@ -156,7 +152,15 @@ void FuInsertGraphic::DoExecute( SfxRequest& )
if(pGrafObj && aDlg.IsAsLink())
{
- // store link only?
+ // really store as link only?
+ if( SvtMiscOptions().ShowLinkWarningDialog() )
+ {
+ SvxLinkWarningDialog aWarnDlg(mpWindow,aDlg.GetPath());
+ if( aWarnDlg.Execute() != RET_OK )
+ return; // don't store as link
+ }
+
+ // store as link
String aFltName(aDlg.GetCurrentFilter());
String aPath(aDlg.GetPath());
pGrafObj->SetGraphicLink(aPath, aFltName);
@@ -165,7 +169,7 @@ void FuInsertGraphic::DoExecute( SfxRequest& )
}
else
{
- SdGRFFilter::HandleGraphicFilterError( (sal_uInt16)nError, GraphicFilter::GetGraphicFilter()->GetLastError().nStreamError );
+ SdGRFFilter::HandleGraphicFilterError( (sal_uInt16)nError, GraphicFilter::GetGraphicFilter().GetLastError().nStreamError );
}
}
}
@@ -389,7 +393,6 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
pOleObj->SetProgName( UniString::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( "StarMath" ) ) );
}
- //HMHmpView->HideMarkHdl();
pOleObj->SetLogicRect(aRect);
Size aTmp( OutputDevice::LogicToLogic( aRect.GetSize(), MAP_100TH_MM, aUnit ) );
awt::Size aVisualSize;
@@ -502,7 +505,7 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
uno::Reference < beans::XPropertySet > xSet( xSup->getComponent(), uno::UNO_QUERY );
if ( xSet.is() )
{
- xSet->setPropertyValue( ::rtl::OUString::createFromAscii("PluginURL"),
+ xSet->setPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PluginURL")),
uno::makeAny( ::rtl::OUString( aURL.GetMainURL( INetURLObject::NO_DECODE ) ) ) );
}
}
@@ -593,8 +596,6 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
( (SdrOle2Obj*) pObj)->SetAspect(nAspect);
Rectangle aRect = ( (SdrOle2Obj*) pObj)->GetLogicRect();
- //HMHmpView->HideMarkHdl();
-
if ( nAspect == embed::Aspects::MSOLE_ICON )
{
if( xIconMetaFile.is() )
@@ -636,7 +637,7 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
if( mpView->InsertObjectAtView(pObj, *pPV, SDRINSERT_SETDEFLAYER) )
{
- // #73279# Math objects change their object size during InsertObject.
+ // Math objects change their object size during InsertObject.
// New size must be set in SdrObject, or a wrong scale will be set at
// ActivateObject.
@@ -660,7 +661,6 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
if (bCreateNew)
{
- //HMHmpView->HideMarkHdl();
pObj->SetLogicRect(aRect);
if ( nAspect != embed::Aspects::MSOLE_ICON )
@@ -777,3 +777,5 @@ void FuInsertAVMedia::DoExecute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuinsfil.cxx b/sd/source/ui/func/fuinsfil.cxx
index 82e18683a..521c91a85 100755..100644
--- a/sd/source/ui/func/fuinsfil.cxx
+++ b/sd/source/ui/func/fuinsfil.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#include <vcl/wrkwin.hxx>
#include <sfx2/progress.hxx>
#include <editeng/outliner.hxx>
-#ifndef _EDITENG_HXX
#include <editeng/editeng.hxx>
-#endif
#include <svl/stritem.hxx>
#include <sfx2/request.hxx>
#include <sfx2/app.hxx>
@@ -412,7 +411,7 @@ sal_Bool FuInsertFile::InsSDDinDrMode(SfxMedium* pMedium)
bLink, bReplace, nPos,
sal_False, NULL, sal_True, sal_True, sal_False );
- // Loeschen der BookmarkList
+ // delete the BookmarkList
if( pBookmarkList )
{
String* pString = (String*) pBookmarkList->First();
@@ -424,7 +423,7 @@ sal_Bool FuInsertFile::InsSDDinDrMode(SfxMedium* pMedium)
delete pBookmarkList;
pBookmarkList = NULL;
}
- // Loeschen der ExchangeList
+ // delete the ExchangeList
if( pExchangeList )
{
String* pString = (String*) pExchangeList->First();
@@ -438,7 +437,6 @@ sal_Bool FuInsertFile::InsSDDinDrMode(SfxMedium* pMedium)
}
}
// Dann Objekte einfuegen
- //pBookmarkList = pDlg->GetList( 2 ); // Objekte
pBookmarkList = pObjectBookmarkList;
// Um zu gewaehrleisten... (s.o.)
@@ -448,7 +446,7 @@ sal_Bool FuInsertFile::InsSDDinDrMode(SfxMedium* pMedium)
bOK = mpDoc->InsertBookmarkAsObject( pBookmarkList, pExchangeList,
bLink, NULL, NULL);
- // Loeschen der BookmarkList
+ // delete the BookmarkList
if( pBookmarkList )
{
String* pString = (String*) pBookmarkList->First();
@@ -460,7 +458,7 @@ sal_Bool FuInsertFile::InsSDDinDrMode(SfxMedium* pMedium)
delete pBookmarkList;
pBookmarkList = NULL;
}
- // Loeschen der ExchangeList
+ // delete the ExchangeList
if( pExchangeList )
{
String* pString = (String*) pExchangeList->First();
@@ -513,11 +511,7 @@ void FuInsertFile::InsTextOrRTFinDrMode(SfxMedium* pMedium)
// was zeichnen muessen;
// der globale Outliner koennte in SdPage::CreatePresObj
// benutzt werden
-// SfxItemPool* pPool = mpDoc->GetDrawOutliner().GetEmptyItemSet().GetPool();
SdrOutliner* pOutliner = new ::sd::Outliner( mpDoc, OUTLINERMODE_TEXTOBJECT );
-// pOutliner->SetStyleSheetPool((SfxStyleSheetPool*)mpDoc->GetStyleSheetPool());
-// pOutliner->SetEditTextObjectPool(pPool);
-// pOutliner->SetForbiddenCharsTable( mpDoc->GetForbiddenCharsTable() );
// Referenz-Device setzen
pOutliner->SetRefDevice( SD_MOD()->GetRefDevice( *mpDocSh ) );
@@ -636,14 +630,16 @@ void FuInsertFile::InsTextOrRTFinOlMode(SfxMedium* pMedium)
nFormat = EE_FORMAT_HTML;
::Outliner* pDocliner = static_cast<OutlineView*>(mpView)->GetOutliner();
- List* pList = pDocliner->GetView(0)->CreateSelectionList();
- Paragraph* pPara = (Paragraph*)pList->First();
+
+ std::vector<Paragraph*> aSelList;
+ pDocliner->GetView(0)->CreateSelectionList(aSelList);
+
+ Paragraph* pPara = aSelList.empty() ? NULL : *(aSelList.begin());
// wo soll eingefuegt werden?
while( !pDocliner->HasParaFlag( pPara, PARAFLAG_ISPAGE ) )
- {
pPara = pDocliner->GetParent(pPara);
- }
+
sal_uLong nTargetPos = pDocliner->GetAbsPos(pPara) + 1;
// Layout der Vorgaengerseite uebernehmen
@@ -822,3 +818,5 @@ void FuInsertFile::GetSupportedFilterVector( ::std::vector< String >& rFilterVec
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuline.cxx b/sd/source/ui/func/fuline.cxx
index e6af62660..4d48769b7 100755..100644
--- a/sd/source/ui/func/fuline.cxx
+++ b/sd/source/ui/func/fuline.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,9 +44,7 @@
#include <sfx2/viewfrm.hxx>
#include "ViewShell.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "app.hrc"
#include <svx/svxdlg.hxx>
@@ -128,3 +127,5 @@ void FuLine::Deactivate()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fulinend.cxx b/sd/source/ui/func/fulinend.cxx
index 006af3197..1000607a5 100755..100644
--- a/sd/source/ui/func/fulinend.cxx
+++ b/sd/source/ui/func/fulinend.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,9 +44,7 @@
#include "sdresid.hxx"
#include "drawdoc.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
namespace sd {
@@ -181,3 +180,5 @@ void FuLineEnd::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fulink.cxx b/sd/source/ui/func/fulink.cxx
index 854994520..922af457f 100644
--- a/sd/source/ui/func/fulink.cxx
+++ b/sd/source/ui/func/fulink.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,9 +38,7 @@
#include <svx/svxdlg.hxx>
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "ViewShell.hxx"
#include "app.hrc"
@@ -90,3 +89,5 @@ void FuLink::DoExecute( SfxRequest& )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fumeasur.cxx b/sd/source/ui/func/fumeasur.cxx
index 6ff3a6b6f..4ce60fb86 100644
--- a/sd/source/ui/func/fumeasur.cxx
+++ b/sd/source/ui/func/fumeasur.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,5 @@ void FuMeasureDlg::DoExecute( SfxRequest& rReq )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fumorph.cxx b/sd/source/ui/func/fumorph.cxx
index 58c3ee8d6..6d71b1753 100755..100644
--- a/sd/source/ui/func/fumorph.cxx
+++ b/sd/source/ui/func/fumorph.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -511,3 +512,5 @@ sal_Bool FuMorph::ImpMorphPolygons(
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuoaprms.cxx b/sd/source/ui/func/fuoaprms.cxx
index 04770bb1e..3c2f59be0 100755..100644
--- a/sd/source/ui/func/fuoaprms.cxx
+++ b/sd/source/ui/func/fuoaprms.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,9 +41,7 @@
#include <sfx2/objsh.hxx>
#include <sfx2/request.hxx>
#include <sfx2/viewfrm.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svl/aeitem.hxx>
#include "svx/xtable.hxx"
@@ -52,7 +51,7 @@
#include "ViewShell.hxx"
#include "anminfo.hxx"
#include "unoaprms.hxx" // Undo-Action
-#include "sdundogr.hxx" // Undo Gruppe
+#include "sdundogr.hxx" // Undo Group
#include "View.hxx"
#include "sdabstdlg.hxx"
#include "sdresid.hxx"
@@ -118,11 +117,7 @@ void FuObjectAnimationParameters::DoExecute( SfxRequest& rReq )
short nSecondSoundOnSet = ATTR_MISSING;
short nSecondPlayFullSet = ATTR_MISSING;
-
-
-// sal_Bool bDontKnow = sal_False;
-
- // defaulten (fuer Undo-Aktion)
+ // defaults (for Undo-Action)
presentation::AnimationEffect eEffect = presentation::AnimationEffect_NONE;
presentation::AnimationEffect eTextEffect = presentation::AnimationEffect_NONE;
presentation::AnimationSpeed eSpeed = presentation::AnimationSpeed_MEDIUM;
@@ -728,10 +723,8 @@ void FuObjectAnimationParameters::DoExecute( SfxRequest& rReq )
pAction->SetSoundOn(pInfo->mbSoundOn, pInfo->mbSoundOn);
pAction->SetSound(pInfo->maSoundFile, pInfo->maSoundFile);
pAction->SetPlayFull(pInfo->mbPlayFull, pInfo->mbPlayFull);
-// pAction->SetPathObj(pInfo->mpPathObj, pInfo->mpPathObj);
pAction->SetClickAction(pInfo->meClickAction, pInfo->meClickAction);
pAction->SetBookmark(pInfo->GetBookmark(), pInfo->GetBookmark());
-// pAction->SetInvisibleInPres(pInfo->mbInvisibleInPresentation, sal_True);
pAction->SetVerb(pInfo->mnVerb, pInfo->mnVerb);
pAction->SetSecondEffect(pInfo->meSecondEffect, pInfo->meSecondEffect);
pAction->SetSecondSpeed(pInfo->meSecondSpeed, pInfo->meSecondSpeed);
@@ -739,7 +732,6 @@ void FuObjectAnimationParameters::DoExecute( SfxRequest& rReq )
pAction->SetSecondPlayFull(pInfo->mbSecondPlayFull, pInfo->mbSecondPlayFull);
pUndoGroup->AddAction(pAction);
-// pInfo->mbInvisibleInPresentation = sal_True;
}
else
{
@@ -760,8 +752,6 @@ void FuObjectAnimationParameters::DoExecute( SfxRequest& rReq )
pAction->SetPathObj(pInfo->mpPathObj, pPath);
pAction->SetClickAction(pInfo->meClickAction, eClickAction);
pAction->SetBookmark(pInfo->GetBookmark(), aBookmark);
-// pAction->SetInvisibleInPres(pInfo->mbInvisibleInPresentation,
-// pInfo->mbInvisibleInPresentation);
pAction->SetVerb(pInfo->mnVerb, (sal_uInt16)pInfo->GetBookmark().ToInt32() );
pAction->SetSecondEffect(pInfo->meSecondEffect, eSecondEffect);
pAction->SetSecondSpeed(pInfo->meSecondSpeed, eSecondSpeed);
@@ -818,22 +808,20 @@ void FuObjectAnimationParameters::DoExecute( SfxRequest& rReq )
if (nSecondPlayFullSet == ATTR_SET)
pInfo->mbSecondPlayFull = bSecondPlayFull;
- // noch ein paar Spezialitaeten
-// if (eEffect == presentation::AnimationEffect_PATH && nEffectSet == ATTR_SET)
-// pInfo->mSetPath(pPath);
-
if (eClickAction == presentation::ClickAction_VERB)
pInfo->mnVerb = (sal_uInt16)aBookmark.ToInt32();
}
}
- // Undo Gruppe dem Undo Manager uebergeben
+ // Set the Undo Group in of the Undo Manager
pUndoMgr->AddUndoAction(pUndoGroup);
pUndoMgr->LeaveListAction();
- // Model geaendert
+ // Model changed
mpDoc->SetChanged();
}
// sieht man nicht, also muss an den Bindings nicht invalidiert werden
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuolbull.cxx b/sd/source/ui/func/fuolbull.cxx
index 5cb4ee7bd..0cc9f0c3d 100755..100644
--- a/sd/source/ui/func/fuolbull.cxx
+++ b/sd/source/ui/func/fuolbull.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,9 +43,7 @@
#include "OutlineView.hxx"
#include "OutlineViewShell.hxx"
#include "DrawViewShell.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "sdabstdlg.hxx"
@@ -144,3 +143,5 @@ void FuOutlineBullet::DoExecute( SfxRequest& rReq )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuoltext.cxx b/sd/source/ui/func/fuoltext.cxx
index 76b4a7b99..b203cfaa2 100755..100644
--- a/sd/source/ui/func/fuoltext.cxx
+++ b/sd/source/ui/func/fuoltext.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,9 +43,7 @@
#include <svx/svxids.hrc>
#include "app.hrc"
#include "OutlineView.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "DrawDocShell.hxx"
#include "ViewShell.hxx"
#include "OutlineViewShell.hxx"
@@ -156,22 +155,6 @@ sal_Bool FuOutlineText::MouseMove(const MouseEvent& rMEvt)
bReturn = FuOutline::MouseMove(rMEvt);
}
- // MT 07/2002: Done in OutlinerView::MouseMove
- /*
- const SvxFieldItem* pFieldItem = pOutlineView->GetViewByWindow( mpWindow )->
- GetFieldUnderMousePointer();
- const SvxFieldData* pField = NULL;
- if( pFieldItem )
- pField = pFieldItem->GetField();
-
- if( pField && pField->ISA( SvxURLField ) )
- {
- mpWindow->SetPointer( Pointer( POINTER_REFHAND ) );
- }
- else
- mpWindow->SetPointer( Pointer( POINTER_TEXT ) );
- */
-
return (bReturn);
}
@@ -359,3 +342,5 @@ void FuOutlineText::DoPaste()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuoutl.cxx b/sd/source/ui/func/fuoutl.cxx
index 8fede7808..f5dde86d3 100755..100644
--- a/sd/source/ui/func/fuoutl.cxx
+++ b/sd/source/ui/func/fuoutl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include <editeng/outliner.hxx>
#include "OutlineView.hxx"
#include "OutlineViewShell.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
namespace sd {
@@ -92,3 +91,5 @@ void FuOutline::ScrollEnd()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fupage.cxx b/sd/source/ui/func/fupage.cxx
index f7db77a07..b28a8bf89 100755..100644
--- a/sd/source/ui/func/fupage.cxx
+++ b/sd/source/ui/func/fupage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,20 +39,14 @@
#include <svx/svxids.hrc>
#include <svx/dialogs.hrc>
#include <svl/itempool.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <sfx2/request.hxx>
#include <svl/stritem.hxx>
#include <vcl/prntypes.hxx>
#include <svl/style.hxx>
#include <stlsheet.hxx>
-#ifndef _SVX_SVDORECT_HXX
#include <svx/svdorect.hxx>
-#endif
-#ifndef _SVX_SVDUNDO_HXX
#include <svx/svdundo.hxx>
-#endif
#include <editeng/eeitem.hxx>
#include <editeng/frmdiritem.hxx>
#include <svx/xbtmpit.hxx>
@@ -635,3 +630,5 @@ void FuPage::ApplyItemSet( const SfxItemSet* pArgs )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuparagr.cxx b/sd/source/ui/func/fuparagr.cxx
index ba11fd0bb..224b73947 100755..100644
--- a/sd/source/ui/func/fuparagr.cxx
+++ b/sd/source/ui/func/fuparagr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "fuparagr.hxx"
#include <editeng/eeitem.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <sfx2/bindings.hxx>
#include <sfx2/request.hxx>
#include <sfx2/viewfrm.hxx>
@@ -185,3 +184,5 @@ void FuParagraph::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fupoor.cxx b/sd/source/ui/func/fupoor.cxx
index 88c93b41f..bf07a4a10 100755..100644
--- a/sd/source/ui/func/fupoor.cxx
+++ b/sd/source/ui/func/fupoor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,17 +48,13 @@
#include <com/sun/star/drawing/XLayerManager.hpp>
#include <com/sun/star/container/XChild.hpp>
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "app.hrc"
#include "fusel.hxx"
#include "sdpage.hxx"
#include "drawview.hxx"
#include "DrawViewShell.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "DrawDocShell.hxx"
#include "zoomlist.hxx"
@@ -67,10 +64,8 @@
#include <sfx2/viewfrm.hxx>
-// #97016# IV
#include <svx/svditer.hxx>
-// #98533#
#include <editeng/editeng.hxx>
using namespace ::com::sun::star;
@@ -105,7 +100,7 @@ FuPoor::FuPoor (
bScrollable (sal_False),
bDelayActive (sal_False),
bFirstMouseMove (sal_False),
- // #95491# remember MouseButton state
+ // remember MouseButton state
mnCode(0)
{
ReceiveRequest(rReq);
@@ -186,14 +181,6 @@ void FuPoor::ForceScroll(const Point& aPixPos)
if ( !mpView->IsDragHelpLine() && !mpView->IsSetPageOrg() &&
!SlideShow::IsRunning( mpViewShell->GetViewShellBase() ) )
{
-/* Size aSize = mpWindow->GetSizePixel();
- short dx = 0, dy = 0;
-
- if ( aPixPos.X() <= 0 ) dx = -1;
- if ( aPixPos.X() >= aSize.Width() ) dx = 1;
- if ( aPixPos.Y() <= 0 ) dy = -1;
- if ( aPixPos.Y() >= aSize.Height() ) dy = 1;
-*/
Point aPos = mpWindow->OutputToScreenPixel(aPixPos);
const Rectangle& rRect = mpViewShell->GetAllWindowRect();
@@ -237,7 +224,7 @@ IMPL_LINK_INLINE_START( FuPoor, ScrollHdl, Timer *, EMPTYARG )
{
Point aPnt(mpWindow->GetPointerPosPixel());
- // #95491# use remembered MouseButton state to create correct
+ // use remembered MouseButton state to create correct
// MouseEvents for this artifical MouseMove.
MouseMove(MouseEvent(aPnt, 1, 0, GetMouseButtonCode()));
@@ -262,7 +249,6 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
switch (nCode)
{
- // #97016# IV
case KEY_RETURN:
{
if(rKEvt.GetKeyCode().IsMod1())
@@ -317,8 +303,8 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
else
{
- // #98255# activate OLE object on RETURN for selected object
- // #98198# activate text edit on RETURN for selected object
+ // activate OLE object on RETURN for selected object
+ // activate text edit on RETURN for selected object
const SdrMarkList& rMarkList = mpView->GetMarkedObjectList();
if( !mpView->IsTextEdit() && 1 == rMarkList.GetMarkCount() )
@@ -346,13 +332,12 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
break;
- // #97016# II
case KEY_TAB:
{
- // #98994# handle Mod1 and Mod2 to get travelling running on different systems
+ // handle Mod1 and Mod2 to get travelling running on different systems
if(rKEvt.GetKeyCode().IsMod1() || rKEvt.GetKeyCode().IsMod2())
{
- // #97016# II do something with a selected handle?
+ // do something with a selected handle?
const SdrHdlList& rHdlList = mpView->GetHdlList();
sal_Bool bForward(!rKEvt.GetKeyCode().IsShift());
@@ -586,7 +571,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
break;
- // #97016# II change select state when focus is on poly point
+ // change select state when focus is on poly point
case KEY_SPACE:
{
const SdrHdlList& rHdlList = mpView->GetHdlList();
@@ -685,11 +670,9 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
if (mpView->AreObjectsMarked() && !rKEvt.GetKeyCode().IsMod1() &&
!mpDocSh->IsReadOnly())
{
- // #97016# II
const SdrHdlList& rHdlList = mpView->GetHdlList();
SdrHdl* pHdl = rHdlList.GetFocusHdl();
- // #109007#
sal_Bool bIsMoveOfConnectedHandle(sal_False);
sal_Bool bOldSuppress = false;
SdrEdgeObj* pEdgeObj = 0L;
@@ -714,7 +697,6 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
}
- // #109007#
if(pEdgeObj)
{
// Suppress default connects to inside object and object center
@@ -722,7 +704,6 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
pEdgeObj->SetSuppressDefaultConnect(sal_True);
}
- // #109007#
if(bIsMoveOfConnectedHandle)
{
sal_uInt16 nMarkHdSiz(mpView->GetMarkHdlSizePixel());
@@ -741,7 +722,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
else if(rKEvt.GetKeyCode().IsMod2())
{
- // #97016# move in 1 pixel distance
+ // move in 1 pixel distance
Size aLogicSizeOnePixel = (mpWindow) ? mpWindow->PixelToLogic(Size(1,1)) : Size(100, 100);
nX *= aLogicSizeOnePixel.Width();
nY *= aLogicSizeOnePixel.Height();
@@ -760,10 +741,10 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
if(0L == pHdl)
{
- // #67368# only take action when move is allowed
+ // only take action when move is allowed
if(mpView->IsMoveAllowed())
{
- // #90129# restrict movement to WorkArea
+ // restrict movement to WorkArea
const Rectangle& rWorkArea = mpView->GetWorkArea();
if(!rWorkArea.IsEmpty())
@@ -800,7 +781,6 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
{
mpView->MoveAllMarked(Size(nX, nY));
- // #97016# II
mpView->MakeVisible(mpView->GetAllMarkedRect(), *mpWindow);
}
}
@@ -820,7 +800,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
if(mpView->IsDragObj())
{
- FASTBOOL bWasNoSnap = rDragStat.IsNoSnap();
+ bool bWasNoSnap = rDragStat.IsNoSnap();
sal_Bool bWasSnapEnabled = mpView->IsSnapEnabled();
// switch snapping off
@@ -845,7 +825,6 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
}
- // #109007#
if(pEdgeObj)
{
// Restore original suppress value
@@ -871,7 +850,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
mpWindow->ReleaseMouse();
}
- // #98198# when a text-editable object is selected and the
+ // when a text-editable object is selected and the
// input character is printable, activate text edit on that object
// and feed character to object
if(!bReturn && !mpDocSh->IsReadOnly())
@@ -886,8 +865,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
if(pObj->ISA(SdrTextObj) && pObj->HasTextEdit() && !pObj->ISA(SdrOle2Obj))
{
- // #98533# use common IsSimpleCharInput from
- // the EditEngine.
+ // use common IsSimpleCharInput from the EditEngine.
sal_Bool bPrintable(EditEngine::IsSimpleCharInput(rKEvt));
if(bPrintable)
@@ -908,7 +886,7 @@ sal_Bool FuPoor::KeyInput(const KeyEvent& rKEvt)
}
else
{
- // #99039# test if there is a title object there. If yes, try to
+ // test if there is a title object there. If yes, try to
// set it to edit mode and start typing...
if(mpViewShell->ISA(DrawViewShell)
&& EditEngine::IsSimpleCharInput(rKEvt))
@@ -968,7 +946,6 @@ sal_Bool FuPoor::MouseMove(const MouseEvent& )
return sal_False;
}
-// #97016# II
void FuPoor::SelectionHasChanged()
{
const SdrHdlList& rHdlList = mpView->GetHdlList();
@@ -1065,7 +1042,7 @@ IMPL_LINK_INLINE_START( FuPoor, DelayHdl, Timer *, EMPTYARG )
Point aPnt(mpWindow->GetPointerPosPixel());
- // #95491# use remembered MouseButton state to create correct
+ // use remembered MouseButton state to create correct
// MouseEvents for this artifical MouseMove.
MouseMove(MouseEvent(aPnt, 1, 0, GetMouseButtonCode()));
@@ -1081,7 +1058,7 @@ IMPL_LINK_INLINE_END( FuPoor, DelayHdl, Timer *, pTimer )
sal_Bool FuPoor::MouseButtonUp (const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
aDelayToScrollTimer.Stop ();
@@ -1091,7 +1068,7 @@ sal_Bool FuPoor::MouseButtonUp (const MouseEvent& rMEvt)
sal_Bool FuPoor::MouseButtonDown(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
return sal_False;
@@ -1162,12 +1139,6 @@ void FuPoor::ReceiveRequest(SfxRequest& rReq)
}
}
-/*************************************************************************
-|*
-|* #97016#
-|*
-\************************************************************************/
-
SdrObject* FuPoor::CreateDefaultObject(const sal_uInt16, const Rectangle& )
{
// empty base implementation
@@ -1275,3 +1246,5 @@ void FuPoor::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuprlout.cxx b/sd/source/ui/func/fuprlout.cxx
index a9dc02168..faeaf795f 100755..100644
--- a/sd/source/ui/func/fuprlout.cxx
+++ b/sd/source/ui/func/fuprlout.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,9 +46,7 @@
#include "sdpage.hxx"
#include "pres.hxx"
#include "DrawViewShell.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "stlpool.hxx"
#include "View.hxx"
#include "glob.hrc"
@@ -285,3 +284,5 @@ void FuPresentationLayout::DoExecute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuprobjs.cxx b/sd/source/ui/func/fuprobjs.cxx
index fa9d5bb61..b7bf5637f 100755..100644
--- a/sd/source/ui/func/fuprobjs.cxx
+++ b/sd/source/ui/func/fuprobjs.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "fuprobjs.hxx"
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svl/style.hxx>
#include <editeng/outliner.hxx>
#include <svl/smplhint.hxx>
@@ -46,9 +45,7 @@
#include "sdresid.hxx"
#include "drawdoc.hxx"
-#ifndef SD_OUTLINE_VIEW_SHELL_HX
#include "OutlineViewShell.hxx"
-#endif
#include "ViewShell.hxx"
#include "Window.hxx"
#include "glob.hxx"
@@ -102,13 +99,20 @@ void FuPresentationObjects::DoExecute( SfxRequest& )
OutlineView* pOlView = static_cast<OutlineView*>(pOutlineViewShell->GetView());
OutlinerView* pOutlinerView = pOlView->GetViewByWindow( (Window*) mpWindow );
::Outliner* pOutl = pOutlinerView->GetOutliner();
- List* pList = pOutlinerView->CreateSelectionList();
- Paragraph* pPara = (Paragraph*)pList->First();
+
+ std::vector<Paragraph*> aSelList;
+ pOutlinerView->CreateSelectionList(aSelList);
+
+ std::vector<Paragraph*>::const_iterator iter = aSelList.begin();
+ Paragraph* pPara = aSelList.empty() ? NULL : *iter;
+
nDepth = pOutl->GetDepth((sal_uInt16)pOutl->GetAbsPos( pPara ) );
bool bPage = pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE );
- while( pPara )
+ while( iter != aSelList.end() )
{
+ pPara = *iter;
+
nTmp = pOutl->GetDepth((sal_uInt16) pOutl->GetAbsPos( pPara ) );
if( nDepth != nTmp )
@@ -123,8 +127,7 @@ void FuPresentationObjects::DoExecute( SfxRequest& )
break;
}
bUnique = sal_True;
-
- pPara = (Paragraph*) pList->Next();
+ ++iter;
}
if( bUnique )
@@ -177,3 +180,5 @@ void FuPresentationObjects::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuscale.cxx b/sd/source/ui/func/fuscale.cxx
index 600904cc3..c13bcaa6f 100755..100644
--- a/sd/source/ui/func/fuscale.cxx
+++ b/sd/source/ui/func/fuscale.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,9 +36,7 @@
#include "app.hrc"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "OutlineViewShell.hxx"
#include "drawview.hxx"
#include "drawdoc.hxx"
@@ -45,9 +44,7 @@
#include "ViewShell.hxx"
#include "fuzoom.hxx" // wegen SidArrayZoom[]
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svx/svdpagv.hxx>
#include <sfx2/viewfrm.hxx>
#include <sfx2/dispatch.hxx>
@@ -214,3 +211,5 @@ void FuScale::DoExecute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fusearch.cxx b/sd/source/ui/func/fusearch.cxx
index 9eadd6eaf..76c917856 100755..100644
--- a/sd/source/ui/func/fusearch.cxx
+++ b/sd/source/ui/func/fusearch.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,9 +39,7 @@
#include <svx/srchdlg.hxx>
#include <sfx2/bindings.hxx>
#include "fupoor.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "app.hrc"
#include "app.hxx"
@@ -176,3 +175,5 @@ void FuSearch::SearchAndReplace( const SvxSearchItem* pSearchItem )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fusel.cxx b/sd/source/ui/func/fusel.cxx
index 3b5304ab3..9e20f9712 100755..100644
--- a/sd/source/ui/func/fusel.cxx
+++ b/sd/source/ui/func/fusel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,6 @@
#include "fusel.hxx"
-#include <vos/process.hxx>
#include <basic/sbstar.hxx>
#include <svx/svdpagv.hxx>
#include <svx/svdogrp.hxx>
@@ -67,13 +67,9 @@
#include "fudraw.hxx"
#include "ViewShell.hxx"
#include "ViewShellBase.hxx"
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "sdpage.hxx"
#include "DrawViewShell.hxx"
@@ -84,7 +80,6 @@
#include "slideshow.hxx"
-// #108981#
#include <svx/svdundo.hxx>
#include <avmedia/mediawindow.hxx>
@@ -525,7 +520,7 @@ sal_Bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
}
else
{
- // #90239# point IS marked and NO shift is pressed. Start
+ // point IS marked and NO shift is pressed. Start
// dragging of selected point(s)
pHdl = mpView->PickHandle(aMDPos);
if(pHdl)
@@ -805,7 +800,6 @@ sal_Bool FuSelection::MouseButtonUp(const MouseEvent& rMEvt)
pPool->GetActualStyleSheet());
if (pStyleSheet != NULL && mpView->IsUndoEnabled() )
{
- // #108981#
// Added UNDOs for the WaterCan mode. This was never done in
// the past, thus it was missing all the time.
SdrUndoAction* pUndoAttr = mpDoc->GetSdrUndoFactory().CreateUndoAttrObject(*pWaterCanCandidate, sal_True, sal_True);
@@ -815,7 +809,6 @@ sal_Bool FuSelection::MouseButtonUp(const MouseEvent& rMEvt)
pWaterCanCandidate->SetStyleSheet (pStyleSheet, sal_False);
- // #108981#
mpView->EndUndo();
}
}
@@ -987,7 +980,7 @@ void FuSelection::Activate()
{
case SID_OBJECT_ROTATE:
{
- // (gemapter) Slot wird explizit auf Rotate gesetzt #31052#
+ // (gemapter) Slot wird explizit auf Rotate gesetzt
if( mpViewShell->ISA(DrawViewShell) )
{
sal_uInt16* pSlotArray =
@@ -1504,3 +1497,5 @@ SdrObject* FuSelection::pickObject (const Point& rTestPoint)
return pObject;
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fusldlg.cxx b/sd/source/ui/func/fusldlg.cxx
index b818688db..409e99adc 100755..100644
--- a/sd/source/ui/func/fusldlg.cxx
+++ b/sd/source/ui/func/fusldlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "fusldlg.hxx"
#include <svl/itemset.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include "drawdoc.hxx"
#include "sdpage.hxx"
@@ -111,14 +110,6 @@ void FuSlideShowDlg::DoExecute( SfxRequest& )
List* pCustomShowList = mpDoc->GetCustomShowList(); // No Create
sal_Bool bStartWithActualPage = SD_MOD()->GetSdOptions( mpDoc->GetDocumentType() )->IsStartWithActualPage();
-/* #109180# change in behaviour, even when always start with current page is enabled, range settings are
- still used
- if( bStartWithActualPage )
- {
- aFirstPage = pViewSh->GetActualPage()->GetName();
- pCustomShowList = NULL;
- }
-*/
if( !aFirstPage.Len() && pPage )
aFirstPage = pPage->GetName();
@@ -263,3 +254,5 @@ void FuSlideShowDlg::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fusnapln.cxx b/sd/source/ui/func/fusnapln.cxx
index 45b505f36..bb4938a8a 100755..100644
--- a/sd/source/ui/func/fusnapln.cxx
+++ b/sd/source/ui/func/fusnapln.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,9 +41,7 @@
#include "View.hxx"
#include "ViewShell.hxx"
#include "DrawViewShell.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "sdenumdef.hxx"
#include "sdresid.hxx"
#include "sdabstdlg.hxx"
@@ -75,7 +74,6 @@ FunctionReference FuSnapLine::Create( ViewShell* pViewSh, ::sd::Window* pWin, ::
void FuSnapLine::DoExecute( SfxRequest& rReq )
{
const SfxItemSet* pArgs = rReq.GetArgs();
- SdrPageView* pPV = 0;
sal_uInt16 nHelpLine = 0;
sal_Bool bCreateNew = sal_True;
@@ -88,11 +86,12 @@ void FuSnapLine::DoExecute( SfxRequest& rReq )
pArgs = NULL;
}
- if ( !pArgs )
+ SdrPageView* pPV = mpView->GetSdrPageView();
+
+ if (!pArgs)
{
SfxItemSet aNewAttr(mpViewShell->GetPool(), ATTR_SNAPLINE_START, ATTR_SNAPLINE_END);
bool bLineExist (false);
- pPV = mpView->GetSdrPageView();
Point aLinePos;
if (pHelpLineIndex == NULL)
@@ -131,53 +130,54 @@ void FuSnapLine::DoExecute( SfxRequest& rReq )
SdAbstractDialogFactory* pFact = SdAbstractDialogFactory::Create();
AbstractSdSnapLineDlg* pDlg = pFact ? pFact->CreateSdSnapLineDlg( NULL, aNewAttr, mpView ) : 0;
- if( pDlg )
+ OSL_ASSERT(pDlg);
+ if (!pDlg)
+ return;
+
+ if ( bLineExist )
{
- if ( bLineExist )
- {
- pDlg->HideRadioGroup();
+ pDlg->HideRadioGroup();
- const SdrHelpLine& rHelpLine = (pPV->GetHelpLines())[nHelpLine];
+ const SdrHelpLine& rHelpLine = (pPV->GetHelpLines())[nHelpLine];
- if ( rHelpLine.GetKind() == SDRHELPLINE_POINT )
- {
- pDlg->SetText(String(SdResId(STR_SNAPDLG_SETPOINT)));
- pDlg->SetInputFields(sal_True, sal_True);
- }
- else
- {
- pDlg->SetText(String(SdResId(STR_SNAPDLG_SETLINE)));
-
- if ( rHelpLine.GetKind() == SDRHELPLINE_VERTICAL )
- pDlg->SetInputFields(sal_True, sal_False);
- else
- pDlg->SetInputFields(sal_False, sal_True);
- }
- bCreateNew = sal_False;
+ if ( rHelpLine.GetKind() == SDRHELPLINE_POINT )
+ {
+ pDlg->SetText(String(SdResId(STR_SNAPDLG_SETPOINT)));
+ pDlg->SetInputFields(sal_True, sal_True);
}
else
- pDlg->HideDeleteBtn();
+ {
+ pDlg->SetText(String(SdResId(STR_SNAPDLG_SETLINE)));
+
+ if ( rHelpLine.GetKind() == SDRHELPLINE_VERTICAL )
+ pDlg->SetInputFields(sal_True, sal_False);
+ else
+ pDlg->SetInputFields(sal_False, sal_True);
+ }
+ bCreateNew = sal_False;
+ }
+ else
+ pDlg->HideDeleteBtn();
- sal_uInt16 nResult = pDlg->Execute();
+ sal_uInt16 nResult = pDlg->Execute();
- pDlg->GetAttr(aNewAttr);
- delete pDlg;
+ pDlg->GetAttr(aNewAttr);
+ delete pDlg;
- switch( nResult )
- {
- case RET_OK:
- rReq.Done(aNewAttr);
- pArgs = rReq.GetArgs();
- break;
-
- case RET_SNAP_DELETE:
- // Fangobjekt loeschen
- if ( !bCreateNew )
- pPV->DeleteHelpLine(nHelpLine);
- // und weiter wie bei default
- default:
- return;
- }
+ switch( nResult )
+ {
+ case RET_OK:
+ rReq.Done(aNewAttr);
+ pArgs = rReq.GetArgs();
+ break;
+
+ case RET_SNAP_DELETE:
+ // Fangobjekt loeschen
+ if ( !bCreateNew )
+ pPV->DeleteHelpLine(nHelpLine);
+ /*fall-through*/
+ default:
+ return;
}
}
Point aHlpPos;
@@ -217,3 +217,5 @@ void FuSnapLine::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fusumry.cxx b/sd/source/ui/func/fusumry.cxx
index 21785162c..6596f67e0 100755..100644
--- a/sd/source/ui/func/fusumry.cxx
+++ b/sd/source/ui/func/fusumry.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -241,3 +242,5 @@ void FuSummaryPage::DoExecute( SfxRequest& )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/futempl.cxx b/sd/source/ui/func/futempl.cxx
index 6c9f7510b..40f5d3c5b 100755..100644
--- a/sd/source/ui/func/futempl.cxx
+++ b/sd/source/ui/func/futempl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,9 +61,7 @@
#include "stlpool.hxx"
#include "app.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawview.hxx"
#include "drawdoc.hxx"
#include "DrawDocShell.hxx"
@@ -163,7 +162,7 @@ void FuTemplate::DoExecute( SfxRequest& rReq )
Reference< XPropertySet > xInfo( xStyles->getByName( pNameItem->GetValue() ), UNO_QUERY_THROW );
OUString aUIName;
- xInfo->getPropertyValue( ::rtl::OUString::createFromAscii("DisplayName") ) >>= aUIName;
+ xInfo->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayName")) ) >>= aUIName;
if ( aUIName.getLength() )
rReq.AppendItem( SfxStringItem( nSId, aUIName ) );
}
@@ -264,9 +263,6 @@ void FuTemplate::DoExecute( SfxRequest& rReq )
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SID_STYLE_FAMILY2 );
}
}
-/* #96983# GrabFocus moved to stylist
- pWin->GrabFocus();
-*/
break;
case SID_STYLE_WATERCAN:
@@ -385,7 +381,7 @@ void FuTemplate::DoExecute( SfxRequest& rReq )
}
else
{
- DBG_ERROR("Vorlage aus aelterer anderssprachiger Version");
+ OSL_FAIL("Vorlage aus aelterer anderssprachiger Version");
bOldDocInOtherLanguage = sal_True;
}
@@ -477,45 +473,6 @@ void FuTemplate::DoExecute( SfxRequest& rReq )
SfxItemSet& rAttr = pStyleSheet->GetItemSet();
-/* #i35937#
- if ( rAttr.GetItemState( EE_PARA_LRSPACE ) == SFX_ITEM_ON )
- {
- // SvxLRSpaceItem hart gesetzt: NumBulletItem anpassen
- if ( aOriSet.GetItemState( EE_PARA_LRSPACE ) != SFX_ITEM_ON ||
- (const SvxLRSpaceItem&) aOriSet.Get( EE_PARA_LRSPACE ) !=
- (const SvxLRSpaceItem&) rAttr.Get( EE_PARA_LRSPACE ) )
- {
- SvxNumBulletItem aNumBullet( (const SvxNumBulletItem&) rAttr.Get(EE_PARA_NUMBULLET) );
-
- sal_uInt16 nLevel = 0;
- if( (ePO >= PO_OUTLINE_2) && (ePO <= PO_OUTLINE_9) )
- nLevel = (sal_uInt16)(ePO - PO_OUTLINE_1 + 1);
-
- EditEngine::ImportBulletItem( aNumBullet, nLevel, NULL,
- &(const SvxLRSpaceItem&) rAttr.Get( EE_PARA_LRSPACE ) );
-
- // the numbering bullet item is not valid in styles Outline 2 to Outline 9
- if( nLevel != 0 )
- {
- // so put it into Outline 1 then..
- String sStyleName((SdResId(STR_PSEUDOSHEET_OUTLINE)));
- sStyleName.AppendAscii( RTL_CONSTASCII_STRINGPARAM( " 1" ) );
- SfxStyleSheetBase* pFirstStyleSheet = pSSPool->Find( sStyleName, SD_STYLE_FAMILY_PSEUDO);
-
- if(pFirstStyleSheet)
- {
- pFirstStyleSheet->GetItemSet().Put( aNumBullet);
- SdStyleSheet* pRealSheet = ((SdStyleSheet*)pFirstStyleSheet)->GetRealStyleSheet();
- pRealSheet->Broadcast(SfxSimpleHint(SFX_HINT_DATACHANGED));
- }
- }
- else
- {
- ( (SfxItemSet&) rAttr).Put( aNumBullet );
- }
- }
- }
-*/
// check for unique names of named items for xml
if( rAttr.GetItemState( XATTR_FILLBITMAP ) == SFX_ITEM_SET )
{
@@ -731,3 +688,5 @@ void FuTemplate::Deactivate()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
index 1539e3052..281645d36 100755..100644
--- a/sd/source/ui/func/futext.cxx
+++ b/sd/source/ui/func/futext.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,7 +57,6 @@
#include <editeng/outlobj.hxx>
#include <svtools/langtab.hxx>
-// #104122#
#include <editeng/frmdiritem.hxx>
#include <svx/svdetc.hxx>
@@ -239,7 +239,7 @@ void FuText::DoExecute( SfxRequest& )
if (pArgs
- // #98198# test for type before using
+ // test for type before using
&& SID_TEXTEDIT == nSlotId
&& SFX_ITEM_SET == pArgs->GetItemState(SID_TEXTEDIT)
@@ -264,15 +264,6 @@ sal_Bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
sal_Bool bReturn = FuDraw::MouseButtonDown(rMEvt);
- /* af: (de)Select object before showing the context menu.
- // Fuer PopupMenu (vorher DrawViewShell)
- if ((rMEvt.GetButtons() == MOUSE_RIGHT) && rMEvt.GetClicks() == 1 &&
- mpView->IsTextEdit())
- {
- return (sal_True);
- }
- */
-
mpView->SetMarkHdlWhenTextEdit(sal_True);
SdrViewEvent aVEvt;
SdrHitKind eHit = mpView->PickAnything(rMEvt, SDRMOUSEBUTTONDOWN, aVEvt);
@@ -406,10 +397,6 @@ sal_Bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
// this caused SdrEndTextEdit() to be called also when not in text editing and
// this does not make sense and caused troubles. (see issue 112855)
-// ::Outliner* pOutl = mpView->GetTextEditOutliner();
-//
-// if (mxTextObj.is() && (mxTextObj->GetOutlinerParaObject() ||
-// (pOutl && pOutl->GetText(pOutl->GetParagraph( 0 )).Len() != 0)))
if( mpView->IsTextEdit() )
{
mpView->SdrEndTextEdit();
@@ -433,7 +420,7 @@ sal_Bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
mpView->MarkObj(aVEvt.pRootObj, pPV);
}
- // Objekt draggen
+ // Drag object
bFirstMouseMove = sal_True;
aDragTimer.Start();
}
@@ -530,7 +517,6 @@ sal_Bool FuText::MouseMove(const MouseEvent& rMEvt)
|*
\************************************************************************/
-// #97016#
void FuText::ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj)
{
if(mpDoc->GetDocumentType() == DOCUMENT_TYPE_IMPRESS)
@@ -556,7 +542,7 @@ void FuText::ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj)
aSet.Put(SdrTextAutoGrowWidthItem(sal_True));
aSet.Put(SdrTextAutoGrowHeightItem(sal_False));
- // #91853# Needs to be set since default is SDRTEXTHORZADJUST_BLOCK
+ // Needs to be set since default is SDRTEXTHORZADJUST_BLOCK
aSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT));
pTxtObj->SetMergedItemSet(aSet);
pTxtObj->AdjustTextFrameWidthAndHeight();
@@ -571,19 +557,13 @@ void FuText::ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj)
// draw text object, needs to be initialized when vertical text is used
SfxItemSet aSet(mpViewShell->GetPool());
- // #91510#
aSet.Put(SdrTextAutoGrowWidthItem(sal_True));
aSet.Put(SdrTextAutoGrowHeightItem(sal_False));
- // #91508#
- //aSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_TOP));
- //aSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT));
-
- // #107235#
// Set defaults for vertical klick-n'drag text object, pool defaults are:
// SdrTextVertAdjustItem: SDRTEXTVERTADJUST_TOP
// SdrTextHorzAdjustItem: SDRTEXTHORZADJUST_BLOCK
- // Analog to that (thus, #91508# was not completely correct):
+ // Analog to that:
aSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_BLOCK));
aSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT));
@@ -592,7 +572,6 @@ void FuText::ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj)
}
}
-// #97016#
void FuText::ImpSetAttributesFitToSize(SdrTextObj* pTxtObj)
{
// FitToSize (An Rahmen anpassen)
@@ -605,7 +584,6 @@ void FuText::ImpSetAttributesFitToSize(SdrTextObj* pTxtObj)
pTxtObj->AdjustTextFrameWidthAndHeight();
}
-// #97016#
void FuText::ImpSetAttributesFitToSizeVertical(SdrTextObj* pTxtObj)
{
SfxItemSet aSet(mpViewShell->GetPool(),
@@ -618,15 +596,14 @@ void FuText::ImpSetAttributesFitToSizeVertical(SdrTextObj* pTxtObj)
pTxtObj->AdjustTextFrameWidthAndHeight();
}
-// #97016#
void FuText::ImpSetAttributesFitCommon(SdrTextObj* pTxtObj)
{
- // Normales Textobjekt
+ // Normal Textobject
if (mpDoc->GetDocumentType() == DOCUMENT_TYPE_IMPRESS)
{
if( nSlotId == SID_ATTR_CHAR )
{
- // Impress-Textobjekt (faellt auf Zeilenhoehe zusammen)
+ // Impress-Textobject (faellt auf Zeilenhoehe zusammen)
SfxItemSet aSet(mpViewShell->GetPool());
aSet.Put(SdrTextMinFrameHeightItem(0));
aSet.Put(SdrTextMaxFrameHeightItem(0));
@@ -733,7 +710,6 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
|| nSlotId == SID_TEXT_FITTOSIZE_VERTICAL);
rOutl.SetVertical(bVertical);
- // #107235#
// Before ImpSetAttributesForNewTextObject the vertical writing mode
// needs to be set at the object. This is done here at the OutlinerParaObject
// directly to not mirror the layout text items involved. These items will be set
@@ -752,7 +728,6 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
pPara->SetVertical(bVertical);
}
- // #97016#
ImpSetAttributesForNewTextObject(GetTextObj());
}
@@ -763,21 +738,18 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
}
else if (nSlotId == SID_TEXT_FITTOSIZE)
{
- // #97016#
ImpSetAttributesFitToSize(GetTextObj());
SetInEditMode(rMEvt, sal_False);
}
else if ( nSlotId == SID_TEXT_FITTOSIZE_VERTICAL )
{
- // #97016#
ImpSetAttributesFitToSizeVertical(GetTextObj());
SetInEditMode(rMEvt, sal_False);
}
else
{
- // #97016#
ImpSetAttributesFitCommon(GetTextObj());
// Damit die Handles und der graue Rahmen stimmen
@@ -853,11 +825,8 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
aSet.Put(SdrTextAutoGrowHeightItem(sal_True));
aSet.Put(SdrTextAutoGrowWidthItem(sal_True));
- // #91508#
if(nSlotId == SID_ATTR_CHAR_VERTICAL)
{
- // #107235#
- //
// Here, all items which need to be different from pool default need to be set
// again on the newly created text object.
// Since this is a simple klick text object, it is first created, then SetVertical()
@@ -883,15 +852,11 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
pPara->SetVertical(sal_True);
}
- // #91508#
- // aSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_TOP));
aSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT));
- // #107235#
// Analog to the else case below, for vertical simple click texts
// one of the defaulted setted items from ImpSetAttributesForNewTextObject
- // needs to be adapted to non-block mode. This could have been done with the
- // #104122#, but was obviously overseen.
+ // needs to be adapted to non-block mode.
const SfxItemSet& rSet = mpView->GetDefaultAttr();
SvxFrameDirection eDirection = (SvxFrameDirection)((SvxFrameDirectionItem&)rSet.Get(EE_PARA_WRITINGDIR)).GetValue();
@@ -906,14 +871,11 @@ sal_Bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
}
else
{
- // #104122# This is for Format/Page settings. Since this also leads
+ // This is for Format/Page settings. Since this also leads
// to the object defaults to be changed, i think this code can be
// removed. CL. wanted to take a look before adding this.
- //const SdrTextHorzAdjust eHA = ( ( pDoc && pDoc->GetDefaultWritingMode() == ::com::sun::star::text::WritingMode_RL_TB ) ?
- // SDRTEXTHORZADJUST_RIGHT : SDRTEXTHORZADJUST_LEFT );
- //aSet.Put( SdrTextHorzAdjustItem( eHA ) );
- // #104122# Look in the object defaults if left-to-right is wanted. If
+ // Look in the object defaults if left-to-right is wanted. If
// yes, set text anchoring to right to let the box grow to left.
const SfxItemSet& rSet = mpView->GetDefaultAttr();
SvxFrameDirection eDirection = (SvxFrameDirection)((SvxFrameDirectionItem&)rSet.Get(EE_PARA_WRITINGDIR)).GetValue();
@@ -970,7 +932,6 @@ sal_Bool FuText::KeyInput(const KeyEvent& rKEvt)
KeyCode nCode = rKEvt.GetKeyCode();
sal_Bool bShift = nCode.IsShift();
- // #97016# IV
if(mxTextObj.is())
{
// maybe object is deleted, test if it's equal to the selected object
@@ -1016,8 +977,6 @@ sal_Bool FuText::KeyInput(const KeyEvent& rKEvt)
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SidArray );
-// if ( pTextObj )
-// pTextObj->SetEmptyPresObj(sal_False);
}
else if (aKeyCode == KEY_ESCAPE)
{
@@ -1185,7 +1144,7 @@ void FuText::SetInEditMode(const MouseEvent& rMEvt, sal_Bool bQuickDrag)
}
else
{
- // #98198# Move cursor to end of text
+ // Move cursor to end of text
ESelection aNewSelection(EE_PARA_NOT_FOUND, EE_INDEX_NOT_FOUND, EE_PARA_NOT_FOUND, EE_INDEX_NOT_FOUND);
pOLV->SetSelection(aNewSelection);
}
@@ -1328,7 +1287,7 @@ void FuText::ReceiveRequest(SfxRequest& rReq)
// Dann Basisklasse rufen (dort wird u.a. nSlotId NICHT gesetzt)
FuPoor::ReceiveRequest(rReq);
- if (nSlotId == SID_TEXTEDIT || mpViewShell->GetFrameView()->IsQuickEdit() || /*#95971#*/ SID_ATTR_CHAR == nSlotId)
+ if (nSlotId == SID_TEXTEDIT || mpViewShell->GetFrameView()->IsQuickEdit() || SID_ATTR_CHAR == nSlotId)
{
MouseEvent aMEvt(mpWindow->GetPointerPosPixel());
@@ -1342,7 +1301,7 @@ void FuText::ReceiveRequest(SfxRequest& rReq)
if (!mxTextObj.is())
{
- // Versuchen, ein Obj zu selektieren
+ // Try to select an object
SdrPageView* pPV = mpView->GetSdrPageView();
SdrViewEvent aVEvt;
mpView->PickAnything(aMEvt, SDRMOUSEBUTTONDOWN, aVEvt);
@@ -1375,7 +1334,7 @@ void FuText::ReceiveRequest(SfxRequest& rReq)
if (pArgs
- // #98198# test for type before using
+ // test for type before using
&& SID_TEXTEDIT == nSlotId
&& SFX_ITEM_SET == pArgs->GetItemState(SID_TEXTEDIT)
@@ -1406,27 +1365,16 @@ IMPL_LINK( FuText, SpellError, void *, nLang )
}
-/*************************************************************************
-|*
-|* Reaktion auf Doppelklick
-|*
-\************************************************************************/
void FuText::DoubleClick(const MouseEvent& )
{
- // Nichts zu tun
+ // Nothing to do
}
-/** #97016#
- #105815# Removed the insertion of default text and putting a new text
+/** Removed the insertion of default text and putting a new text
object directly into edit mode.
*/
SdrObject* FuText::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle)
{
- // case SID_TEXTEDIT: // BASIC ???
- // case SID_ATTR_CHAR:
- // case SID_ATTR_CHAR_VERTICAL:
- // case SID_TEXT_FITTOSIZE:
- // case SID_TEXT_FITTOSIZE_VERTICAL:
SdrObject* pObj = SdrObjFactory::MakeNewObject(
mpView->GetCurrentObjInventor(), mpView->GetCurrentObjIdentifier(),
@@ -1442,22 +1390,18 @@ SdrObject* FuText::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rR
sal_Bool bVertical = (SID_ATTR_CHAR_VERTICAL == nID || SID_TEXT_FITTOSIZE_VERTICAL == nID);
pText->SetVerticalWriting(bVertical);
- // #97016#
ImpSetAttributesForNewTextObject(pText);
if (nSlotId == SID_TEXT_FITTOSIZE)
{
- // #97016#
ImpSetAttributesFitToSize(pText);
}
else if ( nSlotId == SID_TEXT_FITTOSIZE_VERTICAL )
{
- // #97016#
ImpSetAttributesFitToSizeVertical(pText);
}
else
{
- // #97016#
ImpSetAttributesFitCommon(pText);
}
@@ -1467,7 +1411,7 @@ SdrObject* FuText::CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rR
}
else
{
- DBG_ERROR("Object is NO text object");
+ OSL_FAIL("Object is NO text object");
}
}
@@ -1511,7 +1455,6 @@ void FuText::ChangeFontSize( bool bGrow, OutlinerView* pOLV, const FontList* pFo
}
else
{
-// SdDrawDocument* pDoc = pView->GetDoc();
const SdrMarkList& rMarkList = pView->GetMarkedObjectList();
for( sal_uInt32 nMark = 0; nMark < rMarkList.GetMarkCount(); nMark++ )
@@ -1559,3 +1502,4 @@ void FuText::ChangeFontSize( bool bGrow, OutlinerView* pOLV, const FontList* pFo
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/futhes.cxx b/sd/source/ui/func/futhes.cxx
index b06ed4e28..183c80f21 100644
--- a/sd/source/ui/func/futhes.cxx
+++ b/sd/source/ui/func/futhes.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -31,7 +32,6 @@
#include "futhes.hxx"
-#include <tools/pstm.hxx>
#include <editeng/outliner.hxx>
#include <vcl/msgbox.hxx>
#include <svx/svdobj.hxx>
@@ -51,9 +51,7 @@
#include "Outliner.hxx"
#include "DrawViewShell.hxx"
#include "OutlineViewShell.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "sdresid.hxx"
using ::rtl::OUString;
@@ -168,3 +166,5 @@ void FuThesaurus::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/futransf.cxx b/sd/source/ui/func/futransf.cxx
index bf1babeca..cee01fcfb 100755..100644
--- a/sd/source/ui/func/futransf.cxx
+++ b/sd/source/ui/func/futransf.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -137,3 +138,5 @@ void FuTransform::DoExecute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/futxtatt.cxx b/sd/source/ui/func/futxtatt.cxx
index a11fdfd93..c0e954ca7 100755..100644
--- a/sd/source/ui/func/futxtatt.cxx
+++ b/sd/source/ui/func/futxtatt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -103,3 +104,5 @@ void FuTextAttrDlg::DoExecute( SfxRequest& rReq )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuvect.cxx b/sd/source/ui/func/fuvect.cxx
index 09ff7dbd4..c04a5a4d7 100644
--- a/sd/source/ui/func/fuvect.cxx
+++ b/sd/source/ui/func/fuvect.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -31,16 +32,10 @@
#include "fuvect.hxx"
#include <tools/poly.hxx>
-#ifndef _SVDOPATH_HXX //autogen
#include <svx/svdograf.hxx>
-#endif
#include <vcl/msgbox.hxx>
-#ifndef _SVX_SVDOGRAF_HXX //autogen
#include <svx/svdograf.hxx>
-#endif
-#ifndef _SVX_SVDEDTV_HXX //autogen
#include <svx/svdedtv.hxx>
-#endif
#include "View.hxx"
@@ -62,10 +57,10 @@ TYPEINIT1( FuVectorize, FuPoor );
\************************************************************************/
FuVectorize::FuVectorize (
- ViewShell* pViewSh,
- ::sd::Window* pWin,
+ ViewShell* pViewSh,
+ ::sd::Window* pWin,
::sd::View* pView,
- SdDrawDocument* pDoc,
+ SdDrawDocument* pDoc,
SfxRequest& rReq)
: FuPoor (pViewSh, pWin, pView, pDoc, rReq)
{
@@ -95,7 +90,7 @@ void FuVectorize::DoExecute( SfxRequest& )
const GDIMetaFile& rMtf = pDlg->GetGDIMetaFile();
SdrPageView* pPageView = mpView->GetSdrPageView();
- if( pPageView && rMtf.GetActionCount() )
+ if( pPageView && rMtf.GetActionSize() )
{
SdrGrafObj* pVectObj = (SdrGrafObj*) pObj->Clone();
String aStr( mpView->GetDescriptionOfMarkedObjects() );
@@ -114,3 +109,5 @@ void FuVectorize::DoExecute( SfxRequest& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/fuzoom.cxx b/sd/source/ui/func/fuzoom.cxx
index 3d3a9ef5b..287f1cdbd 100755..100644
--- a/sd/source/ui/func/fuzoom.cxx
+++ b/sd/source/ui/func/fuzoom.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,14 +38,10 @@
#include "app.hrc"
#include <svx/svdpagv.hxx>
-#ifndef SD_FRAMW_VIEW_HXX
#include "FrameView.hxx"
-#endif
#include "ViewShell.hxx"
#include "View.hxx"
-#ifndef SD_WINDOW_SHELL_HXX
#include "Window.hxx"
-#endif
#include "drawdoc.hxx"
#include "zoomlist.hxx"
@@ -108,7 +105,7 @@ FunctionReference FuZoom::Create( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::
sal_Bool FuZoom::MouseButtonDown(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
mpWindow->CaptureMouse();
@@ -183,7 +180,7 @@ sal_Bool FuZoom::MouseMove(const MouseEvent& rMEvt)
sal_Bool FuZoom::MouseButtonUp(const MouseEvent& rMEvt)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
if (bVisible)
@@ -260,3 +257,5 @@ void FuZoom::Deactivate()
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SidArrayZoom );
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/makefile.mk b/sd/source/ui/func/makefile.mk
deleted file mode 100755
index e4df8fe9d..000000000
--- a/sd/source/ui/func/makefile.mk
+++ /dev/null
@@ -1,185 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util\sd
-PRJNAME=sd
-TARGET=func
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE
-
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/fuformatpaintbrush.obj \
- $(SLO)$/fuhhconv.obj \
- $(SLO)$/undoheaderfooter.obj \
- $(SLO)$/undolayer.obj \
- $(SLO)$/fupoor.obj \
- $(SLO)$/fudraw.obj \
- $(SLO)$/fuzoom.obj \
- $(SLO)$/fusel.obj \
- $(SLO)$/fuconstr.obj \
- $(SLO)$/fuconrec.obj \
- $(SLO)$/fuconuno.obj \
- $(SLO)$/fuconbez.obj \
- $(SLO)$/fuediglu.obj \
- $(SLO)$/fusldlg.obj \
- $(SLO)$/fuscale.obj \
- $(SLO)$/futransf.obj \
- $(SLO)$/futext.obj \
- $(SLO)$/fuline.obj \
- $(SLO)$/sdundo.obj \
- $(SLO)$/sdundogr.obj \
- $(SLO)$/fuoaprms.obj \
- $(SLO)$/unoaprms.obj \
- $(SLO)$/fuarea.obj \
- $(SLO)$/fuchar.obj \
- $(SLO)$/fuconarc.obj \
- $(SLO)$/fuparagr.obj \
- $(SLO)$/fubullet.obj \
- $(SLO)$/futempl.obj \
- $(SLO)$/fuoutl.obj \
- $(SLO)$/fuoltext.obj \
- $(SLO)$/fuinsert.obj \
- $(SLO)$/fupage.obj \
- $(SLO)$/undopage.obj \
- $(SLO)$/fuprlout.obj \
- $(SLO)$/fuprobjs.obj \
- $(SLO)$/fulinend.obj \
- $(SLO)$/fusnapln.obj \
- $(SLO)$/fuolbull.obj \
- $(SLO)$/fucopy.obj \
- $(SLO)$/fulink.obj \
- $(SLO)$/futhes.obj \
- $(SLO)$/fusearch.obj \
- $(SLO)$/fuinsfil.obj \
- $(SLO)$/futxtatt.obj \
- $(SLO)$/fumeasur.obj \
- $(SLO)$/fuconnct.obj \
- $(SLO)$/unprlout.obj \
- $(SLO)$/fudspord.obj \
- $(SLO)$/unmovss.obj \
- $(SLO)$/fucon3d.obj \
- $(SLO)$/fumorph.obj \
- $(SLO)$/fuexpand.obj \
- $(SLO)$/fusumry.obj \
- $(SLO)$/fucushow.obj \
- $(SLO)$/fuvect.obj \
- $(SLO)$/bulmaper.obj \
- $(SLO)$/undoback.obj \
- $(SLO)$/fuconcs.obj \
- $(SLO)$/smarttag.obj
-
-.IF "$(GUI)" == "WNT"
-
-NOOPTFILES=\
- $(SLO)$/futext.obj
-
-.ENDIF # wnt
-
-LIB1TARGET= $(SLB)$/$(TARGET).lib
-LIB1OBJFILES= \
- $(SLO)$/fuformatpaintbrush.obj \
- $(SLO)$/fuhhconv.obj \
- $(SLO)$/undoheaderfooter.obj \
- $(SLO)$/undolayer.obj \
- $(SLO)$/fupoor.obj \
- $(SLO)$/fudraw.obj \
- $(SLO)$/fuzoom.obj \
- $(SLO)$/fusel.obj \
- $(SLO)$/fuconstr.obj \
- $(SLO)$/fuconrec.obj \
- $(SLO)$/fuconuno.obj \
- $(SLO)$/fuconbez.obj \
- $(SLO)$/fuediglu.obj \
- $(SLO)$/fusldlg.obj \
- $(SLO)$/fuscale.obj \
- $(SLO)$/futransf.obj \
- $(SLO)$/futext.obj \
- $(SLO)$/fuline.obj \
- $(SLO)$/sdundo.obj \
- $(SLO)$/sdundogr.obj \
- $(SLO)$/fuoaprms.obj \
- $(SLO)$/unoaprms.obj \
- $(SLO)$/fuarea.obj \
- $(SLO)$/fuchar.obj \
- $(SLO)$/fuconarc.obj \
- $(SLO)$/fuparagr.obj \
- $(SLO)$/fubullet.obj \
- $(SLO)$/futempl.obj \
- $(SLO)$/fuoutl.obj \
- $(SLO)$/fuoltext.obj \
- $(SLO)$/smarttag.obj
-
-LIB3TARGET= $(SLB)$/$(TARGET)_2.lib
-LIB3OBJFILES= \
- $(SLO)$/fuinsert.obj \
- $(SLO)$/fupage.obj \
- $(SLO)$/undopage.obj \
- $(SLO)$/fuprlout.obj \
- $(SLO)$/fuprobjs.obj \
- $(SLO)$/fulinend.obj \
- $(SLO)$/fusnapln.obj \
- $(SLO)$/fuolbull.obj \
- $(SLO)$/fucopy.obj \
- $(SLO)$/fulink.obj \
- $(SLO)$/futhes.obj \
- $(SLO)$/fusearch.obj \
- $(SLO)$/fuinsfil.obj \
- $(SLO)$/futxtatt.obj \
- $(SLO)$/fumeasur.obj \
- $(SLO)$/fuconnct.obj \
- $(SLO)$/unprlout.obj \
- $(SLO)$/fudspord.obj \
- $(SLO)$/unmovss.obj \
- $(SLO)$/fucon3d.obj \
- $(SLO)$/fumorph.obj \
- $(SLO)$/fuexpand.obj \
- $(SLO)$/fusumry.obj \
- $(SLO)$/fucushow.obj \
- $(SLO)$/fuvect.obj \
- $(SLO)$/bulmaper.obj \
- $(SLO)$/undoback.obj \
- $(SLO)$/fuconcs.obj
-
-LIB2TARGET= $(SLB)$/$(TARGET)_ui.lib
-LIB2OBJFILES= \
- $(SLO)$/bulmaper.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/ui/func/sdundo.cxx b/sd/source/ui/func/sdundo.cxx
index 657e88c38..70024e69e 100644
--- a/sd/source/ui/func/sdundo.cxx
+++ b/sd/source/ui/func/sdundo.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,3 +35,4 @@
TYPEINIT1(SdUndoAction, SfxUndoAction);
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/sdundogr.cxx b/sd/source/ui/func/sdundogr.cxx
index 37ef93148..07de30593 100755..100644
--- a/sd/source/ui/func/sdundogr.cxx
+++ b/sd/source/ui/func/sdundogr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116,3 +117,5 @@ void SdUndoGroup::AddAction(SdUndoAction* pAction)
{
aCtn.Insert(pAction, CONTAINER_APPEND);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/smarttag.cxx b/sd/source/ui/func/smarttag.cxx
index ae561997d..2baf564a6 100755..100644
--- a/sd/source/ui/func/smarttag.cxx
+++ b/sd/source/ui/func/smarttag.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -477,3 +478,4 @@ SmartProxyHdl::~SmartProxyHdl()
*/
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/undoback.cxx b/sd/source/ui/func/undoback.cxx
index 596550a79..0f8f7b7ad 100644
--- a/sd/source/ui/func/undoback.cxx
+++ b/sd/source/ui/func/undoback.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,7 +72,6 @@ void SdBackgroundObjUndoAction::ImplRestoreBackgroundObj()
delete mpItemSet;
mpItemSet = pNew;
- // #110094#-15
// tell the page that it's visualization has changed
mrPage.ActionChanged();
}
@@ -96,3 +96,5 @@ SdUndoAction* SdBackgroundObjUndoAction::Clone() const
{
return new SdBackgroundObjUndoAction(*mpDoc, mrPage, *mpItemSet);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/undoheaderfooter.cxx b/sd/source/ui/func/undoheaderfooter.cxx
index 2d834891d..f1b200fbf 100644
--- a/sd/source/ui/func/undoheaderfooter.cxx
+++ b/sd/source/ui/func/undoheaderfooter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,4 @@ void SdHeaderFooterUndoAction::Redo()
SfxViewFrame::Current()->GetDispatcher()->Execute( SID_SWITCHPAGE, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/undolayer.cxx b/sd/source/ui/func/undolayer.cxx
index 197ad1ae9..3c021d130 100644
--- a/sd/source/ui/func/undolayer.cxx
+++ b/sd/source/ui/func/undolayer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,5 @@ void SdLayerModifyUndoAction::Redo()
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/undopage.cxx b/sd/source/ui/func/undopage.cxx
index a11ea92f3..36355309d 100644
--- a/sd/source/ui/func/undopage.cxx
+++ b/sd/source/ui/func/undopage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -138,3 +139,4 @@ void SdPageULUndoAction::Redo()
mpPage->SetLwrBorder(mnNewLower);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/unmovss.cxx b/sd/source/ui/func/unmovss.cxx
index 5f16a7260..677ffd071 100644
--- a/sd/source/ui/func/unmovss.cxx
+++ b/sd/source/ui/func/unmovss.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,7 +44,7 @@ SdMoveStyleSheetsUndoAction::SdMoveStyleSheetsUndoAction( SdDrawDocument* pTheDo
maListOfChildLists.resize( maStyles.size() );
// Liste mit den Listen der StyleSheet-Kinder erstellen
std::size_t i = 0;
- for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); iter++ )
+ for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); ++iter )
{
maListOfChildLists[i++] = SdStyleSheetPool::CreateChildList( (*iter).get() );
}
@@ -64,17 +65,17 @@ void SdMoveStyleSheetsUndoAction::Undo()
// the styles have to be inserted in the pool
// first insert all styles to the pool
- for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); iter++ )
+ for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); ++iter )
{
pPool->Insert((*iter).get());
}
// now assign the childs again
std::vector< SdStyleSheetVector >::iterator childlistiter( maListOfChildLists.begin() );
- for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); iter++, childlistiter++ )
+ for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); ++iter, ++childlistiter )
{
String aParent((*iter)->GetName());
- for( SdStyleSheetVector::iterator childiter = (*childlistiter).begin(); childiter != (*childlistiter).end(); childiter++ )
+ for( SdStyleSheetVector::iterator childiter = (*childlistiter).begin(); childiter != (*childlistiter).end(); ++childiter )
{
(*childiter)->SetParent(aParent);
}
@@ -83,7 +84,7 @@ void SdMoveStyleSheetsUndoAction::Undo()
else
{
// remove the styles again from the pool
- for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); iter++ )
+ for(SdStyleSheetVector::iterator iter = maStyles.begin(); iter != maStyles.end(); ++iter )
{
pPool->Remove((*iter).get());
}
@@ -106,3 +107,4 @@ String SdMoveStyleSheetsUndoAction::GetComment() const
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/unoaprms.cxx b/sd/source/ui/func/unoaprms.cxx
index b6a529947..d2a527ab5 100755..100644
--- a/sd/source/ui/func/unoaprms.cxx
+++ b/sd/source/ui/func/unoaprms.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,8 +53,7 @@ void SdAnimationPrmsUndoAction::Undo()
if( pDoc )
{
SdAnimationInfo* pInfo = pDoc->GetAnimationInfo( pObject );
- // So nicht...
- //SdAnimationInfo* pInfo = (SdAnimationInfo*)pObject->GetUserData(0);
+
pInfo->mbActive = bOldActive;
pInfo->meEffect = eOldEffect;
pInfo->meTextEffect = eOldTextEffect;
@@ -64,10 +64,8 @@ void SdAnimationPrmsUndoAction::Undo()
pInfo->mbSoundOn = bOldSoundOn;
pInfo->maSoundFile = aOldSoundFile;
pInfo->mbPlayFull = bOldPlayFull;
-// pInfo->mSetPath(pOldPathObj);
pInfo->meClickAction = eOldClickAction;
pInfo->SetBookmark( aOldBookmark );
-// pInfo->mbInvisibleInPresentation = bOldInvisibleInPres;
pInfo->mnVerb = nOldVerb;
pInfo->mnPresOrder = nOldPresOrder;
@@ -110,10 +108,8 @@ void SdAnimationPrmsUndoAction::Redo()
pInfo->mbSoundOn = bNewSoundOn;
pInfo->maSoundFile = aNewSoundFile;
pInfo->mbPlayFull = bNewPlayFull;
-// pInfo->mSetPath(pNewPathObj);
pInfo->meClickAction = eNewClickAction;
pInfo->SetBookmark( aNewBookmark );
-// pInfo->mbInvisibleInPresentation = bNewInvisibleInPres;
pInfo->mnVerb = nNewVerb;
pInfo->mnPresOrder = nNewPresOrder;
@@ -139,3 +135,4 @@ SdAnimationPrmsUndoAction::~SdAnimationPrmsUndoAction()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/func/unprlout.cxx b/sd/source/ui/func/unprlout.cxx
index f473a3814..9f3e76620 100755..100644
--- a/sd/source/ui/func/unprlout.cxx
+++ b/sd/source/ui/func/unprlout.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117,3 +118,4 @@ String SdPresentationLayoutUndoAction::GetComment() const
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/3dchld.hxx b/sd/source/ui/inc/3dchld.hxx
index 0ec40da70..5752c4ffc 100755..100644
--- a/sd/source/ui/inc/3dchld.hxx
+++ b/sd/source/ui/inc/3dchld.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,4 @@ class Sd3DChildWindow : public SfxChildWindow
#endif // _SD_3DCHLD_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleDocumentViewBase.hxx b/sd/source/ui/inc/AccessibleDocumentViewBase.hxx
index 3403703a1..da8b8d12d 100644
--- a/sd/source/ui/inc/AccessibleDocumentViewBase.hxx
+++ b/sd/source/ui/inc/AccessibleDocumentViewBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -370,3 +371,5 @@ protected:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleDrawDocumentView.hxx b/sd/source/ui/inc/AccessibleDrawDocumentView.hxx
index a47db2a65..c48b6d84a 100644
--- a/sd/source/ui/inc/AccessibleDrawDocumentView.hxx
+++ b/sd/source/ui/inc/AccessibleDrawDocumentView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -171,3 +172,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleOutlineEditSource.hxx b/sd/source/ui/inc/AccessibleOutlineEditSource.hxx
index bb69de017..1bf2c0be5 100755..100644
--- a/sd/source/ui/inc/AccessibleOutlineEditSource.hxx
+++ b/sd/source/ui/inc/AccessibleOutlineEditSource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,5 @@ namespace accessibility
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleOutlineView.hxx b/sd/source/ui/inc/AccessibleOutlineView.hxx
index 727e544ee..f864e68c2 100644
--- a/sd/source/ui/inc/AccessibleOutlineView.hxx
+++ b/sd/source/ui/inc/AccessibleOutlineView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -159,3 +160,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessiblePageShape.hxx b/sd/source/ui/inc/AccessiblePageShape.hxx
index 9430b7980..6071359b1 100644
--- a/sd/source/ui/inc/AccessiblePageShape.hxx
+++ b/sd/source/ui/inc/AccessiblePageShape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -176,3 +177,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessiblePresentationGraphicShape.hxx b/sd/source/ui/inc/AccessiblePresentationGraphicShape.hxx
index 7be7a2351..614370412 100644
--- a/sd/source/ui/inc/AccessiblePresentationGraphicShape.hxx
+++ b/sd/source/ui/inc/AccessiblePresentationGraphicShape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,5 @@ public:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessiblePresentationOLEShape.hxx b/sd/source/ui/inc/AccessiblePresentationOLEShape.hxx
index 4d5850166..3d80656fa 100644
--- a/sd/source/ui/inc/AccessiblePresentationOLEShape.hxx
+++ b/sd/source/ui/inc/AccessiblePresentationOLEShape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,5 @@ public:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessiblePresentationShape.hxx b/sd/source/ui/inc/AccessiblePresentationShape.hxx
index 0e75d8fb8..0e314da32 100644
--- a/sd/source/ui/inc/AccessiblePresentationShape.hxx
+++ b/sd/source/ui/inc/AccessiblePresentationShape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleScrollPanel.hxx b/sd/source/ui/inc/AccessibleScrollPanel.hxx
index ff73f55d1..b88615559 100644
--- a/sd/source/ui/inc/AccessibleScrollPanel.hxx
+++ b/sd/source/ui/inc/AccessibleScrollPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleSlideSorterObject.hxx b/sd/source/ui/inc/AccessibleSlideSorterObject.hxx
index 8e23870ea..4d7876940 100644
--- a/sd/source/ui/inc/AccessibleSlideSorterObject.hxx
+++ b/sd/source/ui/inc/AccessibleSlideSorterObject.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,7 +49,7 @@ class SlideSorter;
namespace accessibility {
-typedef ::cppu::WeakComponentImplHelper5<
+typedef ::cppu::PartialWeakComponentImplHelper5<
::com::sun::star::accessibility::XAccessible,
::com::sun::star::accessibility::XAccessibleEventBroadcaster,
::com::sun::star::accessibility::XAccessibleContext,
@@ -94,7 +95,14 @@ public:
virtual void SAL_CALL disposing (void);
+ //===== XComponent ==============================================
+ virtual void SAL_CALL dispose()throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::dispose(); }
+ virtual void SAL_CALL addEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::addEventListener(xListener); }
+ virtual void SAL_CALL removeEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::removeEventListener(xListener); }
//===== XAccessible =======================================================
@@ -117,9 +125,6 @@ public:
::com::sun::star::accessibility::XAccessibleEventListener >& rxListener )
throw (::com::sun::star::uno::RuntimeException);
- using cppu::WeakComponentImplHelperBase::addEventListener;
- using cppu::WeakComponentImplHelperBase::removeEventListener;
-
//===== XAccessibleContext ==============================================
virtual sal_Int32 SAL_CALL
@@ -247,3 +252,5 @@ private:
} // end of namespace ::accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleSlideSorterView.hxx b/sd/source/ui/inc/AccessibleSlideSorterView.hxx
index 5890e295b..9dcc7cd9c 100644
--- a/sd/source/ui/inc/AccessibleSlideSorterView.hxx
+++ b/sd/source/ui/inc/AccessibleSlideSorterView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,7 @@ namespace accessibility {
class AccessibleSlideSorterObject;
-typedef ::cppu::WeakComponentImplHelper6<
+typedef ::cppu::PartialWeakComponentImplHelper6<
::com::sun::star::accessibility::XAccessible,
::com::sun::star::accessibility::XAccessibleEventBroadcaster,
::com::sun::star::accessibility::XAccessibleContext,
@@ -76,6 +77,8 @@ public:
::sd::slidesorter::SlideSorter& rSlideSorter,
const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible> & rxParent,
::Window* pParentWindow);
+
+ void Init();
virtual ~AccessibleSlideSorterView (void);
@@ -97,6 +100,15 @@ public:
*/
AccessibleSlideSorterObject* GetAccessibleChildImplementation (sal_Int32 nIndex);
+ //===== XComponent ==============================================
+
+ virtual void SAL_CALL dispose()throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::dispose(); }
+ virtual void SAL_CALL addEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::addEventListener(xListener); }
+ virtual void SAL_CALL removeEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::removeEventListener(xListener); }
+
//===== XAccessible =======================================================
virtual ::com::sun::star::uno::Reference<
@@ -118,9 +130,6 @@ public:
::com::sun::star::accessibility::XAccessibleEventListener >& rxListener )
throw (::com::sun::star::uno::RuntimeException);
- using cppu::WeakComponentImplHelperBase::addEventListener;
- using cppu::WeakComponentImplHelperBase::removeEventListener;
-
//===== XAccessibleContext ==============================================
/// Return the number of currently visible children.
@@ -324,3 +333,5 @@ private:
} // end of namespace ::accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleSlideView.hxx b/sd/source/ui/inc/AccessibleSlideView.hxx
deleted file mode 100755
index fa536cc35..000000000
--- a/sd/source/ui/inc/AccessibleSlideView.hxx
+++ /dev/null
@@ -1,280 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_ACCESSIBILITY_ACCESSIBLE_SLIDE_VIEW_HXX
-#define SD_ACCESSIBILITY_ACCESSIBLE_SLIDE_VIEW_HXX
-
-#include <cppuhelper/implbase6.hxx>
-#include <cppuhelper/implbase7.hxx>
-#include "SlideView.hxx"
-#include <com/sun/star/lang/XUnoTunnel.hpp>
-#include <com/sun/star/accessibility/XAccessible.hpp>
-#include <com/sun/star/accessibility/XAccessibleContext.hpp>
-#include <com/sun/star/accessibility/XAccessibleComponent.hpp>
-#include <com/sun/star/accessibility/XAccessibleSelection.hpp>
-#include <com/sun/star/accessibility/XAccessibleEventBroadcaster.hpp>
-#include <com/sun/star/lang/XServiceInfo.hpp>
-
-#include <vector>
-
-class SdDrawDocument;
-class AccessibleSlideView;
-
-namespace sd {
-class SlideView;
-class Window;
-}
-
-// -----------------------------
-// - AccessibleSlideViewObject -
-// -----------------------------
-
-class AccessibleSlideViewObject : public ::cppu::WeakImplHelper6<
- ::com::sun::star::lang::XUnoTunnel,
- ::com::sun::star::accessibility::XAccessible,
- ::com::sun::star::accessibility::XAccessibleEventBroadcaster,
- ::com::sun::star::accessibility::XAccessibleContext,
- ::com::sun::star::accessibility::XAccessibleComponent,
- ::com::sun::star::lang::XServiceInfo >
-{
-private:
-
- ::osl::Mutex maMutex;
- ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > mxParent;
- AccessibleSlideView* mpManager;
- /// client id in the AccessibleEventNotifier queue
- sal_uInt32 mnClientId;
- sal_uInt16 mnPage;
- sal_Bool mbVisible;
- sal_Bool mbValid;
-
-private:
-
- // Misc
- static const ::com::sun::star::uno::Sequence< sal_Int8 >& getUnoTunnelId();
-
- // XUnoTunnel
- virtual sal_Int64 SAL_CALL getSomething( const ::com::sun::star::uno::Sequence< sal_Int8 >& rId ) throw( ::com::sun::star::uno::RuntimeException );
-
- // XAccessible
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext( ) throw (::com::sun::star::uno::RuntimeException);
-
- // XAccessibleEventBroadcaster
- virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-
- // XAccessibleContext
- virtual sal_Int32 SAL_CALL getAccessibleChildCount( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleChild( sal_Int32 i ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleParent( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Int32 SAL_CALL getAccessibleIndexInParent( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Int16 SAL_CALL getAccessibleRole( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getAccessibleDescription( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getAccessibleName( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::lang::Locale SAL_CALL getLocale( ) throw (::com::sun::star::accessibility::IllegalAccessibleComponentStateException, ::com::sun::star::uno::RuntimeException);
-
- // XAccessibleComponent
- virtual sal_Bool SAL_CALL containsPoint( const ::com::sun::star::awt::Point& aPoint ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleAtPoint( const ::com::sun::star::awt::Point& aPoint ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Rectangle SAL_CALL getBounds( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Point SAL_CALL getLocation( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException);
-
- virtual sal_Int32 SAL_CALL getForeground (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- virtual sal_Int32 SAL_CALL getBackground (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- //===== XServiceInfo ====================================================
-
- /** Returns an identifier for the implementation of this object.
- */
- virtual ::rtl::OUString SAL_CALL
- getImplementationName (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- /** Return whether the specified service is supported by this class.
- */
- virtual sal_Bool SAL_CALL
- supportsService (const ::rtl::OUString& sServiceName)
- throw (::com::sun::star::uno::RuntimeException);
-
- /** Returns a list of all supported services.
- */
- virtual ::com::sun::star::uno::Sequence< ::rtl::OUString> SAL_CALL
- getSupportedServiceNames (void)
- throw (::com::sun::star::uno::RuntimeException);
-
-public:
-
- static AccessibleSlideViewObject* getImplementation( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& rxData ) throw();
-
-public:
-
- AccessibleSlideViewObject( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >& rxParent, sal_uInt16 nPage, sal_Bool bVisible );
- ~AccessibleSlideViewObject();
-
- void FireAccessibleEvent( short nEventId, const ::com::sun::star::uno::Any& rOldValue, const ::com::sun::star::uno::Any& rNewValue );
-
- /** This method acts like a dispose call. It sends a disposing to all
- of its listeners. It may be called twice.
- */
- void Destroyed (void);
-
- sal_uInt16 GetPageNum() const { return mnPage; }
-
- void SetVisible( sal_Bool bVisible );
- sal_Bool IsVisible() const;
-};
-
-// -----------------------
-// - AccessibleSlideView -
-// -----------------------
-
-class AccessibleSlideView : public ::cppu::WeakImplHelper7<
- ::com::sun::star::lang::XUnoTunnel,
- ::com::sun::star::accessibility::XAccessible,
- ::com::sun::star::accessibility::XAccessibleEventBroadcaster,
- ::com::sun::star::accessibility::XAccessibleContext,
- ::com::sun::star::accessibility::XAccessibleComponent,
- ::com::sun::star::accessibility::XAccessibleSelection,
- ::com::sun::star::lang::XServiceInfo >
-{
-public:
-
- static AccessibleSlideView* getImplementation( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& rxData ) throw();
-
- AccessibleSlideView(
- SdDrawDocument& rDoc,
- ::sd::SlideView& rView,
- ::sd::Window& rParentWindow);
- virtual ~AccessibleSlideView (void);
-
- void FireAccessibleEvent( short nEventId, const ::com::sun::star::uno::Any& rOldValue, const ::com::sun::star::uno::Any& rNewValue );
-
- /** This method acts like a dispose call. It sends a disposing to all
- of its listeners. It may be called twice.
- */
- void Destroyed (void);
-
- SdDrawDocument* GetDrawDocument() const { return mpDoc; }
- ::sd::SlideView* GetSlideView() const { return mpView; }
- ::sd::Window* GetParentWindow() const { return mpParentWindow; }
-
- void SetPageVisible( sal_uInt16 nPage, sal_Bool bVisible );
- void Reset();
- void FocusHasChanged( sal_uInt16 nOldFocusPage, sal_uInt16 nNewFocusPage );
-
-
-private:
- ::osl::Mutex maMutex;
- ::std::vector< ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > > maSlidePageObjects;
- SdDrawDocument* mpDoc;
- ::sd::SlideView* mpView;
- ::sd::Window* mpParentWindow;
- /// client id in the AccessibleEventNotifier queue
- sal_uInt32 mnClientId;
-
- // internal
- static const ::com::sun::star::uno::Sequence< sal_Int8 >& getUnoTunnelId();
- sal_Int32 ImplGetVisibleChildCount() const;
- ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > ImplGetVisibleChild( sal_Int32 nVisibleChild ) const;
-
- // XUnoTunnel
- virtual sal_Int64 SAL_CALL getSomething( const ::com::sun::star::uno::Sequence< sal_Int8 >& rId ) throw( ::com::sun::star::uno::RuntimeException );
-
- // XAccessible
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext( ) throw (::com::sun::star::uno::RuntimeException);
-
- // XAccessibleEventBroadcaster
- virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-
- // XAccessibleContext
- virtual sal_Int32 SAL_CALL getAccessibleChildCount( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleChild( sal_Int32 i ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleParent( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Int32 SAL_CALL getAccessibleIndexInParent( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Int16 SAL_CALL getAccessibleRole( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getAccessibleDescription( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getAccessibleName( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::lang::Locale SAL_CALL getLocale( ) throw (::com::sun::star::accessibility::IllegalAccessibleComponentStateException, ::com::sun::star::uno::RuntimeException);
-
- // XAccessibleComponent
- virtual sal_Bool SAL_CALL containsPoint( const ::com::sun::star::awt::Point& aPoint ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getAccessibleAtPoint( const ::com::sun::star::awt::Point& aPoint ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Rectangle SAL_CALL getBounds( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Point SAL_CALL getLocation( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException);
-
- virtual sal_Int32 SAL_CALL getForeground (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- virtual sal_Int32 SAL_CALL getBackground (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- // XAccessibleSelection
- virtual void SAL_CALL selectAccessibleChild( sal_Int32 nChildIndex ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
- virtual sal_Bool SAL_CALL isAccessibleChildSelected( sal_Int32 nChildIndex ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL clearAccessibleSelection( ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL selectAllAccessibleChildren( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Int32 SAL_CALL getSelectedAccessibleChildCount( ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > SAL_CALL getSelectedAccessibleChild( sal_Int32 nSelectedChildIndex ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL deselectAccessibleChild( sal_Int32 nSelectedChildIndex ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException);
-
- //===== XServiceInfo ====================================================
-
- /** Returns an identifier for the implementation of this object.
- */
- virtual ::rtl::OUString SAL_CALL
- getImplementationName (void)
- throw (::com::sun::star::uno::RuntimeException);
-
- /** Return whether the specified service is supported by this class.
- */
- virtual sal_Bool SAL_CALL
- supportsService (const ::rtl::OUString& sServiceName)
- throw (::com::sun::star::uno::RuntimeException);
-
- /** Returns a list of all supported services.
- */
- virtual ::com::sun::star::uno::Sequence< ::rtl::OUString> SAL_CALL
- getSupportedServiceNames (void)
- throw (::com::sun::star::uno::RuntimeException);
-
-};
-
-#endif
diff --git a/sd/source/ui/inc/AccessibleTreeNode.hxx b/sd/source/ui/inc/AccessibleTreeNode.hxx
index 4dd621425..70e715719 100755..100644
--- a/sd/source/ui/inc/AccessibleTreeNode.hxx
+++ b/sd/source/ui/inc/AccessibleTreeNode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,7 +62,7 @@ namespace accessibility {
class AccessibleSlideSorterObject;
-typedef ::cppu::WeakComponentImplHelper5<
+typedef ::cppu::PartialWeakComponentImplHelper5<
::com::sun::star::accessibility::XAccessible,
::com::sun::star::accessibility::XAccessibleEventBroadcaster,
::com::sun::star::accessibility::XAccessibleContext,
@@ -103,6 +104,15 @@ public:
virtual void SAL_CALL disposing (void);
+ //===== XComponent =======================================================
+
+ virtual void SAL_CALL dispose()throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::dispose(); }
+ virtual void SAL_CALL addEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::addEventListener(xListener); }
+ virtual void SAL_CALL removeEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
+ { WeakComponentImplHelperBase::removeEventListener(xListener); }
+
//===== XAccessible =======================================================
virtual ::com::sun::star::uno::Reference<
@@ -125,9 +135,6 @@ public:
::com::sun::star::accessibility::XAccessibleEventListener >& rxListener )
throw (::com::sun::star::uno::RuntimeException);
- using cppu::WeakComponentImplHelperBase::addEventListener;
- using cppu::WeakComponentImplHelperBase::removeEventListener;
-
//===== XAccessibleContext ==============================================
/// Return the number of currently visible children.
@@ -292,3 +299,5 @@ private:
} // end of namespace ::accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AccessibleViewForwarder.hxx b/sd/source/ui/inc/AccessibleViewForwarder.hxx
index 4fb9ba623..88ca772f0 100755..100644
--- a/sd/source/ui/inc/AccessibleViewForwarder.hxx
+++ b/sd/source/ui/inc/AccessibleViewForwarder.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,3 +135,5 @@ private:
} // end of namespace accessibility
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/AnimationChildWindow.hxx b/sd/source/ui/inc/AnimationChildWindow.hxx
index a10073969..050c8cb3d 100755..100644
--- a/sd/source/ui/inc/AnimationChildWindow.hxx
+++ b/sd/source/ui/inc/AnimationChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/BezierObjectBar.hxx b/sd/source/ui/inc/BezierObjectBar.hxx
index 3519eaa1c..373c72969 100644
--- a/sd/source/ui/inc/BezierObjectBar.hxx
+++ b/sd/source/ui/inc/BezierObjectBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/BreakDlg.hxx b/sd/source/ui/inc/BreakDlg.hxx
index b98a0e33b..373848bae 100755..100644
--- a/sd/source/ui/inc/BreakDlg.hxx
+++ b/sd/source/ui/inc/BreakDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#define SD_BREAK_DLG_HXX
#include <vcl/group.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <svx/dlgctrl.hxx>
#include <vcl/field.hxx>
#include <vcl/fixed.hxx>
@@ -94,3 +93,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/Client.hxx b/sd/source/ui/inc/Client.hxx
index b8f1dd298..035e168cd 100644
--- a/sd/source/ui/inc/Client.hxx
+++ b/sd/source/ui/inc/Client.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#define SD_CLIENT_HXX
-#ifndef _SFX_CLIENTSH_HXX //autogen
#include <sfx2/ipclient.hxx>
-#endif
class SdrGrafObj;
class SdrOle2Obj;
class OutlinerParaObject;
@@ -73,3 +72,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ClientView.hxx b/sd/source/ui/inc/ClientView.hxx
index 5bd2870bc..f62d87531 100644
--- a/sd/source/ui/inc/ClientView.hxx
+++ b/sd/source/ui/inc/ClientView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/CustomAnimation.hxx b/sd/source/ui/inc/CustomAnimation.hxx
index 21e4865f4..f32d2326b 100644
--- a/sd/source/ui/inc/CustomAnimation.hxx
+++ b/sd/source/ui/inc/CustomAnimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,15 @@
#ifndef _SD_CUSTOMANIMATION_HXX_
#define _SD_CUSTOMANIMATION_HXX_
-#ifndef _COM_SUN_STAR_FRAME_XModel_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
class Window;
namespace sd {
-// extern void showCustomAnimationPane( const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawView >& xView );
extern ::Window* createCustomAnimationPane( ::Window* pParent, const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel >& xModel );
}
#endif // _SD_CUSTOMANIMATION_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DialogListBox.hxx b/sd/source/ui/inc/DialogListBox.hxx
index 5dec726f6..e663bcf83 100644
--- a/sd/source/ui/inc/DialogListBox.hxx
+++ b/sd/source/ui/inc/DialogListBox.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@ public:
// SD_DIALOGLISTBOX_HXX
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DocumentRenderer.hxx b/sd/source/ui/inc/DocumentRenderer.hxx
index 5143f2ad5..c4f2869e1 100644
--- a/sd/source/ui/inc/DocumentRenderer.hxx
+++ b/sd/source/ui/inc/DocumentRenderer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DrawController.hxx b/sd/source/ui/inc/DrawController.hxx
index ea5f358e8..470930393 100755..100644
--- a/sd/source/ui/inc/DrawController.hxx
+++ b/sd/source/ui/inc/DrawController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -294,6 +295,8 @@ protected:
using cppu::OPropertySetHelper::getFastPropertyValue;
private:
+ const ::com::sun::star::uno::Type m_aSelectionTypeIdentifier;
+
/** This pointer to the ViewShellBase can be NULL (after a call to
ReleaseViewShellBase()).
*/
@@ -337,3 +340,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DrawDocShell.hxx b/sd/source/ui/inc/DrawDocShell.hxx
index c7dfcd0f1..e74aeaf08 100755..100644
--- a/sd/source/ui/inc/DrawDocShell.hxx
+++ b/sd/source/ui/inc/DrawDocShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,7 +90,8 @@ public:
virtual void Activate( sal_Bool bMDI );
virtual void Deactivate( sal_Bool bMDI );
virtual sal_Bool InitNew( const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >& xStorage );
- virtual sal_Bool ConvertFrom( SfxMedium &rMedium );
+ virtual sal_Bool ImportFrom( SfxMedium &rMedium, bool bInsert=false );
+ virtual sal_Bool ConvertFrom( SfxMedium &rMedium );
virtual sal_Bool Save();
virtual sal_Bool SaveAsOwnFormat( SfxMedium& rMedium );
virtual sal_Bool ConvertTo( SfxMedium &rMedium );
@@ -203,7 +205,7 @@ public:
DECL_LINK( RenameSlideHdl, AbstractSvxNameDialog* );
- // #91457# ExecuteSpellPopup now handled by DrawDocShell
+ // ExecuteSpellPopup now handled by DrawDocShell
DECL_LINK( OnlineSpellCallback, SpellCallbackInfo* );
void ClearUndoBuffer();
@@ -241,3 +243,5 @@ SV_IMPL_REF (DrawDocShell)
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DrawSubController.hxx b/sd/source/ui/inc/DrawSubController.hxx
index 186024573..3c83bb8cc 100755..100644
--- a/sd/source/ui/inc/DrawSubController.hxx
+++ b/sd/source/ui/inc/DrawSubController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ namespace sd {
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/DrawViewShell.hxx b/sd/source/ui/inc/DrawViewShell.hxx
index 936a9faa1..b1d6fd084 100755..100644
--- a/sd/source/ui/inc/DrawViewShell.hxx
+++ b/sd/source/ui/inc/DrawViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,6 +37,7 @@
#include "pres.hxx"
#include <com/sun/star/lang/XEventListener.hpp>
#include <com/sun/star/scanner/XScannerManager.hpp>
+#include <unotools/caserotate.hxx>
class SdPage;
class DrawDocShell;
@@ -64,7 +66,7 @@ class ViewOverlayManager;
/** Base class of the stacked shells that provide graphical views to
Draw and Impress documents and editing functionality. In contrast
to this other stacked shells are responsible for showing an
- overview over several slides (SlideViewShell) or a textual
+ overview over several slides or a textual
overview over the text in an Impress document (OutlineViewShell).
*/
class DrawViewShell
@@ -217,6 +219,7 @@ public:
void FuTemporary(SfxRequest& rReq);
void FuPermanent(SfxRequest& rReq);
void FuSupport(SfxRequest& rReq);
+ void FuSupportRotate(SfxRequest& rReq);
void FuTable(SfxRequest& rReq);
void AttrExec (SfxRequest& rReq);
@@ -434,6 +437,8 @@ private:
*/
bool mbIsInSwitchPage;
+ RotateTransliteration m_aRotateCase;
+
void Construct (DrawDocShell* pDocSh, PageKind ePageKind);
/** Depending on the given request create a new page or duplicate an
@@ -497,3 +502,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/EventMultiplexer.hxx b/sd/source/ui/inc/EventMultiplexer.hxx
index 8cffaa1d9..79615390c 100644
--- a/sd/source/ui/inc/EventMultiplexer.hxx
+++ b/sd/source/ui/inc/EventMultiplexer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -220,3 +221,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/FormShellManager.hxx b/sd/source/ui/inc/FormShellManager.hxx
index f683f9e5c..1e2ee8608 100644
--- a/sd/source/ui/inc/FormShellManager.hxx
+++ b/sd/source/ui/inc/FormShellManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -141,3 +142,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/FrameView.hxx b/sd/source/ui/inc/FrameView.hxx
index d1e8f5d48..6c8a4047e 100755..100644
--- a/sd/source/ui/inc/FrameView.hxx
+++ b/sd/source/ui/inc/FrameView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -235,3 +236,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/GraphicDocShell.hxx b/sd/source/ui/inc/GraphicDocShell.hxx
index 8798614a2..506b2b4da 100755..100644
--- a/sd/source/ui/inc/GraphicDocShell.hxx
+++ b/sd/source/ui/inc/GraphicDocShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,13 +68,8 @@ public:
virtual ~GraphicDocShell (void);
};
-#ifndef SV_DECL_SD_GRAPHIC_DOC_SHELL_DEFINED
-#define SV_DECL_SD_GRAPHIC_DOC_SHELL_DEFINED
-SV_DECL_REF(GraphicDocShell)
-#endif
-
-SV_IMPL_REF (GraphicDocShell)
-
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/GraphicObjectBar.hxx b/sd/source/ui/inc/GraphicObjectBar.hxx
index 35ef06ea6..662ba8829 100755..100644
--- a/sd/source/ui/inc/GraphicObjectBar.hxx
+++ b/sd/source/ui/inc/GraphicObjectBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/GraphicViewShell.hxx b/sd/source/ui/inc/GraphicViewShell.hxx
index beeb8ca77..c6bbd1725 100755..100644
--- a/sd/source/ui/inc/GraphicViewShell.hxx
+++ b/sd/source/ui/inc/GraphicViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/GraphicViewShellBase.hxx b/sd/source/ui/inc/GraphicViewShellBase.hxx
index f05eafe54..cf0d5c182 100644
--- a/sd/source/ui/inc/GraphicViewShellBase.hxx
+++ b/sd/source/ui/inc/GraphicViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ImpressViewShellBase.hxx b/sd/source/ui/inc/ImpressViewShellBase.hxx
index 6dcc8a37d..62bf183df 100644
--- a/sd/source/ui/inc/ImpressViewShellBase.hxx
+++ b/sd/source/ui/inc/ImpressViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/LayerDialogChildWindow.hxx b/sd/source/ui/inc/LayerDialogChildWindow.hxx
index c346caf4c..162ddf2ba 100755..100644
--- a/sd/source/ui/inc/LayerDialogChildWindow.hxx
+++ b/sd/source/ui/inc/LayerDialogChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/LayerDialogContent.hxx b/sd/source/ui/inc/LayerDialogContent.hxx
index ab1ac2ab5..652f8912b 100755..100644
--- a/sd/source/ui/inc/LayerDialogContent.hxx
+++ b/sd/source/ui/inc/LayerDialogContent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <sfx2/dockwin.hxx>
#include "LayerTabBar.hxx"
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
namespace sd {
@@ -62,3 +61,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/LayerTabBar.hxx b/sd/source/ui/inc/LayerTabBar.hxx
index 9a1282a8c..233220805 100644
--- a/sd/source/ui/inc/LayerTabBar.hxx
+++ b/sd/source/ui/inc/LayerTabBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/MasterPageObserver.hxx b/sd/source/ui/inc/MasterPageObserver.hxx
index de40a6949..821d2703f 100755..100644
--- a/sd/source/ui/inc/MasterPageObserver.hxx
+++ b/sd/source/ui/inc/MasterPageObserver.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -132,3 +133,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/MediaObjectBar.hxx b/sd/source/ui/inc/MediaObjectBar.hxx
index b3f948df6..67384db6e 100644
--- a/sd/source/ui/inc/MediaObjectBar.hxx
+++ b/sd/source/ui/inc/MediaObjectBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,3 +60,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/MutexOwner.hxx b/sd/source/ui/inc/MutexOwner.hxx
index b3d123861..b7d9fdea3 100644
--- a/sd/source/ui/inc/MutexOwner.hxx
+++ b/sd/source/ui/inc/MutexOwner.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,3 +46,5 @@ protected:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/NavigatorChildWindow.hxx b/sd/source/ui/inc/NavigatorChildWindow.hxx
index b3a724cfe..58357d561 100755..100644
--- a/sd/source/ui/inc/NavigatorChildWindow.hxx
+++ b/sd/source/ui/inc/NavigatorChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/NotesChildWindow.hxx b/sd/source/ui/inc/NotesChildWindow.hxx
index 3520ed63c..591780635 100755..100644
--- a/sd/source/ui/inc/NotesChildWindow.hxx
+++ b/sd/source/ui/inc/NotesChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
} } // end of namespaces ::sd::notes
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/OutlineBulletDlg.hxx b/sd/source/ui/inc/OutlineBulletDlg.hxx
index b230bb5d6..b0c6145f3 100755..100644
--- a/sd/source/ui/inc/OutlineBulletDlg.hxx
+++ b/sd/source/ui/inc/OutlineBulletDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/OutlineView.hxx b/sd/source/ui/inc/OutlineView.hxx
index a5f419cb6..b67699538 100755..100644
--- a/sd/source/ui/inc/OutlineView.hxx
+++ b/sd/source/ui/inc/OutlineView.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -61,12 +62,12 @@ static const int MAX_OUTLINERVIEWS = 4;
|*
\************************************************************************/
-class OutlineView
+class OutlineView
: public ::sd::View
{
friend class OutlineViewModelChangeGuard;
public:
- OutlineView (DrawDocShell* pDocSh,
+ OutlineView (DrawDocShell* pDocSh,
::Window* pWindow,
OutlineViewShell* pOutlineViewSh);
~OutlineView (void);
@@ -104,7 +105,7 @@ public:
virtual void Paint (const Rectangle& rRect, ::sd::Window* pWin);
virtual void AdjustPosSizePixel(
- const Point &rPos,
+ const Point &rPos,
const Size &rSize,
::sd::Window* pWindow);
@@ -128,7 +129,6 @@ public:
virtual sal_Bool GetAttributes( SfxItemSet& rTargetSet, sal_Bool bOnlyHardAttr=sal_False ) const;
virtual sal_Bool SetAttributes(const SfxItemSet& rSet, sal_Bool bReplaceAll = sal_False);
-// virtual sal_Bool HasMarkedObjUnused() const;
void FillOutliner();
void SetLinks();
void ResetLinks() const;
@@ -138,20 +138,20 @@ public:
void SetSelectedPages();
virtual sal_Int8 AcceptDrop (
- const AcceptDropEvent& rEvt,
- DropTargetHelper& rTargetHelper,
- ::sd::Window* pTargetWindow = NULL,
- sal_uInt16 nPage = SDRPAGE_NOTFOUND,
+ const AcceptDropEvent& rEvt,
+ DropTargetHelper& rTargetHelper,
+ ::sd::Window* pTargetWindow = NULL,
+ sal_uInt16 nPage = SDRPAGE_NOTFOUND,
sal_uInt16 nLayer = SDRPAGE_NOTFOUND);
virtual sal_Int8 ExecuteDrop (
- const ExecuteDropEvent& rEvt,
- DropTargetHelper& rTargetHelper,
- ::sd::Window* pTargetWindow = NULL,
- sal_uInt16 nPage = SDRPAGE_NOTFOUND,
+ const ExecuteDropEvent& rEvt,
+ DropTargetHelper& rTargetHelper,
+ ::sd::Window* pTargetWindow = NULL,
+ sal_uInt16 nPage = SDRPAGE_NOTFOUND,
sal_uInt16 nLayer = SDRPAGE_NOTFOUND);
- // #97766# Re-implement GetScriptType for this view to get correct results
+ // Re-implement GetScriptType for this view to get correct results
virtual sal_uInt16 GetScriptType() const;
/** After this method has been called with <TRUE/> following changes of
@@ -161,11 +161,6 @@ public:
cursor position.
*/
void IgnoreCurrentPageChanges (bool bIgnore);
-
-#if 0
- sal_Int32 GetPageNumberWidthPixel();
-#endif
-
void InvalidateSlideNumberArea();
/** creates and inserts an empty slide for the given paragraph. */
@@ -178,7 +173,7 @@ protected:
virtual void OnEndPasteOrDrop( PasteOrDropInfos* pInfos );
private:
- /** call this method before you do anything that can modify the outliner
+ /** call this method before you do anything that can modify the outliner
and or the drawing document model. It will create needed undo actions */
void BeginModelChange();
@@ -196,8 +191,8 @@ private:
SdrOutliner* mpOutliner;
OutlinerView* mpOutlinerView[MAX_OUTLINERVIEWS];
- List* mpOldParaOrder;
- List* mpSelectedParas;
+ std::vector<Paragraph*> maOldParaOrder;
+ std::vector<Paragraph*> maSelectedParas;
sal_uInt16 mnPagesToProcess; // fuer die Fortschrittsanzeige
sal_uInt16 mnPagesProcessed;
@@ -206,11 +201,6 @@ private:
SfxProgress* mpProgress;
- /** stores the last used high contrast mode.
- this is changed in onUpdateStyleSettings()
- */
- bool mbHighContrastMode;
-
/** stores the last used document color.
this is changed in onUpdateStyleSettings()
*/
@@ -262,3 +252,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/OutlineViewShell.hxx b/sd/source/ui/inc/OutlineViewShell.hxx
index 09b932516..9de82ef56 100755..100644
--- a/sd/source/ui/inc/OutlineViewShell.hxx
+++ b/sd/source/ui/inc/OutlineViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -177,3 +178,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/OutlineViewShellBase.hxx b/sd/source/ui/inc/OutlineViewShellBase.hxx
index f381d19c8..000426a57 100644
--- a/sd/source/ui/inc/OutlineViewShellBase.hxx
+++ b/sd/source/ui/inc/OutlineViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/OutlinerIteratorImpl.hxx b/sd/source/ui/inc/OutlinerIteratorImpl.hxx
index c63d38dbe..da51d1c1f 100755..100644
--- a/sd/source/ui/inc/OutlinerIteratorImpl.hxx
+++ b/sd/source/ui/inc/OutlinerIteratorImpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -224,8 +225,8 @@ protected:
void SetPage (sal_Int32 nPageIndex);
private:
- /// Indicates whether a page changed occured on switching to current page.
- bool mbPageChangeOccured;
+ /// Indicates whether a page changed occurred on switching to current page.
+ bool mbPageChangeOccurred;
/// Pointer to the page associated with the current page index. May be NULL.
SdPage* mpPage;
/// Iterator of all objects on the current page.
@@ -270,3 +271,5 @@ private:
} } // end of namespace ::sd::outliner
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PaneChildWindows.hxx b/sd/source/ui/inc/PaneChildWindows.hxx
index 6c69916da..0c13d5ca2 100755..100644
--- a/sd/source/ui/inc/PaneChildWindows.hxx
+++ b/sd/source/ui/inc/PaneChildWindows.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,5 @@ public:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PaneDockingWindow.hxx b/sd/source/ui/inc/PaneDockingWindow.hxx
index 67305ca3a..44f47b687 100644
--- a/sd/source/ui/inc/PaneDockingWindow.hxx
+++ b/sd/source/ui/inc/PaneDockingWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,5 @@ public:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PaneShells.hxx b/sd/source/ui/inc/PaneShells.hxx
index d982603c0..a2e812439 100755..100644
--- a/sd/source/ui/inc/PaneShells.hxx
+++ b/sd/source/ui/inc/PaneShells.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PresentationViewShell.hxx b/sd/source/ui/inc/PresentationViewShell.hxx
index 4dbbe1cc4..738a317ff 100755..100644
--- a/sd/source/ui/inc/PresentationViewShell.hxx
+++ b/sd/source/ui/inc/PresentationViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PresentationViewShellBase.hxx b/sd/source/ui/inc/PresentationViewShellBase.hxx
index 02fc7607c..8fdd04380 100644
--- a/sd/source/ui/inc/PresentationViewShellBase.hxx
+++ b/sd/source/ui/inc/PresentationViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/PreviewRenderer.hxx b/sd/source/ui/inc/PreviewRenderer.hxx
index 1ffe67f25..f252a8726 100755..100644
--- a/sd/source/ui/inc/PreviewRenderer.hxx
+++ b/sd/source/ui/inc/PreviewRenderer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -176,3 +177,5 @@ private:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/Ruler.hxx b/sd/source/ui/inc/Ruler.hxx
index 6d1b25cd7..e994ca35c 100755..100644
--- a/sd/source/ui/inc/Ruler.hxx
+++ b/sd/source/ui/inc/Ruler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,12 +40,6 @@ class RulerCtrlItem;
class View;
class Window;
-/*************************************************************************
-|*
-|* das Fenster der Diashow leitet Mouse- und Key-Events an die SlideViewShell
-|*
-\************************************************************************/
-
class Ruler
: public SvxRuler
{
@@ -80,3 +75,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SdUnoDrawView.hxx b/sd/source/ui/inc/SdUnoDrawView.hxx
index 1a8277d0d..ebd079197 100755..100644
--- a/sd/source/ui/inc/SdUnoDrawView.hxx
+++ b/sd/source/ui/inc/SdUnoDrawView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -151,3 +152,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SdUnoOutlineView.hxx b/sd/source/ui/inc/SdUnoOutlineView.hxx
index be5c0960b..ad4bfbd9c 100755..100644
--- a/sd/source/ui/inc/SdUnoOutlineView.hxx
+++ b/sd/source/ui/inc/SdUnoOutlineView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,3 +126,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SdUnoSlideView.hxx b/sd/source/ui/inc/SdUnoSlideView.hxx
index 14ebbb61a..b65ed13ea 100755..100644
--- a/sd/source/ui/inc/SdUnoSlideView.hxx
+++ b/sd/source/ui/inc/SdUnoSlideView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,7 +46,6 @@ class PageSelector;
namespace sd {
class DrawController;
-class SlideViewShell;
class View;
@@ -140,3 +140,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ShellFactory.hxx b/sd/source/ui/inc/ShellFactory.hxx
index 5de0b7144..f6ca72e0a 100644
--- a/sd/source/ui/inc/ShellFactory.hxx
+++ b/sd/source/ui/inc/ShellFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SlideSorter.hxx b/sd/source/ui/inc/SlideSorter.hxx
index 3659f88e4..c39033738 100755..100644
--- a/sd/source/ui/inc/SlideSorter.hxx
+++ b/sd/source/ui/inc/SlideSorter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -285,3 +286,5 @@ private:
} } // end of namespace ::sd::slidesorter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SlideSorterChildWindow.hxx b/sd/source/ui/inc/SlideSorterChildWindow.hxx
index d0aa67ea0..db0ea244a 100755..100644
--- a/sd/source/ui/inc/SlideSorterChildWindow.hxx
+++ b/sd/source/ui/inc/SlideSorterChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ public:
} } // end of namespaces ::sd::slidesorter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SlideSorterViewShell.hxx b/sd/source/ui/inc/SlideSorterViewShell.hxx
index adbd65434..8d4faa1df 100755..100644
--- a/sd/source/ui/inc/SlideSorterViewShell.hxx
+++ b/sd/source/ui/inc/SlideSorterViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -217,3 +218,5 @@ typedef ::boost::shared_ptr<SlideSorterViewShell::PageSelection> SharedPageSelec
} } // end of namespace ::sd::slidesorter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SlideSorterViewShellBase.hxx b/sd/source/ui/inc/SlideSorterViewShellBase.hxx
index 06be68d78..5deee7cd4 100644
--- a/sd/source/ui/inc/SlideSorterViewShellBase.hxx
+++ b/sd/source/ui/inc/SlideSorterViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/SlideView.hxx b/sd/source/ui/inc/SlideView.hxx
deleted file mode 100755
index a95a3e8c3..000000000
--- a/sd/source/ui/inc/SlideView.hxx
+++ /dev/null
@@ -1,144 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_SLIDE_VIEW_HXX
-#define SD_SLIDE_VIEW_HXX
-
-#include "View.hxx"
-
-class SdDrawDocument;
-class BitmapCache;
-class SdPage;
-
-namespace sd {
-
-class SlideViewShell;
-class Window;
-
-// ----------------------
-// - SlideViewFocusMove -
-// ----------------------
-
-enum SlideViewFocusMove
-{
- SLIDEVIEWFOCUSMOVE_NONE = 0,
- SLIDEVIEWFOCUSMOVE_TOGGLE = 1,
- SLIDEVIEWFOCUSMOVE_SELECT = 2,
- SLIDEVIEWFOCUSMOVE_LEFT = 3,
- SLIDEVIEWFOCUSMOVE_TOP = 4,
- SLIDEVIEWFOCUSMOVE_RIGHT = 5,
- SLIDEVIEWFOCUSMOVE_BOTTOM = 6
-};
-
-// ---------------
-// - SdSlideView -
-// ---------------
-
-class SlideView
- : public ::sd::View
-{
-public:
- TYPEINFO();
-
- SlideView (
- SdDrawDocument* pDoc,
- ::Window* pWindow,
- SlideViewShell* pSlideVShell);
- virtual ~SlideView (void);
-
- void Select( sal_uInt16 nSdPageNum, sal_Bool bSelect );
- void SelectAllSlides( sal_Bool bSelect );
-
- void MoveFocus( SlideViewFocusMove eMove );
- sal_uInt16 GetFocusPage() const;
- sal_Bool HasFocus() const;
-
- sal_uInt16 ChangePagesPerRow( sal_uInt16 nNum );
- sal_uInt16 GetPagesPerRow() const { return nPagesPerRow; }
-
- virtual void InvalidateOneWin( ::Window& rWin );
- virtual void InvalidateOneWin( ::Window& rWin, const Rectangle& rRect );
-
- void SetAllowInvalidate( sal_Bool bFlag );
- sal_Bool IsInvalidateAllowed() const;
-
- void Paint(const Rectangle& rRect, OutputDevice* pOut);
- void DrawSelectionRect(sal_uInt16 nPage);
-
- Point CalcPagePos( sal_uInt16 nPageNo ) const;
- Rectangle GetPageArea( sal_uInt16 nPageNo ) const;
- sal_uLong GetPageGap() const;
- Rectangle GetFadeIconArea( sal_uInt16 nPageNo ) const;
- SdPage* GetHitPage( const Point& rPos ) const;
- SdPage* GetFadePage( const Point& rPos ) const;
- SdPage* GetNearestPage( const Point& rPos ) const;
-
- void DeleteMarked();
- void MoveMarked( sal_uInt16 nTargetPage );
-
- void AddToCache( SdPage* pPage, const Bitmap& rBitmap, long nZoom );
- const GraphicObject* GetFromCache( SdPage* pPage, long& rZoom, long nZoomTolerance ) const;
-
- virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
-
- virtual void DoCut( ::Window* pWindow = NULL );
- virtual void DoCopy( ::Window* pWindow = NULL );
- virtual void DoPaste( ::Window* pWindow = NULL );
-
- virtual void StartDrag( const Point& rDragPt, ::Window* pWindow );
- virtual void DragFinished( sal_Int8 nDropAction );
-
- virtual sal_Int8 AcceptDrop( const AcceptDropEvent& rEvt, DropTargetHelper& rTargetHelper,
- ::sd::Window* pTargetWindow = NULL,
- sal_uInt16 nPage = SDRPAGE_NOTFOUND,
- sal_uInt16 nLayer = SDRPAGE_NOTFOUND );
- virtual sal_Int8 ExecuteDrop( const ExecuteDropEvent& rEvt, DropTargetHelper& rTargetHelper,
- ::sd::Window* pTargetWindow = NULL,
- sal_uInt16 nPage = SDRPAGE_NOTFOUND,
- sal_uInt16 nLayer = SDRPAGE_NOTFOUND );
-
- void UpdateAllPages();
-
-private:
- Timer aDelayedPaintTimer;
- List aDelayedPaints;
- SlideViewShell* pSlideViewShell;
- BitmapCache* pCache;
- VirtualDevice* mpVDev;
- sal_uInt16 nAllowInvalidateSmph;
- sal_uInt16 nPagesPerRow;
- sal_uInt16 nFocusPage;
- sal_Bool bInPaint;
- sal_Bool bInDelayedPaint;
-
- DECL_LINK( PaintDelayed, Timer * );
- void CreateSlideTransferable (::Window* pWindow, sal_Bool bDrag);
-};
-
-} // end of namespace sd
-
-#endif
diff --git a/sd/source/ui/inc/SlideViewShell.hxx b/sd/source/ui/inc/SlideViewShell.hxx
deleted file mode 100755
index 18c5596ba..000000000
--- a/sd/source/ui/inc/SlideViewShell.hxx
+++ /dev/null
@@ -1,175 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_SLIDE_VIEW_SHELL_HXX
-#define SD_SLIDE_VIEW_SHELL_HXX
-
-
-#include "ViewShell.hxx"
-#include "SlideView.hxx"
-#include <sfx2/viewfac.hxx>
-#include <sfx2/viewsh.hxx>
-
-
-
-class SdPage;
-
-
-
-namespace sd {
-
-class SdUnoSlideView;
-class Window;
-
-/** Show an overview over the slides in an Impress document and allow
- some high level editing i.e. editing of the order in a show, not
- the contents of the slides.
-*/
-class SlideViewShell
- : public ViewShell
-{
-public:
-
- TYPEINFO();
-
- SFX_DECL_VIEWFACTORY(SlideViewShell);
- SFX_DECL_INTERFACE(SD_IF_SDSLIDEVIEWSHELL)
-
- /** Create a new view shell for the slide view.
- @param rViewShellBase
- The new object will be stacked on this view shell base.
- @param pFrameView
- The frame view that makes it possible to pass information from
- one view shell to the next.
- */
- SlideViewShell(SfxViewFrame* pFrame,
- ViewShellBase& rViewShellBase,
- ::Window* pParentWindow,
- FrameView* pFrameView = NULL);
-
- SlideViewShell(SfxViewFrame *pFrame,
- ::Window* pParentWindow,
- const SlideViewShell& rShell);
-
- virtual ~SlideViewShell (void);
-
- virtual void Paint(const Rectangle& rRect, ::sd::Window* pWin);
-
- /** Arrange and resize the GUI elements like rulers, sliders, and
- buttons as well as the actual document view according to the size of
- the enclosing window and current sizes of buttons, rulers, and
- sliders.
- */
- virtual void ArrangeGUIElements (void);
- virtual void AddWindow(::sd::Window* pWin) { pSlideView->AddWindowToPaintView((OutputDevice*) pWin); }
- virtual void RemoveWindow(::sd::Window* pWin) { pSlideView->DeleteWindowFromPaintView((OutputDevice*) pWin); }
-
- virtual sal_Bool KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin);
- virtual void MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin);
- virtual void MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin);
- virtual void MouseButtonDown(const MouseEvent& rMEvt, ::sd::Window* pWin);
- virtual void Command(const CommandEvent& rCEvt, ::sd::Window* pWin);
-
- virtual SdPage* GetActualPage();
-
- /** @returns
- current or selected page or 0.
- */
- virtual SdPage* getCurrentPage() const;
-
- void ExecCtrl(SfxRequest &rReq);
- void GetCtrlState(SfxItemSet &rSet);
- void GetMenuState(SfxItemSet &rSet);
- void GetAttrState(SfxItemSet &rSet);
-
- void SetPagesPerRow( sal_uInt16 nPagesPerRow );
-
- void ExecStatusBar(SfxRequest& rReq);
- void GetStatusBarState(SfxItemSet& rSet);
-
- void FuTemporary(SfxRequest &rReq);
- void FuPermanent(SfxRequest &rReq);
- void FuSupport(SfxRequest &rReq);
-
- virtual void ReadFrameViewData(FrameView* pView);
- virtual void WriteFrameViewData();
-
- virtual void SetZoom(long nZoom);
- virtual void SetZoomRect(const Rectangle& rZoomRect);
-
- virtual sal_Bool HasSelection( sal_Bool bText = sal_True ) const;
-
- /** Draw the rectangle arround the specified slide that indicates whether
- the slide is selected or not. When not selected the rectangle is
- painted in the background color (WindowColor from the style settings)
- and is therefore not visible. A selected slide is painted with the
- WindowTextColor from the style settings. Painting takes place in
- all associated windows. The line- and fill color of the windows are
- restored to their original values after the rectangle is painted.
- @param nPage
- When the page number is invalid then the call is ignored.
- */
- void DrawSelectionRect( sal_uInt16 nPage );
- void DrawFocusRect( sal_uInt16 nPage );
-
- virtual void WriteUserDataSequence ( ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, sal_Bool bBrowse = sal_False );
- virtual void ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, sal_Bool bBrowse = sal_False );
-
- virtual void VisAreaChanged(const Rectangle& rRect);
-
- virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible> CreateAccessibleDocumentView( ::sd::Window* pWindow );
-
- void SelectionHasChanged();
- void PageLayoutHasChanged();
- void FocusHasChanged( sal_uInt16 nOldFocusPage, sal_uInt16 nNewFocusPage );
- void PageVisibilityHasChanged( sal_uInt16 nPage, sal_Bool bVisible );
-
- /** On activation the preview is turned off.
- */
- virtual void Activate (sal_Bool IsMDIActivate);
-
-protected:
- virtual Size GetOptimalSizePixel() const;
- virtual long VirtHScrollHdl(ScrollBar* pHScroll);
- virtual long VirtVScrollHdl(ScrollBar* pVHScroll);
-
-
-private:
- SlideView* pSlideView;
- Point aDisplayPos;
- Size aDisplaySize;
- sal_uInt16 nCurFocusPage;
- bool bSetInitialZoomFactor;
- bool bInitializeWinPos;
-
- void Construct(SdDrawDocument* pDoc);
- void ImplDrawFocusRect( sal_uInt16 nPage, sal_Bool bVisible );
-};
-
-} // end of namespace sd
-
-#endif
diff --git a/sd/source/ui/inc/SpellDialogChildWindow.hxx b/sd/source/ui/inc/SpellDialogChildWindow.hxx
index 78555f9de..a2bb00061 100755..100644
--- a/sd/source/ui/inc/SpellDialogChildWindow.hxx
+++ b/sd/source/ui/inc/SpellDialogChildWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ private:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/TabControl.hxx b/sd/source/ui/inc/TabControl.hxx
index c1e6aa2b0..7ac5c52cb 100755..100644
--- a/sd/source/ui/inc/TabControl.hxx
+++ b/sd/source/ui/inc/TabControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -120,3 +121,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/TemplateScanner.hxx b/sd/source/ui/inc/TemplateScanner.hxx
index a24fd9094..deb48ef05 100755..100644
--- a/sd/source/ui/inc/TemplateScanner.hxx
+++ b/sd/source/ui/inc/TemplateScanner.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -218,3 +219,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/TextLogger.hxx b/sd/source/ui/inc/TextLogger.hxx
index 8b344c680..7a7bc0b06 100644
--- a/sd/source/ui/inc/TextLogger.hxx
+++ b/sd/source/ui/inc/TextLogger.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ private:
} } // end of namespace ::sd::notes
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/TextObjectBar.hxx b/sd/source/ui/inc/TextObjectBar.hxx
index 5a9c463f8..2ef1f2bff 100644
--- a/sd/source/ui/inc/TextObjectBar.hxx
+++ b/sd/source/ui/inc/TextObjectBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ToolBarManager.hxx b/sd/source/ui/inc/ToolBarManager.hxx
index e37143eb2..bdf30db4d 100755..100644
--- a/sd/source/ui/inc/ToolBarManager.hxx
+++ b/sd/source/ui/inc/ToolBarManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -281,3 +282,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/UpdateLockManager.hxx b/sd/source/ui/inc/UpdateLockManager.hxx
index 8ee4af44c..1f12d3dc7 100755..100644
--- a/sd/source/ui/inc/UpdateLockManager.hxx
+++ b/sd/source/ui/inc/UpdateLockManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/View.hxx b/sd/source/ui/inc/View.hxx
index 13b8d4b5f..858c205fe 100755..100644
--- a/sd/source/ui/inc/View.hxx
+++ b/sd/source/ui/inc/View.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,14 +29,13 @@
#ifndef SD_VIEW_HXX
#define SD_VIEW_HXX
+#include <boost/ptr_container/ptr_vector.hpp>
+
#include "pres.hxx"
#include <tools/gen.hxx>
#include <svtools/transfer.hxx>
#include <svx/fmview.hxx>
#include <svx/svdmark.hxx>
-//#ifndef _SVDVMARK_HXX //autogen
-//#include <svx/svdvmark.hxx>
-//#endif
#include <svx/svdpage.hxx>
#include "fupoor.hxx"
@@ -226,7 +226,7 @@ protected:
Timer maDropErrorTimer;
Timer maDropInsertFileTimer;
sal_uInt16 mnLockRedrawSmph;
- List* mpLockedRedraws;
+ boost::ptr_vector<SdViewRedrawRec> maLockedRedraws;
bool mbIsDropAllowed;
DECL_LINK( DropErrorHdl, Timer* );
@@ -259,3 +259,5 @@ ViewShell* View::GetViewShell (void) const
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewClipboard.hxx b/sd/source/ui/inc/ViewClipboard.hxx
index 14ae968f7..d04b70db4 100755..100644
--- a/sd/source/ui/inc/ViewClipboard.hxx
+++ b/sd/source/ui/inc/ViewClipboard.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,5 @@ protected:
} // end of namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewShell.hxx b/sd/source/ui/inc/ViewShell.hxx
index 75b2765d1..bf2f098a3 100755..100644
--- a/sd/source/ui/inc/ViewShell.hxx
+++ b/sd/source/ui/inc/ViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,9 +40,7 @@
#include "glob.hxx"
#include "pres.hxx"
#include "cfgids.hxx"
-#ifndef _SD_VIEW_HXX
#include "View.hxx"
-#endif
#include "sddllapi.h"
#include <com/sun/star/drawing/XDrawSubController.hpp>
@@ -533,7 +532,7 @@ protected:
::std::auto_ptr<Implementation> mpImpl;
- // #96090# Support methods for centralized UNDO/REDO
+ // Support methods for centralized UNDO/REDO
virtual ::svl::IUndoManager* ImpGetUndoManager (void) const;
void ImpGetUndoStrings(SfxItemSet &rSet) const;
void ImpGetRedoStrings(SfxItemSet &rSet) const;
@@ -563,6 +562,27 @@ protected:
virtual void SetZoomFactor( const Fraction &rZoomX,
const Fraction &rZoomY );
+ /**
+ This must be called after the ctor, but before anything else.
+ It's the part of construction that is dependent
+ on showing the top-level window.
+
+ Showing a window with a11y enabled causes various callbacks
+ to be triggered.
+
+ Due to the "virtual methods are not virtual during constructors"
+ problem, this is a disaster to call from the ctor
+
+ i.e. construct calls Show, and if a11y is enabled this
+ reenters the not-fully constructed object and calls
+ CreateAccessibleDocumentView, so if construct is called
+ from the ctor then if a derived class is contructed the base-cass
+ CreateAccessibleDocumentView is used, not the derived
+ CreateAccessibleDocumentView. i.e. run smoketest under a11y with
+ debugging assertions enabled
+ */
+ void doShow();
+
private:
::Window* mpParentWindow;
/** This window updater is used to keep all relevant windows up to date
@@ -604,3 +624,5 @@ SdrView* ViewShell::GetDrawView (void) const
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewShellBase.hxx b/sd/source/ui/inc/ViewShellBase.hxx
index cb4f8bf8a..2ee137d23 100755..100644
--- a/sd/source/ui/inc/ViewShellBase.hxx
+++ b/sd/source/ui/inc/ViewShellBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -271,3 +272,5 @@ public:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewShellHint.hxx b/sd/source/ui/inc/ViewShellHint.hxx
index 424106543..c72780783 100644
--- a/sd/source/ui/inc/ViewShellHint.hxx
+++ b/sd/source/ui/inc/ViewShellHint.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewShellImplementation.hxx b/sd/source/ui/inc/ViewShellImplementation.hxx
index 60704da89..699047659 100755..100644
--- a/sd/source/ui/inc/ViewShellImplementation.hxx
+++ b/sd/source/ui/inc/ViewShellImplementation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -164,3 +165,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewShellManager.hxx b/sd/source/ui/inc/ViewShellManager.hxx
index 1dcde8358..9a3a7b1f4 100755..100644
--- a/sd/source/ui/inc/ViewShellManager.hxx
+++ b/sd/source/ui/inc/ViewShellManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -210,3 +211,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewTabBar.hxx b/sd/source/ui/inc/ViewTabBar.hxx
index afe5ad69f..ce668bea7 100644
--- a/sd/source/ui/inc/ViewTabBar.hxx
+++ b/sd/source/ui/inc/ViewTabBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,9 +37,7 @@
#include <com/sun/star/drawing/framework/XConfigurationController.hpp>
#include <com/sun/star/drawing/framework/XConfigurationChangeListener.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#ifndef _VCL_TABCTRL_HXX_
#include <vcl/tabctrl.hxx>
-#endif
#include <cppuhelper/compbase4.hxx>
#include "MutexOwner.hxx"
@@ -208,3 +207,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ViewTabControl.hxx b/sd/source/ui/inc/ViewTabControl.hxx
index 31f5f2222..9077d760d 100755..100644
--- a/sd/source/ui/inc/ViewTabControl.hxx
+++ b/sd/source/ui/inc/ViewTabControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -118,3 +119,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/Window.hxx b/sd/source/ui/inc/Window.hxx
index 6e33cc85e..af200f362 100755..100644
--- a/sd/source/ui/inc/Window.hxx
+++ b/sd/source/ui/inc/Window.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -170,11 +171,12 @@ protected:
Point maWinPos;
Point maViewOrigin;
Size maViewSize;
+ Size maPrevSize; // contains previous window size in logical coords
sal_uInt16 mnMinZoom;
sal_uInt16 mnMaxZoom;
+
/** This flag tells whether to re-calculate the minimal zoom factor
- depening on the current zoom factor. According to task #105436# its
- default value is now sal_False.
+ depening on the current zoom factor. Its default value is now sal_False.
*/
bool mbMinZoomAutoCalc;
bool mbCalcMinZoomByMinSide;
@@ -214,3 +216,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/WindowUpdater.hxx b/sd/source/ui/inc/WindowUpdater.hxx
index 791c468d2..63d5138da 100644
--- a/sd/source/ui/inc/WindowUpdater.hxx
+++ b/sd/source/ui/inc/WindowUpdater.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -150,3 +151,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/animobjs.hxx b/sd/source/ui/inc/animobjs.hxx
index 7352e8851..2e8100fd5 100755..100644
--- a/sd/source/ui/inc/animobjs.hxx
+++ b/sd/source/ui/inc/animobjs.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include <vcl/group.hxx>
#include <sfx2/ctrlitem.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/field.hxx>
#include <svx/dlgctrl.hxx>
#include <sfx2/progress.hxx>
@@ -44,9 +43,7 @@
#include <vcl/lstbox.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "misc/scopelock.hxx"
class SdDrawDocument;
@@ -199,3 +196,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/annotationmanager.hxx b/sd/source/ui/inc/annotationmanager.hxx
index be7cd03a6..0d596bd6e 100755..100644
--- a/sd/source/ui/inc/annotationmanager.hxx
+++ b/sd/source/ui/inc/annotationmanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ private:
}
#endif // _SD_ANNOTATIONMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/assclass.hxx b/sd/source/ui/inc/assclass.hxx
index 1bbe3eee3..435801f14 100644
--- a/sd/source/ui/inc/assclass.hxx
+++ b/sd/source/ui/inc/assclass.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,17 +29,19 @@
#ifndef INC_ASSCLASS
#define INC_ASSCLASS
+#include <vector>
+#include <boost/scoped_array.hpp>
+
#include <tools/solar.h>
#include "sddllapi.h"
#define MAX_PAGES 10
-class List;
class Control;
class SD_DLLPUBLIC Assistent
{
- List* mpPages[MAX_PAGES];
+ std::vector<Control*> maPages[MAX_PAGES];
//enthaelt fuer jede Seite die Controls die
//korrekt geschaltet werden muessen
@@ -48,13 +51,13 @@ class SD_DLLPUBLIC Assistent
int mnCurrentPage;
//gibt die aktuelle Seite an
- bool* mpPageStatus;
+ boost::scoped_array<bool> mpPageStatus;
public:
Assistent(int nNoOfPage);
- bool IsEnabled( int nPage );
+ bool IsEnabled ( int nPage ) const;
void EnablePage( int nPage );
void DisablePage( int nPage );
@@ -70,17 +73,17 @@ public:
bool GotoPage(const int nPageToGo);
//springt zu einer angegebenen Seite
- bool IsLastPage();
+ bool IsLastPage() const;
//gibt an ob die aktuelle Seite die letzte ist
- bool IsFirstPage();
+ bool IsFirstPage() const;
//gibt an ob die aktuelle Seite die erste ist
- int GetCurrentPage();
+ int GetCurrentPage() const;
//gibt die aktuelle Seite zurueck
-
- ~Assistent();
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/bmcache.hxx b/sd/source/ui/inc/bmcache.hxx
deleted file mode 100755
index 4449ec434..000000000
--- a/sd/source/ui/inc/bmcache.hxx
+++ /dev/null
@@ -1,52 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _SD_BMCACHE_HXX
-#define _SD_BMCACHE_HXX
-
-#include <tools/list.hxx>
-
-
-class SdPage;
-class GraphicObject;
-
-class BitmapCache
-{
- sal_uLong nMaxSize;
- sal_uLong nCurSize;
- List aEntries;
-
-public:
- BitmapCache(sal_uLong nMaxSizeKB)
- : nMaxSize(nMaxSizeKB), nCurSize(0) {}
- virtual ~BitmapCache();
-
- void Remove(const SdPage* pPage);
-};
-
-#endif // _SD_BMCACHE_HXX
-
diff --git a/sd/source/ui/inc/bulmaper.hxx b/sd/source/ui/inc/bulmaper.hxx
index b02072b3e..2ad072c22 100644
--- a/sd/source/ui/inc/bulmaper.hxx
+++ b/sd/source/ui/inc/bulmaper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,14 +29,14 @@
#ifndef INCLUDED_SD_BULMAPER_HXX
#define INCLUDED_SD_BULMAPER_HXX
-#include "tools/solar.h"
+#include <sddllapi.h>
class SfxItemSet;
class SvxBulletItem;
class SvxNumberFormat;
class SvxNumRule;
-class SdBulletMapper
+class SD_DLLPUBLIC SdBulletMapper
{
public:
/* #i35937#
@@ -47,3 +48,5 @@ public:
};
#endif /* INCLUDED_SD_BULMAPER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/celltempl.hxx b/sd/source/ui/inc/celltempl.hxx
index a6bc03daa..133eae2e4 100755..100644
--- a/sd/source/ui/inc/celltempl.hxx
+++ b/sd/source/ui/inc/celltempl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ public:
#endif // SD_CELLTEMPL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/cfgids.hxx b/sd/source/ui/inc/cfgids.hxx
index 12e51fce0..58e4e898e 100644
--- a/sd/source/ui/inc/cfgids.hxx
+++ b/sd/source/ui/inc/cfgids.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/copydlg.hxx b/sd/source/ui/inc/copydlg.hxx
index aaa82d433..72c9cecfe 100755..100644
--- a/sd/source/ui/inc/copydlg.hxx
+++ b/sd/source/ui/inc/copydlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#define SD_COPY_DLG_HXX
#include <vcl/group.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <svx/dlgctrl.hxx>
#include <vcl/field.hxx>
#include <vcl/fixed.hxx>
@@ -103,3 +102,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/custsdlg.hxx b/sd/source/ui/inc/custsdlg.hxx
index 1def1b886..a12b3c7bb 100755..100644
--- a/sd/source/ui/inc/custsdlg.hxx
+++ b/sd/source/ui/inc/custsdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#ifndef _SD_CUSTSDLG_HXX
#define _SD_CUSTSDLG_HXX
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/lstbox.hxx>
#include <vcl/fixed.hxx>
#include <vcl/edit.hxx>
@@ -114,3 +113,4 @@ public:
#endif // _SD_CUSTSDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/diactrl.hxx b/sd/source/ui/inc/diactrl.hxx
index f53c294e7..82dfefb0d 100755..100644
--- a/sd/source/ui/inc/diactrl.hxx
+++ b/sd/source/ui/inc/diactrl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ public:
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlg_char.hxx b/sd/source/ui/inc/dlg_char.hxx
index 897755423..bd935596f 100755..100644
--- a/sd/source/ui/inc/dlg_char.hxx
+++ b/sd/source/ui/inc/dlg_char.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,3 +60,4 @@ public:
#endif // SD_DLG_CHAR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlgass.hxx b/sd/source/ui/inc/dlgass.hxx
index 3c4f69966..980e0161b 100755..100644
--- a/sd/source/ui/inc/dlgass.hxx
+++ b/sd/source/ui/inc/dlgass.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,11 @@
#ifndef INC_DLGASS
#define INC_DLGASS
-#ifndef _GROUP_HXX
#include <vcl/group.hxx>
-#endif
-#ifndef _EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
#include <svtools/svmedit.hxx>
#include "assclass.hxx"
#include <vcl/lstbox.hxx>
@@ -75,3 +66,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlgctrls.hxx b/sd/source/ui/inc/dlgctrls.hxx
index e7d4286f7..aa8798e9a 100755..100644
--- a/sd/source/ui/inc/dlgctrls.hxx
+++ b/sd/source/ui/inc/dlgctrls.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#include "TransitionPreset.hxx"
#include <vcl/lstbox.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "fadedef.h"
#include "sddllapi.h"
@@ -60,3 +59,5 @@ public:
};
#endif // SD_DLGCTRLS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlgfield.hxx b/sd/source/ui/inc/dlgfield.hxx
index 3e9059cb1..36339e326 100755..100644
--- a/sd/source/ui/inc/dlgfield.hxx
+++ b/sd/source/ui/inc/dlgfield.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,21 +31,11 @@
#define _SD_DLGFIELD_HXX
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
#include <svx/langbox.hxx>
class SvxFieldData;
@@ -87,3 +78,5 @@ public:
#endif // _SD_DLGFIELD_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlgpage.hxx b/sd/source/ui/inc/dlgpage.hxx
index 346ee15a7..69136fed9 100755..100644
--- a/sd/source/ui/inc/dlgpage.hxx
+++ b/sd/source/ui/inc/dlgpage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,4 @@ public:
#endif // _SD_DLGPAGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/dlgsnap.hrc b/sd/source/ui/inc/dlgsnap.hrc
index f7a20249e..6d4c1a6fc 100644
--- a/sd/source/ui/inc/dlgsnap.hrc
+++ b/sd/source/ui/inc/dlgsnap.hrc
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -38,7 +38,3 @@
#define RB_HORIZONTAL 11
#define RB_VERTICAL 12
#define RB_POINT 13
-
-#define BMP_POINT_H 1
-#define BMP_VERTICAL_H 2
-#define BMP_HORIZONTAL_H 3
diff --git a/sd/source/ui/inc/dlgsnap.hxx b/sd/source/ui/inc/dlgsnap.hxx
index dd615c34a..c654b9318 100755..100644
--- a/sd/source/ui/inc/dlgsnap.hxx
+++ b/sd/source/ui/inc/dlgsnap.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,25 +31,13 @@
#define _SD_DLGSNAP_HXX
-#ifndef _IMAGEBTN_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <tools/fract.hxx>
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
#include "sdenumdef.hxx"
/************************************************************************/
@@ -99,3 +88,5 @@ public:
#endif // _SD_DLGSNAP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/docprev.hxx b/sd/source/ui/inc/docprev.hxx
index 67095453b..e1db2ed5a 100755..100644
--- a/sd/source/ui/inc/docprev.hxx
+++ b/sd/source/ui/inc/docprev.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -86,3 +87,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/drawview.hxx b/sd/source/ui/inc/drawview.hxx
index 17c797add..4a2ce636d 100755..100644
--- a/sd/source/ui/inc/drawview.hxx
+++ b/sd/source/ui/inc/drawview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/filedlg.hxx b/sd/source/ui/inc/filedlg.hxx
index 6061ca8ce..211579632 100755..100644
--- a/sd/source/ui/inc/filedlg.hxx
+++ b/sd/source/ui/inc/filedlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,4 @@ public:
#endif // _FILEDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/Configuration.hxx b/sd/source/ui/inc/framework/Configuration.hxx
index 50c0fc0f7..8f5dd6c6a 100755..100644
--- a/sd/source/ui/inc/framework/Configuration.hxx
+++ b/sd/source/ui/inc/framework/Configuration.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -205,3 +206,5 @@ bool AreConfigurationsEquivalent (
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/ConfigurationController.hxx b/sd/source/ui/inc/framework/ConfigurationController.hxx
index faec19d02..221ff7cda 100644
--- a/sd/source/ui/inc/framework/ConfigurationController.hxx
+++ b/sd/source/ui/inc/framework/ConfigurationController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -229,3 +230,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/DrawModule.hxx b/sd/source/ui/inc/framework/DrawModule.hxx
index f5e97f365..14865c674 100644
--- a/sd/source/ui/inc/framework/DrawModule.hxx
+++ b/sd/source/ui/inc/framework/DrawModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,3 +47,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/FrameworkHelper.hxx b/sd/source/ui/inc/framework/FrameworkHelper.hxx
index ad7552bec..3d90ce5dd 100755..100644
--- a/sd/source/ui/inc/framework/FrameworkHelper.hxx
+++ b/sd/source/ui/inc/framework/FrameworkHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -428,3 +429,5 @@ namespace {
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/ImpressModule.hxx b/sd/source/ui/inc/framework/ImpressModule.hxx
index 03a507a59..3d5744e18 100644
--- a/sd/source/ui/inc/framework/ImpressModule.hxx
+++ b/sd/source/ui/inc/framework/ImpressModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,3 +46,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/ModuleController.hxx b/sd/source/ui/inc/framework/ModuleController.hxx
index 9c85c8dc3..9be39f1e8 100644
--- a/sd/source/ui/inc/framework/ModuleController.hxx
+++ b/sd/source/ui/inc/framework/ModuleController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -146,3 +147,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/Pane.hxx b/sd/source/ui/inc/framework/Pane.hxx
index d3a65ba6a..7293bc53d 100755..100644
--- a/sd/source/ui/inc/framework/Pane.hxx
+++ b/sd/source/ui/inc/framework/Pane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -173,3 +174,5 @@ protected:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/PresentationFactory.hxx b/sd/source/ui/inc/framework/PresentationFactory.hxx
index e63edf88a..140ce0f22 100755..100644
--- a/sd/source/ui/inc/framework/PresentationFactory.hxx
+++ b/sd/source/ui/inc/framework/PresentationFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,3 +115,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/PresentationModule.hxx b/sd/source/ui/inc/framework/PresentationModule.hxx
index 350019acc..064c4549d 100644
--- a/sd/source/ui/inc/framework/PresentationModule.hxx
+++ b/sd/source/ui/inc/framework/PresentationModule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,3 +46,5 @@ public:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/ResourceId.hxx b/sd/source/ui/inc/framework/ResourceId.hxx
index 30db09834..cfcf61d15 100755..100644
--- a/sd/source/ui/inc/framework/ResourceId.hxx
+++ b/sd/source/ui/inc/framework/ResourceId.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -242,3 +243,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/framework/ViewShellWrapper.hxx b/sd/source/ui/inc/framework/ViewShellWrapper.hxx
index 376219ff5..e2acb35a9 100755..100644
--- a/sd/source/ui/inc/framework/ViewShellWrapper.hxx
+++ b/sd/source/ui/inc/framework/ViewShellWrapper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -146,3 +147,5 @@ private:
} } // end of namespace sd::framework
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuarea.hxx b/sd/source/ui/inc/fuarea.hxx
index 4ced2de1b..afbe9b6a2 100644
--- a/sd/source/ui/inc/fuarea.hxx
+++ b/sd/source/ui/inc/fuarea.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fubullet.hxx b/sd/source/ui/inc/fubullet.hxx
index b72224d20..76108e903 100644
--- a/sd/source/ui/inc/fubullet.hxx
+++ b/sd/source/ui/inc/fubullet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuchar.hxx b/sd/source/ui/inc/fuchar.hxx
index 03ec4a0b6..fc02994de 100644
--- a/sd/source/ui/inc/fuchar.hxx
+++ b/sd/source/ui/inc/fuchar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fucon3d.hxx b/sd/source/ui/inc/fucon3d.hxx
index 60c307792..ee86247ef 100755..100644
--- a/sd/source/ui/inc/fucon3d.hxx
+++ b/sd/source/ui/inc/fucon3d.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,7 +56,6 @@ public:
virtual void Activate(); // Function aktivieren
virtual void Deactivate(); // Function deaktivieren
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
private:
@@ -66,7 +66,6 @@ private:
SdDrawDocument* pDoc,
SfxRequest& rReq);
- // #97016#
void ImpPrepareBasic3DShape(E3dCompoundObject* p3DObj, E3dScene *pScene);
E3dCompoundObject* ImpCreateBasic3DShape();
};
@@ -75,3 +74,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconarc.hxx b/sd/source/ui/inc/fuconarc.hxx
index 5bc4514ca..e0cddab1c 100755..100644
--- a/sd/source/ui/inc/fuconarc.hxx
+++ b/sd/source/ui/inc/fuconarc.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,7 +52,6 @@ public:
virtual void Activate(); // Function aktivieren
virtual void Deactivate(); // Function deaktivieren
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
protected:
@@ -68,3 +68,4 @@ protected:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconbez.hxx b/sd/source/ui/inc/fuconbez.hxx
index 5e28028f6..f68b726f6 100755..100644
--- a/sd/source/ui/inc/fuconbez.hxx
+++ b/sd/source/ui/inc/fuconbez.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,7 +64,6 @@ public:
void SetEditMode(sal_uInt16 nMode);
sal_uInt16 GetEditMode() { return nEditMode; }
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
protected:
@@ -83,3 +83,4 @@ protected:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconcs.hxx b/sd/source/ui/inc/fuconcs.hxx
index e9b52f21c..bf3069ca6 100755..100644
--- a/sd/source/ui/inc/fuconcs.hxx
+++ b/sd/source/ui/inc/fuconcs.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,7 +64,6 @@ public:
void SetAttributes( SdrObject* pObj );
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
// #i33136#
@@ -85,3 +85,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconnct.hxx b/sd/source/ui/inc/fuconnct.hxx
index ef8e5ffa5..0f923cd86 100644
--- a/sd/source/ui/inc/fuconnct.hxx
+++ b/sd/source/ui/inc/fuconnct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconrec.hxx b/sd/source/ui/inc/fuconrec.hxx
index 79e9b05fb..616c8b8b1 100755..100644
--- a/sd/source/ui/inc/fuconrec.hxx
+++ b/sd/source/ui/inc/fuconrec.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,7 +66,6 @@ public:
void SetAttributes(SfxItemSet& rAttr, SdrObject* pObj);
void SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj);
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
protected:
@@ -82,3 +82,4 @@ protected:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconstr.hxx b/sd/source/ui/inc/fuconstr.hxx
index a79108b68..f2aed7bce 100755..100644
--- a/sd/source/ui/inc/fuconstr.hxx
+++ b/sd/source/ui/inc/fuconstr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,3 +86,5 @@ protected:
} // end of namespace sd
#endif // _SD_FUCONSTR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuconuno.hxx b/sd/source/ui/inc/fuconuno.hxx
index d652752e6..7086c013e 100755..100644
--- a/sd/source/ui/inc/fuconuno.hxx
+++ b/sd/source/ui/inc/fuconuno.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,7 +58,6 @@ public:
virtual void Activate(); // Function aktivieren
virtual void Deactivate(); // Function deaktivieren
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
protected:
@@ -79,3 +79,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fucopy.hxx b/sd/source/ui/inc/fucopy.hxx
index ac9b76331..2b244ef9b 100644
--- a/sd/source/ui/inc/fucopy.hxx
+++ b/sd/source/ui/inc/fucopy.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fucushow.hxx b/sd/source/ui/inc/fucushow.hxx
index 3681a83c5..783d755ef 100644
--- a/sd/source/ui/inc/fucushow.hxx
+++ b/sd/source/ui/inc/fucushow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fudraw.hxx b/sd/source/ui/inc/fudraw.hxx
index 5e9115677..4baec8895 100755..100644
--- a/sd/source/ui/inc/fudraw.hxx
+++ b/sd/source/ui/inc/fudraw.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef SD_FU_DRAW_HXX
#define SD_FU_DRAW_HXX
-#ifndef _SV_POINTR_HXX //autogen
#include <vcl/pointr.hxx>
-#endif
#include "fupoor.hxx"
struct SdrViewEvent;
@@ -100,3 +99,5 @@ protected:
} // end of namespace sd
#endif // _SD_FUDRAW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fudspord.hxx b/sd/source/ui/inc/fudspord.hxx
index 110b4ef14..3a2ad314d 100755..100644
--- a/sd/source/ui/inc/fudspord.hxx
+++ b/sd/source/ui/inc/fudspord.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,4 @@ private:
#endif // _SD_FUDSPORD_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuediglu.hxx b/sd/source/ui/inc/fuediglu.hxx
index 4b785fa23..959a3f4af 100755..100644
--- a/sd/source/ui/inc/fuediglu.hxx
+++ b/sd/source/ui/inc/fuediglu.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,3 +73,4 @@ protected:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuexpand.hxx b/sd/source/ui/inc/fuexpand.hxx
index 651f28f01..fb37e32a6 100644
--- a/sd/source/ui/inc/fuexpand.hxx
+++ b/sd/source/ui/inc/fuexpand.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuformatpaintbrush.hxx b/sd/source/ui/inc/fuformatpaintbrush.hxx
index c1fefb0d4..81900f88a 100755..100644
--- a/sd/source/ui/inc/fuformatpaintbrush.hxx
+++ b/sd/source/ui/inc/fuformatpaintbrush.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fugrid.hxx b/sd/source/ui/inc/fugrid.hxx
index 547f16610..4e21704f4 100644
--- a/sd/source/ui/inc/fugrid.hxx
+++ b/sd/source/ui/inc/fugrid.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuhhconv.hxx b/sd/source/ui/inc/fuhhconv.hxx
index 906864a82..b01f89fae 100755..100644
--- a/sd/source/ui/inc/fuhhconv.hxx
+++ b/sd/source/ui/inc/fuhhconv.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _SD_FUHHCONV_HXX
#define _SD_FUHHCONV_HXX
-#ifndef _SD_FUPOOR_HXX
#include "fupoor.hxx"
-#endif
namespace sd {
@@ -73,3 +72,5 @@ private:
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuinsert.hxx b/sd/source/ui/inc/fuinsert.hxx
index 1cdc88047..e54f7d42c 100644
--- a/sd/source/ui/inc/fuinsert.hxx
+++ b/sd/source/ui/inc/fuinsert.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117,3 +118,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuinsfil.hxx b/sd/source/ui/inc/fuinsfil.hxx
index 5ea04fafc..44069f8b5 100755..100644
--- a/sd/source/ui/inc/fuinsfil.hxx
+++ b/sd/source/ui/inc/fuinsfil.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,3 +69,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuline.hxx b/sd/source/ui/inc/fuline.hxx
index 35ab1d32b..936357e69 100644
--- a/sd/source/ui/inc/fuline.hxx
+++ b/sd/source/ui/inc/fuline.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fulinend.hxx b/sd/source/ui/inc/fulinend.hxx
index 0aab63ee7..cda6c5c49 100644
--- a/sd/source/ui/inc/fulinend.hxx
+++ b/sd/source/ui/inc/fulinend.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fulink.hxx b/sd/source/ui/inc/fulink.hxx
index 70a8cc1c6..aa675b338 100644
--- a/sd/source/ui/inc/fulink.hxx
+++ b/sd/source/ui/inc/fulink.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fumeasur.hxx b/sd/source/ui/inc/fumeasur.hxx
index 88697d163..7781429d0 100644
--- a/sd/source/ui/inc/fumeasur.hxx
+++ b/sd/source/ui/inc/fumeasur.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fumorph.hxx b/sd/source/ui/inc/fumorph.hxx
index a06259de3..7c060bc3f 100755..100644
--- a/sd/source/ui/inc/fumorph.hxx
+++ b/sd/source/ui/inc/fumorph.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,6 @@
#include <math.h>
-/*************************************************************************
-|*
-\************************************************************************/
class List;
namespace basegfx {
class B2DPolyPolygon;
@@ -78,3 +76,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuoaprms.hxx b/sd/source/ui/inc/fuoaprms.hxx
index 33628b062..2728e2339 100644
--- a/sd/source/ui/inc/fuoaprms.hxx
+++ b/sd/source/ui/inc/fuoaprms.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ private:
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuolbull.hxx b/sd/source/ui/inc/fuolbull.hxx
index 720bfefe6..06c395570 100644
--- a/sd/source/ui/inc/fuolbull.hxx
+++ b/sd/source/ui/inc/fuolbull.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuoltext.hxx b/sd/source/ui/inc/fuoltext.hxx
index bcf266106..f450c6d79 100755..100644
--- a/sd/source/ui/inc/fuoltext.hxx
+++ b/sd/source/ui/inc/fuoltext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuoutl.hxx b/sd/source/ui/inc/fuoutl.hxx
index bc570c385..62ff60859 100755..100644
--- a/sd/source/ui/inc/fuoutl.hxx
+++ b/sd/source/ui/inc/fuoutl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fupage.hxx b/sd/source/ui/inc/fupage.hxx
index 3be210876..eaf7a8929 100755..100644
--- a/sd/source/ui/inc/fupage.hxx
+++ b/sd/source/ui/inc/fupage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79,3 +80,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuparagr.hxx b/sd/source/ui/inc/fuparagr.hxx
index 9ef985446..284eb8964 100644
--- a/sd/source/ui/inc/fuparagr.hxx
+++ b/sd/source/ui/inc/fuparagr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fupoor.hxx b/sd/source/ui/inc/fupoor.hxx
index ffa261d57..22bd0cfbf 100755..100644
--- a/sd/source/ui/inc/fupoor.hxx
+++ b/sd/source/ui/inc/fupoor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,9 +36,7 @@
#include <vcl/event.hxx>
#include <rtl/ref.hxx>
-#ifndef _SALHELPER_SIMPLEREFERENCECOMPONENT_HXX_
#include "helper/simplereferencecomponent.hxx"
-#endif
class SdDrawDocument;
class SfxRequest;
@@ -67,7 +66,6 @@ public:
virtual void DoExecute( SfxRequest& rReq );
- // #95491# see member
void SetMouseButtonCode(sal_uInt16 nNew) { if(nNew != mnCode) mnCode = nNew; }
sal_uInt16 GetMouseButtonCode() const { return mnCode; }
@@ -83,7 +81,7 @@ public:
virtual sal_Bool MouseMove(const MouseEvent& );
virtual sal_Bool MouseButtonUp(const MouseEvent& rMEvt);
- // #95491# moved from inline to *.cxx
+ // moved from inline to *.cxx
virtual sal_Bool MouseButtonDown(const MouseEvent& rMEvt);
virtual sal_Bool Command(const CommandEvent& rCEvt);
@@ -99,7 +97,6 @@ public:
void SetWindow(::sd::Window* pWin) { mpWindow = pWin; }
- // #97016# II
virtual void SelectionHasChanged();
sal_uInt16 GetSlotID() const { return( nSlotId ); }
@@ -110,7 +107,6 @@ public:
void StartDelayToScrollTimer ();
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
/** is called when the currenct function should be aborted. <p>
@@ -196,7 +192,7 @@ protected:
sal_Bool bDelayActive;
sal_Bool bFirstMouseMove;
- // #95491# member to hold state of the mouse buttons for creation
+ // member to hold state of the mouse buttons for creation
// of own MouseEvents (like in ScrollHdl)
private:
@@ -210,3 +206,4 @@ typedef rtl::Reference< FuPoor > FunctionReference;
#endif // _SD_FUPOOR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuprlout.hxx b/sd/source/ui/inc/fuprlout.hxx
index a2a3fa253..6b89b96b1 100644
--- a/sd/source/ui/inc/fuprlout.hxx
+++ b/sd/source/ui/inc/fuprlout.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,3 +63,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuprobjs.hxx b/sd/source/ui/inc/fuprobjs.hxx
index 1e9f1b201..4eba956f3 100644
--- a/sd/source/ui/inc/fuprobjs.hxx
+++ b/sd/source/ui/inc/fuprobjs.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,3 +63,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuscale.hxx b/sd/source/ui/inc/fuscale.hxx
index 973dee7d4..325aa0ccd 100644
--- a/sd/source/ui/inc/fuscale.hxx
+++ b/sd/source/ui/inc/fuscale.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fusearch.hxx b/sd/source/ui/inc/fusearch.hxx
index c4073c97e..e5ad6de78 100755..100644
--- a/sd/source/ui/inc/fusearch.hxx
+++ b/sd/source/ui/inc/fusearch.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fusel.hxx b/sd/source/ui/inc/fusel.hxx
index 4d17649ea..e9b805768 100755..100644
--- a/sd/source/ui/inc/fusel.hxx
+++ b/sd/source/ui/inc/fusel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -110,3 +111,4 @@ private:
#endif // _SD_FUSEL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fusldlg.hxx b/sd/source/ui/inc/fusldlg.hxx
index 72e9d6e89..4342058b5 100644
--- a/sd/source/ui/inc/fusldlg.hxx
+++ b/sd/source/ui/inc/fusldlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuslhide.hxx b/sd/source/ui/inc/fuslhide.hxx
deleted file mode 100644
index 8a1ebc74c..000000000
--- a/sd/source/ui/inc/fuslhide.hxx
+++ /dev/null
@@ -1,63 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_FU_SLIDE_HIDE_HXX
-#define SD_FU_SLIDE_HIDE_HXX
-
-#include "fuslid.hxx"
-
-namespace sd {
-
-/*************************************************************************
-|*
-|* selektierte Dias in der Show zeigen / nicht zeigen
-|*
-\************************************************************************/
-
-class FuSlideHide
- : public FuSlide
-{
-public:
- TYPEINFO();
-
- static FunctionReference Create( SlideViewShell* pViewSh, ::sd::Window* pWin, SlideView* pView, SdDrawDocument* pDoc, SfxRequest& rReq );
- virtual void DoExecute( SfxRequest& rReq );
-
-protected:
- FuSlideHide (
- ViewShell* pViewSh,
- ::sd::Window* pWin,
- ::sd::View* pView,
- SdDrawDocument* pDoc,
- SfxRequest& rReq);
- virtual ~FuSlideHide (void);
-};
-
-} // end of namespace sd
-
-#endif
-
diff --git a/sd/source/ui/inc/fuslid.hxx b/sd/source/ui/inc/fuslid.hxx
deleted file mode 100755
index 6d1d85bc9..000000000
--- a/sd/source/ui/inc/fuslid.hxx
+++ /dev/null
@@ -1,77 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_FU_SLIDE_HXX
-#define SD_FU_SLIDE_HXX
-
-#include "fupoor.hxx"
-
-class SdDrawDocument;
-
-namespace sd {
-
-class SlideView;
-class SlideViewShell;
-class Window;
-
-
-/*************************************************************************
-|*
-|* Basisklasse der Funktionen des Diamodus
-|*
-\************************************************************************/
-
-class FuSlide
- : public FuPoor
-{
-public:
- TYPEINFO();
-
- static FunctionReference Create( SlideViewShell* pViewSh, ::sd::Window* pWin, SlideView* pView, SdDrawDocument* pDoc, SfxRequest& rReq );
-
- virtual sal_Bool MouseMove(const MouseEvent& rMEvt);
- virtual sal_Bool MouseButtonUp(const MouseEvent& rMEvt);
- virtual sal_Bool MouseButtonDown(const MouseEvent& rMEvt);
-
- virtual void ScrollStart();
- virtual void ScrollEnd();
-
-protected:
- FuSlide (
- SlideViewShell* pViewSh,
- ::sd::Window* pWin,
- SlideView* pView,
- SdDrawDocument* pDoc,
- SfxRequest& rReq);
-
- SlideViewShell* pSlViewShell;
- SlideView* pSlView;
-};
-
-} // end of namespace sd
-
-#endif
diff --git a/sd/source/ui/inc/fuslsel.hxx b/sd/source/ui/inc/fuslsel.hxx
deleted file mode 100755
index cb6fa0198..000000000
--- a/sd/source/ui/inc/fuslsel.hxx
+++ /dev/null
@@ -1,120 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SD_FU_SLIDE_SELECTION_HXX
-#define SD_FU_SLIDE_SELECTION_HXX
-
-#include "fuslid.hxx"
-#include <tools/list.hxx>
-
-class SdDrawDocument;
-class Sound;
-
-namespace sd {
-
-class SlideView;
-class SlideViewShell;
-class Window;
-
-struct FSS_IsShowingEffectInfo
-{
- sal_Bool bIsShowingEffect; // sal_True while we show a fade effect one the slide view
- sal_Bool bDisposed; // sal_True if the FuSlideSelection was deleted during fade effect
-};
-
-
-class FuSlideSelection
- : public FuSlide
-{
-public:
- TYPEINFO();
-
- static FunctionReference Create( SlideViewShell* pViewSh, ::sd::Window* pWin, SlideView* pView, SdDrawDocument* pDoc, SfxRequest& rReq );
- virtual void DoExecute( SfxRequest& rReq );
-
- // Mouse- & Key-Events
- virtual sal_Bool KeyInput(const KeyEvent& rKEvt);
- virtual sal_Bool MouseMove(const MouseEvent& rMEvt);
- virtual sal_Bool MouseButtonUp(const MouseEvent& rMEvt);
- virtual sal_Bool MouseButtonDown(const MouseEvent& rMEvt);
- virtual void Paint(const Rectangle& rRect, ::sd::Window* pWin);
-
- virtual void Activate(); // Function aktivieren
- virtual void Deactivate(); // Function deaktivieren
-
- virtual void ScrollStart();
- virtual void ScrollEnd();
-
- sal_Bool IsShowingEffect() const { return pIsShowingEffectInfo && pIsShowingEffectInfo->bIsShowingEffect; }
-
- /** is called when the currenct function should be aborted. <p>
- This is used when a function gets a KEY_ESCAPE but can also
- be called directly.
-
- @returns true if a active function was aborted
- */
- virtual bool cancel();
-
-protected:
- FuSlideSelection (
- SlideViewShell* pViewSh,
- ::sd::Window* pWin,
- SlideView* pView,
- SdDrawDocument* pDoc,
- SfxRequest& rReq);
- virtual ~FuSlideSelection (void);
-
-private:
- sal_Bool bSubstShown;
- sal_Bool bPageHit;
- List aSubstList; // Liste mit Ertsatzdarstellungen
- Point aDragPos; // hier wird die Seite angefasst
- sal_Bool bDragSelection;
- Point aDragSelRectAnchor; // fester Punkt des Selektionsrechtecks
- Rectangle aDragSelRect;
- Point aPosOfInsertMarker;
- FSS_IsShowingEffectInfo* pIsShowingEffectInfo;
-
- void DrawInsertMarker(sal_Bool bShow);
- Point CalcPosOfInsertMarker(const Point& rPoint);
-
- sal_uInt16 GetTargetPage(const Point& rPoint) const;
-
- void CreateSubst();
- void DeleteSubst();
- void DrawSubst() const;
- void ChangeSubstPos(const Point& rVector);
- void DrawDragSelectionRect() const;
- void ShowEffect(sal_uInt16 nPageNo);
-
- DECL_LINK( DragSlideHdl, Timer* );
-};
-
-} // end of namespace sd
-
-#endif
-
diff --git a/sd/source/ui/inc/fusnapln.hxx b/sd/source/ui/inc/fusnapln.hxx
index 383988f4a..ec677511b 100644
--- a/sd/source/ui/inc/fusnapln.hxx
+++ b/sd/source/ui/inc/fusnapln.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fusumry.hxx b/sd/source/ui/inc/fusumry.hxx
index f9a7a5572..dc868acbb 100644
--- a/sd/source/ui/inc/fusumry.hxx
+++ b/sd/source/ui/inc/fusumry.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/futempl.hxx b/sd/source/ui/inc/futempl.hxx
index 8f9a44e09..91e78d33b 100644
--- a/sd/source/ui/inc/futempl.hxx
+++ b/sd/source/ui/inc/futempl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/futext.hxx b/sd/source/ui/inc/futext.hxx
index 8c48ad230..ea5b3091f 100755..100644
--- a/sd/source/ui/inc/futext.hxx
+++ b/sd/source/ui/inc/futext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef SD_FU_TEXT_HXX
#define SD_FU_TEXT_HXX
-#ifndef _EDITDATA_HXX
#include <editeng/editdata.hxx>
-#endif
#include "fuconstr.hxx"
#include <svx/svdotext.hxx>
@@ -75,7 +74,6 @@ public:
DECL_LINK(SpellError, void* );
- // #97016#
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle);
/** is called when the currenct function should be aborted. <p>
@@ -104,7 +102,6 @@ protected:
SfxRequest& rRequest;
private:
- // #97016#
void ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj);
void ImpSetAttributesFitToSize(SdrTextObj* pTxtObj);
void ImpSetAttributesFitToSizeVertical(SdrTextObj* pTxtObj);
@@ -114,3 +111,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/futhes.hxx b/sd/source/ui/inc/futhes.hxx
index e243898ed..8c46681a4 100644
--- a/sd/source/ui/inc/futhes.hxx
+++ b/sd/source/ui/inc/futhes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/futransf.hxx b/sd/source/ui/inc/futransf.hxx
index 9fe7c37ee..8e2a22813 100755..100644
--- a/sd/source/ui/inc/futransf.hxx
+++ b/sd/source/ui/inc/futransf.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef SD_FU_TRANSFORM_HXX
#define SD_FU_TRANSFORM_HXX
-#ifndef _SVX_RETENUM_HXX
#include <svx/rectenum.hxx>
-#endif
#include "fupoor.hxx"
namespace sd {
@@ -57,3 +56,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/futxtatt.hxx b/sd/source/ui/inc/futxtatt.hxx
index ea1cc6f6f..a8d2ac212 100644
--- a/sd/source/ui/inc/futxtatt.hxx
+++ b/sd/source/ui/inc/futxtatt.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuvect.hxx b/sd/source/ui/inc/fuvect.hxx
index fef49d813..7aa80e057 100644
--- a/sd/source/ui/inc/fuvect.hxx
+++ b/sd/source/ui/inc/fuvect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/fuzoom.hxx b/sd/source/ui/inc/fuzoom.hxx
index c4c74df4f..74f152eef 100755..100644
--- a/sd/source/ui/inc/fuzoom.hxx
+++ b/sd/source/ui/inc/fuzoom.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef SD_FU_ZOOM_HXX
#define SD_FU_ZOOM_HXX
-#ifndef _SV_POINTR_HXX //autogen
#include <vcl/pointr.hxx>
-#endif
#include "fupoor.hxx"
namespace sd {
@@ -77,3 +76,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/gluectrl.hxx b/sd/source/ui/inc/gluectrl.hxx
index d6bbcd720..9a81c9b08 100755..100644
--- a/sd/source/ui/inc/gluectrl.hxx
+++ b/sd/source/ui/inc/gluectrl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,4 @@ public:
#endif // SD_GLUECTRL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/headerfooterdlg.hxx b/sd/source/ui/inc/headerfooterdlg.hxx
index fedd33d5c..f49ebcd82 100755..100644
--- a/sd/source/ui/inc/headerfooterdlg.hxx
+++ b/sd/source/ui/inc/headerfooterdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#define _SD_HEADERFOOTER_DIALOG_HXX
#include <vcl/tabdlg.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/tabctrl.hxx>
#include <vcl/tabpage.hxx>
@@ -83,3 +82,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/ins_paste.hxx b/sd/source/ui/inc/ins_paste.hxx
index c68edd413..9c4d27ebf 100755..100644
--- a/sd/source/ui/inc/ins_paste.hxx
+++ b/sd/source/ui/inc/ins_paste.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,6 +29,8 @@
#ifndef _SD_INS_PASTE_HXX_
#define _SD_INS_PASTE_HXX_
+#include <sddllapi.h>
+
#include <vcl/button.hxx>
#include <vcl/fixed.hxx>
#include <vcl/dialog.hxx>
@@ -37,7 +40,7 @@
// - SdInsertPasteDlg -
// --------------------
-class SdInsertPasteDlg : public ModalDialog
+class SD_DLLPUBLIC SdInsertPasteDlg : public ModalDialog
{
private:
@@ -57,3 +60,5 @@ public:
};
#endif // _SD_INS_PASTE_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/inspagob.hxx b/sd/source/ui/inc/inspagob.hxx
index a96672bb3..c76fa6ed4 100755..100644
--- a/sd/source/ui/inc/inspagob.hxx
+++ b/sd/source/ui/inc/inspagob.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _SD_INSPAGOB_HXX
#define _SD_INSPAGOB_HXX
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/dialog.hxx>
#include "sdtreelb.hxx"
@@ -69,3 +68,5 @@ public:
#endif // _SD_INSPAGOB_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/layeroptionsdlg.hxx b/sd/source/ui/inc/layeroptionsdlg.hxx
index 81b7f86d9..38753d153 100644
--- a/sd/source/ui/inc/layeroptionsdlg.hxx
+++ b/sd/source/ui/inc/layeroptionsdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,6 +30,8 @@
#ifndef _SD_LAYER_DLG_HXX_
#define _SD_LAYER_DLG_HXX_
+#include <sddllapi.h>
+
#include <vcl/edit.hxx>
#include <vcl/fixed.hxx>
#include <vcl/dialog.hxx>
@@ -39,7 +42,7 @@
class SfxItemSet;
-class SdInsertLayerDlg : public ModalDialog
+class SD_DLLPUBLIC SdInsertLayerDlg : public ModalDialog
{
private:
FixedText maFtName;
@@ -65,3 +68,5 @@ public:
};
#endif // _SD_LAYER_DLG_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/masterlayoutdlg.hxx b/sd/source/ui/inc/masterlayoutdlg.hxx
index f9ed5b2b3..f9d0d637d 100755..100644
--- a/sd/source/ui/inc/masterlayoutdlg.hxx
+++ b/sd/source/ui/inc/masterlayoutdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#include <vcl/dialog.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/fixed.hxx>
#include "sdpage.hxx"
@@ -76,3 +75,4 @@ public:
#endif // _SD_MASTERLAYOUT_DIALOG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/morphdlg.hxx b/sd/source/ui/inc/morphdlg.hxx
index a193cca94..2d398dfe2 100755..100644
--- a/sd/source/ui/inc/morphdlg.hxx
+++ b/sd/source/ui/inc/morphdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,12 +39,6 @@ class SdrObject;
namespace sd {
-/******************************************************************************
-|*
-|*
-|*
-\******************************************************************************/
-
class MorphDlg
: public ModalDialog
{
@@ -79,3 +74,5 @@ private:
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/navigatr.hrc b/sd/source/ui/inc/navigatr.hrc
index a4d862290..b1e81ae90 100755
--- a/sd/source/ui/inc/navigatr.hrc
+++ b/sd/source/ui/inc/navigatr.hrc
@@ -43,7 +43,6 @@
#define LB_DOCS 1
#define IL_NAVIGATR 333
-#define ILH_NAVIGATR 444
//IAccessibility2 Implementation 2009-----
#define STR_DRAGMODE 1
//-----IAccessibility2 Implementation 2009
diff --git a/sd/source/ui/inc/navigatr.hxx b/sd/source/ui/inc/navigatr.hxx
index 072a5828d..6ea8cc597 100755..100644
--- a/sd/source/ui/inc/navigatr.hxx
+++ b/sd/source/ui/inc/navigatr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <vcl/window.hxx>
#include <vcl/lstbox.hxx>
-#ifndef _TOOLBOX_HXX //autogen
#include <vcl/toolbox.hxx>
-#endif
#include <sfx2/ctrlitem.hxx>
#include "sdtreelb.hxx"
#include "pres.hxx"
@@ -126,17 +125,15 @@ private:
::sd::NavigatorChildWindow* mpChildWinContext;
Size maSize;
Size maMinSize;
-// Size maFltWinSize;
sal_Bool mbDocImported;
String maDropFileName;
NavigatorDragType meDragType;
- List* mpDocList;
+ std::vector<NavDocInfo> maDocList;
SfxBindings* mpBindings;
SdNavigatorControllerItem* mpNavigatorCtrlItem;
SdPageNameControllerItem* mpPageNameCtrlItem;
ImageList maImageList;
- ImageList maImageListH;
/** This flag controls whether all shapes or only the named shapes are
shown.
@@ -205,3 +202,5 @@ private:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/optdlg.hxx b/sd/source/ui/inc/optdlg.hxx
index 43f4f27b8..24c2b5b61 100755..100644
--- a/sd/source/ui/inc/optdlg.hxx
+++ b/sd/source/ui/inc/optdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,7 +48,6 @@ public:
protected:
virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage );
-// virtual SfxItemSet* CreateInputItemSet( sal_uInt16 nPageId );
};
@@ -55,3 +55,4 @@ protected:
#endif // SD_OPTDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/optsitem.hxx b/sd/source/ui/inc/optsitem.hxx
index 608b36754..4301b5d3e 100755..100644
--- a/sd/source/ui/inc/optsitem.hxx
+++ b/sd/source/ui/inc/optsitem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -145,11 +146,11 @@ class SD_DLLPUBLIC SdOptionsLayout : public SdOptionsGeneric
{
private:
- sal_Bool bRuler : 1; // Layout/Display/Ruler
- sal_Bool bMoveOutline : 1; // Layout/Display/Contur
- sal_Bool bDragStripes : 1; // Layout/Display/Guide
- sal_Bool bHandlesBezier : 1; // Layout/Display/Bezier
- sal_Bool bHelplines : 1; // Layout/Display/Helpline
+ sal_Bool bRuler; // Layout/Display/Ruler
+ sal_Bool bMoveOutline; // Layout/Display/Contur
+ sal_Bool bDragStripes; // Layout/Display/Guide
+ sal_Bool bHandlesBezier; // Layout/Display/Bezier
+ sal_Bool bHelplines; // Layout/Display/Helpline
sal_uInt16 nMetric; // Layout/Other/MeasureUnit
sal_uInt16 nDefTab; // Layout/Other/TabStop
@@ -248,7 +249,6 @@ class SD_DLLPUBLIC SdOptionsMisc : public SdOptionsGeneric
{
private:
- // #97016#
sal_uLong nDefaultObjectSizeWidth;
sal_uLong nDefaultObjectSizeHeight;
@@ -267,7 +267,6 @@ private:
sal_Bool bSolidDragging : 1; // Misc/ModifyWithAttributes
sal_Bool bSolidMarkHdl : 1; // /Misc/SimpleHandles
sal_Bool bSummationOfParagraphs : 1; // misc/SummationOfParagraphs
- // #90356#
sal_Bool bShowUndoDeleteWarning : 1; // Misc/ShowUndoDeleteWarning
// #i75315#
sal_Bool bSlideshowRespectZOrder : 1; // Misc/SlideshowRespectZOrder
@@ -325,10 +324,8 @@ public:
is disabled. Other values are reserved for future use.
*/
sal_uInt16 GetPrinterIndependentLayout() const { Init(); return mnPrinterIndependentLayout; };
- // #90356#
sal_Bool IsShowUndoDeleteWarning() const { Init(); return (sal_Bool) bShowUndoDeleteWarning; }
sal_Bool IsSlideshowRespectZOrder() const { Init(); return (sal_Bool) bSlideshowRespectZOrder; }
- // #97016#
sal_uLong GetDefaultObjectSizeWidth() const { Init(); return nDefaultObjectSizeWidth; }
sal_uLong GetDefaultObjectSizeHeight() const { Init(); return nDefaultObjectSizeHeight; }
@@ -367,10 +364,8 @@ public:
void SetPrinterIndependentLayout (sal_uInt16 nOn = 1 ){ if ( nOn != mnPrinterIndependentLayout ) { OptionsChanged(); mnPrinterIndependentLayout = nOn; } }
void SetSolidDragging( sal_Bool bOn = sal_True ) { if( bSolidDragging != bOn ) { OptionsChanged(); bSolidDragging = bOn; } }
void SetSolidMarkHdl( sal_Bool bOn = sal_True ) { if( bSolidMarkHdl != bOn ) { OptionsChanged(); bSolidMarkHdl = bOn; } }
- // #90356#
void SetShowUndoDeleteWarning( sal_Bool bOn = sal_True ) { if( bShowUndoDeleteWarning != bOn ) { OptionsChanged(); bShowUndoDeleteWarning = bOn; } }
void SetSlideshowRespectZOrder( sal_Bool bOn = sal_True ) { if( bSlideshowRespectZOrder != bOn ) { OptionsChanged(); bSlideshowRespectZOrder = bOn; } }
- // #97016#
void SetDefaultObjectSizeWidth( sal_uLong nWidth ) { if( nDefaultObjectSizeWidth != nWidth ) { OptionsChanged(); nDefaultObjectSizeWidth = nWidth; } }
void SetDefaultObjectSizeHeight( sal_uLong nHeight ) { if( nDefaultObjectSizeHeight != nHeight ) { OptionsChanged(); nDefaultObjectSizeHeight = nHeight; } }
@@ -686,3 +681,5 @@ public:
};
#endif // _SD_OPTSITEM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/paragr.hxx b/sd/source/ui/inc/paragr.hxx
index 89333d8d7..b93fb7d9b 100644
--- a/sd/source/ui/inc/paragr.hxx
+++ b/sd/source/ui/inc/paragr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,6 +44,8 @@ class SdParagraphDlg : public SfxTabDialog
private:
const SfxItemSet& rOutAttrs;
+ virtual void PageCreated( sal_uInt16 nId, SfxTabPage &rPage );
+
public:
SdParagraphDlg( Window* pParent, const SfxItemSet* pAttr );
~SdParagraphDlg() {};
@@ -51,3 +54,4 @@ public:
#endif // _SD_PARAGR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/pgjump.hxx b/sd/source/ui/inc/pgjump.hxx
index ba8821a6c..a906a8c39 100644
--- a/sd/source/ui/inc/pgjump.hxx
+++ b/sd/source/ui/inc/pgjump.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,3 +42,4 @@ enum PageJump
#endif // _SD_PGJUMP_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/present.hxx b/sd/source/ui/inc/present.hxx
index bb26c2c03..6069edcde 100644
--- a/sd/source/ui/inc/present.hxx
+++ b/sd/source/ui/inc/present.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,22 +30,12 @@
#ifndef _SD_PRESENT_HXX_
#define _SD_PRESENT_HXX_
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
#include <vcl/fixed.hxx>
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
class SfxItemSet;
class List;
@@ -112,3 +103,4 @@ public:
#endif // _SD_PRESENT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/prltempl.hxx b/sd/source/ui/inc/prltempl.hxx
index fad757b86..2b8da55ee 100755..100644
--- a/sd/source/ui/inc/prltempl.hxx
+++ b/sd/source/ui/inc/prltempl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#ifndef SD_PRLTEMPL_HXX
#define SD_PRLTEMPL_HXX
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include <sfx2/tabdlg.hxx>
#include <svx/tabarea.hxx>
@@ -99,3 +98,4 @@ public:
#endif // SD_PRLTEMPL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/prntopts.hxx b/sd/source/ui/inc/prntopts.hxx
index 73d3063b0..4d283a7ce 100755..100644
--- a/sd/source/ui/inc/prntopts.hxx
+++ b/sd/source/ui/inc/prntopts.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include <vcl/group.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <sfx2/tabdlg.hxx>
#include <vcl/fixed.hxx>
@@ -107,3 +106,4 @@ public:
#endif // _SD_PRNTOPTS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/pubdlg.hxx b/sd/source/ui/inc/pubdlg.hxx
index d236b2ce7..6cc693ee9 100755..100644
--- a/sd/source/ui/inc/pubdlg.hxx
+++ b/sd/source/ui/inc/pubdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,26 +31,17 @@
#include <com/sun/star/beans/PropertyValue.hpp>
#include <vcl/fixed.hxx>
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
#include "resltn.hxx" // enum PublishingResolution
#include "pres.hxx"
#include "assclass.hxx"
#include <boost/scoped_ptr.hpp>
+#include <boost/ptr_container/ptr_vector.hpp>
#define NOOFPAGES 6
@@ -65,7 +57,6 @@ class Edit;
class MultiLineEdit;
class ValueSet;
class SdHtmlAttrPreview;
-class List;
class SdPublishingDesign;
class ButtonSet;
@@ -147,7 +138,6 @@ private:
FixedText* pPage4_Titel2;
MultiLineEdit* pPage4_Misc;
CheckBox* pPage4_Download;
-//-/ CheckBox* pPage4_Created;
// page 5 controls
@@ -172,8 +162,6 @@ private:
boost::scoped_ptr< ButtonSet > mpButtonSet;
-// CheckBox* pPage6_Sound;
-
// standard controls
FixedLine aBottomLine;
HelpButton aHelpButton;
@@ -197,7 +185,7 @@ private:
void ChangePage();
void UpdatePage();
- List* m_pDesignList;
+ boost::ptr_vector<SdPublishingDesign> m_aDesignList;
sal_Bool m_bDesignListDirty;
SdPublishingDesign* m_pDesign;
sal_Bool Load();
@@ -233,3 +221,5 @@ public:
};
#endif // _SD_PUBDLG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/res_bmp.hrc b/sd/source/ui/inc/res_bmp.hrc
index c8dd81d98..d51a79c1d 100755
--- a/sd/source/ui/inc/res_bmp.hrc
+++ b/sd/source/ui/inc/res_bmp.hrc
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -138,78 +138,41 @@
#define BMP_EFFECT_UNCOVER_TO_B RID_APP_START+171
#define BMP_EFFECT_UNCOVER_TO_LL RID_APP_START+172
-#define BMP_PAGE_H RID_SD_START+213
-#define BMP_PAGEOBJS_H RID_SD_START+214
-#define BMP_OBJECTS_H RID_SD_START+215
-#define BMP_DOC_OPEN_H RID_SD_START+216
-#define BMP_DOC_CLOSED_H RID_SD_START+217
-#define BMP_DOC_TEXT_H RID_SD_START+218
-#define BMP_OLE_H RID_SD_START+219
-#define BMP_PAGE_EXCLUDED_H RID_SD_START+220
-#define BMP_PAGEOBJS_EXCLUDED_H RID_SD_START+221
-#define BMP_EXPAND_H RID_SD_START+222
-#define BMP_COLLAPSE_H RID_SD_START+223
-#define BMP_GRAPHIC_H RID_SD_START+224
-
#define BMP_FOIL_NONE_H RID_SD_START+225
-#define BMP_GROUP_H RID_SD_START+226
#define BMP_WAIT_ICON_H RID_SD_START+229
#define BMP_FADE_EFFECT_INDICATOR RID_SD_START+331
-#define BMP_FADE_EFFECT_INDICATOR_H RID_SD_START+332
#define BMP_COMMENTS_INDICATOR RID_SD_START+338
-#define BMP_COMMENTS_INDICATOR_H RID_SD_START+339
#define BMP_LAYOUT_EMPTY RID_SD_START+340
-#define BMP_LAYOUT_EMPTY_H RID_SD_START+341
#define BMP_LAYOUT_HEAD01 RID_SD_START+342
-#define BMP_LAYOUT_HEAD01_H RID_SD_START+343
#define BMP_LAYOUT_HEAD02 RID_SD_START+344
-#define BMP_LAYOUT_HEAD02_H RID_SD_START+345
#define BMP_LAYOUT_HEAD02A RID_SD_START+346
-#define BMP_LAYOUT_HEAD02A_H RID_SD_START+347
#define BMP_LAYOUT_HEAD02B RID_SD_START+348
-#define BMP_LAYOUT_HEAD02B_H RID_SD_START+349
#define BMP_LAYOUT_HEAD03 RID_SD_START+350
-#define BMP_LAYOUT_HEAD03_H RID_SD_START+351
#define BMP_LAYOUT_HEAD03A RID_SD_START+352
-#define BMP_LAYOUT_HEAD03A_H RID_SD_START+353
#define BMP_LAYOUT_HEAD03B RID_SD_START+354
-#define BMP_LAYOUT_HEAD03B_H RID_SD_START+355
#define BMP_LAYOUT_HEAD03C RID_SD_START+356
-#define BMP_LAYOUT_HEAD03C_H RID_SD_START+357
#define BMP_LAYOUT_HEAD04 RID_SD_START+358
-#define BMP_LAYOUT_HEAD04_H RID_SD_START+359
#define BMP_LAYOUT_HEAD06 RID_SD_START+360
-#define BMP_LAYOUT_HEAD06_H RID_SD_START+361
#define BMP_LAYOUT_TEXTONLY RID_SD_START+362
-#define BMP_LAYOUT_TEXTONLY_H RID_SD_START+363
#define BMP_LAYOUT_VERTICAL01 RID_SD_START+364
-#define BMP_LAYOUT_VERTICAL01_H RID_SD_START+365
#define BMP_LAYOUT_VERTICAL02 RID_SD_START+366
-#define BMP_LAYOUT_VERTICAL02_H RID_SD_START+367
#define BMP_FOILH_01 RID_SD_START+388
-#define BMP_FOILH_01_H RID_SD_START+389
#define BMP_FOILH_02 RID_SD_START+390
-#define BMP_FOILH_02_H RID_SD_START+391
#define BMP_FOILH_03 RID_SD_START+392
-#define BMP_FOILH_03_H RID_SD_START+393
#define BMP_FOILH_04 RID_SD_START+394
-#define BMP_FOILH_04_H RID_SD_START+395
#define BMP_FOILH_06 RID_SD_START+396
-#define BMP_FOILH_06_H RID_SD_START+397
#define BMP_FOILH_09 RID_SD_START+398
-#define BMP_FOILH_09_H RID_SD_START+399
#define BMP_FOILN_01 RID_SD_START+400
-#define BMP_FOILN_01_H RID_SD_START+401
#define BMP_PLACEHOLDER_SMALL_START (RID_SD_START+402) // these ids must stay in order!
#define BMP_PLACEHOLDER_TABLE_SMALL (RID_SD_START+402)
#define BMP_PLACEHOLDER_CHART_SMALL (RID_SD_START+403)
-#define BMP_PLACEHOLDER_IMAGE_SMALL (RID_SD_START+404)
+#define BMP_PLACEHOLDER_IMAGE_SMALL (RID_SD_START+404)
#define BMP_PLACEHOLDER_MOVIE_SMALL (RID_SD_START+405)
#define BMP_PLACEHOLDER_TABLE_SMALL_HOVER (RID_SD_START+406)
#define BMP_PLACEHOLDER_CHART_SMALL_HOVER (RID_SD_START+407)
@@ -218,7 +181,7 @@
#define BMP_PLACEHOLDER_SMALL_END (RID_SD_START+410)
#define BMP_PLACEHOLDER_LARGE_START (RID_SD_START+410)
#define BMP_PLACEHOLDER_TABLE_LARGE (RID_SD_START+410)
-#define BMP_PLACEHOLDER_CHART_LARGE (RID_SD_START+411)
+#define BMP_PLACEHOLDER_CHART_LARGE (RID_SD_START+411)
#define BMP_PLACEHOLDER_IMAGE_LARGE (RID_SD_START+412)
#define BMP_PLACEHOLDER_MOVIE_LARGE (RID_SD_START+413)
#define BMP_PLACEHOLDER_TABLE_LARGE_HOVER (RID_SD_START+414)
@@ -229,12 +192,6 @@
// -----------------------------------------------------------------------------
-#define IMG_PIPETTE_H RID_APP_START+21
-#define IMG_GET1OBJECT_H RID_APP_START+22
-#define IMG_GETALLOBJECT_H RID_APP_START+23
-#define IMG_REMOVEBMP_H RID_APP_START+24
-#define IMG_REMOVEALLBMP_H RID_APP_START+25
-
/*
* ResourceIDs fuer Popup-Menues brauchen keinen Dummy-String !!!
*/
@@ -298,6 +255,9 @@
#define RID_DRAW_TABLEOBJ_INSIDE_POPUP RID_APP_START+94
+#define RID_DRAW_OUTLINETEXTOBJ_POPUP RID_APP_START+95
+#define RID_GRAPHIC_OUTLINETEXTOBJ_POPUP RID_APP_START+96
+
/*
* Pointer (Mauszeiger)
*/
diff --git a/sd/source/ui/inc/sdpopup.hxx b/sd/source/ui/inc/sdpopup.hxx
index f6160bd30..8e41835e6 100644
--- a/sd/source/ui/inc/sdpopup.hxx
+++ b/sd/source/ui/inc/sdpopup.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,3 +60,5 @@ public:
#endif // _SD_SDPOPUP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/sdpreslt.hxx b/sd/source/ui/inc/sdpreslt.hxx
index ee299ce6c..a1df1b625 100644
--- a/sd/source/ui/inc/sdpreslt.hxx
+++ b/sd/source/ui/inc/sdpreslt.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#define SD_PRES_LAYOUT_DLG_HXX
#include <vcl/dialog.hxx>
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <vcl/fixed.hxx>
#include <svtools/valueset.hxx>
@@ -87,3 +86,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/sdtreelb.hxx b/sd/source/ui/inc/sdtreelb.hxx
index f6207b5c1..e6c3420e1 100755..100644
--- a/sd/source/ui/inc/sdtreelb.hxx
+++ b/sd/source/ui/inc/sdtreelb.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -30,9 +31,7 @@
#include <svtools/transfer.hxx>
-#ifndef _SD_SDRESID_HXX
#include "sdresid.hxx"
-#endif
#include "pres.hxx"
#include "sddllapi.h"
#include <tools/string.hxx>
@@ -76,15 +75,15 @@ public:
class SdPageObjsTransferable : public SdTransferable
{
public:
- SdPageObjsTransferable(
- SdPageObjsTLB& rParent,
+ SdPageObjsTransferable(
+ SdPageObjsTLB& rParent,
const INetBookmark& rBookmark,
::sd::DrawDocShell& rDocShell,
NavigatorDragType eDragType,
const ::com::sun::star::uno::Any& rTreeListBoxData );
::sd::DrawDocShell& GetDocShell() const;
NavigatorDragType GetDragType() const;
-
+
static const ::com::sun::star::uno::Sequence< sal_Int8 >& getUnoTunnelId();
static SdPageObjsTransferable* getImplementation( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& rxData ) throw();
/** Return a temporary transferable data flavor that is used
@@ -136,8 +135,6 @@ protected:
SfxMedium* mpOwnMedium;
Image maImgOle;
Image maImgGraphic;
- Image maImgOleH;
- Image maImgGraphicH;
sal_Bool mbLinkableSelected;
sal_Bool mbDragEnabled;
String maDocName;
@@ -146,7 +143,7 @@ protected:
SdNavigatorWin* mpDropNavWin;
SfxViewFrame* mpFrame;
- // DragSourceHelper
+ // DragSourceHelper
virtual void StartDrag( sal_Int8 nAction, const Point& rPosPixel );
// DropTargetHelper
@@ -174,7 +171,7 @@ protected:
String GetObjectName (
const SdrObject* pObject,
const bool bCreate = true) const;
- void CloseBookmarkDoc();
+ void CloseBookmarkDoc();
DECL_STATIC_LINK(SdPageObjsTLB, ExecDragHdl, void*);
/** Handle the reordering of entries in the navigator. This method
@@ -270,3 +267,5 @@ private:
};
#endif // _SDTREELB_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/sdundogr.hxx b/sd/source/ui/inc/sdundogr.hxx
index 7dfbedc90..ea7c61709 100755..100644
--- a/sd/source/ui/inc/sdundogr.hxx
+++ b/sd/source/ui/inc/sdundogr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
};
#endif // _SD_SDUNDOGR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/sdxfer.hxx b/sd/source/ui/inc/sdxfer.hxx
index 0a8af25bc..89b3cbd87 100755..100644
--- a/sd/source/ui/inc/sdxfer.hxx
+++ b/sd/source/ui/inc/sdxfer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -136,3 +137,5 @@ private:
};
#endif // _SD_SDXFER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/slideshow.hxx b/sd/source/ui/inc/slideshow.hxx
index ac56511ea..50f715755 100755..100644
--- a/sd/source/ui/inc/slideshow.hxx
+++ b/sd/source/ui/inc/slideshow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -230,3 +231,5 @@ private:
}
#endif /* _SD_SLIDESHOW_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/smarttag.hxx b/sd/source/ui/inc/smarttag.hxx
index 5a9da8861..7c485b652 100755..100644
--- a/sd/source/ui/inc/smarttag.hxx
+++ b/sd/source/ui/inc/smarttag.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -186,3 +187,4 @@ protected:
#endif // _SD_SMARTTAG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/sprite.hxx b/sd/source/ui/inc/sprite.hxx
index d710789fc..68b17cd83 100755..100644
--- a/sd/source/ui/inc/sprite.hxx
+++ b/sd/source/ui/inc/sprite.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -86,3 +87,5 @@ protected:
}
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tabtempl.hxx b/sd/source/ui/inc/tabtempl.hxx
index c56aa125e..116ecb816 100755..100644
--- a/sd/source/ui/inc/tabtempl.hxx
+++ b/sd/source/ui/inc/tabtempl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -84,3 +85,4 @@ public:
#endif // SD_TABTEMPL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/ControlContainer.hxx b/sd/source/ui/inc/taskpane/ControlContainer.hxx
index b95461b12..c9db3b12c 100755..100644
--- a/sd/source/ui/inc/taskpane/ControlContainer.hxx
+++ b/sd/source/ui/inc/taskpane/ControlContainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -195,3 +196,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/ILayoutableWindow.hxx b/sd/source/ui/inc/taskpane/ILayoutableWindow.hxx
index 67f2986b7..7f0c9c5f6 100755..100644
--- a/sd/source/ui/inc/taskpane/ILayoutableWindow.hxx
+++ b/sd/source/ui/inc/taskpane/ILayoutableWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -100,3 +101,5 @@ public:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/PanelId.hxx b/sd/source/ui/inc/taskpane/PanelId.hxx
index 16f861ebc..204e0f506 100644
--- a/sd/source/ui/inc/taskpane/PanelId.hxx
+++ b/sd/source/ui/inc/taskpane/PanelId.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -60,3 +61,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
#endif // SD_UI_TASKPANE_PANELID_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/ScrollPanel.hxx b/sd/source/ui/inc/taskpane/ScrollPanel.hxx
index 432ed1fcf..ba152b184 100755..100644
--- a/sd/source/ui/inc/taskpane/ScrollPanel.hxx
+++ b/sd/source/ui/inc/taskpane/ScrollPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -183,3 +184,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/SlideSorterCacheDisplay.hxx b/sd/source/ui/inc/taskpane/SlideSorterCacheDisplay.hxx
index 8511e4a79..efc1c2fe7 100755..100644
--- a/sd/source/ui/inc/taskpane/SlideSorterCacheDisplay.hxx
+++ b/sd/source/ui/inc/taskpane/SlideSorterCacheDisplay.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -199,3 +200,5 @@ void SscdSetUpToDate (const SdrPage* pPage, bool bUpToDate)
#endif
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/SubToolPanel.hxx b/sd/source/ui/inc/taskpane/SubToolPanel.hxx
index 0bbd1c3a3..a92a439cd 100755..100644
--- a/sd/source/ui/inc/taskpane/SubToolPanel.hxx
+++ b/sd/source/ui/inc/taskpane/SubToolPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -132,3 +133,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/TaskPaneControlFactory.hxx b/sd/source/ui/inc/taskpane/TaskPaneControlFactory.hxx
index 6d16c0157..12f1d163f 100755..100644
--- a/sd/source/ui/inc/taskpane/TaskPaneControlFactory.hxx
+++ b/sd/source/ui/inc/taskpane/TaskPaneControlFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,3 +97,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/TaskPaneTreeNode.hxx b/sd/source/ui/inc/taskpane/TaskPaneTreeNode.hxx
index 0ac37bbf1..75d2d66e3 100755..100644
--- a/sd/source/ui/inc/taskpane/TaskPaneTreeNode.hxx
+++ b/sd/source/ui/inc/taskpane/TaskPaneTreeNode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -212,3 +213,5 @@ public:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/TitleBar.hxx b/sd/source/ui/inc/taskpane/TitleBar.hxx
index 99f47f9a1..3c3dedf26 100755..100644
--- a/sd/source/ui/inc/taskpane/TitleBar.hxx
+++ b/sd/source/ui/inc/taskpane/TitleBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -167,3 +168,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/TitledControl.hxx b/sd/source/ui/inc/taskpane/TitledControl.hxx
index 635133331..35902469f 100755..100644
--- a/sd/source/ui/inc/taskpane/TitledControl.hxx
+++ b/sd/source/ui/inc/taskpane/TitledControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include <com/sun/star/drawing/framework/XResourceId.hpp>
#include <tools/string.hxx>
#include <tools/gen.hxx>
-#ifndef SD_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
#include <memory>
#include <boost/function.hpp>
@@ -179,3 +178,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx b/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx
index b5f2f1ca4..34717dbb0 100644
--- a/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx
+++ b/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: ToolPanelViewShell.hxx,v $
- * $Revision: 1.12 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -170,3 +168,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tbx_ww.hxx b/sd/source/ui/inc/tbx_ww.hxx
index d7927c69e..2aecab9d4 100755..100644
--- a/sd/source/ui/inc/tbx_ww.hxx
+++ b/sd/source/ui/inc/tbx_ww.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,4 @@ public:
#endif // _SD_TBX_WW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tmplctrl.hxx b/sd/source/ui/inc/tmplctrl.hxx
index 6f55c0351..f0aa34967 100755..100644
--- a/sd/source/ui/inc/tmplctrl.hxx
+++ b/sd/source/ui/inc/tmplctrl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/AsynchronousCall.hxx b/sd/source/ui/inc/tools/AsynchronousCall.hxx
index 705057ffa..55f82a692 100644
--- a/sd/source/ui/inc/tools/AsynchronousCall.hxx
+++ b/sd/source/ui/inc/tools/AsynchronousCall.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/AsynchronousTask.hxx b/sd/source/ui/inc/tools/AsynchronousTask.hxx
index cb0e60719..a377d5e3f 100755..100644
--- a/sd/source/ui/inc/tools/AsynchronousTask.hxx
+++ b/sd/source/ui/inc/tools/AsynchronousTask.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ public:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/ConfigurationAccess.hxx b/sd/source/ui/inc/tools/ConfigurationAccess.hxx
index 64ff1d777..7f595c52c 100644
--- a/sd/source/ui/inc/tools/ConfigurationAccess.hxx
+++ b/sd/source/ui/inc/tools/ConfigurationAccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -150,3 +151,5 @@ private:
} } // end of namespace sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/IconCache.hxx b/sd/source/ui/inc/tools/IconCache.hxx
index 7f30e9365..e09f33270 100755..100644
--- a/sd/source/ui/inc/tools/IconCache.hxx
+++ b/sd/source/ui/inc/tools/IconCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,7 @@ public:
/** Return the icon with the given resource id.
@return
The returned Image may be empty when there is no icon for the
- given id or an error occured. Should not happen under normal
+ given id or an error occurred. Should not happen under normal
circumstances.
*/
Image GetIcon (sal_uInt16 nResourceId);
@@ -77,3 +78,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/IdleDetection.hxx b/sd/source/ui/inc/tools/IdleDetection.hxx
index b300ad405..9b6dc6d7c 100644
--- a/sd/source/ui/inc/tools/IdleDetection.hxx
+++ b/sd/source/ui/inc/tools/IdleDetection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,3 +90,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/PropertySet.hxx b/sd/source/ui/inc/tools/PropertySet.hxx
index f5a9a3060..282eeb6c0 100755..100644
--- a/sd/source/ui/inc/tools/PropertySet.hxx
+++ b/sd/source/ui/inc/tools/PropertySet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -148,3 +149,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx b/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
index 8541c2b6c..220a4e9c7 100755..100644
--- a/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
+++ b/sd/source/ui/inc/tools/SdGlobalResourceContainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -106,3 +107,5 @@ protected:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/SlotStateListener.hxx b/sd/source/ui/inc/tools/SlotStateListener.hxx
index ba9c3ea0f..b2c90910b 100755..100644
--- a/sd/source/ui/inc/tools/SlotStateListener.hxx
+++ b/sd/source/ui/inc/tools/SlotStateListener.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <com/sun/star/frame/XFrame.hpp>
#include <com/sun/star/frame/FeatureStateEvent.hpp>
#include <com/sun/star/frame/XDispatchProvider.hpp>
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTIOIN_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
#include <com/sun/star/lang/XComponent.hpp>
#include <cppuhelper/compbase1.hxx>
#include <tools/link.hxx>
@@ -158,3 +157,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tools/TimerBasedTaskExecution.hxx b/sd/source/ui/inc/tools/TimerBasedTaskExecution.hxx
index 2157a485c..d2c3bf01e 100755..100644
--- a/sd/source/ui/inc/tools/TimerBasedTaskExecution.hxx
+++ b/sd/source/ui/inc/tools/TimerBasedTaskExecution.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,5 @@ private:
} } // end of namespace ::sd::tools
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tpaction.hxx b/sd/source/ui/inc/tpaction.hxx
index 39f7577a2..116d8150f 100755..100644
--- a/sd/source/ui/inc/tpaction.hxx
+++ b/sd/source/ui/inc/tpaction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,3 +140,4 @@ public:
#endif // _SD_TPACTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/tpoption.hrc b/sd/source/ui/inc/tpoption.hrc
index b75726fa7..dc51afb6b 100644
--- a/sd/source/ui/inc/tpoption.hrc
+++ b/sd/source/ui/inc/tpoption.hrc
@@ -35,17 +35,13 @@
#define GRP_SETTINGS 5
#define GRP_TEXT 6
#define FT_TABSTOP 7
-//#i80528##define GRP_VIEW_SUBSTITUTE 8
#define CBX_COPY 13
#define CBX_RULER 14
#define CBX_HELPLINES 1
#define CBX_MOVE_OUTLINE 15
-//#i80528##define CBX_OUTLINEMODE 11
-//#i80528##define CBX_HAIRLINEMODE 12
#define CBX_MARKED_HIT_MOVES_ALWAYS 19
#define CBX_CROOK_NO_CONTORTION 21
#define CBX_SLANT_BUT_SHEAR 22
-#//#i80528#define CBX_EXTERN_GRAPHIC 10
#define CBX_HANDLES_BEZIER 2
#define GRP_SNAP 1
#define GRP_ORTHO 2
@@ -71,7 +67,6 @@
#define CBX_START_WITH_TEMPLATE 6
#define CBX_START_WITH_LAYOUT 7
#define CBX_PICKTHROUGH 9
-//#i80528##define CBX_NOTEXT 23
#define CBX_QUICKEDIT 24
#define CBX_MASTERPAGE_CACHE 25
diff --git a/sd/source/ui/inc/tpoption.hxx b/sd/source/ui/inc/tpoption.hxx
index ad4b187a5..5f7835ad7 100755..100644
--- a/sd/source/ui/inc/tpoption.hxx
+++ b/sd/source/ui/inc/tpoption.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,21 +30,11 @@
#define _SD_TPOPTION_HXX
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _GROUP_HXX //autogen
#include <vcl/group.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#include <svtools/stdctrl.hxx>
#include <sfx2/tabdlg.hxx>
#include <svx/optgrid.hxx>
@@ -63,8 +54,6 @@ public:
virtual sal_Bool FillItemSet( SfxItemSet& );
virtual void Reset( const SfxItemSet & );
-// virtual void ActivatePage( const SfxItemSet& rSet );
-// virtual int DeactivatePage( SfxItemSet* pSet );
};
/*************************************************************************
|*
@@ -199,3 +188,4 @@ public:
#endif // _SD_TPOPTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unchss.hxx b/sd/source/ui/inc/unchss.hxx
index b540581e7..6cd3a1331 100644
--- a/sd/source/ui/inc/unchss.hxx
+++ b/sd/source/ui/inc/unchss.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,4 @@ public:
#endif // _SD_UNCHSS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/undoback.hxx b/sd/source/ui/inc/undoback.hxx
index f1ad848d2..0021a35ec 100644
--- a/sd/source/ui/inc/undoback.hxx
+++ b/sd/source/ui/inc/undoback.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ public:
};
#endif // _SD_UNDOBACK_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/undoheaderfooter.hxx b/sd/source/ui/inc/undoheaderfooter.hxx
index e884ad872..02756e2be 100644
--- a/sd/source/ui/inc/undoheaderfooter.hxx
+++ b/sd/source/ui/inc/undoheaderfooter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,4 @@ public:
#endif // _SD_UNDOHEADERFOOTER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/undolayer.hxx b/sd/source/ui/inc/undolayer.hxx
index 8ab83df18..09f324b6e 100644
--- a/sd/source/ui/inc/undolayer.hxx
+++ b/sd/source/ui/inc/undolayer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,3 +66,4 @@ private:
#endif // _SD_UNDOLAYER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/undopage.hxx b/sd/source/ui/inc/undopage.hxx
index 213e8cdc0..bfb4e010e 100755..100644
--- a/sd/source/ui/inc/undopage.hxx
+++ b/sd/source/ui/inc/undopage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -178,3 +179,4 @@ public:
#endif // _SD_UNDOPAGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unmodpg.hxx b/sd/source/ui/inc/unmodpg.hxx
index e2729cc30..8be46ca44 100755..100644
--- a/sd/source/ui/inc/unmodpg.hxx
+++ b/sd/source/ui/inc/unmodpg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,3 +86,4 @@ private:
#endif // _SD_UNMODPG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unmovss.hxx b/sd/source/ui/inc/unmovss.hxx
index 36aee5505..6b02bf512 100644
--- a/sd/source/ui/inc/unmovss.hxx
+++ b/sd/source/ui/inc/unmovss.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,4 @@ public:
#endif // _SD_UNMOVSS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unoaprms.hxx b/sd/source/ui/inc/unoaprms.hxx
index aa82522a7..533eef607 100755..100644
--- a/sd/source/ui/inc/unoaprms.hxx
+++ b/sd/source/ui/inc/unoaprms.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -147,3 +148,4 @@ public:
#endif // _SD_UNOAPRMS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unokywds.hxx b/sd/source/ui/inc/unokywds.hxx
index 01a9a9dc9..2c21d9551 100644
--- a/sd/source/ui/inc/unokywds.hxx
+++ b/sd/source/ui/inc/unokywds.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,9 @@
#include <tools/solar.h>
#ifndef SD_DEFINE_KEYWORDS
-#define SD_CONSTASCII_ACTION( n, s ) extern sal_Char __FAR_DATA n[sizeof(s)]
+#define SD_CONSTASCII_ACTION( n, s ) extern sal_Char n[sizeof(s)]
#else
-#define SD_CONSTASCII_ACTION( n, s ) sal_Char __FAR_DATA n[sizeof(s)] = s
+#define SD_CONSTASCII_ACTION( n, s ) sal_Char n[sizeof(s)] = s
#endif
#define UNO_PREFIX "com.sun.star."
@@ -213,3 +214,4 @@ SD_CONSTASCII_ACTION( sUNO_View_VisibleAreaHeight, "VisibleAreaHeight" );
SD_CONSTASCII_ACTION( sUNO_View_ZoomOnPage, "ZoomOnPage" );
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unomodel.hxx b/sd/source/ui/inc/unomodel.hxx
index 472ce790a..c5afe9261 100644
--- a/sd/source/ui/inc/unomodel.hxx
+++ b/sd/source/ui/inc/unomodel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,7 +60,6 @@
class SdDrawDocument;
class SdPage;
-class List;
class SdXCustomPresentations;
namespace sd {
@@ -352,3 +352,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unoprnms.hxx b/sd/source/ui/inc/unoprnms.hxx
index 1324bcbfc..c3d0ff431 100644
--- a/sd/source/ui/inc/unoprnms.hxx
+++ b/sd/source/ui/inc/unoprnms.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,4 @@
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unosrch.hxx b/sd/source/ui/inc/unosrch.hxx
index 36add6793..4cac45c0c 100755..100644
--- a/sd/source/ui/inc/unosrch.hxx
+++ b/sd/source/ui/inc/unosrch.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -147,3 +148,4 @@ public:
virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unprlout.hxx b/sd/source/ui/inc/unprlout.hxx
index 0c3c86f31..0bd42bc75 100755..100644
--- a/sd/source/ui/inc/unprlout.hxx
+++ b/sd/source/ui/inc/unprlout.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,4 @@ public:
#endif // _SD_UNPRLOUT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/unslsel.hxx b/sd/source/ui/inc/unslsel.hxx
index b133c6b1a..5085bf25e 100644
--- a/sd/source/ui/inc/unslsel.hxx
+++ b/sd/source/ui/inc/unslsel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,5 @@ public:
};
#endif // _SD_UNSLSEL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/vectdlg.hxx b/sd/source/ui/inc/vectdlg.hxx
index 56c03713e..7c949852b 100755..100644
--- a/sd/source/ui/inc/vectdlg.hxx
+++ b/sd/source/ui/inc/vectdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -105,3 +106,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/view/viewoverlaymanager.hxx b/sd/source/ui/inc/view/viewoverlaymanager.hxx
index 4437a9597..2a62a5cb7 100755..100644
--- a/sd/source/ui/inc/view/viewoverlaymanager.hxx
+++ b/sd/source/ui/inc/view/viewoverlaymanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: $
- * $Revision: $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -69,3 +67,5 @@ private:
}
#endif // _SD_VIEWOVERLAYMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/inc/zoomlist.hxx b/sd/source/ui/inc/zoomlist.hxx
index 653212381..73a928448 100755..100644
--- a/sd/source/ui/inc/zoomlist.hxx
+++ b/sd/source/ui/inc/zoomlist.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,20 +29,19 @@
#ifndef SD_ZOOM_LIST_HXX
#define SD_ZOOM_LIST_HXX
+#include <vector>
#include <tools/gen.hxx>
-#include <tools/list.hxx>
-
namespace sd {
class ViewShell;
-class ZoomList : public List
+class ZoomList
{
public:
+
ZoomList(ViewShell* pViewShell);
- virtual ~ZoomList();
void InsertZoomRect(const Rectangle& rRect);
Rectangle GetNextZoomRect();
@@ -51,7 +51,9 @@ public:
private:
ViewShell* mpViewShell;
- sal_uLong mnCurPos;
+ sal_uLong mnCurPos;
+
+ std::vector<Rectangle> maRectangles;
};
} // end of namespace sd
@@ -59,3 +61,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/EditWindow.cxx b/sd/source/ui/notes/EditWindow.cxx
index a4b2a17aa..364db9901 100755..100644
--- a/sd/source/ui/notes/EditWindow.cxx
+++ b/sd/source/ui/notes/EditWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,7 +41,7 @@
#include "sdresid.hxx"
#include <svl/itempool.hxx>
#include <editeng/fhgtitem.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <unotools/linguprops.hxx>
#include <unotools/lingucfg.hxx>
@@ -353,34 +354,7 @@ void EditWindow::MouseButtonDown(const MouseEvent &rEvt)
void EditWindow::Command(const CommandEvent& rCEvt)
{
- /* if (rCEvt.GetCommand() == COMMAND_CONTEXTMENU)
- {
- GetParent()->ToTop();
-
- Point aPoint = rCEvt.GetMousePosPixel();
- PopupMenu* pPopupMenu = new PopupMenu(SmResId(RID_COMMANDMENU));
-
- // added for replaceability of context menus #96085, #93782
- Menu* pMenu = NULL;
- ::com::sun::star::ui::ContextMenuExecuteEvent aEvent;
- aEvent.SourceWindow = VCLUnoHelper::GetInterface( this );
- aEvent.ExecutePosition.X = aPoint.X();
- aEvent.ExecutePosition.Y = aPoint.Y();
- if ( GetView()->TryContextMenuInterception( *pPopupMenu, pMenu, aEvent ) )
- {
- if ( pMenu )
- {
- delete pPopupMenu;
- pPopupMenu = (PopupMenu*) pMenu;
- }
- }
-
- pPopupMenu->SetSelectHdl(LINK(this, EditWindow, MenuSelectHdl));
-
- pPopupMenu->Execute( this, aPoint );
- delete pPopupMenu;
- }
- else*/ if (mpEditView)
+ if (mpEditView)
mpEditView->Command( rCEvt );
else
Window::Command (rCEvt);
@@ -388,78 +362,13 @@ void EditWindow::Command(const CommandEvent& rCEvt)
}
IMPL_LINK_INLINE_START( EditWindow, MenuSelectHdl, Menu *, EMPTYARG )
{
- /* SmViewShell *pViewSh = rCmdBox.GetView();
- if (pViewSh)
- pViewSh->GetViewFrame()->GetDispatcher()->Execute(
- SID_INSERTCOMMAND, SFX_CALLMODE_STANDARD,
- new SfxInt16Item(SID_INSERTCOMMAND, pMenu->GetCurItemId()), 0L);
-*/
return 0;
}
IMPL_LINK_INLINE_END( EditWindow, MenuSelectHdl, Menu *, EMPTYARG )
void EditWindow::KeyInput(const KeyEvent& )
{
- /* if (rKEvt.GetKeyCode().GetCode() == KEY_ESCAPE)
- {
- sal_Bool bCallBase = sal_True;
- SfxViewShell* pViewShell = SfxViewShell::Current();
- if ( pViewShell && pViewShell->ISA(SmViewShell) )
- {
- SmDocShell* pDocSh = (SmDocShell*) pViewShell->GetViewFrame()->GetObjectShell();
- if (pDocSh)
- {
- // fuert zum (sofortigen) Zerstoeren von this!
- pDocSh->DoInPlaceActivate( sal_False );
- bCallBase = sal_False;
- }
- }
- if ( bCallBase )
- Window::KeyInput( rKEvt );
- }
- else
- {
- // Timer neu starten, um den Handler (auch bei längeren Eingaben)
- // möglichst nur einmal am Ende aufzurufen.
- aCursorMoveTimer.Start();
- DBG_ASSERT( mpEditView, "EditView missing (NULL pointer)" );
- if (!mpEditView)
- CreateEditView();
- if ( !mpEditView->PostKeyEvent(rKEvt) )
- {
- if ( !SfxViewShell::Current()->KeyInput(rKEvt) )
- {
- // fuert bei F1 (Hilfe) zum Zerstoeren von this!
- Flush();
- if ( aModifyTimer.IsActive() )
- aModifyTimer.Stop();
- Window::KeyInput(rKEvt);
- }
- else
- {
- //SFX hat evtl. Slot an der View gecallt und dabei (wg. Hack
- //im SFX) den Focus auf die View gesetzt
- SfxViewShell* pVShell = SfxViewShell::Current();
- if ( pVShell && pVShell->ISA(SmViewShell) &&
- ((SmViewShell*)pVShell)->GetGraphicWindow().HasFocus() )
- {
- GrabFocus();
- }
- }
- }
- else
- {
- // have doc-shell modified only for formula input/change and not
- // cursor travelling and such things...
- SmDocShell *pDocShell = GetDoc();
- if (pDocShell)
- pDocShell->SetModified( GetEditEngine()->IsModified() );
-
- aModifyTimer.Start();
- }
- }
- */
}
@@ -642,7 +551,7 @@ void EditWindow::SetText(const XubString& rText)
pEditEngine->SetText(rText);
pEditEngine->ClearModifyFlag();
- //! Hier die Timer neu zu starten verhindert, dass die Handler für andere
+ //! Hier die Timer neu zu starten verhindert, dass die Handler f�r andere
//! (im Augenblick nicht mehr aktive) Math Tasks aufgerufen werden.
maModifyTimer.Start();
maCursorMoveTimer.Start();
@@ -873,7 +782,7 @@ void EditWindow::Delete()
void EditWindow::InsertText(const String& Text)
{
DBG_ASSERT( mpEditView, "EditView missing" );
- ::vos::OGuard aGuard (::Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if (mpEditView)
mpEditView->InsertText(Text);
}
@@ -881,3 +790,5 @@ void EditWindow::InsertText(const String& Text)
} } // end of namespace ::sd::notes
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/EditWindow.hxx b/sd/source/ui/notes/EditWindow.hxx
index dac056ae5..b93e35a9f 100755..100644
--- a/sd/source/ui/notes/EditWindow.hxx
+++ b/sd/source/ui/notes/EditWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -126,3 +127,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/NotesChildWindow.cxx b/sd/source/ui/notes/NotesChildWindow.cxx
index b9b1b75f0..f82e10d4f 100755..100644
--- a/sd/source/ui/notes/NotesChildWindow.cxx
+++ b/sd/source/ui/notes/NotesChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,3 +62,5 @@ SFX_IMPL_DOCKINGWINDOW(NotesChildWindow, SID_NOTES_WINDOW)
} } // end of namespace ::sd::notes
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/NotesChildWindow.src b/sd/source/ui/notes/NotesChildWindow.src
index 19ddb624c..19ddb624c 100755..100644
--- a/sd/source/ui/notes/NotesChildWindow.src
+++ b/sd/source/ui/notes/NotesChildWindow.src
diff --git a/sd/source/ui/notes/NotesDockingWindow.cxx b/sd/source/ui/notes/NotesDockingWindow.cxx
index c78e91cbe..d4ae7bb9a 100755..100644
--- a/sd/source/ui/notes/NotesDockingWindow.cxx
+++ b/sd/source/ui/notes/NotesDockingWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,9 +39,7 @@
#include <sfx2/dispatch.hxx>
#include <sfx2/viewfrm.hxx>
#include "DrawViewShell.hxx"
-#ifndef SD_DRAW_DOC_HXX
#include "drawdoc.hxx"
-#endif
#include "sdresid.hxx"
#include "ViewShellBase.hxx"
@@ -112,3 +111,4 @@ void NotesDockingWindow::Resize (void)
} } // end of namespace ::sd::notes
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/NotesDockingWindow.hxx b/sd/source/ui/notes/NotesDockingWindow.hxx
index b51d19548..f8377ceed 100755..100644
--- a/sd/source/ui/notes/NotesDockingWindow.hxx
+++ b/sd/source/ui/notes/NotesDockingWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,5 @@ private:
} } // end of namespace ::sd::notes
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/TextLogger.cxx b/sd/source/ui/notes/TextLogger.cxx
index aba74edb5..f22e08523 100755..100644
--- a/sd/source/ui/notes/TextLogger.cxx
+++ b/sd/source/ui/notes/TextLogger.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,7 +32,7 @@
#include "TextLogger.hxx"
#include "EditWindow.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
namespace sd { namespace notes {
@@ -42,7 +43,7 @@ TextLogger& TextLogger::Instance (void)
{
if (spInstance == NULL)
{
- ::vos::OGuard aGuard (::Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if (spInstance == NULL)
spInstance = new TextLogger ();
}
@@ -62,7 +63,7 @@ TextLogger::TextLogger (void)
void TextLogger::AppendText (const char* sText)
{
- OSL_TRACE (sText);
+ OSL_TRACE("%s", sText);
if (mpEditWindow != NULL)
mpEditWindow->InsertText (UniString::CreateFromAscii(sText));
}
@@ -73,7 +74,7 @@ void TextLogger::AppendText (const char* sText)
void TextLogger::AppendText (const String& sText)
{
ByteString s(sText, RTL_TEXTENCODING_ISO_8859_1);
- OSL_TRACE (s.GetBuffer());
+ OSL_TRACE("%s", s.GetBuffer());
if (mpEditWindow != NULL)
mpEditWindow->InsertText (sText);
}
@@ -127,3 +128,5 @@ IMPL_LINK(TextLogger, WindowEventHandler, VclWindowEvent*, pEvent)
} } // end of namespace ::sd::notes
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/notes/makefile.mk b/sd/source/ui/notes/makefile.mk
deleted file mode 100755
index a4b0e457c..000000000
--- a/sd/source/ui/notes/makefile.mk
+++ /dev/null
@@ -1,60 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=notes
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/EditWindow.obj \
- $(SLO)$/NotesChildWindow.obj \
- $(SLO)$/NotesDockingWindow.obj \
- $(SLO)$/TextLogger.obj
-
-
-
-EXCEPTIONSFILES=
-
-SRS2NAME = notes
-SRC2FILES = NotesChildWindow.src
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/presenter/CanvasUpdateRequester.cxx b/sd/source/ui/presenter/CanvasUpdateRequester.cxx
index a7f1b58c0..fbc79e687 100644
--- a/sd/source/ui/presenter/CanvasUpdateRequester.cxx
+++ b/sd/source/ui/presenter/CanvasUpdateRequester.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,3 +126,5 @@ IMPL_LINK(CanvasUpdateRequester, Callback, void*, EMPTYARG)
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/CanvasUpdateRequester.hxx b/sd/source/ui/presenter/CanvasUpdateRequester.hxx
index 61ccf031c..c5debf80d 100755..100644
--- a/sd/source/ui/presenter/CanvasUpdateRequester.hxx
+++ b/sd/source/ui/presenter/CanvasUpdateRequester.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterCanvas.cxx b/sd/source/ui/presenter/PresenterCanvas.cxx
index 1beb78f99..ea3e41227 100755..100644
--- a/sd/source/ui/presenter/PresenterCanvas.cxx
+++ b/sd/source/ui/presenter/PresenterCanvas.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,7 +64,7 @@ Reference<XInterface> SAL_CALL PresenterCanvas_createInstance (
::rtl::OUString PresenterCanvas_getImplementationName (void) throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.PresenterCanvasFactory");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.PresenterCanvasFactory"));
}
@@ -73,7 +74,7 @@ Sequence<rtl::OUString> SAL_CALL PresenterCanvas_getSupportedServiceNames (void)
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.rendering.Canvas"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.rendering.Canvas")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -232,7 +233,7 @@ void SAL_CALL PresenterCanvas::initialize (
if ( ! (rArguments[2] >>= mxSharedWindow))
{
throw lang::IllegalArgumentException(
- OUString::createFromAscii("PresenterCanvas: invalid shared window"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("PresenterCanvas: invalid shared window")),
static_cast<XWeak*>(this),
1);
}
@@ -240,7 +241,7 @@ void SAL_CALL PresenterCanvas::initialize (
if ( ! (rArguments[3] >>= mxSharedCanvas))
{
throw lang::IllegalArgumentException(
- OUString::createFromAscii("PresenterCanvas: invalid shared canvas"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("PresenterCanvas: invalid shared canvas")),
static_cast<XWeak*>(this),
2);
}
@@ -248,7 +249,7 @@ void SAL_CALL PresenterCanvas::initialize (
if ( ! (rArguments[4] >>= mxWindow))
{
throw lang::IllegalArgumentException(
- OUString::createFromAscii("PresenterCanvas: invalid window"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("PresenterCanvas: invalid window")),
static_cast<XWeak*>(this),
3);
}
@@ -269,7 +270,7 @@ void SAL_CALL PresenterCanvas::initialize (
else
{
throw RuntimeException(
- OUString::createFromAscii("PresenterCanvas: invalid number of arguments"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("PresenterCanvas: invalid number of arguments")),
static_cast<XWeak*>(this));
}
}
@@ -1226,3 +1227,5 @@ void PresenterCustomSprite::ThrowIfDisposed (void)
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterCanvas.hxx b/sd/source/ui/presenter/PresenterCanvas.hxx
index c5a31b1fd..84267ed67 100644
--- a/sd/source/ui/presenter/PresenterCanvas.hxx
+++ b/sd/source/ui/presenter/PresenterCanvas.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -442,3 +443,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterCanvasFactory.cxx b/sd/source/ui/presenter/PresenterCanvasFactory.cxx
index 8d30fbd96..4d17967cc 100644
--- a/sd/source/ui/presenter/PresenterCanvasFactory.cxx
+++ b/sd/source/ui/presenter/PresenterCanvasFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -251,7 +252,7 @@ Reference<rendering::XCanvas> PresenterCanvasFactory::CreateCanvas (
xFactory->createInstanceWithArguments(
rsCanvasServiceName.getLength()>0
? rsCanvasServiceName
- : OUString::createFromAscii("com.sun.star.rendering.VCLCanvas"),
+ : OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.rendering.VCLCanvas")),
aArg),
UNO_QUERY);
}
@@ -305,3 +306,5 @@ PresenterCanvasFactory::~PresenterCanvasFactory (void)
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterHelper.cxx b/sd/source/ui/presenter/PresenterHelper.cxx
index 30c1f3c2e..77173213a 100755..100644
--- a/sd/source/ui/presenter/PresenterHelper.cxx
+++ b/sd/source/ui/presenter/PresenterHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,7 +61,7 @@ Reference<XInterface> SAL_CALL PresenterHelperService_createInstance (
::rtl::OUString PresenterHelperService_getImplementationName (void)
throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.PresenterHelper");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.PresenterHelper"));
}
@@ -70,7 +71,7 @@ Sequence<rtl::OUString> SAL_CALL PresenterHelperService_getSupportedServiceNames
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.PresenterHelper"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.PresenterHelper")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -176,7 +177,7 @@ Reference<rendering::XCanvas> SAL_CALL PresenterHelper::createSharedCanvas (
|| ! rxWindow.is())
{
throw RuntimeException(
- OUString::createFromAscii("illegal argument"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("illegal argument")),
Reference<XInterface>(static_cast<XWeak*>(this)));
}
@@ -222,7 +223,7 @@ Reference<rendering::XCanvas> SAL_CALL PresenterHelper::createCanvas (
xFactory->createInstanceWithArguments(
rsOptionalCanvasServiceName.getLength()>0
? rsOptionalCanvasServiceName
- : OUString::createFromAscii("com.sun.star.rendering.VCLCanvas"),
+ : OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.rendering.VCLCanvas")),
aArg),
UNO_QUERY);
}
@@ -341,3 +342,5 @@ awt::Rectangle PresenterHelper::getWindowExtentsRelative (
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterHelper.hxx b/sd/source/ui/presenter/PresenterHelper.hxx
index af5aaab6b..f9d814c0c 100644
--- a/sd/source/ui/presenter/PresenterHelper.hxx
+++ b/sd/source/ui/presenter/PresenterHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -118,3 +119,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterPreviewCache.cxx b/sd/source/ui/presenter/PresenterPreviewCache.cxx
index 9f4c40b99..3c7ac487c 100755..100644
--- a/sd/source/ui/presenter/PresenterPreviewCache.cxx
+++ b/sd/source/ui/presenter/PresenterPreviewCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -100,7 +101,7 @@ Reference<XInterface> SAL_CALL PresenterPreviewCache_createInstance (
::rtl::OUString PresenterPreviewCache_getImplementationName (void) throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.PresenterPreviewCache");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.PresenterPreviewCache"));
}
@@ -110,7 +111,7 @@ Sequence<rtl::OUString> SAL_CALL PresenterPreviewCache_getSupportedServiceNames
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.PresenterPreviewCache"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.PresenterPreviewCache")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -387,13 +388,6 @@ void PresenterPreviewCache::PresenterCacheContext::NotifyPreviewCreation (
bool PresenterPreviewCache::PresenterCacheContext::IsIdle (void)
{
return true;
- /*
- sal_Int32 nIdleState (tools::IdleDetection::GetIdleState(NULL));
- if (nIdleState == tools::IdleDetection::IDET_IDLE)
- return true;
- else
- return false;
- */
}
@@ -514,3 +508,5 @@ void PresenterPreviewCache::PresenterCacheContext::CallListeners (
}
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterPreviewCache.hxx b/sd/source/ui/presenter/PresenterPreviewCache.hxx
index 5d1b3262a..b3de5a341 100644
--- a/sd/source/ui/presenter/PresenterPreviewCache.hxx
+++ b/sd/source/ui/presenter/PresenterPreviewCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -120,3 +121,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterTextView.cxx b/sd/source/ui/presenter/PresenterTextView.cxx
index 1f8882b86..f593384c0 100755..100644
--- a/sd/source/ui/presenter/PresenterTextView.cxx
+++ b/sd/source/ui/presenter/PresenterTextView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,7 +73,7 @@ Reference<XInterface> SAL_CALL PresenterTextViewService_createInstance (
::rtl::OUString PresenterTextViewService_getImplementationName (void) throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.PresenterTextView");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.PresenterTextView"));
}
@@ -82,7 +83,7 @@ Sequence<rtl::OUString> SAL_CALL PresenterTextViewService_getSupportedServiceNam
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.PresenterTextView"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.PresenterTextView")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -192,7 +193,7 @@ void SAL_CALL PresenterTextView::initialize (const Sequence<Any>& rArguments)
else
{
throw RuntimeException(
- OUString::createFromAscii("PresenterTextView: invalid number of arguments"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("PresenterTextView: invalid number of arguments")),
static_cast<XWeak*>(this));
}
}
@@ -302,15 +303,15 @@ void PresenterTextView::ThrowIfDisposed (void)
//===== PresenterTextView::Implementation =====================================
PresenterTextView::Implementation::Implementation (void)
- : msTextPropertyName(OUString::createFromAscii("Text")),
- msBitmapPropertyName(OUString::createFromAscii("Bitmap")),
- msSizePropertyName(OUString::createFromAscii("Size")),
- msBackgroundColorPropertyName(OUString::createFromAscii("BackgroundColor")),
- msTextColorPropertyName(OUString::createFromAscii("TextColor")),
- msFontDescriptorPropertyName(OUString::createFromAscii("FontDescriptor")),
- msTopPropertyName(OUString::createFromAscii("Top")),
- msTopRelativePropertyName(OUString::createFromAscii("RelativeTop")),
- msTotalHeightPropertyName(OUString::createFromAscii("TotalHeight")),
+ : msTextPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("Text"))),
+ msBitmapPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("Bitmap"))),
+ msSizePropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("Size"))),
+ msBackgroundColorPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("BackgroundColor"))),
+ msTextColorPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("TextColor"))),
+ msFontDescriptorPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("FontDescriptor"))),
+ msTopPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("Top"))),
+ msTopRelativePropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("RelativeTop"))),
+ msTotalHeightPropertyName(OUString(RTL_CONSTASCII_USTRINGPARAM("TotalHeight"))),
mxBitmap(),
mpCanvas(),
mpOutputDevice(new VirtualDevice(*Application::GetDefaultDevice(), 0, 0)),
@@ -361,7 +362,7 @@ EditEngine* PresenterTextView::Implementation::CreateEditEngine (void)
//
SvtLinguOptions aOpt;
SvtLinguConfig().GetOptions( aOpt );
- //
+
struct FontDta {
sal_Int16 nFallbackLang;
sal_Int16 nLang;
@@ -382,7 +383,7 @@ EditEngine* PresenterTextView::Implementation::CreateEditEngine (void)
aTable[0].nLang = MsLangId::resolveSystemLanguageByScriptType(aOpt.nDefaultLanguage, ::com::sun::star::i18n::ScriptType::LATIN);
aTable[1].nLang = MsLangId::resolveSystemLanguageByScriptType(aOpt.nDefaultLanguage_CJK, ::com::sun::star::i18n::ScriptType::ASIAN);
aTable[2].nLang = MsLangId::resolveSystemLanguageByScriptType(aOpt.nDefaultLanguage_CTL, ::com::sun::star::i18n::ScriptType::COMPLEX);
- //
+
for (int i = 0; i < 3; ++i)
{
const FontDta &rFntDta = aTable[i];
@@ -643,3 +644,5 @@ void PresenterTextView::Implementation::CheckTop (void)
} } // end of namespace ::sd::presenter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/PresenterTextView.hxx b/sd/source/ui/presenter/PresenterTextView.hxx
index 6524fbccb..561a748e5 100644
--- a/sd/source/ui/presenter/PresenterTextView.hxx
+++ b/sd/source/ui/presenter/PresenterTextView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/SlideRenderer.cxx b/sd/source/ui/presenter/SlideRenderer.cxx
index 81c66b84d..95c0eecb6 100644
--- a/sd/source/ui/presenter/SlideRenderer.cxx
+++ b/sd/source/ui/presenter/SlideRenderer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,7 @@
#include "SlideRenderer.hxx"
#include "sdpage.hxx"
#include <toolkit/helper/vclunohelper.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <cppcanvas/vclfactory.hxx>
@@ -53,7 +54,7 @@ Reference<XInterface> SAL_CALL SlideRenderer_createInstance (
::rtl::OUString SlideRenderer_getImplementationName (void) throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.SlideRenderer");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.SlideRenderer"));
}
@@ -63,7 +64,7 @@ Sequence<rtl::OUString> SAL_CALL SlideRenderer_getSupportedServiceNames (void)
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.SlideRenderer"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.SlideRenderer")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -116,7 +117,7 @@ void SAL_CALL SlideRenderer::initialize (const Sequence<Any>& rArguments)
else
{
throw RuntimeException(
- OUString::createFromAscii("SlideRenderer: invalid number of arguments"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("SlideRenderer: invalid number of arguments")),
static_cast<XWeak*>(this));
}
}
@@ -133,7 +134,7 @@ Reference<awt::XBitmap> SlideRenderer::createPreview (
throw (css::uno::RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
return VCLUnoHelper::CreateBitmap(
CreatePreview(rxSlide, rMaximalSize, nSuperSampleFactor));
@@ -150,7 +151,7 @@ Reference<rendering::XBitmap> SlideRenderer::createPreviewForCanvas (
throw (css::uno::RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
cppcanvas::BitmapCanvasSharedPtr pCanvas (cppcanvas::VCLFactory::getInstance().createCanvas(
Reference<rendering::XBitmapCanvas>(rxCanvas, UNO_QUERY)));
@@ -202,7 +203,7 @@ BitmapEx SlideRenderer::CreatePreview (
const SdPage* pPage = SdPage::getImplementation(rxSlide);
if (pPage == NULL)
throw lang::IllegalArgumentException(
- OUString::createFromAscii("SlideRenderer::createPreview() called with invalid slide"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("SlideRenderer::createPreview() called with invalid slide")),
static_cast<XWeak*>(this),
0);
@@ -210,7 +211,7 @@ BitmapEx SlideRenderer::CreatePreview (
Size aPageSize = pPage->GetSize();
if (aPageSize.Height() <= 0)
throw lang::IllegalArgumentException(
- OUString::createFromAscii("SlideRenderer::createPreview() called with invalid size"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("SlideRenderer::createPreview() called with invalid size")),
static_cast<XWeak*>(this),
1);
@@ -270,3 +271,4 @@ void SlideRenderer::ThrowIfDisposed (void)
} } // end of namespace ::sd::presenter
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/SlideRenderer.hxx b/sd/source/ui/presenter/SlideRenderer.hxx
index d4adbff08..e5a715ea1 100644
--- a/sd/source/ui/presenter/SlideRenderer.hxx
+++ b/sd/source/ui/presenter/SlideRenderer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -106,3 +107,5 @@ private:
} } // end of namespace ::sd::presenter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/presenter/makefile.mk b/sd/source/ui/presenter/makefile.mk
deleted file mode 100644
index fe6232098..000000000
--- a/sd/source/ui/presenter/makefile.mk
+++ /dev/null
@@ -1,56 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=presenter
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=.. ..$/slidesorter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/CanvasUpdateRequester.obj \
- $(SLO)$/PresenterCanvas.obj \
- $(SLO)$/PresenterHelper.obj \
- $(SLO)$/PresenterPreviewCache.obj \
- $(SLO)$/PresenterTextView.obj \
- $(SLO)$/SlideRenderer.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slideshow/PaneHider.cxx b/sd/source/ui/slideshow/PaneHider.cxx
index b6d793824..73f613e8d 100755..100644
--- a/sd/source/ui/slideshow/PaneHider.cxx
+++ b/sd/source/ui/slideshow/PaneHider.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115,3 +116,5 @@ PaneHider::~PaneHider (void)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/PaneHider.hxx b/sd/source/ui/slideshow/PaneHider.hxx
index 01d5b504c..2424c03fe 100644
--- a/sd/source/ui/slideshow/PaneHider.hxx
+++ b/sd/source/ui/slideshow/PaneHider.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/SlideShowRestarter.cxx b/sd/source/ui/slideshow/SlideShowRestarter.cxx
index 6938826fc..83110d7c5 100644
--- a/sd/source/ui/slideshow/SlideShowRestarter.cxx
+++ b/sd/source/ui/slideshow/SlideShowRestarter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -182,3 +183,5 @@ void SlideShowRestarter::StartPresentation (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/SlideShowRestarter.hxx b/sd/source/ui/slideshow/SlideShowRestarter.hxx
index de713fbc7..1f6fa2cfe 100644
--- a/sd/source/ui/slideshow/SlideShowRestarter.hxx
+++ b/sd/source/ui/slideshow/SlideShowRestarter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,3 +90,5 @@ private:
};
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/makefile.mk b/sd/source/ui/slideshow/makefile.mk
deleted file mode 100755
index 62062d7e5..000000000
--- a/sd/source/ui/slideshow/makefile.mk
+++ /dev/null
@@ -1,65 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slideshow
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-.IF "$(ENABLE_PRESENTER_EXTRA_UI)"=="YES"
-ENABLE_PRESENTER_EXTRA_UI is not used anymore
-.ENDIF
-
-# --- Files --------------------------------------------------------
-
-
-SLOFILES = \
- $(SLO)$/slideshow.obj \
- $(SLO)$/showwin.obj \
- $(SLO)$/slideshowimpl.obj \
- $(SLO)$/slideshowviewimpl.obj \
- $(SLO)$/PaneHider.obj \
- $(SLO)$/SlideShowRestarter.obj
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- slideshow.src
-
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slideshow/showwin.cxx b/sd/source/ui/slideshow/showwin.cxx
index 6d3264924..43831f476 100755..100644
--- a/sd/source/ui/slideshow/showwin.cxx
+++ b/sd/source/ui/slideshow/showwin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,7 +86,6 @@ ShowWindow::ShowWindow( const ::rtl::Reference< SlideshowImpl >& xController, ::
maMouseTimer.SetTimeout( HIDE_MOUSE_TIMEOUT );
maShowBackground = Wallpaper( Color( COL_BLACK ) );
-// SetBackground( Wallpaper( Color( COL_BLACK ) ) );
SetBackground(); // avoids that VCL paints any background!
GetParent()->Show();
AddEventListener( LINK( this, ShowWindow, EventHdl ) );
@@ -288,17 +288,6 @@ void ShowWindow::Paint(const Rectangle& rRect)
{
if( (meShowWindowMode == SHOWWINDOWMODE_NORMAL) || (meShowWindowMode == SHOWWINDOWMODE_PREVIEW) )
{
-/*
- Region aOldClipRegion( GetClipRegion() );
-
- Region aClipRegion( rRect );
- aClipRegion.Exclude( maPresArea );
- SetClipRegion( aClipRegion );
-
- DrawWallpaper( rRect, maShowBackground );
-
- SetClipRegion( aOldClipRegion );
-*/
if( mxController.is() )
{
mxController->paint(rRect);
@@ -336,13 +325,6 @@ void ShowWindow::Paint(const Rectangle& rRect)
long ShowWindow::Notify(NotifyEvent& rNEvt)
{
long nOK = sal_False;
-/*
- if( mpViewShell && rNEvt.GetType() == EVENT_GETFOCUS )
- {
- NotifyEvent aNEvt(EVENT_GETFOCUS, this);
- nOK = mpViewShell->GetViewFrame()->GetWindow().Notify(aNEvt);
- }
-*/
if (!nOK)
nOK = Window::Notify(rNEvt);
@@ -356,13 +338,6 @@ void ShowWindow::GetFocus()
{
// Basisklasse
Window::GetFocus();
-/*
- if( mpViewShell )
- {
- NotifyEvent aNEvt(EVENT_GETFOCUS, this);
- mpViewShell->GetViewFrame()->GetWindow().Notify(aNEvt);
- }
-*/
}
// -----------------------------------------------------------------------------
@@ -397,8 +372,6 @@ sal_Bool ShowWindow::SetEndMode()
{
DeleteWindowFromPaintView();
meShowWindowMode = SHOWWINDOWMODE_END;
-// maShowBackground = GetBackground();
-// SetBackground( Wallpaper( Color( COL_BLACK ) ) );
maShowBackground = Wallpaper( Color( COL_BLACK ) );
// hide navigator if it is visible
@@ -433,8 +406,6 @@ sal_Bool ShowWindow::SetPauseMode( sal_Int32 nPageIndexToRestart, sal_Int32 nTim
mnPauseTimeout = nTimeout;
mnRestartPageIndex = nPageIndexToRestart;
meShowWindowMode = SHOWWINDOWMODE_PAUSE;
-// maShowBackground = GetBackground();
-// SetBackground( Wallpaper( Color( COL_BLACK ) ) );
maShowBackground = Wallpaper( Color( COL_BLACK ) );
// hide navigator if it is visible
@@ -465,8 +436,6 @@ sal_Bool ShowWindow::SetBlankMode( sal_Int32 nPageIndexToRestart, const Color& r
DeleteWindowFromPaintView();
mnRestartPageIndex = nPageIndexToRestart;
meShowWindowMode = SHOWWINDOWMODE_BLANK;
-// maShowBackground = GetBackground();
-// SetBackground( Wallpaper( rBlankColor ) );
maShowBackground = Wallpaper( rBlankColor );
// hide navigator if it is visible
@@ -497,7 +466,6 @@ void ShowWindow::TerminateShow()
maPauseTimer.Stop();
maMouseTimer.Stop();
Erase();
-// SetBackground( maShowBackground );
maShowBackground = Wallpaper( Color( COL_BLACK ) );
meShowWindowMode = SHOWWINDOWMODE_NORMAL;
mnPauseTimeout = SLIDE_NO_TIMEOUT;
@@ -535,7 +503,6 @@ void ShowWindow::RestartShow( sal_Int32 nPageIndexToRestart )
maLogo.Clear();
maPauseTimer.Stop();
Erase();
-// SetBackground( maShowBackground );
maShowBackground = Wallpaper( Color( COL_BLACK ) );
meShowWindowMode = SHOWWINDOWMODE_NORMAL;
mnPauseTimeout = SLIDE_NO_TIMEOUT;
@@ -743,3 +710,5 @@ void ShowWindow::AddWindowToPaintView()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/showwindow.hxx b/sd/source/ui/slideshow/showwindow.hxx
index f63965ec1..b91ca8ea4 100755..100644
--- a/sd/source/ui/slideshow/showwindow.hxx
+++ b/sd/source/ui/slideshow/showwindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <vcl/timer.hxx>
#include <vcl/graph.hxx>
-#ifndef SD_WINDOW_HXX
#include "Window.hxx"
-#endif
#include "slideshowimpl.hxx"
@@ -69,12 +68,10 @@ enum ShowWindowMode
SHOWWINDOWMODE_PREVIEW = 4
};
-//class ShowWindowImpl;
-
class ShowWindow
: public ::sd::Window
{
-// friend class ShowWindowImpl;
+
public:
ShowWindow ( const ::rtl::Reference< ::sd::SlideshowImpl >& xController, ::Window* pParent );
virtual ~ShowWindow (void);
@@ -98,7 +95,6 @@ public:
virtual void Resize();
virtual void GetFocus();
virtual void LoseFocus();
-// virtual void GrabFocus();
virtual void KeyInput(const KeyEvent& rKEvt);
virtual void MouseMove(const MouseEvent& rMEvt);
@@ -142,3 +138,5 @@ private:
} // end of namespace sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/slideshow.cxx b/sd/source/ui/slideshow/slideshow.cxx
index e6e802952..bba8fab08 100755..100644
--- a/sd/source/ui/slideshow/slideshow.cxx
+++ b/sd/source/ui/slideshow/slideshow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
-//#include <com/sun/star/frame/XController.hpp>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/drawing/framework/XControllerManager.hpp>
#include <com/sun/star/container/XIndexAccess.hpp>
#include <comphelper/serviceinfohelper.hxx>
+#include <com/sun/star/frame/XDispatchProvider.hpp>
+#include <com/sun/star/util/URL.hpp>
#include <cppuhelper/bootstrap.hxx>
#include <comphelper/processfactory.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <vcl/wrkwin.hxx>
@@ -69,7 +71,7 @@ using ::rtl::OUString;
using ::com::sun::star::awt::XWindow;
using namespace ::sd;
using namespace ::cppu;
-using namespace ::vos;
+using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::presentation;
using namespace ::com::sun::star::drawing;
@@ -141,8 +143,6 @@ const SfxItemPropertyMapEntry* ImplGetPresentationPropertyMap()
return aPresentationPropertyMap_Impl;
}
-//SfxItemPropertyMap map_impl[] = { { 0,0,0,0,0,0 } };
-
// --------------------------------------------------------------------
// class SlideShow
// --------------------------------------------------------------------
@@ -294,7 +294,7 @@ Sequence< OUString > SAL_CALL SlideShow::getSupportedServiceNames( ) throw(Runt
Reference< XPropertySetInfo > SAL_CALL SlideShow::getPropertySetInfo() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
static Reference< XPropertySetInfo > xInfo = maPropSet.getPropertySetInfo();
return xInfo;
}
@@ -303,7 +303,7 @@ Reference< XPropertySetInfo > SAL_CALL SlideShow::getPropertySetInfo() throw(Run
void SAL_CALL SlideShow::setPropertyValue( const OUString& aPropertyName, const Any& aValue ) throw(UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
ThrowIfDisposed();
sd::PresentationSettings& rPresSettings = mpDoc->getPresentationSettings();
@@ -576,7 +576,7 @@ void SAL_CALL SlideShow::setPropertyValue( const OUString& aPropertyName, const
Any SAL_CALL SlideShow::getPropertyValue( const OUString& PropertyName ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
ThrowIfDisposed();
const sd::PresentationSettings& rPresSettings = mpDoc->getPresentationSettings();
@@ -678,7 +678,7 @@ void SAL_CALL SlideShow::start() throw(RuntimeException)
void SAL_CALL SlideShow::end() throw(RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// The mbIsInStartup flag should have been reset during the start of the
// slide show. Reset it here just in case that something has horribly
@@ -700,6 +700,13 @@ void SAL_CALL SlideShow::end() throw(RuntimeException)
ViewShellBase* pFullScreenViewShellBase = mpFullScreenViewShellBase;
mpFullScreenViewShellBase = 0;
+ // dispose before fullscreen window changes screens
+ // (potentially). If this needs to be moved behind
+ // pWorkWindow->StartPresentationMode() again, read issue
+ // pWorkWindow->i94007 & implement the solution outlined
+ // there.
+ xController->dispose();
+
if( pFullScreenViewShellBase )
{
PresentationViewShell* pShell = dynamic_cast<PresentationViewShell*>(pFullScreenViewShellBase->GetMainViewShell().get());
@@ -714,8 +721,6 @@ void SAL_CALL SlideShow::end() throw(RuntimeException)
}
}
- xController->dispose();
-
if( pFullScreenViewShellBase )
{
PresentationViewShell* pShell = NULL;
@@ -781,6 +786,28 @@ void SAL_CALL SlideShow::end() throw(RuntimeException)
UNO_QUERY));
}
}
+
+ if( pViewShell->GetDoc()->IsStartWithPresentation() )
+ {
+ pViewShell->GetDoc()->SetStartWithPresentation( false );
+
+ Reference<frame::XDispatchProvider> xProvider(pViewShell->GetViewShellBase().GetController()->getFrame(),
+ UNO_QUERY);
+ if( xProvider.is() )
+ {
+ util::URL aURL;
+ aURL.Complete = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseFrame"));
+
+ uno::Reference< frame::XDispatch > xDispatch(
+ xProvider->queryDispatch(
+ aURL, ::rtl::OUString(), 0));
+ if( xDispatch.is() )
+ {
+ xDispatch->dispatch(aURL,
+ uno::Sequence< beans::PropertyValue >());
+ }
+ }
+ }
}
}
mpCurrentViewShellBase = 0;
@@ -803,7 +830,7 @@ void SAL_CALL SlideShow::rehearseTimings() throw(RuntimeException)
void SAL_CALL SlideShow::startWithArguments( const Sequence< PropertyValue >& rArguments ) throw (RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
ThrowIfDisposed();
// Stop a running show before starting a new one.
@@ -853,7 +880,7 @@ void SAL_CALL SlideShow::startWithArguments( const Sequence< PropertyValue >& rA
::sal_Bool SAL_CALL SlideShow::isRunning( ) throw (RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return mxController.is() && mxController->isRunning();
}
@@ -873,7 +900,7 @@ Reference< XSlideShowController > SAL_CALL SlideShow::getController( ) throw (R
void SAL_CALL SlideShow::disposing (void)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mnInPlaceConfigEvent )
{
@@ -1198,8 +1225,6 @@ void SlideShow::StartFullscreenPresentation( )
delete mpFullScreenFrameView;
mpFullScreenFrameView = new FrameView(mpDoc, pOriginalFrameView);
-// Reference<XController> xController;
-
// The new frame is created hidden. To make it visible and activate the
// new view shell--a prerequisite to process slot calls and initialize
// its panes--a GrabFocus() has to be called later on.
@@ -1270,3 +1295,4 @@ Reference< XPresentation2 > CreatePresentation( const SdDrawDocument& rDocument
// ---------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/slideshow.src b/sd/source/ui/slideshow/slideshow.src
index 2d8c70712..2d8c70712 100755..100644
--- a/sd/source/ui/slideshow/slideshow.src
+++ b/sd/source/ui/slideshow/slideshow.src
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index 53487647f..35500de72 100755..100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,7 +44,6 @@
#include <com/sun/star/util/XURLTransformer.hpp>
#include <com/sun/star/frame/XDispatch.hpp>
#include <com/sun/star/frame/XLayoutManager.hpp>
-#include <vos/process.hxx>
#include <svl/aeitem.hxx>
#include <svl/urihelper.hxx>
@@ -64,7 +64,6 @@
#include <svx/colrctrl.hxx>
#include <svx/bmpmask.hxx>
#include <svx/srchdlg.hxx>
-#include <svx/hyprlink.hxx>
#include <svx/hyperdlg.hxx>
#include <svx/galbrws.hxx>
#include "NavigatorChildWindow.hxx"
@@ -116,16 +115,12 @@ namespace sd
// Slots, welche im Sfx verwaltet werden und in der SlideShow disabled
// werden sollen (muss in Reihenfolge der SIDs geordnet sein)
-static sal_uInt16 __READONLY_DATA pAllowed[] =
+static sal_uInt16 const pAllowed[] =
{
SID_OPENDOC , // 5501 // damit interne Spruenge klappen
SID_JUMPTOMARK , // 5598
-// SID_SHOWPOPUPS , // 5929
-// SID_GALLERY , // 5960
SID_OPENHYPERLINK , // 6676
-// SID_GALLERY_FORMATS , // 10280
SID_NAVIGATOR , // 10366
-// SID_FM_DESIGN_MODE , // 10629
SID_PRESENTATION_END , // 27218
SID_NAVIGATOR_PAGENAME , // 27287
SID_NAVIGATOR_STATE , // 27288
@@ -169,7 +164,7 @@ public:
bool nextSlide();
bool previousSlide();
- void displayCurrentSlide( const Reference< XSlideShow >& xShow,
+ void displayCurrentSlide( const Reference< XSlideShow >& xShow,
const Reference< XDrawPagesSupplier>& xDrawPages,
const bool bSkipAllMainSequenceEffects );
@@ -349,7 +344,7 @@ bool AnimationSlideController::getSlideAPI( sal_Int32 nSlideNumber, Reference< X
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::AnimationSlideController::getSlideAPI(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -468,7 +463,7 @@ bool AnimationSlideController::previousSlide()
return jumpToSlideIndex( getPreviousSlideIndex() );
}
-void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow >& xShow,
+void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow >& xShow,
const Reference< XDrawPagesSupplier>& xDrawPages,
const bool bSkipAllMainSequenceEffects )
{
@@ -615,7 +610,7 @@ SlideshowImpl::~SlideshowImpl()
if( !mbDisposed )
{
- DBG_ERROR("SlideshowImpl::~SlideshowImpl(), component was not disposed!");
+ OSL_FAIL("SlideshowImpl::~SlideshowImpl(), component was not disposed!");
disposing();
}
}
@@ -635,7 +630,7 @@ void SAL_CALL SlideshowImpl::disposing()
maInputFreezeTimer.Stop();
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( !mxShow.is() )
return;
@@ -671,7 +666,7 @@ void SAL_CALL SlideshowImpl::disposing()
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::stop(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -789,13 +784,13 @@ void SAL_CALL SlideshowImpl::disposing()
mbDisposed = true;
}
-bool SlideshowImpl::startPreview(
+bool SlideshowImpl::startPreview(
const Reference< XDrawPage >& xDrawPage,
const Reference< XAnimationNode >& xAnimationNode,
::Window* pParent )
{
bool bRet = false;
-
+
try
{
const Reference<lang::XServiceInfo> xServiceInfo( xDrawPage, UNO_QUERY );
@@ -806,7 +801,7 @@ bool SlideshowImpl::startPreview(
if (supportedServices[pos].equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.drawing.MasterPage") )) {
- DBG_ERROR("sd::SlideshowImpl::startPreview() "
+ OSL_FAIL("sd::SlideshowImpl::startPreview() "
"not allowed on master page!");
return false;
}
@@ -873,7 +868,7 @@ bool SlideshowImpl::startPreview(
}
else
{
- DBG_ERROR("sd::SlideshowImpl::startPreview(), I need either a parent window or a viewshell!");
+ OSL_FAIL("sd::SlideshowImpl::startPreview(), I need either a parent window or a viewshell!");
}
resize( maPresSize );
@@ -900,7 +895,7 @@ bool SlideshowImpl::startPreview(
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::startPreview(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1047,10 +1042,6 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
Help::DisableContextHelp();
Help::DisableExtHelp();
- // mpTimeButton = new PushButton( mpShowWindow, SdResId( RID_TIME_BUTTON ) );
- // maPencil = Pointer( POINTER_PEN );
- // mpTimeButton->Hide();
-
if( maPresSettings.mbFullScreen )
{
// disable basic ide error handling
@@ -1075,18 +1066,6 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
// resize() at the SlideShow (this). Calling resize here results in a
// temporary display of a black window in the window's default size
-/*
- if ( mbRehearseTimings )
- {
- Size aButtonSizePixel( pTimeButton->GetSizePixel() );
- Point aButtonPosPixel( aButtonSizePixel.Width() >> 1, pShowWindow->GetSizePixel().Height() - aButtonSizePixel.Height() * 5 / 2);
-
- pTimeButton->SetPosPixel( aButtonPosPixel );
- aTimer.SetTimeoutHdl( LINK( this,FuSlideShow, TimeButtonTimeOutHdl ) );
- pTimeButton->SetClickHdl( LINK( this, FuSlideShow, TimeButtonHdl ) );
- }
-*/
-
if( mpView )
{
mpView->AddWindowToPaintView( mpShowWindow );
@@ -1110,14 +1089,14 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
OUString( RTL_CONSTASCII_USTRINGPARAM("AdvanceOnClick") ),
-1, Any( ! (maPresSettings.mbLockedPages != sal_False) ),
beans::PropertyState_DIRECT_VALUE ) );
-
+
aProperties.push_back(
beans::PropertyValue(
OUString( RTL_CONSTASCII_USTRINGPARAM("ImageAnimationsAllowed") ),
-1, Any( maPresSettings.mbAnimationAllowed != sal_False ),
beans::PropertyState_DIRECT_VALUE ) );
- const sal_Bool bZOrderEnabled(
+ const sal_Bool bZOrderEnabled(
SD_MOD()->GetSdOptions( mpDoc->GetDocumentType() )->IsSlideshowRespectZOrder() );
aProperties.push_back(
beans::PropertyValue(
@@ -1125,19 +1104,12 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
-1, Any( bZOrderEnabled == sal_False ),
beans::PropertyState_DIRECT_VALUE ) );
-/*
- aProperties.push_back(
- beans::PropertyValue(
- OUString( RTL_CONSTASCII_USTRINGPARAM("MouseVisible") ),
- -1, Any( maPresSettings.mbMouseVisible != sal_False ),
- beans::PropertyState_DIRECT_VALUE ) );
-*/
aProperties.push_back(
beans::PropertyValue(
OUString( RTL_CONSTASCII_USTRINGPARAM("ForceManualAdvance") ),
-1, Any( maPresSettings.mbManual != sal_False ),
beans::PropertyState_DIRECT_VALUE ) );
-
+
if( mbUsePen )
{
aProperties.push_back(
@@ -1163,7 +1135,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
}
bRet = startShowImpl( Sequence<beans::PropertyValue>(
- &aProperties[0], aProperties.size() ) );
+ &aProperties[0], aProperties.size() ) );
}
@@ -1172,7 +1144,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::startShow(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1189,10 +1161,10 @@ bool SlideshowImpl::startShowImpl( const Sequence< beans::PropertyValue >& aProp
try
{
mxShow = Reference< XSlideShow >( createSlideShow(), UNO_QUERY_THROW );
- mxView = mxView.createFromQuery( new SlideShowView(
- *mpShowWindow,
- mpDoc,
- meAnimationMode,
+ mxView = mxView.createFromQuery( new SlideShowView(
+ *mpShowWindow,
+ mpDoc,
+ meAnimationMode,
this,
maPresSettings.mbFullScreen) );
@@ -1235,7 +1207,7 @@ bool SlideshowImpl::startShowImpl( const Sequence< beans::PropertyValue >& aProp
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::startShowImpl(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1258,7 +1230,7 @@ void SlideshowImpl::onFirstPaint()
*/
}
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
maUpdateTimer.SetTimeout( (sal_uLong)100 );
maUpdateTimer.Start();
}
@@ -1274,7 +1246,7 @@ void SlideshowImpl::paint( const Rectangle& /* rRect */ )
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::paint(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1318,7 +1290,7 @@ void SlideshowImpl::removeShapeEvents()
WrappedShapeEventImplMap::iterator aIter;
const WrappedShapeEventImplMap::iterator aEnd( maShapeEventMap.end() );
- for( aIter = maShapeEventMap.begin(); aIter != aEnd; aIter++ )
+ for( aIter = maShapeEventMap.begin(); aIter != aEnd; ++aIter )
{
mxListenerProxy->removeShapeEventListener( (*aIter).first );
mxShow->setShapeCursor( (*aIter).first, awt::SystemPointer::ARROW );
@@ -1329,7 +1301,7 @@ void SlideshowImpl::removeShapeEvents()
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::removeShapeEvents(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1365,7 +1337,7 @@ void SlideshowImpl::registerShapeEvents(sal_Int32 nSlideNumber)
catch( Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::registerShapeEvents(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1445,7 +1417,7 @@ void SlideshowImpl::registerShapeEvents( Reference< XShapes >& xShapes ) throw(
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::registerShapeEvents(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1463,7 +1435,7 @@ void SlideshowImpl::displayCurrentSlide (const bool bSkipAllMainSequenceEffects)
if( mpSlideController.get() && mxShow.is() )
{
- Reference< XDrawPagesSupplier > xDrawPages( mpDoc->getUnoModel(),
+ Reference< XDrawPagesSupplier > xDrawPages( mpDoc->getUnoModel(),
UNO_QUERY_THROW );
mpSlideController->displayCurrentSlide( mxShow, xDrawPages, bSkipAllMainSequenceEffects );
registerShapeEvents(mpSlideController->getCurrentSlideNumber());
@@ -1482,14 +1454,6 @@ void SlideshowImpl::displayCurrentSlide (const bool bSkipAllMainSequenceEffects)
void SlideshowImpl::endPresentation()
{
-/*
- if( maPresSettings.mbMouseAsPen)
- {
- Reference< XMultiServiceFactory > xDocFactory(mpDoc->getUnoModel(), UNO_QUERY );
- if( xDocFactory.is() )
- mxShow->registerUserPaintPolygons(xDocFactory);
- }
-*/
if( !mnEndShowEvent )
mnEndShowEvent = Application::PostUserEvent( LINK(this, SlideshowImpl, endPresentationHdl) );
}
@@ -1509,7 +1473,7 @@ IMPL_LINK( SlideshowImpl, endPresentationHdl, void*, EMPTYARG )
void SAL_CALL SlideshowImpl::pause() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( !mbIsPaused ) try
{
@@ -1525,7 +1489,7 @@ void SAL_CALL SlideshowImpl::pause() throw (RuntimeException)
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::pause(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1538,7 +1502,7 @@ void SAL_CALL SlideshowImpl::pause() throw (RuntimeException)
void SAL_CALL SlideshowImpl::resume() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mbIsPaused ) try
{
@@ -1562,7 +1526,7 @@ void SAL_CALL SlideshowImpl::resume() throw (RuntimeException)
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::resume(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -1575,7 +1539,7 @@ void SAL_CALL SlideshowImpl::resume() throw (RuntimeException)
sal_Bool SAL_CALL SlideshowImpl::isPaused() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mbIsPaused;
}
@@ -1583,7 +1547,7 @@ sal_Bool SAL_CALL SlideshowImpl::isPaused() throw (RuntimeException)
void SAL_CALL SlideshowImpl::blankScreen( sal_Int32 nColor ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mpShowWindow && mpSlideController )
{
@@ -1600,7 +1564,7 @@ void SAL_CALL SlideshowImpl::blankScreen( sal_Int32 nColor ) throw (RuntimeExcep
void SlideshowImpl::click( const Reference< XShape >& xShape, const ::com::sun::star::awt::MouseEvent& /* aOriginalEvent */ )
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
WrappedShapeEventImplPtr pEvent = maShapeEventMap[xShape];
if( !pEvent.get() )
@@ -1628,7 +1592,7 @@ void SlideshowImpl::click( const Reference< XShape >& xShape, const ::com::sun::
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR("sd::SlideshowImpl::click(), exception caught!" );
+ OSL_FAIL("sd::SlideshowImpl::click(), exception caught!" );
}
}
break;
@@ -1731,7 +1695,7 @@ sal_Int32 SlideshowImpl::getSlideNumberForBookmark( const OUString& rStrBookmark
if( nPgNum == SDRPAGE_NOTFOUND )
{
- // Ist das Bookmark ein Objekt?
+ // Is the bookmark an object?
SdrObject* pObj = mpDoc->GetObj( aBookmark );
if( pObj )
@@ -1858,7 +1822,7 @@ sal_Int32 SlideshowImpl::getLastSlideNumber()
sal_Bool SAL_CALL SlideshowImpl::isEndless() throw( RuntimeException )
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return maPresSettings.mbEndless;
}
@@ -1874,7 +1838,7 @@ double SlideshowImpl::update()
void SlideshowImpl::startUpdateTimer()
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
maUpdateTimer.SetTimeout( 0 );
maUpdateTimer.Start();
}
@@ -1935,9 +1899,7 @@ sal_Int32 SlideshowImpl::updateSlideShow (void)
// G550, the frame rates were much more steadier with this
// tweak, although.
-// currently no solution, because this kills sound (at least on Windows)
-// // Boost our prio, as long as we're in the render loop
-// ::canvas::tools::PriorityBooster aBooster(2);
+ // currently no solution, because this kills sound (at least on Windows)
double fUpdate = 0.0;
if( !xShow->update(fUpdate) )
@@ -1981,7 +1943,7 @@ sal_Int32 SlideshowImpl::updateSlideShow (void)
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::updateSlideShow(), exception caught: ")
+ rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
@@ -2113,7 +2075,7 @@ bool SlideshowImpl::keyInput(const KeyEvent& rKEvt)
{
bRet = false;
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::keyInput(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -2239,13 +2201,13 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
Reference< ::com::sun::star::frame::XFrame > xFrame( pViewFrame->GetFrame().GetFrameInterface() );
if( xFrame.is() )
{
- pMenu->SetItemImage( CM_NEXT_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10617") ), sal_False, sal_False ) );
- pMenu->SetItemImage( CM_PREV_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10618") ), sal_False, sal_False ) );
+ pMenu->SetItemImage( CM_NEXT_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10617") ), sal_False ) );
+ pMenu->SetItemImage( CM_PREV_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10618") ), sal_False ) );
if( pPageMenu )
{
- pPageMenu->SetItemImage( CM_FIRST_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10616") ), sal_False, sal_False ) );
- pPageMenu->SetItemImage( CM_LAST_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10619") ), sal_False, sal_False ) );
+ pPageMenu->SetItemImage( CM_FIRST_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10616") ), sal_False ) );
+ pPageMenu->SetItemImage( CM_LAST_SLIDE, GetImage( xFrame, OUString( RTL_CONSTASCII_USTRINGPARAM( "slot:10619") ), sal_False ) );
}
}
}
@@ -2409,14 +2371,14 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
mbWasPaused = false;
}
break;
-
+
case CM_WIDTH_PEN_VERY_THIN:
{
setPenWidth(4.0);
mbWasPaused = false;
}
break;
-
+
case CM_WIDTH_PEN_THIN:
{
setPenWidth(100.0);
@@ -2447,7 +2409,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
case CM_ERASE_ALLINK:
{
setEraseAllInk(true);
- mbWasPaused = false;
+ mbWasPaused = false;
}
break;
case CM_PEN_MODE:
@@ -2495,11 +2457,11 @@ Reference< XSlideShow > SlideshowImpl::createSlideShow() const
try
{
- Reference< lang::XMultiServiceFactory > xFactory(
+ Reference< lang::XMultiServiceFactory > xFactory(
::comphelper::getProcessServiceFactory(),
UNO_QUERY_THROW );
- Reference< XInterface > xInt( xFactory->createInstance(
+ Reference< XInterface > xInt( xFactory->createInstance(
OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.SlideShow")) ) );
xShow.set( xInt, UNO_QUERY_THROW );
@@ -2507,7 +2469,7 @@ Reference< XSlideShow > SlideshowImpl::createSlideShow() const
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::createSlideShow(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -2534,7 +2496,7 @@ void SlideshowImpl::createSlideList( bool bAll, bool bStartWithActualSlide, cons
pCustomShow = NULL;
// create animation slide controller
- AnimationSlideController::Mode eMode =
+ AnimationSlideController::Mode eMode =
( pCustomShow && pCustomShow->Count() ) ? AnimationSlideController::CUSTOM :
(bAll ? AnimationSlideController::ALL : AnimationSlideController::FROM);
@@ -2622,7 +2584,6 @@ FncGetChildWindowId aShowChilds[] =
&SvxSearchDialogWrapper::GetChildWindowId,
&SvxBmpMaskChildWindow::GetChildWindowId,
&SvxIMapDlgChildWindow::GetChildWindowId,
- &SvxHyperlinkDlgWrapper::GetChildWindowId,
&SvxHlinkDlgWrapper::GetChildWindowId,
&SfxTemplateDialogWrapper::GetChildWindowId,
&GalleryChildWindow::GetChildWindowId
@@ -2708,17 +2669,6 @@ void SlideshowImpl::resize( const Size& rSize )
{
mpShowWindow->SetSizePixel( maPresSize );
mpShowWindow->Show();
-
- // Call ToTop() to bring the window to top if
- // a) the old size is not degenerate (then the window will be closed
- // soon) and
- // b) the animation mode is not that of a preview (on the one hand
- // this leaves the old behaviour for the slide show mode unmodified
- // and on the other hand does not move the focus from the document
- // to the (preview) window; the ToTop() seems not to be necessary at
- // least for the preview).
-// if( !aOldSize.Width() && !aOldSize.Height() )
-// mpShowWindow->ToTop();
}
if( mxView.is() ) try
@@ -2729,7 +2679,7 @@ void SlideshowImpl::resize( const Size& rSize )
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::resize(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -2762,7 +2712,7 @@ void SlideshowImpl::setActiveXToolbarsVisible( sal_Bool bVisible )
>>= xLayoutManager )
&& xLayoutManager.is() )
{
- xLayoutManager->setVisible( bVisible );
+ xLayoutManager->setVisible( bVisible );
}
}
catch( uno::Exception& )
@@ -2776,7 +2726,7 @@ void SlideshowImpl::setActiveXToolbarsVisible( sal_Bool bVisible )
void SAL_CALL SlideshowImpl::activate() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
maDeactivateTimer.Stop();
@@ -2817,7 +2767,7 @@ void SAL_CALL SlideshowImpl::activate() throw (RuntimeException)
void SAL_CALL SlideshowImpl::deactivate() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mbActive && mxShow.is() )
{
@@ -2853,7 +2803,7 @@ IMPL_LINK( SlideshowImpl, deactivateHdl, Timer*, EMPTYARG )
sal_Bool SAL_CALL SlideshowImpl::isActive() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mbActive;
}
@@ -2920,24 +2870,24 @@ void SlideshowImpl::setAutoSaveState( bool bOn)
uno::Reference<lang::XMultiServiceFactory> xFac( ::comphelper::getProcessServiceFactory() );
uno::Reference< util::XURLTransformer > xParser(
- xFac->createInstance( OUString::createFromAscii("com.sun.star.util.URLTransformer" ) ),
+ xFac->createInstance( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.URLTransformer" )) ),
uno::UNO_QUERY_THROW);
util::URL aURL;
- aURL.Complete = OUString::createFromAscii("vnd.sun.star.autorecovery:/setAutoSaveState");
+ aURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.autorecovery:/setAutoSaveState"));
xParser->parseStrict(aURL);
Sequence< beans::PropertyValue > aArgs(1);
- aArgs[0].Name = OUString::createFromAscii("AutoSaveState");
+ aArgs[0].Name = OUString(RTL_CONSTASCII_USTRINGPARAM("AutoSaveState"));
aArgs[0].Value <<= bOn ? sal_True : sal_False;
uno::Reference< frame::XDispatch > xAutoSave(
- xFac->createInstance(OUString::createFromAscii("com.sun.star.frame.AutoRecovery")),
+ xFac->createInstance(OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.AutoRecovery"))),
uno::UNO_QUERY_THROW);
xAutoSave->dispatch(aURL, aArgs);
}
catch( Exception& )
{
- DBG_ERROR("sd::SlideshowImpl::setAutoSaveState(), exception caught!");
+ OSL_FAIL("sd::SlideshowImpl::setAutoSaveState(), exception caught!");
}
}
@@ -2945,7 +2895,7 @@ void SlideshowImpl::setAutoSaveState( bool bOn)
Reference< XDrawPage > SAL_CALL SlideshowImpl::getCurrentSlide() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
Reference< XDrawPage > xSlide;
if( mxShow.is() && mpSlideController.get() )
@@ -2962,7 +2912,7 @@ Reference< XDrawPage > SAL_CALL SlideshowImpl::getCurrentSlide() throw (RuntimeE
sal_Int32 SAL_CALL SlideshowImpl::getNextSlideIndex() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxShow.is() )
{
@@ -3002,7 +2952,7 @@ Reference< XDrawPage > SAL_CALL SlideshowImpl::getSlideByIndex(::sal_Int32 Index
sal_Bool SAL_CALL SlideshowImpl::getAlwaysOnTop() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return maPresSettings.mbAlwaysOnTop;
}
@@ -3010,7 +2960,7 @@ sal_Bool SAL_CALL SlideshowImpl::getAlwaysOnTop() throw (RuntimeException)
void SAL_CALL SlideshowImpl::setAlwaysOnTop( sal_Bool bAlways ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( maPresSettings.mbAlwaysOnTop != bAlways )
{
maPresSettings.mbAlwaysOnTop = bAlways;
@@ -3022,7 +2972,7 @@ void SAL_CALL SlideshowImpl::setAlwaysOnTop( sal_Bool bAlways ) throw (RuntimeEx
sal_Bool SAL_CALL SlideshowImpl::isFullScreen() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return maPresSettings.mbFullScreen;
}
@@ -3030,7 +2980,7 @@ sal_Bool SAL_CALL SlideshowImpl::isFullScreen() throw (RuntimeException)
sal_Bool SAL_CALL SlideshowImpl::getMouseVisible() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return maPresSettings.mbMouseVisible;
}
@@ -3038,7 +2988,7 @@ sal_Bool SAL_CALL SlideshowImpl::getMouseVisible() throw (RuntimeException)
void SAL_CALL SlideshowImpl::setMouseVisible( sal_Bool bVisible ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( maPresSettings.mbMouseVisible != bVisible )
{
maPresSettings.mbMouseVisible = bVisible;
@@ -3051,7 +3001,7 @@ void SAL_CALL SlideshowImpl::setMouseVisible( sal_Bool bVisible ) throw (Runtime
sal_Bool SAL_CALL SlideshowImpl::getUsePen() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mbUsePen;
}
@@ -3059,7 +3009,7 @@ sal_Bool SAL_CALL SlideshowImpl::getUsePen() throw (RuntimeException)
void SAL_CALL SlideshowImpl::setUsePen( sal_Bool bMouseAsPen ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
mbUsePen = bMouseAsPen;
if( mxShow.is() ) try
{
@@ -3083,14 +3033,14 @@ void SAL_CALL SlideshowImpl::setUsePen( sal_Bool bMouseAsPen ) throw (RuntimeExc
// for Pen Mode
beans::PropertyValue aPenPropSwitchPenMode;
aPenPropSwitchPenMode.Name = OUString( RTL_CONSTASCII_USTRINGPARAM( "SwitchPenMode" ));
- aPenPropSwitchPenMode.Value <<= sal_True;
+ aPenPropSwitchPenMode.Value <<= sal_True;
mxShow->setProperty( aPenPropSwitchPenMode );
}
}
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::setUsePen(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -3103,7 +3053,7 @@ void SAL_CALL SlideshowImpl::setUsePen( sal_Bool bMouseAsPen ) throw (RuntimeExc
double SAL_CALL SlideshowImpl::getPenWidth() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mdUserPaintStrokeWidth;
}
@@ -3111,7 +3061,7 @@ double SAL_CALL SlideshowImpl::getPenWidth() throw (RuntimeException)
void SAL_CALL SlideshowImpl::setPenWidth( double dStrokeWidth ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
mdUserPaintStrokeWidth = dStrokeWidth;
setUsePen( true ); // enable pen mode, update color and width
}
@@ -3120,7 +3070,7 @@ void SAL_CALL SlideshowImpl::setPenWidth( double dStrokeWidth ) throw (RuntimeEx
sal_Int32 SAL_CALL SlideshowImpl::getPenColor() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mnUserPaintColor;
}
@@ -3128,7 +3078,7 @@ sal_Int32 SAL_CALL SlideshowImpl::getPenColor() throw (RuntimeException)
void SAL_CALL SlideshowImpl::setPenColor( sal_Int32 nColor ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
mnUserPaintColor = nColor;
setUsePen( true ); // enable pen mode, update color
}
@@ -3143,7 +3093,7 @@ void SAL_CALL SlideshowImpl::setUseEraser( ::sal_Bool /*_usepen*/ ) throw (css::
void SAL_CALL SlideshowImpl::setPenMode( bool bSwitchPenMode ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
setUsePen( bSwitchPenMode ); // SwitchPen Mode
}
@@ -3154,7 +3104,7 @@ void SAL_CALL SlideshowImpl::setEraseAllInk(bool bEraseAllInk) throw (RuntimeExc
{
if( bEraseAllInk )
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxShow.is() ) try
{
beans::PropertyValue aPenPropEraseAllInk;
@@ -3165,7 +3115,7 @@ void SAL_CALL SlideshowImpl::setEraseAllInk(bool bEraseAllInk) throw (RuntimeExc
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_TRACE(
(OString("sd::SlideshowImpl::setEraseAllInk(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -3189,7 +3139,7 @@ void SAL_CALL SlideshowImpl::setEraserMode( bool /*bSwitchEraserMode*/ ) throw (
sal_Bool SAL_CALL SlideshowImpl::isRunning( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
return mxShow.is();
}
@@ -3197,7 +3147,7 @@ sal_Bool SAL_CALL SlideshowImpl::isRunning( ) throw (RuntimeException)
void SAL_CALL SlideshowImpl::gotoNextEffect( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxShow.is() && mpSlideController.get() && mpShowWindow )
{
@@ -3225,7 +3175,7 @@ void SAL_CALL SlideshowImpl::gotoNextEffect( ) throw (RuntimeException)
void SAL_CALL SlideshowImpl::gotoPreviousEffect( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxShow.is() && mpSlideController.get() && mpShowWindow )
{
@@ -3249,7 +3199,7 @@ void SAL_CALL SlideshowImpl::gotoPreviousEffect( ) throw (RuntimeException)
void SAL_CALL SlideshowImpl::gotoFirstSlide( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mpShowWindow && mpSlideController.get() )
{
@@ -3272,7 +3222,7 @@ void SAL_CALL SlideshowImpl::gotoFirstSlide( ) throw (RuntimeException)
void SAL_CALL SlideshowImpl::gotoNextSlide( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mbIsPaused )
resume();
@@ -3327,7 +3277,8 @@ void SAL_CALL SlideshowImpl::gotoNextSlide( ) throw (RuntimeException)
if( mpShowWindow )
{
mpShowWindow->SetEndMode();
- pause();
+ if( !mpViewShell->GetDoc()->IsStartWithPresentation() )
+ pause();
}
}
}
@@ -3344,7 +3295,7 @@ void SAL_CALL SlideshowImpl::gotoPreviousSlide( ) throw (RuntimeException)
void SlideshowImpl::gotoPreviousSlide (const bool bSkipAllMainSequenceEffects)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxShow.is() && mpSlideController.get() ) try
{
@@ -3385,7 +3336,7 @@ void SlideshowImpl::gotoPreviousSlide (const bool bSkipAllMainSequenceEffects)
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::gotoPreviousSlide(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -3398,7 +3349,7 @@ void SlideshowImpl::gotoPreviousSlide (const bool bSkipAllMainSequenceEffects)
void SAL_CALL SlideshowImpl::gotoLastSlide() throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mpSlideController.get() )
{
@@ -3424,7 +3375,7 @@ void SAL_CALL SlideshowImpl::gotoLastSlide() throw (RuntimeException)
void SAL_CALL SlideshowImpl::gotoBookmark( const OUString& rBookmark ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mbIsPaused )
resume();
@@ -3439,7 +3390,7 @@ void SAL_CALL SlideshowImpl::gotoBookmark( const OUString& rBookmark ) throw (Ru
void SAL_CALL SlideshowImpl::gotoSlide( const Reference< XDrawPage >& xSlide )
throw(IllegalArgumentException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mpSlideController.get() && xSlide.is() )
{
@@ -3461,7 +3412,7 @@ void SAL_CALL SlideshowImpl::gotoSlide( const Reference< XDrawPage >& xSlide )
void SAL_CALL SlideshowImpl::gotoSlideIndex( sal_Int32 nIndex ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mbIsPaused )
resume();
@@ -3473,7 +3424,7 @@ void SAL_CALL SlideshowImpl::gotoSlideIndex( sal_Int32 nIndex ) throw (RuntimeEx
void SAL_CALL SlideshowImpl::stopSound( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
try
{
@@ -3486,7 +3437,7 @@ void SAL_CALL SlideshowImpl::stopSound( ) throw (RuntimeException)
catch( Exception& e )
{
static_cast<void>(e);
- DBG_ERROR(
+ OSL_FAIL(
(OString("sd::SlideshowImpl::stopSound(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -3834,7 +3785,7 @@ void SlideShowListenerProxy::slideEnded(sal_Bool bReverse) throw (RuntimeExcepti
}
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxController.is() )
mxController->slideEnded(bReverse);
}
@@ -3852,7 +3803,7 @@ void SlideShowListenerProxy::hyperLinkClicked( rtl::OUString const& aHyperLink )
}
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxController.is() )
mxController->hyperLinkClicked(aHyperLink);
}
@@ -3875,9 +3826,11 @@ void SAL_CALL SlideShowListenerProxy::disposing( const ::com::sun::star::lang::E
void SAL_CALL SlideShowListenerProxy::click( const Reference< XShape >& xShape, const ::com::sun::star::awt::MouseEvent& aOriginalEvent ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
if( mxController.is() )
mxController->click(xShape, aOriginalEvent );
}
} // namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/slideshowimpl.hxx b/sd/source/ui/slideshow/slideshowimpl.hxx
index 5279b1b25..c507de8f6 100755..100644
--- a/sd/source/ui/slideshow/slideshowimpl.hxx
+++ b/sd/source/ui/slideshow/slideshowimpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,9 +69,7 @@
#include <svx/svdpagv.hxx>
#include <svx/fmshell.hxx>
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include "sdmod.hxx"
#include "cusshow.hxx"
#include "ViewShellBase.hxx"
@@ -85,9 +84,7 @@
#include "FrameView.hxx"
#include "DrawDocShell.hxx"
-#ifndef _SD_APP_HRC_
#include "app.hrc"
-#endif
#include "slideshow.hxx"
@@ -425,3 +422,5 @@ private:
} // namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/slideshowviewimpl.cxx b/sd/source/ui/slideshow/slideshowviewimpl.cxx
index adb0dc80d..25aac7504 100644
--- a/sd/source/ui/slideshow/slideshowviewimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowviewimpl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,7 +30,7 @@
#include "precompiled_sd.hxx"
#include <slideshowviewimpl.hxx>
#include <slideshowimpl.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <com/sun/star/beans/XPropertySet.hpp>
@@ -319,7 +320,7 @@ void SAL_CALL SlideShowView::clear() throw (::com::sun::star::uno::RuntimeExcept
{
// paint background in black
::osl::MutexGuard aGuard( m_aMutex );
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
// fill the bounds rectangle in black
// ----------------------------------
@@ -343,7 +344,7 @@ void SAL_CALL SlideShowView::clear() throw (::com::sun::star::uno::RuntimeExcept
geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
const Size& rTmpSize( mrOutputWindow.GetSizePixel() );
@@ -352,11 +353,7 @@ geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) throw (Ru
return geometry::AffineMatrix2D (1,0,0,0,1,0);
}
- // Reduce available width by one, as the slides might actually
- // render one pixel wider and higher as aPageSize below specifies
- // (when shapes of page size have visible border lines)
- const Size aWindowSize( rTmpSize.Width()-1,
- rTmpSize.Height()-1 );
+ const Size aWindowSize( mrOutputWindow.GetSizePixel() );
Size aOutputSize( aWindowSize );
if( meAnimationMode != ANIMATIONMODE_SHOW )
@@ -383,6 +380,12 @@ geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) throw (Ru
Point aOutputOffset( ( aWindowSize.Width() - aOutputSize.Width() ) >> 1,
( aWindowSize.Height() - aOutputSize.Height() ) >> 1 );
+ // Reduce available width by one, as the slides might actually
+ // render one pixel wider and higher as aPageSize below specifies
+ // (when shapes of page size have visible border lines)
+ aOutputSize.Width() --;
+ aOutputSize.Height() --;
+
maPresentationArea = Rectangle( aOutputOffset, aOutputSize );
mrOutputWindow.SetPresentationArea( maPresentationArea );
@@ -499,7 +502,17 @@ void SlideShowView::updateimpl( ::osl::ClearableMutexGuard& rGuard, SlideshowImp
if( pSlideShow )
{
::rtl::Reference< SlideshowImpl > aSLGuard( pSlideShow );
- rGuard.clear();
+
+ if( mbFirstPaint )
+ {
+ mbFirstPaint = false;
+ SlideshowImpl* pTmpSlideShow = mpSlideShow;
+ rGuard.clear();
+ if( pTmpSlideShow )
+ pTmpSlideShow->onFirstPaint();
+ } else
+ rGuard.clear();
+
pSlideShow->startUpdateTimer();
}
}
@@ -683,3 +696,5 @@ void SlideShowView::init()
}
} // namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slideshow/slideshowviewimpl.hxx b/sd/source/ui/slideshow/slideshowviewimpl.hxx
index 12af70540..ab0d51cf2 100644
--- a/sd/source/ui/slideshow/slideshowviewimpl.hxx
+++ b/sd/source/ui/slideshow/slideshowviewimpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,9 +63,7 @@
#include <svx/svdpagv.hxx>
#include <svx/fmshell.hxx>
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include "sdmod.hxx"
#include "cusshow.hxx"
#include "ViewShellBase.hxx"
@@ -78,9 +77,7 @@
#include "FrameView.hxx"
#include "DrawDocShell.hxx"
-#ifndef _SD_APP_HRC_
#include "app.hrc"
-#endif
namespace sd
{
@@ -284,3 +281,5 @@ private:
} // namespace ::sd
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapCache.cxx b/sd/source/ui/slidesorter/cache/SlsBitmapCache.cxx
index a57e151c3..721b424a6 100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapCache.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -104,7 +105,7 @@ public:
};
class BitmapCache::CacheBitmapContainer
- : public ::std::hash_map<CacheKey, CacheEntry, CacheHash>
+ : public ::boost::unordered_map<CacheKey, CacheEntry, CacheHash>
{
public:
CacheBitmapContainer (void) {}
@@ -701,3 +702,5 @@ inline bool BitmapCache::CacheEntry::HasLosslessReplacement (void) const
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx b/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx
index fbf71c587..f1ae4bfe9 100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,8 +34,8 @@ class SdrPage;
#include <vcl/bitmapex.hxx>
#include <osl/mutex.hxx>
#include <boost/shared_ptr.hpp>
+#include <boost/unordered_map.hpp>
#include <boost/scoped_ptr.hpp>
-#include <hash_map>
namespace sd { namespace slidesorter { namespace cache {
@@ -233,3 +234,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx
index 1cf4f3d40..73dfe0ba0 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -248,3 +249,5 @@ bool PngCompression::IsLossless (void) const
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx
index f6699d6ce..213ac6151 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,3 +155,5 @@ public:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx
index e3dbf4e43..13f447700 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,4 @@ Bitmap BitmapFactory::CreateBitmap (
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.hxx b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.hxx
index 566ff0aca..83d83c71a 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsCacheCompactor.cxx b/sd/source/ui/slidesorter/cache/SlsCacheCompactor.cxx
index f67eb7963..2eb3d5495 100644
--- a/sd/source/ui/slidesorter/cache/SlsCacheCompactor.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsCacheCompactor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -234,3 +235,5 @@ void CacheCompactionByCompression::Run (void)
} // end of anonymous namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsCacheCompactor.hxx b/sd/source/ui/slidesorter/cache/SlsCacheCompactor.hxx
index 80e9d2aaa..cd8067056 100644
--- a/sd/source/ui/slidesorter/cache/SlsCacheCompactor.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsCacheCompactor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.cxx b/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.cxx
index 589b681dc..89f0b7c95 100644
--- a/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,48 +30,52 @@
#include "precompiled_sd.hxx"
#include "SlsCacheConfiguration.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
+#include <rtl/instance.hxx>
#include <vcl/svapp.hxx>
#include <comphelper/processfactory.hxx>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
-#ifndef _COM_SUN_STAR_CONTAINER_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
namespace sd { namespace slidesorter { namespace cache {
-::boost::shared_ptr<CacheConfiguration> CacheConfiguration::mpInstance;
+namespace
+{
+ typedef ::boost::shared_ptr<CacheConfiguration> CacheConfigSharedPtr;
+ class theInstance :
+ public rtl::Static<CacheConfigSharedPtr, theInstance> {};
+}
+
::boost::weak_ptr<CacheConfiguration> CacheConfiguration::mpWeakInstance;
Timer CacheConfiguration::maReleaseTimer;
-
-
::boost::shared_ptr<CacheConfiguration> CacheConfiguration::Instance (void)
{
- ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
- if (mpInstance.get() == NULL)
+ SolarMutexGuard aSolarGuard;
+ CacheConfigSharedPtr &rInstancePtr = theInstance::get();
+ if (rInstancePtr.get() == NULL)
{
// Maybe somebody else kept a previously created instance alive.
if ( ! mpWeakInstance.expired())
- mpInstance = ::boost::shared_ptr<CacheConfiguration>(mpWeakInstance);
- if (mpInstance.get() == NULL)
+ rInstancePtr = ::boost::shared_ptr<CacheConfiguration>(mpWeakInstance);
+ if (rInstancePtr.get() == NULL)
{
// We have to create a new instance.
- mpInstance.reset(new CacheConfiguration());
- mpWeakInstance = mpInstance;
+ rInstancePtr.reset(new CacheConfiguration());
+ mpWeakInstance = rInstancePtr;
// Prepare to release this instance in the near future.
maReleaseTimer.SetTimeoutHdl(
- LINK(mpInstance.get(),CacheConfiguration,TimerCallback));
+ LINK(rInstancePtr.get(),CacheConfiguration,TimerCallback));
maReleaseTimer.SetTimeout(5000 /* 5s */);
maReleaseTimer.Start();
}
}
- return mpInstance;
+ return rInstancePtr;
}
@@ -87,59 +92,55 @@ CacheConfiguration::CacheConfiguration (void)
const ::rtl::OUString sPathToNode(
RTL_CONSTASCII_USTRINGPARAM(
"MultiPaneGUI/SlideSorter/PreviewCache"));
-
+
try
{
- do
- {
- // Obtain access to the configuration.
- Reference<lang::XMultiServiceFactory> xProvider (
- ::comphelper::getProcessServiceFactory()->createInstance(
- sConfigurationProviderServiceName),
- UNO_QUERY);
- if ( ! xProvider.is())
- break;
-
- // Obtain access to Impress configuration.
- Sequence<Any> aCreationArguments(3);
- aCreationArguments[0] = makeAny(beans::PropertyValue(
- ::rtl::OUString(
- RTL_CONSTASCII_USTRINGPARAM("nodepath")),
- 0,
- makeAny(sPathToImpressConfigurationRoot),
- beans::PropertyState_DIRECT_VALUE));
- aCreationArguments[1] = makeAny(beans::PropertyValue(
- ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("depth")),
- 0,
- makeAny((sal_Int32)-1),
- beans::PropertyState_DIRECT_VALUE));
- aCreationArguments[2] = makeAny(beans::PropertyValue(
- ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("lazywrite")),
- 0,
- makeAny(true),
- beans::PropertyState_DIRECT_VALUE));
- ::rtl::OUString sAccessService (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
- "com.sun.star.configuration.ConfigurationAccess")));
- Reference<XInterface> xRoot (xProvider->createInstanceWithArguments(
- sAccessService, aCreationArguments));
- if ( ! xRoot.is())
- break;
- Reference<container::XHierarchicalNameAccess> xHierarchy (xRoot, UNO_QUERY);
- if ( ! xHierarchy.is())
- break;
-
- // Get the node for the slide sorter preview cache.
- mxCacheNode = Reference<container::XNameAccess>(
- xHierarchy->getByHierarchicalName(sPathToNode),
- UNO_QUERY);
- }
- while (false);
+ // Obtain access to the configuration.
+ Reference<lang::XMultiServiceFactory> xProvider (
+ ::comphelper::getProcessServiceFactory()->createInstance(
+ sConfigurationProviderServiceName),
+ UNO_QUERY);
+ if ( ! xProvider.is())
+ return;
+
+ // Obtain access to Impress configuration.
+ Sequence<Any> aCreationArguments(3);
+ aCreationArguments[0] = makeAny(beans::PropertyValue(
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("nodepath")),
+ 0,
+ makeAny(sPathToImpressConfigurationRoot),
+ beans::PropertyState_DIRECT_VALUE));
+ aCreationArguments[1] = makeAny(beans::PropertyValue(
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("depth")),
+ 0,
+ makeAny((sal_Int32)-1),
+ beans::PropertyState_DIRECT_VALUE));
+ aCreationArguments[2] = makeAny(beans::PropertyValue(
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("lazywrite")),
+ 0,
+ makeAny(true),
+ beans::PropertyState_DIRECT_VALUE));
+ ::rtl::OUString sAccessService (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "com.sun.star.configuration.ConfigurationAccess")));
+ Reference<XInterface> xRoot (xProvider->createInstanceWithArguments(
+ sAccessService, aCreationArguments));
+ if ( ! xRoot.is())
+ return;
+ Reference<container::XHierarchicalNameAccess> xHierarchy (xRoot, UNO_QUERY);
+ if ( ! xHierarchy.is())
+ return;
+
+ // Get the node for the slide sorter preview cache.
+ mxCacheNode = Reference<container::XNameAccess>(
+ xHierarchy->getByHierarchicalName(sPathToNode),
+ UNO_QUERY);
}
- catch (RuntimeException aException)
+ catch (RuntimeException &aException)
{
(void)aException;
}
- catch (Exception aException)
+ catch (Exception &aException)
{
(void)aException;
}
@@ -158,7 +159,7 @@ Any CacheConfiguration::GetValue (const ::rtl::OUString& rName)
{
aResult = mxCacheNode->getByName(rName);
}
- catch (Exception aException)
+ catch (Exception &aException)
{
(void)aException;
}
@@ -172,10 +173,13 @@ Any CacheConfiguration::GetValue (const ::rtl::OUString& rName)
IMPL_LINK(CacheConfiguration,TimerCallback, Timer*,EMPTYARG)
{
+ CacheConfigSharedPtr &rInstancePtr = theInstance::get();
// Release out reference to the instance.
- mpInstance.reset();
+ rInstancePtr.reset();
return 0;
}
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.hxx b/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.hxx
index d683afae8..6e7174bad 100644
--- a/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsCacheConfiguration.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,7 +56,6 @@ public:
::com::sun::star::uno::Any GetValue (const ::rtl::OUString& rName);
private:
- static ::boost::shared_ptr<CacheConfiguration> mpInstance;
/** When a caller holds a reference after we have released ours we use
this weak pointer to avoid creating a new instance.
*/
@@ -72,3 +72,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsGenericPageCache.cxx b/sd/source/ui/slidesorter/cache/SlsGenericPageCache.cxx
index 226ca82fe..98c295b91 100644
--- a/sd/source/ui/slidesorter/cache/SlsGenericPageCache.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsGenericPageCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -377,3 +378,4 @@ void GenericPageCache::Resume (void)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx b/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx
index 4ec1e86f0..ba73f2e49 100644
--- a/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -166,3 +167,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsPageCache.cxx b/sd/source/ui/slidesorter/cache/SlsPageCache.cxx
index ef5993333..9242aa3fd 100644
--- a/sd/source/ui/slidesorter/cache/SlsPageCache.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsPageCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -164,3 +165,5 @@ void PageCache::Resume (void)
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx b/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
index 973318b9e..855810739 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsPageCacheManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -132,7 +133,7 @@ namespace sd { namespace slidesorter { namespace cache {
/** Container for the active caches.
*/
class PageCacheManager::PageCacheContainer
- : public ::std::hash_map<CacheDescriptor,
+ : public ::boost::unordered_map<CacheDescriptor,
::boost::shared_ptr<PageCacheManager::Cache>,
CacheDescriptor::Hash,
CacheDescriptor::Equal>
@@ -146,7 +147,7 @@ public:
class CompareWithCache { public:
CompareWithCache(const ::boost::shared_ptr<PageCacheManager::Cache>& rpCache)
: mpCache(rpCache) {}
- bool operator () (const PageCacheContainer::value_type& rValue)
+ bool operator () (const PageCacheContainer::value_type& rValue) const
{ return rValue.second == mpCache; }
private:
::boost::shared_ptr<PageCacheManager::Cache> mpCache;
@@ -487,3 +488,5 @@ void PageCacheManager::PutRecentlyUsedCache(
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx b/sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx
index fc98236a9..ff404eef4 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -221,15 +222,15 @@ void QueueProcessor::ProcessOneRequest (
}
}
}
- catch (::com::sun::star::uno::RuntimeException aException)
+ catch (::com::sun::star::uno::RuntimeException &aException)
{
(void) aException;
- OSL_ASSERT("RuntimeException caught in QueueProcessor");
+ OSL_FAIL("RuntimeException caught in QueueProcessor");
}
- catch (::com::sun::star::uno::Exception aException)
+ catch (::com::sun::star::uno::Exception &aException)
{
(void) aException;
- OSL_ASSERT("Exception caught in QueueProcessor");
+ OSL_FAIL("Exception caught in QueueProcessor");
}
}
@@ -254,3 +255,5 @@ void QueueProcessor::SetBitmapCache (
} } } // end of namespace ::sd::slidesorter::cache
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx b/sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx
index 8823e7309..1f4170f51 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -138,3 +139,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsQueueProcessorThread.hxx b/sd/source/ui/slidesorter/cache/SlsQueueProcessorThread.hxx
index c308257c0..ca9a11862 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsQueueProcessorThread.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsQueueProcessorThread.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -193,7 +194,7 @@ void QueueProcessorThread<Queue, Request, Cache, Factory>
if (mrQueue.IsEmpty())
break;
}
- ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard (maMutex);
if (mbIsTerminated)
break;
@@ -285,7 +286,7 @@ void QueueProcessorThread<
Queue, RequestData, BitmapCache, BitmapFactory
>::Terminate (void)
{
- // ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ // SolarMutexGuard aSolarGuard;
::osl::Thread::terminate ();
{
::osl::MutexGuard aGuard (maMutex);
@@ -317,3 +318,5 @@ void SAL_CALL QueueProcessorThread<
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestFactory.cxx b/sd/source/ui/slidesorter/cache/SlsRequestFactory.cxx
index 00336c58d..4324796a4 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestFactory.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,4 @@ void RequestFactory::operator()(
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestFactory.hxx b/sd/source/ui/slidesorter/cache/SlsRequestFactory.hxx
index 0e802055e..f908598de 100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestFactory.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,3 +47,5 @@ public:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestPriorityClass.hxx b/sd/source/ui/slidesorter/cache/SlsRequestPriorityClass.hxx
index cf05e5bb7..077940a82 100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestPriorityClass.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestPriorityClass.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ enum RequestPriorityClass
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
index b3ad0c2d0..a4c8d072b 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -287,3 +288,4 @@ void RequestQueue::Clear (void)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx b/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
index e1a618b1c..5b9c0cdb2 100755..100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -131,3 +132,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/cache/makefile.mk b/sd/source/ui/slidesorter/cache/makefile.mk
deleted file mode 100755
index 58862a286..000000000
--- a/sd/source/ui/slidesorter/cache/makefile.mk
+++ /dev/null
@@ -1,64 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slscache
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/SlsBitmapCache.obj \
- $(SLO)$/SlsBitmapCompressor.obj \
- $(SLO)$/SlsBitmapFactory.obj \
- $(SLO)$/SlsCacheCompactor.obj \
- $(SLO)$/SlsCacheConfiguration.obj \
- $(SLO)$/SlsGenericPageCache.obj \
- $(SLO)$/SlsPageCache.obj \
- $(SLO)$/SlsPageCacheManager.obj \
- $(SLO)$/SlsQueueProcessor.obj \
- $(SLO)$/SlsRequestFactory.obj \
- $(SLO)$/SlsRequestQueue.obj
-
-
-EXCEPTIONSFILES=
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slidesorter/controller/SlideSorterController.cxx b/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
index b920b900e..984d01663 100644
--- a/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
+++ b/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -193,7 +194,7 @@ SlideSorterController::~SlideSorterController (void)
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR( "sd::SlideSorterController::~SlideSorterController(), exception caught!" );
+ OSL_FAIL( "sd::SlideSorterController::~SlideSorterController(), exception caught!" );
}
// dispose should have been called by now so that nothing is to be done
@@ -374,7 +375,7 @@ bool SlideSorterController::Command (
if (pWindow == NULL)
return false;
-
+
ViewShell* pViewShell = mrSlideSorter.GetViewShell();
if (pViewShell == NULL)
return false;
@@ -994,45 +995,41 @@ void SlideSorterController::PageNameHasChanged (int nPageIndex, const String& rs
// Get a pointer to the corresponding accessible object and notify
// that of the name change.
- do
- {
SharedSdWindow pWindow (mrSlideSorter.GetContentWindow());
if ( ! pWindow)
- break;
+ return;
- ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >
- xAccessible (pWindow->GetAccessible(sal_False));
- if ( ! xAccessible.is())
- break;
+ ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >
+ xAccessible (pWindow->GetAccessible(sal_False));
+ if ( ! xAccessible.is())
+ return;
- // Now comes a small hack. We assume that the accessible object is
- // an instantiation of AccessibleSlideSorterView and cast it to that
- // class. The cleaner alternative to this cast would be a new member
- // in which we would store the last AccessibleSlideSorterView object
- // created by SlideSorterViewShell::CreateAccessibleDocumentView().
- // But then there is no guaranty that the accessible object obtained
- // from the window really is that instance last created by
- // CreateAccessibleDocumentView().
- // However, the dynamic cast together with the check of the result
- // being NULL should be safe enough.
- ::accessibility::AccessibleSlideSorterView* pAccessibleView
- = dynamic_cast< ::accessibility::AccessibleSlideSorterView*>(xAccessible.get());
- if (pAccessibleView == NULL)
- break;
+ // Now comes a small hack. We assume that the accessible object is
+ // an instantiation of AccessibleSlideSorterView and cast it to that
+ // class. The cleaner alternative to this cast would be a new member
+ // in which we would store the last AccessibleSlideSorterView object
+ // created by SlideSorterViewShell::CreateAccessibleDocumentView().
+ // But then there is no guaranty that the accessible object obtained
+ // from the window really is that instance last created by
+ // CreateAccessibleDocumentView().
+ // However, the dynamic cast together with the check of the result
+ // being NULL should be safe enough.
+ ::accessibility::AccessibleSlideSorterView* pAccessibleView
+ = dynamic_cast< ::accessibility::AccessibleSlideSorterView*>(xAccessible.get());
+ if (pAccessibleView == NULL)
+ return;
- ::accessibility::AccessibleSlideSorterObject* pChild
- = pAccessibleView->GetAccessibleChildImplementation(nPageIndex);
- if (pChild == NULL || pChild->GetPage() == NULL)
- break;
+ ::accessibility::AccessibleSlideSorterObject* pChild
+ = pAccessibleView->GetAccessibleChildImplementation(nPageIndex);
+ if (pChild == NULL || pChild->GetPage() == NULL)
+ return;
- ::rtl::OUString sOldName (rsOldName);
- ::rtl::OUString sNewName (pChild->GetPage()->GetName());
- pChild->FireAccessibleEvent(
- ::com::sun::star::accessibility::AccessibleEventId::NAME_CHANGED,
- makeAny(sOldName),
- makeAny(sNewName));
- }
- while (false);
+ ::rtl::OUString sOldName (rsOldName);
+ ::rtl::OUString sNewName (pChild->GetPage()->GetName());
+ pChild->FireAccessibleEvent(
+ ::com::sun::star::accessibility::AccessibleEventId::NAME_CHANGED,
+ makeAny(sOldName),
+ makeAny(sNewName));
}
@@ -1133,3 +1130,5 @@ void SlideSorterController::ModelChangeLock::Release (void)
}
} } } // end of namespace ::sd::slidesorter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsAnimationFunction.cxx b/sd/source/ui/slidesorter/controller/SlsAnimationFunction.cxx
index bcfb01a4f..ae84a40c0 100644
--- a/sd/source/ui/slidesorter/controller/SlsAnimationFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsAnimationFunction.cxx
@@ -276,7 +276,7 @@ AnimationParametricFunction::AnimationParametricFunction (const ParametricFuncti
double AnimationParametricFunction::operator() (const double nX)
{
- const sal_Int32 nIndex0 (nX * maY.size());
+ const sal_Int32 nIndex0 (static_cast<sal_Int32>(nX * maY.size()));
const double nX0 (nIndex0 / double(maY.size()-1));
const sal_uInt32 nIndex1 (nIndex0 + 1);
const double nX1 (nIndex1 / double(maY.size()-1));
diff --git a/sd/source/ui/slidesorter/controller/SlsAnimator.cxx b/sd/source/ui/slidesorter/controller/SlsAnimator.cxx
index 22f612883..74f9fc2c2 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsAnimator.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsAnimator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -393,3 +394,5 @@ bool Animator::Animation::IsExpired (void)
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
index ba6094121..10e9a8fdd 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,7 +53,6 @@
#include "DrawViewShell.hxx"
#include "Window.hxx"
#include "fupoor.hxx"
-#include "fuslhide.hxx"
#include "fuzoom.hxx"
#include "fucushow.hxx"
#include "fusldlg.hxx"
@@ -80,7 +80,7 @@
#include <vcl/msgbox.hxx>
#include <tools/urlobj.hxx>
#include <rtl/ustring.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
namespace sd { namespace slidesorter { namespace controller {
@@ -315,7 +315,7 @@ sal_Int32 Clipboard::PasteTransferable (sal_Int32 nInsertPosition)
if (pClipTransferable->HasPageBookmarks())
{
const List& rBookmarkList = pClipTransferable->GetPageBookmarks();
- const ::vos::OGuard aGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aGuard;
nInsertPageCount = (sal_uInt16) rBookmarkList.Count();
rModel.GetDocument()->InsertBookmarkAsPage(
@@ -339,7 +339,7 @@ sal_Int32 Clipboard::PasteTransferable (sal_Int32 nInsertPosition)
if (pDataDoc!=NULL
&& pDataDoc->GetSdPageCount(PK_STANDARD))
{
- const ::vos::OGuard aGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aGuard;
bMergeMasterPages = (pDataDoc != rModel.GetDocument());
nInsertPageCount = pDataDoc->GetSdPageCount( PK_STANDARD );
@@ -550,7 +550,7 @@ IMPL_LINK(Clipboard, ProcessDragFinished, void*, pUserData)
PageList::iterator aDraggedPage;
for (aDraggedPage=maPagesToRemove.begin();
aDraggedPage!=maPagesToRemove.end();
- aDraggedPage++)
+ ++aDraggedPage)
{
rSelector.SelectPage(*aDraggedPage);
}
@@ -618,7 +618,6 @@ sal_Int8 Clipboard::AcceptDrop (
}
// Show the insertion marker and the substitution for a drop.
- Point aPosition = pTargetWindow->PixelToLogic (rEvent.maPosPixel);
SelectionFunction* pSelectionFunction = dynamic_cast<SelectionFunction*>(
mrSlideSorter.GetViewShell()->GetCurrentFunction().get());
if (pSelectionFunction != NULL)
@@ -890,3 +889,4 @@ sal_Int8 Clipboard::ExecuteOrAcceptShapeDrop (
} } } // end of namespace ::sd::slidesorter::controller
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsCommand.hxx b/sd/source/ui/slidesorter/controller/SlsCommand.hxx
index 089263693..d6dee9911 100644
--- a/sd/source/ui/slidesorter/controller/SlsCommand.hxx
+++ b/sd/source/ui/slidesorter/controller/SlsCommand.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,3 +44,5 @@ public:
} } } // end of namespace sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsCurrentSlideManager.cxx b/sd/source/ui/slidesorter/controller/SlsCurrentSlideManager.cxx
index f4950fa98..d26d9b7e3 100644
--- a/sd/source/ui/slidesorter/controller/SlsCurrentSlideManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsCurrentSlideManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -317,3 +318,5 @@ IMPL_LINK(CurrentSlideManager, SwitchPageCallback, void*, EMPTYARG)
}
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsFocusManager.cxx b/sd/source/ui/slidesorter/controller/SlsFocusManager.cxx
index 274d0e893..6f67c8188 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsFocusManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsFocusManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -228,24 +229,6 @@ sal_Int32 FocusManager::GetFocusedPageIndex (void) const
}
-
-/*
-void FocusManager::FocusPage (sal_Int32 nPageIndex)
-{
- if (nPageIndex != mnPageIndex)
- {
- // Hide the focus while switching it to the specified page.
- FocusHider aHider (*this);
- mnPageIndex = nPageIndex;
- }
-
- if (HasFocus() && !IsFocusShowing())
- ShowFocus();
-}
-*/
-
-
-
void FocusManager::SetFocusedPage (const model::SharedPageDescriptor& rpDescriptor)
{
if (rpDescriptor.get() != NULL)
@@ -398,3 +381,4 @@ FocusManager::FocusHider::~FocusHider (void)
} } } // end of namespace ::sd::slidesorter::controller
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.cxx b/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.cxx
index 07bbdb32a..71bf69410 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -169,3 +170,5 @@ HideSlideFunction::ExclusionState HideSlideFunction::GetExclusionState (
}
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.hxx b/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.hxx
index 424376f4b..9fb32c2c0 100644
--- a/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.hxx
+++ b/sd/source/ui/slidesorter/controller/SlsHideSlideFunction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,4 @@ protected:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsListener.cxx b/sd/source/ui/slidesorter/controller/SlsListener.cxx
index 918a009eb..7c2d905a1 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsListener.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsListener.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -235,7 +236,7 @@ void Listener::ConnectToController (void)
{
xSet->addPropertyChangeListener(String::CreateFromAscii("CurrentPage"), this);
}
- catch (beans::UnknownPropertyException aEvent)
+ catch (beans::UnknownPropertyException&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -243,7 +244,7 @@ void Listener::ConnectToController (void)
{
xSet->addPropertyChangeListener(String::CreateFromAscii("IsMasterPageMode"), this);
}
- catch (beans::UnknownPropertyException aEvent)
+ catch (beans::UnknownPropertyException&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -291,7 +292,7 @@ void Listener::DisconnectFromController (void)
Reference<lang::XEventListener>(
static_cast<XWeak*>(this), UNO_QUERY));
}
- catch (beans::UnknownPropertyException aEvent)
+ catch (beans::UnknownPropertyException&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -504,7 +505,7 @@ void SAL_CALL Listener::propertyChange (
mrController.GetPageSelector().SelectPage(nCurrentPage-1);
mrController.GetCurrentSlideManager()->NotifyCurrentSlideChange(nCurrentPage-1);
}
- catch (beans::UnknownPropertyException aEvent)
+ catch (beans::UnknownPropertyException&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -588,7 +589,7 @@ void Listener::UpdateEditMode (void)
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsMasterPageMode"))));
aValue >>= bIsMasterPageMode;
}
- catch (beans::UnknownPropertyException e)
+ catch (beans::UnknownPropertyException&)
{
// When the property is not supported then the master page mode
// is not supported, too.
@@ -696,3 +697,5 @@ void Listener::ThrowIfDisposed (void)
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsListener.hxx b/sd/source/ui/slidesorter/controller/SlsListener.hxx
index 1976541c9..28248c291 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsListener.hxx
+++ b/sd/source/ui/slidesorter/controller/SlsListener.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -192,3 +193,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsPageObjectFactory.cxx b/sd/source/ui/slidesorter/controller/SlsPageObjectFactory.cxx
index f5dc63c80..7e49d884b 100644
--- a/sd/source/ui/slidesorter/controller/SlsPageObjectFactory.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsPageObjectFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,5 @@ view::PageObject* PageObjectFactory::CreatePageObject (
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsPageSelector.cxx b/sd/source/ui/slidesorter/controller/SlsPageSelector.cxx
index 4e708be51..a9545b089 100644
--- a/sd/source/ui/slidesorter/controller/SlsPageSelector.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsPageSelector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -486,3 +487,5 @@ PageSelector::BroadcastLock::~BroadcastLock (void)
}
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsProperties.cxx b/sd/source/ui/slidesorter/controller/SlsProperties.cxx
index 084ed9209..fef6b6eb1 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsProperties.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsProperties.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -271,3 +272,5 @@ bool Properties::IsHighContrastModeActive (void) const
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx b/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
index 5e5c35bdd..2d1cba5ce 100644
--- a/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -194,7 +195,7 @@ void ScrollBarManager::PlaceVerticalScrollBar (const Rectangle& aArea)
mpVerticalScrollBar->SetPosSizePixel(aPosition, aSize);
// Restore the position.
- mpVerticalScrollBar->SetThumbPos(nThumbPosition);
+ mpVerticalScrollBar->SetThumbPos(static_cast<long>(nThumbPosition));
mnVerticalPosition = nThumbPosition / double(mpVerticalScrollBar->GetRange().Len());
}
@@ -735,3 +736,5 @@ void ScrollBarManager::Scroll(
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionCommand.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionCommand.cxx
index 154575894..d85e80f74 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionCommand.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionCommand.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ void SelectionCommand::operator() (void)
} } } // end of namespace sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionCommand.hxx b/sd/source/ui/slidesorter/controller/SlsSelectionCommand.hxx
index 805bbc2b8..62e0c819b 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionCommand.hxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionCommand.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ private:
} } } // end of namespace sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
index ee07022f0..13e02cd84 100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -400,7 +401,7 @@ FunctionReference SelectionFunction::Create(
sal_Bool SelectionFunction::MouseButtonDown (const MouseEvent& rEvent)
{
- // #95491# remember button state for creation of own MouseEvents
+ // remember button state for creation of own MouseEvents
SetMouseButtonCode (rEvent.GetButtons());
aMDPos = rEvent.GetPosPixel();
mbProcessingMouseButtonDown = true;
@@ -2022,3 +2023,5 @@ bool ButtonModeHandler::ProcessMotionEvent (SelectionFunction::EventDescriptor&
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionManager.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionManager.cxx
index 529f5c21b..3d8726df6 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -183,7 +184,7 @@ void SelectionManager::DeleteSelectedNormalPages (const ::std::vector<SdPage*>&
// reverse order so that when one slide is not deleted (to avoid an
// empty document) the remaining slide is the first one.
::std::vector<SdPage*>::const_reverse_iterator aI;
- for (aI=rSelectedPages.rbegin(); aI!=rSelectedPages.rend(); aI++)
+ for (aI=rSelectedPages.rbegin(); aI!=rSelectedPages.rend(); ++aI)
{
// Do not delete the last slide in the document.
if (xPages->getCount() <= 1)
@@ -197,7 +198,7 @@ void SelectionManager::DeleteSelectedNormalPages (const ::std::vector<SdPage*>&
}
catch( Exception& )
{
- DBG_ERROR("SelectionManager::DeleteSelectedNormalPages(), exception caught!");
+ OSL_FAIL("SelectionManager::DeleteSelectedNormalPages(), exception caught!");
}
}
@@ -219,7 +220,7 @@ void SelectionManager::DeleteSelectedMasterPages (const ::std::vector<SdPage*>&
// reverse order so that when one slide is not deleted (to avoid an
// empty document) the remaining slide is the first one.
::std::vector<SdPage*>::const_reverse_iterator aI;
- for (aI=rSelectedPages.rbegin(); aI!=rSelectedPages.rend(); aI++)
+ for (aI=rSelectedPages.rbegin(); aI!=rSelectedPages.rend(); ++aI)
{
// Do not delete the last slide in the document.
if (xPages->getCount() <= 1)
@@ -233,7 +234,7 @@ void SelectionManager::DeleteSelectedMasterPages (const ::std::vector<SdPage*>&
}
catch( Exception& )
{
- DBG_ERROR("SelectionManager::DeleteSelectedMasterPages(), exception caught!");
+ OSL_FAIL("SelectionManager::DeleteSelectedMasterPages(), exception caught!");
}
}
@@ -357,3 +358,5 @@ void SelectionManager::SetInsertionPosition (const sal_Int32 nInsertionPosition)
}
} } } // end of namespace ::sd::slidesorter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSlideFunction.cxx b/sd/source/ui/slidesorter/controller/SlsSlideFunction.cxx
index c430a0937..f53719fa0 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsSlideFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlideFunction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,5 @@ sal_Bool SlideFunction::MouseButtonDown(const MouseEvent& )
}
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
index b05f6d5af..cd2b1d3e9 100644
--- a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -824,10 +825,6 @@ void SlotManager::GetClipboardState ( SfxItemSet& rSet)
void SlotManager::GetStatusBarState (SfxItemSet& rSet)
{
// Seitenanzeige und Layout
- /*
- if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_STATUS_PAGE ) ||
- SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_STATUS_LAYOUT ) )
- */
SdPage* pPage = NULL;
SdPage* pFirstPage = NULL;
sal_uInt16 nFirstPage;
@@ -1341,3 +1338,4 @@ SlideExclusionState GetSlideExclusionState (model::PageEnumeration& rPageSet)
} } } // end of namespace ::sd::slidesorter::controller
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/SlsTransferable.cxx b/sd/source/ui/slidesorter/controller/SlsTransferable.cxx
index 62f0e35d4..22d33074c 100755..100644
--- a/sd/source/ui/slidesorter/controller/SlsTransferable.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsTransferable.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -99,3 +100,5 @@ const ::std::vector<Transferable::Representative>& Transferable::GetRepresentati
} } } // end of namespace ::sd::slidesorter::controller
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/controller/makefile.mk b/sd/source/ui/slidesorter/controller/makefile.mk
deleted file mode 100755
index 460ef16ed..000000000
--- a/sd/source/ui/slidesorter/controller/makefile.mk
+++ /dev/null
@@ -1,69 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slscontroller
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/SlideSorterController.obj \
- $(SLO)$/SlsAnimator.obj \
- $(SLO)$/SlsAnimationFunction.obj \
- $(SLO)$/SlsClipboard.obj \
- $(SLO)$/SlsCurrentSlideManager.obj \
- $(SLO)$/SlsDragAndDropContext.obj \
- $(SLO)$/SlsFocusManager.obj \
- $(SLO)$/SlsInsertionIndicatorHandler.obj\
- $(SLO)$/SlsListener.obj \
- $(SLO)$/SlsPageSelector.obj \
- $(SLO)$/SlsProperties.obj \
- $(SLO)$/SlsScrollBarManager.obj \
- $(SLO)$/SlsSelectionCommand.obj \
- $(SLO)$/SlsSelectionFunction.obj \
- $(SLO)$/SlsSelectionManager.obj \
- $(SLO)$/SlsSelectionObserver.obj \
- $(SLO)$/SlsSlotManager.obj \
- $(SLO)$/SlsTransferable.obj \
- $(SLO)$/SlsVisibleAreaManager.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slidesorter/inc/cache/SlsCacheContext.hxx b/sd/source/ui/slidesorter/inc/cache/SlsCacheContext.hxx
index 249995490..cafd6f607 100755..100644
--- a/sd/source/ui/slidesorter/inc/cache/SlsCacheContext.hxx
+++ b/sd/source/ui/slidesorter/inc/cache/SlsCacheContext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -104,3 +105,4 @@ typedef ::boost::shared_ptr<CacheContext> SharedCacheContext;
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx b/sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx
index b43d57518..c31106532 100644
--- a/sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx
+++ b/sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -177,3 +178,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx b/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
index 390968c3f..f21857ca6 100755..100644
--- a/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
+++ b/sd/source/ui/slidesorter/inc/cache/SlsPageCacheManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -186,3 +187,5 @@ private:
} } } // end of namespace ::sd::slidesorter::cache
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx b/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx
index 0c470b5cc..912397c8c 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -341,3 +342,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx b/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx
index dd8b12aac..4a2659f46 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,3 +140,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsClipboard.hxx b/sd/source/ui/slidesorter/inc/controller/SlsClipboard.hxx
index d4adf8cea..fd83227f3 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsClipboard.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsClipboard.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -231,3 +232,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsCurrentSlideManager.hxx b/sd/source/ui/slidesorter/inc/controller/SlsCurrentSlideManager.hxx
index bb8bfdce0..6e3bb250e 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsCurrentSlideManager.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsCurrentSlideManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -126,3 +127,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsFocusManager.hxx b/sd/source/ui/slidesorter/inc/controller/SlsFocusManager.hxx
index a696f26b1..05305d3b2 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsFocusManager.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsFocusManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -232,3 +233,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsPageObjectFactory.hxx b/sd/source/ui/slidesorter/inc/controller/SlsPageObjectFactory.hxx
index 3d528e476..fef75520c 100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsPageObjectFactory.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsPageObjectFactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,3 +96,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsPageSelector.hxx b/sd/source/ui/slidesorter/inc/controller/SlsPageSelector.hxx
index cb8247766..11717f2da 100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsPageSelector.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsPageSelector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -227,3 +228,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsProperties.hxx b/sd/source/ui/slidesorter/inc/controller/SlsProperties.hxx
index f8ad1f84e..bbf01a8ec 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsProperties.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsProperties.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -142,3 +143,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx b/sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx
index a8dd5797a..999d824f1 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -281,3 +282,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsSelectionFunction.hxx b/sd/source/ui/slidesorter/inc/controller/SlsSelectionFunction.hxx
index 6b894db92..34efc2280 100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsSelectionFunction.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsSelectionFunction.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -36,9 +37,7 @@
#include <boost/noncopyable.hpp>
#include <boost/scoped_ptr.hpp>
-class SdSlideViewShell;
class SdWindow;
-class SdSlideView;
class SdDrawDocument;
class Sound;
@@ -52,7 +51,7 @@ class SlideSorterController;
class DragAndDropContext;
-class SelectionFunction
+class SelectionFunction
: public FuPoor,
private ::boost::noncopyable
{
@@ -60,16 +59,16 @@ public:
TYPEINFO();
static FunctionReference Create( SlideSorter& rSlideSorter, SfxRequest& rRequest );
-
+
// Mouse- & Key-Events
virtual sal_Bool KeyInput(const KeyEvent& rKEvt);
virtual sal_Bool MouseMove(const MouseEvent& rMEvt);
virtual sal_Bool MouseButtonUp(const MouseEvent& rMEvt);
virtual sal_Bool MouseButtonDown(const MouseEvent& rMEvt);
-
+
virtual void Activate();
virtual void Deactivate();
-
+
virtual void ScrollStart();
virtual void ScrollEnd();
@@ -86,7 +85,7 @@ public:
This is used when a function gets a KEY_ESCAPE but can also
be called directly.
- @returns
+ @returns
true if a active function was aborted
*/
virtual bool cancel();
@@ -203,3 +202,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsSelectionManager.hxx b/sd/source/ui/slidesorter/inc/controller/SlsSelectionManager.hxx
index aaec10bc7..ff120d544 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsSelectionManager.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsSelectionManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -165,3 +166,5 @@ private:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsSlideFunction.hxx b/sd/source/ui/slidesorter/inc/controller/SlsSlideFunction.hxx
index 6bf57a7d8..44df6672c 100755..100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsSlideFunction.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsSlideFunction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ protected:
} } } // end of namespace ::sd::slidesorter::controller
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsSlotManager.hxx b/sd/source/ui/slidesorter/inc/controller/SlsSlotManager.hxx
index bb7cc6171..3635355e3 100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsSlotManager.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsSlotManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -123,3 +124,4 @@ private:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/controller/SlsTransferable.hxx b/sd/source/ui/slidesorter/inc/controller/SlsTransferable.hxx
index 58bb4399e..a29b53403 100644
--- a/sd/source/ui/slidesorter/inc/controller/SlsTransferable.hxx
+++ b/sd/source/ui/slidesorter/inc/controller/SlsTransferable.hxx
@@ -52,7 +52,7 @@ public:
: maBitmap(rBitmap), mbIsExcluded(bIsExcluded) {}
Representative (const Representative& rOther)
: maBitmap(rOther.maBitmap), mbIsExcluded(rOther.mbIsExcluded) {}
- Representative operator= (Representative& rOther)
+ Representative operator= (Representative const& rOther)
{ if (&rOther != this) {maBitmap = rOther.maBitmap; mbIsExcluded = rOther.mbIsExcluded; }
return *this;
}
diff --git a/sd/source/ui/slidesorter/inc/model/SlideSorterModel.hxx b/sd/source/ui/slidesorter/inc/model/SlideSorterModel.hxx
index e17ff371a..4b12659a5 100644
--- a/sd/source/ui/slidesorter/inc/model/SlideSorterModel.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlideSorterModel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -249,3 +250,5 @@ private:
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/model/SlsEnumeration.hxx b/sd/source/ui/slidesorter/inc/model/SlsEnumeration.hxx
index 989e0c463..ff3e45018 100644
--- a/sd/source/ui/slidesorter/inc/model/SlsEnumeration.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlsEnumeration.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ public:
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/model/SlsPageDescriptor.hxx b/sd/source/ui/slidesorter/inc/model/SlsPageDescriptor.hxx
index baf880d1e..31775b489 100644
--- a/sd/source/ui/slidesorter/inc/model/SlsPageDescriptor.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlsPageDescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -161,3 +162,5 @@ private:
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/model/SlsPageEnumeration.hxx b/sd/source/ui/slidesorter/inc/model/SlsPageEnumeration.hxx
index fa613032b..abbd121c1 100755..100644
--- a/sd/source/ui/slidesorter/inc/model/SlsPageEnumeration.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlsPageEnumeration.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,3 +126,5 @@ private:
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/model/SlsPageEnumerationProvider.hxx b/sd/source/ui/slidesorter/inc/model/SlsPageEnumerationProvider.hxx
index 06c1ce38c..f587586e5 100644
--- a/sd/source/ui/slidesorter/inc/model/SlsPageEnumerationProvider.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlsPageEnumerationProvider.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,5 @@ public:
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/model/SlsSharedPageDescriptor.hxx b/sd/source/ui/slidesorter/inc/model/SlsSharedPageDescriptor.hxx
index 9837f6ef0..746681530 100644
--- a/sd/source/ui/slidesorter/inc/model/SlsSharedPageDescriptor.hxx
+++ b/sd/source/ui/slidesorter/inc/model/SlsSharedPageDescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,3 +40,5 @@ typedef ::boost::shared_ptr<PageDescriptor> SharedPageDescriptor;
} } } // end of namespace ::sd::slidesorter::model
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlideSorterView.hxx b/sd/source/ui/slidesorter/inc/view/SlideSorterView.hxx
index a2d7a112d..378311913 100644
--- a/sd/source/ui/slidesorter/inc/view/SlideSorterView.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlideSorterView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -299,3 +300,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlsFontProvider.hxx b/sd/source/ui/slidesorter/inc/view/SlsFontProvider.hxx
index 9ecc85085..bef3a05c5 100644
--- a/sd/source/ui/slidesorter/inc/view/SlsFontProvider.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlsFontProvider.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlsLayouter.hxx b/sd/source/ui/slidesorter/inc/view/SlsLayouter.hxx
index 57bb40825..d1371a677 100644
--- a/sd/source/ui/slidesorter/inc/view/SlsLayouter.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlsLayouter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -294,3 +295,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlsPageObject.hxx b/sd/source/ui/slidesorter/inc/view/SlsPageObject.hxx
index ef14ae81c..e58e48ca7 100644
--- a/sd/source/ui/slidesorter/inc/view/SlsPageObject.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlsPageObject.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ protected:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewContact.hxx b/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewContact.hxx
index 63d53eeb4..59033cd10 100755..100644
--- a/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewContact.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewContact.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewObjectContact.hxx b/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewObjectContact.hxx
index 4310d381e..df3d69f14 100755..100644
--- a/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewObjectContact.hxx
+++ b/sd/source/ui/slidesorter/inc/view/SlsPageObjectViewObjectContact.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -223,3 +224,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/makefile.mk b/sd/source/ui/slidesorter/makefile.mk
deleted file mode 100644
index c294bf05f..000000000
--- a/sd/source/ui/slidesorter/makefile.mk
+++ /dev/null
@@ -1,58 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slidesorter
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/SlideSorter.obj \
- $(SLO)$/SlideSorterChildWindow.obj \
- $(SLO)$/SlideSorterViewShell.obj
-
-EXCEPTIONSFILES=
-
-SRS2NAME = slidesorter
-SRC2FILES = SlsChildWindow.src
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
index c770009e9..61d009b49 100644
--- a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
+++ b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -248,7 +249,7 @@ sal_Int32 SlideSorterModel::GetIndex (const Reference<drawing::XDrawPage>& rxSli
{
try
{
- const Any aNumber (xSet->getPropertyValue(::rtl::OUString::createFromAscii("Number")));
+ const Any aNumber (xSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Number"))));
sal_Int16 nNumber (-1);
aNumber >>= nNumber;
nNumber -= 1;
@@ -735,3 +736,5 @@ SdPage* SlideSorterModel::GetPage (const sal_Int32 nSdIndex) const
} } } // end of namespace ::sd::slidesorter::model
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/model/SlsPageDescriptor.cxx b/sd/source/ui/slidesorter/model/SlsPageDescriptor.cxx
index 7583d1fdc..32224f38c 100644
--- a/sd/source/ui/slidesorter/model/SlsPageDescriptor.cxx
+++ b/sd/source/ui/slidesorter/model/SlsPageDescriptor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -287,3 +288,5 @@ void PageDescriptor::SetBoundingBox (const Rectangle& rBoundingBox)
} } } // end of namespace ::sd::slidesorter::model
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/model/SlsPageEnumeration.cxx b/sd/source/ui/slidesorter/model/SlsPageEnumeration.cxx
index b7a8f2234..797175cb8 100644
--- a/sd/source/ui/slidesorter/model/SlsPageEnumeration.cxx
+++ b/sd/source/ui/slidesorter/model/SlsPageEnumeration.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -282,3 +283,4 @@ void PageEnumerationImpl::AdvanceToNextValidElement (void)
} // end of anonymous namespace
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/model/SlsPageEnumerationProvider.cxx b/sd/source/ui/slidesorter/model/SlsPageEnumerationProvider.cxx
index 1eca0a1fe..fc62c3b58 100755..100644
--- a/sd/source/ui/slidesorter/model/SlsPageEnumerationProvider.cxx
+++ b/sd/source/ui/slidesorter/model/SlsPageEnumerationProvider.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,7 +41,7 @@ namespace {
class AllPagesPredicate
{
public:
- bool operator() (const SharedPageDescriptor& rpDescriptor)
+ bool operator() (const SharedPageDescriptor& rpDescriptor) const
{
(void)rpDescriptor;
return true;
@@ -80,7 +81,6 @@ public:
PageEnumeration PageEnumerationProvider::CreateAllPagesEnumeration (
const SlideSorterModel& rModel)
{
-// AllPagesPredicate aPredicate; // spurious warning on unxsoli4 debug=t
return PageEnumeration::Create(rModel, AllPagesPredicate());
}
@@ -108,3 +108,5 @@ PageEnumeration PageEnumerationProvider::CreateVisiblePagesEnumeration (
} } } // end of namespace ::sd::slidesorter::model
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/model/makefile.mk b/sd/source/ui/slidesorter/model/makefile.mk
deleted file mode 100755
index 0347d05a8..000000000
--- a/sd/source/ui/slidesorter/model/makefile.mk
+++ /dev/null
@@ -1,57 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slsmodel
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/SlsPageDescriptor.obj \
- $(SLO)$/SlsPageEnumeration.obj \
- $(SLO)$/SlsPageEnumerationProvider.obj \
- $(SLO)$/SlsVisualState.obj \
- $(SLO)$/SlideSorterModel.obj
-
-EXCEPTIONSFILES=
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slidesorter/shell/SlideSorter.cxx b/sd/source/ui/slidesorter/shell/SlideSorter.cxx
index 3dab01e28..89d38a715 100755..100644
--- a/sd/source/ui/slidesorter/shell/SlideSorter.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -698,3 +699,5 @@ long ContentWindow::Notify (NotifyEvent& rEvent)
} } // end of namespace ::sd::slidesorter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterChildWindow.cxx b/sd/source/ui/slidesorter/shell/SlideSorterChildWindow.cxx
index f31f8ce4c..9562e2b2c 100755..100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterChildWindow.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ SlideSorterChildWindow::~SlideSorterChildWindow (void)
SFX_IMPL_DOCKINGWINDOW(SlideSorterChildWindow, SID_SLIDE_BROWSER)
} } // end of namespace ::sd::slidesorter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterService.cxx b/sd/source/ui/slidesorter/shell/SlideSorterService.cxx
index 5e6bf80db..3c4272a4e 100755..100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterService.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterService.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,7 +40,7 @@
#include <toolkit/helper/vclunohelper.hxx>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <cppuhelper/proptypehlp.hxx>
@@ -79,7 +80,7 @@ Reference<XInterface> SAL_CALL SlideSorterService_createInstance (
::rtl::OUString SlideSorterService_getImplementationName (void) throw(RuntimeException)
{
- return OUString::createFromAscii("com.sun.star.comp.Draw.SlideSorter");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.Draw.SlideSorter"));
}
@@ -89,7 +90,7 @@ Sequence<rtl::OUString> SAL_CALL SlideSorterService_getSupportedServiceNames (vo
throw (RuntimeException)
{
static const ::rtl::OUString sServiceName(
- ::rtl::OUString::createFromAscii("com.sun.star.drawing.SlideSorter"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.SlideSorter")));
return Sequence<rtl::OUString>(&sServiceName, 1);
}
@@ -175,7 +176,7 @@ void SAL_CALL SlideSorterService::initialize (const Sequence<Any>& rArguments)
else
{
throw RuntimeException(
- OUString::createFromAscii("SlideSorterService: invalid number of arguments"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("SlideSorterService: invalid number of arguments")),
static_cast<drawing::XDrawView*>(this));
}
}
@@ -642,3 +643,4 @@ void SlideSorterService::ThrowIfDisposed (void)
} } // end of namespace ::sd::presenter
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterService.hxx b/sd/source/ui/slidesorter/shell/SlideSorterService.hxx
index 73ec088af..cbbee0e1c 100755..100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterService.hxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterService.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -214,3 +215,5 @@ private:
} } // end of namespace ::sd::slidesorter
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
index 87ffcde58..b0902a6fa 100755..100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,9 +135,6 @@ SlideSorterViewShell::SlideSorterViewShell (
{
meShellType = ST_SLIDE_SORTER;
- SetPool( &GetDoc()->GetPool() );
- SetUndoManager( GetDoc()->GetDocSh()->GetUndoManager() );
-
if (pFrameViewArgument != NULL)
mpFrameView = pFrameViewArgument;
else
@@ -171,8 +169,9 @@ SlideSorterViewShell::~SlideSorterViewShell (void)
catch( ::com::sun::star::uno::Exception& e )
{
(void)e;
- DBG_ERROR("sd::SlideSorterViewShell::~SlideSorterViewShell(), exception caught!" );
+ OSL_FAIL("sd::SlideSorterViewShell::~SlideSorterViewShell(), exception caught!" );
}
+ GetFrameView()->Disconnect();
}
@@ -189,6 +188,11 @@ void SlideSorterViewShell::Initialize (void)
mpScrollBarBox);
mpView = &mpSlideSorter->GetView();
+ ViewShell::doShow();
+
+ SetPool( &GetDoc()->GetPool() );
+ SetUndoManager( GetDoc()->GetDocSh()->GetUndoManager() );
+
// For accessibility we have to shortly hide the content window.
// This triggers the construction of a new accessibility object for
// the new view shell. (One is created earlier while the construtor
@@ -278,17 +282,24 @@ Reference<drawing::XDrawSubController> SlideSorterViewShell::CreateSubController
::com::sun::star::accessibility::XAccessible>
SlideSorterViewShell::CreateAccessibleDocumentView (::sd::Window* pWindow)
{
- OSL_ASSERT(mpSlideSorter.get()!=NULL);
-
// When the view is not set then the initialization is not yet complete
// and we can not yet provide an accessibility object.
- if (mpView == NULL)
+ if (mpView == NULL || mpSlideSorter.get() == NULL)
return NULL;
- return new ::accessibility::AccessibleSlideSorterView (
+ OSL_ASSERT(mpSlideSorter.get()!=NULL);
+
+ ::accessibility::AccessibleSlideSorterView *pAccessibleView =
+ new ::accessibility::AccessibleSlideSorterView(
*mpSlideSorter.get(),
pWindow->GetAccessibleParentWindow()->GetAccessible(),
pWindow);
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible> xRet(pAccessibleView);
+
+ pAccessibleView->Init();
+
+ return xRet;
}
@@ -693,7 +704,6 @@ void SlideSorterViewShell::SetZoomRect (const Rectangle& rZoomRect)
ViewShell::SetZoomRect(aRect);
- // #106268#
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOM );
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOMSLIDER );
}
@@ -812,3 +822,5 @@ void SlideSorterViewShell::RemoveSelectionChangeListener (
} } // end of namespace ::sd::slidesorter
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/shell/makefile.mk b/sd/source/ui/slidesorter/shell/makefile.mk
deleted file mode 100755
index 94209c34d..000000000
--- a/sd/source/ui/slidesorter/shell/makefile.mk
+++ /dev/null
@@ -1,55 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slsshell
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/SlideSorter.obj \
- $(SLO)$/SlideSorterService.obj \
- $(SLO)$/SlideSorterViewShell.obj
-
-EXCEPTIONSFILES=
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/slidesorter/view/SlideSorterView.cxx b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
index aa76c45f9..ce2b3a641 100644
--- a/sd/source/ui/slidesorter/view/SlideSorterView.cxx
+++ b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -1130,3 +1131,5 @@ void SlideSorterView::DrawLock::Dispose (void)
} } } // end of namespace ::sd::slidesorter::view
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsButtonBar.cxx b/sd/source/ui/slidesorter/view/SlsButtonBar.cxx
index 5254c4ba0..5c0adf49a 100644
--- a/sd/source/ui/slidesorter/view/SlsButtonBar.cxx
+++ b/sd/source/ui/slidesorter/view/SlsButtonBar.cxx
@@ -155,7 +155,7 @@ namespace {
for (sal_Int32 nX = 0; nX<nWidth; ++nX)
{
const sal_uInt8 nValue (255 - pSourceBitmap->GetPixel(nY, nX).GetBlueOrIndex());
- const sal_uInt8 nNewValue (nValue * (1-nAlpha));
+ const sal_uInt8 nNewValue (static_cast<sal_uInt8>(nValue * (1-nAlpha)));
pBitmap->SetPixel(nY, nX, 255-nNewValue);
}
}
@@ -756,8 +756,8 @@ void ButtonBar::StartFadeAnimation (
::boost::ref(mrSlideSorter.GetView()),
::boost::bind(aButtonBlendFunctor, _1),
::boost::bind(aButtonBarBlendFunctor, _1)),
- nDelay,
- nDuration,
+ static_cast<sal_Int32>(nDelay),
+ static_cast<sal_Int32>(nDuration),
::boost::bind(
&model::VisualState::SetButtonAlphaAnimationId,
::boost::ref(pDescriptor->GetVisualState()),
@@ -1449,7 +1449,7 @@ void StartShowButton::ProcessClick (const model::SharedPageDescriptor& rpDescrip
if (xPresentation.is())
{
Sequence<PropertyValue> aProperties (1);
- aProperties[0].Name = ::rtl::OUString::createFromAscii("FirstPage");
+ aProperties[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FirstPage"));
const ::rtl::OUString sName (rpDescriptor->GetPage()->GetName());
aProperties[0].Value = Any(sName);
xPresentation->startWithArguments(aProperties);
diff --git a/sd/source/ui/slidesorter/view/SlsFontProvider.cxx b/sd/source/ui/slidesorter/view/SlsFontProvider.cxx
index 061c1bab8..c7d7d2c34 100755..100644
--- a/sd/source/ui/slidesorter/view/SlsFontProvider.cxx
+++ b/sd/source/ui/slidesorter/view/SlsFontProvider.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -130,3 +131,5 @@ FontProvider::SharedFontPointer FontProvider::GetFont (const OutputDevice& rDevi
}
} } } // end of namespace ::sd::slidesorter::view
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
index 4a8f7b489..6cd455730 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
@@ -158,7 +158,7 @@ private:
view::Layouter& rLayouter,
const InsertPosition& rInsertPosition,
const bool bCreate = true);
- RunContainer::iterator FindRun (const sal_Int32 nRunIndex) const;
+ RunContainer::const_iterator FindRun (const sal_Int32 nRunIndex) const;
};
@@ -251,7 +251,7 @@ SharedPageObjectRun InsertAnimator::Implementation::GetRun (
if (nRow < 0)
return SharedPageObjectRun();
- RunContainer::iterator iRun (maRuns.end());
+ RunContainer::const_iterator iRun (maRuns.end());
if (rLayouter.GetColumnCount() == 1)
{
// There is only one run that contains all slides.
@@ -292,7 +292,7 @@ SharedPageObjectRun InsertAnimator::Implementation::GetRun (
-InsertAnimator::Implementation::RunContainer::iterator
+InsertAnimator::Implementation::RunContainer::const_iterator
InsertAnimator::Implementation::FindRun (const sal_Int32 nRunIndex) const
{
return std::find_if(
@@ -330,7 +330,7 @@ void InsertAnimator::Implementation::RemoveRun (const ::boost::shared_ptr<PageOb
// Do not remove runs that show the space for the insertion indicator.
if (pRun->mnLocalInsertIndex == -1)
{
- InsertAnimator::Implementation::RunContainer::iterator iRun (FindRun(pRun->mnRunIndex));
+ InsertAnimator::Implementation::RunContainer::const_iterator iRun (FindRun(pRun->mnRunIndex));
if (iRun != maRuns.end())
{
OSL_ASSERT(*iRun == pRun);
diff --git a/sd/source/ui/slidesorter/view/SlsLayouter.cxx b/sd/source/ui/slidesorter/view/SlsLayouter.cxx
index fdb48867d..19ec3bc64 100644
--- a/sd/source/ui/slidesorter/view/SlsLayouter.cxx
+++ b/sd/source/ui/slidesorter/view/SlsLayouter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -1550,3 +1551,5 @@ void InsertPosition::SetGeometricalPosition(
} } } // end of namespace ::sd::slidesorter::namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsPageObject.cxx b/sd/source/ui/slidesorter/view/SlsPageObject.cxx
index 3b03beaaa..a9508e406 100644
--- a/sd/source/ui/slidesorter/view/SlsPageObject.cxx
+++ b/sd/source/ui/slidesorter/view/SlsPageObject.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,5 @@ sdr::contact::ViewContact* PageObject::CreateObjectSpecificViewContact()
} } } // end of namespace ::sd::slidesorter::view
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsResource.hxx b/sd/source/ui/slidesorter/view/SlsResource.hxx
index 7d5e2ad06..bdbb819ba 100644
--- a/sd/source/ui/slidesorter/view/SlsResource.hxx
+++ b/sd/source/ui/slidesorter/view/SlsResource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,3 +46,5 @@ public:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx b/sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx
index f38baef85..4f35996fe 100755..100644
--- a/sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx
+++ b/sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,3 +158,5 @@ model::SharedPageDescriptor ViewCacheContext::GetDescriptor (cache::CacheKey aKe
}
} } } // end of namespace ::sd::slidesorter::view
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx b/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
index 3f48b026d..9c714f871 100755..100644
--- a/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
+++ b/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,3 +69,5 @@ private:
} } } // end of namespace ::sd::slidesorter::view
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/slidesorter/view/makefile.mk b/sd/source/ui/slidesorter/view/makefile.mk
deleted file mode 100755
index 3c5fc39c3..000000000
--- a/sd/source/ui/slidesorter/view/makefile.mk
+++ /dev/null
@@ -1,69 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=slsview
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..
-
-IMGLST_SRS=$(SRS)$/$(TARGET).srs
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- SlsResource.src
-
-SLOFILES = \
- $(SLO)$/SlideSorterView.obj \
- $(SLO)$/SlsButtonBar.obj \
- $(SLO)$/SlsFontProvider.obj \
- $(SLO)$/SlsFramePainter.obj \
- $(SLO)$/SlsInsertAnimator.obj \
- $(SLO)$/SlsInsertionIndicatorOverlay.obj\
- $(SLO)$/SlsLayeredDevice.obj \
- $(SLO)$/SlsLayouter.obj \
- $(SLO)$/SlsPageObjectLayouter.obj \
- $(SLO)$/SlsPageObjectPainter.obj \
- $(SLO)$/SlsTheme.obj \
- $(SLO)$/SlsToolTip.obj \
- $(SLO)$/SlsViewCacheContext.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/table/TableDesignPane.cxx b/sd/source/ui/table/TableDesignPane.cxx
index 536231f6c..08271e2db 100755..100644
--- a/sd/source/ui/table/TableDesignPane.cxx
+++ b/sd/source/ui/table/TableDesignPane.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,7 +155,7 @@ TableDesignPane::TableDesignPane( ::Window* pParent, ViewShellBase& rBase, bool
catch( Exception& e )
{
(void)e;
- DBG_ERROR( "sd::CustomAnimationPane::CustomAnimationPane(), Exception caught!" );
+ OSL_FAIL( "sd::CustomAnimationPane::CustomAnimationPane(), Exception caught!" );
}
onSelectionChanged();
@@ -262,7 +263,7 @@ void TableDesignPane::ApplyStyle()
}
catch( Exception& )
{
- DBG_ERROR("TableDesignPane::implValueSetHdl(), exception caught!");
+ OSL_FAIL("TableDesignPane::implValueSetHdl(), exception caught!");
}
}
@@ -353,7 +354,7 @@ void TableDesignPane::onSelectionChanged()
}
catch( Exception& )
{
- DBG_ERROR( "sd::TableDesignPane::onSelectionChanged(), Exception caught!" );
+ OSL_FAIL( "sd::TableDesignPane::onSelectionChanged(), Exception caught!" );
}
if( mxSelectedTable != xNewSelection )
@@ -485,7 +486,7 @@ void TableDesignPane::updateControls()
}
catch( Exception& )
{
- DBG_ERROR("sd::TableDesignPane::updateControls(), exception caught!");
+ OSL_FAIL("sd::TableDesignPane::updateControls(), exception caught!");
}
static_cast< CheckBox* >( mxControls[i].get() )->Check( bUse ? sal_True : sal_False );
mxControls[i]->Enable(bHasTable ? sal_True : sal_False );
@@ -647,7 +648,7 @@ static void FillCellInfoVector( const Reference< XIndexAccess >& xTableStyle, Ce
}
catch(Exception&)
{
- DBG_ERROR("sd::FillCellInfoVector(), exception caught!");
+ OSL_FAIL("sd::FillCellInfoVector(), exception caught!");
}
}
@@ -811,7 +812,7 @@ const Bitmap CreateDesignPreview( const Reference< XIndexAccess >& xTableStyle,
// draw top border
for( sal_uInt16 nLine = 0; nLine < 4; ++nLine )
{
- const SvxBorderLine* pBorderLine = xCellInfo->maBorder.GetLine(nLine);
+ const ::editeng::SvxBorderLine* pBorderLine = xCellInfo->maBorder.GetLine(nLine);
if( !pBorderLine || ((pBorderLine->GetOutWidth() == 0) && (pBorderLine->GetInWidth()==0)) )
continue;
@@ -824,7 +825,7 @@ const Bitmap CreateDesignPreview( const Reference< XIndexAccess >& xTableStyle,
if( xBorderInfo.get() )
{
const sal_uInt16 nOtherLine = nLine ^ 1;
- const SvxBorderLine* pBorderLine2 = xBorderInfo->maBorder.GetLine(nOtherLine^1);
+ const ::editeng::SvxBorderLine* pBorderLine2 = xBorderInfo->maBorder.GetLine(nOtherLine^1);
if( pBorderLine2 && pBorderLine2->HasPriority(*pBorderLine) )
continue; // other border line wins
}
@@ -887,12 +888,12 @@ void TableDesignPane::FillDesignPreviewControl()
}
catch( Exception& )
{
- DBG_ERROR("sd::TableDesignPane::FillDesignPreviewControl(), exception caught!");
+ OSL_FAIL("sd::TableDesignPane::FillDesignPreviewControl(), exception caught!");
}
}
catch( Exception& )
{
- DBG_ERROR("sd::TableDesignPane::FillDesignPreviewControl(), exception caught!");
+ OSL_FAIL("sd::TableDesignPane::FillDesignPreviewControl(), exception caught!");
}
pValueSet->SelectItem(nSelectedItem);
}
@@ -949,3 +950,4 @@ void showTableDesignDialog( ::Window* pParent, ViewShellBase& rBase )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/table/TableDesignPane.hxx b/sd/source/ui/table/TableDesignPane.hxx
index a5fad040a..efd868a58 100644
--- a/sd/source/ui/table/TableDesignPane.hxx
+++ b/sd/source/ui/table/TableDesignPane.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124,3 +125,5 @@ private:
}
#endif // _SD_TABLEFORMATPANE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/table/makefile.mk b/sd/source/ui/table/makefile.mk
deleted file mode 100644
index f35602349..000000000
--- a/sd/source/ui/table/makefile.mk
+++ /dev/null
@@ -1,56 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=uitable
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES =\
- TableDesignPane.src\
-
-SLOFILES = \
- $(SLO)$/tablefunction.obj\
- $(SLO)$/tableobjectbar.obj\
- $(SLO)$/TableDesignPane.obj
-
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/source/ui/table/tablefunction.cxx b/sd/source/ui/table/tablefunction.cxx
index 211750dff..1bf5a0a0d 100755..100644
--- a/sd/source/ui/table/tablefunction.cxx
+++ b/sd/source/ui/table/tablefunction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,7 +109,7 @@ static void apply_table_style( SdrTableObj* pObj, SdrModel* pModel, const OUStri
}
catch( Exception& )
{
- DBG_ERROR("sd::apply_default_table_style(), exception caught!");
+ OSL_FAIL("sd::apply_default_table_style(), exception caught!");
}
}
}
@@ -268,3 +269,5 @@ void CreateTableFromRTF( SvStream& rStream, SdDrawDocument* pModel )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/table/tableobjectbar.cxx b/sd/source/ui/table/tableobjectbar.cxx
index 67ab0fc61..5e66904ba 100755..100644
--- a/sd/source/ui/table/tableobjectbar.cxx
+++ b/sd/source/ui/table/tableobjectbar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -232,3 +233,5 @@ void TableObjectBar::Execute( SfxRequest& rReq )
}
} } }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/table/tableobjectbar.hxx b/sd/source/ui/table/tableobjectbar.hxx
index 1711ed26a..f3f0800c6 100644
--- a/sd/source/ui/table/tableobjectbar.hxx
+++ b/sd/source/ui/table/tableobjectbar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,3 +63,5 @@ protected:
} } }
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ConstrainedIterator.cxx b/sd/source/ui/toolpanel/ConstrainedIterator.cxx
index 3eaa9ba76..009085df7 100644
--- a/sd/source/ui/toolpanel/ConstrainedIterator.cxx
+++ b/sd/source/ui/toolpanel/ConstrainedIterator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -265,3 +266,5 @@ void ConstrainedIterator<Container>::AdvanceToPreviousValidElement (void)
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ConstrainedIterator.hxx b/sd/source/ui/toolpanel/ConstrainedIterator.hxx
index 90b615006..a9ca9da65 100644
--- a/sd/source/ui/toolpanel/ConstrainedIterator.hxx
+++ b/sd/source/ui/toolpanel/ConstrainedIterator.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ControlContainer.cxx b/sd/source/ui/toolpanel/ControlContainer.cxx
index 9a30103fb..5b53b0ca1 100755..100644
--- a/sd/source/ui/toolpanel/ControlContainer.cxx
+++ b/sd/source/ui/toolpanel/ControlContainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -443,3 +444,5 @@ void ControlContainer::SetVisibilityState (
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ControlContainerDescriptor.hxx b/sd/source/ui/toolpanel/ControlContainerDescriptor.hxx
index 3375381a6..b4d3f5122 100644
--- a/sd/source/ui/toolpanel/ControlContainerDescriptor.hxx
+++ b/sd/source/ui/toolpanel/ControlContainerDescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#include "taskpane/TitleBar.hxx"
#include <tools/string.hxx>
#include <tools/gen.hxx>
-#ifndef SD_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
#include <memory>
class Window;
@@ -137,3 +136,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ControlList.hxx b/sd/source/ui/toolpanel/ControlList.hxx
index 97f746e6b..90a73692e 100644
--- a/sd/source/ui/toolpanel/ControlList.hxx
+++ b/sd/source/ui/toolpanel/ControlList.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ public:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/LayoutMenu.cxx b/sd/source/ui/toolpanel/LayoutMenu.cxx
index 5b064bd80..452d1d020 100755..100644
--- a/sd/source/ui/toolpanel/LayoutMenu.cxx
+++ b/sd/source/ui/toolpanel/LayoutMenu.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -122,7 +123,6 @@ TYPEINIT1(LayoutMenu, SfxShell);
struct snewfoil_value_info
{
sal_uInt16 mnBmpResId;
- sal_uInt16 mnHCBmpResId;
sal_uInt16 mnStrResId;
WritingMode meWritingMode;
AutoLayout maAutoLayout;
@@ -130,49 +130,49 @@ struct snewfoil_value_info
static snewfoil_value_info notes[] =
{
- {BMP_FOILN_01, BMP_FOILN_01_H, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
+ {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
AUTOLAYOUT_NOTES},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
};
static snewfoil_value_info handout[] =
{
- {BMP_FOILH_01, BMP_FOILH_01_H, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
+ {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT1},
- {BMP_FOILH_02, BMP_FOILH_02_H, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB,
+ {BMP_FOILH_02, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT2},
- {BMP_FOILH_03, BMP_FOILH_03_H, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB,
+ {BMP_FOILH_03, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT3},
- {BMP_FOILH_04, BMP_FOILH_04_H, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB,
+ {BMP_FOILH_04, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT4},
- {BMP_FOILH_06, BMP_FOILH_06_H, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB,
+ {BMP_FOILH_06, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT6},
- {BMP_FOILH_09, BMP_FOILH_09_H, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB,
+ {BMP_FOILH_09, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB,
AUTOLAYOUT_HANDOUT9},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
};
static snewfoil_value_info standard[] =
{
- {BMP_LAYOUT_EMPTY, BMP_LAYOUT_EMPTY_H, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB, AUTOLAYOUT_NONE},
- {BMP_LAYOUT_HEAD03, BMP_LAYOUT_HEAD03_H, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB, AUTOLAYOUT_TITLE},
- {BMP_LAYOUT_HEAD02, BMP_LAYOUT_HEAD02_H, STR_AUTOLAYOUT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_ENUM},
- {BMP_LAYOUT_HEAD02A, BMP_LAYOUT_HEAD02A_H, STR_AUTOLAYOUT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2TEXT},
- {BMP_LAYOUT_HEAD01, BMP_LAYOUT_HEAD01_H, STR_AUTOLAYOUT_ONLY_TITLE, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TITLE},
- {BMP_LAYOUT_TEXTONLY, BMP_LAYOUT_TEXTONLY_H, STR_AUTOLAYOUT_ONLY_TEXT, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TEXT},
- {BMP_LAYOUT_HEAD03B, BMP_LAYOUT_HEAD03B_H, STR_AUTOLAYOUT_2CONTENT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2OBJTEXT},
- {BMP_LAYOUT_HEAD03C, BMP_LAYOUT_HEAD03C_H, STR_AUTOLAYOUT_CONTENT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_TEXT2OBJ},
- {BMP_LAYOUT_HEAD03A, BMP_LAYOUT_HEAD03A_H, STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT},
- {BMP_LAYOUT_HEAD02B, BMP_LAYOUT_HEAD02B_H, STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT},
- {BMP_LAYOUT_HEAD04, BMP_LAYOUT_HEAD04_H, STR_AUTOLAYOUT_4CONTENT, WritingMode_LR_TB, AUTOLAYOUT_4OBJ},
- {BMP_LAYOUT_HEAD06, BMP_LAYOUT_HEAD06_H, STR_AUTOLAYOUT_6CONTENT, WritingMode_LR_TB, AUTOLAYOUT_6CLIPART},
+ {BMP_LAYOUT_EMPTY, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB, AUTOLAYOUT_NONE},
+ {BMP_LAYOUT_HEAD03, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB, AUTOLAYOUT_TITLE},
+ {BMP_LAYOUT_HEAD02, STR_AUTOLAYOUT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_ENUM},
+ {BMP_LAYOUT_HEAD02A, STR_AUTOLAYOUT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2TEXT},
+ {BMP_LAYOUT_HEAD01, STR_AUTOLAYOUT_ONLY_TITLE, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TITLE},
+ {BMP_LAYOUT_TEXTONLY, STR_AUTOLAYOUT_ONLY_TEXT, WritingMode_LR_TB, AUTOLAYOUT_ONLY_TEXT},
+ {BMP_LAYOUT_HEAD03B, STR_AUTOLAYOUT_2CONTENT_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_2OBJTEXT},
+ {BMP_LAYOUT_HEAD03C, STR_AUTOLAYOUT_CONTENT_2CONTENT, WritingMode_LR_TB, AUTOLAYOUT_TEXT2OBJ},
+ {BMP_LAYOUT_HEAD03A, STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT},
+ {BMP_LAYOUT_HEAD02B, STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT},
+ {BMP_LAYOUT_HEAD04, STR_AUTOLAYOUT_4CONTENT, WritingMode_LR_TB, AUTOLAYOUT_4OBJ},
+ {BMP_LAYOUT_HEAD06, STR_AUTOLAYOUT_6CONTENT, WritingMode_LR_TB, AUTOLAYOUT_6CLIPART},
// vertical
- {BMP_LAYOUT_VERTICAL02, BMP_LAYOUT_VERTICAL02_H, STR_AL_VERT_TITLE_TEXT_CHART, WritingMode_TB_RL,AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART},
- {BMP_LAYOUT_VERTICAL01, BMP_LAYOUT_VERTICAL01_H, STR_AL_VERT_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE},
- {BMP_LAYOUT_HEAD02, BMP_LAYOUT_HEAD02_H, STR_AL_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE},
- {BMP_LAYOUT_HEAD02A, BMP_LAYOUT_HEAD02A_H, STR_AL_TITLE_VERT_OUTLINE_CLIPART, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART},
- {0, 0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
+ {BMP_LAYOUT_VERTICAL02, STR_AL_VERT_TITLE_TEXT_CHART, WritingMode_TB_RL,AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART},
+ {BMP_LAYOUT_VERTICAL01, STR_AL_VERT_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE},
+ {BMP_LAYOUT_HEAD02, STR_AL_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE},
+ {BMP_LAYOUT_HEAD02A, STR_AL_TITLE_VERT_OUTLINE_CLIPART, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART},
+ {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
};
LayoutMenu::LayoutMenu( TreeNode* pParent, ToolPanelViewShell& i_rPanelViewShell )
@@ -228,7 +228,7 @@ void LayoutMenu::implConstruct( DrawDocShell& rDocumentShell )
mxListener = new ::sd::tools::SlotStateListener(
aStateChangeLink,
Reference<frame::XDispatchProvider>(mrBase.GetController()->getFrame(), UNO_QUERY),
- ::rtl::OUString::createFromAscii(".uno:VerticalTextState"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:VerticalTextState")));
// Add this new object as shell to the shell factory.
GetShellManager()->AddSubShell(SHELLID_SD_TASK_PANE_PREVIEW_LAYOUTS,this,this);
@@ -763,7 +763,6 @@ SfxRequest LayoutMenu::CreateRequest (
void LayoutMenu::Fill (void)
{
- const bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
SvtLanguageOptions aLanguageOptions;
sal_Bool bVertical = aLanguageOptions.IsVerticalTextEnabled();
SdDrawDocument* pDocument = mrBase.GetDocument();
@@ -811,9 +810,7 @@ void LayoutMenu::Fill (void)
{
if ((WritingMode_TB_RL != pInfo->meWritingMode) || bVertical)
{
- BitmapEx aBmp (SdResId (bHighContrast
- ? pInfo->mnHCBmpResId
- : pInfo->mnBmpResId));
+ BitmapEx aBmp(SdResId(pInfo->mnBmpResId));
if (bRightToLeft && (WritingMode_TB_RL != pInfo->meWritingMode))
aBmp.Mirror (BMP_MIRROR_HORZ);
@@ -1010,3 +1007,5 @@ void LayoutMenu::DataChanged (const DataChangedEvent& rEvent)
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/LayoutMenu.hxx b/sd/source/ui/toolpanel/LayoutMenu.hxx
index 2823e7907..ac5b5ffba 100755..100644
--- a/sd/source/ui/toolpanel/LayoutMenu.hxx
+++ b/sd/source/ui/toolpanel/LayoutMenu.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "taskpane/TaskPaneTreeNode.hxx"
-#ifndef _COM_SUN_STAR_FRAME_XSTATUS_LISTENER_HPP_
#include <com/sun/star/frame/XStatusListener.hpp>
-#endif
#include "glob.hxx"
#include "pres.hxx"
@@ -237,3 +236,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/MethodGuard.hxx b/sd/source/ui/toolpanel/MethodGuard.hxx
index a8f6d673e..b14deeccc 100644
--- a/sd/source/ui/toolpanel/MethodGuard.hxx
+++ b/sd/source/ui/toolpanel/MethodGuard.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -65,3 +66,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
#endif // SD_METHODGUARD_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ScrollPanel.cxx b/sd/source/ui/toolpanel/ScrollPanel.cxx
index 53b3db042..3d97bc884 100755..100644
--- a/sd/source/ui/toolpanel/ScrollPanel.cxx
+++ b/sd/source/ui/toolpanel/ScrollPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -62,7 +63,7 @@ ScrollPanel::ScrollPanel (
void ScrollPanel::Construct()
{
SetAccessibleName (
- ::rtl::OUString::createFromAscii("Sub Task Panel"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Sub Task Panel")));
mpControlContainer->SetMultiSelection (true);
SetBorderStyle (WINDOW_BORDER_NORMAL);
@@ -223,7 +224,7 @@ void ScrollPanel::Paint (const Rectangle& rRect)
Point (mnHorizontalBorder,0),
Size(mnChildrenWidth,0));
StripeList::const_iterator iStripe;
- for (iStripe=maStripeList.begin(); iStripe!=maStripeList.end(); iStripe++)
+ for (iStripe=maStripeList.begin(); iStripe!=maStripeList.end(); ++iStripe)
{
aStripeArea.Top() = iStripe->first;
aStripeArea.Bottom() = iStripe->second;
@@ -694,8 +695,8 @@ long ScrollPanel::Notify( NotifyEvent& rNEvt )
{
return new ::accessibility::AccessibleScrollPanel (
*this,
- ::rtl::OUString::createFromAscii("Scroll Panel"),
- ::rtl::OUString::createFromAscii("Scroll Panel"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Scroll Panel")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Scroll Panel")));
}
@@ -813,3 +814,5 @@ IMPL_LINK(ScrollPanel,WindowEventListener,VclSimpleEvent*,pEvent)
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/SlideSorterCacheDisplay.cxx b/sd/source/ui/toolpanel/SlideSorterCacheDisplay.cxx
index 78301f8d8..a0a9641e7 100755..100644
--- a/sd/source/ui/toolpanel/SlideSorterCacheDisplay.cxx
+++ b/sd/source/ui/toolpanel/SlideSorterCacheDisplay.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -370,3 +371,5 @@ void SlideSorterCacheDisplay::PaintPage (sal_Int32 nPageIndex)
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/SubToolPanel.cxx b/sd/source/ui/toolpanel/SubToolPanel.cxx
index fadaff587..7b34b560a 100755..100644
--- a/sd/source/ui/toolpanel/SubToolPanel.cxx
+++ b/sd/source/ui/toolpanel/SubToolPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,7 @@ SubToolPanel::SubToolPanel (
mnHorizontalBorder(2)
{
SetAccessibleName (
- ::rtl::OUString::createFromAscii("Sub Task Panel"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Sub Task Panel")));
mpControlContainer->SetMultiSelection (true);
SetBorderStyle (WINDOW_BORDER_NORMAL);
@@ -116,7 +117,7 @@ void SubToolPanel::Paint (const Rectangle& rRect)
Point (mnHorizontalBorder,0),
Size(mnChildrenWidth,0));
StripeList::const_iterator iStripe;
- for (iStripe=maStripeList.begin(); iStripe!=maStripeList.end(); iStripe++)
+ for (iStripe=maStripeList.begin(); iStripe!=maStripeList.end(); ++iStripe)
{
aStripeArea.Top() = iStripe->first;
aStripeArea.Bottom() = iStripe->second;
@@ -382,9 +383,11 @@ IMPL_LINK(SubToolPanel, WindowEventListener, VclSimpleEvent*, pEvent)
{
return new ::accessibility::AccessibleTreeNode (
*this,
- ::rtl::OUString::createFromAscii("Sub Task Panel"),
- ::rtl::OUString::createFromAscii("Sub Task Panel"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Sub Task Panel")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Sub Task Panel")),
::com::sun::star::accessibility::AccessibleRole::PANEL);
}
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneControlFactory.cxx b/sd/source/ui/toolpanel/TaskPaneControlFactory.cxx
index c85d2a0f7..ead4074d1 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneControlFactory.cxx
+++ b/sd/source/ui/toolpanel/TaskPaneControlFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,7 @@
#include "taskpane/TaskPaneControlFactory.hxx"
-#include <vos/diagnose.hxx>
+#include <osl/diagnose.h>
namespace sd { namespace toolpanel {
@@ -55,3 +56,5 @@ ControlFactory::~ControlFactory (void)
}
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneFocusManager.cxx b/sd/source/ui/toolpanel/TaskPaneFocusManager.cxx
index 37e5668ad..54425518f 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneFocusManager.cxx
+++ b/sd/source/ui/toolpanel/TaskPaneFocusManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,7 +35,7 @@
#include <vcl/svapp.hxx>
#include <vcl/event.hxx>
#include <rtl/instance.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace {
@@ -64,31 +65,23 @@ namespace sd { namespace toolpanel {
class FocusManager::LinkMap
- : public ::std::hash_multimap< ::Window*, EventDescriptor, WindowHash>
+ : public ::boost::unordered_multimap< ::Window*, EventDescriptor, WindowHash>
{
};
+struct FocusManagerCreator
+{
+ FocusManager m_aFocusManager;
+};
+namespace
+{
+ class theFocusManagerInstance : public rtl::Static< FocusManagerCreator, theFocusManagerInstance> {};
+}
FocusManager& FocusManager::Instance (void)
{
- static FocusManager* spInstance = NULL;
-
- if (spInstance == NULL)
- {
- ::osl::MutexGuard aGuard (::osl::Mutex::getGlobalMutex());
- if (spInstance == NULL)
- {
- static FocusManager aInstance;
- OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
- spInstance = &aInstance;
- }
- }
- else
- {
- OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
- }
- return *spInstance;
+ return theFocusManagerInstance::get().m_aFocusManager;
}
@@ -330,3 +323,5 @@ IMPL_LINK(FocusManager, WindowEventListener, VclSimpleEvent*, pEvent)
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneFocusManager.hxx b/sd/source/ui/toolpanel/TaskPaneFocusManager.hxx
index acbe34763..cf26d3ea8 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneFocusManager.hxx
+++ b/sd/source/ui/toolpanel/TaskPaneFocusManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -103,6 +104,8 @@ public:
bool TransferFocus (::Window* pSource, const KeyCode& rCode);
private:
+ friend struct FocusManagerCreator;
+
class LinkMap;
::std::auto_ptr<LinkMap> mpLinks;
@@ -132,3 +135,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneShellManager.cxx b/sd/source/ui/toolpanel/TaskPaneShellManager.cxx
index eb49ca4d4..51bba27e5 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneShellManager.cxx
+++ b/sd/source/ui/toolpanel/TaskPaneShellManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -181,3 +182,5 @@ IMPL_LINK(TaskPaneShellManager, WindowCallback, VclWindowEvent*, pEvent)
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneShellManager.hxx b/sd/source/ui/toolpanel/TaskPaneShellManager.hxx
index 10862070d..f70a90c0e 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneShellManager.hxx
+++ b/sd/source/ui/toolpanel/TaskPaneShellManager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -119,3 +120,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TaskPaneTreeNode.cxx b/sd/source/ui/toolpanel/TaskPaneTreeNode.cxx
index e76aabdc9..904c0dcad 100755..100644
--- a/sd/source/ui/toolpanel/TaskPaneTreeNode.cxx
+++ b/sd/source/ui/toolpanel/TaskPaneTreeNode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -290,3 +291,5 @@ TreeNodeStateChangeEvent::TreeNodeStateChangeEvent (
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TestMenu.cxx b/sd/source/ui/toolpanel/TestMenu.cxx
index ec4b96341..294197b9f 100755..100644
--- a/sd/source/ui/toolpanel/TestMenu.cxx
+++ b/sd/source/ui/toolpanel/TestMenu.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -316,3 +317,5 @@ void ColorMenu::Fill (void)
#endif
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TestMenu.hxx b/sd/source/ui/toolpanel/TestMenu.hxx
index 1670e9531..7eb4882e4 100755..100644
--- a/sd/source/ui/toolpanel/TestMenu.hxx
+++ b/sd/source/ui/toolpanel/TestMenu.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,3 +83,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TestPanel.cxx b/sd/source/ui/toolpanel/TestPanel.cxx
index ac1265503..a0d060e90 100755..100644
--- a/sd/source/ui/toolpanel/TestPanel.cxx
+++ b/sd/source/ui/toolpanel/TestPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -172,3 +173,5 @@ std::auto_ptr<ControlFactory> TestPanel::CreateControlFactory (void)
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TestPanel.hxx b/sd/source/ui/toolpanel/TestPanel.hxx
index 135e2827b..d923e4257 100755..100644
--- a/sd/source/ui/toolpanel/TestPanel.hxx
+++ b/sd/source/ui/toolpanel/TestPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,5 @@ public:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TitleBar.cxx b/sd/source/ui/toolpanel/TitleBar.cxx
index d29fe08a4..3515c0354 100755..100644
--- a/sd/source/ui/toolpanel/TitleBar.cxx
+++ b/sd/source/ui/toolpanel/TitleBar.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -36,7 +37,7 @@
#include <vcl/decoview.hxx>
#include <vcl/window.hxx>
#include <vcl/virdev.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include "sdresid.hxx"
#include <vcl/bitmap.hxx>
@@ -251,7 +252,6 @@ bool TitleBar::HasExpansionIndicator (void) const
Image TitleBar::GetExpansionIndicator (void) const
{
Image aIndicator;
- bool bHighContrastMode (GetSettings().GetStyleSettings().GetHighContrastMode() != 0);
if (mbIsExpandable)
{
sal_uInt16 nResourceId = 0;
@@ -259,15 +259,9 @@ Image TitleBar::GetExpansionIndicator (void) const
{
case TBT_SUB_CONTROL_HEADLINE:
if (mbExpanded)
- if (bHighContrastMode)
- nResourceId = BMP_COLLAPSE_H;
- else
- nResourceId = BMP_COLLAPSE;
+ nResourceId = BMP_COLLAPSE;
else
- if (bHighContrastMode)
- nResourceId = BMP_EXPAND_H;
- else
- nResourceId = BMP_EXPAND;
+ nResourceId = BMP_EXPAND;
aIndicator = IconCache::Instance().GetIcon(nResourceId);
break;
@@ -286,7 +280,7 @@ void TitleBar::PaintSubPanelHeadLineBar (void)
Rectangle aTextBox (CalculateTextBoundingBox (nWidth, true));
Rectangle aTitleBarBox (CalculateTitleBarBox(aTextBox, nWidth));
- int nVerticalOffset = -aTitleBarBox.Top();
+ int nVerticalOffset = -aTitleBarBox.Top();
aTitleBarBox.Top() += nVerticalOffset;
aTitleBarBox.Bottom() += nVerticalOffset;
aTextBox.Top() += nVerticalOffset;
@@ -376,9 +370,9 @@ sal_uInt16 TitleBar::GetTextStyle (void)
{
if(IsEnabled())
{
- return TEXT_DRAW_LEFT
+ return TEXT_DRAW_LEFT
| TEXT_DRAW_TOP
- | TEXT_DRAW_MULTILINE
+ | TEXT_DRAW_MULTILINE
| TEXT_DRAW_WORDBREAK;
}
else
@@ -451,7 +445,7 @@ Rectangle TitleBar::CalculateTextBoundingBox (
Rectangle aTextBox (
Point(0,0),
- Size (nAvailableWidth,
+ Size (nAvailableWidth,
GetSettings().GetStyleSettings().GetTitleHeight()));
aTextBox.Top() += (aTextBox.GetHeight() - GetTextHeight()) / 2;
if (HasExpansionIndicator())
@@ -583,3 +577,5 @@ String TitleBar::GetTitle (void) const
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/TitledControl.cxx b/sd/source/ui/toolpanel/TitledControl.cxx
index 891ade2dd..d06812e85 100755..100644
--- a/sd/source/ui/toolpanel/TitledControl.cxx
+++ b/sd/source/ui/toolpanel/TitledControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -430,3 +431,5 @@ void TitledControlStandardClickHandler::operator () (TitledControl& rTitledContr
}
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanel.cxx b/sd/source/ui/toolpanel/ToolPanel.cxx
index 9f3e0830c..c89040739 100755..100644
--- a/sd/source/ui/toolpanel/ToolPanel.cxx
+++ b/sd/source/ui/toolpanel/ToolPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -111,3 +112,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
} } // namespace sd::toolpanel
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanel.hxx b/sd/source/ui/toolpanel/ToolPanel.hxx
index f40873a41..311944c71 100644
--- a/sd/source/ui/toolpanel/ToolPanel.hxx
+++ b/sd/source/ui/toolpanel/ToolPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -78,3 +79,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
#endif // SD_TOOLPANEL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanelDescriptor.hxx b/sd/source/ui/toolpanel/ToolPanelDescriptor.hxx
index 0210246d7..98943d6c5 100644
--- a/sd/source/ui/toolpanel/ToolPanelDescriptor.hxx
+++ b/sd/source/ui/toolpanel/ToolPanelDescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,5 @@ private:
} } // end of namespace ::sd::toolpanel
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanelFactory.cxx b/sd/source/ui/toolpanel/ToolPanelFactory.cxx
index 767dece44..86adba943 100644
--- a/sd/source/ui/toolpanel/ToolPanelFactory.cxx
+++ b/sd/source/ui/toolpanel/ToolPanelFactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -43,7 +44,7 @@
#include <sfx2/frame.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <sfx2/viewfrm.hxx>
#include <cppuhelper/implbase3.hxx>
#include <comphelper/namedvaluecollection.hxx>
@@ -142,7 +143,7 @@ namespace sd { namespace toolpanel
//------------------------------------------------------------------------------------------------------------------
Reference< XUIElement > SAL_CALL ToolPanelFactory::createUIElement( const ::rtl::OUString& i_rResourceURL, const Sequence< PropertyValue >& i_rArgs ) throw (NoSuchElementException, IllegalArgumentException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
const PanelId ePanelId( toolpanel::GetStandardPanelId( i_rResourceURL ) );
if ( ePanelId == PID_UNKNOWN )
@@ -253,3 +254,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
} } // namespace sd::toolpanel
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanelUIElement.cxx b/sd/source/ui/toolpanel/ToolPanelUIElement.cxx
index b9b808133..f4f3501b6 100644
--- a/sd/source/ui/toolpanel/ToolPanelUIElement.cxx
+++ b/sd/source/ui/toolpanel/ToolPanelUIElement.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -132,3 +133,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
} } // namespace sd::toolpanel
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanelUIElement.hxx b/sd/source/ui/toolpanel/ToolPanelUIElement.hxx
index 4b0baf02c..685a3f961 100644
--- a/sd/source/ui/toolpanel/ToolPanelUIElement.hxx
+++ b/sd/source/ui/toolpanel/ToolPanelUIElement.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -85,3 +86,5 @@ namespace sd { namespace toolpanel
//......................................................................................................................
#endif // SD_TOOLPANELUIELEMENT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/ToolPanelViewShell.cxx b/sd/source/ui/toolpanel/ToolPanelViewShell.cxx
index 53c8eab6b..514a48bc1 100755..100644
--- a/sd/source/ui/toolpanel/ToolPanelViewShell.cxx
+++ b/sd/source/ui/toolpanel/ToolPanelViewShell.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -218,7 +219,7 @@ public:
static const size_t mnInvalidId = static_cast< size_t >( -1 );
ToolPanelViewShell_Impl( ToolPanelViewShell& i_rPanelViewShell, ::Window& i_rPanelDeckParent );
- ~ToolPanelViewShell_Impl();
+ virtual ~ToolPanelViewShell_Impl();
ToolPanelViewShell& GetAntiImpl() { return m_rPanelViewShell; }
@@ -482,6 +483,8 @@ ToolPanelViewShell::ToolPanelViewShell( SfxViewFrame* pFrame, ViewShellBase& rVi
,mpSubShellManager()
,mnMenuId(0)
{
+ ViewShell::doShow();
+
meShellType = ST_TASK_PANE;
mpContentWindow->SetCenterAllowed( false );
@@ -553,6 +556,7 @@ ToolPanelViewShell::~ToolPanelViewShell()
// disposed/destroyed, too
mpImpl.reset();
GetViewShellBase().GetViewShellManager()->RemoveSubShellFactory(this, mpSubShellManager);
+ GetFrameView()->Disconnect();
}
// ---------------------------------------------------------------------------------------------------------------------
@@ -899,3 +903,5 @@ Reference< XAccessible > ToolPanelViewShell_Impl::CreateAccessible( ::sd::Window
}
} } // end of namespace ::sd::toolpanel
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx b/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx
index a43812e3c..99a13e145 100644
--- a/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx
+++ b/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -206,3 +207,5 @@ void AllMasterPagesSelector::GetState (SfxItemSet& rItemSet)
} } } // end of namespace ::sd::toolpanel::control
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx b/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx
index 10ed29853..7e6c84602 100755..100644
--- a/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx
+++ b/sd/source/ui/toolpanel/controls/AllMasterPagesSelector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.cxx b/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.cxx
index 01531d4f2..fd1eaa354 100755..100644
--- a/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.cxx
+++ b/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -24,35 +25,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2008 by Sun Microsystems, Inc.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * $RCSfile: AnimationSchemesPanel.cxx,v $
- * $Revision: 1.6 $
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
@@ -168,3 +140,5 @@ bool AnimationSchemesPanel::IsExpandable() const
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.hxx b/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.hxx
index 1b947de16..05347ccb4 100755..100644
--- a/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.hxx
+++ b/sd/source/ui/toolpanel/controls/AnimationSchemesPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -24,35 +25,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2008 by Sun Microsystems, Inc.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * $RCSfile: AnimationSchemesPanel.hxx,v $
- * $Revision: 1.6 $
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
#ifndef SD_TASKPANE_CONTROLS_ANIMATION_SCHEMES_PANEL_HXX
#define SD_TASKPANE_CONTROLS_ANIMATION_SCHEMES_PANEL_HXX
@@ -136,3 +108,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx b/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx
index 2e5d5cde2..b0c85922e 100755..100644
--- a/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx
+++ b/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -341,3 +342,5 @@ void CurrentMasterPagesSelector::Notify (SfxBroadcaster&, const SfxHint& rHint)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx b/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx
index ca3676957..393e8b0e7 100644
--- a/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx
+++ b/sd/source/ui/toolpanel/controls/CurrentMasterPagesSelector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -81,3 +82,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/CustomAnimationPanel.cxx b/sd/source/ui/toolpanel/controls/CustomAnimationPanel.cxx
index e20f1934c..470dd63ea 100755..100644
--- a/sd/source/ui/toolpanel/controls/CustomAnimationPanel.cxx
+++ b/sd/source/ui/toolpanel/controls/CustomAnimationPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -111,3 +112,5 @@ bool CustomAnimationPanel::IsExpandable() const
}
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/CustomAnimationPanel.hxx b/sd/source/ui/toolpanel/controls/CustomAnimationPanel.hxx
index f4eeca4ca..d9ee13dab 100755..100644
--- a/sd/source/ui/toolpanel/controls/CustomAnimationPanel.hxx
+++ b/sd/source/ui/toolpanel/controls/CustomAnimationPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79,3 +80,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/DocumentHelper.cxx b/sd/source/ui/toolpanel/controls/DocumentHelper.cxx
index 90e95eb3d..ff42e8264 100755..100644
--- a/sd/source/ui/toolpanel/controls/DocumentHelper.cxx
+++ b/sd/source/ui/toolpanel/controls/DocumentHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -244,17 +245,17 @@ SdPage* DocumentHelper::AddMasterPage (
// master page.
rTargetDocument.InsertMasterPage (pClonedMasterPage);
}
- catch (uno::Exception& rException)
+ catch(const uno::Exception&)
{
pClonedMasterPage = NULL;
DBG_UNHANDLED_EXCEPTION();
}
- catch (::std::exception rException)
+ catch(const ::std::exception&)
{
pClonedMasterPage = NULL;
OSL_TRACE ("caught general exception");
}
- catch (...)
+ catch(...)
{
pClonedMasterPage = NULL;
OSL_TRACE ("caught general exception");
@@ -311,59 +312,55 @@ void DocumentHelper::AssignMasterPageToPageList (
SdPage* pMasterPage,
const ::boost::shared_ptr<std::vector<SdPage*> >& rpPageList)
{
- do
- {
- if (pMasterPage == NULL && pMasterPage->IsMasterPage())
- break;
+ if (pMasterPage == NULL || !pMasterPage->IsMasterPage())
+ return;
- // Make the layout name by stripping ouf the layout postfix from the
- // layout name of the given master page.
- String sFullLayoutName (pMasterPage->GetLayoutName());
- String sBaseLayoutName (sFullLayoutName);
- sBaseLayoutName.Erase (sBaseLayoutName.SearchAscii (SD_LT_SEPARATOR));
+ // Make the layout name by stripping ouf the layout postfix from the
+ // layout name of the given master page.
+ String sFullLayoutName (pMasterPage->GetLayoutName());
+ String sBaseLayoutName (sFullLayoutName);
+ sBaseLayoutName.Erase (sBaseLayoutName.SearchAscii (SD_LT_SEPARATOR));
- if (rpPageList->empty())
- break;
+ if (rpPageList->empty())
+ return;
- // Create a second list that contains only the valid pointers to
- // pages for which an assignment is necessary.
- ::std::vector<SdPage*>::const_iterator iPage;
- ::std::vector<SdPage*> aCleanedList;
- for (iPage=rpPageList->begin(); iPage!=rpPageList->end(); ++iPage)
+ // Create a second list that contains only the valid pointers to
+ // pages for which an assignment is necessary.
+ ::std::vector<SdPage*>::const_iterator iPage;
+ ::std::vector<SdPage*> aCleanedList;
+ for (iPage=rpPageList->begin(); iPage!=rpPageList->end(); ++iPage)
+ {
+ OSL_ASSERT(*iPage!=NULL && (*iPage)->GetModel() == &rTargetDocument);
+ if (*iPage != NULL
+ && (*iPage)->GetLayoutName().CompareTo(sFullLayoutName)!=0)
{
- OSL_ASSERT(*iPage!=NULL && (*iPage)->GetModel() == &rTargetDocument);
- if (*iPage != NULL
- && (*iPage)->GetLayoutName().CompareTo(sFullLayoutName)!=0)
- {
- aCleanedList.push_back(*iPage);
- }
+ aCleanedList.push_back(*iPage);
}
- if (aCleanedList.size() == 0)
- break;
-
- ::svl::IUndoManager* pUndoMgr = rTargetDocument.GetDocSh()->GetUndoManager();
- if( pUndoMgr )
- pUndoMgr->EnterListAction(String(SdResId(STR_UNDO_SET_PRESLAYOUT)), String());
+ }
+ if (aCleanedList.size() == 0)
+ return;
- SdPage* pMasterPageInDocument = ProvideMasterPage(rTargetDocument,pMasterPage,rpPageList);
- if (pMasterPageInDocument == NULL)
- break;
+ ::svl::IUndoManager* pUndoMgr = rTargetDocument.GetDocSh()->GetUndoManager();
+ if( pUndoMgr )
+ pUndoMgr->EnterListAction(String(SdResId(STR_UNDO_SET_PRESLAYOUT)), String());
- // Assign the master pages to the given list of pages.
- for (iPage=aCleanedList.begin();
- iPage!=aCleanedList.end();
- ++iPage)
- {
- AssignMasterPageToPage (
- pMasterPageInDocument,
- sBaseLayoutName,
- *iPage);
- }
+ SdPage* pMasterPageInDocument = ProvideMasterPage(rTargetDocument,pMasterPage,rpPageList);
+ if (pMasterPageInDocument == NULL)
+ return;
- if( pUndoMgr )
- pUndoMgr->LeaveListAction();
+ // Assign the master pages to the given list of pages.
+ for (iPage=aCleanedList.begin();
+ iPage!=aCleanedList.end();
+ ++iPage)
+ {
+ AssignMasterPageToPage (
+ pMasterPageInDocument,
+ sBaseLayoutName,
+ *iPage);
}
- while (false);
+
+ if( pUndoMgr )
+ pUndoMgr->LeaveListAction();
}
@@ -583,3 +580,5 @@ SdPage* DocumentHelper::ProvideMasterPage (
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/DocumentHelper.hxx b/sd/source/ui/toolpanel/controls/DocumentHelper.hxx
index 44cd6cd18..046a164fb 100755..100644
--- a/sd/source/ui/toolpanel/controls/DocumentHelper.hxx
+++ b/sd/source/ui/toolpanel/controls/DocumentHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,3 +115,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainer.cxx b/sd/source/ui/toolpanel/controls/MasterPageContainer.cxx
index f290adaaa..bbce925ba 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainer.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -710,8 +711,11 @@ void MasterPageContainer::Implementation::UpdatePreviewSizePixel (void)
if (*iDescriptor!=NULL && (*iDescriptor)->mpMasterPage != NULL)
{
Size aPageSize ((*iDescriptor)->mpMasterPage->GetSize());
- nWidth = aPageSize.Width();
- nHeight = aPageSize.Height();
+ OSL_ASSERT(aPageSize.Width() > 0 && aPageSize.Height() > 0);
+ if (aPageSize.Width() > 0)
+ nWidth = aPageSize.Width();
+ if (aPageSize.Height() > 0)
+ nHeight = aPageSize.Height();
mbFirstPageObjectSeen = true;
break;
}
@@ -1218,3 +1222,5 @@ void MasterPageContainer::Implementation::FillingDone (void)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainer.hxx b/sd/source/ui/toolpanel/controls/MasterPageContainer.hxx
index b4d2ca4cf..6a7d5ecaf 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainer.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -218,3 +219,5 @@ public:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.cxx b/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.cxx
index f83e1a637..164c39e41 100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -197,3 +198,5 @@ MasterPageContainerFiller::State MasterPageContainerFiller::AddTemplate (void)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.hxx b/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.hxx
index 3c15fe6ea..f83db4b59 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerFiller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.cxx b/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.cxx
index 1904ec318..a9fa93d5c 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -130,8 +131,8 @@ Image TemplatePreviewProvider::operator() (
{
uno::Reference<lang::XSingleServiceFactory> xStorageFactory(
xServiceManager->createInstance(
- ::rtl::OUString::createFromAscii(
- "com.sun.star.embed.StorageFactory")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "com.sun.star.embed.StorageFactory"))),
uno::UNO_QUERY);
if (xStorageFactory.is())
@@ -149,14 +150,14 @@ Image TemplatePreviewProvider::operator() (
{
uno::Reference<embed::XStorage> xStorage (
xDocStorage->openStorageElement(
- ::rtl::OUString::createFromAscii("Thumbnails"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Thumbnails")),
embed::ElementModes::READ));
if (xStorage.is())
{
uno::Reference<io::XStream> xThumbnailCopy (
xStorage->cloneStreamElement(
- ::rtl::OUString::createFromAscii(
- "thumbnail.png")));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "thumbnail.png"))));
if (xThumbnailCopy.is())
xIStream = xThumbnailCopy->getInputStream();
}
@@ -182,14 +183,14 @@ Image TemplatePreviewProvider::operator() (
{
uno::Reference<embed::XStorage> xStorage (
xDocStorage->openStorageElement(
- ::rtl::OUString::createFromAscii("Thumbnail"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Thumbnail")),
embed::ElementModes::READ));
if (xStorage.is())
{
uno::Reference<io::XStream> xThumbnailCopy (
xStorage->cloneStreamElement(
- ::rtl::OUString::createFromAscii(
- "thumbnail.png")));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(
+ "thumbnail.png"))));
if (xThumbnailCopy.is())
xIStream = xThumbnailCopy->getInputStream();
}
@@ -427,3 +428,5 @@ bool ExistingPageProvider::operator== (const PageObjectProvider& rProvider)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.hxx b/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.hxx
index a561fbf9b..e07879693 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerProviders.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -187,3 +188,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.cxx b/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.cxx
index e962cd146..895c6edbe 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,8 +54,10 @@ public:
{}
SharedMasterPageDescriptor mpDescriptor;
int mnPriority;
- class Compare {public:
- bool operator() (const PreviewCreationRequest& r1,const PreviewCreationRequest& r2)
+ class Compare
+ {
+ public:
+ bool operator() (const PreviewCreationRequest& r1,const PreviewCreationRequest& r2) const
{
if (r1.mnPriority != r2.mnPriority)
{
@@ -69,11 +72,13 @@ public:
}
}
};
- class CompareToken {public:
+ class CompareToken
+ {
+ public:
MasterPageContainer::Token maToken;
CompareToken(MasterPageContainer::Token aToken) : maToken(aToken) {}
- bool operator() (const PreviewCreationRequest& rRequest)
- { return maToken==rRequest.mpDescriptor->maToken; }
+ bool operator() (const PreviewCreationRequest& rRequest) const
+ { return maToken==rRequest.mpDescriptor->maToken; }
};
};
@@ -302,3 +307,5 @@ void MasterPageContainerQueue::ProcessAllRequests (void)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.hxx b/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.hxx
index 76a075dc3..e4251e48d 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageContainerQueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,3 +135,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageDescriptor.cxx b/sd/source/ui/toolpanel/controls/MasterPageDescriptor.cxx
index bbdbc0928..c891878d4 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageDescriptor.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageDescriptor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -106,7 +107,7 @@ void MasterPageDescriptor::SetToken (MasterPageContainer::Token aToken)
-Image MasterPageDescriptor::GetPreview (MasterPageContainer::PreviewSize eSize)
+Image MasterPageDescriptor::GetPreview (MasterPageContainer::PreviewSize eSize) const
{
if (eSize == MasterPageContainer::SMALL)
return maSmallPreview;
@@ -292,15 +293,15 @@ MasterPageDescriptor::URLClassification MasterPageDescriptor::GetURLClassificati
{
if (msURL.getLength() == 0)
meURLClassification = URLCLASS_UNKNOWN;
- else if (msURL.indexOf(::rtl::OUString::createFromAscii("presnt"))>=0)
+ else if (msURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("presnt")))>=0)
{
meURLClassification = URLCLASS_PRESENTATION;
}
- else if (msURL.indexOf(::rtl::OUString::createFromAscii("layout"))>=0)
+ else if (msURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("layout")))>=0)
{
meURLClassification = URLCLASS_LAYOUT;
}
- else if (msURL.indexOf(::rtl::OUString::createFromAscii("educate"))>=0)
+ else if (msURL.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("educate")))>=0)
{
meURLClassification = URLCLASS_OTHER;
}
@@ -421,3 +422,5 @@ bool MasterPageDescriptor::AllComparator::operator() (const SharedMasterPageDesc
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageDescriptor.hxx b/sd/source/ui/toolpanel/controls/MasterPageDescriptor.hxx
index 2a31bab48..0761d4959 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageDescriptor.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageDescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,7 +78,7 @@ public:
@return
The returned preview may be empty.
*/
- Image GetPreview (MasterPageContainer::PreviewSize ePreviewSize);
+ Image GetPreview (MasterPageContainer::PreviewSize ePreviewSize) const;
/** Use the PreviewProvider to get access to a preview of the master
page.
@@ -238,3 +239,5 @@ public:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPageObserver.cxx b/sd/source/ui/toolpanel/controls/MasterPageObserver.cxx
index 3a7ae626c..f16f6876e 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPageObserver.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPageObserver.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,7 +34,7 @@
#include <algorithm>
#include "drawdoc.hxx"
#include "sdpage.hxx"
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <set>
#include <vector>
#include <svl/lstner.hxx>
@@ -92,7 +93,7 @@ private:
size_t operator()(SdDrawDocument* argument) const
{ return reinterpret_cast<unsigned long>(argument); }
};
- typedef ::std::hash_map<SdDrawDocument*,
+ typedef ::boost::unordered_map<SdDrawDocument*,
MasterPageObserver::MasterPageNameSet,
DrawDocHash>
MasterPageContainer;
@@ -193,7 +194,7 @@ void MasterPageObserver::Implementation::RegisterDocument (
SdDrawDocument& rDocument)
{
// Gather the names of all the master pages in the given document.
- MasterPageContainer::data_type aMasterPageSet;
+ MasterPageContainer::mapped_type aMasterPageSet;
sal_uInt16 nMasterPageCount = rDocument.GetMasterSdPageCount(PK_STANDARD);
for (sal_uInt16 nIndex=0; nIndex<nMasterPageCount; nIndex++)
{
@@ -424,3 +425,5 @@ void MasterPageObserver::Implementation::SendEvent (
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPagesPanel.cxx b/sd/source/ui/toolpanel/controls/MasterPagesPanel.cxx
index c92a07d8b..d23b48c38 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPagesPanel.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPagesPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,7 +62,6 @@ void MasterPagesPanel::impl_construct( ViewShellBase& rBase )
{
SdDrawDocument* pDocument = rBase.GetDocument();
::std::auto_ptr<controls::MasterPagesSelector> pSelector;
- TitledControl* pTitledControl;
::boost::shared_ptr<MasterPageContainer> pContainer (new MasterPageContainer());
@@ -79,7 +79,7 @@ void MasterPagesPanel::impl_construct( ViewShellBase& rBase )
SHELLID_SD_TASK_PANE_PREVIEW_CURRENT,
pSelector.get(),
pSelector->GetWindow());
- pTitledControl = AddControl (
+ AddControl (
::std::auto_ptr<TreeNode>(pSelector.release()),
SdResId(STR_TASKPANEL_CURRENT_MASTER_PAGES_TITLE),
HID_SD_CURRENT_MASTERS);
@@ -96,7 +96,7 @@ void MasterPagesPanel::impl_construct( ViewShellBase& rBase )
SHELLID_SD_TASK_PANE_PREVIEW_RECENT,
pSelector.get(),
pSelector->GetWindow());
- pTitledControl = AddControl (
+ AddControl (
::std::auto_ptr<TreeNode>(pSelector.release()),
SdResId(STR_TASKPANEL_RECENT_MASTER_PAGES_TITLE),
HID_SD_RECENT_MASTERS);
@@ -114,7 +114,7 @@ void MasterPagesPanel::impl_construct( ViewShellBase& rBase )
SHELLID_SD_TASK_PANE_PREVIEW_ALL,
pSelector.get(),
pSelector->GetWindow());
- pTitledControl = AddControl (
+ AddControl (
::std::auto_ptr<TreeNode>(pSelector.release()),
SdResId(STR_TASKPANEL_ALL_MASTER_PAGES_TITLE),
HID_SD_ALL_MASTERS);
@@ -156,3 +156,5 @@ std::auto_ptr< ControlFactory > MasterPagesPanel::CreateControlFactory( ToolPane
}
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPagesPanel.hxx b/sd/source/ui/toolpanel/controls/MasterPagesPanel.hxx
index 691cf0ac2..8c886d007 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPagesPanel.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPagesPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx b/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx
index 28b2362e0..ca0243d64 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx
+++ b/sd/source/ui/toolpanel/controls/MasterPagesSelector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,9 +55,7 @@
#include <sfx2/objface.hxx>
#include "sdresid.hxx"
#include "TemplateScanner.hxx"
-#ifndef _SD_DRAWVIEW_HXX
#include "drawview.hxx"
-#endif
#include <vcl/image.hxx>
#include <svl/languageoptions.hxx>
#include <sfx2/app.hxx>
@@ -345,34 +344,30 @@ SdPage* MasterPagesSelector::GetSelectedMasterPage (void)
*/
void MasterPagesSelector::AssignMasterPageToAllSlides (SdPage* pMasterPage)
{
- do
- {
- if (pMasterPage == NULL)
- break;
+ if (pMasterPage == NULL)
+ return;
- sal_uInt16 nPageCount = mrDocument.GetSdPageCount(PK_STANDARD);
- if (nPageCount == 0)
- break;
+ sal_uInt16 nPageCount = mrDocument.GetSdPageCount(PK_STANDARD);
+ if (nPageCount == 0)
+ return;
- // Get a list of all pages. As a little optimization we only
- // include pages that do not already have the given master page
- // assigned.
- String sFullLayoutName (pMasterPage->GetLayoutName());
- ::sd::slidesorter::SharedPageSelection pPageList (
- new ::sd::slidesorter::SlideSorterViewShell::PageSelection());
- for (sal_uInt16 nPageIndex=0; nPageIndex<nPageCount; nPageIndex++)
+ // Get a list of all pages. As a little optimization we only
+ // include pages that do not already have the given master page
+ // assigned.
+ String sFullLayoutName (pMasterPage->GetLayoutName());
+ ::sd::slidesorter::SharedPageSelection pPageList (
+ new ::sd::slidesorter::SlideSorterViewShell::PageSelection());
+ for (sal_uInt16 nPageIndex=0; nPageIndex<nPageCount; nPageIndex++)
+ {
+ SdPage* pPage = mrDocument.GetSdPage (nPageIndex, PK_STANDARD);
+ if (pPage != NULL
+ && pPage->GetLayoutName().CompareTo(sFullLayoutName)!=0)
{
- SdPage* pPage = mrDocument.GetSdPage (nPageIndex, PK_STANDARD);
- if (pPage != NULL
- && pPage->GetLayoutName().CompareTo(sFullLayoutName)!=0)
- {
- pPageList->push_back (pPage);
- }
+ pPageList->push_back (pPage);
}
-
- AssignMasterPageToPageList(pMasterPage, pPageList);
}
- while (false);
+
+ AssignMasterPageToPageList(pMasterPage, pPageList);
}
@@ -384,31 +379,26 @@ void MasterPagesSelector::AssignMasterPageToAllSlides (SdPage* pMasterPage)
void MasterPagesSelector::AssignMasterPageToSelectedSlides (
SdPage* pMasterPage)
{
- do
- {
- using namespace ::std;
- using namespace ::sd::slidesorter;
- using namespace ::sd::slidesorter::controller;
+ using namespace ::sd::slidesorter;
+ using namespace ::sd::slidesorter::controller;
- if (pMasterPage == NULL)
- break;
+ if (pMasterPage == NULL)
+ return;
- // Find a visible slide sorter.
- SlideSorterViewShell* pSlideSorter = SlideSorterViewShell::GetSlideSorter(mrBase);
- if (pSlideSorter == NULL)
- break;
+ // Find a visible slide sorter.
+ SlideSorterViewShell* pSlideSorter = SlideSorterViewShell::GetSlideSorter(mrBase);
+ if (pSlideSorter == NULL)
+ return;
- // Get a list of selected pages.
- ::sd::slidesorter::SharedPageSelection pPageSelection = pSlideSorter->GetPageSelection();
- if (pPageSelection->empty())
- break;
+ // Get a list of selected pages.
+ SharedPageSelection pPageSelection = pSlideSorter->GetPageSelection();
+ if (pPageSelection->empty())
+ return;
- AssignMasterPageToPageList(pMasterPage, pPageSelection);
+ AssignMasterPageToPageList(pMasterPage, pPageSelection);
- // Restore the previous selection.
- pSlideSorter->SetPageSelection(pPageSelection);
- }
- while (false);
+ // Restore the previous selection.
+ pSlideSorter->SetPageSelection(pPageSelection);
}
@@ -477,7 +467,7 @@ MasterPagesSelector::UserData* MasterPagesSelector::GetUserData (int nIndex) con
{
const ::osl::MutexGuard aGuard (maMutex);
- if (nIndex>0 && nIndex<=mpPageSet->GetItemCount())
+ if (nIndex>0 && static_cast<unsigned int>(nIndex)<=mpPageSet->GetItemCount())
return reinterpret_cast<UserData*>(mpPageSet->GetItemData((sal_uInt16)nIndex));
else
return NULL;
@@ -490,7 +480,7 @@ void MasterPagesSelector::SetUserData (int nIndex, UserData* pData)
{
const ::osl::MutexGuard aGuard (maMutex);
- if (nIndex>0 && nIndex<=mpPageSet->GetItemCount())
+ if (nIndex>0 && static_cast<unsigned int>(nIndex)<=mpPageSet->GetItemCount())
{
UserData* pOldData = GetUserData(nIndex);
if (pOldData!=NULL && pOldData!=pData)
@@ -852,3 +842,5 @@ void MasterPagesSelector::UpdateItemList (::std::auto_ptr<ItemList> pNewItemList
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx b/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx
index 15f71aef2..52bc25a7c 100755..100644
--- a/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx
+++ b/sd/source/ui/toolpanel/controls/MasterPagesSelector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -234,3 +235,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/PreviewValueSet.cxx b/sd/source/ui/toolpanel/controls/PreviewValueSet.cxx
index 0f5276165..b3870512d 100755..100644
--- a/sd/source/ui/toolpanel/controls/PreviewValueSet.cxx
+++ b/sd/source/ui/toolpanel/controls/PreviewValueSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -238,3 +239,5 @@ sal_Int32 PreviewValueSet::GetPreferredHeight (sal_Int32 nWidth)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/PreviewValueSet.hxx b/sd/source/ui/toolpanel/controls/PreviewValueSet.hxx
index 38c64e969..986a061a3 100755..100644
--- a/sd/source/ui/toolpanel/controls/PreviewValueSet.hxx
+++ b/sd/source/ui/toolpanel/controls/PreviewValueSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,3 +95,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx b/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx
index b6f3a6978..450aa7423 100755..100644
--- a/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx
+++ b/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,3 +158,5 @@ void RecentMasterPagesSelector::GetState (SfxItemSet& rItemSet)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx b/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx
index 5bc85209d..108aa24b2 100644
--- a/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx
+++ b/sd/source/ui/toolpanel/controls/RecentMasterPagesSelector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ protected:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.cxx b/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.cxx
index a7e400214..558cfd69f 100644
--- a/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.cxx
+++ b/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,12 +96,14 @@ public:
maToken(aToken)
{}
class TokenComparator
- { public:
+ {
+ public:
TokenComparator(::sd::toolpanel::controls::MasterPageContainer::Token aToken)
: maToken(aToken) {}
- bool operator () (const Descriptor& rDescriptor)
- { return maToken==rDescriptor.maToken; }
- private: ::sd::toolpanel::controls::MasterPageContainer::Token maToken;
+ bool operator () (const Descriptor& rDescriptor) const
+ { return maToken==rDescriptor.maToken; }
+ private:
+ ::sd::toolpanel::controls::MasterPageContainer::Token maToken;
};
};
@@ -187,64 +190,60 @@ void RecentlyUsedMasterPages::LoadPersistentValues (void)
{
try
{
- do
+ tools::ConfigurationAccess aConfiguration (
+ GetPathToImpressConfigurationRoot(),
+ tools::ConfigurationAccess::READ_ONLY);
+ Reference<container::XNameAccess> xSet (
+ aConfiguration.GetConfigurationNode(GetPathToSetNode()),
+ UNO_QUERY);
+ if ( ! xSet.is())
+ return;
+
+ const String sURLMemberName (RTL_CONSTASCII_USTRINGPARAM("URL"));
+ const String sNameMemberName (RTL_CONSTASCII_USTRINGPARAM("Name"));
+ OUString sURL;
+ OUString sName;
+
+ // Read the names and URLs of the master pages.
+ Sequence<OUString> aKeys (xSet->getElementNames());
+ mpMasterPages->clear();
+ mpMasterPages->reserve(aKeys.getLength());
+ for (int i=0; i<aKeys.getLength(); i++)
{
- tools::ConfigurationAccess aConfiguration (
- GetPathToImpressConfigurationRoot(),
- tools::ConfigurationAccess::READ_ONLY);
- Reference<container::XNameAccess> xSet (
- aConfiguration.GetConfigurationNode(GetPathToSetNode()),
- UNO_QUERY);
- if ( ! xSet.is())
- break;
-
- const String sURLMemberName (OUString::createFromAscii("URL"));
- const String sNameMemberName (OUString::createFromAscii("Name"));
- OUString sURL;
- OUString sName;
-
- // Read the names and URLs of the master pages.
- Sequence<OUString> aKeys (xSet->getElementNames());
- mpMasterPages->clear();
- mpMasterPages->reserve(aKeys.getLength());
- for (int i=0; i<aKeys.getLength(); i++)
+ Reference<container::XNameAccess> xSetItem (
+ xSet->getByName(aKeys[i]), UNO_QUERY);
+ if (xSetItem.is())
{
- Reference<container::XNameAccess> xSetItem (
- xSet->getByName(aKeys[i]), UNO_QUERY);
- if (xSetItem.is())
- {
- Any aURL (xSetItem->getByName(sURLMemberName));
- Any aName (xSetItem->getByName(sNameMemberName));
- aURL >>= sURL;
- aName >>= sName;
- SharedMasterPageDescriptor pDescriptor (new MasterPageDescriptor(
- MasterPageContainer::TEMPLATE,
- -1,
- sURL,
- String(),
- sName,
- false,
- ::boost::shared_ptr<PageObjectProvider>(
- new TemplatePageObjectProvider(sURL)),
- ::boost::shared_ptr<PreviewProvider>(
- new TemplatePreviewProvider(sURL))));
- // For user supplied templates we use a different
- // preview provider: The preview in the document shows
- // not only shapes on the master page but also shapes on
- // the foreground. This is misleading and therefore
- // these previews are discarded and created directly
- // from the page objects.
- if (pDescriptor->GetURLClassification() == MasterPageDescriptor::URLCLASS_USER)
- pDescriptor->mpPreviewProvider = ::boost::shared_ptr<PreviewProvider>(
- new PagePreviewProvider());
- MasterPageContainer::Token aToken (mpContainer->PutMasterPage(pDescriptor));
- mpMasterPages->push_back(Descriptor(aToken,sURL,sName));
- }
+ Any aURL (xSetItem->getByName(sURLMemberName));
+ Any aName (xSetItem->getByName(sNameMemberName));
+ aURL >>= sURL;
+ aName >>= sName;
+ SharedMasterPageDescriptor pDescriptor (new MasterPageDescriptor(
+ MasterPageContainer::TEMPLATE,
+ -1,
+ sURL,
+ String(),
+ sName,
+ false,
+ ::boost::shared_ptr<PageObjectProvider>(
+ new TemplatePageObjectProvider(sURL)),
+ ::boost::shared_ptr<PreviewProvider>(
+ new TemplatePreviewProvider(sURL))));
+ // For user supplied templates we use a different
+ // preview provider: The preview in the document shows
+ // not only shapes on the master page but also shapes on
+ // the foreground. This is misleading and therefore
+ // these previews are discarded and created directly
+ // from the page objects.
+ if (pDescriptor->GetURLClassification() == MasterPageDescriptor::URLCLASS_USER)
+ pDescriptor->mpPreviewProvider = ::boost::shared_ptr<PreviewProvider>(
+ new PagePreviewProvider());
+ MasterPageContainer::Token aToken (mpContainer->PutMasterPage(pDescriptor));
+ mpMasterPages->push_back(Descriptor(aToken,sURL,sName));
}
-
- ResolveList();
}
- while (false);
+
+ ResolveList();
}
catch (Exception&)
{
@@ -259,58 +258,54 @@ void RecentlyUsedMasterPages::SavePersistentValues (void)
{
try
{
- do
+ tools::ConfigurationAccess aConfiguration (
+ GetPathToImpressConfigurationRoot(),
+ tools::ConfigurationAccess::READ_WRITE);
+ Reference<container::XNameContainer> xSet (
+ aConfiguration.GetConfigurationNode(GetPathToSetNode()),
+ UNO_QUERY);
+ if ( ! xSet.is())
+ return;
+
+ // Clear the set.
+ Sequence<OUString> aKeys (xSet->getElementNames());
+ sal_Int32 i;
+ for (i=0; i<aKeys.getLength(); i++)
+ xSet->removeByName (aKeys[i]);
+
+ // Fill it with the URLs of this object.
+ const String sURLMemberName (RTL_CONSTASCII_USTRINGPARAM("URL"));
+ const String sNameMemberName (RTL_CONSTASCII_USTRINGPARAM("Name"));
+ Any aValue;
+ Reference<lang::XSingleServiceFactory> xChildFactory (
+ xSet, UNO_QUERY);
+ if ( ! xChildFactory.is())
+ return;
+ MasterPageList::const_iterator iDescriptor;
+ sal_Int32 nIndex(0);
+ for (iDescriptor=mpMasterPages->begin();
+ iDescriptor!=mpMasterPages->end();
+ ++iDescriptor,++nIndex)
{
- tools::ConfigurationAccess aConfiguration (
- GetPathToImpressConfigurationRoot(),
- tools::ConfigurationAccess::READ_WRITE);
- Reference<container::XNameContainer> xSet (
- aConfiguration.GetConfigurationNode(GetPathToSetNode()),
- UNO_QUERY);
- if ( ! xSet.is())
- break;
-
- // Clear the set.
- Sequence<OUString> aKeys (xSet->getElementNames());
- sal_Int32 i;
- for (i=0; i<aKeys.getLength(); i++)
- xSet->removeByName (aKeys[i]);
-
- // Fill it with the URLs of this object.
- const String sURLMemberName (OUString::createFromAscii("URL"));
- const String sNameMemberName (OUString::createFromAscii("Name"));
- Any aValue;
- Reference<lang::XSingleServiceFactory> xChildFactory (
- xSet, UNO_QUERY);
- if ( ! xChildFactory.is())
- break;
- MasterPageList::const_iterator iDescriptor;
- sal_Int32 nIndex(0);
- for (iDescriptor=mpMasterPages->begin();
- iDescriptor!=mpMasterPages->end();
- ++iDescriptor,++nIndex)
+ // Create new child.
+ OUString sKey (RTL_CONSTASCII_USTRINGPARAM("index_"));
+ sKey += OUString::valueOf(nIndex);
+ Reference<container::XNameReplace> xChild(
+ xChildFactory->createInstance(), UNO_QUERY);
+ if (xChild.is())
{
- // Create new child.
- OUString sKey (OUString::createFromAscii("index_"));
- sKey += OUString::valueOf(nIndex);
- Reference<container::XNameReplace> xChild(
- xChildFactory->createInstance(), UNO_QUERY);
- if (xChild.is())
- {
- xSet->insertByName (sKey, makeAny(xChild));
-
- aValue <<= OUString(iDescriptor->msURL);
- xChild->replaceByName (sURLMemberName, aValue);
-
- aValue <<= OUString(iDescriptor->msName);
- xChild->replaceByName (sNameMemberName, aValue);
- }
- }
+ xSet->insertByName (sKey, makeAny(xChild));
+
+ aValue <<= OUString(iDescriptor->msURL);
+ xChild->replaceByName (sURLMemberName, aValue);
- // Write the data back to disk.
- aConfiguration.CommitChanges();
+ aValue <<= OUString(iDescriptor->msName);
+ xChild->replaceByName (sNameMemberName, aValue);
+ }
}
- while (false);
+
+ // Write the data back to disk.
+ aConfiguration.CommitChanges();
}
catch (Exception&)
{
@@ -499,3 +494,5 @@ void RecentlyUsedMasterPages::ResolveList (void)
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.hxx b/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.hxx
index a786a8513..1e1536259 100755..100644
--- a/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.hxx
+++ b/sd/source/ui/toolpanel/controls/RecentlyUsedMasterPages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -126,3 +127,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/SlideTransitionPanel.cxx b/sd/source/ui/toolpanel/controls/SlideTransitionPanel.cxx
index 7a58923b4..d0d5ef0cd 100755..100644
--- a/sd/source/ui/toolpanel/controls/SlideTransitionPanel.cxx
+++ b/sd/source/ui/toolpanel/controls/SlideTransitionPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,3 +115,5 @@ bool SlideTransitionPanel::IsExpandable() const
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/SlideTransitionPanel.hxx b/sd/source/ui/toolpanel/controls/SlideTransitionPanel.hxx
index e2135c7da..48e29ebbd 100755..100644
--- a/sd/source/ui/toolpanel/controls/SlideTransitionPanel.hxx
+++ b/sd/source/ui/toolpanel/controls/SlideTransitionPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79,3 +80,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/TableDesignPanel.cxx b/sd/source/ui/toolpanel/controls/TableDesignPanel.cxx
index f199429c2..61b35ae9b 100755..100644
--- a/sd/source/ui/toolpanel/controls/TableDesignPanel.cxx
+++ b/sd/source/ui/toolpanel/controls/TableDesignPanel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,3 +109,5 @@ bool TableDesignPanel::IsExpandable() const
}
} } } // end of namespace ::sd::toolpanel::controls
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/TableDesignPanel.hxx b/sd/source/ui/toolpanel/controls/TableDesignPanel.hxx
index eef21450d..6ed358bd4 100755..100644
--- a/sd/source/ui/toolpanel/controls/TableDesignPanel.hxx
+++ b/sd/source/ui/toolpanel/controls/TableDesignPanel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79,3 +80,5 @@ private:
} } } // end of namespace ::sd::toolpanel::controls
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/toolpanel/controls/makefile.mk b/sd/source/ui/toolpanel/controls/makefile.mk
deleted file mode 100755
index b2218e550..000000000
--- a/sd/source/ui/toolpanel/controls/makefile.mk
+++ /dev/null
@@ -1,67 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=tpcontrols
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/..$/ ..$/..$/slidesorter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/AllMasterPagesSelector.obj \
- $(SLO)$/CurrentMasterPagesSelector.obj \
- $(SLO)$/DocumentHelper.obj \
- $(SLO)$/MasterPageObserver.obj \
- $(SLO)$/MasterPagesPanel.obj \
- $(SLO)$/MasterPagesSelector.obj \
- $(SLO)$/MasterPageContainer.obj \
- $(SLO)$/MasterPageContainerFiller.obj \
- $(SLO)$/MasterPageContainerProviders.obj\
- $(SLO)$/MasterPageContainerQueue.obj \
- $(SLO)$/MasterPageDescriptor.obj \
- $(SLO)$/PreviewValueSet.obj \
- $(SLO)$/RecentlyUsedMasterPages.obj \
- $(SLO)$/RecentMasterPagesSelector.obj \
- $(SLO)$/CustomAnimationPanel.obj \
- $(SLO)$/SlideTransitionPanel.obj \
- $(SLO)$/TableDesignPanel.obj
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/toolpanel/makefile.mk b/sd/source/ui/toolpanel/makefile.mk
deleted file mode 100755
index 262b32535..000000000
--- a/sd/source/ui/toolpanel/makefile.mk
+++ /dev/null
@@ -1,70 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=toolpanel
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-PRJINC=..$/slidesorter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/ControlContainer.obj \
- $(SLO)$/ScrollPanel.obj \
- $(SLO)$/SubToolPanel.obj \
- $(SLO)$/TitleBar.obj \
- $(SLO)$/TitledControl.obj \
- $(SLO)$/TaskPaneControlFactory.obj \
- $(SLO)$/TaskPaneFocusManager.obj \
- $(SLO)$/TaskPaneShellManager.obj \
- $(SLO)$/TaskPaneTreeNode.obj \
- $(SLO)$/ToolPanel.obj \
- $(SLO)$/ToolPanelViewShell.obj \
- $(SLO)$/ToolPanelFactory.obj \
- $(SLO)$/ToolPanelUIElement.obj \
- \
- $(SLO)$/LayoutMenu.obj \
- $(SLO)$/TestMenu.obj \
- $(SLO)$/TestPanel.obj \
- $(SLO)$/SlideSorterCacheDisplay.obj
-
-EXCEPTIONSFILES=
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/tools/AsynchronousCall.cxx b/sd/source/ui/tools/AsynchronousCall.cxx
index 8cb9f0aad..d8de5e866 100644
--- a/sd/source/ui/tools/AsynchronousCall.cxx
+++ b/sd/source/ui/tools/AsynchronousCall.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,5 @@ IMPL_LINK(AsynchronousCall,TimerCallback,Timer*,pTimer)
} } // end of namespace ::sd::tools
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/ConfigurationAccess.cxx b/sd/source/ui/tools/ConfigurationAccess.cxx
index ce245066b..615fd544a 100755..100644
--- a/sd/source/ui/tools/ConfigurationAccess.cxx
+++ b/sd/source/ui/tools/ConfigurationAccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,7 +53,7 @@ ConfigurationAccess::ConfigurationAccess (
{
Reference<lang::XMultiServiceFactory> xProvider (
xFactory->createInstanceWithContext(
- OUString::createFromAscii("com.sun.star.configuration.ConfigurationProvider"),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationProvider")),
rxContext),
UNO_QUERY);
if (xProvider.is())
@@ -70,7 +71,7 @@ ConfigurationAccess::ConfigurationAccess (
{
Reference<lang::XMultiServiceFactory> xProvider (
::comphelper::getProcessServiceFactory()->createInstance(
- OUString::createFromAscii("com.sun.star.configuration.ConfigurationProvider")),
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.configuration.ConfigurationProvider"))),
UNO_QUERY);
if (xProvider.is())
Initialize(xProvider, rsRootName, eMode);
@@ -228,3 +229,4 @@ void ConfigurationAccess::FillList(
} } // end of namespace sd::tools
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/EventMultiplexer.cxx b/sd/source/ui/tools/EventMultiplexer.cxx
index 989587d40..fa7436164 100644
--- a/sd/source/ui/tools/EventMultiplexer.cxx
+++ b/sd/source/ui/tools/EventMultiplexer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -821,3 +822,5 @@ EventMultiplexerEvent::EventMultiplexerEvent (
}
} } // end of namespace ::sd::tools
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/IconCache.cxx b/sd/source/ui/tools/IconCache.cxx
index 61a2d5654..550fd9cb5 100755..100644
--- a/sd/source/ui/tools/IconCache.cxx
+++ b/sd/source/ui/tools/IconCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,7 +32,7 @@
#include "tools/IconCache.hxx"
#include "sdresid.hxx"
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <osl/doublecheckedlocking.h>
#include <osl/getglobalmutex.hxx>
@@ -50,7 +51,7 @@ private:
*/
static IconCache* mpInstance;
- typedef ::std::hash_map<sal_uInt16,Image> ImageContainer;
+ typedef ::boost::unordered_map<sal_uInt16,Image> ImageContainer;
ImageContainer maContainer;
Image GetIcon (sal_uInt16 nResourceId);
@@ -131,3 +132,5 @@ IconCache::~IconCache (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/IdleDetection.cxx b/sd/source/ui/tools/IdleDetection.cxx
index 9690627d6..f9cee99f9 100644
--- a/sd/source/ui/tools/IdleDetection.cxx
+++ b/sd/source/ui/tools/IdleDetection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,3 +126,5 @@ sal_Int32 IdleDetection::CheckWindowPainting (const ::Window& rWindow)
}
} } // end of namespace ::sd::tools
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/PreviewRenderer.cxx b/sd/source/ui/tools/PreviewRenderer.cxx
index e4077d639..2e057469d 100644
--- a/sd/source/ui/tools/PreviewRenderer.cxx
+++ b/sd/source/ui/tools/PreviewRenderer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -605,3 +606,5 @@ drawinglayer::primitive2d::Primitive2DSequence ViewRedirector::createRedirectedP
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/PropertySet.cxx b/sd/source/ui/tools/PropertySet.cxx
index 45a838202..36f66fc47 100755..100644
--- a/sd/source/ui/tools/PropertySet.cxx
+++ b/sd/source/ui/tools/PropertySet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,7 @@
#include "tools/PropertySet.hxx"
#include <boost/bind.hpp>
#include <algorithm>
-#include <functional>
+#include <o3tl/compat_functional.hxx>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -149,10 +150,10 @@ void SAL_CALL PropertySet::removePropertyChangeListener (
::std::find_if(
aRange.first,
aRange.second,
- std::compose1(
+ o3tl::compose1(
std::bind1st(std::equal_to<Reference<beans::XPropertyChangeListener> >(),
rxListener),
- std::select2nd<ChangeListenerContainer::value_type>())));
+ o3tl::select2nd<ChangeListenerContainer::value_type>())));
if (iListener != mpChangeListeners->end())
{
mpChangeListeners->erase(iListener);
@@ -230,3 +231,5 @@ void PropertySet::ThrowIfDisposed (void)
}
} } // end of namespace ::sd::tools
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/SdGlobalResourceContainer.cxx b/sd/source/ui/tools/SdGlobalResourceContainer.cxx
index cb5121ab8..b74b2f019 100755..100644
--- a/sd/source/ui/tools/SdGlobalResourceContainer.cxx
+++ b/sd/source/ui/tools/SdGlobalResourceContainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -213,3 +214,5 @@ SdGlobalResourceContainer::~SdGlobalResourceContainer (void)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/SlotStateListener.cxx b/sd/source/ui/tools/SlotStateListener.cxx
index 82564efdc..8d803e3ec 100755..100644
--- a/sd/source/ui/tools/SlotStateListener.cxx
+++ b/sd/source/ui/tools/SlotStateListener.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "tools/SlotStateListener.hxx"
#include <com/sun/star/frame/XStatusListener.hpp>
#include <com/sun/star/frame/XDispatchProvider.hpp>
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCHP_HPP_
#include <com/sun/star/frame/XDispatch.hpp>
-#endif
#include <com/sun/star/util/XURLTransformer.hpp>
#include <com/sun/star/beans/PropertyChangeEvent.hpp>
@@ -223,3 +222,5 @@ void SlotStateListener::ThrowIfDisposed (void)
} } // end of namespace ::sd::tools
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/TimerBasedTaskExecution.cxx b/sd/source/ui/tools/TimerBasedTaskExecution.cxx
index 074ed2664..a2ad2e696 100644
--- a/sd/source/ui/tools/TimerBasedTaskExecution.cxx
+++ b/sd/source/ui/tools/TimerBasedTaskExecution.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -178,3 +179,4 @@ IMPL_LINK(TimerBasedTaskExecution,TimerCallback, Timer*,EMPTYARG)
} } // end of namespace ::sd::tools
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/tools/makefile.mk b/sd/source/ui/tools/makefile.mk
deleted file mode 100644
index 67ea9e718..000000000
--- a/sd/source/ui/tools/makefile.mk
+++ /dev/null
@@ -1,61 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=uitools
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/AsynchronousCall.obj \
- $(SLO)$/ConfigurationAccess.obj \
- $(SLO)$/IconCache.obj \
- $(SLO)$/IdleDetection.obj \
- $(SLO)$/EventMultiplexer.obj \
- $(SLO)$/PreviewRenderer.obj \
- $(SLO)$/PropertySet.obj \
- $(SLO)$/SdGlobalResourceContainer.obj \
- $(SLO)$/SlotStateListener.obj \
- $(SLO)$/TimerBasedTaskExecution.obj
-
-EXCEPTIONSFILES=
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/unoidl/DrawController.cxx b/sd/source/ui/unoidl/DrawController.cxx
index 9dfc5744e..43beb5377 100755..100644
--- a/sd/source/ui/unoidl/DrawController.cxx
+++ b/sd/source/ui/unoidl/DrawController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,6 +43,7 @@
#include <comphelper/processfactory.hxx>
#include <comphelper/sequence.hxx>
#include <comphelper/stl_types.hxx>
+#include <comphelper/servicehelper.hxx>
#include <cppuhelper/exc_hlp.hxx>
#include <cppuhelper/bootstrap.hxx>
@@ -53,26 +55,17 @@
#include "slideshow.hxx"
#include <svx/fmshell.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <boost/shared_ptr.hpp>
using namespace ::std;
using ::rtl::OUString;
using namespace ::cppu;
-using namespace ::vos;
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::drawing::framework;
-namespace {
-static const ::com::sun::star::uno::Type saComponentTypeIdentifier (
- ::getCppuType( (Reference<lang::XEventListener > *)0 ));
-static const ::com::sun::star::uno::Type saSelectionTypeIdentifier (
- ::getCppuType( (Reference<view::XSelectionChangeListener > *)0 ));
-
-} // end of anonymous namespace
-
namespace sd {
DrawController::DrawController (ViewShellBase& rBase) throw()
@@ -82,6 +75,8 @@ DrawController::DrawController (ViewShellBase& rBase) throw()
OMultiTypeInterfaceContainerHelper,
OMultiTypeInterfaceContainerHelper::keyType>& >(
BroadcastHelperOwner::maBroadcastHelper)),
+ m_aSelectionTypeIdentifier(
+ ::getCppuType( (Reference<view::XSelectionChangeListener > *)0 )),
mpBase(&rBase),
maLastVisArea(),
mpCurrentPage(NULL),
@@ -160,13 +155,15 @@ void SAL_CALL DrawController::dispose (void)
{
if( !mbDisposing )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( !mbDisposing )
{
mbDisposing = true;
- boost::shared_ptr<ViewShell> pViewShell = mpBase->GetMainViewShell();
+ boost::shared_ptr<ViewShell> pViewShell;
+ if (mpBase)
+ pViewShell = mpBase->GetMainViewShell();
if ( pViewShell )
{
pViewShell->DeactivateCurrentFunction();
@@ -247,7 +244,7 @@ OUString SAL_CALL DrawController::getImplementationName( ) throw(RuntimeExcepti
-static OUString ssServiceName (OUString::createFromAscii(
+static OUString ssServiceName (RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.DrawingDocumentDrawView"));
sal_Bool SAL_CALL DrawController::supportsService (
@@ -282,7 +279,7 @@ sal_Bool SAL_CALL DrawController::select (const Any& aSelection)
throw(lang::IllegalArgumentException, RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if (mxSubController.is())
return mxSubController->select(aSelection);
@@ -297,7 +294,7 @@ Any SAL_CALL DrawController::getSelection()
throw(RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if (mxSubController.is())
return mxSubController->getSelection();
@@ -315,7 +312,7 @@ void SAL_CALL DrawController::addSelectionChangeListener(
if( mbDisposing )
throw lang::DisposedException();
- BroadcastHelperOwner::maBroadcastHelper.addListener (saSelectionTypeIdentifier, xListener);
+ BroadcastHelperOwner::maBroadcastHelper.addListener (m_aSelectionTypeIdentifier, xListener);
}
@@ -328,7 +325,7 @@ void SAL_CALL DrawController::removeSelectionChangeListener(
if (rBHelper.bDisposed)
throw lang::DisposedException();
- BroadcastHelperOwner::maBroadcastHelper.removeListener (saSelectionTypeIdentifier, xListener);
+ BroadcastHelperOwner::maBroadcastHelper.removeListener (m_aSelectionTypeIdentifier, xListener);
}
@@ -386,7 +383,7 @@ void SAL_CALL DrawController::setCurrentPage( const Reference< drawing::XDrawPag
throw(RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if (mxSubController.is())
mxSubController->setCurrentPage(xPage);
@@ -399,7 +396,7 @@ Reference< drawing::XDrawPage > SAL_CALL DrawController::getCurrentPage (void)
throw(RuntimeException)
{
ThrowIfDisposed();
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
Reference<drawing::XDrawPage> xPage;
// Get current page from sub controller.
@@ -447,7 +444,7 @@ void DrawController::FireVisAreaChanged (const Rectangle& rVisArea) throw()
void DrawController::FireSelectionChangeListener() throw()
{
OInterfaceContainerHelper * pLC = BroadcastHelperOwner::maBroadcastHelper.getContainer(
- saSelectionTypeIdentifier);
+ m_aSelectionTypeIdentifier);
if( pLC )
{
Reference< XInterface > xSource( (XWeak*)this );
@@ -530,7 +527,7 @@ void DrawController::FireSwitchCurrentPage (SdPage* pNewCurrentPage) throw()
catch( uno::Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(::rtl::OString("sd::SdUnoDrawView::FireSwitchCurrentPage(), "
"exception caught: ") +
::rtl::OUStringToOString(
@@ -610,20 +607,14 @@ Reference<XModuleController> SAL_CALL
//===== XUnoTunnel ============================================================
+namespace
+{
+ class theDrawControllerUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theDrawControllerUnoTunnelId> {};
+}
+
const Sequence<sal_Int8>& DrawController::getUnoTunnelId (void)
{
- static ::com::sun::star::uno::Sequence<sal_Int8>* pSequence = NULL;
- if (pSequence == NULL)
- {
- ::osl::Guard< ::osl::Mutex > aGuard (::osl::Mutex::getGlobalMutex());
- if (pSequence == NULL)
- {
- static ::com::sun::star::uno::Sequence<sal_Int8> aSequence (16);
- rtl_createUuid((sal_uInt8*)aSequence.getArray(), 0, sal_True);
- pSequence = &aSequence;
- }
- }
- return *pSequence;
+ return theDrawControllerUnoTunnelId::get().getSeq();
}
@@ -711,7 +702,7 @@ void DrawController::FillPropertyTable (
IPropertyArrayHelper & DrawController::getInfoHelper()
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if (mpPropertyArrayHelper.get() == NULL)
{
@@ -732,7 +723,7 @@ IPropertyArrayHelper & DrawController::getInfoHelper()
Reference < beans::XPropertySetInfo > DrawController::getPropertySetInfo()
throw ( ::com::sun::star::uno::RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
static Reference < beans::XPropertySetInfo > xInfo( createPropertySetInfo( getInfoHelper() ) );
return xInfo;
@@ -741,7 +732,7 @@ Reference < beans::XPropertySetInfo > DrawController::getPropertySetInfo()
uno::Reference< form::runtime::XFormController > SAL_CALL DrawController::getFormController( const uno::Reference< form::XForm >& Form ) throw (uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
FmFormShell* pFormShell = mpBase->GetFormShellManager()->GetFormShell();
SdrView* pSdrView = mpBase->GetDrawView();
@@ -756,7 +747,7 @@ uno::Reference< form::runtime::XFormController > SAL_CALL DrawController::getFor
::sal_Bool SAL_CALL DrawController::isFormDesignMode( ) throw (uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sal_Bool bIsDesignMode = sal_True;
@@ -769,7 +760,7 @@ uno::Reference< form::runtime::XFormController > SAL_CALL DrawController::getFor
void SAL_CALL DrawController::setFormDesignMode( ::sal_Bool _DesignMode ) throw (uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
FmFormShell* pFormShell = mpBase->GetFormShellManager()->GetFormShell();
if ( pFormShell )
@@ -778,7 +769,7 @@ void SAL_CALL DrawController::setFormDesignMode( ::sal_Bool _DesignMode ) throw
uno::Reference< awt::XControl > SAL_CALL DrawController::getControl( const uno::Reference< awt::XControlModel >& xModel ) throw (container::NoSuchElementException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
FmFormShell* pFormShell = mpBase->GetFormShellManager()->GetFormShell();
SdrView* pSdrView = mpBase->GetDrawView();
@@ -835,7 +826,7 @@ void DrawController::setFastPropertyValue_NoBroadcast (
const Any& rValue)
throw ( com::sun::star::uno::Exception)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if (nHandle == PROPERTY_SUB_CONTROLLER)
SetSubController(Reference<drawing::XDrawSubController>(rValue, UNO_QUERY));
else if (mxSubController.is())
@@ -849,7 +840,7 @@ void DrawController::getFastPropertyValue (
Any & rRet,
sal_Int32 nHandle ) const
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
switch( nHandle )
{
@@ -879,7 +870,7 @@ void DrawController::getFastPropertyValue (
void DrawController::ProvideFrameworkControllers (void)
{
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
try
{
Reference<XController> xController (this);
@@ -936,3 +927,4 @@ void DrawController::ThrowIfDisposed (void) const
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/SdUnoDrawView.cxx b/sd/source/ui/unoidl/SdUnoDrawView.cxx
index e75ef9d81..89e5ee7a4 100755..100644
--- a/sd/source/ui/unoidl/SdUnoDrawView.cxx
+++ b/sd/source/ui/unoidl/SdUnoDrawView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -164,25 +165,21 @@ Reference<drawing::XLayer> SdUnoDrawView::getActiveLayer (void) throw ()
void SdUnoDrawView::setActiveLayer (const Reference<drawing::XLayer>& rxLayer) throw ()
{
- do
- {
- // Get the SdrLayer object corresponding to the given reference.
- if ( ! rxLayer.is())
- break;
+ // Get the SdrLayer object corresponding to the given reference.
+ if ( ! rxLayer.is())
+ return;
- SdLayer* pLayer = SdLayer::getImplementation (rxLayer);
- if (pLayer == NULL)
- break;
+ SdLayer* pLayer = SdLayer::getImplementation (rxLayer);
+ if (pLayer == NULL)
+ return;
- SdrLayer* pSdrLayer = pLayer->GetSdrLayer();
- if (pSdrLayer == NULL)
- break;
+ SdrLayer* pSdrLayer = pLayer->GetSdrLayer();
+ if (pSdrLayer == NULL)
+ return;
- // Set the new active layer and make the change visible.
- mrView.SetActiveLayer (pSdrLayer->GetName());
- mrDrawViewShell.ResetActualLayer ();
- }
- while (false);
+ // Set the new active layer and make the change visible.
+ mrView.SetActiveLayer (pSdrLayer->GetName());
+ mrDrawViewShell.ResetActualLayer ();
}
@@ -642,3 +639,4 @@ Sequence< OUString > SAL_CALL SdUnoDrawView::getSupportedServiceNames( ) throw
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/SdUnoOutlineView.cxx b/sd/source/ui/unoidl/SdUnoOutlineView.cxx
index 5432fa36c..ee1d4538c 100755..100644
--- a/sd/source/ui/unoidl/SdUnoOutlineView.cxx
+++ b/sd/source/ui/unoidl/SdUnoOutlineView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,11 +40,10 @@
#include <cppuhelper/proptypehlp.hxx>
#include <svx/unopage.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
using ::rtl::OUString;
-using namespace ::vos;
using namespace ::cppu;
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -149,44 +149,6 @@ Reference< drawing::XDrawPage > SAL_CALL SdUnoOutlineView::getCurrentPage (void)
return xPage;
}
-
-
-/*
-// Return sal_True, value change
-sal_Bool SdUnoOutlineView::convertFastPropertyValue (
- Any & rConvertedValue,
- Any & rOldValue,
- sal_Int32 nHandle,
- const Any& rValue)
- throw ( com::sun::star::lang::IllegalArgumentException)
-{
- sal_Bool bResult = sal_False;
-
- switch( nHandle )
- {
- case DrawController::PROPERTY_CURRENTPAGE:
- {
- Reference< drawing::XDrawPage > xOldPage( getCurrentPage() );
- Reference< drawing::XDrawPage > xNewPage;
- ::cppu::convertPropertyValue( xNewPage, rValue );
- if( xOldPage != xNewPage )
- {
- rConvertedValue <<= xNewPage;
- rOldValue <<= xOldPage;
- bResult = sal_True;
- }
- }
- break;
-
- default:
- break;
- }
-
- return bResult;
-}
-*/
-
-
void SdUnoOutlineView::setFastPropertyValue (
sal_Int32 nHandle,
const Any& rValue)
@@ -269,3 +231,5 @@ Sequence< OUString > SAL_CALL SdUnoOutlineView::getSupportedServiceNames( ) thr
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/SdUnoSlideView.cxx b/sd/source/ui/unoidl/SdUnoSlideView.cxx
index a5ddb61c4..3541c82d6 100755..100644
--- a/sd/source/ui/unoidl/SdUnoSlideView.cxx
+++ b/sd/source/ui/unoidl/SdUnoSlideView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -167,7 +168,7 @@ void SAL_CALL SdUnoSlideView::setCurrentPage (
if (xProperties.is())
{
sal_uInt16 nPageNumber(0);
- if (xProperties->getPropertyValue(::rtl::OUString::createFromAscii("Number")) >>= nPageNumber)
+ if (xProperties->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Number"))) >>= nPageNumber)
{
mrSlideSorter.GetController().GetCurrentSlideManager()->SwitchCurrentSlide(
nPageNumber-1,
@@ -282,3 +283,5 @@ void SAL_CALL SdUnoSlideView::getFastPropertyValue( ::com::sun::star::uno::Any&,
*/
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/UnoDocumentSettings.cxx b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
index 95efabe48..c91577306 100755..100644
--- a/sd/source/ui/unoidl/UnoDocumentSettings.cxx
+++ b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,33 +41,19 @@
#include <svx/xtable.hxx>
#include <osl/diagnose.h>
#include <osl/mutex.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include "drawdoc.hxx"
-#ifndef SVX_LIGHT
-#ifndef SD_DRAW_DOC_SHELL_HXX
#include "DrawDocShell.hxx"
-#endif
-#endif
#include "unomodel.hxx"
-#ifndef SVX_LIGHT
-#ifndef _SD_OPTSITEM_HXX
#include "optsitem.hxx"
-#endif
#include <sfx2/printer.hxx>
#include "sdattr.hxx"
-#endif
#include "../inc/ViewShell.hxx"
#include "../inc/FrameView.hxx"
-#ifndef SVX_LIGHT
-#ifndef SD_OUTLINER_HXX
#include "Outliner.hxx"
-#endif
-#else
-#include <svx/svdoutl.hxx>
-#endif
#include <editeng/editstat.hxx>
#include <svx/unoapi.hxx>
@@ -76,7 +63,6 @@ using namespace ::comphelper;
using namespace ::osl;
using ::rtl::OUString;
using namespace ::cppu;
-using namespace ::vos;
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::util;
@@ -149,9 +135,8 @@ enum SdDocumentSettingsPropertyHandles
HANDLE_GRADIENTTABLEURL, HANDLE_BITMAPTABLEURL, HANDLE_FORBIDDENCHARS, HANDLE_APPLYUSERDATA, HANDLE_PAGENUMFMT,
HANDLE_PRINTERNAME, HANDLE_PRINTERJOB, HANDLE_PARAGRAPHSUMMATION, HANDLE_CHARCOMPRESS, HANDLE_ASIANPUNCT, HANDLE_UPDATEFROMTEMPLATE,
HANDLE_PRINTER_INDEPENDENT_LAYOUT
- // --> PB 2004-08-23 #i33095#
+ // #i33095#
,HANDLE_LOAD_READONLY, HANDLE_SAVE_VERSION
- // <--
,HANDLE_SLIDESPERHANDOUT, HANDLE_HANDOUTHORIZONTAL
};
@@ -183,7 +168,6 @@ enum SdDocumentSettingsPropertyHandles
{ MAP_LEN("DefaultTabStop"), HANDLE_TABSTOP, &::getCppuType((const sal_Int32*)0), 0, 0 },
{ MAP_LEN("PrinterName"), HANDLE_PRINTERNAME, &::getCppuType((const OUString*)0), 0, 0 },
{ MAP_LEN("PrinterSetup"), HANDLE_PRINTERJOB, &::getCppuType((const uno::Sequence < sal_Int8 > *)0), 0, MID_PRINTER },
-#ifndef SVX_LIGHT
{ MAP_LEN("IsPrintPageName"), HANDLE_PRINTPAGENAME, &::getBooleanCppuType(), 0, MID_PRINTER },
{ MAP_LEN("IsPrintDate"), HANDLE_PRINTDATE, &::getBooleanCppuType(), 0, MID_PRINTER },
@@ -195,7 +179,6 @@ enum SdDocumentSettingsPropertyHandles
{ MAP_LEN("IsPrintBookletFront"), HANDLE_PRINTBOOKLETFRONT, &::getBooleanCppuType(), 0, MID_PRINTER },
{ MAP_LEN("IsPrintBookletBack"), HANDLE_PRINTBOOKLETBACK, &::getBooleanCppuType(), 0, MID_PRINTER },
{ MAP_LEN("PrintQuality"), HANDLE_PRINTQUALITY, &::getCppuType((const sal_Int32*)0), 0, MID_PRINTER },
-#endif
{ MAP_LEN("ColorTableURL"), HANDLE_COLORTABLEURL, &::getCppuType((const OUString*)0), 0, 0 },
{ MAP_LEN("DashTableURL"), HANDLE_DASHTABLEURL, &::getCppuType((const OUString*)0), 0, 0 },
{ MAP_LEN("LineEndTableURL"), HANDLE_LINEENDTABLEURL, &::getCppuType((const OUString*)0), 0, 0 },
@@ -212,10 +195,9 @@ enum SdDocumentSettingsPropertyHandles
{ MAP_LEN("IsKernAsianPunctuation"),HANDLE_ASIANPUNCT, &::getBooleanCppuType(), 0, 0 },
{ MAP_LEN("UpdateFromTemplate"), HANDLE_UPDATEFROMTEMPLATE, &::getBooleanCppuType(), 0, 0 },
{ MAP_LEN("PrinterIndependentLayout"),HANDLE_PRINTER_INDEPENDENT_LAYOUT,&::getCppuType((const sal_Int16*)0), 0, 0 },
- // --> PB 2004-08-23 #i33095#
+ // --> #i33095#
{ MAP_LEN("LoadReadonly"), HANDLE_LOAD_READONLY, &::getBooleanCppuType(), 0, 0 },
{ MAP_LEN("SaveVersionOnClose"), HANDLE_SAVE_VERSION, &::getBooleanCppuType(), 0, 0 },
- // <--
{ NULL, 0, 0, NULL, 0, 0 }
};
@@ -241,7 +223,7 @@ DocumentSettings::~DocumentSettings() throw()
void DocumentSettings::_setPropertyValues( const PropertyMapEntry** ppEntries, const Any* pValues ) throw(UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
SdDrawDocument* pDoc = mpModel->GetDoc();
::sd::DrawDocShell* pDocSh = mpModel->GetDocShell();
@@ -837,7 +819,7 @@ void DocumentSettings::_setPropertyValues( const PropertyMapEntry** ppEntries, c
}
break;
- // --> PB 2004-08-23 #i33095#
+ // --> #i33095#
case HANDLE_LOAD_READONLY:
{
sal_Bool bNewValue = sal_False;
@@ -849,7 +831,6 @@ void DocumentSettings::_setPropertyValues( const PropertyMapEntry** ppEntries, c
}
}
break;
- // <--
case HANDLE_SAVE_VERSION:
{
@@ -886,7 +867,7 @@ void DocumentSettings::_setPropertyValues( const PropertyMapEntry** ppEntries, c
void DocumentSettings::_getPropertyValues( const PropertyMapEntry** ppEntries, Any* pValue ) throw(UnknownPropertyException, WrappedTargetException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
SdDrawDocument* pDoc = mpModel->GetDoc();
::sd::DrawDocShell* pDocSh = mpModel->GetDocShell();
@@ -1108,13 +1089,12 @@ void DocumentSettings::_getPropertyValues( const PropertyMapEntry** ppEntries, A
}
break;
- // --> PB 2004-08-23 #i33095#
+ // --> #i33095#
case HANDLE_LOAD_READONLY:
{
*pValue <<= pDocSh->IsLoadReadonly();
}
break;
- // <--
case HANDLE_SAVE_VERSION:
{
@@ -1246,3 +1226,4 @@ Sequence< OUString > SAL_CALL DocumentSettings::getSupportedServiceNames( )
return aSeq;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/UnoDocumentSettings.hxx b/sd/source/ui/unoidl/UnoDocumentSettings.hxx
index 6304d6fc9..3bdd24ee2 100644
--- a/sd/source/ui/unoidl/UnoDocumentSettings.hxx
+++ b/sd/source/ui/unoidl/UnoDocumentSettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,3 +39,5 @@ namespace sd
}
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/detreg.cxx b/sd/source/ui/unoidl/detreg.cxx
index efbf122b0..2d4beb853 100755..100644
--- a/sd/source/ui/unoidl/detreg.cxx
+++ b/sd/source/ui/unoidl/detreg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,4 @@ SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
} // extern "C"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/facreg.cxx b/sd/source/ui/unoidl/facreg.cxx
index a3f3deb7c..4359c1de5 100755..100644
--- a/sd/source/ui/unoidl/facreg.cxx
+++ b/sd/source/ui/unoidl/facreg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,12 +43,12 @@
#define INCLUDED_STRING_H
#endif
#include <comphelper/stl_types.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <boost/shared_ptr.hpp>
-using namespace rtl;
using namespace com::sun::star;
+using ::rtl::OUString;
// Forward declarations of the factories.
@@ -254,7 +255,7 @@ enum FactoryId
SlideLayoutControllerFactoryId,
InsertSlideControllerFactoryId,
};
-typedef ::std::hash_map<OUString, FactoryId, comphelper::UStringHash, comphelper::UStringEqual> FactoryMap;
+typedef ::boost::unordered_map<OUString, FactoryId, comphelper::UStringHash, comphelper::UStringEqual> FactoryMap;
namespace {
@@ -512,3 +513,5 @@ SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory(
}
} // end of extern "C"
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/makefile.mk b/sd/source/ui/unoidl/makefile.mk
deleted file mode 100755
index cf4910b29..000000000
--- a/sd/source/ui/unoidl/makefile.mk
+++ /dev/null
@@ -1,90 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=unoidl
-ENABLE_EXCEPTIONS=TRUE
-AUTOSEG=true
-LIBTARGET = NO
-PRJINC=..$/slidesorter
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-.IF "$(COM)"=="GCC"
-NOOPTFILES= $(SLO)$/unowcntr.obj
-.ENDIF
-
-SLO1FILES = \
- $(SLO)$/DrawController.obj \
- $(SLO)$/SdUnoSlideView.obj\
- $(SLO)$/SdUnoOutlineView.obj\
- $(SLO)$/SdUnoDrawView.obj \
- $(SLO)$/unopool.obj \
- $(SLO)$/UnoDocumentSettings.obj \
- $(SLO)$/facreg.obj \
- $(SLO)$/unomodel.obj \
- $(SLO)$/unopage.obj \
- $(SLO)$/unolayer.obj \
- $(SLO)$/unocpres.obj \
- $(SLO)$/unoobj.obj \
- $(SLO)$/unosrch.obj \
- $(SLO)$/unowcntr.obj \
- $(SLO)$/unokywds.obj \
- $(SLO)$/unopback.obj \
- $(SLO)$/unodoc.obj \
- $(SLO)$/unomodule.obj \
- $(SLO)$/randomnode.obj
-
-SLO2FILES = \
- $(SLO)$/sddetect.obj \
- $(SLO)$/detreg.obj
-
-SLOFILES = \
- $(SLO1FILES) \
- $(SLO2FILES)
-
-LIB1TARGET = \
- $(SLB)$/$(TARGET).lib
-
-LIB1OBJFILES = \
- $(SLO1FILES)
-
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/unoidl/randomnode.cxx b/sd/source/ui/unoidl/randomnode.cxx
index 38ac609cb..0183fba4b 100644
--- a/sd/source/ui/unoidl/randomnode.cxx
+++ b/sd/source/ui/unoidl/randomnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -193,11 +194,8 @@ OUString RandomNode__getImplementationName() throw( RuntimeException )
Sequence< OUString > SAL_CALL RandomNode_getSupportedServiceNames() throw( RuntimeException )
{
-// static const OUString aSN1( OUString::createFromAscii( pSN1 ) );
static const OUString aSN2( OUString::createFromAscii( pSN2 ) );
Sequence< OUString > aSeq( &aSN2, 1 );
-// aSeq[0] = aSN1;
-/// aSeq[1] = aSN2;
return aSeq;
}
@@ -701,3 +699,4 @@ Sequence< OUString > RandomAnimationNode::getSupportedServiceNames(void) throw()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/sddetect.cxx b/sd/source/ui/unoidl/sddetect.cxx
index 5fa628bc6..b40705284 100755..100644
--- a/sd/source/ui/unoidl/sddetect.cxx
+++ b/sd/source/ui/unoidl/sddetect.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,7 +59,7 @@
#include <svl/eitem.hxx>
#include <svl/stritem.hxx>
#include <tools/urlobj.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <svtools/sfxecode.hxx>
#include <svtools/ehdl.hxx>
#include <sot/storinfo.hxx>
@@ -120,7 +121,6 @@ SdFilterDetect::~SdFilterDetect()
// now some parameters that can already be in the array, but may be overwritten or new inserted here
// remember their indices in the case new values must be added to the array
sal_Int32 nPropertyCount = lDescriptor.getLength();
- sal_Int32 nIndexOfFilterName = -1;
sal_Int32 nIndexOfInputStream = -1;
sal_Int32 nIndexOfContent = -1;
sal_Int32 nIndexOfReadOnlyFlag = -1;
@@ -149,10 +149,6 @@ SdFilterDetect::~SdFilterDetect()
{
lDescriptor[nProperty].Value >>= sTemp;
aPreselectedFilterName = sTemp;
-
- // if the preselected filter name is not correct, it must be erased after detection
- // remember index of property to get access to it later
- nIndexOfFilterName = nProperty;
}
else if( lDescriptor[nProperty].Name == OUString(RTL_CONSTASCII_USTRINGPARAM("InputStream")) )
nIndexOfInputStream = nProperty;
@@ -174,7 +170,7 @@ SdFilterDetect::~SdFilterDetect()
}
// can't check the type for external filters, so set the "dont" flag accordingly
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
//SfxFilterFlags nMust = SFX_FILTER_IMPORT, nDont = SFX_FILTER_NOTINSTALLED;
SfxApplication* pApp = SFX_APP();
@@ -350,10 +346,12 @@ SdFilterDetect::~SdFilterDetect()
String aFileName(aMedium.GetName());
aFileName.ToUpperAscii();
- if( aFileName.SearchAscii( ".POT" ) == STRING_NOTFOUND )
- pFilter = SfxFilter::GetFilterByName( pFilterPowerPoint97);
- else
+ if( aFileName.SearchAscii( ".POT" ) != STRING_NOTFOUND )
pFilter = SfxFilter::GetFilterByName( pFilterPowerPoint97Template );
+ else if( aFileName.SearchAscii( ".PPS" ) != STRING_NOTFOUND )
+ pFilter = SfxFilter::GetFilterByName( pFilterPowerPoint97AutoPlay );
+ else
+ pFilter = SfxFilter::GetFilterByName( pFilterPowerPoint97);
}
}
else
@@ -363,7 +361,6 @@ SdFilterDetect::~SdFilterDetect()
const String aFileName( aMedium.GetURLObject().GetMainURL( INetURLObject::NO_DECODE ) );
GraphicDescriptor aDesc( *pStm, &aFileName );
- GraphicFilter* pGrfFilter = GraphicFilter::GetGraphicFilter();
if( !aDesc.Detect( sal_False ) )
{
pFilter = 0;
@@ -387,7 +384,8 @@ SdFilterDetect::~SdFilterDetect()
else
{
String aShortName( aDesc.GetImportFormatShortName( aDesc.GetFileFormat() ) );
- const String aName( pGrfFilter->GetImportFormatTypeName( pGrfFilter->GetImportFormatNumberForShortName( aShortName ) ) );
+ GraphicFilter &rGrfFilter = GraphicFilter::GetGraphicFilter();
+ const String aName( rGrfFilter.GetImportFormatTypeName( rGrfFilter.GetImportFormatNumberForShortName( aShortName ) ) );
if ( pFilter && aShortName.EqualsIgnoreCaseAscii( "PCD" ) ) // there is a multiple pcd selection possible
{
@@ -416,7 +414,7 @@ SdFilterDetect::~SdFilterDetect()
{
// if input stream wasn't part of the descriptor, now it should be, otherwise the content would be opend twice
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("InputStream");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InputStream"));
lDescriptor[nPropertyCount].Value <<= xStream;
nPropertyCount++;
}
@@ -425,7 +423,7 @@ SdFilterDetect::~SdFilterDetect()
{
// if input stream wasn't part of the descriptor, now it should be, otherwise the content would be opend twice
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("UCBContent");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UCBContent"));
lDescriptor[nPropertyCount].Value <<= xContent;
nPropertyCount++;
}
@@ -435,7 +433,7 @@ SdFilterDetect::~SdFilterDetect()
if ( nIndexOfReadOnlyFlag == -1 )
{
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("ReadOnly");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ReadOnly"));
lDescriptor[nPropertyCount].Value <<= bReadOnly;
nPropertyCount++;
}
@@ -446,7 +444,7 @@ SdFilterDetect::~SdFilterDetect()
if ( !bRepairPackage && bRepairAllowed )
{
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("RepairPackage");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("RepairPackage"));
lDescriptor[nPropertyCount].Value <<= bRepairAllowed;
nPropertyCount++;
@@ -460,7 +458,7 @@ SdFilterDetect::~SdFilterDetect()
if ( nIndexOfTemplateFlag == -1 )
{
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("AsTemplate");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AsTemplate"));
lDescriptor[nPropertyCount].Value <<= bOpenAsTemplate;
nPropertyCount++;
}
@@ -474,7 +472,7 @@ SdFilterDetect::~SdFilterDetect()
if ( nIndexOfDocumentTitle == -1 )
{
lDescriptor.realloc( nPropertyCount + 1 );
- lDescriptor[nPropertyCount].Name = ::rtl::OUString::createFromAscii("DocumentTitle");
+ lDescriptor[nPropertyCount].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DocumentTitle"));
lDescriptor[nPropertyCount].Value <<= aDocumentTitle;
nPropertyCount++;
}
@@ -522,16 +520,15 @@ UNOSEQUENCE< UNOOUSTRING > SAL_CALL SdFilterDetect::getSupportedServiceNames() t
/* Helper for XServiceInfo */
UNOSEQUENCE< UNOOUSTRING > SdFilterDetect::impl_getStaticSupportedServiceNames()
{
- UNOMUTEXGUARD aGuard( UNOMUTEX::getGlobalMutex() );
UNOSEQUENCE< UNOOUSTRING > seqServiceNames( 1 );
- seqServiceNames.getArray() [0] = UNOOUSTRING::createFromAscii( "com.sun.star.frame.ExtendedTypeDetection" );
+ seqServiceNames.getArray() [0] = UNOOUSTRING(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.ExtendedTypeDetection" ));
return seqServiceNames ;
}
/* Helper for XServiceInfo */
UNOOUSTRING SdFilterDetect::impl_getStaticImplementationName()
{
- return UNOOUSTRING::createFromAscii( "com.sun.star.comp.draw.FormatDetector" );
+ return UNOOUSTRING(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.draw.FormatDetector" ));
}
/* Helper for registry */
@@ -540,3 +537,4 @@ UNOREFERENCE< UNOXINTERFACE > SAL_CALL SdFilterDetect::impl_createInstance( cons
return UNOREFERENCE< UNOXINTERFACE >( *new SdFilterDetect( xServiceManager ) );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/sddetect.hxx b/sd/source/ui/unoidl/sddetect.hxx
index f1046f309..a3d94a39a 100644
--- a/sd/source/ui/unoidl/sddetect.hxx
+++ b/sd/source/ui/unoidl/sddetect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unocpres.cxx b/sd/source/ui/unoidl/unocpres.cxx
index 2fbae2bc5..4c18277f3 100755..100644
--- a/sd/source/ui/unoidl/unocpres.cxx
+++ b/sd/source/ui/unoidl/unocpres.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,7 +30,7 @@
#include "precompiled_sd.hxx"
#include <com/sun/star/lang/DisposedException.hpp>
#include <osl/mutex.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <svx/svdpage.hxx>
#include <comphelper/extract.hxx>
@@ -43,7 +44,6 @@
#include "unopage.hxx"
using namespace ::rtl;
-using namespace ::vos;
using namespace ::com::sun::star;
@@ -97,7 +97,7 @@ uno::Sequence< OUString > SAL_CALL SdXCustomPresentation::getSupportedServiceNam
void SAL_CALL SdXCustomPresentation::insertByIndex( sal_Int32 Index, const uno::Any& Element )
throw(lang::IllegalArgumentException, lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -131,7 +131,7 @@ void SAL_CALL SdXCustomPresentation::insertByIndex( sal_Int32 Index, const uno::
void SAL_CALL SdXCustomPresentation::removeByIndex( sal_Int32 Index )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -171,7 +171,7 @@ uno::Type SAL_CALL SdXCustomPresentation::getElementType()
sal_Bool SAL_CALL SdXCustomPresentation::hasElements()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -183,7 +183,7 @@ sal_Bool SAL_CALL SdXCustomPresentation::hasElements()
sal_Int32 SAL_CALL SdXCustomPresentation::getCount()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -193,7 +193,7 @@ sal_Int32 SAL_CALL SdXCustomPresentation::getCount()
uno::Any SAL_CALL SdXCustomPresentation::getByIndex( sal_Int32 Index )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -220,7 +220,7 @@ uno::Any SAL_CALL SdXCustomPresentation::getByIndex( sal_Int32 Index )
OUString SAL_CALL SdXCustomPresentation::getName()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -234,7 +234,7 @@ OUString SAL_CALL SdXCustomPresentation::getName()
void SAL_CALL SdXCustomPresentation::setName( const OUString& aName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
throw lang::DisposedException();
@@ -246,7 +246,7 @@ void SAL_CALL SdXCustomPresentation::setName( const OUString& aName )
// XComponent
void SAL_CALL SdXCustomPresentation::dispose() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( bDisposing )
return; // catched a recursion
@@ -332,7 +332,7 @@ uno::Reference< uno::XInterface > SAL_CALL SdXCustomPresentationAccess::createIn
void SAL_CALL SdXCustomPresentationAccess::insertByName( const OUString& aName, const uno::Any& aElement )
throw(lang::IllegalArgumentException, container::ElementExistException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// get the documents custom show list
List* pList = 0;
@@ -386,7 +386,7 @@ void SAL_CALL SdXCustomPresentationAccess::insertByName( const OUString& aName,
void SAL_CALL SdXCustomPresentationAccess::removeByName( const OUString& Name )
throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
SdCustomShow* pShow = getSdCustomShow(Name);
@@ -411,7 +411,7 @@ void SAL_CALL SdXCustomPresentationAccess::replaceByName( const OUString& aName,
uno::Any SAL_CALL SdXCustomPresentationAccess::getByName( const OUString& aName )
throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
uno::Any aAny;
@@ -432,7 +432,7 @@ uno::Any SAL_CALL SdXCustomPresentationAccess::getByName( const OUString& aName
uno::Sequence< OUString > SAL_CALL SdXCustomPresentationAccess::getElementNames()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
List* pList = GetCustomShowList();
const sal_uInt32 nCount = pList?pList->Count():0;
@@ -455,7 +455,7 @@ uno::Sequence< OUString > SAL_CALL SdXCustomPresentationAccess::getElementNames(
sal_Bool SAL_CALL SdXCustomPresentationAccess::hasByName( const OUString& aName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return getSdCustomShow(aName) != NULL;
}
@@ -469,7 +469,7 @@ uno::Type SAL_CALL SdXCustomPresentationAccess::getElementType()
sal_Bool SAL_CALL SdXCustomPresentationAccess::hasElements()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
List* pList = GetCustomShowList();
return pList && pList->Count() > 0;
@@ -493,3 +493,5 @@ SdCustomShow * SdXCustomPresentationAccess::getSdCustomShow( const OUString& Nam
}
return NULL;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unocpres.hxx b/sd/source/ui/unoidl/unocpres.hxx
index dd36671f2..7ce4e3fe4 100755..100644
--- a/sd/source/ui/unoidl/unocpres.hxx
+++ b/sd/source/ui/unoidl/unocpres.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -167,3 +168,4 @@ inline List * SdXCustomPresentationAccess::GetCustomShowList() const throw()
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unodoc.cxx b/sd/source/ui/unoidl/unodoc.cxx
index 15d92ab3b..2d3483e90 100755..100644
--- a/sd/source/ui/unoidl/unodoc.cxx
+++ b/sd/source/ui/unoidl/unodoc.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,7 +39,7 @@
#include "sdmod.hxx"
#include "DrawDocShell.hxx"
#include "GraphicDocShell.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
using namespace ::com::sun::star;
@@ -62,7 +63,7 @@ uno::Sequence< rtl::OUString > SAL_CALL SdDrawingDocument_getSupportedServiceNam
uno::Reference< uno::XInterface > SAL_CALL SdDrawingDocument_createInstance(
const uno::Reference< lang::XMultiServiceFactory > &, const sal_uInt64 _nCreationFlags )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
SdDLL::Init();
@@ -91,7 +92,7 @@ uno::Sequence< rtl::OUString > SAL_CALL SdPresentationDocument_getSupportedServi
uno::Reference< uno::XInterface > SAL_CALL SdPresentationDocument_createInstance(
const uno::Reference< lang::XMultiServiceFactory > &, const sal_uInt64 _nCreationFlags )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
SdDLL::Init();
@@ -102,3 +103,4 @@ uno::Reference< uno::XInterface > SAL_CALL SdPresentationDocument_createInstance
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unohelp.hxx b/sd/source/ui/unoidl/unohelp.hxx
index 8a9a1c4b2..7d5fd896f 100644
--- a/sd/source/ui/unoidl/unohelp.hxx
+++ b/sd/source/ui/unoidl/unohelp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ inline void bool2any( sal_Bool bBool, ::com::sun::star::uno::Any& rAny )
#define QUERYINT( xint ) \
if( rType == ::getCppuType((const uno::Reference< xint >*)0) ) \
aAny <<= uno::Reference< xint >(this)
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unokywds.cxx b/sd/source/ui/unoidl/unokywds.cxx
index 45fbd88b1..85ddeb032 100644
--- a/sd/source/ui/unoidl/unokywds.cxx
+++ b/sd/source/ui/unoidl/unokywds.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,3 +36,4 @@
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unolayer.cxx b/sd/source/ui/unoidl/unolayer.cxx
index 372c7dfa6..69a0b298a 100755..100644
--- a/sd/source/ui/unoidl/unolayer.cxx
+++ b/sd/source/ui/unoidl/unolayer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,7 +32,7 @@
#include "unolayer.hxx"
#include <osl/mutex.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <svx/svdpagv.hxx>
#include <svx/unoshape.hxx>
@@ -41,11 +42,7 @@
// folgende fuer InsertSdPage()
#include <svx/svdlayer.hxx>
-#ifndef SVX_LIGHT
-#ifndef SD_DRAW_DOC_SHELL_HXX
#include "DrawDocShell.hxx"
-#endif
-#endif
#include <drawdoc.hxx>
#include <unomodel.hxx>
#include "unoprnms.hxx"
@@ -66,7 +63,6 @@
#include <vcl/svapp.hxx>
using namespace ::rtl;
-using namespace ::vos;
using namespace ::com::sun::star;
//=============================================================================
@@ -195,14 +191,14 @@ uno::Sequence< OUString > SAL_CALL SdLayer::getSupportedServiceNames()
uno::Reference< beans::XPropertySetInfo > SAL_CALL SdLayer::getPropertySetInfo( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return pPropSet->getPropertySetInfo();
}
void SAL_CALL SdLayer::setPropertyValue( const OUString& aPropertyName, const uno::Any& aValue )
throw(beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if(pLayer == NULL || pLayerManager == NULL)
throw lang::DisposedException();
@@ -270,16 +266,14 @@ void SAL_CALL SdLayer::setPropertyValue( const OUString& aPropertyName, const un
throw beans::UnknownPropertyException();
}
-#ifndef SVX_LIGHT
if( pLayerManager->GetDocShell() )
pLayerManager->GetDocShell()->SetModified();
-#endif
}
uno::Any SAL_CALL SdLayer::getPropertyValue( const OUString& PropertyName )
throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if(pLayer == NULL || pLayerManager == NULL)
throw lang::DisposedException();
@@ -345,7 +339,6 @@ sal_Bool SdLayer::get( LayerAttribute what ) throw()
}
}
-#ifndef SVX_LIGHT
// Versuch 2. Info von der FrameView besorgen
if(pLayerManager->GetDocShell())
{
@@ -358,7 +351,6 @@ sal_Bool SdLayer::get( LayerAttribute what ) throw()
case LOCKED: return pFrameView->GetLockedLayers().IsSet(pLayer->GetID());
}
}
-#endif
}
return sal_False; //TODO: uno::Exception?
}
@@ -387,7 +379,6 @@ void SdLayer::set( LayerAttribute what, sal_Bool flag ) throw()
}
}
-#ifndef SVX_LIGHT
// Versuch 2. Info von der FrameView besorgen
if(pLayerManager->GetDocShell())
{
@@ -420,7 +411,6 @@ void SdLayer::set( LayerAttribute what, sal_Bool flag ) throw()
return;
}
}
-#endif
}
//TODO: uno::Exception?
}
@@ -433,7 +423,7 @@ void SdLayer::set( LayerAttribute what, sal_Bool flag ) throw()
uno::Reference<uno::XInterface> SAL_CALL SdLayer::getParent (void)
throw (::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( pLayerManager == NULL )
throw lang::DisposedException();
@@ -459,12 +449,12 @@ void SAL_CALL SdLayer::dispose( ) throw (uno::RuntimeException)
void SAL_CALL SdLayer::addEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR("not implemented!");
+ OSL_FAIL("not implemented!");
}
void SAL_CALL SdLayer::removeEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR("not implemented!");
+ OSL_FAIL("not implemented!");
}
@@ -503,12 +493,12 @@ void SAL_CALL SdLayerManager::dispose( ) throw (uno::RuntimeException)
void SAL_CALL SdLayerManager::addEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR("not implemented!");
+ OSL_FAIL("not implemented!");
}
void SAL_CALL SdLayerManager::removeEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR("not implemented!");
+ OSL_FAIL("not implemented!");
}
// XServiceInfo
@@ -536,7 +526,7 @@ uno::Sequence< OUString > SAL_CALL SdLayerManager::getSupportedServiceNames()
uno::Reference< drawing::XLayer > SAL_CALL SdLayerManager::insertNewByIndex( sal_Int32 nIndex )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -570,7 +560,7 @@ uno::Reference< drawing::XLayer > SAL_CALL SdLayerManager::insertNewByIndex( sal
void SAL_CALL SdLayerManager::remove( const uno::Reference< drawing::XLayer >& xLayer )
throw(container::NoSuchElementException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -591,7 +581,7 @@ void SAL_CALL SdLayerManager::remove( const uno::Reference< drawing::XLayer >& x
void SAL_CALL SdLayerManager::attachShapeToLayer( const uno::Reference< drawing::XShape >& xShape, const uno::Reference< drawing::XLayer >& xLayer )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -612,7 +602,7 @@ void SAL_CALL SdLayerManager::attachShapeToLayer( const uno::Reference< drawing:
uno::Reference< drawing::XLayer > SAL_CALL SdLayerManager::getLayerForShape( const uno::Reference< drawing::XShape >& xShape ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -637,7 +627,7 @@ uno::Reference< drawing::XLayer > SAL_CALL SdLayerManager::getLayerForShape( con
sal_Int32 SAL_CALL SdLayerManager::getCount()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -654,7 +644,7 @@ sal_Int32 SAL_CALL SdLayerManager::getCount()
uno::Any SAL_CALL SdLayerManager::getByIndex( sal_Int32 nLayer )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -678,7 +668,7 @@ uno::Any SAL_CALL SdLayerManager::getByIndex( sal_Int32 nLayer )
uno::Any SAL_CALL SdLayerManager::getByName( const OUString& aName )
throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( (mpModel == 0) || (mpModel->mpDoc == 0 ) )
throw lang::DisposedException();
@@ -694,7 +684,7 @@ uno::Any SAL_CALL SdLayerManager::getByName( const OUString& aName )
uno::Sequence< OUString > SAL_CALL SdLayerManager::getElementNames()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -719,7 +709,7 @@ uno::Sequence< OUString > SAL_CALL SdLayerManager::getElementNames()
sal_Bool SAL_CALL SdLayerManager::hasByName( const OUString& aName ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpModel == 0 )
throw lang::DisposedException();
@@ -830,3 +820,5 @@ uno::Reference<drawing::XLayer> SdLayerManager::GetLayer (SdrLayer* pLayer)
return xLayer;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unolayer.hxx b/sd/source/ui/unoidl/unolayer.hxx
index ba83422dd..d7f73d02e 100644
--- a/sd/source/ui/unoidl/unolayer.hxx
+++ b/sd/source/ui/unoidl/unolayer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117,8 +118,6 @@ private:
* *
***********************************************************************/
-//#include <cppuhelper/implbase4.hxx>
-
class SdLayerManager : public ::cppu::WeakImplHelper5< ::com::sun::star::drawing::XLayerManager,
::com::sun::star::container::XNameAccess,
::com::sun::star::lang::XServiceInfo,
@@ -187,3 +186,5 @@ private:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index a163046fb..6ecbaa9ec 100755..100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,11 +41,10 @@
#include <com/sun/star/presentation/XPresentation2.hpp>
#include <osl/mutex.hxx>
-#include <comphelper/serviceinfohelper.hxx>
-
#include <comphelper/sequence.hxx>
+#include <comphelper/servicehelper.hxx>
+#include <comphelper/serviceinfohelper.hxx>
-#include <rtl/uuid.h>
#include <rtl/memory.h>
#include <editeng/unofield.hxx>
#include <unomodel.hxx>
@@ -62,7 +62,7 @@
#include <svx/unopool.hxx>
#include <svx/svdorect.hxx>
#include <editeng/flditem.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <toolkit/awt/vclxdevice.hxx>
#include <svx/svdpool.hxx>
#include <editeng/unolingu.hxx>
@@ -72,7 +72,7 @@
#include <editeng/unonrule.hxx>
#include <editeng/eeitem.hxx>
-// #99870# Support creation of GraphicObjectResolver and EmbeddedObjectResolver
+// Support creation of GraphicObjectResolver and EmbeddedObjectResolver
#include <svx/xmleohlp.hxx>
#include <svx/xmlgrhlp.hxx>
#include "DrawDocShell.hxx"
@@ -118,7 +118,6 @@ using ::rtl::OUString;
#include <drawinglayer/primitive2d/structuretagprimitive2d.hxx>
using namespace ::osl;
-using namespace ::vos;
using namespace ::cppu;
using namespace ::com::sun::star;
@@ -227,7 +226,7 @@ SdXImpressDocument::SdXImpressDocument (::sd::DrawDocShell* pShell, bool bClipBo
}
else
{
- DBG_ERROR("DocShell is invalid");
+ OSL_FAIL("DocShell is invalid");
}
}
@@ -246,7 +245,7 @@ SdXImpressDocument::SdXImpressDocument( SdDrawDocument* pDoc, bool bClipBoard )
}
else
{
- DBG_ERROR("SdDrawDocument is invalid");
+ OSL_FAIL("SdDrawDocument is invalid");
}
}
@@ -257,41 +256,6 @@ SdXImpressDocument::~SdXImpressDocument() throw()
{
}
-// uno helper
-
-
-/******************************************************************************
-* Erzeugt anhand der uebergebennen SdPage eine SdDrawPage. Wurde fuer diese *
-* SdPage bereits eine SdDrawPage erzeugt, wird keine neue SdDrawPage erzeug. *
-******************************************************************************/
-/*
-uno::Reference< drawing::XDrawPage > SdXImpressDocument::CreateXDrawPage( SdPage* pPage ) throw()
-{
- DBG_ASSERT(pPage,"SdXImpressDocument::CreateXDrawPage( NULL? )");
-
- uno::Reference< drawing::XDrawPage > xDrawPage;
-
- if(pPage)
- {
- xDrawPage = SvxDrawPage::GetPageForSdrPage(pPage);
-
- if(!xDrawPage.is())
- {
- if(pPage->IsMasterPage())
- {
- xDrawPage = (presentation::XPresentationPage*)new SdMasterPage( this, pPage );
- }
- else
- {
- xDrawPage = (SvxDrawPage*)new SdDrawPage( this, pPage );
- }
- }
- }
-
- return xDrawPage;
-}
-*/
-
// XInterface
uno::Any SAL_CALL SdXImpressDocument::queryInterface( const uno::Type & rType ) throw(uno::RuntimeException)
{
@@ -338,8 +302,8 @@ void SAL_CALL SdXImpressDocument::release() throw ( )
}
catch (uno::RuntimeException const& exc)
{ // don't break throw ()
- OSL_ENSURE(
- false, OUStringToOString(
+ OSL_FAIL(
+ OUStringToOString(
exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
static_cast<void>(exc);
}
@@ -348,21 +312,15 @@ void SAL_CALL SdXImpressDocument::release() throw ( )
}
}
+namespace
+{
+ class theSdXImpressDocumentUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSdXImpressDocumentUnoTunnelId> {};
+}
+
// XUnoTunnel
const ::com::sun::star::uno::Sequence< sal_Int8 > & SdXImpressDocument::getUnoTunnelId() throw()
{
- static ::com::sun::star::uno::Sequence< sal_Int8 > * pSeq = 0;
- if( !pSeq )
- {
- ::osl::Guard< ::osl::Mutex > aGuard( ::osl::Mutex::getGlobalMutex() );
- if( !pSeq )
- {
- static ::com::sun::star::uno::Sequence< sal_Int8 > aSeq( 16 );
- rtl_createUuid( (sal_uInt8*)aSeq.getArray(), 0, sal_True );
- pSeq = &aSeq;
- }
- }
- return *pSeq;
+ return theSdXImpressDocumentUnoTunnelId::get().getSeq();
}
SdXImpressDocument* SdXImpressDocument::getImplementation( const uno::Reference< uno::XInterface >& xInt )
@@ -391,7 +349,7 @@ sal_Int64 SAL_CALL SdXImpressDocument::getSomething( const ::com::sun::star::uno
// XTypeProvider
uno::Sequence< uno::Type > SAL_CALL SdXImpressDocument::getTypes( ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( maTypeSequence.getLength() == 0 )
{
@@ -429,17 +387,14 @@ uno::Sequence< uno::Type > SAL_CALL SdXImpressDocument::getTypes( ) throw(uno::
return maTypeSequence;
}
-uno::Sequence< sal_Int8 > SAL_CALL SdXImpressDocument::getImplementationId( ) throw(uno::RuntimeException)
+namespace
{
- OGuard aGuard( Application::GetSolarMutex() );
+ class theSdXImpressDocumentImplementationId : public rtl::Static< UnoTunnelIdInit, theSdXImpressDocumentImplementationId > {};
+}
- static uno::Sequence< sal_Int8 > aId;
- if( aId.getLength() == 0 )
- {
- aId.realloc( 16 );
- rtl_createUuid( (sal_uInt8 *)aId.getArray(), 0, sal_True );
- }
- return aId;
+uno::Sequence< sal_Int8 > SAL_CALL SdXImpressDocument::getImplementationId( ) throw(uno::RuntimeException)
+{
+ return theSdXImpressDocumentImplementationId::get().getSeq();
}
/***********************************************************************
@@ -523,7 +478,7 @@ SdPage* SdXImpressDocument::InsertSdPage( sal_uInt16 nPage, sal_Bool bDuplicate
sal_Bool bIsPageBack = aVisibleLayers.IsSet( aBckgrnd );
sal_Bool bIsPageObj = aVisibleLayers.IsSet( aBckgrndObj );
- // AutoLayouts muessen fertig sein
+ // AutoLayouts must be ready
mpDoc->StopWorkStartupDelay();
/**************************************************************
@@ -539,7 +494,7 @@ SdPage* SdXImpressDocument::InsertSdPage( sal_uInt16 nPage, sal_Bool bDuplicate
String aNotesPageName;
/**************************************************************
- * Standardseite
+ * Standardpage
**************************************************************/
if( bDuplicate )
pStandardPage = (SdPage*) pPreviousStandardPage->Clone();
@@ -572,7 +527,7 @@ SdPage* SdXImpressDocument::InsertSdPage( sal_uInt16 nPage, sal_Bool bDuplicate
pStandardPage->TRG_SetMasterPageVisibleLayers(aVisibleLayers);
/**************************************************************
- * Notizseite
+ * Notespage
**************************************************************/
SdPage* pNotesPage = NULL;
@@ -617,32 +572,32 @@ void SdXImpressDocument::SetModified( sal_Bool bModified /* = sal_True */ ) thro
void SAL_CALL SdXImpressDocument ::lockControllers( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
- mpDoc->setLock( sal_True );
+ mpDoc->setLock(true);
}
void SAL_CALL SdXImpressDocument::unlockControllers( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
if( mpDoc->isLocked() )
{
- mpDoc->setLock( sal_False );
+ mpDoc->setLock(false);
}
}
sal_Bool SAL_CALL SdXImpressDocument::hasControllersLocked( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -650,13 +605,11 @@ sal_Bool SAL_CALL SdXImpressDocument::hasControllersLocked( )
return mpDoc && mpDoc->isLocked();
}
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
uno::Reference < container::XIndexAccess > SAL_CALL SdXImpressDocument::getViewData() throw( uno::RuntimeException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -665,9 +618,9 @@ uno::Reference < container::XIndexAccess > SAL_CALL SdXImpressDocument::getViewD
if( !xRet.is() )
{
- List* pFrameViewList = mpDoc->GetFrameViewList();
+ const std::vector<sd::FrameView*> &rList = mpDoc->GetFrameViewList();
- if( pFrameViewList && pFrameViewList->Count() )
+ if( !rList.empty() )
{
xRet = uno::Reference < container::XIndexAccess >::query(::comphelper::getProcessServiceFactory()->createInstance(OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.IndexedPropertyValues"))));
@@ -676,19 +629,13 @@ uno::Reference < container::XIndexAccess > SAL_CALL SdXImpressDocument::getViewD
DBG_ASSERT( xCont.is(), "SdXImpressDocument::getViewData() failed for OLE object" );
if( xCont.is() )
{
- sal_uInt32 i;
- for( i = 0; i < pFrameViewList->Count(); i++ )
+ for( sal_uInt32 i = 0, n = rList.size(); i < n; i++ )
{
- ::sd::FrameView* pFrameView =
- static_cast< ::sd::FrameView*>(
- pFrameViewList->GetObject(i));
+ ::sd::FrameView* pFrameView = rList[ i ];
- if(pFrameView)
- {
- uno::Sequence< beans::PropertyValue > aSeq;
- pFrameView->WriteUserDataSequence( aSeq );
- xCont->insertByIndex( i, uno::makeAny( aSeq ) );
- }
+ uno::Sequence< beans::PropertyValue > aSeq;
+ pFrameView->WriteUserDataSequence( aSeq );
+ xCont->insertByIndex( i, uno::makeAny( aSeq ) );
}
}
}
@@ -699,7 +646,7 @@ uno::Reference < container::XIndexAccess > SAL_CALL SdXImpressDocument::getViewD
void SAL_CALL SdXImpressDocument::setViewData( const uno::Reference < container::XIndexAccess >& xData ) throw(::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -709,36 +656,24 @@ void SAL_CALL SdXImpressDocument::setViewData( const uno::Reference < container:
{
const sal_Int32 nCount = xData->getCount();
- List* pFrameViewList = mpDoc->GetFrameViewList();
-
- DBG_ASSERT( pFrameViewList, "No FrameViewList?" );
- if( pFrameViewList )
- {
- ::sd::FrameView* pFrameView;
-
- sal_uInt32 i;
- for ( i = 0; i < pFrameViewList->Count(); i++)
- {
- // Ggf. FrameViews loeschen
- pFrameView = static_cast< ::sd::FrameView*>(
- pFrameViewList->GetObject(i));
+ std::vector<sd::FrameView*>::iterator pIter;
+ std::vector<sd::FrameView*> &rViews = mpDoc->GetFrameViewList();
- if (pFrameView)
- delete pFrameView;
- }
+ for ( pIter = rViews.begin(); pIter != rViews.end(); ++pIter )
+ delete *pIter;
- pFrameViewList->Clear();
+ rViews.clear();
- uno::Sequence< beans::PropertyValue > aSeq;
- sal_Int32 nIndex;
- for( nIndex = 0; nIndex < nCount; nIndex++ )
+ ::sd::FrameView* pFrameView;
+ uno::Sequence< beans::PropertyValue > aSeq;
+ for( sal_Int32 nIndex = 0; nIndex < nCount; nIndex++ )
+ {
+ if( xData->getByIndex( nIndex ) >>= aSeq )
{
- if( xData->getByIndex( nIndex ) >>= aSeq )
- {
- pFrameView = new ::sd::FrameView( mpDoc );
- pFrameView->ReadUserDataSequence( aSeq );
- pFrameViewList->Insert( pFrameView );
- }
+ pFrameView = new ::sd::FrameView( mpDoc );
+
+ pFrameView->ReadUserDataSequence( aSeq );
+ rViews.push_back( pFrameView );
}
}
}
@@ -748,7 +683,7 @@ void SAL_CALL SdXImpressDocument::setViewData( const uno::Reference < container:
uno::Reference< drawing::XDrawPage > SAL_CALL SdXImpressDocument::duplicate( const uno::Reference< drawing::XDrawPage >& xPage )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -777,7 +712,7 @@ uno::Reference< drawing::XDrawPage > SAL_CALL SdXImpressDocument::duplicate( con
uno::Reference< drawing::XDrawPages > SAL_CALL SdXImpressDocument::getDrawPages()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -797,7 +732,7 @@ uno::Reference< drawing::XDrawPages > SAL_CALL SdXImpressDocument::getDrawPages(
uno::Reference< drawing::XDrawPages > SAL_CALL SdXImpressDocument::getMasterPages()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -817,7 +752,7 @@ uno::Reference< drawing::XDrawPages > SAL_CALL SdXImpressDocument::getMasterPage
uno::Reference< container::XNameAccess > SAL_CALL SdXImpressDocument::getLayerManager( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -834,7 +769,7 @@ uno::Reference< container::XNameAccess > SAL_CALL SdXImpressDocument::getLayerMa
uno::Reference< container::XNameContainer > SAL_CALL SdXImpressDocument::getCustomPresentations()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -853,7 +788,7 @@ extern uno::Reference< presentation::XPresentation > createPresentation( SdXImpr
uno::Reference< presentation::XPresentation > SAL_CALL SdXImpressDocument::getPresentation()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -865,7 +800,7 @@ uno::Reference< presentation::XPresentation > SAL_CALL SdXImpressDocument::getPr
uno::Reference< drawing::XDrawPage > SAL_CALL SdXImpressDocument::getHandoutMasterPage()
throw (uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -886,7 +821,7 @@ uno::Reference< drawing::XDrawPage > SAL_CALL SdXImpressDocument::getHandoutMast
uno::Reference< uno::XInterface > SAL_CALL SdXImpressDocument::createInstance( const OUString& aServiceSpecifier )
throw(uno::Exception, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1005,7 +940,7 @@ uno::Reference< uno::XInterface > SAL_CALL SdXImpressDocument::createInstance( c
return svx::NamespaceMap_createInstance( aWhichIds, &mpDoc->GetItemPool() );
}
- // #99870# Support creation of GraphicObjectResolver and EmbeddedObjectResolver
+ // Support creation of GraphicObjectResolver and EmbeddedObjectResolver
if( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.document.ExportGraphicObjectResolver") ) )
{
return (::cppu::OWeakObject * )new SvXMLGraphicHelper( GRAPHICHELPER_MODE_WRITE );
@@ -1153,7 +1088,7 @@ uno::Reference< uno::XInterface > SAL_CALL SdXImpressDocument::createInstance( c
uno::Sequence< OUString > SAL_CALL SdXImpressDocument::getAvailableServiceNames()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1178,7 +1113,7 @@ uno::Sequence< OUString > SAL_CALL SdXImpressDocument::getAvailableServiceNames(
aSNS[i++] = OUString( RTL_CONSTASCII_USTRINGPARAM(sUNO_Service_ImageMapPolygonObject));
aSNS[i++] = OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.NamespaceMap"));
- // #99870# Support creation of GraphicObjectResolver and EmbeddedObjectResolver
+ // Support creation of GraphicObjectResolver and EmbeddedObjectResolver
aSNS[i++] = OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExportGraphicObjectResolver"));
aSNS[i++] = OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ImportGraphicObjectResolver"));
aSNS[i++] = OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExportEmbeddedObjectResolver"));
@@ -1226,26 +1161,26 @@ OUString SAL_CALL SdXImpressDocument::getImplementationName()
sal_Bool SAL_CALL SdXImpressDocument::supportsService( const OUString& ServiceName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if (
- (ServiceName.equalsAscii("com.sun.star.document.OfficeDocument" )) ||
- (ServiceName.equalsAscii("com.sun.star.drawing.GenericDrawingDocument")) ||
- (ServiceName.equalsAscii("com.sun.star.drawing.DrawingDocumentFactory"))
+ (ServiceName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.document.OfficeDocument"))) ||
+ (ServiceName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.drawing.GenericDrawingDocument"))) ||
+ (ServiceName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.drawing.DrawingDocumentFactory")))
)
{
return sal_True;
}
return (
- ( mbImpressDoc && ServiceName.equalsAscii("com.sun.star.presentation.PresentationDocument")) ||
- (!mbImpressDoc && ServiceName.equalsAscii("com.sun.star.drawing.DrawingDocument" ))
+ ( mbImpressDoc && ServiceName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.presentation.PresentationDocument"))) ||
+ (!mbImpressDoc && ServiceName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.drawing.DrawingDocument")))
);
}
uno::Sequence< OUString > SAL_CALL SdXImpressDocument::getSupportedServiceNames() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
uno::Sequence< OUString > aSeq( 4 );
OUString* pServices = aSeq.getArray();
@@ -1266,14 +1201,14 @@ uno::Sequence< OUString > SAL_CALL SdXImpressDocument::getSupportedServiceNames(
uno::Reference< beans::XPropertySetInfo > SAL_CALL SdXImpressDocument::getPropertySetInfo( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
return mpPropSet->getPropertySetInfo();
}
void SAL_CALL SdXImpressDocument::setPropertyValue( const OUString& aPropertyName, const uno::Any& aValue )
throw(beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1347,7 +1282,7 @@ void SAL_CALL SdXImpressDocument::setPropertyValue( const OUString& aPropertyNam
uno::Any SAL_CALL SdXImpressDocument::getPropertyValue( const OUString& PropertyName )
throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
uno::Any aAny;
if( NULL == mpDoc )
@@ -1431,7 +1366,7 @@ void SAL_CALL SdXImpressDocument::removeVetoableChangeListener( const OUString&
uno::Reference< container::XNameAccess > SAL_CALL SdXImpressDocument::getLinks()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1446,7 +1381,7 @@ uno::Reference< container::XNameAccess > SAL_CALL SdXImpressDocument::getLinks()
uno::Reference< container::XNameAccess > SAL_CALL SdXImpressDocument::getStyleFamilies( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1467,7 +1402,7 @@ sal_Int32 SAL_CALL SdXImpressDocument::getRendererCount( const uno::Any& rSelect
const uno::Sequence< beans::PropertyValue >& )
throw (lang::IllegalArgumentException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
sal_Int32 nRet = 0;
if( NULL == mpDoc )
@@ -1500,7 +1435,7 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SdXImpressDocument::getRenderer(
const uno::Sequence< beans::PropertyValue >& rxOptions )
throw (lang::IllegalArgumentException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1508,7 +1443,7 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SdXImpressDocument::getRenderer(
sal_Bool bExportNotesPages = sal_False;
for( sal_Int32 nProperty = 0, nPropertyCount = rxOptions.getLength(); nProperty < nPropertyCount; ++nProperty )
{
- if( rxOptions[ nProperty ].Name.equalsAscii( "ExportNotesPages" ) )
+ if( rxOptions[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ExportNotesPages" ) ) )
rxOptions[ nProperty].Value >>= bExportNotesPages;
}
uno::Sequence< beans::PropertyValue > aRenderer;
@@ -1610,7 +1545,6 @@ void ImplPDFExportComments( uno::Reference< drawing::XDrawPage > xPage, vcl::PDF
geometry::RealPoint2D aRealPoint2D( xAnnotation->getPosition() );
uno::Reference< text::XText > xText( xAnnotation->getTextRange() );
-// rtl::OUString sInitials( getInitials( sAuthor ) );
util::DateTime aDateTime( xAnnotation->getDateTime() );
Date aDate( aDateTime.Day, aDateTime.Month, aDateTime.Year );
@@ -1859,7 +1793,7 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
const uno::Sequence< beans::PropertyValue >& rxOptions )
throw (lang::IllegalArgumentException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpDoc )
throw lang::DisposedException();
@@ -1978,9 +1912,11 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
// exporting object interactions to pdf
// if necessary, the master page interactions will be exported first
- sal_Bool bIsBackgroundObjectsVisible = sal_False; // SJ: #i39428# IsBackgroundObjectsVisible not available for Draw
+ sal_Bool bIsBackgroundObjectsVisible = sal_False; // #i39428# IsBackgroundObjectsVisible not available for Draw
const rtl::OUString sIsBackgroundObjectsVisible( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundObjectsVisible" ) );
- if ( mbImpressDoc && ( xPagePropSet->getPropertyValue( sIsBackgroundObjectsVisible ) >>= bIsBackgroundObjectsVisible ) && bIsBackgroundObjectsVisible )
+ if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sIsBackgroundObjectsVisible ) )
+ xPagePropSet->getPropertyValue( sIsBackgroundObjectsVisible ) >>= bIsBackgroundObjectsVisible;
+ if ( mbImpressDoc && bIsBackgroundObjectsVisible )
{
uno::Reference< drawing::XMasterPageTarget > xMasterPageTarget( xPage, uno::UNO_QUERY );
if ( xMasterPageTarget.is() )
@@ -2013,88 +1949,99 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
}
// exporting transition effects to pdf
- if ( mbImpressDoc && pPDFExtOutDevData->GetIsExportTransitionEffects() ) // SJ: #i39428# TransitionEffects not available for Draw
+ if ( mbImpressDoc && pPDFExtOutDevData->GetIsExportTransitionEffects() ) // #i39428# TransitionEffects not available for Draw
{
const rtl::OUString sEffect( RTL_CONSTASCII_USTRINGPARAM( "Effect" ) );
const rtl::OUString sSpeed ( RTL_CONSTASCII_USTRINGPARAM( "Speed" ) );
sal_Int32 nTime = 800;
presentation::AnimationSpeed aAs;
- aAny = xPagePropSet->getPropertyValue( sSpeed );
- if ( aAny >>= aAs )
+ if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sSpeed ) )
{
- switch( aAs )
+ aAny = xPagePropSet->getPropertyValue( sSpeed );
+ if ( aAny >>= aAs )
{
- case presentation::AnimationSpeed_SLOW : nTime = 1500; break;
- case presentation::AnimationSpeed_FAST : nTime = 300; break;
- default:
- case presentation::AnimationSpeed_MEDIUM : nTime = 800;
+ switch( aAs )
+ {
+ case presentation::AnimationSpeed_SLOW : nTime = 1500; break;
+ case presentation::AnimationSpeed_FAST : nTime = 300; break;
+ default:
+ case presentation::AnimationSpeed_MEDIUM : nTime = 800;
+ }
}
}
presentation::FadeEffect eFe;
- aAny = xPagePropSet->getPropertyValue( sEffect );
vcl::PDFWriter::PageTransition eType = vcl::PDFWriter::Regular;
- if ( aAny >>= eFe )
+ if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sEffect ) )
{
- switch( eFe )
+ aAny = xPagePropSet->getPropertyValue( sEffect );
+ if ( aAny >>= eFe )
{
- case presentation::FadeEffect_HORIZONTAL_LINES :
- case presentation::FadeEffect_HORIZONTAL_CHECKERBOARD :
- case presentation::FadeEffect_HORIZONTAL_STRIPES : eType = vcl::PDFWriter::BlindsHorizontal; break;
-
- case presentation::FadeEffect_VERTICAL_LINES :
- case presentation::FadeEffect_VERTICAL_CHECKERBOARD :
- case presentation::FadeEffect_VERTICAL_STRIPES : eType = vcl::PDFWriter::BlindsVertical; break;
-
- case presentation::FadeEffect_UNCOVER_TO_RIGHT :
- case presentation::FadeEffect_UNCOVER_TO_UPPERRIGHT :
- case presentation::FadeEffect_ROLL_FROM_LEFT :
- case presentation::FadeEffect_FADE_FROM_UPPERLEFT :
- case presentation::FadeEffect_MOVE_FROM_UPPERLEFT :
- case presentation::FadeEffect_FADE_FROM_LEFT :
- case presentation::FadeEffect_MOVE_FROM_LEFT : eType = vcl::PDFWriter::WipeLeftToRight; break;
-
- case presentation::FadeEffect_UNCOVER_TO_BOTTOM :
- case presentation::FadeEffect_UNCOVER_TO_LOWERRIGHT :
- case presentation::FadeEffect_ROLL_FROM_TOP :
- case presentation::FadeEffect_FADE_FROM_UPPERRIGHT :
- case presentation::FadeEffect_MOVE_FROM_UPPERRIGHT :
- case presentation::FadeEffect_FADE_FROM_TOP :
- case presentation::FadeEffect_MOVE_FROM_TOP : eType = vcl::PDFWriter::WipeTopToBottom; break;
-
- case presentation::FadeEffect_UNCOVER_TO_LEFT :
- case presentation::FadeEffect_UNCOVER_TO_LOWERLEFT :
- case presentation::FadeEffect_ROLL_FROM_RIGHT :
-
- case presentation::FadeEffect_FADE_FROM_LOWERRIGHT :
- case presentation::FadeEffect_MOVE_FROM_LOWERRIGHT :
- case presentation::FadeEffect_FADE_FROM_RIGHT :
- case presentation::FadeEffect_MOVE_FROM_RIGHT : eType = vcl::PDFWriter::WipeRightToLeft; break;
-
- case presentation::FadeEffect_UNCOVER_TO_TOP :
- case presentation::FadeEffect_UNCOVER_TO_UPPERLEFT :
- case presentation::FadeEffect_ROLL_FROM_BOTTOM :
- case presentation::FadeEffect_FADE_FROM_LOWERLEFT :
- case presentation::FadeEffect_MOVE_FROM_LOWERLEFT :
- case presentation::FadeEffect_FADE_FROM_BOTTOM :
- case presentation::FadeEffect_MOVE_FROM_BOTTOM : eType = vcl::PDFWriter::WipeBottomToTop; break;
-
- case presentation::FadeEffect_OPEN_VERTICAL : eType = vcl::PDFWriter::SplitHorizontalInward; break;
- case presentation::FadeEffect_CLOSE_HORIZONTAL : eType = vcl::PDFWriter::SplitHorizontalOutward; break;
-
- case presentation::FadeEffect_OPEN_HORIZONTAL : eType = vcl::PDFWriter::SplitVerticalInward; break;
- case presentation::FadeEffect_CLOSE_VERTICAL : eType = vcl::PDFWriter::SplitVerticalOutward; break;
-
- case presentation::FadeEffect_FADE_TO_CENTER : eType = vcl::PDFWriter::BoxInward; break;
- case presentation::FadeEffect_FADE_FROM_CENTER : eType = vcl::PDFWriter::BoxOutward; break;
-
- case presentation::FadeEffect_NONE : eType = vcl::PDFWriter::Regular; break;
-
- case presentation::FadeEffect_RANDOM :
- case presentation::FadeEffect_DISSOLVE :
- default: eType = vcl::PDFWriter::Dissolve; break;
+ switch( eFe )
+ {
+ case presentation::FadeEffect_HORIZONTAL_LINES :
+ case presentation::FadeEffect_HORIZONTAL_CHECKERBOARD :
+ case presentation::FadeEffect_HORIZONTAL_STRIPES : eType = vcl::PDFWriter::BlindsHorizontal; break;
+
+ case presentation::FadeEffect_VERTICAL_LINES :
+ case presentation::FadeEffect_VERTICAL_CHECKERBOARD :
+ case presentation::FadeEffect_VERTICAL_STRIPES : eType = vcl::PDFWriter::BlindsVertical; break;
+
+ case presentation::FadeEffect_UNCOVER_TO_RIGHT :
+ case presentation::FadeEffect_UNCOVER_TO_UPPERRIGHT :
+ case presentation::FadeEffect_ROLL_FROM_LEFT :
+ case presentation::FadeEffect_FADE_FROM_UPPERLEFT :
+ case presentation::FadeEffect_MOVE_FROM_UPPERLEFT :
+ case presentation::FadeEffect_FADE_FROM_LEFT :
+ case presentation::FadeEffect_MOVE_FROM_LEFT : eType = vcl::PDFWriter::WipeLeftToRight; break;
+
+ case presentation::FadeEffect_UNCOVER_TO_BOTTOM :
+ case presentation::FadeEffect_UNCOVER_TO_LOWERRIGHT :
+ case presentation::FadeEffect_ROLL_FROM_TOP :
+ case presentation::FadeEffect_FADE_FROM_UPPERRIGHT :
+ case presentation::FadeEffect_MOVE_FROM_UPPERRIGHT :
+ case presentation::FadeEffect_FADE_FROM_TOP :
+ case presentation::FadeEffect_MOVE_FROM_TOP : eType = vcl::PDFWriter::WipeTopToBottom; break;
+
+ case presentation::FadeEffect_UNCOVER_TO_LEFT :
+ case presentation::FadeEffect_UNCOVER_TO_LOWERLEFT :
+ case presentation::FadeEffect_ROLL_FROM_RIGHT :
+
+ case presentation::FadeEffect_FADE_FROM_LOWERRIGHT :
+ case presentation::FadeEffect_MOVE_FROM_LOWERRIGHT :
+ case presentation::FadeEffect_FADE_FROM_RIGHT :
+ case presentation::FadeEffect_MOVE_FROM_RIGHT : eType = vcl::PDFWriter::WipeRightToLeft; break;
+
+ case presentation::FadeEffect_UNCOVER_TO_TOP :
+ case presentation::FadeEffect_UNCOVER_TO_UPPERLEFT :
+ case presentation::FadeEffect_ROLL_FROM_BOTTOM :
+ case presentation::FadeEffect_FADE_FROM_LOWERLEFT :
+ case presentation::FadeEffect_MOVE_FROM_LOWERLEFT :
+ case presentation::FadeEffect_FADE_FROM_BOTTOM :
+ case presentation::FadeEffect_MOVE_FROM_BOTTOM : eType = vcl::PDFWriter::WipeBottomToTop; break;
+
+ case presentation::FadeEffect_OPEN_VERTICAL : eType = vcl::PDFWriter::SplitHorizontalInward; break;
+ case presentation::FadeEffect_CLOSE_HORIZONTAL : eType = vcl::PDFWriter::SplitHorizontalOutward; break;
+
+ case presentation::FadeEffect_OPEN_HORIZONTAL : eType = vcl::PDFWriter::SplitVerticalInward; break;
+ case presentation::FadeEffect_CLOSE_VERTICAL : eType = vcl::PDFWriter::SplitVerticalOutward; break;
+
+ case presentation::FadeEffect_FADE_TO_CENTER : eType = vcl::PDFWriter::BoxInward; break;
+ case presentation::FadeEffect_FADE_FROM_CENTER : eType = vcl::PDFWriter::BoxOutward; break;
+
+ case presentation::FadeEffect_NONE : eType = vcl::PDFWriter::Regular; break;
+
+ case presentation::FadeEffect_RANDOM :
+ case presentation::FadeEffect_DISSOLVE :
+ default: eType = vcl::PDFWriter::Dissolve; break;
+ }
}
}
- pPDFExtOutDevData->SetPageTransition( eType, nTime, -1 );
+
+ if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sEffect ) ||
+ xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sSpeed ) )
+ {
+ pPDFExtOutDevData->SetPageTransition( eType, nTime, -1 );
+ }
}
}
}
@@ -2119,10 +2066,10 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
}
else
pPDFExtOutDevData->SetLinkURL( aIBeg->nLinkId, aIBeg->aBookmark );
- aIBeg++;
+ ++aIBeg;
}
rBookmarks.clear();
- //---> i56629, i40318
+ //---> #i56629, #i40318
//get the page name, will be used as outline element in PDF bookmark pane
String aPageName = mpDoc->GetSdPage( (sal_uInt16)nPageNumber - 1 , PK_STANDARD )->GetName();
if( aPageName.Len() > 0 )
@@ -2132,7 +2079,7 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
pPDFExtOutDevData->CreateNamedDest( aPageName, aPageRect, nPageNumber - 1 );
//
// add the name to the outline, (almost) same code as in sc/source/ui/unoobj/docuno.cxx
- // issue i40318.
+ // issue #i40318.
//
if( pPDFExtOutDevData->GetIsExportBookmarks() )
{
@@ -2144,9 +2091,9 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
pPDFExtOutDevData->CreateOutlineItem( -1 , aPageName, nDestId );
}
}
- //<--- i56629, i40318
+ //<--- #i56629, #i40318
}
- catch( uno::Exception& )
+ catch( uno::Exception& e )
{
}
@@ -2236,7 +2183,7 @@ void SAL_CALL SdXImpressDocument::dispose() throw (::com::sun::star::uno::Runtim
if( !mbDisposed )
{
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( mpDoc )
{
@@ -2350,7 +2297,7 @@ SdDrawPagesAccess::~SdDrawPagesAccess() throw()
sal_Int32 SAL_CALL SdDrawPagesAccess::getCount()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2361,7 +2308,7 @@ sal_Int32 SAL_CALL SdDrawPagesAccess::getCount()
uno::Any SAL_CALL SdDrawPagesAccess::getByIndex( sal_Int32 Index )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2384,7 +2331,7 @@ uno::Any SAL_CALL SdDrawPagesAccess::getByIndex( sal_Int32 Index )
// XNameAccess
uno::Any SAL_CALL SdDrawPagesAccess::getByName( const OUString& aName ) throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2414,7 +2361,7 @@ uno::Any SAL_CALL SdDrawPagesAccess::getByName( const OUString& aName ) throw(co
uno::Sequence< OUString > SAL_CALL SdDrawPagesAccess::getElementNames() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2435,7 +2382,7 @@ uno::Sequence< OUString > SAL_CALL SdDrawPagesAccess::getElementNames() throw(un
sal_Bool SAL_CALL SdDrawPagesAccess::hasByName( const OUString& aName ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2477,7 +2424,7 @@ sal_Bool SAL_CALL SdDrawPagesAccess::hasElements()
uno::Reference< drawing::XDrawPage > SAL_CALL SdDrawPagesAccess::insertNewByIndex( sal_Int32 nIndex )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2503,7 +2450,7 @@ uno::Reference< drawing::XDrawPage > SAL_CALL SdDrawPagesAccess::insertNewByInde
void SAL_CALL SdDrawPagesAccess::remove( const uno::Reference< drawing::XDrawPage >& xPage )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel || mpModel->mpDoc == NULL )
throw lang::DisposedException();
@@ -2581,12 +2528,12 @@ void SAL_CALL SdDrawPagesAccess::dispose( ) throw (uno::RuntimeException)
void SAL_CALL SdDrawPagesAccess::addEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
void SAL_CALL SdDrawPagesAccess::removeEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
//=============================================================================
@@ -2610,19 +2557,19 @@ void SAL_CALL SdMasterPagesAccess::dispose( ) throw (uno::RuntimeException)
void SAL_CALL SdMasterPagesAccess::addEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
void SAL_CALL SdMasterPagesAccess::removeEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
// XIndexAccess
sal_Int32 SAL_CALL SdMasterPagesAccess::getCount()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel->mpDoc )
throw lang::DisposedException();
@@ -2637,7 +2584,7 @@ sal_Int32 SAL_CALL SdMasterPagesAccess::getCount()
uno::Any SAL_CALL SdMasterPagesAccess::getByIndex( sal_Int32 Index )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2674,7 +2621,7 @@ sal_Bool SAL_CALL SdMasterPagesAccess::hasElements()
uno::Reference< drawing::XDrawPage > SAL_CALL SdMasterPagesAccess::insertNewByIndex( sal_Int32 nInsertPos )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2757,7 +2704,6 @@ uno::Reference< drawing::XDrawPage > SAL_CALL SdMasterPagesAccess::insertNewByIn
pRefNotesPage->GetLwrBorder() );
pMNotesPage->SetLayoutName( aLayoutName );
mpDoc->InsertMasterPage(pMNotesPage, (sal_uInt16)nInsertPos + 1);
-// pMNotesPage->InsertMasterPage( pMPage->GetPageNum() );
pMNotesPage->SetAutoLayout(AUTOLAYOUT_NOTES, sal_True, sal_True);
mpModel->SetModified();
}
@@ -2773,7 +2719,7 @@ uno::Reference< drawing::XDrawPage > SAL_CALL SdMasterPagesAccess::insertNewByIn
void SAL_CALL SdMasterPagesAccess::remove( const uno::Reference< drawing::XDrawPage >& xPage )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel || mpModel->mpDoc == NULL )
throw lang::DisposedException();
@@ -2864,19 +2810,19 @@ void SAL_CALL SdDocLinkTargets::dispose( ) throw (uno::RuntimeException)
void SAL_CALL SdDocLinkTargets::addEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
void SAL_CALL SdDocLinkTargets::removeEventListener( const uno::Reference< lang::XEventListener >& ) throw (uno::RuntimeException)
{
- DBG_ERROR( "not implemented!" );
+ OSL_FAIL( "not implemented!" );
}
// XNameAccess
uno::Any SAL_CALL SdDocLinkTargets::getByName( const OUString& aName )
throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2898,7 +2844,7 @@ uno::Any SAL_CALL SdDocLinkTargets::getByName( const OUString& aName )
uno::Sequence< OUString > SAL_CALL SdDocLinkTargets::getElementNames()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2951,7 +2897,7 @@ uno::Sequence< OUString > SAL_CALL SdDocLinkTargets::getElementNames()
sal_Bool SAL_CALL SdDocLinkTargets::hasByName( const OUString& aName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -2969,7 +2915,7 @@ uno::Type SAL_CALL SdDocLinkTargets::getElementType()
sal_Bool SAL_CALL SdDocLinkTargets::hasElements()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
if( NULL == mpModel )
throw lang::DisposedException();
@@ -3072,3 +3018,5 @@ void NotifyDocumentEvent( SdDrawDocument* pDocument, const rtl::OUString& rEvent
xModel->notifyEvent(aEvent );
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unomodule.cxx b/sd/source/ui/unoidl/unomodule.cxx
index e2ff83c45..d340fc47b 100644
--- a/sd/source/ui/unoidl/unomodule.cxx
+++ b/sd/source/ui/unoidl/unomodule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,7 +38,7 @@
#include <sfx2/objface.hxx>
#include <sfx2/bindings.hxx>
#include <sfx2/request.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
using namespace ::com::sun::star;
@@ -57,7 +58,7 @@ uno::Sequence< rtl::OUString > SAL_CALL SdUnoModule_getSupportedServiceNames() t
uno::Reference< uno::XInterface > SAL_CALL SdUnoModule_createInstance(
const uno::Reference< lang::XMultiServiceFactory > & rSMgr )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return uno::Reference< uno::XInterface >( static_cast< cppu::OWeakObject* >( new SdUnoModule( rSMgr ) ) );
}
@@ -69,7 +70,7 @@ void SAL_CALL SdUnoModule::dispatchWithNotification( const ::com::sun::star::uti
// asynchronous ...
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > xThis(static_cast< ::com::sun::star::frame::XNotifyingDispatch* >(this));
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
SdDLL::Init();
const SfxSlot* pSlot = SD_MOD()->GetInterface()->GetSlot( aURL.Complete );
@@ -125,7 +126,7 @@ SEQUENCE< REFERENCE< XDISPATCH > > SAL_CALL SdUnoModule::queryDispatches( const
// XDispatchProvider
REFERENCE< XDISPATCH > SAL_CALL SdUnoModule::queryDispatch( const UNOURL& aURL, const OUSTRING&, sal_Int32 ) throw( RUNTIMEEXCEPTION )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
SdDLL::Init();
const SfxSlot* pSlot = SD_MOD()->GetInterface()->GetSlot( aURL.Complete );
@@ -161,3 +162,4 @@ sal_Bool SAL_CALL SdUnoModule::supportsService( const ::rtl::OUString& sServiceN
return SdUnoModule_getSupportedServiceNames();
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unomodule.hxx b/sd/source/ui/unoidl/unomodule.hxx
index e7dcffc76..5af44440d 100644
--- a/sd/source/ui/unoidl/unomodule.hxx
+++ b/sd/source/ui/unoidl/unomodule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,3 +97,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unoobj.cxx b/sd/source/ui/unoidl/unoobj.cxx
index fc5b9c9b7..e47d9fc7d 100755..100644
--- a/sd/source/ui/unoidl/unoobj.cxx
+++ b/sd/source/ui/unoidl/unoobj.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,7 +37,7 @@
#include <com/sun/star/beans/PropertyValues.hpp>
#include <rtl/ustrbuf.hxx>
#include <comphelper/stl_types.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <svl/itemprop.hxx>
#include <svl/style.hxx>
#include <svx/svdpool.hxx>
@@ -71,11 +72,7 @@
#include "ViewShell.hxx"
#include "unokywds.hxx"
#include "unopage.hxx"
-#ifndef SVX_LIGHT
-#ifndef SD_DRAW_DOC_SHELL_HXX
#include "DrawDocShell.hxx"
-#endif
-#endif
#include "helpids.h"
#include "glob.hxx"
#include "glob.hrc"
@@ -93,7 +90,6 @@
using ::rtl::OUString;
using ::rtl::OUStringBuffer;
-using namespace ::vos;
using namespace ::sd;
using namespace ::com::sun::star;
using namespace ::com::sun::star::presentation;
@@ -146,6 +142,7 @@ static SdTypesCache gImplTypesCache;
#define WID_THAT_NEED_ANIMINFO 19
+#define WID_PLACEHOLDERTEXT 24
#define IMPRESS_MAP_ENTRIES \
@@ -170,6 +167,7 @@ static SdTypesCache gImplTypesCache;
{ MAP_CHAR_LEN(UNO_NAME_OBJ_VERB), WID_VERB, &::getCppuType((const sal_Int32*)0), 0, 0},\
{ MAP_CHAR_LEN("IsAnimation"), WID_ISANIMATION, &::getBooleanCppuType(), 0, 0},\
{ MAP_CHAR_LEN("NavigationOrder"), WID_NAVORDER, &::getCppuType((const sal_Int32*)0), 0, 0},\
+ { MAP_CHAR_LEN("PlaceholderText"), WID_PLACEHOLDERTEXT, &::getCppuType((const OUString*)0), 0, 0},\
{ 0,0,0,0,0,0}
@@ -407,7 +405,7 @@ uno::Sequence< uno::Type > SAL_CALL SdXShape::getTypes()
// XPropertyState
beans::PropertyState SAL_CALL SdXShape::getPropertyState( const OUString& PropertyName ) throw( beans::UnknownPropertyException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpPropSet->getPropertyMapEntry(PropertyName) )
{
@@ -425,7 +423,7 @@ beans::PropertyState SAL_CALL SdXShape::getPropertyState( const OUString& Proper
void SAL_CALL SdXShape::setPropertyToDefault( const OUString& PropertyName ) throw( beans::UnknownPropertyException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpPropSet->getPropertyMapEntry(PropertyName) )
{
@@ -439,7 +437,7 @@ void SAL_CALL SdXShape::setPropertyToDefault( const OUString& PropertyName ) thr
uno::Any SAL_CALL SdXShape::getPropertyDefault( const OUString& aPropertyName ) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if( mpPropSet->getPropertyMapEntry(aPropertyName) )
{
@@ -494,7 +492,7 @@ uno::Any SAL_CALL SdXShape::getPropertyDefault( const OUString& aPropertyName )
void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName, const ::com::sun::star::uno::Any& aValue )
throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = mpPropSet->getPropertyMapEntry(aPropertyName);
@@ -546,17 +544,7 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
EffectMigration::SetAnimationSpeed( mpShape, eSpeed );
break;
}
-/* TODO?? case WID_ISANIMATION:
- {
-
- sal_Bool bIsAnimation;
- if(!(aValue >>= bIsAnimation))
- throw lang::IllegalArgumentException();
-
- pInfo->mbIsMovie = bIsAnimation;
- break;
- }
-*/
+// TODO: WID_ISANIMATION
case WID_BOOKMARK:
{
OUString aString;
@@ -570,11 +558,7 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
::cppu::any2enum< presentation::ClickAction >( pInfo->meClickAction, aValue);
break;
-/* todo?
- case WID_PLAYFULL:
- pInfo->mbPlayFull = ::cppu::any2bool(aValue);
- break;
-*/
+// TODO: WID_PLAYFULL:
case WID_SOUNDFILE:
{
OUString aString;
@@ -592,17 +576,6 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
EffectMigration::UpdateSoundEffect( mpShape, pInfo );
break;
}
-/*
- case WID_BLUESCREEN:
- {
- sal_Int32 nColor;
- if(!(aValue >>= nColor))
- throw lang::IllegalArgumentException();
-
- pInfo->maBlueScreen.SetColor( nColor );
- break;
- }
-*/
case WID_VERB:
{
sal_Int32 nVerb = 0;
@@ -658,36 +631,8 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
case WID_MASTERDEPEND:
SetMasterDepend( ::cppu::any2bool(aValue) );
break;
-/* todo
- case WID_ANIMPATH:
- {
- uno::Reference< drawing::XShape > xShape;
- aValue >>= xShape;
-
- SdrObject* pObj = NULL;
- if(xShape.is())
- pObj = GetSdrObjectFromXShape( xShape );
-
- if( pObj == NULL || !pObj->ISA( SdrPathObj ) )
- throw lang::IllegalArgumentException();
- pInfo->mpPathObj = (SdrPathObj*)pObj;
-
- SdDrawDocument* pDoc = mpModel?mpModel->GetDoc():NULL;
- if( pDoc )
- {
- pInfo = pDoc->GetAnimationInfo(pObj);
- if( pInfo == NULL )
- {
- pInfo = new SdAnimationInfo(pDoc);
- pObj->InsertUserData( pInfo );
- }
- pInfo->mbInvisibleInPresentation = sal_True;
- }
-
- break;
- }
-*/
+// TODO: WID_ANIMPATH
case WID_IMAGEMAP:
{
SdDrawDocument* pDoc = mpModel?mpModel->GetDoc():NULL;
@@ -740,7 +685,7 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
::com::sun::star::uno::Any SAL_CALL SdXShape::getPropertyValue( const ::rtl::OUString& PropertyName )
throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
uno::Any aRet;
@@ -779,6 +724,9 @@ void SAL_CALL SdXShape::setPropertyValue( const ::rtl::OUString& aPropertyName,
case WID_ISANIMATION:
aRet <<= (sal_Bool)( pInfo && pInfo->mbIsMovie);
break;
+ case WID_PLACEHOLDERTEXT:
+ aRet <<= GetPlaceholderText();
+ break;
case WID_BOOKMARK:
{
OUString aString;
@@ -967,6 +915,24 @@ sal_Bool SdXShape::IsEmptyPresObj() const throw()
return sal_False;
}
+OUString SdXShape::GetPlaceholderText() const
+{
+ // only possible if this actually *is* a presentation object
+ if( !IsPresObj() )
+ return OUString();
+
+ SdrObject* pObj = mpShape->GetSdrObject();
+ if( pObj == NULL )
+ return OUString();
+
+ SdPage* pPage = PTR_CAST(SdPage,pObj->GetPage());
+ DBG_ASSERT( pPage, "no page?" );
+ if( pPage == NULL )
+ return OUString();
+
+ return pPage->GetPresObjText( pPage->GetPresObjKind(pObj) );
+ }
+
/** sets/reset the empty status of a presentation object
*/
void SdXShape::SetEmptyPresObj( sal_Bool bEmpty ) throw()
@@ -1761,3 +1727,4 @@ void SdXShape::objectChanged( SdrObject* )
{
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unoobj.hxx b/sd/source/ui/unoidl/unoobj.hxx
index e6f8f4dd2..809a98593 100755..100644
--- a/sd/source/ui/unoidl/unoobj.hxx
+++ b/sd/source/ui/unoidl/unoobj.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,6 +72,7 @@ private:
void SetMasterDepend( sal_Bool bDepend ) throw();
SdrObject* GetSdrObject() const throw();
+ ::rtl::OUString GetPlaceholderText() const;
com::sun::star::uno::Sequence< sal_Int8 >* mpImplementationId;
@@ -136,3 +138,4 @@ const SvEventDescription* ImplGetSupportedMacroItems();
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index d97e7405d..487401c76 100755..100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
@@ -1,7 +1,8 @@
+ /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -38,6 +39,7 @@
#include <com/sun/star/presentation/EffectNodeType.hpp>
#include <com/sun/star/lang/DisposedException.hpp>
#include <comphelper/processfactory.hxx>
+#include <comphelper/servicehelper.hxx>
#include <rtl/ustrbuf.hxx>
#include <vcl/bitmapex.hxx>
#include <vcl/metaact.hxx>
@@ -58,9 +60,8 @@
#include <svx/unoshape.hxx>
#include <com/sun/star/style/XStyle.hpp>
#include <svx/svdorect.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <svl/style.hxx>
-#include <rtl/uuid.h>
#include <rtl/memory.h>
#include <comphelper/serviceinfohelper.hxx>
@@ -71,13 +72,8 @@
#include <svx/svdoole2.hxx>
#include <svx/svdpool.hxx>
#include <svx/svdview.hxx>
-#include "misc.hxx"
#include "View.hxx"
-#ifndef SVX_LIGHT
-#ifndef SD_DRAW_DOC_SHELL_HXX
#include "DrawDocShell.hxx"
-#endif
-#endif
#include "ViewShell.hxx"
#include "DrawViewShell.hxx"
#include "unoobj.hxx"
@@ -91,7 +87,6 @@ using ::com::sun::star::animations::XAnimationNodeSupplier;
using ::rtl::OUString;
using ::rtl::OUStringBuffer;
-using namespace ::vos;
using namespace ::osl;
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -114,7 +109,7 @@ enum WID_PAGE
WID_PAGE_BACK, WID_PAGE_PREVIEW, WID_PAGE_PREVIEWBITMAP, WID_PAGE_VISIBLE, WID_PAGE_SOUNDFILE, WID_PAGE_BACKFULL,
WID_PAGE_BACKVIS, WID_PAGE_BACKOBJVIS, WID_PAGE_USERATTRIBS, WID_PAGE_BOOKMARK, WID_PAGE_ISDARK,
WID_PAGE_HEADERVISIBLE, WID_PAGE_HEADERTEXT, WID_PAGE_FOOTERVISIBLE, WID_PAGE_FOOTERTEXT,
- WID_PAGE_PAGENUMBERVISIBLE, WID_PAGE_DATETIMEVISIBLE, WID_PAGE_DATETIMEFIXED,
+ WID_PAGE_PAGENUMBERVISIBLE, WID_PAGE_DATETIMEVISIBLE, WID_PAGE_DATETIMEFIXED,
WID_PAGE_DATETIMETEXT, WID_PAGE_DATETIMEFORMAT, WID_TRANSITION_TYPE, WID_TRANSITION_SUBTYPE,
WID_TRANSITION_DIRECTION, WID_TRANSITION_FADE_COLOR, WID_TRANSITION_DURATION, WID_LOOP_SOUND,
WID_NAVORDER
@@ -128,7 +123,7 @@ enum WID_PAGE
#endif
#endif
-static sal_Char __FAR_DATA sEmptyPageName[sizeof("page")] = "page";
+static sal_Char sEmptyPageName[sizeof("page")] = "page";
/** this function stores the property maps for draw pages in impress and draw */
const SvxItemPropertySet* ImplGetDrawPagePropertySet( sal_Bool bImpress, PageKind ePageKind )
@@ -231,41 +226,40 @@ const SvxItemPropertySet* ImplGetDrawPagePropertySet( sal_Bool bImpress, PageKin
{ MAP_CHAR_LEN(sUNO_Prop_BookmarkURL), WID_PAGE_BOOKMARK, &::getCppuType((const OUString*)0), 0, 0}, \
{ MAP_CHAR_LEN("IsBackgroundDark" ), WID_PAGE_ISDARK, &::getBooleanCppuType(), beans::PropertyAttribute::READONLY, 0}, \
{ MAP_CHAR_LEN("NavigationOrder"), WID_NAVORDER, &::com::sun::star::container::XIndexAccess::static_type(),0, 0}, \
- {0,0,0,0,0,0}
+ {0,0,0,0,0,0}
static const SfxItemPropertyMapEntry aGraphicPagePropertyMap_Impl[] =
{
{ MAP_CHAR_LEN(UNO_NAME_PAGE_BACKGROUND), WID_PAGE_BACK, &ITYPE( beans::XPropertySet), beans::PropertyAttribute::MAYBEVOID,0},
GRAPHIC_PAGE_PROPERTIES
};
- static const SfxItemPropertyMapEntry aGraphicPagePropertyNoBackMap_Impl[] =
+ static const SfxItemPropertyMapEntry aGraphicPagePropertyNoBackMap_Impl[] =
{
GRAPHIC_PAGE_PROPERTIES
};
- //
bool bWithoutBackground = ePageKind != PK_STANDARD && ePageKind != PK_HANDOUT;
- const SvxItemPropertySet* pRet = 0;
+ const SvxItemPropertySet* pRet = 0;
if( bImpress )
{
if( ePageKind == PK_STANDARD )
{
//PK_STANDARD always has a background property
static SvxItemPropertySet aDrawPagePropertySet_Impl( aDrawPagePropertyMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aDrawPagePropertySet_Impl;
+ pRet = &aDrawPagePropertySet_Impl;
}
else
{
if(bWithoutBackground)
{
static SvxItemPropertySet aDrawPageNotesHandoutPropertyNoBackSet_Impl( aDrawPageNotesHandoutPropertyNoBackMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aDrawPageNotesHandoutPropertyNoBackSet_Impl;
- }
+ pRet = &aDrawPageNotesHandoutPropertyNoBackSet_Impl;
+ }
else
{
static SvxItemPropertySet aDrawPageNotesHandoutPropertySet_Impl( aDrawPageNotesHandoutPropertyMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aDrawPageNotesHandoutPropertySet_Impl;
- }
+ pRet = &aDrawPageNotesHandoutPropertySet_Impl;
+ }
}
}
else
@@ -273,13 +267,13 @@ const SvxItemPropertySet* ImplGetDrawPagePropertySet( sal_Bool bImpress, PageKin
if(bWithoutBackground)
{
static SvxItemPropertySet aGraphicPagePropertyNoBackSet_Impl( aGraphicPagePropertyNoBackMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aGraphicPagePropertyNoBackSet_Impl;
- }
+ pRet = &aGraphicPagePropertyNoBackSet_Impl;
+ }
else
{
static SvxItemPropertySet aGraphicPagePropertySet_Impl( aGraphicPagePropertyMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aGraphicPagePropertySet_Impl;
- }
+ pRet = &aGraphicPagePropertySet_Impl;
+ }
}
return pRet;
}
@@ -335,30 +329,24 @@ const SvxItemPropertySet* ImplGetMasterPagePropertySet( PageKind ePageKind )
if( ePageKind == PK_HANDOUT )
{
static SvxItemPropertySet aHandoutMasterPagePropertySet_Impl( aHandoutMasterPagePropertyMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aHandoutMasterPagePropertySet_Impl;
+ pRet = &aHandoutMasterPagePropertySet_Impl;
}
else
{
static SvxItemPropertySet aMasterPagePropertySet_Impl( aMasterPagePropertyMap_Impl, SdrObject::GetGlobalDrawObjectItemPool() );
- pRet = &aMasterPagePropertySet_Impl;
+ pRet = &aMasterPagePropertySet_Impl;
}
return pRet;
}
+namespace
+{
+ class theSdGenericDrawPageUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSdGenericDrawPageUnoTunnelId> {};
+}
+
const ::com::sun::star::uno::Sequence< sal_Int8 > & SdGenericDrawPage::getUnoTunnelId() throw()
{
- static ::com::sun::star::uno::Sequence< sal_Int8 > * pSeq = 0;
- if( !pSeq )
- {
- ::osl::Guard< ::osl::Mutex > aGuard( ::osl::Mutex::getGlobalMutex() );
- if( !pSeq )
- {
- static ::com::sun::star::uno::Sequence< sal_Int8 > aSeq( 16 );
- rtl_createUuid( (sal_uInt8*)aSeq.getArray(), 0, sal_True );
- pSeq = &aSeq;
- }
- }
- return *pSeq;
+ return theSdGenericDrawPageUnoTunnelId::get().getSeq();
}
sal_Int64 SAL_CALL SdGenericDrawPage::getSomething( const ::com::sun::star::uno::Sequence< sal_Int8 >& rId ) throw(::com::sun::star::uno::RuntimeException)
@@ -374,9 +362,6 @@ sal_Int64 SAL_CALL SdGenericDrawPage::getSomething( const ::com::sun::star::uno:
}
}
-/***********************************************************************
-* *
-***********************************************************************/
SdGenericDrawPage::SdGenericDrawPage( SdXImpressDocument* _pModel, SdPage* pInPage, const SvxItemPropertySet* _pSet ) throw()
: SvxFmDrawPage( (SdrPage*) pInPage ),
SdUnoSearchReplaceShape(this),
@@ -477,11 +462,7 @@ SdrObject * SdGenericDrawPage::_CreateSdrObject( const Reference< drawing::XShap
}
else if( aType.EqualsAscii( "GraphicObjectShape" ) )
{
-#ifdef STARIMAGE_AVAILABLE
- eObjKind = PRESOBJ_IMAGE;
-#else
eObjKind = PRESOBJ_GRAPHIC;
-#endif
}
else if( aType.EqualsAscii( "OrgChartShape" ) )
{
@@ -592,7 +573,7 @@ Any SAL_CALL SdGenericDrawPage::queryInterface( const uno::Type & rType )
Reference< beans::XPropertySetInfo > SAL_CALL SdGenericDrawPage::getPropertySetInfo()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
return mpPropSet->getPropertySetInfo();
}
@@ -600,7 +581,7 @@ Reference< beans::XPropertySetInfo > SAL_CALL SdGenericDrawPage::getPropertySetI
void SAL_CALL SdGenericDrawPage::setPropertyValue( const OUString& aPropertyName, const Any& aValue )
throw(beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -997,13 +978,10 @@ void SAL_CALL SdGenericDrawPage::setPropertyValue( const OUString& aPropertyName
GetModel()->SetModified();
}
-/***********************************************************************
-* *
-***********************************************************************/
Any SAL_CALL SdGenericDrawPage::getPropertyValue( const OUString& PropertyName )
throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1078,9 +1056,8 @@ Any SAL_CALL SdGenericDrawPage::getPropertyValue( const OUString& PropertyName )
}
case WID_PAGE_LDBITMAP:
{
- sal_Bool bHC = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
Reference< awt::XBitmap > xBitmap(
- VCLUnoHelper::CreateBitmap( BitmapEx( SdResId( bHC ? BMP_PAGE_H : BMP_PAGE ) ) ) );
+ VCLUnoHelper::CreateBitmap( BitmapEx( SdResId( BMP_PAGE ) ) ) );
aAny <<= xBitmap;
}
break;
@@ -1518,14 +1495,14 @@ Reference< container::XNameAccess > SAL_CALL SdGenericDrawPage::getLinks( )
void SdGenericDrawPage::setBackground( const Any& ) throw(lang::IllegalArgumentException)
{
- DBG_ERROR( "Don't call me, I'm useless!" );
+ OSL_FAIL( "Don't call me, I'm useless!" );
}
//----------------------------------------------------------------------
void SdGenericDrawPage::getBackground( Any& ) throw()
{
- DBG_ERROR( "Don't call me, I'm useless!" );
+ OSL_FAIL( "Don't call me, I'm useless!" );
}
//----------------------------------------------------------------------
@@ -1574,7 +1551,7 @@ void SdGenericDrawPage::setBookmarkURL( rtl::OUString& rURL )
Reference< drawing::XShape > SAL_CALL SdGenericDrawPage::combine( const Reference< drawing::XShapes >& xShapes )
throw( uno::RuntimeException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1611,7 +1588,7 @@ Reference< drawing::XShape > SAL_CALL SdGenericDrawPage::combine( const Referenc
void SAL_CALL SdGenericDrawPage::split( const Reference< drawing::XShape >& xGroup )
throw( uno::RuntimeException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1630,7 +1607,7 @@ void SAL_CALL SdGenericDrawPage::split( const Reference< drawing::XShape >& xGro
Reference< drawing::XShape > SAL_CALL SdGenericDrawPage::bind( const Reference< drawing::XShapes >& xShapes )
throw( uno::RuntimeException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1664,7 +1641,7 @@ Reference< drawing::XShape > SAL_CALL SdGenericDrawPage::bind( const Reference<
void SAL_CALL SdGenericDrawPage::unbind( const Reference< drawing::XShape >& xShape )
throw( uno::RuntimeException )
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1878,7 +1855,7 @@ void SdGenericDrawPage::disposing() throw()
// XAnimationNodeSupplier
Reference< XAnimationNode > SAL_CALL SdGenericDrawPage::getAnimationNode() throw (uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -1912,7 +1889,7 @@ uno::Type SAL_CALL SdPageLinkTargets::getElementType()
sal_Bool SAL_CALL SdPageLinkTargets::hasElements()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
SdPage* pPage = mpUnoPage->GetPage();
if( pPage != NULL )
@@ -1939,7 +1916,7 @@ sal_Bool SAL_CALL SdPageLinkTargets::hasElements()
Any SAL_CALL SdPageLinkTargets::getByName( const OUString& aName )
throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
SdPage* pPage = mpUnoPage->GetPage();
if( pPage != NULL )
@@ -1958,7 +1935,7 @@ Any SAL_CALL SdPageLinkTargets::getByName( const OUString& aName )
Sequence< OUString > SAL_CALL SdPageLinkTargets::getElementNames()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
sal_uInt32 nObjCount = 0;
@@ -2000,14 +1977,11 @@ Sequence< OUString > SAL_CALL SdPageLinkTargets::getElementNames()
sal_Bool SAL_CALL SdPageLinkTargets::hasByName( const OUString& aName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
return FindObject( aName ) != NULL;
}
-/***********************************************************************
-* *
-***********************************************************************/
SdrObject* SdPageLinkTargets::FindObject( const String& rName ) const throw()
{
SdPage* pPage = mpUnoPage->GetPage();
@@ -2102,7 +2076,7 @@ UNO3_GETIMPLEMENTATION2_IMPL( SdDrawPage, SdGenericDrawPage );
// XTypeProvider
Sequence< uno::Type > SAL_CALL SdDrawPage::getTypes() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2148,19 +2122,14 @@ Sequence< uno::Type > SAL_CALL SdDrawPage::getTypes() throw(uno::RuntimeExceptio
return maTypeSequence;
}
-Sequence< sal_Int8 > SAL_CALL SdDrawPage::getImplementationId() throw(uno::RuntimeException)
+namespace
{
- OGuard aGuard( Application::GetSolarMutex() );
-
- throwIfDisposed();
+ class theSdDrawPageImplementationId : public rtl::Static< UnoTunnelIdInit, theSdDrawPageImplementationId > {};
+}
- static Sequence< sal_Int8 > aId;
- if( aId.getLength() == 0 )
- {
- aId.realloc( 16 );
- rtl_createUuid( (sal_uInt8 *)aId.getArray(), 0, sal_True );
- }
- return aId;
+Sequence< sal_Int8 > SAL_CALL SdDrawPage::getImplementationId() throw(uno::RuntimeException)
+{
+ return theSdDrawPageImplementationId::get().getSeq();
}
OUString SdDrawPage::getPageApiName( SdPage* pPage )
@@ -2266,7 +2235,7 @@ OUString SAL_CALL SdDrawPage::getImplementationName() throw(uno::RuntimeExceptio
Sequence< OUString > SAL_CALL SdDrawPage::getSupportedServiceNames() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2289,7 +2258,7 @@ sal_Bool SAL_CALL SdDrawPage::supportsService( const OUString& ServiceName )
void SAL_CALL SdDrawPage::setName( const OUString& rName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2349,7 +2318,7 @@ void SAL_CALL SdDrawPage::setName( const OUString& rName )
::sd::ViewShell* pViewSh = pDocSh ? pDocSh->GetViewShell() : NULL;
if( pViewSh && pViewSh->ISA(::sd::DrawViewShell))
{
- ::sd::DrawViewShell* pDrawViewSh = static_cast<
+ ::sd::DrawViewShell* pDrawViewSh = static_cast<
::sd::DrawViewShell*>(pViewSh);
EditMode eMode = pDrawViewSh->GetEditMode();
@@ -2369,7 +2338,7 @@ void SAL_CALL SdDrawPage::setName( const OUString& rName )
OUString SAL_CALL SdDrawPage::getName()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2380,7 +2349,7 @@ OUString SAL_CALL SdDrawPage::getName()
Reference< drawing::XDrawPage > SAL_CALL SdDrawPage::getMasterPage( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2403,7 +2372,7 @@ Reference< drawing::XDrawPage > SAL_CALL SdDrawPage::getMasterPage( )
void SAL_CALL SdDrawPage::setMasterPage( const Reference< drawing::XDrawPage >& xMasterPage )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2442,7 +2411,7 @@ void SAL_CALL SdDrawPage::setMasterPage( const Reference< drawing::XDrawPage >&
Reference< drawing::XDrawPage > SAL_CALL SdDrawPage::getNotesPage()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2493,7 +2462,7 @@ void SAL_CALL SdDrawPage::add( const Reference< drawing::XShape >& xShape ) thro
void SAL_CALL SdDrawPage::remove( const Reference< drawing::XShape >& xShape ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2560,7 +2529,6 @@ void SdDrawPage::setBackground( const Any& rValue )
pBackground->fillItemSet( (SdDrawDocument*)GetPage()->GetModel(), aSet );
}
-//-/ pObj->NbcSetAttributes( aSet, sal_False );
if( aSet.Count() == 0 )
{
// no background fill, represent by setting XFILL_NONE
@@ -2575,7 +2543,6 @@ void SdDrawPage::setBackground( const Any& rValue )
// repaint only
SvxFmDrawPage::mpPage->ActionChanged();
- // pPage->SendRepaintBroadcast();
}
// XAnnotationAccess:
@@ -2612,7 +2579,7 @@ void SdDrawPage::getBackground( Any& rValue ) throw()
{
// there is a fill set, export to rValue
Reference< beans::XPropertySet > xSet(new SdUnoPageBackground(
- GetModel()->GetDoc(),
+ GetModel()->GetDoc(),
&GetPage()->getSdrPageProperties().GetItemSet()));
rValue <<= xSet;
}
@@ -2727,7 +2694,7 @@ SdMasterPage::~SdMasterPage() throw()
Any SAL_CALL SdMasterPage::queryInterface( const uno::Type & rType )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2764,7 +2731,7 @@ UNO3_GETIMPLEMENTATION2_IMPL( SdMasterPage, SdGenericDrawPage );
// XTypeProvider
Sequence< uno::Type > SAL_CALL SdMasterPage::getTypes() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2784,7 +2751,7 @@ Sequence< uno::Type > SAL_CALL SdMasterPage::getTypes() throw(uno::RuntimeExcept
aTypes.push_back(ITYPE(document::XLinkTargetSupplier));
aTypes.push_back(ITYPE( drawing::XShapeCombiner ));
aTypes.push_back(ITYPE( drawing::XShapeBinder ));
- aTypes.push_back(ITYPE( office::XAnnotationAccess ));
+ aTypes.push_back(ITYPE( office::XAnnotationAccess ));
aTypes.push_back(ITYPE( beans::XMultiPropertySet ));
if( bPresPage )
aTypes.push_back(ITYPE(presentation::XPresentationPage));
@@ -2809,19 +2776,14 @@ Sequence< uno::Type > SAL_CALL SdMasterPage::getTypes() throw(uno::RuntimeExcept
return maTypeSequence;
}
-Sequence< sal_Int8 > SAL_CALL SdMasterPage::getImplementationId() throw(uno::RuntimeException)
+namespace
{
- OGuard aGuard( Application::GetSolarMutex() );
-
- throwIfDisposed();
+ class theSdMasterPageImplementationId : public rtl::Static< UnoTunnelIdInit, theSdMasterPageImplementationId > {};
+}
- static Sequence< sal_Int8 > aId;
- if( aId.getLength() == 0 )
- {
- aId.realloc( 16 );
- rtl_createUuid( (sal_uInt8 *)aId.getArray(), 0, sal_True );
- }
- return aId;
+Sequence< sal_Int8 > SAL_CALL SdMasterPage::getImplementationId() throw(uno::RuntimeException)
+{
+ return theSdMasterPageImplementationId::get().getSeq();
}
// XServiceInfo
@@ -2832,7 +2794,7 @@ OUString SAL_CALL SdMasterPage::getImplementationName() throw(uno::RuntimeExcept
Sequence< OUString > SAL_CALL SdMasterPage::getSupportedServiceNames() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2854,7 +2816,7 @@ sal_Bool SAL_CALL SdMasterPage::supportsService( const OUString& ServiceName )
// XElementAccess
sal_Bool SAL_CALL SdMasterPage::hasElements() throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2874,7 +2836,7 @@ uno::Type SAL_CALL SdMasterPage::getElementType()
sal_Int32 SAL_CALL SdMasterPage::getCount()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2884,7 +2846,7 @@ sal_Int32 SAL_CALL SdMasterPage::getCount()
Any SAL_CALL SdMasterPage::getByIndex( sal_Int32 Index )
throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -2916,7 +2878,7 @@ void SdMasterPage::setBackground( const Any& rValue )
Reference< beans::XPropertyState > xSetStates( xInputSet, UNO_QUERY );
PropertyEntryVector_t aBackgroundProperties = ImplGetPageBackgroundPropertySet()->getPropertyMap()->getPropertyEntries();
- PropertyEntryVector_t::const_iterator aIt = aBackgroundProperties.begin();
+ PropertyEntryVector_t::const_iterator aIt = aBackgroundProperties.begin();
while( aIt != aBackgroundProperties.end() )
{
if( xSetInfo->hasPropertyByName( aIt->sName ) )
@@ -2994,7 +2956,7 @@ void SdMasterPage::setBackground( const Any& rValue )
}
catch( Exception& )
{
- DBG_ERROR("sd::SdMasterPage::setBackground(), exception caught!");
+ OSL_FAIL("sd::SdMasterPage::setBackground(), exception caught!");
}
}
@@ -3050,7 +3012,7 @@ void SdMasterPage::getBackground( Any& rValue ) throw()
catch( Exception& )
{
rValue.clear();
- DBG_ERROR("sd::SdMasterPage::getBackground(), exception caught!");
+ OSL_FAIL("sd::SdMasterPage::getBackground(), exception caught!");
}
}
@@ -3058,7 +3020,7 @@ void SdMasterPage::getBackground( Any& rValue ) throw()
void SAL_CALL SdMasterPage::setName( const OUString& aName )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -3075,7 +3037,7 @@ void SAL_CALL SdMasterPage::setName( const OUString& aName )
::sd::ViewShell* pViewSh = pDocSh ? pDocSh->GetViewShell() : NULL;
if( pViewSh && pViewSh->ISA(::sd::DrawViewShell ) )
{
- ::sd::DrawViewShell* pDrawViewSh =
+ ::sd::DrawViewShell* pDrawViewSh =
static_cast< ::sd::DrawViewShell*>(pViewSh);
EditMode eMode = pDrawViewSh->GetEditMode();
@@ -3095,7 +3057,7 @@ void SAL_CALL SdMasterPage::setName( const OUString& aName )
OUString SAL_CALL SdMasterPage::getName( )
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -3114,7 +3076,7 @@ OUString SAL_CALL SdMasterPage::getName( )
Reference< drawing::XDrawPage > SAL_CALL SdMasterPage::getNotesPage()
throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -3138,7 +3100,7 @@ void SAL_CALL SdMasterPage::add( const Reference< drawing::XShape >& xShape ) th
void SAL_CALL SdMasterPage::remove( const Reference< drawing::XShape >& xShape ) throw(uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aGuard;
throwIfDisposed();
@@ -3179,3 +3141,5 @@ Reference< uno::XInterface > createUnoPageImpl( SdPage* pPage )
return xPage;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unopage.hxx b/sd/source/ui/unoidl/unopage.hxx
index b50a1281f..a203bf708 100755..100644
--- a/sd/source/ui/unoidl/unopage.hxx
+++ b/sd/source/ui/unoidl/unopage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,9 +39,7 @@
#include <svl/itemprop.hxx>
-#ifndef _SVX_UNOPAGE_HXX
#include <svx/unopage.hxx>
-#endif
#include <svx/fmdpage.hxx>
#include <svx/svdpool.hxx>
@@ -53,10 +52,6 @@ class SvxShape;
class SdrObject;
struct SfxItemPropertySimpleEntry;
-#ifdef SVX_LIGHT
-#define SvxFmDrawPage SvxDrawPage
-#endif
-
/***********************************************************************
* *
***********************************************************************/
@@ -317,3 +312,5 @@ public:
};
#endif // _SD_UNOPAGE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unopback.cxx b/sd/source/ui/unoidl/unopback.cxx
index acfc05b64..63420744e 100644
--- a/sd/source/ui/unoidl/unopback.cxx
+++ b/sd/source/ui/unoidl/unopback.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
#include <com/sun/star/drawing/BitmapMode.hpp>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
#include <svl/itemset.hxx>
#include <svx/svdpool.hxx>
#include <comphelper/extract.hxx>
-#include <rtl/uuid.h>
#include <rtl/memory.h>
#include <svx/xflbstit.hxx>
#include <svx/xflbmtit.hxx>
@@ -48,7 +48,6 @@
#include "unokywds.hxx"
using namespace ::rtl;
-using namespace ::vos;
using namespace ::com::sun::star;
const SvxItemPropertySet* ImplGetPageBackgroundPropertySet()
@@ -226,7 +225,7 @@ uno::Reference< beans::XPropertySetInfo > SAL_CALL SdUnoPageBackground::getPrope
void SAL_CALL SdUnoPageBackground::setPropertyValue( const OUString& aPropertyName, const uno::Any& aValue )
throw(beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry( aPropertyName );
@@ -283,7 +282,7 @@ void SAL_CALL SdUnoPageBackground::setPropertyValue( const OUString& aPropertyNa
uno::Any SAL_CALL SdUnoPageBackground::getPropertyValue( const OUString& PropertyName )
throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
uno::Any aAny;
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry(PropertyName);
@@ -342,7 +341,7 @@ void SAL_CALL SdUnoPageBackground::removeVetoableChangeListener( const OUString&
beans::PropertyState SAL_CALL SdUnoPageBackground::getPropertyState( const OUString& PropertyName )
throw(beans::UnknownPropertyException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry(PropertyName);
@@ -389,7 +388,7 @@ beans::PropertyState SAL_CALL SdUnoPageBackground::getPropertyState( const OUStr
uno::Sequence< beans::PropertyState > SAL_CALL SdUnoPageBackground::getPropertyStates( const uno::Sequence< OUString >& aPropertyName )
throw(beans::UnknownPropertyException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
sal_Int32 nCount = aPropertyName.getLength();
const OUString* pNames = aPropertyName.getConstArray();
@@ -406,7 +405,7 @@ uno::Sequence< beans::PropertyState > SAL_CALL SdUnoPageBackground::getPropertyS
void SAL_CALL SdUnoPageBackground::setPropertyToDefault( const OUString& PropertyName )
throw(beans::UnknownPropertyException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry(PropertyName);
@@ -430,7 +429,7 @@ void SAL_CALL SdUnoPageBackground::setPropertyToDefault( const OUString& Propert
uno::Any SAL_CALL SdUnoPageBackground::getPropertyDefault( const OUString& aPropertyName )
throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = getPropertyMapEntry(aPropertyName);
if( pEntry == NULL || mpSet == NULL )
@@ -461,3 +460,4 @@ const SfxItemPropertySimpleEntry* SdUnoPageBackground::getPropertyMapEntry( cons
return mpPropSet->getPropertyMap()->getByName(rPropertyName);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unopback.hxx b/sd/source/ui/unoidl/unopback.hxx
index b344e532c..569af0a37 100644
--- a/sd/source/ui/unoidl/unopback.hxx
+++ b/sd/source/ui/unoidl/unopback.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unopool.cxx b/sd/source/ui/unoidl/unopool.cxx
index 4f223c8f1..d3c4fdf2e 100755..100644
--- a/sd/source/ui/unoidl/unopool.cxx
+++ b/sd/source/ui/unoidl/unopool.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,5 @@ uno::Reference< uno::XInterface > SdUnoCreatePool( SdDrawDocument* pDrawModel )
{
return (uno::XAggregation*)new SdUnoDrawPool( pDrawModel );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unosrch.cxx b/sd/source/ui/unoidl/unosrch.cxx
index bdfe218ca..58b8f2259 100755..100644
--- a/sd/source/ui/unoidl/unosrch.cxx
+++ b/sd/source/ui/unoidl/unosrch.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,7 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <svx/unoshape.hxx>
#include <svx/svdpool.hxx>
@@ -36,14 +37,12 @@
#include <editeng/unotext.hxx>
#include <comphelper/extract.hxx>
-#include <rtl/uuid.h>
#include <rtl/memory.h>
#include "unohelp.hxx"
#include "unoprnms.hxx"
#include "unosrch.hxx"
-using namespace ::vos;
using namespace ::rtl;
using namespace ::com::sun::star;
@@ -493,7 +492,7 @@ uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Refere
sal_Int32* pConvertPara = new sal_Int32[nTextLen+2];
int ndbg = 0;
- const sal_Unicode* pText = aText;
+ const sal_Unicode* pText = aText.getStr();
sal_Int32* pPos = pConvertPos;
sal_Int32* pPara = pConvertPara;
@@ -547,7 +546,7 @@ uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Refere
}
else
{
- DBG_ERROR( "array overflow while searching" );
+ OSL_FAIL( "array overflow while searching" );
}
}
@@ -568,7 +567,7 @@ uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Refere
}
else
{
- DBG_ERROR( "array overflow while searching" );
+ OSL_FAIL( "array overflow while searching" );
}
}
@@ -591,7 +590,7 @@ uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Refere
}
else
{
- DBG_ERROR( "array overflow while searching" );
+ OSL_FAIL( "array overflow while searching" );
}
}
}
@@ -627,12 +626,11 @@ uno::Reference< text::XTextRange > SdUnoSearchReplaceShape::Search( uno::Refere
xFound = (text::XText*)pRange;
pRange->SetSelection(aSelection);
-// pDescr->SetStartPos( nEndPos );
}
}
else
{
- DBG_ERROR("Array overflow while searching!");
+ OSL_FAIL("Array overflow while searching!");
}
}
@@ -767,14 +765,14 @@ void SAL_CALL SdUnoSearchReplaceDescriptor::setReplaceString( const ::rtl::OUStr
uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL SdUnoSearchReplaceDescriptor::getPropertySetInfo()
throw(::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
return mpPropSet->getPropertySetInfo();
}
void SAL_CALL SdUnoSearchReplaceDescriptor::setPropertyValue( const ::rtl::OUString& aPropertyName, const ::com::sun::star::uno::Any& aValue )
throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
const SfxItemPropertySimpleEntry* pEntry = mpPropSet->getPropertyMapEntry(aPropertyName);
@@ -802,7 +800,7 @@ void SAL_CALL SdUnoSearchReplaceDescriptor::setPropertyValue( const ::rtl::OUStr
uno::Any SAL_CALL SdUnoSearchReplaceDescriptor::getPropertyValue( const ::rtl::OUString& PropertyName )
throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
- OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
uno::Any aAny;
@@ -877,3 +875,4 @@ uno::Any SAL_CALL SdUnoFindAllAccess::getByIndex( sal_Int32 Index )
return aAny;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unowcntr.cxx b/sd/source/ui/unoidl/unowcntr.cxx
index e53d336f7..8973c670a 100755..100644
--- a/sd/source/ui/unoidl/unowcntr.cxx
+++ b/sd/source/ui/unoidl/unowcntr.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -28,68 +29,62 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
#include <com/sun/star/lang/XComponent.hpp>
-#include <tools/list.hxx>
#include <unowcntr.hxx>
using namespace ::rtl;
using namespace ::com::sun::star;
-DECLARE_LIST( WeakRefList, uno::WeakReference< uno::XInterface >* )
-
SvUnoWeakContainer::SvUnoWeakContainer() throw()
{
- mpList = new WeakRefList;
}
SvUnoWeakContainer::~SvUnoWeakContainer() throw()
{
- uno::WeakReference< uno::XInterface >* pRef = mpList->First();
- while( pRef )
- {
- delete mpList->Remove();
- pRef = mpList->GetCurObject();
- }
- delete mpList;
+ for ( WeakRefList::iterator it = maList.begin(); it != maList.end(); ++it )
+ delete *it;
+ maList.clear();
}
/** inserts the given ref into this container */
void SvUnoWeakContainer::insert( uno::WeakReference< uno::XInterface > xRef ) throw()
{
- uno::WeakReference< uno::XInterface >* pRef = mpList->First();
- while( pRef )
+ for ( WeakRefList::iterator it = maList.begin(); it != maList.end(); )
{
- ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > xTestRef( *pRef );
- if(! xTestRef.is() )
+ uno::WeakReference< uno::XInterface >* pRef = *it;
+ uno::Reference< uno::XInterface > xTestRef( *pRef );
+ if ( !xTestRef.is() )
{
- delete mpList->Remove();
- pRef = mpList->GetCurObject();
+ delete pRef;
+ it = maList.erase( it );
}
else
{
- if( *pRef == xRef )
+ if ( *pRef == xRef )
return;
-
- pRef = mpList->Next();
+ ++it;
}
}
-
- mpList->Insert( new uno::WeakReference< uno::XInterface >( xRef ) );
+ maList.push_back( new uno::WeakReference< uno::XInterface >( xRef ) );
}
-/** searches the container for a ref that returns true on the given
+/** searches the container for a ref that returns true on the given
search function
*/
-sal_Bool SvUnoWeakContainer::findRef( uno::WeakReference< uno::XInterface >& rRef, void* pSearchData, weakref_searchfunc pSearchFunc )
+sal_Bool SvUnoWeakContainer::findRef(
+ uno::WeakReference< uno::XInterface >& rRef,
+ void* pSearchData,
+ weakref_searchfunc pSearchFunc
+)
{
- uno::WeakReference< uno::XInterface >* pRef = mpList->First();
- while( pRef )
+ for ( WeakRefList::iterator it = maList.begin(); it != maList.end(); )
{
- uno::Reference< ::com::sun::star::uno::XInterface > xTestRef( *pRef );
- if(!xTestRef.is())
+ uno::WeakReference< uno::XInterface >* pRef = *it;
+ uno::Reference< uno::XInterface > xTestRef( *pRef );
+ if ( !xTestRef.is() )
{
- delete mpList->Remove();
- pRef = mpList->GetCurObject();
+ delete pRef;
+ it = maList.erase( it );
}
else
{
@@ -98,28 +93,25 @@ sal_Bool SvUnoWeakContainer::findRef( uno::WeakReference< uno::XInterface >& rRe
rRef = *pRef;
return sal_True;
}
-
- pRef = mpList->Next();
+ ++it;
}
}
-
return sal_False;
}
void SvUnoWeakContainer::dispose()
{
- uno::WeakReference< uno::XInterface >* pRef = mpList->First();
- while( pRef )
+ for ( WeakRefList::iterator it = maList.begin(); it != maList.end(); ++it )
{
+ uno::WeakReference< uno::XInterface >* pRef = *it;
uno::Reference< uno::XInterface > xTestRef( *pRef );
- if(xTestRef.is())
+ if ( xTestRef.is() )
{
uno::Reference< lang::XComponent > xComp( xTestRef, uno::UNO_QUERY );
if( xComp.is() )
xComp->dispose();
}
-
- pRef = mpList->Next();
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/unoidl/unowcntr.hxx b/sd/source/ui/unoidl/unowcntr.hxx
index 5276015ee..26d1ad4e5 100755..100644
--- a/sd/source/ui/unoidl/unowcntr.hxx
+++ b/sd/source/ui/unoidl/unowcntr.hxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -29,30 +30,32 @@
#define _SV_UNOWCNTR_HXX_
#include <cppuhelper/weakref.hxx>
+#include <list>
typedef sal_Bool (*weakref_searchfunc)( ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface > xRef, void* pSearchData );
-class WeakRefList;
+typedef ::std::list< ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface >* > WeakRefList;
class SvUnoWeakContainer
{
private:
- WeakRefList* mpList;
+ WeakRefList maList;
public:
SvUnoWeakContainer() throw();
~SvUnoWeakContainer() throw();
/** inserts the given ref into this container */
- void insert( ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface > xRef ) throw();
+ void insert( ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface > xRef ) throw();
- /** searches the container for a ref that returns true on the given
+ /** searches the container for a ref that returns true on the given
search function
*/
- sal_Bool findRef( ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface >& rRef, void* pSearchData, weakref_searchfunc pSearchFunc );
+ sal_Bool findRef( ::com::sun::star::uno::WeakReference< ::com::sun::star::uno::XInterface >& rRef, void* pSearchData, weakref_searchfunc pSearchFunc );
void dispose();
};
#endif // _SV_UNOWCNTR_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/DocumentRenderer.cxx b/sd/source/ui/view/DocumentRenderer.cxx
index b836ebb83..758e5ed85 100755..100644
--- a/sd/source/ui/view/DocumentRenderer.cxx
+++ b/sd/source/ui/view/DocumentRenderer.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -268,8 +269,8 @@ namespace {
{
public:
Selection (const OUString& rsSelection, const SdPage* pCurrentPage)
- : mbAreAllPagesSelected(rsSelection.equalsAscii("all")),
- mbIsShapeSelection(rsSelection.equalsAscii("selection")),
+ : mbAreAllPagesSelected(rsSelection.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("all"))),
+ mbIsShapeSelection(rsSelection.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("selection"))),
mnCurrentPageIndex(pCurrentPage!=NULL ? (pCurrentPage->GetPageNum()-1)/2 : -1),
mpSelectedPages()
{
@@ -433,7 +434,7 @@ namespace {
SvtModuleOptions aOpt;
String aAppGroupname( String( SdResId( _STR_IMPRESS_PRINT_UI_GROUP_NAME ) ) );
aAppGroupname.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%s" ) ),
- aOpt.GetModuleName( mbImpress ? SvtModuleOptions::E_SIMPRESS : SvtModuleOptions::E_SDRAW ) );
+ aOpt.GetModuleName( mbImpress ? SvtModuleOptions::E_SIMPRESS : SvtModuleOptions::E_SDRAW ) );
AddDialogControl( vcl::PrinterOptionsHelper::getGroupControlOpt(
aAppGroupname,
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".HelpID:vcl:PrintDialog:TabPage:AppPage" ) )
@@ -461,10 +462,10 @@ namespace {
OUString( RTL_CONSTASCII_USTRINGPARAM( "List" ) )
)
);
-
+
aHelpIds[0] = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".HelpID:vcl:PrintDialog:SlidesPerPage:ListBox" ) );
vcl::PrinterOptionsHelper::UIControlOptions
- aContentOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PageContentType" ) ), 1 );
+ aContentOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PageContentType" ) ), 1 );
AddDialogControl( vcl::PrinterOptionsHelper::getChoiceControlOpt(
String( SdResId( _STR_IMPRESS_PRINT_UI_SLIDESPERPAGE ) ),
aHelpIds,
@@ -476,10 +477,10 @@ namespace {
aContentOpt
)
);
-
+
aHelpIds[0] = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".HelpID:vcl:PrintDialog:SlidesPerPageOrder:ListBox" ) );
vcl::PrinterOptionsHelper::UIControlOptions
- aSlidesPerPageOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "SlidesPerPage" ) ), -1, sal_True );
+ aSlidesPerPageOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "SlidesPerPage" ) ), -1, sal_True );
AddDialogControl( vcl::PrinterOptionsHelper::getChoiceControlOpt(
String( SdResId( _STR_IMPRESS_PRINT_UI_ORDER ) ),
aHelpIds,
@@ -497,7 +498,7 @@ namespace {
if( mbImpress )
- {
+ {
AddDialogControl( vcl::PrinterOptionsHelper::getBoolControlOpt(
String( SdResId(_STR_IMPRESS_PRINT_UI_IS_PRINT_NAME) ),
OUString( RTL_CONSTASCII_USTRINGPARAM( ".HelpID:vcl:PrintDialog:IsPrintName:CheckBox" ) ),
@@ -564,7 +565,7 @@ namespace {
{
// FIXME: additional dependency on PrintProspect = false
vcl::PrinterOptionsHelper::UIControlOptions
- aPageOptionsOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PageContentType" ) ), 0 );
+ aPageOptionsOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PageContentType" ) ), 0 );
AddDialogControl( vcl::PrinterOptionsHelper::getChoiceControlOpt(
rtl::OUString(),
aHelpIds,
@@ -580,7 +581,7 @@ namespace {
else
{
vcl::PrinterOptionsHelper::UIControlOptions
- aPageOptionsOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PrintProspect" ) ), sal_False );
+ aPageOptionsOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PrintProspect" ) ), sal_False );
AddDialogControl( vcl::PrinterOptionsHelper::getChoiceControlOpt(
rtl::OUString(),
aHelpIds,
@@ -595,7 +596,7 @@ namespace {
}
vcl::PrinterOptionsHelper::UIControlOptions aBrochureOpt;
- aBrochureOpt.maGroupHint = OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutPage" ) );
+ aBrochureOpt.maGroupHint = OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutPage" ) );
AddDialogControl( vcl::PrinterOptionsHelper::getSubgroupControlOpt(
String( SdResId(_STR_IMPRESS_PRINT_UI_PAGE_SIDES) ), rtl::OUString(),
aBrochureOpt ) );
@@ -611,7 +612,7 @@ namespace {
);
vcl::PrinterOptionsHelper::UIControlOptions
- aIncludeOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PrintProspect" ) ), -1, sal_False );
+ aIncludeOpt( OUString( RTL_CONSTASCII_USTRINGPARAM( "PrintProspect" ) ), -1, sal_False );
aIncludeOpt.maGroupHint = OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutPage" ) );
aHelpIds.realloc( 1 );
aHelpIds[0] = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".HelpID:vcl:PrintDialog:PrintProspectInclude:ListBox" ) );
@@ -642,12 +643,12 @@ namespace {
vcl::PrinterOptionsHelper::UIControlOptions aPrintRangeOpt;
aPrintRangeOpt.mbInternalOnly = sal_True;
aPrintRangeOpt.maGroupHint = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "PrintRange" ) );
- AddDialogControl( vcl::PrinterOptionsHelper::getSubgroupControlOpt(
+ AddDialogControl( vcl::PrinterOptionsHelper::getSubgroupControlOpt(
String( SdResId( _STR_IMPRESS_PRINT_UI_PAGE_RANGE ) ),
rtl::OUString(),
aPrintRangeOpt )
);
-
+
// create a choice for the content to create
rtl::OUString aPrintRangeName( RTL_CONSTASCII_USTRINGPARAM( "PrintContent" ) );
aHelpIds.realloc( 3 );
@@ -669,7 +670,7 @@ namespace {
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "PageRange" ) ),
rtl::OUString(),
aPageRangeOpt )
- );
+ );
FreeResource();
}
@@ -1237,8 +1238,8 @@ public:
}
-
-
+
+
virtual ~Implementation (void)
{
EndListening(mrBase);
@@ -1361,7 +1362,7 @@ public:
::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell()));
if ( ! mpPrintView)
- mpPrintView.reset(new DrawView(mrBase.GetDocShell(), &rPrinter, pDrawViewShell.get()));
+ mpPrintView.reset(new DrawView(mrBase.GetDocShell(), &rPrinter, NULL));
if (nIndex<0 || sal::static_int_cast<sal_uInt32>(nIndex)>=maPrinterPages.size())
return;
@@ -1608,7 +1609,7 @@ private:
// delete all previous shapes from handout page
while( pHandout->GetObjCount() )
{
- SdrObject* pObj = pHandout->NbcRemoveObject(0);
+ SdrObject* pObj = pHandout->NbcRemoveObject(0);
if( pObj )
SdrObject::Free( pObj );
}
@@ -1708,8 +1709,8 @@ private:
}
-
-
+
+
/** Prepare the outline of the document for printing. There is no fixed
number of slides whose outline data is put onto one printer page.
If the current printer page has enough room for the outline of the
@@ -2074,13 +2075,11 @@ private:
// Bugfix zu 44530:
// Falls implizit umgestellt wurde (Landscape/Portrait)
// wird dies beim Kacheln, bzw. aufteilen (Poster) beruecksichtigt
- sal_Bool bSwitchPageSize = sal_False;
if( ( rInfo.maPrintSize.Width() > rInfo.maPrintSize.Height()
&& aPageWidth < aPageHeight )
|| ( rInfo.maPrintSize.Width() < rInfo.maPrintSize.Height()
&& aPageWidth > aPageHeight ) )
{
- bSwitchPageSize = sal_True;
const sal_Int32 nTmp (rInfo.maPrintSize.Width());
rInfo.maPrintSize.Width() = rInfo.maPrintSize.Height();
rInfo.maPrintSize.Height() = nTmp;
@@ -2253,7 +2252,7 @@ private:
rInfo.mnDrawMode,
rInfo.meOrientation,
nPaperBin)));
- }
+ }
@@ -2291,12 +2290,6 @@ private:
// if CutPage is set then do not move it, otherwise move the
// scaled page to printable area
- #if 0
- if (bCutPage)
- aMap.SetOrigin(Point(-aPageOffset.X(), -aPageOffset.Y()));
- else
- aMap.SetOrigin(Point(0,0));
- #endif
maPrinterPages.push_back(
::boost::shared_ptr<PrinterPage>(
new RegularPrinterPage(
@@ -2321,13 +2314,9 @@ private:
rInfo.maPageSize.Width() - rPage.GetLftBorder() - rPage.GetRgtBorder());
const long nPageHeight (
rInfo.maPageSize.Height() - rPage.GetUppBorder() - rPage.GetLwrBorder());
- #if 0
- Point aOrigin (
- nPageWidth < rInfo.maPrintSize.Width() ? -aPageOffset.X() : 0,
- nPageHeight < rInfo.maPrintSize.Height() ? -aPageOffset.Y() : 0);
- #else
+
Point aOrigin ( 0, 0 );
- #endif
+
for (Point aPageOrigin = aOrigin;
-aPageOrigin.Y()<nPageHeight;
aPageOrigin.Y() -= rInfo.maPrintSize.Height())
@@ -2420,3 +2409,5 @@ void SAL_CALL DocumentRenderer::render (
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/DocumentRenderer.src b/sd/source/ui/view/DocumentRenderer.src
index 6815b34ac..6815b34ac 100755..100644
--- a/sd/source/ui/view/DocumentRenderer.src
+++ b/sd/source/ui/view/DocumentRenderer.src
diff --git a/sd/source/ui/view/FormShellManager.cxx b/sd/source/ui/view/FormShellManager.cxx
index fc3005699..2bd3d9541 100644
--- a/sd/source/ui/view/FormShellManager.cxx
+++ b/sd/source/ui/view/FormShellManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,70 +158,62 @@ FmFormShell* FormShellManager::GetFormShell (void)
void FormShellManager::RegisterAtCenterPane (void)
{
- do
- {
- ViewShell* pShell = mrBase.GetMainViewShell().get();
- if (pShell == NULL)
- break;
+ ViewShell* pShell = mrBase.GetMainViewShell().get();
+ if (pShell == NULL)
+ return;
+
+ // No form shell for the slide sorter. Besides that it is not
+ // necessary, using both together results in crashes.
+ if (pShell->GetShellType() == ViewShell::ST_SLIDE_SORTER)
+ return;
+
+ mpMainViewShellWindow = pShell->GetActiveWindow();
+ if (mpMainViewShellWindow == NULL)
+ return;
+
+ // Register at the window to get informed when to move the form
+ // shell to the bottom of the shell stack.
+ mpMainViewShellWindow->AddEventListener(
+ LINK(
+ this,
+ FormShellManager,
+ WindowEventHandler));
+
+ // Create a shell factory and with it activate the form shell.
+ OSL_ASSERT(mpSubShellFactory.get()==NULL);
+ mpSubShellFactory.reset(new FormShellManagerFactory(*pShell, *this));
+ mrBase.GetViewShellManager()->AddSubShellFactory(pShell,mpSubShellFactory);
+ mrBase.GetViewShellManager()->ActivateSubShell(*pShell, RID_FORMLAYER_TOOLBOX);
+}
- // No form shell for the slide sorter. Besides that it is not
- // necessary, using both together results in crashes.
- if (pShell->GetShellType() == ViewShell::ST_SLIDE_SORTER)
- break;
- mpMainViewShellWindow = pShell->GetActiveWindow();
- if (mpMainViewShellWindow == NULL)
- break;
- // Register at the window to get informed when to move the form
- // shell to the bottom of the shell stack.
- mpMainViewShellWindow->AddEventListener(
+
+void FormShellManager::UnregisterAtCenterPane (void)
+{
+ if (mpMainViewShellWindow != NULL)
+ {
+ // Unregister from the window.
+ mpMainViewShellWindow->RemoveEventListener(
LINK(
this,
FormShellManager,
WindowEventHandler));
-
- // Create a shell factory and with it activate the form shell.
- OSL_ASSERT(mpSubShellFactory.get()==NULL);
- mpSubShellFactory.reset(new FormShellManagerFactory(*pShell, *this));
- mrBase.GetViewShellManager()->AddSubShellFactory(pShell,mpSubShellFactory);
- mrBase.GetViewShellManager()->ActivateSubShell(*pShell, RID_FORMLAYER_TOOLBOX);
+ mpMainViewShellWindow = NULL;
}
- while (false);
-}
-
-
+ // Unregister form at the form shell.
+ SetFormShell(NULL);
-void FormShellManager::UnregisterAtCenterPane (void)
-{
- do
+ // Deactivate the form shell and destroy the shell factory.
+ ViewShell* pShell = mrBase.GetMainViewShell().get();
+ if (pShell != NULL)
{
- if (mpMainViewShellWindow != NULL)
- {
- // Unregister from the window.
- mpMainViewShellWindow->RemoveEventListener(
- LINK(
- this,
- FormShellManager,
- WindowEventHandler));
- mpMainViewShellWindow = NULL;
- }
-
- // Unregister form at the form shell.
- SetFormShell(NULL);
-
- // Deactivate the form shell and destroy the shell factory.
- ViewShell* pShell = mrBase.GetMainViewShell().get();
- if (pShell != NULL)
- {
- mrBase.GetViewShellManager()->DeactivateSubShell(*pShell, RID_FORMLAYER_TOOLBOX);
- mrBase.GetViewShellManager()->RemoveSubShellFactory(pShell, mpSubShellFactory);
- }
-
- mpSubShellFactory.reset();
+ mrBase.GetViewShellManager()->DeactivateSubShell(*pShell, RID_FORMLAYER_TOOLBOX);
+ mrBase.GetViewShellManager()->RemoveSubShellFactory(pShell, mpSubShellFactory);
}
- while (false);
+
+ mpSubShellFactory.reset();
}
@@ -391,3 +384,5 @@ void FormShellManagerFactory::ReleaseShell (SfxShell* pShell)
} // end of anonymous namespace
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/GraphicObjectBar.cxx b/sd/source/ui/view/GraphicObjectBar.cxx
index a53459668..111cee279 100755..100644
--- a/sd/source/ui/view/GraphicObjectBar.cxx
+++ b/sd/source/ui/view/GraphicObjectBar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -183,3 +184,5 @@ void GraphicObjectBar::ExecuteFilter( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/GraphicViewShellBase.cxx b/sd/source/ui/view/GraphicViewShellBase.cxx
index c43abd47e..944269ca5 100755..100644
--- a/sd/source/ui/view/GraphicViewShellBase.cxx
+++ b/sd/source/ui/view/GraphicViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,7 +47,7 @@ TYPEINIT1(GraphicViewShellBase, ViewShellBase);
// new GraphicViewShellBase object has been constructed.
SfxViewFactory* GraphicViewShellBase::pFactory;
-SfxViewShell* __EXPORT GraphicViewShellBase::CreateInstance (
+SfxViewShell* GraphicViewShellBase::CreateInstance (
SfxViewFrame *pFrame, SfxViewShell *pOldView)
{
GraphicViewShellBase* pBase = new GraphicViewShellBase(pFrame, pOldView);
@@ -130,3 +131,4 @@ void GraphicViewShellBase::InitializeFramework (void)
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ImpressViewShellBase.cxx b/sd/source/ui/view/ImpressViewShellBase.cxx
index 02744c0ae..4975cfcc8 100755..100644
--- a/sd/source/ui/view/ImpressViewShellBase.cxx
+++ b/sd/source/ui/view/ImpressViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,7 +47,7 @@ TYPEINIT1(ImpressViewShellBase, ViewShellBase);
// new ImpressViewShellBase object has been constructed.
SfxViewFactory* ImpressViewShellBase::pFactory;
-SfxViewShell* __EXPORT ImpressViewShellBase::CreateInstance (
+SfxViewShell* ImpressViewShellBase::CreateInstance (
SfxViewFrame *pFrame, SfxViewShell *pOldView)
{
ImpressViewShellBase* pBase = new ImpressViewShellBase(pFrame, pOldView);
@@ -120,3 +121,4 @@ void ImpressViewShellBase::InitializeFramework (void)
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/MediaObjectBar.cxx b/sd/source/ui/view/MediaObjectBar.cxx
index 45d2614f5..6632e508a 100755..100644
--- a/sd/source/ui/view/MediaObjectBar.cxx
+++ b/sd/source/ui/view/MediaObjectBar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -164,3 +165,5 @@ void MediaObjectBar::Execute( SfxRequest& rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/OutlineViewShellBase.cxx b/sd/source/ui/view/OutlineViewShellBase.cxx
index 5f029f78a..3c82aacef 100755..100644
--- a/sd/source/ui/view/OutlineViewShellBase.cxx
+++ b/sd/source/ui/view/OutlineViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,7 +45,7 @@ TYPEINIT1(OutlineViewShellBase, ViewShellBase);
// new OutlineViewShellBase object has been constructed.
SfxViewFactory* OutlineViewShellBase::pFactory;
-SfxViewShell* __EXPORT OutlineViewShellBase::CreateInstance (
+SfxViewShell* OutlineViewShellBase::CreateInstance (
SfxViewFrame *pFrame, SfxViewShell *pOldView)
{
OutlineViewShellBase* pBase = new OutlineViewShellBase(pFrame, pOldView);
@@ -84,3 +85,4 @@ OutlineViewShellBase::~OutlineViewShellBase (void)
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/Outliner.cxx b/sd/source/ui/view/Outliner.cxx
index e9d03ad98..f4f803325 100755..100644
--- a/sd/source/ui/view/Outliner.cxx
+++ b/sd/source/ui/view/Outliner.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -215,12 +216,12 @@ Outliner::Outliner( SdDrawDocument* pDoc, sal_uInt16 nMode )
Any aAny;
aAny = aLinguConfig.GetProperty(
- rtl::OUString::createFromAscii( UPN_IS_SPELL_AUTO ) );
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( UPN_IS_SPELL_AUTO )) );
aAny >>= bOnlineSpell;
}
catch( ... )
{
- DBG_ERROR( "Ill. type in linguistic property" );
+ OSL_FAIL( "Ill. type in linguistic property" );
}
}
@@ -272,8 +273,6 @@ Outliner::~Outliner (void)
<li>When the current shell is a <type>SdOutlineViewShell</type> then
directly operate on it. No switching into other views takes place.</li>
-
- <li>For a <type>SlideViewShell</type> no action is performed.</li>
</ol>
*/
void Outliner::PrepareSpelling (void)
@@ -369,7 +368,7 @@ void Outliner::EndSpelling (void)
SetUpdateMode(sal_True);
}
- // #95811# Before clearing the modify flag use it as a hint that
+ // Before clearing the modify flag use it as a hint that
// changes were done at SpellCheck
if(IsModified())
{
@@ -379,7 +378,7 @@ void Outliner::EndSpelling (void)
mpDrawDocument->SetChanged(sal_True);
}
- // #95811# now clear the modify flag to have a specified state of
+ // now clear the modify flag to have a specified state of
// Outliner
ClearModifyFlag();
@@ -532,7 +531,7 @@ bool Outliner::StartSearchAndReplace (const SvxSearchItem* pSearchItem)
{
RememberStartPosition ();
bEndOfSearch = SearchAndReplaceOnce ();
- //#107233# restore start position if nothing was found
+ // restore start position if nothing was found
if(!mbStringFound)
RestoreStartPosition ();
else
@@ -1476,8 +1475,6 @@ void Outliner::SetViewShell (const ::boost::shared_ptr<ViewShell>& rpViewShell)
// When the outline view is not owned by us then we have to clear
// that pointer so that the current one for the new view shell will
// be used (in ProvideOutlinerView).
- // if ( ! mbOwnOutlineView)
- // mpOutlineView = NULL;
if (mpViewShell.get() != NULL)
{
mpView = mpViewShell->GetView();
@@ -1573,7 +1570,6 @@ void Outliner::PrepareConversion (void)
mpDrawDocument->GetDocSh()->SetWaitCursor( sal_False );
// Start seach at the right end of the current object's text
// depending on the search direction.
-// mpOutlineView->SetSelection (GetSearchStartPosition ());
}
else
{
@@ -1826,3 +1822,5 @@ void Outliner::Implementation::ReleaseOutlinerView (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/OutlinerIterator.cxx b/sd/source/ui/view/OutlinerIterator.cxx
index 61665bc7e..399be16e2 100755..100644
--- a/sd/source/ui/view/OutlinerIterator.cxx
+++ b/sd/source/ui/view/OutlinerIterator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -580,7 +581,7 @@ ViewIteratorImpl::ViewIteratorImpl (
const ::boost::weak_ptr<ViewShell>& rpViewShellWeak,
bool bDirectionIsForward)
: IteratorImplBase (pDocument, rpViewShellWeak, bDirectionIsForward),
- mbPageChangeOccured(false),
+ mbPageChangeOccurred(false),
mpPage(NULL),
mpObjectIterator(NULL)
{
@@ -598,7 +599,7 @@ ViewIteratorImpl::ViewIteratorImpl (
PageKind ePageKind,
EditMode eEditMode)
: IteratorImplBase (pDocument, rpViewShellWeak, bDirectionIsForward, ePageKind, eEditMode),
- mbPageChangeOccured(false),
+ mbPageChangeOccurred(false),
mpPage(NULL),
mpObjectIterator(NULL)
{
@@ -695,8 +696,8 @@ void ViewIteratorImpl::GotoNextText(void)
void ViewIteratorImpl::SetPage (sal_Int32 nPageIndex)
{
- mbPageChangeOccured = (maPosition.mnPageIndex!=nPageIndex);
- if (mbPageChangeOccured)
+ mbPageChangeOccurred = (maPosition.mnPageIndex!=nPageIndex);
+ if (mbPageChangeOccurred)
{
maPosition.mnPageIndex = nPageIndex;
@@ -896,3 +897,5 @@ void DocumentIteratorImpl::GotoNextText (void)
} } // end of namespace ::sd::outliner
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/PresentationViewShellBase.cxx b/sd/source/ui/view/PresentationViewShellBase.cxx
index 729aea41e..b74327d5e 100755..100644
--- a/sd/source/ui/view/PresentationViewShellBase.cxx
+++ b/sd/source/ui/view/PresentationViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,7 +54,7 @@ TYPEINIT1(PresentationViewShellBase, ViewShellBase);
// new PresentationViewShellBase object has been constructed.
SfxViewFactory* PresentationViewShellBase::pFactory;
-SfxViewShell* __EXPORT PresentationViewShellBase::CreateInstance (
+SfxViewShell* PresentationViewShellBase::CreateInstance (
SfxViewFrame *_pFrame, SfxViewShell *pOldView)
{
PresentationViewShellBase* pBase =
@@ -91,12 +92,12 @@ PresentationViewShellBase::PresentationViewShellBase (
if (xFrameSet.is())
{
Reference<beans::XPropertySet> xLayouterSet (
- xFrameSet->getPropertyValue(::rtl::OUString::createFromAscii("LayoutManager")),
+ xFrameSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LayoutManager"))),
UNO_QUERY);
if (xLayouterSet.is())
{
xLayouterSet->setPropertyValue(
- ::rtl::OUString::createFromAscii("AutomaticToolbars"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AutomaticToolbars")),
makeAny(sal_False));
}
}
@@ -121,3 +122,4 @@ void PresentationViewShellBase::InitializeFramework (void)
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/SlideSorterViewShellBase.cxx b/sd/source/ui/view/SlideSorterViewShellBase.cxx
index c0202bc8f..ab42fc0fa 100755..100644
--- a/sd/source/ui/view/SlideSorterViewShellBase.cxx
+++ b/sd/source/ui/view/SlideSorterViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,7 +45,7 @@ TYPEINIT1(SlideSorterViewShellBase, ViewShellBase);
// new SlideSorterViewShellBase object has been constructed.
SfxViewFactory* SlideSorterViewShellBase::pFactory;
-SfxViewShell* __EXPORT SlideSorterViewShellBase::CreateInstance (
+SfxViewShell* SlideSorterViewShellBase::CreateInstance (
SfxViewFrame *pFrame, SfxViewShell *pOldView)
{
SlideSorterViewShellBase* pBase = new SlideSorterViewShellBase(pFrame, pOldView);
@@ -95,3 +96,4 @@ SlideSorterViewShellBase::~SlideSorterViewShellBase (void)
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ToolBarManager.cxx b/sd/source/ui/view/ToolBarManager.cxx
index ba6658179..81b193736 100755..100644
--- a/sd/source/ui/view/ToolBarManager.cxx
+++ b/sd/source/ui/view/ToolBarManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,9 +51,7 @@
#include <svx/dialogs.hrc>
#include <svx/extrusionbar.hxx>
#include <svx/fontworkbar.hxx>
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
#include <tools/link.hxx>
#include <map>
@@ -1695,3 +1694,5 @@ void ToolBarShellList::UpdateShells (
} // end of anonymous namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/UpdateLockManager.cxx b/sd/source/ui/view/UpdateLockManager.cxx
index a8121af4e..260d2a64e 100644
--- a/sd/source/ui/view/UpdateLockManager.cxx
+++ b/sd/source/ui/view/UpdateLockManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -406,7 +407,7 @@ Reference< ::com::sun::star::frame::XLayoutManager>
try
{
Any aValue (xFrameProperties->getPropertyValue(
- ::rtl::OUString::createFromAscii("LayoutManager")));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LayoutManager"))));
aValue >>= xLayoutManager;
}
catch (const beans::UnknownPropertyException& rException)
@@ -427,3 +428,5 @@ Reference< ::com::sun::star::frame::XLayoutManager>
} // end of anonymous namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewClipboard.cxx b/sd/source/ui/view/ViewClipboard.cxx
index 25e98efdb..d5265494a 100755..100644
--- a/sd/source/ui/view/ViewClipboard.cxx
+++ b/sd/source/ui/view/ViewClipboard.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,7 +43,7 @@
#include "glob.hrc"
#include <svx/svdpagv.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
namespace sd {
@@ -139,54 +140,50 @@ void ViewClipboard::AssignMasterPage (
const SdTransferable& rTransferable,
SdPage* pMasterPage)
{
- do
- {
- if (pMasterPage == NULL)
- return;
-
- // Get the target page to which the master page is assigned.
- SdrPageView* pPageView = mrView.GetSdrPageView();
- if (pPageView == NULL)
- break;
-
- SdPage* pPage = static_cast<SdPage*>(pPageView->GetPage());
- if (pPage == NULL)
- break;
-
- SdDrawDocument* pDocument = mrView.GetDoc();
- if (pDocument == NULL)
- break;
-
- if ( ! rTransferable.HasPageBookmarks())
- break;
-
- DrawDocShell* pDataDocShell = rTransferable.GetPageDocShell();
- if (pDataDocShell == NULL)
- break;
-
- SdDrawDocument* pSourceDocument = pDataDocShell->GetDoc();
- if (pSourceDocument == NULL)
- break;
-
- // We have to remove the layout suffix from the layout name which is
- // appended again by SetMasterPage() to the given name. Don't ask.
- String sLayoutSuffix (RTL_CONSTASCII_STRINGPARAM(SD_LT_SEPARATOR));
- sLayoutSuffix.Append (SdResId(STR_LAYOUT_OUTLINE));
- sal_uInt16 nLength = sLayoutSuffix.Len();
- String sLayoutName (pMasterPage->GetLayoutName());
- if (String(sLayoutName, sLayoutName.Len()-nLength, nLength).Equals (
- sLayoutSuffix))
- sLayoutName = String(sLayoutName, 0, sLayoutName.Len()-nLength);
-
- pDocument->SetMasterPage (
- pPage->GetPageNum() / 2,
- sLayoutName,
- pSourceDocument,
- sal_False, // Exchange the master page of only the target page.
- sal_False // Keep unused master pages.
- );
- }
- while (false);
+ if (pMasterPage == NULL)
+ return;
+
+ // Get the target page to which the master page is assigned.
+ SdrPageView* pPageView = mrView.GetSdrPageView();
+ if (pPageView == NULL)
+ return;
+
+ SdPage* pPage = static_cast<SdPage*>(pPageView->GetPage());
+ if (pPage == NULL)
+ return;
+
+ SdDrawDocument* pDocument = mrView.GetDoc();
+ if (pDocument == NULL)
+ return;
+
+ if ( ! rTransferable.HasPageBookmarks())
+ return;
+
+ DrawDocShell* pDataDocShell = rTransferable.GetPageDocShell();
+ if (pDataDocShell == NULL)
+ return;
+
+ SdDrawDocument* pSourceDocument = pDataDocShell->GetDoc();
+ if (pSourceDocument == NULL)
+ return;
+
+ // We have to remove the layout suffix from the layout name which is
+ // appended again by SetMasterPage() to the given name. Don't ask.
+ String sLayoutSuffix (RTL_CONSTASCII_USTRINGPARAM(SD_LT_SEPARATOR));
+ sLayoutSuffix.Append (SdResId(STR_LAYOUT_OUTLINE));
+ sal_uInt16 nLength = sLayoutSuffix.Len();
+ String sLayoutName (pMasterPage->GetLayoutName());
+ if (String(sLayoutName, sLayoutName.Len()-nLength, nLength).Equals (
+ sLayoutSuffix))
+ sLayoutName = String(sLayoutName, 0, sLayoutName.Len()-nLength);
+
+ pDocument->SetMasterPage (
+ pPage->GetPageNum() / 2,
+ sLayoutName,
+ pSourceDocument,
+ sal_False, // Exchange the master page of only the target page.
+ sal_False // Keep unused master pages.
+ );
}
@@ -248,7 +245,7 @@ sal_uInt16 ViewClipboard::InsertSlides (
}
if (nInsertPgCnt > 0)
{
- const ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aGuard;
::sd::Window* pWin = mrView.GetViewShell()->GetActiveWindow();
const sal_Bool bWait = pWin && pWin->IsWait();
@@ -276,3 +273,5 @@ sal_uInt16 ViewClipboard::InsertSlides (
} // end of namespace ::sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewShellBase.cxx b/sd/source/ui/view/ViewShellBase.cxx
index 863c4c2a2..1f7fc6d92 100644
--- a/sd/source/ui/view/ViewShellBase.cxx
+++ b/sd/source/ui/view/ViewShellBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -242,7 +243,7 @@ TYPEINIT1(ViewShellBase, SfxViewShell);
// new ViewShellBase object has been constructed.
SfxViewFactory* ViewShellBase::pFactory;
-SfxViewShell* __EXPORT ViewShellBase::CreateInstance (
+SfxViewShell* ViewShellBase::CreateInstance (
SfxViewFrame *pFrame, SfxViewShell *pOldView)
{
ViewShellBase* pBase = new ViewShellBase(pFrame, pOldView);
@@ -481,15 +482,10 @@ void ViewShellBase::Notify(SfxBroadcaster& rBC, const SfxHint& rHint)
{
if( GetViewFrame() )
{
- GetDocument()->SetStartWithPresentation( false );
GetViewFrame()->GetDispatcher()->Execute(
SID_PRESENTATION, SFX_CALLMODE_ASYNCHRON );
}
}
- else
- {
- // mpPaneManager->InitPanes();
- }
break;
default:
@@ -655,7 +651,6 @@ SfxTabPage* ViewShellBase::CreatePrintOptionsPage(
(void)pParent;
(void)rOptions;
return NULL;
- // return mpImpl->mpPrintManager->CreatePrintOptionsPage (pParent, rOptions);
}
@@ -774,12 +769,6 @@ void ViewShellBase::Execute (SfxRequest& rRequest)
void ViewShellBase::GetState (SfxItemSet& rSet)
{
- // The full screen mode is not supported. Disable the the slot so that
- // it appears grayed out when somebody uses configures the menu to show
- // an menu item for it.
- // if (rSet.GetItemState(SID_WIN_FULLSCREEN) == SFX_ITEM_AVAILABLE)
- // rSet.DisableItem(SID_WIN_FULLSCREEN);
-
mpImpl->GetSlotState(rSet);
FuBullet::GetSlotState( rSet, 0, GetViewFrame() );
@@ -974,8 +963,8 @@ void ViewShellBase::UpdateBorder ( bool bForce /* = false */ )
// made only for the main view shell. This not only avoids unnecessary
// calls for the views in side panes but prevents calling an already
// dying SfxViewShell base class.
- // For issue #140703# we have to check the existence of the window,
- // too. The SfxViewFrame accesses the window without checking it.
+ // We have to check the existence of the window, too.
+ // The SfxViewFrame accesses the window without checking it.
ViewShell* pMainViewShell = GetMainViewShell().get();
if (pMainViewShell != NULL && GetWindow()!=NULL)
{
@@ -1194,7 +1183,7 @@ void ViewShellBase::SetViewTabBar (const ::rtl::Reference<ViewTabBar>& rViewTabB
{
for( sal_Int32 i = 0; i < aPropSeq.getLength(); i++ )
{
- if( aPropSeq[i].Name.equalsAscii( "Name" ))
+ if( aPropSeq[i].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Name" ) ))
{
aPropSeq[i].Value >>= aLabel;
break;
@@ -1278,7 +1267,7 @@ void ViewShellBase::Implementation::ProcessRestoreEditingViewSlot (void)
pHelper->GetViewURL(pFrameView->GetViewShellTypeOnLoad()),
FrameworkHelper::msCenterPaneURL);
pHelper->RunOnConfigurationEvent(
- ::rtl::OUString::createFromAscii("ConfigurationUpdateEnd"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ConfigurationUpdateEnd")),
CurrentPageSetter(mrBase));
}
}
@@ -1556,7 +1545,6 @@ void ViewShellBase::Implementation::ProcessTaskPaneSlot (SfxRequest& rRequest)
{
// Set the visibility state of the toolpanel and one of its top
// level panels.
- sal_Bool bShowToolPanel = sal_True;
toolpanel::PanelId nPanelId (
toolpanel::PID_UNKNOWN);
bool bPanelIdGiven = false;
@@ -1565,13 +1553,6 @@ void ViewShellBase::Implementation::ProcessTaskPaneSlot (SfxRequest& rRequest)
const SfxItemSet* pArgs = rRequest.GetArgs();
if (pArgs)
{
- if ((pArgs->Count() == 1) || (pArgs->Count() == 2))
- {
- SFX_REQUEST_ARG (rRequest, pIsPanelVisible,
- SfxBoolItem, ID_VAL_ISVISIBLE, sal_False);
- if (pIsPanelVisible != NULL)
- bShowToolPanel = pIsPanelVisible->GetValue();
- }
if (pArgs->Count() == 2)
{
SFX_REQUEST_ARG (rRequest, pPanelId, SfxUInt32Item,
@@ -1733,3 +1714,5 @@ void FocusForwardingWindow::Command (const CommandEvent& rEvent)
} // end of anonymouse namespace
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewShellHint.cxx b/sd/source/ui/view/ViewShellHint.cxx
index a5aee5c09..6b3dd9592 100644
--- a/sd/source/ui/view/ViewShellHint.cxx
+++ b/sd/source/ui/view/ViewShellHint.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ ViewShellHint::HintId ViewShellHint::GetHintId (void) const
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewShellImplementation.cxx b/sd/source/ui/view/ViewShellImplementation.cxx
index 04939930c..5eeeeb85c 100755..100644
--- a/sd/source/ui/view/ViewShellImplementation.cxx
+++ b/sd/source/ui/view/ViewShellImplementation.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115,8 +116,6 @@ void ViewShell::Implementation::ProcessModifyPageSlot (
sal_Bool bHandoutMode = sal_False;
SdPage* pHandoutMPage = NULL;
String aNewName;
-
- // #95981#
String aOldName;
AutoLayout aNewAutoLayout;
@@ -137,18 +136,6 @@ void ViewShell::Implementation::ProcessModifyPageSlot (
if (!pArgs || pArgs->Count() == 1 || pArgs->Count() == 2 )
{
- if (pArgs && pArgs->Count() == 2)
- {
- // We have been called with a request that contains two
- // arguments. One was used as preselected layout in a
- // dialog. We could select that layout in the
- // layout panel instead.
- /*
- SFX_REQUEST_ARG (rRequest, pNewAutoLayout, SfxUInt32Item, ID_VAL_WHATLAYOUT, sal_False);
- eNewAutoLayout = (AutoLayout) pNewAutoLayout->GetValue
- ();
- */
- }
// Make the layout menu visible in the tool pane.
SfxBoolItem aMakeToolPaneVisible (ID_VAL_ISVISIBLE, sal_True);
@@ -447,3 +434,5 @@ ViewShell::Implementation::ToolBarManagerLock::~ToolBarManagerLock (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewShellManager.cxx b/sd/source/ui/view/ViewShellManager.cxx
index aa8ec230a..c05d510c7 100755..100644
--- a/sd/source/ui/view/ViewShellManager.cxx
+++ b/sd/source/ui/view/ViewShellManager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,7 +40,8 @@
#include <svx/svxids.hrc>
#include <svx/fmshell.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
+#include <iterator>
#undef VERBOSE
//#define VERBOSE 2
@@ -175,7 +177,7 @@ private:
mutable ::osl::Mutex maMutex;
class ShellHash{public: size_t operator()(const SfxShell* p) const { return (size_t)p;} };
- typedef ::std::hash_multimap<const SfxShell*,SharedShellFactory,ShellHash>
+ typedef ::boost::unordered_multimap<const SfxShell*,SharedShellFactory,ShellHash>
FactoryList;
FactoryList maShellFactories;
@@ -187,7 +189,7 @@ private:
ActiveShellList maActiveViewShells;
typedef ::std::list<ShellDescriptor> SubShellSubList;
- typedef ::std::hash_map<const SfxShell*,SubShellSubList,ShellHash> SubShellList;
+ typedef ::boost::unordered_map<const SfxShell*,SubShellSubList,ShellHash> SubShellList;
SubShellList maActiveSubShells;
/** In this member we remember what shells we have pushed on the shell
@@ -652,34 +654,30 @@ void ViewShellManager::Implementation::ActivateSubShell (
{
::osl::MutexGuard aGuard (maMutex);
- do
- {
- // Check that the given view shell is active.
- ActiveShellList::iterator iShell (::std::find_if (
- maActiveViewShells.begin(),
- maActiveViewShells.end(),
- IsShell(&rParentShell)));
- if (iShell == maActiveViewShells.end())
- break;
+ // Check that the given view shell is active.
+ ActiveShellList::iterator iShell (::std::find_if (
+ maActiveViewShells.begin(),
+ maActiveViewShells.end(),
+ IsShell(&rParentShell)));
+ if (iShell == maActiveViewShells.end())
+ return;
- // Create the sub shell list if it does not yet exist.
- SubShellList::iterator iList (maActiveSubShells.find(&rParentShell));
- if (iList == maActiveSubShells.end())
- iList = maActiveSubShells.insert(
- SubShellList::value_type(&rParentShell,SubShellSubList())).first;
-
- // Do not activate an object bar that is already active. Requesting
- // this is not exactly an error but may be an indication of one.
- SubShellSubList& rList (iList->second);
- if (::std::find_if(rList.begin(),rList.end(), IsId(nId)) != rList.end())
- break;
+ // Create the sub shell list if it does not yet exist.
+ SubShellList::iterator iList (maActiveSubShells.find(&rParentShell));
+ if (iList == maActiveSubShells.end())
+ iList = maActiveSubShells.insert(
+ SubShellList::value_type(&rParentShell,SubShellSubList())).first;
+
+ // Do not activate an object bar that is already active. Requesting
+ // this is not exactly an error but may be an indication of one.
+ SubShellSubList& rList (iList->second);
+ if (::std::find_if(rList.begin(),rList.end(), IsId(nId)) != rList.end())
+ return;
- // Add just the id of the sub shell. The actual shell is created
- // later in CreateShells().
- UpdateLock aLock (*this);
- rList.push_back(ShellDescriptor(NULL, nId));
- }
- while (false);
+ // Add just the id of the sub shell. The actual shell is created
+ // later in CreateShells().
+ UpdateLock aLock (*this);
+ rList.push_back(ShellDescriptor(NULL, nId));
}
@@ -691,34 +689,30 @@ void ViewShellManager::Implementation::DeactivateSubShell (
{
::osl::MutexGuard aGuard (maMutex);
- do
- {
- // Check that the given view shell is active.
- SubShellList::iterator iList (maActiveSubShells.find(&rParentShell));
- if (iList == maActiveSubShells.end())
- break;
+ // Check that the given view shell is active.
+ SubShellList::iterator iList (maActiveSubShells.find(&rParentShell));
+ if (iList == maActiveSubShells.end())
+ return;
- // Look up the sub shell.
- SubShellSubList& rList (iList->second);
- SubShellSubList::iterator iShell (
- ::std::find_if(rList.begin(),rList.end(), IsId(nId)));
- if (iShell == rList.end())
- break;
- SfxShell* pShell = iShell->mpShell;
- if (pShell == NULL)
- break;
-
- UpdateLock aLock (*this);
+ // Look up the sub shell.
+ SubShellSubList& rList (iList->second);
+ SubShellSubList::iterator iShell (
+ ::std::find_if(rList.begin(),rList.end(), IsId(nId)));
+ if (iShell == rList.end())
+ return;
+ SfxShell* pShell = iShell->mpShell;
+ if (pShell == NULL)
+ return;
- ShellDescriptor aDescriptor(*iShell);
- // Remove the sub shell from both the internal structure as well as the
- // SFX shell stack above and including the sub shell.
- rList.erase(iShell);
- TakeShellsFromStack(pShell);
+ UpdateLock aLock (*this);
- DestroySubShell(rParentShell, aDescriptor);
- }
- while (false);
+ ShellDescriptor aDescriptor(*iShell);
+ // Remove the sub shell from both the internal structure as well as the
+ // SFX shell stack above and including the sub shell.
+ rList.erase(iShell);
+ TakeShellsFromStack(pShell);
+
+ DestroySubShell(rParentShell, aDescriptor);
}
@@ -947,7 +941,7 @@ void ViewShellManager::Implementation::UpdateShellStack (void)
// 4. Find the lowest shell in which the two stacks differ.
- ShellStack::const_iterator iSfxShell (aSfxShellStack.begin());
+ ShellStack::iterator iSfxShell (aSfxShellStack.begin());
ShellStack::iterator iTargetShell (aTargetStack.begin());
while (iSfxShell != aSfxShellStack.end()
&& iTargetShell!=aTargetStack.end()
@@ -960,15 +954,16 @@ void ViewShellManager::Implementation::UpdateShellStack (void)
// 5. Remove all shells above and including the differing shell from the
// SFX stack starting with the shell on top of the stack.
- while (iSfxShell != aSfxShellStack.end())
+ for (std::reverse_iterator<ShellStack::const_iterator> i(aSfxShellStack.end()), iLast(iSfxShell);
+ i != iLast; ++i)
{
- SfxShell* pShell = aSfxShellStack.back();
- aSfxShellStack.pop_back();
+ SfxShell* const pShell = *i;
#ifdef VERBOSE
OSL_TRACE("removing shell %p from stack\r", pShell);
#endif
mrBase.RemoveSubShell(pShell);
}
+ aSfxShellStack.erase(iSfxShell, aSfxShellStack.end());
// 6. Push shells from the given stack onto the SFX stack.
@@ -1465,3 +1460,5 @@ bool ShellDescriptor::IsMainViewShell (void) const
} // end of anonymous namespace
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/ViewTabBar.cxx b/sd/source/ui/view/ViewTabBar.cxx
index 12458a33c..661440d38 100755..100644
--- a/sd/source/ui/view/ViewTabBar.cxx
+++ b/sd/source/ui/view/ViewTabBar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,13 +48,14 @@
#include "Client.hxx"
#include <vcl/svapp.hxx>
#include <vcl/tabpage.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <sfx2/viewfrm.hxx>
#include <com/sun/star/drawing/framework/ResourceId.hpp>
#include <com/sun/star/drawing/framework/XControllerManager.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
#include <com/sun/star/lang/DisposedException.hpp>
#include <comphelper/processfactory.hxx>
+#include <comphelper/servicehelper.hxx>
#include <tools/diagnose_ex.h>
using namespace ::com::sun::star;
@@ -196,7 +198,7 @@ void ViewTabBar::disposing (void)
}
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
// Set all references to the one tab page to NULL and delete the page.
for (sal_uInt16 nIndex=0; nIndex<mpTabControl->GetPageCount(); ++nIndex)
mpTabControl->SetTabPage(nIndex, NULL);
@@ -320,7 +322,7 @@ void SAL_CALL ViewTabBar::addTabBarButtonAfter (
const TabBarButton& rAnchor)
throw (::com::sun::star::uno::RuntimeException)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
AddTabBarButton(rButton, rAnchor);
}
@@ -330,7 +332,7 @@ void SAL_CALL ViewTabBar::addTabBarButtonAfter (
void SAL_CALL ViewTabBar::appendTabBarButton (const TabBarButton& rButton)
throw (::com::sun::star::uno::RuntimeException)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
AddTabBarButton(rButton);
}
@@ -339,7 +341,7 @@ void SAL_CALL ViewTabBar::appendTabBarButton (const TabBarButton& rButton)
void SAL_CALL ViewTabBar::removeTabBarButton (const TabBarButton& rButton)
throw (::com::sun::star::uno::RuntimeException)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
RemoveTabBarButton(rButton);
}
@@ -349,7 +351,7 @@ void SAL_CALL ViewTabBar::removeTabBarButton (const TabBarButton& rButton)
sal_Bool SAL_CALL ViewTabBar::hasTabBarButton (const TabBarButton& rButton)
throw (::com::sun::star::uno::RuntimeException)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return HasTabBarButton(rButton);
}
@@ -359,7 +361,7 @@ sal_Bool SAL_CALL ViewTabBar::hasTabBarButton (const TabBarButton& rButton)
Sequence<TabBarButton> SAL_CALL ViewTabBar::getTabBarButtons (void)
throw (::com::sun::star::uno::RuntimeException)
{
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
+ const SolarMutexGuard aSolarGuard;
return GetTabBarButtons();
}
@@ -388,24 +390,15 @@ sal_Bool SAL_CALL ViewTabBar::isAnchorOnly (void)
//----- XUnoTunnel ------------------------------------------------------------
-const Sequence<sal_Int8>& ViewTabBar::getUnoTunnelId (void)
+namespace
{
- static Sequence<sal_Int8>* pSequence = NULL;
- if (pSequence == NULL)
- {
- const ::vos::OGuard aSolarGuard (Application::GetSolarMutex());
- if (pSequence == NULL)
- {
- static ::com::sun::star::uno::Sequence<sal_Int8> aSequence (16);
- rtl_createUuid((sal_uInt8*)aSequence.getArray(), 0, sal_True);
- pSequence = &aSequence;
- }
- }
- return *pSequence;
+ class theViewTabBarUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theViewTabBarUnoTunnelId > {};
}
-
-
+const Sequence<sal_Int8>& ViewTabBar::getUnoTunnelId (void)
+{
+ return theViewTabBarUnoTunnelId::get().getSeq();
+}
sal_Int64 SAL_CALL ViewTabBar::getSomething (const Sequence<sal_Int8>& rId)
throw (RuntimeException)
@@ -714,3 +707,5 @@ void TabBarControl::ActivatePage (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/WindowUpdater.cxx b/sd/source/ui/view/WindowUpdater.cxx
index 481ff0e11..9c5397e97 100644
--- a/sd/source/ui/view/WindowUpdater.cxx
+++ b/sd/source/ui/view/WindowUpdater.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,9 +35,7 @@
#include "drawdoc.hxx"
#include "View.hxx"
-#ifndef _SPLIT_HXX
#include <vcl/split.hxx>
-#endif
#include <sfx2/childwin.hxx>
#include <sfx2/viewfrm.hxx>
#include <svl/smplhint.hxx>
@@ -162,14 +161,6 @@ void WindowUpdater::UpdateWindow (OutputDevice* pDevice) const
void WindowUpdater::ConfigurationChanged( utl::ConfigurationBroadcaster*, sal_uInt32 )
{
- // #110094#-7
- // Clear the master page cache so that master pages will be redrawn.
- //if (mpViewShell != NULL)
- //{
- // SdView* pView = mpViewShell->GetView();
- // if (pView != NULL)
- // pView->ReleaseMasterPagePaintCache ();
- //}
// Set the current state at all registered output devices.
tWindowList::iterator aWindowIterator (maWindowList.begin());
while (aWindowIterator != maWindowList.end())
@@ -187,3 +178,5 @@ void WindowUpdater::ConfigurationChanged( utl::ConfigurationBroadcaster*, sal_uI
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/bmcache.cxx b/sd/source/ui/view/bmcache.cxx
deleted file mode 100755
index d34451a88..000000000
--- a/sd/source/ui/view/bmcache.cxx
+++ /dev/null
@@ -1,78 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_sd.hxx"
-
-
-#include <limits.h> // LONG_MAX
-#include <tools/solar.h>
-#include <svtools/grfmgr.hxx>
-#include "bmcache.hxx"
-
-// eine Struktur fuer die Cache-Eintraege
-struct BitmapCacheEntry
-{
- const SdPage* pPage;
- GraphicObject* pGraphicObject;
- sal_uInt32 nSizeBytes;
- long nZoom;
-};
-
-/*************************************************************************
-|*
-|* Destruktor, loescht die gespeicherten Bitmaps
-|*
-\************************************************************************/
-
-BitmapCache::~BitmapCache()
-{
- for( void* pEntry = aEntries.First(); pEntry; pEntry = aEntries.Next() )
- {
- delete static_cast< BitmapCacheEntry* >( pEntry )->pGraphicObject;
- delete static_cast< BitmapCacheEntry* >( pEntry );
- }
-}
-
-void BitmapCache::Remove( const SdPage* pPage )
-{
- for( sal_uLong nPos = 0; nPos < aEntries.Count(); )
- {
- BitmapCacheEntry* pCand = (BitmapCacheEntry*) aEntries.GetObject( nPos );
-
- if( pCand->pPage == pPage )
- {
- pCand = (BitmapCacheEntry*) aEntries.Remove((sal_uLong)nPos);
- delete pCand->pGraphicObject;
- delete pCand;
- }
- else
- nPos++;
- }
-}
-
-
diff --git a/sd/source/ui/view/clview.cxx b/sd/source/ui/view/clview.cxx
index eb702e5b8..58b2fe1d5 100644
--- a/sd/source/ui/view/clview.cxx
+++ b/sd/source/ui/view/clview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,13 +92,6 @@ void ClientView::InvalidateOneWin(::Window& rWin, const Rectangle& rRect)
CompleteRedraw(&rWin, rRect);
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void ClientView::CompleteRedraw(OutputDevice* pOutDev, const Region& rReg, sdr::contact::ViewObjectContactRedirector* pRedirector )
{
DrawView::CompleteRedraw(pOutDev, rReg, pRedirector);
@@ -105,3 +99,5 @@ void ClientView::CompleteRedraw(OutputDevice* pOutDev, const Region& rReg, sdr::
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drawview.cxx b/sd/source/ui/view/drawview.cxx
index f181a8899..151762c53 100755..100644
--- a/sd/source/ui/view/drawview.cxx
+++ b/sd/source/ui/view/drawview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sd.hxx"
#include <sfx2/dispatch.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svx/svdpagv.hxx>
#include <sfx2/request.hxx>
#include <svl/style.hxx>
#include <editeng/outliner.hxx>
-#ifndef _VIEW3D_HXX //autogen
#include <svx/view3d.hxx>
-#endif
-#ifndef _SVXIDS_HRC //autogen
#include <svx/svxids.hrc>
-#endif
#include <svx/svdotext.hxx>
#include <svx/svdograf.hxx>
#include <svx/svdogrp.hxx>
@@ -211,7 +206,7 @@ sal_Bool DrawView::SetAttributes(const SfxItemSet& rSet,
// Presentation object outline
OutlinerView* pOV = GetTextEditOutlinerView();
::Outliner* pOutliner = pOV->GetOutliner();
- List* pList = (List*)pOV->CreateSelectionList();
+
aTemplateName += String(SdResId(STR_LAYOUT_OUTLINE));
pOutliner->SetUpdateMode(sal_False);
@@ -224,7 +219,12 @@ sal_Bool DrawView::SetAttributes(const SfxItemSet& rSet,
aComment.Insert( String((SdResId(STR_PSEUDOSHEET_OUTLINE))), nPos);
mpDocSh->GetUndoManager()->EnterListAction( aComment, String() );
- Paragraph* pPara = (Paragraph*)pList->Last();
+ std::vector<Paragraph*> aSelList;
+ pOV->CreateSelectionList(aSelList);
+
+ std::vector<Paragraph*>::reverse_iterator iter = aSelList.rbegin();
+ Paragraph* pPara = iter != aSelList.rend() ? *iter : NULL;
+
while (pPara)
{
sal_uLong nParaPos = pOutliner->GetAbsPos( pPara );
@@ -265,10 +265,11 @@ sal_Bool DrawView::SetAttributes(const SfxItemSet& rSet,
pOutlSheet->Broadcast(SfxSimpleHint(SFX_HINT_DATACHANGED));
}
- pPara = (Paragraph*)pList->Prev();
+ ++iter;
+ pPara = iter != aSelList.rend() ? *iter : NULL;
if( !pPara && nDepth > 0 && rSet.GetItemState( EE_PARA_NUMBULLET ) == SFX_ITEM_ON &&
- pOutliner->GetDepth( (sal_uInt16) pOutliner->GetAbsPos( (Paragraph*) pList->First() ) ) > 0 )
+ pOutliner->GetDepth( (sal_uInt16) pOutliner->GetAbsPos(*(aSelList.begin())) ) > 0 )
pPara = pOutliner->GetParagraph( 0 ); // Put NumBulletItem in outline level 1
}
@@ -277,7 +278,6 @@ sal_Bool DrawView::SetAttributes(const SfxItemSet& rSet,
mpDocSh->GetUndoManager()->LeaveListAction();
- delete pList;
bOk = sal_True;
}
else
@@ -414,7 +414,7 @@ void DrawView::Notify(SfxBroadcaster& rBC, const SfxHint& rHint)
mpDrawViewShell->ResetActualLayer();
}
- // #94278# switch to that page when it's not a master page
+ // switch to that page when it's not a master page
if(HINT_SWITCHTOPAGE == eHintKind)
{
const SdrPage* pPage = ((const SdrHint&)rHint).GetPage();
@@ -555,7 +555,7 @@ sal_Bool DrawView::IsObjMarkable(SdrObject* pObj, SdrPageView* pPV) const
void DrawView::MakeVisible(const Rectangle& rRect, ::Window& rWin)
{
- if (!rRect.IsEmpty())
+ if (!rRect.IsEmpty() && mpDrawViewShell)
{
mpDrawViewShell->MakeVisible(rRect, rWin);
}
@@ -649,3 +649,5 @@ void DrawView::DeleteMarked()
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drbezob.cxx b/sd/source/ui/view/drbezob.cxx
index 00d5ae14c..eb16a63c2 100755..100644
--- a/sd/source/ui/view/drbezob.cxx
+++ b/sd/source/ui/view/drbezob.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -363,3 +364,5 @@ void BezierObjectBar::Execute(SfxRequest& rReq)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drtxtob.cxx b/sd/source/ui/view/drtxtob.cxx
index 2ac6ec221..b302eab26 100755..100644
--- a/sd/source/ui/view/drtxtob.cxx
+++ b/sd/source/ui/view/drtxtob.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -167,7 +168,6 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
{
SfxWhichIter aIter( rSet );
sal_uInt16 nWhich = aIter.FirstWhich();
- sal_Bool bTemplate = sal_False;
SfxItemSet aAttrSet( mpView->GetDoc()->GetPool() );
SvtLanguageOptions aLangOpt;
sal_Bool bDisableParagraphTextDirection = !aLangOpt.IsCTLFontEnabled();
@@ -195,7 +195,7 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
if( (nSlotId == SID_ATTR_CHAR_FONT) || (nSlotId == SID_ATTR_CHAR_FONTHEIGHT) )
{
- // #42732# input language should be preferred over
+ // input language should be preferred over
// current cursor position to detect script type
OutlinerView* pOLV = mpView->GetTextEditOutlinerView();
@@ -235,7 +235,6 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
{
rSet.Put( SfxTemplateItem( nWhich, String() ) );
}
- bTemplate = sal_True;
}
break;
@@ -263,16 +262,17 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
{
// Outliner im Gliederungsmodus
::Outliner* pOutl = pOLV->GetOutliner();
- List* pList = pOLV->CreateSelectionList();
- Paragraph* pPara = (Paragraph*) pList->First();
- // #96539# find out if we are a OutlineView
+ std::vector<Paragraph*> aSelList;
+ pOLV->CreateSelectionList(aSelList);
+ Paragraph* pPara = aSelList.empty() ? NULL : *(aSelList.begin());
+
+ // find out if we are a OutlineView
sal_Bool bIsOutlineView(OUTLINERMODE_OUTLINEVIEW == pOLV->GetOutliner()->GetMode());
- // #96539# This is ONLY for OutlineViews
+ // This is ONLY for OutlineViews
if(bIsOutlineView)
{
- // #96250# and #78665#
// allow move up if position is 2 or greater OR it
// is a title object (and thus depth==1)
if(pOutl->GetAbsPos(pPara) > 1 || ( pOutl->HasParaFlag(pPara,PARAFLAG_ISPAGE) && pOutl->GetAbsPos(pPara) > 0 ) )
@@ -283,7 +283,7 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
}
else
{
- // #96539# old behaviour for OUTLINERMODE_OUTLINEOBJECT
+ // old behaviour for OUTLINERMODE_OUTLINEOBJECT
if(pOutl->GetAbsPos(pPara) > 0)
{
// Nicht ganz oben
@@ -291,8 +291,10 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
}
}
- while (pPara)
+ for (std::vector<Paragraph*>::const_iterator iter = aSelList.begin(); iter != aSelList.end(); ++iter)
{
+ pPara = *iter;
+
sal_Int16 nDepth = pOutl->GetDepth( (sal_uInt16) pOutl->GetAbsPos( pPara ) );
if (nDepth > 0 || (bOutlineViewSh && (nDepth <= 0) && !pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE )) )
@@ -307,20 +309,18 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
// Nicht maximale Tiefe und nicht ganz oben
bDisableRight = sal_False;
}
-
- pPara = static_cast<Paragraph*>( pList->Next() );
}
- if ( ( pOutl->GetAbsPos((Paragraph*) pList->Last()) < pOutl->GetParagraphCount() - 1 ) &&
+ if ( ( pOutl->GetAbsPos(pPara) < pOutl->GetParagraphCount() - 1 ) &&
( pOutl->GetParagraphCount() > 1 || !bOutlineViewSh) )
{
// Nicht letzter Absatz
bDisableDown = sal_False;
}
- // #96250# and #78665#
// disable when first para and 2nd is not a title
- pPara = static_cast< Paragraph* >( pList->First() );
+ pPara = aSelList.empty() ? NULL : *(aSelList.begin());
+
if(!bDisableDown && bIsOutlineView
&& pPara
&& 0 == pOutl->GetAbsPos(pPara)
@@ -330,8 +330,6 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
// Needs to be disabled
bDisableDown = sal_True;
}
-
- delete pList;
}
if (bDisableLeft)
@@ -515,7 +513,6 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
rSet.Put( SfxBoolItem( SID_ATTR_PARA_RIGHT_TO_LEFT, sal_True ) );
break;
- // #107865#
// The case for the superordinate object is missing.
case FRMDIR_ENVIRONMENT:
{
@@ -536,21 +533,6 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
}
}
-/* #i35937#
- if (aAttrSet.GetItemState(EE_PARA_BULLETSTATE) == SFX_ITEM_ON)
- {
- SfxUInt16Item aBulletState((const SfxUInt16Item&) aAttrSet.Get(EE_PARA_BULLETSTATE));
-
- if (aBulletState.GetValue() != 0)
- {
- rSet.Put(SfxBoolItem(FN_NUM_BULLET_ON, sal_True));
- }
- else
- {
- rSet.Put(SfxBoolItem(FN_NUM_BULLET_ON, sal_False));
- }
- }
-*/
sal_uInt16 nLineSpace = (sal_uInt16) ( (const SvxLineSpacingItem&) aAttrSet.
Get( EE_PARA_SBL ) ).GetPropLineSpace();
switch( nLineSpace )
@@ -589,3 +571,5 @@ void TextObjectBar::Command( const CommandEvent& )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drtxtob1.cxx b/sd/source/ui/view/drtxtob1.cxx
index e60f7d547..8d95cef49 100755..100644
--- a/sd/source/ui/view/drtxtob1.cxx
+++ b/sd/source/ui/view/drtxtob1.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,14 +96,12 @@ void TextObjectBar::Execute( SfxRequest &rReq )
const SfxItemSet* pArgs = rReq.GetArgs();
const SfxPoolItem* pPoolItem = NULL;
sal_uInt16 nSlot = rReq.GetSlot();
- sal_Bool bOutlineMode = sal_False;
OutlinerView* pOLV = mpView->GetTextEditOutlinerView();
std::auto_ptr< OutlineViewModelChangeGuard > aGuard;
if (mpView->ISA(OutlineView))
{
- bOutlineMode = sal_True;
pOLV = static_cast<OutlineView*>(mpView)
->GetViewByWindow(mpViewShell->GetActiveWindow());
@@ -252,7 +251,7 @@ void TextObjectBar::Execute( SfxRequest &rReq )
// Ensure bold/italic etc. icon state updates
Invalidate();
- // #96551# trigger preview refresh
+ // trigger preview refresh
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SID_PREVIEW_STATE, sal_True, sal_False );
}
rReq.Done();
@@ -267,7 +266,7 @@ void TextObjectBar::Execute( SfxRequest &rReq )
// Ensure bold/italic etc. icon state updates
Invalidate();
- // #96551# trigger preview refresh
+ // trigger preview refresh
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SID_PREVIEW_STATE, sal_True, sal_False );
}
rReq.Done();
@@ -280,7 +279,7 @@ void TextObjectBar::Execute( SfxRequest &rReq )
{
pOLV->AdjustHeight( -1 );
- // #96551# trigger preview refresh
+ // trigger preview refresh
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SID_PREVIEW_STATE, sal_True, sal_False );
}
rReq.Done();
@@ -293,7 +292,7 @@ void TextObjectBar::Execute( SfxRequest &rReq )
{
pOLV->AdjustHeight( 1 );
- // #96551# trigger preview refresh
+ // trigger preview refresh
mpViewShell->GetViewFrame()->GetBindings().Invalidate( SID_PREVIEW_STATE, sal_True, sal_False );
}
rReq.Done();
@@ -514,32 +513,7 @@ void TextObjectBar::Execute( SfxRequest &rReq )
aNewAttr.Put( *pPoolItem );
}
break;
-/* #i35937#
- case FN_NUM_BULLET_ON:
- {
- if (aEditAttr.GetItemState(EE_PARA_BULLETSTATE) == SFX_ITEM_ON)
- {
- SfxUInt16Item aBulletState((const SfxUInt16Item&) aEditAttr.Get(EE_PARA_BULLETSTATE));
-
- if (aBulletState.GetValue() != 0)
- {
- // Ausschalten
- aNewAttr.Put(SfxUInt16Item(EE_PARA_BULLETSTATE, 0));
- }
- else
- {
- // Einschalten
- aNewAttr.Put(SfxUInt16Item(EE_PARA_BULLETSTATE, 1));
- }
- }
- else
- {
- // Einschalten
- aNewAttr.Put(SfxUInt16Item(EE_PARA_BULLETSTATE, 1));
- }
- }
- break;
-*/
+// #i35937# removed need for FN_NUM_BULLET_ON handling
}
rReq.Done( aNewAttr );
@@ -610,3 +584,5 @@ void TextObjectBar::Execute( SfxRequest &rReq )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index c867f90d7..2966dc6a3 100755..100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,9 +40,7 @@
#include "cppuhelper/exc_hlp.hxx"
#include "rtl/ref.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/svdpagv.hxx>
#include <sfx2/viewfrm.hxx>
#include <sfx2/bindings.hxx>
@@ -56,16 +55,6 @@
#include <svx/globl3d.hxx>
#include <svx/fmglob.hxx>
#include <editeng/outliner.hxx>
-
-
-#include "misc.hxx"
-
-#ifdef STARIMAGE_AVAILABLE
-#ifndef _SIMDLL_HXX
-#include <sim2/simdll.hxx>
-#endif
-#endif
-
#include <svx/dialogs.hrc>
#include "view/viewoverlaymanager.hxx"
@@ -84,9 +73,7 @@
#include "FrameView.hxx"
#include "stlpool.hxx"
#include "Window.hxx"
-#ifndef SD_DRAWVIEW_HXX
#include "drawview.hxx"
-#endif
#include "drawdoc.hxx"
#include "DrawDocShell.hxx"
#include "Ruler.hxx"
@@ -127,7 +114,7 @@ void DrawViewShell::UIActivating( SfxInPlaceClient* pCli )
{
ViewShell::UIActivating(pCli);
- // #94252# Disable own controls
+ // Disable own controls
maTabControl.Disable();
if (GetLayerTabControl() != NULL)
GetLayerTabControl()->Disable();
@@ -135,7 +122,7 @@ void DrawViewShell::UIActivating( SfxInPlaceClient* pCli )
void DrawViewShell::UIDeactivated( SfxInPlaceClient* pCli )
{
- // #94252# Enable own controls
+ // Enable own controls
maTabControl.Enable();
if (GetLayerTabControl() != NULL)
GetLayerTabControl()->Enable();
@@ -191,7 +178,6 @@ void DrawViewShell::SelectionHasChanged (void)
SID_3D_STATE, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD, &aItem, 0L );
SdrOle2Obj* pOleObj = NULL;
- SdrGrafObj* pGrafObj = NULL;
if ( mpDrawView->AreObjectsMarked() )
{
@@ -211,10 +197,7 @@ void DrawViewShell::SelectionHasChanged (void)
UpdateIMapDlg( pObj );
}
else if (nSdrObjKind == OBJ_GRAF)
- {
- pGrafObj = (SdrGrafObj*) pObj;
UpdateIMapDlg( pObj );
- }
}
}
@@ -275,7 +258,7 @@ void DrawViewShell::SelectionHasChanged (void)
catch( ::com::sun::star::uno::Exception& e )
{
(void)e;
- DBG_ERROR(
+ OSL_FAIL(
(rtl::OString("sd::DrawViewShell::SelectionHasChanged(), "
"exception caught: ") +
rtl::OUStringToOString(
@@ -292,7 +275,7 @@ void DrawViewShell::SelectionHasChanged (void)
GetViewShellBase().GetToolBarManager()->SelectionHasChanged(*this,*mpDrawView);
}
- // #96124# Invalidate for every subshell
+ // Invalidate for every subshell
GetViewShellBase().GetViewShellManager()->InvalidateAllSubShells(this);
mpDrawView->UpdateSelectionClipboard( sal_False );
@@ -605,7 +588,7 @@ SvxRuler* DrawViewShell::CreateVRuler(::sd::Window* pWin)
GetViewFrame()->GetBindings(), aWBits);
pRuler->SetSourceUnit(pWin->GetMapMode().GetMapUnit());
- // #96629# Metric same as HRuler, use document setting
+ // Metric same as HRuler, use document setting
sal_uInt16 nMetric = (sal_uInt16)GetDoc()->GetUIUnit();
if( nMetric == 0xffff )
@@ -721,6 +704,9 @@ SdPage* DrawViewShell::getCurrentPage() const
void DrawViewShell::ResetActualPage()
{
+ if (!GetDoc())
+ return;
+
sal_uInt16 nCurrentPage = maTabControl.GetCurPageId() - 1;
sal_uInt16 nPageCount = (meEditMode == EM_PAGE)?GetDoc()->GetSdPageCount(mePageKind):GetDoc()->GetMasterSdPageCount(mePageKind);
if (nPageCount > 0)
@@ -800,76 +786,6 @@ ErrCode DrawViewShell::DoVerb(long nVerb)
{
ActivateObject( (SdrOle2Obj*) pObj, nVerb);
}
-#ifdef STARIMAGE_AVAILABLE
- else if (nInv = SdrInventor && nSdrObjKind == OBJ_GRAF &&
- ((SdrGrafObj*) pObj)->GetGraphicType() == GRAPHIC_BITMAP &&
- SFX_APP()->HasFeature(SFX_FEATURE_SIMAGE))
- {
- SdrGrafObj* pSdrGrafObj = (SdrGrafObj*) pObj;
- short nOK = RET_YES;
-
- if ( pSdrGrafObj->GetFileName().Len() )
- {
- // Graphik ist gelinkt, soll der Link aufgehoben werden?
- QueryBox aBox(pWindow, WB_YES_NO | WB_DEF_YES,
- String( SdResId(STR_REMOVE_LINK) ) );
- nOK = aBox.Execute();
-
- if (nOK == RET_YES)
- {
- // Link aufheben (File- und Filtername zuruecksetzen)
- pSdrGrafObj->SetGraphicLink(String(), String());
- }
- }
-
- if (nOK == RET_YES)
- {
- /**************************************************************
- * OLE-Objekt erzeugen, StarImage starten
- * Grafik-Objekt loeschen (durch OLE-Objekt ersetzt)
- **************************************************************/
- //HMHmpDrView->HideMarkHdl();
-
- SvStorageRef aStor = new SvStorage(String());
- SvInPlaceObjectRef aNewIPObj = &((SvFactory*)SvInPlaceObject::ClassFactory())
- ->CreateAndInit(SimModuleDummy::GetID(SOFFICE_FILEFORMAT_CURRENT), aStor);
- if ( aNewIPObj.Is() )
- {
- SdrGrafObj* pTempSdrGrafObj = (SdrGrafObj*) pSdrGrafObj->Clone ();
-
- SvEmbeddedInfoObject * pInfo;
- pInfo = GetViewFrame()->GetObjectShell()->
- InsertObject( aNewIPObj, String() );
-
- String aName;
- if (pInfo)
- {
- aName = pInfo->GetObjName();
- }
-
- Rectangle aRect = pObj->GetLogicRect();
- SdrOle2Obj* pSdrOle2Obj = new SdrOle2Obj( aNewIPObj,
- aName, aRect );
-
- SdrPageView* pPV = mpDrawView->GetSdrPageView();
-
- pPV->GetObjList()->InsertObject( pSdrOle2Obj );
- mpDrawView->ReplaceObjectAtView( pObj, *pPV, pTempSdrGrafObj );
-
- pSdrOle2Obj->SetLogicRect(aRect);
- aNewIPObj->SetVisAreaSize(aRect.GetSize());
-
- SimDLL::Update(aNewIPObj, pTempSdrGrafObj->GetGraphic(), pWindow);
- ActivateObject(pSdrOle2Obj, SVVERB_SHOW);
-
- Client* pClient = (Client*) GetIPClient();
-
- if (pClient)
- pClient->SetSdrGrafObj( pTempSdrGrafObj );
- }
- }
- }
-#endif
}
}
@@ -1447,3 +1363,4 @@ sal_Int8 DrawViewShell::ExecuteDrop (
#endif
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index 160f3991d..924988c6d 100755..100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,17 +33,11 @@
#include "ViewShellImplementation.hxx"
#include <vcl/waitobj.hxx>
#include <svx/svdograf.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/svdpagv.hxx>
#include <svx/svdundo.hxx>
-#ifndef _ZOOMITEM_HXX
#include <svx/zoomitem.hxx>
-#endif
-#ifndef _EDITDATA_HXX
#include <editeng/editdata.hxx>
-#endif
#include <basic/sberrors.hxx>
#include <vcl/msgbox.hxx>
#include <sfx2/request.hxx>
@@ -56,9 +51,7 @@
#include <svx/xlineit0.hxx>
#include <svx/xfillit0.hxx>
-#ifndef _SDOUTL_HXX //autogen
#include <svx/svdoutl.hxx>
-#endif
#include <svx/xlnwtit.hxx>
#include <svx/svdoattr.hxx>
#include <svx/xlnstwit.hxx>
@@ -90,7 +83,6 @@
#include "fuvect.hxx"
#include "stlpool.hxx"
-// #90356#
#include "optsitem.hxx"
#include "sdabstdlg.hxx"
#include <com/sun/star/drawing/XMasterPagesSupplier.hpp>
@@ -130,6 +122,31 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
switch ( nSId )
{
+ case SID_OUTLINE_TEXT_AUTOFIT:
+ {
+ ::svl::IUndoManager* pUndoManager = GetDocSh()->GetUndoManager();
+ SdrObject* pObj = NULL;
+ const SdrMarkList& rMarkList = mpDrawView->GetMarkedObjectList();
+ if( rMarkList.GetMarkCount() == 1 )
+ {
+ pUndoManager->EnterListAction( String(), String() );
+ mpDrawView->BegUndo();
+
+ pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
+ bool bSet = ((const SdrTextFitToSizeTypeItem*)pObj->GetMergedItemSet().GetItem(SDRATTR_TEXT_FITTOSIZE))->GetValue() != SDRTEXTFIT_NONE;
+
+ mpDrawView->AddUndo(GetDoc()->GetSdrUndoFactory().CreateUndoAttrObject(*pObj));
+
+ pObj->SetMergedItem(SdrTextFitToSizeTypeItem(bSet ? SDRTEXTFIT_NONE : SDRTEXTFIT_AUTOFIT));
+
+ mpDrawView->EndUndo();
+ pUndoManager->LeaveListAction();
+ }
+ Cancel();
+ rReq.Done();
+ }
+ break;
+
// Flaechen und Linien-Attribute:
// Sollten (wie StateMethode) eine eigene
// Execute-Methode besitzen
@@ -153,7 +170,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
sal_Bool bMergeUndo = sal_False;
::svl::IUndoManager* pUndoManager = GetDocSh()->GetUndoManager();
- // Anpassungen Start/EndWidth #63083#
+ // Anpassungen Start/EndWidth
if(nSId == SID_ATTR_LINE_WIDTH)
{
SdrObject* pObj = NULL;
@@ -174,7 +191,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
{
sal_Bool bSetItemSet(sal_False);
- // #86265# do this for SFX_ITEM_DEFAULT and for SFX_ITEM_SET
+ // do this for SFX_ITEM_DEFAULT and for SFX_ITEM_SET
if(SFX_ITEM_DONTCARE != aAttr.GetItemState(XATTR_LINESTARTWIDTH))
{
sal_Int32 nValAct = ((const XLineStartWidthItem&)aAttr.Get(XATTR_LINESTARTWIDTH)).GetValue();
@@ -185,7 +202,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
aAttr.Put(XLineStartWidthItem(nValNew));
}
- // #86265# do this for SFX_ITEM_DEFAULT and for SFX_ITEM_SET
+ // do this for SFX_ITEM_DEFAULT and for SFX_ITEM_SET
if(SFX_ITEM_DONTCARE != aAttr.GetItemState(XATTR_LINEENDWIDTH))
{
sal_Int32 nValAct = ((const XLineEndWidthItem&)aAttr.Get(XATTR_LINEENDWIDTH)).GetValue();
@@ -305,7 +322,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
}
else // nur zum Test
{
- DBG_ERROR(" Kein Wert fuer Silbentrennung!");
+ OSL_FAIL(" Kein Wert fuer Silbentrennung!");
SfxItemSet aSet( GetPool(), EE_PARA_HYPHENATE, EE_PARA_HYPHENATE );
sal_Bool bValue = sal_True;
aSet.Put( SfxBoolItem( EE_PARA_HYPHENATE, bValue ) );
@@ -594,7 +611,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD );
break;
case SVX_ZOOM_PAGEWIDTH_NOBORDER:
- DBG_ERROR("sd::DrawViewShell::FuTemporary(), SVX_ZOOM_PAGEWIDTH_NOBORDER not handled!" );
+ OSL_FAIL("sd::DrawViewShell::FuTemporary(), SVX_ZOOM_PAGEWIDTH_NOBORDER not handled!" );
break;
}
rReq.Ignore ();
@@ -974,3 +991,5 @@ SdPage* DrawViewShell::CreateOrDuplicatePage (
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews3.cxx b/sd/source/ui/view/drviews3.cxx
index a2ce7f0a6..d520a8b1c 100755..100644
--- a/sd/source/ui/view/drviews3.cxx
+++ b/sd/source/ui/view/drviews3.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,13 +38,10 @@
#include <editeng/protitem.hxx>
#include <editeng/frmdiritem.hxx>
#include <svx/ruler.hxx>
-#ifndef _SVX_RULERITEM_HXX
+#include <editeng/numitem.hxx>
#include <svx/rulritem.hxx>
-#endif
#include <svx/zoomitem.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/svdpagv.hxx>
#include <sfx2/request.hxx>
#include <sfx2/dispatch.hxx>
@@ -154,8 +152,6 @@ void DrawViewShell::ExecCtrl(SfxRequest& rReq)
{
case SID_SWITCHPAGE: // BASIC
{
- sal_Bool bWasBasic = sal_False;
-
// switch page in running slide show
if(SlideShow::IsRunning(GetViewShellBase()) && rReq.GetArgs())
{
@@ -195,7 +191,6 @@ void DrawViewShell::ExecCtrl(SfxRequest& rReq)
nSelectedPage = (short) nWhatPage;
mePageKind = (PageKind) nWhatKind;
- bWasBasic = sal_True;
}
}
else
@@ -373,7 +368,6 @@ void DrawViewShell::ExecCtrl(SfxRequest& rReq)
case SID_RELOAD:
{
- // #83951#
sal_uInt16 nId = Svx3DChildWindow::GetChildWindowId();
SfxViewFrame* pFrame = GetViewFrame();
@@ -675,7 +669,6 @@ void DrawViewShell::ExecRuler(SfxRequest& rReq)
aEditAttr.Put( rItem );
mpDrawView->SetAttributes( aEditAttr );
- // #91081# Invalidate is missing here
Invalidate(SID_ATTR_TABSTOP);
}
break;
@@ -689,16 +682,75 @@ void DrawViewShell::ExecRuler(SfxRequest& rReq)
const SvxLRSpaceItem& rItem = (const SvxLRSpaceItem&)
pArgs->Get( nId );
- SfxItemSet aEditAttr( GetPool(), EE_PARA_LRSPACE, EE_PARA_LRSPACE );
+ static const sal_uInt16 aWhichTable[]=
+ {
+ EE_PARA_OUTLLEVEL, EE_PARA_OUTLLEVEL,
+ EE_PARA_LRSPACE, EE_PARA_LRSPACE,
+ EE_PARA_NUMBULLET, EE_PARA_NUMBULLET,
+ 0, 0
+ };
+
+ SfxItemSet aEditAttr( GetDoc()->GetPool(),
+ aWhichTable );
+ mpDrawView->GetAttributes( aEditAttr );
nId = EE_PARA_LRSPACE;
SvxLRSpaceItem aLRSpaceItem( rItem.GetLeft(),
rItem.GetRight(), rItem.GetTxtLeft(),
rItem.GetTxtFirstLineOfst(), nId );
- aEditAttr.Put( aLRSpaceItem );
- mpDrawView->SetAttributes( aEditAttr );
- // #92557# Invalidate is missing here
+ const sal_Int16 nOutlineLevel = ((const SfxInt16Item&)aEditAttr.Get( EE_PARA_OUTLLEVEL )).GetValue();
+ const SvxLRSpaceItem& rOrigLRSpaceItem = (const SvxLRSpaceItem&) aEditAttr.Get( EE_PARA_LRSPACE );
+ const SvxNumBulletItem& rNumBulletItem = (const SvxNumBulletItem&) aEditAttr.Get( EE_PARA_NUMBULLET );
+ if( nOutlineLevel != -1 &&
+ rNumBulletItem.GetNumRule() &&
+ rNumBulletItem.GetNumRule()->GetLevelCount() > nOutlineLevel )
+ {
+ const SvxNumberFormat& rFormat = rNumBulletItem.GetNumRule()->GetLevel(nOutlineLevel);
+ SvxNumberFormat aFormat(rFormat);
+
+ // left margin always controls LRSpace item
+ aLRSpaceItem.SetTxtLeft(rItem.GetTxtLeft() - aFormat.GetAbsLSpace());
+
+ // negative first line indent goes to the number
+ // format, positive to the lrSpace item
+ if( rItem.GetTxtFirstLineOfst() < 0 )
+ {
+ aFormat.SetFirstLineOffset(
+ rItem.GetTxtFirstLineOfst()
+ - rOrigLRSpaceItem.GetTxtFirstLineOfst()
+ + aFormat.GetCharTextDistance());
+ aLRSpaceItem.SetTxtFirstLineOfst(0);
+ }
+ else
+ {
+ aFormat.SetFirstLineOffset(0);
+ aLRSpaceItem.SetTxtFirstLineOfst(
+ rItem.GetTxtFirstLineOfst()
+ - aFormat.GetFirstLineOffset()
+ + aFormat.GetCharTextDistance());
+ }
+
+ if( rFormat != aFormat )
+ {
+ // put all items
+ SvxNumBulletItem aNumBulletItem(rNumBulletItem);
+ aNumBulletItem.GetNumRule()->SetLevel(nOutlineLevel,aFormat);
+ aEditAttr.Put( aNumBulletItem );
+ aEditAttr.Put( aLRSpaceItem );
+ mpDrawView->SetAttributes( aEditAttr );
+
+ Invalidate(SID_ATTR_PARA_LRSPACE);
+ break;
+ }
+ }
+
+ // only put lrSpace item
+ SfxItemSet aEditAttrReduced( GetDoc()->GetPool(),
+ EE_PARA_LRSPACE, EE_PARA_LRSPACE );
+ aEditAttrReduced.Put( aLRSpaceItem );
+ mpDrawView->SetAttributes( aEditAttrReduced );
+
Invalidate(SID_ATTR_PARA_LRSPACE);
}
break;
@@ -735,7 +787,6 @@ void DrawViewShell::GetRulerState(SfxItemSet& rSet)
if( mpDrawView->IsTextEdit() )
{
Point aPnt1 = GetActiveWindow()->GetWinViewPos();
- Point aPnt2 = GetActiveWindow()->GetViewOrigin();
Rectangle aMinMaxRect = Rectangle( aPnt1, Size(ULONG_MAX, ULONG_MAX) );
rSet.Put( SfxRectangleItem(SID_RULER_LR_MIN_MAX, aMinMaxRect) );
}
@@ -775,13 +826,25 @@ void DrawViewShell::GetRulerState(SfxItemSet& rSet)
const SvxTabStopItem& rItem = (const SvxTabStopItem&) aEditAttr.Get( EE_PARA_TABS );
rSet.Put( rItem );
- //Rectangle aRect = maMarkRect;
-
const SvxLRSpaceItem& rLRSpaceItem = (const SvxLRSpaceItem&) aEditAttr.Get( EE_PARA_LRSPACE );
sal_uInt16 nId = SID_ATTR_PARA_LRSPACE;
SvxLRSpaceItem aLRSpaceItem( rLRSpaceItem.GetLeft(),
rLRSpaceItem.GetRight(), rLRSpaceItem.GetTxtLeft(),
rLRSpaceItem.GetTxtFirstLineOfst(), nId );
+
+ const sal_Int16 nOutlineLevel = ((const SfxInt16Item&)aEditAttr.Get( EE_PARA_OUTLLEVEL )).GetValue();
+ const SvxNumBulletItem& rNumBulletItem = (const SvxNumBulletItem&) aEditAttr.Get( EE_PARA_NUMBULLET );
+ if( nOutlineLevel != -1 &&
+ rNumBulletItem.GetNumRule() &&
+ rNumBulletItem.GetNumRule()->GetLevelCount() > nOutlineLevel )
+ {
+ const SvxNumberFormat& rFormat = rNumBulletItem.GetNumRule()->GetLevel(nOutlineLevel);
+ aLRSpaceItem.SetTxtLeft(rFormat.GetAbsLSpace() + rLRSpaceItem.GetTxtLeft());
+ aLRSpaceItem.SetTxtFirstLineOfst(
+ rLRSpaceItem.GetTxtFirstLineOfst() + rFormat.GetFirstLineOffset()
+ - rFormat.GetCharTextDistance());
+ }
+
rSet.Put( aLRSpaceItem );
Point aPos( aPagePos + maMarkRect.TopLeft() );
@@ -849,7 +912,6 @@ void DrawViewShell::GetRulerState(SfxItemSet& rSet)
{
rSet.DisableItem( SID_RULER_OBJECT );
rSet.DisableItem( EE_PARA_TABS );
-// rSet.DisableItem( SID_RULER_TEXT_RIGHT_TO_LEFT );
}
rSet.Put( aLRSpace );
@@ -924,27 +986,16 @@ void DrawViewShell::GetSnapItemState( SfxItemSet &rSet )
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::AddWindow (::sd::Window* pWin)
{
mpDrawView->AddWindowToPaintView(pWin);
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::RemoveWindow(::sd::Window* pWin)
{
mpDrawView->DeleteWindowFromPaintView(pWin);
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews4.cxx b/sd/source/ui/view/drviews4.cxx
index d513a7718..aa5ef82b3 100755..100644
--- a/sd/source/ui/view/drviews4.cxx
+++ b/sd/source/ui/view/drviews4.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,20 +38,12 @@
#include <svx/svdundo.hxx>
#include <svx/fmglob.hxx>
#include <editeng/eeitem.hxx>
-#ifndef _FLDITEM_HXX
#include <editeng/flditem.hxx>
-#endif
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/ruler.hxx>
-#ifndef _GLOBL3D_HXX
#include <svx/globl3d.hxx>
-#endif
#include <editeng/outliner.hxx>
-#ifndef _SFX_CLIENTSH_HXX
#include <sfx2/ipclient.hxx>
-#endif
#include <sfx2/request.hxx>
#include <sfx2/dispatch.hxx>
#include <svx/svdopath.hxx>
@@ -80,7 +73,6 @@
#include <svx/bmpmask.hxx>
#include "LayerTabBar.hxx"
-// #97016# IV
#include <svx/svditer.hxx>
namespace sd {
@@ -115,7 +107,7 @@ void DrawViewShell::DeleteActualPage()
}
catch( Exception& )
{
- DBG_ERROR("SelectionManager::DeleteSelectedMasterPages(), exception caught!");
+ OSL_FAIL("SelectionManager::DeleteSelectedMasterPages(), exception caught!");
}
}
@@ -164,7 +156,6 @@ sal_Bool DrawViewShell::KeyInput (const KeyEvent& rKEvt, ::sd::Window* pWin)
if ( !IsInputLocked() || ( rKEvt.GetKeyCode().GetCode() == KEY_ESCAPE ) )
{
- // #97016# IV
if(KEY_RETURN == rKEvt.GetKeyCode().GetCode()
&& rKEvt.GetKeyCode().IsMod1()
&& GetView()->IsTextEdit())
@@ -291,7 +282,6 @@ void DrawViewShell::MouseButtonDown(const MouseEvent& rMEvt,
// opened by inplace client and we would deactivate the inplace client,
// the contex menu is closed by VCL asynchronously which in the end
// would work on deleted objects or the context menu has no parent anymore)
- // See #126086# and #128122#
SfxInPlaceClient* pIPClient = GetViewShell()->GetIPClient();
sal_Bool bIsOleActive = ( pIPClient && pIPClient->IsObjectInPlaceActive() );
@@ -352,7 +342,6 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin)
pWin->CaptureMouse();
}
- // #109585#
// Since the next MouseMove may execute a IsSolidDraggingNow() in
// SdrCreateView::MovCreateObj and there the ApplicationBackgroundColor
// is needed it is necessary to set it here.
@@ -440,7 +429,7 @@ void DrawViewShell::MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin)
{
if ( !IsInputLocked() )
{
- FASTBOOL bIsSetPageOrg = mpDrawView->IsSetPageOrg();
+ bool bIsSetPageOrg = mpDrawView->IsSetPageOrg();
if (mbIsRulerDrag)
{
@@ -486,7 +475,6 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
// menu from an inplace client is closed. Now we have the chance to
// deactivate the inplace client without any problem regarding parent
// windows and code on the stack.
- // For more information, see #126086# and #128122#
SfxInPlaceClient* pIPClient = GetViewShell()->GetIPClient();
sal_Bool bIsOleActive = ( pIPClient && pIPClient->IsObjectInPlaceActive() );
if ( bIsOleActive && ( rCEvt.GetCommand() == COMMAND_CONTEXTMENU ))
@@ -552,7 +540,6 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
const SvxFieldItem* pFldItem = NULL;
if( pOLV )
pFldItem = pOLV->GetFieldAtSelection();
- //pFldItem = pOLV->GetFieldUnderMousePointer();
// Hilfslinie
if ( mpDrawView->PickHelpLine( aMPos, nHitLog, *GetActiveWindow(), nHelpLine, pPV) )
@@ -575,7 +562,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
{
LanguageType eLanguage( LANGUAGE_SYSTEM );
- // #101743# Format popup with outliner language, if possible
+ // Format popup with outliner language, if possible
if( pOLV->GetOutliner() )
{
ESelection aSelection( pOLV->GetSelection() );
@@ -594,7 +581,6 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
if( pField )
{
SvxFieldItem aFieldItem( *pField, EE_FEATURE_FIELD );
- //pOLV->DeleteSelected(); <-- fehlt leider !
// Feld selektieren, so dass es beim Insert geloescht wird
ESelection aSel = pOLV->GetSelection();
sal_Bool bSel = sal_True;
@@ -638,8 +624,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
if( ( rCEvt.IsMouseEvent() && pOutlinerView->IsWrongSpelledWordAtPos(aPos) ) ||
( !rCEvt.IsMouseEvent() && pOutlinerView->IsCursorAtWrongSpelledWord() ) )
{
- // #91457# Popup for Online-Spelling now handled by DrawDocShell
- // Link aLink = LINK(GetDoc(), SdDrawDocument, OnlineSpellCallback);
+ // Popup for Online-Spelling now handled by DrawDocShell
Link aLink = LINK(GetDocSh(), DrawDocShell, OnlineSpellCallback);
if( !rCEvt.IsMouseEvent() )
@@ -679,9 +664,13 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
{
switch ( nId )
{
+ case OBJ_OUTLINETEXT:
+ nSdResId = bGraphicShell ? RID_GRAPHIC_OUTLINETEXTOBJ_POPUP :
+ RID_DRAW_OUTLINETEXTOBJ_POPUP;
+ break;
+
case OBJ_CAPTION:
case OBJ_TITLETEXT:
- case OBJ_OUTLINETEXT:
case OBJ_TEXT:
nSdResId = bGraphicShell ? RID_GRAPHIC_TEXTOBJ_POPUP :
RID_DRAW_TEXTOBJ_POPUP;
@@ -750,7 +739,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
break;
}
}
- else if( nInv == E3dInventor /*&& nId == E3D_POLYSCENE_ID*/)
+ else if( nInv == E3dInventor )
{
if( nId == E3D_POLYSCENE_ID || nId == E3D_SCENE_ID )
{
@@ -788,7 +777,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
RID_DRAW_NOSEL_POPUP;
}
}
- // Popup-Menue anzeigen
+ // show Popup-Menu
if (nSdResId)
{
GetActiveWindow()->ReleaseMouse();
@@ -797,7 +786,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
GetViewFrame()->GetDispatcher()->ExecutePopup(SdResId(nSdResId));
else
{
- //#106326# don't open contextmenu at mouse position if not opened via mouse
+ //don't open contextmenu at mouse position if not opened via mouse
//middle of the window if nothing is marked
Point aMenuPos(GetActiveWindow()->GetSizePixel().Width()/2
@@ -911,23 +900,11 @@ void DrawViewShell::ShowMousePosInfo(const Rectangle& rRect,
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::LockInput()
{
mnLockCount++;
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::UnlockInput()
{
DBG_ASSERT( mnLockCount, "Input for this shell is not locked!" );
@@ -1005,3 +982,5 @@ void DrawViewShell::ShowSnapLineContextMenu (
#endif
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx
index f34b608ec..5c73e80c0 100755..100644
--- a/sd/source/ui/view/drviews5.cxx
+++ b/sd/source/ui/view/drviews5.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "DrawViewShell.hxx"
#include "PresentationViewShell.hxx"
#include <editeng/outliner.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <sfx2/request.hxx>
#include <sfx2/dispatch.hxx>
#include <svx/svdpagv.hxx>
@@ -93,7 +92,6 @@ void DrawViewShell::ModelHasChanged()
// Damit der Navigator auch einen aktuellen Status bekommt
GetViewFrame()->GetBindings().Invalidate( SID_NAVIGATOR_STATE, sal_True, sal_False );
- //Update3DWindow();
SfxBoolItem aItem( SID_3D_STATE, sal_True );
GetViewFrame()->GetDispatcher()->Execute(
SID_3D_STATE, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD, &aItem, 0L );
@@ -236,8 +234,6 @@ void DrawViewShell::ReadFrameViewData(FrameView* pView)
if (mpDrawView->IsMoveOnlyDragging() != pView->IsMoveOnlyDragging() )
mpDrawView->SetMoveOnlyDragging( pView->IsMoveOnlyDragging() );
-// mpDrawView->SetSlantButShear( pView->IsSlantButShear() );
-
if (mpDrawView->IsNoDragXorPolys() != pView->IsNoDragXorPolys() )
mpDrawView->SetNoDragXorPolys( pView->IsNoDragXorPolys() );
@@ -455,7 +451,7 @@ void DrawViewShell::PrePaint()
void DrawViewShell::Paint(const Rectangle& rRect, ::sd::Window* pWin)
{
- // #103834# Fill var FillColor here to have it available on later call
+ // Fill var FillColor here to have it available on later call
svtools::ColorConfig aColorConfig;
Color aFillColor;
@@ -468,15 +464,15 @@ void DrawViewShell::Paint(const Rectangle& rRect, ::sd::Window* pWin)
aFillColor = Color( aColorConfig.GetColorValue( svtools::DOCCOLOR ).nColor );
}
- /* #97517# This is done before each text edit, so why not do it before every paint.
+ /* This is done before each text edit, so why not do it before every paint.
The default language is only used if the outliner only contains one
character in a symbol font */
GetDoc()->GetDrawOutliner( NULL ).SetDefaultLanguage( GetDoc()->GetLanguage( EE_CHAR_LANGUAGE ) );
- // #103834# Set Application Background color for usage in SdrPaintView(s)
+ // Set Application Background color for usage in SdrPaintView(s)
mpDrawView->SetApplicationBackgroundColor(aFillColor);
- /* #97517# This is done before each text edit, so why not do it before every paint.
+ /* This is done before each text edit, so why not do it before every paint.
The default language is only used if the outliner only contains one
character in a symbol font */
GetDoc()->GetDrawOutliner( NULL ).SetDefaultLanguage( Application::GetSettings().GetLanguage() );
@@ -639,6 +635,7 @@ void DrawViewShell::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence
ChangeEditMode (meEditMode, ! IsLayerModeActive());
ChangeEditMode (meEditMode, ! IsLayerModeActive());
+ ResetActualLayer();
}
void DrawViewShell::VisAreaChanged(const Rectangle& rRect)
@@ -653,9 +650,8 @@ void DrawViewShell::VisAreaChanged(const Rectangle& rRect)
/** If there is a valid controller then create a new instance of
- <type>AccessibleDrawDocumentView</type>. Otherwise delegate this call
- to the base class to return a default object (probably an empty
- reference).
+ <type>AccessibleDrawDocumentView</type>. Otherwise return an empty
+ reference.
*/
::com::sun::star::uno::Reference<
::com::sun::star::accessibility::XAccessible>
@@ -675,11 +671,9 @@ void DrawViewShell::VisAreaChanged(const Rectangle& rRect)
(static_cast< ::com::sun::star::uno::XWeak*>(pDocumentView),
::com::sun::star::uno::UNO_QUERY);
}
- else
- {
- OSL_TRACE ("DrawViewShell::CreateAccessibleDocumentView: no controller");
- return ViewShell::CreateAccessibleDocumentView (pWindow);
- }
+
+ OSL_TRACE ("DrawViewShell::CreateAccessibleDocumentView: no controller");
+ return ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible>();
}
@@ -744,3 +738,5 @@ int DrawViewShell::GetTabLayerCount (void) const
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews6.cxx b/sd/source/ui/view/drviews6.cxx
index 0664d578a..231fc32cf 100755..100644
--- a/sd/source/ui/view/drviews6.cxx
+++ b/sd/source/ui/view/drviews6.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,21 +36,11 @@
#include <vcl/msgbox.hxx>
#include <sfx2/viewfrm.hxx>
#include <svx/svdograf.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
-#ifndef _FONTWORK_HXX
#include <svx/fontwork.hxx>
-#endif
-#ifndef _BMPMASK_HXX
#include <svx/bmpmask.hxx>
-#endif
-#ifndef _SVX_GALBRWS_HXX
#include <svx/galbrws.hxx>
-#endif
-#ifndef _IMAPDLG_HXX
#include <svx/imapdlg.hxx>
-#endif
#include <svx/xftsfit.hxx>
#include <svx/colrctrl.hxx>
#include <svx/f3dchild.hxx>
@@ -57,9 +48,7 @@
#include <svx/extrusionbar.hxx>
#include <svx/fontworkbar.hxx>
#include <svx/tbxcustomshapes.hxx>
-#ifndef _AVMEDIA_MEDIAPLAYER_HXX
#include <avmedia/mediaplayer.hxx>
-#endif
#include "app.hrc"
#include "strings.hrc"
@@ -160,8 +149,6 @@ void DrawViewShell::GetFormTextState(SfxItemSet& rSet)
!((SdrTextObj*) pObj)->HasText() )
{
// automatisches Auf/Zuklappen des FontWork-Dialog; erstmal deaktiviert
-// if ( pDlg )
-// pDlg->SetActive(sal_False);
rSet.DisableItem(XATTR_FORMTXTSTYLE);
rSet.DisableItem(XATTR_FORMTXTADJUST);
@@ -180,7 +167,6 @@ void DrawViewShell::GetFormTextState(SfxItemSet& rSet)
{
if ( pDlg )
{
-// pDlg->SetActive();
pDlg->SetColorTable(GetDoc()->GetColorTable());
}
@@ -214,7 +200,6 @@ void DrawViewShell::ExecAnimationWin( SfxRequest& rReq )
{
AnimationWindow* pAnimWin;
sal_uInt16 nId = AnimationChildWindow::GetChildWindowId();
- //((const SfxUInt16Item&)(rReq.GetArgs()->Get(nSId))).GetValue();
pAnimWin = static_cast<AnimationWindow*>(
GetViewFrame()->GetChildWindow(nId)->GetWindow());
@@ -423,12 +408,6 @@ void DrawViewShell::ExecBmpMask( SfxRequest& rReq )
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::GetBmpMaskState( SfxItemSet& rSet )
{
const SdrMarkList& rMarkList = mpDrawView->GetMarkedObjectList();
@@ -449,7 +428,7 @@ void DrawViewShell::GetBmpMaskState( SfxItemSet& rSet )
pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
// valid graphic object?
- if( pObj && pObj->ISA( SdrGrafObj ) &&
+ if( pObj && pObj->ISA( SdrGrafObj ) &&
!( ((SdrGrafObj*) pObj)->IsEPS() || ((SdrGrafObj*) pObj)->IsRenderGraphic() ) &&
!mpDrawView->IsTextEdit() )
{
@@ -744,3 +723,5 @@ void DrawViewShell::FuTemp04(SfxRequest& rReq)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews7.cxx b/sd/source/ui/view/drviews7.cxx
index fed922cdd..a00c763d6 100755..100644
--- a/sd/source/ui/view/drviews7.cxx
+++ b/sd/source/ui/view/drviews7.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,7 +72,6 @@
#include "res_bmp.hrc"
#include "PresentationViewShell.hxx"
-#include "misc.hxx"
#include "Outliner.hxx"
#include "drawdoc.hxx"
#include "sdresid.hxx"
@@ -220,8 +220,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
{
if (mpDrawView == NULL)
{
- // This assertion and return are here to prevent crashes like that
- // of issue #126202#.
+ // This assertion and return are here to prevent crashes.
DBG_ASSERT(mpDrawView!=NULL, "Please report this assertion to the Impress team.");
return;
}
@@ -237,7 +236,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
rSet.DisableItem( SID_DRAW_TEXT_VERTICAL );
}
- FASTBOOL bConvertToPathPossible = mpDrawView->IsConvertToPathObjPossible(sal_False);
+ bool bConvertToPathPossible = mpDrawView->IsConvertToPathObjPossible(sal_False);
const SdrMarkList& rMarkList = mpDrawView->GetMarkedObjectList();
const sal_uLong nMarkCount = rMarkList.GetMarkCount();
@@ -614,7 +613,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
{
if ( !mpClipEvtLstnr )
{
- // SSA: #108717# avoid clipboard initialization for
+ // avoid clipboard initialization for
// read-only presentation views (workaround for NT4.0
// clipboard prob...)
if( !ISA(PresentationViewShell) )
@@ -652,9 +651,8 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
if (mpDrawView == NULL)
{
- // When we come to this line then we probably have another
- // incarnation of issue #126202#. The mpDrawView was not NULL but is
- // now. The reason for this may be that the DrawViewShell has been
+ // The mpDrawView was not NULL but is now.
+ // The reason for this may be that the DrawViewShell has been
// destroyed in the mean time.
// We can only return immediately and hope that the deleted
// DrawViewShell is not called again.
@@ -924,7 +922,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
{
OutlinerView* pOlView = mpDrawView->GetTextEditOutlinerView();
- // Sonderbehandlung für SID_OUTLINE_BULLET wenn Objekte
+ // Sonderbehandlung f�r SID_OUTLINE_BULLET wenn Objekte
// mit unterschiedlichen arten von NumBullet Items markiert
// sind
sal_Bool bHasOutliner = sal_False;
@@ -1278,12 +1276,6 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
{
rSet.DisableItem( SID_INSERT_DIAGRAM );
}
-#ifdef STARIMAGE_AVAILABLE
- if (!(pApp->HasFeature(SFX_FEATURE_SIMAGE)))
- {
- rSet.DisableItem( SID_INSERT_IMAGE );
- }
-#endif
if (!SvtModuleOptions().IsMath())
{
rSet.DisableItem( SID_INSERT_MATH );
@@ -1358,22 +1350,6 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
}
}
- // #i102735# discussed with CL: removed for performance reasons
- #if 0
- if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_INSERT_SOUND ) ||
- SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_INSERT_VIDEO ) )
- {
- ///////////////////////////////////////////////////////////////////////
- // Menuoption : Insert->Object->Sound and Insert->Object->Video
- // diable, if there isn't installed any appropriate plugin
- //
- if (!SvxPluginFileDlg::IsAvailable (SID_INSERT_SOUND))
- rSet.DisableItem (SID_INSERT_SOUND);
- if (!SvxPluginFileDlg::IsAvailable (SID_INSERT_VIDEO))
- rSet.DisableItem (SID_INSERT_VIDEO);
- }
- #endif
-
///////////////////////////////////////////////////////////////////////
// Menuoption: Change->Convert->To Bitmap, Change->Convert->To Metafile
// disable, if there only Bitmap or Metafiles marked
@@ -1441,9 +1417,6 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
default:
break;
}
-
- // #i25616# bFoundObjNoLine = sal_True;
- // #i25616# bFoundObjNoArea = sal_True;
break;
case OBJ_TABLE:
bFoundTable = true;
@@ -1490,11 +1463,6 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
rSet.DisableItem (SID_ATTR_GRAF_CROP);
}
- // #96090# moved SID_UNDO to ViewShell::GetMenuState()
- // #96090# moved SID_REDO to ViewShell::GetMenuState()
- // #96090# moved SID_GETUNDOSTRINGS to ViewShell::GetMenuState()
- // #96090# moved SID_GETREDOSTRINGS to ViewShell::GetMenuState()
-
///////////////////////////////////////////////////////////////////////
// Menuoption: Edit->Hyperlink
// Disable, if there is no hyperlink
@@ -1626,7 +1594,7 @@ void DrawViewShell::GetModeSwitchingMenuState (SfxItemSet &rSet)
rSet.Put(SfxBoolItem(SID_HANDOUTMODE, sal_False));
}
- // #101976# Removed [GetDocSh()->GetCurrentFunction() ||] from the following
+ // Removed [GetDocSh()->GetCurrentFunction() ||] from the following
// clause because the current function of the docshell can only be
// search and replace or spell checking and in that case switching the
// view mode is allowed.
@@ -1739,3 +1707,5 @@ void DrawViewShell::Execute (SfxRequest& rReq)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews8.cxx b/sd/source/ui/view/drviews8.cxx
index 9dd8de519..f80d3f911 100755..100644
--- a/sd/source/ui/view/drviews8.cxx
+++ b/sd/source/ui/view/drviews8.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,13 +33,9 @@
#include "ViewShellHint.hxx"
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
#include <sfx2/dispatch.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <vcl/msgbox.hxx>
#include <svx/svddef.hxx>
#include <sfx2/bindings.hxx>
@@ -50,7 +47,6 @@
#include "app.hrc"
#include "strings.hrc"
-#include "misc.hxx"
#include "fuzoom.hxx"
#include "fudspord.hxx"
#include "futransf.hxx"
@@ -63,13 +59,9 @@
#include "fuinsert.hxx"
#include "fuprlout.hxx"
#include "fupage.hxx"
-#ifndef SD_FU_OBJECT_ANIMATION_PARAMETERS_HXX
#include "fuoaprms.hxx"
-#endif
#include "fucopy.hxx"
-#ifndef SD_FU_LINE_END_HXX
#include "fulinend.hxx"
-#endif
#include "fusnapln.hxx"
#include "fuolbull.hxx"
#include "fuinsfil.hxx"
@@ -84,7 +76,7 @@
#include "Window.hxx"
#include "drawview.hxx"
#include "zoomlist.hxx"
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <vcl/salbtype.hxx> // FRound
#include <vcl/svapp.hxx>
@@ -358,8 +350,6 @@ void DrawViewShell::FuTemp01(SfxRequest& rReq)
case SID_TWAIN_SELECT:
{
- sal_Bool bDone = sal_False;
-
if( mxScannerManager.is() )
{
try
@@ -370,7 +360,7 @@ void DrawViewShell::FuTemp01(SfxRequest& rReq)
if( aContexts.getLength() )
{
::com::sun::star::scanner::ScannerContext aContext( aContexts.getConstArray()[ 0 ] );
- bDone = mxScannerManager->configureScanner( aContext );
+ mxScannerManager->configureScanner( aContext );
}
}
catch(...)
@@ -475,7 +465,7 @@ void DrawViewShell::ScannerEvent( const ::com::sun::star::lang::EventObject& )
if( !!aScanBmp )
{
- const ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ const SolarMutexGuard aGuard;
SdrPage* pPage = mpDrawView->GetSdrPageView()->GetPage();
Size aBmpSize( aScanBmp.GetPrefSize() ), aPageSize( pPage->GetSize() );
const MapMode aMap100( MAP_100TH_MM );
@@ -555,3 +545,5 @@ void DrawViewShell::ScannerEvent( const ::com::sun::star::lang::EventObject& )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviews9.cxx b/sd/source/ui/view/drviews9.cxx
index 680057fb8..ced5235cb 100755..100644
--- a/sd/source/ui/view/drviews9.cxx
+++ b/sd/source/ui/view/drviews9.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,16 +42,12 @@
#include <svx/xlnwtit.hxx>
#include <sfx2/bindings.hxx>
-#ifndef _SFX_DISPATCH_HXX //autogen
#include <sfx2/dispatch.hxx>
-#endif
#include <svl/intitem.hxx>
#include <sfx2/app.hxx>
#include <sfx2/request.hxx>
#include <svl/stritem.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <svx/xtable.hxx>
#include <svx/gallery.hxx>
#include <vcl/graph.hxx>
@@ -879,3 +876,5 @@ void DrawViewShell::AttrState (SfxItemSet& rSet)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsa.cxx b/sd/source/ui/view/drviewsa.cxx
index 7e69f28c5..e2770161f 100755..100644
--- a/sd/source/ui/view/drviewsa.cxx
+++ b/sd/source/ui/view/drviewsa.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,9 +49,7 @@
#include <svx/zoomslideritem.hxx>
#include <svl/eitem.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <svx/extrusionbar.hxx>
#include <svx/fontworkbar.hxx>
#include <svx/clipfmtitem.hxx>
@@ -90,7 +89,7 @@ using namespace ::com::sun::star::uno;
namespace {
static const ::rtl::OUString MASTER_VIEW_TOOL_BAR_NAME(
- ::rtl::OUString::createFromAscii("masterviewtoolbar"));
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("masterviewtoolbar")));
}
namespace sd {
@@ -141,8 +140,11 @@ void SAL_CALL ScannerEventListener::disposing( const ::com::sun::star::lang::Eve
DrawViewShell::DrawViewShell( SfxViewFrame* pFrame, ViewShellBase& rViewShellBase, ::Window* pParentWindow, PageKind ePageKind, FrameView* pFrameViewArgument )
: ViewShell (pFrame, pParentWindow, rViewShellBase)
, maTabControl(this, pParentWindow)
+, mbIsLayerModeActive(false)
, mbIsInSwitchPage(false)
{
+ ViewShell::doShow();
+
if (pFrameViewArgument != NULL)
mpFrameView = pFrameViewArgument;
else
@@ -166,7 +168,7 @@ DrawViewShell::~DrawViewShell()
if( mxScannerListener.is() )
static_cast< ScannerEventListener* >( mxScannerListener.get() )->ParentDestroyed();
- // #96642# Remove references to items within Svx3DWin
+ // Remove references to items within Svx3DWin
// (maybe do a listening sometime in Svx3DWin)
sal_uInt16 nId = Svx3DChildWindow::GetChildWindowId();
SfxChildWindow* pWindow = GetViewFrame() ? GetViewFrame()->GetChildWindow(nId) : NULL;
@@ -205,7 +207,7 @@ DrawViewShell::~DrawViewShell()
if ( mpClipEvtLstnr )
{
mpClipEvtLstnr->AddRemoveListener( GetActiveWindow(), sal_False );
- mpClipEvtLstnr->ClearCallbackLink(); // #103849# prevent callback if another thread is waiting
+ mpClipEvtLstnr->ClearCallbackLink(); // prevent callback if another thread is waiting
mpClipEvtLstnr->release();
}
@@ -392,7 +394,7 @@ void DrawViewShell::Construct(DrawDocShell* pDocSh, PageKind eInitialPageKind)
if( xMgr.is() )
{
mxScannerManager = ::com::sun::star::uno::Reference< ::com::sun::star::scanner::XScannerManager >(
- xMgr->createInstance( ::rtl::OUString::createFromAscii( "com.sun.star.scanner.ScannerManager" ) ),
+ xMgr->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.scanner.ScannerManager" )) ),
::com::sun::star::uno::UNO_QUERY );
if( mxScannerManager.is() )
@@ -493,7 +495,7 @@ void DrawViewShell::CheckLineTo(SfxRequest& rReq)
{
if(SID_LINETO == rReq.GetSlot() || SID_BEZIERTO == rReq.GetSlot() || SID_MOVETO == rReq.GetSlot() )
{
- DBG_ERROR("DrawViewShell::CheckLineTo: slots SID_LINETO, SID_BEZIERTO, SID_MOVETO no longer supported.");
+ OSL_FAIL("DrawViewShell::CheckLineTo: slots SID_LINETO, SID_BEZIERTO, SID_MOVETO no longer supported.");
}
}
#endif
@@ -772,7 +774,7 @@ void DrawViewShell::GetStatusBarState(SfxItemSet& rSet)
SdrObject* pObj = NULL;
const SdrMarkList& rMarkList = mpDrawView->GetMarkedObjectList();
sal_uLong nMarkCount = rMarkList.GetMarkCount();
- FASTBOOL bOneLayer = sal_True;
+ bool bOneLayer = true;
// Use the first ten selected shapes as a (hopefully
// representative) sample of all shapes of the current page.
@@ -858,3 +860,5 @@ void DrawViewShell::GetAnnotationState (SfxItemSet& rItemSet )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsb.cxx b/sd/source/ui/view/drviewsb.cxx
index 1b10e4b6b..258d9ea35 100755..100644
--- a/sd/source/ui/view/drviewsb.cxx
+++ b/sd/source/ui/view/drviewsb.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,18 +31,13 @@
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <comphelper/processfactory.hxx>
#include <svx/svdlayer.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <sfx2/msgpool.hxx>
-#include <svx/hyprlink.hxx>
#include <sfx2/viewfrm.hxx>
#include <svx/hlnkitem.hxx>
#include <tools/urlobj.hxx>
#include <editeng/eeitem.hxx>
-#ifndef _FLDITEM_HXX
#include <editeng/flditem.hxx>
-#endif
#include <vcl/msgbox.hxx>
#include <sfx2/request.hxx>
#include <sfx2/dispatch.hxx>
@@ -159,8 +155,6 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
}
else
{
- //pDlg->GetAttr( aNewAttr );
- //aLayerName = ((SdAttrLayerName &) aNewAttr.Get (ATTR_LAYER_NAME)).GetValue ();
aLayerTitle = ((SdAttrLayerTitle &) aNewAttr.Get (ATTR_LAYER_TITLE)).GetValue ();
aLayerDesc = ((SdAttrLayerDesc &) aNewAttr.Get (ATTR_LAYER_DESC)).GetValue ();
bIsVisible = ((SdAttrLayerVisible &) aNewAttr.Get (ATTR_LAYER_VISIBLE)).GetValue ();
@@ -204,7 +198,6 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
if ( aPrevLayer == aName )
{
-// nPrevLayer = nLayer;
nPrevLayer = Max(nLayer, (sal_uInt16) 4);
}
}
@@ -553,8 +546,6 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
String aName;
if( GetDocSh()->HasName() )
aName = GetDocSh()->GetMedium()->GetName();
- //else
- // aName = GetDocSh()->GetName();
pFieldItem = new SvxFieldItem( SvxExtFileField( aName ), EE_FEATURE_FIELD );
}
break;
@@ -641,7 +632,6 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
AbstractSdModifyFieldDlg* pDlg = pFact ? pFact->CreateSdModifyFieldDlg(GetActiveWindow(), pFldItem->GetField(), pOLV->GetAttribs() ) : 0;
if( pDlg && pDlg->Execute() == RET_OK )
{
- // #108538#
// To make a correct SetAttribs() call at the utlinerView
// it is necessary to split the actions here
SvxFieldData* pField = pDlg->GetField();
@@ -661,7 +651,7 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
pOLV->InsertField( aFieldItem );
- // #108538# select again for eventual SetAttribs call
+ // select again for eventual SetAttribs call
pOLV->SetSelection( aSel );
}
@@ -678,7 +668,7 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
if(pField)
{
- // #108538# restore selection to original
+ // restore selection to original
if(bSelectionWasModified)
{
aSel.nEndPos--;
@@ -701,7 +691,7 @@ void DrawViewShell::FuTemp02(SfxRequest& rReq)
{
try
{
- com::sun::star::uno::Reference < ::com::sun::star::ui::dialogs::XExecutableDialog > xDialog(::comphelper::getProcessServiceFactory()->createInstance(rtl::OUString::createFromAscii("com.sun.star.comp.ui.XSLTFilterDialog")), com::sun::star::uno::UNO_QUERY);
+ com::sun::star::uno::Reference < ::com::sun::star::ui::dialogs::XExecutableDialog > xDialog(::comphelper::getProcessServiceFactory()->createInstance(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.ui.XSLTFilterDialog"))), com::sun::star::uno::UNO_QUERY);
if( xDialog.is() )
{
xDialog->execute();
@@ -747,7 +737,6 @@ bool DrawViewShell::RenameSlide( sal_uInt16 nPageId, const String & rName )
sal_uInt8 nBgObj = rLayerAdmin.GetLayerID( String( SdResId( STR_LAYER_BCKGRNDOBJ )), sal_False );
SetOfByte aVisibleLayers = mpActualPage->TRG_GetMasterPageVisibleLayers();
- // (#67720#)
::svl::IUndoManager* pManager = GetDoc()->GetDocSh()->GetUndoManager();
ModifyPageUndoAction* pAction = new ModifyPageUndoAction(
GetDoc(), pUndoPage, rName, pUndoPage->GetAutoLayout(),
@@ -877,3 +866,5 @@ void DrawViewShell::ModifyLayer (
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsc.cxx b/sd/source/ui/view/drviewsc.cxx
index 11f5821cf..9f4c16f13 100755..100644
--- a/sd/source/ui/view/drviewsc.cxx
+++ b/sd/source/ui/view/drviewsc.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -32,22 +33,16 @@
#include "ViewShellImplementation.hxx"
#include <vcl/waitobj.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/dialogs.hrc>
-#ifndef _IMAPDLG_HXX
#include <svx/imapdlg.hxx>
-#endif
#include <vcl/msgbox.hxx>
#include <sfx2/request.hxx>
#include <svx/svdogrp.hxx>
#include <svx/svdoole2.hxx>
#include <svx/svdograf.hxx>
#include <svx/svxdlg.hxx>
-#ifndef _BINDING_HXX //autogen
#include <sfx2/bindings.hxx>
-#endif
#include <sfx2/dispatch.hxx>
#include <svx/svdoole2.hxx>
#include <svl/style.hxx>
@@ -60,7 +55,6 @@
#include "app.hrc"
#include "strings.hrc"
#include "helpids.h"
-#include "misc.hxx"
#include "Window.hxx"
#include "imapinfo.hxx"
#include "futempl.hxx"
@@ -69,8 +63,8 @@
#include "drawdoc.hxx"
#include "DrawDocShell.hxx"
#include "drawview.hxx"
-#include "sdabstdlg.hxx"
-#include "brkdlg.hrc"
+#include "sdabstdlg.hxx"
+#include "brkdlg.hrc"
namespace sd {
#define MIN_ACTIONS_FOR_DIALOG 5000 // bei mehr als 1600 Metaobjekten
@@ -126,7 +120,7 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
OSL_ENSURE(pFact, "Dialogdiet fail!");
AbstractSvxObjectNameDialog* pDlg = pFact->CreateSvxObjectNameDialog(NULL, aName);
OSL_ENSURE(pDlg, "Dialogdiet fail!");
-
+
pDlg->SetCheckNameHdl(LINK(this, DrawViewShell, NameObjectHdl));
if(RET_OK == pDlg->Execute())
@@ -205,10 +199,10 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
rReq.Done ();
}
break;
-
+
case SID_COMBINE: // BASIC
{
- // #88224# End text edit to avoid conflicts
+ // End text edit to avoid conflicts
if(mpDrawView->IsTextEdit())
mpDrawView->SdrEndTextEdit();
@@ -245,7 +239,7 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
case SID_POLY_MERGE:
{
- // #88224# End text edit to avoid conflicts
+ // End text edit to avoid conflicts
if(mpDrawView->IsTextEdit())
mpDrawView->SdrEndTextEdit();
@@ -266,7 +260,7 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
case SID_POLY_SUBSTRACT:
{
- // #88224# End text edit to avoid conflicts
+ // End text edit to avoid conflicts
if(mpDrawView->IsTextEdit())
mpDrawView->SdrEndTextEdit();
@@ -287,7 +281,7 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
case SID_POLY_INTERSECT:
{
- // #88224# End text edit to avoid conflicts
+ // End text edit to avoid conflicts
if(mpDrawView->IsTextEdit())
mpDrawView->SdrEndTextEdit();
@@ -368,9 +362,9 @@ void DrawViewShell::FuTemp03(SfxRequest& rReq)
SdrGrafObj* pGraf=PTR_CAST(SdrGrafObj,pObj);
SdrOle2Obj* pOle2=PTR_CAST(SdrOle2Obj,pObj);
if (pGraf!=NULL && pGraf->HasGDIMetaFile())
- nCount += pGraf->GetGraphic().GetGDIMetaFile().GetActionCount();
+ nCount += pGraf->GetGraphic().GetGDIMetaFile().GetActionSize();
if(pOle2!=NULL && pOle2->GetGraphic())
- nCount += pOle2->GetGraphic()->GetGDIMetaFile().GetActionCount();
+ nCount += pOle2->GetGraphic()->GetGDIMetaFile().GetActionSize();
}
// anhand der erm. Summe entscheiden ob mit
@@ -925,7 +919,7 @@ sal_uInt16 DrawViewShell::GetArrayId( sal_uInt16 nSId )
if( mpSlotArray[ i ] == nSId )
return( i );
}
- DBG_ERROR( "Slot im Array nicht gefunden!" );
+ OSL_FAIL( "Slot im Array nicht gefunden!" );
return( USHRT_MAX );
}
@@ -963,13 +957,8 @@ void DrawViewShell::UpdateIMapDlg( SdrObject* pObj )
// TargetListe kann von uns wieder geloescht werden
if ( pTargetList )
{
- String* pEntry = pTargetList->First();
- while( pEntry )
- {
- delete pEntry;
- pEntry = pTargetList->Next();
- }
-
+ for ( size_t i = 0, n = pTargetList->size(); i < n; ++i )
+ delete pTargetList->at( i );
delete pTargetList;
}
}
@@ -988,3 +977,5 @@ IMPL_LINK( DrawViewShell, NameObjectHdl, AbstractSvxNameDialog*, pDialog )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsd.cxx b/sd/source/ui/view/drviewsd.cxx
index 65da04ed9..ba80c4ac0 100755..100644
--- a/sd/source/ui/view/drviewsd.cxx
+++ b/sd/source/ui/view/drviewsd.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "DrawViewShell.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svl/aeitem.hxx>
#include <svl/stritem.hxx>
#include <sfx2/docfile.hxx>
@@ -52,9 +51,7 @@
#include "slideshow.hxx"
#include "pgjump.hxx"
#include "NavigatorChildWindow.hxx"
-#ifndef SD_NAVIGATION_HXX
#include "navigatr.hxx"
-#endif
#include "drawview.hxx"
#include "slideshow.hxx"
@@ -257,3 +254,5 @@ void DrawViewShell::GetNavigatorWinState( SfxItemSet& rSet )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx
index 2ad25c583..733af6756 100755..100644
--- a/sd/source/ui/view/drviewse.cxx
+++ b/sd/source/ui/view/drviewse.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124,7 +125,7 @@ namespace sd {
void ImpAddPrintableCharactersToTextEdit(SfxRequest& rReq, ::sd::View* pView)
{
- // #98198# evtl. feed characters to activated textedit
+ // evtl. feed characters to activated textedit
const SfxItemSet* pSet = rReq.GetArgs();
if(pSet)
@@ -182,7 +183,7 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
Invalidate();
- // #98198# evtl. feed characters to activated textedit
+ // evtl. feed characters to activated textedit
if(SID_ATTR_CHAR == nSId && GetView() && GetView()->IsTextEdit())
ImpAddPrintableCharactersToTextEdit(rReq, GetView());
@@ -264,7 +265,7 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
rBindings.Invalidate( SID_TEXT_FITTOSIZE );
rBindings.Invalidate( SID_TEXT_FITTOSIZE_VERTICAL );
- // #98198# evtl. feed characters to activated textedit
+ // evtl. feed characters to activated textedit
if(SID_ATTR_CHAR == nSId && GetView() && GetView()->IsTextEdit())
ImpAddPrintableCharactersToTextEdit(rReq, GetView());
@@ -279,7 +280,6 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
}
break;
- // #98721#
case SID_FM_CREATE_FIELDCONTROL:
{
SFX_REQUEST_ARG( rReq, pDescriptorItem, SfxUnoAnyItem, SID_FM_DATACCESS_DESCRIPTOR, sal_False );
@@ -580,7 +580,7 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
// Jetzt explizit der letzte Slot incl. Update()
Invalidate();
- // #97016# III CTRL-SID_OBJECT_SELECT -> select first draw object if none is selected yet
+ // CTRL-SID_OBJECT_SELECT -> select first draw object if none is selected yet
if(SID_OBJECT_SELECT == nSId && HasCurrentFunction() && (rReq.GetModifier() & KEY_MOD1))
{
if(!GetView()->AreObjectsMarked())
@@ -595,7 +595,7 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq)
}
}
- // #97016# with qualifier construct directly
+ // with qualifier construct directly
if(HasCurrentFunction() && (rReq.GetModifier() & KEY_MOD1))
{
// get SdOptions
@@ -1054,7 +1054,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
{
const SfxItemSet* pReqArgs = rReq.GetArgs();
- // #97516# Remember old ruler state
+ // Remember old ruler state
sal_Bool bOldHasRuler(HasRuler());
if ( pReqArgs )
@@ -1064,7 +1064,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
}
else SetRuler (!HasRuler());
- // #97516# Did ruler state change? Tell that to SdOptions, too.
+ // Did ruler state change? Tell that to SdOptions, too.
sal_Bool bHasRuler(HasRuler());
if(bOldHasRuler != bHasRuler)
@@ -1469,13 +1469,13 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
// #UndoRedo#
case SID_UNDO :
{
- // #96090# moved implementation to BaseClass
+ // moved implementation to BaseClass
ImpSidUndo(sal_True, rReq);
}
break;
case SID_REDO :
{
- // #96090# moved implementation to BaseClass
+ // moved implementation to BaseClass
ImpSidRedo(sal_True, rReq);
}
break;
@@ -1485,6 +1485,24 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
}
}
+void DrawViewShell::FuSupportRotate(SfxRequest &rReq)
+{
+ if( rReq.GetSlot() == SID_TRANSLITERATE_ROTATE_CASE )
+ {
+ ::sd::View* pView = GetView();
+
+ if (!pView)
+ return;
+
+ OutlinerView* pOLV = pView->GetTextEditOutlinerView();
+
+ if (!pOLV)
+ return;
+
+ pOLV->TransliterateText( m_aRotateCase.getNextMode() );
+ }
+}
+
/*************************************************************************
|*
|* URL-Feld einfuegen
@@ -1587,7 +1605,6 @@ void DrawViewShell::InsertURLButton(const String& rURL, const String& rText,
xPropSet->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( "ButtonType" )), Any( form::FormButtonType_URL ) );
if ( ::avmedia::MediaWindow::isMediaURL( rURL ) )
{
- // #105638# OJ
xPropSet->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( "DispatchURLInternal" )), Any( sal_True ) );
}
}
@@ -1621,7 +1638,6 @@ void DrawViewShell::InsertURLButton(const String& rURL, const String& rText,
xPropSet->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( "TargetFrame" )), Any( OUString( rTarget ) ) );
xPropSet->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( "ButtonType" )), Any( form::FormButtonType_URL ) );
- // #105638# OJ
if ( ::avmedia::MediaWindow::isMediaURL( rURL ) )
xPropSet->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( "DispatchURLInternal" )), Any( sal_True ) );
@@ -1658,12 +1674,6 @@ void DrawViewShell::InsertURLButton(const String& rURL, const String& rText,
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::ShowUIControls (bool bVisible)
{
ViewShell::ShowUIControls (bVisible);
@@ -1692,3 +1702,5 @@ void DrawViewShell::StopSlideShow (bool /*bCloseFrame*/)
#endif
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsf.cxx b/sd/source/ui/view/drviewsf.cxx
index 19ae358e6..4b9a3f0d9 100755..100644
--- a/sd/source/ui/view/drviewsf.cxx
+++ b/sd/source/ui/view/drviewsf.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,25 +33,17 @@
#include <com/sun/star/form/FormButtonType.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _GLOBL3D_HXX
#include <svx/globl3d.hxx>
-#endif
#include <svx/hlnkitem.hxx>
#include <editeng/eeitem.hxx>
-#ifndef _FLDITEM_HXX
#include <editeng/flditem.hxx>
-#endif
#include <sfx2/viewfrm.hxx>
#include <svl/whiter.hxx>
#include <svl/eitem.hxx>
#include <svl/itempool.hxx>
#include <sfx2/tplpitem.hxx>
-#ifndef _BINDING_HXX //autogen
#include <sfx2/bindings.hxx>
-#endif
#include <sfx2/app.hxx>
#include <sfx2/templdlg.hxx>
#include <svx/xdef.hxx>
@@ -374,7 +367,6 @@ void DrawViewShell::GetAttrState( SfxItemSet& rSet )
else
{ SfxTemplateItem aItem( nWhich, String() );
aAllSet.Put( aItem, aItem.Which() );
- // rSet.DisableItem( nWhich );
}
}
break;
@@ -495,22 +487,6 @@ void DrawViewShell::GetAttrState( SfxItemSet& rSet )
delete pSet;
}
-// const SdrMarkList& rMarkList = mpDrawView->GetMarkedObjectList();
-// sal_uLong nMarkCount = rMarkList.GetMarkCount();
-// sal_Bool bDisabled = sal_False;
-//
-// for (sal_uLong i = 0;
-// i < nMarkCount && !bDisabled && i < 50; i++)
-// {
-// SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
-//
-// if (pObj->GetObjInventor() == E3dInventor)
-// {
-// bDisabled = sal_True;
-// rSet.ClearItem(SDRATTR_SHADOW);
-// rSet.DisableItem(SDRATTR_SHADOW);
-// }
-// }
}
@@ -574,3 +550,5 @@ sal_Bool DrawViewShell::HasSelection(sal_Bool bText) const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsg.cxx b/sd/source/ui/view/drviewsg.cxx
index a5ac6ee3f..e3d5adafa 100755..100644
--- a/sd/source/ui/view/drviewsg.cxx
+++ b/sd/source/ui/view/drviewsg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,12 +32,8 @@
#include "DrawViewShell.hxx"
#include "ViewShellImplementation.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _IMAPDLG_HXX
#include <svx/imapdlg.hxx>
-#endif
#include <sfx2/request.hxx>
#include <sfx2/dispatch.hxx>
#include <sfx2/viewfrm.hxx>
@@ -60,12 +57,6 @@
namespace sd {
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::ExecIMap( SfxRequest& rReq )
{
// waehrend einer Diashow wird nichts ausgefuehrt!
@@ -97,13 +88,6 @@ void DrawViewShell::ExecIMap( SfxRequest& rReq )
}
}
-
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
void DrawViewShell::GetIMapState( SfxItemSet& rSet )
{
sal_Bool bDisable = sal_True;
@@ -294,3 +278,5 @@ void DrawViewShell::GetOptionsBarState( SfxItemSet& rSet )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsh.cxx b/sd/source/ui/view/drviewsh.cxx
index 4ff073b26..4c5999a14 100755..100644
--- a/sd/source/ui/view/drviewsh.cxx
+++ b/sd/source/ui/view/drviewsh.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,9 +33,7 @@
#include <svl/aeitem.hxx>
#include <svl/itemset.hxx>
#include <sfx2/request.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/fmshell.hxx>
@@ -86,7 +85,7 @@ sal_Bool DrawViewShell::GotoBookmark(const String& rBookmark)
void DrawViewShell::MakeVisible(const Rectangle& rRect, ::Window& rWin)
{
- // #98568# In older versions, if in X or Y the size of the object was
+ // In older versions, if in X or Y the size of the object was
// smaller than the visible area, the user-defined zoom was
// changed. This was decided to be a bug for 6.x, thus I developed a
// version which instead handles X/Y bigger/smaller and visibility
@@ -118,7 +117,7 @@ void DrawViewShell::MakeVisible(const Rectangle& rRect, ::Window& rWin)
}
else
{
- // #98568# allow a mode for move-only visibility without zooming.
+ // allow a mode for move-only visibility without zooming.
const sal_Int32 nPercentBorder(30);
const Rectangle aInnerRectangle(
aVisArea.Left() + ((aVisAreaSize.Width() * nPercentBorder) / 200),
@@ -191,3 +190,5 @@ void DrawViewShell::MakeVisible(const Rectangle& rRect, ::Window& rWin)
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsi.cxx b/sd/source/ui/view/drviewsi.cxx
index 7b146d61c..1a60d7341 100755..100644
--- a/sd/source/ui/view/drviewsi.cxx
+++ b/sd/source/ui/view/drviewsi.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,17 +38,13 @@
#include <svx/svditer.hxx>
#include <editeng/colritem.hxx>
#include <sfx2/viewfrm.hxx>
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/svdundo.hxx>
#include <svx/view3d.hxx>
#include <sfx2/dispatch.hxx>
#include <svx/float3d.hxx>
#include <svx/f3dchild.hxx>
-#ifndef _SVX_DIALOGS_HRC //autogen
#include <svx/dialogs.hrc>
-#endif
#include <vcl/msgbox.hxx>
@@ -205,3 +202,5 @@ void DrawViewShell::AssignFrom3DWindow()
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewsj.cxx b/sd/source/ui/view/drviewsj.cxx
index a6fb60526..50cab4795 100755..100644
--- a/sd/source/ui/view/drviewsj.cxx
+++ b/sd/source/ui/view/drviewsj.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,16 +32,10 @@
#include "DrawViewShell.hxx"
#include <com/sun/star/embed/EmbedMisc.hpp>
#include <svl/aeitem.hxx>
-#ifndef _SVXIDS_HRC //autogen
#include <svx/svxids.hrc>
-#endif
-#ifndef _GLOBL3D_HXX //autogen
#include <svx/globl3d.hxx>
-#endif
#include <editeng/eeitem.hxx>
-#ifndef _FLDITEM_HXX
#include <editeng/flditem.hxx>
-#endif
#include <svx/svdogrp.hxx>
#include <svx/svdograf.hxx>
#include <svx/svdoole2.hxx>
@@ -103,8 +98,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_MEASURE_DLG ) ||
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONNECTION_DLG ) ||
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONNECTION_NEW_ROUTING ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_3D_LATHE ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_3D_LATHE_FAST ) ||
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_SHEAR ) ||
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_1BIT_THRESHOLD ) ||
SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_1BIT_MATRIX ) ||
@@ -137,7 +130,7 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
pObj->TakeObjInfo( aInfoRec );
- // #91929#; don't show original size entry if not possible
+ // don't show original size entry if not possible
if ( pObj->ISA( SdrOle2Obj ) )
{
SdrOle2Obj* pOleObj = PTR_CAST(SdrOle2Obj, pObj);
@@ -165,12 +158,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
{
rSet.DisableItem(SID_UNGROUP);
}
-/*
- if (!pObj->ISA(SdrObjGroup) && !pObj->ISA(SdrGrafObj) && !pObj->ISA(SdrOle2Obj))
- {
- rSet.DisableItem( SID_NAME_GROUP );
- }
-*/
if (!pObj->ISA(SdrGrafObj) ||
((SdrGrafObj*) pObj)->GetGraphicType() != GRAPHIC_BITMAP ||
((SdrGrafObj*) pObj)->IsLinkedGraphic())
@@ -208,9 +195,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
rSet.DisableItem( SID_CHANGEPOLYGON );
}
- if(nInv == SdrInventor && (nId == OBJ_TITLETEXT || nId == OBJ_OUTLINETEXT))
- rSet.DisableItem( SID_TEXTATTR_DLG );
-
if(nInv == SdrInventor && nId == OBJ_TABLE )
{
rSet.DisableItem( SID_TEXTATTR_DLG );
@@ -303,6 +287,12 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
else
rSet.DisableItem( SID_MODIFY_FIELD );
}
+ if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OUTLINE_TEXT_AUTOFIT ) )
+ {
+ const SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
+ const bool bSet = ((const SdrTextFitToSizeTypeItem*)pObj->GetMergedItemSet().GetItem(SDRATTR_TEXT_FITTOSIZE))->GetValue() != SDRTEXTFIT_NONE;
+ rSet.Put(SfxBoolItem(SID_OUTLINE_TEXT_AUTOFIT, bSet));
+ }
rSet.DisableItem( SID_GROUP );
rSet.DisableItem( SID_COMBINE );
@@ -319,32 +309,14 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
if(nMarkCount <= 2)
rSet.DisableItem(SID_DISTRIBUTE_DLG);
-// rSet.ClearItem( SID_BEZIER_EDIT );
-// rSet.DisableItem( SID_BEZIER_EDIT );
rSet.DisableItem( SID_LINEEND_POLYGON );
rSet.DisableItem( SID_ENTER_GROUP );
- // Jetzt (28.10.96) muessen Namen fuer Objekte eindeutig sein
+ // Jetzt muessen Namen fuer Objekte eindeutig sein
rSet.DisableItem( SID_NAME_GROUP );
// #i68101#
rSet.DisableItem( SID_OBJECT_TITLE_DESCRIPTION );
rSet.DisableItem( SID_MODIFY_FIELD );
- if( 1 )
-// if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_ATTR_FILL_STYLE ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_UNGROUP ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_MEASURE_DLG ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONNECTION_DLG ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_COMBINE ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_SHEAR ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_TEXTATTR_DLG ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_3D_LATHE ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_CONVERT_TO_3D_LATHE_FAST ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_LEFT ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_CENTER ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_RIGHT ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_UP ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_MIDDLE ) ||
-// SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_OBJECT_ALIGN_DOWN ) )
{
sal_Bool bText = sal_False;
sal_Bool bLine = sal_False;
@@ -352,7 +324,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
sal_Bool bGraf = sal_False;
sal_Bool bDrawObj = sal_False;
sal_Bool b3dObj = sal_False;
- sal_Bool bTitOutText = sal_False;
bool bTable = false;
sal_Bool bMeasureObj = sal_False;
sal_Bool bEdgeObj = sal_False; // Connector
@@ -392,8 +363,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
case OBJ_GRAF: bGraf = sal_True; break;
- case OBJ_TITLETEXT:
- case OBJ_OUTLINETEXT: bTitOutText = sal_True; break;
case OBJ_TABLE: bTable = true; break;
}
}
@@ -405,17 +374,8 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
bE3dCompoundObject = sal_True;
}
}
- /* Kann wohl raus, da jedes(?) Objekt Text enthalten kann
- if( !bText )
- {
- rSet.DisableItem( SID_CHAR_DLG );
- rSet.DisableItem( SID_PARA_DLG );
- rSet.DisableItem( SID_CHARMAP );
- }
- */
if( bLine && !bText && !bDrawObj &&!b3dObj)
{
- //rSet.DisableItem( SID_ATTRIBUTES_AREA );
rSet.DisableItem( SID_ATTR_FILL_STYLE );
}
if( !bEdgeObj )
@@ -441,7 +401,7 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
{
rSet.DisableItem( SID_UNGROUP );
}
- if( bTitOutText || bTable )
+ if( bTable )
rSet.DisableItem( SID_TEXTATTR_DLG );
if( !bMeasureObj )
@@ -509,8 +469,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
// kein Objekt selektiert
else
{
-// rSet.ClearItem( SID_BEZIER_EDIT );
-
rSet.DisableItem( SID_ENTER_GROUP );
rSet.DisableItem( SID_CUT );
rSet.DisableItem( SID_COPY );
@@ -532,7 +490,6 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
rSet.DisableItem( SID_BEHIND_OBJ );
rSet.DisableItem( SID_CONVERT );
-// rSet.DisableItem( SID_BEZIER_EDIT );
rSet.DisableItem( SID_SIZE_OPTIMAL );
rSet.DisableItem( SID_LINEEND_POLYGON );
rSet.DisableItem( SID_COPYOBJECTS );
@@ -562,3 +519,5 @@ void DrawViewShell::GetMenuStateSel( SfxItemSet &rSet )
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drvwshrg.cxx b/sd/source/ui/view/drvwshrg.cxx
index 2df4ee0c8..e5875c8b3 100755..100644
--- a/sd/source/ui/view/drvwshrg.cxx
+++ b/sd/source/ui/view/drvwshrg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,7 +42,6 @@
#include <svx/tbxcustomshapes.hxx>
#include <svx/svxids.hrc>
-#include <svx/hyprlink.hxx>
#include <svx/hyperdlg.hxx>
#include <avmedia/mediaplayer.hxx>
@@ -67,8 +67,6 @@ using namespace sd;
namespace sd {
-//AF:unused #define TABCONTROL_INITIAL_SIZE 500
-
/*************************************************************************
|*
|* SFX-Slotmap und Standardinterface deklarieren
@@ -88,7 +86,6 @@ SFX_IMPL_INTERFACE(DrawViewShell, SfxShell, SdResId(STR_DRAWVIEWSHELL))
SFX_CHILDWINDOW_REGISTRATION( SvxBmpMaskChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( GalleryChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SvxIMapDlgChildWindow::GetChildWindowId() );
- SFX_CHILDWINDOW_REGISTRATION( SvxHyperlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SvxHlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( ::sd::SpellDialogChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SID_SEARCH_DLG );
@@ -114,7 +111,6 @@ SFX_IMPL_INTERFACE(GraphicViewShell, SfxShell, SdResId(STR_DRAWVIEWSHELL)) //SOH
SFX_CHILDWINDOW_REGISTRATION( SvxBmpMaskChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( GalleryChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SvxIMapDlgChildWindow::GetChildWindowId() );
- SFX_CHILDWINDOW_REGISTRATION( SvxHyperlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SvxHlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( ::sd::SpellDialogChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SID_SEARCH_DLG );
@@ -125,3 +121,5 @@ TYPEINIT1( GraphicViewShell, DrawViewShell );
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/frmview.cxx b/sd/source/ui/view/frmview.cxx
index 9feb5b29f..173e499e9 100755..100644
--- a/sd/source/ui/view/frmview.cxx
+++ b/sd/source/ui/view/frmview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
#include "FrameView.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <com/sun/star/awt/Rectangle.hpp>
#include <com/sun/star/drawing/framework/ResourceId.hpp>
#include <rtl/ustrbuf.hxx>
@@ -182,8 +181,6 @@ FrameView::FrameView(SdDrawDocument* pDrawDoc, FrameView* pFrameView /* = NULK *
SetOrtho( pFrameView->IsOrtho() );
SetEliminatePolyPointLimitAngle( pFrameView->GetEliminatePolyPointLimitAngle() );
SetEliminatePolyPoints( pFrameView->IsEliminatePolyPoints() );
-// #110094#-7
-// SetMasterPagePaintCaching( pFrameView->IsMasterPagePaintCaching() );
SetDesignMode( pFrameView->IsDesignMode() );
SetSolidMarkHdl( pFrameView->IsSolidMarkHdl() );
@@ -351,8 +348,6 @@ void FrameView::Update(SdOptions* pOptions)
SetBigOrtho( pOptions->IsBigOrtho() );
SetOrtho( pOptions->IsOrtho() );
SetEliminatePolyPointLimitAngle( pOptions->GetEliminatePolyPointLimitAngle() );
-// #110094#-7
-// SetMasterPagePaintCaching( pOptions->IsMasterPagePaintCaching() );
GetModel()->SetPickThroughTransparentTextFrames( pOptions->IsPickThrough() );
SetSolidMarkHdl( pOptions->IsSolidMarkHdl() );
@@ -471,7 +466,7 @@ static OUString createHelpLinesString( const SdrHelpLineList& rHelpLines )
aLines.append( (sal_Int32)rPos.Y() );
break;
default:
- DBG_ERROR( "Unsupported helpline Kind!" );
+ OSL_FAIL( "Unsupported helpline Kind!" );
}
}
@@ -491,40 +486,12 @@ void FrameView::WriteUserDataSequence ( ::com::sun::star::uno::Sequence < ::com:
aUserData.addValue( sUNO_View_IsSnapToObjectFrame, makeAny( (sal_Bool)IsOFrmSnap() ) );
aUserData.addValue( sUNO_View_IsSnapToObjectPoints, makeAny( (sal_Bool)IsOPntSnap() ) );
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsSnapLinesVisible ) );
-// pValue->Value <<= (sal_Bool)IsHlplVisible();
-// pValue++;nIndex++;
-
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsDragStripes ) );
-// pValue->Value <<= (sal_Bool)IsDragStripes();
-// pValue++;nIndex++;
-
aUserData.addValue( sUNO_View_IsPlusHandlesAlwaysVisible, makeAny( (sal_Bool)IsPlusHandlesAlwaysVisible() ) );
aUserData.addValue( sUNO_View_IsFrameDragSingles, makeAny( (sal_Bool)IsFrameDragSingles() ) );
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsMarkedHitMovesAlways ) );
-// pValue->Value <<= (sal_Bool)IsMarkedHitMovesAlways();
-// pValue++;nIndex++;
-
aUserData.addValue( sUNO_View_EliminatePolyPointLimitAngle, makeAny( (sal_Int32)GetEliminatePolyPointLimitAngle() ) );
aUserData.addValue( sUNO_View_IsEliminatePolyPoints, makeAny( (sal_Bool)IsEliminatePolyPoints() ) );
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsLineDraft ) );
-// pValue->Value <<= (sal_Bool)IsLineDraft();
-// pValue++;nIndex++;
-
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsFillDraft ) );
-// pValue->Value <<= (sal_Bool)IsFillDraft();
-// pValue++;nIndex++;
-
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsTextDraft ) );
-// pValue->Value <<= (sal_Bool)IsTextDraft();
-// pValue++;nIndex++;
-
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsGrafDraft ) );
-// pValue->Value <<= (sal_Bool)IsGrafDraft();
-// pValue++;nIndex++;
-
Any aAny;
GetVisibleLayers().QueryValue( aAny );
aUserData.addValue( sUNO_View_VisibleLayers, aAny );
@@ -552,23 +519,11 @@ void FrameView::WriteUserDataSequence ( ::com::sun::star::uno::Sequence < ::com:
aUserData.addValue( sUNO_View_SelectedPage, makeAny( (sal_Int16)GetSelectedPage() ) );
aUserData.addValue( sUNO_View_IsLayerMode, makeAny( (sal_Bool)IsLayerMode() ) );
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsQuickEdit ) );
-// pValue->Value <<= (sal_Bool)IsQuickEdit();
-// pValue++;nIndex++;
-
aUserData.addValue( sUNO_View_IsBigHandles, makeAny( (sal_Bool)IsBigHandles() ) );
aUserData.addValue( sUNO_View_IsDoubleClickTextEdit, makeAny( (sal_Bool)IsDoubleClickTextEdit() ) );
aUserData.addValue( sUNO_View_IsClickChangeRotation, makeAny( (sal_Bool)IsClickChangeRotation() ) );
-// pValue->Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( sUNO_View_IsDragWithCopy ) );
-// pValue->Value <<= (sal_Bool)IsDragWithCopy();
-// pValue++;nIndex++;
-
aUserData.addValue( sUNO_View_SlidesPerRow, makeAny( (sal_Int16)GetSlidesPerRow() ) );
-/* #107128# Product managment decided to not make this persistent
- aUserData.addValue( sUNO_View_DrawMode, makeAny( (sal_Int32)GetDrawMode() ) );
- aUserData.addValue( sUNO_View_PreviewDrawMode, makeAny( (sal_Int32)GetPreviewDrawMode() ) );
-*/
aUserData.addValue( sUNO_View_EditModeStandard, makeAny( (sal_Int32)GetViewShEditMode( PK_STANDARD ) ) );
aUserData.addValue( sUNO_View_EditModeNotes, makeAny( (sal_Int32)GetViewShEditMode( PK_NOTES ) ) );
aUserData.addValue( sUNO_View_EditModeHandout, makeAny( (sal_Int32)GetViewShEditMode( PK_HANDOUT ) ) );
@@ -599,7 +554,7 @@ void FrameView::WriteUserDataSequence ( ::com::sun::star::uno::Sequence < ::com:
PropertyValue* pValue = &(rValues.getArray()[nOldLength]);
std::vector< std::pair< OUString, Any > >::iterator aIter( aUserData.begin() );
- for( ; aIter != aUserData.end(); aIter++, pValue++ )
+ for( ; aIter != aUserData.end(); ++aIter, ++pValue )
{
pValue->Name = (*aIter).first;
pValue->Value = (*aIter).second;
@@ -629,7 +584,7 @@ static void createHelpLinesFromString( const rtl::OUString& rLines, SdrHelpLineL
aNewHelpLine.SetKind( SDRHELPLINE_HORIZONTAL );
break;
default:
- DBG_ERROR( "syntax error in snap lines settings string" );
+ OSL_FAIL( "syntax error in snap lines settings string" );
return;
}
@@ -688,10 +643,6 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
sal_Int32 aSnapGridWidthYNum = GetSnapGridWidthY().GetNumerator();
sal_Int32 aSnapGridWidthYDom = GetSnapGridWidthY().GetDenominator();
- EditMode eStandardEditMode;
- EditMode eNotesEditMode;
- EditMode eHandoutEditMode;
-
const com::sun::star::beans::PropertyValue *pValue = rSequence.getConstArray();
for (sal_Int16 i = 0 ; i < nLength; i++, pValue++ )
{
@@ -761,14 +712,7 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SetLayerMode( bBool );
}
}
-/* else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsQuickEdit ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetQuickEdit( bBool );
- }
- }
-*/ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsBigHandles ) ) )
+ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsBigHandles ) ) )
{
if( pValue->Value >>= bBool )
{
@@ -789,43 +733,13 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SetClickChangeRotation( bBool );
}
}
-/* else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsDragWithCopy ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetDragWithCopy( bBool );
- }
- }
-*/ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_SlidesPerRow ) ) )
+ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_SlidesPerRow ) ) )
{
if( pValue->Value >>= nInt16 )
{
SetSlidesPerRow( (sal_uInt16)nInt16 );
}
}
-/* #107128# Product managment decided to not make this persistent
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_DrawMode ) ) )
- {
- if( pValue->Value >>= nInt32 )
- {
- const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings();
- if( rStyleSettings.GetHighContrastMode() )
- continue;
- SetDrawMode( (sal_uLong)nInt32 );
- }
- }
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_PreviewDrawMode ) ) )
- {
- if( pValue->Value >>= nInt32 )
- {
- const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings();
- SvtAccessibilityOptions aAccOptions;
- if( rStyleSettings.GetHighContrastMode() && aAccOptions.GetIsForPagePreviews() )
- continue;
- SetPreviewDrawMode( (sal_uLong)nInt32 );
- }
- }
-*/
else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_EditModeStandard ) ) )
{
if( pValue->Value >>= nInt32 )
@@ -833,7 +747,6 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SdDrawDocument* pDoc = dynamic_cast< SdDrawDocument* >( GetModel() );
if( pDoc && pDoc->GetDocSh() && ( SFX_CREATE_MODE_EMBEDDED == pDoc->GetDocSh()->GetCreateMode() ) )
SetViewShEditMode( (EditMode)nInt32, PK_STANDARD );
- eStandardEditMode = (EditMode)nInt32;
}
}
else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_EditModeNotes ) ) )
@@ -843,7 +756,6 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SdDrawDocument* pDoc = dynamic_cast< SdDrawDocument* >( GetModel() );
if( pDoc && pDoc->GetDocSh() && ( SFX_CREATE_MODE_EMBEDDED == pDoc->GetDocSh()->GetCreateMode() ) )
SetViewShEditMode( (EditMode)nInt32, PK_NOTES );
- eNotesEditMode = (EditMode)nInt32;
}
}
else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_EditModeHandout ) ) )
@@ -853,7 +765,6 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SdDrawDocument* pDoc = dynamic_cast< SdDrawDocument* >( GetModel() );
if( pDoc && pDoc->GetDocSh() && ( SFX_CREATE_MODE_EMBEDDED == pDoc->GetDocSh()->GetCreateMode() ) )
SetViewShEditMode( (EditMode)nInt32, PK_HANDOUT );
- eHandoutEditMode = (EditMode)nInt32;
}
}
else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_VisibleAreaTop ) ) )
@@ -949,21 +860,7 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SetOPntSnap( bBool );
}
}
-/* else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsSnapLinesVisible ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetHlplVisible( bBool );
- }
- }
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsDragStripes ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetDragStripes( bBool );
- }
- }
-*/ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsPlusHandlesAlwaysVisible ) ) )
+ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsPlusHandlesAlwaysVisible ) ) )
{
if( pValue->Value >>= bBool )
{
@@ -977,14 +874,7 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SetFrameDragSingles( bBool );
}
}
-/* else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsMarkedHitMovesAlways ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetMarkedHitMovesAlways( bBool );
- }
- }
-*/ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_EliminatePolyPointLimitAngle ) ) )
+ else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_EliminatePolyPointLimitAngle ) ) )
{
if( pValue->Value >>= nInt32 )
{
@@ -998,36 +888,6 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
SetEliminatePolyPoints( bBool );
}
}
-/*
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsLineDraft ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetLineDraft( bBool );
- }
- }
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsFillDraft ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetFillDraft( bBool );
- }
- }
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsTextDraft ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetTextDraft( bBool );
- }
- }
- else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_IsGrafDraft ) ) )
- {
- if( pValue->Value >>= bBool )
- {
- SetGrafDraft( bBool );
- }
- }
-*/
else if (pValue->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( sUNO_View_ActiveLayer ) ) )
{
if( pValue->Value >>= aString )
@@ -1212,3 +1072,5 @@ bool FrameView::IsNavigatorShowingAllShapes (void) const
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/grviewsh.cxx b/sd/source/ui/view/grviewsh.cxx
index a06a6eb27..15cccdf1e 100755..100644
--- a/sd/source/ui/view/grviewsh.cxx
+++ b/sd/source/ui/view/grviewsh.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,3 +155,5 @@ IMPL_LINK(GraphicViewShell, TabBarSplitHandler, TabBar*, pTabBar)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/makefile.mk b/sd/source/ui/view/makefile.mk
deleted file mode 100644
index 0ee8280d3..000000000
--- a/sd/source/ui/view/makefile.mk
+++ /dev/null
@@ -1,123 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-
-PRJ=..$/..$/..
-
-PROJECTPCH=sd
-PROJECTPCHSOURCE=$(PRJ)$/util$/sd
-PRJNAME=sd
-TARGET=view
-
-AUTOSEG=true
-PRJINC=..$/slidesorter
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- DocumentRenderer.src
-
-SLOFILES = \
- $(SLO)$/sdview.obj \
- $(SLO)$/sdview2.obj \
- $(SLO)$/sdview3.obj \
- $(SLO)$/sdview4.obj \
- $(SLO)$/sdview5.obj \
- $(SLO)$/viewshel.obj \
- $(SLO)$/viewshe2.obj \
- $(SLO)$/viewshe3.obj \
- $(SLO)$/sdwindow.obj \
- $(SLO)$/drviewsh.obj \
- $(SLO)$/drviews1.obj \
- $(SLO)$/drviews2.obj \
- $(SLO)$/drviews3.obj \
- $(SLO)$/drviews4.obj \
- $(SLO)$/drviews5.obj \
- $(SLO)$/drviews6.obj \
- $(SLO)$/drviews7.obj \
- $(SLO)$/drviews8.obj \
- $(SLO)$/drviews9.obj \
- $(SLO)$/drviewsa.obj \
- $(SLO)$/drviewsb.obj \
- $(SLO)$/drviewsc.obj \
- $(SLO)$/drviewsd.obj \
- $(SLO)$/drviewse.obj \
- $(SLO)$/drviewsf.obj \
- $(SLO)$/drviewsg.obj \
- $(SLO)$/drviewsi.obj \
- $(SLO)$/drviewsj.obj \
- $(SLO)$/drvwshrg.obj \
- $(SLO)$/drawview.obj \
- $(SLO)$/grviewsh.obj \
- $(SLO)$/outlnvsh.obj \
- $(SLO)$/outlnvs2.obj \
- $(SLO)$/presvish.obj \
- $(SLO)$/outlview.obj \
- $(SLO)$/tabcontr.obj \
- $(SLO)$/bmcache.obj \
- $(SLO)$/drbezob.obj \
- $(SLO)$/drtxtob.obj \
- $(SLO)$/drtxtob1.obj \
- $(SLO)$/sdruler.obj \
- $(SLO)$/frmview.obj \
- $(SLO)$/clview.obj \
- $(SLO)$/zoomlist.obj \
- $(SLO)$/unmodpg.obj \
- $(SLO)$/DocumentRenderer.obj \
- $(SLO)$/FormShellManager.obj \
- $(SLO)$/GraphicObjectBar.obj \
- $(SLO)$/GraphicViewShellBase.obj \
- $(SLO)$/ImpressViewShellBase.obj \
- $(SLO)$/MediaObjectBar.obj \
- $(SLO)$/Outliner.obj \
- $(SLO)$/OutlinerIterator.obj \
- $(SLO)$/OutlineViewShellBase.obj \
- $(SLO)$/SlideSorterViewShellBase.obj \
- $(SLO)$/PresentationViewShellBase.obj \
- $(SLO)$/ToolBarManager.obj \
- $(SLO)$/UpdateLockManager.obj \
- $(SLO)$/ViewClipboard.obj \
- $(SLO)$/ViewShellBase.obj \
- $(SLO)$/ViewShellImplementation.obj \
- $(SLO)$/ViewShellManager.obj \
- $(SLO)$/ViewShellHint.obj \
- $(SLO)$/ViewTabBar.obj \
- $(SLO)$/WindowUpdater.obj \
- $(SLO)$/viewoverlaymanager.obj
-
-
-# --- Tagets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/sd/source/ui/view/outlnvs2.cxx b/sd/source/ui/view/outlnvs2.cxx
index 12f72ca3b..d3e6e794d 100755..100644
--- a/sd/source/ui/view/outlnvs2.cxx
+++ b/sd/source/ui/view/outlnvs2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,9 +39,7 @@
#include <sfx2/dispatch.hxx>
#include <sfx2/request.hxx>
#include <svl/eitem.hxx>
-#ifndef _ZOOMITEM_HXX //autogen
#include <svx/zoomitem.hxx>
-#endif
#include <vcl/msgbox.hxx>
#include <editeng/eeitem.hxx>
#include <editeng/flditem.hxx>
@@ -84,7 +83,7 @@ namespace sd {
/*************************************************************************
|*
-|* SfxRequests fuer temporaere Funktionen
+|* SfxRequests for temporary functions
|*
\************************************************************************/
@@ -120,7 +119,7 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq)
}
else
{
- // hier den Zoom-Dialog oeffnen
+ // open the zoom dialog here
SetCurrentFunction( FuScale::Create( this, GetActiveWindow(), pOlView, GetDoc(), rReq ) );
}
Cancel();
@@ -155,7 +154,7 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq)
case SID_ZOOM_OUT:
{
SetCurrentFunction( FuZoom::Create(this, GetActiveWindow(), pOlView, GetDoc(), rReq) );
- // Beendet sich selbst, kein Cancel() notwendig!
+ // ends itself, no need for Cancel()!
rReq.Done();
}
break;
@@ -266,12 +265,12 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq)
if ( !(nCntrl & EE_CNTRL_NOCOLORS) )
{
- // Farbansicht ist eingeschaltet: ausschalten
+ // color view is enabled: disable
pOutl->SetControlWord(nCntrl | EE_CNTRL_NOCOLORS);
}
else
{
- // Farbansicht ist ausgeschaltet: einschalten
+ // color view is disabled: enable
pOutl->SetControlWord(nCntrl & ~EE_CNTRL_NOCOLORS);
}
@@ -420,35 +419,7 @@ void OutlineViewShell::FuTemporaryModify(SfxRequest &rReq)
case SID_SET_DEFAULT:
{
- // 1. Selektion merken (kriegt die eselige EditEngine nicht selbst
- // auf die Reihe!)
- // 2. Update auf False (sonst flackert's noch staerker
- // an allen selektierten Absaetzen:
- // a. deren Vorlage nochmal setzen, um absatzweite harte Attribute
- // zu entfernen
- // b. harte Zeichenattribute loeschen
- // 3. Update auf True und Selektion wieder setzen
- /*
- ESelection aEsel= pOutlinerView->GetSelection();
- Outliner* pOutl = pOutlinerView->GetOutliner();
- pOutl->SetUpdateMode(sal_False);
- List* pSelectedParas = pOutlinerView->CreateSelectionList();
- Paragraph* pPara = (Paragraph*)pSelectedParas->First();
- while (pPara)
- {
- sal_uLong nParaPos = pOutl->GetAbsPos(pPara);
- String aName;
- SfxStyleFamily aFamily;
- pOutl->GetStyleSheet(nParaPos, aName, aFamily);
- pOutl->SetStyleSheet(nParaPos, aName, aFamily);
- pOutl->QuickRemoveCharAttribs(nParaPos);
- pPara = (Paragraph*)pSelectedParas->Next();
- }
- delete pSelectedParas;
- pOutl->SetUpdateMode(sal_True);
- pOutlinerView->SetSelection(aEsel);
- */
- pOutlinerView->RemoveAttribs(sal_True); // sal_True = auch Absatzattribute
+ pOutlinerView->RemoveAttribs(sal_True); // sal_True = also paragraph attributes
Cancel();
rReq.Done();
}
@@ -548,7 +519,7 @@ void OutlineViewShell::FuTemporaryModify(SfxRequest &rReq)
pOldFldItem->GetField()->ISA( SvxPageField ) ||
pOldFldItem->GetField()->ISA( SvxPagesField )) )
{
- // Feld selektieren, so dass es beim Insert geloescht wird
+ // select field, so it gets deleted on Insert
ESelection aSel = pOutlinerView->GetSelection();
if( aSel.nStartPos == aSel.nEndPos )
aSel.nEndPos++;
@@ -583,8 +554,8 @@ void OutlineViewShell::FuTemporaryModify(SfxRequest &rReq)
if( pField )
{
SvxFieldItem aFieldItem( *pField, EE_FEATURE_FIELD );
- //pOLV->DeleteSelected(); <-- fehlt leider !
- // Feld selektieren, so dass es beim Insert geloescht wird
+ //pOLV->DeleteSelected(); <-- unfortunately missing!
+ // select field, so it gets deleted on Insert
ESelection aSel = pOutlinerView->GetSelection();
sal_Bool bSel = sal_True;
if( aSel.nStartPos == aSel.nEndPos )
@@ -596,7 +567,7 @@ void OutlineViewShell::FuTemporaryModify(SfxRequest &rReq)
pOutlinerView->InsertField( aFieldItem );
- // Selektion wird wieder in den Ursprungszustand gebracht
+ // reset selection to original state
if( !bSel )
aSel.nEndPos--;
pOutlinerView->SetSelection( aSel );
@@ -646,3 +617,5 @@ void OutlineViewShell::FuTemporaryModify(SfxRequest &rReq)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/outlnvsh.cxx b/sd/source/ui/view/outlnvsh.cxx
index 389931f4f..2cfed4fee 100755..100644
--- a/sd/source/ui/view/outlnvsh.cxx
+++ b/sd/source/ui/view/outlnvsh.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,7 +35,6 @@
#include <memory>
#include "helpids.h"
#include "app.hrc"
-#include <svx/hyprlink.hxx>
#include <svx/hyperdlg.hxx>
#include <svx/zoomslideritem.hxx>
@@ -106,15 +106,15 @@ using namespace sd;
namespace sd {
-#define MIN_ZOOM 10 // Minimaler Zoomfaktor
-#define MAX_ZOOM 1000 // Maximaler Zoomfaktor
+#define MIN_ZOOM 10 // minimum zoom factor
+#define MAX_ZOOM 1000 // maximum zoom factor
/************************************************************************/
/*************************************************************************
|*
-|* SFX-Slotmap und Standardinterface deklarieren
+|* Declare SFX-Slotmap and standard interface
|*
\************************************************************************/
@@ -128,7 +128,6 @@ SFX_IMPL_INTERFACE(OutlineViewShell, SfxShell, SdResId(STR_OUTLINEVIEWSHELL))
SFX_OBJECTBAR_REGISTRATION( SFX_OBJECTBAR_APPLICATION | SFX_VISIBILITY_DESKTOP | SFX_VISIBILITY_STANDARD | SFX_VISIBILITY_CLIENT | SFX_VISIBILITY_VIEWER | SFX_VISIBILITY_READONLYDOC,
SdResId(RID_DRAW_VIEWER_TOOLBOX) );
SFX_CHILDWINDOW_REGISTRATION( SfxTemplateDialogWrapper::GetChildWindowId() );
- SFX_CHILDWINDOW_REGISTRATION( SvxHyperlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SvxHlinkDlgWrapper::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( ::sd::SpellDialogChildWindow::GetChildWindowId() );
SFX_CHILDWINDOW_REGISTRATION( SID_SEARCH_DLG );
@@ -140,7 +139,7 @@ TYPEINIT1( OutlineViewShell, ViewShell );
/*************************************************************************
|*
-|* gemeinsamer Initialiserungsanteil der beiden Konstruktoren
+|* common initialization part of both constructors
|*
\************************************************************************/
@@ -157,13 +156,13 @@ void OutlineViewShell::Construct(DrawDocShell* )
GetActiveWindow()->SetMaxZoom( MAX_ZOOM );
InitWindows(aViewOrigin, aSize, aWinPos);
pOlView = new OutlineView(GetDocSh(), GetActiveWindow(), this);
- mpView = pOlView; // Pointer der Basisklasse ViewShell
+ mpView = pOlView; // Pointer of base class ViewShell
SetPool( &GetDoc()->GetPool() );
SetZoom(69);
- // Einstellungen der FrameView uebernehmen
+ // Apply settings of FrameView
ReadFrameViewData(mpFrameView);
::Outliner* pOutl = pOlView->GetOutliner();
@@ -209,7 +208,7 @@ Reference<drawing::XDrawSubController> OutlineViewShell::CreateSubController (vo
/*************************************************************************
|*
-|* Standard-Konstruktor, Fenster duerfen nicht automatisch zentrieren
+|* Default constructor, windows must not center themselves automatically
|*
\************************************************************************/
@@ -226,6 +225,8 @@ OutlineViewShell::OutlineViewShell (
mbInitialized(false)
{
+ ViewShell::doShow();
+
if (pFrameViewArgument != NULL)
mpFrameView = pFrameViewArgument;
else
@@ -238,7 +239,7 @@ OutlineViewShell::OutlineViewShell (
/*************************************************************************
|*
-|* Destruktor
+|* Destructor
|*
\************************************************************************/
@@ -253,7 +254,7 @@ OutlineViewShell::~OutlineViewShell()
if ( pClipEvtLstnr )
{
pClipEvtLstnr->AddRemoveListener( GetActiveWindow(), sal_False );
- pClipEvtLstnr->ClearCallbackLink(); // #103849# prevent callback if another thread is waiting
+ pClipEvtLstnr->ClearCallbackLink(); // prevent callback if another thread is waiting
pClipEvtLstnr->release();
}
}
@@ -273,8 +274,8 @@ void OutlineViewShell::Shutdown (void)
/*************************************************************************
|*
-|* Paint-Methode: das Ereignis wird vom Fenster pWindow an
-|* die Viewshell und die aktuelle Funktion weitergeleitet
+|* Paint method: the event gets forwarded from pWindow to the Viewshell
+|* and the current function
|*
\************************************************************************/
@@ -307,13 +308,11 @@ void OutlineViewShell::ArrangeGUIElements ()
{
pWindow->SetMinZoomAutoCalc(sal_False);
- // pWindow->SetPosSizePixel(rNewPos, Size(nSizeX, nSizeY));
- // OutputArea der OutlinerView aendern
+ // change OuputArea of the OutlinerView
OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow);
Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel());
-// aWin.nLeft = pOlView->GetPageNumberWidthPixel();
aWin = pWindow->PixelToLogic(aWin);
pOutlinerView->SetOutputArea(aWin);
@@ -325,7 +324,7 @@ void OutlineViewShell::ArrangeGUIElements ()
pOlView->GetOutliner()->GetTextHeight()));
aText.Bottom() += aWin.GetHeight();
- if (!aWin.IsEmpty()) // nicht beim Oeffnen
+ if (!aWin.IsEmpty()) // not when opening
{
InitWindows(Point(0,0), aText.GetSize(), Point(aVis.TopLeft()));
UpdateScrollBars();
@@ -335,7 +334,7 @@ void OutlineViewShell::ArrangeGUIElements ()
/*************************************************************************
|*
-|* SfxRequests fuer Controller bearbeiten
+|* Handle SfxRequest for the Controller
|*
\************************************************************************/
@@ -384,7 +383,7 @@ void OutlineViewShell::RemoveWindow (::sd::Window* pWin)
/*************************************************************************
|*
-|* Activate(), beim ersten Aufruf erfolgt ein Update der Felder
+|* Activate(): during the first invocation the fields get updated
|*
\************************************************************************/
void OutlineViewShell::Activate( sal_Bool bIsMDIActivate )
@@ -417,16 +416,14 @@ void OutlineViewShell::Deactivate( sal_Bool bIsMDIActivate )
{
pOlView->DisconnectFromApplication();
- // #96416# Links must be kept also on deactivated viewshell, to allow drag'n'drop
+ // Links must be kept also on deactivated viewshell, to allow drag'n'drop
// to function properly
- // pOlView->ResetLinks();
-
ViewShell::Deactivate( bIsMDIActivate );
}
/*************************************************************************
|*
-|* Status von Controller-SfxSlots setzen
+|* Set status of Controller-SfxSlots
|*
\************************************************************************/
void OutlineViewShell::GetCtrlState(SfxItemSet &rSet)
@@ -490,7 +487,7 @@ void OutlineViewShell::GetCtrlState(SfxItemSet &rSet)
/*************************************************************************
|*
-|* SfxRequests fuer Support-Funktionen
+|* SfxRequests for support functions
|*
\************************************************************************/
@@ -514,7 +511,6 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq)
(nSlot == SID_TRANSLITERATE_HIRAGANA) ||
(nSlot == SID_TRANSLITERATE_KATAGANA) ||
(nSlot == SID_CUT) ||
-// (nSlot == SID_COPY) ||
(nSlot == SID_PASTE) ||
(nSlot == SID_DELETE)))
{
@@ -615,7 +611,6 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq)
{
if (mpZoomList->IsPreviousPossible())
{
- // Vorheriges ZoomRect einstellen
SetZoomRect(mpZoomList->GetPreviousZoomRect());
}
rReq.Done ();
@@ -626,7 +621,6 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq)
{
if (mpZoomList->IsNextPossible())
{
- // Naechstes ZoomRect einstellen
SetZoomRect(mpZoomList->GetNextZoomRect());
}
rReq.Done ();
@@ -695,7 +689,7 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq)
}
break;
- // #96090# added Undo/Redo handling
+ // added Undo/Redo handling
case SID_UNDO :
{
OutlineViewPageChangesGuard aGuard2(pOlView);
@@ -723,7 +717,7 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq)
/*************************************************************************
|*
-|* SfxRequests fuer permanente Funktionen
+|* SfxRequests for permanent functions
|*
\************************************************************************/
@@ -788,7 +782,7 @@ IMPL_LINK( OutlineViewShell, ClipboardChanged, TransferableDataHelper*, pDataHel
/*************************************************************************
|*
-|* Status (Enabled/Disabled) von Menue-SfxSlots setzen
+|* Set Status (Enabled/Disabled) of Menu-SfxSlots
|*
\************************************************************************/
@@ -796,7 +790,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
{
ViewShell::GetMenuState(rSet);
- // Vorlagenkatalog darf nicht aufgerufen werden
+ // Style catalog must not be called
rSet.DisableItem( SID_STYLE_CATALOG );
rSet.Put(SfxBoolItem(SID_DIAMODE, sal_False));
@@ -828,7 +822,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
if( !pOutl )
return;
- // 'Alles auswaehlen' zulassen?
+ // allow 'Select All'?
if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_SELECTALL ) )
{
sal_uLong nParaCount = pOutl->GetParagraphCount();
@@ -845,17 +839,17 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
rSet.DisableItem(SID_SELECTALL);
}
- // Status des Lineals setzen
+ // set status of Ruler
rSet.Put( SfxBoolItem( SID_RULER, HasRuler() ) );
- // Formatierung ein oder aus?
+ // Enable formatting?
rSet.Put( SfxBoolItem( SID_OUTLINE_FORMAT, !pOutl->IsFlatMode() ) );
if( pOutl->IsFlatMode() )
rSet.DisableItem( SID_COLORVIEW );
else
{
- // Farbansicht ein/aus
+ // Enable color view?
sal_uLong nCntrl = pOutl->GetControlWord();
sal_Bool bNoColor = sal_False;
if (nCntrl & EE_CNTRL_NOCOLORS)
@@ -864,43 +858,53 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
rSet.Put( SfxBoolItem( SID_COLORVIEW, bNoColor ) );
}
- // Buttons der Werkzeugleiste
- // zunaechst selektionsabhaengige: COLLAPSE, EXPAND
+ // Buttons of toolbar
+ // first the selection dependent ones: COLLAPSE, EXPAND
sal_Bool bDisableCollapse = sal_True;
sal_Bool bDisableExpand = sal_True;
sal_Bool bUnique = sal_True;
OutlinerView* pOutlinerView = pOlView->GetViewByWindow(GetActiveWindow());
- List* pList = pOutlinerView->CreateSelectionList();
- Paragraph* pPara = (Paragraph*)pList->First();
- sal_Int16 nDepth;
- sal_Int16 nTmpDepth = pOutl->GetDepth( (sal_uInt16) pOutl->GetAbsPos( pPara ) );
- bool bPage = pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE );
- while (pPara)
+ std::vector<Paragraph*> aSelList;
+ pOutlinerView->CreateSelectionList(aSelList);
+
+ if (!aSelList.empty())
{
- nDepth = pOutl->GetDepth( (sal_uInt16) pOutl->GetAbsPos( pPara ) );
+ std::vector<Paragraph*>::const_iterator iter = aSelList.begin();
+ Paragraph* pPara = *iter;
- if( nDepth != nTmpDepth )
- bUnique = sal_False;
- if( bPage != pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE ) )
- bUnique = sal_False;
- if (!pOutl->IsExpanded(pPara) && pOutl->HasChilds(pPara))
- bDisableExpand = sal_False;
- if (pOutl->IsExpanded(pPara) && pOutl->HasChilds(pPara))
- bDisableCollapse = sal_False;
+ sal_Int16 nDepth;
+ sal_Int16 nTmpDepth = pOutl->GetDepth( (sal_uInt16) pOutl->GetAbsPos( pPara ) );
+ bool bPage = pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE );
- pPara = (Paragraph*)pList->Next();
- }
+ while (iter != aSelList.begin())
+ {
+ pPara = *iter;
- delete pList;
+ nDepth = pOutl->GetDepth( (sal_uInt16) pOutl->GetAbsPos( pPara ) );
+
+ if( nDepth != nTmpDepth || bPage != pOutl->HasParaFlag( pPara, PARAFLAG_ISPAGE ))
+ bUnique = sal_False;
+
+ if (pOutl->HasChilds(pPara))
+ {
+ if (!pOutl->IsExpanded(pPara))
+ bDisableExpand = sal_False;
+ else
+ bDisableCollapse = sal_False;
+ }
+
+ ++iter;
+ }
+ }
if (bDisableExpand)
rSet.DisableItem(SID_OUTLINE_EXPAND);
if (bDisableCollapse)
rSet.DisableItem(SID_OUTLINE_COLLAPSE);
- // ergibt die Selektion ein eindeutiges Praesentationslayout?
- // wenn nicht, duerfen die Vorlagen nicht bearbeitet werden
+ // does the selection provide a unique presentation layout?
+ // if not, the templates must not be edited
SfxItemSet aSet(*rSet.GetPool(), SID_STATUS_LAYOUT, SID_STATUS_LAYOUT);
GetStatusBarState(aSet);
String aTest(((SfxStringItem&)aSet.Get(SID_STATUS_LAYOUT)).GetValue());
@@ -913,21 +917,21 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
if (!bUnique)
rSet.DisableItem( SID_PRESENTATIONOBJECT );
- // jetzt die selektionsunabhaengigen: COLLAPSE_ALL, EXPAND_ALL
+ // now the selection independent ones: COLLAPSE_ALL, EXPAND_ALL
sal_Bool bDisableCollapseAll = sal_True;
sal_Bool bDisableExpandAll = sal_True;
- // wenn schon die Selektion etwas kollabierbares/expandierbares enthaelt
+ // does the selection contain something collapsable/expandable?
if (!bDisableCollapse)
bDisableCollapseAll = sal_False;
if (!bDisableExpand)
bDisableExpandAll = sal_False;
- // schade, so billig kommen wir nicht davon; alle Absaetze durchsuchen
+ // otherwise look through all paragraphs
if (bDisableCollapseAll || bDisableExpandAll)
{
sal_uLong nParaPos = 0;
- pPara = pOutl->GetParagraph( nParaPos );
+ Paragraph* pPara = pOutl->GetParagraph( nParaPos );
while (pPara && (bDisableCollapseAll || bDisableExpandAll))
{
if (!pOutl->IsExpanded(pPara) && pOutl->HasChilds(pPara))
@@ -979,7 +983,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
GetDoc()->SetChanged(sal_True);
}
- // Da �berladen, muss hier der Status gesetzt werden
+ // the status has to be set here because of overloading
if( !GetDocSh()->IsModified() )
{
rSet.DisableItem( SID_SAVEDOC );
@@ -1001,7 +1005,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
}
}
- // Feldbefehle
+ // field commands
if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_MODIFY_FIELD ) )
{
const SvxFieldItem* pFldItem = pOutlinerView->GetFieldAtSelection();
@@ -1111,7 +1115,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
}
}
- // Starten der Praesentation moeglich?
+ // is starting the presentation possible?
if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_PRESENTATION ) )
{
sal_Bool bDisable = sal_True;
@@ -1132,14 +1136,11 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
FuBullet::GetSlotState( rSet, this, GetViewFrame() );
- //rSet.DisableItem( SID_PRINTDOC );
- //rSet.DisableItem( SID_PRINTDOCDIRECT );
- //rSet.DisableItem( SID_SETUPPRINTER );
}
/*************************************************************************
|*
-|* wird gerufen, wenn ScrollBar benutzt wird
+|* gets invoked when ScrollBar is used
|*
\************************************************************************/
@@ -1167,12 +1168,6 @@ long OutlineViewShell::VirtHScrollHdl(ScrollBar* pHScroll)
return 0;
}
-/*************************************************************************
-|*
-|* wird gerufen, wenn ScrollBar benutzt wird
-|*
-\************************************************************************/
-
long OutlineViewShell::VirtVScrollHdl(ScrollBar* pVScroll)
{
long nThumb = pVScroll->GetThumbPos();
@@ -1200,8 +1195,8 @@ long OutlineViewShell::VirtVScrollHdl(ScrollBar* pVScroll)
/*************************************************************************
|*
-|* PrepareClose, wird gerufen, wenn die Shell zestoert werden soll,
-|* leitet den Aufruf an die View weiter
+|* PrepareClose, gets called when the Shell shall be destroyed.
+|* Forwards the invocation to the View
|*
\************************************************************************/
@@ -1216,7 +1211,7 @@ sal_uInt16 OutlineViewShell::PrepareClose( sal_Bool bUI, sal_Bool bForBrowsing )
/*************************************************************************
|*
-|* Zoomen mit Zoomfaktor, OutlinerView informieren
+|* Zoom with zoom factor. Inform OutlinerView
|*
\************************************************************************/
@@ -1227,21 +1222,20 @@ void OutlineViewShell::SetZoom(long nZoom)
::sd::Window* pWindow = mpContentWindow.get();
if (pWindow)
{
- // OutputArea der OutlinerView aendern
+ // change OutputArea of OutlinerView
OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow);
Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel());
aWin = pWindow->PixelToLogic(aWin);
pOutlinerView->SetOutputArea(aWin);
}
- // #106268#
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOM );
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOMSLIDER );
}
/*************************************************************************
|*
-|* Zoomen mit Zoomrechteck, OutlinerView informieren
+|* Zoom with zoom rectangle. Inform OutlinerView
|*
\************************************************************************/
@@ -1252,22 +1246,21 @@ void OutlineViewShell::SetZoomRect(const Rectangle& rZoomRect)
::sd::Window* pWindow = mpContentWindow.get();
if (pWindow)
{
- // OutputArea der OutlinerView aendern
+ // change OutputArea of OutlinerView
OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow);
Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel());
aWin = pWindow->PixelToLogic(aWin);
pOutlinerView->SetOutputArea(aWin);
}
- // #106268#
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOM );
GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOMSLIDER );
}
/*************************************************************************
|*
-|* Vorm Speichern das Model der Drawing Engine aktualisieren, dann den
-|* Call weiterleiten an die ObjectShell.
+|* Before saving: Update Model of the Drawing Engine, then forward the
+|* invocation to the ObjectShell.
|*
\************************************************************************/
@@ -1326,17 +1319,14 @@ void OutlineViewShell::ReadFrameViewData(FrameView* pView)
{
::Outliner* pOutl = pOlView->GetOutliner();
- if ( pView->IsNoAttribs() )
- pOutl->SetFlatMode( sal_True ); // Attribut-Darstellung ausschalten
- else
- pOutl->SetFlatMode( sal_False ); // Attribut-Darstellung einschalten
-
+ pOutl->SetFlatMode( static_cast<bool>(pView->IsNoAttribs()) );
+
sal_uLong nCntrl = pOutl->GetControlWord();
if ( pView->IsNoColors() )
- pOutl->SetControlWord(nCntrl | EE_CNTRL_NOCOLORS); // Farbansicht ausschalten
+ pOutl->SetControlWord(nCntrl | EE_CNTRL_NOCOLORS);
else
- pOutl->SetControlWord(nCntrl & ~EE_CNTRL_NOCOLORS); // Farbansicht einschalten
+ pOutl->SetControlWord(nCntrl & ~EE_CNTRL_NOCOLORS);
sal_uInt16 nPage = mpFrameView->GetSelectedPage();
pLastPage = GetDoc()->GetSdPage( nPage, PK_STANDARD );
@@ -1370,7 +1360,7 @@ void OutlineViewShell::WriteFrameViewData()
/*************************************************************************
|*
-|* SfxRequests fuer StatusBar bearbeiten
+|* Handle SfxRequests for the StatusBar
|*
\************************************************************************/
@@ -1380,7 +1370,7 @@ void OutlineViewShell::ExecStatusBar(SfxRequest&)
/*************************************************************************
|*
-|* Statuswerte der Statusbar zurueckgeben
+|* Return state values of the StatusBar
|*
\************************************************************************/
@@ -1394,7 +1384,7 @@ void OutlineViewShell::GetStatusBarState(SfxItemSet& rSet)
pZoomItem = new SvxZoomItem( SVX_ZOOM_PERCENT, nZoom );
- // Bereich einschraenken
+ // limit area
sal_uInt16 nZoomValues = SVX_ZOOM_ENABLE_ALL;
nZoomValues &= ~SVX_ZOOM_ENABLE_OPTIMAL;
nZoomValues &= ~SVX_ZOOM_ENABLE_WHOLEPAGE;
@@ -1421,20 +1411,26 @@ void OutlineViewShell::GetStatusBarState(SfxItemSet& rSet)
}
- // Seitenanzeige und Layout
- /*
- if( SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_STATUS_PAGE ) ||
- SFX_ITEM_AVAILABLE == rSet.GetItemState( SID_STATUS_LAYOUT ) )
- */
+ // page view and layout
+
sal_uInt16 nPageCount = GetDoc()->GetSdPageCount( PK_STANDARD );
String aPageStr, aLayoutStr;
::sd::Window* pWin = GetActiveWindow();
OutlinerView* pActiveView = pOlView->GetViewByWindow( pWin );
::Outliner* pOutliner = pOlView->GetOutliner();
- List* pSelList = (List*)pActiveView->CreateSelectionList();
- Paragraph* pFirstPara = (Paragraph*)pSelList->First();
- Paragraph* pLastPara = (Paragraph*)pSelList->Last();
+
+ std::vector<Paragraph*> aSelList;
+ pActiveView->CreateSelectionList(aSelList);
+
+ Paragraph *pFirstPara = NULL;
+ Paragraph *pLastPara = NULL;
+
+ if (!aSelList.empty())
+ {
+ pFirstPara = *(aSelList.begin());
+ pLastPara = *(aSelList.rbegin());
+ }
if( !pOutliner->HasParaFlag(pFirstPara,PARAFLAG_ISPAGE) )
pFirstPara = pOlView->GetPrevTitle( pFirstPara );
@@ -1442,12 +1438,10 @@ void OutlineViewShell::GetStatusBarState(SfxItemSet& rSet)
if( !pOutliner->HasParaFlag(pLastPara, PARAFLAG_ISPAGE) )
pLastPara = pOlView->GetPrevTitle( pLastPara );
- delete pSelList; // die wurde extra fuer uns erzeugt
-
- // nur eine Seite selektiert?
+ // only one page selected?
if( pFirstPara == pLastPara )
{
- // wieviele Seiten sind vor der selektierten Seite?
+ // how many pages are we before the selected page?
sal_uLong nPos = 0L;
while( pFirstPara )
{
@@ -1491,8 +1485,7 @@ void OutlineViewShell::Command( const CommandEvent& rCEvt, ::sd::Window* pWin )
if (pOLV && pOLV->IsWrongSpelledWordAtPos(aPos))
{
- // #91457# Popup for Online-Spelling now handled by DrawDocShell
- // Link aLink = LINK(GetDoc(), SdDrawDocument, OnlineSpellCallback);
+ // Popup for Online-Spelling now handled by DrawDocShell
Link aLink = LINK(GetDocSh(), DrawDocShell, OnlineSpellCallback);
pOLV->ExecuteSpellPopup(aPos, &aLink);
@@ -1506,7 +1499,7 @@ void OutlineViewShell::Command( const CommandEvent& rCEvt, ::sd::Window* pWin )
{
ViewShell::Command( rCEvt, pWin );
- // ggfs. Preview den neuen Kontext mitteilen
+ // if necessary communicate the new context to the Preview
Invalidate( SID_PREVIEW_STATE );
}
@@ -1529,7 +1522,7 @@ sal_Bool OutlineViewShell::KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin)
bReturn = GetCurrentFunction()->KeyInput(rKEvt);
}
- // nein, weiterleiten an Basisklasse
+ // no, forward to base class
else
{
bReturn = ViewShell::KeyInput(rKEvt, pWin);
@@ -1543,7 +1536,7 @@ sal_Bool OutlineViewShell::KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin)
Invalidate(SID_STYLE_WATERCAN);
Invalidate(SID_STYLE_FAMILY5);
- // Pruefen und Unterscheiden von CursorBewegungs- oder Eingabe-Keys
+ // check and distinguish cursor movements- or input-keys
KeyCode aKeyGroup( rKEvt.GetKeyCode().GetGroup() );
if( (aKeyGroup != KEYGROUP_CURSOR && aKeyGroup != KEYGROUP_FKEYS) ||
(GetActualPage() != pLastPage) )
@@ -1557,7 +1550,7 @@ sal_Bool OutlineViewShell::KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin)
/*************************************************************************
|*
-|* Optimale Groesse zurueckgeben
+|* Return optimal Size
|*
\************************************************************************/
@@ -1580,17 +1573,16 @@ Size OutlineViewShell::GetOptimalSizePixel() const
}
}
- // und jetzt jetzt das Standardgelumpe draufaddieren
+ // now add the default stuff
aResult.Width() += mpVerticalScrollBar->GetSizePixel().Width();
aResult.Height() += mpHorizontalScrollBar->GetSizePixel().Height();
- //!!! + System::GetMenuBarHeightPixel(); // statt Titlebar
return aResult;
}
/*************************************************************************
|*
-|* Text der Selektion zurueckgeben
+|* Return text of the selection
|*
\************************************************************************/
@@ -1623,7 +1615,7 @@ String OutlineViewShell::GetSelectionText(sal_Bool bCompleteWords)
/*************************************************************************
|*
-|* Ist etwas selektiert?
+|* Is something selected?
|*
\************************************************************************/
@@ -1647,7 +1639,7 @@ sal_Bool OutlineViewShell::HasSelection(sal_Bool bText) const
/*************************************************************************
|*
-|* Status der Attribut-Items
+|* Status of Attribute-Items
|*
\************************************************************************/
@@ -1708,7 +1700,7 @@ void OutlineViewShell::GetAttrState( SfxItemSet& rSet )
if (!aRealStyle.Len())
{
- // Kein eindeutiger Layoutname gefunden
+ // no unique layout name found
rSet.DisableItem(nWhich);
}
}
@@ -1723,8 +1715,8 @@ void OutlineViewShell::GetAttrState( SfxItemSet& rSet )
if (aESel.nStartPara != aESel.nEndPara ||
aESel.nStartPos != aESel.nEndPos)
- // aufgespannte Selektion, also StyleSheet und/oder
- // Attributierung nicht zwingend eindeutig
+ // spanned selection, i.e. StyleSheet and/or
+ // attribution not necessarily unqiue
rSet.DisableItem(nWhich);
}
break;
@@ -1755,7 +1747,7 @@ void OutlineViewShell::GetAttrState( SfxItemSet& rSet )
void OutlineViewShell::MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin)
{
- // Zuerst die Basisklasse
+ // first the base classes
ViewShell::MouseButtonUp(rMEvt, pWin);
Invalidate(SID_STYLE_EDIT);
@@ -1766,7 +1758,7 @@ void OutlineViewShell::MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin
Invalidate(SID_STYLE_WATERCAN);
Invalidate(SID_STYLE_FAMILY5);
- // ggfs. Preview den neuen Kontext mitteilen
+ // if necessary communicate the new context to the Preview
if( GetActualPage() != pLastPage )
Invalidate( SID_PREVIEW_STATE );
}
@@ -1782,8 +1774,8 @@ SdPage* OutlineViewShell::getCurrentPage() const
/*************************************************************************
|*
-|* Liefert die erste selektierte Seite zurueck.
-|* Wenn nichts selektiert ist, wird die erste Seite zurueckgeliefert.
+|* Returns the first selected page.
+|* If nothing is selected, the first page is returned.
|*
\************************************************************************/
SdPage* OutlineViewShell::GetActualPage()
@@ -1791,7 +1783,6 @@ SdPage* OutlineViewShell::GetActualPage()
return pOlView->GetActualPage();
}
-
void OutlineViewShell::UpdatePreview( SdPage* pPage, sal_Bool )
{
const bool bNewPage = pPage != pLastPage;
@@ -1918,7 +1909,7 @@ bool OutlineViewShell::UpdateOutlineObject( SdPage* pPage, Paragraph* pPara )
pTO = pOlView->GetOutlineTextObject( pPage );
}
- // wieviele Absaetze in der Gliederung?
+ // how many paragraphs in the outline?
sal_uLong nTitlePara = pOutliner->GetAbsPos( pPara );
sal_uLong nPara = nTitlePara + 1;
sal_uLong nParasInLayout = 0L;
@@ -1930,7 +1921,7 @@ bool OutlineViewShell::UpdateOutlineObject( SdPage* pPage, Paragraph* pPara )
}
if( nParasInLayout )
{
- // ein OutlinerParaObject erzeugen
+ // create an OutlinerParaObject
pPara = pOutliner->GetParagraph( nTitlePara + 1 );
pOPO = pOutliner->CreateParaObject( (sal_uInt16) nTitlePara + 1, (sal_uInt16) nParasInLayout );
}
@@ -1946,8 +1937,8 @@ bool OutlineViewShell::UpdateOutlineObject( SdPage* pPage, Paragraph* pPara )
bNewObject = sal_True;
}
- // Seitenobjekt, Gliederungstext im Outliner:
- // Text uebernehmen
+ // page object, outline text in Outliner:
+ // apply text
if( pTO )
{
pOPO->SetVertical( pTO->IsVerticalWriting() );
@@ -1970,16 +1961,17 @@ bool OutlineViewShell::UpdateOutlineObject( SdPage* pPage, Paragraph* pPara )
}
else if( pTO )
{
- // Seitenobjekt, aber kein Gliederungstext:
- // wenn Objekt in Praesentationsliste der Seite ist -> Defaulttext,
- // sonst Objekt loeschen
+ // page object but no outline text:
+ // if the object is in the outline of the page -> default text
+
+ // otherwise delete object
if( pPage->IsPresObj(pTO) )
{
if( !pTO->IsEmptyPresObj() )
{
DBG_ASSERT( pOlView->isRecordingUndo(), "sd::OutlineViewShell::UpdateOutlineObject(), no undo for model change!?" );
- // loescht auch altes OutlinerParaObject
+ // delete old OutlinerParaObject, too
if( pOlView->isRecordingUndo() )
pOlView->AddUndo(GetDoc()->GetSdrUndoFactory().CreateUndoObjectSetText(*pTO,0));
pPage->RestoreDefaultText( pTO );
@@ -2002,7 +1994,7 @@ bool OutlineViewShell::UpdateOutlineObject( SdPage* pPage, Paragraph* pPara )
/*************************************************************************
|*
-|* Outliner aus Stream fuellen
+|* Fill Outliner from Stream
|*
\************************************************************************/
@@ -2087,9 +2079,8 @@ void OutlineViewShell::VisAreaChanged(const Rectangle& rRect)
}
/** If there is a valid controller then create a new instance of
- <type>AccessibleDrawDocumentView</type>. Otherwise delegate this call
- to the base class to return a default object (probably an empty
- reference).
+ <type>AccessibleDrawDocumentView</type>. Otherwise return an empty
+ reference.
*/
::com::sun::star::uno::Reference<
::com::sun::star::accessibility::XAccessible>
@@ -2110,11 +2101,9 @@ void OutlineViewShell::VisAreaChanged(const Rectangle& rRect)
(static_cast< ::com::sun::star::uno::XWeak*>(pDocumentView),
::com::sun::star::uno::UNO_QUERY);
}
- else
- {
- OSL_TRACE ("OutlineViewShell::CreateAccessibleDocumentView: no controller");
- return ViewShell::CreateAccessibleDocumentView (pWindow);
- }
+
+ OSL_TRACE ("OutlineViewShell::CreateAccessibleDocumentView: no controller");
+ return ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >();
}
@@ -2163,3 +2152,5 @@ void OutlineViewShell::SetCurrentPage (SdPage* pPage)
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx
index 2c93af300..efb99b7ee 100755..100644
--- a/sd/source/ui/view/outlview.cxx
+++ b/sd/source/ui/view/outlview.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -57,7 +58,6 @@
#include <editeng/numitem.hxx>
#include <editeng/editeng.hxx>
-// #97766#
#include <editeng/editobj.hxx>
#include <editeng/editund2.hxx>
@@ -88,11 +88,11 @@ using namespace ::com::sun::star::frame;
namespace sd {
-// Breite: DIN A 4, zwei Raender zu je 1 cm
+// width: DIN A4, two margins à 1 cm each
#define OUTLINE_PAPERWIDTH 19000
-// beim Seitenmanipulation Fortschrittsanzeige, wenn mehr Seiten betroffen
-// sind als:
+// a progress bar gets displayed when more than
+// PROCESS_WITH_PROGRESS_THRESHOLD pages are concerned
#define PROCESS_WITH_PROGRESS_THRESHOLD 5
struct SdParaAndPos
@@ -105,7 +105,7 @@ TYPEINIT1( OutlineView, ::sd::View );
/*************************************************************************
|*
-|* Konstruktor
+|* Constructor
|*
\************************************************************************/
@@ -113,13 +113,10 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
: ::sd::View(pDocSh->GetDoc(), pWindow, pOutlineViewSh)
, mpOutlineViewShell(pOutlineViewSh)
, mpOutliner( mpDoc->GetOutliner(sal_True) )
-, mpOldParaOrder(NULL)
-, mpSelectedParas(NULL)
, mnPagesToProcess(0)
, mnPagesProcessed(0)
, mbFirstPaint(sal_True)
, mpProgress(NULL)
-, mbHighContrastMode( false )
, maDocColor( COL_WHITE )
, mnPageNumberWidthPixel( 0 )
, maLRSpaceItem( 0, 0, 2000, 0, EE_PARA_OUTLLRSPACE )
@@ -128,46 +125,15 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
if (mpOutliner->GetViewCount() == 0)
{
- // Outliner initialisieren: Referenz-Device setzen
+ // initialize Outliner: set Reference Device
bInitOutliner = sal_True;
mpOutliner->Init( OUTLINERMODE_OUTLINEVIEW );
-/*
- SfxStyleSheet* pTitleSheet = mpDoc->GetSdPage( 0, PK_STANDARD )->GetStyleSheetForPresObj( PRESOBJ_TITLE );
-
- if ( pTitleSheet )
- {
- // set title symbol (level 0)
- SvxNumBulletItem aNumBulletItem( (const SvxNumBulletItem&) pTitleSheet->GetItemSet().Get(EE_PARA_NUMBULLET) );
- SvxNumRule aNumRule(* aNumBulletItem.GetNumRule());
- SvxNumberFormat aFormat( aNumRule.GetLevel(0));
- Font aBulletFont;
- const Font* pFont = aFormat.GetBulletFont();
- if ( pFont ) // if available take font size and color from style
- aBulletFont = *pFont;
- else
- {
- aBulletFont.SetColor( COL_AUTO );
- aBulletFont.SetHeight( 1552 );
- }
- aBulletFont.SetCharSet(RTL_TEXTENCODING_MS_1252); // and replacing other values by standard
- aBulletFont.SetName( String( RTL_CONSTASCII_USTRINGPARAM( "StarSymbol" )) );
- aBulletFont.SetWeight(WEIGHT_NORMAL);
- aBulletFont.SetUnderline(UNDERLINE_NONE);
- aBulletFont.SetStrikeout(STRIKEOUT_NONE);
- aBulletFont.SetItalic(ITALIC_NONE);
- aBulletFont.SetOutline(sal_False);
- aBulletFont.SetShadow(sal_False);
- aFormat.SetBulletFont( &aBulletFont );
- aFormat.SetBulletChar( 0xE011 ); // StarBats: 0xF000 + 114
- mpOutliner->OverwriteLevel0Bullet( aFormat );
- }
-*/
mpOutliner->SetRefDevice( SD_MOD()->GetRefDevice( *pDocSh ) );
sal_uLong nWidth = OUTLINE_PAPERWIDTH;
mpOutliner->SetPaperSize(Size(nWidth, 400000000));
}
- // View in Outliner einfuegen
+ // insert View into Outliner
for (sal_uInt16 nView = 0; nView < MAX_OUTLINERVIEWS; nView++)
{
mpOutlinerView[nView] = NULL;
@@ -183,7 +149,7 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
if (bInitOutliner)
{
- // Outliner mit Inhalt fuellen
+ // fill Outliner with contents
FillOutliner();
}
@@ -212,7 +178,7 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
Reference<XFrame> xFrame (mpOutlineViewShell->GetViewShellBase().GetFrame()->GetTopFrame().GetFrameInterface(), UNO_QUERY);
const OUString aSlotURL( RTL_CONSTASCII_USTRINGPARAM( ".uno:ShowSlide" ));
- maSlideImage = GetImage( xFrame, aSlotURL, true, false /* todo, hc mode */ );
+ maSlideImage = GetImage( xFrame, aSlotURL, true );
// Tell undo manager of the document about the undo manager of the
// outliner, so that the former can synchronize with the later.
@@ -223,7 +189,7 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
/*************************************************************************
|*
-|* Destruktor, Links restaurieren, Outliner leeren
+|* Destructor, restore Links, clear Oultiner
|*
\************************************************************************/
@@ -238,7 +204,7 @@ OutlineView::~OutlineView()
if( mpProgress )
delete mpProgress;
- // OutlinerViews abmelden und zerstoeren
+ // unregister OutlinerViews and destroy them
for (sal_uInt16 nView = 0; nView < MAX_OUTLINERVIEWS; nView++)
{
if (mpOutlinerView[nView] != NULL)
@@ -251,18 +217,15 @@ OutlineView::~OutlineView()
if (mpOutliner->GetViewCount() == 0)
{
- // Outliner deinitialisieren: Farbdarstellung einschalten
+ // uninitialize Outliner: enable color display
ResetLinks();
sal_uLong nCntrl = mpOutliner->GetControlWord();
- mpOutliner->SetUpdateMode(sal_False); // sonst wird bei SetControlWord gezeichnet
+ mpOutliner->SetUpdateMode(sal_False); // otherwise there will be drawn on SetControlWord
mpOutliner->SetControlWord(nCntrl & ~EE_CNTRL_NOCOLORS);
SvtAccessibilityOptions aOptions;
mpOutliner->ForceAutoColor( aOptions.GetIsAutomaticFontColor() );
mpOutliner->Clear();
}
-
- DBG_ASSERT(!mpSelectedParas, "Absatzliste nicht geloescht");
- DBG_ASSERT(!mpOldParaOrder, "Absatzliste nicht geloescht");
}
@@ -287,7 +250,7 @@ void OutlineView::DisconnectFromApplication (void)
/*************************************************************************
|*
-|* Paint-Methode
+|* Paint method
|*
\************************************************************************/
@@ -302,73 +265,17 @@ void OutlineView::Paint(const Rectangle& rRect, ::sd::Window* pWin)
pOlView->ShowCursor(mbFirstPaint);
-/*
- if( mnPageNumberWidthPixel == 0 )
- GetPageNumberWidthPixel();
-
- const sal_uLong nParaCount = pOlView->GetOutliner()->GetParagraphCount();
- EditView& rEditView = pOlView->GetEditView();
-
- Font aOldFont( pWin->GetFont() );
-
- const String aBulletStr( sal_Unicode( 0xE011 ) );
- pWin->SetFont( maBulletFont);
- sal_Int32 nBulletWidth = pWin->GetTextWidth(aBulletStr);
-
- sal_Int32 nPage = 1;
- for( sal_uLong nPara = 0; nPara < nParaCount; nPara++ )
- {
- Paragraph* pPara = pOlView->GetOutliner()->GetParagraph( nPara );
- if( pPara->HasFlag( PARAFLAG_ISPAGE ) )
- {
- pWin->SetFont( maPageNumberFont );
- const String aStr( String::CreateFromInt32( nPage++ ) );
- Point aPos( rEditView.GetWindowPosTopLeft( (sal_uInt16)nPara ) );
-
- sal_Int32 nNumberOffset = pWin->PixelToLogic( Point(mnPageNumberWidthPixel, 0) ).X() - nBulletWidth;
- sal_Int32 nLineHeight = pOlView->GetOutliner()->GetLineHeight( nPara, 0 );
-
- aPos.X() = nNumberOffset;
-
- Point aPoint( aPos.X() - pWin->GetTextWidth( aStr ), aPos.Y() + ( nLineHeight - maPageNumberFont.GetHeight()) / 2 );
- pWin->DrawText( aPoint, aStr );
-
- aPoint.X() = aPos.X();
- aPoint.Y() = aPos.Y() +( nLineHeight - maBulletFont.GetHeight()) / 2;
- pWin->SetFont( maBulletFont );
- pWin->DrawText( aPoint, aBulletStr );
- }
- }
-
- pWin->SetFont( aOldFont );
-*/
mbFirstPaint = sal_False;
}
}
void OutlineView::InvalidateSlideNumberArea()
-{
-/*
- for( sal_Int16 nView = 0; nView < MAX_OUTLINERVIEWS; ++nView )
- {
- if (mpOutlinerView[nView] != NULL)
- {
- ::Window* pWindow = mpOutlinerView[nView]->GetWindow();
- if( pWindow )
- {
- Rectangle aRect( Point(0,0), pWindow->GetOutputSize() );
- aRect.nRight = aRect.nLeft + pWindow->PixelToLogic( Point( mnPageNumberWidthPixel, 0 ) ).X() * 2;
-
- pWindow->Invalidate(aRect);
- }
- }
- }
-*/
+{
}
/*************************************************************************
|*
-|* Fenster-Groesse hat sich geaendert
+|* Window size was changed
|*
\************************************************************************/
@@ -378,7 +285,7 @@ void OutlineView::AdjustPosSizePixel(const Point &,const Size &,::sd::Window*)
/*************************************************************************
|*
-|* ein Fenster hinzufuegen
+|* add a window
|*
\************************************************************************/
@@ -413,7 +320,7 @@ void OutlineView::AddWindowToPaintView(OutputDevice* pWin)
nView++;
}
- // weisser Hintergrund im Outliner
+ // white background in Outliner
pWin->SetBackground( Wallpaper( aWhiteColor ) );
::sd::View::AddWindowToPaintView(pWin);
@@ -421,7 +328,7 @@ void OutlineView::AddWindowToPaintView(OutputDevice* pWin)
/*************************************************************************
|*
-|* ein Fenster entfernen
+|* remove a window
|*
\************************************************************************/
@@ -454,7 +361,7 @@ void OutlineView::DeleteWindowFromPaintView(OutputDevice* pWin)
/*************************************************************************
|*
-|* Zeiger der dem Fenster entsprechenden OutlinerView zurueckgeben.
+|* Return a pointer to the OutlinerView corresponding to the window
|*
\************************************************************************/
@@ -477,7 +384,7 @@ OutlinerView* OutlineView::GetViewByWindow (::Window* pWin) const
/*************************************************************************
|*
-|* Ermittelt den Titel vor einem beliebigen Absatz.
+|* Return the title before a random paragraph
|*
\************************************************************************/
@@ -502,7 +409,7 @@ Paragraph* OutlineView::GetPrevTitle(const Paragraph* pPara)
/*************************************************************************
|*
-|* Ermittelt den Titel nach einem beliebigen Absatz.
+|* Return the title after a random paragraph
|*
\************************************************************************/
@@ -525,14 +432,12 @@ Paragraph* OutlineView::GetNextTitle(const Paragraph* pPara)
/*************************************************************************
|*
-|* Handler fuer das Einfuegen von Seiten (Absaetzen)
+|* Handler for inserting pages (paragraphs)
|*
\************************************************************************/
IMPL_LINK( OutlineView, ParagraphInsertedHdl, ::Outliner *, pOutliner )
{
-// DBG_ASSERT( isRecordingUndo(), "sd::OutlineView::ParagraphInsertedHdl(), model change without undo?!" );
-
// we get calls to this handler during binary insert of drag and drop contents but
// we ignore it here and handle it later in OnEndPasteOrDrop()
if( maDragAndDropModelGuard.get() == 0 )
@@ -563,9 +468,9 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
OutlineViewPageChangesGuard aGuard(this);
mpOutliner->SetParaFlag( pPara, PARAFLAG_ISPAGE );
- // wieviele Titel sind vor dem neuen Titelabsatz?
- sal_uLong nExample = 0L; // Position der "Vorbild"seite
- sal_uLong nTarget = 0L; // Einfuegeposition
+ // how many titles are there before the new title paragraph?
+ sal_uLong nExample = 0L; // position of the "example" page
+ sal_uLong nTarget = 0L; // position of insertion
while(pPara)
{
pPara = GetPrevTitle(pPara);
@@ -573,11 +478,9 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
nTarget++;
}
-
- // was der Outliner nicht kann, muss hier wieder wettgemacht werden:
- // wenn VOR dem ersten Absatz ein neuer Absatz mit RETURN erzeugt wird,
- // meldet der Outliner den bereits bestehenden (jetzt nach unten
- // gerutschten) Absatz als neuen Absatz; nicht darauf reinfallen!
+ // if a new paragraph is created via RETURN before the first paragraph, the
+ // Outliner reports the old paragraph (which was moved down) as a new
+ // paragraph
if (nTarget == 1)
{
String aTest(mpOutliner->GetText( mpOutliner->GetParagraph( 0 ) ));
@@ -588,7 +491,7 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
}
- // "Vorbild"seite ist - wenn vorhanden - die Vorgaengerseite
+ // the "example" page is the previous page - if it is available
if (nTarget > 0)
{
nExample = nTarget - 1;
@@ -599,36 +502,35 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
}
/**********************************************************************
- * Es wird stets zuerst eine Standardseite und dann eine
- * Notizseite erzeugt. Es ist sichergestellt, dass auf eine
- * Standardseite stets die zugehoerige Notizseite folgt.
- * Vorangestellt ist genau eine Handzettelseite
+ * All the time, a standard page is created before a notes page.
+ * It is ensured that after each standard page the corresponding notes page
+ * follows. A handout page is exactly one handout page.
**********************************************************************/
- // diese Seite hat Vorbildfunktion
+ // this page is exemplary
SdPage* pExample = (SdPage*)mpDoc->GetSdPage((sal_uInt16)nExample, PK_STANDARD);
SdPage* pPage = (SdPage*)mpDoc->AllocPage(sal_False);
pPage->SetLayoutName(pExample->GetLayoutName());
- // einfuegen (Seite)
+ // insert (page)
mpDoc->InsertPage(pPage, (sal_uInt16)(nTarget) * 2 + 1);
if( isRecordingUndo() )
AddUndo(mpDoc->GetSdrUndoFactory().CreateUndoNewPage(*pPage));
- // der Standardseite eine Masterpage zuweisen
+ // assign a master page to the standard page
pPage->TRG_SetMasterPage(pExample->TRG_GetMasterPage());
- // Seitengroesse setzen
+ // set page size
pPage->SetSize(pExample->GetSize());
pPage->SetBorder( pExample->GetLftBorder(),
pExample->GetUppBorder(),
pExample->GetRgtBorder(),
pExample->GetLwrBorder() );
- // neue Praesentationsobjekte anlegen (auf <Titel> oder
- // <Titel mit Untertitel> folgt <Titel mit Gliederung>, ansonsten
- // wird das Layout von der Vorgaengerseite uebernommen)
+ // create new presentation objects (after <Title> or <Title with subtitle>
+ // follows <Title with outline>, otherwise apply the layout of the previous
+ // page
AutoLayout eAutoLayout = pExample->GetAutoLayout();
if (eAutoLayout == AUTOLAYOUT_TITLE ||
eAutoLayout == AUTOLAYOUT_ONLY_TITLE)
@@ -641,7 +543,7 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
}
/**********************************************************************
- |* jetzt die Notizseite
+ |* now the notes page
\*********************************************************************/
pExample = (SdPage*)mpDoc->GetSdPage((sal_uInt16)nExample, PK_NOTES);
SdPage* pNotesPage = (SdPage*)mpDoc->AllocPage(sal_False);
@@ -650,22 +552,22 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
pNotesPage->SetPageKind(PK_NOTES);
- // einfuegen (Notizseite)
+ // insert (notes page)
mpDoc->InsertPage(pNotesPage, (sal_uInt16)(nTarget) * 2 + 2);
if( isRecordingUndo() )
AddUndo(mpDoc->GetSdrUndoFactory().CreateUndoNewPage(*pNotesPage));
- // der Notizseite eine Masterpage zuweisen
+ // assign a master page to the notes page
pNotesPage->TRG_SetMasterPage(pExample->TRG_GetMasterPage());
- // Seitengroesse setzen, es muss bereits eine Seite vorhanden sein
+ // set page size, there must be already one page available
pNotesPage->SetSize(pExample->GetSize());
pNotesPage->SetBorder( pExample->GetLftBorder(),
pExample->GetUppBorder(),
pExample->GetRgtBorder(),
pExample->GetLwrBorder() );
- // neue Praesentationsobjekte anlegen
+ // create presentation objects
pNotesPage->SetAutoLayout(pExample->GetAutoLayout(), sal_True);
mpOutliner->UpdateFields();
@@ -675,7 +577,7 @@ SdPage* OutlineView::InsertSlideForParagraph( Paragraph* pPara )
/*************************************************************************
|*
-|* Handler fuer das Loeschen von Seiten (Absaetzen)
+|* Handler for deleting pages (paragraphs)
|*
\************************************************************************/
@@ -688,7 +590,7 @@ IMPL_LINK( OutlineView, ParagraphRemovingHdl, ::Outliner *, pOutliner )
Paragraph* pPara = pOutliner->GetHdlParagraph();
if( pOutliner->HasParaFlag( pPara, PARAFLAG_ISPAGE ) )
{
- // wieviele Titel sind vor dem fraglichen Titelabsatz?
+ // how many titles are in front of the title paragraph in question?
sal_uLong nPos = 0L;
while(pPara)
{
@@ -696,7 +598,7 @@ IMPL_LINK( OutlineView, ParagraphRemovingHdl, ::Outliner *, pOutliner )
if (pPara) nPos++;
}
- // Seite und Notizseite loeschen
+ // delete page and notes page
sal_uInt16 nAbsPos = (sal_uInt16)nPos * 2 + 1;
SdrPage* pPage = mpDoc->GetPage(nAbsPos);
if( isRecordingUndo() )
@@ -709,7 +611,7 @@ IMPL_LINK( OutlineView, ParagraphRemovingHdl, ::Outliner *, pOutliner )
AddUndo(mpDoc->GetSdrUndoFactory().CreateUndoDeletePage(*pPage));
mpDoc->RemovePage(nAbsPos);
- // ggfs. Fortschrittsanzeige
+ // progress display if necessary
if (mnPagesToProcess)
{
mnPagesProcessed++;
@@ -738,8 +640,8 @@ IMPL_LINK( OutlineView, ParagraphRemovingHdl, ::Outliner *, pOutliner )
/*************************************************************************
|*
-|* Handler fuer das Aendern der Einruecktiefe von Absaetzen (macht ggfs.
-|* das Einfuegen oder Loeschen von Seiten notwendig)
+|* Handler for changing the indentation depth of paragraphs (requires inserting
+|* or deleting of pages in some cases)
|*
\************************************************************************/
@@ -756,25 +658,28 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
mpOutliner->SetDepth( pPara, -1 );
- // werden da etwa mehrere Level-1-Absaetze auf Level 0 gebracht und
- // wir sollten eine Fortschrittsanzeige oder Eieruhr aufsetzen und
- // haben es noch nicht getan?
+ // are multiple level 1 paragraphs being brought to level 0 and we
+ // should start a progress view or a timer and didn't already?
if (mnPagesToProcess == 0)
{
Window* pActWin = mpOutlineViewShell->GetActiveWindow();
OutlinerView* pOlView = GetViewByWindow(pActWin);
- List* pList = pOlView->CreateSelectionList();
- Paragraph* pParagraph = (Paragraph*)pList->First();
- while (pParagraph)
+ std::vector<Paragraph*> aSelList;
+ pOlView->CreateSelectionList(aSelList);
+
+ Paragraph *pParagraph = NULL;
+ for (std::vector<Paragraph*>::const_iterator iter = aSelList.begin(); iter != aSelList.end(); ++iter)
{
- if( !pOutliner->HasParaFlag( pParagraph, PARAFLAG_ISPAGE ) && (pOutliner->GetDepth( (sal_uInt16) pOutliner->GetAbsPos( pParagraph ) ) <= 0) )
+ pParagraph = *iter;
+
+ if( !pOutliner->HasParaFlag( pParagraph, PARAFLAG_ISPAGE ) &&
+ (pOutliner->GetDepth( (sal_uInt16) pOutliner->GetAbsPos( pParagraph ) ) <= 0) )
mnPagesToProcess++;
- pParagraph = (Paragraph*)pList->Next();
}
- mnPagesToProcess++; // der Absatz, der jetzt schon auf Level 0
- // steht, gehoert auch dazu
+ mnPagesToProcess++; // the paragraph being in level 0 already
+ // should be included
mnPagesProcessed = 0;
if (mnPagesToProcess > PROCESS_WITH_PROGRESS_THRESHOLD)
@@ -789,21 +694,20 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
{
mpDocSh->SetWaitCursor( sal_True );
}
- delete pList;
}
ParagraphInsertedHdl(pOutliner);
mnPagesProcessed++;
- // muss eine Fortschrittsanzeige gepflegt werden?
+ // should there be a progress display?
if (mnPagesToProcess > PROCESS_WITH_PROGRESS_THRESHOLD)
{
if (mpProgress)
mpProgress->SetState(mnPagesProcessed);
}
- // war das die letzte Seite?
+ // was this the last page?
if (mnPagesProcessed == mnPagesToProcess)
{
if (mnPagesToProcess > PROCESS_WITH_PROGRESS_THRESHOLD && mpProgress)
@@ -832,7 +736,7 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
if (pParagraph)
nPos++;
}
- // Seite und Notizseite loeschen
+ // delete page and notes page
sal_uInt16 nAbsPos = (sal_uInt16)nPos * 2 + 1;
SdrPage* pPage = mpDoc->GetPage(nAbsPos);
@@ -850,7 +754,7 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
mpOutliner->SetDepth( pPara, (pPage && (static_cast<SdPage*>(pPage)->GetAutoLayout() == AUTOLAYOUT_TITLE)) ? -1 : 0 );
- // ggfs. Fortschrittsanzeige
+ // progress display if necessary
if (mnPagesToProcess)
{
mnPagesProcessed++;
@@ -872,7 +776,7 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
}
else if ( (pOutliner->GetPrevDepth() == 1) && ( pOutliner->GetDepth( (sal_uInt16) pOutliner->GetAbsPos( pPara ) ) == 2 ) )
{
- // wieviele Titel sind vor dem fraglichen Titelabsatz?
+ // how many titles are in front of the title paragraph in question?
sal_Int32 nPos = -1L;
Paragraph* pParagraph = pPara;
@@ -892,7 +796,7 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
}
}
- // wieviele Titel sind vor dem fraglichen Titelabsatz?
+ // how many titles are in front of the title paragraph in question?
sal_Int32 nPos = -1L;
Paragraph* pTempPara = pPara;
@@ -960,7 +864,7 @@ IMPL_LINK( OutlineView, DepthChangedHdl, ::Outliner *, pOutliner )
/*************************************************************************
|*
-|* Handler fuer StatusEvents
+|* Handler for StatusEvents
|*
\************************************************************************/
@@ -969,8 +873,6 @@ IMPL_LINK( OutlineView, StatusEventHdl, EditStatus *, EMPTYARG )
::sd::Window* pWin = mpOutlineViewShell->GetActiveWindow();
OutlinerView* pOutlinerView = GetViewByWindow(pWin);
Rectangle aVis = pOutlinerView->GetVisArea();
-
-// sal_uLong nWidth = ((SdPage*)mpDoc->GetSdPage(0, PK_STANDARD))->GetSize().Width();
sal_uLong nWidth = OUTLINE_PAPERWIDTH;
Rectangle aText = Rectangle(Point(0,0),
Size(nWidth,
@@ -978,7 +880,7 @@ IMPL_LINK( OutlineView, StatusEventHdl, EditStatus *, EMPTYARG )
Rectangle aWin(Point(0,0), pWin->GetOutputSizePixel());
aWin = pWin->PixelToLogic(aWin);
- if (!aVis.IsEmpty()) // nicht beim Oeffnen
+ if (!aVis.IsEmpty()) // not when opening
{
aText.Bottom() += aWin.GetHeight();
@@ -1008,53 +910,43 @@ IMPL_LINK( OutlineView, EndDropHdl, void *, EMPTYARG )
/*************************************************************************
|*
-|* Handler fuer den Beginn einer Absatzverschiebung
+|* Handler for the start of a paragraph movement
|*
\************************************************************************/
IMPL_LINK( OutlineView, BeginMovingHdl, ::Outliner *, pOutliner )
{
- DBG_ASSERT(!mpSelectedParas, "Absatzliste nicht geloescht");
- DBG_ASSERT(!mpOldParaOrder, "Absatzliste nicht geloescht");
-
OutlineViewPageChangesGuard aGuard(this);
- mpOldParaOrder = new List;
+ // list of selected title paragraphs
+ mpOutlinerView[0]->CreateSelectionList(maSelectedParas);
- // Liste der selektierten Titelabsaetze
- mpSelectedParas = mpOutlinerView[0]->CreateSelectionList();
- Paragraph* pPara = static_cast<Paragraph*>(mpSelectedParas->First());
- while (pPara)
+ for (std::vector<Paragraph*>::iterator it = maSelectedParas.begin(); it != maSelectedParas.end();)
{
- if( !pOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) )
- {
- mpSelectedParas->Remove();
- pPara = static_cast<Paragraph*>(mpSelectedParas->GetCurObject());
- }
+ if (!pOutliner->HasParaFlag(*it, PARAFLAG_ISPAGE))
+ it = maSelectedParas.erase(it);
else
- {
- pPara = static_cast<Paragraph*>(mpSelectedParas->Next());
- }
+ ++it;
}
- // Die zu den selektierten Absaetzen auf Ebene 0 gehoerenden Seiten
- // selektieren
+ // select the pages belonging to the paragraphs on level 0 to select
sal_uInt16 nPos = 0;
sal_uLong nParaPos = 0;
- pPara = pOutliner->GetParagraph( 0 );
+ Paragraph* pPara = pOutliner->GetParagraph( 0 );
+ std::vector<Paragraph*>::const_iterator fiter;
while(pPara)
{
- if( pOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) ) // eine Seite?
+ if( pOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) ) // one page?
{
- mpOldParaOrder->Insert(pPara, LIST_APPEND);
+ maOldParaOrder.push_back(pPara);
SdPage* pPage = mpDoc->GetSdPage(nPos, PK_STANDARD);
- pPage->SetSelected(sal_False);
- if (mpSelectedParas->Seek(pPara)) // selektiert?
- {
- pPage->SetSelected(sal_True);
- }
- nPos++;
+
+ fiter = std::find(maSelectedParas.begin(),maSelectedParas.end(),pPara);
+
+ pPage->SetSelected(fiter != maSelectedParas.end());
+
+ ++nPos;
}
pPara = pOutliner->GetParagraph( ++nParaPos );
}
@@ -1064,7 +956,7 @@ IMPL_LINK( OutlineView, BeginMovingHdl, ::Outliner *, pOutliner )
/*************************************************************************
|*
-|* Handler fuer das Ende einer Absatzverschiebung
+|* Handler for the end of a paragraph movement
|*
\************************************************************************/
@@ -1072,14 +964,12 @@ IMPL_LINK( OutlineView, EndMovingHdl, ::Outliner *, pOutliner )
{
OutlineViewPageChangesGuard aGuard(this);
- DBG_ASSERT(mpSelectedParas, "keine Absatzliste");
- DBG_ASSERT(mpOldParaOrder, "keine Absatzliste");
DBG_ASSERT( isRecordingUndo(), "sd::OutlineView::EndMovingHdl(), model change without undo?!" );
- // Einfuegeposition anhand des ersten Absatzes suchen
- Paragraph* pSearchIt = (Paragraph*)mpSelectedParas->First();
+ // look for insertion position via the first paragraph
+ Paragraph* pSearchIt = maSelectedParas.empty() ? NULL : *(maSelectedParas.begin());
- // den ersten der selektierten Paragraphen in der neuen Ordnung suchen
+ // look for the first of the selected paragraphs in the new ordering
sal_uInt16 nPosNewOrder = 0;
sal_uLong nParaPos = 0;
Paragraph* pPara = pOutliner->GetParagraph( 0 );
@@ -1094,22 +984,30 @@ IMPL_LINK( OutlineView, EndMovingHdl, ::Outliner *, pOutliner )
pPara = pOutliner->GetParagraph( ++nParaPos );
}
- sal_uInt16 nPos = nPosNewOrder; // nPosNewOrder nicht veraendern
+ sal_uInt16 nPos = nPosNewOrder; // don't change nPosNewOrder
if (nPos == 0)
{
- nPos = (sal_uInt16)-1; // vor der ersten Seite einfuegen
+ nPos = (sal_uInt16)-1; // insert before the first page
}
else
{
- // den Vorgaenger in der alten Ordnung suchen
- nPos = (sal_uInt16)mpOldParaOrder->GetPos(pPrev);
+ // look for the predecessor in the old ordering
+ std::vector<Paragraph*>::const_iterator it = std::find(maOldParaOrder.begin(),
+ maOldParaOrder.end(),
+ pPrev);
+
+ if (it != maOldParaOrder.end())
+ nPos = static_cast<sal_uInt16>(it-maOldParaOrder.begin());
+ else
+ nPos = 0xffff;
+
DBG_ASSERT(nPos != 0xffff, "Absatz nicht gefunden");
}
mpDoc->MovePages(nPos);
- // die Seiten wieder deselektieren
- sal_uInt16 nPageCount = (sal_uInt16)mpSelectedParas->Count();
+ // deselect the pages again
+ sal_uInt16 nPageCount = (sal_uInt16)maSelectedParas.size();
while (nPageCount)
{
SdPage* pPage = mpDoc->GetSdPage(nPosNewOrder, PK_STANDARD);
@@ -1120,10 +1018,8 @@ IMPL_LINK( OutlineView, EndMovingHdl, ::Outliner *, pOutliner )
pOutliner->UpdateFields();
- delete mpSelectedParas;
- mpSelectedParas = NULL;
- delete mpOldParaOrder;
- mpOldParaOrder = NULL;
+ maSelectedParas.clear();
+ maOldParaOrder.clear();
InvalidateSlideNumberArea();
@@ -1132,7 +1028,7 @@ IMPL_LINK( OutlineView, EndMovingHdl, ::Outliner *, pOutliner )
/*************************************************************************
|*
-|* Eine Seite des Models nach dem Titeltextobjekt durchsuchen
+|* Look for the title text object in one page of the model
|*
\************************************************************************/
@@ -1158,7 +1054,7 @@ SdrTextObj* OutlineView::GetTitleTextObject(SdrPage* pPage)
/*************************************************************************
|*
-|* Eine Seite des Models nach dem Gliederungstextobjekt durchsuchen
+|* Look for the outline text object in one page of the model
|*
\************************************************************************/
@@ -1256,7 +1152,7 @@ sal_Bool OutlineView::PrepareClose(sal_Bool)
/*************************************************************************
|*
-|* Attribute des selektierten Textes setzen
+|* Set attributes of the selected text
|*
\************************************************************************/
@@ -1279,7 +1175,7 @@ sal_Bool OutlineView::SetAttributes(const SfxItemSet& rSet, sal_Bool )
/*************************************************************************
|*
-|* Attribute des selektierten Textes erfragen
+|* Get attributes of the selected text
|*
\************************************************************************/
@@ -1330,7 +1226,7 @@ void OutlineView::FillOutliner()
pPara = mpOutliner->Insert(String());
mpOutliner->SetDepth(pPara, -1);
- // Keine harten Attribute vom vorherigen Absatz uebernehmen
+ // do not apply hard attributes from the previous paragraph
mpOutliner->SetParaAttribs( (sal_uInt16)mpOutliner->GetAbsPos(pPara),
mpOutliner->GetEmptyItemSet() );
@@ -1399,7 +1295,7 @@ void OutlineView::FillOutliner()
/*************************************************************************
|*
-|* Handler fuer das Loeschen von Level-0-Absaetzen (Seiten): Warnung
+|* Handler for deleting of level 0 paragraphs (pages): Warning
|*
\************************************************************************/
@@ -1430,7 +1326,7 @@ IMPL_LINK( OutlineView, RemovingPagesHdl, OutlinerView *, EMPTYARG )
/*************************************************************************
|*
-|* Handler fuer das Einruecken von Level-0-Absaetzen (Seiten): Warnung
+|* Handler for indenting level 0 paragraphs (pages): Warning
|*
\************************************************************************/
@@ -1447,17 +1343,22 @@ SdPage* OutlineView::GetActualPage()
{
::sd::Window* pWin = mpOutlineViewShell->GetActiveWindow();
OutlinerView* pActiveView = GetViewByWindow(pWin);
- std::auto_ptr<List> pSelList( static_cast< List* >(pActiveView->CreateSelectionList()) );
- SdPage* pCurrent = GetPageForParagraph(static_cast<Paragraph*>(pSelList->First()) );
+ std::vector<Paragraph*> aSelList;
+ pActiveView->CreateSelectionList(aSelList);
+
+ Paragraph *pPar = aSelList.empty() ? NULL : *(aSelList.begin());
+ SdPage* pCurrent = GetPageForParagraph(pPar);
+
DBG_ASSERT( pCurrent ||
(mpDocSh->GetUndoManager() && static_cast< sd::UndoManager *>(mpDocSh->GetUndoManager())->IsDoing()) ||
maDragAndDropModelGuard.get(),
"sd::OutlineView::GetActualPage(), no current page?" );
+
if( pCurrent )
return pCurrent;
- else
- return mpDoc->GetSdPage( 0, PK_STANDARD );
+
+ return mpDoc->GetSdPage( 0, PK_STANDARD );
}
SdPage* OutlineView::GetPageForParagraph( Paragraph* pPara )
@@ -1475,8 +1376,8 @@ SdPage* OutlineView::GetPageForParagraph( Paragraph* pPara )
if( nPageToSelect < (sal_uInt32)mpDoc->GetSdPageCount( PK_STANDARD ) )
return static_cast< SdPage* >( mpDoc->GetSdPage( (sal_uInt16)nPageToSelect, PK_STANDARD) );
- else
- return 0;
+
+ return 0;
}
Paragraph* OutlineView::GetParagraphForPage( ::Outliner* pOutl, SdPage* pPage )
@@ -1521,7 +1422,7 @@ void OutlineView::SetActualPage( SdPage* pActual )
/*************************************************************************
|*
-|* StyleSheet aus der Selektion besorgen
+|* Get StyleSheet from the selection
|*
\************************************************************************/
@@ -1537,48 +1438,42 @@ SfxStyleSheet* OutlineView::GetStyleSheet() const
/*************************************************************************
|*
-|* Seiten als selektiert / nicht selektiert setzen
+|* Mark pages as selected / not selected
|*
\************************************************************************/
void OutlineView::SetSelectedPages()
{
- // Liste der selektierten Titelabsaetze
- List* pSelParas = mpOutlinerView[0]->CreateSelectionList();
- Paragraph* pPara = (Paragraph*) pSelParas->First();
+ // list of selected title paragraphs
+ std::vector<Paragraph*> aSelParas;
+ mpOutlinerView[0]->CreateSelectionList(aSelParas);
- while(pPara)
+ for (std::vector<Paragraph*>::iterator it = aSelParas.begin(); it != aSelParas.end();)
{
- if( !mpOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) )
- {
- pSelParas->Remove();
- pPara = (Paragraph*) pSelParas->GetCurObject();
- }
+ if (!mpOutliner->HasParaFlag(*it, PARAFLAG_ISPAGE))
+ it = aSelParas.erase(it);
else
- {
- pPara = (Paragraph*) pSelParas->Next();
- }
+ ++it;
}
- // Die zu den selektierten Absaetzen auf Ebene 0 gehoerenden Seiten
- // selektieren
+ // select the pages belonging to the paragraphs on level 0 to select
sal_uInt16 nPos = 0;
sal_uLong nParaPos = 0;
- pPara = mpOutliner->GetParagraph( 0 );
+ Paragraph *pPara = mpOutliner->GetParagraph( 0 );
+ std::vector<Paragraph*>::const_iterator fiter;
while(pPara)
{
- if( mpOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) ) // eine Seite?
+ if( mpOutliner->HasParaFlag(pPara, PARAFLAG_ISPAGE) ) // one page
{
SdPage* pPage = mpDoc->GetSdPage(nPos, PK_STANDARD);
DBG_ASSERT(pPage!=NULL,
"Trying to select non-existing page OutlineView::SetSelectedPages()");
- if (pPage != NULL)
- {
- pPage->SetSelected(sal_False);
- if (pSelParas->Seek(pPara)) // selektiert?
- pPage->SetSelected(sal_True);
+ if (pPage)
+ {
+ fiter = std::find(aSelParas.begin(),aSelParas.end(),pPara);
+ pPage->SetSelected(fiter != aSelParas.end());
}
nPos++;
@@ -1591,13 +1486,13 @@ void OutlineView::SetSelectedPages()
/*************************************************************************
|*
-|* Neue Links setzen
+|* Set new links
|*
\************************************************************************/
void OutlineView::SetLinks()
{
- // Benachrichtigungs-Links setzen
+ // set notification links
mpOutliner->SetParaInsertedHdl(LINK(this, OutlineView, ParagraphInsertedHdl));
mpOutliner->SetParaRemovingHdl(LINK(this, OutlineView, ParagraphRemovingHdl));
mpOutliner->SetDepthChangedHdl(LINK(this, OutlineView, DepthChangedHdl));
@@ -1617,13 +1512,12 @@ void OutlineView::SetLinks()
/*************************************************************************
|*
-|* Alte Links restaurieren
+|* Restore old links
|*
\************************************************************************/
void OutlineView::ResetLinks() const
{
- // alte Links restaurieren
Link aEmptyLink;
mpOutliner->SetParaInsertedHdl(aEmptyLink);
mpOutliner->SetParaRemovingHdl(aEmptyLink);
@@ -1660,7 +1554,7 @@ sal_Int8 OutlineView::ExecuteDrop( const ExecuteDropEvent&, DropTargetHelper&, :
return DND_ACTION_NONE;
}
-// #97766# Re-implement GetScriptType for this view to get correct results
+// Re-implement GetScriptType for this view to get correct results
sal_uInt16 OutlineView::GetScriptType() const
{
sal_uInt16 nScriptType = ::sd::View::GetScriptType();
@@ -1681,17 +1575,6 @@ sal_uInt16 OutlineView::GetScriptType() const
void OutlineView::onUpdateStyleSettings( bool bForceUpdate /* = false */ )
{
- const bool bHighContrastMode = Application::GetSettings().GetStyleSettings().GetHighContrastMode() != 0;
- if( bForceUpdate || (mbHighContrastMode != bHighContrastMode) )
- {
- if( mpOutliner )
- {
- mpOutliner->ForceAutoColor( bHighContrastMode );
- }
- mbHighContrastMode = bHighContrastMode;
-
- }
-
svtools::ColorConfig aColorConfig;
const Color aDocColor( aColorConfig.GetColorValue( svtools::DOCCOLOR ).nColor );
if( bForceUpdate || (maDocColor != aDocColor) )
@@ -1976,14 +1859,10 @@ IMPL_LINK(OutlineView, PaintingFirstLineHdl, PaintFirstLineInfo*, pInfo)
long nFontHeight = 0;
if ( !rEditEngine.IsFlatMode() )
{
-// const SvxFontHeightItem& rFH = (const SvxFontHeightItem&)rEditEngine.GetParaAttrib( pInfo->mnPara, EE_CHAR_FONTHEIGHT );
-// nBulletHeight = rFH.GetHeight();
nFontHeight = nBulletHeight / 5;
}
else
{
-// const SvxFontHeightItem& rFH = (const SvxFontHeightItem&)rEditEngine.GetEmptyItemSet().Get( EE_CHAR_FONTHEIGHT );
- // nBulletHeight = rFH.GetHeight();
nFontHeight = (nBulletHeight * 10) / 25;
}
@@ -2010,7 +1889,6 @@ IMPL_LINK(OutlineView, PaintingFirstLineHdl, PaintFirstLineInfo*, pInfo)
Point aTextPos( aImagePos.X() - aOffset.Width(), pInfo->mrStartPos.Y() );
Font aNewFont( OutputDevice::GetDefaultFont( DEFAULTFONT_SANS_UNICODE, eLang, 0 ) );
aNewFont.SetSize( aFontSz );
-// aNewFont.SetAlign( aBulletFont.GetAlign() );
aNewFont.SetVertical( bVertical );
aNewFont.SetOrientation( bVertical ? 2700 : 0 );
aNewFont.SetColor( COL_AUTO );
@@ -2019,7 +1897,6 @@ IMPL_LINK(OutlineView, PaintingFirstLineHdl, PaintFirstLineInfo*, pInfo)
Size aTextSz;
aTextSz.Width() = pInfo->mpOutDev->GetTextWidth( aPageText );
aTextSz.Height() = pInfo->mpOutDev->GetTextHeight();
-// long nBulletHeight = !bVertical ? aBulletArea.GetHeight() : aBulletArea.GetWidth();
if ( !bVertical )
{
aTextPos.Y() += (aOutSize.Height() - aTextSz.Height()) / 2;
@@ -2044,31 +1921,6 @@ IMPL_LINK(OutlineView, PaintingFirstLineHdl, PaintFirstLineInfo*, pInfo)
return 0;
}
-#if 0
-sal_Int32 OutlineView::GetPageNumberWidthPixel()
-{
- Window* pActWin = mpOutlineViewShell->GetActiveWindow();
- if( pActWin )
- {
- Font aOldFont( pActWin->GetFont() );
- pActWin->SetFont( maPageNumberFont );
- Size aSize( pActWin->GetTextWidth( String( RTL_CONSTASCII_USTRINGPARAM("X" ) ) ), 0 );
- sal_Int32 nWidth = pActWin->LogicToPixel( aSize ).Width() * 5;
-
- const String aBulletStr( sal_Unicode( 0xE011 ) );
- pActWin->SetFont( maBulletFont);
-
- aSize.Width() = pActWin->GetTextWidth(aBulletStr);
- nWidth += pActWin->LogicToPixel( aSize ).Width();
-
- pActWin->SetFont( aOldFont );
-
- mnPageNumberWidthPixel = nWidth;
- }
- return mnPageNumberWidthPixel;
-}
-#endif
-
// --------------------------------------------------------------------
void OutlineView::UpdateParagraph( sal_uInt16 nPara )
@@ -2179,3 +2031,5 @@ OutlineViewPageChangesGuard::~OutlineViewPageChangesGuard()
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/presvish.cxx b/sd/source/ui/view/presvish.cxx
index 30cb2dd01..b7179edc3 100755..100644
--- a/sd/source/ui/view/presvish.cxx
+++ b/sd/source/ui/view/presvish.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,9 +39,7 @@
#include "optsitem.hxx"
#include "sddll.hxx"
#include <sfx2/request.hxx>
-#ifndef _SFX_DISPATCH_HXX
#include <sfx2/dispatch.hxx>
-#endif
#include <sfx2/objface.hxx>
@@ -61,7 +60,6 @@
#include "ViewShellBase.hxx"
#include "FactoryIds.hxx"
-// #110496#
#include "slideshow.hxx"
#include "fupoor.hxx"
#include "Window.hxx"
@@ -127,7 +125,6 @@ void PresentationViewShell::FinishInitialization( FrameView* pFrameView )
pFrameView->Connect();
}
SetRuler(false);
-// SwitchPage (nPageNumber);
WriteFrameViewData();
GetActiveWindow()->GrabFocus();
@@ -151,7 +148,6 @@ void PresentationViewShell::Activate( sal_Bool bIsMDIActivate )
if( bIsMDIActivate )
{
- //HMH::sd::View* pView = GetView();
SfxBoolItem aItem( SID_NAVIGATOR_INIT, sal_True );
GetViewFrame()->GetDispatcher()->Execute( SID_NAVIGATOR_INIT, SFX_CALLMODE_ASYNCHRON | SFX_CALLMODE_RECORD, &aItem, 0L );
@@ -186,3 +182,5 @@ void PresentationViewShell::Resize (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdruler.cxx b/sd/source/ui/view/sdruler.cxx
index 6c8e3757c..9a31b3f9e 100755..100644
--- a/sd/source/ui/view/sdruler.cxx
+++ b/sd/source/ui/view/sdruler.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,9 +32,7 @@
#include "Ruler.hxx"
#include <svl/ptitem.hxx>
#include <svx/ruler.hxx>
-#ifndef _SVXIDS_HXX //autogen
#include <svx/svxids.hrc>
-#endif
#include <sfx2/ctrlitem.hxx>
#include <sfx2/bindings.hxx>
@@ -64,21 +63,12 @@ class RulerCtrlItem : public SfxControllerItem
RulerCtrlItem(sal_uInt16 nId, Ruler& rRlr, SfxBindings& rBind);
};
-/*************************************************************************
-|*
-\************************************************************************/
-
RulerCtrlItem::RulerCtrlItem(sal_uInt16 _nId, Ruler& rRlr, SfxBindings& rBind)
: SfxControllerItem(_nId, rBind)
, rRuler(rRlr)
{
}
-
-/*************************************************************************
-|*
-\************************************************************************/
-
void RulerCtrlItem::StateChanged( sal_uInt16 nSId, SfxItemState, const SfxPoolItem* pState )
{
switch( nSId )
@@ -224,3 +214,4 @@ void Ruler::ExtraDown()
} // end of namespace sd
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdview.cxx b/sd/source/ui/view/sdview.cxx
index b5af00d27..4933d8bdd 100755..100644
--- a/sd/source/ui/view/sdview.cxx
+++ b/sd/source/ui/view/sdview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,9 +37,7 @@
#include <svx/obj3d.hxx>
#include <svx/fmview.hxx>
#include <editeng/outliner.hxx>
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <svx/svdograf.hxx>
#include <svx/svdoole2.hxx>
#include <svx/svdundo.hxx>
@@ -129,7 +128,6 @@ View::View(SdDrawDocument* pDrawDoc, OutputDevice* pOutDev,
mnDragSrcPgNum(SDRPAGE_NOTFOUND),
mnAction(DND_ACTION_NONE),
mnLockRedrawSmph(0),
- mpLockedRedraws(NULL),
mbIsDropAllowed(sal_True),
maSmartTags(*this),
mpClipboard (new ViewClipboard (*this))
@@ -191,18 +189,6 @@ View::~View()
// Alle angemeldeten OutDevs entfernen
DeleteWindowFromPaintView(GetFirstOutputDevice() /*GetWin(0)*/);
}
-
- // gespeicherte Redraws loeschen
- if (mpLockedRedraws)
- {
- SdViewRedrawRec* pRec = (SdViewRedrawRec*)mpLockedRedraws->First();
- while (pRec)
- {
- delete pRec;
- pRec = (SdViewRedrawRec*)mpLockedRedraws->Next();
- }
- delete mpLockedRedraws;
- }
}
@@ -544,13 +530,10 @@ void View::CompleteRedraw(OutputDevice* pOutDev, const Region& rReg, sdr::contac
// oder speichern?
else
{
- if (!mpLockedRedraws)
- mpLockedRedraws = new List;
-
SdViewRedrawRec* pRec = new SdViewRedrawRec;
pRec->mpOut = pOutDev;
pRec->aRect = rReg.GetBoundRect();
- mpLockedRedraws->Insert(pRec, LIST_APPEND);
+ maLockedRedraws.push_back(pRec);
}
}
@@ -1012,12 +995,6 @@ void View::DoConnect(SdrOle2Obj* pObj)
}
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
sal_Bool View::IsMorphingAllowed() const
{
const SdrMarkList& rMarkList = GetMarkedObjectList();
@@ -1064,12 +1041,6 @@ sal_Bool View::IsMorphingAllowed() const
return bRet;
}
-/*************************************************************************
-|*
-|*
-|*
-\************************************************************************/
-
sal_Bool View::IsVectorizeAllowed() const
{
const SdrMarkList& rMarkList = GetMarkedObjectList();
@@ -1314,3 +1285,5 @@ void View::OnEndPasteOrDrop( PasteOrDropInfos* pInfos )
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdview2.cxx b/sd/source/ui/view/sdview2.cxx
index f24ddbcb7..562c14349 100755..100644
--- a/sd/source/ui/view/sdview2.cxx
+++ b/sd/source/ui/view/sdview2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,9 +36,7 @@
#include <com/sun/star/embed/XEmbedPersist.hpp>
#include <tools/ref.hxx>
#include <tools/urlobj.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svx/svdetc.hxx>
#include <svx/svdoole2.hxx>
#include <svx/svdograf.hxx>
@@ -822,7 +821,6 @@ sal_Int8 View::ExecuteDrop( const ExecuteDropEvent& rEvt, DropTargetHelper& rTar
pAction->SetPathObj(pInfo->mpPathObj, pInfo->mpPathObj);
pAction->SetClickAction(pInfo->meClickAction, eClickAction);
pAction->SetBookmark(pInfo->GetBookmark(), aBookmark);
-// pAction->SetInvisibleInPres(pInfo->mbInvisibleInPresentation, sal_True);
pAction->SetVerb(pInfo->mnVerb, pInfo->mnVerb);
pAction->SetSecondEffect(pInfo->meSecondEffect, pInfo->meSecondEffect);
pAction->SetSecondSpeed(pInfo->meSecondSpeed, pInfo->meSecondSpeed);
@@ -906,7 +904,7 @@ IMPL_LINK( View, ExecuteNavigatorDrop, SdNavigatorDropEvent*, pSdNavigatorDropEv
sal_True, &aPos );
}
- // Loeschen der ExchangeList
+ // Delete the ExchangeList
if( pExchangeList )
{
for( void* p = pExchangeList->First(); p; p = pExchangeList->Next() )
@@ -1036,3 +1034,5 @@ sal_Bool View::Paste(const SdrModel& rMod, const Point& rPos, SdrObjList* pLst /
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdview3.cxx b/sd/source/ui/view/sdview3.cxx
index 8670759a7..9625c262a 100755..100644
--- a/sd/source/ui/view/sdview3.cxx
+++ b/sd/source/ui/view/sdview3.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,7 +109,6 @@ namespace sd {
|*
\************************************************************************/
-// #83525#
struct ImpRememberOrigAndClone
{
SdrObject* pOrig;
@@ -125,7 +125,7 @@ SdrObject* ImpGetClone(Container& aConnectorContainer, SdrObject* pConnObj)
return 0L;
}
-// #90129# restrict movement to WorkArea
+// restrict movement to WorkArea
void ImpCheckInsertPos(Point& rPos, const Size& rSize, const Rectangle& rWorkArea)
{
if(!rWorkArea.IsEmpty())
@@ -164,30 +164,6 @@ bool View::InsertMetaFile( TransferableDataHelper& rDataHelper, const Point& rPo
if( !rDataHelper.GetGDIMetaFile( FORMAT_GDIMETAFILE, aMtf ) )
return false;
-/*
-SvFileStream aSvOutputStream( String( RTL_CONSTASCII_USTRINGPARAM( "/tmp/test.png" ) ), STREAM_WRITE | STREAM_TRUNC );
-Graphic aMtfGraphic( aMtf );
-Size aPreviewSizePixel( OutputDevice::LogicToLogic( aMtf.GetPrefSize(), aMtf.GetPrefMapMode(), MAP_PIXEL ) );
-
-if( aPreviewSizePixel.Width() && aPreviewSizePixel.Height() )
-{
- const double fWH = static_cast< double >( aPreviewSizePixel.Width() ) / static_cast< double >( aPreviewSizePixel.Height() );
-
- if( fWH <= 1.0 )
- aPreviewSizePixel.Width() = static_cast< long >( 128.0 * fWH ), aPreviewSizePixel.Height() = 128;
- else
- aPreviewSizePixel.Width() = 128, aPreviewSizePixel.Height() = static_cast< long >( 128.0 / fWH );
-
- if( GraphicConverter::Export( aSvOutputStream, aMtfGraphic.GetBitmapEx( &aPreviewSizePixel ), CVT_PNG ) )
- {
- // handle errror case here
- }
- else
- {
- // Success
- }
-}
-*/
bool bVector = false;
Graphic aGraphic;
@@ -275,7 +251,7 @@ if( aPreviewSizePixel.Width() && aPreviewSizePixel.Height() )
if( !bVector && (aGraphic.GetType() == GRAPHIC_NONE) )
bVector = true;
- // #90129# restrict movement to WorkArea
+ // restrict movement to WorkArea
Point aInsertPos( rPos );
Size aImageSize;
aImageSize = bVector ? aMtf.GetPrefSize() : aGraphic.GetSizePixel();
@@ -464,7 +440,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
pMarkList->ForceSort();
- // #83525# stuff to remember originals and clones
+ // stuff to remember originals and clones
Container aConnectorContainer(0);
sal_uInt32 a, nConnectorCount(0L);
Point aCurPos;
@@ -494,7 +470,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
{
if(!bDropOnTabBar)
{
- // #83525# do a NbcMove(...) instead of setting SnapRects here
+ // do a NbcMove(...) instead of setting SnapRects here
pObj->NbcMove(aVector);
}
@@ -507,7 +483,6 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
EndUndo();
}
- // #83525#
ImpRememberOrigAndClone* pRem = new ImpRememberOrigAndClone;
pRem->pOrig = pM->GetMarkedSdrObj();
pRem->pClone = pObj;
@@ -518,7 +493,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
}
}
- // #83525# try to re-establish connections at clones
+ // try to re-establish connections at clones
if(nConnectorCount)
{
for(a = 0; a < aConnectorContainer.Count(); a++)
@@ -597,7 +572,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
}
}
- // #83525# cleanup remember classes
+ // cleanup remember classes
for(a = 0; a < aConnectorContainer.Count(); a++)
delete (ImpRememberOrigAndClone*)aConnectorContainer.GetObject(a);
@@ -655,7 +630,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
pWorkPage->SetRectsDirty();
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
maDropPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
@@ -702,7 +677,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
if( pModel->GetPageCount() == 0 )
{
- DBG_ERROR("empty or invalid drawing xml document on clipboard!" );
+ OSL_FAIL("empty or invalid drawing xml document on clipboard!" );
}
else
{
@@ -808,7 +783,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
if( pOwnData )
{
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
maDropPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
@@ -874,7 +849,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
if( pOwnData )
{
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
maDropPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
@@ -916,17 +891,6 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
Graphic aGraphic;
sal_uLong nGrFormat = 0;
-// (wg. Selection Manager bei Trustet Solaris)
-#ifndef SOLARIS
-/*
- if( aDataHelper.GetGraphic( SOT_FORMATSTR_ID_SVXB, aGraphic ) )
- nGrFormat = SOT_FORMATSTR_ID_SVXB;
- else if( aDataHelper.GetGraphic( FORMAT_GDIMETAFILE, aGraphic ) )
- nGrFormat = SOT_FORMAT_GDIMETAFILE;
- else if( aDataHelper.GetGraphic( FORMAT_BITMAP, aGraphic ) )
- nGrFormat = SOT_FORMAT_BITMAP;
-*/
-#endif
// insert replacement image ( if there is one ) into the object helper
if ( nGrFormat )
@@ -1210,14 +1174,14 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
pWorkPage->SetRectsDirty();
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
aInsertPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
aInsertPos.Y() = pOwnData->GetStartPos().Y() + ( aSize.Height() >> 1 );
}
- // #90129# restrict movement to WorkArea
+ // restrict movement to WorkArea
Size aImageMapSize = OutputDevice::LogicToLogic(aGraphic.GetPrefSize(),
aGraphic.GetPrefMapMode(), MapMode(MAP_100TH_MM));
@@ -1241,7 +1205,7 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
pWorkPage->SetRectsDirty();
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
aInsertPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
@@ -1267,14 +1231,14 @@ sal_Bool View::InsertData( const TransferableDataHelper& rDataHelper,
pWorkPage->SetRectsDirty();
- // #104148# Use SnapRect, not BoundRect
+ // Use SnapRect, not BoundRect
Size aSize( pWorkPage->GetAllObjSnapRect().GetSize() );
aInsertPos.X() = pOwnData->GetStartPos().X() + ( aSize.Width() >> 1 );
aInsertPos.Y() = pOwnData->GetStartPos().Y() + ( aSize.Height() >> 1 );
}
- // #90129# restrict movement to WorkArea
+ // restrict movement to WorkArea
Size aImageMapSize(aBmp.GetPrefSize());
ImpCheckInsertPos(aInsertPos, aImageMapSize, GetWorkArea());
@@ -1505,3 +1469,5 @@ bool View::PasteRTFTable( SotStorageStreamRef xStm, SdrPage* pPage, sal_uLong nP
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx
index 28da6b7d8..5e9c442bb 100755..100644
--- a/sd/source/ui/view/sdview4.cxx
+++ b/sd/source/ui/view/sdview4.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -207,7 +208,6 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction,
aPageSize.Width() -= pPage->GetLftBorder() + pPage->GetRgtBorder();
aPageSize.Height() -= pPage->GetUppBorder() + pPage->GetLwrBorder();
pNewGrafObj->AdjustToMaxRect( Rectangle( Point(), aPageSize ), sal_True );
-// pNewGrafObj->AdjustToMaxRect( Rectangle( pPV->GetOffset(), aPageSize ), sal_True );
sal_uLong nOptions = SDRINSERT_SETDEFLAYER;
sal_Bool bIsPresTarget = sal_False;
@@ -386,21 +386,17 @@ IMPL_LINK( View, DropInsertFileHdl, Timer*, EMPTYARG )
aURL = INetURLObject( aURLStr );
}
- GraphicFilter* pGraphicFilter = GraphicFilter::GetGraphicFilter();
+ GraphicFilter& rGraphicFilter = GraphicFilter::GetGraphicFilter();
Graphic aGraphic;
aCurrentDropFile = aURL.GetMainURL( INetURLObject::NO_DECODE );
if( !::avmedia::MediaWindow::isMediaURL( aCurrentDropFile ) )
{
- if( !pGraphicFilter->ImportGraphic( aGraphic, aURL ) )
+ if( !rGraphicFilter.ImportGraphic( aGraphic, aURL ) )
{
sal_Int8 nTempAction = ( aIter == maDropFileVector.begin() ) ? mnAction : 0;
- const bool bLink = ( ( nTempAction & DND_ACTION_LINK ) != 0 );
- SdrGrafObj* pGrafObj = InsertGraphic( aGraphic, nTempAction, maDropPos, NULL, NULL );
-
- if( pGrafObj && bLink )
- pGrafObj->SetGraphicLink( aCurrentDropFile, String() );
+ InsertGraphic( aGraphic, nTempAction, maDropPos, NULL, NULL );
// return action from first inserted graphic
if( aIter == maDropFileVector.begin() )
@@ -589,34 +585,32 @@ void View::LockRedraw(sal_Bool bLock)
// alle gespeicherten Redraws ausfuehren
if (!mnLockRedrawSmph)
{
- while (mpLockedRedraws && mpLockedRedraws->Count())
+ boost::ptr_vector<SdViewRedrawRec>::iterator iter;
+
+ while (!maLockedRedraws.empty())
{
- SdViewRedrawRec* pRec = (SdViewRedrawRec*)mpLockedRedraws->First();
- OutputDevice* pCurrentOut = pRec->mpOut;
- Rectangle aBoundRect(pRec->aRect);
- mpLockedRedraws->Remove(pRec);
- delete pRec;
-
- pRec = (SdViewRedrawRec*)mpLockedRedraws->First();
- while (pRec)
+ iter = maLockedRedraws.begin();
+
+ OutputDevice* pCurrentOut = iter->mpOut;
+ Rectangle aBoundRect(iter->aRect);
+
+ iter = maLockedRedraws.erase(iter);
+
+ while (iter != maLockedRedraws.end())
{
- if (pRec->mpOut == pCurrentOut)
+ if (iter->mpOut == pCurrentOut)
{
- aBoundRect.Union(pRec->aRect);
- mpLockedRedraws->Remove(pRec);
- delete pRec;
- pRec = (SdViewRedrawRec*)mpLockedRedraws->GetCurObject();
+ aBoundRect.Union(iter->aRect);
+ iter = maLockedRedraws.erase(iter);
}
else
{
- pRec = (SdViewRedrawRec*)mpLockedRedraws->Next();
+ ++iter;
}
}
CompleteRedraw(pCurrentOut, Region(aBoundRect));
}
- delete mpLockedRedraws;
- mpLockedRedraws = NULL;
}
}
}
@@ -636,3 +630,5 @@ SfxStyleSheet* View::GetStyleSheet() const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdview5.cxx b/sd/source/ui/view/sdview5.cxx
index 5970ed7dd..4b88a16e2 100755..100644
--- a/sd/source/ui/view/sdview5.cxx
+++ b/sd/source/ui/view/sdview5.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,7 +97,7 @@ SdrObject* View::GetEmptyPresentationObject( PresObjKind eKind )
{
const std::list< SdrObject* >& rShapes = pPage->GetPresentationShapeList().getList();
- for( std::list< SdrObject* >::const_iterator iter( rShapes.begin() ); iter != rShapes.end(); iter++ )
+ for( std::list< SdrObject* >::const_iterator iter( rShapes.begin() ); iter != rShapes.end(); ++iter )
{
if( (*iter)->IsEmptyPresObj() && implIsMultiPresObj(pPage->GetPresObjKind(*iter)) )
{
@@ -112,3 +113,5 @@ SdrObject* View::GetEmptyPresentationObject( PresObjKind eKind )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/sdwindow.cxx b/sd/source/ui/view/sdwindow.cxx
index 08b5c91cb..25ea467c7 100755..100644
--- a/sd/source/ui/view/sdwindow.cxx
+++ b/sd/source/ui/view/sdwindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,6 +73,7 @@ Window::Window(::Window* pParent)
maWinPos(0, 0), // vorsichtshalber; die Werte sollten aber
maViewOrigin(0, 0), // vom Besitzer des Fensters neu gesetzt
maViewSize(1000, 1000), // werden
+ maPrevSize(-1,-1),
mnMinZoom(MIN_ZOOM),
mnMaxZoom(MAX_ZOOM),
mbMinZoomAutoCalc(false),
@@ -471,6 +473,9 @@ long Window::SetZoomFactor(long nZoom)
aMap.SetScaleY(Fraction(nZoom, 100));
SetMapMode(aMap);
+ // invalidate previous size - it was relative to the old scaling
+ maPrevSize = Size(-1,-1);
+
// Update the map mode's origin (to what effect?).
UpdateMapOrigin();
@@ -667,11 +672,20 @@ void Window::SetMinZoomAutoCalc (bool bAuto)
void Window::UpdateMapOrigin(sal_Bool bInvalidate)
{
- sal_Bool bChanged = sal_False;
- Size aWinSize = PixelToLogic(GetOutputSizePixel());
+ sal_Bool bChanged = sal_False;
+ const Size aWinSize = PixelToLogic(GetOutputSizePixel());
if ( mbCenterAllowed )
{
+ if( maPrevSize != Size(-1,-1) )
+ {
+ // keep view centered around current pos, when window
+ // resizes
+ maWinPos.X() -= (aWinSize.Width() - maPrevSize.Width()) / 2;
+ maWinPos.Y() -= (aWinSize.Height() - maPrevSize.Height()) / 2;
+ bChanged = sal_True;
+ }
+
if ( maWinPos.X() > maViewSize.Width() - aWinSize.Width() )
{
maWinPos.X() = maViewSize.Width() - aWinSize.Width();
@@ -696,6 +710,8 @@ void Window::UpdateMapOrigin(sal_Bool bInvalidate)
UpdateMapMode ();
+ maPrevSize = aWinSize;
+
if (bChanged && bInvalidate)
Invalidate();
}
@@ -705,7 +721,6 @@ void Window::UpdateMapOrigin(sal_Bool bInvalidate)
void Window::UpdateMapMode (void)
{
- Size aWinSize = PixelToLogic(GetOutputSizePixel());
maWinPos -= maViewOrigin;
Size aPix(maWinPos.X(), maWinPos.Y());
aPix = LogicToPixel(aPix);
@@ -717,9 +732,6 @@ void Window::UpdateMapMode (void)
if (mpViewShell && mpViewShell->ISA(DrawViewShell))
{
- Size aViewSizePixel = LogicToPixel(maViewSize);
- Size aWinSizePixel = LogicToPixel(aWinSize);
-
// Seite soll nicht am Fensterrand "kleben"
if (aPix.Width() == 0)
{
@@ -793,8 +805,6 @@ void Window::SetVisibleXY(double fX, double fY)
if ( fY >= 0 )
maWinPos.Y() = (long) (fY * maViewSize.Height());
UpdateMapOrigin(sal_False);
- // Size sz(nOldX - aWinPos.X(), nOldY - aWinPos.Y());
- // sz = LogicToPixel(sz);
Scroll(nOldX - maWinPos.X(), nOldY - maWinPos.Y(), SCROLL_CHILDREN);
Update();
}
@@ -967,12 +977,10 @@ void Window::DataChanged( const DataChangedEvent& rDCEvt )
{
SetDrawMode( nOutputMode );
mpViewShell->GetFrameView()->SetDrawMode( nOutputMode );
-// #110094#-7
-// mpViewShell->GetView()->ReleaseMasterPagePaintCache();
Invalidate();
}
- // #103100# Overwrite window color for OutlineView
+ // Overwrite window color for OutlineView
if( mpViewShell->ISA(OutlineViewShell ) )
{
svtools::ColorConfig aColorConfig;
@@ -985,7 +993,7 @@ void Window::DataChanged( const DataChangedEvent& rDCEvt )
mpViewShell->Invalidate();
mpViewShell->ArrangeGUIElements();
- // #101928# re-create handles to show new outfit
+ // re-create handles to show new outfit
if(mpViewShell->ISA(DrawViewShell))
{
mpViewShell->GetView()->AdjustMarkHdl();
@@ -1208,3 +1216,5 @@ Selection Window::GetSurroundingTextSelection() const
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/tabcontr.cxx b/sd/source/ui/view/tabcontr.cxx
index e16d97ca3..afde7ac68 100755..100644
--- a/sd/source/ui/view/tabcontr.cxx
+++ b/sd/source/ui/view/tabcontr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115,10 +116,6 @@ TabControl::~TabControl()
{
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::Select()
{
SfxDispatcher* pDispatcher = pDrViewSh->GetViewFrame()->GetDispatcher();
@@ -126,10 +123,6 @@ void TabControl::Select()
SFX_CALLMODE_RECORD);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::MouseButtonDown(const MouseEvent& rMEvt)
{
if (rMEvt.IsLeft()
@@ -176,10 +169,6 @@ void TabControl::MouseButtonDown(const MouseEvent& rMEvt)
TabBar::MouseButtonDown(rMEvt);
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::DoubleClick()
{
if (GetCurPageId() != 0)
@@ -342,10 +331,6 @@ sal_Int8 TabControl::ExecuteDrop( const ExecuteDropEvent& rEvt )
return nRet;
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::Command(const CommandEvent& rCEvt)
{
sal_uInt16 nCmd = rCEvt.GetCommand();
@@ -360,10 +345,6 @@ void TabControl::Command(const CommandEvent& rCEvt)
}
}
-/*************************************************************************
-|*
-\************************************************************************/
-
long TabControl::StartRenaming()
{
sal_Bool bOK = sal_False;
@@ -381,10 +362,6 @@ long TabControl::StartRenaming()
return( bOK );
}
-/*************************************************************************
-|*
-\************************************************************************/
-
long TabControl::AllowRenaming()
{
sal_Bool bOK = sal_True;
@@ -408,21 +385,12 @@ long TabControl::AllowRenaming()
return( bOK );
}
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::EndRenaming()
{
if( !IsEditModeCanceled() )
pDrViewSh->RenameSlide( GetEditPageId(), GetEditText() );
}
-
-/*************************************************************************
-|*
-\************************************************************************/
-
void TabControl::ActivatePage()
{
if ( /*IsInSwitching && */ pDrViewSh->IsSwitchPageAllowed() )
@@ -433,11 +401,6 @@ void TabControl::ActivatePage()
}
}
-
-/*************************************************************************
-|*
-\************************************************************************/
-
long TabControl::DeactivatePage()
{
return pDrViewSh->IsSwitchPageAllowed();
@@ -462,3 +425,5 @@ void TabControl::SendDeactivatePageEvent (void)
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/unmodpg.cxx b/sd/source/ui/view/unmodpg.cxx
index 39bb1c54a..90a46edfb 100755..100644
--- a/sd/source/ui/view/unmodpg.cxx
+++ b/sd/source/ui/view/unmodpg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,7 +99,7 @@ ModifyPageUndoAction::ModifyPageUndoAction(
#include <svx/svdview.hxx>
void ModifyPageUndoAction::Undo()
{
- // #94637# invalidate Selection, there could be objects deleted in tis UNDO
+ // invalidate Selection, there could be objects deleted in tis UNDO
// which are no longer allowed to be selected then.
SdrViewIter aIter(mpPage);
SdrView* pView = aIter.FirstView();
@@ -147,7 +148,7 @@ void ModifyPageUndoAction::Undo()
void ModifyPageUndoAction::Redo()
{
- // #94637# invalidate Selection, there could be objects deleted in tis UNDO
+ // invalidate Selection, there could be objects deleted in tis UNDO
// which are no longer allowed to be selected then.
SdrViewIter aIter(mpPage);
SdrView* pView = aIter.FirstView();
@@ -245,3 +246,4 @@ String RenameLayoutTemplateUndoAction::GetComment() const
return maComment;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/viewoverlaymanager.cxx b/sd/source/ui/view/viewoverlaymanager.cxx
index 129b919b5..15797bf91 100755..100644
--- a/sd/source/ui/view/viewoverlaymanager.cxx
+++ b/sd/source/ui/view/viewoverlaymanager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: $
- * $Revision: $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -44,7 +42,6 @@
#include <tools/rcid.h>
#include <vcl/help.hxx>
-#include <vcl/imagerepository.hxx>
#include <vcl/lazydelete.hxx>
#include <svx/sdrpagewindow.hxx>
@@ -209,10 +206,10 @@ extern ::rtl::OUString ImplRetrieveLabelFromCommand( const Reference< XFrame >&
void ImageButtonHdl::onMouseEnter(const MouseEvent& rMEvt)
{
- int nHighlightId = 0;
if( pHdlList && pHdlList->GetView())
{
+ int nHighlightId = 0;
OutputDevice* pDev = pHdlList->GetView()->GetFirstOutputDevice();
if( pDev == 0 )
pDev = Application::GetDefaultDevice();
@@ -556,14 +553,16 @@ IMPL_LINK(ViewOverlayManager,UpdateTagsHdl, void *, EMPTYARG)
bool ViewOverlayManager::CreateTags()
{
bool bChanges = false;
+
+ ::boost::shared_ptr<ViewShell> aMainShell = mrBase.GetMainViewShell();
- SdPage* pPage = mrBase.GetMainViewShell()->getCurrentPage();
+ SdPage* pPage = aMainShell.get() ? aMainShell->getCurrentPage() : NULL;
if( pPage && !pPage->IsMasterPage() && (pPage->GetPageKind() == PK_STANDARD) )
{
const std::list< SdrObject* >& rShapes = pPage->GetPresentationShapeList().getList();
- for( std::list< SdrObject* >::const_iterator iter( rShapes.begin() ); iter != rShapes.end(); iter++ )
+ for( std::list< SdrObject* >::const_iterator iter( rShapes.begin() ); iter != rShapes.end(); ++iter )
{
if( (*iter)->IsEmptyPresObj() && ((*iter)->GetObjIdentifier() == OBJ_OUTLINETEXT) && (mrBase.GetDrawView()->GetTextEditObject() != (*iter)) )
{
@@ -617,3 +616,5 @@ IMPL_LINK(ViewOverlayManager,EventMultiplexerListener,
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/viewshe2.cxx b/sd/source/ui/view/viewshe2.cxx
index 2dd77da5d..2aef1b6c1 100755..100644
--- a/sd/source/ui/view/viewshe2.cxx
+++ b/sd/source/ui/view/viewshe2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,12 +40,8 @@
#include "ViewShellImplementation.hxx"
#include "FactoryIds.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _SCRBAR_HXX //autogen
#include <vcl/scrbar.hxx>
-#endif
#include <svx/svdpagv.hxx>
#include <sfx2/dispatch.hxx>
#include <sfx2/app.hxx>
@@ -57,12 +54,9 @@
#include <sfx2/dispatch.hxx>
#include <rtl/ustrbuf.hxx>
#include <unotools/moduleoptions.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <sot/clsids.hxx>
-#include "misc.hxx"
#include "strings.hrc"
#include "app.hrc"
#include "unokywds.hxx"
@@ -1205,9 +1199,11 @@ void ViewShell::AdaptDefaultsForChart(
}
catch( const uno::Exception & )
{
- OSL_ENSURE( false, "Exception caught in AdaptDefaultsForChart" );
+ OSL_FAIL( "Exception caught in AdaptDefaultsForChart" );
}
}
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/viewshe3.cxx b/sd/source/ui/view/viewshe3.cxx
index cbededae4..7d271a3fe 100644
--- a/sd/source/ui/view/viewshe3.cxx
+++ b/sd/source/ui/view/viewshe3.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,9 +66,7 @@
#include <comphelper/processfactory.hxx>
#include <rtl/ustrbuf.hxx>
#include "stlsheet.hxx"
-#ifndef SD_WINDOW_UPDATER_HXX
#include "WindowUpdater.hxx"
-#endif
#include "DrawViewShell.hxx"
#include "OutlineViewShell.hxx"
#include "drawview.hxx"
@@ -84,10 +83,7 @@
#include "optsitem.hxx"
#include "sdresid.hxx"
-// #96090#
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <sfx2/request.hxx>
#include <svl/aeitem.hxx>
#include <basic/sbstar.hxx>
@@ -136,19 +132,16 @@ void ViewShell::GetMenuState( SfxItemSet &rSet )
rSet.Put(SfxUInt16Item(SID_STYLE_FAMILY, nFamily ));
}
- // #96090#
if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_GETUNDOSTRINGS))
{
ImpGetUndoStrings(rSet);
}
- // #96090#
if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_GETREDOSTRINGS))
{
ImpGetRedoStrings(rSet);
}
- // #96090#
if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_UNDO))
{
::svl::IUndoManager* pUndoManager = ImpGetUndoManager();
@@ -164,7 +157,7 @@ void ViewShell::GetMenuState( SfxItemSet &rSet )
if(bActivate)
{
- // #87229# Set the necessary string like in
+ // Set the necessary string like in
// sfx2/source/view/viewfrm.cxx ver 1.23 ln 1072 ff.
String aTmp( SvtResId( STR_UNDO ) );
aTmp += pUndoManager->GetUndoActionComment(0);
@@ -176,7 +169,6 @@ void ViewShell::GetMenuState( SfxItemSet &rSet )
}
}
- // #96090#
if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_REDO))
{
::svl::IUndoManager* pUndoManager = ImpGetUndoManager();
@@ -192,7 +184,7 @@ void ViewShell::GetMenuState( SfxItemSet &rSet )
if(bActivate)
{
- // #87229# Set the necessary string like in
+ // Set the necessary string like in
// sfx2/source/view/viewfrm.cxx ver 1.23 ln 1081 ff.
String aTmp(SvtResId(STR_REDO));
aTmp += pUndoManager->GetRedoActionComment(0);
@@ -248,19 +240,6 @@ SdPage* ViewShell::CreateOrDuplicatePage (
const SfxItemSet* pArgs = rRequest.GetArgs();
if (! pArgs)
{
-/*
- // Make the layout menu visible in the tool pane.
- const ViewShellBase& rBase (GetViewShellBase());
- if (rBase.GetMainViewShell()!=NULL
- && rBase.GetMainViewShell()->GetShellType()!=ViewShell::ST_OUTLINE
- && rBase.GetMainViewShell()->GetShellType()!=ViewShell::ST_DRAW)
- {
- framework::FrameworkHelper::Instance(GetViewShellBase())->RequestTaskPanel(
- framework::FrameworkHelper::msLayoutTaskPanelURL,
- false);
- }
-*/
-
// AutoLayouts muessen fertig sein
pDocument->StopWorkStartupDelay();
@@ -415,8 +394,6 @@ SdPage* ViewShell::CreateOrDuplicatePage (
ePageKind,
aStandardPageName,
aNotesPageName,
- eStandardLayout,
- eNotesLayout,
bIsPageBack,
bIsPageObj,
nInsertPosition);
@@ -446,3 +423,5 @@ SdPage* ViewShell::CreateOrDuplicatePage (
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx
index 9a3ee6985..d819b11db 100755..100644
--- a/sd/source/ui/view/viewshel.cxx
+++ b/sd/source/ui/view/viewshel.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -31,9 +32,7 @@
#include "ViewShell.hxx"
#include "ViewShellImplementation.hxx"
-#ifndef _COM_SUN_STAR_EMBED_EMBEDSTATE_HPP_
#include <com/sun/star/embed/EmbedStates.hpp>
-#endif
#include "ViewShellBase.hxx"
#include "ShellFactory.hxx"
#include "DrawController.hxx"
@@ -42,18 +41,12 @@
#include <sfx2/viewfrm.hxx>
#include <sfx2/bindings.hxx>
#include <sfx2/dispatch.hxx>
-#ifndef _SCRBAR_HXX //autogen
#include <vcl/scrbar.hxx>
-#endif
#include <svl/eitem.hxx>
#include <svx/ruler.hxx>
-#ifndef _SVXIDS_HXX
#include <svx/svxids.hrc>
-#endif
#include <svx/fmshell.hxx>
-#ifndef SD_WINDOW_UPDATER_HXX
#include "WindowUpdater.hxx"
-#endif
#include "GraphicViewShell.hxx"
#include <sfx2/childwin.hxx>
#include <sdxfer.hxx>
@@ -87,7 +80,6 @@
#include <svx/svdoutl.hxx>
#include <tools/diagnose_ex.h>
-// #96090#
#include <svl/slstitm.hxx>
#include <sfx2/request.hxx>
#include "SpellDialogChildWindow.hxx"
@@ -226,11 +218,6 @@ void ViewShell::construct(void)
mpContentWindow->SetViewShell(this);
mpContentWindow->SetPosSizePixel(
GetParentWindow()->GetPosPixel(),GetParentWindow()->GetSizePixel());
- mpContentWindow->Show();
- static_cast< ::Window*>(mpContentWindow.get())->Resize();
- OSL_TRACE("content window has size %d %d",
- mpContentWindow->GetSizePixel().Width(),
- mpContentWindow->GetSizePixel().Height());
if ( ! GetDocSh()->IsPreview())
{
@@ -239,18 +226,12 @@ void ViewShell::construct(void)
mpHorizontalScrollBar->EnableRTL (sal_False);
mpHorizontalScrollBar->SetRange(Range(0, 32000));
mpHorizontalScrollBar->SetScrollHdl(LINK(this, ViewShell, HScrollHdl));
- mpHorizontalScrollBar->Show();
mpVerticalScrollBar.reset (new ScrollBar(GetParentWindow(), WinBits(WB_VSCROLL | WB_DRAG)));
mpVerticalScrollBar->SetRange(Range(0, 32000));
mpVerticalScrollBar->SetScrollHdl(LINK(this, ViewShell, VScrollHdl));
- mpVerticalScrollBar->Show();
- maScrBarWH = Size(
- mpVerticalScrollBar->GetSizePixel().Width(),
- mpHorizontalScrollBar->GetSizePixel().Height());
mpScrollBarBox.reset(new ScrollBarBox(GetParentWindow(), WB_SIZEABLE));
- mpScrollBarBox->Show();
}
String aName( RTL_CONSTASCII_USTRINGPARAM( "ViewShell" ));
@@ -272,12 +253,31 @@ void ViewShell::construct(void)
// Register the sub shell factory.
mpImpl->mpSubShellFactory.reset(new ViewShellObjectBarFactory(*this));
GetViewShellBase().GetViewShellManager()->AddSubShellFactory(this,mpImpl->mpSubShellFactory);
-
- GetParentWindow()->Show();
}
+void ViewShell::doShow(void)
+{
+ mpContentWindow->Show();
+ static_cast< ::Window*>(mpContentWindow.get())->Resize();
+ OSL_TRACE("content window has size %d %d",
+ mpContentWindow->GetSizePixel().Width(),
+ mpContentWindow->GetSizePixel().Height());
+ if ( ! GetDocSh()->IsPreview())
+ {
+ // Show scroll bars
+ mpHorizontalScrollBar->Show();
+
+ mpVerticalScrollBar->Show();
+ maScrBarWH = Size(
+ mpVerticalScrollBar->GetSizePixel().Width(),
+ mpHorizontalScrollBar->GetSizePixel().Height());
+ mpScrollBarBox->Show();
+ }
+
+ GetParentWindow()->Show();
+}
void ViewShell::Init (bool bIsMainViewShell)
{
@@ -325,8 +325,7 @@ void ViewShell::Activate(sal_Bool bIsMDIActivate)
// Laut MI darf keiner GrabFocus rufen, der nicht genau weiss von
// welchem Window der Focus gegrabt wird. Da Activate() vom SFX teilweise
// asynchron verschickt wird, kann es sein, dass ein falsches Window
- // den Focus hat (#29682#):
- //GetViewFrame()->GetWindow().GrabFocus();
+ // den Focus hat
if (mpHorizontalRuler.get() != NULL)
mpHorizontalRuler->SetActive(sal_True);
@@ -362,12 +361,6 @@ void ViewShell::Activate(sal_Bool bIsMDIActivate)
if(!GetDocSh()->IsUIActive())
UpdatePreview( GetActualPage(), sal_True );
- //HMH::sd::View* pView = GetView();
-
- //HMHif (pView)
- //HMH{
- //HMH pView->ShowMarkHdl();
- //HMH}
}
ReadFrameViewData( mpFrameView );
@@ -463,7 +456,6 @@ sal_Bool ViewShell::KeyInput(const KeyEvent& rKEvt, ::sd::Window* pWin)
if(!bReturn)
{
- // #76008#
// give key input first to SfxViewShell to give CTRL+Key
// (e.g. CTRL+SHIFT+'+', to front) priority.
OSL_ASSERT (GetViewShell()!=NULL);
@@ -537,7 +529,6 @@ void ViewShell::MouseButtonDown(const MouseEvent& rMEvt, ::sd::Window* pWin)
{
pWin->GrabFocus();
SetActiveWindow(pWin);
-// GetViewFrame()->GetWindow().GrabFocus();
}
// MouseEvent in E3dView eintragen
@@ -662,7 +653,7 @@ void ViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
{
bConsumed = GetView()->getSmartTags().Command(rCEvt);
}
-
+
if( !bConsumed && HasCurrentFunction())
{
GetCurrentFunction()->Command(rCEvt);
@@ -815,14 +806,14 @@ void ViewShell::Resize (void)
if (mpParentWindow == NULL)
return;
-
+
// Make sure that the new size is not degenerate.
const Size aSize (mpParentWindow->GetSizePixel());
if (aSize.Width()==0 || aSize.Height()==0)
return;
// Remember the new position and size.
- maViewPos = Point(0,0); //mpParentWindow->GetPosPixel();
+ maViewPos = Point(0,0);
maViewSize = aSize;
// Rearrange the UI elements to take care of the new position and size.
@@ -830,18 +821,12 @@ void ViewShell::Resize (void)
// end of included AdjustPosSizePixel.
Size aS (GetParentWindow()->GetOutputSizePixel());
- Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel();
- Rectangle aVisArea = GetParentWindow()->PixelToLogic(
- Rectangle( Point(0,0), aVisSizePixel));
Rectangle aCurrentVisArea (GetDocSh()->GetVisArea(ASPECT_CONTENT));
- Rectangle aWindowRect = GetActiveWindow()->LogicToPixel(aCurrentVisArea);
if (GetDocSh()->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED
&& IsMainViewShell())
{
- // GetDocSh()->SetVisArea(aVisArea);
- }
- // VisAreaChanged(aVisArea);
+ }
::sd::View* pView = GetView();
@@ -1089,22 +1074,17 @@ void ViewShell::ImpGetUndoStrings(SfxItemSet &rSet) const
if(nCount)
{
// prepare list
- List aStringList;
+ ::std::vector< String > aStringList;
sal_uInt16 a;
for( a = 0; a < nCount; a++)
{
// generate one String in list per undo step
- String* pInsertString = new String(pUndoManager->GetUndoActionComment(a));
- aStringList.Insert(pInsertString, LIST_APPEND);
+ aStringList.push_back( String(pUndoManager->GetUndoActionComment(a)) );
}
// set item
rSet.Put(SfxStringListItem(SID_GETUNDOSTRINGS, &aStringList));
-
- // delete Strings again
- for(a = 0; a < nCount; a++)
- delete (String*)aStringList.GetObject(a);
}
else
{
@@ -1124,22 +1104,17 @@ void ViewShell::ImpGetRedoStrings(SfxItemSet &rSet) const
if(nCount)
{
// prepare list
- List aStringList;
+ ::std::vector< String > aStringList;
sal_uInt16 a;
for( a = 0; a < nCount; a++)
{
// generate one String in list per undo step
- String* pInsertString = new String(pUndoManager->GetRedoActionComment(a));
- aStringList.Insert(pInsertString, LIST_APPEND);
+ aStringList.push_back( String(pUndoManager->GetRedoActionComment(a)) );
}
// set item
rSet.Put(SfxStringListItem(SID_GETREDOSTRINGS, &aStringList));
-
- // delete Strings again
- for(a = 0; a < nCount; a++)
- delete (String*)aStringList.GetObject(a);
}
else
{
@@ -1169,7 +1144,7 @@ void ViewShell::ImpSidUndo(sal_Bool, SfxRequest& rReq)
{
try
{
- // #94637# when UndoStack is cleared by ModifyPageUndoAction
+ // when UndoStack is cleared by ModifyPageUndoAction
// the nCount may have changed, so test GetUndoActionCount()
while(nNumber-- && pUndoManager->GetUndoActionCount())
{
@@ -1183,7 +1158,7 @@ void ViewShell::ImpSidUndo(sal_Bool, SfxRequest& rReq)
}
}
- // #91081# refresh rulers, maybe UNDO was move of TAB marker in ruler
+ // refresh rulers, maybe UNDO was move of TAB marker in ruler
if (mbHasRulers)
{
Invalidate(SID_ATTR_TABSTOP);
@@ -1218,7 +1193,7 @@ void ViewShell::ImpSidRedo(sal_Bool, SfxRequest& rReq)
{
try
{
- // #94637# when UndoStack is cleared by ModifyPageRedoAction
+ // when UndoStack is cleared by ModifyPageRedoAction
// the nCount may have changed, so test GetRedoActionCount()
while(nNumber-- && pUndoManager->GetRedoActionCount())
{
@@ -1232,7 +1207,7 @@ void ViewShell::ImpSidRedo(sal_Bool, SfxRequest& rReq)
}
}
- // #91081# refresh rulers, maybe REDO was move of TAB marker in ruler
+ // refresh rulers, maybe REDO was move of TAB marker in ruler
if (mbHasRulers)
{
Invalidate(SID_ATTR_TABSTOP);
@@ -1284,8 +1259,7 @@ void ViewShell::ExecReq( SfxRequest& rReq )
GetActiveWindow()->SetDrawMode( nMode );
mpFrameView->SetDrawMode( nMode );
-// #110094#-7
-// GetView()->ReleaseMasterPagePaintCache();
+
GetActiveWindow()->Invalidate();
Invalidate();
@@ -1305,6 +1279,8 @@ void ViewShell::ExecReq( SfxRequest& rReq )
::com::sun::star::accessibility::XAccessible>
ViewShell::CreateAccessibleDocumentView (::sd::Window* )
{
+ OSL_FAIL("ViewShell::CreateAccessibleDocumentView should not be called!, perhaps Meyers, 3rd edition, Item 9:\n");
+
return ::com::sun::star::uno::Reference<
::com::sun::star::accessibility::XAccessible> ();
}
@@ -1427,7 +1403,6 @@ void ViewShell::DisposeFunctions()
bool ViewShell::IsMainViewShell (void) const
{
return mpImpl->mbIsMainViewShell;
- // return GetViewShellBase().GetMainViewShell() == this;
}
void ViewShell::SetIsMainViewShell (bool bIsMainViewShell)
@@ -1634,3 +1609,5 @@ void ViewShellObjectBarFactory::ReleaseShell (SfxShell* pShell)
}
} // end of anonymous namespace
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/zoomlist.cxx b/sd/source/ui/view/zoomlist.cxx
index dd363cfa9..80b670cae 100755..100644
--- a/sd/source/ui/view/zoomlist.cxx
+++ b/sd/source/ui/view/zoomlist.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,15 +31,10 @@
#include "zoomlist.hxx"
-#ifndef _SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#include <sfx2/bindings.hxx>
#include <sfx2/viewfrm.hxx>
-#ifndef _SFXVIEWSHELL_HXX
#include <sfx2/viewsh.hxx>
-#endif
-
#include "ViewShell.hxx"
@@ -46,152 +42,69 @@ namespace sd {
#define MAX_ENTRYS 10
-/*************************************************************************
-|*
-|* Konstruktor
-|*
-\************************************************************************/
-
ZoomList::ZoomList(ViewShell* pViewShell)
-: List()
-, mpViewShell (pViewShell)
+: mpViewShell (pViewShell)
, mnCurPos(0)
{
}
-
-/*************************************************************************
-|*
-|* Destruktor
-|*
-\************************************************************************/
-
-ZoomList::~ZoomList()
-{
-#if ( defined GCC && defined C272 )
- for (sal_uLong nObject=0; nObject<List::Count(); nObject++)
-#else
- for (sal_uLong nObject=0; nObject<Count(); nObject++)
-#endif
- {
- // Ggf. ZoomRects loeschen
- delete ((Rectangle*) GetObject(nObject));
- }
-}
-
-
-/*************************************************************************
-|*
-|* Neues ZoomRect aufnehmen
-|*
-\************************************************************************/
-
void ZoomList::InsertZoomRect(const Rectangle& rRect)
{
- sal_uLong nRectCount = Count();
+ sal_uLong nRectCount = maRectangles.size();
if (nRectCount >= MAX_ENTRYS)
- {
- delete ((Rectangle*) GetObject(0));
- Remove((sal_uLong) 0);
- }
+ maRectangles.erase(maRectangles.begin());
else if (nRectCount == 0)
- {
mnCurPos = 0;
- }
else
- {
mnCurPos++;
- }
- Rectangle* pRect = new Rectangle(rRect);
- Insert(pRect, mnCurPos);
+ maRectangles.insert(maRectangles.begin()+mnCurPos,rRect);
SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings();
rBindings.Invalidate( SID_ZOOM_NEXT );
rBindings.Invalidate( SID_ZOOM_PREV );
}
-/*************************************************************************
-|*
-|* Naechstes ZoomRect herausgeben
-|*
-\************************************************************************/
-
Rectangle ZoomList::GetNextZoomRect()
{
mnCurPos++;
- sal_uLong nRectCount = Count();
+ sal_uLong nRectCount = maRectangles.size();
if (nRectCount > 0 && mnCurPos > nRectCount - 1)
- {
mnCurPos = nRectCount - 1;
- }
SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings();
rBindings.Invalidate( SID_ZOOM_NEXT );
rBindings.Invalidate( SID_ZOOM_PREV );
- Rectangle aRect(*(Rectangle*) GetObject(mnCurPos));
- return (aRect);
+ return maRectangles[mnCurPos];
}
-/*************************************************************************
-|*
-|* Letztes ZoomRect herausgeben
-|*
-\************************************************************************/
-
Rectangle ZoomList::GetPreviousZoomRect()
{
if (mnCurPos > 0)
- {
mnCurPos--;
- }
SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings();
rBindings.Invalidate( SID_ZOOM_NEXT );
rBindings.Invalidate( SID_ZOOM_PREV );
- Rectangle aRect(*(Rectangle*) GetObject(mnCurPos));
- return (aRect);
+ return maRectangles[mnCurPos];
}
-/*************************************************************************
-|*
-|* Gibt es ein naechstes ZoomRect?
-|*
-\************************************************************************/
-
sal_Bool ZoomList::IsNextPossible() const
{
- sal_Bool bPossible = sal_False;
- sal_uLong nRectCount = Count();
-
- if (nRectCount > 0 && mnCurPos < nRectCount - 1)
- {
- bPossible = sal_True;
- }
+ sal_uLong nRectCount = maRectangles.size();
- return (bPossible);
+ return nRectCount > 0 && mnCurPos < nRectCount - 1;
}
-/*************************************************************************
-|*
-|* Gibt es ein vorheriges ZoomRect?
-|*
-\************************************************************************/
-
sal_Bool ZoomList::IsPreviousPossible() const
{
- sal_Bool bPossible = sal_False;
-
- if (mnCurPos > 0)
- {
- bPossible = sal_True;
- }
-
- return (bPossible);
+ return mnCurPos > 0;
}
} // end of namespace sd
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/unotypes/makefile.mk b/sd/source/unotypes/makefile.mk
deleted file mode 100644
index 1780cdd54..000000000
--- a/sd/source/unotypes/makefile.mk
+++ /dev/null
@@ -1,53 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-PRJNAME=sd
-TARGET=unotypesanim
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-
-PRIVATERDB = slideshow.rdb
-UNOUCRRDB = $(SOLARBINDIR)$/$(PRIVATERDB)
-UNOUCRDEP = $(UNOUCRRDB)
-UNOUCROUT = $(OUT)$/inc
-
-CPPUMAKERFLAGS += -C -X$(SOLARBINDIR)$/types.rdb
-
-#UNOTYPES= \
-# com.sun.star.presentation.XSlideShow \
-# com.sun.star.presentation.XSlideShowView \
-# com.sun.star.presentation.XSlideShowListener \
-# com.sun.star.presentation.XShapeEventListener
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/sd/uiconfig/sdraw/menubar/menubar.xml b/sd/uiconfig/sdraw/menubar/menubar.xml
index 176f25cb0..55f620d86 100755
--- a/sd/uiconfig/sdraw/menubar/menubar.xml
+++ b/sd/uiconfig/sdraw/menubar/menubar.xml
@@ -55,6 +55,7 @@
<menu:menuitem menu:id=".uno:PasteSpecial"/>
<menu:menuitem menu:id=".uno:SelectAll"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id="vnd.sun.star.findbar:FocusToFindbar"/>
<menu:menuitem menu:id=".uno:SearchDialog"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:CopyObjects"/>
@@ -108,7 +109,6 @@
<menu:menuitem menu:id=".uno:ShowAnnotations"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Navigator"/>
- <menu:menuitem menu:id=".uno:TaskPane"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Zoom"/>
</menu:menupopup>
@@ -222,7 +222,6 @@
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Gallery"/>
<menu:menuitem menu:id=".uno:BmpMask"/>
- <menu:menuitem menu:id=".uno:AVMediaPlayer"/>
<menu:menuseparator/>
<menu:menu menu:id=".uno:MacrosMenu">
<menu:menupopup>
@@ -323,9 +322,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/sd/uiconfig/sdraw/statusbar/statusbar.xml b/sd/uiconfig/sdraw/statusbar/statusbar.xml
index e657e64ab..0872bd42f 100644
--- a/sd/uiconfig/sdraw/statusbar/statusbar.xml
+++ b/sd/uiconfig/sdraw/statusbar/statusbar.xml
@@ -3,7 +3,7 @@
<statusbar:statusbar xmlns:statusbar="http://openoffice.org/2001/statusbar" xmlns:xlink="http://www.w3.org/1999/xlink">
<statusbar:statusbaritem xlink:href=".uno:Context" statusbar:align="left" statusbar:autosize="true" statusbar:width="184" statusbar:helpid="helpid:5310"/>
<statusbar:statusbaritem xlink:href=".uno:Size" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="208" statusbar:helpid="helpid:10224"/>
- <statusbar:statusbaritem xlink:href=".uno:ModifiedStatus" statusbar:align="center" statusbar:width="14" statusbar:helpid="helpid:5584"/>
+ <statusbar:statusbaritem xlink:href=".uno:ModifiedStatus" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="14" statusbar:helpid="helpid:5584"/>
<statusbar:statusbaritem xlink:href=".uno:Signature" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="16" statusbar:helpid="helpid:5699"/>
<statusbar:statusbaritem xlink:href=".uno:PageStatus" statusbar:align="left" statusbar:width="124" statusbar:helpid="helpid:27086"/>
<statusbar:statusbaritem xlink:href=".uno:LayoutStatus" statusbar:align="left" statusbar:autosize="true" statusbar:width="54" statusbar:helpid="helpid:27087"/>
diff --git a/sd/uiconfig/sdraw/toolbar/toolbar.xml b/sd/uiconfig/sdraw/toolbar/toolbar.xml
index 5ac55e4e9..aa5d754e3 100644
--- a/sd/uiconfig/sdraw/toolbar/toolbar.xml
+++ b/sd/uiconfig/sdraw/toolbar/toolbar.xml
@@ -5,8 +5,8 @@
<toolbar:toolbarseparator/>
<toolbar:toolbaritem xlink:href=".uno:Line" toolbar:helpid="helpid:10102" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:LineArrowEnd" toolbar:helpid="helpid:27173" toolbar:style="radio" />
- <toolbar:toolbaritem xlink:href=".uno:Rect" toolbar:helpid="helpid:10104" toolbar:style="radio" />
- <toolbar:toolbaritem xlink:href=".uno:Ellipse" toolbar:helpid="helpid:10110" toolbar:style="radio" />
+ <toolbar:toolbaritem xlink:href=".uno:BasicShapes.rectangle" toolbar:helpid="helpid:10104" toolbar:style="radio" />
+ <toolbar:toolbaritem xlink:href=".uno:BasicShapes.ellipse" toolbar:helpid="helpid:10110" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:Text" toolbar:helpid="helpid:10398" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:VerticalText" toolbar:helpid="helpid:10398" toolbar:style="radio" />
<toolbar:toolbarseparator/>
diff --git a/sd/uiconfig/simpress/menubar/menubar.xml b/sd/uiconfig/simpress/menubar/menubar.xml
index bf669992c..03ddd6d68 100755
--- a/sd/uiconfig/simpress/menubar/menubar.xml
+++ b/sd/uiconfig/simpress/menubar/menubar.xml
@@ -57,6 +57,7 @@
<menu:menuitem menu:id=".uno:PasteSpecial"/>
<menu:menuitem menu:id=".uno:SelectAll"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id="vnd.sun.star.findbar:FocusToFindbar"/>
<menu:menuitem menu:id=".uno:SearchDialog"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:CopyObjects"/>
@@ -79,14 +80,14 @@
<menu:menuitem menu:id=".uno:NormalMultiPaneGUI" menu:style="radio"/>
<menu:menuitem menu:id=".uno:OutlineMode" menu:style="radio"/>
<menu:menuitem menu:id=".uno:DiaMode" menu:style="radio"/>
- <menu:menuitem menu:id=".uno:Presentation"/>
+ <menu:menuitem menu:id=".uno:Presentation" menu:style="radio"/>
<menu:menuitem menu:id=".uno:NotesMode" menu:style="radio"/>
<menu:menuitem menu:id=".uno:HandoutMode" menu:style="radio"/>
<menu:menuseparator/>
<menu:menu menu:id=".uno:MasterPageMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:SlideMasterPage"/>
- <menu:menuitem menu:id=".uno:NotesMasterPage"/>
+ <menu:menuitem menu:id=".uno:SlideMasterPage" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:NotesMasterPage" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:MasterLayouts"/>
</menu:menupopup>
@@ -297,9 +298,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/sd/uiconfig/simpress/statusbar/statusbar.xml b/sd/uiconfig/simpress/statusbar/statusbar.xml
index e657e64ab..0872bd42f 100644
--- a/sd/uiconfig/simpress/statusbar/statusbar.xml
+++ b/sd/uiconfig/simpress/statusbar/statusbar.xml
@@ -3,7 +3,7 @@
<statusbar:statusbar xmlns:statusbar="http://openoffice.org/2001/statusbar" xmlns:xlink="http://www.w3.org/1999/xlink">
<statusbar:statusbaritem xlink:href=".uno:Context" statusbar:align="left" statusbar:autosize="true" statusbar:width="184" statusbar:helpid="helpid:5310"/>
<statusbar:statusbaritem xlink:href=".uno:Size" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="208" statusbar:helpid="helpid:10224"/>
- <statusbar:statusbaritem xlink:href=".uno:ModifiedStatus" statusbar:align="center" statusbar:width="14" statusbar:helpid="helpid:5584"/>
+ <statusbar:statusbaritem xlink:href=".uno:ModifiedStatus" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="14" statusbar:helpid="helpid:5584"/>
<statusbar:statusbaritem xlink:href=".uno:Signature" statusbar:align="center" statusbar:ownerdraw="true" statusbar:width="16" statusbar:helpid="helpid:5699"/>
<statusbar:statusbaritem xlink:href=".uno:PageStatus" statusbar:align="left" statusbar:width="124" statusbar:helpid="helpid:27086"/>
<statusbar:statusbaritem xlink:href=".uno:LayoutStatus" statusbar:align="left" statusbar:autosize="true" statusbar:width="54" statusbar:helpid="helpid:27087"/>
diff --git a/sd/uiconfig/simpress/toolbar/toolbar.xml b/sd/uiconfig/simpress/toolbar/toolbar.xml
index 62d33c1fc..25bffb7e7 100644
--- a/sd/uiconfig/simpress/toolbar/toolbar.xml
+++ b/sd/uiconfig/simpress/toolbar/toolbar.xml
@@ -5,8 +5,8 @@
<toolbar:toolbarseparator/>
<toolbar:toolbaritem xlink:href=".uno:Line" toolbar:helpid="helpid:10102" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:LineArrowEnd" toolbar:helpid="helpid:27173" toolbar:style="radio" />
- <toolbar:toolbaritem xlink:href=".uno:Rect" toolbar:helpid="helpid:10104" toolbar:style="radio" />
- <toolbar:toolbaritem xlink:href=".uno:Ellipse" toolbar:helpid="helpid:10110" toolbar:style="radio" />
+ <toolbar:toolbaritem xlink:href=".uno:BasicShapes.rectangle" toolbar:helpid="helpid:10104" toolbar:style="radio" />
+ <toolbar:toolbaritem xlink:href=".uno:BasicShapes.ellipse" toolbar:helpid="helpid:10110" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:Text" toolbar:helpid="helpid:10398" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:VerticalText" toolbar:helpid="helpid:10398" toolbar:style="radio" />
<toolbar:toolbarseparator/>
diff --git a/sd/util/hidother.src b/sd/util/hidother.src
index 7e409bfdd..7e409bfdd 100755..100644
--- a/sd/util/hidother.src
+++ b/sd/util/hidother.src
diff --git a/sd/util/makefile.mk b/sd/util/makefile.mk
deleted file mode 100755
index 5794696b8..000000000
--- a/sd/util/makefile.mk
+++ /dev/null
@@ -1,291 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..
-
-PRJNAME=sd
-TARGET=sdraw3
-GEN_HID=TRUE
-GEN_HID_OTHER=TRUE
-USE_DEFFILE=TRUE
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Resources ----------------------------------------------------
-
-RESLIB1NAME=sd
-RESLIB1IMAGES=$(PRJ)$/res/imagelst $(PRJ)$/res
-RESLIB1SRSFILES=\
- $(SRS)$/app.srs \
- $(SRS)$/dlg.srs \
- $(SRS)$/core.srs \
- $(SRS)$/html.srs \
- $(SRS)$/accessibility.srs \
- $(SRS)$/notes.srs \
- $(SRS)$/animui.srs \
- $(SRS)$/slideshow.srs \
- $(SRS)$/slsview.srs \
- $(SRS)$/uitable.srs \
- $(SRS)$/view.srs \
- $(SRS)$/uiannotations.srs \
-
-
-# --- StarDraw DLL
-
-SHL1TARGET= sd$(DLLPOSTFIX)
-SHL1USE_EXPORTS=name
-SHL1IMPLIB= sdi
-
-# dynamic libraries
-SHL1STDLIBS+= \
- $(EDITENGLIB) \
- $(SVXCORELIB) \
- $(SVXLIB) \
- $(SFXLIB) \
- $(BASICLIB) \
- $(CPPCANVASLIB) \
- $(BASEGFXLIB) \
- $(DRAWINGLAYERLIB) \
- $(BASEGFXLIB) \
- $(SVTOOLLIB) \
- $(TKLIB) \
- $(VCLLIB) \
- $(SVLLIB) \
- $(SOTLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(I18NISOLANGLIB) \
- $(COMPHELPERLIB) \
- $(UCBHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(VOSLIB) \
- $(CANVASTOOLSLIB) \
- $(SALLIB) \
- $(AVMEDIALIB)
-
-SHL1LIBS= $(LIB3TARGET) $(LIB5TARGET) $(LIB6TARGET)
-SHL1DEPN+= makefile.mk
-
-SHL1DEF= $(MISC)$/$(SHL1TARGET).def
-DEF1DEPN =$(MISC)$/$(SHL1TARGET).flt
-DEF1NAME =$(SHL1TARGET)
-DEFLIB1NAME = $(TARGET) $(LIB5TARGET:b) $(LIB6TARGET:b)
-
-.IF "$(GUI)" == "WNT"
-SHL1RES= $(RCTARGET)
-.ENDIF
-
-# --- Linken der Applikation ---------------------------------------
-
-LIB2TARGET=$(SLB)$/sdmod.lib
-LIB2OBJFILES= \
- $(SLO)$/sdmod1.obj \
- $(SLO)$/sdmod2.obj \
- $(SLO)$/sdmod.obj
-
-LIB3TARGET=$(SLB)$/sdraw3.lib
-LIB3FILES= \
- $(SLB)$/view.lib \
- $(SLB)$/app.lib \
- $(SLB)$/docshell.lib \
- $(SLB)$/dlg.lib \
- $(SLB)$/core.lib \
- $(SLB)$/undo.lib \
- $(SLB)$/annotations.lib \
- $(SLB)$/text.lib \
- $(SLB)$/helper.lib \
- $(SLB)$/xml.lib \
- $(SLB)$/cgm.lib \
- $(SLB)$/uitable.lib \
- $(SLB)$/uiannotations.lib\
- $(SLB)$/grf.lib \
- $(SLB)$/controller.lib
-
-LIB5TARGET=$(SLB)$/sdraw3_2.lib
-LIB5FILES= \
- $(SLB)$/html.lib \
- $(SLB)$/filter.lib \
- $(SLB)$/unoidl.lib \
- $(SLB)$/animui.lib \
- $(SLB)$/accessibility.lib \
- $(SLB)$/toolpanel.lib \
- $(SLB)$/uitools.lib \
- $(SLB)$/tpcontrols.lib
-
-LIB6TARGET=$(SLB)$/sdraw3_3.lib
-LIB6FILES= \
- $(SLB)$/func.lib \
- $(SLB)$/func_2.lib \
- $(SLB)$/slsshell.lib \
- $(SLB)$/slsmodel.lib \
- $(SLB)$/slsview.lib \
- $(SLB)$/slscontroller.lib \
- $(SLB)$/slscache.lib \
- $(SLB)$/slideshow.lib \
- $(SLB)$/framework_configuration.lib \
- $(SLB)$/framework_factories.lib \
- $(SLB)$/framework_module.lib \
- $(SLB)$/framework_tools.lib \
- $(SLB)$/presenter.lib
-
-# sdd
-SHL2TARGET= sdd$(DLLPOSTFIX)
-SHL2IMPLIB= sddimp
-SHL2VERSIONMAP=$(SOLARENV)/src/component.map
-SHL2DEF=$(MISC)$/$(SHL2TARGET).def
-DEF2NAME= $(SHL2TARGET)
-
-SHL2STDLIBS= \
- $(SFX2LIB) \
- $(SVXCORELIB) \
- $(SVTOOLLIB) \
- $(SVLLIB) \
- $(VCLLIB) \
- $(SOTLIB) \
- $(TOOLSLIB) \
- $(UNOTOOLSLIB) \
- $(UCBHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(SALLIB)
-
-SHL2OBJS= $(SLO)$/sddetect.obj \
- $(SLO)$/detreg.obj
-
-SHL2DEPN+= makefile.mk
-
-# sdui
-SHL4TARGET= sdui$(DLLPOSTFIX)
-SHL4IMPLIB= sduiimp
-SHL4VERSIONMAP= sdui.map
-SHL4DEF=$(MISC)$/$(SHL4TARGET).def
-DEF4NAME= $(SHL4TARGET)
-SHL4LIBS= $(SLB)$/sdui_all.lib
-
-LIB4TARGET= $(SLB)$/sdui_all.lib
-LIB4FILES= \
- $(SLB)$/sdui.lib \
- $(SLB)$/func_ui.lib \
- $(SLB)$/html_ui.lib
-
-SHL4STDLIBS= \
- $(ISDLIB) \
- $(EDITENGLIB) \
- $(SVXCORELIB) \
- $(SVXLIB) \
- $(SFXLIB) \
- $(BASEGFXLIB) \
- $(SO2LIB) \
- $(SVTOOLLIB) \
- $(VCLLIB) \
- $(SVLLIB) \
- $(SOTLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(I18NISOLANGLIB) \
- $(COMPHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(CANVASLIB) \
- $(SALLIB)
-
-.IF "$(GUI)$(COM)" == "WNTMSC"
-.IF "$(ENABLE_PCH)" != ""
-#target sd
-SHL1OBJS += $(SLO)$/pchname.obj \
- $(SLO)$/pchname_ex.obj
-#target sdd
-SHL2OBJS += $(SLO)$/pchname.obj \
- $(SLO)$/pchname_ex.obj
-#target sdui
-SHL4OBJS += $(SLO)$/pchname.obj \
- $(SLO)$/pchname_ex.obj
-.ENDIF # "$(ENABLE_PCH)" != ""
-.ENDIF # "$(GUI)$(COM)" == "WNTMSC"
-
-# $(ISDLIB) is build in SHL1TARGET
-.IF "$(GUI)"=="UNX" || ("$(COM)"=="GCC" && "$(GUI)"=="WNT")
-SHL4DEPN=$(SHL1TARGETN)
-SHL5DEPN=$(SHL1TARGETN)
-.ELSE
-SHL4DEPN=$(SHL1IMPLIBN)
-SHL5DEPN=$(SHL1IMPLIBN)
-.ENDIF
-
-# ppt import/export library
-SHL5TARGET = sdfilt$(DLLPOSTFIX)
-SHL5IMPLIB = sdfilti
-SHL5VERSIONMAP= sdfilt.map
-SHL5DEF = $(MISC)$/$(SHL5TARGET).def
-SHL5LIBS = $(SLB)$/ppt.lib $(SLB)$/eppt.lib
-
-DEF5NAME=$(SHL5TARGET)
-
-SHL5STDLIBS = $(ISDLIB) \
- $(EDITENGLIB) \
- $(SVXCORELIB) \
- $(MSFILTERLIB) \
- $(SFX2LIB) \
- $(SVTOOLLIB) \
- $(SOTLIB) \
- $(VCLLIB) \
- $(SVLLIB) \
- $(SOTLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(UCBHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(SALLIB) \
- $(COMPHELPERLIB) \
- $(I18NISOLANGLIB)
-
-# --- Targets -------------------------------------------------------------
-
-.INCLUDE : target.mk
-
-$(MISC)$/$(SHL1TARGET).flt: makefile.mk
- @echo ------------------------------
- @echo Making: $@
- @$(TYPE) sd.flt > $@
-
-ALLTAR : $(MISC)/sd.component $(MISC)/sdd.component
-
-$(MISC)/sd.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- sd.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt sd.component
-
-$(MISC)/sdd.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- sdd.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL2TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt sdd.component
diff --git a/sd/util/sdfilt.component b/sd/util/sdfilt.component
new file mode 100644
index 000000000..397d31cf6
--- /dev/null
+++ b/sd/util/sdfilt.component
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<component loader="com.sun.star.loader.SharedLibrary"
+ xmlns="http://openoffice.org/2010/uno-components">
+ <implementation name="com.sun.star.comp.Impress.oox.PowerPointExport">
+ <service name="com.sun.star.comp.ooxpptx"/>
+ </implementation>
+</component>
diff --git a/sd/util/sdfilt.map b/sd/util/sdfilt.map
index e38cc1e8c..223201489 100644
--- a/sd/util/sdfilt.map
+++ b/sd/util/sdfilt.map
@@ -3,6 +3,8 @@ UDK_3_0_0 {
ExportPPT;
ImportPPT;
SaveVBA;
+ component_getImplementationEnvironment;
+ component_getFactory;
local:
*;
};
diff --git a/sd/workben/custompanel/ctp_panel.cxx b/sd/workben/custompanel/ctp_panel.cxx
index 3719816a9..378432748 100644
--- a/sd/workben/custompanel/ctp_panel.cxx
+++ b/sd/workben/custompanel/ctp_panel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -247,3 +248,5 @@ namespace sd { namespace colortoolpanel
//......................................................................................................................
} } // namespace sd::colortoolpanel
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/workben/custompanel/ctp_panel.hxx b/sd/workben/custompanel/ctp_panel.hxx
index 2aea52c0f..efff2be78 100644
--- a/sd/workben/custompanel/ctp_panel.hxx
+++ b/sd/workben/custompanel/ctp_panel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -97,3 +98,5 @@ namespace sd { namespace colortoolpanel
//......................................................................................................................
#endif // SD_WORKBENCH_CTP_PANEL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/workben/testdll/makefile b/sd/workben/testdll/makefile
index 51f7a1a29..0ba371ff3 100644
--- a/sd/workben/testdll/makefile
+++ b/sd/workben/testdll/makefile
@@ -71,31 +71,3 @@ $(MISC)\$(SHL1TARGET).def: makefile
@echo EXPORTS >>$@
@echo _CreateWindow @2 >>$@
!ENDIF
-
-!IF "$(GUI)" == "OS2"
-
-$(MISC)\$(SHL1TARGET).def: makefile
- @echo ================================================================
- @echo building $@
- @echo ----------------------------------------------------------------
-!IF "$(COM)"!="WTC"
- echo LIBRARY INITINSTANCE TERMINSTANCE >$@
- echo DESCRIPTION 'StarOne Test-DLL' >>$@
- echo PROTMODE >>$@
- @echo CODE LOADONCALL >>$@
- @echo DATA PRELOAD MULTIPLE NONSHARED >>$@
- @echo EXPORTS >>$@
-!IF "$(COM)"!="ICC"
- @echo _CreateWindow @2 >>$@
-!ELSE
- @echo CreateWindow @2 >>$@
-!ENDIF
-
-!ELSE
- @echo option DESCRIPTION 'StarOne Test-DLL' >$@
- @echo name $(BIN)\$(SHL1TARGET).dll >>$@
- @echo CreateWindow_ @2 >>$@
- @gawk -f s:\util\exp.awk temp.def >>$@
- del temp.def
-!ENDIF
-!ENDIF
diff --git a/sd/xml/transitions-ogl.xml b/sd/xml/transitions-ogl.xml
index 8db943406..ca1e3661c 100644
--- a/sd/xml/transitions-ogl.xml
+++ b/sd/xml/transitions-ogl.xml
@@ -30,4 +30,19 @@
<anim:par pres:preset-id="rochade">
<anim:transitionFilter smil:type="miscShapeWipe" smil:subtype="bottomRight"/>
</anim:par>
+ <anim:par pres:preset-id="venetian3dv">
+ <anim:transitionFilter smil:type="miscShapeWipe" smil:subtype="bottomLeft"/>
+ </anim:par>
+ <anim:par pres:preset-id="venetian3dh">
+ <anim:transitionFilter smil:type="miscShapeWipe" smil:subtype="topCenter"/>
+ </anim:par>
+ <anim:par pres:preset-id="static">
+ <anim:transitionFilter smil:type="miscShapeWipe" smil:subtype="rightCenter"/>
+ </anim:par>
+ <anim:par pres:preset-id="finedissolve">
+ <anim:transitionFilter smil:type="miscShapeWipe" smil:subtype="bottomCenter"/>
+ </anim:par>
+ <anim:par pres:preset-id="zoom-rotate-in">
+ <anim:transitionFilter smil:type="zoom" smil:subtype="rotateIn"/>
+ </anim:par>
</anim:seq>
diff --git a/sd/xml/transitions.xml b/sd/xml/transitions.xml
index a9a32ebf5..92bdb5259 100644
--- a/sd/xml/transitions.xml
+++ b/sd/xml/transitions.xml
@@ -111,6 +111,9 @@
<anim:par pres:preset-id="fade-through-black">
<anim:transitionFilter smil:type="fade" smil:subtype="fadeOverColor" smil:fadeColor="#000000"/>
</anim:par>
+ <anim:par pres:preset-id="cut-through-black">
+ <anim:transitionFilter smil:type="barWipe" smil:subtype="fadeOverColor" smil:fadeColor="#000000"/>
+ </anim:par>
<anim:par pres:preset-id="cover-down">
<anim:transitionFilter smil:type="slideWipe" smil:subtype="fromTop"/>
</anim:par>
diff --git a/slideshow/CppunitTest_slideshow.mk b/slideshow/CppunitTest_slideshow.mk
new file mode 100644
index 000000000..3105f9091
--- /dev/null
+++ b/slideshow/CppunitTest_slideshow.mk
@@ -0,0 +1,77 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_CppunitTest_CppunitTest,slideshow))
+
+$(eval $(call gb_CppunitTest_add_package_headers,slideshow,sd_qa_unit))
+
+$(eval $(call gb_CppunitTest_set_include,slideshow,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/slideshow/inc/pch) \
+ -I$(realpath $(SRCDIR)/slideshow/source/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_CppunitTest_set_defs,slideshow,\
+ $$(DEFS) \
+ $(if $(filter TRUE,$(VERBOSE)),-DVERBOSE) \
+))
+
+ifneq ($(strip $(debug)$(DEBUG)),)
+$(eval $(call gb_CppunitTest_set_defs,slideshow,\
+ $$(DEFS) \
+ -DBOOST_SP_ENABLE_DEBUG_HOOKS \
+))
+endif
+
+$(eval $(call gb_CppunitTest_add_library_objects,slideshow,slideshow))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,slideshow,\
+ avmedia \
+ basegfx \
+ canvastools \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ sal \
+ svt \
+ tl \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,slideshow,\
+ slideshow/test/slidetest \
+ slideshow/test/testshape \
+ slideshow/test/testview \
+ slideshow/test/views \
+))
+
+# vim: set noet sw=4:
diff --git a/slideshow/Executable_demoshow.mk b/slideshow/Executable_demoshow.mk
new file mode 100644
index 000000000..6c54ff5ba
--- /dev/null
+++ b/slideshow/Executable_demoshow.mk
@@ -0,0 +1,71 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Executable_Executable,demoshow))
+
+$(eval $(call gb_Executable_add_package_headers,demoshow,sd_qa_unit))
+
+$(eval $(call gb_Executable_set_include,demoshow,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/slideshow/inc/pch) \
+ -I$(realpath $(SRCDIR)/slideshow/source/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+ifeq ($(strip $(VERBOSE)),TRUE)
+$(eval $(call gb_Executable_set_defs,demoshow,\
+ $$(DEFS) \
+ -DVERBOSE \
+))
+endif
+
+ifneq ($(strip $(debug)$(DEBUG)),)
+$(eval $(call gb_Executable_set_defs,demoshow,\
+ $$(DEFS) \
+ -DBOOST_SP_ENABLE_DEBUG_HOOKS \
+))
+endif
+
+$(eval $(call gb_Executable_add_linked_libs,demoshow,\
+ basegfx \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ sal \
+ tl \
+ ucbhelper \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Executable_add_exception_objects,demoshow,\
+ slideshow/test/demoshow \
+))
+
+# vim: set noet sw=4:
diff --git a/slideshow/Library_OGLTrans.mk b/slideshow/Library_OGLTrans.mk
new file mode 100644
index 000000000..3a04c1e4f
--- /dev/null
+++ b/slideshow/Library_OGLTrans.mk
@@ -0,0 +1,111 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,OGLTrans))
+
+$(eval $(call gb_Library_add_precompiled_header,OGLTrans,$(SRCDIR)/sd/inc/pch/precompiled_sd))
+
+$(eval $(call gb_Library_set_include,OGLTrans,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/slideshow/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+ifeq ($(strip $(VERBOSE)),TRUE)
+$(eval $(call gb_Library_set_defs,OGLTrans,\
+ $$(DEFS) \
+ -DVERBOSE \
+))
+endif
+
+ifneq ($(strip $(debug)$(DEBUG)),)
+$(eval $(call gb_Library_set_defs,OGLTrans,\
+ $$(DEFS) \
+ -DBOOST_SP_ENABLE_DEBUG_HOOKS \
+))
+endif
+
+$(eval $(call gb_Library_add_linked_libs,OGLTrans,\
+ canvastools \
+ comphelper \
+ cppu \
+ cppuhelper \
+ sal \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_set_componentfile,OGLTrans,slideshow/source/engine/OGLTrans/ogltrans))
+
+ifeq ($(strip $(OS)),MACOSX)
+$(eval $(call gb_Library_add_objcobjects,OGLTrans,\
+ slideshow/source/engine/OGLTrans/mac/aquaOpenGLView \
+ slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders \
+ ,\
+))
+
+$(eval $(call gb_Library_add_objcxxobjects,OGLTrans,\
+ slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionerImpl \
+ slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl \
+ , $(gb_LinkTarget_EXCEPTIONFLAGS) \
+))
+
+$(eval $(call gb_Library_add_linked_libs,OGLTrans,\
+ Cocoa \
+ GLUT \
+ OpenGL \
+))
+
+else ifeq ($(strip $(OS)),WNT)
+$(eval $(call gb_Library_add_linked_libs,OGLTrans,\
+ gdi32 \
+ glu32 \
+ opengl32 \
+))
+
+$(eval $(call gb_Library_add_exception_objects,OGLTrans,\
+ slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders \
+ slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionerImpl \
+ slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl \
+))
+
+else
+$(eval $(call gb_Library_add_exception_objects,OGLTrans,\
+ slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders \
+ slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl \
+ slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl \
+))
+
+$(eval $(call gb_Library_add_linked_libs,OGLTrans,\
+ GL \
+ GLU \
+ X11 \
+))
+endif
+
+# vim: set noet ts=4 sw=4:
diff --git a/slideshow/Library_slideshow.mk b/slideshow/Library_slideshow.mk
new file mode 100644
index 000000000..3823474b2
--- /dev/null
+++ b/slideshow/Library_slideshow.mk
@@ -0,0 +1,185 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,slideshow))
+
+$(eval $(call gb_Library_add_precompiled_header,slideshow,$(SRCDIR)/slideshow/inc/pch/precompiled_slideshow))
+
+$(eval $(call gb_Library_set_include,slideshow,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/slideshow/inc/pch) \
+ -I$(realpath $(SRCDIR)/slideshow/source/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_set_defs,slideshow,\
+ $$(DEFS) \
+ -DBOOST_SPIRIT_USE_OLD_NAMESPACE \
+ $(if $(filter TRUE,$(VERBOSE)),-DVERBOSE) \
+))
+
+ifneq ($(strip $(debug)$(DEBUG)),)
+$(eval $(call gb_Library_set_defs,slideshow,\
+ $$(DEFS) \
+ -DBOOST_SP_ENABLE_DEBUG_HOOKS \
+))
+endif
+
+$(eval $(call gb_Library_add_linked_libs,slideshow,\
+ avmedia \
+ basegfx \
+ canvastools \
+ comphelper \
+ cppcanvas \
+ cppu \
+ cppuhelper \
+ sal \
+ svt \
+ tl \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_set_componentfile,slideshow,slideshow/util/slideshow))
+
+$(eval $(call gb_Library_add_exception_objects,slideshow,\
+ slideshow/source/engine/activities/activitiesfactory \
+ slideshow/source/engine/activities/activitybase \
+ slideshow/source/engine/activities/continuousactivitybase \
+ slideshow/source/engine/activities/continuouskeytimeactivitybase \
+ slideshow/source/engine/activities/discreteactivitybase \
+ slideshow/source/engine/activitiesqueue \
+ slideshow/source/engine/activities/simplecontinuousactivitybase \
+ slideshow/source/engine/animatedsprite \
+ slideshow/source/engine/animationfactory \
+ slideshow/source/engine/animationnodes/animationaudionode \
+ slideshow/source/engine/animationnodes/animationbasenode \
+ slideshow/source/engine/animationnodes/animationcolornode \
+ slideshow/source/engine/animationnodes/animationcommandnode \
+ slideshow/source/engine/animationnodes/animationnodefactory \
+ slideshow/source/engine/animationnodes/animationpathmotionnode \
+ slideshow/source/engine/animationnodes/animationsetnode \
+ slideshow/source/engine/animationnodes/animationtransformnode \
+ slideshow/source/engine/animationnodes/animationtransitionfilternode \
+ slideshow/source/engine/animationnodes/basecontainernode \
+ slideshow/source/engine/animationnodes/basenode \
+ slideshow/source/engine/animationnodes/generateevent \
+ slideshow/source/engine/animationnodes/nodetools \
+ slideshow/source/engine/animationnodes/paralleltimecontainer \
+ slideshow/source/engine/animationnodes/propertyanimationnode \
+ slideshow/source/engine/animationnodes/sequentialtimecontainer \
+ slideshow/source/engine/attributemap \
+ slideshow/source/engine/color \
+ slideshow/source/engine/debug \
+ slideshow/source/engine/delayevent \
+ slideshow/source/engine/effectrewinder \
+ slideshow/source/engine/eventmultiplexer \
+ slideshow/source/engine/eventqueue \
+ slideshow/source/engine/expressionnodefactory \
+ slideshow/source/engine/rehearsetimingsactivity \
+ slideshow/source/engine/screenupdater \
+ slideshow/source/engine/shapeattributelayer \
+ slideshow/source/engine/shapes/appletshape \
+ slideshow/source/engine/shapes/backgroundshape \
+ slideshow/source/engine/shapes/drawinglayeranimation \
+ slideshow/source/engine/shapes/drawshape \
+ slideshow/source/engine/shapes/drawshapesubsetting \
+ slideshow/source/engine/shapes/externalshapebase \
+ slideshow/source/engine/shapes/gdimtftools \
+ slideshow/source/engine/shapes/intrinsicanimationactivity \
+ slideshow/source/engine/shapes/mediashape \
+ slideshow/source/engine/shapes/shapeimporter \
+ slideshow/source/engine/shapesubset \
+ slideshow/source/engine/shapes/viewappletshape \
+ slideshow/source/engine/shapes/viewbackgroundshape \
+ slideshow/source/engine/shapes/viewmediashape \
+ slideshow/source/engine/shapes/viewshape \
+ slideshow/source/engine/slidebitmap \
+ slideshow/source/engine/slide/layer \
+ slideshow/source/engine/slide/layermanager \
+ slideshow/source/engine/slide/shapemanagerimpl \
+ slideshow/source/engine/slideshowcontext \
+ slideshow/source/engine/slideshowimpl \
+ slideshow/source/engine/slide/slideanimations \
+ slideshow/source/engine/slide/slideimpl \
+ slideshow/source/engine/slide/userpaintoverlay \
+ slideshow/source/engine/slideview \
+ slideshow/source/engine/soundplayer \
+ slideshow/source/engine/tools \
+ slideshow/source/engine/transitions/barndoorwipe \
+ slideshow/source/engine/transitions/barwipepolypolygon \
+ slideshow/source/engine/transitions/boxwipe \
+ slideshow/source/engine/transitions/checkerboardwipe \
+ slideshow/source/engine/transitions/clippingfunctor \
+ slideshow/source/engine/transitions/clockwipe \
+ slideshow/source/engine/transitions/combtransition \
+ slideshow/source/engine/transitions/doublediamondwipe \
+ slideshow/source/engine/transitions/ellipsewipe \
+ slideshow/source/engine/transitions/fanwipe \
+ slideshow/source/engine/transitions/figurewipe \
+ slideshow/source/engine/transitions/fourboxwipe \
+ slideshow/source/engine/transitions/iriswipe \
+ slideshow/source/engine/transitions/parametricpolypolygonfactory \
+ slideshow/source/engine/transitions/pinwheelwipe \
+ slideshow/source/engine/transitions/randomwipe \
+ slideshow/source/engine/transitions/shapetransitionfactory \
+ slideshow/source/engine/transitions/slidechangebase \
+ slideshow/source/engine/transitions/slidetransitionfactory \
+ slideshow/source/engine/transitions/snakewipe \
+ slideshow/source/engine/transitions/spiralwipe \
+ slideshow/source/engine/transitions/sweepwipe \
+ slideshow/source/engine/transitions/transitionfactorytab \
+ slideshow/source/engine/transitions/transitiontools \
+ slideshow/source/engine/transitions/veewipe \
+ slideshow/source/engine/transitions/waterfallwipe \
+ slideshow/source/engine/transitions/zigzagwipe \
+ slideshow/source/engine/unoviewcontainer \
+ slideshow/source/engine/usereventqueue \
+ slideshow/source/engine/waitsymbol \
+ slideshow/source/engine/wakeupevent \
+))
+
+ifeq ($(strip $(OS)),MACOSX)
+$(eval $(call gb_Library_add_cxxobjects,slideshow,\
+ slideshow/source/engine/smilfunctionparser \
+ , $(gb_COMPILERNOOPTFLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) \
+))
+else
+$(eval $(call gb_Library_add_exception_objects,slideshow,\
+ slideshow/source/engine/smilfunctionparser \
+))
+endif
+
+ifneq ($(strip $(debug)$(DEBUG)),)
+$(eval $(call gb_Library_add_exception_objects,slideshow,\
+ slideshow/source/engine/sp_debug \
+))
+endif
+
+# vim: set noet ts=4 sw=4:
diff --git a/slideshow/inc/makefile.mk b/slideshow/Makefile
index ac68ba080..c898975e5 100644
--- a/slideshow/inc/makefile.mk
+++ b/slideshow/Makefile
@@ -1,7 +1,7 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -24,24 +24,15 @@
# for a copy of the LGPLv3 License.
#
#*************************************************************************
-PRJ=..
-
-PRJNAME=slideshow
-TARGET=inc
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-# --- Files --------------------------------------------------------
-# --- Targets -------------------------------------------------------
+ifeq ($(strip $(SOLARENV)),)
+$(error No environment set!)
+endif
-.INCLUDE : target.mk
+gb_PARTIALBUILD := T
+GBUILDDIR := $(SOLARENV)/gbuild
+include $(GBUILDDIR)/gbuild.mk
-.IF "$(ENABLE_PCH)"!=""
-ALLTAR : \
- $(SLO)$/precompiled.pch \
- $(SLO)$/precompiled_ex.pch
-
-.ENDIF # "$(ENABLE_PCH)"!=""
+$(eval $(call gb_Module_make_global_targets,$(shell ls $(dir $(realpath $(firstword $(MAKEFILE_LIST))))/Module*.mk)))
+# vim: set noet sw=4 ts=4:
diff --git a/slideshow/Module_slideshow.mk b/slideshow/Module_slideshow.mk
new file mode 100644
index 000000000..0c39701a1
--- /dev/null
+++ b/slideshow/Module_slideshow.mk
@@ -0,0 +1,41 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Module_Module,slideshow))
+
+$(eval $(call gb_Module_add_targets,slideshow,\
+ $(if $(filter TRUE,$(ENABLE_OPENGL)),Library_OGLTrans) \
+ Library_slideshow \
+))
+
+# not working
+ # CppunitTest_slideshow \
+
+# not built normally (and unbuildable anyway ;)
+ # Executable_demoshow \
+
+# vim: set noet ts=4 sw=4:
diff --git a/slideshow/inc/pch/precompiled_slideshow.cxx b/slideshow/inc/pch/precompiled_slideshow.cxx
index e5eec9707..31553196f 100644
--- a/slideshow/inc/pch/precompiled_slideshow.cxx
+++ b/slideshow/inc/pch/precompiled_slideshow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,3 +28,4 @@
#include "precompiled_slideshow.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/inc/pch/precompiled_slideshow.hxx b/slideshow/inc/pch/precompiled_slideshow.hxx
index 0d67d70ac..b3f964d57 100644
--- a/slideshow/inc/pch/precompiled_slideshow.hxx
+++ b/slideshow/inc/pch/precompiled_slideshow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,4 @@
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/prj/build.lst b/slideshow/prj/build.lst
index 60989f862..30c3d3af0 100644
--- a/slideshow/prj/build.lst
+++ b/slideshow/prj/build.lst
@@ -1,11 +1,3 @@
-pe slideshow : tools sal cppu vcl comphelper cppuhelper offuh cppcanvas basegfx svtools unotools toolkit animations avmedia LIBXSLT:libxslt NULL
+pe slideshow : tools sal cppu vcl comphelper cppuhelper offuh cppcanvas basegfx svtools unotools toolkit animations avmedia MESA:Mesa LIBXSLT:libxslt NULL
pe slideshow usr1 - all pe_mkout NULL
-pe slideshow\inc nmake - all pe_inc NULL
-pe slideshow\source\engine nmake - all pe_engine pe_inc NULL
-pe slideshow\source\engine\slide nmake - all pe_slide pe_inc NULL
-pe slideshow\source\engine\shapes nmake - all pe_shapes pe_inc NULL
-pe slideshow\source\engine\OGLTrans nmake - u pe_ogltrans pe_inc NULL
-pe slideshow\source\engine\transitions nmake - all pe_transitions pe_inc NULL
-pe slideshow\source\engine\animationnodes nmake - all pe_animationnodes pe_inc NULL
-pe slideshow\source\engine\activities nmake - all pe_activities pe_inc NULL
-pe slideshow\util nmake - all pe_util pe_shapes pe_slide pe_activities pe_animationnodes pe_transitions pe_engine NULL
+pe slideshow\prj nmake - all pe_prj NULL
diff --git a/slideshow/prj/d.lst b/slideshow/prj/d.lst
index f6707c249..e69de29bb 100644
--- a/slideshow/prj/d.lst
+++ b/slideshow/prj/d.lst
@@ -1,8 +0,0 @@
-..\%__SRC%\bin\OGLTrans.uno.dll %_DEST%\bin%_EXT%\OGLTrans.uno.dll
-..\%__SRC%\bin\slidesho*.dll %_DEST%\bin%_EXT%\slidesho*.dll
-..\%__SRC%\bin\*.rdb %_DEST%\bin%_EXT%\*.rdb
-..\%__SRC%\lib\slideshow.uno.so %_DEST%\lib%_EXT%\slideshow.uno.so
-..\%__SRC%\lib\OGLTrans.uno.so %_DEST%\lib%_EXT%\OGLTrans.uno.so
-..\%__SRC%\lib\*.dylib %_DEST%\lib%_EXT%\*.dylib
-..\%__SRC%\misc\ogltrans.component %_DEST%\xml%_EXT%\ogltrans.component
-..\%__SRC%\misc\slideshow.component %_DEST%\xml%_EXT%\slideshow.component
diff --git a/sd/source/filter/grf/makefile.mk b/slideshow/prj/makefile.mk
index 7b6ad7121..e312a7cca 100644..100755
--- a/sd/source/filter/grf/makefile.mk
+++ b/slideshow/prj/makefile.mk
@@ -25,20 +25,16 @@
#
#*************************************************************************
-PRJ=..$/..$/..
-PRJNAME=sd
-TARGET=grf
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
+PRJ=..
+TARGET=prj
.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES = $(SLO)$/sdgrffilter.obj
-# --- Targets --------------------------------------------------------------
+.IF "$(VERBOSE)"!=""
+VERBOSEFLAG :=
+.ELSE
+VERBOSEFLAG := -s
+.ENDIF
-.INCLUDE : target.mk
+all:
+ cd $(PRJ) && $(GNUMAKE) $(VERBOSEFLAG) -r -j$(MAXPROCESS) $(gb_MAKETARGET) && $(GNUMAKE) $(VERBOSEFLAG) -r deliverlog
diff --git a/slideshow/qa/debug/nodetree.sh b/slideshow/qa/debug/nodetree.sh
index a4ef1c107..82db0ba0d 100644
--- a/slideshow/qa/debug/nodetree.sh
+++ b/slideshow/qa/debug/nodetree.sh
@@ -1,9 +1,5 @@
#!/bin/bash
#
-# $Revision: 1.3 $
-#
-# Last changes: $Author: kz $ $Date: 2005-01-21 16:54:21 $
-#
# Generate node tree from verbose logfile
#
# HOWTO USE
diff --git a/slideshow/qa/debug/timings.pl b/slideshow/qa/debug/timings.pl
index a409b8d5f..0a1dd05c6 100644
--- a/slideshow/qa/debug/timings.pl
+++ b/slideshow/qa/debug/timings.pl
@@ -5,8 +5,7 @@ eval 'exec perl -wS $0 ${1+"$@"}'
=head1 PROGRAM NAME AND AUTHOR
-Timings - $Revision: 1.2 $
-Last changes: $Author: rt $ $Date: 2004-11-26 18:43:32 $
+Timings
=head1 WHAT IT IS
diff --git a/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.h b/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.h
new file mode 100644
index 000000000..358630beb
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.h
@@ -0,0 +1,94 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef INCLUDED_OGLTRANS_SHADERS_HXX_
+#define INCLUDED_OGLTRANS_SHADERS_HXX_
+
+/* FIXME : Really needed ? */
+#define GL_GLEXT_PROTOTYPES 1
+
+/* Required Includes */
+#import <Cocoa/Cocoa.h>
+#import <OpenGL/gl.h>
+#import <OpenGL/glext.h>
+#import <OpenGL/glu.h>
+#import <OpenGL/OpenGL.h>
+#import <GLUT/glut.h>
+
+/* Parameter */
+typedef struct _Parameter {
+ float current [4];
+ float min [4];
+ float max [4];
+ float delta [4];
+
+} Parameter;
+
+/* Macros */
+#define PARAMETER_CURRENT(p) (p.current)
+#define PARAMETER_ANIMATE(p) ({ int i; for (i = 0; i < 4; i ++) { \
+ p.current[i] += p.delta[i]; \
+ if ((p.current[i] < p.min[i]) || (p.current[i] > p.max[i])) \
+ p.delta[i] = -p.delta[i]; } } )
+
+/* OGLShaders base class */
+@interface OGLShaders : NSObject
+{
+ BOOL initialised;
+ GLhandleARB vertex_shader;
+ GLhandleARB fragment_shader;
+ GLhandleARB program_object;
+ GLUquadric *quadric;
+ BOOL gpuProcessingInit;
+ BOOL gpuProcessing;
+}
+- (id) init;
+- (void) initLazy;
+- (void) dealloc;
+- (NSString *) name;
+- (NSString *) descriptionFilename;
+- (unsigned int) loadVertexShader: (NSString *) vertexString fragmentShader: (NSString *) fragmentString;
+
+ /* if!initialized -> initLazy */
+- (void) renderFrame;
+
+/* Check whether software rasterization or software vertex processing will be used */
+- (BOOL) reflect;
+
+@end
+
+
+// Utility Functions
+
+int NextHighestPowerOf2(int n);
+void CopyFramebufferToTexture(GLuint texture);
+NSBitmapImageRep *LoadImage(NSString *path, int shouldFlipVertical);
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.m b/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.m
new file mode 100644
index 000000000..360e8cf5e
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/OGLTrans_Shaders.m
@@ -0,0 +1,231 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#import "OGLTrans_Shaders.h"
+
+
+@implementation OGLShaders
+
+- (id) init
+{
+ [super init];
+ gpuProcessingInit = NO;
+ return self;
+}
+
+- (void) initLazy
+{
+ /* Subclass should put initialisation code that can be performaned
+ lazily (on first frame render) here */
+ initialised = TRUE;
+
+ /* Create a GLU quadric, used for rendering certain geometry */
+ quadric = gluNewQuadric();
+ gluQuadricDrawStyle(quadric, GLU_FILL);
+ gluQuadricNormals(quadric, GL_SMOOTH);
+ gluQuadricTexture(quadric, GL_TRUE);
+
+}
+
+- (void) dealloc
+{
+ /* Free the GLU quadric */
+ if (quadric)
+ gluDeleteQuadric(quadric);
+
+ [super dealloc];
+}
+
+- (NSString *) name
+{
+ return @"Unnamed OGLShaders";
+}
+
+- (NSString *) descriptionFilename
+{
+ return NULL;
+}
+
+- (unsigned int) loadVertexShader: (NSString *) vertexString fragmentShader: (NSString *) fragmentString
+{
+ const GLcharARB *vertex_string;
+ const GLcharARB *fragment_string;
+ GLint vertex_compiled;
+ GLint fragment_compiled;
+ GLint linked;
+
+ /* Delete any existing program object */
+ if (program_object) {
+ glDeleteObjectARB(program_object);
+ program_object = NULL;
+ }
+
+ /* Load and compile both shaders */
+ if (vertexString) {
+ vertex_shader = glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB);
+ vertex_string = (GLcharARB *) [vertexString cString];
+ glShaderSourceARB(vertex_shader, 1, &vertex_string, NULL);
+ glCompileShaderARB(vertex_shader);
+ glGetObjectParameterivARB(vertex_shader, GL_OBJECT_COMPILE_STATUS_ARB, &vertex_compiled);
+ /* TODO - Get info log */
+ } else {
+ vertex_shader = NULL;
+ vertex_compiled = 1;
+ }
+
+ if (fragmentString) {
+ fragment_shader = glCreateShaderObjectARB(GL_FRAGMENT_SHADER_ARB);
+ fragment_string = [fragmentString cString];
+ glShaderSourceARB(fragment_shader, 1, &fragment_string, NULL);
+ glCompileShaderARB(fragment_shader);
+ glGetObjectParameterivARB(fragment_shader, GL_OBJECT_COMPILE_STATUS_ARB, &fragment_compiled);
+ /* TODO - Get info log */
+ } else {
+ fragment_shader = NULL;
+ fragment_compiled = 1;
+ }
+
+ /* Ensure both shaders compiled */
+ if (!vertex_compiled || !fragment_compiled) {
+ if (vertex_shader) {
+ glDeleteObjectARB(vertex_shader);
+ vertex_shader = NULL;
+ }
+ if (fragment_shader) {
+ glDeleteObjectARB(fragment_shader);
+ fragment_shader = NULL;
+ }
+ return 1;
+ }
+
+ /* Create a program object and link both shaders */
+ program_object = glCreateProgramObjectARB();
+ if (vertex_shader != NULL)
+ {
+ glAttachObjectARB(program_object, vertex_shader);
+ glDeleteObjectARB(vertex_shader); /* Release */
+ }
+ if (fragment_shader != NULL)
+ {
+ glAttachObjectARB(program_object, fragment_shader);
+ glDeleteObjectARB(fragment_shader); /* Release */
+ }
+ glLinkProgramARB(program_object);
+ glGetObjectParameterivARB(program_object, GL_OBJECT_LINK_STATUS_ARB, &linked);
+ /* TODO - Get info log */
+
+ if (!linked) {
+ glDeleteObjectARB(program_object);
+ program_object = NULL;
+ return 1;
+ }
+
+ return 0;
+}
+
+- (void) renderFrame
+{
+ if (!initialised)
+ [self initLazy];
+}
+
+- (BOOL) reflect
+{
+ if(!gpuProcessingInit)
+ {
+ /* Check if this will fall back to software rasterization or
+ software vertex processing and don't reflect if it is. */
+
+ GLint fragmentGPUProcessing, vertexGPUProcessing;
+ gpuProcessingInit = YES;
+
+ glPushAttrib(GL_VIEWPORT_BIT);
+ glViewport(0,0,0,0);
+ glPushMatrix();
+ [self renderFrame];
+ glPopMatrix();
+ CGLGetParameter(CGLGetCurrentContext(), kCGLCPGPUFragmentProcessing, &fragmentGPUProcessing);
+ CGLGetParameter(CGLGetCurrentContext(), kCGLCPGPUVertexProcessing, &vertexGPUProcessing);
+ gpuProcessing = (fragmentGPUProcessing && vertexGPUProcessing) ? YES : NO;
+ glPopAttrib();
+ }
+
+ return gpuProcessing;
+}
+
+@end
+
+
+// Utility Functions
+
+int NextHighestPowerOf2(int n)
+{
+ n--;
+ n |= n >> 1;
+ n |= n >> 2;
+ n |= n >> 4;
+ n |= n >> 8;
+ n |= n >> 16;
+ n++;
+ return n;
+}
+
+void CopyFramebufferToTexture(GLuint texture)
+{
+ GLint viewport[4];
+ glGetIntegerv(GL_VIEWPORT, viewport);
+ glBindTexture(GL_TEXTURE_2D, texture);
+ glCopyTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, viewport[0], viewport[1], NextHighestPowerOf2(viewport[2]), NextHighestPowerOf2(viewport[3]), 0);
+}
+
+NSBitmapImageRep *LoadImage(NSString *path, int shouldFlipVertical)
+{
+ NSBitmapImageRep *bitmapimagerep;
+ NSImage *image;
+ image = [[[NSImage alloc] initWithContentsOfFile: path] autorelease];
+ bitmapimagerep = [[NSBitmapImageRep alloc] initWithData:[image TIFFRepresentation]];
+
+ if (shouldFlipVertical)
+ {
+ int bytesPerRow, lowRow, highRow;
+ unsigned char *pixelData, *swapRow;
+
+ bytesPerRow = [bitmapimagerep bytesPerRow];
+ pixelData = [bitmapimagerep bitmapData];
+
+ swapRow = (unsigned char *)malloc(bytesPerRow);
+ for (lowRow = 0, highRow = [bitmapimagerep pixelsHigh]-1; lowRow < highRow; lowRow++, highRow--)
+ {
+ memcpy(swapRow, &pixelData[lowRow*bytesPerRow], bytesPerRow);
+ memcpy(&pixelData[lowRow*bytesPerRow], &pixelData[highRow*bytesPerRow], bytesPerRow);
+ memcpy(&pixelData[highRow*bytesPerRow], swapRow, bytesPerRow);
+ }
+ free(swapRow);
+ }
+
+ return bitmapimagerep;
+}
diff --git a/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.hxx b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.hxx
new file mode 100644
index 000000000..eeb6a6576
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.hxx
@@ -0,0 +1,497 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+#ifndef INCLUDED_OGLTRANS_TRANSITIONIMPL_HXX_
+#define INCLUDED_OGLTRANS_TRANSITIONIMPL_HXX_
+
+#include <basegfx/vector/b2dvector.hxx>
+#include <basegfx/vector/b3dvector.hxx>
+
+#include <OpenGL/gl.h>
+#include <vector>
+
+using namespace std;
+
+class Primitive;
+class Operation;
+class SceneObject;
+
+
+/** OpenGL 3D Transition class. It implicitly is constructed from XOGLTransition
+
+ This class is capable of making itself into many difference transitions. It holds Primitives and Operations on those primitives.
+*/
+class OGLTransitionImpl
+{
+public:
+ OGLTransitionImpl() :
+ mbUseMipMapLeaving( true ),
+ mbUseMipMapEntering( true ),
+ mnRequiredGLVersion( 1.0 ),
+ maLeavingSlidePrimitives(),
+ maEnteringSlidePrimitives(),
+ maSceneObjects(),
+ mbReflectSlides( false ),
+ mVertexObject( 0 ),
+ mFragmentObject( 0 ),
+ mProgramObject( 0 ),
+ maHelperTexture( 0 ),
+ mmPrepare( NULL ),
+ mmPrepareTransition( NULL ),
+ mmClearTransition( NULL ),
+ mmDisplaySlides( NULL )
+ {}
+
+ ~OGLTransitionImpl();
+
+ void prepare( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void display( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight );
+ void finish();
+
+ void makeOutsideCubeFaceToLeft();
+ void makeInsideCubeFaceToLeft();
+ void makeNByMTileFlip( ::sal_uInt16 n, ::sal_uInt16 m );
+ void makeRevolvingCircles( ::sal_uInt16 nCircles , ::sal_uInt16 nPointsOnCircles );
+ void makeHelix( ::sal_uInt16 nRows );
+ void makeFallLeaving();
+ void makeTurnAround();
+ void makeTurnDown();
+ void makeIris();
+ void makeRochade();
+ void makeVenetianBlinds( bool vertical, int parts );
+ void makeStatic();
+ void makeDissolve();
+ void makeNewsflash();
+
+ /** 2D replacements
+ */
+ void makeDiamond();
+ void makeFadeSmoothly();
+ void makeFadeThroughBlack();
+
+ /** Whether to use mipmaping for slides textures
+ */
+ bool mbUseMipMapLeaving;
+ bool mbUseMipMapEntering;
+
+ /** which GL version does the transition require
+ */
+ float mnRequiredGLVersion;
+
+private:
+ /** clears all the primitives and operations
+ */
+ void clear();
+
+ /** All the primitives that use the leaving slide texture
+ */
+ vector<Primitive> maLeavingSlidePrimitives;
+
+ /** All the primitives that use the leaving slide texture
+ */
+ vector<Primitive> maEnteringSlidePrimitives;
+
+ /** All the surrounding scene objects
+ */
+ vector<SceneObject*> maSceneObjects;
+
+ /** All the operations that should be applied to both leaving and entering slide primitives. These operations will be called in the order they were pushed back in. In OpenGL this effectively uses the operations in the opposite order they were pushed back.
+ */
+ vector<Operation*> OverallOperations;
+
+ /** Whether to reflect slides, the reflection happens on flat surface beneath the slides.
+ ** Now it only works with slides which keep their rectangular shape together.
+ */
+ bool mbReflectSlides;
+
+ /** GLSL objects, shaders and program
+ */
+ GLuint mVertexObject, mFragmentObject, mProgramObject;
+
+ /** various data */
+ GLuint maHelperTexture;
+
+ /** When this method is not NULL, it is called in display method to prepare the slides, scene, etc.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmPrepare)( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight );
+
+ /** When this method is not NULL, it is called after glx context is ready to let the transition prepare GL related things, like GLSL program.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmPrepareTransition)( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+
+ /** When this method is not NULL, it is called when the transition needs to clear after itself, like delete own textures etc.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmClearTransition)();
+
+ /** When this method is not NULL, it is called in display method to display the slides.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmDisplaySlides)( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+
+ void displaySlides( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlide( double nTime, ::sal_Int32 glSlideTex, std::vector<Primitive>& primitives, double SlideWidthScale, double SlideHeightScale );
+ void displayScene( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ void applyOverallOperations( double nTime, double SlideWidthScale, double SlideHeightScale );
+
+ /** various transitions helper methods
+ */
+ void prepareDiamond( double nTime, double SlideWidth, double SlideHeight,double DispWidth, double DispHeight );
+ void displaySlidesFadeSmoothly( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesFadeThroughBlack( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesRochade( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesShaders( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void prepareStatic( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void prepareDissolve( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void preparePermShader();
+};
+
+class SceneObject
+{
+public:
+ SceneObject();
+
+ virtual void prepare() {};
+ virtual void display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ virtual void finish() {};
+
+ void pushPrimitive (const Primitive &p);
+
+protected:
+ /** All the surrounding scene primitives
+ */
+ vector<Primitive> maPrimitives;
+};
+
+class Iris : public SceneObject
+{
+public:
+ Iris ();
+
+ virtual void prepare();
+ virtual void display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ virtual void finish();
+
+private:
+
+ GLuint maTexture;
+};
+
+/** This class is a list of Triangles that will share Operations, and could possibly share
+*/
+class Primitive
+{
+public:
+ Primitive() {}
+ // making copy constructor explicit makes the class un-suitable for use with stl containers
+ Primitive(const Primitive& rvalue);
+ ~Primitive();
+
+ void applyOperations(double nTime, double SlideWidthScale, double SlideHeightScale);
+ void display(double nTime, double SlideWidthScale, double SlideHeightScale);
+ const Primitive& operator=(const Primitive& rvalue);
+
+ /** PushBack a vertex,normal, and tex coord. Each SlideLocation is where on the slide is mapped to this location ( from (0,0) to (1,1) ). This will make sure the correct aspect ratio is used, and helps to make slides begin and end at the correct position. (0,0) is the top left of the slide, and (1,1) is the bottom right.
+
+ @param SlideLocation0
+ Location of first Vertex on slide
+
+ @param SlideLocation1
+ Location of second Vertex on slide
+
+ @param SlideLocation2
+ Location of third Vertex on slide
+
+ */
+ void pushTriangle(const basegfx::B2DVector& SlideLocation0,const basegfx::B2DVector& SlideLocation1,const basegfx::B2DVector& SlideLocation2);
+
+ /** clear all the vertices, normals, tex coordinates, and normals
+ */
+ void clearTriangles();
+
+ /** guards against directly changing the vertices
+
+ @return
+ the list of vertices
+ */
+ const vector<basegfx::B3DVector>& getVertices() const {return Vertices;}
+
+ /** guards against directly changing the vertices
+ */
+ const vector<basegfx::B3DVector>& getNormals() const {return Normals;}
+
+ /** guards against directly changing the vertices
+
+ @return
+ the list of Texture Coordinates
+
+ */
+ const vector<basegfx::B2DVector>& getTexCoords() const {return TexCoords;}
+
+ /** list of Operations to be performed on this primitive.These operations will be called in the order they were pushed back in. In OpenGL this effectively uses the operations in the opposite order they were pushed back.
+
+ @return
+ the list of Operations
+
+ */
+ vector<Operation*> Operations;
+
+private:
+ /** list of vertices
+ */
+ vector<basegfx::B3DVector> Vertices;
+
+ /** list of Normals
+ */
+ vector<basegfx::B3DVector> Normals;
+
+ /** list of Texture Coordinates
+ */
+ vector<basegfx::B2DVector> TexCoords;
+};
+
+/** This class is to be derived to make any operation (tranform) you may need in order to construct your transitions
+*/
+class Operation
+{
+public:
+ Operation(){}
+ virtual ~Operation(){}
+
+ /** Should this operation be interpolated . If TRUE, the transform will smoothly move from making no difference from t = 0.0 to nT0 to being completely transformed from t = nT1 to 1. If FALSE, the transform will be inneffectual from t = 0 to nT0, and completely transformed from t = nT0 to 1.
+ */
+ bool bInterpolate;
+
+ /** time to begin the transformation
+ */
+ double nT0;
+
+ /** time to finish the transformation
+ */
+ double nT1;
+public:
+ /** this is the function that is called to give the Operation to OpenGL.
+
+ @param t
+ time from t = 0 to t = 1
+
+ @param SlideWidthScale
+ width of slide divided by width of window
+
+ @param SlideHeightScale
+ height of slide divided by height of window
+
+ */
+ virtual void interpolate(double t,double SlideWidthScale,double SlideHeightScale) = 0;
+
+ /** return a copy of this operation
+ */
+ virtual Operation* clone() = 0;
+};
+
+/** this class is a generic CounterClockWise(CCW) rotation with an axis angle
+*/
+class SRotate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ virtual SRotate* clone();
+
+ /** Constructor
+
+ @param Axis
+ axis to rotate about
+
+ @param Origin
+ position that rotation axis runs through
+
+ @param Angle
+ angle in radians of CCW rotation
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SRotate(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~SRotate(){}
+private:
+ /** axis to rotate CCW about
+ */
+ basegfx::B3DVector axis;
+
+ /** position that rotation axis runs through
+ */
+ basegfx::B3DVector origin;
+
+ /** angle in radians of CCW rotation
+ */
+ double angle;
+};
+
+/** scaling transformation
+*/
+class SScale: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ SScale* clone();
+
+ /** Constructor
+
+ @param Scale
+ amount to scale by
+
+ @param Origin
+ position that rotation axis runs through
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SScale(const basegfx::B3DVector& Scale, const basegfx::B3DVector& Origin,bool bInter, double T0, double T1);
+ ~SScale(){}
+private:
+ basegfx::B3DVector scale;
+ basegfx::B3DVector origin;
+};
+
+/** translation transformation
+*/
+class STranslate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ STranslate* clone();
+
+ /** Constructor
+
+ @param Vector
+ vector to translate
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ STranslate(const basegfx::B3DVector& Vector,bool bInter, double T0, double T1);
+ ~STranslate(){}
+private:
+ /** vector to translate by
+ */
+ basegfx::B3DVector vector;
+};
+
+/** translation transformation
+*/
+class SEllipseTranslate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ SEllipseTranslate* clone();
+
+ /** Constructor
+
+ @param Vector
+ vector to translate
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SEllipseTranslate(double dWidth, double dHeight, double dStartPosition, double dEndPosition, bool bInter, double T0, double T1);
+ ~SEllipseTranslate(){}
+private:
+ /** width and length of the ellipse
+ */
+ double width, height;
+
+ /** start and end position on the ellipse <0,1>
+ */
+ double startPosition;
+ double endPosition;
+};
+
+/** Same as SRotate, except the depth is scaled by the width of the slide divided by the width of the window.
+*/
+class RotateAndScaleDepthByWidth: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ RotateAndScaleDepthByWidth* clone();
+
+ RotateAndScaleDepthByWidth(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~RotateAndScaleDepthByWidth(){}
+private:
+ basegfx::B3DVector axis;
+ basegfx::B3DVector origin;
+ double angle;
+};
+
+/** Same as SRotate, except the depth is scaled by the width of the slide divided by the height of the window.
+*/
+class RotateAndScaleDepthByHeight: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ RotateAndScaleDepthByHeight* clone();
+
+ RotateAndScaleDepthByHeight(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~RotateAndScaleDepthByHeight(){}
+private:
+ basegfx::B3DVector axis;
+ basegfx::B3DVector origin;
+ double angle;
+};
+
+#endif // INCLUDED_SLIDESHOW_TRANSITION_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.mm b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.mm
new file mode 100644
index 000000000..f006e96c2
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionImpl.mm
@@ -0,0 +1,1326 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include "OGLTrans_TransitionImpl.hxx"
+#include "OGLTrans_Shaders.h"
+#ifdef QUARTZ
+#include <OpenGL/gl.h>
+#else
+#include <GL/gl.h>
+#endif
+#include <math.h>
+
+void OGLTransitionImpl::clear()
+{
+ for(unsigned int i( 0 ); i < OverallOperations.size(); ++i)
+ delete OverallOperations[i];
+ OverallOperations.clear();
+ maLeavingSlidePrimitives.clear();
+ maEnteringSlidePrimitives.clear();
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i)
+ delete maSceneObjects[i];
+ maSceneObjects.clear();
+
+ mbReflectSlides = false;
+
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ glDeleteProgram( mProgramObject );
+ mProgramObject = 0;
+ }
+
+ if( mVertexObject ) {
+ glDeleteShader( mVertexObject );
+ mVertexObject = 0;
+ }
+
+ if( mFragmentObject ) {
+ glDeleteShader( mFragmentObject );
+ mFragmentObject = 0;
+ }
+#endif
+
+ if( maHelperTexture ) {
+ glDeleteTextures( 1, &maHelperTexture );
+ maHelperTexture = 0;
+ }
+
+ if( mmClearTransition )
+ (this->*mmClearTransition)();
+}
+
+OGLTransitionImpl::~OGLTransitionImpl()
+{
+ clear();
+}
+
+void OGLTransitionImpl::prepare( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex )
+{
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i) {
+ maSceneObjects[i]->prepare();
+ }
+
+ if( mmPrepareTransition )
+ (this->*mmPrepareTransition)( glLeavingSlideTex, glEnteringSlideTex );
+}
+
+void OGLTransitionImpl::finish()
+{
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i) {
+ maSceneObjects[i]->finish();
+ }
+}
+
+static void blendSlide( double depth )
+{
+ double showHeight = -1 + depth*2;
+ GLfloat reflectionColor[] = {0, 0, 0, 0.25};
+
+ glDisable( GL_DEPTH_TEST );
+ glBegin( GL_QUADS );
+ glColor4fv( reflectionColor );
+ glVertex3f( -1, -1, 0 );
+ glColor4f( 0, 0, 0, 1 );
+ glVertex3f(-1, showHeight, 0 );
+ glVertex3f( 1, showHeight, 0 );
+ glColor4fv( reflectionColor );
+ glVertex3f( 1, -1, 0 );
+ glEnd();
+
+ glBegin( GL_QUADS );
+ glColor4f( 0, 0, 0, 1 );
+ glVertex3f( -1, showHeight, 0 );
+ glVertex3f( -1, 1, 0 );
+ glVertex3f( 1, 1, 0 );
+ glVertex3f( 1, showHeight, 0 );
+ glEnd();
+ glEnable( GL_DEPTH_TEST );
+}
+
+static void slideShadow( double nTime, Primitive& primitive, double sw, double sh )
+{
+ double reflectionDepth = 0.3;
+
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glDisable(GL_LIGHTING);
+
+ glPushMatrix();
+ primitive.applyOperations( nTime, sw, sh );
+ blendSlide( reflectionDepth );
+ glPopMatrix();
+
+ glDisable(GL_BLEND);
+ glEnable(GL_LIGHTING);
+}
+
+void OGLTransitionImpl::display( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ double SlideWidthScale, SlideHeightScale;
+
+ SlideWidthScale = SlideWidth/DispWidth;
+ SlideHeightScale = SlideHeight/DispHeight;
+
+ if( mmPrepare ) {
+ clear();
+ (this->*mmPrepare)( nTime, SlideWidth, SlideHeight, DispWidth, DispHeight );
+ }
+
+ glPushMatrix();
+ displaySlides( nTime, glLeavingSlideTex, glEnteringSlideTex, SlideWidthScale, SlideHeightScale );
+ displayScene( nTime, SlideWidth, SlideHeight, DispWidth, DispHeight );
+ glPopMatrix();
+}
+
+void OGLTransitionImpl::applyOverallOperations( double nTime, double SlideWidthScale, double SlideHeightScale )
+{
+ for(unsigned int i(0); i < OverallOperations.size(); ++i)
+ OverallOperations[i]->interpolate(nTime,SlideWidthScale,SlideHeightScale);
+}
+
+void OGLTransitionImpl::displaySlide( double nTime, ::sal_Int32 glSlideTex, std::vector<Primitive>& primitives,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ //TODO change to foreach
+ glBindTexture(GL_TEXTURE_2D, glSlideTex);
+
+ // display slide reflection
+ // note that depth test is turned off while blending the shadow
+ // so the slides has to be rendered in right order, see rochade as example
+ if( mbReflectSlides ) {
+ double surfaceLevel = -0.04;
+
+ /* reflected slides */
+ glPushMatrix();
+
+ glScaled( 1, -1, 1 );
+ glTranslated( 0, 2 - surfaceLevel, 0 );
+
+ glCullFace(GL_FRONT);
+ for(unsigned int i(0); i < primitives.size(); ++i)
+ primitives[i].display(nTime, SlideWidthScale, SlideHeightScale);
+ glCullFace(GL_BACK);
+
+ slideShadow( nTime, primitives[0], SlideWidthScale, SlideHeightScale );
+
+ glPopMatrix();
+ }
+
+ for(unsigned int i(0); i < primitives.size(); ++i)
+ primitives[i].display(nTime, SlideWidthScale, SlideHeightScale);
+}
+
+void OGLTransitionImpl::displaySlides( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ if( mmDisplaySlides )
+ (this->*mmDisplaySlides)( nTime, glLeavingSlideTex, glEnteringSlideTex, SlideWidthScale, SlideHeightScale );
+ else {
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glEnable(GL_TEXTURE_2D);
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+}
+
+void OGLTransitionImpl::displayScene( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ glEnable(GL_TEXTURE_2D);
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i)
+ maSceneObjects[i]->display(nTime, SlideWidth, SlideHeight, DispWidth, DispHeight);
+}
+
+void Primitive::display(double nTime, double WidthScale, double HeightScale)
+{
+ glPushMatrix();
+
+ applyOperations( nTime, WidthScale, HeightScale );
+
+ glEnableClientState( GL_VERTEX_ARRAY );
+ if(!Normals.empty())
+ {
+ glNormalPointer( GL_DOUBLE , 0 , &Normals[0] );
+ glEnableClientState( GL_NORMAL_ARRAY );
+ }
+ glEnableClientState( GL_TEXTURE_COORD_ARRAY );
+ glTexCoordPointer( 2, GL_DOUBLE, 0, &TexCoords[0] );
+ glVertexPointer( 3, GL_DOUBLE, 0, &Vertices[0] );
+ glDrawArrays( GL_TRIANGLES, 0, Vertices.size() );
+ glPopMatrix();
+}
+
+void Primitive::applyOperations(double nTime, double WidthScale, double HeightScale)
+{
+ for(unsigned int i(0); i < Operations.size(); ++i)
+ Operations[i]->interpolate( nTime ,WidthScale,HeightScale);
+ glScaled(WidthScale,HeightScale,1);
+}
+
+Primitive::~Primitive()
+{
+ for(unsigned int i( 0 ); i < Operations.size(); ++i)
+ delete Operations[i];
+}
+
+
+void SceneObject::display(double nTime, double /* SlideWidth */, double /* SlideHeight */, double DispWidth, double DispHeight )
+{
+ for(unsigned int i(0); i < maPrimitives.size(); ++i) {
+ // fixme: allow various model spaces, now we make it so that
+ // it is regular -1,-1 to 1,1, where the whole display fits in
+ glPushMatrix();
+ if (DispHeight > DispWidth)
+ glScaled(DispHeight/DispWidth, 1, 1);
+ else
+ glScaled(1, DispWidth/DispHeight, 1);
+ maPrimitives[i].display(nTime, 1, 1);
+ glPopMatrix();
+ }
+}
+
+void SceneObject::pushPrimitive(const Primitive &p)
+{
+ maPrimitives.push_back(p);
+}
+
+SceneObject::SceneObject()
+ : maPrimitives()
+{
+}
+
+Iris::Iris()
+ : SceneObject ()
+{
+}
+
+void Iris::display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ glBindTexture(GL_TEXTURE_2D, maTexture);
+ SceneObject::display(nTime, SlideWidth, SlideHeight, DispWidth, DispHeight);
+}
+
+void Iris::prepare()
+{
+ static GLubyte img[3] = { 80, 80, 80 };
+
+ glGenTextures(1, &maTexture);
+ glBindTexture(GL_TEXTURE_2D, maTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 3, 1, 1, 0, GL_RGB, GL_UNSIGNED_BYTE, img);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_REPEAT);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_REPEAT);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
+}
+
+void Iris::finish()
+{
+ glDeleteTextures(1, &maTexture);
+}
+
+void OGLTransitionImpl::makeOutsideCubeFaceToLeft()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,-1),90,false,0.0,1.0));
+
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,-1),-90,true,0.0,1.0));
+}
+
+void OGLTransitionImpl::makeInsideCubeFaceToLeft()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,1),-90,false,0.0,1.0));
+
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,1),90,true,0.0,1.0));
+}
+
+void OGLTransitionImpl::makeFallLeaving()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(1,0,0),basegfx::B3DVector(0,-1,0), 90,true,0.0,1.0));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::makeTurnAround()
+{
+ clear();
+ Primitive Slide;
+
+ mbReflectSlides = true;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0),-180,false,0.0,1.0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, -1.5),true, 0, 0.5));
+ OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, 1.5), true, 0.5, 1));
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0, 1, 0),basegfx::B3DVector(0, 0, 0), -180, true, 0.0, 1.0));
+}
+
+void OGLTransitionImpl::makeTurnDown()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, 0.0001), false, -1.0, 0.0));
+ Slide.Operations.push_back(new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(-1, 1, 0), -90, true, 0.0, 1.0));
+ Slide.Operations.push_back(new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(-1, 1, 0), 90, false, -1.0, 0.0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ mbUseMipMapLeaving = false;
+}
+
+void OGLTransitionImpl::makeIris()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ Slide.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, 0.000001), false, -1, 0));
+ Slide.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, -0.000002), false, 0.5, 1));
+ maLeavingSlidePrimitives.push_back (Slide);
+
+
+ Primitive irisPart, part;
+ int i, nSteps = 24, nParts = 7;
+ double lt = 0, t = 1.0/nSteps, cx, cy, lcx, lcy, lx = 1, ly = 0, x, y, cxo, cyo, lcxo, lcyo, of=2.2, f=1.42;
+
+ for (i=1; i<=nSteps; i++) {
+ x = cos ((3*2*M_PI*t)/nParts);
+ y = -sin ((3*2*M_PI*t)/nParts);
+ cx = (f*x + 1)/2;
+ cy = (f*y + 1)/2;
+ lcx = (f*lx + 1)/2;
+ lcy = (f*ly + 1)/2;
+ cxo = (of*x + 1)/2;
+ cyo = (of*y + 1)/2;
+ lcxo = (of*lx + 1)/2;
+ lcyo = (of*ly + 1)/2;
+ irisPart.pushTriangle (basegfx::B2DVector (lcx, lcy),
+ basegfx::B2DVector (lcxo, lcyo),
+ basegfx::B2DVector (cx, cy));
+ irisPart.pushTriangle (basegfx::B2DVector (cx, cy),
+ basegfx::B2DVector (lcxo, lcyo),
+ basegfx::B2DVector (cxo, cyo));
+ lx = x;
+ ly = y;
+ lt = t;
+ t += 1.0/nSteps;
+ }
+
+ Iris* pIris = new Iris();
+ double angle = 87;
+
+ for (i = 0; i < nParts; i++) {
+ irisPart.Operations.clear ();
+ double rx, ry;
+
+ rx = cos ((2*M_PI*i)/nParts);
+ ry = sin ((2*M_PI*i)/nParts);
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(rx, ry, 0), angle, true, 0.0, 0.5));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(rx, ry, 0), -angle, true, 0.5, 1));
+ if (i > 0) {
+ irisPart.Operations.push_back (new STranslate (basegfx::B3DVector(rx, ry, 0), false, -1, 0));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(0, 0, 0), i*360.0/nParts, false, -1, 0));
+ irisPart.Operations.push_back (new STranslate (basegfx::B3DVector(-1, 0, 0), false, -1, 0));
+ }
+ irisPart.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, 1), false, -2, 0.0));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(1, .5, 0), basegfx::B3DVector(1, 0, 0), -30, false, -1, 0));
+ pIris->pushPrimitive (irisPart);
+ }
+
+ maSceneObjects.push_back (pIris);
+
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::displaySlidesRochade( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glEnable(GL_TEXTURE_2D);
+
+ if( nTime > .5) {
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ } else {
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+}
+
+void OGLTransitionImpl::makeRochade()
+{
+ clear();
+ Primitive Slide;
+
+ mbReflectSlides = true;
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesRochade;
+
+ double w, h;
+
+ w = 2.2;
+ h = 10;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ Slide.Operations.push_back(new SEllipseTranslate(w, h, 0.25, -0.25, true, 0, 1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), -45, true, 0, 1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.clear();
+ Slide.Operations.push_back(new SEllipseTranslate(w, h, 0.75, 0.25, true, 0, 1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, -h), false, -1, 0));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), -45, true, 0, 1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), 45, false, -1, 0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ // OverallOperations.push_back(new SEllipseTranslate(0.5, 2, 0, 1, true, 0, 1));
+// push_back(new STranslate(basegfx::B3DVector(0, 0, -2), true, 0, 0.5));
+// OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, 2), true, 0.5, 1));
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B2DVector clamp(const basegfx::B2DVector& v)
+{
+ return basegfx::B2DVector(min(max(v.getX(),-1.0),1.0),
+ min(max(v.getY(),-1.0),1.0));
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B3DVector clamp(const basegfx::B3DVector& v)
+{
+ return basegfx::B3DVector(min(max(v.getX(),-1.0),1.0),
+ min(max(v.getY(),-1.0),1.0),
+ min(max(v.getZ(),-1.0),1.0));
+}
+
+inline double randFromNeg1to1()
+{
+ return ( ( static_cast<double>( rand() ) / static_cast<double>( RAND_MAX ) ) * 2.0 ) - 1.0;
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B3DVector randNormVectorInXYPlane()
+{
+ basegfx::B3DVector toReturn(randFromNeg1to1(),randFromNeg1to1(),0.0);
+ return toReturn/toReturn.getLength();
+}
+
+void OGLTransitionImpl::makeRevolvingCircles( ::sal_uInt16 nCircles , ::sal_uInt16 nPointsOnCircles )
+{
+ clear();
+ double dAngle(2*3.1415926/static_cast<double>( nPointsOnCircles ));
+ if(nCircles < 2 || nPointsOnCircles < 4)
+ {
+ makeNByMTileFlip(1,1);
+ return;
+ }
+ double Radius(1.0/static_cast<double>( nCircles ));
+ double dRadius(Radius);
+ double LastRadius(0.0);
+ double NextRadius(2*Radius);
+
+ /// now we know there is at least two circles
+ /// the first will always be a full circle
+ /// the last will always be the outer shell of the slide with a circle hole
+
+ //add the full circle
+ vector<basegfx::B2DVector> unScaledTexCoords;
+ double TempAngle(0.0);
+ for(unsigned int Point(0); Point < nPointsOnCircles; ++Point)
+ {
+ unScaledTexCoords.push_back( basegfx::B2DVector( cos(TempAngle - 3.1415926/2.0) , sin(TempAngle- 3.1415926/2.0) ) );
+
+ TempAngle += dAngle;
+ }
+
+ {
+ //double angle(0.0);
+ Primitive EnteringSlide;
+ Primitive LeavingSlide;
+ for(int Point(0); Point + 1 < nPointsOnCircles; ++Point)
+ {
+ EnteringSlide.pushTriangle( basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point + 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) );
+ LeavingSlide.pushTriangle( basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point + 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point ] / 2.0 + basegfx::B2DVector( 0.5, 0.5) );
+ }
+ EnteringSlide.pushTriangle( basegfx::B2DVector(0.5,0.5) , Radius * unScaledTexCoords[ 0 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ nPointsOnCircles - 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) );
+ LeavingSlide.pushTriangle( basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+ LastRadius = Radius;
+ Radius = NextRadius;
+ NextRadius += dRadius;
+ }
+
+ for(int i(1); i < nCircles - 1; ++i)
+ {
+ Primitive LeavingSlide;
+ Primitive EnteringSlide;
+ for(int Side(0); Side < nPointsOnCircles - 1; ++Side)
+ {
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ }
+
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+
+ LastRadius = Radius;
+ Radius = NextRadius;
+ NextRadius += dRadius;
+ }
+ {
+ Radius = sqrt(2.0);
+ Primitive LeavingSlide;
+ Primitive EnteringSlide;
+ for(int Side(0); Side < nPointsOnCircles - 1; ++Side)
+ {
+
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[Side + 1])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[Side + 1])/2.0 + basegfx::B2DVector(0.5,0.5) );
+ }
+
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[0])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[0])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, (LastRadius + dRadius)/2.0 , 1.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, (LastRadius + dRadius)/2.0 , 1.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+ }
+}
+
+void OGLTransitionImpl::makeHelix( ::sal_uInt16 nRows )
+{
+ clear();
+ double invN(1.0/static_cast<double>(nRows));
+ double iDn = 0.0;
+ double iPDn = invN;
+ for(unsigned int i(0); i < nRows; ++i)
+ {
+ Primitive Tile;
+
+ Tile.pushTriangle(basegfx::B2DVector( 1.0 , iDn ) , basegfx::B2DVector( 0.0 , iDn ) , basegfx::B2DVector( 0.0 , iPDn ));
+
+ Tile.pushTriangle(basegfx::B2DVector( 1.0 , iPDn ) , basegfx::B2DVector( 1.0 , iDn ) , basegfx::B2DVector( 0.0 , iPDn ));
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , 180 ,
+ true,min(max(static_cast<double>(i - nRows/2.0)*invN/2.0,0.0),1.0),
+ min(max(static_cast<double>(i + nRows/2.0)*invN/2.0,0.0),1.0) ) );
+
+ maLeavingSlidePrimitives.push_back(Tile);
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , -180 , false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(Tile);
+
+ iDn += invN;
+ iPDn += invN;
+ }
+}
+
+void OGLTransitionImpl::makeNByMTileFlip( ::sal_uInt16 n, ::sal_uInt16 m )
+{
+ clear();
+ double invN(1.0/static_cast<double>(n));
+ double invM(1.0/static_cast<double>(m));
+ double iDn = 0.0;
+ double iPDn = invN;
+ for(unsigned int i(0); i < n; ++i)
+ {
+ double jDm = 0.0;
+ double jPDm = invM;
+ for(unsigned int j(0); j < m; ++j)
+ {
+ Primitive Tile;
+
+ Tile.pushTriangle(basegfx::B2DVector( iPDn , jDm ) , basegfx::B2DVector( iDn , jDm ) , basegfx::B2DVector( iDn , jPDm ));
+
+ Tile.pushTriangle(basegfx::B2DVector( iPDn , jPDm ) , basegfx::B2DVector( iPDn , jDm ) , basegfx::B2DVector( iDn , jPDm ));//bottom left corner of tile
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 1 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , 180 , true, iDn*jDm/2.0 , ((iPDn*jPDm)+1.0)/2.0 ) );
+ maLeavingSlidePrimitives.push_back(Tile);
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 1 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , -180, false, iDn*jDm/2.0 , ((iPDn*jPDm)+1.0)/2.0 ) );
+
+ maEnteringSlidePrimitives.push_back(Tile);
+
+ jDm += invM;
+ jPDm += invM;
+ }
+ iDn += invN;
+ iPDn += invN;
+ }
+}
+
+SRotate::SRotate(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+SScale::SScale(const basegfx::B3DVector& Scale,const basegfx::B3DVector& Origin, bool bInter, double T0, double T1):scale(Scale),origin(Origin)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+RotateAndScaleDepthByWidth::RotateAndScaleDepthByWidth(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+RotateAndScaleDepthByHeight::RotateAndScaleDepthByHeight(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+
+STranslate::STranslate(const basegfx::B3DVector& Vector, bool bInter, double T0, double T1):vector(Vector)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+inline double intervalInter(double t, double T0, double T1)
+{
+ return ( t - T0 ) / ( T1 - T0 );
+}
+
+void STranslate::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*t*vector.getX(),SlideHeightScale*t*vector.getY(),t*vector.getZ());
+}
+
+void SRotate::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),origin.getZ());
+ glScaled(SlideWidthScale,SlideHeightScale,1);
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glScaled(1/SlideWidthScale,1/SlideHeightScale,1);
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-origin.getZ());
+}
+
+void SScale::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),origin.getZ());
+ glScaled((1-t) + t*scale.getX(),(1-t) + t*scale.getY(),(1-t) + t*scale.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-origin.getZ());
+}
+
+void RotateAndScaleDepthByWidth::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),SlideWidthScale*origin.getZ());
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-SlideWidthScale*origin.getZ());
+}
+
+void RotateAndScaleDepthByHeight::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),SlideHeightScale*origin.getZ());
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-SlideHeightScale*origin.getZ());
+}
+
+SEllipseTranslate::SEllipseTranslate(double dWidth, double dHeight, double dStartPosition, double dEndPosition, bool bInter, double T0, double T1)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+ width = dWidth;
+ height = dHeight;
+ startPosition = dStartPosition;
+ endPosition = dEndPosition;
+}
+
+void SEllipseTranslate::interpolate(double t,double /* SlideWidthScale */,double /* SlideHeightScale */)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+
+ double a1, a2, x, y;
+ a1 = startPosition*2*M_PI;
+ a2 = (startPosition + t*(endPosition - startPosition))*2*M_PI;
+ x = width*(cos (a2) - cos (a1))/2;
+ y = height*(sin (a2) - sin (a1))/2;
+
+ glTranslated(x, 0, y);
+}
+
+STranslate* STranslate::clone()
+{
+ return new STranslate(*this);
+}
+SRotate* SRotate::clone()
+{
+ return new SRotate(*this);
+}
+
+SScale* SScale::clone()
+{
+ return new SScale(*this);
+}
+
+SEllipseTranslate* SEllipseTranslate::clone()
+{
+ return new SEllipseTranslate(*this);
+}
+
+RotateAndScaleDepthByWidth* RotateAndScaleDepthByWidth::clone()
+{
+ return new RotateAndScaleDepthByWidth(*this);
+}
+
+RotateAndScaleDepthByHeight* RotateAndScaleDepthByHeight::clone()
+{
+ return new RotateAndScaleDepthByHeight(*this);
+}
+
+const Primitive& Primitive::operator=(const Primitive& rvalue)
+{
+ for(unsigned int i( 0 ); i < rvalue.Operations.size(); ++i)
+ Operations.push_back(rvalue.Operations[i]->clone());
+ for(unsigned int i( 0 ); i < rvalue.Vertices.size(); ++i)//SPEED! use copy or something. this is slow.
+ Vertices.push_back(rvalue.Vertices[i]);
+ for(unsigned int i( 0 ); i < rvalue.TexCoords.size(); ++i)//SPEED! use copy or something. this is slow.
+ TexCoords.push_back(rvalue.TexCoords[i]);
+ for(unsigned int i( 0 ); i < rvalue.Normals.size(); ++i)//SPEED! use copy or something. this is slow.
+ Normals.push_back(rvalue.Normals[i]);
+ return *this;
+}
+
+Primitive::Primitive(const Primitive& rvalue)
+{
+ for(unsigned int i( 0 ); i < rvalue.Operations.size(); ++i)
+ Operations.push_back(rvalue.Operations[i]->clone());
+ for(unsigned int i( 0 ); i < rvalue.Vertices.size(); ++i)//SPEED! use copy or something. this is slow.
+ Vertices.push_back(rvalue.Vertices[i]);
+ for(unsigned int i( 0 ); i < rvalue.TexCoords.size(); ++i)//SPEED! use copy or something. this is slow.
+ TexCoords.push_back(rvalue.TexCoords[i]);
+ for(unsigned int i( 0 ); i < rvalue.Normals.size(); ++i)//SPEED! use copy or something. this is slow.
+ Normals.push_back(rvalue.Normals[i]);
+}
+
+void Primitive::pushTriangle(const basegfx::B2DVector& SlideLocation0,const basegfx::B2DVector& SlideLocation1,const basegfx::B2DVector& SlideLocation2)
+{
+ vector<basegfx::B3DVector> Verts;
+ vector<basegfx::B2DVector> Texs;
+ Verts.reserve(3);
+ Texs.reserve(3);
+
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation0.getX() - 1, -2*SlideLocation0.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation1.getX() - 1, -2*SlideLocation1.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation2.getX() - 1, -2*SlideLocation2.getY() + 1 , 0.0 ));
+
+ //figure out if they're facing the correct way, and make them face the correct way.
+ basegfx::B3DVector Normal( basegfx::cross( Verts[0] - Verts[1] , Verts[1] - Verts[2] ) );
+ if(Normal.getZ() >= 0.0)//if the normal is facing us
+ {
+ Texs.push_back(SlideLocation0);
+ Texs.push_back(SlideLocation1);
+ Texs.push_back(SlideLocation2);
+ }
+ else // if the normal is facing away from us, make it face us
+ {
+ Texs.push_back(SlideLocation0);
+ Texs.push_back(SlideLocation2);
+ Texs.push_back(SlideLocation1);
+ Verts.clear();
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation0.getX() - 1, -2*SlideLocation0.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation2.getX() - 1, -2*SlideLocation2.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation1.getX() - 1, -2*SlideLocation1.getY() + 1 , 0.0 ));
+ }
+
+ Vertices.push_back(Verts[0]);
+ Vertices.push_back(Verts[1]);
+ Vertices.push_back(Verts[2]);
+
+ TexCoords.push_back(Texs[0]);
+ TexCoords.push_back(Texs[1]);
+ TexCoords.push_back(Texs[2]);
+
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+}
+
+void OGLTransitionImpl::makeDiamond()
+{
+ mmPrepare = &OGLTransitionImpl::prepareDiamond;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::prepareDiamond( double nTime, double /* SlideWidth */, double /* SlideHeight */, double /* DispWidth */, double /* DispHeight */ )
+{
+ Primitive Slide1, Slide2;
+
+ Slide1.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide1.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maEnteringSlidePrimitives.push_back (Slide1);
+
+
+ if( nTime >= 0.5 ) {
+ double m = 1 - nTime;
+
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (m,0), basegfx::B2DVector (0,m));
+ Slide2.pushTriangle (basegfx::B2DVector (nTime,0), basegfx::B2DVector (1,0), basegfx::B2DVector (1,m));
+ Slide2.pushTriangle (basegfx::B2DVector (1,nTime), basegfx::B2DVector (1,1), basegfx::B2DVector (nTime,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,nTime), basegfx::B2DVector (m,1), basegfx::B2DVector (0,1));
+ } else {
+ double l = 0.5 - nTime;
+ double h = 0.5 + nTime;
+
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0.5,l));
+ Slide2.pushTriangle (basegfx::B2DVector (0.5,l), basegfx::B2DVector (1,0), basegfx::B2DVector (h,0.5));
+ Slide2.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (1,1), basegfx::B2DVector (h,0.5));
+ Slide2.pushTriangle (basegfx::B2DVector (h,0.5), basegfx::B2DVector (1,1), basegfx::B2DVector (0.5,h));
+ Slide2.pushTriangle (basegfx::B2DVector (0.5,h), basegfx::B2DVector (1,1), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (l,0.5), basegfx::B2DVector (0.5,h), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (l,0.5), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (0.5,l), basegfx::B2DVector (l,0.5));
+ }
+ Slide2.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, 0.00000001), false, -1, 0));
+ maLeavingSlidePrimitives.push_back (Slide2);
+}
+
+void OGLTransitionImpl::makeVenetianBlinds( bool vertical, int parts )
+{
+ static double t30 = tan( M_PI/6.0 );
+ double n, ln = 0;
+ double p = 1.0/parts;
+
+ for( int i=0; i<parts; i++ ) {
+ Primitive Slide;
+ n = (i + 1)/(double)parts;
+ if( vertical ) {
+ Slide.pushTriangle (basegfx::B2DVector (ln,0), basegfx::B2DVector (n,0), basegfx::B2DVector (ln,1));
+ Slide.pushTriangle (basegfx::B2DVector (n,0), basegfx::B2DVector (ln,1), basegfx::B2DVector (n,1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(n + ln - 1, 0, -t30*p), -120, true, 0.0, 1.0));
+ } else {
+ Slide.pushTriangle (basegfx::B2DVector (0,ln), basegfx::B2DVector (1,ln), basegfx::B2DVector (0,n));
+ Slide.pushTriangle (basegfx::B2DVector (1,ln), basegfx::B2DVector (0,n), basegfx::B2DVector (1,n));
+ Slide.Operations.push_back(new RotateAndScaleDepthByHeight(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - n - ln, -t30*p), -120, true, 0.0, 1.0));
+ }
+ maLeavingSlidePrimitives.push_back (Slide);
+
+ if( vertical ) {
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(2*n - 1, 0, 0), -60, false, -1, 0));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(n + ln - 1, 0, 0), 180, false, -1, 0));
+ } else {
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - 2*n, 0), -60, false, -1, 0));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - n - ln, 0), 180, false, -1, 0));
+ }
+ maEnteringSlidePrimitives.push_back (Slide);
+ ln = n;
+ }
+}
+
+void OGLTransitionImpl::displaySlidesFadeSmoothly( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_DEPTH_TEST);
+
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_LIGHTING);
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+ glColor4f( 1, 1, 1, nTime );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ glDisable(GL_BLEND);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
+ glEnable(GL_LIGHTING);
+
+ glEnable(GL_DEPTH_TEST);
+}
+
+void OGLTransitionImpl::makeFadeSmoothly()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesFadeSmoothly;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::displaySlidesFadeThroughBlack( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_DEPTH_TEST);
+
+ glDisable(GL_LIGHTING);
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+ if( nTime < 0.5 ) {
+ glColor4f( 1, 1, 1, 1 - nTime*2 );
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ } else {
+ glColor4f( 1, 1, 1, (nTime - 0.5)*2 );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+ glDisable(GL_BLEND);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
+ glEnable(GL_LIGHTING);
+
+ glEnable(GL_DEPTH_TEST);
+}
+
+void OGLTransitionImpl::makeFadeThroughBlack()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesFadeThroughBlack;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+static const char* basicVertexShader = "\n\
+varying vec2 v_texturePosition;\n\
+\n\
+void main( void )\n\
+{\n\
+ gl_Position = ftransform();\n\
+ v_texturePosition = gl_MultiTexCoord0.xy;\n\
+}\n\
+";
+
+static const char* staticFragmentShader = "\n\
+uniform sampler2D leavingSlideTexture;\n\
+uniform sampler2D enteringSlideTexture;\n\
+uniform sampler2D permTexture;\n\
+uniform float time;\n\
+varying vec2 v_texturePosition;\n\
+\n\
+float snoise(vec2 P) {\n\
+\n\
+ return texture2D(permTexture, P).r;\n\
+}\n\
+\n\
+\n\
+#define PART 0.5\n\
+#define START 0.4\n\
+#define END 0.9\n\
+\n\
+void main() {\n\
+ float sn = snoise(10.0*v_texturePosition+time*0.07);\n\
+ if( time < PART ) {\n\
+ float sn1 = snoise(vec2(time*15.0, 20.0*v_texturePosition.y));\n\
+ float sn2 = snoise(v_texturePosition);\n\
+ if (sn1 > 1.0 - time*time && sn2 < 2.0*time+0.1)\n\
+ gl_FragColor = vec4(sn, sn, sn, 1.0);\n\
+ else if (time > START )\n\
+ gl_FragColor = ((time-START)/(PART - START))*vec4(sn, sn, sn, 1.0) + (1.0 - (time - START)/(PART - START))*texture2D(leavingSlideTexture, v_texturePosition);\n\
+ else\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+ } else if ( time < PART ) {\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+ } else if ( time > END ) {\n\
+ gl_FragColor = ((1.0 - time)/(1.0 - END))*vec4(sn, sn, sn, 1.0) + ((time - END)/(1.0 - END))*texture2D(enteringSlideTexture, v_texturePosition);\n\
+ } else \n\
+ gl_FragColor = vec4(sn, sn, sn, 1.0);\n\
+}\n\
+";
+
+static const char* dissolveFragmentShader = "\n\
+uniform sampler2D leavingSlideTexture;\n\
+uniform sampler2D enteringSlideTexture;\n\
+uniform sampler2D permTexture;\n\
+uniform float time;\n\
+varying vec2 v_texturePosition;\n\
+\n\
+float snoise(vec2 P) {\n\
+\n\
+ return texture2D(permTexture, P).r;\n\
+}\n\
+\n\
+void main() {\n\
+ float sn = snoise(10.0*v_texturePosition);\n\
+ if( sn < time)\n\
+ gl_FragColor = texture2D(enteringSlideTexture, v_texturePosition);\n\
+ else\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+}\n\
+";
+
+int permutation256 [256]= {
+215, 100, 200, 204, 233, 50, 85, 196,
+ 71, 141, 122, 160, 93, 131, 243, 234,
+162, 183, 36, 155, 4, 62, 35, 205,
+ 40, 102, 33, 27, 255, 55, 214, 156,
+ 75, 163, 134, 126, 249, 74, 197, 228,
+ 72, 90, 206, 235, 17, 22, 49, 169,
+227, 89, 16, 5, 117, 60, 248, 230,
+217, 68, 138, 96, 194, 170, 136, 10,
+112, 238, 184, 189, 176, 42, 225, 212,
+ 84, 58, 175, 244, 150, 168, 219, 236,
+101, 208, 123, 37, 164, 110, 158, 201,
+ 78, 114, 57, 48, 70, 142, 106, 43,
+232, 26, 32, 252, 239, 98, 191, 94,
+ 59, 149, 39, 187, 203, 190, 19, 13,
+133, 45, 61, 247, 23, 34, 20, 52,
+118, 209, 146, 193, 222, 18, 1, 152,
+ 46, 41, 91, 148, 115, 25, 135, 77,
+254, 147, 224, 161, 9, 213, 223, 250,
+231, 251, 127, 166, 63, 179, 81, 130,
+139, 28, 120, 151, 241, 86, 111, 0,
+ 88, 153, 172, 182, 159, 105, 178, 47,
+ 51, 167, 65, 66, 92, 73, 198, 211,
+245, 195, 31, 220, 140, 76, 221, 186,
+154, 185, 56, 83, 38, 165, 109, 67,
+124, 226, 132, 53, 229, 29, 12, 181,
+121, 24, 207, 199, 177, 113, 30, 80,
+ 3, 97, 188, 79, 216, 173, 8, 145,
+ 87, 128, 180, 237, 240, 137, 125, 104,
+ 15, 242, 119, 246, 103, 143, 95, 144,
+ 2, 44, 69, 157, 192, 174, 14, 54,
+218, 82, 64, 210, 11, 6, 129, 21,
+116, 171, 99, 202, 7, 107, 253, 108
+};
+
+void initPermTexture(GLuint *texID)
+{
+ glGenTextures(1, texID);
+ glBindTexture(GL_TEXTURE_2D, *texID);
+
+ static bool initialized = false;
+ static unsigned char permutation2D[256*256*4];
+ if( !initialized ) {
+ int x, y;
+
+ for( y=0; y < 256; y++ )
+ for( x=0; x < 256; x++ )
+ permutation2D[x*4 + y*1024] = permutation256[(y + permutation256[x]) & 0xff];
+
+ initialized = true;
+ }
+
+ glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_UNSIGNED_BYTE, permutation2D );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
+}
+
+void OGLTransitionImpl::preparePermShader()
+{
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ glUseProgram( mProgramObject );
+
+ GLint location = glGetUniformLocation( mProgramObject, "leavingSlideTexture" );
+ if( location != -1 ) {
+ glUniform1i( location, 0 ); // texture unit 0
+ }
+
+ glActiveTexture(GL_TEXTURE1);
+ if( !maHelperTexture )
+ initPermTexture( &maHelperTexture );
+ glActiveTexture(GL_TEXTURE0);
+
+ location = glGetUniformLocation( mProgramObject, "permTexture" );
+ if( location != -1 ) {
+ glUniform1i( location, 1 ); // texture unit 1
+ }
+
+ location = glGetUniformLocation( mProgramObject, "enteringSlideTexture" );
+ if( location != -1 ) {
+ glUniform1i( location, 2 ); // texture unit 2
+ }
+ }
+#endif
+}
+
+void OGLTransitionImpl::prepareStatic( ::sal_Int32 /* glLeavingSlideTex */, ::sal_Int32 /* glEnteringSlideTex */ )
+{
+ //mProgramObject = LinkProgram( basicVertexShader, staticFragmentShader );
+ NSString * _basicVertexShader = (NSString *) basicVertexShader;
+ NSString * _staticFragmentShader = (NSString *) staticFragmentShader;
+ OGLShaders * anOGLShader = NULL;
+ mProgramObject = [anOGLShader loadVertexShader: _basicVertexShader fragmentShader: _staticFragmentShader];
+
+ preparePermShader();
+}
+
+void OGLTransitionImpl::displaySlidesShaders( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ GLint location = glGetUniformLocation( mProgramObject, "time" );
+ if( location != -1 ) {
+ glUniform1f( location, nTime );
+ }
+ }
+
+ glActiveTexture( GL_TEXTURE2 );
+ glBindTexture( GL_TEXTURE_2D, glEnteringSlideTex );
+ glActiveTexture( GL_TEXTURE0 );
+#endif
+
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+}
+
+void OGLTransitionImpl::makeStatic()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesShaders;
+ mmPrepareTransition = &OGLTransitionImpl::prepareStatic;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+
+ mnRequiredGLVersion = 2.0;
+}
+
+void OGLTransitionImpl::prepareDissolve( ::sal_Int32 /* glLeavingSlideTex */, ::sal_Int32 /* glEnteringSlideTex */ )
+{
+ NSString * _basicVertexShader = (NSString *) basicVertexShader;
+ NSString * _dissolveFragmentShader = (NSString *) dissolveFragmentShader;
+// mProgramObject = loadVertexShader( _basicVertexShader, _dissolveFragmentShader );
+ OGLShaders * anOGLShader = NULL;
+ mProgramObject = [anOGLShader loadVertexShader: _basicVertexShader fragmentShader: _dissolveFragmentShader];
+
+ preparePermShader();
+}
+
+void OGLTransitionImpl::makeDissolve()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesShaders;
+ mmPrepareTransition = &OGLTransitionImpl::prepareDissolve;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+
+ mnRequiredGLVersion = 2.0;
+}
+
+void OGLTransitionImpl::makeNewsflash()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0,0,0),3000,true,0,0.5));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(0.01,0.01,0.01),basegfx::B3DVector(0,0,0),true,0,0.5));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(-10000, 0, 0),false, 0.5, 2));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.clear();
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0,0,0),-3000,true,0.5,1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(-100, 0, 0),false, -1, 1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(100, 0, 0),false, 0.5, 1));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(0.01,0.01,0.01),basegfx::B3DVector(0,0,0),false,-1,1));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(100,100,100),basegfx::B3DVector(0,0,0),true,0.5,1));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0.2,0.2,0),1080,true,0,1));
+}
+
diff --git a/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionerImpl.mm b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionerImpl.mm
new file mode 100644
index 000000000..9200f4c94
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/OGLTrans_TransitionerImpl.mm
@@ -0,0 +1,1132 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#define GLX_GLXEXT_PROTOTYPES 1
+#include "OGLTrans_TransitionImpl.hxx"
+
+#include <com/sun/star/beans/XFastPropertySet.hpp>
+#include <com/sun/star/rendering/IntegerBitmapLayout.hpp>
+#include <com/sun/star/rendering/ColorComponentTag.hpp>
+#include <com/sun/star/rendering/ColorSpaceType.hpp>
+#include <com/sun/star/animations/TransitionType.hpp>
+#include <com/sun/star/animations/TransitionSubType.hpp>
+#include <com/sun/star/presentation/XTransitionFactory.hpp>
+#include <com/sun/star/presentation/XTransition.hpp>
+#include <com/sun/star/presentation/XSlideShowView.hpp>
+#include <com/sun/star/uno/XComponentContext.hpp>
+#include <com/sun/star/rendering/XIntegerBitmap.hpp>
+#include <com/sun/star/geometry/IntegerSize2D.hpp>
+
+#include <cppuhelper/compbase1.hxx>
+#include <cppuhelper/basemutex.hxx>
+#include <cppuhelper/factory.hxx>
+#include <rtl/ref.hxx>
+
+#include <comphelper/servicedecl.hxx>
+
+#include <canvas/canvastools.hxx>
+#include <tools/gen.hxx>
+#include <vcl/window.hxx>
+#include <vcl/syschild.hxx>
+#include <vcl/sysdata.hxx>
+
+#include <boost/noncopyable.hpp>
+
+#include <premac.h>
+#include <Foundation/Foundation.h>
+#include <Cocoa/Cocoa.h>
+#include <OpenGL/gl.h>
+#include <OpenGL/glu.h>
+#include <OpenGL/glext.h>
+#include "aquaOpenGLView.h"
+#include <postmac.h>
+
+#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
+#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
+
+#ifdef DEBUG
+#include <boost/date_time/posix_time/posix_time.hpp>
+using namespace ::boost::posix_time;
+
+static ptime t1;
+static ptime t2;
+
+#define DBG(x) x
+#else
+#define DBG(x)
+#endif
+
+using namespace ::com::sun::star;
+using ::com::sun::star::beans::XFastPropertySet;
+using ::com::sun::star::uno::Any;
+using ::com::sun::star::uno::Reference;
+using ::com::sun::star::uno::Sequence;
+using ::com::sun::star::uno::UNO_QUERY;
+using ::com::sun::star::uno::UNO_QUERY_THROW;
+
+namespace
+{
+
+typedef cppu::WeakComponentImplHelper1<presentation::XTransition> OGLTransitionerImplBase;
+
+namespace
+{
+ struct OGLFormat
+ {
+ GLint nInternalFormat;
+ GLenum eFormat;
+ GLenum eType;
+ };
+
+ /* channel ordering: (0:rgba, 1:bgra, 2:argb, 3:abgr)
+ */
+ int calcComponentOrderIndex(const uno::Sequence<sal_Int8>& rTags)
+ {
+ using namespace rendering::ColorComponentTag;
+
+ static const sal_Int8 aOrderTable[] =
+ {
+ RGB_RED, RGB_GREEN, RGB_BLUE, ALPHA,
+ RGB_BLUE, RGB_GREEN, RGB_RED, ALPHA,
+ ALPHA, RGB_RED, RGB_GREEN, RGB_BLUE,
+ ALPHA, RGB_BLUE, RGB_GREEN, RGB_RED,
+ };
+
+ const sal_Int32 nNumComps(rTags.getLength());
+ const sal_Int8* pLine=aOrderTable;
+ for(int i=0; i<4; ++i)
+ {
+ int j=0;
+ while( j<4 && j<nNumComps && pLine[j] == rTags[j] )
+ ++j;
+
+ // all of the line passed, this is a match!
+ if( j==nNumComps )
+ return i;
+
+ pLine+=4;
+ }
+
+ return -1;
+ }
+}
+
+/** This is the Transitioner class for OpenGL 3D transitions in
+ * slideshow. This class is implicitly
+ * constructed from XTransitionFactory.
+*/
+class OGLTransitionerImpl : private cppu::BaseMutex, private boost::noncopyable, public OGLTransitionerImplBase
+{
+public:
+ explicit OGLTransitionerImpl(OGLTransitionImpl* pOGLTransition);
+ bool initWindowFromSlideShowView( const uno::Reference< presentation::XSlideShowView >& xView );
+ void setSlides( const Reference< rendering::XBitmap >& xLeavingSlide , const uno::Reference< rendering::XBitmap >& xEnteringSlide );
+ static bool initialize( const Reference< presentation::XSlideShowView >& xView );
+
+ // XTransition
+ virtual void SAL_CALL update( double nTime )
+ throw (uno::RuntimeException);
+ virtual void SAL_CALL viewChanged( const Reference< presentation::XSlideShowView >& rView,
+ const Reference< rendering::XBitmap >& rLeavingBitmap,
+ const Reference< rendering::XBitmap >& rEnteringBitmap )
+ throw (uno::RuntimeException);
+
+protected:
+ void disposeContextAndWindow();
+ void disposeTextures();
+
+ // WeakComponentImplHelperBase
+ virtual void SAL_CALL disposing();
+
+ bool isDisposed() const
+ {
+ return (rBHelper.bDisposed || rBHelper.bInDispose);
+ }
+
+// bool createWindow( Window* pPWindow );
+ void createTexture(GLuint* texID,
+ bool useMipmap,
+ uno::Sequence<sal_Int8>& data,
+ const OGLFormat* pFormat );
+ void prepareEnvironment ();
+ const OGLFormat* chooseFormats();
+
+private:
+ /** After the window has been created, and the slides have been set, we'll initialize the slides with OpenGL.
+ */
+ void GLInitSlides();
+
+
+ /// Holds the information of our new child window
+ struct GLWindow
+ {
+ AquaOpenGLView* pAquaOpenGLView; // Custom Cocoa NSOpenGLView
+ NSOpenGLContext* pOpenGLContext; // our OpenGLContext
+ NSRect aInitFrame;
+ NSView* apView;
+ NSScreen* screen;
+ unsigned int bpp;
+ unsigned int Width;
+ unsigned int Height;
+ const char* GLXExtensions;
+ const GLubyte* GLExtensions;
+
+ bool HasGLXExtension( const char* name ) { return gluCheckExtension( (const GLubyte*) name, (const GLubyte*) GLXExtensions ); }
+ bool HasGLExtension( const char* name ) { return gluCheckExtension( (const GLubyte*) name, GLExtensions ); }
+ } GLWin;
+
+ /** OpenGL handle to the leaving slide's texture
+ */
+#if defined(MAC_OS_X_VERSION_10_5) || defined(MAC_OS_X_VERSION_10_6)
+ GLuint GLleavingSlide;
+#else /* build target 10.4 */
+ unsigned long int GLleavingSlide;
+#endif
+
+ /** OpenGL handle to the entering slide's texture
+ */
+#if defined(MAC_OS_X_VERSION_10_5) || defined(MAC_OS_X_VERSION_10_6)
+ GLuint GLenteringSlide;
+#else /* build target 10.4 */
+ unsigned long int GLenteringSlide;
+#endif
+
+ /** pointer to our window which we MIGHT create.
+ */
+ class SystemChildWindow* pWindow;
+
+ Reference< presentation::XSlideShowView > mxView;
+ Reference< rendering::XIntegerBitmap > mxLeavingBitmap;
+ Reference< rendering::XIntegerBitmap > mxEnteringBitmap;
+
+ /** raw bytes of the entering bitmap
+ */
+ uno::Sequence<sal_Int8> EnteringBytes;
+
+ /** raw bytes of the leaving bitmap
+ */
+ uno::Sequence<sal_Int8> LeavingBytes;
+ bool mbRestoreSync;
+ bool mbUseLeavingPixmap;
+ bool mbUseEnteringPixmap;
+ bool mbFreeLeavingPixmap;
+ bool mbFreeEnteringPixmap;
+// unx::Pixmap maLeavingPixmap;
+// unx::Pixmap maEnteringPixmap;
+
+ /** the form the raw bytes are in for the bitmaps
+ */
+ rendering::IntegerBitmapLayout SlideBitmapLayout;
+
+ /** the size of the slides
+ */
+ geometry::IntegerSize2D SlideSize;
+
+ /** Our Transition to be used.
+ */
+ OGLTransitionImpl* pTransition;
+
+public:
+ /** whether we are running on ATI fglrx with bug related to textures
+ */
+ static bool cbBrokenTexturesATI;
+
+ /** GL version
+ */
+ static float cnGLVersion;
+
+ /** Whether Mesa is the OpenGL vendor
+ */
+
+ static bool cbMesa;
+
+ /**
+ whether the display has GLX extension
+ */
+ static bool cbGLXPresent;
+
+ /**
+ whether texture from pixmap extension is available
+ */
+ bool mbTextureFromPixmap;
+
+ /**
+ whether to generate mipmaped textures
+ */
+ bool mbGenerateMipmap;
+
+ /**
+ whether we have visual which can be used for texture_from_pixmap extension
+ */
+// bool mbHasTFPVisual;
+
+#ifdef DEBUG
+ ptime t3;
+ ptime t4;
+ ptime t5;
+ ptime t6;
+ time_duration total_update;
+ int frame_count;
+#endif
+};
+
+// declare the static variables as some gcc versions have problems declaring them automaticaly
+/**/
+bool OGLTransitionerImpl::cbBrokenTexturesATI;
+
+float OGLTransitionerImpl::cnGLVersion;
+/**/
+bool OGLTransitionerImpl::cbMesa;
+
+bool OGLTransitionerImpl::cbGLXPresent;
+
+
+bool OGLTransitionerImpl::initialize( const Reference< presentation::XSlideShowView >& xView )
+{
+ // not thread safe
+
+ // only once. This part is needed for the hardware identification
+ // [FIXME]: is there a Mac way of doing that ?
+ static bool initialized = false;
+
+ if( !initialized ) {
+ OGLTransitionerImpl *instance;
+
+ instance = new OGLTransitionerImpl( NULL );
+ if( instance->initWindowFromSlideShowView( xView ) )
+
+ {
+ const GLubyte* version = glGetString( GL_VERSION );
+ if( version && version[0] ) {
+ cnGLVersion = version[0] - '0';
+ if( version[1] == '.' && version[2] )
+ cnGLVersion += (version[2] - '0')/10.0;
+ } else
+ cnGLVersion = 1.0;
+ OSL_TRACE("GL version: %s parsed: %f", version, cnGLVersion );
+
+ const GLubyte* vendor = glGetString( GL_VENDOR );
+ cbMesa = ( vendor && strstr( (const char *) vendor, "Mesa" ) );
+ OSL_TRACE("GL vendor: %s identified as Mesa: %d", vendor, cbMesa );
+
+ /* TODO: check for version once the bug in fglrx driver is fixed */
+ cbBrokenTexturesATI = (vendor && strcmp( (const char *) vendor, "ATI Technologies Inc." ) == 0 );
+
+ instance->disposing();
+ cbGLXPresent = true;
+ } else
+ cbGLXPresent = false;
+
+ delete instance;
+ initialized = true;
+ }
+
+ return cbGLXPresent;
+}
+
+/*bool OGLTransitionerImpl::createWindow( Window* pPWindow )
+{
+ const SystemEnvData* sysData(pPWindow->GetSystemData());
+
+ GLWin.apView = sysData->pView;
+
+ NSOpenGLPixelFormat* fmt = [AquaOpenGLView defaultPixelFormat];
+ Window *pFrameWindow = pPWindow->GetWindow(WINDOW_FRAME);
+ Size aFrameSize( pFrameWindow->GetSizePixel() );
+ Point aScreen( pPWindow->OutputToScreenPixel( Point() ) );
+ GLWin.aInitFrame = (NSRect){ { aScreen.X(), aFrameSize.Height() - GLWin.Height - aScreen.Y() }, { GLWin.Width, GLWin.Height } };
+
+ GLWin.pAquaOpenGLView = [[NSOpenGLView alloc]initWithFrame: GLWin.aInitFrame pixelFormat: fmt];
+ OSL_ENSURE(GLWin.pAquaOpenGLView, "Could not create NSOPenGLView");
+ if( !GLWin.pAquaOpenGLView )
+ return false;
+//
+ GLWin.pOpenGLContext = [GLWin.pAquaOpenGLView openGLContext];
+ [GLWin.pOpenGLContext retain];
+ [GLWin.pAquaOpenGLView setOpenGLContext:GLWin.pOpenGLContext];
+ [sysData->pView addSubview:GLWin.pAquaOpenGLView];
+//
+ if( pWindow )
+ {
+ pWindow->SetMouseTransparent( sal_True );
+ pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP );
+ pWindow->EnableEraseBackground( sal_False );
+ pWindow->SetControlForeground();
+ pWindow->SetControlBackground();
+ pWindow->EnablePaint(sal_False);
+ pWindow->SetPosSizePixel(pPWindow->GetPosPixel(),pPWindow->GetSizePixel());
+ // GLWin.dpy = reinterpret_cast<unx::Display*>(pChildSysData->pDisplay);
+// GLWin.win = pChildSysData->aWindow;
+
+ return true;
+ }
+
+ return false;
+}
+*/
+
+bool OGLTransitionerImpl::initWindowFromSlideShowView( const Reference< presentation::XSlideShowView >& xView )
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed())
+ return false;
+
+ mxView.set( xView, UNO_QUERY );
+ if( !mxView.is() )
+ return false;
+
+ /// take the XSlideShowView and extract the parent window from it. see viewmediashape.cxx
+ uno::Reference< rendering::XCanvas > xCanvas(mxView->getCanvas(), uno::UNO_QUERY_THROW);
+ uno::Sequence< uno::Any > aDeviceParams;
+ ::canvas::tools::getDeviceInfo( xCanvas, aDeviceParams );
+
+ ::rtl::OUString aImplName;
+ aDeviceParams[ 0 ] >>= aImplName;
+
+ sal_Int64 aVal = 0;
+ aDeviceParams[1] >>= aVal;
+ Window* pPWindow = reinterpret_cast< Window* >( aVal );
+ GLWin.Width = pPWindow->GetSizePixel().Width();
+ GLWin.Height = pPWindow->GetSizePixel().Height();
+
+ const SystemEnvData* sysData(pPWindow->GetSystemData());
+
+ GLWin.apView = sysData->pView;
+
+ NSOpenGLPixelFormat* fmt = [AquaOpenGLView defaultPixelFormat];
+ Window *pFrameWindow = pPWindow->GetWindow(WINDOW_FRAME);
+ Size aFrameSize( pFrameWindow->GetSizePixel() );
+ Point aScreen( pPWindow->OutputToScreenPixel( Point() ) );
+ GLWin.aInitFrame = (NSRect){ { aScreen.X(), aFrameSize.Height() - GLWin.Height - aScreen.Y() }, { GLWin.Width, GLWin.Height } };
+
+ GLWin.pAquaOpenGLView = [[NSOpenGLView alloc]initWithFrame: GLWin.aInitFrame pixelFormat: fmt];
+ OSL_ENSURE(GLWin.pAquaOpenGLView, "Could not create NSOPenGLView");
+ if( !GLWin.pAquaOpenGLView )
+ return false;
+
+ GLWin.pOpenGLContext = [GLWin.pAquaOpenGLView openGLContext];
+ [GLWin.pOpenGLContext retain];
+ [GLWin.pAquaOpenGLView setOpenGLContext:GLWin.pOpenGLContext];
+
+ if( GLWin.pOpenGLContext == NULL ) {
+ OSL_TRACE("unable to create GLX context");
+ return false;
+ }
+
+ awt::Rectangle aCanvasArea = mxView->getCanvasArea();
+
+ // needed in windowed mode only ?
+ if( (aCanvasArea.X != 0) && (aCanvasArea.Y != 0) )
+ pWindow->SetPosSizePixel(aCanvasArea.X, aCanvasArea.Y, aCanvasArea.Width, aCanvasArea.Height);
+
+ GLWin.Width = aCanvasArea.Width;
+ GLWin.Height = aCanvasArea.Height;
+ OSL_TRACE("canvas area: %d,%d - %dx%d", aCanvasArea.X, aCanvasArea.Y, aCanvasArea.Width, aCanvasArea.Height);
+
+ mbTextureFromPixmap = GLWin.HasGLXExtension( "GLX_EXT_texture_from_pixmap" );
+ mbGenerateMipmap = GLWin.HasGLExtension( "GL_SGIS_generate_mipmap" );
+
+ [GLWin.apView addSubview:GLWin.pAquaOpenGLView];
+
+ if( pWindow )
+ {
+ pWindow->SetMouseTransparent( sal_True );
+ pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP );
+ pWindow->EnableEraseBackground( sal_False );
+ pWindow->SetControlForeground();
+ pWindow->SetControlBackground();
+ pWindow->EnablePaint(sal_False);
+ pWindow->SetPosSizePixel(pPWindow->GetPosPixel(),pPWindow->GetSizePixel());
+
+ }
+
+
+ glShadeModel( GL_SMOOTH );
+ glEnable(GL_CULL_FACE);
+ glCullFace(GL_BACK);
+ glClearColor (0.0f, 0.0f, 0.0f, 0.0f); // R G B A
+ glClear(GL_COLOR_BUFFER_BIT);
+ glClearDepth( 1.0f );
+ glEnable( GL_DEPTH_TEST );
+ glDepthFunc( GL_LEQUAL );
+ glHint( GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST );
+ glEnable(GL_TEXTURE_2D);
+
+ glEnable(GL_LIGHTING);
+ GLfloat light_direction[] = { 0.0 , 0.0 , 1.0 };
+ GLfloat materialDiffuse[] = { 1.0 , 1.0 , 1.0 , 1.0};
+ glLightfv(GL_LIGHT0, GL_SPOT_DIRECTION, light_direction);
+ glMaterialfv(GL_FRONT,GL_DIFFUSE,materialDiffuse);
+ glEnable(GL_LIGHT0);
+ glEnable(GL_NORMALIZE);
+
+ [[GLWin.pAquaOpenGLView openGLContext] flushBuffer];
+
+ if( LeavingBytes.hasElements() && EnteringBytes.hasElements())
+ GLInitSlides();//we already have uninitialized slides, let's initialize
+
+ if( pTransition && pTransition->mnRequiredGLVersion <= cnGLVersion )
+ pTransition->prepare( GLleavingSlide, GLenteringSlide );
+
+ return true;
+}
+
+void OGLTransitionerImpl::setSlides( const uno::Reference< rendering::XBitmap >& xLeavingSlide,
+ const uno::Reference< rendering::XBitmap >& xEnteringSlide )
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed())
+ return;
+
+ mxLeavingBitmap.set( xLeavingSlide , UNO_QUERY_THROW );
+ mxEnteringBitmap.set( xEnteringSlide , UNO_QUERY_THROW );
+ Reference< XFastPropertySet > xLeavingSet( xLeavingSlide , UNO_QUERY );
+ Reference< XFastPropertySet > xEnteringSet( xEnteringSlide , UNO_QUERY );
+
+ geometry::IntegerRectangle2D SlideRect;
+ SlideSize = mxLeavingBitmap->getSize();
+ SlideRect.X1 = 0;
+ SlideRect.X2 = SlideSize.Width;
+ SlideRect.Y1 = 0;
+ SlideRect.Y2 = SlideSize.Height;
+
+ OSL_TRACE("leaving bitmap area: %dx%d", SlideSize.Width, SlideSize.Height);
+ SlideSize = mxEnteringBitmap->getSize();
+ OSL_TRACE("entering bitmap area: %dx%d", SlideSize.Width, SlideSize.Height);
+
+#ifdef DEBUG
+ t1 = microsec_clock::local_time();
+#endif
+
+ mbUseLeavingPixmap = false;
+ mbUseEnteringPixmap = false;
+
+ if( !mbUseLeavingPixmap )
+ LeavingBytes = mxLeavingBitmap->getData(SlideBitmapLayout,SlideRect);
+ if( !mbUseEnteringPixmap )
+ EnteringBytes = mxEnteringBitmap->getData(SlideBitmapLayout,SlideRect);
+
+ if(GLWin.pOpenGLContext)//if we have a rendering context, let's init the slides
+ GLInitSlides();
+
+ OSL_ENSURE(SlideBitmapLayout.PlaneStride == 0,"only handle no plane stride now");
+
+ /* flush & sync */
+ mbRestoreSync = true;
+}
+
+void OGLTransitionerImpl::createTexture( GLuint* texID,
+//#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+// unx::GLXPixmap pixmap,
+// bool usePixmap,
+//#endif
+ bool useMipmap,
+ uno::Sequence<sal_Int8>& data,
+ const OGLFormat* pFormat )
+{
+ glDeleteTextures( 1, texID );
+ glGenTextures( 1, texID );
+ glBindTexture( GL_TEXTURE_2D, *texID );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT );
+/*
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::PFNGLXBINDTEXIMAGEEXTPROC myglXBindTexImageEXT = (unx::PFNGLXBINDTEXIMAGEEXTPROC) unx::glXGetProcAddress( (const GLubyte*) "glXBindTexImageEXT" );
+
+ if( usePixmap ) {
+ if( mbGenerateMipmap )
+ glTexParameteri( GL_TEXTURE_2D, GL_GENERATE_MIPMAP_SGIS, True);
+ myglXBindTexImageEXT (GLWin.dpy, pixmap, GLX_FRONT_LEFT_EXT, NULL);
+ if( mbGenerateMipmap && useMipmap ) {
+ OSL_TRACE("use mipmaps");
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR); //TRILINEAR FILTERING
+ } else {
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST);
+ }
+ } else {
+#endif
+*/
+ if( !pFormat )
+ {
+ // force-convert color to ARGB8888 int color space
+ uno::Sequence<sal_Int8> tempBytes(
+ SlideBitmapLayout.ColorSpace->convertToIntegerColorSpace(
+ data,
+ canvas::tools::getStdColorSpace()));
+ gluBuild2DMipmaps(GL_TEXTURE_2D,
+ 4,
+ SlideSize.Width,
+ SlideSize.Height,
+ GL_RGBA,
+ GL_UNSIGNED_BYTE,
+ &tempBytes[0]);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR); //TRILINEAR FILTERING
+
+ //anistropic filtering (to make texturing not suck when looking at polygons from oblique angles)
+ GLfloat largest_supported_anisotropy;
+ glGetFloatv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &largest_supported_anisotropy);
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, largest_supported_anisotropy);
+ } else {
+ if( pTransition && !cbBrokenTexturesATI && !useMipmap) {
+ glTexImage2D( GL_TEXTURE_2D, 0, pFormat->nInternalFormat, SlideSize.Width, SlideSize.Height, 0, pFormat->eFormat, pFormat->eType, &data[0] );
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST);
+ } else {
+ gluBuild2DMipmaps( GL_TEXTURE_2D, pFormat->nInternalFormat, SlideSize.Width, SlideSize.Height, pFormat->eFormat, pFormat->eType, &data[0] );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR ); //TRILINEAR FILTERING
+
+ //anistropic filtering (to make texturing not suck when looking at polygons from oblique angles)
+ GLfloat largest_supported_anisotropy;
+ glGetFloatv( GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &largest_supported_anisotropy );
+ glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, largest_supported_anisotropy );
+ }
+ }
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ }
+#endif
+ OSL_ENSURE(glIsTexture(*texID), "Can't generate Leaving slide textures in OpenGL");
+}
+
+void OGLTransitionerImpl::prepareEnvironment()
+{
+ glMatrixMode(GL_PROJECTION);
+ glLoadIdentity();
+ double EyePos(10.0);
+ double RealF(1.0);
+ double RealN(-1.0);
+ double RealL(-1.0);
+ double RealR(1.0);
+ double RealB(-1.0);
+ double RealT(1.0);
+ double ClipN(EyePos+5.0*RealN);
+ double ClipF(EyePos+15.0*RealF);
+ double ClipL(RealL*8.0);
+ double ClipR(RealR*8.0);
+ double ClipB(RealB*8.0);
+ double ClipT(RealT*8.0);
+ //This scaling is to take the plane with BottomLeftCorner(-1,-1,0) and TopRightCorner(1,1,0) and map it to the screen after the perspective division.
+ glScaled( 1.0 / ( ( ( RealR * 2.0 * ClipN ) / ( EyePos * ( ClipR - ClipL ) ) ) - ( ( ClipR + ClipL ) / ( ClipR - ClipL ) ) ),
+ 1.0 / ( ( ( RealT * 2.0 * ClipN ) / ( EyePos * ( ClipT - ClipB ) ) ) - ( ( ClipT + ClipB ) / ( ClipT - ClipB ) ) ),
+ 1.0 );
+ glFrustum(ClipL,ClipR,ClipB,ClipT,ClipN,ClipF);
+ glMatrixMode(GL_MODELVIEW);
+ glLoadIdentity();
+ glTranslated(0,0,-EyePos);
+}
+
+const OGLFormat* OGLTransitionerImpl::chooseFormats()
+{
+ const OGLFormat* pDetectedFormat=NULL;
+ uno::Reference<rendering::XIntegerBitmapColorSpace> xIntColorSpace(
+ SlideBitmapLayout.ColorSpace);
+
+ if( (xIntColorSpace->getType() == rendering::ColorSpaceType::RGB ||
+ xIntColorSpace->getType() == rendering::ColorSpaceType::SRGB) )
+ {
+ /* table for canvas->OGL format mapping. outer index is number
+ of color components (0:3, 1:4), then comes bits per pixel
+ (0:16, 1:24, 2:32), then channel ordering: (0:rgba, 1:bgra,
+ 2:argb, 3:abgr)
+ */
+ static const OGLFormat lcl_RGB24[] =
+ {
+ // 24 bit RGB
+ {3, GL_BGR, GL_UNSIGNED_BYTE},
+ {3, GL_RGB, GL_UNSIGNED_BYTE},
+ {3, GL_BGR, GL_UNSIGNED_BYTE},
+ {3, GL_RGB, GL_UNSIGNED_BYTE}
+ };
+
+#if defined(GL_VERSION_1_2) && defined(GLU_VERSION_1_3)
+ // more format constants available
+ static const OGLFormat lcl_RGB16[] =
+ {
+ // 16 bit RGB
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5_REV},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5_REV},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5}
+ };
+
+ static const OGLFormat lcl_ARGB16_4[] =
+ {
+ // 16 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_4_4_4_4_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_4_4_4_4_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_4_4_4_4},
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_4_4_4_4}
+ };
+
+ static const OGLFormat lcl_ARGB16_5[] =
+ {
+ // 16 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_1_5_5_5_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_5_5_5_1},
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_5_5_5_1}
+ };
+
+ static const OGLFormat lcl_ARGB32[] =
+ {
+ // 32 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8_REV},
+ {4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV},
+ {4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8},
+ {4, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8}
+ };
+
+ const uno::Sequence<sal_Int8> aComponentTags(
+ xIntColorSpace->getComponentTags());
+ const uno::Sequence<sal_Int32> aComponentBitcounts(
+ xIntColorSpace->getComponentBitCounts());
+ const sal_Int32 nNumComponents( aComponentBitcounts.getLength() );
+ const sal_Int32 nBitsPerPixel( xIntColorSpace->getBitsPerPixel() );
+
+ // supported component ordering?
+ const int nComponentOrderIndex(
+ calcComponentOrderIndex(aComponentTags));
+ if( nComponentOrderIndex != -1 )
+ {
+ switch( nBitsPerPixel )
+ {
+ case 16:
+ if( nNumComponents == 3 )
+ {
+ pDetectedFormat = &lcl_RGB16[nComponentOrderIndex];
+ }
+ else if( nNumComponents == 4 )
+ {
+ if( aComponentBitcounts[1] == 4 )
+ {
+ pDetectedFormat = &lcl_ARGB16_4[nComponentOrderIndex];
+ }
+ else if( aComponentBitcounts[1] == 5 )
+ {
+ pDetectedFormat = &lcl_ARGB16_5[nComponentOrderIndex];
+ }
+ }
+ break;
+ case 24:
+ if( nNumComponents == 3 )
+ {
+ pDetectedFormat = &lcl_RGB24[nComponentOrderIndex];
+ }
+ break;
+ case 32:
+ pDetectedFormat = &lcl_ARGB32[nComponentOrderIndex];
+ break;
+ }
+ }
+#else
+ const uno::Sequence<sal_Int8> aComponentTags(
+ xIntColorSpace->getComponentTags());
+ const int nComponentOrderIndex(calcComponentOrderIndex(aComponentTags));
+ if( aComponentTags.getLength() == 3 &&
+ nComponentOrderIndex != -1 &&
+ xIntColorSpace->getBitsPerPixel() == 24 )
+ {
+ pDetectedFormat = &lcl_RGB24[nComponentOrderIndex];
+ }
+#endif
+ }
+
+ return pDetectedFormat;
+}
+
+void OGLTransitionerImpl::GLInitSlides()
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed() || pTransition->mnRequiredGLVersion > cnGLVersion)
+ return;
+
+ prepareEnvironment();
+
+ const OGLFormat* pFormat = NULL;
+ if( !mbUseLeavingPixmap || !mbUseEnteringPixmap )
+ pFormat = chooseFormats();
+
+ createTexture( &GLleavingSlide,
+ pTransition->mbUseMipMapLeaving,
+ LeavingBytes,
+ pFormat );
+
+ createTexture( &GLenteringSlide,
+
+ pTransition->mbUseMipMapEntering,
+ EnteringBytes,
+ pFormat );
+
+#ifdef DEBUG
+ t2 = microsec_clock::local_time();
+ OSL_TRACE("textures created in: %s", to_simple_string( t2 - t1 ).c_str());
+#endif
+}
+
+void SAL_CALL OGLTransitionerImpl::update( double nTime ) throw (uno::RuntimeException)
+{
+#ifdef DEBUG
+ frame_count ++;
+ t3 = microsec_clock::local_time();
+ if( frame_count == 1 ) {
+ t5 = t3;
+ total_update = seconds (0);
+ }
+#endif
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed() || !cbGLXPresent || pTransition->mnRequiredGLVersion > cnGLVersion)
+ return;
+
+ if(GLWin.pOpenGLContext)
+ [GLWin.pOpenGLContext makeCurrentContext];
+
+ glEnable(GL_DEPTH_TEST);
+ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+/*
+ if(pTransition)
+ pTransition->display( nTime, GLleavingSlide, GLenteringSlide,
+ SlideSize.Width, SlideSize.Height,
+ static_cast<double>(GLWin.Width),
+ static_cast<double>(GLWin.Height) );
+*/
+ // works but not mandatory
+#if defined(MAC_OS_X_VERSION_10_5)
+ long int swapInt = 1;
+#else /* build target 10.4 */
+ long swapInt = 1;
+#endif
+ [[GLWin.pAquaOpenGLView openGLContext] setValues:&swapInt forParameter:NSOpenGLCPSwapInterval]; // set to vbl sync
+
+ NSOpenGLContext* context = [GLWin.pAquaOpenGLView openGLContext];
+ [context makeCurrentContext];
+
+ if(pTransition)
+ pTransition->display( nTime, GLleavingSlide, GLenteringSlide,
+ SlideSize.Width, SlideSize.Height,
+ static_cast<double>(GLWin.Width),
+ static_cast<double>(GLWin.Height) );
+
+
+ [context flushBuffer];
+
+ if( pWindow )
+ pWindow->Show();
+
+#ifdef DEBUG
+ t4 = microsec_clock::local_time();
+
+ OSL_TRACE("update time: %f", nTime);
+ OSL_TRACE("update took: %s", to_simple_string( t4 - t3 ).c_str());
+ total_update += (t4 - t3);
+#endif
+}
+
+void SAL_CALL OGLTransitionerImpl::viewChanged( const Reference< presentation::XSlideShowView >& rView,
+ const Reference< rendering::XBitmap >& rLeavingBitmap,
+ const Reference< rendering::XBitmap >& rEnteringBitmap )
+ throw (uno::RuntimeException)
+{
+ OSL_TRACE("transitioner: view changed");
+
+ disposeTextures();
+ disposeContextAndWindow();
+
+ initWindowFromSlideShowView( rView );
+
+ setSlides( rLeavingBitmap, rEnteringBitmap );
+}
+
+void OGLTransitionerImpl::disposeContextAndWindow()
+{
+ /*
+ if(GLWin.pOpenGLContext)
+ [GLWin.pOpenGLContext makeCurrentContext];
+ if( glGetError() != GL_NO_ERROR )
+ {
+ OSL_TRACE("glError: %s", (char *)gluErrorString(glGetError()));
+ if(GLWin.pOpenGLContext)
+ [GLWin.pOpenGLContext clearGLContext];
+ }
+*/
+ if(GLWin.pAquaOpenGLView)
+ {
+ [GLWin.pAquaOpenGLView clearGLContext];// currentContext]; //clearCurrentContext];
+ [GLWin.pAquaOpenGLView willRemoveSubview:GLWin.apView];
+ [GLWin.pAquaOpenGLView removeFromSuperview];
+ [GLWin.pAquaOpenGLView release];
+ }
+
+ if( pWindow )
+ {
+ delete pWindow;
+ pWindow = NULL;
+ GLWin.pAquaOpenGLView = nil;
+ }
+}
+
+void OGLTransitionerImpl::disposeTextures()
+{
+ if(GLWin.pOpenGLContext)
+ [GLWin.pOpenGLContext makeCurrentContext];
+
+ if( !mbUseLeavingPixmap )
+ {
+ glDeleteTextures(1,&GLleavingSlide);
+ GLleavingSlide = 0;
+ }
+
+ if( !mbUseEnteringPixmap )
+ {
+ glDeleteTextures(1,&GLenteringSlide);
+ GLleavingSlide = 0;
+ }
+
+ mbUseLeavingPixmap = false;
+ mbUseEnteringPixmap = false;
+}
+
+// we are about to be disposed (someone call dispose() on us)
+void OGLTransitionerImpl::disposing()
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+#ifdef DEBUG
+ OSL_TRACE("dispose %p\n", this);
+ if( frame_count ) {
+ t6 = microsec_clock::local_time();
+ time_duration duration = t6 - t5;
+ OSL_TRACE("whole transition (frames: %d) took: %s fps: %f time spent in updates: %s percentage of transition time: %f%%",
+ frame_count, to_simple_string( duration ).c_str(),
+ ((double)frame_count*1000000000.0)/duration.total_nanoseconds(),
+ to_simple_string( total_update ).c_str(),
+ 100*(((double)total_update.total_nanoseconds())/((double)duration.total_nanoseconds()))
+ );
+ }
+#endif
+
+ if( pWindow )
+ {
+ disposeTextures();
+
+ if (pTransition)
+ pTransition->finish();
+
+ disposeContextAndWindow();
+ }
+
+ if (pTransition)
+ delete pTransition;
+
+ mxLeavingBitmap.clear();
+ mxEnteringBitmap.clear();
+ mxView.clear();
+}
+
+OGLTransitionerImpl::OGLTransitionerImpl(OGLTransitionImpl* pOGLTransition) :
+ OGLTransitionerImplBase(m_aMutex),
+ GLWin(),
+ GLleavingSlide( 0 ),
+ GLenteringSlide( 0 ),
+ pWindow( NULL ),
+ mxView(),
+ EnteringBytes(),
+ LeavingBytes(),
+ mbRestoreSync( false ),
+ mbUseLeavingPixmap( false ),
+ mbUseEnteringPixmap( false ),
+ SlideBitmapLayout(),
+ SlideSize(),
+ pTransition(pOGLTransition)
+{
+ GLWin.pAquaOpenGLView = nil;
+ DBG(frame_count = 0);
+}
+
+typedef cppu::WeakComponentImplHelper1<presentation::XTransitionFactory> OGLTransitionFactoryImplBase;
+
+class OGLTransitionFactoryImpl : private cppu::BaseMutex, public OGLTransitionFactoryImplBase
+{
+public:
+ explicit OGLTransitionFactoryImpl( const uno::Reference< uno::XComponentContext >& ) :
+ OGLTransitionFactoryImplBase(m_aMutex)
+ {}
+
+ // XTransitionFactory
+ virtual ::sal_Bool SAL_CALL hasTransition( ::sal_Int16 transitionType, ::sal_Int16 transitionSubType ) throw (uno::RuntimeException)
+ {
+ if( transitionType == animations::TransitionType::MISCSHAPEWIPE ) {
+ switch( transitionSubType )
+ {
+ case animations::TransitionSubType::ACROSS:
+ case animations::TransitionSubType::CORNERSOUT:
+ case animations::TransitionSubType::CIRCLE:
+ case animations::TransitionSubType::FANOUTHORIZONTAL:
+ case animations::TransitionSubType::CORNERSIN:
+ case animations::TransitionSubType::LEFTTORIGHT:
+ case animations::TransitionSubType::TOPTOBOTTOM:
+ case animations::TransitionSubType::TOPRIGHT:
+ case animations::TransitionSubType::TOPLEFT:
+ case animations::TransitionSubType::BOTTOMRIGHT:
+ case animations::TransitionSubType::BOTTOMLEFT:
+ case animations::TransitionSubType::TOPCENTER:
+ case animations::TransitionSubType::RIGHTCENTER:
+ case animations::TransitionSubType::BOTTOMCENTER:
+ return sal_True;
+
+ default:
+ return sal_False;
+ }
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::ZOOM && transitionSubType == animations::TransitionSubType::ROTATEIN ) {
+ return sal_True;
+ } else
+ return sal_False;
+ }
+
+ virtual uno::Reference< presentation::XTransition > SAL_CALL createTransition(
+ ::sal_Int16 transitionType,
+ ::sal_Int16 transitionSubType,
+ const uno::Reference< presentation::XSlideShowView >& view,
+ const uno::Reference< rendering::XBitmap >& leavingBitmap,
+ const uno::Reference< rendering::XBitmap >& enteringBitmap )
+ throw (uno::RuntimeException)
+ {
+ if( !hasTransition( transitionType, transitionSubType ) )
+ return uno::Reference< presentation::XTransition >();
+
+ bool bGLXPresent = OGLTransitionerImpl::initialize( view );
+
+ if(
+ ( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) ||
+ ( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) ||
+ ( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) )
+ return uno::Reference< presentation::XTransition >();
+
+
+ OGLTransitionImpl* pTransition = NULL;
+
+ if( transitionType == animations::TransitionType::MISCSHAPEWIPE ) {
+ pTransition = new OGLTransitionImpl();
+ switch( transitionSubType )
+ {
+ case animations::TransitionSubType::ACROSS:
+ pTransition->makeNByMTileFlip(8,6);
+ break;
+ case animations::TransitionSubType::CORNERSOUT:
+ pTransition->makeOutsideCubeFaceToLeft();
+ break;
+ case animations::TransitionSubType::CIRCLE:
+ pTransition->makeRevolvingCircles(8,128);
+ break;
+ case animations::TransitionSubType::FANOUTHORIZONTAL:
+ pTransition->makeHelix(20);
+ break;
+ case animations::TransitionSubType::CORNERSIN:
+ pTransition->makeInsideCubeFaceToLeft();
+ break;
+ case animations::TransitionSubType::LEFTTORIGHT:
+ pTransition->makeFallLeaving();
+ break;
+ case animations::TransitionSubType::TOPTOBOTTOM:
+ pTransition->makeTurnAround();
+ break;
+ case animations::TransitionSubType::TOPRIGHT:
+ pTransition->makeTurnDown();
+ break;
+ case animations::TransitionSubType::TOPLEFT:
+ pTransition->makeIris();
+ break;
+ case animations::TransitionSubType::BOTTOMRIGHT:
+ pTransition->makeRochade();
+ break;
+ case animations::TransitionSubType::BOTTOMLEFT:
+ pTransition->makeVenetianBlinds( true, 8 );
+ break;
+ case animations::TransitionSubType::TOPCENTER:
+ pTransition->makeVenetianBlinds( false, 6 );
+ break;
+ case animations::TransitionSubType::RIGHTCENTER:
+ pTransition->makeStatic();
+ break;
+ case animations::TransitionSubType::BOTTOMCENTER:
+ pTransition->makeDissolve();
+ break;
+ }
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeFadeSmoothly();
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeFadeThroughBlack();
+ } else if( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeDiamond();
+ } else if( transitionType == animations::TransitionType::ZOOM && transitionSubType == animations::TransitionSubType::ROTATEIN ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeNewsflash();
+ }
+
+ rtl::Reference<OGLTransitionerImpl> xRes(
+ new OGLTransitionerImpl(pTransition) );
+ if( bGLXPresent ) {
+ if( !xRes->initWindowFromSlideShowView(view))
+ return uno::Reference< presentation::XTransition >();
+ xRes->setSlides(leavingBitmap,enteringBitmap);
+ }
+
+ return uno::Reference<presentation::XTransition>(xRes.get());
+ }
+};
+
+}
+
+namespace sdecl = comphelper::service_decl;
+#if defined (__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ <= 3)
+ sdecl::class_<OGLTransitionFactoryImpl> serviceImpl;
+ const sdecl::ServiceDecl OGLTransitionFactoryDecl(
+ serviceImpl,
+#else
+ const sdecl::ServiceDecl OGLTransitionFactoryDecl(
+ sdecl::class_<OGLTransitionFactoryImpl>(),
+#endif
+ "com.sun.star.comp.presentation.OGLTransitionFactory",
+ "com.sun.star.presentation.TransitionFactory" );
+
+// The C shared lib entry points
+COMPHELPER_SERVICEDECL_EXPORTS1(OGLTransitionFactoryDecl)
diff --git a/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.h b/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.h
new file mode 100644
index 000000000..52f14b52d
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.h
@@ -0,0 +1,39 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * aquaOpenGLView.h
+ */
+
+@class NSOpenGLContext, NSOpenGLPixelFormat;
+
+// the most interesting is there : in OGLTrans, we use an NSView*
+// and subclass the NSView to create an OpenGLView does the trick
+
+@interface AquaOpenGLView : NSView
+{
+ @private
+ NSOpenGLContext* _openGLContext;
+ NSOpenGLPixelFormat* _pixelFormat;
+}
+
++ (NSOpenGLPixelFormat*)defaultPixelFormat;
+
+- (id)initWithFrame:(NSRect)frameRect pixelFormat:(NSOpenGLPixelFormat*)format;
+- (void)dealloc;
+- (void)setOpenGLContext:(NSOpenGLContext*)context;
+- (NSOpenGLContext*)openGLContext;
+- (void)clearGLContext;
+- (void)prepareOpenGL;
+- (BOOL)isOpaque;
+- (void)drawRect;
+- (void)lockFocus;
+- (void)update; // moved or resized
+// reshape is not supported, update bounds in drawRect
+- (void) _surfaceNeedsUpdate:(NSNotification*)notification;
+- (void)setPixelFormat:(NSOpenGLPixelFormat*)pixelFormat;
+- (NSOpenGLPixelFormat*)pixelFormat;
+- (void)encodeWithCoder:(NSCoder *)coder;
+- (id)initWithCoder:(NSCoder *)coder;
+
+@end
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.m b/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.m
new file mode 100644
index 000000000..b2c22c0bc
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/mac/aquaOpenGLView.m
@@ -0,0 +1,195 @@
+/*
+ * aquaOpenGLView.m
+ */
+
+#include <Cocoa/Cocoa.h>
+#include <OpenGL/OpenGL.h>
+#include <OpenGL/gl.h>
+
+#include "aquaOpenGLView.h"
+
+@implementation AquaOpenGLView
+
++ (NSOpenGLPixelFormat*)defaultPixelFormat
+{
+// first simple implementation (let's see later with more complex )
+ NSOpenGLPixelFormatAttribute attributes [] =
+ {
+ NSOpenGLPFAWindow,
+ NSOpenGLPFADoubleBuffer, // double buffered
+ NSOpenGLPFADepthSize, (NSOpenGLPixelFormatAttribute)16, // 16 bit depth buffer
+ (NSOpenGLPixelFormatAttribute)nil
+ };
+ return [[[NSOpenGLPixelFormat alloc] initWithAttributes:attributes] autorelease];
+}
+
+- (id)initWithFrame:(NSRect)frameRect pixelFormat:(NSOpenGLPixelFormat*)format
+{
+ self = [super initWithFrame:frameRect];
+ if (self != nil) {
+ _pixelFormat = [format retain];
+ }
+ [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(_surfaceNeedsUpdate:) name:NSViewGlobalFrameDidChangeNotification object:self];
+ return self;
+}
+
+- (void)dealloc
+{ // get rid of the context and pixel format
+ [[NSNotificationCenter defaultCenter] removeObserver:self name:NSViewGlobalFrameDidChangeNotification object:self];
+ [self clearGLContext];
+ if (_pixelFormat)
+ [_pixelFormat release];
+
+ [super dealloc];
+}
+
+- (void)setOpenGLContext:(NSOpenGLContext*)context
+{
+ [self clearGLContext];
+ _openGLContext = [context retain];
+}
+
+- (NSOpenGLContext*)openGLContext
+{ // create a context the first time through
+ if (_openGLContext == NULL) {
+ _openGLContext = [[NSOpenGLContext alloc] initWithFormat:_pixelFormat != nil ? _pixelFormat : [[self class] defaultPixelFormat] shareContext:nil];
+ [_openGLContext makeCurrentContext];
+ [self prepareOpenGL]; // call to initialize OpenGL state here
+ }
+ return _openGLContext;
+}
+
+- (void)clearGLContext
+{
+ if (_openGLContext != nil) {
+ if ([_openGLContext view] == self) {
+ [_openGLContext clearDrawable];
+ }
+ [_openGLContext release];
+ _openGLContext = nil;
+ }
+}
+
+- (void)prepareOpenGL
+{
+ // for overriding to initialize OpenGL state, occurs after context creation
+#ifdef MAC_OS_X_VERSION_10_4
+ long swapInt = 1;
+#else /* build target 10.5 */
+ int swapInt = 1;
+#endif
+
+ [[self openGLContext] setValues:&swapInt forParameter:NSOpenGLCPSwapInterval]; // set to vbl sync
+
+ // init GL stuff here
+ // FIXME: why is there garbage using prepareOpenGL ,
+ // but NOT, wen using the same content,
+ // directly in the OGLTrans instance ?
+ glShadeModel( GL_SMOOTH );
+ glEnable(GL_CULL_FACE);
+ glCullFace(GL_BACK);
+ glClearColor (0.0f, 0.0f, 0.0f, 0.0f); // R G B A
+ glClear(GL_COLOR_BUFFER_BIT);
+ glClearDepth( 1.0f );
+ glEnable( GL_DEPTH_TEST );
+ glDepthFunc( GL_LEQUAL );
+ glHint( GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST );
+ glEnable(GL_TEXTURE_2D);
+
+
+ glEnable(GL_LIGHTING);
+ GLfloat light_direction[] = { 0.0 , 0.0 , 1.0 };
+ GLfloat materialDiffuse[] = { 1.0 , 1.0 , 1.0 , 1.0};
+ glLightfv(GL_LIGHT0, GL_SPOT_DIRECTION, light_direction);
+ glMaterialfv(GL_FRONT,GL_DIFFUSE,materialDiffuse);
+ glEnable(GL_LIGHT0);
+ glEnable(GL_NORMALIZE);
+
+ [[self openGLContext] flushBuffer];
+}
+
+- (BOOL)isOpaque
+{
+ return YES;
+}
+
+- (void)drawRect
+{
+ // get context. will create if we don't have one yet
+ NSOpenGLContext* context = [self openGLContext];
+ [context makeCurrentContext];
+ //perform drawing here
+ [context flushBuffer];
+}
+
+- (void)lockFocus
+{
+ // get context. will create if we don't have one yet
+ NSOpenGLContext* context = [self openGLContext];
+
+ // make sure we are ready to draw
+ [super lockFocus];
+
+ // when we are about to draw, make sure we are linked to the view
+ if ([context view] != self) {
+ [context setView:self];
+ }
+
+ // make us the current OpenGL context
+ [context makeCurrentContext];
+}
+
+// no reshape will be called since NSView does not export a specific reshape method
+
+- (void)update
+{
+ if ([_openGLContext view] == self) {
+ [_openGLContext update];
+ }
+}
+
+- (void) _surfaceNeedsUpdate:(NSNotification*)notification
+{
+ [self update];
+}
+
+- (void)setPixelFormat:(NSOpenGLPixelFormat*)pixelFormat
+{
+ [_pixelFormat release];
+ _pixelFormat = [pixelFormat retain];
+}
+
+- (NSOpenGLPixelFormat*)pixelFormat
+{
+ return _pixelFormat;
+}
+
+
+- (void)encodeWithCoder:(NSCoder *)coder
+{
+
+ [super encodeWithCoder:coder];
+ if (![coder allowsKeyedCoding]) {
+ [coder encodeValuesOfObjCTypes:"@iii", &_pixelFormat];
+ } else {
+ [coder encodeObject:_pixelFormat forKey:@"NSPixelFormat"];
+ }
+}
+
+- (id)initWithCoder:(NSCoder *)coder
+{
+
+ self = [super initWithCoder:coder];
+
+ if (![coder allowsKeyedCoding]) {
+ [coder decodeValuesOfObjCTypes:"@iii", &_pixelFormat];
+ } else {
+ _pixelFormat = [[coder decodeObjectForKey:@"NSPixelFormat"] retain];
+ }
+
+ [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(_surfaceNeedsUpdate:) name:NSViewGlobalFrameDidChangeNotification object:self];
+
+ return self;
+}
+
+@end
diff --git a/slideshow/source/engine/OGLTrans/makefile.mk b/slideshow/source/engine/OGLTrans/makefile.mk
deleted file mode 100644
index 46d40b3e6..000000000
--- a/slideshow/source/engine/OGLTrans/makefile.mk
+++ /dev/null
@@ -1,88 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=OGLTrans
-TARGETTYPE=GUI
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Nothing to do if we're compiling with --disable-opengl -----------
-.IF "$(ENABLE_OPENGL)" != "TRUE"
-@all:
- @echo "Building without OpenGL Transitions..."
-.ENDIF
-
-# --- Common ----------------------------------------------------------
-#.IF "$(GUI)"=="UNX"
-
-SLOFILES = \
- $(SLO)$/OGLTrans_TransitionImpl.obj \
- $(SLO)$/OGLTrans_Shaders.obj \
- $(SLO)$/OGLTrans_TransitionerImpl.obj
-
-DLLPRE=
-SHL1TARGET=$(TARGET).uno
-
-.IF "$(GUI)"=="UNX"
-.IF "$(GUIBASE)"=="aqua"
- SHL1STDLIBS= $(SALLIB) $(VCLLIB) $(CPPULIB) $(CPPUHELPERLIB) $(COMPHELPERLIB) $(CANVASTOOLSLIB)
- CFLAGSCXX+=$(OBJCXXFLAGS)
-.ELSE
- SHL1STDLIBS= $(SALLIB) $(VCLLIB) $(CPPULIB) $(CPPUHELPERLIB) $(COMPHELPERLIB) $(CANVASTOOLSLIB) -lGL -lGLU -lX11
-.ENDIF
-.ELSE
- SHL1STDLIBS= $(SALLIB) $(VCLLIB) $(CPPULIB) $(CPPUHELPERLIB) $(COMPHELPERLIB) $(CANVASTOOLSLIB) opengl32.lib glu32.lib gdi32.lib
-.ENDIF
-SHL1IMPLIB=i$(TARGET)
-SHL1LIBS=$(SLB)$/$(TARGET).lib
-SHL1DEF=$(MISC)$/$(SHL1TARGET).def
-
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-
-DEF1NAME=$(SHL1TARGET)
-DEF1EXPORTFILE=exports.dxp
-
-#.ENDIF
-
-# ==========================================================================
-
-.INCLUDE : target.mk
-
-ALLTAR : $(MISC)/ogltrans.component
-
-$(MISC)/ogltrans.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- ogltrans.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt ogltrans.component
diff --git a/slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.cxx b/slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.cxx
new file mode 100644
index 000000000..c1beae123
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.cxx
@@ -0,0 +1,142 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <osl/diagnose.hxx>
+
+#include "OGLTrans_Shaders.hxx"
+
+namespace unx
+{
+#include <GL/glx.h>
+#include <GL/glxext.h>
+}
+
+bool OGLShaders::cbInitialized = false;
+
+#ifdef GL_VERSION_2_0
+
+PFNGLCREATESHADERPROC OGLShaders::glCreateShader = NULL;
+PFNGLSHADERSOURCEPROC OGLShaders::glShaderSource = NULL;
+PFNGLCOMPILESHADERPROC OGLShaders::glCompileShader = NULL;
+PFNGLGETSHADERIVPROC OGLShaders::glGetShaderiv = NULL;
+PFNGLGETSHADERINFOLOGPROC OGLShaders::glGetShaderInfoLog = NULL;
+PFNGLDELETESHADERPROC OGLShaders::glDeleteShader = NULL;
+PFNGLCREATEPROGRAMPROC OGLShaders::glCreateProgram = NULL;
+PFNGLATTACHSHADERPROC OGLShaders::glAttachShader = NULL;
+PFNGLLINKPROGRAMPROC OGLShaders::glLinkProgram = NULL;
+PFNGLGETPROGRAMIVPROC OGLShaders::glGetProgramiv = NULL;
+PFNGLGETPROGRAMINFOLOGPROC OGLShaders::glGetProgramInfoLog = NULL;
+PFNGLUSEPROGRAMPROC OGLShaders::glUseProgram = NULL;
+PFNGLDELETEPROGRAMPROC OGLShaders::glDeleteProgram = NULL;
+PFNGLGETUNIFORMLOCATIONPROC OGLShaders::glGetUniformLocation = NULL;
+PFNGLUNIFORM1IPROC OGLShaders::glUniform1i = NULL;
+PFNGLUNIFORM1FPROC OGLShaders::glUniform1f = NULL;
+#endif
+
+bool OGLShaders::Initialize()
+{
+#ifdef GL_VERSION_2_0
+ if( !cbInitialized ) {
+ glCreateShader = (PFNGLCREATESHADERPROC) unx::glXGetProcAddress( (unsigned char *) "glCreateShader" );
+ glShaderSource = (PFNGLSHADERSOURCEPROC) unx::glXGetProcAddress( (unsigned char *) "glShaderSource" );
+ glCompileShader = (PFNGLCOMPILESHADERPROC) unx::glXGetProcAddress( (unsigned char *) "glCompileShader" );
+ glGetShaderiv = (PFNGLGETSHADERIVPROC) unx::glXGetProcAddress( (unsigned char *) "glGetShaderiv" );
+ glGetShaderInfoLog = (PFNGLGETSHADERINFOLOGPROC) unx::glXGetProcAddress( (unsigned char *) "glGetShaderInfoLog" );
+ glDeleteShader = (PFNGLDELETESHADERPROC) unx::glXGetProcAddress( (unsigned char *) "glDeleteShader" );
+ glCreateProgram = (PFNGLCREATEPROGRAMPROC) unx::glXGetProcAddress( (unsigned char *) "glCreateProgram" );
+ glAttachShader = (PFNGLATTACHSHADERPROC) unx::glXGetProcAddress( (unsigned char *) "glAttachShader" );
+ glLinkProgram = (PFNGLLINKPROGRAMPROC) unx::glXGetProcAddress( (unsigned char *) "glLinkProgram" );
+ glGetProgramiv = (PFNGLGETPROGRAMIVPROC) unx::glXGetProcAddress( (unsigned char *) "glGetProgramiv" );
+ glGetProgramInfoLog = (PFNGLGETPROGRAMINFOLOGPROC) unx::glXGetProcAddress( (unsigned char *) "glGetProgramInfoLog" );
+ glUseProgram = (PFNGLUSEPROGRAMPROC) unx::glXGetProcAddress( (unsigned char *) "glUseProgram" );
+ glDeleteProgram = (PFNGLDELETEPROGRAMPROC) unx::glXGetProcAddress( (unsigned char *) "glDeleteProgram" );
+ glGetUniformLocation = (PFNGLGETUNIFORMLOCATIONPROC) unx::glXGetProcAddress( (unsigned char *) "glGetUniformLocation" );
+ glUniform1i = (PFNGLUNIFORM1IPROC) unx::glXGetProcAddress( (unsigned char *) "glUniform1i" );
+ glUniform1f = (PFNGLUNIFORM1FPROC) unx::glXGetProcAddress( (unsigned char *) "glUniform1f" );
+ cbInitialized = true;
+ }
+
+ return glCreateShader != NULL;
+#else
+ return false;
+#endif
+}
+
+GLuint OGLShaders::LinkProgram( const char *vertexShader, const char *fragmentShader )
+{
+#ifdef GL_VERSION_2_0
+ if( !Initialize() )
+ return 0;
+
+ GLhandleARB vertexObject, fragmentObject, programObject;
+ GLint vertexCompiled, fragmentCompiled, programLinked;
+ char log[1024];
+
+ vertexObject = glCreateShader( GL_VERTEX_SHADER );
+ fragmentObject = glCreateShader( GL_FRAGMENT_SHADER );
+ OSL_TRACE("checkpoint 1: shaders created (%d) vertex: %d fragment: %d", glGetError() == GL_NO_ERROR, vertexObject, fragmentObject );
+
+
+ glShaderSource( vertexObject, 1, &vertexShader, NULL );
+ glShaderSource( fragmentObject, 1, &fragmentShader, NULL );
+
+ glCompileShader( vertexObject );
+ glGetShaderInfoLog( vertexObject, sizeof( log ), NULL, log );
+ OSL_TRACE("vertex compile log: %s", log);
+ glGetShaderiv( vertexObject, GL_COMPILE_STATUS, &vertexCompiled );
+ glCompileShader( fragmentObject );
+ glGetShaderInfoLog( fragmentObject, sizeof( log ), NULL, log );
+ OSL_TRACE("fragment compile log: %s", log);
+ glGetShaderiv( fragmentObject, GL_COMPILE_STATUS, &fragmentCompiled );
+
+ if( !vertexCompiled || !fragmentCompiled )
+ return 0;
+
+ OSL_TRACE("checkpoint 2: shaders compiled (%d)", glGetError() == GL_NO_ERROR);
+
+ programObject = glCreateProgram();
+ glAttachShader( programObject, vertexObject );
+ glAttachShader( programObject, fragmentObject );
+
+ glLinkProgram( programObject );
+ glGetProgramInfoLog( programObject, sizeof( log ), NULL, log );
+ OSL_TRACE("program link log: %s", log);
+ glGetProgramiv( programObject, GL_LINK_STATUS, &programLinked );
+
+ if( !programLinked )
+ return 0;
+
+ OSL_TRACE("checkpoint 3: program linked (%d)", glGetError() == GL_NO_ERROR);
+
+ return programObject;
+#else
+ return 0;
+#endif
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/OGLTrans_Shaders.hxx b/slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.hxx
index 1586e9ef7..045b9ff8d 100644
--- a/slideshow/source/engine/OGLTrans/OGLTrans_Shaders.hxx
+++ b/slideshow/source/engine/OGLTrans/unx/OGLTrans_Shaders.hxx
@@ -1,8 +1,9 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
- * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2008 by Sun Microsystems, Inc.
*
* OpenOffice.org - a multi-platform office productivity suite
*
@@ -66,3 +67,5 @@ public:
};
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.cxx b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.cxx
index 722920d99..a0f647af9 100644
--- a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.cxx
+++ b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.cxx
@@ -1,8 +1,9 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
- * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2008 by Sun Microsystems, Inc.
*
* OpenOffice.org - a multi-platform office productivity suite
*
@@ -401,7 +402,7 @@ void OGLTransitionImpl::makeIris()
Primitive irisPart, part;
int i, nSteps = 24, nParts = 7;
- double lt = 0, t = 1.0/nSteps, cx, cy, lcx, lcy, lx = 1, ly = 0, x, y, cxo, cyo, lcxo, lcyo, of=2.2, f=1.42;
+ double t = 1.0/nSteps, cx, cy, lcx, lcy, lx = 1, ly = 0, x, y, cxo, cyo, lcxo, lcyo, of=2.2, f=1.42;
for (i=1; i<=nSteps; i++) {
x = cos ((3*2*M_PI*t)/nParts);
@@ -422,7 +423,6 @@ void OGLTransitionImpl::makeIris()
basegfx::B2DVector (cxo, cyo));
lx = x;
ly = y;
- lt = t;
t += 1.0/nSteps;
}
@@ -495,9 +495,6 @@ void OGLTransitionImpl::makeRochade()
Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), 45, false, -1, 0));
maEnteringSlidePrimitives.push_back(Slide);
- // OverallOperations.push_back(new SEllipseTranslate(0.5, 2, 0, 1, true, 0, 1));
-// push_back(new STranslate(basegfx::B3DVector(0, 0, -2), true, 0, 0.5));
-// OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, 2), true, 0.5, 1));
}
// TODO(Q3): extract to basegfx
@@ -556,7 +553,6 @@ void OGLTransitionImpl::makeRevolvingCircles( ::sal_uInt16 nCircles , ::sal_uInt
}
{
- //double angle(0.0);
Primitive EnteringSlide;
Primitive LeavingSlide;
for(int Point(0); Point + 1 < nPointsOnCircles; ++Point)
@@ -1313,3 +1309,4 @@ void OGLTransitionImpl::makeNewsflash()
OverallOperations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0.2,0.2,0),1080,true,0,1));
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.hxx b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.hxx
index f0e95f5b7..7a33fe078 100644
--- a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionImpl.hxx
+++ b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionImpl.hxx
@@ -1,8 +1,9 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
- * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2008 by Sun Microsystems, Inc.
*
* OpenOffice.org - a multi-platform office productivity suite
*
@@ -30,17 +31,6 @@
#include <basegfx/vector/b2dvector.hxx>
#include <basegfx/vector/b3dvector.hxx>
-#include <tools/prewin.h>
-#include <tools/postwin.h>
-
-#if defined( WNT )
-#include <tools/prewin.h>
-#include <tools/postwin.h>
-#elif defined( OS2 )
-#elif defined( QUARTZ )
-#elif defined( UNX )
-#endif
-
#include <vector>
#include <GL/gl.h>
@@ -504,3 +494,4 @@ private:
#endif // INCLUDED_SLIDESHOW_TRANSITION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl.cxx b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl.cxx
new file mode 100644
index 000000000..02a5e25f8
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl.cxx
@@ -0,0 +1,1482 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#define GLX_GLXEXT_PROTOTYPES 1
+#include "OGLTrans_TransitionImpl.hxx"
+
+#include <com/sun/star/beans/XFastPropertySet.hpp>
+#include <com/sun/star/rendering/IntegerBitmapLayout.hpp>
+#include <com/sun/star/rendering/ColorComponentTag.hpp>
+#include <com/sun/star/rendering/ColorSpaceType.hpp>
+#include <com/sun/star/animations/TransitionType.hpp>
+#include <com/sun/star/animations/TransitionSubType.hpp>
+#include <com/sun/star/presentation/XTransitionFactory.hpp>
+#include <com/sun/star/presentation/XTransition.hpp>
+#include <com/sun/star/presentation/XSlideShowView.hpp>
+#include <com/sun/star/uno/XComponentContext.hpp>
+#include <com/sun/star/rendering/XIntegerBitmap.hpp>
+#include <com/sun/star/geometry/IntegerSize2D.hpp>
+
+#include <cppuhelper/compbase1.hxx>
+#include <cppuhelper/basemutex.hxx>
+#include <cppuhelper/factory.hxx>
+#include <rtl/ref.hxx>
+
+#include <comphelper/servicedecl.hxx>
+
+#include <canvas/canvastools.hxx>
+#include <tools/gen.hxx>
+#include <vcl/window.hxx>
+#include <vcl/syschild.hxx>
+
+#include <boost/noncopyable.hpp>
+
+#include <GL/gl.h>
+#include <GL/glu.h>
+
+
+#if defined( WNT )
+ #define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
+ #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
+#elif defined( QUARTZ )
+ #include "premac.h"
+ #include <Cocoa/Cocoa.h>
+ #include "postmac.h"
+#elif defined( UNX )
+namespace unx
+{
+#include <X11/keysym.h>
+#include <X11/X.h>
+#include <GL/glx.h>
+#include <GL/glxext.h>
+}
+#endif
+#include <vcl/sysdata.hxx>
+
+#ifdef DEBUG
+#include <boost/date_time/posix_time/posix_time.hpp>
+using namespace ::boost::posix_time;
+
+static ptime t1;
+static ptime t2;
+
+#define DBG(x) x
+#else
+#define DBG(x)
+#endif
+
+using namespace ::com::sun::star;
+using ::com::sun::star::beans::XFastPropertySet;
+using ::com::sun::star::uno::Any;
+using ::com::sun::star::uno::Reference;
+using ::com::sun::star::uno::Sequence;
+using ::com::sun::star::uno::UNO_QUERY;
+using ::com::sun::star::uno::UNO_QUERY_THROW;
+
+namespace
+{
+
+typedef cppu::WeakComponentImplHelper1<presentation::XTransition> OGLTransitionerImplBase;
+
+namespace
+{
+ struct OGLFormat
+ {
+ GLint nInternalFormat;
+ GLenum eFormat;
+ GLenum eType;
+ };
+
+ /* channel ordering: (0:rgba, 1:bgra, 2:argb, 3:abgr)
+ */
+ int calcComponentOrderIndex(const uno::Sequence<sal_Int8>& rTags)
+ {
+ using namespace rendering::ColorComponentTag;
+
+ static const sal_Int8 aOrderTable[] =
+ {
+ RGB_RED, RGB_GREEN, RGB_BLUE, ALPHA,
+ RGB_BLUE, RGB_GREEN, RGB_RED, ALPHA,
+ ALPHA, RGB_RED, RGB_GREEN, RGB_BLUE,
+ ALPHA, RGB_BLUE, RGB_GREEN, RGB_RED,
+ };
+
+ const sal_Int32 nNumComps(rTags.getLength());
+ const sal_Int8* pLine=aOrderTable;
+ for(int i=0; i<4; ++i)
+ {
+ int j=0;
+ while( j<4 && j<nNumComps && pLine[j] == rTags[j] )
+ ++j;
+
+ // all of the line passed, this is a match!
+ if( j==nNumComps )
+ return i;
+
+ pLine+=4;
+ }
+
+ return -1;
+ }
+}
+
+// not thread safe
+static bool errorTriggered;
+int oglErrorHandler( unx::Display* /*dpy*/, unx::XErrorEvent* /*evnt*/ )
+{
+ errorTriggered = true;
+
+ return 0;
+}
+
+/** This is the Transitioner class for OpenGL 3D transitions in
+ * slideshow. At the moment, it's Linux only. This class is implicitly
+ * constructed from XTransitionFactory.
+*/
+class OGLTransitionerImpl : private cppu::BaseMutex, private boost::noncopyable, public OGLTransitionerImplBase
+{
+public:
+ explicit OGLTransitionerImpl(OGLTransitionImpl* pOGLTransition);
+ bool initWindowFromSlideShowView( const uno::Reference< presentation::XSlideShowView >& xView );
+ void setSlides( const Reference< rendering::XBitmap >& xLeavingSlide , const uno::Reference< rendering::XBitmap >& xEnteringSlide );
+ static bool initialize( const Reference< presentation::XSlideShowView >& xView );
+
+ // XTransition
+ virtual void SAL_CALL update( double nTime )
+ throw (uno::RuntimeException);
+ virtual void SAL_CALL viewChanged( const Reference< presentation::XSlideShowView >& rView,
+ const Reference< rendering::XBitmap >& rLeavingBitmap,
+ const Reference< rendering::XBitmap >& rEnteringBitmap )
+ throw (uno::RuntimeException);
+
+protected:
+ void disposeContextAndWindow();
+ void disposeTextures();
+
+ // WeakComponentImplHelperBase
+ virtual void SAL_CALL disposing();
+
+ bool isDisposed() const
+ {
+ return (rBHelper.bDisposed || rBHelper.bInDispose);
+ }
+
+ bool createWindow( Window* pPWindow );
+ void createTexture( unsigned int* texID,
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::GLXPixmap pixmap,
+ bool usePixmap,
+#endif
+ bool useMipmap,
+ uno::Sequence<sal_Int8>& data,
+ const OGLFormat* pFormat );
+ void prepareEnvironment ();
+ const OGLFormat* chooseFormats();
+
+private:
+ /** After the window has been created, and the slides have been set, we'll initialize the slides with OpenGL.
+ */
+ void GLInitSlides();
+
+
+ /// Holds the information of our new child window
+ struct GLWindow
+ {
+#if defined( WNT )
+ HWND hWnd;
+ HDC hDC;
+ HGLRC hRC;
+#elif defined( QUARTZ )
+#elif defined( UNX )
+ unx::Display* dpy;
+ int screen;
+ unx::Window win;
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::GLXFBConfig fbc;
+#endif
+ unx::XVisualInfo* vi;
+ unx::GLXContext ctx;
+#endif
+ unsigned int bpp;
+ unsigned int Width;
+ unsigned int Height;
+ const char* GLXExtensions;
+ const GLubyte* GLExtensions;
+
+ bool HasGLXExtension( const char* name ) { return gluCheckExtension( (const GLubyte*) name, (const GLubyte*) GLXExtensions ); }
+ bool HasGLExtension( const char* name ) { return gluCheckExtension( (const GLubyte*) name, GLExtensions ); }
+ } GLWin;
+
+ /** OpenGL handle to the leaving slide's texture
+ */
+ unsigned int GLleavingSlide;
+ /** OpenGL handle to the entering slide's texture
+ */
+ unsigned int GLenteringSlide;
+
+ /** pointer to our window which we MIGHT create.
+ */
+ class SystemChildWindow* pWindow;
+
+ Reference< presentation::XSlideShowView > mxView;
+ Reference< rendering::XIntegerBitmap > mxLeavingBitmap;
+ Reference< rendering::XIntegerBitmap > mxEnteringBitmap;
+
+ /** raw bytes of the entering bitmap
+ */
+ uno::Sequence<sal_Int8> EnteringBytes;
+
+ /** raw bytes of the leaving bitmap
+ */
+ uno::Sequence<sal_Int8> LeavingBytes;
+
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::GLXPixmap LeavingPixmap;
+ unx::GLXPixmap EnteringPixmap;
+#endif
+ bool mbRestoreSync;
+ bool mbUseLeavingPixmap;
+ bool mbUseEnteringPixmap;
+ bool mbFreeLeavingPixmap;
+ bool mbFreeEnteringPixmap;
+ unx::Pixmap maLeavingPixmap;
+ unx::Pixmap maEnteringPixmap;
+
+ /** the form the raw bytes are in for the bitmaps
+ */
+ rendering::IntegerBitmapLayout SlideBitmapLayout;
+
+ /** the size of the slides
+ */
+ geometry::IntegerSize2D SlideSize;
+
+ /** Our Transition to be used.
+ */
+ OGLTransitionImpl* pTransition;
+
+public:
+ /** whether we are running on ATI fglrx with bug related to textures
+ */
+ static bool cbBrokenTexturesATI;
+
+ /** GL version
+ */
+ static float cnGLVersion;
+ float mnGLXVersion;
+
+ /** Whether Mesa is the OpenGL vendor
+ */
+ static bool cbMesa;
+
+ /**
+ whether the display has GLX extension
+ */
+ static bool cbGLXPresent;
+
+ /**
+ whether texture from pixmap extension is available
+ */
+ bool mbTextureFromPixmap;
+
+ /**
+ whether to generate mipmaped textures
+ */
+ bool mbGenerateMipmap;
+
+ /**
+ whether we have visual which can be used for texture_from_pixmap extension
+ */
+ bool mbHasTFPVisual;
+
+#ifdef DEBUG
+ ptime t3;
+ ptime t4;
+ ptime t5;
+ ptime t6;
+ time_duration total_update;
+ int frame_count;
+#endif
+};
+
+// declare the static variables as some gcc versions have problems declaring them automaticaly
+bool OGLTransitionerImpl::cbBrokenTexturesATI;
+float OGLTransitionerImpl::cnGLVersion;
+bool OGLTransitionerImpl::cbMesa;
+bool OGLTransitionerImpl::cbGLXPresent;
+
+bool OGLTransitionerImpl::initialize( const Reference< presentation::XSlideShowView >& xView )
+{
+ // not thread safe
+ static bool initialized = false;
+
+ if( !initialized ) {
+ OGLTransitionerImpl *instance;
+
+ instance = new OGLTransitionerImpl( NULL );
+ if( instance->initWindowFromSlideShowView( xView ) ) {
+
+ const GLubyte* version = glGetString( GL_VERSION );
+ if( version && version[0] ) {
+ cnGLVersion = version[0] - '0';
+ if( version[1] == '.' && version[2] )
+ cnGLVersion += (version[2] - '0')/10.0;
+ } else
+ cnGLVersion = 1.0;
+ OSL_TRACE("GL version: %s parsed: %f", version, cnGLVersion );
+
+ const GLubyte* vendor = glGetString( GL_VENDOR );
+ cbMesa = ( vendor && strstr( (const char *) vendor, "Mesa" ) );
+ OSL_TRACE("GL vendor: %s identified as Mesa: %d", vendor, cbMesa );
+
+ /* TODO: check for version once the bug in fglrx driver is fixed */
+ cbBrokenTexturesATI = (vendor && strcmp( (const char *) vendor, "ATI Technologies Inc." ) == 0 );
+
+ instance->disposing();
+ cbGLXPresent = true;
+ } else
+ cbGLXPresent = false;
+
+ delete instance;
+ initialized = true;
+ }
+
+ return cbGLXPresent;
+}
+
+bool OGLTransitionerImpl::createWindow( Window* pPWindow )
+{
+ const SystemEnvData* sysData(pPWindow->GetSystemData());
+#if defined( WNT )
+ GLWin.hWnd = sysData->hWnd;
+#elif defined( UNX )
+ GLWin.dpy = reinterpret_cast<unx::Display*>(sysData->pDisplay);
+
+ if( unx::glXQueryExtension( GLWin.dpy, NULL, NULL ) == false )
+ return false;
+
+ GLWin.win = sysData->aWindow;
+
+ OSL_TRACE("parent window: %d", GLWin.win);
+
+ unx::XWindowAttributes xattr;
+ unx::XGetWindowAttributes( GLWin.dpy, GLWin.win, &xattr );
+
+ GLWin.screen = XScreenNumberOfScreen( xattr.screen );
+
+ unx::XVisualInfo* vi( NULL );
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::XVisualInfo* visinfo;
+ unx::XVisualInfo* firstVisual( NULL );
+#endif
+ static int attrList3[] =
+ {
+ GLX_RGBA,//only TrueColor or DirectColor
+ //single buffered
+ GLX_RED_SIZE,4,//use the maximum red bits, with a minimum of 4 bits
+ GLX_GREEN_SIZE,4,//use the maximum green bits, with a minimum of 4 bits
+ GLX_BLUE_SIZE,4,//use the maximum blue bits, with a minimum of 4 bits
+ GLX_DEPTH_SIZE,0,//no depth buffer
+ None
+ };
+ static int attrList2[] =
+ {
+ GLX_RGBA,//only TrueColor or DirectColor
+ /// single buffered
+ GLX_RED_SIZE,4,/// use the maximum red bits, with a minimum of 4 bits
+ GLX_GREEN_SIZE,4,/// use the maximum green bits, with a minimum of 4 bits
+ GLX_BLUE_SIZE,4,/// use the maximum blue bits, with a minimum of 4 bits
+ GLX_DEPTH_SIZE,1,/// use the maximum depth bits, making sure there is a depth buffer
+ None
+ };
+ static int attrList1[] =
+ {
+ GLX_RGBA,//only TrueColor or DirectColor
+ GLX_DOUBLEBUFFER,/// only double buffer
+ GLX_RED_SIZE,4,/// use the maximum red bits, with a minimum of 4 bits
+ GLX_GREEN_SIZE,4,/// use the maximum green bits, with a minimum of 4 bits
+ GLX_BLUE_SIZE,4,/// use the maximum blue bits, with a minimum of 4 bits
+ GLX_DEPTH_SIZE,0,/// no depth buffer
+ None
+ };
+ static int attrList0[] =
+ {
+ GLX_RGBA,//only TrueColor or DirectColor
+ GLX_DOUBLEBUFFER,/// only double buffer
+ GLX_RED_SIZE,4,/// use the maximum red bits, with a minimum of 4 bits
+ GLX_GREEN_SIZE,4,/// use the maximum green bits, with a minimum of 4 bits
+ GLX_BLUE_SIZE,4,/// use the maximum blue bits, with a minimum of 4 bits
+ GLX_DEPTH_SIZE,1,/// use the maximum depth bits, making sure there is a depth buffer
+ None
+ };
+ static int* attrTable[] =
+ {
+ attrList0,
+ attrList1,
+ attrList2,
+ attrList3,
+ NULL
+ };
+ int** pAttributeTable = attrTable;
+ const SystemEnvData* pChildSysData = NULL;
+ delete pWindow;
+ pWindow=NULL;
+
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::GLXFBConfig* fbconfigs = NULL;
+ int nfbconfigs, value, i = 0;
+#endif
+
+ while( *pAttributeTable )
+ {
+ // try to find a visual for the current set of attributes
+ vi = unx::glXChooseVisual( GLWin.dpy,
+ GLWin.screen,
+ *pAttributeTable );
+
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ if( vi ) {
+ if( !firstVisual )
+ firstVisual = vi;
+ OSL_TRACE("trying VisualID %08X", vi->visualid);
+ fbconfigs = glXGetFBConfigs (GLWin.dpy, GLWin.screen, &nfbconfigs);
+ for ( ; i < nfbconfigs; i++)
+ {
+ visinfo = glXGetVisualFromFBConfig (GLWin.dpy, fbconfigs[i]);
+ if( !visinfo || visinfo->visualid != vi->visualid )
+ continue;
+
+ glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i], GLX_DRAWABLE_TYPE, &value);
+ if (!(value & GLX_PIXMAP_BIT))
+ continue;
+
+ glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i],
+ GLX_BIND_TO_TEXTURE_TARGETS_EXT,
+ &value);
+ if (!(value & GLX_TEXTURE_2D_BIT_EXT))
+ continue;
+
+ glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i],
+ GLX_BIND_TO_TEXTURE_RGB_EXT,
+ &value);
+ if (value == sal_False)
+ continue;
+
+ glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i],
+ GLX_BIND_TO_MIPMAP_TEXTURE_EXT,
+ &value);
+ if (value == sal_False)
+ continue;
+
+ /* TODO: handle non Y inverted cases */
+ break;
+ }
+
+ if( i != nfbconfigs || ( firstVisual && pAttributeTable[1] == NULL ) ) {
+ if( i != nfbconfigs ) {
+ vi = glXGetVisualFromFBConfig( GLWin.dpy, fbconfigs[i] );
+ mbHasTFPVisual = true;
+ OSL_TRACE("found visual suitable for texture_from_pixmap");
+ } else {
+ vi = firstVisual;
+ mbHasTFPVisual = false;
+ OSL_TRACE("did not find visual suitable for texture_from_pixmap, using %08X", vi->visualid);
+ }
+#else
+ if( vi ) {
+#endif
+ SystemWindowData winData;
+ winData.nSize = sizeof(winData);
+ OSL_TRACE("using VisualID %08X", vi->visualid);
+ winData.pVisual = (void*)(vi->visual);
+ pWindow=new SystemChildWindow(pPWindow, 0, &winData, sal_False);
+ pChildSysData = pWindow->GetSystemData();
+ if( pChildSysData ) {
+ break;
+ } else {
+ delete pWindow, pWindow=NULL;
+ }
+ }
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ }
+#endif
+
+ ++pAttributeTable;
+ }
+#endif
+
+#if defined( WNT )
+ const SystemEnvData* pChildSysData = NULL;
+ SystemWindowData winData;
+ winData.nSize = sizeof(winData);
+ pWindow=new SystemChildWindow(pPWindow, 0, &winData, sal_False);
+ pChildSysData = pWindow->GetSystemData();
+#endif
+
+ if( pWindow )
+ {
+ pWindow->SetMouseTransparent( sal_True );
+ pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP );
+ pWindow->EnableEraseBackground( sal_False );
+ pWindow->SetControlForeground();
+ pWindow->SetControlBackground();
+ pWindow->EnablePaint(sal_False);
+#if defined( WNT )
+ GLWin.hWnd = sysData->hWnd;
+#elif defined( UNX )
+ GLWin.dpy = reinterpret_cast<unx::Display*>(pChildSysData->pDisplay);
+ GLWin.win = pChildSysData->aWindow;
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ if( mbHasTFPVisual )
+ GLWin.fbc = fbconfigs[i];
+#endif
+ GLWin.vi = vi;
+ GLWin.GLXExtensions = unx::glXQueryExtensionsString( GLWin.dpy, GLWin.screen );
+ OSL_TRACE("available GLX extensions: %s", GLWin.GLXExtensions);
+#endif
+
+ return true;
+ }
+
+ return false;
+}
+
+bool OGLTransitionerImpl::initWindowFromSlideShowView( const Reference< presentation::XSlideShowView >& xView )
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed())
+ return false;
+
+ mxView.set( xView, UNO_QUERY );
+ if( !mxView.is() )
+ return false;
+
+ /// take the XSlideShowView and extract the parent window from it. see viewmediashape.cxx
+ uno::Reference< rendering::XCanvas > xCanvas(mxView->getCanvas(), uno::UNO_QUERY_THROW);
+ uno::Sequence< uno::Any > aDeviceParams;
+ ::canvas::tools::getDeviceInfo( xCanvas, aDeviceParams );
+
+ ::rtl::OUString aImplName;
+ aDeviceParams[ 0 ] >>= aImplName;
+
+ sal_Int64 aVal = 0;
+ aDeviceParams[1] >>= aVal;
+ if( !createWindow( reinterpret_cast< Window* >( aVal ) ) )
+ return false;
+
+ awt::Rectangle aCanvasArea = mxView->getCanvasArea();
+ pWindow->SetPosSizePixel(aCanvasArea.X, aCanvasArea.Y, aCanvasArea.Width, aCanvasArea.Height);
+ GLWin.Width = aCanvasArea.Width;
+ GLWin.Height = aCanvasArea.Height;
+ OSL_TRACE("canvas area: %d,%d - %dx%d", aCanvasArea.X, aCanvasArea.Y, aCanvasArea.Width, aCanvasArea.Height);
+
+#if defined( WNT )
+ GLWin.hDC = GetDC(GLWin.hWnd);
+#elif defined( UNX )
+ GLWin.ctx = glXCreateContext(GLWin.dpy,
+ GLWin.vi,
+ 0,
+ GL_TRUE);
+ if( GLWin.ctx == NULL ) {
+ OSL_TRACE("unable to create GLX context");
+ return false;
+ }
+#endif
+
+#if defined( WNT )
+ PIXELFORMATDESCRIPTOR PixelFormatFront = // PixelFormat Tells Windows How We Want Things To Be
+ {
+ sizeof(PIXELFORMATDESCRIPTOR),
+ 1, // Version Number
+ PFD_DRAW_TO_WINDOW |
+ PFD_SUPPORT_OPENGL |
+ PFD_DOUBLEBUFFER,
+ PFD_TYPE_RGBA, // Request An RGBA Format
+ (BYTE)32, // Select Our Color Depth
+ 0, 0, 0, 0, 0, 0, // Color Bits Ignored
+ 0, // No Alpha Buffer
+ 0, // Shift Bit Ignored
+ 0, // No Accumulation Buffer
+ 0, 0, 0, 0, // Accumulation Bits Ignored
+ 64, // 32 bit Z-BUFFER
+ 0, // 0 bit stencil buffer
+ 0, // No Auxiliary Buffer
+ 0, // now ignored
+ 0, // Reserved
+ 0, 0, 0 // Layer Masks Ignored
+ };
+ int WindowPix = ChoosePixelFormat(GLWin.hDC,&PixelFormatFront);
+ SetPixelFormat(GLWin.hDC,WindowPix,&PixelFormatFront);
+ GLWin.hRC = wglCreateContext(GLWin.hDC);
+ wglMakeCurrent(GLWin.hDC,GLWin.hRC);
+#elif defined( UNX )
+ if( !glXMakeCurrent( GLWin.dpy, GLWin.win, GLWin.ctx ) ) {
+ OSL_TRACE("unable to select current GLX context");
+ return false;
+ }
+
+ int glxMinor, glxMajor;
+ mnGLXVersion = 0;
+ if( glXQueryVersion( GLWin.dpy, &glxMajor, &glxMinor ) )
+ mnGLXVersion = glxMajor + 0.1*glxMinor;
+ OSL_TRACE("available GLX version: %f", mnGLXVersion);
+
+ GLWin.GLExtensions = glGetString( GL_EXTENSIONS );
+ OSL_TRACE("available GL extensions: %s", GLWin.GLExtensions);
+
+ mbTextureFromPixmap = GLWin.HasGLXExtension( "GLX_EXT_texture_from_pixmap" );
+ mbGenerateMipmap = GLWin.HasGLExtension( "GL_SGIS_generate_mipmap" );
+
+ if( GLWin.HasGLXExtension("GLX_SGI_swap_control" ) ) {
+ // enable vsync
+ typedef GLint (*glXSwapIntervalProc)(GLint);
+ glXSwapIntervalProc glXSwapInterval = (glXSwapIntervalProc) unx::glXGetProcAddress( (const GLubyte*) "glXSwapIntervalSGI" );
+ if( glXSwapInterval ) {
+ int (*oldHandler)(unx::Display* /*dpy*/, unx::XErrorEvent* /*evnt*/);
+
+ // replace error handler temporarily
+ oldHandler = unx::XSetErrorHandler( oglErrorHandler );
+
+ errorTriggered = false;
+
+ glXSwapInterval( 1 );
+
+ // sync so that we possibly get an XError
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+
+ if( errorTriggered )
+ OSL_TRACE("error when trying to set swap interval, NVIDIA or Mesa bug?");
+ else
+ OSL_TRACE("set swap interval to 1 (enable vsync)");
+
+ // restore the error handler
+ unx::XSetErrorHandler( oldHandler );
+ }
+ }
+#endif
+
+ glEnable(GL_CULL_FACE);
+ glCullFace(GL_BACK);
+ glClearColor (0, 0, 0, 0);
+ glClear(GL_COLOR_BUFFER_BIT);
+#if defined( WNT )
+ SwapBuffers(GLWin.hDC);
+#elif defined( UNX )
+ unx::glXSwapBuffers(GLWin.dpy, GLWin.win);
+#endif
+
+ glEnable(GL_LIGHTING);
+ GLfloat light_direction[] = { 0.0 , 0.0 , 1.0 };
+ GLfloat materialDiffuse[] = { 1.0 , 1.0 , 1.0 , 1.0};
+ glLightfv(GL_LIGHT0, GL_SPOT_DIRECTION, light_direction);
+ glMaterialfv(GL_FRONT,GL_DIFFUSE,materialDiffuse);
+ glEnable(GL_LIGHT0);
+ glEnable(GL_NORMALIZE);
+
+ if( LeavingBytes.hasElements() && EnteringBytes.hasElements())
+ GLInitSlides();//we already have uninitialized slides, let's initialize
+
+ if( pTransition && pTransition->mnRequiredGLVersion <= cnGLVersion )
+ pTransition->prepare( GLleavingSlide, GLenteringSlide );
+
+ return true;
+}
+
+void OGLTransitionerImpl::setSlides( const uno::Reference< rendering::XBitmap >& xLeavingSlide,
+ const uno::Reference< rendering::XBitmap >& xEnteringSlide )
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed())
+ return;
+
+ mxLeavingBitmap.set( xLeavingSlide , UNO_QUERY_THROW );
+ mxEnteringBitmap.set( xEnteringSlide , UNO_QUERY_THROW );
+ Reference< XFastPropertySet > xLeavingSet( xLeavingSlide , UNO_QUERY );
+ Reference< XFastPropertySet > xEnteringSet( xEnteringSlide , UNO_QUERY );
+
+ geometry::IntegerRectangle2D SlideRect;
+ SlideSize = mxLeavingBitmap->getSize();
+ SlideRect.X1 = 0;
+ SlideRect.X2 = SlideSize.Width;
+ SlideRect.Y1 = 0;
+ SlideRect.Y2 = SlideSize.Height;
+
+ OSL_TRACE("leaving bitmap area: %dx%d", SlideSize.Width, SlideSize.Height);
+ SlideSize = mxEnteringBitmap->getSize();
+ OSL_TRACE("entering bitmap area: %dx%d", SlideSize.Width, SlideSize.Height);
+
+#ifdef UNX
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+#endif
+
+#ifdef DEBUG
+ t1 = microsec_clock::local_time();
+#endif
+
+ mbUseLeavingPixmap = false;
+ mbUseEnteringPixmap = false;
+
+#ifdef UNX
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+
+ if( mnGLXVersion >= 1.2999 && mbTextureFromPixmap && xLeavingSet.is() && xEnteringSet.is() && mbHasTFPVisual ) {
+ Sequence< Any > leaveArgs;
+ Sequence< Any > enterArgs;
+ if( (xLeavingSet->getFastPropertyValue( 1 ) >>= leaveArgs) &&
+ (xEnteringSet->getFastPropertyValue( 1 ) >>= enterArgs) ) {
+ OSL_TRACE ("pixmaps available");
+
+ sal_Int32 depth(0);
+
+ leaveArgs[0] >>= mbFreeLeavingPixmap;
+ enterArgs[0] >>= mbFreeEnteringPixmap;
+ leaveArgs[1] >>= maLeavingPixmap;
+ enterArgs[1] >>= maEnteringPixmap;
+ leaveArgs[2] >>= depth;
+
+ int pixmapAttribs[] = { GLX_TEXTURE_TARGET_EXT, GLX_TEXTURE_2D_EXT,
+ GLX_TEXTURE_FORMAT_EXT, GLX_TEXTURE_FORMAT_RGB_EXT,
+ GLX_MIPMAP_TEXTURE_EXT, True,
+ None };
+
+
+ // sync so that we possibly get an pending XError, before we set our handler.
+ // this way we will not miss any error from other code
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+
+ int (*oldHandler)(unx::Display* /*dpy*/, unx::XErrorEvent* /*evnt*/);
+
+ // replace error handler temporarily
+ oldHandler = unx::XSetErrorHandler( oglErrorHandler );
+
+ errorTriggered = false;
+ LeavingPixmap = glXCreatePixmap( GLWin.dpy, GLWin.fbc, maLeavingPixmap, pixmapAttribs );
+
+ // sync so that we possibly get an XError
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+
+ if( !errorTriggered )
+ mbUseLeavingPixmap = true;
+ else {
+ OSL_TRACE("XError triggered");
+ if( mbFreeLeavingPixmap ) {
+ unx::XFreePixmap( GLWin.dpy, maLeavingPixmap );
+ mbFreeLeavingPixmap = false;
+ }
+ errorTriggered = false;
+ }
+
+ EnteringPixmap = glXCreatePixmap( GLWin.dpy, GLWin.fbc, maEnteringPixmap, pixmapAttribs );
+
+ // sync so that we possibly get an XError
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+
+ OSL_TRACE("created glx pixmap %p and %p depth: %d", LeavingPixmap, EnteringPixmap, depth);
+ if( !errorTriggered )
+ mbUseEnteringPixmap = true;
+ else {
+ OSL_TRACE("XError triggered");
+ if( mbFreeEnteringPixmap ) {
+ unx::XFreePixmap( GLWin.dpy, maEnteringPixmap );
+ mbFreeEnteringPixmap = false;
+ }
+ }
+
+ // restore the error handler
+ unx::XSetErrorHandler( oldHandler );
+ }
+ }
+
+#endif
+#endif
+ if( !mbUseLeavingPixmap )
+ LeavingBytes = mxLeavingBitmap->getData(SlideBitmapLayout,SlideRect);
+ if( !mbUseEnteringPixmap )
+ EnteringBytes = mxEnteringBitmap->getData(SlideBitmapLayout,SlideRect);
+
+// TODO
+#ifdef UNX
+ if(GLWin.ctx)//if we have a rendering context, let's init the slides
+#endif
+ GLInitSlides();
+
+ OSL_ENSURE(SlideBitmapLayout.PlaneStride == 0,"only handle no plane stride now");
+
+#ifdef UNX
+ /* flush & sync */
+ unx::glXWaitGL();
+ XSync( GLWin.dpy, false );
+
+ // synchronized X still gives us much smoother play
+ // I suspect some issues in above code in slideshow
+ // synchronize whole transition for now
+ XSynchronize( GLWin.dpy, true );
+ mbRestoreSync = true;
+#endif
+}
+
+void OGLTransitionerImpl::createTexture( unsigned int* texID,
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::GLXPixmap pixmap,
+ bool usePixmap,
+#endif
+ bool useMipmap,
+ uno::Sequence<sal_Int8>& data,
+ const OGLFormat* pFormat )
+{
+ glDeleteTextures( 1, texID );
+ glGenTextures( 1, texID );
+ glBindTexture( GL_TEXTURE_2D, *texID );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT );
+
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::PFNGLXBINDTEXIMAGEEXTPROC myglXBindTexImageEXT = (unx::PFNGLXBINDTEXIMAGEEXTPROC) unx::glXGetProcAddress( (const GLubyte*) "glXBindTexImageEXT" );
+
+ if( usePixmap ) {
+ if( mbGenerateMipmap )
+ glTexParameteri( GL_TEXTURE_2D, GL_GENERATE_MIPMAP_SGIS, True);
+ myglXBindTexImageEXT (GLWin.dpy, pixmap, GLX_FRONT_LEFT_EXT, NULL);
+ if( mbGenerateMipmap && useMipmap ) {
+ OSL_TRACE("use mipmaps");
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR); //TRILINEAR FILTERING
+ } else {
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST);
+ }
+ } else {
+#endif
+ if( !pFormat )
+ {
+ // force-convert color to ARGB8888 int color space
+ uno::Sequence<sal_Int8> tempBytes(
+ SlideBitmapLayout.ColorSpace->convertToIntegerColorSpace(
+ data,
+ canvas::tools::getStdColorSpace()));
+ gluBuild2DMipmaps(GL_TEXTURE_2D,
+ 4,
+ SlideSize.Width,
+ SlideSize.Height,
+ GL_RGBA,
+ GL_UNSIGNED_BYTE,
+ &tempBytes[0]);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR); //TRILINEAR FILTERING
+
+ //anistropic filtering (to make texturing not suck when looking at polygons from oblique angles)
+ GLfloat largest_supported_anisotropy;
+ glGetFloatv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &largest_supported_anisotropy);
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, largest_supported_anisotropy);
+ } else {
+ if( pTransition && !cbBrokenTexturesATI && !useMipmap) {
+ glTexImage2D( GL_TEXTURE_2D, 0, pFormat->nInternalFormat, SlideSize.Width, SlideSize.Height, 0, pFormat->eFormat, pFormat->eType, &data[0] );
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST);
+ } else {
+ gluBuild2DMipmaps( GL_TEXTURE_2D, pFormat->nInternalFormat, SlideSize.Width, SlideSize.Height, pFormat->eFormat, pFormat->eType, &data[0] );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR ); //TRILINEAR FILTERING
+
+ //anistropic filtering (to make texturing not suck when looking at polygons from oblique angles)
+ GLfloat largest_supported_anisotropy;
+ glGetFloatv( GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &largest_supported_anisotropy );
+ glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, largest_supported_anisotropy );
+ }
+ }
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ }
+#endif
+ OSL_ENSURE(glIsTexture(*texID), "Can't generate Leaving slide textures in OpenGL");
+}
+
+void OGLTransitionerImpl::prepareEnvironment()
+{
+ glMatrixMode(GL_PROJECTION);
+ glLoadIdentity();
+ double EyePos(10.0);
+ double RealF(1.0);
+ double RealN(-1.0);
+ double RealL(-1.0);
+ double RealR(1.0);
+ double RealB(-1.0);
+ double RealT(1.0);
+ double ClipN(EyePos+5.0*RealN);
+ double ClipF(EyePos+15.0*RealF);
+ double ClipL(RealL*8.0);
+ double ClipR(RealR*8.0);
+ double ClipB(RealB*8.0);
+ double ClipT(RealT*8.0);
+ //This scaling is to take the plane with BottomLeftCorner(-1,-1,0) and TopRightCorner(1,1,0) and map it to the screen after the perspective division.
+ glScaled( 1.0 / ( ( ( RealR * 2.0 * ClipN ) / ( EyePos * ( ClipR - ClipL ) ) ) - ( ( ClipR + ClipL ) / ( ClipR - ClipL ) ) ),
+ 1.0 / ( ( ( RealT * 2.0 * ClipN ) / ( EyePos * ( ClipT - ClipB ) ) ) - ( ( ClipT + ClipB ) / ( ClipT - ClipB ) ) ),
+ 1.0 );
+ glFrustum(ClipL,ClipR,ClipB,ClipT,ClipN,ClipF);
+ glMatrixMode(GL_MODELVIEW);
+ glLoadIdentity();
+ glTranslated(0,0,-EyePos);
+}
+
+const OGLFormat* OGLTransitionerImpl::chooseFormats()
+{
+ const OGLFormat* pDetectedFormat=NULL;
+ uno::Reference<rendering::XIntegerBitmapColorSpace> xIntColorSpace(
+ SlideBitmapLayout.ColorSpace);
+
+ if( (xIntColorSpace->getType() == rendering::ColorSpaceType::RGB ||
+ xIntColorSpace->getType() == rendering::ColorSpaceType::SRGB) )
+ {
+ /* table for canvas->OGL format mapping. outer index is number
+ of color components (0:3, 1:4), then comes bits per pixel
+ (0:16, 1:24, 2:32), then channel ordering: (0:rgba, 1:bgra,
+ 2:argb, 3:abgr)
+ */
+ static const OGLFormat lcl_RGB24[] =
+ {
+ // 24 bit RGB
+ {3, GL_BGR, GL_UNSIGNED_BYTE},
+ {3, GL_RGB, GL_UNSIGNED_BYTE},
+ {3, GL_BGR, GL_UNSIGNED_BYTE},
+ {3, GL_RGB, GL_UNSIGNED_BYTE}
+ };
+
+#if defined(GL_VERSION_1_2) && defined(GLU_VERSION_1_3)
+ // more format constants available
+ static const OGLFormat lcl_RGB16[] =
+ {
+ // 16 bit RGB
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5_REV},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5_REV},
+ {3, GL_RGB, GL_UNSIGNED_SHORT_5_6_5}
+ };
+
+ static const OGLFormat lcl_ARGB16_4[] =
+ {
+ // 16 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_4_4_4_4_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_4_4_4_4_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_4_4_4_4},
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_4_4_4_4}
+ };
+
+ static const OGLFormat lcl_ARGB16_5[] =
+ {
+ // 16 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_1_5_5_5_REV},
+ {4, GL_BGRA, GL_UNSIGNED_SHORT_5_5_5_1},
+ {4, GL_RGBA, GL_UNSIGNED_SHORT_5_5_5_1}
+ };
+
+ static const OGLFormat lcl_ARGB32[] =
+ {
+ // 32 bit ARGB
+ {4, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8_REV},
+ {4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV},
+ {4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8},
+ {4, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8}
+ };
+
+ const uno::Sequence<sal_Int8> aComponentTags(
+ xIntColorSpace->getComponentTags());
+ const uno::Sequence<sal_Int32> aComponentBitcounts(
+ xIntColorSpace->getComponentBitCounts());
+ const sal_Int32 nNumComponents( aComponentBitcounts.getLength() );
+ const sal_Int32 nBitsPerPixel( xIntColorSpace->getBitsPerPixel() );
+
+ // supported component ordering?
+ const int nComponentOrderIndex(
+ calcComponentOrderIndex(aComponentTags));
+ if( nComponentOrderIndex != -1 )
+ {
+ switch( nBitsPerPixel )
+ {
+ case 16:
+ if( nNumComponents == 3 )
+ {
+ pDetectedFormat = &lcl_RGB16[nComponentOrderIndex];
+ }
+ else if( nNumComponents == 4 )
+ {
+ if( aComponentBitcounts[1] == 4 )
+ {
+ pDetectedFormat = &lcl_ARGB16_4[nComponentOrderIndex];
+ }
+ else if( aComponentBitcounts[1] == 5 )
+ {
+ pDetectedFormat = &lcl_ARGB16_5[nComponentOrderIndex];
+ }
+ }
+ break;
+ case 24:
+ if( nNumComponents == 3 )
+ {
+ pDetectedFormat = &lcl_RGB24[nComponentOrderIndex];
+ }
+ break;
+ case 32:
+ pDetectedFormat = &lcl_ARGB32[nComponentOrderIndex];
+ break;
+ }
+ }
+#else
+ const uno::Sequence<sal_Int8> aComponentTags(
+ xIntColorSpace->getComponentTags());
+ const int nComponentOrderIndex(calcComponentOrderIndex(aComponentTags));
+ if( aComponentTags.getLength() == 3 &&
+ nComponentOrderIndex != -1 &&
+ xIntColorSpace->getBitsPerPixel() == 24 )
+ {
+ pDetectedFormat = &lcl_RGB24[nComponentOrderIndex];
+ }
+#endif
+ }
+
+ return pDetectedFormat;
+}
+
+void OGLTransitionerImpl::GLInitSlides()
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed() || pTransition->mnRequiredGLVersion > cnGLVersion)
+ return;
+
+ prepareEnvironment();
+
+ const OGLFormat* pFormat = NULL;
+ if( !mbUseLeavingPixmap || !mbUseEnteringPixmap )
+ pFormat = chooseFormats();
+
+ createTexture( &GLleavingSlide,
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ LeavingPixmap,
+ mbUseLeavingPixmap,
+#endif
+ pTransition->mbUseMipMapLeaving,
+ LeavingBytes,
+ pFormat );
+
+ createTexture( &GLenteringSlide,
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ EnteringPixmap,
+ mbUseEnteringPixmap,
+#endif
+ pTransition->mbUseMipMapEntering,
+ EnteringBytes,
+ pFormat );
+
+#ifdef UNX
+ unx::glXWaitGL();
+ XSync(GLWin.dpy, false);
+#endif
+
+#ifdef DEBUG
+ t2 = microsec_clock::local_time();
+ OSL_TRACE("textures created in: %s", to_simple_string( t2 - t1 ).c_str());
+#endif
+}
+
+void SAL_CALL OGLTransitionerImpl::update( double nTime ) throw (uno::RuntimeException)
+{
+#ifdef DEBUG
+ frame_count ++;
+ t3 = microsec_clock::local_time();
+ if( frame_count == 1 ) {
+ t5 = t3;
+ total_update = seconds (0);
+ }
+#endif
+ osl::MutexGuard const guard( m_aMutex );
+
+ if (isDisposed() || !cbGLXPresent || pTransition->mnRequiredGLVersion > cnGLVersion)
+ return;
+
+#ifdef WNT
+ wglMakeCurrent(GLWin.hDC,GLWin.hRC);
+#endif
+#ifdef UNX
+ glXMakeCurrent( GLWin.dpy, GLWin.win, GLWin.ctx );
+#endif
+
+ glEnable(GL_DEPTH_TEST);
+ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+ if(pTransition)
+ pTransition->display( nTime, GLleavingSlide, GLenteringSlide,
+ SlideSize.Width, SlideSize.Height,
+ static_cast<double>(GLWin.Width),
+ static_cast<double>(GLWin.Height) );
+
+#if defined( WNT )
+ SwapBuffers(GLWin.hDC);
+#elif defined( UNX )
+ unx::glXSwapBuffers(GLWin.dpy, GLWin.win);
+#endif
+ if( pWindow )
+ pWindow->Show();
+
+#ifdef UNX
+ /* flush & sync */
+ unx::glXWaitGL();
+ XSync( GLWin.dpy, false );
+#endif
+
+#ifdef DEBUG
+ t4 = microsec_clock::local_time();
+
+ OSL_TRACE("update time: %f", nTime);
+ OSL_TRACE("update took: %s", to_simple_string( t4 - t3 ).c_str());
+ total_update += (t4 - t3);
+#endif
+}
+
+void SAL_CALL OGLTransitionerImpl::viewChanged( const Reference< presentation::XSlideShowView >& rView,
+ const Reference< rendering::XBitmap >& rLeavingBitmap,
+ const Reference< rendering::XBitmap >& rEnteringBitmap )
+ throw (uno::RuntimeException)
+{
+ OSL_TRACE("transitioner: view changed");
+
+ disposeTextures();
+ disposeContextAndWindow();
+
+ initWindowFromSlideShowView( rView );
+ setSlides( rLeavingBitmap, rEnteringBitmap );
+}
+
+void OGLTransitionerImpl::disposeContextAndWindow()
+{
+#if defined( WNT )
+ if (GLWin.hRC)
+ {
+ wglMakeCurrent( GLWin.hDC, 0 ); // kill Device Context
+ wglDeleteContext( GLWin.hRC ); // Kill Render Context
+ ReleaseDC( GLWin.hWnd, GLWin.hDC ); // Release Window
+ }
+#elif defined( UNX )
+ if(GLWin.ctx)
+ {
+ glXMakeCurrent(GLWin.dpy, None, NULL);
+ if( glGetError() != GL_NO_ERROR ) {
+ OSL_TRACE("glError: %s", (char *)gluErrorString(glGetError()));
+ }
+ glXDestroyContext(GLWin.dpy, GLWin.ctx);
+ GLWin.ctx = NULL;
+ }
+#endif
+ if( pWindow ) {
+ delete pWindow;
+ pWindow = NULL;
+ GLWin.win = 0;
+ }
+}
+
+void OGLTransitionerImpl::disposeTextures()
+{
+#ifdef WNT
+ wglMakeCurrent(GLWin.hDC,GLWin.hRC);
+#endif
+#ifdef UNX
+ glXMakeCurrent( GLWin.dpy, GLWin.win, GLWin.ctx );
+#endif
+
+#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
+ unx::PFNGLXRELEASETEXIMAGEEXTPROC myglXReleaseTexImageEXT = (unx::PFNGLXRELEASETEXIMAGEEXTPROC) unx::glXGetProcAddress( (const GLubyte*) "glXReleaseTexImageEXT" );
+ if( mbUseLeavingPixmap ) {
+
+ myglXReleaseTexImageEXT( GLWin.dpy, LeavingPixmap, GLX_FRONT_LEFT_EXT );
+ glXDestroyGLXPixmap( GLWin.dpy, LeavingPixmap );
+ LeavingPixmap = 0;
+ if( mbFreeLeavingPixmap ) {
+ unx::XFreePixmap( GLWin.dpy, maLeavingPixmap );
+ mbFreeLeavingPixmap = false;
+ maLeavingPixmap = 0;
+ }
+ }
+ if( mbUseEnteringPixmap ) {
+ myglXReleaseTexImageEXT( GLWin.dpy, EnteringPixmap, GLX_FRONT_LEFT_EXT );
+ glXDestroyGLXPixmap( GLWin.dpy, EnteringPixmap );
+ EnteringPixmap = 0;
+ if( mbFreeEnteringPixmap ) {
+ unx::XFreePixmap( GLWin.dpy, maEnteringPixmap );
+ mbFreeEnteringPixmap = false;
+ maEnteringPixmap = 0;
+ }
+ }
+#endif
+
+ if( !mbUseLeavingPixmap ) {
+ glDeleteTextures(1,&GLleavingSlide);
+ GLleavingSlide = 0;
+ }
+ if( !mbUseEnteringPixmap ) {
+ glDeleteTextures(1,&GLenteringSlide);
+ GLleavingSlide = 0;
+ }
+
+ mbUseLeavingPixmap = false;
+ mbUseEnteringPixmap = false;
+}
+
+// we are about to be disposed (someone call dispose() on us)
+void OGLTransitionerImpl::disposing()
+{
+ osl::MutexGuard const guard( m_aMutex );
+
+#ifdef DEBUG
+ OSL_TRACE("dispose %p\n", this);
+ if( frame_count ) {
+ t6 = microsec_clock::local_time();
+ time_duration duration = t6 - t5;
+ OSL_TRACE("whole transition (frames: %d) took: %s fps: %f time spent in updates: %s percentage of transition time: %f%%",
+ frame_count, to_simple_string( duration ).c_str(),
+ ((double)frame_count*1000000000.0)/duration.total_nanoseconds(),
+ to_simple_string( total_update ).c_str(),
+ 100*(((double)total_update.total_nanoseconds())/((double)duration.total_nanoseconds()))
+ );
+ }
+#endif
+
+ if( pWindow ) {
+
+ disposeTextures();
+
+ if (pTransition)
+ pTransition->finish();
+
+#ifdef UNX
+ if( mbRestoreSync ) {
+ // try to reestablish synchronize state
+ char* sal_synchronize = getenv("SAL_SYNCHRONIZE");
+ XSynchronize( GLWin.dpy, sal_synchronize && *sal_synchronize == '1' );
+ }
+#endif
+
+ disposeContextAndWindow();
+ }
+
+ if (pTransition)
+ delete pTransition;
+
+ mxLeavingBitmap.clear();
+ mxEnteringBitmap.clear();
+ mxView.clear();
+}
+
+OGLTransitionerImpl::OGLTransitionerImpl(OGLTransitionImpl* pOGLTransition) :
+ OGLTransitionerImplBase(m_aMutex),
+ GLWin(),
+ GLleavingSlide( 0 ),
+ GLenteringSlide( 0 ),
+ pWindow( NULL ),
+ mxView(),
+ EnteringBytes(),
+ LeavingBytes(),
+ mbRestoreSync( false ),
+ mbUseLeavingPixmap( false ),
+ mbUseEnteringPixmap( false ),
+ SlideBitmapLayout(),
+ SlideSize(),
+ pTransition(pOGLTransition)
+{
+#if defined( WNT )
+ GLWin.hWnd = 0;
+#elif defined( UNX )
+ GLWin.ctx = 0;
+#endif
+
+ DBG(frame_count = 0);
+}
+
+typedef cppu::WeakComponentImplHelper1<presentation::XTransitionFactory> OGLTransitionFactoryImplBase;
+
+class OGLTransitionFactoryImpl : private cppu::BaseMutex, public OGLTransitionFactoryImplBase
+{
+public:
+ explicit OGLTransitionFactoryImpl( const uno::Reference< uno::XComponentContext >& ) :
+ OGLTransitionFactoryImplBase(m_aMutex)
+ {}
+
+ // XTransitionFactory
+ virtual ::sal_Bool SAL_CALL hasTransition( ::sal_Int16 transitionType, ::sal_Int16 transitionSubType ) throw (uno::RuntimeException)
+ {
+ if( transitionType == animations::TransitionType::MISCSHAPEWIPE ) {
+ switch( transitionSubType )
+ {
+ case animations::TransitionSubType::ACROSS:
+ case animations::TransitionSubType::CORNERSOUT:
+ case animations::TransitionSubType::CIRCLE:
+ case animations::TransitionSubType::FANOUTHORIZONTAL:
+ case animations::TransitionSubType::CORNERSIN:
+ case animations::TransitionSubType::LEFTTORIGHT:
+ case animations::TransitionSubType::TOPTOBOTTOM:
+ case animations::TransitionSubType::TOPRIGHT:
+ case animations::TransitionSubType::TOPLEFT:
+ case animations::TransitionSubType::BOTTOMRIGHT:
+ case animations::TransitionSubType::BOTTOMLEFT:
+ case animations::TransitionSubType::TOPCENTER:
+ case animations::TransitionSubType::RIGHTCENTER:
+ case animations::TransitionSubType::BOTTOMCENTER:
+ return sal_True;
+
+ default:
+ return sal_False;
+ }
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) {
+ return sal_True;
+ } else if( transitionType == animations::TransitionType::ZOOM && transitionSubType == animations::TransitionSubType::ROTATEIN ) {
+ return sal_True;
+ } else
+ return sal_False;
+ }
+
+ virtual uno::Reference< presentation::XTransition > SAL_CALL createTransition(
+ ::sal_Int16 transitionType,
+ ::sal_Int16 transitionSubType,
+ const uno::Reference< presentation::XSlideShowView >& view,
+ const uno::Reference< rendering::XBitmap >& leavingBitmap,
+ const uno::Reference< rendering::XBitmap >& enteringBitmap )
+ throw (uno::RuntimeException)
+ {
+ if( !hasTransition( transitionType, transitionSubType ) )
+ return uno::Reference< presentation::XTransition >();
+
+ bool bGLXPresent = OGLTransitionerImpl::initialize( view );
+
+ if( OGLTransitionerImpl::cbMesa && (
+ ( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) ||
+ ( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) ||
+ ( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) ) )
+ return uno::Reference< presentation::XTransition >();
+
+
+ OGLTransitionImpl* pTransition = NULL;
+
+ if( transitionType == animations::TransitionType::MISCSHAPEWIPE ) {
+ pTransition = new OGLTransitionImpl();
+ switch( transitionSubType )
+ {
+ case animations::TransitionSubType::ACROSS:
+ pTransition->makeNByMTileFlip(8,6);
+ break;
+ case animations::TransitionSubType::CORNERSOUT:
+ pTransition->makeOutsideCubeFaceToLeft();
+ break;
+ case animations::TransitionSubType::CIRCLE:
+ pTransition->makeRevolvingCircles(8,128);
+ break;
+ case animations::TransitionSubType::FANOUTHORIZONTAL:
+ pTransition->makeHelix(20);
+ break;
+ case animations::TransitionSubType::CORNERSIN:
+ pTransition->makeInsideCubeFaceToLeft();
+ break;
+ case animations::TransitionSubType::LEFTTORIGHT:
+ pTransition->makeFallLeaving();
+ break;
+ case animations::TransitionSubType::TOPTOBOTTOM:
+ pTransition->makeTurnAround();
+ break;
+ case animations::TransitionSubType::TOPRIGHT:
+ pTransition->makeTurnDown();
+ break;
+ case animations::TransitionSubType::TOPLEFT:
+ pTransition->makeIris();
+ break;
+ case animations::TransitionSubType::BOTTOMRIGHT:
+ pTransition->makeRochade();
+ break;
+ case animations::TransitionSubType::BOTTOMLEFT:
+ pTransition->makeVenetianBlinds( true, 8 );
+ break;
+ case animations::TransitionSubType::TOPCENTER:
+ pTransition->makeVenetianBlinds( false, 6 );
+ break;
+ case animations::TransitionSubType::RIGHTCENTER:
+ pTransition->makeStatic();
+ break;
+ case animations::TransitionSubType::BOTTOMCENTER:
+ pTransition->makeDissolve();
+ break;
+ }
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::CROSSFADE ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeFadeSmoothly();
+ } else if( transitionType == animations::TransitionType::FADE && transitionSubType == animations::TransitionSubType::FADEOVERCOLOR ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeFadeThroughBlack();
+ } else if( transitionType == animations::TransitionType::IRISWIPE && transitionSubType == animations::TransitionSubType::DIAMOND ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeDiamond();
+ } else if( transitionType == animations::TransitionType::ZOOM && transitionSubType == animations::TransitionSubType::ROTATEIN ) {
+ pTransition = new OGLTransitionImpl();
+ pTransition->makeNewsflash();
+ }
+
+ rtl::Reference<OGLTransitionerImpl> xRes(
+ new OGLTransitionerImpl(pTransition) );
+ if( bGLXPresent ) {
+ if( !xRes->initWindowFromSlideShowView(view))
+ return uno::Reference< presentation::XTransition >();
+ xRes->setSlides(leavingBitmap,enteringBitmap);
+ }
+
+ return uno::Reference<presentation::XTransition>(xRes.get());
+ }
+};
+
+}
+
+namespace sdecl = comphelper::service_decl;
+#if defined (__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ <= 3)
+ sdecl::class_<OGLTransitionFactoryImpl> serviceImpl;
+ const sdecl::ServiceDecl OGLTransitionFactoryDecl(
+ serviceImpl,
+#else
+ const sdecl::ServiceDecl OGLTransitionFactoryDecl(
+ sdecl::class_<OGLTransitionFactoryImpl>(),
+#endif
+ "com.sun.star.comp.presentation.OGLTransitionFactory",
+ "com.sun.star.presentation.TransitionFactory" );
+
+// The C shared lib entry points
+COMPHELPER_SERVICEDECL_EXPORTS1(OGLTransitionFactoryDecl)
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/OGLTrans_Shaders.cxx b/slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.cxx
index 0ca2d291a..4f20094cf 100644
--- a/slideshow/source/engine/OGLTrans/OGLTrans_Shaders.cxx
+++ b/slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.cxx
@@ -1,8 +1,9 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
- * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2008 by Sun Microsystems, Inc.
*
* OpenOffice.org - a multi-platform office productivity suite
*
@@ -138,3 +139,4 @@ GLuint OGLShaders::LinkProgram( const char *vertexShader, const char *fragmentSh
#endif
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.hxx b/slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.hxx
new file mode 100644
index 000000000..045b9ff8d
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/win/OGLTrans_Shaders.hxx
@@ -0,0 +1,71 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef INCLUDED_OGLTRANS_SHADERS_HXX_
+#define INCLUDED_OGLTRANS_SHADERS_HXX_
+
+#define GL_GLEXT_PROTOTYPES 1
+#include <GL/gl.h>
+#include <GL/glext.h>
+
+class OGLShaders {
+ static bool Initialize();
+ static bool cbInitialized;
+
+public:
+
+ static GLuint LinkProgram( const char *vertexShader, const char *fragmentShader );
+
+ /** GL shader functions
+ */
+#ifdef GL_VERSION_2_0
+
+ static PFNGLCREATESHADERPROC glCreateShader;
+ static PFNGLSHADERSOURCEPROC glShaderSource;
+ static PFNGLCOMPILESHADERPROC glCompileShader;
+ static PFNGLGETSHADERIVPROC glGetShaderiv;
+ static PFNGLGETSHADERINFOLOGPROC glGetShaderInfoLog;
+ static PFNGLDELETESHADERPROC glDeleteShader;
+
+ static PFNGLCREATEPROGRAMPROC glCreateProgram;
+ static PFNGLATTACHSHADERPROC glAttachShader;
+ static PFNGLLINKPROGRAMPROC glLinkProgram;
+ static PFNGLGETPROGRAMIVPROC glGetProgramiv;
+ static PFNGLGETPROGRAMINFOLOGPROC glGetProgramInfoLog;
+ static PFNGLUSEPROGRAMPROC glUseProgram;
+ static PFNGLDELETEPROGRAMPROC glDeleteProgram;
+
+ static PFNGLGETUNIFORMLOCATIONPROC glGetUniformLocation;
+ static PFNGLUNIFORM1IPROC glUniform1i;
+ static PFNGLUNIFORM1FPROC glUniform1f;
+#endif
+};
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.cxx b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.cxx
new file mode 100644
index 000000000..d658d54b7
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.cxx
@@ -0,0 +1,1315 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include "OGLTrans_TransitionImpl.hxx"
+#include "OGLTrans_Shaders.hxx"
+#ifdef QUARTZ
+#include <OpenGL/gl.h>
+#else
+#include <GL/gl.h>
+#include <math.h>
+#endif
+
+void OGLTransitionImpl::clear()
+{
+ for(unsigned int i( 0 ); i < OverallOperations.size(); ++i)
+ delete OverallOperations[i];
+ OverallOperations.clear();
+ maLeavingSlidePrimitives.clear();
+ maEnteringSlidePrimitives.clear();
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i)
+ delete maSceneObjects[i];
+ maSceneObjects.clear();
+
+ mbReflectSlides = false;
+
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ OGLShaders::glDeleteProgram( mProgramObject );
+ mProgramObject = 0;
+ }
+
+ if( mVertexObject ) {
+ OGLShaders::glDeleteShader( mVertexObject );
+ mVertexObject = 0;
+ }
+
+ if( mFragmentObject ) {
+ OGLShaders::glDeleteShader( mFragmentObject );
+ mFragmentObject = 0;
+ }
+#endif
+
+ if( maHelperTexture ) {
+ glDeleteTextures( 1, &maHelperTexture );
+ maHelperTexture = 0;
+ }
+
+ if( mmClearTransition )
+ (this->*mmClearTransition)();
+}
+
+OGLTransitionImpl::~OGLTransitionImpl()
+{
+ clear();
+}
+
+void OGLTransitionImpl::prepare( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex )
+{
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i) {
+ maSceneObjects[i]->prepare();
+ }
+
+ if( mmPrepareTransition )
+ (this->*mmPrepareTransition)( glLeavingSlideTex, glEnteringSlideTex );
+}
+
+void OGLTransitionImpl::finish()
+{
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i) {
+ maSceneObjects[i]->finish();
+ }
+}
+
+static void blendSlide( double depth )
+{
+ double showHeight = -1 + depth*2;
+ GLfloat reflectionColor[] = {0, 0, 0, 0.25};
+
+ glDisable( GL_DEPTH_TEST );
+ glBegin( GL_QUADS );
+ glColor4fv( reflectionColor );
+ glVertex3f( -1, -1, 0 );
+ glColor4f( 0, 0, 0, 1 );
+ glVertex3f(-1, showHeight, 0 );
+ glVertex3f( 1, showHeight, 0 );
+ glColor4fv( reflectionColor );
+ glVertex3f( 1, -1, 0 );
+ glEnd();
+
+ glBegin( GL_QUADS );
+ glColor4f( 0, 0, 0, 1 );
+ glVertex3f( -1, showHeight, 0 );
+ glVertex3f( -1, 1, 0 );
+ glVertex3f( 1, 1, 0 );
+ glVertex3f( 1, showHeight, 0 );
+ glEnd();
+ glEnable( GL_DEPTH_TEST );
+}
+
+static void slideShadow( double nTime, Primitive& primitive, double sw, double sh )
+{
+ double reflectionDepth = 0.3;
+
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glDisable(GL_LIGHTING);
+
+ glPushMatrix();
+ primitive.applyOperations( nTime, sw, sh );
+ blendSlide( reflectionDepth );
+ glPopMatrix();
+
+ glDisable(GL_BLEND);
+ glEnable(GL_LIGHTING);
+}
+
+void OGLTransitionImpl::display( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ double SlideWidthScale, SlideHeightScale;
+
+ SlideWidthScale = SlideWidth/DispWidth;
+ SlideHeightScale = SlideHeight/DispHeight;
+
+ if( mmPrepare ) {
+ clear();
+ (this->*mmPrepare)( nTime, SlideWidth, SlideHeight, DispWidth, DispHeight );
+ }
+
+ glPushMatrix();
+ displaySlides( nTime, glLeavingSlideTex, glEnteringSlideTex, SlideWidthScale, SlideHeightScale );
+ displayScene( nTime, SlideWidth, SlideHeight, DispWidth, DispHeight );
+ glPopMatrix();
+}
+
+void OGLTransitionImpl::applyOverallOperations( double nTime, double SlideWidthScale, double SlideHeightScale )
+{
+ for(unsigned int i(0); i < OverallOperations.size(); ++i)
+ OverallOperations[i]->interpolate(nTime,SlideWidthScale,SlideHeightScale);
+}
+
+void OGLTransitionImpl::displaySlide( double nTime, ::sal_Int32 glSlideTex, std::vector<Primitive>& primitives,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ //TODO change to foreach
+ glBindTexture(GL_TEXTURE_2D, glSlideTex);
+
+ // display slide reflection
+ // note that depth test is turned off while blending the shadow
+ // so the slides has to be rendered in right order, see rochade as example
+ if( mbReflectSlides ) {
+ double surfaceLevel = -0.04;
+
+ /* reflected slides */
+ glPushMatrix();
+
+ glScaled( 1, -1, 1 );
+ glTranslated( 0, 2 - surfaceLevel, 0 );
+
+ glCullFace(GL_FRONT);
+ for(unsigned int i(0); i < primitives.size(); ++i)
+ primitives[i].display(nTime, SlideWidthScale, SlideHeightScale);
+ glCullFace(GL_BACK);
+
+ slideShadow( nTime, primitives[0], SlideWidthScale, SlideHeightScale );
+
+ glPopMatrix();
+ }
+
+ for(unsigned int i(0); i < primitives.size(); ++i)
+ primitives[i].display(nTime, SlideWidthScale, SlideHeightScale);
+}
+
+void OGLTransitionImpl::displaySlides( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ if( mmDisplaySlides )
+ (this->*mmDisplaySlides)( nTime, glLeavingSlideTex, glEnteringSlideTex, SlideWidthScale, SlideHeightScale );
+ else {
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glEnable(GL_TEXTURE_2D);
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+}
+
+void OGLTransitionImpl::displayScene( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ glEnable(GL_TEXTURE_2D);
+ for(unsigned int i(0); i < maSceneObjects.size(); ++i)
+ maSceneObjects[i]->display(nTime, SlideWidth, SlideHeight, DispWidth, DispHeight);
+}
+
+void Primitive::display(double nTime, double WidthScale, double HeightScale)
+{
+ glPushMatrix();
+
+ applyOperations( nTime, WidthScale, HeightScale );
+
+ glEnableClientState( GL_VERTEX_ARRAY );
+ if(!Normals.empty())
+ {
+ glNormalPointer( GL_DOUBLE , 0 , &Normals[0] );
+ glEnableClientState( GL_NORMAL_ARRAY );
+ }
+ glEnableClientState( GL_TEXTURE_COORD_ARRAY );
+ glTexCoordPointer( 2, GL_DOUBLE, 0, &TexCoords[0] );
+ glVertexPointer( 3, GL_DOUBLE, 0, &Vertices[0] );
+ glDrawArrays( GL_TRIANGLES, 0, Vertices.size() );
+ glPopMatrix();
+}
+
+void Primitive::applyOperations(double nTime, double WidthScale, double HeightScale)
+{
+ for(unsigned int i(0); i < Operations.size(); ++i)
+ Operations[i]->interpolate( nTime ,WidthScale,HeightScale);
+ glScaled(WidthScale,HeightScale,1);
+}
+
+Primitive::~Primitive()
+{
+ for(unsigned int i( 0 ); i < Operations.size(); ++i)
+ delete Operations[i];
+}
+
+
+void SceneObject::display(double nTime, double /* SlideWidth */, double /* SlideHeight */, double DispWidth, double DispHeight )
+{
+ for(unsigned int i(0); i < maPrimitives.size(); ++i) {
+ // fixme: allow various model spaces, now we make it so that
+ // it is regular -1,-1 to 1,1, where the whole display fits in
+ glPushMatrix();
+ if (DispHeight > DispWidth)
+ glScaled(DispHeight/DispWidth, 1, 1);
+ else
+ glScaled(1, DispWidth/DispHeight, 1);
+ maPrimitives[i].display(nTime, 1, 1);
+ glPopMatrix();
+ }
+}
+
+void SceneObject::pushPrimitive(const Primitive &p)
+{
+ maPrimitives.push_back(p);
+}
+
+SceneObject::SceneObject()
+ : maPrimitives()
+{
+}
+
+Iris::Iris()
+ : SceneObject ()
+{
+}
+
+void Iris::display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight )
+{
+ glBindTexture(GL_TEXTURE_2D, maTexture);
+ SceneObject::display(nTime, SlideWidth, SlideHeight, DispWidth, DispHeight);
+}
+
+void Iris::prepare()
+{
+ static GLubyte img[3] = { 80, 80, 80 };
+
+ glGenTextures(1, &maTexture);
+ glBindTexture(GL_TEXTURE_2D, maTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 3, 1, 1, 0, GL_RGB, GL_UNSIGNED_BYTE, img);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_REPEAT);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_REPEAT);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
+}
+
+void Iris::finish()
+{
+ glDeleteTextures(1, &maTexture);
+}
+
+void OGLTransitionImpl::makeOutsideCubeFaceToLeft()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,-1),90,false,0.0,1.0));
+
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,-1),-90,true,0.0,1.0));
+}
+
+void OGLTransitionImpl::makeInsideCubeFaceToLeft()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,1),-90,false,0.0,1.0));
+
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,1),90,true,0.0,1.0));
+}
+
+void OGLTransitionImpl::makeFallLeaving()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(1,0,0),basegfx::B3DVector(0,-1,0), 90,true,0.0,1.0));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::makeTurnAround()
+{
+ clear();
+ Primitive Slide;
+
+ mbReflectSlides = true;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0),-180,false,0.0,1.0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, -1.5),true, 0, 0.5));
+ OverallOperations.push_back(new STranslate(basegfx::B3DVector(0, 0, 1.5), true, 0.5, 1));
+ OverallOperations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0, 1, 0),basegfx::B3DVector(0, 0, 0), -180, true, 0.0, 1.0));
+}
+
+void OGLTransitionImpl::makeTurnDown()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, 0.0001), false, -1.0, 0.0));
+ Slide.Operations.push_back(new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(-1, 1, 0), -90, true, 0.0, 1.0));
+ Slide.Operations.push_back(new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(-1, 1, 0), 90, false, -1.0, 0.0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ mbUseMipMapLeaving = false;
+}
+
+void OGLTransitionImpl::makeIris()
+{
+ clear();
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ Slide.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, 0.000001), false, -1, 0));
+ Slide.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, -0.000002), false, 0.5, 1));
+ maLeavingSlidePrimitives.push_back (Slide);
+
+
+ Primitive irisPart, part;
+ int i, nSteps = 24, nParts = 7;
+ double t = 1.0/nSteps, cx, cy, lcx, lcy, lx = 1, ly = 0, x, y, cxo, cyo, lcxo, lcyo, of=2.2, f=1.42;
+
+ for (i=1; i<=nSteps; i++) {
+ x = cos ((3*2*M_PI*t)/nParts);
+ y = -sin ((3*2*M_PI*t)/nParts);
+ cx = (f*x + 1)/2;
+ cy = (f*y + 1)/2;
+ lcx = (f*lx + 1)/2;
+ lcy = (f*ly + 1)/2;
+ cxo = (of*x + 1)/2;
+ cyo = (of*y + 1)/2;
+ lcxo = (of*lx + 1)/2;
+ lcyo = (of*ly + 1)/2;
+ irisPart.pushTriangle (basegfx::B2DVector (lcx, lcy),
+ basegfx::B2DVector (lcxo, lcyo),
+ basegfx::B2DVector (cx, cy));
+ irisPart.pushTriangle (basegfx::B2DVector (cx, cy),
+ basegfx::B2DVector (lcxo, lcyo),
+ basegfx::B2DVector (cxo, cyo));
+ lx = x;
+ ly = y;
+ t += 1.0/nSteps;
+ }
+
+ Iris* pIris = new Iris();
+ double angle = 87;
+
+ for (i = 0; i < nParts; i++) {
+ irisPart.Operations.clear ();
+ double rx, ry;
+
+ rx = cos ((2*M_PI*i)/nParts);
+ ry = sin ((2*M_PI*i)/nParts);
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(rx, ry, 0), angle, true, 0.0, 0.5));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(rx, ry, 0), -angle, true, 0.5, 1));
+ if (i > 0) {
+ irisPart.Operations.push_back (new STranslate (basegfx::B3DVector(rx, ry, 0), false, -1, 0));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(0, 0, 1), basegfx::B3DVector(0, 0, 0), i*360.0/nParts, false, -1, 0));
+ irisPart.Operations.push_back (new STranslate (basegfx::B3DVector(-1, 0, 0), false, -1, 0));
+ }
+ irisPart.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, 1), false, -2, 0.0));
+ irisPart.Operations.push_back (new SRotate (basegfx::B3DVector(1, .5, 0), basegfx::B3DVector(1, 0, 0), -30, false, -1, 0));
+ pIris->pushPrimitive (irisPart);
+ }
+
+ maSceneObjects.push_back (pIris);
+
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::displaySlidesRochade( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glEnable(GL_TEXTURE_2D);
+
+ if( nTime > .5) {
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ } else {
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+}
+
+void OGLTransitionImpl::makeRochade()
+{
+ clear();
+ Primitive Slide;
+
+ mbReflectSlides = true;
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesRochade;
+
+ double w, h;
+
+ w = 2.2;
+ h = 10;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+
+ Slide.Operations.push_back(new SEllipseTranslate(w, h, 0.25, -0.25, true, 0, 1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), -45, true, 0, 1));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.clear();
+ Slide.Operations.push_back(new SEllipseTranslate(w, h, 0.75, 0.25, true, 0, 1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(0, 0, -h), false, -1, 0));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), -45, true, 0, 1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0,1,0),basegfx::B3DVector(0,0,0), 45, false, -1, 0));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B2DVector clamp(const basegfx::B2DVector& v)
+{
+ return basegfx::B2DVector(min(max(v.getX(),-1.0),1.0),
+ min(max(v.getY(),-1.0),1.0));
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B3DVector clamp(const basegfx::B3DVector& v)
+{
+ return basegfx::B3DVector(min(max(v.getX(),-1.0),1.0),
+ min(max(v.getY(),-1.0),1.0),
+ min(max(v.getZ(),-1.0),1.0));
+}
+
+inline double randFromNeg1to1()
+{
+ return ( ( static_cast<double>( rand() ) / static_cast<double>( RAND_MAX ) ) * 2.0 ) - 1.0;
+}
+
+// TODO(Q3): extract to basegfx
+inline basegfx::B3DVector randNormVectorInXYPlane()
+{
+ basegfx::B3DVector toReturn(randFromNeg1to1(),randFromNeg1to1(),0.0);
+ return toReturn/toReturn.getLength();
+}
+
+void OGLTransitionImpl::makeRevolvingCircles( ::sal_uInt16 nCircles , ::sal_uInt16 nPointsOnCircles )
+{
+ clear();
+ double dAngle(2*3.1415926/static_cast<double>( nPointsOnCircles ));
+ if(nCircles < 2 || nPointsOnCircles < 4)
+ {
+ makeNByMTileFlip(1,1);
+ return;
+ }
+ double Radius(1.0/static_cast<double>( nCircles ));
+ double dRadius(Radius);
+ double LastRadius(0.0);
+ double NextRadius(2*Radius);
+
+ /// now we know there is at least two circles
+ /// the first will always be a full circle
+ /// the last will always be the outer shell of the slide with a circle hole
+
+ //add the full circle
+ vector<basegfx::B2DVector> unScaledTexCoords;
+ double TempAngle(0.0);
+ for(unsigned int Point(0); Point < nPointsOnCircles; ++Point)
+ {
+ unScaledTexCoords.push_back( basegfx::B2DVector( cos(TempAngle - 3.1415926/2.0) , sin(TempAngle- 3.1415926/2.0) ) );
+
+ TempAngle += dAngle;
+ }
+
+ {
+ Primitive EnteringSlide;
+ Primitive LeavingSlide;
+ for(int Point(0); Point + 1 < nPointsOnCircles; ++Point)
+ {
+ EnteringSlide.pushTriangle( basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point + 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) );
+ LeavingSlide.pushTriangle( basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point + 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ Point ] / 2.0 + basegfx::B2DVector( 0.5, 0.5) );
+ }
+ EnteringSlide.pushTriangle( basegfx::B2DVector(0.5,0.5) , Radius * unScaledTexCoords[ 0 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) , Radius * unScaledTexCoords[ nPointsOnCircles - 1 ] / 2.0 + basegfx::B2DVector( 0.5 , 0.5 ) );
+ LeavingSlide.pushTriangle( basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+ LastRadius = Radius;
+ Radius = NextRadius;
+ NextRadius += dRadius;
+ }
+
+ for(int i(1); i < nCircles - 1; ++i)
+ {
+ Primitive LeavingSlide;
+ Primitive EnteringSlide;
+ for(int Side(0); Side < nPointsOnCircles - 1; ++Side)
+ {
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ }
+
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(Radius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , Radius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, Radius/2.0 , (NextRadius + 1)/2.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+
+ LastRadius = Radius;
+ Radius = NextRadius;
+ NextRadius += dRadius;
+ }
+ {
+ Radius = sqrt(2.0);
+ Primitive LeavingSlide;
+ Primitive EnteringSlide;
+ for(int Side(0); Side < nPointsOnCircles - 1; ++Side)
+ {
+
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[Side + 1])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[Side])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[Side + 1]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[Side + 1])/2.0 + basegfx::B2DVector(0.5,0.5) );
+ }
+
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ EnteringSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[0])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[nPointsOnCircles - 1]/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) );
+ LeavingSlide.pushTriangle(clamp(Radius*unScaledTexCoords[nPointsOnCircles - 1])/2.0 + basegfx::B2DVector(0.5,0.5) , LastRadius*unScaledTexCoords[0]/2.0 + basegfx::B2DVector(0.5,0.5) , clamp(Radius*unScaledTexCoords[0])/2.0 + basegfx::B2DVector(0.5,0.5) );
+
+ basegfx::B3DVector axis(randNormVectorInXYPlane());
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, (LastRadius + dRadius)/2.0 , 1.0 ) );
+ LeavingSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , 180, true, (LastRadius + dRadius)/2.0 , 1.0 ) );
+ EnteringSlide.Operations.push_back( new SRotate( axis , basegfx::B3DVector(0,0,0) , -180, false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(EnteringSlide);
+ maLeavingSlidePrimitives.push_back(LeavingSlide);
+ }
+}
+
+void OGLTransitionImpl::makeHelix( ::sal_uInt16 nRows )
+{
+ clear();
+ double invN(1.0/static_cast<double>(nRows));
+ double iDn = 0.0;
+ double iPDn = invN;
+ for(unsigned int i(0); i < nRows; ++i)
+ {
+ Primitive Tile;
+
+ Tile.pushTriangle(basegfx::B2DVector( 1.0 , iDn ) , basegfx::B2DVector( 0.0 , iDn ) , basegfx::B2DVector( 0.0 , iPDn ));
+
+ Tile.pushTriangle(basegfx::B2DVector( 1.0 , iPDn ) , basegfx::B2DVector( 1.0 , iDn ) , basegfx::B2DVector( 0.0 , iPDn ));
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , 180 ,
+ true,min(max(static_cast<double>(i - nRows/2.0)*invN/2.0,0.0),1.0),
+ min(max(static_cast<double>(i + nRows/2.0)*invN/2.0,0.0),1.0) ) );
+
+ maLeavingSlidePrimitives.push_back(Tile);
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , -180 , false,0.0,1.0) );
+
+ maEnteringSlidePrimitives.push_back(Tile);
+
+ iDn += invN;
+ iPDn += invN;
+ }
+}
+
+void OGLTransitionImpl::makeNByMTileFlip( ::sal_uInt16 n, ::sal_uInt16 m )
+{
+ clear();
+ double invN(1.0/static_cast<double>(n));
+ double invM(1.0/static_cast<double>(m));
+ double iDn = 0.0;
+ double iPDn = invN;
+ for(unsigned int i(0); i < n; ++i)
+ {
+ double jDm = 0.0;
+ double jPDm = invM;
+ for(unsigned int j(0); j < m; ++j)
+ {
+ Primitive Tile;
+
+ Tile.pushTriangle(basegfx::B2DVector( iPDn , jDm ) , basegfx::B2DVector( iDn , jDm ) , basegfx::B2DVector( iDn , jPDm ));
+
+ Tile.pushTriangle(basegfx::B2DVector( iPDn , jPDm ) , basegfx::B2DVector( iPDn , jDm ) , basegfx::B2DVector( iDn , jPDm ));//bottom left corner of tile
+
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 1 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , 180 , true, iDn*jDm/2.0 , ((iPDn*jPDm)+1.0)/2.0 ) );
+ maLeavingSlidePrimitives.push_back(Tile);
+ Tile.Operations.push_back( new SRotate( basegfx::B3DVector( 1 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0 , -180, false, iDn*jDm/2.0 , ((iPDn*jPDm)+1.0)/2.0 ) );
+
+ maEnteringSlidePrimitives.push_back(Tile);
+
+ jDm += invM;
+ jPDm += invM;
+ }
+ iDn += invN;
+ iPDn += invN;
+ }
+}
+
+SRotate::SRotate(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+SScale::SScale(const basegfx::B3DVector& Scale,const basegfx::B3DVector& Origin, bool bInter, double T0, double T1):scale(Scale),origin(Origin)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+RotateAndScaleDepthByWidth::RotateAndScaleDepthByWidth(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+RotateAndScaleDepthByHeight::RotateAndScaleDepthByHeight(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle, bool bInter, double T0, double T1):axis(Axis),origin(Origin),angle(Angle)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+
+STranslate::STranslate(const basegfx::B3DVector& Vector, bool bInter, double T0, double T1):vector(Vector)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+}
+
+inline double intervalInter(double t, double T0, double T1)
+{
+ return ( t - T0 ) / ( T1 - T0 );
+}
+
+void STranslate::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*t*vector.getX(),SlideHeightScale*t*vector.getY(),t*vector.getZ());
+}
+
+void SRotate::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),origin.getZ());
+ glScaled(SlideWidthScale,SlideHeightScale,1);
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glScaled(1/SlideWidthScale,1/SlideHeightScale,1);
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-origin.getZ());
+}
+
+void SScale::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),origin.getZ());
+ glScaled((1-t) + t*scale.getX(),(1-t) + t*scale.getY(),(1-t) + t*scale.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-origin.getZ());
+}
+
+void RotateAndScaleDepthByWidth::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),SlideWidthScale*origin.getZ());
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-SlideWidthScale*origin.getZ());
+}
+
+void RotateAndScaleDepthByHeight::interpolate(double t,double SlideWidthScale,double SlideHeightScale)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+ glTranslated(SlideWidthScale*origin.getX(),SlideHeightScale*origin.getY(),SlideHeightScale*origin.getZ());
+ glRotated(t*angle,axis.getX(),axis.getY(),axis.getZ());
+ glTranslated(-SlideWidthScale*origin.getX(),-SlideHeightScale*origin.getY(),-SlideHeightScale*origin.getZ());
+}
+
+SEllipseTranslate::SEllipseTranslate(double dWidth, double dHeight, double dStartPosition, double dEndPosition, bool bInter, double T0, double T1)
+{
+ nT0 = T0;
+ nT1 = T1;
+ bInterpolate = bInter;
+ width = dWidth;
+ height = dHeight;
+ startPosition = dStartPosition;
+ endPosition = dEndPosition;
+}
+
+void SEllipseTranslate::interpolate(double t,double /* SlideWidthScale */,double /* SlideHeightScale */)
+{
+ if(t <= nT0)
+ return;
+ if(!bInterpolate || t > nT1)
+ t = nT1;
+ t = intervalInter(t,nT0,nT1);
+
+ double a1, a2, x, y;
+ a1 = startPosition*2*M_PI;
+ a2 = (startPosition + t*(endPosition - startPosition))*2*M_PI;
+ x = width*(cos (a2) - cos (a1))/2;
+ y = height*(sin (a2) - sin (a1))/2;
+
+ glTranslated(x, 0, y);
+}
+
+STranslate* STranslate::clone()
+{
+ return new STranslate(*this);
+}
+SRotate* SRotate::clone()
+{
+ return new SRotate(*this);
+}
+
+SScale* SScale::clone()
+{
+ return new SScale(*this);
+}
+
+SEllipseTranslate* SEllipseTranslate::clone()
+{
+ return new SEllipseTranslate(*this);
+}
+
+RotateAndScaleDepthByWidth* RotateAndScaleDepthByWidth::clone()
+{
+ return new RotateAndScaleDepthByWidth(*this);
+}
+
+RotateAndScaleDepthByHeight* RotateAndScaleDepthByHeight::clone()
+{
+ return new RotateAndScaleDepthByHeight(*this);
+}
+
+const Primitive& Primitive::operator=(const Primitive& rvalue)
+{
+ for(unsigned int i( 0 ); i < rvalue.Operations.size(); ++i)
+ Operations.push_back(rvalue.Operations[i]->clone());
+ for(unsigned int i( 0 ); i < rvalue.Vertices.size(); ++i)//SPEED! use copy or something. this is slow.
+ Vertices.push_back(rvalue.Vertices[i]);
+ for(unsigned int i( 0 ); i < rvalue.TexCoords.size(); ++i)//SPEED! use copy or something. this is slow.
+ TexCoords.push_back(rvalue.TexCoords[i]);
+ for(unsigned int i( 0 ); i < rvalue.Normals.size(); ++i)//SPEED! use copy or something. this is slow.
+ Normals.push_back(rvalue.Normals[i]);
+ return *this;
+}
+
+Primitive::Primitive(const Primitive& rvalue)
+{
+ for(unsigned int i( 0 ); i < rvalue.Operations.size(); ++i)
+ Operations.push_back(rvalue.Operations[i]->clone());
+ for(unsigned int i( 0 ); i < rvalue.Vertices.size(); ++i)//SPEED! use copy or something. this is slow.
+ Vertices.push_back(rvalue.Vertices[i]);
+ for(unsigned int i( 0 ); i < rvalue.TexCoords.size(); ++i)//SPEED! use copy or something. this is slow.
+ TexCoords.push_back(rvalue.TexCoords[i]);
+ for(unsigned int i( 0 ); i < rvalue.Normals.size(); ++i)//SPEED! use copy or something. this is slow.
+ Normals.push_back(rvalue.Normals[i]);
+}
+
+void Primitive::pushTriangle(const basegfx::B2DVector& SlideLocation0,const basegfx::B2DVector& SlideLocation1,const basegfx::B2DVector& SlideLocation2)
+{
+ vector<basegfx::B3DVector> Verts;
+ vector<basegfx::B2DVector> Texs;
+ Verts.reserve(3);
+ Texs.reserve(3);
+
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation0.getX() - 1, -2*SlideLocation0.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation1.getX() - 1, -2*SlideLocation1.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation2.getX() - 1, -2*SlideLocation2.getY() + 1 , 0.0 ));
+
+ //figure out if they're facing the correct way, and make them face the correct way.
+ basegfx::B3DVector Normal( basegfx::cross( Verts[0] - Verts[1] , Verts[1] - Verts[2] ) );
+ if(Normal.getZ() >= 0.0)//if the normal is facing us
+ {
+ Texs.push_back(SlideLocation0);
+ Texs.push_back(SlideLocation1);
+ Texs.push_back(SlideLocation2);
+ }
+ else // if the normal is facing away from us, make it face us
+ {
+ Texs.push_back(SlideLocation0);
+ Texs.push_back(SlideLocation2);
+ Texs.push_back(SlideLocation1);
+ Verts.clear();
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation0.getX() - 1, -2*SlideLocation0.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation2.getX() - 1, -2*SlideLocation2.getY() + 1 , 0.0 ));
+ Verts.push_back(basegfx::B3DVector( 2*SlideLocation1.getX() - 1, -2*SlideLocation1.getY() + 1 , 0.0 ));
+ }
+
+ Vertices.push_back(Verts[0]);
+ Vertices.push_back(Verts[1]);
+ Vertices.push_back(Verts[2]);
+
+ TexCoords.push_back(Texs[0]);
+ TexCoords.push_back(Texs[1]);
+ TexCoords.push_back(Texs[2]);
+
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+ Normals.push_back(basegfx::B3DVector(0,0,1));//all normals always face the screen when untransformed.
+}
+
+void OGLTransitionImpl::makeDiamond()
+{
+ mmPrepare = &OGLTransitionImpl::prepareDiamond;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::prepareDiamond( double nTime, double /* SlideWidth */, double /* SlideHeight */, double /* DispWidth */, double /* DispHeight */ )
+{
+ Primitive Slide1, Slide2;
+
+ Slide1.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide1.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maEnteringSlidePrimitives.push_back (Slide1);
+
+
+ if( nTime >= 0.5 ) {
+ double m = 1 - nTime;
+
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (m,0), basegfx::B2DVector (0,m));
+ Slide2.pushTriangle (basegfx::B2DVector (nTime,0), basegfx::B2DVector (1,0), basegfx::B2DVector (1,m));
+ Slide2.pushTriangle (basegfx::B2DVector (1,nTime), basegfx::B2DVector (1,1), basegfx::B2DVector (nTime,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,nTime), basegfx::B2DVector (m,1), basegfx::B2DVector (0,1));
+ } else {
+ double l = 0.5 - nTime;
+ double h = 0.5 + nTime;
+
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0.5,l));
+ Slide2.pushTriangle (basegfx::B2DVector (0.5,l), basegfx::B2DVector (1,0), basegfx::B2DVector (h,0.5));
+ Slide2.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (1,1), basegfx::B2DVector (h,0.5));
+ Slide2.pushTriangle (basegfx::B2DVector (h,0.5), basegfx::B2DVector (1,1), basegfx::B2DVector (0.5,h));
+ Slide2.pushTriangle (basegfx::B2DVector (0.5,h), basegfx::B2DVector (1,1), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (l,0.5), basegfx::B2DVector (0.5,h), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (l,0.5), basegfx::B2DVector (0,1));
+ Slide2.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (0.5,l), basegfx::B2DVector (l,0.5));
+ }
+ Slide2.Operations.push_back (new STranslate (basegfx::B3DVector (0, 0, 0.00000001), false, -1, 0));
+ maLeavingSlidePrimitives.push_back (Slide2);
+}
+
+void OGLTransitionImpl::makeVenetianBlinds( bool vertical, int parts )
+{
+ static double t30 = tan( M_PI/6.0 );
+ double n, ln = 0;
+ double p = 1.0/parts;
+
+ for( int i=0; i<parts; i++ ) {
+ Primitive Slide;
+ n = (i + 1)/(double)parts;
+ if( vertical ) {
+ Slide.pushTriangle (basegfx::B2DVector (ln,0), basegfx::B2DVector (n,0), basegfx::B2DVector (ln,1));
+ Slide.pushTriangle (basegfx::B2DVector (n,0), basegfx::B2DVector (ln,1), basegfx::B2DVector (n,1));
+ Slide.Operations.push_back(new RotateAndScaleDepthByWidth(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(n + ln - 1, 0, -t30*p), -120, true, 0.0, 1.0));
+ } else {
+ Slide.pushTriangle (basegfx::B2DVector (0,ln), basegfx::B2DVector (1,ln), basegfx::B2DVector (0,n));
+ Slide.pushTriangle (basegfx::B2DVector (1,ln), basegfx::B2DVector (0,n), basegfx::B2DVector (1,n));
+ Slide.Operations.push_back(new RotateAndScaleDepthByHeight(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - n - ln, -t30*p), -120, true, 0.0, 1.0));
+ }
+ maLeavingSlidePrimitives.push_back (Slide);
+
+ if( vertical ) {
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(2*n - 1, 0, 0), -60, false, -1, 0));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0, 1, 0), basegfx::B3DVector(n + ln - 1, 0, 0), 180, false, -1, 0));
+ } else {
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - 2*n, 0), -60, false, -1, 0));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(1, 0, 0), basegfx::B3DVector(0, 1 - n - ln, 0), 180, false, -1, 0));
+ }
+ maEnteringSlidePrimitives.push_back (Slide);
+ ln = n;
+ }
+}
+
+void OGLTransitionImpl::displaySlidesFadeSmoothly( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_DEPTH_TEST);
+
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_LIGHTING);
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+ glColor4f( 1, 1, 1, nTime );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ glDisable(GL_BLEND);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
+ glEnable(GL_LIGHTING);
+
+ glEnable(GL_DEPTH_TEST);
+}
+
+void OGLTransitionImpl::makeFadeSmoothly()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesFadeSmoothly;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+void OGLTransitionImpl::displaySlidesFadeThroughBlack( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+ glDisable(GL_DEPTH_TEST);
+
+ glDisable(GL_LIGHTING);
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+ if( nTime < 0.5 ) {
+ glColor4f( 1, 1, 1, 1 - nTime*2 );
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ } else {
+ glColor4f( 1, 1, 1, (nTime - 0.5)*2 );
+ displaySlide( nTime, glEnteringSlideTex, maEnteringSlidePrimitives, SlideWidthScale, SlideHeightScale );
+ }
+ glDisable(GL_BLEND);
+ glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
+ glEnable(GL_LIGHTING);
+
+ glEnable(GL_DEPTH_TEST);
+}
+
+void OGLTransitionImpl::makeFadeThroughBlack()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesFadeThroughBlack;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+}
+
+static const char* basicVertexShader = "\n\
+varying vec2 v_texturePosition;\n\
+\n\
+void main( void )\n\
+{\n\
+ gl_Position = ftransform();\n\
+ v_texturePosition = gl_MultiTexCoord0.xy;\n\
+}\n\
+";
+
+static const char* staticFragmentShader = "\n\
+uniform sampler2D leavingSlideTexture;\n\
+uniform sampler2D enteringSlideTexture;\n\
+uniform sampler2D permTexture;\n\
+uniform float time;\n\
+varying vec2 v_texturePosition;\n\
+\n\
+float snoise(vec2 P) {\n\
+\n\
+ return texture2D(permTexture, P).r;\n\
+}\n\
+\n\
+\n\
+#define PART 0.5\n\
+#define START 0.4\n\
+#define END 0.9\n\
+\n\
+void main() {\n\
+ float sn = snoise(10.0*v_texturePosition+time*0.07);\n\
+ if( time < PART ) {\n\
+ float sn1 = snoise(vec2(time*15.0, 20.0*v_texturePosition.y));\n\
+ float sn2 = snoise(v_texturePosition);\n\
+ if (sn1 > 1.0 - time*time && sn2 < 2.0*time+0.1)\n\
+ gl_FragColor = vec4(sn, sn, sn, 1.0);\n\
+ else if (time > START )\n\
+ gl_FragColor = ((time-START)/(PART - START))*vec4(sn, sn, sn, 1.0) + (1.0 - (time - START)/(PART - START))*texture2D(leavingSlideTexture, v_texturePosition);\n\
+ else\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+ } else if ( time < PART ) {\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+ } else if ( time > END ) {\n\
+ gl_FragColor = ((1.0 - time)/(1.0 - END))*vec4(sn, sn, sn, 1.0) + ((time - END)/(1.0 - END))*texture2D(enteringSlideTexture, v_texturePosition);\n\
+ } else \n\
+ gl_FragColor = vec4(sn, sn, sn, 1.0);\n\
+}\n\
+";
+
+static const char* dissolveFragmentShader = "\n\
+uniform sampler2D leavingSlideTexture;\n\
+uniform sampler2D enteringSlideTexture;\n\
+uniform sampler2D permTexture;\n\
+uniform float time;\n\
+varying vec2 v_texturePosition;\n\
+\n\
+float snoise(vec2 P) {\n\
+\n\
+ return texture2D(permTexture, P).r;\n\
+}\n\
+\n\
+void main() {\n\
+ float sn = snoise(10.0*v_texturePosition);\n\
+ if( sn < time)\n\
+ gl_FragColor = texture2D(enteringSlideTexture, v_texturePosition);\n\
+ else\n\
+ gl_FragColor = texture2D(leavingSlideTexture, v_texturePosition);\n\
+}\n\
+";
+
+int permutation256 [256]= {
+215, 100, 200, 204, 233, 50, 85, 196,
+ 71, 141, 122, 160, 93, 131, 243, 234,
+162, 183, 36, 155, 4, 62, 35, 205,
+ 40, 102, 33, 27, 255, 55, 214, 156,
+ 75, 163, 134, 126, 249, 74, 197, 228,
+ 72, 90, 206, 235, 17, 22, 49, 169,
+227, 89, 16, 5, 117, 60, 248, 230,
+217, 68, 138, 96, 194, 170, 136, 10,
+112, 238, 184, 189, 176, 42, 225, 212,
+ 84, 58, 175, 244, 150, 168, 219, 236,
+101, 208, 123, 37, 164, 110, 158, 201,
+ 78, 114, 57, 48, 70, 142, 106, 43,
+232, 26, 32, 252, 239, 98, 191, 94,
+ 59, 149, 39, 187, 203, 190, 19, 13,
+133, 45, 61, 247, 23, 34, 20, 52,
+118, 209, 146, 193, 222, 18, 1, 152,
+ 46, 41, 91, 148, 115, 25, 135, 77,
+254, 147, 224, 161, 9, 213, 223, 250,
+231, 251, 127, 166, 63, 179, 81, 130,
+139, 28, 120, 151, 241, 86, 111, 0,
+ 88, 153, 172, 182, 159, 105, 178, 47,
+ 51, 167, 65, 66, 92, 73, 198, 211,
+245, 195, 31, 220, 140, 76, 221, 186,
+154, 185, 56, 83, 38, 165, 109, 67,
+124, 226, 132, 53, 229, 29, 12, 181,
+121, 24, 207, 199, 177, 113, 30, 80,
+ 3, 97, 188, 79, 216, 173, 8, 145,
+ 87, 128, 180, 237, 240, 137, 125, 104,
+ 15, 242, 119, 246, 103, 143, 95, 144,
+ 2, 44, 69, 157, 192, 174, 14, 54,
+218, 82, 64, 210, 11, 6, 129, 21,
+116, 171, 99, 202, 7, 107, 253, 108
+};
+
+void initPermTexture(GLuint *texID)
+{
+ glGenTextures(1, texID);
+ glBindTexture(GL_TEXTURE_2D, *texID);
+
+ static bool initialized = false;
+ static unsigned char permutation2D[256*256*4];
+ if( !initialized ) {
+ int x, y;
+
+ for( y=0; y < 256; y++ )
+ for( x=0; x < 256; x++ )
+ permutation2D[x*4 + y*1024] = permutation256[(y + permutation256[x]) & 0xff];
+
+ initialized = true;
+ }
+
+ glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_UNSIGNED_BYTE, permutation2D );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
+}
+
+void OGLTransitionImpl::preparePermShader()
+{
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ OGLShaders::glUseProgram( mProgramObject );
+
+ GLint location = OGLShaders::glGetUniformLocation( mProgramObject, "leavingSlideTexture" );
+ if( location != -1 ) {
+ OGLShaders::glUniform1i( location, 0 ); // texture unit 0
+ }
+
+ glActiveTexture(GL_TEXTURE1);
+ if( !maHelperTexture )
+ initPermTexture( &maHelperTexture );
+ glActiveTexture(GL_TEXTURE0);
+
+ location = OGLShaders::glGetUniformLocation( mProgramObject, "permTexture" );
+ if( location != -1 ) {
+ OGLShaders::glUniform1i( location, 1 ); // texture unit 1
+ }
+
+ location = OGLShaders::glGetUniformLocation( mProgramObject, "enteringSlideTexture" );
+ if( location != -1 ) {
+ OGLShaders::glUniform1i( location, 2 ); // texture unit 2
+ }
+ }
+#endif
+}
+
+void OGLTransitionImpl::prepareStatic( ::sal_Int32 /* glLeavingSlideTex */, ::sal_Int32 /* glEnteringSlideTex */ )
+{
+ mProgramObject = OGLShaders::LinkProgram( basicVertexShader, staticFragmentShader );
+
+ preparePermShader();
+}
+
+void OGLTransitionImpl::displaySlidesShaders( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex,
+ double SlideWidthScale, double SlideHeightScale )
+{
+ applyOverallOperations( nTime, SlideWidthScale, SlideHeightScale );
+
+#ifdef GL_VERSION_2_0
+ if( mProgramObject ) {
+ GLint location = OGLShaders::glGetUniformLocation( mProgramObject, "time" );
+ if( location != -1 ) {
+ OGLShaders::glUniform1f( location, nTime );
+ }
+ }
+
+ glActiveTexture( GL_TEXTURE2 );
+ glBindTexture( GL_TEXTURE_2D, glEnteringSlideTex );
+ glActiveTexture( GL_TEXTURE0 );
+#endif
+
+ displaySlide( nTime, glLeavingSlideTex, maLeavingSlidePrimitives, SlideWidthScale, SlideHeightScale );
+}
+
+void OGLTransitionImpl::makeStatic()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesShaders;
+ mmPrepareTransition = &OGLTransitionImpl::prepareStatic;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+
+ mnRequiredGLVersion = 2.0;
+}
+
+void OGLTransitionImpl::prepareDissolve( ::sal_Int32 /* glLeavingSlideTex */, ::sal_Int32 /* glEnteringSlideTex */ )
+{
+ mProgramObject = OGLShaders::LinkProgram( basicVertexShader, dissolveFragmentShader );
+
+ preparePermShader();
+}
+
+void OGLTransitionImpl::makeDissolve()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle (basegfx::B2DVector (0,0), basegfx::B2DVector (1,0), basegfx::B2DVector (0,1));
+ Slide.pushTriangle (basegfx::B2DVector (1,0), basegfx::B2DVector (0,1), basegfx::B2DVector (1,1));
+ maLeavingSlidePrimitives.push_back (Slide);
+ maEnteringSlidePrimitives.push_back (Slide);
+
+ mmDisplaySlides = &OGLTransitionImpl::displaySlidesShaders;
+ mmPrepareTransition = &OGLTransitionImpl::prepareDissolve;
+ mbUseMipMapLeaving = mbUseMipMapEntering = false;
+
+ mnRequiredGLVersion = 2.0;
+}
+
+void OGLTransitionImpl::makeNewsflash()
+{
+ Primitive Slide;
+
+ Slide.pushTriangle(basegfx::B2DVector(0,0),basegfx::B2DVector(1,0),basegfx::B2DVector(0,1));
+ Slide.pushTriangle(basegfx::B2DVector(1,0),basegfx::B2DVector(0,1),basegfx::B2DVector(1,1));
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0,0,0),3000,true,0,0.5));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(0.01,0.01,0.01),basegfx::B3DVector(0,0,0),true,0,0.5));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(-10000, 0, 0),false, 0.5, 2));
+ maLeavingSlidePrimitives.push_back(Slide);
+
+ Slide.Operations.clear();
+ Slide.Operations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0,0,0),-3000,true,0.5,1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(-100, 0, 0),false, -1, 1));
+ Slide.Operations.push_back(new STranslate(basegfx::B3DVector(100, 0, 0),false, 0.5, 1));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(0.01,0.01,0.01),basegfx::B3DVector(0,0,0),false,-1,1));
+ Slide.Operations.push_back(new SScale(basegfx::B3DVector(100,100,100),basegfx::B3DVector(0,0,0),true,0.5,1));
+ maEnteringSlidePrimitives.push_back(Slide);
+
+ OverallOperations.push_back(new SRotate(basegfx::B3DVector(0,0,1),basegfx::B3DVector(0.2,0.2,0),1080,true,0,1));
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.hxx b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.hxx
new file mode 100644
index 000000000..b67ab8854
--- /dev/null
+++ b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionImpl.hxx
@@ -0,0 +1,506 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+#ifndef INCLUDED_OGLTRANS_TRANSITIONIMPL_HXX_
+#define INCLUDED_OGLTRANS_TRANSITIONIMPL_HXX_
+
+#include <basegfx/vector/b2dvector.hxx>
+#include <basegfx/vector/b3dvector.hxx>
+
+#if defined( WNT )
+#elif defined( QUARTZ )
+#include <OpenGL/gl.h>
+#elif defined( UNX ) && !defined( QUARTZ )
+#endif
+
+#include <vector>
+
+#if !defined( QUARTZ )
+#include <GL/gl.h>
+#endif
+
+using namespace std;
+
+class Primitive;
+class Operation;
+class SceneObject;
+
+
+/** OpenGL 3D Transition class. It implicitly is constructed from XOGLTransition
+
+ This class is capable of making itself into many difference transitions. It holds Primitives and Operations on those primitives.
+*/
+class OGLTransitionImpl
+{
+public:
+ OGLTransitionImpl() :
+ mbUseMipMapLeaving( true ),
+ mbUseMipMapEntering( true ),
+ mnRequiredGLVersion( 1.0 ),
+ maLeavingSlidePrimitives(),
+ maEnteringSlidePrimitives(),
+ maSceneObjects(),
+ mbReflectSlides( false ),
+ mVertexObject( 0 ),
+ mFragmentObject( 0 ),
+ mProgramObject( 0 ),
+ maHelperTexture( 0 ),
+ mmPrepare( NULL ),
+ mmPrepareTransition( NULL ),
+ mmClearTransition( NULL ),
+ mmDisplaySlides( NULL )
+ {}
+
+ ~OGLTransitionImpl();
+
+ void prepare( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void display( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight );
+ void finish();
+
+ void makeOutsideCubeFaceToLeft();
+ void makeInsideCubeFaceToLeft();
+ void makeNByMTileFlip( ::sal_uInt16 n, ::sal_uInt16 m );
+ void makeRevolvingCircles( ::sal_uInt16 nCircles , ::sal_uInt16 nPointsOnCircles );
+ void makeHelix( ::sal_uInt16 nRows );
+ void makeFallLeaving();
+ void makeTurnAround();
+ void makeTurnDown();
+ void makeIris();
+ void makeRochade();
+ void makeVenetianBlinds( bool vertical, int parts );
+ void makeStatic();
+ void makeDissolve();
+ void makeNewsflash();
+
+ /** 2D replacements
+ */
+ void makeDiamond();
+ void makeFadeSmoothly();
+ void makeFadeThroughBlack();
+
+ /** Whether to use mipmaping for slides textures
+ */
+ bool mbUseMipMapLeaving;
+ bool mbUseMipMapEntering;
+
+ /** which GL version does the transition require
+ */
+ float mnRequiredGLVersion;
+
+private:
+ /** clears all the primitives and operations
+ */
+ void clear();
+
+ /** All the primitives that use the leaving slide texture
+ */
+ vector<Primitive> maLeavingSlidePrimitives;
+
+ /** All the primitives that use the leaving slide texture
+ */
+ vector<Primitive> maEnteringSlidePrimitives;
+
+ /** All the surrounding scene objects
+ */
+ vector<SceneObject*> maSceneObjects;
+
+ /** All the operations that should be applied to both leaving and entering slide primitives. These operations will be called in the order they were pushed back in. In OpenGL this effectively uses the operations in the opposite order they were pushed back.
+ */
+ vector<Operation*> OverallOperations;
+
+ /** Whether to reflect slides, the reflection happens on flat surface beneath the slides.
+ ** Now it only works with slides which keep their rectangular shape together.
+ */
+ bool mbReflectSlides;
+
+ /** GLSL objects, shaders and program
+ */
+ GLuint mVertexObject, mFragmentObject, mProgramObject;
+
+ /** various data */
+ GLuint maHelperTexture;
+
+ /** When this method is not NULL, it is called in display method to prepare the slides, scene, etc.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmPrepare)( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight );
+
+ /** When this method is not NULL, it is called after glx context is ready to let the transition prepare GL related things, like GLSL program.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmPrepareTransition)( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+
+ /** When this method is not NULL, it is called when the transition needs to clear after itself, like delete own textures etc.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmClearTransition)();
+
+ /** When this method is not NULL, it is called in display method to display the slides.
+ ** We might later replace this by cleaner derived class.
+ */
+ void (OGLTransitionImpl::*mmDisplaySlides)( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+
+ void displaySlides( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlide( double nTime, ::sal_Int32 glSlideTex, std::vector<Primitive>& primitives, double SlideWidthScale, double SlideHeightScale );
+ void displayScene( double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ void applyOverallOperations( double nTime, double SlideWidthScale, double SlideHeightScale );
+
+ /** various transitions helper methods
+ */
+ void prepareDiamond( double nTime, double SlideWidth, double SlideHeight,double DispWidth, double DispHeight );
+ void displaySlidesFadeSmoothly( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesFadeThroughBlack( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesRochade( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void displaySlidesShaders( double nTime, ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex, double SlideWidthScale, double SlideHeightScale );
+ void prepareStatic( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void prepareDissolve( ::sal_Int32 glLeavingSlideTex, ::sal_Int32 glEnteringSlideTex );
+ void preparePermShader();
+};
+
+class SceneObject
+{
+public:
+ SceneObject();
+
+ virtual void prepare() {};
+ virtual void display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ virtual void finish() {};
+
+ void pushPrimitive (const Primitive &p);
+
+protected:
+ /** All the surrounding scene primitives
+ */
+ vector<Primitive> maPrimitives;
+};
+
+class Iris : public SceneObject
+{
+public:
+ Iris ();
+
+ virtual void prepare();
+ virtual void display(double nTime, double SlideWidth, double SlideHeight, double DispWidth, double DispHeight);
+ virtual void finish();
+
+private:
+
+ GLuint maTexture;
+};
+
+/** This class is a list of Triangles that will share Operations, and could possibly share
+*/
+class Primitive
+{
+public:
+ Primitive() {}
+ // making copy constructor explicit makes the class un-suitable for use with stl containers
+ Primitive(const Primitive& rvalue);
+ ~Primitive();
+
+ void applyOperations(double nTime, double SlideWidthScale, double SlideHeightScale);
+ void display(double nTime, double SlideWidthScale, double SlideHeightScale);
+ const Primitive& operator=(const Primitive& rvalue);
+
+ /** PushBack a vertex,normal, and tex coord. Each SlideLocation is where on the slide is mapped to this location ( from (0,0) to (1,1) ). This will make sure the correct aspect ratio is used, and helps to make slides begin and end at the correct position. (0,0) is the top left of the slide, and (1,1) is the bottom right.
+
+ @param SlideLocation0
+ Location of first Vertex on slide
+
+ @param SlideLocation1
+ Location of second Vertex on slide
+
+ @param SlideLocation2
+ Location of third Vertex on slide
+
+ */
+ void pushTriangle(const basegfx::B2DVector& SlideLocation0,const basegfx::B2DVector& SlideLocation1,const basegfx::B2DVector& SlideLocation2);
+
+ /** clear all the vertices, normals, tex coordinates, and normals
+ */
+ void clearTriangles();
+
+ /** guards against directly changing the vertices
+
+ @return
+ the list of vertices
+ */
+ const vector<basegfx::B3DVector>& getVertices() const {return Vertices;}
+
+ /** guards against directly changing the vertices
+ */
+ const vector<basegfx::B3DVector>& getNormals() const {return Normals;}
+
+ /** guards against directly changing the vertices
+
+ @return
+ the list of Texture Coordinates
+
+ */
+ const vector<basegfx::B2DVector>& getTexCoords() const {return TexCoords;}
+
+ /** list of Operations to be performed on this primitive.These operations will be called in the order they were pushed back in. In OpenGL this effectively uses the operations in the opposite order they were pushed back.
+
+ @return
+ the list of Operations
+
+ */
+ vector<Operation*> Operations;
+
+private:
+ /** list of vertices
+ */
+ vector<basegfx::B3DVector> Vertices;
+
+ /** list of Normals
+ */
+ vector<basegfx::B3DVector> Normals;
+
+ /** list of Texture Coordinates
+ */
+ vector<basegfx::B2DVector> TexCoords;
+};
+
+/** This class is to be derived to make any operation (tranform) you may need in order to construct your transitions
+*/
+class Operation
+{
+public:
+ Operation(){}
+ virtual ~Operation(){}
+
+ /** Should this operation be interpolated . If TRUE, the transform will smoothly move from making no difference from t = 0.0 to nT0 to being completely transformed from t = nT1 to 1. If FALSE, the transform will be inneffectual from t = 0 to nT0, and completely transformed from t = nT0 to 1.
+ */
+ bool bInterpolate;
+
+ /** time to begin the transformation
+ */
+ double nT0;
+
+ /** time to finish the transformation
+ */
+ double nT1;
+public:
+ /** this is the function that is called to give the Operation to OpenGL.
+
+ @param t
+ time from t = 0 to t = 1
+
+ @param SlideWidthScale
+ width of slide divided by width of window
+
+ @param SlideHeightScale
+ height of slide divided by height of window
+
+ */
+ virtual void interpolate(double t,double SlideWidthScale,double SlideHeightScale) = 0;
+
+ /** return a copy of this operation
+ */
+ virtual Operation* clone() = 0;
+};
+
+/** this class is a generic CounterClockWise(CCW) rotation with an axis angle
+*/
+class SRotate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ virtual SRotate* clone();
+
+ /** Constructor
+
+ @param Axis
+ axis to rotate about
+
+ @param Origin
+ position that rotation axis runs through
+
+ @param Angle
+ angle in radians of CCW rotation
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SRotate(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~SRotate(){}
+private:
+ /** axis to rotate CCW about
+ */
+ basegfx::B3DVector axis;
+
+ /** position that rotation axis runs through
+ */
+ basegfx::B3DVector origin;
+
+ /** angle in radians of CCW rotation
+ */
+ double angle;
+};
+
+/** scaling transformation
+*/
+class SScale: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ SScale* clone();
+
+ /** Constructor
+
+ @param Scale
+ amount to scale by
+
+ @param Origin
+ position that rotation axis runs through
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SScale(const basegfx::B3DVector& Scale, const basegfx::B3DVector& Origin,bool bInter, double T0, double T1);
+ ~SScale(){}
+private:
+ basegfx::B3DVector scale;
+ basegfx::B3DVector origin;
+};
+
+/** translation transformation
+*/
+class STranslate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ STranslate* clone();
+
+ /** Constructor
+
+ @param Vector
+ vector to translate
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ STranslate(const basegfx::B3DVector& Vector,bool bInter, double T0, double T1);
+ ~STranslate(){}
+private:
+ /** vector to translate by
+ */
+ basegfx::B3DVector vector;
+};
+
+/** translation transformation
+*/
+class SEllipseTranslate: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ SEllipseTranslate* clone();
+
+ /** Constructor
+
+ @param Vector
+ vector to translate
+
+ @param bInter
+ see Operation
+
+ @param T0
+ transformation starting time
+
+ @param T1
+ transformation ending time
+
+ */
+ SEllipseTranslate(double dWidth, double dHeight, double dStartPosition, double dEndPosition, bool bInter, double T0, double T1);
+ ~SEllipseTranslate(){}
+private:
+ /** width and length of the ellipse
+ */
+ double width, height;
+
+ /** start and end position on the ellipse <0,1>
+ */
+ double startPosition;
+ double endPosition;
+};
+
+/** Same as SRotate, except the depth is scaled by the width of the slide divided by the width of the window.
+*/
+class RotateAndScaleDepthByWidth: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ RotateAndScaleDepthByWidth* clone();
+
+ RotateAndScaleDepthByWidth(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~RotateAndScaleDepthByWidth(){}
+private:
+ basegfx::B3DVector axis;
+ basegfx::B3DVector origin;
+ double angle;
+};
+
+/** Same as SRotate, except the depth is scaled by the width of the slide divided by the height of the window.
+*/
+class RotateAndScaleDepthByHeight: public Operation
+{
+public:
+ void interpolate(double t,double SlideWidthScale,double SlideHeightScale);
+ RotateAndScaleDepthByHeight* clone();
+
+ RotateAndScaleDepthByHeight(const basegfx::B3DVector& Axis,const basegfx::B3DVector& Origin,double Angle,bool bInter, double T0, double T1);
+ ~RotateAndScaleDepthByHeight(){}
+private:
+ basegfx::B3DVector axis;
+ basegfx::B3DVector origin;
+ double angle;
+};
+
+#endif // INCLUDED_SLIDESHOW_TRANSITION_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionerImpl.cxx b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionerImpl.cxx
index 7d5e1c78c..a46e73c59 100644
--- a/slideshow/source/engine/OGLTrans/OGLTrans_TransitionerImpl.cxx
+++ b/slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionerImpl.cxx
@@ -1,8 +1,9 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
- * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2008 by Sun Microsystems, Inc.
*
* OpenOffice.org - a multi-platform office productivity suite
*
@@ -52,34 +53,15 @@
#include <tools/gen.hxx>
#include <vcl/window.hxx>
#include <vcl/syschild.hxx>
+#include <vcl/sysdata.hxx>
#include <boost/noncopyable.hpp>
#include <GL/gl.h>
#include <GL/glu.h>
-
-#if defined( WNT )
- #include <tools/prewin.h>
- #include <windows.h>
- #include <tools/postwin.h>
- #define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
- #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
-#elif defined( OS2 )
-#elif defined( QUARTZ )
- #include "premac.h"
- #include <Cocoa/Cocoa.h>
- #include "postmac.h"
-#elif defined( UNX )
-namespace unx
-{
-#include <X11/keysym.h>
-#include <X11/X.h>
-#include <GL/glx.h>
-#include <GL/glxext.h>
-}
-#endif
-#include <vcl/sysdata.hxx>
+#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
+#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
#ifdef DEBUG
#include <boost/date_time/posix_time/posix_time.hpp>
@@ -210,22 +192,9 @@ private:
/// Holds the information of our new child window
struct GLWindow
{
-#if defined( WNT )
HWND hWnd;
HDC hDC;
HGLRC hRC;
-#elif defined( OS2 )
-#elif defined( QUARTZ )
-#elif defined( UNX )
- unx::Display* dpy;
- int screen;
- unx::Window win;
-#if defined( GLX_VERSION_1_3 ) && defined( GLX_EXT_texture_from_pixmap )
- unx::GLXFBConfig fbc;
-#endif
- unx::XVisualInfo* vi;
- unx::GLXContext ctx;
-#endif
unsigned int bpp;
unsigned int Width;
unsigned int Height;
@@ -487,13 +456,13 @@ bool OGLTransitionerImpl::createWindow( Window* pPWindow )
glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i],
GLX_BIND_TO_TEXTURE_RGB_EXT,
&value);
- if (value == FALSE)
+ if (value == sal_False)
continue;
glXGetFBConfigAttrib (GLWin.dpy, fbconfigs[i],
GLX_BIND_TO_MIPMAP_TEXTURE_EXT,
&value);
- if (value == FALSE)
+ if (value == sal_False)
continue;
/* TODO: handle non Y inverted cases */
@@ -517,7 +486,7 @@ bool OGLTransitionerImpl::createWindow( Window* pPWindow )
winData.nSize = sizeof(winData);
OSL_TRACE("using VisualID %08X", vi->visualid);
winData.pVisual = (void*)(vi->visual);
- pWindow=new SystemChildWindow(pPWindow, 0, &winData, FALSE);
+ pWindow=new SystemChildWindow(pPWindow, 0, &winData, sal_False);
pChildSysData = pWindow->GetSystemData();
if( pChildSysData ) {
break;
@@ -537,18 +506,18 @@ bool OGLTransitionerImpl::createWindow( Window* pPWindow )
const SystemEnvData* pChildSysData = NULL;
SystemWindowData winData;
winData.nSize = sizeof(winData);
- pWindow=new SystemChildWindow(pPWindow, 0, &winData, FALSE);
+ pWindow=new SystemChildWindow(pPWindow, 0, &winData, sal_False);
pChildSysData = pWindow->GetSystemData();
#endif
if( pWindow )
{
- pWindow->SetMouseTransparent( TRUE );
+ pWindow->SetMouseTransparent( sal_True );
pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP );
- pWindow->EnableEraseBackground( FALSE );
+ pWindow->EnableEraseBackground( sal_False );
pWindow->SetControlForeground();
pWindow->SetControlBackground();
- pWindow->EnablePaint(FALSE);
+ pWindow->EnablePaint(sal_False);
#if defined( WNT )
GLWin.hWnd = sysData->hWnd;
#elif defined( UNX )
@@ -1482,3 +1451,5 @@ namespace sdecl = comphelper::service_decl;
// The C shared lib entry points
COMPHELPER_SERVICEDECL_EXPORTS1(OGLTransitionFactoryDecl)
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/accumulation.hxx b/slideshow/source/engine/activities/accumulation.hxx
index b5b24c445..b8b317192 100644
--- a/slideshow/source/engine/activities/accumulation.hxx
+++ b/slideshow/source/engine/activities/accumulation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ACCUMULATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/activitiesfactory.cxx b/slideshow/source/engine/activities/activitiesfactory.cxx
index a4a670dd8..f4e748167 100644
--- a/slideshow/source/engine/activities/activitiesfactory.cxx
+++ b/slideshow/source/engine/activities/activitiesfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -660,8 +661,7 @@ AnimationActivitySharedPtr createActivity(
catch( ParseError& )
{
// parse error, thus no formula
- OSL_ENSURE( false,
- "createActivity(): Error parsing formula string" );
+ OSL_FAIL( "createActivity(): Error parsing formula string" );
}
}
@@ -727,7 +727,7 @@ AnimationActivitySharedPtr createActivity(
}
default:
- OSL_ENSURE( false, "createActivity(): unexpected case" );
+ OSL_FAIL( "createActivity(): unexpected case" );
// FALLTHROUGH intended
case animations::AnimationCalcMode::PACED:
// FALLTHROUGH intended
@@ -795,7 +795,7 @@ AnimationActivitySharedPtr createActivity(
}
default:
- OSL_ENSURE( false, "createActivity(): unexpected case" );
+ OSL_FAIL( "createActivity(): unexpected case" );
// FALLTHROUGH intended
case animations::AnimationCalcMode::PACED:
// FALLTHROUGH intended
@@ -985,3 +985,4 @@ AnimationActivitySharedPtr ActivitiesFactory::createSimpleActivity(
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/activitybase.cxx b/slideshow/source/engine/activities/activitybase.cxx
index b1d326e52..541e6e9e7 100644
--- a/slideshow/source/engine/activities/activitybase.cxx
+++ b/slideshow/source/engine/activities/activitybase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -244,3 +245,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/activitybase.hxx b/slideshow/source/engine/activities/activitybase.hxx
index 17479d4af..d521df178 100644
--- a/slideshow/source/engine/activities/activitybase.hxx
+++ b/slideshow/source/engine/activities/activitybase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -150,3 +151,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_ACTIVITYBASE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/activityparameters.hxx b/slideshow/source/engine/activities/activityparameters.hxx
index 3bd47e4bc..0bab1359e 100644
--- a/slideshow/source/engine/activities/activityparameters.hxx
+++ b/slideshow/source/engine/activities/activityparameters.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -141,3 +142,4 @@ struct ActivityParameters
#endif /* INCLUDED_SLIDESHOW_ACTIVITYPARAMETERS_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/continuousactivitybase.cxx b/slideshow/source/engine/activities/continuousactivitybase.cxx
index c11dc98f6..e6129d77a 100644
--- a/slideshow/source/engine/activities/continuousactivitybase.cxx
+++ b/slideshow/source/engine/activities/continuousactivitybase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/continuousactivitybase.hxx b/slideshow/source/engine/activities/continuousactivitybase.hxx
index dac552f5c..6ef84dd0e 100644
--- a/slideshow/source/engine/activities/continuousactivitybase.hxx
+++ b/slideshow/source/engine/activities/continuousactivitybase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_CONTINUOUSACTIVITYBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/continuouskeytimeactivitybase.cxx b/slideshow/source/engine/activities/continuouskeytimeactivitybase.cxx
index facfedec5..78b5b6f44 100644
--- a/slideshow/source/engine/activities/continuouskeytimeactivitybase.cxx
+++ b/slideshow/source/engine/activities/continuouskeytimeactivitybase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/continuouskeytimeactivitybase.hxx b/slideshow/source/engine/activities/continuouskeytimeactivitybase.hxx
index 5d133e857..427fea36b 100644
--- a/slideshow/source/engine/activities/continuouskeytimeactivitybase.hxx
+++ b/slideshow/source/engine/activities/continuouskeytimeactivitybase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -81,3 +82,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_CONTINUOUSKEYTIMEACTIVITYBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/discreteactivitybase.cxx b/slideshow/source/engine/activities/discreteactivitybase.cxx
index 32bf0494d..949f0c8a8 100644
--- a/slideshow/source/engine/activities/discreteactivitybase.cxx
+++ b/slideshow/source/engine/activities/discreteactivitybase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -204,3 +205,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/discreteactivitybase.hxx b/slideshow/source/engine/activities/discreteactivitybase.hxx
index d728335b9..de4c11aee 100644
--- a/slideshow/source/engine/activities/discreteactivitybase.hxx
+++ b/slideshow/source/engine/activities/discreteactivitybase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,3 +86,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DISCRETEACTIVITYBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/interpolation.hxx b/slideshow/source/engine/activities/interpolation.hxx
index c51998bd6..97e13822f 100644
--- a/slideshow/source/engine/activities/interpolation.hxx
+++ b/slideshow/source/engine/activities/interpolation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,8 +56,7 @@ namespace basegfx
const sal_Int16& rTo,
double )
{
- OSL_ENSURE( false,
- "lerp<sal_Int16> called" );
+ OSL_FAIL( "lerp<sal_Int16> called" );
return rTo;
}
@@ -65,8 +65,7 @@ namespace basegfx
const ::rtl::OUString& rTo,
double )
{
- OSL_ENSURE( false,
- "lerp<::rtl::OUString> called" );
+ OSL_FAIL( "lerp<::rtl::OUString> called" );
return rTo;
}
@@ -75,8 +74,7 @@ namespace basegfx
const bool& rTo,
double )
{
- OSL_ENSURE( false,
- "lerp<bool> called" );
+ OSL_FAIL( "lerp<bool> called" );
return rTo;
}
}
@@ -192,3 +190,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_INTERPOLATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/makefile.mk b/slideshow/source/engine/activities/makefile.mk
deleted file mode 100644
index fc24b4042..000000000
--- a/slideshow/source/engine/activities/makefile.mk
+++ /dev/null
@@ -1,53 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=activities
-ENABLE_EXCEPTIONS=TRUE
-PRJINC=..$/..
-
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-SLOFILES = $(SLO)$/activitybase.obj \
- $(SLO)$/activitiesfactory.obj \
- $(SLO)$/continuousactivitybase.obj \
- $(SLO)$/continuouskeytimeactivitybase.obj \
- $(SLO)$/discreteactivitybase.obj \
- $(SLO)$/simplecontinuousactivitybase.obj
-
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/activities/simplecontinuousactivitybase.cxx b/slideshow/source/engine/activities/simplecontinuousactivitybase.cxx
index b2139621c..e391a0fdb 100644
--- a/slideshow/source/engine/activities/simplecontinuousactivitybase.cxx
+++ b/slideshow/source/engine/activities/simplecontinuousactivitybase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -256,3 +257,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activities/simplecontinuousactivitybase.hxx b/slideshow/source/engine/activities/simplecontinuousactivitybase.hxx
index a309be1cb..73d6b0b68 100644
--- a/slideshow/source/engine/activities/simplecontinuousactivitybase.hxx
+++ b/slideshow/source/engine/activities/simplecontinuousactivitybase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -85,3 +86,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SIMPLECONTINUOUSACTIVITYBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/activitiesqueue.cxx b/slideshow/source/engine/activitiesqueue.cxx
index 253d71c0b..c9d790035 100644
--- a/slideshow/source/engine/activitiesqueue.cxx
+++ b/slideshow/source/engine/activitiesqueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,7 +73,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -140,8 +141,7 @@ namespace slideshow
// since this will also capture segmentation
// violations and the like. In such a case, we
// still better let our clients now...
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -208,3 +208,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animatedsprite.cxx b/slideshow/source/engine/animatedsprite.cxx
index 5184c2ed7..d4188b6a7 100644
--- a/slideshow/source/engine/animatedsprite.cxx
+++ b/slideshow/source/engine/animatedsprite.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -223,3 +224,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationfactory.cxx b/slideshow/source/engine/animationfactory.cxx
index 4af5d8dfb..6e7ab28ec 100644
--- a/slideshow/source/engine/animationfactory.cxx
+++ b/slideshow/source/engine/animationfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -591,6 +592,13 @@ namespace slideshow
bool mbAnimationStarted;
};
+ //Current c++0x draft (apparently) has std::identity, but not operator()
+ template<typename T> struct SGI_identity : public std::unary_function<T,T>
+ {
+ T& operator()(T& x) const { return x; }
+ const T& operator()(const T& x) const { return x; }
+ };
+
/** Function template wrapper around GenericAnimation template
@tpl AnimationBase
@@ -607,7 +615,7 @@ namespace slideshow
{
return ::boost::shared_ptr< AnimationBase >(
new GenericAnimation< AnimationBase,
- ::std::identity< typename AnimationBase::ValueType > >(
+ SGI_identity< typename AnimationBase::ValueType > >(
rShapeManager,
nFlags,
pIsValid,
@@ -615,8 +623,8 @@ namespace slideshow
pGetValue,
pSetValue,
// no modification necessary, use identity functor here
- ::std::identity< typename AnimationBase::ValueType >(),
- ::std::identity< typename AnimationBase::ValueType >() ) );
+ SGI_identity< typename AnimationBase::ValueType >(),
+ SGI_identity< typename AnimationBase::ValueType >() ) );
}
class Scaler
@@ -685,7 +693,7 @@ namespace slideshow
if( !rAny.hasValue() )
{
- OSL_ENSURE( false, "getDefault(): cannot get requested shape property" );
+ OSL_FAIL( "getDefault(): cannot get requested shape property" );
OSL_TRACE( "getDefault(): cannot get '%s' shape property",
::rtl::OUStringToOString( rPropertyName,
RTL_TEXTENCODING_ASCII_US ).getStr() );
@@ -697,7 +705,7 @@ namespace slideshow
if( !(rAny >>= aValue) )
{
- OSL_ENSURE( false, "getDefault(): cannot extract requested shape property" );
+ OSL_FAIL( "getDefault(): cannot extract requested shape property" );
OSL_TRACE( "getDefault(): cannot extract '%s' shape property",
::rtl::OUStringToOString( rPropertyName,
RTL_TEXTENCODING_ASCII_US ).getStr() );
@@ -716,7 +724,7 @@ namespace slideshow
if( !rAny.hasValue() )
{
- OSL_ENSURE( false, "getDefault(): cannot get requested shape color property" );
+ OSL_FAIL( "getDefault(): cannot get requested shape color property" );
OSL_TRACE( "getDefault(): cannot get '%s' shape color property",
::rtl::OUStringToOString( rPropertyName,
RTL_TEXTENCODING_ASCII_US ).getStr() );
@@ -728,7 +736,7 @@ namespace slideshow
if( !(rAny >>= nValue) )
{
- OSL_ENSURE( false, "getDefault(): cannot extract requested shape color property" );
+ OSL_FAIL( "getDefault(): cannot extract requested shape color property" );
OSL_TRACE( "getDefault(): cannot extract '%s' shape color property",
::rtl::OUStringToOString( rPropertyName,
RTL_TEXTENCODING_ASCII_US ).getStr() );
@@ -1384,3 +1392,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationaudionode.cxx b/slideshow/source/engine/animationnodes/animationaudionode.cxx
index bcd694d8d..a03336650 100644
--- a/slideshow/source/engine/animationnodes/animationaudionode.cxx
+++ b/slideshow/source/engine/animationnodes/animationaudionode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -179,3 +180,4 @@ bool AnimationAudioNode::handleAnimationEvent(
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationaudionode.hxx b/slideshow/source/engine/animationnodes/animationaudionode.hxx
index 1fd2e4699..35397557d 100644
--- a/slideshow/source/engine/animationnodes/animationaudionode.hxx
+++ b/slideshow/source/engine/animationnodes/animationaudionode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ private:
} // namespace slideshow
#endif /* INCLUDED_SLIDESHOW_ANIMATIONAUDIONODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationbasenode.cxx b/slideshow/source/engine/animationnodes/animationbasenode.cxx
index fd3549a5f..10700502d 100644
--- a/slideshow/source/engine/animationnodes/animationbasenode.cxx
+++ b/slideshow/source/engine/animationnodes/animationbasenode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -216,7 +217,7 @@ bool AnimationBaseNode::init_st()
mpActivity = createActivity();
}
catch (uno::Exception const&) {
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(cppu::getCaughtException()),
RTL_TEXTENCODING_UTF8 ) );
// catch and ignore. We later handle empty activities, but for
@@ -488,3 +489,4 @@ AttributableShapeSharedPtr AnimationBaseNode::getShape() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationbasenode.hxx b/slideshow/source/engine/animationnodes/animationbasenode.hxx
index e34a86d70..aac9f3a0c 100644
--- a/slideshow/source/engine/animationnodes/animationbasenode.hxx
+++ b/slideshow/source/engine/animationnodes/animationbasenode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -109,3 +110,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_ANIMATIONBASENODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationcolornode.cxx b/slideshow/source/engine/animationnodes/animationcolornode.cxx
index f459de2d5..5bd25ec26 100644
--- a/slideshow/source/engine/animationnodes/animationcolornode.cxx
+++ b/slideshow/source/engine/animationnodes/animationcolornode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -135,3 +136,4 @@ AnimationActivitySharedPtr AnimationColorNode::createActivity() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationcolornode.hxx b/slideshow/source/engine/animationnodes/animationcolornode.hxx
index dc203115f..dfa9f60cf 100644
--- a/slideshow/source/engine/animationnodes/animationcolornode.hxx
+++ b/slideshow/source/engine/animationnodes/animationcolornode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ private:
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_ANIMATIONCOLORNODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationcommandnode.cxx b/slideshow/source/engine/animationnodes/animationcommandnode.cxx
index 5be8e4985..6717b5fd7 100644
--- a/slideshow/source/engine/animationnodes/animationcommandnode.cxx
+++ b/slideshow/source/engine/animationnodes/animationcommandnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -132,3 +133,5 @@ bool AnimationCommandNode::hasPendingAnimation() const
} // namespace internal
} // namespace slideshow
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationcommandnode.hxx b/slideshow/source/engine/animationnodes/animationcommandnode.hxx
index 87a38926b..94b10fd44 100644
--- a/slideshow/source/engine/animationnodes/animationcommandnode.hxx
+++ b/slideshow/source/engine/animationnodes/animationcommandnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,5 @@ private:
} // namespace slideshow
#endif /* INCLUDED_SLIDESHOW_ANIMATIONAUDIONODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationnodefactory.cxx b/slideshow/source/engine/animationnodes/animationnodefactory.cxx
index a3bdf9717..feeb9aeec 100644
--- a/slideshow/source/engine/animationnodes/animationnodefactory.cxx
+++ b/slideshow/source/engine/animationnodes/animationnodefactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -370,8 +371,7 @@ bool implCreateIteratedNodes(
{
// will not animate the whole paragraph, when
// only the paragraph is animated at all.
- OSL_ENSURE( false,
- "implCreateIteratedNodes(): Ignoring paragraph iteration for paragraph master" );
+ OSL_FAIL( "implCreateIteratedNodes(): Ignoring paragraph iteration for paragraph master" );
}
else
{
@@ -474,7 +474,7 @@ BaseNodeSharedPtr implCreateAnimationNode(
switch( xNode->getType() )
{
case animations::AnimationNodeType::CUSTOM:
- OSL_ENSURE( false, "implCreateAnimationNode(): "
+ OSL_FAIL( "implCreateAnimationNode(): "
"CUSTOM not yet implemented" );
return pCreatedNode;
@@ -537,7 +537,7 @@ BaseNodeSharedPtr implCreateAnimationNode(
break;
default:
- OSL_ENSURE( false, "implCreateAnimationNode(): "
+ OSL_FAIL( "implCreateAnimationNode(): "
"invalid AnimationNodeType" );
return pCreatedNode;
}
@@ -578,7 +578,7 @@ BaseNodeSharedPtr implCreateAnimationNode(
NodeCreator aCreator( pCreatedContainer, rContext );
if( !::anim::for_each_childNode( xNode, aCreator ) )
{
- OSL_ENSURE( false, "implCreateAnimationNode(): "
+ OSL_FAIL( "implCreateAnimationNode(): "
"child node creation failed" );
return BaseNodeSharedPtr();
}
@@ -618,3 +618,4 @@ void AnimationNodeFactory::showTree( AnimationNodeSharedPtr& pRootNode )
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationpathmotionnode.cxx b/slideshow/source/engine/animationnodes/animationpathmotionnode.cxx
index 56b4fdaed..7e90f3abf 100644
--- a/slideshow/source/engine/animationnodes/animationpathmotionnode.cxx
+++ b/slideshow/source/engine/animationnodes/animationpathmotionnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,3 +66,4 @@ AnimationActivitySharedPtr AnimationPathMotionNode::createActivity() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationpathmotionnode.hxx b/slideshow/source/engine/animationnodes/animationpathmotionnode.hxx
index 8916dfc43..c0e11d818 100644
--- a/slideshow/source/engine/animationnodes/animationpathmotionnode.hxx
+++ b/slideshow/source/engine/animationnodes/animationpathmotionnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ private:
} // namespace slideshow
#endif /* INCLUDED_SLIDESHOW_ANIMATIONPATHMOTIONNODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationsetnode.cxx b/slideshow/source/engine/animationnodes/animationsetnode.cxx
index 4fea17017..5bf744ecb 100644
--- a/slideshow/source/engine/animationnodes/animationsetnode.cxx
+++ b/slideshow/source/engine/animationnodes/animationsetnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -211,3 +212,4 @@ AnimationActivitySharedPtr AnimationSetNode::createActivity() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationsetnode.hxx b/slideshow/source/engine/animationnodes/animationsetnode.hxx
index b718e23c6..f84f831d3 100644
--- a/slideshow/source/engine/animationnodes/animationsetnode.hxx
+++ b/slideshow/source/engine/animationnodes/animationsetnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_ANIMATIONSETNODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationtransformnode.cxx b/slideshow/source/engine/animationnodes/animationtransformnode.cxx
index bc88d1d92..fa83ea7fc 100644
--- a/slideshow/source/engine/animationnodes/animationtransformnode.cxx
+++ b/slideshow/source/engine/animationnodes/animationtransformnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -112,3 +113,5 @@ AnimationActivitySharedPtr AnimationTransformNode::createActivity() const
} // namespace internal
} // namespace slideshow
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationtransformnode.hxx b/slideshow/source/engine/animationnodes/animationtransformnode.hxx
index 6a8f30f2e..c24030f73 100644
--- a/slideshow/source/engine/animationnodes/animationtransformnode.hxx
+++ b/slideshow/source/engine/animationnodes/animationtransformnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ private:
} // namespace slideshow
#endif /* INCLUDED_SLIDESHOW_ANIMATIONTRANSFORMNODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationtransitionfilternode.cxx b/slideshow/source/engine/animationnodes/animationtransitionfilternode.cxx
index 382167509..709685633 100644
--- a/slideshow/source/engine/animationnodes/animationtransitionfilternode.cxx
+++ b/slideshow/source/engine/animationnodes/animationtransitionfilternode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ AnimationTransitionFilterNode::createActivity() const
} // namespace internal
} // namespace slideshow
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/animationtransitionfilternode.hxx b/slideshow/source/engine/animationnodes/animationtransitionfilternode.hxx
index dd0ffe2a8..05a8802c4 100644
--- a/slideshow/source/engine/animationnodes/animationtransitionfilternode.hxx
+++ b/slideshow/source/engine/animationnodes/animationtransitionfilternode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,3 +66,5 @@ private:
} // namespace slideshow
#endif /* INCLUDED_SLIDESHOW_ANIMATIONTRANSITIONFILTERNODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/basecontainernode.cxx b/slideshow/source/engine/animationnodes/basecontainernode.cxx
index da99624e0..3cb8a3609 100644
--- a/slideshow/source/engine/animationnodes/basecontainernode.cxx
+++ b/slideshow/source/engine/animationnodes/basecontainernode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -132,7 +133,7 @@ bool BaseContainerNode::notifyDeactivatedChild(
return false;
if (! isChildNode(pChildNode)) {
- OSL_ENSURE( false, "unknown notifier!" );
+ OSL_FAIL( "unknown notifier!" );
return false;
}
@@ -173,3 +174,4 @@ void BaseContainerNode::showState() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/basecontainernode.hxx b/slideshow/source/engine/animationnodes/basecontainernode.hxx
index 99d32f8cc..3015694a2 100644
--- a/slideshow/source/engine/animationnodes/basecontainernode.hxx
+++ b/slideshow/source/engine/animationnodes/basecontainernode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -103,3 +104,4 @@ typedef ::boost::shared_ptr< BaseContainerNode > BaseContainerNodeSharedPtr;
#endif /* INCLUDED_SLIDESHOW_BASECONTAINERNODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/basenode.cxx b/slideshow/source/engine/animationnodes/basenode.cxx
index 61ec04ae1..a8bc7c758 100644
--- a/slideshow/source/engine/animationnodes/basenode.cxx
+++ b/slideshow/source/engine/animationnodes/basenode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -217,8 +218,8 @@ const int* getStateTransitionTable( sal_Int16 nRestartMode,
default:
case animations::AnimationRestart::DEFAULT:
// same value: animations::AnimationRestart::INHERIT:
- OSL_ENSURE(
- false, "getStateTransitionTable(): unexpected case for restart" );
+ OSL_FAIL(
+ "getStateTransitionTable(): unexpected case for restart" );
// FALLTHROUGH intended
case animations::AnimationRestart::NEVER:
nRestartValue = 0;
@@ -237,8 +238,8 @@ const int* getStateTransitionTable( sal_Int16 nRestartMode,
case animations::AnimationFill::AUTO:
case animations::AnimationFill::DEFAULT:
// same value: animations::AnimationFill::INHERIT:
- OSL_ENSURE(
- false, "getStateTransitionTable(): unexpected case for fill" );
+ OSL_FAIL(
+ "getStateTransitionTable(): unexpected case for fill" );
// FALLTHROUGH intended
case animations::AnimationFill::REMOVE:
nFillValue = 0;
@@ -767,3 +768,4 @@ void BaseNode::showTreeFromWithin() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/basenode.hxx b/slideshow/source/engine/animationnodes/basenode.hxx
index 12d7e4789..ceb6b2331 100644
--- a/slideshow/source/engine/animationnodes/basenode.hxx
+++ b/slideshow/source/engine/animationnodes/basenode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -227,3 +228,4 @@ typedef ::boost::shared_ptr< BaseNode > BaseNodeSharedPtr;
#endif /* INCLUDED_SLIDESHOW_BASENODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/generateevent.cxx b/slideshow/source/engine/animationnodes/generateevent.cxx
index ed1b87681..909997e6d 100644
--- a/slideshow/source/engine/animationnodes/generateevent.cxx
+++ b/slideshow/source/engine/animationnodes/generateevent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,7 +72,7 @@ EventSharedPtr generateEvent(
case animations::Timing_INDEFINITE:
break; // don't schedule no event
case animations::Timing_MEDIA:
- OSL_ENSURE( false, "MEDIA timing not yet implemented!" );
+ OSL_FAIL( "MEDIA timing not yet implemented!" );
break;
default:
ENSURE_OR_THROW( false, "unexpected case!" );
@@ -82,7 +83,7 @@ EventSharedPtr generateEvent(
// try to extract additional event delay
double nDelay2 = 0.0;
if (aEvent.Offset.hasValue() && !(aEvent.Offset >>= nDelay2)) {
- OSL_ENSURE( false, "offset values apart from DOUBLE not "
+ OSL_FAIL( "offset values apart from DOUBLE not "
"recognized in animations::Event!" );
}
@@ -100,10 +101,10 @@ EventSharedPtr generateEvent(
// no event at all
break;
case animations::EventTrigger::ON_BEGIN:
- OSL_ENSURE( false, "event trigger ON_BEGIN not yet implemented!" );
+ OSL_FAIL( "event trigger ON_BEGIN not yet implemented!" );
break;
case animations::EventTrigger::ON_END:
- OSL_ENSURE( false, "event trigger ON_END not yet implemented!" );
+ OSL_FAIL( "event trigger ON_END not yet implemented!" );
break;
case animations::EventTrigger::BEGIN_EVENT:
// try to extract XAnimationNode event source
@@ -115,7 +116,7 @@ EventSharedPtr generateEvent(
pEvent, xNode );
}
else {
- OSL_ENSURE(false, "could not extract source XAnimationNode "
+ OSL_FAIL("could not extract source XAnimationNode "
"for BEGIN_EVENT!" );
}
break;
@@ -129,7 +130,7 @@ EventSharedPtr generateEvent(
pEvent, xNode );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for END_EVENT!" );
}
break;
@@ -145,7 +146,7 @@ EventSharedPtr generateEvent(
pEvent, pShape );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for ON_CLICK!" );
}
break;
@@ -161,7 +162,7 @@ EventSharedPtr generateEvent(
pEvent, pShape );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for ON_DBL_CLICK!" );
}
break;
@@ -177,7 +178,7 @@ EventSharedPtr generateEvent(
pEvent, pShape );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for ON_MOUSE_ENTER!" );
}
break;
@@ -193,12 +194,12 @@ EventSharedPtr generateEvent(
pEvent, pShape );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for ON_MOUSE_LEAVE!" );
}
break;
case animations::EventTrigger::ON_PREV:
- OSL_ENSURE( false, "event trigger ON_PREV not yet implemented, "
+ OSL_FAIL( "event trigger ON_PREV not yet implemented, "
"mapped to ON_NEXT!" );
// FALLTHROUGH intended
case animations::EventTrigger::ON_NEXT:
@@ -217,17 +218,17 @@ EventSharedPtr generateEvent(
pEvent, xNode );
}
else {
- OSL_ENSURE( false, "could not extract source XAnimationNode "
+ OSL_FAIL( "could not extract source XAnimationNode "
"for ON_STOP_AUDIO!" );
}
break;
case animations::EventTrigger::REPEAT:
- OSL_ENSURE( false, "event trigger REPEAT not yet implemented!" );
+ OSL_FAIL( "event trigger REPEAT not yet implemented!" );
break;
}
}
else if (rEventDescription >>= aSequence) {
- OSL_ENSURE( false, "sequence of timing primitives "
+ OSL_FAIL( "sequence of timing primitives "
"not yet implemented!" );
}
else if (rEventDescription >>= nDelay1) {
@@ -244,3 +245,4 @@ EventSharedPtr generateEvent(
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/generateevent.hxx b/slideshow/source/engine/animationnodes/generateevent.hxx
index 2b7c761bc..fcadee19d 100644
--- a/slideshow/source/engine/animationnodes/generateevent.hxx
+++ b/slideshow/source/engine/animationnodes/generateevent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,4 @@ EventSharedPtr generateEvent(
#endif /* INCLUDED_SLIDESHOW_GENERATEEVENT_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/makefile.mk b/slideshow/source/engine/animationnodes/makefile.mk
deleted file mode 100644
index fc1c80352..000000000
--- a/slideshow/source/engine/animationnodes/makefile.mk
+++ /dev/null
@@ -1,61 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=animationnodes
-ENABLE_EXCEPTIONS=TRUE
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-SLOFILES = $(SLO)$/animationaudionode.obj \
- $(SLO)$/animationcommandnode.obj \
- $(SLO)$/animationbasenode.obj \
- $(SLO)$/animationcolornode.obj \
- $(SLO)$/animationnodefactory.obj \
- $(SLO)$/animationpathmotionnode.obj \
- $(SLO)$/animationsetnode.obj \
- $(SLO)$/animationtransformnode.obj \
- $(SLO)$/animationtransitionfilternode.obj \
- $(SLO)$/basecontainernode.obj \
- $(SLO)$/basenode.obj \
- $(SLO)$/nodetools.obj \
- $(SLO)$/paralleltimecontainer.obj \
- $(SLO)$/propertyanimationnode.obj \
- $(SLO)$/sequentialtimecontainer.obj \
- $(SLO)$/generateevent.obj
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/animationnodes/nodetools.cxx b/slideshow/source/engine/animationnodes/nodetools.cxx
index 8ae7e5c9b..ce7fab6d3 100644
--- a/slideshow/source/engine/animationnodes/nodetools.cxx
+++ b/slideshow/source/engine/animationnodes/nodetools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -126,3 +127,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/nodetools.hxx b/slideshow/source/engine/animationnodes/nodetools.hxx
index a790c78b4..ed02ddc24 100644
--- a/slideshow/source/engine/animationnodes/nodetools.hxx
+++ b/slideshow/source/engine/animationnodes/nodetools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -86,3 +87,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_NODETOOLS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/paralleltimecontainer.cxx b/slideshow/source/engine/animationnodes/paralleltimecontainer.cxx
index 54457247f..766c0e9ad 100644
--- a/slideshow/source/engine/animationnodes/paralleltimecontainer.cxx
+++ b/slideshow/source/engine/animationnodes/paralleltimecontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,4 @@ void ParallelTimeContainer::notifyDeactivating(
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/paralleltimecontainer.hxx b/slideshow/source/engine/animationnodes/paralleltimecontainer.hxx
index 3e9c2e301..3387ca8b6 100644
--- a/slideshow/source/engine/animationnodes/paralleltimecontainer.hxx
+++ b/slideshow/source/engine/animationnodes/paralleltimecontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,3 +62,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_PARALLELTIMECONTAINER_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/propertyanimationnode.cxx b/slideshow/source/engine/animationnodes/propertyanimationnode.cxx
index 2063569fa..288a9b87c 100644
--- a/slideshow/source/engine/animationnodes/propertyanimationnode.cxx
+++ b/slideshow/source/engine/animationnodes/propertyanimationnode.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -113,3 +114,4 @@ AnimationActivitySharedPtr PropertyAnimationNode::createActivity() const
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/propertyanimationnode.hxx b/slideshow/source/engine/animationnodes/propertyanimationnode.hxx
index 1a87c93a6..8c542774d 100644
--- a/slideshow/source/engine/animationnodes/propertyanimationnode.hxx
+++ b/slideshow/source/engine/animationnodes/propertyanimationnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_PROPERTYANIMATIONNODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/sequentialtimecontainer.cxx b/slideshow/source/engine/animationnodes/sequentialtimecontainer.cxx
index f70828d09..269e0beae 100644
--- a/slideshow/source/engine/animationnodes/sequentialtimecontainer.cxx
+++ b/slideshow/source/engine/animationnodes/sequentialtimecontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,7 +52,7 @@ void SequentialTimeContainer::activate_st()
break;
else {
// node still UNRESOLVED, no need to deactivate or end...
- OSL_ENSURE( false, "### resolving child failed!" );
+ OSL_FAIL( "### resolving child failed!" );
}
}
@@ -93,7 +94,7 @@ void SequentialTimeContainer::skipEffect(
"SequentialTimeContainer::deactivate, skipEffect with delay") );
}
else
- OSL_ENSURE( false, "unknown notifier!" );
+ OSL_FAIL( "unknown notifier!" );
}
void SequentialTimeContainer::rewindEffect(
@@ -160,3 +161,4 @@ void SequentialTimeContainer::notifyDeactivating(
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/sequentialtimecontainer.hxx b/slideshow/source/engine/animationnodes/sequentialtimecontainer.hxx
index 1fc4b3b8a..878b0f34f 100644
--- a/slideshow/source/engine/animationnodes/sequentialtimecontainer.hxx
+++ b/slideshow/source/engine/animationnodes/sequentialtimecontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_SEQUENTIALTIMECONTAINER_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/animationnodes/setactivity.hxx b/slideshow/source/engine/animationnodes/setactivity.hxx
index 86f65f336..76d750f2b 100644
--- a/slideshow/source/engine/animationnodes/setactivity.hxx
+++ b/slideshow/source/engine/animationnodes/setactivity.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -153,3 +154,5 @@ template <class AnimationT> AnimationActivitySharedPtr makeSetActivity(
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_SETACTIVITY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/attributemap.cxx b/slideshow/source/engine/attributemap.cxx
index 9d3cc2734..ecf01a629 100644
--- a/slideshow/source/engine/attributemap.cxx
+++ b/slideshow/source/engine/attributemap.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,49 +55,28 @@ namespace slideshow
static AnimateAttributeMap::MapEntry lcl_attributeMap[] =
{
{ "charcolor", ATTRIBUTE_CHAR_COLOR },
-
{ "charfontname", ATTRIBUTE_CHAR_FONT_NAME },
-
{ "charheight", ATTRIBUTE_CHAR_HEIGHT },
-
{ "charposture", ATTRIBUTE_CHAR_POSTURE },
-
// TODO(Q1): This should prolly be changed in PPT import
// { "charrotation", ATTRIBUTE_CHAR_ROTATION },
{ "charrotation", ATTRIBUTE_ROTATE },
-
{ "charunderline", ATTRIBUTE_CHAR_UNDERLINE },
-
{ "charweight", ATTRIBUTE_CHAR_WEIGHT },
-
{ "color", ATTRIBUTE_COLOR },
-
{ "dimcolor", ATTRIBUTE_DIMCOLOR },
-
{ "fillcolor", ATTRIBUTE_FILL_COLOR },
-
{ "fillstyle", ATTRIBUTE_FILL_STYLE },
-
{ "height", ATTRIBUTE_HEIGHT },
-
{ "linecolor", ATTRIBUTE_LINE_COLOR },
-
{ "linestyle", ATTRIBUTE_LINE_STYLE },
-
{ "opacity", ATTRIBUTE_OPACITY },
-
{ "rotate", ATTRIBUTE_ROTATE },
-
{ "skewx", ATTRIBUTE_SKEW_X },
-
{ "skewy", ATTRIBUTE_SKEW_Y },
-
{ "visibility", ATTRIBUTE_VISIBILITY },
-
{ "width", ATTRIBUTE_WIDTH },
-
{ "x", ATTRIBUTE_POS_X },
-
{ "y", ATTRIBUTE_POS_Y }
};
@@ -121,3 +101,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/color.cxx b/slideshow/source/engine/color.cxx
index d4b810978..35f3b4ed5 100644
--- a/slideshow/source/engine/color.cxx
+++ b/slideshow/source/engine/color.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -227,59 +228,6 @@ namespace slideshow
return maHSLTriple.mnLuminance;
}
- double HSLColor::getRed() const
- {
- if( ::basegfx::fTools::equalZero( getSaturation() ) )
- return getLuminance();
-
- return hsl2rgbHelper( 2.0*getLuminance() - mnMagicValue,
- mnMagicValue,
- getHue() + 120.0 );
- }
-
- double HSLColor::getGreen() const
- {
- if( ::basegfx::fTools::equalZero( getSaturation() ) )
- return getLuminance();
-
- return hsl2rgbHelper( 2.0*getLuminance() - mnMagicValue,
- mnMagicValue,
- getHue() );
- }
-
- double HSLColor::getBlue() const
- {
- if( ::basegfx::fTools::equalZero( getSaturation() ) )
- return getLuminance();
-
- return hsl2rgbHelper( 2.0*getLuminance() - mnMagicValue,
- mnMagicValue,
- getHue() - 120.0 );
- }
-
- RGBColor HSLColor::getRGBColor() const
- {
- RGBColor::RGBTriple aColor( hsl2rgb( getHue(),
- getSaturation(),
- getLuminance() ) );
- return RGBColor( aColor.mnRed, aColor.mnGreen, aColor.mnBlue );
- }
-
- RGBColor::RGBColor(const RGBColor& rLHS)
- {
- maRGBTriple.mnRed = rLHS.getRed();
- maRGBTriple.mnGreen = rLHS.getGreen();
- maRGBTriple.mnBlue = rLHS.getBlue();
- }
-
- RGBColor& RGBColor::operator=( const RGBColor& rLHS ){
-
- maRGBTriple.mnRed = rLHS.getRed();
- maRGBTriple.mnGreen = rLHS.getGreen();
- maRGBTriple.mnBlue = rLHS.getBlue();
- return *this;
- }
-
HSLColor operator+( const HSLColor& rLHS, const HSLColor& rRHS )
{
return HSLColor( rLHS.getHue() + rRHS.getHue(),
@@ -386,27 +334,6 @@ namespace slideshow
{
}
- double RGBColor::getHue() const
- {
- return rgb2hsl( getRed(),
- getGreen(),
- getBlue() ).mnHue;
- }
-
- double RGBColor::getSaturation() const
- {
- return rgb2hsl( getRed(),
- getGreen(),
- getBlue() ).mnSaturation;
- }
-
- double RGBColor::getLuminance() const
- {
- return rgb2hsl( getRed(),
- getGreen(),
- getBlue() ).mnLuminance;
- }
-
double RGBColor::getRed() const
{
return maRGBTriple.mnRed;
@@ -422,14 +349,6 @@ namespace slideshow
return maRGBTriple.mnBlue;
}
- HSLColor RGBColor::getHSLColor() const
- {
- HSLColor::HSLTriple aColor( rgb2hsl( getRed(),
- getGreen(),
- getBlue() ) );
- return HSLColor( aColor.mnHue, aColor.mnSaturation, aColor.mnLuminance );
- }
-
::cppcanvas::Color::IntSRGBA RGBColor::getIntegerColor() const
{
return ::cppcanvas::makeColor( colorToInt( getRed() ),
@@ -467,3 +386,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/debug.cxx b/slideshow/source/engine/debug.cxx
index 60262180e..1b713022b 100644
--- a/slideshow/source/engine/debug.cxx
+++ b/slideshow/source/engine/debug.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,30 +73,30 @@ OUString DebugGetDescription (const AnimationNodeSharedPtr& rpNode)
{
// Node is a container.
if (::boost::dynamic_pointer_cast<ParallelTimeContainer>(rpNode))
- return OUString::createFromAscii("ParallelTimeContainer");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("ParallelTimeContainer"));
else if (::boost::dynamic_pointer_cast<SequentialTimeContainer>(rpNode))
- return OUString::createFromAscii("SequentialTimeContainer");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("SequentialTimeContainer"));
else
- return OUString::createFromAscii("<unknown container>");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("<unknown container>"));
}
else if (::boost::dynamic_pointer_cast<AnimationTransitionFilterNode>(rpNode))
- return OUString::createFromAscii("AnimationTransitionFilterNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationTransitionFilterNode"));
else if (::boost::dynamic_pointer_cast<AnimationAudioNode>(rpNode))
- return OUString::createFromAscii("AnimationAudioNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationAudioNode"));
else if (::boost::dynamic_pointer_cast<AnimationColorNode>(rpNode))
- return OUString::createFromAscii("AnimationColorNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationColorNode"));
else if (::boost::dynamic_pointer_cast<AnimationCommandNode>(rpNode))
- return OUString::createFromAscii("AnimationCommandNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationCommandNode"));
else if (::boost::dynamic_pointer_cast<AnimationPathMotionNode>(rpNode))
- return OUString::createFromAscii("AnimationPathMotionNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationPathMotionNode"));
else if (::boost::dynamic_pointer_cast<AnimationSetNode>(rpNode))
- return OUString::createFromAscii("AnimationSetNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationSetNode"));
else if (::boost::dynamic_pointer_cast<AnimationTransformNode>(rpNode))
- return OUString::createFromAscii("AnimationTransformNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("AnimationTransformNode"));
else if (::boost::dynamic_pointer_cast<PropertyAnimationNode>(rpNode))
- return OUString::createFromAscii("PropertyAnimationNode");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("PropertyAnimationNode"));
else
- return OUString::createFromAscii("<unknown node type>");
+ return OUString(RTL_CONSTASCII_USTRINGPARAM("<unknown node type>"));
}
@@ -112,28 +113,28 @@ void DebugShowState (const AnimationNodeSharedPtr& rpNode)
{
default:
case AnimationNode::INVALID:
- sState = OUString::createFromAscii("Invalid");
- sStateColor = OUString::createFromAscii("firebrick1");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Invalid"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("firebrick1"));
break;
case AnimationNode::UNRESOLVED:
- sState = OUString::createFromAscii("Unresolved");
- sStateColor = OUString::createFromAscii("dodgerblue4");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Unresolved"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("dodgerblue4"));
break;
case AnimationNode::RESOLVED:
- sState = OUString::createFromAscii("Resolved");
- sStateColor = OUString::createFromAscii("dodgerblue");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Resolved"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("dodgerblue"));
break;
case AnimationNode::ACTIVE:
- sState = OUString::createFromAscii("Active");
- sStateColor = OUString::createFromAscii("seagreen1");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Active"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("seagreen1"));
break;
case AnimationNode::FROZEN:
- sState = OUString::createFromAscii("Frozen");
- sStateColor = OUString::createFromAscii("lightskyblue1");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Frozen"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("lightskyblue1"));
break;
case AnimationNode::ENDED:
- sState = OUString::createFromAscii("Ended");
- sStateColor = OUString::createFromAscii("slategray3");
+ sState = OUString(RTL_CONSTASCII_USTRINGPARAM("Ended"));
+ sStateColor = OUString(RTL_CONSTASCII_USTRINGPARAM("slategray3"));
break;
}
@@ -157,11 +158,11 @@ void DebugShowState (const AnimationNodeSharedPtr& rpNode)
}
else
{
- sTrigger = OUString::createFromAscii("other");
+ sTrigger = OUString(RTL_CONSTASCII_USTRINGPARAM("other"));
}
}
else
- sTrigger = ::rtl::OUString::createFromAscii("void");
+ sTrigger = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("void"));
TRACE("Node state: n%x [label=\"%x / %x / %s\\n%s\\n%s\",style=filled,fillcolor=\"%s\"]\r",
rpNode.get(),
@@ -322,3 +323,5 @@ DebugTraceScope::~DebugTraceScope (void)
} }
#endif // OSL_DEBUG_LEVEL > 1
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/delayevent.cxx b/slideshow/source/engine/delayevent.cxx
index 5093c7d88..5c0defb79 100644
--- a/slideshow/source/engine/delayevent.cxx
+++ b/slideshow/source/engine/delayevent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,4 @@ void Delay::dispose()
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/effectrewinder.cxx b/slideshow/source/engine/effectrewinder.cxx
index 6fac9696d..a6d5c5120 100644
--- a/slideshow/source/engine/effectrewinder.cxx
+++ b/slideshow/source/engine/effectrewinder.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -431,3 +432,5 @@ void EffectRewinder::asynchronousRewindToPreviousSlide (
} } // end of namespace ::slideshow::internal
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/effectrewinder.hxx b/slideshow/source/engine/effectrewinder.hxx
index fed03592e..d61b559c6 100644
--- a/slideshow/source/engine/effectrewinder.hxx
+++ b/slideshow/source/engine/effectrewinder.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -180,3 +181,5 @@ private:
} } // end of namespace ::slideshow::internal
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/eventmultiplexer.cxx b/slideshow/source/engine/eventmultiplexer.cxx
index 9576f0fc9..28ca27443 100644
--- a/slideshow/source/engine/eventmultiplexer.cxx
+++ b/slideshow/source/engine/eventmultiplexer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,7 +62,7 @@
#include <boost/bind.hpp>
#include <vector>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <algorithm>
using namespace ::com::sun::star;
@@ -474,7 +475,7 @@ UnoViewSharedPtr EventMultiplexerImpl::findUnoView(
boost::cref( xView ),
boost::bind( &UnoView::getUnoView, _1 )))) == aEnd )
{
- OSL_ENSURE(false, "EventMultiplexer::findUnoView(): unexpected message source" );
+ OSL_FAIL("EventMultiplexer::findUnoView(): unexpected message source" );
return UnoViewSharedPtr();
}
@@ -1276,3 +1277,4 @@ bool EventMultiplexer::notifySlideTransitionStarted()
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/eventqueue.cxx b/slideshow/source/engine/eventqueue.cxx
index 44dd95755..c3472008d 100644
--- a/slideshow/source/engine/eventqueue.cxx
+++ b/slideshow/source/engine/eventqueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,7 +90,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -265,8 +266,7 @@ namespace slideshow
// since this will also capture segmentation
// violations and the like. In such a case, we
// still better let our clients now...
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -333,3 +333,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/expressionnodefactory.cxx b/slideshow/source/engine/expressionnodefactory.cxx
index 6d689459b..14426cb59 100644
--- a/slideshow/source/engine/expressionnodefactory.cxx
+++ b/slideshow/source/engine/expressionnodefactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -277,3 +278,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/makefile.mk b/slideshow/source/engine/makefile.mk
deleted file mode 100644
index fdc99cd1a..000000000
--- a/slideshow/source/engine/makefile.mk
+++ /dev/null
@@ -1,102 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-
-PRJNAME=slideshow
-TARGET=engine
-ENABLE_EXCEPTIONS=TRUE
-
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-.IF "$(ENABLE_PRESENTER_EXTRA_UI)"=="YES"
-ENABLE_PRESENTER_EXTRA_UI is not used anymore
-.ENDIF
-
-# --- Common ----------------------------------------------------------
-
-ENVCFLAGS += -DBOOST_SPIRIT_USE_OLD_NAMESPACE
-
-.IF "$(OS)"=="SOLARIS"
-.IF "$(CCNUMVER)"=="00050009"
-# SunStudio12: anachronism warning in boost code (smilfunctionparser.cxx)
-# reevaluate with newer boost or compiler version
-CFLAGSWARNCXX!:=$(CFLAGSWARNCXX),badargtype2w
-.ENDIF
-.ENDIF
-
-# Disable optimization for SunCC Sparc (funny loops
-# when parsing e.g. "x+width/2")
-# Do not disable optimization for SunCC++ 5.5 Solaris x86,
-# this compiler has an ICE on smilfunctionparser.cxx *without*
-# optimization
-.IF "$(OS)$(CPU)"=="SOLARISS" && "$(COM)"!="GCC"
-NOOPTFILES= $(SLO)$/smilfunctionparser.obj
-.ENDIF
-# same issue for MACOSX
-.IF "$(OS)"=="MACOSX"
-NOOPTFILES= $(SLO)$/smilfunctionparser.obj
-.ENDIF
-
-SLOFILES = $(SLO)$/activitiesqueue.obj \
- $(SLO)$/animatedsprite.obj \
- $(SLO)$/animationfactory.obj \
- $(SLO)$/attributemap.obj \
- $(SLO)$/color.obj \
- $(SLO)$/delayevent.obj \
- $(SLO)$/effectrewinder.obj \
- $(SLO)$/eventmultiplexer.obj \
- $(SLO)$/eventqueue.obj \
- $(SLO)$/expressionnodefactory.obj \
- $(SLO)$/rehearsetimingsactivity.obj \
- $(SLO)$/screenupdater.obj \
- $(SLO)$/shapeattributelayer.obj \
- $(SLO)$/shapesubset.obj \
- $(SLO)$/slidebitmap.obj \
- $(SLO)$/slideshowcontext.obj \
- $(SLO)$/slideshowimpl.obj \
- $(SLO)$/slideview.obj \
- $(SLO)$/smilfunctionparser.obj \
- $(SLO)$/soundplayer.obj \
- $(SLO)$/tools.obj \
- $(SLO)$/unoviewcontainer.obj \
- $(SLO)$/usereventqueue.obj \
- $(SLO)$/waitsymbol.obj \
- $(SLO)$/wakeupevent.obj \
- $(SLO)$/debug.obj
-
-.IF "$(debug)"!="" || "$(DEBUG)"!=""
-SLOFILES += $(SLO)$/sp_debug.obj
-.ENDIF
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/rehearsetimingsactivity.cxx b/slideshow/source/engine/rehearsetimingsactivity.cxx
index 546d84b06..325b86d1c 100644
--- a/slideshow/source/engine/rehearsetimingsactivity.cxx
+++ b/slideshow/source/engine/rehearsetimingsactivity.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,6 +55,7 @@
#include "rehearsetimingsactivity.hxx"
#include <boost/bind.hpp>
+#include <o3tl/compat_functional.hxx>
#include <algorithm>
using namespace com::sun::star;
@@ -70,7 +72,7 @@ public:
ActivitySharedPtr const& rActivity,
ActivitiesQueue & rActivityQueue ) :
#if OSL_DEBUG_LEVEL > 1
- Event(::rtl::OUString::createFromAscii("WakeupEvent")),
+ Event(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("WakeupEvent"))),
#endif
maTimer(pTimeBase),
mnNextTime(0.0),
@@ -195,7 +197,7 @@ RehearseTimingsActivity::~RehearseTimingsActivity()
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -373,7 +375,7 @@ void RehearseTimingsActivity::viewRemoved( const UnoViewSharedPtr& rView )
std::equal_to<UnoViewSharedPtr>(),
rView,
// select view:
- boost::bind( std::select1st<ViewsVecT::value_type>(), _1 ))),
+ boost::bind( o3tl::select1st<ViewsVecT::value_type>(), _1 ))),
maViews.end() );
}
@@ -388,7 +390,7 @@ void RehearseTimingsActivity::viewChanged( const UnoViewSharedPtr& rView )
std::equal_to<UnoViewSharedPtr>(),
rView,
// select view:
- boost::bind( std::select1st<ViewsVecT::value_type>(), _1 ))));
+ boost::bind( o3tl::select1st<ViewsVecT::value_type>(), _1 ))));
OSL_ASSERT( aModifiedEntry != maViews.end() );
if( aModifiedEntry == maViews.end() )
@@ -579,3 +581,5 @@ bool RehearseTimingsActivity::MouseHandler::handleMouseMoved(
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/rehearsetimingsactivity.hxx b/slideshow/source/engine/rehearsetimingsactivity.hxx
index f600e3446..213287591 100644
--- a/slideshow/source/engine/rehearsetimingsactivity.hxx
+++ b/slideshow/source/engine/rehearsetimingsactivity.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -145,3 +146,5 @@ private:
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_REHEARSETIMINGSACTIVITY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/screenupdater.cxx b/slideshow/source/engine/screenupdater.cxx
index 52d11b8ad..5d39b23c0 100644
--- a/slideshow/source/engine/screenupdater.cxx
+++ b/slideshow/source/engine/screenupdater.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -266,3 +267,5 @@ void UpdateLock::Activate (void)
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapeattributelayer.cxx b/slideshow/source/engine/shapeattributelayer.cxx
index 93ea4ea4b..c17da20a4 100644
--- a/slideshow/source/engine/shapeattributelayer.cxx
+++ b/slideshow/source/engine/shapeattributelayer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -854,3 +855,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/appletshape.cxx b/slideshow/source/engine/shapes/appletshape.cxx
index dee9298e5..f998e6df7 100644
--- a/slideshow/source/engine/shapes/appletshape.cxx
+++ b/slideshow/source/engine/shapes/appletshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -328,3 +329,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/appletshape.hxx b/slideshow/source/engine/shapes/appletshape.hxx
index fa006fe31..4eb86ee2e 100644
--- a/slideshow/source/engine/shapes/appletshape.hxx
+++ b/slideshow/source/engine/shapes/appletshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_APPLETSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/backgroundshape.cxx b/slideshow/source/engine/shapes/backgroundshape.cxx
index bcfebf8f0..4f46d9172 100644
--- a/slideshow/source/engine/shapes/backgroundshape.cxx
+++ b/slideshow/source/engine/shapes/backgroundshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -334,3 +335,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/backgroundshape.hxx b/slideshow/source/engine/shapes/backgroundshape.hxx
index 37bcb6b24..1de9eaa6e 100644
--- a/slideshow/source/engine/shapes/backgroundshape.hxx
+++ b/slideshow/source/engine/shapes/backgroundshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_BACKGROUNDSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawinglayeranimation.cxx b/slideshow/source/engine/shapes/drawinglayeranimation.cxx
index 9dc00c2ec..1bf19b985 100644
--- a/slideshow/source/engine/shapes/drawinglayeranimation.cxx
+++ b/slideshow/source/engine/shapes/drawinglayeranimation.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -109,7 +110,7 @@ public:
double ScrollTextAnimNode::GetStateAtRelativeTime(
sal_uInt32 nRelativeTime) const
{
- // #151174# Avoid division by zero.
+ // Avoid division by zero.
if( mnDuration == 0 )
return mfStop;
@@ -358,7 +359,7 @@ sal_uInt32 ActivityImpl::GetStepWidthLogic() const
{
// step 1 pixel, canned value
- // #128389# with very high DPIs like in PDF export, this can
+ // with very high DPIs like in PDF export, this can
// still get zero. for that cases, set a default, too (taken
// from ainfoscrolltext.cxx)
nRetval = 100L;
@@ -375,7 +376,7 @@ void ActivityImpl::ImpForceScrollTextAnimNodes()
sal_uInt32 nLoopTime;
double fZeroLogic, fOneLogic, fInitLogic, fDistanceLogic;
double fZeroLogicAlternate = 0.0, fOneLogicAlternate = 0.0;
- double fZeroRelative, fOneRelative, fInitRelative,fDistanceRelative;
+ double fZeroRelative, fOneRelative, fInitRelative;
if(ScrollHorizontal())
{
@@ -428,13 +429,11 @@ void ActivityImpl::ImpForceScrollTextAnimNodes()
(fZeroLogicAlternate - fZeroLogic) / fDistanceLogic;
fOneRelative =
(fOneLogicAlternate - fZeroLogic) / fDistanceLogic;
- fDistanceRelative = fOneRelative - fZeroRelative;
}
else
{
fZeroRelative = 0.0;
fOneRelative = 1.0;
- fDistanceRelative = 1.0;
}
if(mnStartTime)
@@ -970,8 +969,7 @@ boost::shared_ptr<Activity> createDrawingLayerAnimActivity(
catch( uno::Exception& )
{
// translate any error into empty factory product.
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -982,3 +980,4 @@ boost::shared_ptr<Activity> createDrawingLayerAnimActivity(
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawinglayeranimation.hxx b/slideshow/source/engine/shapes/drawinglayeranimation.hxx
index 7e68f1440..b1d2bd1c6 100644
--- a/slideshow/source/engine/shapes/drawinglayeranimation.hxx
+++ b/slideshow/source/engine/shapes/drawinglayeranimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,3 +47,4 @@ boost::shared_ptr<Activity> createDrawingLayerAnimActivity(
#endif // ! defined INCLUDED_DRAWINGLAYERANIMATION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawshape.cxx b/slideshow/source/engine/shapes/drawshape.cxx
index 39105eb6d..d791c95fd 100644
--- a/slideshow/source/engine/shapes/drawshape.cxx
+++ b/slideshow/source/engine/shapes/drawshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -173,7 +174,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -790,7 +791,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -1100,7 +1101,7 @@ namespace slideshow
{
if (!maHyperlinkIndices.empty() &&
maHyperlinkIndices.back().second == -1) {
- OSL_ENSURE( false, "### pending FIELD_SEQ_END!" );
+ OSL_FAIL( "### pending FIELD_SEQ_END!" );
maHyperlinkIndices.pop_back();
maHyperlinkRegions.pop_back();
}
@@ -1132,7 +1133,7 @@ namespace slideshow
}
if (!maHyperlinkIndices.empty() &&
maHyperlinkIndices.back().second == -1) {
- OSL_ENSURE( false, "### pending FIELD_SEQ_END!" );
+ OSL_FAIL( "### pending FIELD_SEQ_END!" );
maHyperlinkIndices.pop_back();
maHyperlinkRegions.pop_back();
}
@@ -1476,3 +1477,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawshape.hxx b/slideshow/source/engine/shapes/drawshape.hxx
index bccd54401..12bd216d2 100644
--- a/slideshow/source/engine/shapes/drawshape.hxx
+++ b/slideshow/source/engine/shapes/drawshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -380,3 +381,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DRAWSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawshapesubsetting.cxx b/slideshow/source/engine/shapes/drawshapesubsetting.cxx
index c59dc1fea..743c08927 100644
--- a/slideshow/source/engine/shapes/drawshapesubsetting.cxx
+++ b/slideshow/source/engine/shapes/drawshapesubsetting.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -73,7 +74,7 @@ namespace slideshow
// init doctree vector
maActionClassVector.clear();
- maActionClassVector.reserve( mpMtf->GetActionCount() );
+ maActionClassVector.reserve( mpMtf->GetActionSize() );
// search metafile for text output
MetaAction* pCurrAct;
@@ -254,7 +255,7 @@ namespace slideshow
maCurrentSubsets(),
mbNodeTreeInitialized( false )
{
- ENSURE_OR_THROW( mpMtf,
+ ENSURE_OR_THROW( mpMtf,
"DrawShapeSubsetting::DrawShapeSubsetting(): Invalid metafile" );
initCurrentSubsets();
@@ -271,7 +272,7 @@ namespace slideshow
maCurrentSubsets(),
mbNodeTreeInitialized( false )
{
- ENSURE_OR_THROW( mpMtf,
+ ENSURE_OR_THROW( mpMtf,
"DrawShapeSubsetting::DrawShapeSubsetting(): Invalid metafile" );
initCurrentSubsets();
@@ -332,7 +333,7 @@ namespace slideshow
// subset shape already created for this DocTreeNode?
SubsetEntry aEntry;
-
+
aEntry.mnStartActionIndex = rTreeNode.getStartIndex();
aEntry.mnEndActionIndex = rTreeNode.getEndIndex();
@@ -353,7 +354,7 @@ namespace slideshow
// subset shape already created for this DocTreeNode?
SubsetEntry aEntry;
const DocTreeNode& rEffectiveSubset( rShape->getSubsetNode() );
-
+
aEntry.mnStartActionIndex = rEffectiveSubset.getStartIndex();
aEntry.mnEndActionIndex = rEffectiveSubset.getEndIndex();
@@ -371,9 +372,9 @@ namespace slideshow
// not yet created, init entry
aEntry.mnSubsetQueriedCount = 1;
aEntry.mpShape = rShape;
-
+
maSubsetShapes.insert( aEntry );
-
+
// update cached subset borders
updateSubsetBounds( aEntry );
updateSubsets();
@@ -387,7 +388,7 @@ namespace slideshow
// lookup subset shape
SubsetEntry aEntry;
const DocTreeNode& rEffectiveSubset( rShape->getSubsetNode() );
-
+
aEntry.mnStartActionIndex = rEffectiveSubset.getStartIndex();
aEntry.mnEndActionIndex = rEffectiveSubset.getEndIndex();
@@ -429,7 +430,7 @@ namespace slideshow
mnMinSubsetActionIndex = SAL_MAX_INT32;
mnMaxSubsetActionIndex = 0;
- // TODO(P2): This is quite expensive, when
+ // TODO(P2): This is quite expensive, when
// after every subset effect end, we have to scan
// the whole shape set
@@ -539,7 +540,7 @@ namespace slideshow
case DrawShapeSubsetting::CLASS_SHAPE_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_SHAPE_END,
- nCurrShapeCount,
+ nCurrShapeCount,
aLastShapeStart,
aNext ) )
{
@@ -551,7 +552,7 @@ namespace slideshow
// ends lines
case DrawShapeSubsetting::CLASS_PARAGRAPH_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_PARAGRAPH_END,
- nCurrParaCount,
+ nCurrParaCount,
aLastParaStart,
aNext ) )
{
@@ -564,7 +565,7 @@ namespace slideshow
// ends line
case DrawShapeSubsetting::CLASS_LINE_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_LINE_END,
- nCurrLineCount,
+ nCurrLineCount,
aLastLineStart,
aNext ) )
{
@@ -591,7 +592,7 @@ namespace slideshow
// FALLTHROUGH intended
case DrawShapeSubsetting::CLASS_SENTENCE_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_SENTENCE_END,
- nCurrSentenceCount,
+ nCurrSentenceCount,
aLastSentenceStart,
aNext ) )
{
@@ -603,7 +604,7 @@ namespace slideshow
// FALLTHROUGH intended
case DrawShapeSubsetting::CLASS_WORD_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_WORD_END,
- nCurrWordCount,
+ nCurrWordCount,
aLastWordStart,
aNext ) )
{
@@ -615,7 +616,7 @@ namespace slideshow
// FALLTHROUGH intended
case DrawShapeSubsetting::CLASS_CHARACTER_CELL_END:
if( !io_rFunctor( DrawShapeSubsetting::CLASS_CHARACTER_CELL_END,
- nCurrCharCount,
+ nCurrCharCount,
aLastCharStart,
aNext ) )
{
@@ -638,8 +639,7 @@ namespace slideshow
case DocTreeNode::NODETYPE_INVALID:
// FALLTHROUGH intended
default:
- OSL_ENSURE(false,
- "DrawShapeSubsetting::mapDocTreeNode(): unexpected node type");
+ OSL_FAIL("DrawShapeSubsetting::mapDocTreeNode(): unexpected node type");
return DrawShapeSubsetting::CLASS_NOOP;
case DocTreeNode::NODETYPE_LOGICAL_SHAPE:
@@ -664,11 +664,11 @@ namespace slideshow
};
}
- /// Counts number of class occurences
+ /// Counts number of class occurrences
class CountClassFunctor
{
public:
- CountClassFunctor( DrawShapeSubsetting::IndexClassificator eClass ) :
+ CountClassFunctor( DrawShapeSubsetting::IndexClassificator eClass ) :
meClass( eClass ),
mnCurrCount(0)
{
@@ -682,7 +682,7 @@ namespace slideshow
if( eCurrElemClassification == meClass )
++mnCurrCount;
- return true; // never stop, count all occurences
+ return true; // never stop, count all occurrences
}
sal_Int32 getCount() const
@@ -700,14 +700,14 @@ namespace slideshow
const DrawShapeSubsetting::IndexClassificatorVector::const_iterator& rEnd,
DocTreeNode::NodeType eNodeType ) const
{
- const IndexClassificator eRequestedClass(
+ const IndexClassificator eRequestedClass(
mapDocTreeNode( eNodeType ) );
// create a counting functor for the requested class of
// actions
CountClassFunctor aFunctor( eRequestedClass );
- // count all occurences in the given range
+ // count all occurrences in the given range
iterateActionClassifications( aFunctor, rBegin, rEnd );
return aFunctor.getCount();
@@ -796,7 +796,7 @@ namespace slideshow
sal_Int32 nNodeIndex,
DocTreeNode::NodeType eNodeType ) const
{
- const IndexClassificator eRequestedClass(
+ const IndexClassificator eRequestedClass(
mapDocTreeNode( eNodeType ) );
// create a nth element functor for the requested class of
@@ -860,6 +860,8 @@ namespace slideshow
{
return maCurrentSubsets;
}
-
+
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/drawshapesubsetting.hxx b/slideshow/source/engine/shapes/drawshapesubsetting.hxx
index 9a1572c4e..0177907c1 100644
--- a/slideshow/source/engine/shapes/drawshapesubsetting.hxx
+++ b/slideshow/source/engine/shapes/drawshapesubsetting.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -286,3 +287,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DRAWSHAPESUBSETTING_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/externalshapebase.cxx b/slideshow/source/engine/shapes/externalshapebase.cxx
index 8c24c0ee9..0051c24bb 100644
--- a/slideshow/source/engine/shapes/externalshapebase.cxx
+++ b/slideshow/source/engine/shapes/externalshapebase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -122,7 +123,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -244,3 +245,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/externalshapebase.hxx b/slideshow/source/engine/shapes/externalshapebase.hxx
index 25abcb6c3..8e415fcc3 100644
--- a/slideshow/source/engine/shapes/externalshapebase.hxx
+++ b/slideshow/source/engine/shapes/externalshapebase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -143,3 +144,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_EXTERNALSHAPEBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/gdimtftools.cxx b/slideshow/source/engine/shapes/gdimtftools.cxx
index a40b40600..5265926f5 100644
--- a/slideshow/source/engine/shapes/gdimtftools.cxx
+++ b/slideshow/source/engine/shapes/gdimtftools.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -67,7 +68,7 @@ using namespace ::com::sun::star;
namespace slideshow
{
-namespace internal
+namespace internal
{
// TODO(E2): Detect the case when svx/drawing layer is not
// in-process, or even not on the same machine, and
@@ -86,8 +87,8 @@ bool hasUnsupportedActions( const GDIMetaFile& rMtf )
MetaAction* pCurrAct;
// TODO(Q3): avoid const-cast
- for( pCurrAct = const_cast<GDIMetaFile&>(rMtf).FirstAction();
- pCurrAct;
+ for( pCurrAct = const_cast<GDIMetaFile&>(rMtf).FirstAction();
+ pCurrAct;
pCurrAct = const_cast<GDIMetaFile&>(rMtf).NextAction() )
{
switch( pCurrAct->GetType() )
@@ -117,12 +118,12 @@ namespace {
typedef ::cppu::WeakComponentImplHelper1< graphic::XGraphicRenderer > DummyRenderer_Base;
-class DummyRenderer :
+class DummyRenderer :
public DummyRenderer_Base,
public cppu::BaseMutex
{
public:
- DummyRenderer() :
+ DummyRenderer() :
DummyRenderer_Base( m_aMutex ),
mxGraphic()
{
@@ -146,11 +147,11 @@ public:
GDIMetaFile getMtf( bool bForeignSource ) const
{
::osl::MutexGuard aGuard( m_aMutex );
-
+
Graphic aGraphic( mxGraphic );
if( aGraphic.GetType() == GRAPHIC_BITMAP ||
- (bForeignSource &&
+ (bForeignSource &&
hasUnsupportedActions(aGraphic.GetGDIMetaFile()) ) )
{
// wrap bitmap into GDIMetafile
@@ -177,10 +178,10 @@ private:
};
} // anon namespace
-
+
// Quick'n'dirty way: tunnel Graphic (only works for
// in-process slideshow, of course)
-bool getMetaFile( const uno::Reference< lang::XComponent >& xSource,
+bool getMetaFile( const uno::Reference< lang::XComponent >& xSource,
const uno::Reference< drawing::XDrawPage >& xContainingPage,
GDIMetaFile& rMtf,
int mtfLoadFlags,
@@ -199,7 +200,7 @@ bool getMetaFile( const uno::Reference< lang::XComponent >& xSource,
uno::Reference< graphic::XGraphicRenderer > xRenderer( pRenderer );
// -> stuff that into UnoGraphicExporter.
- uno::Reference<lang::XMultiComponentFactory> xFactory(
+ uno::Reference<lang::XMultiComponentFactory> xFactory(
rxContext->getServiceManager() );
OSL_ENSURE( xFactory.is(), "### no UNO?!" );
@@ -208,7 +209,7 @@ bool getMetaFile( const uno::Reference< lang::XComponent >& xSource,
// creating the graphic exporter
uno::Reference< document::XExporter > xExporter(
- xFactory->createInstanceWithContext(
+ xFactory->createInstanceWithContext(
OUSTR("com.sun.star.drawing.GraphicExportFilter"),
rxContext),
uno::UNO_QUERY );
@@ -231,7 +232,7 @@ bool getMetaFile( const uno::Reference< lang::XComponent >& xSource,
aFilterData[1].Name = OUSTR("ScrollText");
aFilterData[1].Value <<= ((mtfLoadFlags & MTF_LOAD_SCROLL_TEXT_MTF) != 0);
-
+
aFilterData[2].Name = OUSTR("ExportOnlyBackground");
aFilterData[2].Value <<= ((mtfLoadFlags & MTF_LOAD_BACKGROUND_ONLY) != 0);
@@ -266,7 +267,7 @@ void removeTextActions( GDIMetaFile& rMtf )
MetaAction* pCurrAct;
int nActionIndex(0);
- pCurrAct = rMtf.FirstAction();
+ pCurrAct = rMtf.FirstAction();
while( pCurrAct )
{
switch( pCurrAct->GetType() )
@@ -303,7 +304,7 @@ sal_Int32 getNextActionOffset( MetaAction * pCurrAct )
// Special handling for actions that represent
// more than one indexable action
// ===========================================
-
+
switch (pCurrAct->GetType()) {
case META_TEXT_ACTION: {
MetaTextAction * pAct = static_cast<MetaTextAction *>(pCurrAct);
@@ -329,7 +330,7 @@ sal_Int32 getNextActionOffset( MetaAction * pCurrAct )
// (though this is currently not used from the
// DrawingLayer - shape transparency gradients
// don't affect shape text)
- return pAct->GetGDIMetaFile().GetActionCount();
+ return pAct->GetGDIMetaFile().GetActionSize();
}
default:
return 1;
@@ -349,7 +350,7 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
// some loop invariants
Animation aAnimation( rGraphic.GetAnimation() );
const Point aEmptyPoint;
- const Size aAnimSize( aAnimation.GetDisplaySizePixel() );
+ const Size aAnimSize( aAnimation.GetDisplaySizePixel() );
// setup VDev, into which all bitmaps are painted (want to
// normalize animations to n bitmaps of same size. An Animation,
@@ -398,24 +399,24 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
{
case DISPOSE_NOT:
{
- aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
+ aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
rAnimBmp.aBmpEx);
Bitmap aMask = rAnimBmp.aBmpEx.GetMask();
if( aMask.IsEmpty() )
{
const Point aEmpty;
- const Rectangle aRect(aEmptyPoint,
+ const Rectangle aRect(aEmptyPoint,
aVDevMask.GetOutputSizePixel());
const Wallpaper aWallpaper(COL_BLACK);
- aVDevMask.DrawWallpaper(aRect,
+ aVDevMask.DrawWallpaper(aRect,
aWallpaper);
}
else
{
- BitmapEx aTmpMask = BitmapEx(aMask,
+ BitmapEx aTmpMask = BitmapEx(aMask,
aMask);
- aVDevMask.DrawBitmapEx(rAnimBmp.aPosPix,
+ aVDevMask.DrawBitmapEx(rAnimBmp.aPosPix,
aTmpMask );
}
break;
@@ -446,16 +447,16 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
case DISPOSE_FULL:
{
- aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
+ aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
rAnimBmp.aBmpEx);
break;
}
case DISPOSE_PREVIOUS :
{
- aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
+ aVDev.DrawBitmapEx(rAnimBmp.aPosPix,
rAnimBmp.aBmpEx);
- aVDevMask.DrawBitmap(rAnimBmp.aPosPix,
+ aVDevMask.DrawBitmap(rAnimBmp.aPosPix,
rAnimBmp.aBmpEx.GetMask());
break;
}
@@ -464,7 +465,7 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
// extract current aVDev content into a new animation
// frame
GDIMetaFileSharedPtr pMtf( new GDIMetaFile() );
- pMtf->AddAction(
+ pMtf->AddAction(
new MetaBmpExAction( aEmptyPoint,
BitmapEx(
aVDev.GetBitmap(
@@ -480,7 +481,6 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
pMtf->SetPrefMapMode( MapMode() );
pMtf->SetPrefSize( aAnimSize );
- // #115934#
// Take care of special value for MultiPage TIFFs. ATM these shall just
// show their first page for _quite_ some time.
sal_Int32 nWaitTime100thSeconds( rAnimBmp.nWait );
@@ -490,13 +490,13 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
// time to show first page (whole day)
nWaitTime100thSeconds = 100 * 60 * 60 * 24;
}
-
+
// There are animated GIFs with no WaitTime set. Take 0.1 sec, the
// same duration that is used by the edit view.
if( nWaitTime100thSeconds == 0 )
nWaitTime100thSeconds = 10;
- o_rFrames.push_back( MtfAnimationFrame( pMtf,
+ o_rFrames.push_back( MtfAnimationFrame( pMtf,
nWaitTime100thSeconds / 100.0 ) );
}
@@ -506,7 +506,7 @@ bool getAnimationFromGraphic( VectorOfMtfAnimationFrames& o_rFrames,
bool getRectanglesFromScrollMtf( ::basegfx::B2DRectangle& o_rScrollRect,
::basegfx::B2DRectangle& o_rPaintRect,
const GDIMetaFileSharedPtr& rMtf )
-{
+{
// extract bounds: scroll rect, paint rect
bool bScrollRectSet(false);
bool bPaintRectSet(false);
@@ -548,3 +548,4 @@ bool getRectanglesFromScrollMtf( ::basegfx::B2DRectangle& o_rScrollRect,
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/gdimtftools.hxx b/slideshow/source/engine/shapes/gdimtftools.hxx
index 4cecbb338..705c7eb35 100644
--- a/slideshow/source/engine/shapes/gdimtftools.hxx
+++ b/slideshow/source/engine/shapes/gdimtftools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -153,3 +154,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_GDIMTFTOOLS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/intrinsicanimationactivity.cxx b/slideshow/source/engine/shapes/intrinsicanimationactivity.cxx
index 013c9099b..e185085a9 100644
--- a/slideshow/source/engine/shapes/intrinsicanimationactivity.cxx
+++ b/slideshow/source/engine/shapes/intrinsicanimationactivity.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -288,3 +289,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/intrinsicanimationactivity.hxx b/slideshow/source/engine/shapes/intrinsicanimationactivity.hxx
index ea7031c94..9f626a38f 100644
--- a/slideshow/source/engine/shapes/intrinsicanimationactivity.hxx
+++ b/slideshow/source/engine/shapes/intrinsicanimationactivity.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_INTRINSICANIMATIONACTIVITY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/makefile.mk b/slideshow/source/engine/shapes/makefile.mk
deleted file mode 100644
index 1d40c1657..000000000
--- a/slideshow/source/engine/shapes/makefile.mk
+++ /dev/null
@@ -1,60 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=shapes
-ENABLE_EXCEPTIONS=TRUE
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-SLOFILES = $(SLO)$/appletshape.obj \
- $(SLO)$/backgroundshape.obj \
- $(SLO)$/drawinglayeranimation.obj \
- $(SLO)$/drawshape.obj \
- $(SLO)$/drawshapesubsetting.obj \
- $(SLO)$/externalshapebase.obj \
- $(SLO)$/gdimtftools.obj \
- $(SLO)$/intrinsicanimationactivity.obj \
- $(SLO)$/mediashape.obj \
- $(SLO)$/shapeimporter.obj \
- $(SLO)$/viewappletshape.obj \
- $(SLO)$/viewbackgroundshape.obj \
- $(SLO)$/viewmediashape.obj \
- $(SLO)$/viewshape.obj
-
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/shapes/mediashape.cxx b/slideshow/source/engine/shapes/mediashape.cxx
index e98c4ed45..6d489ee73 100644
--- a/slideshow/source/engine/shapes/mediashape.cxx
+++ b/slideshow/source/engine/shapes/mediashape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -295,3 +296,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/mediashape.hxx b/slideshow/source/engine/shapes/mediashape.hxx
index ce1e7ad18..bd5b29882 100644
--- a/slideshow/source/engine/shapes/mediashape.hxx
+++ b/slideshow/source/engine/shapes/mediashape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_MEDIASHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/shapeimporter.cxx b/slideshow/source/engine/shapes/shapeimporter.cxx
index 87eaad5f6..2eac8d631 100644
--- a/slideshow/source/engine/shapes/shapeimporter.cxx
+++ b/slideshow/source/engine/shapes/shapeimporter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,7 +99,7 @@ bool importShapeGraphic(
if(nIndex >= aURL.getLength())
{
- OSL_ENSURE( false, "ShapeImporter::importShape(): "
+ OSL_FAIL( "ShapeImporter::importShape(): "
"embedded graphic has no graphic ID" );
return false;
}
@@ -136,7 +137,7 @@ bool importShapeGraphic(
STREAM_READ ) );
if( !pGraphicStream )
{
- OSL_ENSURE( false, "ShapeImporter::importShape(): "
+ OSL_FAIL( "ShapeImporter::importShape(): "
"cannot create input stream for graphic" );
return false;
}
@@ -145,7 +146,7 @@ bool importShapeGraphic(
if( GraphicConverter::Import(
*pGraphicStream, aTmpGraphic ) != ERRCODE_NONE )
{
- OSL_ENSURE( false, "ShapeImporter::importShape(): "
+ OSL_FAIL( "ShapeImporter::importShape(): "
"Failed to import shape graphic from given URL" );
return false;
}
@@ -366,7 +367,7 @@ ShapeSharedPtr ShapeImporter::createShape(
// animation frame)
if( !importShapeGraphic( aGraphicObject, xPropSet ) )
return ShapeSharedPtr(); // error loading graphic -
- // #142147# no placeholders in
+ // no placeholders in
// slideshow
if( !aGraphicObject.IsAnimated() )
@@ -474,11 +475,11 @@ bool ShapeImporter::isSkip(
rtl::OUString layerName;
uno::Reference<beans::XPropertySet> xPropLayerSet(
xLayer, uno::UNO_QUERY );
- const uno::Any& a(xPropLayerSet->getPropertyValue(rtl::OUString::createFromAscii("Name")) );
+ const uno::Any& a(xPropLayerSet->getPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"))) );
bool const bRet = (a >>= layerName);
if(bRet)
{
- if( layerName.equals(rtl::OUString::createFromAscii("DrawnInSlideshow")))
+ if( layerName.equals(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DrawnInSlideshow"))))
{
//Transform shapes into PolyPolygons
importPolygons(xPropSet);
@@ -540,7 +541,7 @@ void ShapeImporter::importPolygons(uno::Reference<beans::XPropertySet> const& xP
pPolyPoly->draw();
maPolygons.push_back(pPolyPoly);
}
- aIter++;
+ ++aIter;
}
}
@@ -668,3 +669,4 @@ ShapeImporter::ShapeImporter( uno::Reference<drawing::XDrawPage> const&
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewappletshape.cxx b/slideshow/source/engine/shapes/viewappletshape.cxx
index ed65a9bef..1ef00d7f2 100644
--- a/slideshow/source/engine/shapes/viewappletshape.cxx
+++ b/slideshow/source/engine/shapes/viewappletshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -120,7 +121,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -149,7 +150,7 @@ namespace slideshow
uno::Reference< awt::XWindow2 > xParentWindow(
xPropSet->getPropertyValue(
- ::rtl::OUString::createFromAscii( "Window" )),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "Window" ))),
uno::UNO_QUERY_THROW );
uno::Reference<lang::XMultiComponentFactory> xFactory(
@@ -162,7 +163,7 @@ namespace slideshow
uno::Reference< awt::XToolkit > xToolkit(
xFactory->createInstanceWithContext(
- ::rtl::OUString::createFromAscii( "com.sun.star.awt.Toolkit" ),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.awt.Toolkit" )),
mxComponentContext ),
uno::UNO_QUERY_THROW );
@@ -186,7 +187,7 @@ namespace slideshow
mxFrame.set(
xFactory->createInstanceWithContext(
- ::rtl::OUString::createFromAscii( "com.sun.star.frame.Frame" ),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.Frame" )),
mxComponentContext ),
uno::UNO_QUERY_THROW );
@@ -298,3 +299,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewappletshape.hxx b/slideshow/source/engine/shapes/viewappletshape.hxx
index 36bc5627e..b80b89f51 100644
--- a/slideshow/source/engine/shapes/viewappletshape.hxx
+++ b/slideshow/source/engine/shapes/viewappletshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -167,3 +168,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWAPPLETSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewbackgroundshape.cxx b/slideshow/source/engine/shapes/viewbackgroundshape.cxx
index f89391867..c18cc26ba 100644
--- a/slideshow/source/engine/shapes/viewbackgroundshape.cxx
+++ b/slideshow/source/engine/shapes/viewbackgroundshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -197,8 +198,7 @@ namespace slideshow
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -210,3 +210,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewbackgroundshape.hxx b/slideshow/source/engine/shapes/viewbackgroundshape.hxx
index 5ecc17c33..cd561a712 100644
--- a/slideshow/source/engine/shapes/viewbackgroundshape.hxx
+++ b/slideshow/source/engine/shapes/viewbackgroundshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWBACKGROUNDSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewmediashape.cxx b/slideshow/source/engine/shapes/viewmediashape.cxx
index fec96502c..00d2045d7 100644
--- a/slideshow/source/engine/shapes/viewmediashape.cxx
+++ b/slideshow/source/engine/shapes/viewmediashape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -111,7 +112,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -224,7 +225,7 @@ namespace slideshow
if( xPropSet.is() &&
getPropertyValue( xParentWindow,
xPropSet,
- ::rtl::OUString::createFromAscii( "Window" )) )
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "Window" ))) )
{
const awt::Rectangle aRect( xParentWindow->getPosSize() );
@@ -304,7 +305,8 @@ namespace slideshow
aDeviceParams[ 0 ] >>= aImplName;
if( aImplName.endsWithIgnoreAsciiCaseAsciiL(
- RTL_CONSTASCII_STRINGPARAM("VCL") ))
+ RTL_CONSTASCII_STRINGPARAM("VCL") ) || aImplName.endsWithIgnoreAsciiCaseAsciiL(
+ RTL_CONSTASCII_STRINGPARAM("Cairo") ) )
{
implInitializeVCLBasedPlayerWindow( rBounds, aDeviceParams );
}
@@ -326,8 +328,7 @@ namespace slideshow
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -410,6 +411,7 @@ namespace slideshow
bool ViewMediaShape::implInitializeVCLBasedPlayerWindow( const ::basegfx::B2DRectangle& rBounds,
const uno::Sequence< uno::Any >& rVCLDeviceParams)
{
+ OSL_TRACE( "ViewMediaShape::implInitializeVCLBasedPlayerWindow" );
if( !mpMediaWindow.get() && !rBounds.isEmpty() )
{
try
@@ -439,16 +441,22 @@ namespace slideshow
mpMediaWindow = ::std::auto_ptr< SystemChildWindow >( new
SystemChildWindow( pWindow, WB_CLIPCHILDREN ) );
+ mpMediaWindow = ::std::auto_ptr< SystemChildWindow >( new SystemChildWindow( pWindow, WB_CLIPCHILDREN ) );
mpMediaWindow->SetBackground( Color( COL_BLACK ) );
mpMediaWindow->SetPosSizePixel( Point( aAWTRect.X, aAWTRect.Y ),
Size( aAWTRect.Width, aAWTRect.Height ) );
+ mpMediaWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP );
+ mpMediaWindow->EnableEraseBackground( sal_False );
+ mpMediaWindow->EnablePaint( sal_False );
+ mpMediaWindow->SetForwardKey( sal_True );
+ mpMediaWindow->SetMouseTransparent( sal_True );
mpMediaWindow->Show();
if( mxPlayer.is() )
{
aArgs[ 0 ] = uno::makeAny(
sal::static_int_cast< sal_IntPtr >( mpMediaWindow->GetParentWindowHandle() ) );
-
+
aAWTRect.X = aAWTRect.Y = 0;
aArgs[ 1 ] = uno::makeAny( aAWTRect );
@@ -471,8 +479,7 @@ namespace slideshow
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -530,8 +537,7 @@ namespace slideshow
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -541,3 +547,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewmediashape.hxx b/slideshow/source/engine/shapes/viewmediashape.hxx
index 465f6d534..6fb36a3fb 100644
--- a/slideshow/source/engine/shapes/viewmediashape.hxx
+++ b/slideshow/source/engine/shapes/viewmediashape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -172,3 +173,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWMEDIASHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewshape.cxx b/slideshow/source/engine/shapes/viewshape.cxx
index 778f974ae..7f4d3dc5f 100644
--- a/slideshow/source/engine/shapes/viewshape.cxx
+++ b/slideshow/source/engine/shapes/viewshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -369,7 +370,7 @@ namespace slideshow
// nominal area for the shape (without subsetting, without
// char scaling). NOTE: to cancel the shape translation,
// contained in rSpriteBoundsPixel, this is _without_ any
- // translational component (fixed along with #121921#).
+ // translational component.
::basegfx::B2DRectangle aLogShapeBounds;
const ::basegfx::B2DRectangle& rNominalShapeBoundsPixel(
shapeArea2AreaPixel( rCanvasTransform,
@@ -437,7 +438,7 @@ namespace slideshow
// at the origin.
// NOTE: As for now, sprites are always positioned on
// integer pixel positions on screen, have to round to
- // nearest integer here, too (fixed along with #121921#)
+ // nearest integer here, too
mpSprite->setPixelOffset(
aAAOffset - ::basegfx::B2DSize(
::basegfx::fround( rSpriteCorrectionOffset.getX() ),
@@ -896,3 +897,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapes/viewshape.hxx b/slideshow/source/engine/shapes/viewshape.hxx
index 44d66cfaf..68ba34938 100644
--- a/slideshow/source/engine/shapes/viewshape.hxx
+++ b/slideshow/source/engine/shapes/viewshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -227,7 +228,7 @@ namespace slideshow
{
}
- ::cppcanvas::CanvasSharedPtr getDestinationCanvas()
+ ::cppcanvas::CanvasSharedPtr getDestinationCanvas() const
{
return mpDestinationCanvas;
}
@@ -338,3 +339,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWSHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/shapesubset.cxx b/slideshow/source/engine/shapesubset.cxx
index c994a6465..a06bd345a 100644
--- a/slideshow/source/engine/shapesubset.cxx
+++ b/slideshow/source/engine/shapesubset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,7 +93,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -139,3 +140,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/layer.cxx b/slideshow/source/engine/slide/layer.cxx
index a41a000e8..b2bca8752 100644
--- a/slideshow/source/engine/slide/layer.cxx
+++ b/slideshow/source/engine/slide/layer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -362,3 +363,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/layer.hxx b/slideshow/source/engine/slide/layer.hxx
index 91441b6ba..20ed39efa 100644
--- a/slideshow/source/engine/slide/layer.hxx
+++ b/slideshow/source/engine/slide/layer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -314,3 +315,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_LAYER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/layermanager.cxx b/slideshow/source/engine/slide/layermanager.cxx
index 85fc0476e..ed7a14acc 100644
--- a/slideshow/source/engine/slide/layermanager.cxx
+++ b/slideshow/source/engine/slide/layermanager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,6 +40,8 @@
#include <boost/bind.hpp>
#include <algorithm>
+#include <o3tl/compat_functional.hxx>
+
#include "layermanager.hxx"
using namespace ::com::sun::star;
@@ -161,7 +164,7 @@ namespace slideshow
std::for_each(maAllShapes.begin(),
maAllShapes.end(),
boost::bind( &Shape::clearAllViewLayers,
- boost::bind( std::select1st<LayerShapeMap::value_type>(),
+ boost::bind( o3tl::select1st<LayerShapeMap::value_type>(),
_1 )));
for (LayerShapeMap::iterator
@@ -271,7 +274,7 @@ namespace slideshow
std::for_each( maAllShapes.begin(),
maAllShapes.end(),
boost::bind(&Shape::render,
- boost::bind( ::std::select1st<LayerShapeMap::value_type>(), _1)) );
+ boost::bind( ::o3tl::select1st<LayerShapeMap::value_type>(), _1)) );
}
void LayerManager::addShape( const ShapeSharedPtr& rShape )
@@ -654,8 +657,7 @@ namespace slideshow
virtual void setPriority( const basegfx::B1DRange& /*rRange*/ )
{
- OSL_ENSURE( false,
- "BitmapView::setPriority(): This method is not supposed to be called!" );
+ OSL_FAIL( "BitmapView::setPriority(): This method is not supposed to be called!" );
}
virtual ::basegfx::B2DHomMatrix getTransformation() const
@@ -665,21 +667,18 @@ namespace slideshow
virtual ::basegfx::B2DHomMatrix getSpriteTransformation() const
{
- OSL_ENSURE( false,
- "BitmapView::getSpriteTransformation(): This method is not supposed to be called!" );
+ OSL_FAIL( "BitmapView::getSpriteTransformation(): This method is not supposed to be called!" );
return ::basegfx::B2DHomMatrix();
}
virtual void setClip( const ::basegfx::B2DPolyPolygon& /*rClip*/ )
{
- OSL_ENSURE( false,
- "BitmapView::setClip(): This method is not supposed to be called!" );
+ OSL_FAIL( "BitmapView::setClip(): This method is not supposed to be called!" );
}
virtual bool resize( const ::basegfx::B2DRange& /*rArea*/ )
{
- OSL_ENSURE( false,
- "BitmapView::resize(): This method is not supposed to be called!" );
+ OSL_FAIL( "BitmapView::resize(): This method is not supposed to be called!" );
return false;
}
@@ -714,8 +713,7 @@ namespace slideshow
{
// TODO(E1): Might be superfluous. Nowadays,
// addViewLayer swallows all errors, anyway.
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -921,3 +919,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/layermanager.hxx b/slideshow/source/engine/slide/layermanager.hxx
index ed67f2b9b..de415255a 100644
--- a/slideshow/source/engine/slide/layermanager.hxx
+++ b/slideshow/source/engine/slide/layermanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,7 +42,7 @@
#include <vector>
#include <map>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <algorithm>
#include <functional>
@@ -244,7 +245,7 @@ namespace slideshow
Provides quicker lookup than ShapeSet for simple mappings
*/
- typedef ::std::hash_map<
+ typedef ::boost::unordered_map<
::com::sun::star::uno::Reference<
::com::sun::star::drawing::XShape >,
ShapeSharedPtr,
@@ -383,3 +384,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_LAYERMANAGER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/makefile.mk b/slideshow/source/engine/slide/makefile.mk
deleted file mode 100644
index 953307d62..000000000
--- a/slideshow/source/engine/slide/makefile.mk
+++ /dev/null
@@ -1,51 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=slide
-ENABLE_EXCEPTIONS=TRUE
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-SLOFILES = $(SLO)$/layer.obj \
- $(SLO)$/layermanager.obj \
- $(SLO)$/shapemanagerimpl.obj \
- $(SLO)$/slideanimations.obj \
- $(SLO)$/slideimpl.obj \
- $(SLO)$/userpaintoverlay.obj
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/slide/shapemanagerimpl.cxx b/slideshow/source/engine/slide/shapemanagerimpl.cxx
index 05e67c5a5..6d28deef9 100644
--- a/slideshow/source/engine/slide/shapemanagerimpl.cxx
+++ b/slideshow/source/engine/slide/shapemanagerimpl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,6 +41,8 @@
#include <boost/bind.hpp>
+#include <o3tl/compat_functional.hxx>
+
using namespace com::sun::star;
namespace slideshow {
@@ -82,7 +85,7 @@ void ShapeManagerImpl::activate( bool bSlideBackgoundPainted )
this,
boost::cref(xDummyListener),
boost::bind(
- std::select1st<ShapeEventListenerMap::value_type>(),
+ o3tl::select1st<ShapeEventListenerMap::value_type>(),
_1 )));
// clone cursor map
@@ -91,10 +94,10 @@ void ShapeManagerImpl::activate( bool bSlideBackgoundPainted )
boost::bind( &ShapeManagerImpl::cursorChanged,
this,
boost::bind(
- std::select1st<ShapeCursorMap::value_type>(),
+ o3tl::select1st<ShapeCursorMap::value_type>(),
_1 ),
boost::bind(
- std::select2nd<ShapeCursorMap::value_type>(),
+ o3tl::select2nd<ShapeCursorMap::value_type>(),
_1 )));
if( mpLayerManager )
@@ -459,3 +462,5 @@ bool ShapeManagerImpl::notifyIntrinsicAnimationsDisabled()
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/shapemanagerimpl.hxx b/slideshow/source/engine/slide/shapemanagerimpl.hxx
index 961dd718f..cf5addcc9 100644
--- a/slideshow/source/engine/slide/shapemanagerimpl.hxx
+++ b/slideshow/source/engine/slide/shapemanagerimpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -207,3 +208,5 @@ private:
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_SHAPEMANAGERIMPL_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/slideanimations.cxx b/slideshow/source/engine/slide/slideanimations.cxx
index 75c7ae14a..62902c8e7 100644
--- a/slideshow/source/engine/slide/slideanimations.cxx
+++ b/slideshow/source/engine/slide/slideanimations.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,7 +68,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -129,3 +130,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/slideanimations.hxx b/slideshow/source/engine/slide/slideanimations.hxx
index ca5fbea93..02bc38fd8 100644
--- a/slideshow/source/engine/slide/slideanimations.hxx
+++ b/slideshow/source/engine/slide/slideanimations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -123,3 +124,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SLIDEANIMATIONS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/slideimpl.cxx b/slideshow/source/engine/slide/slideimpl.cxx
index f5bdf7c8b..82491dacd 100644
--- a/slideshow/source/engine/slide/slideimpl.cxx
+++ b/slideshow/source/engine/slide/slideimpl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,6 +75,8 @@
#include "event.hxx"
#include "tools.hxx"
+#include <o3tl/compat_functional.hxx>
+
#include <boost/bind.hpp>
#include <iterator>
#include <algorithm>
@@ -175,12 +178,6 @@ private:
*/
bool isAnimated();
- /** Query whether this slide is currently showing.
-
- @return true, if this slide is currently showing.
- */
- bool isShowing() const;
-
/// Set all Shapes to their initial attributes for slideshow
bool applyInitialShapeAttributes( const ::com::sun::star::uno::Reference<
::com::sun::star::animations::XAnimationNode >& xRootAnimationNode );
@@ -633,7 +630,7 @@ SlideBitmapSharedPtr SlideImpl::getCurrentSlideBitmap( const UnoViewSharedPtr& r
rView,
// select view:
boost::bind(
- std::select1st<VectorOfVectorOfSlideBitmaps::value_type>(),
+ o3tl::select1st<VectorOfVectorOfSlideBitmaps::value_type>(),
_1 )))) == aEnd )
{
// corresponding view not found - maybe view was not
@@ -707,7 +704,7 @@ void SlideImpl::viewRemoved( const UnoViewSharedPtr& rView )
rView,
// select view:
boost::bind(
- std::select1st<VectorOfVectorOfSlideBitmaps::value_type>(),
+ o3tl::select1st<VectorOfVectorOfSlideBitmaps::value_type>(),
_1 ))),
aEnd );
}
@@ -740,11 +737,6 @@ void SlideImpl::resetCursor()
mrCursorManager.resetCursor();
}
-bool SlideImpl::isShowing() const
-{
- return meAnimationState == SHOWING_STATE;
-}
-
bool SlideImpl::isAnimated()
{
// prefetch, but don't apply initial shape attributes
@@ -851,8 +843,7 @@ bool SlideImpl::implPrefetchShow()
{
if( !maAnimations.importAnimations( mxRootNode ) )
{
- OSL_ENSURE( false,
- "SlideImpl::implPrefetchShow(): have animation nodes, "
+ OSL_FAIL( "SlideImpl::implPrefetchShow(): have animation nodes, "
"but import animations failed." );
// could not import animation framework,
@@ -882,8 +873,7 @@ bool SlideImpl::implPrefetchShow()
}
catch( uno::Exception& )
{
- OSL_ENSURE(
- false,
+ OSL_FAIL(
rtl::OUStringToOString(
comphelper::anyToString(cppu::getCaughtException()),
RTL_TEXTENCODING_UTF8 ) );
@@ -1010,8 +1000,7 @@ bool SlideImpl::applyInitialShapeAttributes(
}
catch( uno::Exception& )
{
- OSL_ENSURE(
- false,
+ OSL_FAIL(
rtl::OUStringToOString(
comphelper::anyToString(cppu::getCaughtException()),
RTL_TEXTENCODING_UTF8 ) );
@@ -1055,8 +1044,7 @@ bool SlideImpl::applyInitialShapeAttributes(
if( !pShape )
{
- OSL_ENSURE( false,
- "SlideImpl::applyInitialShapeAttributes(): no shape found for given target" );
+ OSL_FAIL( "SlideImpl::applyInitialShapeAttributes(): no shape found for given target" );
continue;
}
@@ -1065,8 +1053,7 @@ bool SlideImpl::applyInitialShapeAttributes(
if( !pAttrShape )
{
- OSL_ENSURE( false,
- "SlideImpl::applyInitialShapeAttributes(): shape found does not "
+ OSL_FAIL( "SlideImpl::applyInitialShapeAttributes(): shape found does not "
"implement AttributableShape interface" );
continue;
}
@@ -1084,8 +1071,7 @@ bool SlideImpl::applyInitialShapeAttributes(
if( !pAttrShape )
{
- OSL_ENSURE( false,
- "SlideImpl::applyInitialShapeAttributes(): shape found does not "
+ OSL_FAIL( "SlideImpl::applyInitialShapeAttributes(): shape found does not "
"provide a subset for requested paragraph index" );
continue;
}
@@ -1106,8 +1092,7 @@ bool SlideImpl::applyInitialShapeAttributes(
}
else
{
- OSL_ENSURE( false,
- "SlideImpl::applyInitialShapeAttributes(): Unexpected "
+ OSL_FAIL( "SlideImpl::applyInitialShapeAttributes(): Unexpected "
"(and unimplemented) property encountered" );
}
}
@@ -1173,7 +1158,7 @@ bool SlideImpl::loadShapes()
}
addPolygons(aMPShapesFunctor.getPolygons());
- nCurrCount = xMasterPageShapes->getCount() + 1;
+ nCurrCount = static_cast<sal_Int32>(aMPShapesFunctor.getImportedShapesCount());
}
catch( uno::RuntimeException& )
{
@@ -1182,15 +1167,13 @@ bool SlideImpl::loadShapes()
catch( ShapeLoadFailedException& )
{
// TODO(E2): Error handling. For now, bail out
- OSL_ENSURE( false,
- "SlideImpl::loadShapes(): caught ShapeLoadFailedException" );
+ OSL_FAIL( "SlideImpl::loadShapes(): caught ShapeLoadFailedException" );
return false;
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -1227,14 +1210,12 @@ bool SlideImpl::loadShapes()
catch( ShapeLoadFailedException& )
{
// TODO(E2): Error handling. For now, bail out
- OSL_ENSURE( false,
- "SlideImpl::loadShapes(): caught ShapeLoadFailedException" );
+ OSL_FAIL( "SlideImpl::loadShapes(): caught ShapeLoadFailedException" );
return false;
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -1299,3 +1280,5 @@ SlideSharedPtr createSlide( const uno::Reference< drawing::XDrawPage >& xDrawP
} // namespace internal
} // namespace slideshow
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/userpaintoverlay.cxx b/slideshow/source/engine/slide/userpaintoverlay.cxx
index a3531008d..a3efc86ad 100644
--- a/slideshow/source/engine/slide/userpaintoverlay.cxx
+++ b/slideshow/source/engine/slide/userpaintoverlay.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -549,7 +550,7 @@ namespace slideshow
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -557,3 +558,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slide/userpaintoverlay.hxx b/slideshow/source/engine/slide/userpaintoverlay.hxx
index 07031bf34..f50080701 100644
--- a/slideshow/source/engine/slide/userpaintoverlay.hxx
+++ b/slideshow/source/engine/slide/userpaintoverlay.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_USERPAINTOVERLAY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slidebitmap.cxx b/slideshow/source/engine/slidebitmap.cxx
index 59a28af50..260d9e651 100644
--- a/slideshow/source/engine/slidebitmap.cxx
+++ b/slideshow/source/engine/slidebitmap.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,8 +97,7 @@ namespace slideshow
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -130,3 +130,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slideshowcontext.cxx b/slideshow/source/engine/slideshowcontext.cxx
index 4a2080fde..cbca36848 100644
--- a/slideshow/source/engine/slideshowcontext.cxx
+++ b/slideshow/source/engine/slideshowcontext.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ void SlideShowContext::dispose()
} // namespace internal
} // namespace slideshow
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
index e5f0f7d56..2e2f4fa6c 100644
--- a/slideshow/source/engine/slideshowimpl.cxx
+++ b/slideshow/source/engine/slideshowimpl.cxx
@@ -1,7 +1,8 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -160,12 +161,6 @@ public:
*/
void Deactivate (void);
- /** Return the current time of the timer. It is not synchronized with
- any other timer so its absolute values are of no concern. Typically
- used during debugging to measure durations.
- */
- double GetCurrentTime (void) const;
-
private:
/** The timer that is used for synchronization is independent from the
one used by SlideShowImpl: it is not paused or modified by
@@ -186,26 +181,23 @@ private:
bool mbIsActive;
};
-
-
-
/******************************************************************************
-
+
SlideShowImpl
This class encapsulates the slideshow presentation viewer.
-
+
With an instance of this class, it is possible to statically
and dynamically show a presentation, as defined by the
constructor-provided draw model (represented by a sequence
of ::com::sun::star::drawing::XDrawPage objects).
-
+
It is possible to show the presentation on multiple views
simultaneously (e.g. for a multi-monitor setup). Since this
class also relies on user interaction, the corresponding
XSlideShowView interface provides means to register some UI
event listeners (mostly borrowed from awt::XWindow interface).
-
+
Since currently (mid 2004), OOo isn't very well suited to
multi-threaded rendering, this class relies on <em>very
frequent</em> external update() calls, which will render the
@@ -344,7 +336,6 @@ private:
uno::Reference<drawing::XShape> const& xShape, sal_Int16 nPointerShape )
throw (uno::RuntimeException);
-
// CursorManager
// -----------------------------------------------------------
@@ -357,32 +348,32 @@ private:
transition.
*/
void redisplayCurrentSlide (void);
-
+
protected:
// WeakComponentImplHelperBase
- virtual void SAL_CALL disposing();
-
- bool isDisposed() const
+ virtual void SAL_CALL disposing();
+
+ bool isDisposed() const
{
return (rBHelper.bDisposed || rBHelper.bInDispose);
}
-
+
private:
struct SeparateListenerImpl; friend struct SeparateListenerImpl;
struct PrefetchPropertiesFunc; friend struct PrefetchPropertiesFunc;
-
+
/// Stop currently running show.
void stopShow();
-
+
///Find a polygons vector in maPolygons (map)
PolygonMap::iterator findPolygons( uno::Reference<drawing::XDrawPage> const& xDrawPage);
-
+
/// Creates a new slide.
SlideSharedPtr makeSlide(
uno::Reference<drawing::XDrawPage> const& xDrawPage,
uno::Reference<drawing::XDrawPagesSupplier> const& xDrawPages,
uno::Reference<animations::XAnimationNode> const& xRootNode );
-
+
/// Checks whether the given slide/animation node matches mpPrefetchSlide
static bool matches(
SlideSharedPtr const& pSlide,
@@ -432,7 +423,6 @@ private:
{ mrSlideShowImpl.releaseWaitSymbol(); }
private: SlideShowImpl& mrSlideShowImpl;
};
-
/// Filter requested cursor shape against hard slideshow cursors (wait, etc.)
sal_Int16 calcActiveCursor( sal_Int16 nCursorShape ) const;
@@ -516,7 +506,6 @@ private:
FrameSynchronization maFrameSynchronization;
};
-
/** Separate event listener for animation, view and hyperlink events.
This handler is registered for slide animation end, view and
@@ -533,12 +522,12 @@ struct SlideShowImpl::SeparateListenerImpl : public EventHandler,
ScreenUpdater& mrScreenUpdater;
EventQueue& mrEventQueue;
- SeparateListenerImpl( SlideShowImpl& rShow,
+ SeparateListenerImpl( SlideShowImpl& rShow,
ScreenUpdater& rScreenUpdater,
EventQueue& rEventQueue ) :
- mrShow( rShow ),
+ mrShow( rShow ),
mrScreenUpdater( rScreenUpdater ),
- mrEventQueue( rEventQueue )
+ mrEventQueue( rEventQueue )
{}
// EventHandler
@@ -579,7 +568,6 @@ struct SlideShowImpl::SeparateListenerImpl : public EventHandler,
}
};
-
SlideShowImpl::SlideShowImpl(
uno::Reference<uno::XComponentContext> const& xContext )
: SlideShowImplBase(m_aMutex),
@@ -595,7 +583,7 @@ SlideShowImpl::SlideShowImpl(
maEventMultiplexer( maEventQueue,
maViewContainer ),
maActivitiesQueue( mpPresTimer ),
- maUserEventQueue( maEventMultiplexer,
+ maUserEventQueue( maEventMultiplexer,
maEventQueue,
*this ),
mpDummyPtr(),
@@ -626,8 +614,8 @@ SlideShowImpl::SlideShowImpl(
{
// keep care not constructing any UNO references to this inside ctor,
// shift that code to create()!
-
- uno::Reference<lang::XMultiComponentFactory> xFactory(
+
+ uno::Reference<lang::XMultiComponentFactory> xFactory(
mxComponentContext->getServiceManager() );
if( xFactory.is() )
@@ -635,10 +623,10 @@ SlideShowImpl::SlideShowImpl(
try
{
// #i82460# try to retrieve special transition factory
- mxOptionalTransitionFactory.set(
- xFactory->createInstanceWithContext(
- ::rtl::OUString::createFromAscii( "com.sun.star.presentation.TransitionFactory" ),
- mxComponentContext ),
+ mxOptionalTransitionFactory.set(
+ xFactory->createInstanceWithContext(
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.presentation.TransitionFactory" )),
+ mxComponentContext ),
uno::UNO_QUERY );
}
catch (loader::CannotActivateFactoryException const&)
@@ -647,7 +635,7 @@ SlideShowImpl::SlideShowImpl(
}
mpListener.reset( new SeparateListenerImpl(
- *this,
+ *this,
maScreenUpdater,
maEventQueue ));
maEventMultiplexer.addSlideAnimationsEndHandler( mpListener );
@@ -677,13 +665,13 @@ void SlideShowImpl::disposing()
mpWaitSymbol.reset();
- if( mpRehearseTimingsActivity )
+ if( mpRehearseTimingsActivity )
{
mpRehearseTimingsActivity->dispose();
mpRehearseTimingsActivity.reset();
}
- if( mpListener )
+ if( mpListener )
{
maEventMultiplexer.removeSlideAnimationsEndHandler(mpListener);
maEventMultiplexer.removeViewRepaintHandler(mpListener);
@@ -692,7 +680,7 @@ void SlideShowImpl::disposing()
maEventMultiplexer.removeAnimationEndHandler( mpListener );
mpListener.reset();
- }
+ }
maUserEventQueue.clear();
maActivitiesQueue.clear();
@@ -719,7 +707,7 @@ void SlideShowImpl::disposing()
/// stops the current slide transition sound
void SlideShowImpl::stopSlideTransitionSound()
{
- if (mpCurrentSlideTransitionSound)
+ if (mpCurrentSlideTransitionSound)
{
mpCurrentSlideTransitionSound->stopPlayback();
mpCurrentSlideTransitionSound->dispose();
@@ -741,15 +729,15 @@ SoundPlayerSharedPtr SlideShowImpl::resetSlideTransitionSound( const uno::Any& r
stopSlideTransitionSound();
- if (url.getLength() > 0)
+ if (url.getLength() > 0)
{
- try
+ try
{
mpCurrentSlideTransitionSound = SoundPlayer::create(
maEventMultiplexer, url, mxComponentContext );
mpCurrentSlideTransitionSound->setPlaybackLoop( bLoopSound );
}
- catch (lang::NoSupportException const&)
+ catch (lang::NoSupportException const&)
{
// catch possible exceptions from SoundPlayer, since
// being not able to playback the sound is not a hard
@@ -874,12 +862,12 @@ ActivitySharedPtr SlideShowImpl::createSlideTransition(
OSL_TRACE( "createSlideTransition(): "
"No minimal number of frames given - assuming 5\n" );
}
-
+
// prefetch slide transition bitmaps, but postpone it after
// displaySlide() has finished - sometimes, view size has not yet
// reached final size
- maEventQueue.addEvent(
- makeEvent(
+ maEventQueue.addEvent(
+ makeEvent(
boost::bind(
&::slideshow::internal::Animation::prefetch,
pTransition,
@@ -910,9 +898,8 @@ PolygonMap::iterator SlideShowImpl::findPolygons( uno::Reference<drawing::XDrawP
// TODO(P2) : Optimze research in the map.
bool bFound = false;
PolygonMap::iterator aIter=maPolygons.begin();
-
-
- while(aIter!=maPolygons.end() && !bFound)
+
+ while(aIter!=maPolygons.end() && !bFound)
{
if(aIter->first == xDrawPage)
bFound = true;
@@ -921,7 +908,7 @@ PolygonMap::iterator SlideShowImpl::findPolygons( uno::Reference<drawing::XDrawP
}
return aIter;
-}
+}
SlideSharedPtr SlideShowImpl::makeSlide(
uno::Reference<drawing::XDrawPage> const& xDrawPage,
@@ -934,8 +921,8 @@ SlideSharedPtr SlideShowImpl::makeSlide(
//Retrieve polygons for the current slide
PolygonMap::iterator aIter;
aIter = findPolygons(xDrawPage);
-
- const SlideSharedPtr pSlide( createSlide(xDrawPage,
+
+ const SlideSharedPtr pSlide( createSlide(xDrawPage,
xDrawPages,
xRootNode,
maEventQueue,
@@ -954,8 +941,8 @@ SlideSharedPtr SlideShowImpl::makeSlide(
!!maUserPaintColor,
mbImageAnimationsAllowed,
mbDisableAnimationZOrder) );
-
- // prefetch show content (reducing latency for slide
+
+ // prefetch show content (reducing latency for slide
// bitmap and effect start later on)
pSlide->prefetch();
@@ -1008,7 +995,6 @@ sal_Int16 SlideShowImpl::calcActiveCursor( sal_Int16 nCursorShape ) const
return nCursorShape;
}
-
void SlideShowImpl::stopShow()
{
@@ -1020,10 +1006,10 @@ void SlideShowImpl::stopShow()
//Register polygons in the map
if(findPolygons(mpCurrentSlide->getXDrawPage()) != maPolygons.end())
maPolygons.erase(mpCurrentSlide->getXDrawPage());
-
- maPolygons.insert(make_pair(mpCurrentSlide->getXDrawPage(),mpCurrentSlide->getPolygons()));
+
+ maPolygons.insert(make_pair(mpCurrentSlide->getXDrawPage(),mpCurrentSlide->getPolygons()));
}
-
+
// clear all queues
maEventQueue.clear();
maActivitiesQueue.clear();
@@ -1040,7 +1026,7 @@ void SlideShowImpl::stopShow()
// re-enable automatic effect advancement
// (maEventQueue.clear() above might have killed
// maEventMultiplexer's tick events)
- if (mbAutomaticAdvancementMode)
+ if (mbAutomaticAdvancementMode)
{
// toggle automatic mode (enabling just again is
// ignored by EventMultiplexer)
@@ -1049,9 +1035,7 @@ void SlideShowImpl::stopShow()
}
}
-
-
-class SlideShowImpl::PrefetchPropertiesFunc
+class SlideShowImpl::PrefetchPropertiesFunc
{
public:
PrefetchPropertiesFunc( SlideShowImpl * that_,
@@ -1061,13 +1045,13 @@ public:
mrbSkipAllMainSequenceEffects(rbSkipAllMainSequenceEffects),
mrbSkipSlideTransition(rbSkipSlideTransition)
{}
-
+
void operator()( beans::PropertyValue const& rProperty ) const {
if (rProperty.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM("Prefetch") ))
+ RTL_CONSTASCII_STRINGPARAM("Prefetch") ))
{
uno::Sequence<uno::Any> seq;
- if ((rProperty.Value >>= seq) && seq.getLength() == 2)
+ if ((rProperty.Value >>= seq) && seq.getLength() == 2)
{
seq[0] >>= mpSlideShowImpl->mxPrefetchSlide;
seq[1] >>= mpSlideShowImpl->mxPrefetchAnimationNode;
@@ -1083,9 +1067,9 @@ public:
{
rProperty.Value >>= mrbSkipSlideTransition;
}
- else
+ else
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
rProperty.Name, RTL_TEXTENCODING_UTF8 ).getStr() );
}
}
@@ -1113,7 +1097,7 @@ void SlideShowImpl::displaySlide(
DBG_TESTSOLARMUTEX();
mxDrawPagesSupplier = xDrawPages;
-
+
stopShow(); // MUST call that: results in
// maUserEventQueue.clear(). What's more,
// stopShow()'s currSlide->hide() call is
@@ -1136,20 +1120,20 @@ void SlideShowImpl::displaySlide(
// this here might take some time
{
WaitSymbolLock aLock (*this);
-
+
mpPreviousSlide = mpCurrentSlide;
mpCurrentSlide.reset();
- if (matches( mpPrefetchSlide, xSlide, xRootNode ))
+ if (matches( mpPrefetchSlide, xSlide, xRootNode ))
{
// prefetched slide matches:
mpCurrentSlide = mpPrefetchSlide;
}
- else
+ else
mpCurrentSlide = makeSlide( xSlide, xDrawPages, xRootNode );
-
+
OSL_ASSERT( mpCurrentSlide );
- if (mpCurrentSlide)
+ if (mpCurrentSlide)
{
basegfx::B2DSize oldSlideSize;
if( mpPreviousSlide )
@@ -1160,19 +1144,19 @@ void SlideShowImpl::displaySlide(
// push new transformation to all views, if size changed
if( !mpPreviousSlide || oldSlideSize != slideSize )
{
- std::for_each( maViewContainer.begin(),
+ std::for_each( maViewContainer.begin(),
maViewContainer.end(),
boost::bind( &View::setViewSize, _1,
boost::cref(slideSize) ));
-
+
// explicitly notify view change here,
// because transformation might have changed:
// optimization, this->notifyViewChange() would
// repaint slide which is not necessary.
maEventMultiplexer.notifyViewsChanged();
}
-
- // create slide transition, and add proper end event
+
+ // create slide transition, and add proper end event
// (which then starts the slide effects
// via CURRENT_SLIDE.show())
ActivitySharedPtr pSlideChangeActivity (
@@ -1180,7 +1164,7 @@ void SlideShowImpl::displaySlide(
mpCurrentSlide->getXDrawPage(),
mpPreviousSlide,
mpCurrentSlide,
- makeEvent(
+ makeEvent(
boost::bind(
&SlideShowImpl::notifySlideTransitionEnded,
this,
@@ -1195,18 +1179,18 @@ void SlideShowImpl::displaySlide(
// anymore.
pSlideChangeActivity.reset();
}
-
- if (pSlideChangeActivity)
+
+ if (pSlideChangeActivity)
{
// factory generated a slide transition - activate it!
maActivitiesQueue.addActivity( pSlideChangeActivity );
}
- else
+ else
{
// no transition effect on this slide - schedule slide
// effect start event right away.
- maEventQueue.addEvent(
- makeEvent(
+ maEventQueue.addEvent(
+ makeEvent(
boost::bind(
&SlideShowImpl::notifySlideTransitionEnded,
this,
@@ -1237,15 +1221,15 @@ void SlideShowImpl::redisplayCurrentSlide (void)
// precondition: must only be called from the main thread!
DBG_TESTSOLARMUTEX();
stopShow();
-
+
OSL_ENSURE( !maViewContainer.empty(), "### no views!" );
if (maViewContainer.empty())
return;
// No transition effect on this slide - schedule slide
// effect start event right away.
- maEventQueue.addEvent(
- makeEvent(
+ maEventQueue.addEvent(
+ makeEvent(
boost::bind(
&SlideShowImpl::notifySlideTransitionEnded,
this,
@@ -1273,14 +1257,13 @@ sal_Bool SlideShowImpl::nextEffect() throw (uno::RuntimeException)
return maEventMultiplexer.notifyNextEffect();
}
-
sal_Bool SlideShowImpl::previousEffect() throw (uno::RuntimeException)
{
osl::MutexGuard const guard( m_aMutex );
if (isDisposed())
return false;
-
+
// precondition: must only be called from the main thread!
DBG_TESTSOLARMUTEX();
@@ -1327,7 +1310,7 @@ sal_Bool SlideShowImpl::startShapeActivity(
DBG_TESTSOLARMUTEX();
// TODO(F3): NYI
- OSL_ENSURE( false, "not yet implemented!" );
+ OSL_FAIL( "not yet implemented!" );
return false;
}
@@ -1341,7 +1324,7 @@ sal_Bool SlideShowImpl::stopShapeActivity(
DBG_TESTSOLARMUTEX();
// TODO(F3): NYI
- OSL_ENSURE( false, "not yet implemented!" );
+ OSL_FAIL( "not yet implemented!" );
return false;
}
@@ -1352,18 +1335,17 @@ sal_Bool SlideShowImpl::pause( sal_Bool bPauseShow )
if (isDisposed())
return false;
-
+
// precondition: must only be called from the main thread!
DBG_TESTSOLARMUTEX();
-
if (bPauseShow)
mpPresTimer->pauseTimer();
else
mpPresTimer->continueTimer();
-
+
maEventMultiplexer.notifyPauseMode(bPauseShow);
-
+
mbShowPaused = bPauseShow;
return true;
}
@@ -1401,18 +1383,18 @@ sal_Bool SlideShowImpl::addView(
ENSURE_OR_RETURN_FALSE( xView.is(), "addView(): Invalid view" );
ENSURE_OR_RETURN_FALSE( xView->getCanvas().is(),
"addView(): View does not provide a valid canvas" );
-
+
UnoViewSharedPtr const pView( createSlideView(
- xView,
+ xView,
maEventQueue,
maEventMultiplexer ));
if (!maViewContainer.addView( pView ))
return false; // view already added
-
+
// initialize view content
// =======================
- if (mpCurrentSlide)
+ if (mpCurrentSlide)
{
// set view transformation
const basegfx::B2ISize slideSize = mpCurrentSlide->getSlideSize();
@@ -1420,7 +1402,7 @@ sal_Bool SlideShowImpl::addView(
slideSize.getY() ) );
}
- // clear view area (since its newly added,
+ // clear view area (since its newly added,
// we need a clean slate)
pView->clearAll();
@@ -1438,26 +1420,26 @@ sal_Bool SlideShowImpl::removeView(
throw (uno::RuntimeException)
{
osl::MutexGuard const guard( m_aMutex );
-
+
// precondition: must only be called from the main thread!
DBG_TESTSOLARMUTEX();
ENSURE_OR_RETURN_FALSE( xView.is(), "removeView(): Invalid view" );
-
+
UnoViewSharedPtr const pView( maViewContainer.removeView( xView ) );
if( !pView )
return false; // view was not added in the first place
-
+
// remove view from EventMultiplexer (mouse events etc.)
maEventMultiplexer.notifyViewRemoved( pView );
-
+
pView->_dispose();
return true;
}
void SlideShowImpl::registerUserPaintPolygons( const uno::Reference< lang::XMultiServiceFactory >& xDocFactory ) throw (uno::RuntimeException)
-{
+{
//Retrieve Polygons if user ends presentation by context menu
if (mpCurrentSlide)
{
@@ -1466,67 +1448,67 @@ void SlideShowImpl::registerUserPaintPolygons( const uno::Reference< lang::XMult
maPolygons.insert(make_pair(mpCurrentSlide->getXDrawPage(),mpCurrentSlide->getPolygons()));
}
-
+
//Creating the layer for shapes
// query for the XLayerManager
uno::Reference< drawing::XLayerSupplier > xLayerSupplier(xDocFactory, uno::UNO_QUERY);
uno::Reference< container::XNameAccess > xNameAccess = xLayerSupplier->getLayerManager();
-
+
uno::Reference< drawing::XLayerManager > xLayerManager(xNameAccess, uno::UNO_QUERY);
// create a layer and set its properties
uno::Reference< drawing::XLayer > xDrawnInSlideshow = xLayerManager->insertNewByIndex(xLayerManager->getCount());
uno::Reference< beans::XPropertySet > xLayerPropSet(xDrawnInSlideshow, uno::UNO_QUERY);
-
+
//Layer Name which enables to catch annotations
- rtl::OUString layerName = rtl::OUString::createFromAscii("DrawnInSlideshow");
+ rtl::OUString layerName = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DrawnInSlideshow"));
uno::Any aPropLayer;
-
+
aPropLayer <<= layerName;
- xLayerPropSet->setPropertyValue(rtl::OUString::createFromAscii("Name"), aPropLayer);
-
+ xLayerPropSet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name")), aPropLayer);
+
aPropLayer <<= true;
- xLayerPropSet->setPropertyValue(rtl::OUString::createFromAscii("IsVisible"), aPropLayer);
-
+ xLayerPropSet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsVisible")), aPropLayer);
+
aPropLayer <<= false;
- xLayerPropSet->setPropertyValue(rtl::OUString::createFromAscii("IsLocked"), aPropLayer);
+ xLayerPropSet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsLocked")), aPropLayer);
PolygonMap::iterator aIter=maPolygons.begin();
-
+
PolyPolygonVector aPolygons;
::cppcanvas::PolyPolygonSharedPtr pPolyPoly;
::basegfx::B2DPolyPolygon b2DPolyPoly;
-
+
//Register polygons for each slide
- while(aIter!=maPolygons.end())
+ while(aIter!=maPolygons.end())
{
aPolygons = aIter->second;
//Get shapes for the slide
::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShapes > Shapes(aIter->first, ::com::sun::star::uno::UNO_QUERY);
//Retrieve polygons for one slide
- for( PolyPolygonVector::iterator aIterPoly=aPolygons.begin(),
+ for( PolyPolygonVector::iterator aIterPoly=aPolygons.begin(),
aEnd=aPolygons.end();
aIterPoly!=aEnd; ++aIterPoly )
- {
+ {
pPolyPoly = (*aIterPoly);
- b2DPolyPoly = ::basegfx::unotools::b2DPolyPolygonFromXPolyPolygon2D(pPolyPoly->getUNOPolyPolygon());
-
- //Normally there is only one polygon
+ b2DPolyPoly = ::basegfx::unotools::b2DPolyPolygonFromXPolyPolygon2D(pPolyPoly->getUNOPolyPolygon());
+
+ //Normally there is only one polygon
for(sal_uInt32 i=0; i< b2DPolyPoly.count();i++)
{
const ::basegfx::B2DPolygon& aPoly = b2DPolyPoly.getB2DPolygon(i);
sal_uInt32 nPoints = aPoly.count();
-
+
if( nPoints > 1)
{
//create the PolyLineShape
uno::Reference< uno::XInterface > polyshape(xDocFactory->createInstance(
- rtl::OUString::createFromAscii("com.sun.star.drawing.PolyLineShape") ) );
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.PolyLineShape")) ) );
uno::Reference< drawing::XShape > rPolyShape(polyshape, uno::UNO_QUERY);
-
+
//Add the shape to the slide
Shapes->add(rPolyShape);
-
- //Retrieve shape properties
+
+ //Retrieve shape properties
uno::Reference< beans::XPropertySet > aXPropSet = uno::Reference< beans::XPropertySet >( rPolyShape, uno::UNO_QUERY );
//Construct a sequence of points sequence
drawing::PointSequenceSequence aRetval;
@@ -1541,8 +1523,8 @@ void SlideShowImpl::registerUserPaintPolygons( const uno::Reference< lang::XMult
for( sal_uInt32 n = 0; n < nPoints; n++ )
{
//Create a point from the polygon
- *pInnerSequence++ = awt::Point(
- basegfx::fround(aPoly.getB2DPoint(n).getX()),
+ *pInnerSequence++ = awt::Point(
+ basegfx::fround(aPoly.getB2DPoint(n).getX()),
basegfx::fround(aPoly.getB2DPoint(n).getY()));
}
@@ -1550,37 +1532,37 @@ void SlideShowImpl::registerUserPaintPolygons( const uno::Reference< lang::XMult
//Give the built PointSequenceSequence.
uno::Any aParam;
aParam <<= aRetval;
- aXPropSet->setPropertyValue( rtl::OUString::createFromAscii("PolyPolygon"), aParam );
+ aXPropSet->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PolyPolygon")), aParam );
//LineStyle : SOLID by default
uno::Any aAny;
drawing::LineStyle eLS;
eLS = drawing::LineStyle_SOLID;
aAny <<= eLS;
- aXPropSet->setPropertyValue( rtl::OUString::createFromAscii("LineStyle"), aAny );
+ aXPropSet->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LineStyle")), aAny );
//LineColor
sal_uInt32 nLineColor;
nLineColor = pPolyPoly->getRGBALineColor();
- //Transform polygon color from RRGGBBAA to AARRGGBB
+ //Transform polygon color from RRGGBBAA to AARRGGBB
aAny <<= RGBAColor2UnoColor(nLineColor);
- aXPropSet->setPropertyValue( rtl::OUString::createFromAscii("LineColor"), aAny );
-
+ aXPropSet->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LineColor")), aAny );
+
//LineWidth
double fLineWidth;
fLineWidth = pPolyPoly->getStrokeWidth();
aAny <<= (sal_Int32)fLineWidth;
- aXPropSet->setPropertyValue( rtl::OUString::createFromAscii("LineWidth"), aAny );
+ aXPropSet->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LineWidth")), aAny );
- // make polygons special
+ // make polygons special
xLayerManager->attachShapeToLayer(rPolyShape, xDrawnInSlideshow);
}
- }
+ }
}
++aIter;
}
}
-
+
sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
throw (uno::RuntimeException)
{
@@ -1597,19 +1579,19 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
{
double nTimeout(0.0);
mbAutomaticAdvancementMode = (rProperty.Value >>= nTimeout);
- if (mbAutomaticAdvancementMode)
+ if (mbAutomaticAdvancementMode)
{
maEventMultiplexer.setAutomaticTimeout( nTimeout );
}
maEventMultiplexer.setAutomaticMode( mbAutomaticAdvancementMode );
return true;
}
-
+
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("UserPaintColor") ))
{
sal_Int32 nColor(0);
- if (rProperty.Value >>= nColor)
+ if (rProperty.Value >>= nColor)
{
OSL_ENSURE( mbMouseVisible,
"setProperty(): User paint overrides invisible mouse" );
@@ -1621,7 +1603,7 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
maEventMultiplexer.notifyUserPaintColor( *maUserPaintColor );
}
- else
+ else
{
// disable user paint
maUserPaintColor.reset();
@@ -1634,22 +1616,22 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
return true;
}
-
+
//adding support for erasing features in UserPaintOverlay
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("EraseAllInk") ))
{
bool nEraseAllInk(false);
- if (rProperty.Value >>= nEraseAllInk)
+ if (rProperty.Value >>= nEraseAllInk)
{
OSL_ENSURE( mbMouseVisible,
"setProperty(): User paint overrides invisible mouse" );
-
+
// enable user paint
maEraseAllInk.reset( nEraseAllInk );
maEventMultiplexer.notifyEraseAllInk( *maEraseAllInk );
}
-
+
return true;
}
@@ -1657,7 +1639,7 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
RTL_CONSTASCII_STRINGPARAM("SwitchPenMode") ))
{
bool nSwitchPenMode(false);
- if (rProperty.Value >>= nSwitchPenMode)
+ if (rProperty.Value >>= nSwitchPenMode)
{
OSL_ENSURE( mbMouseVisible,
"setProperty(): User paint overrides invisible mouse" );
@@ -1671,12 +1653,11 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
return true;
}
-
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("SwitchEraserMode") ))
{
bool nSwitchEraserMode(false);
- if (rProperty.Value >>= nSwitchEraserMode)
+ if (rProperty.Value >>= nSwitchEraserMode)
{
OSL_ENSURE( mbMouseVisible,
"setProperty(): User paint overrides invisible mouse" );
@@ -1686,29 +1667,27 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
maEventMultiplexer.notifySwitchEraserMode();
}
}
-
+
return true;
}
-
-
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("EraseInk") ))
{
sal_Int32 nEraseInk(100);
- if (rProperty.Value >>= nEraseInk)
+ if (rProperty.Value >>= nEraseInk)
{
OSL_ENSURE( mbMouseVisible,
"setProperty(): User paint overrides invisible mouse" );
-
+
// enable user paint
maEraseInk.reset( nEraseInk );
maEventMultiplexer.notifyEraseInkWidth( *maEraseInk );
}
-
+
return true;
}
-
+
// new Property for pen's width
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("UserPaintStrokeWidth") ))
@@ -1724,27 +1703,27 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
return true;
}
-
+
if (rProperty.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM("AdvanceOnClick") ))
+ RTL_CONSTASCII_STRINGPARAM("AdvanceOnClick") ))
{
sal_Bool bAdvanceOnClick = sal_False;
if (! (rProperty.Value >>= bAdvanceOnClick))
return false;
maUserEventQueue.setAdvanceOnClick( bAdvanceOnClick );
return true;
- }
-
+ }
+
if (rProperty.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM("DisableAnimationZOrder") ))
+ RTL_CONSTASCII_STRINGPARAM("DisableAnimationZOrder") ))
{
sal_Bool bDisableAnimationZOrder = sal_False;
if (! (rProperty.Value >>= bDisableAnimationZOrder))
return false;
mbDisableAnimationZOrder = bDisableAnimationZOrder == sal_True;
return true;
- }
-
+ }
+
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("ImageAnimationsAllowed") ) )
{
@@ -1773,28 +1752,28 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
return true;
}
-
+
if (rProperty.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM("ForceManualAdvance") ))
+ RTL_CONSTASCII_STRINGPARAM("ForceManualAdvance") ))
{
return (rProperty.Value >>= mbForceManualAdvance);
}
-
+
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("RehearseTimings") ))
{
bool bRehearseTimings = false;
if (! (rProperty.Value >>= bRehearseTimings))
return false;
-
- if (bRehearseTimings)
+
+ if (bRehearseTimings)
{
// TODO(Q3): Move to slide
mpRehearseTimingsActivity = RehearseTimingsActivity::create(
SlideShowContext(
mpDummyPtr,
- maEventQueue,
- maEventMultiplexer,
+ maEventQueue,
+ maEventMultiplexer,
maScreenUpdater,
maActivitiesQueue,
maUserEventQueue,
@@ -1802,7 +1781,7 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
maViewContainer,
mxComponentContext) );
}
- else if (mpRehearseTimingsActivity)
+ else if (mpRehearseTimingsActivity)
{
// removes timer from all views:
mpRehearseTimingsActivity->dispose();
@@ -1810,28 +1789,28 @@ sal_Bool SlideShowImpl::setProperty( beans::PropertyValue const& rProperty )
}
return true;
}
-
+
if (rProperty.Name.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("WaitSymbolBitmap") ))
{
uno::Reference<rendering::XBitmap> xBitmap;
if (! (rProperty.Value >>= xBitmap))
return false;
-
- mpWaitSymbol = WaitSymbol::create( xBitmap,
+
+ mpWaitSymbol = WaitSymbol::create( xBitmap,
maScreenUpdater,
maEventMultiplexer,
maViewContainer );
return true;
}
-
+
if (rProperty.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM("NoSlideTransitions") ))
+ RTL_CONSTASCII_STRINGPARAM("NoSlideTransitions") ))
{
return (rProperty.Value >>= mbNoSlideTransitions);
}
-
+
if (rProperty.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsSoundEnabled")))
{
uno::Sequence<uno::Any> aValues;
@@ -1904,11 +1883,11 @@ void SlideShowImpl::addShapeEventListener(
maShapeEventListeners.end() )
{
// no entry for this shape -> create one
- aIter = maShapeEventListeners.insert(
+ aIter = maShapeEventListeners.insert(
ShapeEventListenerMap::value_type(
xShape,
- boost::shared_ptr<cppu::OInterfaceContainerHelper>(
- new cppu::OInterfaceContainerHelper(m_aMutex)))).first;
+ boost::shared_ptr<cppu::OInterfaceContainerHelper>(
+ new cppu::OInterfaceContainerHelper(m_aMutex)))).first;
}
// add new listener to broadcaster
@@ -1955,37 +1934,37 @@ void SlideShowImpl::setShapeCursor(
if (isDisposed())
return;
-
+
// precondition: must only be called from the main thread!
DBG_TESTSOLARMUTEX();
ShapeCursorMap::iterator aIter;
- if( (aIter=maShapeCursors.find( xShape )) == maShapeCursors.end() )
+ if( (aIter=maShapeCursors.find( xShape )) == maShapeCursors.end() )
{
// no entry for this shape -> create one
- if( nPointerShape != awt::SystemPointer::ARROW )
+ if( nPointerShape != awt::SystemPointer::ARROW )
{
// add new entry, unless shape shall display
// normal pointer arrow -> no need to handle that
// case
maShapeCursors.insert(
- ShapeCursorMap::value_type(xShape,
+ ShapeCursorMap::value_type(xShape,
nPointerShape) );
}
}
- else if( nPointerShape == awt::SystemPointer::ARROW )
+ else if( nPointerShape == awt::SystemPointer::ARROW )
{
// shape shall display normal cursor -> can disable
// the cursor and clear the entry
maShapeCursors.erase( xShape );
}
- else
+ else
{
// existing entry found, update with new cursor ID
aIter->second = nPointerShape;
}
- maEventMultiplexer.notifyShapeCursorChange(xShape,
+ maEventMultiplexer.notifyShapeCursorChange(xShape,
nPointerShape);
}
@@ -1996,10 +1975,10 @@ bool SlideShowImpl::requestCursor( sal_Int16 nCursorShape )
const sal_Int16 nActualCursor = calcActiveCursor(mnCurrentCursor);
// change all views to the requested cursor ID
- std::for_each( maViewContainer.begin(),
+ std::for_each( maViewContainer.begin(),
maViewContainer.end(),
- boost::bind( &View::setCursorShape,
- _1,
+ boost::bind( &View::setCursorShape,
+ _1,
nActualCursor ));
return nActualCursor==nCursorShape;
@@ -2010,10 +1989,10 @@ void SlideShowImpl::resetCursor()
mnCurrentCursor = awt::SystemPointer::ARROW;
// change all views to the default cursor ID
- std::for_each( maViewContainer.begin(),
+ std::for_each( maViewContainer.begin(),
maViewContainer.end(),
- boost::bind( &View::setCursorShape,
- _1,
+ boost::bind( &View::setCursorShape,
+ _1,
calcActiveCursor(mnCurrentCursor) ));
}
@@ -2024,23 +2003,23 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
if (isDisposed())
return false;
-
+
// precondition: update() must only be called from the
// main thread!
DBG_TESTSOLARMUTEX();
- if( mbShowPaused )
+ if( mbShowPaused )
{
// commit frame (might be repaints pending)
maScreenUpdater.commitUpdates();
return false;
}
- else
+ else
{
// TODO(F2): re-evaluate whether that timer lagging makes
// sense.
-
+
// hold timer, while processing the queues:
// 1. when there is more than one active activity this ensures the
// same time for all activities and events
@@ -2090,15 +2069,15 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
maScreenUpdater.commitUpdates();
}
// Time held until here
-
+
const bool bActivitiesLeft = (! maActivitiesQueue.isEmpty());
const bool bTimerEventsLeft = (! maEventQueue.isEmpty());
const bool bRet = (bActivitiesLeft || bTimerEventsLeft);
-
- if (bRet)
+
+ if (bRet)
{
// calc nNextTimeout value:
- if (bActivitiesLeft)
+ if (bActivitiesLeft)
{
// Activity queue is not empty. Tell caller that we would
// like to render another frame.
@@ -2110,7 +2089,7 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
nNextTimeout = 0;
maFrameSynchronization.Activate();
}
- else
+ else
{
// timer events left:
// difference from current time (nota bene:
@@ -2151,15 +2130,14 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
uno::Reference< util::XUpdatable > xUpdatable( xView->getCanvas(),
uno::UNO_QUERY_THROW );
xUpdatable->update();
- }
+ }
catch( uno::RuntimeException& )
{
throw;
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -2182,7 +2160,7 @@ void SlideShowImpl::notifySlideTransitionEnded( bool bPaintSlide )
OSL_ENSURE( !isDisposed(), "### already disposed!" );
OSL_ENSURE( mpCurrentSlide,
"notifySlideTransitionEnded(): Invalid current slide" );
- if (mpCurrentSlide)
+ if (mpCurrentSlide)
{
mpCurrentSlide->update_settings( !!maUserPaintColor, maUserPaintColor ? *maUserPaintColor : RGBColor(), maUserPaintStrokeWidth );
@@ -2203,25 +2181,25 @@ void queryAutomaticSlideTransition( uno::Reference<drawing::XDrawPage> const& xD
uno::Reference< beans::XPropertySet > xPropSet( xDrawPage,
uno::UNO_QUERY );
-
+
sal_Int32 nChange(0);
if( !xPropSet.is() ||
!getPropertyValue( nChange,
xPropSet,
- ::rtl::OUString(
+ ::rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM("Change"))) )
{
OSL_TRACE(
"queryAutomaticSlideTransition(): "
"Could not extract slide change mode from XDrawPage - assuming <none>\n" );
}
-
+
bHasAutomaticNextSlide = nChange == 1;
if( !xPropSet.is() ||
!getPropertyValue( nAutomaticNextSlideTimeout,
xPropSet,
- ::rtl::OUString(
+ ::rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM("Duration"))) )
{
OSL_TRACE(
@@ -2237,29 +2215,29 @@ void SlideShowImpl::notifySlideAnimationsEnded()
//Draw polygons above animations
mpCurrentSlide->drawPolygons();
-
+
OSL_ENSURE( !isDisposed(), "### already disposed!" );
-
+
// This struct will receive the (interruptable) event,
// that triggers the notifySlideEnded() method.
InterruptableEventPair aNotificationEvents;
- if( maEventMultiplexer.getAutomaticMode() )
+ if( maEventMultiplexer.getAutomaticMode() )
{
OSL_ENSURE( ! mpRehearseTimingsActivity,
"unexpected: RehearseTimings mode!" );
-
+
// schedule a slide end event, with automatic mode's
// delay
aNotificationEvents = makeInterruptableDelay(
boost::bind<void>( boost::mem_fn(&SlideShowImpl::notifySlideEnded), this, false ),
maEventMultiplexer.getAutomaticTimeout() );
}
- else
+ else
{
OSL_ENSURE( mpCurrentSlide,
"notifySlideAnimationsEnded(): Invalid current slide!" );
-
+
bool bHasAutomaticNextSlide=false;
double nAutomaticNextSlideTimeout=0.0;
queryAutomaticSlideTransition(mpCurrentSlide->getXDrawPage(),
@@ -2279,37 +2257,37 @@ void SlideShowImpl::notifySlideAnimationsEnded()
aNotificationEvents = makeInterruptableDelay(
boost::bind<void>( boost::mem_fn(&SlideShowImpl::notifySlideEnded), this, false ),
nAutomaticNextSlideTimeout);
-
- // TODO(F2): Provide a mechanism to let the user override
+
+ // TODO(F2): Provide a mechanism to let the user override
// this automatic timeout via next()
}
- else
+ else
{
if (mpRehearseTimingsActivity)
mpRehearseTimingsActivity->start();
-
+
// generate click event. Thus, the user must
// trigger the actual end of a slide. No need to
// generate interruptable event here, there's no
// timeout involved.
- aNotificationEvents.mpImmediateEvent =
+ aNotificationEvents.mpImmediateEvent =
makeEvent( boost::bind<void>(
boost::mem_fn(&SlideShowImpl::notifySlideEnded), this, false ),
"SlideShowImpl::notifySlideEnded");
}
}
-
+
// register events on the queues. To make automatic slide
// changes interruptable, register the interruption event
// as a nextEffectEvent target. Note that the timeout
// event is optional (e.g. manual slide changes don't
- // generate a timeout)
+ // generate a timeout)
maUserEventQueue.registerNextEffectEvent(
aNotificationEvents.mpImmediateEvent );
-
+
if( aNotificationEvents.mpTimeoutEvent )
maEventQueue.addEvent( aNotificationEvents.mpTimeoutEvent );
-
+
// current slide's main sequence is over. Now should be
// the time to prefetch the next slide (if any), and
// prepare the initial slide bitmap (speeds up slide
@@ -2317,14 +2295,14 @@ void SlideShowImpl::notifySlideAnimationsEnded()
// indeed might take some seconds.
{
WaitSymbolLock aLock (*this);
-
+
if (! matches( mpPrefetchSlide,
- mxPrefetchSlide, mxPrefetchAnimationNode ))
+ mxPrefetchSlide, mxPrefetchAnimationNode ))
{
mpPrefetchSlide = makeSlide( mxPrefetchSlide, mxDrawPagesSupplier,
mxPrefetchAnimationNode );
}
- if (mpPrefetchSlide)
+ if (mpPrefetchSlide)
{
// ignore return value, this is just to populate
// Slide's internal bitmap buffer, such that the time
@@ -2343,17 +2321,17 @@ void SlideShowImpl::notifySlideEnded (const bool bReverse)
osl::MutexGuard const guard( m_aMutex );
OSL_ENSURE( !isDisposed(), "### already disposed!" );
-
- if (mpRehearseTimingsActivity && !bReverse)
+
+ if (mpRehearseTimingsActivity && !bReverse)
{
const double time = mpRehearseTimingsActivity->stop();
- if (mpRehearseTimingsActivity->hasBeenClicked())
+ if (mpRehearseTimingsActivity->hasBeenClicked())
{
// save time at current drawpage:
uno::Reference<beans::XPropertySet> xPropSet(
mpCurrentSlide->getXDrawPage(), uno::UNO_QUERY );
OSL_ASSERT( xPropSet.is() );
- if (xPropSet.is())
+ if (xPropSet.is())
{
xPropSet->setPropertyValue(
OUSTR("Change"),
@@ -2390,7 +2368,7 @@ bool SlideShowImpl::notifyHyperLinkClicked( rtl::OUString const& hyperLink )
maListenerContainer.forEach<presentation::XSlideShowListener>(
boost::bind( &presentation::XSlideShowListener::hyperLinkClicked,
- _1,
+ _1,
boost::cref(hyperLink) ));
return true;
}
@@ -2409,15 +2387,15 @@ bool SlideShowImpl::handleAnimationEvent( const AnimationNodeSharedPtr& rNode )
case AnimationNode::ACTIVE:
maListenerContainer.forEach<presentation::XSlideShowListener>(
boost::bind( &animations::XAnimationListener::beginEvent,
- _1,
+ _1,
boost::cref(xNode) ));
break;
-
+
case AnimationNode::FROZEN:
case AnimationNode::ENDED:
maListenerContainer.forEach<presentation::XSlideShowListener>(
boost::bind( &animations::XAnimationListener::endEvent,
- _1,
+ _1,
boost::cref(xNode) ));
if(mpCurrentSlide->isPaintOverlayActive())
mpCurrentSlide->drawPolygons();
@@ -2429,7 +2407,6 @@ bool SlideShowImpl::handleAnimationEvent( const AnimationNodeSharedPtr& rNode )
return true;
}
-
//===== FrameSynchronization ==================================================
FrameSynchronization::FrameSynchronization (const double nFrameDuration)
@@ -2441,17 +2418,11 @@ FrameSynchronization::FrameSynchronization (const double nFrameDuration)
MarkCurrentFrame();
}
-
-
-
void FrameSynchronization::MarkCurrentFrame (void)
{
mnNextFrameTargetTime = maTimer.getElapsedTime() + mnFrameDuration;
}
-
-
-
void FrameSynchronization::Synchronize (void)
{
if (mbIsActive)
@@ -2464,31 +2435,16 @@ void FrameSynchronization::Synchronize (void)
MarkCurrentFrame();
}
-
-
-
void FrameSynchronization::Activate (void)
{
mbIsActive = true;
}
-
-
-
void FrameSynchronization::Deactivate (void)
{
mbIsActive = false;
}
-
-
-
-double FrameSynchronization::GetCurrentTime (void) const
-{
- return maTimer.getElapsedTime();
-}
-
-
} // anon namespace
namespace sdecl = comphelper::service_decl;
@@ -2506,3 +2462,4 @@ namespace sdecl = comphelper::service_decl;
// The C shared lib entry points
COMPHELPER_SERVICEDECL_EXPORTS1(slideShowDecl)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/slideview.cxx b/slideshow/source/engine/slideview.cxx
index fb1c7223f..6834dc9fe 100644
--- a/slideshow/source/engine/slideview.cxx
+++ b/slideshow/source/engine/slideview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -791,8 +792,7 @@ SlideView::SlideView( const uno::Reference<presentation::XSlideShowView>& xView,
basegfx::B2DVector(aViewTransform.m01,
aViewTransform.m11).getLength()) )
{
- OSL_ENSURE( false,
- "SlideView::SlideView(): Singular matrix!" );
+ OSL_FAIL( "SlideView::SlideView(): Singular matrix!" );
canvas::tools::setIdentityAffineMatrix2D(aViewTransform);
}
@@ -949,8 +949,7 @@ void SlideView::setPriority( const basegfx::B1DRange& /*rRange*/ )
{
osl::MutexGuard aGuard( m_aMutex );
- OSL_ENSURE( false,
- "SlideView::setPriority() is a NOOP for slide view - "
+ OSL_FAIL( "SlideView::setPriority() is a NOOP for slide view - "
"content will always be shown in the background" );
}
@@ -987,8 +986,7 @@ bool SlideView::resize( const ::basegfx::B2DRange& /*rArea*/ )
{
osl::MutexGuard aGuard( m_aMutex );
- OSL_ENSURE( false,
- "SlideView::resize(): ignored for the View, can't change size "
+ OSL_FAIL( "SlideView::resize(): ignored for the View, can't change size "
"effectively, anyway" );
return false;
@@ -1055,8 +1053,7 @@ void SlideView::modified( const lang::EventObject& /*aEvent*/ )
basegfx::B2DVector(aViewTransform.m01,
aViewTransform.m11).getLength()) )
{
- OSL_ENSURE( false,
- "SlideView::modified(): Singular matrix!" );
+ OSL_FAIL( "SlideView::modified(): Singular matrix!" );
canvas::tools::setIdentityAffineMatrix2D(aViewTransform);
}
@@ -1194,3 +1191,4 @@ UnoViewSharedPtr createSlideView( uno::Reference< presentation::XSlideShowView>
} // namespace internal
} // namespace slideshow
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/smilfunctionparser.cxx b/slideshow/source/engine/smilfunctionparser.cxx
index 27bc8ec5f..d9ce6f5c7 100644
--- a/slideshow/source/engine/smilfunctionparser.cxx
+++ b/slideshow/source/engine/smilfunctionparser.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -190,8 +191,7 @@ namespace slideshow
{
if( !mpContext->mbParseAnimationFunction )
{
- OSL_ENSURE( false,
- "ValueTFunctor::operator(): variable encountered, but we're not parsing a function here" );
+ OSL_FAIL( "ValueTFunctor::operator(): variable encountered, but we're not parsing a function here" );
throw ParseError();
}
@@ -636,3 +636,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/soundplayer.cxx b/slideshow/source/engine/soundplayer.cxx
index 915579131..0ee0310ab 100644
--- a/slideshow/source/engine/soundplayer.cxx
+++ b/slideshow/source/engine/soundplayer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -134,7 +135,7 @@ namespace slideshow
dispose();
}
catch (uno::Exception &) {
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -181,3 +182,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/sp_debug.cxx b/slideshow/source/engine/sp_debug.cxx
index 6119ab083..25c5b2cff 100644
--- a/slideshow/source/engine/sp_debug.cxx
+++ b/slideshow/source/engine/sp_debug.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -295,3 +296,5 @@ void sp_array_destructor_hook(void *)
} // namespace boost
#endif // defined(BOOST_SP_ENABLE_DEBUG_HOOKS)
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/tools.cxx b/slideshow/source/engine/tools.cxx
index dc4c5c860..56f15ba96 100644
--- a/slideshow/source/engine/tools.cxx
+++ b/slideshow/source/engine/tools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -76,7 +77,7 @@ namespace slideshow
{
}
- bool operator()( const beans::NamedValue& rValue )
+ bool operator()( const beans::NamedValue& rValue ) const
{
return rValue.Name == mrSearchString;
}
@@ -93,7 +94,7 @@ namespace slideshow
{
}
- bool operator()( const beans::NamedValue& rValue )
+ bool operator()( const beans::NamedValue& rValue ) const
{
return rValue.Name == mrKey.Name && rValue.Value == mrKey.Value;
}
@@ -718,27 +719,6 @@ namespace slideshow
::cppcanvas::getBlue(aColor));
}
- /*sal_Int32 RGBAColor2UnoColor( ::cppcanvas::Color::IntSRGBA aColor )
- {
- return ::cppcanvas::unMakeColor(
- // convert from IntSRGBA color to API color
- // (0xRRGGBBAA -> 0xAARRGGBB)
- static_cast< sal_uInt8 >(0),
- ::cppcanvas::getRed(aColor),
- ::cppcanvas::getGreen(aColor),
- ::cppcanvas::getBlue(aColor));
- }*/
-
- sal_Int8 unSignedToSigned(sal_Int8 nInt)
- {
- if(nInt < 0 ){
- sal_Int8 nInt2 = nInt >> 1U;
- return nInt2;
- }else{
- return nInt;
- }
- }
-
void fillRect( const ::cppcanvas::CanvasSharedPtr& rCanvas,
const ::basegfx::B2DRectangle& rRect,
::cppcanvas::Color::IntSRGBA aFillColor )
@@ -810,6 +790,9 @@ namespace slideshow
aTmpRect.Y+aTmpRect.Height );
}
+/*
+ TODO(F1): When ZOrder someday becomes usable enable this
+
double getAPIShapePrio( const uno::Reference< drawing::XShape >& xShape )
{
uno::Reference< beans::XPropertySet > xPropSet( xShape,
@@ -827,6 +810,7 @@ namespace slideshow
// Maybe we can also take the total number of shapes here
return nPrio / 65535.0;
}
+*/
basegfx::B2IVector getSlideSizePixel( const basegfx::B2DVector& rSlideSize,
const UnoViewSharedPtr& pView )
@@ -851,3 +835,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/barndoorwipe.cxx b/slideshow/source/engine/transitions/barndoorwipe.cxx
index db7458513..abae768be 100644
--- a/slideshow/source/engine/transitions/barndoorwipe.cxx
+++ b/slideshow/source/engine/transitions/barndoorwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/barndoorwipe.hxx b/slideshow/source/engine/transitions/barndoorwipe.hxx
index e16c20c9c..b8683e38f 100644
--- a/slideshow/source/engine/transitions/barndoorwipe.hxx
+++ b/slideshow/source/engine/transitions/barndoorwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_BARNDOORWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/barwipepolypolygon.cxx b/slideshow/source/engine/transitions/barwipepolypolygon.cxx
index 9ba681fa6..c1d263ffa 100644
--- a/slideshow/source/engine/transitions/barwipepolypolygon.cxx
+++ b/slideshow/source/engine/transitions/barwipepolypolygon.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,3 +55,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/barwipepolypolygon.hxx b/slideshow/source/engine/transitions/barwipepolypolygon.hxx
index 1a816252e..6c7b78959 100644
--- a/slideshow/source/engine/transitions/barwipepolypolygon.hxx
+++ b/slideshow/source/engine/transitions/barwipepolypolygon.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_BARWIPEPOLYPOLYGON_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/boxwipe.cxx b/slideshow/source/engine/transitions/boxwipe.cxx
index 5fb085c40..0ecfe203e 100644
--- a/slideshow/source/engine/transitions/boxwipe.cxx
+++ b/slideshow/source/engine/transitions/boxwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/boxwipe.hxx b/slideshow/source/engine/transitions/boxwipe.hxx
index e04813bd3..fe44113d5 100644
--- a/slideshow/source/engine/transitions/boxwipe.hxx
+++ b/slideshow/source/engine/transitions/boxwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_BOXWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/checkerboardwipe.cxx b/slideshow/source/engine/transitions/checkerboardwipe.cxx
index 786eca0e5..8db1b023c 100644
--- a/slideshow/source/engine/transitions/checkerboardwipe.cxx
+++ b/slideshow/source/engine/transitions/checkerboardwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/checkerboardwipe.hxx b/slideshow/source/engine/transitions/checkerboardwipe.hxx
index b78d20885..df83391e2 100644
--- a/slideshow/source/engine/transitions/checkerboardwipe.hxx
+++ b/slideshow/source/engine/transitions/checkerboardwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,3 +56,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_CHECKERBOARDWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/clippingfunctor.cxx b/slideshow/source/engine/transitions/clippingfunctor.cxx
index 7bd522462..52748453f 100644
--- a/slideshow/source/engine/transitions/clippingfunctor.cxx
+++ b/slideshow/source/engine/transitions/clippingfunctor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,8 +50,6 @@ namespace slideshow
bool bModeIn ) :
mpParametricPoly( rPolygon ),
maStaticTransformation(),
- // AW: Not needed
- // maBackgroundRect( createUnitRect() ),
mbForwardParameterSweep( true ),
mbSubtractPolygon( false ),
mbScaleIsotrophically( rTransitionInfo.mbScaleIsotrophically ),
@@ -236,3 +235,5 @@ namespace slideshow
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/clippingfunctor.hxx b/slideshow/source/engine/transitions/clippingfunctor.hxx
index 9775148e4..e02af2d14 100644
--- a/slideshow/source/engine/transitions/clippingfunctor.hxx
+++ b/slideshow/source/engine/transitions/clippingfunctor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_CLIPPINGFUNCTOR_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/clockwipe.cxx b/slideshow/source/engine/transitions/clockwipe.cxx
index 0d4d23fb1..4f9773791 100644
--- a/slideshow/source/engine/transitions/clockwipe.cxx
+++ b/slideshow/source/engine/transitions/clockwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,3 +73,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/clockwipe.hxx b/slideshow/source/engine/transitions/clockwipe.hxx
index 845e54149..bfa45cdb9 100644
--- a/slideshow/source/engine/transitions/clockwipe.hxx
+++ b/slideshow/source/engine/transitions/clockwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,5 @@ public:
}
#endif /* INCLUDED_SLIDESHOW_CLOCKWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/combtransition.cxx b/slideshow/source/engine/transitions/combtransition.cxx
index 22bb77b7c..3640c0961 100644
--- a/slideshow/source/engine/transitions/combtransition.cxx
+++ b/slideshow/source/engine/transitions/combtransition.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -194,3 +195,5 @@ bool CombTransition::operator()( double t )
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/combtransition.hxx b/slideshow/source/engine/transitions/combtransition.hxx
index 2ef5309db..e3c594763 100644
--- a/slideshow/source/engine/transitions/combtransition.hxx
+++ b/slideshow/source/engine/transitions/combtransition.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,5 @@ private:
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_COMBTRANSITION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/doublediamondwipe.cxx b/slideshow/source/engine/transitions/doublediamondwipe.cxx
index 38f94f34e..30ea4cdaf 100644
--- a/slideshow/source/engine/transitions/doublediamondwipe.cxx
+++ b/slideshow/source/engine/transitions/doublediamondwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/doublediamondwipe.hxx b/slideshow/source/engine/transitions/doublediamondwipe.hxx
index bca71171c..16f1cddd1 100644
--- a/slideshow/source/engine/transitions/doublediamondwipe.hxx
+++ b/slideshow/source/engine/transitions/doublediamondwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_DOUBLEDIAMONDWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/ellipsewipe.cxx b/slideshow/source/engine/transitions/ellipsewipe.cxx
index 44b7675d3..3723889d4 100644
--- a/slideshow/source/engine/transitions/ellipsewipe.cxx
+++ b/slideshow/source/engine/transitions/ellipsewipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/ellipsewipe.hxx b/slideshow/source/engine/transitions/ellipsewipe.hxx
index d87adfb29..a4f9701d3 100644
--- a/slideshow/source/engine/transitions/ellipsewipe.hxx
+++ b/slideshow/source/engine/transitions/ellipsewipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46,3 +47,5 @@ public:
}
#endif /* INCLUDED_SLIDESHOW_ELLIPSEWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/fanwipe.cxx b/slideshow/source/engine/transitions/fanwipe.cxx
index 3f4539843..d15a37e90 100644
--- a/slideshow/source/engine/transitions/fanwipe.cxx
+++ b/slideshow/source/engine/transitions/fanwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,4 @@ namespace internal {
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/fanwipe.hxx b/slideshow/source/engine/transitions/fanwipe.hxx
index 3cc66b69b..955cfe9ef 100644
--- a/slideshow/source/engine/transitions/fanwipe.hxx
+++ b/slideshow/source/engine/transitions/fanwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_FANWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/figurewipe.cxx b/slideshow/source/engine/transitions/figurewipe.cxx
index 89f55c795..a98faa670 100644
--- a/slideshow/source/engine/transitions/figurewipe.cxx
+++ b/slideshow/source/engine/transitions/figurewipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -127,3 +128,5 @@ FigureWipe * FigureWipe::createStarWipe( sal_Int32 nPoints )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/figurewipe.hxx b/slideshow/source/engine/transitions/figurewipe.hxx
index 27c4dc4ea..366492b8e 100644
--- a/slideshow/source/engine/transitions/figurewipe.hxx
+++ b/slideshow/source/engine/transitions/figurewipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_FIGUREWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/fourboxwipe.cxx b/slideshow/source/engine/transitions/fourboxwipe.cxx
index b6eb591c0..015a0507e 100644
--- a/slideshow/source/engine/transitions/fourboxwipe.cxx
+++ b/slideshow/source/engine/transitions/fourboxwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/fourboxwipe.hxx b/slideshow/source/engine/transitions/fourboxwipe.hxx
index d6017b59f..2d0a066a5 100644
--- a/slideshow/source/engine/transitions/fourboxwipe.hxx
+++ b/slideshow/source/engine/transitions/fourboxwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_FOURBOXWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/iriswipe.cxx b/slideshow/source/engine/transitions/iriswipe.cxx
index ce166ae6e..d554e1f7e 100644
--- a/slideshow/source/engine/transitions/iriswipe.cxx
+++ b/slideshow/source/engine/transitions/iriswipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/iriswipe.hxx b/slideshow/source/engine/transitions/iriswipe.hxx
index b9cf1f75e..111c36607 100644
--- a/slideshow/source/engine/transitions/iriswipe.hxx
+++ b/slideshow/source/engine/transitions/iriswipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_IRISWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/makefile.mk b/slideshow/source/engine/transitions/makefile.mk
deleted file mode 100644
index a5fbd5677..000000000
--- a/slideshow/source/engine/transitions/makefile.mk
+++ /dev/null
@@ -1,73 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=slideshow
-TARGET=transitions
-ENABLE_EXCEPTIONS=TRUE
-PRJINC=..$/..
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-SLOFILES = \
- $(SLO)$/barwipepolypolygon.obj \
- $(SLO)$/boxwipe.obj \
- $(SLO)$/clippingfunctor.obj \
- $(SLO)$/combtransition.obj \
- $(SLO)$/fourboxwipe.obj \
- $(SLO)$/barndoorwipe.obj \
- $(SLO)$/iriswipe.obj \
- $(SLO)$/veewipe.obj \
- $(SLO)$/ellipsewipe.obj \
- $(SLO)$/checkerboardwipe.obj \
- $(SLO)$/randomwipe.obj \
- $(SLO)$/waterfallwipe.obj \
- $(SLO)$/clockwipe.obj \
- $(SLO)$/fanwipe.obj \
- $(SLO)$/pinwheelwipe.obj \
- $(SLO)$/snakewipe.obj \
- $(SLO)$/spiralwipe.obj \
- $(SLO)$/sweepwipe.obj \
- $(SLO)$/figurewipe.obj \
- $(SLO)$/doublediamondwipe.obj \
- $(SLO)$/zigzagwipe.obj \
- $(SLO)$/parametricpolypolygonfactory.obj \
- $(SLO)$/shapetransitionfactory.obj \
- $(SLO)$/slidetransitionfactory.obj \
- $(SLO)$/transitionfactorytab.obj \
- $(SLO)$/transitiontools.obj \
- $(SLO)$/slidechangebase.obj
-
-# ==========================================================================
-
-.INCLUDE : target.mk
diff --git a/slideshow/source/engine/transitions/parametricpolypolygon.hxx b/slideshow/source/engine/transitions/parametricpolypolygon.hxx
index 5603784a7..5f6091edc 100644
--- a/slideshow/source/engine/transitions/parametricpolypolygon.hxx
+++ b/slideshow/source/engine/transitions/parametricpolypolygon.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,3 +97,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_PARAMETRICPOLYPOLYGON_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/parametricpolypolygonfactory.cxx b/slideshow/source/engine/transitions/parametricpolypolygonfactory.cxx
index 143f041c7..8022a012c 100644
--- a/slideshow/source/engine/transitions/parametricpolypolygonfactory.cxx
+++ b/slideshow/source/engine/transitions/parametricpolypolygonfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -310,3 +311,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/parametricpolypolygonfactory.hxx b/slideshow/source/engine/transitions/parametricpolypolygonfactory.hxx
index 0d0e72b25..979c35bfb 100644
--- a/slideshow/source/engine/transitions/parametricpolypolygonfactory.hxx
+++ b/slideshow/source/engine/transitions/parametricpolypolygonfactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_PARAMETRICPOLYPOLYGONFACTORY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/pinwheelwipe.cxx b/slideshow/source/engine/transitions/pinwheelwipe.cxx
index a13a70f62..78d67b23a 100644
--- a/slideshow/source/engine/transitions/pinwheelwipe.cxx
+++ b/slideshow/source/engine/transitions/pinwheelwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -57,3 +58,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/pinwheelwipe.hxx b/slideshow/source/engine/transitions/pinwheelwipe.hxx
index 7dff75ff9..ec60813e5 100644
--- a/slideshow/source/engine/transitions/pinwheelwipe.hxx
+++ b/slideshow/source/engine/transitions/pinwheelwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_PINWHEELWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/randomwipe.cxx b/slideshow/source/engine/transitions/randomwipe.cxx
index 66fd5bf30..4fdf9fdba 100644
--- a/slideshow/source/engine/transitions/randomwipe.cxx
+++ b/slideshow/source/engine/transitions/randomwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -68,11 +69,12 @@ RandomWipe::RandomWipe( sal_Int32 nElements, bool randomBars )
m_rect.transform( aTransform );
// mix up:
- for (sal_Int32 nIndex=0; nIndex<nElements; ++nIndex)
+ for ( sal_Int32 pos1 = nElements ; pos1-- ; )
{
- const sal_Int32 nOtherIndex (getRandomOrdinal(nElements));
- OSL_ASSERT(nOtherIndex>=0 && nOtherIndex<nElements);
- ::std::swap(m_positions[nIndex], m_positions[nOtherIndex]);
+ const sal_Int32 pos2 = getRandomOrdinal(pos1+1);
+ const ::basegfx::B2DPoint point( m_positions[ pos1 ] );
+ m_positions[ pos1 ] = m_positions[ pos2 ];
+ m_positions[ pos2 ] = point;
}
}
@@ -91,3 +93,5 @@ RandomWipe::RandomWipe( sal_Int32 nElements, bool randomBars )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/randomwipe.hxx b/slideshow/source/engine/transitions/randomwipe.hxx
index 3eeca283e..473310e63 100644
--- a/slideshow/source/engine/transitions/randomwipe.hxx
+++ b/slideshow/source/engine/transitions/randomwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_RANDOMWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/shapetransitionfactory.cxx b/slideshow/source/engine/transitions/shapetransitionfactory.cxx
index ba94e877b..963b4b392 100644
--- a/slideshow/source/engine/transitions/shapetransitionfactory.cxx
+++ b/slideshow/source/engine/transitions/shapetransitionfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,7 +126,7 @@ ClippingAnimation::~ClippingAnimation()
}
catch (uno::Exception &)
{
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -251,8 +252,7 @@ AnimationActivitySharedPtr TransitionFactory::createShapeTransition(
{
default:
case TransitionInfo::TRANSITION_INVALID:
- OSL_ENSURE( false,
- "TransitionFactory::createShapeTransition(): Invalid transition type. "
+ OSL_FAIL( "TransitionFactory::createShapeTransition(): Invalid transition type. "
"Don't ask me for a 0 TransitionType, have no XTransitionFilter node instead!" );
return AnimationActivitySharedPtr();
@@ -395,8 +395,7 @@ AnimationActivitySharedPtr TransitionFactory::createShapeTransition(
"combination encountered",
xTransition->getTransition(),
xTransition->getSubtype() );
- OSL_ENSURE(
- false,
+ OSL_FAIL(
"TransitionFactory::createShapeTransition(): Unknown type/subtype "
"combination encountered" );
}
@@ -406,3 +405,5 @@ AnimationActivitySharedPtr TransitionFactory::createShapeTransition(
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/slidechangebase.cxx b/slideshow/source/engine/transitions/slidechangebase.cxx
index 533d2abf7..eeef5d9ef 100644
--- a/slideshow/source/engine/transitions/slidechangebase.cxx
+++ b/slideshow/source/engine/transitions/slidechangebase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -533,3 +534,5 @@ void SlideChangeBase::clearViewEntry( ViewEntry& rEntry )
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/slidechangebase.hxx b/slideshow/source/engine/transitions/slidechangebase.hxx
index df4cca317..bed8630e5 100644
--- a/slideshow/source/engine/transitions/slidechangebase.hxx
+++ b/slideshow/source/engine/transitions/slidechangebase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -206,3 +207,5 @@ private:
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_TRANSITIONS_SLIDECHANGEBASE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/slidetransitionfactory.cxx b/slideshow/source/engine/transitions/slidetransitionfactory.cxx
index 28636b2fe..abb9195e5 100644
--- a/slideshow/source/engine/transitions/slidetransitionfactory.cxx
+++ b/slideshow/source/engine/transitions/slidetransitionfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -473,6 +474,89 @@ void FadingSlideChange::performOut(
}
}
+class CutSlideChange : public SlideChangeBase
+{
+public:
+ /** Create a new SlideChanger, for the given leaving and
+ entering slides, which applies a cut effect.
+ */
+ CutSlideChange(
+ boost::optional<SlideSharedPtr> const & leavingSlide,
+ const SlideSharedPtr& pEnteringSlide,
+ const RGBColor& rFadeColor,
+ const SoundPlayerSharedPtr& pSoundPlayer,
+ const UnoViewContainer& rViewContainer,
+ ScreenUpdater& rScreenUpdater,
+ EventMultiplexer& rEventMultiplexer )
+ : SlideChangeBase( leavingSlide,
+ pEnteringSlide,
+ pSoundPlayer,
+ rViewContainer,
+ rScreenUpdater,
+ rEventMultiplexer ),
+ maFadeColor( rFadeColor ),
+ mbFirstTurn( true )
+ {}
+
+ virtual void performIn(
+ const ::cppcanvas::CustomSpriteSharedPtr& rSprite,
+ const ViewEntry& rViewEntry,
+ const ::cppcanvas::CanvasSharedPtr& rDestinationCanvas,
+ double t );
+
+ virtual void performOut(
+ const ::cppcanvas::CustomSpriteSharedPtr& rSprite,
+ const ViewEntry& rViewEntry,
+ const ::cppcanvas::CanvasSharedPtr& rDestinationCanvas,
+ double t );
+
+private:
+ RGBColor maFadeColor;
+ bool mbFirstTurn;
+};
+
+void CutSlideChange::performIn(
+ const ::cppcanvas::CustomSpriteSharedPtr& rSprite,
+ const ViewEntry& /*rViewEntry*/,
+ const ::cppcanvas::CanvasSharedPtr& /*rDestinationCanvas*/,
+ double t )
+{
+ ENSURE_OR_THROW(
+ rSprite,
+ "CutSlideChange::performIn(): Invalid sprite" );
+
+ // After 2/3rd of the active time, display new slide
+ rSprite->setAlpha( t > 2/3.0 ? 1.0 : 0.0 );
+}
+
+void CutSlideChange::performOut(
+ const ::cppcanvas::CustomSpriteSharedPtr& rSprite,
+ const ViewEntry& rViewEntry,
+ const ::cppcanvas::CanvasSharedPtr& rDestinationCanvas,
+ double t )
+{
+ ENSURE_OR_THROW(
+ rSprite,
+ "CutSlideChange::performOut(): Invalid sprite" );
+ ENSURE_OR_THROW(
+ rDestinationCanvas,
+ "FadingSlideChange::performOut(): Invalid dest canvas" );
+
+ if( mbFirstTurn )
+ {
+ mbFirstTurn = false;
+
+ // clear page to given fade color. 'Leaving' slide is
+ // painted atop of that
+ fillPage( rDestinationCanvas,
+ getEnteringSlideSizePixel( rViewEntry.mpView ),
+ maFadeColor );
+ }
+
+ // Until 1/3rd of the active time, display old slide.
+ rSprite->setAlpha( t > 1/3.0 ? 0.0 : 1.0 );
+}
+
class MovingSlideChange : public SlideChangeBase
{
/// Direction vector for leaving slide,
@@ -645,8 +729,7 @@ NumberAnimationSharedPtr createPushWipeTransition(
switch( nTransitionSubType )
{
default:
- OSL_ENSURE(
- false,
+ OSL_FAIL(
"createPushWipeTransition(): Unexpected transition "
"subtype for animations::TransitionType::PUSHWIPE "
"transitions" );
@@ -737,8 +820,7 @@ NumberAnimationSharedPtr createSlideWipeTransition(
switch( nTransitionSubType )
{
default:
- OSL_ENSURE(
- false,
+ OSL_FAIL(
"createSlideWipeTransition(): Unexpected transition "
"subtype for animations::TransitionType::SLIDEWIPE "
"transitions" );
@@ -938,8 +1020,7 @@ NumberAnimationSharedPtr TransitionFactory::createSlideTransition(
switch( nTransitionType )
{
default:
- OSL_ENSURE(
- false,
+ OSL_FAIL(
"TransitionFactory::createSlideTransition(): "
"Unexpected transition type for "
"TRANSITION_SPECIAL transitions" );
@@ -1007,6 +1088,7 @@ NumberAnimationSharedPtr TransitionFactory::createSlideTransition(
pSoundPlayer );
}
+ case animations::TransitionType::BARWIPE:
case animations::TransitionType::FADE:
{
// black page:
@@ -1038,16 +1120,27 @@ NumberAnimationSharedPtr TransitionFactory::createSlideTransition(
"SlideTransitionFactory::createSlideTransition(): Unknown FADE subtype" );
}
- return NumberAnimationSharedPtr(
- new FadingSlideChange(
- leavingSlide,
- pEnteringSlide,
- comphelper::make_optional(
- rTransitionFadeColor),
- pSoundPlayer,
- rViewContainer,
- rScreenUpdater,
- rEventMultiplexer ));
+ if( nTransitionType == animations::TransitionType::FADE )
+ return NumberAnimationSharedPtr(
+ new FadingSlideChange(
+ leavingSlide,
+ pEnteringSlide,
+ comphelper::make_optional(
+ rTransitionFadeColor),
+ pSoundPlayer,
+ rViewContainer,
+ rScreenUpdater,
+ rEventMultiplexer ));
+ else
+ return NumberAnimationSharedPtr(
+ new CutSlideChange(
+ leavingSlide,
+ pEnteringSlide,
+ rTransitionFadeColor,
+ pSoundPlayer,
+ rViewContainer,
+ rScreenUpdater,
+ rEventMultiplexer ));
}
}
}
@@ -1062,8 +1155,7 @@ NumberAnimationSharedPtr TransitionFactory::createSlideTransition(
"Unknown type/subtype (%d/%d) combination encountered",
nTransitionType,
nTransitionSubType );
- OSL_ENSURE(
- false,
+ OSL_FAIL(
"TransitionFactory::createSlideTransition(): "
"Unknown type/subtype combination encountered" );
@@ -1072,3 +1164,5 @@ NumberAnimationSharedPtr TransitionFactory::createSlideTransition(
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/snakewipe.cxx b/slideshow/source/engine/transitions/snakewipe.cxx
index 2d7b1a5a7..86572f7f9 100644
--- a/slideshow/source/engine/transitions/snakewipe.cxx
+++ b/slideshow/source/engine/transitions/snakewipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -242,3 +243,5 @@ SnakeWipe::SnakeWipe( sal_Int32 nElements, bool diagonal, bool flipOnYAxis )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/snakewipe.hxx b/slideshow/source/engine/transitions/snakewipe.hxx
index 2a3ae2ebe..3b14944d7 100644
--- a/slideshow/source/engine/transitions/snakewipe.hxx
+++ b/slideshow/source/engine/transitions/snakewipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_SNAKEWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/spiralwipe.cxx b/slideshow/source/engine/transitions/spiralwipe.cxx
index aaa1f5c28..2ddee7226 100644
--- a/slideshow/source/engine/transitions/spiralwipe.cxx
+++ b/slideshow/source/engine/transitions/spiralwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -129,3 +130,5 @@ SpiralWipe::SpiralWipe( sal_Int32 nElements, bool flipOnYAxis )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/spiralwipe.hxx b/slideshow/source/engine/transitions/spiralwipe.hxx
index 716ebbe93..4e11e2df9 100644
--- a/slideshow/source/engine/transitions/spiralwipe.hxx
+++ b/slideshow/source/engine/transitions/spiralwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_SPIRALWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/sweepwipe.cxx b/slideshow/source/engine/transitions/sweepwipe.cxx
index 04779af00..ae743ec23 100644
--- a/slideshow/source/engine/transitions/sweepwipe.cxx
+++ b/slideshow/source/engine/transitions/sweepwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,3 +83,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/sweepwipe.hxx b/slideshow/source/engine/transitions/sweepwipe.hxx
index 2ab1f7c69..c1e9fc332 100644
--- a/slideshow/source/engine/transitions/sweepwipe.hxx
+++ b/slideshow/source/engine/transitions/sweepwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_SWEEPWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/transitionfactorytab.cxx b/slideshow/source/engine/transitions/transitionfactorytab.cxx
index 5a467fd23..052c0ab04 100644
--- a/slideshow/source/engine/transitions/transitionfactorytab.cxx
+++ b/slideshow/source/engine/transitions/transitionfactorytab.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -2015,6 +2016,20 @@ static const TransitionInfo lcl_transitionInfo[] =
true, // 'out' by parameter sweep inversion
false // scale isotrophically to target size
},
+ // this is the cut through black fade (does not fade, but does a
+ // hard cut)
+ {
+ animations::TransitionType::BARWIPE,
+ animations::TransitionSubType::FADEOVERCOLOR,
+ TransitionInfo::TRANSITION_SPECIAL,
+ // TODO(F2): Setup parameters
+ 0.0, // no rotation
+ 1.0, // no scaling
+ 1.0, // no scaling
+ TransitionInfo::REVERSEMETHOD_IGNORE,
+ true, // 'out' by parameter sweep inversion
+ false // scale isotrophically to target size
+ },
{
// mapped to RandomWipe:
@@ -2130,3 +2145,5 @@ const TransitionInfo* TransitionFactory::getRandomTransitionInfo()
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/transitiontools.cxx b/slideshow/source/engine/transitions/transitiontools.cxx
index bc174d3a5..c2cc7c50b 100644
--- a/slideshow/source/engine/transitions/transitiontools.cxx
+++ b/slideshow/source/engine/transitions/transitiontools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/transitiontools.hxx b/slideshow/source/engine/transitions/transitiontools.hxx
index b5e61cb03..c8c95ad7e 100644
--- a/slideshow/source/engine/transitions/transitiontools.hxx
+++ b/slideshow/source/engine/transitions/transitiontools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,3 +54,5 @@ namespace internal {
}
#endif /* INCLUDED_SLIDESHOW_TRANSITIONTOOLS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/veewipe.cxx b/slideshow/source/engine/transitions/veewipe.cxx
index 19702b37f..47bc90101 100644
--- a/slideshow/source/engine/transitions/veewipe.cxx
+++ b/slideshow/source/engine/transitions/veewipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ namespace internal {
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/veewipe.hxx b/slideshow/source/engine/transitions/veewipe.hxx
index ac2e8d190..b25816f6b 100644
--- a/slideshow/source/engine/transitions/veewipe.hxx
+++ b/slideshow/source/engine/transitions/veewipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,5 @@ public:
}
#endif /* INCLUDED_SLIDESHOW_VEEWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/waterfallwipe.cxx b/slideshow/source/engine/transitions/waterfallwipe.cxx
index 7fca4ae58..7ea4539c7 100644
--- a/slideshow/source/engine/transitions/waterfallwipe.cxx
+++ b/slideshow/source/engine/transitions/waterfallwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ WaterfallWipe::WaterfallWipe( sal_Int32 nElements, bool flipOnYAxis )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/waterfallwipe.hxx b/slideshow/source/engine/transitions/waterfallwipe.hxx
index e039a9985..58cf278e2 100644
--- a/slideshow/source/engine/transitions/waterfallwipe.hxx
+++ b/slideshow/source/engine/transitions/waterfallwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,5 @@ private:
}
#endif /* INCLUDED_SLIDESHOW_WATERFALLWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/zigzagwipe.cxx b/slideshow/source/engine/transitions/zigzagwipe.cxx
index 9eb18795c..a0c57db35 100644
--- a/slideshow/source/engine/transitions/zigzagwipe.cxx
+++ b/slideshow/source/engine/transitions/zigzagwipe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,5 @@ ZigZagWipe::ZigZagWipe( sal_Int32 nZigs ) : m_zigEdge( 1.0 / nZigs )
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/transitions/zigzagwipe.hxx b/slideshow/source/engine/transitions/zigzagwipe.hxx
index 722749053..812689011 100644
--- a/slideshow/source/engine/transitions/zigzagwipe.hxx
+++ b/slideshow/source/engine/transitions/zigzagwipe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,5 @@ public:
}
#endif /* INCLUDED_SLIDESHOW_ZIGZAGWIPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/unoviewcontainer.cxx b/slideshow/source/engine/unoviewcontainer.cxx
index 034b78485..a5db2abd4 100644
--- a/slideshow/source/engine/unoviewcontainer.cxx
+++ b/slideshow/source/engine/unoviewcontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -147,3 +148,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/usereventqueue.cxx b/slideshow/source/engine/usereventqueue.cxx
index d62a831c0..1e7aa801d 100644
--- a/slideshow/source/engine/usereventqueue.cxx
+++ b/slideshow/source/engine/usereventqueue.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -686,7 +687,7 @@ UserEventQueue::~UserEventQueue()
clear();
}
catch (uno::Exception &) {
- OSL_ENSURE( false, rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString(
cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
@@ -1005,3 +1006,4 @@ void UserEventQueue::callSkipEffectEventHandler (void)
} // namespace internal
} // namespace presentation
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/waitsymbol.cxx b/slideshow/source/engine/waitsymbol.cxx
index 78c913d57..f7bb88bd0 100644
--- a/slideshow/source/engine/waitsymbol.cxx
+++ b/slideshow/source/engine/waitsymbol.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,6 +43,7 @@
#include "waitsymbol.hxx"
#include "eventmultiplexer.hxx"
+#include <o3tl/compat_functional.hxx>
#include <algorithm>
@@ -146,8 +148,7 @@ void WaitSymbol::viewAdded( const UnoViewSharedPtr& rView )
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -164,7 +165,7 @@ void WaitSymbol::viewRemoved( const UnoViewSharedPtr& rView )
std::equal_to<UnoViewSharedPtr>(),
rView,
// select view:
- boost::bind( std::select1st<ViewsVecT::value_type>(), _1 ) ) ),
+ boost::bind( o3tl::select1st<ViewsVecT::value_type>(), _1 ) ) ),
maViews.end() );
}
@@ -179,7 +180,7 @@ void WaitSymbol::viewChanged( const UnoViewSharedPtr& rView )
std::equal_to<UnoViewSharedPtr>(),
rView,
// select view:
- boost::bind( std::select1st<ViewsVecT::value_type>(), _1 ))));
+ boost::bind( o3tl::select1st<ViewsVecT::value_type>(), _1 ))));
OSL_ASSERT( aModifiedEntry != maViews.end() );
if( aModifiedEntry == maViews.end() )
@@ -206,3 +207,5 @@ void WaitSymbol::viewsChanged()
} // namespace internal
} // namespace presentation
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/waitsymbol.hxx b/slideshow/source/engine/waitsymbol.hxx
index 06c11ace0..f23cb2864 100644
--- a/slideshow/source/engine/waitsymbol.hxx
+++ b/slideshow/source/engine/waitsymbol.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -106,3 +107,5 @@ private:
} // namespace presentation
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/engine/wakeupevent.cxx b/slideshow/source/engine/wakeupevent.cxx
index 597c9d182..a0ce86ac4 100644
--- a/slideshow/source/engine/wakeupevent.cxx
+++ b/slideshow/source/engine/wakeupevent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,7 +44,7 @@ namespace slideshow
boost::shared_ptr<canvas::tools::ElapsedTime> const & pTimeBase,
ActivitiesQueue& rActivityQueue ) :
#if OSL_DEBUG_LEVEL > 1
- Event(::rtl::OUString::createFromAscii("WakeupEvent")),
+ Event(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("WakeupEvent"))),
#endif
maTimer(pTimeBase),
mnNextTime(0.0),
@@ -97,3 +98,5 @@ namespace slideshow
}
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/activitiesfactory.hxx b/slideshow/source/inc/activitiesfactory.hxx
index c123928e3..c32e57720 100644
--- a/slideshow/source/inc/activitiesfactory.hxx
+++ b/slideshow/source/inc/activitiesfactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -332,3 +333,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_ACTIVITIESFACTORY_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/activitiesqueue.hxx b/slideshow/source/inc/activitiesqueue.hxx
index 918216634..fe434e5c2 100644
--- a/slideshow/source/inc/activitiesqueue.hxx
+++ b/slideshow/source/inc/activitiesqueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -128,3 +129,5 @@ namespace slideshow
}
}
#endif /* INCLUDED_SLIDESHOW_ACTIVITIESQUEUE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/activity.hxx b/slideshow/source/inc/activity.hxx
index d2b4fcdc2..07df027a4 100644
--- a/slideshow/source/inc/activity.hxx
+++ b/slideshow/source/inc/activity.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ACTIVITY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animatableshape.hxx b/slideshow/source/inc/animatableshape.hxx
index 0e0d2c851..1c84d289a 100644
--- a/slideshow/source/inc/animatableshape.hxx
+++ b/slideshow/source/inc/animatableshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -86,3 +87,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATABLESHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animatedsprite.hxx b/slideshow/source/inc/animatedsprite.hxx
index 3ac5bc4cf..aae92dd5c 100644
--- a/slideshow/source/inc/animatedsprite.hxx
+++ b/slideshow/source/inc/animatedsprite.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -184,3 +185,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATEDSPRITE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animation.hxx b/slideshow/source/inc/animation.hxx
index 91d137bf0..fe5e20112 100644
--- a/slideshow/source/inc/animation.hxx
+++ b/slideshow/source/inc/animation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,3 +96,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationactivity.hxx b/slideshow/source/inc/animationactivity.hxx
index d71294710..f364e29f5 100644
--- a/slideshow/source/inc/animationactivity.hxx
+++ b/slideshow/source/inc/animationactivity.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATIONACTIVITY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationeventhandler.hxx b/slideshow/source/inc/animationeventhandler.hxx
index 44a7e137e..af11d0800 100644
--- a/slideshow/source/inc/animationeventhandler.hxx
+++ b/slideshow/source/inc/animationeventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATIONEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationfactory.hxx b/slideshow/source/inc/animationfactory.hxx
index a8ca2cfe7..16bdb3382 100644
--- a/slideshow/source/inc/animationfactory.hxx
+++ b/slideshow/source/inc/animationfactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -155,3 +156,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATIONFACTORY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationfunction.hxx b/slideshow/source/inc/animationfunction.hxx
index 683410f8e..2e94bc193 100644
--- a/slideshow/source/inc/animationfunction.hxx
+++ b/slideshow/source/inc/animationfunction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATIONFUNCTION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationnode.hxx b/slideshow/source/inc/animationnode.hxx
index 582ad2c0f..3f341fcb5 100644
--- a/slideshow/source/inc/animationnode.hxx
+++ b/slideshow/source/inc/animationnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -161,3 +162,4 @@ typedef ::boost::shared_ptr< AnimationNode > AnimationNodeSharedPtr;
#endif /* INCLUDED_SLIDESHOW_ANIMATIONNODE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/animationnodefactory.hxx b/slideshow/source/inc/animationnodefactory.hxx
index 83468f6fb..bc0c64314 100644
--- a/slideshow/source/inc/animationnodefactory.hxx
+++ b/slideshow/source/inc/animationnodefactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -76,3 +77,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ANIMATIONNODEFACTORY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/attributableshape.hxx b/slideshow/source/inc/attributableshape.hxx
index 762815927..1efba90b7 100644
--- a/slideshow/source/inc/attributableshape.hxx
+++ b/slideshow/source/inc/attributableshape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -226,3 +227,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ATTRIBUTABLESHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/attributemap.hxx b/slideshow/source/inc/attributemap.hxx
index b3a956c3f..24db268a3 100644
--- a/slideshow/source/inc/attributemap.hxx
+++ b/slideshow/source/inc/attributemap.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ATTRIBUTEMAP_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/boolanimation.hxx b/slideshow/source/inc/boolanimation.hxx
index 01273e822..c7d951ee1 100644
--- a/slideshow/source/inc/boolanimation.hxx
+++ b/slideshow/source/inc/boolanimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_BOOLANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/coloranimation.hxx b/slideshow/source/inc/coloranimation.hxx
index adbfdef16..d7c149dc2 100644
--- a/slideshow/source/inc/coloranimation.hxx
+++ b/slideshow/source/inc/coloranimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_COLORANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/cursormanager.hxx b/slideshow/source/inc/cursormanager.hxx
index 5fa86e05e..4b06e963f 100644
--- a/slideshow/source/inc/cursormanager.hxx
+++ b/slideshow/source/inc/cursormanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_CURSORMANAGER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/debug.hxx b/slideshow/source/inc/debug.hxx
index d9b3a91d0..4bf7d43a4 100644
--- a/slideshow/source/inc/debug.hxx
+++ b/slideshow/source/inc/debug.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ void SAL_CALL DebugTraceMessage (const sal_Char* sFormat, ...);
#endif // OSL_DEBUG_LEVEL > 1
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/delayevent.hxx b/slideshow/source/inc/delayevent.hxx
index ed934bfcd..c4db6e66b 100644
--- a/slideshow/source/inc/delayevent.hxx
+++ b/slideshow/source/inc/delayevent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -155,3 +156,5 @@ inline EventSharedPtr makeDelay_(
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_DELAYEVENT_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/disposable.hxx b/slideshow/source/inc/disposable.hxx
index e9aed9bf8..5e3c4f4d7 100644
--- a/slideshow/source/inc/disposable.hxx
+++ b/slideshow/source/inc/disposable.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DISPOSABLE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/doctreenode.hxx b/slideshow/source/inc/doctreenode.hxx
index b1cc9f7cc..c8ad37f9f 100644
--- a/slideshow/source/inc/doctreenode.hxx
+++ b/slideshow/source/inc/doctreenode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -139,3 +140,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DOCTREENODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/doctreenodesupplier.hxx b/slideshow/source/inc/doctreenodesupplier.hxx
index 9ef6df8e2..0dd012550 100644
--- a/slideshow/source/inc/doctreenodesupplier.hxx
+++ b/slideshow/source/inc/doctreenodesupplier.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -149,3 +150,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_DOCTREENODESUPPLIER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/enumanimation.hxx b/slideshow/source/inc/enumanimation.hxx
index 137a7f2f1..56dda3168 100644
--- a/slideshow/source/inc/enumanimation.hxx
+++ b/slideshow/source/inc/enumanimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_ENUMANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/event.hxx b/slideshow/source/inc/event.hxx
index dfc8ca196..2c0c338b2 100644
--- a/slideshow/source/inc/event.hxx
+++ b/slideshow/source/inc/event.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90,3 +91,5 @@ typedef ::std::vector< EventSharedPtr > VectorOfEvents;
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_EVENT_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/eventhandler.hxx b/slideshow/source/inc/eventhandler.hxx
index 5620310b2..87a30a943 100644
--- a/slideshow/source/inc/eventhandler.hxx
+++ b/slideshow/source/inc/eventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,3 +66,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_EVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/eventmultiplexer.hxx b/slideshow/source/inc/eventmultiplexer.hxx
index a1c921048..aae1c4024 100644
--- a/slideshow/source/inc/eventmultiplexer.hxx
+++ b/slideshow/source/inc/eventmultiplexer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,7 +61,7 @@ struct EventMultiplexerImpl;
are handled as well. Note that registered events which
have a non-zero timeout (i.e. events that return non-zero
from getActivationTime()) will not be fired immediately
- after the user action occured, but only after the given
+ after the user action occurred, but only after the given
timeout. Which is actually a feature.
*/
class EventMultiplexer : private ::boost::noncopyable
@@ -659,3 +660,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_EVENTMULTIPLEXER_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/eventqueue.hxx b/slideshow/source/inc/eventqueue.hxx
index bf1954eaf..19f3358f1 100644
--- a/slideshow/source/inc/eventqueue.hxx
+++ b/slideshow/source/inc/eventqueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,3 +155,5 @@ namespace slideshow
}
}
#endif /* INCLUDED_SLIDESHOW_EVENTQUEUE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/expressionnode.hxx b/slideshow/source/inc/expressionnode.hxx
index 1604dcc54..47cb6abf0 100644
--- a/slideshow/source/inc/expressionnode.hxx
+++ b/slideshow/source/inc/expressionnode.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_EXPRESSIONNODE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/expressionnodefactory.hxx b/slideshow/source/inc/expressionnodefactory.hxx
index 1beae509d..b0ea5e9a2 100644
--- a/slideshow/source/inc/expressionnodefactory.hxx
+++ b/slideshow/source/inc/expressionnodefactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_EXPRESSIONNODEFACTORY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/externalmediashape.hxx b/slideshow/source/inc/externalmediashape.hxx
index c848ee3dd..fa1ccc392 100644
--- a/slideshow/source/inc/externalmediashape.hxx
+++ b/slideshow/source/inc/externalmediashape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,3 +90,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_EXTERNALMEDIASHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/framerate.hxx b/slideshow/source/inc/framerate.hxx
index 8899db865..4ffe891b3 100644
--- a/slideshow/source/inc/framerate.hxx
+++ b/slideshow/source/inc/framerate.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ public:
} } // end of namespace slideshow::internal
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/hslcolor.hxx b/slideshow/source/inc/hslcolor.hxx
index 797f5624f..afd21c74d 100644
--- a/slideshow/source/inc/hslcolor.hxx
+++ b/slideshow/source/inc/hslcolor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,22 +68,6 @@ namespace slideshow
*/
double getLuminance() const;
- /** Get the RGB red value.
- */
- double getRed() const;
-
- /** Get the RGB green value.
- */
- double getGreen() const;
-
- /** Get the RGB blue value.
- */
- double getBlue() const;
-
- /** Create an RGB color object.
- */
- RGBColor getRGBColor() const;
-
struct HSLTriple
{
HSLTriple();
@@ -121,3 +106,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_HSLCOLOR_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/hslcoloranimation.hxx b/slideshow/source/inc/hslcoloranimation.hxx
index aa05c179c..b86e801ea 100644
--- a/slideshow/source/inc/hslcoloranimation.hxx
+++ b/slideshow/source/inc/hslcoloranimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_HSLCOLORANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/hyperlinkarea.hxx b/slideshow/source/inc/hyperlinkarea.hxx
index 3255911e0..07be394a5 100644
--- a/slideshow/source/inc/hyperlinkarea.hxx
+++ b/slideshow/source/inc/hyperlinkarea.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_HYPERLINKAREA_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/hyperlinkhandler.hxx b/slideshow/source/inc/hyperlinkhandler.hxx
index 22a00ac09..25b0d5bc4 100644
--- a/slideshow/source/inc/hyperlinkhandler.hxx
+++ b/slideshow/source/inc/hyperlinkhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_HYPERLINKHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/interruptabledelayevent.hxx b/slideshow/source/inc/interruptabledelayevent.hxx
index 8e824faa2..cd4205564 100644
--- a/slideshow/source/inc/interruptabledelayevent.hxx
+++ b/slideshow/source/inc/interruptabledelayevent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,7 +48,7 @@ namespace slideshow
DelayFacade( const EventSharedPtr& rEvent,
double nTimeout ) :
#if OSL_DEBUG_LEVEL > 1
- Event(::rtl::OUString::createFromAscii("DelayFacade")),
+ Event(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DelayFacade"))),
#endif
mpEvent( rEvent ),
mnTimeout( nTimeout )
@@ -148,3 +149,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_INTERRUPTABLEDELAYEVENT_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/intrinsicanimationeventhandler.hxx b/slideshow/source/inc/intrinsicanimationeventhandler.hxx
index 6ef140953..40935d910 100644
--- a/slideshow/source/inc/intrinsicanimationeventhandler.hxx
+++ b/slideshow/source/inc/intrinsicanimationeventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_INTRINSICANIMATIONEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/listenercontainer.hxx b/slideshow/source/inc/listenercontainer.hxx
index e9f66670e..533f04ff6 100644
--- a/slideshow/source/inc/listenercontainer.hxx
+++ b/slideshow/source/inc/listenercontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -313,3 +314,4 @@ class ThreadUnsafeListenerContainer : public ListenerContainerBase<ListenerT,
#endif /* INCLUDED_SLIDESHOW_LISTENERCONTAINER_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/listenercontainerimpl.hxx b/slideshow/source/inc/listenercontainerimpl.hxx
index 721d20df8..cecffec7b 100644
--- a/slideshow/source/inc/listenercontainerimpl.hxx
+++ b/slideshow/source/inc/listenercontainerimpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -223,3 +224,4 @@ struct ListenerOperations< boost::weak_ptr<ListenerTargetT> >
#endif /* INCLUDED_SLIDESHOW_LISTENERCONTAINERIMPL_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/mouseeventhandler.hxx b/slideshow/source/inc/mouseeventhandler.hxx
index 195c7de2a..f601490cd 100644
--- a/slideshow/source/inc/mouseeventhandler.hxx
+++ b/slideshow/source/inc/mouseeventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -151,3 +152,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_MOUSEEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/numberanimation.hxx b/slideshow/source/inc/numberanimation.hxx
index faf5aae64..b841ef1c8 100644
--- a/slideshow/source/inc/numberanimation.hxx
+++ b/slideshow/source/inc/numberanimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_NUMBERANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/pairanimation.hxx b/slideshow/source/inc/pairanimation.hxx
index 6c8357b24..c913a338d 100644
--- a/slideshow/source/inc/pairanimation.hxx
+++ b/slideshow/source/inc/pairanimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -76,3 +77,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_PAIRANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/pauseeventhandler.hxx b/slideshow/source/inc/pauseeventhandler.hxx
index 9e78b38de..144f9c45e 100644
--- a/slideshow/source/inc/pauseeventhandler.hxx
+++ b/slideshow/source/inc/pauseeventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66,3 +67,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_PAUSEEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/rgbcolor.hxx b/slideshow/source/inc/rgbcolor.hxx
index db096e453..b30615180 100644
--- a/slideshow/source/inc/rgbcolor.hxx
+++ b/slideshow/source/inc/rgbcolor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,24 +50,6 @@ namespace slideshow
RGBColor( double nRed, double nGreen, double nBlue );
explicit RGBColor( const HSLColor& rColor );
- /** Hue of the color.
-
- @return hue, is in the range [0,360]
- */
- double getHue() const;
-
- /** Saturation of the color.
-
- @return saturation, is in the range [0,1]
- */
- double getSaturation() const;
-
- /** Luminance of the color.
-
- @return luminance, is in the range [0,1]
- */
- double getLuminance() const;
-
/** Get the RGB red value.
*/
double getRed() const;
@@ -79,17 +62,10 @@ namespace slideshow
*/
double getBlue() const;
- /** Create an HSL color object.
- */
- HSLColor getHSLColor() const;
-
/** Create an integer sRGBA color.
*/
::cppcanvas::Color::IntSRGBA getIntegerColor() const;
- RGBColor(const RGBColor& rLHS);
- RGBColor& operator=( const RGBColor& rLHS);
-
struct RGBTriple
{
RGBTriple();
@@ -123,3 +99,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_RGBCOLOR_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/screenupdater.hxx b/slideshow/source/inc/screenupdater.hxx
index 96a8ca9b5..d2ce2a4f0 100644
--- a/slideshow/source/inc/screenupdater.hxx
+++ b/slideshow/source/inc/screenupdater.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -137,3 +138,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SCREENUPDATER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shape.hxx b/slideshow/source/inc/shape.hxx
index 3bfec3f67..74ea15921 100644
--- a/slideshow/source/inc/shape.hxx
+++ b/slideshow/source/inc/shape.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -271,3 +272,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapeattributelayer.hxx b/slideshow/source/inc/shapeattributelayer.hxx
index 513b77266..73346430a 100644
--- a/slideshow/source/inc/shapeattributelayer.hxx
+++ b/slideshow/source/inc/shapeattributelayer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -554,3 +555,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPEATTRIBUTELAYER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapeattributelayerholder.hxx b/slideshow/source/inc/shapeattributelayerholder.hxx
index 43c2a2f49..989e306bd 100644
--- a/slideshow/source/inc/shapeattributelayerholder.hxx
+++ b/slideshow/source/inc/shapeattributelayerholder.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,3 +109,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPEATTRIBUTELAYERHOLDER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapecursoreventhandler.hxx b/slideshow/source/inc/shapecursoreventhandler.hxx
index be421f701..298ce67e1 100644
--- a/slideshow/source/inc/shapecursoreventhandler.hxx
+++ b/slideshow/source/inc/shapecursoreventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,3 +66,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPECURSOREVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapeimporter.hxx b/slideshow/source/inc/shapeimporter.hxx
index 9d6528b79..384f35b69 100644
--- a/slideshow/source/inc/shapeimporter.hxx
+++ b/slideshow/source/inc/shapeimporter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,6 +103,8 @@ public:
*/
bool isImportDone() const;
PolyPolygonVector getPolygons();
+
+ double getImportedShapesCount() { return mnAscendingPrio; }
private:
bool isSkip( ::com::sun::star::uno::Reference<
::com::sun::star::beans::XPropertySet> const& xPropSet,
@@ -153,3 +156,5 @@ private:
} // namespace presentation
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapelistenereventhandler.hxx b/slideshow/source/inc/shapelistenereventhandler.hxx
index abedde580..df8b63f80 100644
--- a/slideshow/source/inc/shapelistenereventhandler.hxx
+++ b/slideshow/source/inc/shapelistenereventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPELISTENEREVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapemanager.hxx b/slideshow/source/inc/shapemanager.hxx
index c067fb20d..b67904600 100644
--- a/slideshow/source/inc/shapemanager.hxx
+++ b/slideshow/source/inc/shapemanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -123,3 +124,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPEMANAGER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapemaps.hxx b/slideshow/source/inc/shapemaps.hxx
index 81e15efa3..a6987a46c 100644
--- a/slideshow/source/inc/shapemaps.hxx
+++ b/slideshow/source/inc/shapemaps.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,3 +60,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPEMAPS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/shapesubset.hxx b/slideshow/source/inc/shapesubset.hxx
index 7100bd015..2ae2196c1 100644
--- a/slideshow/source/inc/shapesubset.hxx
+++ b/slideshow/source/inc/shapesubset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -148,3 +149,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SHAPESUBSET_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/slide.hxx b/slideshow/source/inc/slide.hxx
index 5288f6ee6..39f991f67 100644
--- a/slideshow/source/inc/slide.hxx
+++ b/slideshow/source/inc/slide.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -220,3 +221,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SLIDE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/slidebitmap.hxx b/slideshow/source/inc/slidebitmap.hxx
index 2f2229f9d..5f7f5e4d6 100644
--- a/slideshow/source/inc/slidebitmap.hxx
+++ b/slideshow/source/inc/slidebitmap.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SLIDEBITMAP_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/slideshowcontext.hxx b/slideshow/source/inc/slideshowcontext.hxx
index dd24d52c8..72681993d 100644
--- a/slideshow/source/inc/slideshowcontext.hxx
+++ b/slideshow/source/inc/slideshowcontext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116,3 +117,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SLIDESHOWCONTEXT_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/slideshowexceptions.hxx b/slideshow/source/inc/slideshowexceptions.hxx
index 84752224c..f0e1656f3 100644
--- a/slideshow/source/inc/slideshowexceptions.hxx
+++ b/slideshow/source/inc/slideshowexceptions.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SLIDESHOWEXCEPTIONS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/slideview.hxx b/slideshow/source/inc/slideview.hxx
index 758088baa..f791f15a1 100644
--- a/slideshow/source/inc/slideview.hxx
+++ b/slideshow/source/inc/slideview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,3 +61,4 @@ namespace slideshow
#endif /* INCLUDED_SLIDESHOW_SLIDEVIEW_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/smilfunctionparser.hxx b/slideshow/source/inc/smilfunctionparser.hxx
index dd60fb593..c99550ec6 100644
--- a/slideshow/source/inc/smilfunctionparser.hxx
+++ b/slideshow/source/inc/smilfunctionparser.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -165,3 +166,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SMILFUNCTIONPARSER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/soundplayer.hxx b/slideshow/source/inc/soundplayer.hxx
index edc10d98b..edebe5f97 100644
--- a/slideshow/source/inc/soundplayer.hxx
+++ b/slideshow/source/inc/soundplayer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116,3 +117,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SOUNDPLAYER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/state.hxx b/slideshow/source/inc/state.hxx
index e2d84e8ed..d48f7a492 100644
--- a/slideshow/source/inc/state.hxx
+++ b/slideshow/source/inc/state.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_STATE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/stringanimation.hxx b/slideshow/source/inc/stringanimation.hxx
index bea6a0c5a..4b3457deb 100644
--- a/slideshow/source/inc/stringanimation.hxx
+++ b/slideshow/source/inc/stringanimation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,3 +76,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_STRINGANIMATION_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/subsettableshapemanager.hxx b/slideshow/source/inc/subsettableshapemanager.hxx
index 00ce34b2c..b4b4a8819 100644
--- a/slideshow/source/inc/subsettableshapemanager.hxx
+++ b/slideshow/source/inc/subsettableshapemanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124,3 +125,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_SUBSETTABLESHAPEMANAGER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/tools.hxx b/slideshow/source/inc/tools.hxx
index ff2f43f1b..8e0b5b395 100644
--- a/slideshow/source/inc/tools.hxx
+++ b/slideshow/source/inc/tools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -392,9 +393,13 @@ namespace slideshow
basegfx::B2DRange getAPIShapeBounds( const ::com::sun::star::uno::Reference<
::com::sun::star::drawing::XShape >& xShape );
+/*
+ TODO(F1): When ZOrder someday becomes usable enable this
+
/// Get the content of the ZOrder shape property
double getAPIShapePrio( const ::com::sun::star::uno::Reference<
::com::sun::star::drawing::XShape >& xShape );
+*/
basegfx::B2IVector getSlideSizePixel( const basegfx::B2DVector& rSize,
const boost::shared_ptr<UnoView>& pView );
@@ -402,3 +407,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_TOOLS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/transitionfactory.hxx b/slideshow/source/inc/transitionfactory.hxx
index 51f0d403a..33296c5ba 100644
--- a/slideshow/source/inc/transitionfactory.hxx
+++ b/slideshow/source/inc/transitionfactory.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -146,3 +147,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_TRANSITIONFACTORY_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/transitioninfo.hxx b/slideshow/source/inc/transitioninfo.hxx
index 95129db49..a6b60a09d 100644
--- a/slideshow/source/inc/transitioninfo.hxx
+++ b/slideshow/source/inc/transitioninfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -158,3 +159,5 @@ struct TransitionInfo
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_TRANSITIONINFO_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/unoview.hxx b/slideshow/source/inc/unoview.hxx
index aac543e55..6ac02b6d2 100644
--- a/slideshow/source/inc/unoview.hxx
+++ b/slideshow/source/inc/unoview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,3 +84,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_UNOVIEW_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/unoviewcontainer.hxx b/slideshow/source/inc/unoviewcontainer.hxx
index 71ebc5734..994a72504 100644
--- a/slideshow/source/inc/unoviewcontainer.hxx
+++ b/slideshow/source/inc/unoviewcontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108,3 +109,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_UNOVIEWCONTAINER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/usereventqueue.hxx b/slideshow/source/inc/usereventqueue.hxx
index 63f7965b5..e84f0dd08 100644
--- a/slideshow/source/inc/usereventqueue.hxx
+++ b/slideshow/source/inc/usereventqueue.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,7 +57,7 @@ class MouseLeaveHandler;
This class registeres at the EventMultiplexer and fires
events registered for certain user actions. Note that all
events will not be fired immediately after the user action
- occured, but always added to the EventQueue (and fired the
+ occurred, but always added to the EventQueue (and fired the
next time that queue is processed). Which is actually a
feature.
@@ -325,3 +326,4 @@ private:
#endif /* INCLUDED_SLIDESHOW_USEREVENTQUEUE_HXX */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/userpainteventhandler.hxx b/slideshow/source/inc/userpainteventhandler.hxx
index 471c2b35c..c7a56fc36 100644
--- a/slideshow/source/inc/userpainteventhandler.hxx
+++ b/slideshow/source/inc/userpainteventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_USERPAINTEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/view.hxx b/slideshow/source/inc/view.hxx
index 60c514b7b..43fc5f90d 100644
--- a/slideshow/source/inc/view.hxx
+++ b/slideshow/source/inc/view.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEW_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/vieweventhandler.hxx b/slideshow/source/inc/vieweventhandler.hxx
index 93ed651ad..1b97d613a 100644
--- a/slideshow/source/inc/vieweventhandler.hxx
+++ b/slideshow/source/inc/vieweventhandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWEVENTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/viewlayer.hxx b/slideshow/source/inc/viewlayer.hxx
index fd6adf88a..c2351a517 100644
--- a/slideshow/source/inc/viewlayer.hxx
+++ b/slideshow/source/inc/viewlayer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -173,3 +174,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWLAYER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/viewrepainthandler.hxx b/slideshow/source/inc/viewrepainthandler.hxx
index 6720a33b8..a361825a1 100644
--- a/slideshow/source/inc/viewrepainthandler.hxx
+++ b/slideshow/source/inc/viewrepainthandler.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWREPAINTHANDLER_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/viewupdate.hxx b/slideshow/source/inc/viewupdate.hxx
index 7656a311d..7cddf1cbe 100644
--- a/slideshow/source/inc/viewupdate.hxx
+++ b/slideshow/source/inc/viewupdate.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,5 @@ namespace slideshow
}
#endif /* INCLUDED_SLIDESHOW_VIEWUPDATE_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/source/inc/wakeupevent.hxx b/slideshow/source/inc/wakeupevent.hxx
index 0ae0729a5..602993ebd 100644
--- a/slideshow/source/inc/wakeupevent.hxx
+++ b/slideshow/source/inc/wakeupevent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,3 +92,5 @@ typedef ::boost::shared_ptr< WakeupEvent > WakeupEventSharedPtr;
} // namespace presentation
#endif /* INCLUDED_SLIDESHOW_WAKEUPEVENT_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/demoshow.cxx b/slideshow/test/demoshow.cxx
index 4bbfcc7b6..0bf6f34a6 100644
--- a/slideshow/test/demoshow.cxx
+++ b/slideshow/test/demoshow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,6 +54,7 @@
#include <ucbhelper/configurationkeys.hxx>
#include <basegfx/matrix/b2dhommatrix.hxx>
+#include <basegfx/matrix/b2dhommatrixtools.hxx>
#include <basegfx/tools/canvastools.hxx>
#include <basegfx/range/b2drectangle.hxx>
#include <basegfx/polygon/b2dpolygon.hxx>
@@ -198,6 +200,11 @@ private:
{
}
+ virtual awt::Rectangle SAL_CALL getCanvasArea( ) throw (uno::RuntimeException)
+ {
+ return awt::Rectangle(0,0,maSize.Width(),maSize.Height());
+ }
+
uno::Reference< rendering::XSpriteCanvas > mxCanvas;
::cppu::OInterfaceContainerHelper maPaintListeners;
::cppu::OInterfaceContainerHelper maTransformationListeners;
@@ -417,7 +424,7 @@ DemoWindow::DemoWindow() :
maUpdateTimer(),
mbSlideDisplayed( false )
{
- SetText( rtl::OUString::createFromAscii( "Slideshow Demo" ) );
+ SetText( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "Slideshow Demo" )) );
SetSizePixel( Size( 640, 480 ) );
EnablePaint( true );
@@ -455,11 +462,13 @@ void DemoWindow::init()
if( mxShow.is() && !mbSlideDisplayed )
{
uno::Reference< drawing::XDrawPage > xSlide( new DummySlide );
+ uno::Reference< drawing::XDrawPages > xDrawPages;
mxShow->displaySlide( xSlide,
+ uno::Reference< drawing::XDrawPagesSupplier >(),
uno::Reference< animations::XAnimationNode >(),
uno::Sequence< beans::PropertyValue >() );
mxShow->setProperty( beans::PropertyValue(
- rtl::OUString::createFromAscii("RehearseTimings"),
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("RehearseTimings")),
0,
uno::makeAny( sal_True ),
beans::PropertyState_DIRECT_VALUE ));
@@ -478,8 +487,8 @@ IMPL_LINK( DemoWindow, updateHdl, Timer*, EMPTYARG )
{
init();
- double nTimeout;
if( mxShow.is() )
+ double nTimeout;
mxShow->update(nTimeout);
return 0;
@@ -514,8 +523,8 @@ void DemoApp::Main()
{
::rtl::OUString aParam = GetCommandLineParam( i );
- if( aParam.equalsAscii( "--help" ) ||
- aParam.equalsAscii( "-h" ) )
+ if( aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "--help" ) ) ||
+ aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-h" ) ) )
bHelp = true;
}
@@ -541,8 +550,7 @@ void DemoApp::Main()
}
catch( uno::Exception& )
{
- OSL_ENSURE( false,
- rtl::OUStringToOString(
+ OSL_FAIL( rtl::OUStringToOString(
comphelper::anyToString( cppu::getCaughtException() ),
RTL_TEXTENCODING_UTF8 ).getStr() );
}
@@ -555,8 +563,8 @@ void DemoApp::Main()
// Create UCB.
uno::Sequence< uno::Any > aArgs( 2 );
- aArgs[ 0 ] <<= rtl::OUString::createFromAscii( UCB_CONFIGURATION_KEY1_LOCAL );
- aArgs[ 1 ] <<= rtl::OUString::createFromAscii( UCB_CONFIGURATION_KEY2_OFFICE );
+ aArgs[ 0 ] <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( UCB_CONFIGURATION_KEY1_LOCAL ));
+ aArgs[ 1 ] <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( UCB_CONFIGURATION_KEY2_OFFICE ));
::ucbhelper::ContentBroker::initialize( xFactory, aArgs );
DemoWindow pWindow;
@@ -568,3 +576,5 @@ void DemoApp::Main()
}
DemoApp aApp;
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/export.map b/slideshow/test/export.map
index f313c44bd..0dbbcc5a7 100644
--- a/slideshow/test/export.map
+++ b/slideshow/test/export.map
@@ -27,7 +27,7 @@
UDK_3_0_0 {
global:
- registerAllTestFunction;
+ cppunitTestPlugIn;
local:
*;
diff --git a/slideshow/test/makefile.mk b/slideshow/test/makefile.mk
deleted file mode 100644
index c86d166b9..000000000
--- a/slideshow/test/makefile.mk
+++ /dev/null
@@ -1,101 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..
-
-PRJNAME=slideshow
-PRJINC=$(PRJ)$/source
-TARGET=tests
-TARGETTYPE=GUI
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Common ----------------------------------------------------------
-
-# BEGIN target1 -------------------------------------------------------
-SHL1OBJS= \
- $(SLO)$/views.obj \
- $(SLO)$/slidetest.obj \
- $(SLO)$/testshape.obj \
- $(SLO)$/testview.obj
-
-SHL1TARGET= tests
-SHL1STDLIBS= $(SALLIB) \
- $(BASEGFXLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(TESTSHL2LIB) \
- $(CPPUNITLIB) \
- $(UNOTOOLSLIB) \
- $(VCLLIB)
-
-.IF "$(OS)"=="WNT"
- SHL1STDLIBS+=$(LIBPRE) islideshowtest.lib
-.ELSE
- SHL1STDLIBS+=-lslideshowtest$(DLLPOSTFIX)
-.ENDIF
-
-SHL1IMPLIB= i$(SHL1TARGET)
-
-DEF1NAME =$(SHL1TARGET)
-SHL1VERSIONMAP = export.map
-# END target1 ----------------------------------------------------------
-
-# BEGIN target2 --------------------------------------------------------
-APP2OBJS= \
- $(SLO)$/demoshow.obj
-
-APP2TARGET= demoshow
-APP2STDLIBS=$(TOOLSLIB) \
- $(COMPHELPERLIB) \
- $(CPPCANVASLIB) \
- $(CPPULIB) \
- $(CPPUHELPERLIB) \
- $(UCBHELPERLIB) \
- $(SALLIB) \
- $(VCLLIB) \
- $(BASEGFXLIB)
-
-.IF "$(GUI)"!="UNX"
-APP2DEF= $(MISC)$/$(TARGET).def
-.ENDIF
-# END target2 ----------------------------------------------------------------
-
-#------------------------------- All object files ----------------------------
-
-# do this here, so we get right dependencies
-SLOFILES=$(SHL1OBJS)
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-.INCLUDE : _cppunit.mk
diff --git a/slideshow/test/slidetest.cxx b/slideshow/test/slidetest.cxx
index 9f0ab2c82..f43c284dc 100644
--- a/slideshow/test/slidetest.cxx
+++ b/slideshow/test/slidetest.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,7 +26,8 @@
*
************************************************************************/
-#include <testshl/simpleheader.hxx>
+#include <sal/cppunit.h>
+
#include <cppuhelper/compbase1.hxx>
#include <comphelper/broadcasthelper.hxx>
@@ -364,7 +366,9 @@ public:
}; // class LayerManagerTest
// -----------------------------------------------------------------------------
-CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(LayerManagerTest, "LayerManagerTest");
+CPPUNIT_TEST_SUITE_REGISTRATION(LayerManagerTest);
} // namespace
+CPPUNIT_PLUGIN_IMPLEMENT();
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/tests.hxx b/slideshow/test/tests.hxx
index 8272b6638..bce515445 100644
--- a/slideshow/test/tests.hxx
+++ b/slideshow/test/tests.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,3 +71,5 @@ TestShapeSharedPtr createTestShape(const basegfx::B2DRange& rRect,
double nPrio);
#endif /* INCLUDED_TESTS_HXX */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/testshape.cxx b/slideshow/test/testshape.cxx
index 86864c7e2..12db1ddf3 100644
--- a/slideshow/test/testshape.cxx
+++ b/slideshow/test/testshape.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,7 +26,10 @@
*
************************************************************************/
-#include <testshl/simpleheader.hxx>
+#include <cppunit/TestAssert.h>
+#include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
+
#include <cppuhelper/compbase1.hxx>
#include <cppuhelper/basemutex.hxx>
#include <comphelper/make_shared_from_uno.hxx>
@@ -37,6 +41,8 @@
#include "tests.hxx"
#include "com/sun/star/presentation/XSlideShowView.hpp"
+#include <o3tl/compat_functional.hxx>
+
#include <boost/bind.hpp>
namespace target = slideshow::internal;
@@ -139,7 +145,7 @@ private:
maViewLayers.end(),
boost::bind( std::equal_to< target::ViewLayerSharedPtr >(),
boost::cref( rNewLayer ),
- boost::bind( std::select1st<ViewVector::value_type>(),
+ boost::bind( o3tl::select1st<ViewVector::value_type>(),
_1 ))) == maViewLayers.end() )
throw std::exception();
@@ -149,7 +155,7 @@ private:
maViewLayers.end(),
boost::bind( std::equal_to< target::ViewLayerSharedPtr >(),
boost::cref( rNewLayer ),
- boost::bind( std::select1st<ViewVector::value_type>(),
+ boost::bind( o3tl::select1st<ViewVector::value_type>(),
_1 ))));
return true;
}
@@ -219,3 +225,5 @@ TestShapeSharedPtr createTestShape(const basegfx::B2DRange& rRect,
comphelper::make_shared_from_UNO(
new ImplTestShape(rRect,nPrio)) );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/testview.cxx b/slideshow/test/testview.cxx
index 8f029a9f3..1b06b717d 100644
--- a/slideshow/test/testview.cxx
+++ b/slideshow/test/testview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,7 +26,10 @@
*
************************************************************************/
-#include <testshl/simpleheader.hxx>
+#include <cppunit/TestAssert.h>
+#include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
+
#include <cppuhelper/compbase1.hxx>
#include <cppuhelper/basemutex.hxx>
#include <comphelper/make_shared_from_uno.hxx>
@@ -133,6 +137,11 @@ public:
{
}
+ virtual awt::Rectangle SAL_CALL getCanvasArea( ) throw (uno::RuntimeException)
+ {
+ return awt::Rectangle(0,0,100,100);
+ }
+
// TestView
virtual bool isClearCalled() const
{
@@ -275,6 +284,15 @@ public:
{
mbDisposed = true;
}
+
+ virtual bool isSoundEnabled (void) const
+ {
+ return true;
+ }
+
+ virtual void setIsSoundEnabled (const bool /*bValue*/)
+ {
+ }
};
@@ -284,3 +302,5 @@ TestViewSharedPtr createTestView()
comphelper::make_shared_from_UNO(
new ImplTestView()) );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/views.cxx b/slideshow/test/views.cxx
index 4a7a427f4..964e7ecd1 100644
--- a/slideshow/test/views.cxx
+++ b/slideshow/test/views.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,7 +26,10 @@
*
************************************************************************/
-#include <testshl/simpleheader.hxx>
+#include <cppunit/TestAssert.h>
+#include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
+
#include <cppuhelper/compbase1.hxx>
#include <comphelper/broadcasthelper.hxx>
@@ -81,10 +85,4 @@ public:
CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(UnoViewContainerTest, "UnoViewContainerTest");
} // namespace
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-NOADDITIONAL;
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/util/makefile.mk b/slideshow/util/makefile.mk
deleted file mode 100644
index 9d9bee14a..000000000
--- a/slideshow/util/makefile.mk
+++ /dev/null
@@ -1,112 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..
-
-PRJNAME=slideshow
-TARGET=slideshow
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Common ----------------------------------------------------------
-
-.IF "$(VERBOSE)"=="TRUE"
-CDEFS+=-DVERBOSE
-.ENDIF
-
-SHL1DLLPRE=
-LIB1TARGET=$(SLB)$/$(TARGET).lib
-LIB1FILES=\
- $(SLB)$/transitions.lib \
- $(SLB)$/activities.lib \
- $(SLB)$/animationnodes.lib \
- $(SLB)$/shapes.lib \
- $(SLB)$/slide.lib \
- $(SLB)$/engine.lib
-
-SHL1TARGET=$(TARGET).uno
-
-SHL1STDLIBS= $(TOOLSLIB) \
- $(CPPULIB) \
- $(SALLIB) \
- $(VCLLIB) \
- $(COMPHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(BASEGFXLIB) \
- $(CANVASTOOLSLIB) \
- $(CPPCANVASLIB) \
- $(UNOTOOLSLIB) \
- $(SVTOOLLIB) \
- $(AVMEDIALIB)
-
-SHL1IMPLIB=i$(TARGET)
-SHL1LIBS=$(SLB)$/$(TARGET).lib
-SHL1DEF=$(MISC)$/$(SHL1TARGET).def
-
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-
-DEF1NAME=$(SHL1TARGET)
-DEF1EXPORTFILE=exports.dxp
-
-# ==========================================================================
-
-TARGET2=slideshowtest
-LIB2TARGET=$(SLB)$/$(TARGET2).lib
-LIB2FILES=$(LIB1FILES)
-
-SHL2TARGET=$(TARGET2)$(DLLPOSTFIX)
-SHL2IMPLIB=i$(TARGET2)
-SHL2STDLIBS= $(SHL1STDLIBS)
-
-SHL2DEF=$(MISC)$/$(SHL2TARGET).def
-SHL2LIBS=$(SLB)$/$(TARGET2).lib
-
-DEF2NAME =$(SHL2TARGET)
-DEF2LIBNAME = $(TARGET2)
-DEF2DEPN =$(MISC)$/$(SHL2TARGET).flt
-
-DEF2DES =SlideShowTest
-
-# ==========================================================================
-
-.INCLUDE : target.mk
-
-$(MISC)$/$(SHL2TARGET).flt: makefile.mk \
- $(TARGET2).flt
- +$(TYPE) $(TARGET2).flt > $@
-
-
-ALLTAR : $(MISC)/slideshow.component
-
-$(MISC)/slideshow.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- slideshow.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt slideshow.component