summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xcompilerplugins/clang/unusedenumconstants.py2
-rw-r--r--extensions/source/scanner/grid.cxx14
-rw-r--r--extensions/source/scanner/grid.hxx2
3 files changed, 10 insertions, 8 deletions
diff --git a/compilerplugins/clang/unusedenumconstants.py b/compilerplugins/clang/unusedenumconstants.py
index 64aaa597ec9d..291f3500e561 100755
--- a/compilerplugins/clang/unusedenumconstants.py
+++ b/compilerplugins/clang/unusedenumconstants.py
@@ -113,6 +113,7 @@ for d in definitionSet:
"starmath/source/mathtype.hxx", # MathType::MTOKENS
"sd/source/filter/eppt/epptbase.hxx", # PPTExTextAttr
"sc/source/filter/inc/tokstack.hxx", # E_TYPE
+ "filter/source/graphicfilter/icgm/cgmtypes.hxx",
# unit test code
"cppu/source/uno/check.cxx",
# general weird nonsense going on
@@ -160,6 +161,7 @@ for d in definitionSet:
"sd/inc/pres.hxx", # AutoLayout (from UI)
"sc/source/ui/inc/scuitphfedit.hxx", # ScHFEntryId (from UI)
"include/i18nlangtag/languagetag.hxx", # LanguageTag::ScriptType
+ "extensions/source/scanner/grid.hxx", # ResetType (from UI)
# represents constants from an external API
"opencl/inc/opencl_device_selection.h",
"vcl/inc/sft.hxx",
diff --git a/extensions/source/scanner/grid.cxx b/extensions/source/scanner/grid.cxx
index 90faba32e8fc..4f8c285bcb90 100644
--- a/extensions/source/scanner/grid.cxx
+++ b/extensions/source/scanner/grid.cxx
@@ -127,7 +127,7 @@ public:
double* getNewYValues() { return m_pNewYValues; }
- void ChangeMode(int nType);
+ void ChangeMode(ResetType nType);
virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& rRect ) override;
};
@@ -631,11 +631,11 @@ void GridWindow::MouseButtonDown( const MouseEvent& rEvt )
Window::MouseButtonDown( rEvt );
}
-void GridWindow::ChangeMode(int nType)
+void GridWindow::ChangeMode(ResetType nType)
{
switch( nType )
{
- case LINEAR_ASCENDING:
+ case ResetType::LINEAR_ASCENDING:
{
for( int i = 0; i < m_nValues; i++ )
{
@@ -643,7 +643,7 @@ void GridWindow::ChangeMode(int nType)
}
}
break;
- case LINEAR_DESCENDING:
+ case ResetType::LINEAR_DESCENDING:
{
for( int i = 0; i < m_nValues; i++ )
{
@@ -651,13 +651,13 @@ void GridWindow::ChangeMode(int nType)
}
}
break;
- case RESET:
+ case ResetType::RESET:
{
if( m_pOrigYValues && m_pNewYValues && m_nValues )
memcpy( m_pNewYValues, m_pOrigYValues, m_nValues*sizeof(double) );
}
break;
- case EXPONENTIAL:
+ case ResetType::EXPONENTIAL:
{
for( int i = 0; i < m_nValues; i++ )
{
@@ -704,7 +704,7 @@ IMPL_LINK( GridDialog, ClickButtonHdl, Button*, pButton, void )
if (pButton == m_pResetButton)
{
int nType = m_pResetTypeBox->GetSelectEntryPos();
- m_pGridWindow->ChangeMode(nType);
+ m_pGridWindow->ChangeMode((ResetType)nType);
}
}
diff --git a/extensions/source/scanner/grid.hxx b/extensions/source/scanner/grid.hxx
index 73effc64143b..57e1106c7d16 100644
--- a/extensions/source/scanner/grid.hxx
+++ b/extensions/source/scanner/grid.hxx
@@ -27,7 +27,7 @@
class GridWindow;
-enum resetType
+enum class ResetType
{
LINEAR_ASCENDING = 0,
LINEAR_DESCENDING = 1,