Kaydet (Commit) e3290499 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin singlevalfields improvement

checking for casting to void* turns out to mask useful stuff, so
remove that and just deal with a few extra false+

Change-Id: Id9700d7ceda90ba8fdb38aa870f13a7ca3acb668
Reviewed-on: https://gerrit.libreoffice.org/63145
Tested-by: Jenkins
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 8709c643
......@@ -154,12 +154,7 @@ namespace canvas
mbActive(false),
mbIsCurrClipRectangle(true),
mbIsContentFullyOpaque( false ),
mbAlphaDirty( true ),
mbPositionDirty( true ),
mbTransformDirty( true ),
mbClipDirty( true ),
mbPrioDirty( true ),
mbVisibilityDirty( true )
mbTransformDirty( true )
{
}
......@@ -238,8 +233,6 @@ namespace canvas
maPosition,
getUpdateArea() );
}
mbAlphaDirty = true;
}
}
......@@ -277,7 +270,6 @@ namespace canvas
}
maPosition = aPoint;
mbPositionDirty = true;
}
}
......@@ -330,8 +322,6 @@ namespace canvas
maPosition,
getUpdateArea() );
}
mbClipDirty = true;
}
void CanvasCustomSpriteHelper::setPriority( const Sprite::Reference& rSprite,
......@@ -350,8 +340,6 @@ namespace canvas
maPosition,
getUpdateArea() );
}
mbPrioDirty = true;
}
}
......@@ -374,8 +362,6 @@ namespace canvas
maPosition,
getUpdateArea() );
}
mbVisibilityDirty = true;
}
}
......@@ -398,8 +384,6 @@ namespace canvas
maPosition,
getUpdateArea() );
}
mbVisibilityDirty = true;
}
}
......
......@@ -324,7 +324,6 @@ SchAttribTabDlg::SchAttribTabDlg(weld::Window* pParent,
const ViewElementListProvider* pViewElementListProvider,
const uno::Reference< util::XNumberFormatsSupplier >& xNumberFormatsSupplier)
: SfxTabDialogController(pParent, "modules/schart/ui/attributedialog.ui", "AttributeDialog", pAttr)
, nDlgType(nNoArrowNoShadowDlg)
, m_pParameter( pDialogParameter )
, m_pViewElementListProvider( pViewElementListProvider )
, m_pNumberFormatter(nullptr)
......@@ -488,7 +487,7 @@ void SchAttribTabDlg::PageCreated(const OString& rId, SfxTabPage &rPage)
aSet.Put (SvxDashListItem(m_pViewElementListProvider->GetDashList(),SID_DASH_LIST));
aSet.Put (SvxLineEndListItem(m_pViewElementListProvider->GetLineEndList(),SID_LINEEND_LIST));
aSet.Put (SfxUInt16Item(SID_PAGE_TYPE,0));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nDlgType));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nNoArrowNoShadowDlg));
if( m_pParameter->HasSymbolProperties() )
{
......@@ -508,13 +507,13 @@ void SchAttribTabDlg::PageCreated(const OString& rId, SfxTabPage &rPage)
aSet.Put(SvxBitmapListItem(m_pViewElementListProvider->GetBitmapList(),SID_BITMAP_LIST));
aSet.Put(SvxPatternListItem(m_pViewElementListProvider->GetPatternList(),SID_PATTERN_LIST));
aSet.Put(SfxUInt16Item(SID_PAGE_TYPE,0));
aSet.Put(SfxUInt16Item(SID_DLG_TYPE,nDlgType));
aSet.Put(SfxUInt16Item(SID_DLG_TYPE,nNoArrowNoShadowDlg));
rPage.PageCreated(aSet);
}
else if (rId == "transparent")
{
aSet.Put (SfxUInt16Item(SID_PAGE_TYPE,0));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nDlgType));
aSet.Put (SfxUInt16Item(SID_DLG_TYPE,nNoArrowNoShadowDlg));
rPage.PageCreated(aSet);
}
else if (rId == "fontname")
......
......@@ -107,8 +107,6 @@ class ViewElementListProvider;
class SchAttribTabDlg : public SfxTabDialogController
{
private:
sal_uInt16 nDlgType;
const ObjectPropertiesDialogParameter * const m_pParameter;
const ViewElementListProvider* const m_pViewElementListProvider;
SvNumberFormatter* m_pNumberFormatter;
......
......@@ -4,9 +4,39 @@ chart2/source/view/inc/PlottingPositionHelper.hxx:206
connectivity/source/inc/dbase/dindexnode.hxx:125
connectivity::dbase::ONDXPage bNoDelete
unsigned int
cui/source/inc/cfg.hxx:249
SvxConfigEntry nId
sal_uInt16
editeng/source/misc/hangulhanja.cxx:78
editeng::HangulHanjaConversion_Impl m_eConvType
class HangulHanjaConversion::ConversionType
filter/source/graphicfilter/eps/eps.cxx:139
PSWriter nNextChrSetId
sal_uInt8
include/opencl/openclwrapper.hxx:46
openclwrapper::GPUEnv mnIsUserCreated
int
include/svtools/headbar.hxx:219
HeaderBar mnBorderOff1
long
include/svtools/headbar.hxx:220
HeaderBar mnBorderOff2
long
include/svtools/ruler.hxx:628
Ruler mnBorderWidth
long
include/tools/ref.hxx:126
SvRefBase bNoDelete
unsigned int
include/vbahelper/vbapagesetupbase.hxx:50
VbaPageSetupBase mnOrientPortrait
sal_Int32
include/vcl/dialog.hxx:50
Dialog mnMousePositioned
long
libreofficekit/source/gtk/tilebuffer.hxx:219
LOEvent m_nSetGraphicSelectionType
int
sal/rtl/cipher.cxx:110
Cipher_Impl m_algorithm
rtlCipherAlgorithm
......@@ -28,6 +58,9 @@ sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx:1102
sc/source/ui/vba/vbahyperlink.hxx:82
ScVbaHyperlink mnType
long
sd/qa/unit/tiledrendering/tiledrendering.cxx:968
ViewCallback m_nPart
int
soltools/cpp/cpp.h:121
includelist always
char
......@@ -43,15 +76,18 @@ sw/source/filter/ww8/docxexport.hxx:100
sw/source/filter/ww8/ww8scan.hxx:65
SprmInfo nVari
unsigned int
sw/source/uibase/inc/tautofmt.hxx:50
SwAutoFormatDlg m_nDfltStylePos
sal_uInt8
vcl/inc/canvasbitmap.hxx:57
vcl::unotools::VclCanvasBitmap m_nEndianness
sal_Int8
vcl/inc/printdlg.hxx:151
vcl::PrintDialog::JobTabPage mnCollateUIMode
long
vcl/inc/unx/i18n_ic.hxx:33
SalI18N_InputContext mbUseable
int
vcl/inc/unx/salframe.h:130
X11SalFrame mbInputFocus
int
vcl/workben/icontest.cxx:144
IconTestApp nRet
int
......
......@@ -39,6 +39,7 @@ namespace {
struct MyFieldInfo
{
FieldDecl const * fieldDecl;
std::string parentClass;
std::string fieldName;
std::string fieldType;
......@@ -78,17 +79,30 @@ public:
{
TraverseDecl(compiler.getASTContext().getTranslationUnitDecl());
// dump all our output in one write call - this is to try and limit IO "crosstalk" between multiple processes
// writing to the same logfile
std::string output;
for (const MyFieldAssignmentInfo & s : assignedSet)
output += "asgn:\t" + s.parentClass + "\t" + s.fieldName + "\t" + s.value + "\n";
for (const MyFieldInfo & s : definitionSet)
output += "defn:\t" + s.parentClass + "\t" + s.fieldName + "\t" + s.fieldType + "\t" + s.sourceLocation + "\n";
std::ofstream myfile;
myfile.open( WORKDIR "/loplugin.singlevalfields.log", std::ios::app | std::ios::out);
myfile << output;
myfile.close();
if (!isUnitTestMode())
{
// dump all our output in one write call - this is to try and limit IO "crosstalk" between multiple processes
// writing to the same logfile
std::string output;
for (const MyFieldAssignmentInfo & s : assignedSet)
output += "asgn:\t" + s.parentClass + "\t" + s.fieldName + "\t" + s.value + "\n";
for (const MyFieldInfo & s : definitionSet)
output += "defn:\t" + s.parentClass + "\t" + s.fieldName + "\t" + s.fieldType + "\t" + s.sourceLocation + "\n";
std::ofstream myfile;
myfile.open( WORKDIR "/loplugin.singlevalfields.log", std::ios::app | std::ios::out);
myfile << output;
myfile.close();
}
else
{
for (const MyFieldAssignmentInfo & s : assignedSet)
if (compiler.getSourceManager().isInMainFile(compat::getBeginLoc(s.fieldDecl)))
report(
DiagnosticsEngine::Warning,
"assign %0",
compat::getBeginLoc(s.fieldDecl))
<< s.value;
}
}
bool shouldVisitTemplateInstantiations () const { return true; }
......@@ -98,18 +112,17 @@ public:
bool VisitFieldDecl( const FieldDecl* );
bool VisitMemberExpr( const MemberExpr* );
bool VisitCXXConstructorDecl( const CXXConstructorDecl* );
bool VisitImplicitCastExpr( const ImplicitCastExpr* );
// bool VisitUnaryExprOrTypeTraitExpr( const UnaryExprOrTypeTraitExpr* );
private:
void niceName(const FieldDecl*, MyFieldInfo&);
std::string getExprValue(const Expr*);
const FunctionDecl* get_top_FunctionDecl_from_Stmt(const Stmt&);
void checkCallExpr(const Stmt* child, const CallExpr* callExpr, std::string& assignValue, bool& bPotentiallyAssignedTo);
void markAllFields(const RecordDecl* recordDecl);
};
void SingleValFields::niceName(const FieldDecl* fieldDecl, MyFieldInfo& aInfo)
{
aInfo.fieldDecl = fieldDecl;
aInfo.parentClass = fieldDecl->getParent()->getQualifiedNameAsString();
aInfo.fieldName = fieldDecl->getNameAsString();
aInfo.fieldType = fieldDecl->getType().getAsString();
......@@ -164,77 +177,6 @@ bool SingleValFields::VisitCXXConstructorDecl( const CXXConstructorDecl* decl )
return true;
}
/**
* Check for calls to methods where a pointer to something is cast to a pointer to void.
* At which case it could have anything written to it.
*/
bool SingleValFields::VisitImplicitCastExpr( const ImplicitCastExpr* castExpr )
{
QualType qt = castExpr->getType().getDesugaredType(compiler.getASTContext());
if (qt.isNull()) {
return true;
}
if ( qt.isConstQualified() || !qt->isPointerType()
|| !qt->getAs<clang::PointerType>()->getPointeeType()->isVoidType() ) {
return true;
}
const Expr* subExpr = castExpr->getSubExpr();
qt = subExpr->getType();
if (!qt->isPointerType()) {
return true;
}
qt = qt->getPointeeType();
if (!qt->isRecordType()) {
return true;
}
const RecordDecl* recordDecl = qt->getAs<RecordType>()->getDecl();
markAllFields(recordDecl);
return true;
}
void SingleValFields::markAllFields(const RecordDecl* recordDecl)
{
for(auto fieldDecl = recordDecl->field_begin();
fieldDecl != recordDecl->field_end(); ++fieldDecl)
{
MyFieldAssignmentInfo aInfo;
niceName(*fieldDecl, aInfo);
aInfo.value = "?";
assignedSet.insert(aInfo);
}
const CXXRecordDecl* cxxRecordDecl = dyn_cast<CXXRecordDecl>(recordDecl);
if (!cxxRecordDecl || !cxxRecordDecl->hasDefinition()) {
return;
}
for (auto it = cxxRecordDecl->bases_begin(); it != cxxRecordDecl->bases_end(); ++it)
{
QualType qt = it->getType();
if (qt->isRecordType())
markAllFields(qt->getAs<RecordType>()->getDecl());
}
}
/**
* Check for usage of sizeof(T) where T is a record.
* Means we can't touch the size of the class by removing fields.
*
* @FIXME this could be tightened up. In some contexts e.g. "memset(p,sizeof(T),0)" we could emit a "set to zero"
*/
/*
bool SingleValFields::VisitUnaryExprOrTypeTraitExpr( const UnaryExprOrTypeTraitExpr* expr )
{
if (expr->getKind() != UETT_SizeOf || !expr->isArgumentType()) {
return true;
}
QualType qt = expr->getArgumentType();
if (!qt->isRecordType()) {
return true;
}
const RecordDecl* recordDecl = qt->getAs<RecordType>()->getDecl();
markAllFields(recordDecl);
return true;
}
*/
bool SingleValFields::VisitMemberExpr( const MemberExpr* memberExpr )
{
const ValueDecl* decl = memberExpr->getMemberDecl();
......@@ -491,6 +433,9 @@ std::string SingleValFields::getExprValue(const Expr* arg)
return "?";
if (arg->isValueDependent())
return "?";
// for stuff like: OUString foo = "xxx";
if (auto stringLiteral = dyn_cast<clang::StringLiteral>(arg))
return stringLiteral->getString();
// ParenListExpr containing a CXXNullPtrLiteralExpr and has a NULL type pointer
if (auto parenListExpr = dyn_cast<ParenListExpr>(arg))
{
......@@ -527,7 +472,7 @@ std::string SingleValFields::getExprValue(const Expr* arg)
return "?";
}
loplugin::Plugin::Registration< SingleValFields > X("singlevalfields", false);
loplugin::Plugin::Registration< SingleValFields > X("singlevalfields", true);
}
......
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#include <rtl/ustring.hxx>
struct Foo
{
// expected-error@+1 {{assign XXX [loplugin:singlevalfields]}}
OUString m_aMenuResourceURL;
Foo()
: m_aMenuResourceURL("XXX")
{
m_aMenuResourceURL = "XXX";
m_aMenuResourceURL = "X"
"XX";
}
};
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
......@@ -93,8 +93,6 @@ namespace framework
css::uno::Reference< css::ui::XUIConfigurationManager > m_xModuleCfgMgr;
css::uno::Reference< css::ui::XUIConfigurationManager > m_xDocCfgMgr;
OUString m_aModuleIdentifier;
OUString m_aPropUIName;
OUString m_aPropResourceURL;
bool m_bResetActive;
std::vector< OUString > m_aCommandVector;
IntlWrapper m_aIntlWrapper;
......
......@@ -123,11 +123,12 @@ DEFINE_XSERVICEINFO_MULTISERVICE_2 ( ToolbarsMenuController
DEFINE_INIT_SERVICE ( ToolbarsMenuController, {} )
static constexpr OUStringLiteral g_aPropUIName( "UIName" );
static constexpr OUStringLiteral g_aPropResourceURL( "ResourceURL" );
ToolbarsMenuController::ToolbarsMenuController( const css::uno::Reference< css::uno::XComponentContext >& xContext ) :
svt::PopupMenuControllerBase( xContext ),
m_xContext( xContext ),
m_aPropUIName( "UIName" ),
m_aPropResourceURL( "ResourceURL" ),
m_bResetActive( false ),
m_aIntlWrapper(SvtSysLocale().GetUILanguageTag())
{
......@@ -261,8 +262,8 @@ Sequence< Sequence< css::beans::PropertyValue > > ToolbarsMenuController::getLay
}
Sequence< css::beans::PropertyValue > aTbSeq( 2 );
aTbSeq[0].Name = m_aPropUIName;
aTbSeq[1].Name = m_aPropResourceURL;
aTbSeq[0].Name = g_aPropUIName;
aTbSeq[1].Name = g_aPropResourceURL;
Sequence< Sequence< css::beans::PropertyValue > > aSeq( aToolBarArray.size() );
const sal_uInt32 nCount = aToolBarArray.size();
......
......@@ -203,23 +203,8 @@ namespace canvas
*/
mutable bool mbIsContentFullyOpaque;
/// True, iff mfAlpha has changed
mutable bool mbAlphaDirty;
/// True, iff maPosition has changed
mutable bool mbPositionDirty;
/// True, iff maTransform has changed
mutable bool mbTransformDirty;
/// True, iff mxClipPoly has changed
mutable bool mbClipDirty;
/// True, iff mnPriority has changed
mutable bool mbPrioDirty;
/// True, iff mbActive has changed
mutable bool mbVisibilityDirty;
};
}
......
......@@ -84,12 +84,9 @@ public:
*/
const OUString& GetFontFamily() { return m_strFontFamily;}
bool GetFontPitchFixed() { return m_bPitchFixed;}
private:
OUString m_strFontName;
OUString m_strFontFamily;
bool m_bPitchFixed;
};
#endif
......
......@@ -63,7 +63,6 @@ XFFontDecl::XFFontDecl(const OUString& name, const OUString& family)
{
m_strFontName = name;
m_strFontFamily = family;
m_bPitchFixed = false;
}
......
......@@ -320,10 +320,7 @@ void XFStyleManager::ToXml(IXFStream *pStrm)
pAttrList->Clear();
pAttrList->AddAttribute( "style:name", fontDecl.GetFontName() );
pAttrList->AddAttribute( "fo:font-family", fontDecl.GetFontFamily() );
if( fontDecl.GetFontPitchFixed() )
pAttrList->AddAttribute( "style:font-pitch", "fixed" );
else
pAttrList->AddAttribute( "style:font-pitch", "variable" );
pAttrList->AddAttribute( "style:font-pitch", "variable" );
pStrm->StartElement( "style:font-decl" );
pStrm->EndElement( "style:font-decl" );
}
......
......@@ -151,7 +151,6 @@ public:
void DropScroll (const Point& rMousePos);
virtual void KeyInput(const KeyEvent& rKEvt) override;
protected:
VclPtr< ::sd::Window> mpShareWin;
Point maWinPos;
Point maViewOrigin;
Size maViewSize;
......
......@@ -480,7 +480,6 @@ SlideshowImpl::SlideshowImpl( const Reference< XPresentation2 >& xPresentation,
, mpDoc(pDoc)
, mpParentWindow(pParentWindow)
, mpShowWindow(nullptr)
, mpTimeButton(nullptr)
, mnRestoreSlide(0)
, maPresSize( -1, -1 )
, meAnimationMode(ANIMATIONMODE_SHOW)
......@@ -670,10 +669,6 @@ void SAL_CALL SlideshowImpl::disposing()
}
}
if( mpTimeButton )
mpTimeButton->Hide();
mpTimeButton.disposeAndClear();
if( mpShowWindow )
mpShowWindow->Hide();
mpShowWindow.disposeAndClear();
......
......@@ -330,7 +330,6 @@ private:
VclPtr<vcl::Window> mpParentWindow;
VclPtr<sd::ShowWindow> mpShowWindow;
VclPtr<PushButton> mpTimeButton;
std::shared_ptr< AnimationSlideController > mpSlideController;
......
......@@ -61,7 +61,6 @@ namespace sd {
Window::Window(vcl::Window* pParent)
: vcl::Window(pParent, WinBits(WB_CLIPCHILDREN | WB_DIALOGCONTROL)),
DropTargetHelper( this ),
mpShareWin(nullptr),
maWinPos(0, 0), // precautionary; but the values should be set
maViewOrigin(0, 0), // again from the owner of the window
maViewSize(1000, 1000),
......@@ -106,7 +105,6 @@ void Window::dispose()
if (pWindowUpdater != nullptr)
pWindowUpdater->UnregisterWindow (this);
}
mpShareWin.clear();
DropTargetHelper::dispose();
vcl::Window::dispose();
}
......@@ -146,30 +144,23 @@ void Window::CalcMinZoom()
// Get current zoom factor.
long nZoom = GetZoom();
if ( mpShareWin )
{
mpShareWin->CalcMinZoom();
mnMinZoom = mpShareWin->mnMinZoom;
}
else
{
// Get the rectangle of the output area in logical coordinates
// and calculate the scaling factors that would lead to the view
// area (also called application area) to completely fill the
// window.
Size aWinSize = PixelToLogic(GetOutputSizePixel());
sal_uLong nX = static_cast<sal_uLong>(static_cast<double>(aWinSize.Width())
* double(ZOOM_MULTIPLICATOR) / static_cast<double>(maViewSize.Width()));
sal_uLong nY = static_cast<sal_uLong>(static_cast<double>(aWinSize.Height())
* double(ZOOM_MULTIPLICATOR) / static_cast<double>(maViewSize.Height()));
// Decide whether to take the larger or the smaller factor.
sal_uLong nFact = std::min(nX, nY);
// The factor is transformed according to the current zoom factor.
nFact = nFact * nZoom / ZOOM_MULTIPLICATOR;
mnMinZoom = std::max(sal_uInt16(MIN_ZOOM), static_cast<sal_uInt16>(nFact));
}
// Get the rectangle of the output area in logical coordinates
// and calculate the scaling factors that would lead to the view
// area (also called application area) to completely fill the
// window.
Size aWinSize = PixelToLogic(GetOutputSizePixel());
sal_uLong nX = static_cast<sal_uLong>(static_cast<double>(aWinSize.Width())
* double(ZOOM_MULTIPLICATOR) / static_cast<double>(maViewSize.Width()));
sal_uLong nY = static_cast<sal_uLong>(static_cast<double>(aWinSize.Height())
* double(ZOOM_MULTIPLICATOR) / static_cast<double>(maViewSize.Height()));
// Decide whether to take the larger or the smaller factor.
sal_uLong nFact = std::min(nX, nY);
// The factor is transformed according to the current zoom factor.
nFact = nFact * nZoom / ZOOM_MULTIPLICATOR;
mnMinZoom = std::max(sal_uInt16(MIN_ZOOM), static_cast<sal_uInt16>(nFact));
// If the current zoom factor is smaller than the calculated minimal
// zoom factor then set the new minimal factor as the current zoom
// factor.
......
......@@ -76,7 +76,6 @@ namespace slideshow
const uno::Reference< drawing::XShape >& rxShape,
const uno::Reference< uno::XComponentContext >& rxContext ) :
mpViewLayer( rViewLayer ),
mpEventHandlerParent(nullptr),
maWindowOffset( 0, 0 ),
maBounds(),
mxShape( rxShape ),
......@@ -137,7 +136,6 @@ namespace slideshow
}
mpMediaWindow.disposeAndClear();
mpEventHandlerParent.disposeAndClear();
// shutdown player
if( mxPlayer.is() )
......@@ -257,15 +255,7 @@ namespace slideshow
if( mpMediaWindow.get() )
{
if( mpEventHandlerParent )
{
mpEventHandlerParent->SetPosSizePixel( aPosPixel, aSizePixel );
mpMediaWindow->SetPosSizePixel( Point(0,0), aSizePixel );
}
else
{
mpMediaWindow->SetPosSizePixel( aPosPixel, aSizePixel );
}
mpMediaWindow->SetPosSizePixel( aPosPixel, aSizePixel );
mxPlayerWindow->setPosSize( 0, 0,
aSizePixel.Width(), aSizePixel.Height(),
0 );
......@@ -483,7 +473,6 @@ namespace slideshow
//if there was no playerwindow, then clear the mpMediaWindow too
//so that we can draw a placeholder instead in that space
mpMediaWindow.disposeAndClear();
mpEventHandlerParent.disposeAndClear();
}
}
}
......
......@@ -148,7 +148,6 @@ namespace slideshow
const OUString& rMimeType );
ViewLayerSharedPtr const mpViewLayer;
VclPtr< SystemChildWindow > mpMediaWindow;
VclPtr< vcl::Window > mpEventHandlerParent;
mutable css::awt::Point maWindowOffset;
mutable ::basegfx::B2DRectangle maBounds;
......
......@@ -51,6 +51,7 @@ $(eval $(call gb_CompilerTest_add_exception_objects,compilerplugins_clang, \
compilerplugins/clang/test/simplifybool \
compilerplugins/clang/test/simplifyconstruct \
compilerplugins/clang/test/simplifydynamiccast \
compilerplugins/clang/test/singlevalfields \
compilerplugins/clang/test/staticconstfield \
compilerplugins/clang/test/staticvar \
compilerplugins/clang/test/stringbuffer \
......
......@@ -210,7 +210,6 @@ struct XMLEffectHint
OUString maSoundURL;
bool mbPlayFull;
sal_Int32 mnPresId;
sal_Int32 mnPathShapeId;
bool operator<(const XMLEffectHint& rComp) const { return mnPresId < rComp.mnPresId; }
......@@ -218,7 +217,7 @@ struct XMLEffectHint
: meKind( XMLE_SHOW ), mbTextEffect( false ),
meEffect( EK_none ), meDirection( ED_none ), mnStartScale( -1 ),
meSpeed( AnimationSpeed_SLOW ), maDimColor(0), mbPlayFull( false ),
mnPresId( 0 ), mnPathShapeId( -1 )
mnPresId( 0 )
{}
};
......@@ -366,7 +365,6 @@ void XMLAnimationsExporter::collect( const Reference< XShape >& xShape, SvXMLExp
}
mpImpl->maEffects.push_back( aEffect );
aEffect.mnPathShapeId = -1;
aEffect.maSoundURL.clear();
}
......@@ -485,11 +483,6 @@ void XMLAnimationsExporter::exportAnimations( SvXMLExport& rExport )
rExport.AddAttribute( XML_NAMESPACE_PRESENTATION, XML_SPEED, sTmp.makeStringAndClear() );
}
if( rEffect.mnPathShapeId != -1 )
{
rExport.AddAttribute( XML_NAMESPACE_PRESENTATION, XML_PATH_ID, OUString::number( rEffect.mnPathShapeId ) );
}
enum XMLTokenEnum eLocalName;
if( rEffect.meKind == XMLE_SHOW )
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment