Kaydet (Commit) d30a4298 authored tarafından Noel Grandin's avatar Noel Grandin Kaydeden (comit) Noel Grandin

loplugin:unusedenumconstants in package..svtools

Change-Id: I8136b93b9303ebecafd791159e813c335b1bc172
Reviewed-on: https://gerrit.libreoffice.org/28052Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
Tested-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst 500a3be0
......@@ -69,6 +69,16 @@ for d in definitionSet:
or srcLoc.startswith("include/typelib/")
or srcLoc.startswith("include/uno/")):
continue
# definitions of external file formats
if (srcLoc.startswith("include/svx/msdffdef.hxx"):
continue
# used in templates to find the last member of an enum
if (d1.endswith("LAST"):
continue
# used to aid in alignment of enum values
if (d1.endswith("FORCE_EQUAL_SIZE"):
continue
untouchedSet.add((clazz, srcLoc))
# sort the results using a "natural order" so sequences like [item1,item2,item10] sort nicely
......
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* 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/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (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.apache.org/licenses/LICENSE-2.0 .
*/
#ifndef INCLUDED_SVL_MAILENUM_HXX
#define INCLUDED_SVL_MAILENUM_HXX
enum MailState
{
MAIL_STATE_SUCCESS = 0,
MAIL_STATE_FAILURE,
MAIL_STATE_ATTACHED_NOT_FOUND,
MAIL_STATE_NO_MEMORY,
MAIL_STATE_LOGIN_FAILURE,
MAIL_STATE_RECEIVER_NOT_FOUND,
MAIL_STATE_TOO_MANY_FILES,
MAIL_STATE_TOO_MANY_RECEIVERS,
MAIL_STATE_NO_RECEIVERS,
MAIL_STATE_USER_CANCEL,
MAIL_STATE_DRIVER_NOT_AVAILABLE
};
enum MailDriver
{
MAIL_DRIVER_DETECT = 0,
MAIL_DRIVER_BEGIN,
MAIL_DRIVER_VIM = MAIL_DRIVER_BEGIN,
MAIL_DRIVER_MAPI,
MAIL_DRIVER_CMC,
MAIL_DRIVER_SMP,
MAIL_DRIVER_UNIX,
MAIL_DRIVER_SMTP,
MAIL_DRIVER_END
};
enum MailPriority
{
MAIL_PRIORITY_LOW = 0,
MAIL_PRIORITY_NORMAL,
MAIL_PRIORITY_URGENT
};
enum MailReceiverRole
{
MAIL_RECEIVER_TO = 0,
MAIL_RECEIVER_CC,
MAIL_RECEIVER_BCC,
MAIL_RECEIVER_NEWSGROUP
};
enum MailAction
{
MAIL_ACTION_DYING, // server dies
MAIL_ACTION_SEND, // mail was sent
MAIL_ACTION_READ, // mail was marked as read
MAIL_ACTION_REMOVED, // mail was deleted
MAIL_ACTION_UPDATED, // all mails were updated
MAIL_ACTION_NEXT, // jump to next mail
MAIL_ACTION_PREV // jump to previous mail
};
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
......@@ -71,7 +71,7 @@ enum NfKeywordIndex
NF_KEY_MMMMM, // first letter of month name
NF_KEY_LASTKEYWORD = NF_KEY_MMMMM,
NF_KEY_UNUSED4,
NF_KEY_QUARTER, // was quarter word, not used anymore from SRC631 on (26.04.01)
NF_KEY_UNUSED5, // was quarter word, not used anymore from SRC631 on (26.04.01)
NF_KEY_TRUE, // boolean true
NF_KEY_FALSE, // boolean false
NF_KEY_BOOLEAN, // boolean
......
......@@ -73,10 +73,7 @@ enum SfxMapUnit
SFX_MAPUNIT_POINT,
SFX_MAPUNIT_TWIP,
SFX_MAPUNIT_PIXEL,
SFX_MAPUNIT_SYSFONT,
SFX_MAPUNIT_APPFONT,
SFX_MAPUNIT_RELATIVE,
SFX_MAPUNIT_ABSOLUTE
};
/*
......
......@@ -36,15 +36,13 @@ enum class SearchOptionFlags
SELECTION = 0x0100,
FAMILIES = 0x0200,
FORMAT = 0x0400,
MORE = 0x0800,
SIMILARITY = 0x1000,
CONTENT = 0x2000,
WILDCARD = 0x4000,
ALL = 0x7fff
SIMILARITY = 0x0800,
WILDCARD = 0x1000,
ALL = 0x1fff
};
namespace o3tl
{
template<> struct typed_flags<SearchOptionFlags> : is_typed_flags<SearchOptionFlags, 0x7fff> {};
template<> struct typed_flags<SearchOptionFlags> : is_typed_flags<SearchOptionFlags, 0x1fff> {};
}
#endif
......
......@@ -55,7 +55,6 @@ enum class SvxSearchApp
WRITER = 0,
CALC = 1,
DRAW = 2,
BASE = 3,
};
// class SvxSearchItem ---------------------------------------------------
......
......@@ -45,13 +45,6 @@ enum SvNumberformatLimitOps
NUMBERFORMAT_OP_GE = 6 // Operator >=
};
// SYSTEM-german to SYSTEM-xxx and vice versa conversion hack onLoad
enum NfHackConversion
{
NF_CONVERT_NONE,
NF_CONVERT_GERMAN_ENGLISH,
NF_CONVERT_ENGLISH_GERMAN
};
struct ImpSvNumberformatInfo // Struct for FormatInfo
{
......
......@@ -237,11 +237,10 @@ enum class BorderWidthImplFlags
CHANGE_LINE1 = 1,
CHANGE_LINE2 = 2,
CHANGE_DIST = 4,
ADAPT_DIST = 8,
};
namespace o3tl
{
template<> struct typed_flags<BorderWidthImplFlags> : is_typed_flags<BorderWidthImplFlags, 0x0f> {};
template<> struct typed_flags<BorderWidthImplFlags> : is_typed_flags<BorderWidthImplFlags, 0x07> {};
}
class SVT_DLLPUBLIC BorderWidthImpl
{
......
......@@ -209,7 +209,6 @@ enum QueryDeleteResult_Impl
{
QUERYDELETE_CANCEL = RET_CANCEL,
QUERYDELETE_YES = RET_YES,
QUERYDELETE_NO = RET_NO,
QUERYDELETE_ALL = -1
};
......
......@@ -196,13 +196,12 @@ enum class HeaderBarItemBits
FLAT = 0x0800,
DOWNARROW = 0x1000,
UPARROW = 0x2000,
USERDRAW = 0x4000,
STDSTYLE = LEFT | LEFTIMAGE | VCENTER | CLICKABLE,
};
namespace o3tl
{
template<> struct typed_flags<HeaderBarItemBits> : is_typed_flags<HeaderBarItemBits, 0x7fff> {};
template<> struct typed_flags<HeaderBarItemBits> : is_typed_flags<HeaderBarItemBits, 0x3fff> {};
}
#define HEADERBAR_APPEND ((sal_uInt16)0xFFFF)
......
......@@ -39,7 +39,6 @@ enum class SvxIconViewFlags
POS_LOCKED = 0x0001,
SELECTED = 0x0002,
FOCUSED = 0x0004,
IN_USE = 0x0008,
CURSORED = 0x0010, // Border around image
POS_MOVED = 0x0020, // Moved by Drag and Drop, but not logged
DROP_TARGET = 0x0040, // Set in QueryDrop
......@@ -48,14 +47,13 @@ enum class SvxIconViewFlags
};
namespace o3tl
{
template<> struct typed_flags<SvxIconViewFlags> : is_typed_flags<SvxIconViewFlags, 0x04ff> {};
template<> struct typed_flags<SvxIconViewFlags> : is_typed_flags<SvxIconViewFlags, 0x04f7> {};
}
enum SvxIconChoiceCtrlTextMode
{
IcnShowTextFull = 1, // Enlarge BoundRect southwards
IcnShowTextShort, // Shorten with "..."
IcnShowTextSmart, // Show all text (not implemented)
IcnShowTextDontKnow // Settings of the View
};
......@@ -140,24 +138,16 @@ public:
bool IsPosLocked() const { return bool(nFlags & SvxIconViewFlags::POS_LOCKED); }
};
enum SvxIconChoiceCtrlColumnAlign
{
IcnViewAlignLeft = 1,
IcnViewAlignRight,
IcnViewAlignCenter
};
class SvxIconChoiceCtrlColumnInfo
{
OUString aColText;
Image aColImage;
long nWidth;
SvxIconChoiceCtrlColumnAlign eAlignment;
sal_uInt16 nSubItem;
public:
SvxIconChoiceCtrlColumnInfo( long nWd ) :
nWidth( nWd ), eAlignment( IcnViewAlignLeft ), nSubItem( 0 ) {}
nWidth( nWd ), nSubItem( 0 ) {}
SvxIconChoiceCtrlColumnInfo( const SvxIconChoiceCtrlColumnInfo& );
void SetWidth( long nWd ) { nWidth = nWd; }
......
......@@ -90,7 +90,6 @@ enum class SvLBoxTabFlags
// (on which Abo Tabpage/Extras/Option/Customize, etc. rely on)
// The first tab's position corresponds precisely to the Flags set
// and column widths
ALL = 0x0f5f,
};
namespace o3tl
{
......
......@@ -25,64 +25,7 @@
enum SvxChartStyle
{
CHSTYLE_2D_LINE,
CHSTYLE_2D_STACKEDLINE,
CHSTYLE_2D_PERCENTLINE,
CHSTYLE_2D_COLUMN,
CHSTYLE_2D_STACKEDCOLUMN,
CHSTYLE_2D_PERCENTCOLUMN,
CHSTYLE_2D_BAR,
CHSTYLE_2D_STACKEDBAR,
CHSTYLE_2D_PERCENTBAR,
CHSTYLE_2D_AREA,
CHSTYLE_2D_STACKEDAREA,
CHSTYLE_2D_PERCENTAREA,
CHSTYLE_2D_PIE,
CHSTYLE_3D_STRIPE,
CHSTYLE_3D_COLUMN,
CHSTYLE_3D_FLATCOLUMN,
CHSTYLE_3D_STACKEDFLATCOLUMN,
CHSTYLE_3D_PERCENTFLATCOLUMN,
CHSTYLE_3D_AREA,
CHSTYLE_3D_STACKEDAREA,
CHSTYLE_3D_PERCENTAREA,
CHSTYLE_3D_SURFACE,
CHSTYLE_3D_PIE,
CHSTYLE_2D_XY,
CHSTYLE_3D_XYZ,
CHSTYLE_2D_LINESYMBOLS,
CHSTYLE_2D_STACKEDLINESYM,
CHSTYLE_2D_PERCENTLINESYM,
CHSTYLE_2D_XYSYMBOLS,
CHSTYLE_3D_XYZSYMBOLS,
CHSTYLE_2D_DONUT1,
CHSTYLE_2D_DONUT2,
CHSTYLE_3D_BAR,
CHSTYLE_3D_FLATBAR,
CHSTYLE_3D_STACKEDFLATBAR,
CHSTYLE_3D_PERCENTFLATBAR,
CHSTYLE_2D_PIE_SEGOF1,
CHSTYLE_2D_PIE_SEGOFALL,
CHSTYLE_2D_NET,
CHSTYLE_2D_NET_SYMBOLS,
CHSTYLE_2D_NET_STACK,
CHSTYLE_2D_NET_SYMBOLS_STACK,
CHSTYLE_2D_NET_PERCENT,
CHSTYLE_2D_NET_SYMBOLS_PERCENT,
CHSTYLE_2D_CUBIC_SPLINE,
CHSTYLE_2D_CUBIC_SPLINE_SYMBOL,
CHSTYLE_2D_B_SPLINE,
CHSTYLE_2D_B_SPLINE_SYMBOL,
CHSTYLE_2D_CUBIC_SPLINE_XY,
CHSTYLE_2D_CUBIC_SPLINE_SYMBOL_XY,
CHSTYLE_2D_B_SPLINE_XY,
CHSTYLE_2D_B_SPLINE_SYMBOL_XY,
CHSTYLE_2D_XY_LINE,
CHSTYLE_2D_LINE_COLUMN,
CHSTYLE_2D_LINE_STACKEDCOLUMN,
CHSTYLE_2D_STOCK_1,
CHSTYLE_2D_STOCK_2,
CHSTYLE_2D_STOCK_3,
CHSTYLE_2D_STOCK_4,
CHSTYLE_ADDIN
};
......@@ -91,12 +34,6 @@ enum SvxChartStyle
enum SvxChartDataDescr
{
CHDESCR_NONE,
CHDESCR_VALUE,
CHDESCR_PERCENT,
CHDESCR_TEXT,
CHDESCR_TEXTANDPERCENT,
CHDESCR_NUMFORMAT_PERCENT,
CHDESCR_NUMFORMAT_VALUE,
CHDESCR_TEXTANDVALUE
};
......@@ -112,15 +49,6 @@ enum SvxChartTextOrder
#define CHTXTORDER_COUNT (CHTXTORDER_AUTO + 1)
enum SvxChartTextOrient
{
CHTXTORIENT_AUTOMATIC,
CHTXTORIENT_STANDARD,
CHTXTORIENT_BOTTOMTOP,
CHTXTORIENT_STACKED,
CHTXTORIENT_TOPBOTTOM
};
#define CHTXTORIENT_COUNT (CHTXTORIENT_TOPBOTTOM + 1)
enum SvxChartKindError
......
......@@ -32,9 +32,6 @@ const double EPSILON = 1e-06;
enum E3dDragConstraint { E3DDRAG_CONSTR_X = 0x0001,
E3DDRAG_CONSTR_Y = 0x0002,
E3DDRAG_CONSTR_Z = 0x0004,
E3DDRAG_CONSTR_XY = 0x0003,
E3DDRAG_CONSTR_XZ = 0x0005,
E3DDRAG_CONSTR_YZ = 0x0006,
E3DDRAG_CONSTR_XYZ = 0x0007
};
......
......@@ -39,8 +39,7 @@ enum SdrPathSegmentKind {SDRPATHSEGMENT_DONTCARE, // only for status query
enum SdrObjClosedKind {SDROBJCLOSED_DONTCARE, // only for status query
SDROBJCLOSED_OPEN, // non-closed object (line, polyline, ...)
SDROBJCLOSED_CLOSED, // closed object (polygon, ...)
SDROBJCLOSED_TOGGLE}; // only for Set: Toggle (not implemented yet)
SDROBJCLOSED_CLOSED}; // closed object (polygon, ...)
class IPolyPolygonEditorController
{
......
......@@ -31,10 +31,7 @@ enum SvxNumType
SVX_ROMAN_LOWER,
SVX_ARABIC,
SVX_NUMBER_NONE,
SVX_CHAR_SPECIAL,
SVX_PAGEDESC,
SVX_BITMAP,
SVX_CHARS_UPPER_LETTER_N
};
/*--------------------------------------------------------------------
......@@ -46,9 +43,7 @@ enum SvxPageUsage
SVX_PAGE_LEFT = 0x0001,
SVX_PAGE_RIGHT = 0x0002,
SVX_PAGE_ALL = 0x0003,
SVX_PAGE_MIRROR = 0x0007,
SVX_PAGE_HEADERSHARE = 0x0040,
SVX_PAGE_FOOTERSHARE = 0x0080
SVX_PAGE_MIRROR = 0x0007
};
/*--------------------------------------------------------------------
......
......@@ -58,15 +58,6 @@ namespace o3tl
enum SdrHitKind {SDRHIT_NONE, // No hit
SDRHIT_OBJECT, // Hit
SDRHIT_BOUNDRECT, // Hit at BoundRect
SDRHIT_BOUNDTL, // Hit at BoundRect TopLeft
SDRHIT_BOUNDTC, // Hit at BoundRect TopCenter
SDRHIT_BOUNDTR, // Hit at BoundRect TopRight
SDRHIT_BOUNDCL, // Hit at BoundRect CenterLeft
SDRHIT_BOUNDCR, // Hit at BoundRect CenterRight
SDRHIT_BOUNDBL, // Hit at BoundRect BottomLeft
SDRHIT_BOUNDBC, // Hit at BoundRect BottomCenter
SDRHIT_BOUNDBR,/*,*/ // Hit at BoundRect BottomRight
/*SDRHIT_REFPOINT*/ // Reference point (Rotation axis, axis of reflextion) hit
SDRHIT_HANDLE, // Marking handle
SDRHIT_HELPLINE, // Reference line
......
......@@ -57,7 +57,6 @@ enum SdrInsertReasonKind {
SDRREASON_STREAMING, /// importing document
SDRREASON_UNDO, /// from Undo
SDRREASON_COPY, /// something copied...
SDRREASON_VIEWCREATE, /// created by User interactively
SDRREASON_VIEWCALL /// via SdrView::Group(), ...
};
......
......@@ -66,7 +66,6 @@ namespace sdr { namespace contact {
enum SdrAnimationMode
{
SDR_ANIMATION_ANIMATE,
SDR_ANIMATION_DONT_ANIMATE,
SDR_ANIMATION_DISABLE
};
......
......@@ -72,8 +72,7 @@ enum class SdrSnap
{
NOTSNAPPED = 0x00,
XSNAPPED = 0x01,
YSNAPPED = 0x02,
XYSNAPPED = XSNAPPED | YSNAPPED,
YSNAPPED = 0x02
};
namespace o3tl
{
......
......@@ -54,10 +54,6 @@ enum SdrDragMode
};
// fuer SdrObject::ConvertToPoly()
enum SdrConvertType {SDRCONVERT_POLY, // create pure polygon
SDRCONVERT_BEZIER, // Beziersegment
SDRCONVERT_MIXED}; // mixed object (optimal)
/*
* Layer
......@@ -76,8 +72,6 @@ typedef sal_uInt8 SdrLayerID;
enum SdrObjListKind {SDROBJLIST_UNKNOWN =0x00,
// reine Objektlisten:
SDROBJLIST_GROUPOBJ =0x01,
SDROBJLIST_VIRTOBJECTS=0x02,
SDROBJLIST_SYMBOLTABLE=0x03,
// Here is space for 12 more types of lists
// Pages:
SDROBJLIST_DRAWPAGE =0x10,
......@@ -92,16 +86,7 @@ enum SdrRepeatFunc {SDRREPFUNC_OBJ_NONE,
// with parameter
SDRREPFUNC_OBJ_MOVE, // distance
SDRREPFUNC_OBJ_RESIZE, // factor, reference(%) related to MarkRect
SDRREPFUNC_OBJ_SETSNAPRECT, // rectangle
SDRREPFUNC_OBJ_SETLOGICRECT, // rectangle
SDRREPFUNC_OBJ_ROTATE, // rotation angle, reference(%) related to MarkRect
SDRREPFUNC_OBJ_SHEAR, // angle, factor, reference(%) related to MarkRect
SDRREPFUNC_OBJ_CROOKROTATE,
SDRREPFUNC_OBJ_CROOKSLANT,
SDRREPFUNC_OBJ_CROOKSTRETCH,
SDRREPFUNC_OBJ_ALIGN, // Hor/Vert/bBound
SDRREPFUNC_OBJ_SETATTRIBUTES,// ItemSet
SDRREPFUNC_OBJ_SETSTYLESHEET,// StyleSheet*
// Without parameter
SDRREPFUNC_OBJ_DELETE,
SDRREPFUNC_OBJ_COMBINE_POLYPOLY,
......@@ -118,7 +103,6 @@ enum SdrRepeatFunc {SDRREPFUNC_OBJ_NONE,
SDRREPFUNC_OBJ_MOVTOBTM,
SDRREPFUNC_OBJ_REVORDER,
SDRREPFUNC_OBJ_IMPORTMTF,
SDRREPFUNC_PAGE_DELETE,
SDRREPFUNC_LAST};
#endif // INCLUDED_SVX_SVDTYPES_HXX
......
......@@ -29,21 +29,6 @@
#include <basegfx/point/b2dpoint.hxx>
#include <tools/toolsdllapi.h>
/// Supported methods for setting the aspect ratio
enum Base3DRatio
{
Base3DRatioGrow = 1,
Base3DRatioShrink,
Base3DRatioMiddle
};
/// Supported projection types
enum Base3DProjectionType
{
Base3DProjectionTypeParallel = 1,
Base3DProjectionTypePerspective
};
/// Transformation sets for 3D output
class TOOLS_DLLPUBLIC B3dTransformationSet
{
......
......@@ -47,13 +47,6 @@ namespace com { namespace sun { namespace star {
namespace uno { class XComponentContext; }
namespace task { class XInteractionHandler; }
} } }
enum SegmentEnum
{
e_Aborted = -1000,
e_Retry,
e_Finished,
e_Success = 0
};
enum InitialisationMode
{
......
......@@ -39,10 +39,7 @@ namespace rptui
typedef ::std::multimap< sal_Int16, OUString, ::std::less< sal_Int16 > > IndexToNameMap;
enum DlgEdHintKind
{
RPTUI_HINT_UNKNOWN,
RPTUI_HINT_WINDOWSCROLLED,
RPTUI_HINT_LAYERCHANGED,
RPTUI_HINT_OBJORDERCHANGED,
RPTUI_HINT_SELECTIONCHANGED
};
......
......@@ -28,18 +28,12 @@
//= UI flags (for all browseable properties)
enum class PropUIFlags {
NONE = 0x0001, // no special flag
Enum = 0x0002, // the property is some kind of enum property, i.e. its // value is chosen from a fixed list of possible values
EnumOne = 0x0004, // the property is an enum property starting with 1
// (note that this includes PropUIFlags::Enum)
Composeable = 0x0008, // the property is "composeable", i.e. an intersection of property
Composeable = 0x0002, // the property is "composeable", i.e. an intersection of property
// sets should expose it, if all elements do
Experimental = 0x0010, // the property is experimental, i.e. should not appear in the
// UI, unless experimental properties are enabled by a configuration
// option
DataProperty = 0x0020 // the property is to appear on the "Data" page
DataProperty = 0x0004 // the property is to appear on the "Data" page
};
namespace o3tl {
template<> struct typed_flags<PropUIFlags> : is_typed_flags<PropUIFlags, 0x003f> {};
template<> struct typed_flags<PropUIFlags> : is_typed_flags<PropUIFlags, 0x0007> {};
}
......
......@@ -206,12 +206,6 @@ public:
};
enum PasswordState {
no_password,
entered,
cancelled
};
class PasswordContainer : public ::cppu::WeakImplHelper<
css::task::XPasswordContainer2,
css::lang::XServiceInfo,
......
......@@ -58,7 +58,6 @@ SvxIconChoiceCtrlColumnInfo::SvxIconChoiceCtrlColumnInfo( const SvxIconChoiceCtr
: aColText( rInfo.aColText ), aColImage( rInfo.aColImage )
{
nWidth = rInfo.nWidth;
eAlignment = rInfo.eAlignment;
nSubItem = rInfo.nSubItem;
}
......
......@@ -24,7 +24,6 @@
#include <tools/urlobj.hxx>
#include <svl/urihelper.hxx>
#include <unotools/pathoptions.hxx>
#include <svl/mailenum.hxx>
#include <svx/svxdlg.hxx>
#include <svx/dialogs.hrc>
#include <helpid.h>
......
......@@ -22,7 +22,6 @@
#include <o3tl/any.hxx>
#include <tools/stream.hxx>
#include <vcl/svapp.hxx>
#include <svl/mailenum.hxx>
#include <svx/svxids.hrc>
#include <editeng/svxenum.hxx>
#include <osl/diagnose.h>
......
......@@ -59,7 +59,6 @@
#include <sfx2/docfile.hxx>
#include <sfx2/progress.hxx>
#include <sfx2/dispatch.hxx>
#include <svl/mailenum.hxx>
#include <cmdid.h>
#include <swmodule.hxx>
#include <view.hxx>
......
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