summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorMatteo Casalin <matteo.casalin@yahoo.com>2015-12-15 20:46:34 +0100
committerAshod Nakashian <ashod.nakashian@collabora.co.uk>2016-07-20 01:25:51 -0400
commitcfe9fcbedd38e62d16c0a1bfff90c040efd6c1d1 (patch)
tree99269fc518c8bdd0567da080a4b65276d147c21e /sc
parent60e0035e6456e14d0c1c39aec89e87b13ac2057e (diff)
sal_uLong/sal_uIntPtr/sal_uInt16 to sal_uInt32
also avoid some explicit temporaries and group some checks. Change-Id: I7795b208dde53fd383b8c75f72dd9f56429aea2b (cherry picked from commit cb98c423bbdada017a687186a5c06def6cb6f7a2)
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/formulacell.cxx2
-rw-r--r--sc/source/core/tool/dbdata.cxx3
-rw-r--r--sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx2
-rw-r--r--sc/source/ui/Accessibility/AccessiblePreviewTable.cxx4
-rw-r--r--sc/source/ui/Accessibility/AccessibleText.cxx104
-rw-r--r--sc/source/ui/app/inputwin.cxx2
-rw-r--r--sc/source/ui/app/scmod.cxx10
-rw-r--r--sc/source/ui/docshell/docsh.cxx3
-rw-r--r--sc/source/ui/docshell/servobj.cxx3
-rw-r--r--sc/source/ui/navipi/navipi.cxx2
-rw-r--r--sc/source/ui/unoobj/cellsuno.cxx10
-rw-r--r--sc/source/ui/unoobj/chart2uno.cxx2
-rw-r--r--sc/source/ui/unoobj/datauno.cxx8
-rw-r--r--sc/source/ui/unoobj/docuno.cxx2
-rw-r--r--sc/source/ui/unoobj/editsrc.cxx2
-rw-r--r--sc/source/ui/unoobj/textuno.cxx2
-rw-r--r--sc/source/ui/view/prevwsh2.cxx3
-rw-r--r--sc/source/ui/view/tabvwsh5.cxx2
18 files changed, 62 insertions, 104 deletions
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 26a1de92bf6d..8b72b196edb1 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -2172,7 +2172,7 @@ void ScFormulaCell::Notify( const SfxHint& rHint )
if (!pSimpleHint)
return;
- sal_uLong nHint = pSimpleHint->GetId();
+ const sal_uInt32 nHint = pSimpleHint->GetId();
if (nHint == SC_HINT_REFERENCE)
{
const sc::RefHint& rRefHint = static_cast<const sc::RefHint&>(rHint);
diff --git a/sc/source/core/tool/dbdata.cxx b/sc/source/core/tool/dbdata.cxx
index bb1ae5669c23..59fbb9b9b261 100644
--- a/sc/source/core/tool/dbdata.cxx
+++ b/sc/source/core/tool/dbdata.cxx
@@ -888,8 +888,7 @@ void ScDBData::Notify( const SfxHint& rHint )
if (!pScHint)
return;
- sal_uLong nHint = pScHint->GetId();
- if (nHint & SC_HINT_DATACHANGED)
+ if (pScHint->GetId() & SC_HINT_DATACHANGED)
{
mbTableColumnNamesDirty = true;
if (!mpContainer)
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
index 54f456bd3f66..34c1ca250dd6 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
@@ -122,7 +122,7 @@ void ScAccessiblePreviewHeaderCell::Notify( SfxBroadcaster& rBC, const SfxHint&
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if (pSimpleHint)
{
- sal_uLong nId = pSimpleHint->GetId();
+ const sal_uInt32 nId {pSimpleHint->GetId()};
if (nId == SC_HINT_ACC_VISAREACHANGED)
{
if (mpTextHelper)
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
index b1af3790bc83..4e083a6b9106 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
@@ -89,14 +89,14 @@ void ScAccessiblePreviewTable::Notify( SfxBroadcaster& rBC, const SfxHint& rHint
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if (pSimpleHint)
{
- sal_uLong nId = pSimpleHint->GetId();
+ const sal_uInt32 nId {pSimpleHint->GetId()};
if ( nId == SFX_HINT_DATACHANGED )
{
// column / row layout may change with any document change,
// so it must be invalidated
DELETEZ( mpTableInfo );
}
- else if (pSimpleHint->GetId() == SC_HINT_ACC_VISAREACHANGED)
+ else if (nId == SC_HINT_ACC_VISAREACHANGED)
{
AccessibleEventObject aEvent;
aEvent.EventId = AccessibleEventId::VISIBLE_DATA_CHANGED;
diff --git a/sc/source/ui/Accessibility/AccessibleText.cxx b/sc/source/ui/Accessibility/AccessibleText.cxx
index 13f23a3f6da6..4edcec97bbed 100644
--- a/sc/source/ui/Accessibility/AccessibleText.cxx
+++ b/sc/source/ui/Accessibility/AccessibleText.cxx
@@ -723,17 +723,13 @@ ScAccessibleCellTextData::~ScAccessibleCellTextData()
void ScAccessibleCellTextData::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpViewShell = nullptr; // invalid now
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- if (mpEditViewForwarder)
- mpEditViewForwarder->SetInvalid();
- }
+ mpViewShell = nullptr; // invalid now
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
+ if (mpEditViewForwarder)
+ mpEditViewForwarder->SetInvalid();
}
ScAccessibleCellBaseTextData::Notify(rBC, rHint);
}
@@ -979,20 +975,16 @@ ScAccessibleEditObjectTextData::~ScAccessibleEditObjectTextData()
void ScAccessibleEditObjectTextData::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpWindow = nullptr;
- mpEditView = nullptr;
- mpEditEngine = nullptr;
- DELETEZ(mpForwarder);
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- if (mpEditViewForwarder)
- mpEditViewForwarder->SetInvalid();
- }
+ mpWindow = nullptr;
+ mpEditView = nullptr;
+ mpEditEngine = nullptr;
+ DELETEZ(mpForwarder);
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
+ if (mpEditViewForwarder)
+ mpEditViewForwarder->SetInvalid();
}
ScAccessibleTextData::Notify(rBC, rHint);
}
@@ -1240,15 +1232,11 @@ ScAccessiblePreviewCellTextData::~ScAccessiblePreviewCellTextData()
void ScAccessiblePreviewCellTextData::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpViewShell = nullptr; // invalid now
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- }
+ mpViewShell = nullptr; // invalid now
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
}
ScAccessibleCellBaseTextData::Notify(rBC, rHint);
}
@@ -1318,15 +1306,11 @@ ScAccessiblePreviewHeaderCellTextData::~ScAccessiblePreviewHeaderCellTextData()
void ScAccessiblePreviewHeaderCellTextData::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpViewShell = nullptr; // invalid now
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- }
+ mpViewShell = nullptr; // invalid now
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
}
ScAccessibleCellBaseTextData::Notify(rBC, rHint);
}
@@ -1441,16 +1425,12 @@ ScAccessibleTextData* ScAccessibleHeaderTextData::Clone() const
void ScAccessibleHeaderTextData::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpViewShell = nullptr;// invalid now
- mpDocSh = nullptr;
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- }
+ mpViewShell = nullptr;// invalid now
+ mpDocSh = nullptr;
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
}
}
@@ -1556,16 +1536,12 @@ ScAccessibleTextData* ScAccessibleNoteTextData::Clone() const
void ScAccessibleNoteTextData::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- mpViewShell = nullptr;// invalid now
- mpDocSh = nullptr;
- if (mpViewForwarder)
- mpViewForwarder->SetInvalid();
- }
+ mpViewShell = nullptr;// invalid now
+ mpDocSh = nullptr;
+ if (mpViewForwarder)
+ mpViewForwarder->SetInvalid();
}
}
@@ -1697,16 +1673,12 @@ ScAccessibleCsvTextData::~ScAccessibleCsvTextData()
void ScAccessibleCsvTextData::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if( nId == SFX_HINT_DYING )
- {
- mpWindow = nullptr;
- mpEditEngine = nullptr;
- if (mpViewForwarder.get())
- mpViewForwarder->SetInvalid();
- }
+ mpWindow = nullptr;
+ mpEditEngine = nullptr;
+ if (mpViewForwarder.get())
+ mpViewForwarder->SetInvalid();
}
ScAccessibleTextData::Notify( rBC, rHint );
}
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index cd15f3d5c116..996264dd8c72 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -2203,7 +2203,7 @@ void ScPosWnd::Notify( SfxBroadcaster&, const SfxHint& rHint )
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if ( pSimpleHint )
{
- sal_uLong nHintId = pSimpleHint->GetId();
+ const sal_uInt32 nHintId = pSimpleHint->GetId();
if ( nHintId == SC_HINT_AREAS_CHANGED || nHintId == SC_HINT_NAVIGATOR_UPDATEALL)
FillRangeNames();
}
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index 98e2bacadca1..0b39678594ff 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -318,14 +318,10 @@ void ScModule::ConfigurationChanged( utl::ConfigurationBroadcaster* p, sal_uInt3
void ScModule::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DEINITIALIZING )
{
- sal_uLong nHintId = pSimpleHint->GetId();
- if ( nHintId == SFX_HINT_DEINITIALIZING )
- {
- // ConfigItems must be removed before ConfigManager
- DeleteCfg();
- }
+ // ConfigItems must be removed before ConfigManager
+ DeleteCfg();
}
}
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index b9da5dd32918..410ccabb30b4 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -620,8 +620,7 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
if ( dynamic_cast<const SfxSimpleHint*>(&rHint) ) // Without parameter
{
- sal_uLong nSlot = static_cast<const SfxSimpleHint&>(rHint).GetId();
- switch ( nSlot )
+ switch ( static_cast<const SfxSimpleHint&>(rHint).GetId() )
{
case SFX_HINT_TITLECHANGED:
aDocument.SetName( SfxShell::GetName() );
diff --git a/sc/source/ui/docshell/servobj.cxx b/sc/source/ui/docshell/servobj.cxx
index 6cb3fa982890..2c215dcf2dd0 100644
--- a/sc/source/ui/docshell/servobj.cxx
+++ b/sc/source/ui/docshell/servobj.cxx
@@ -239,8 +239,7 @@ void ScServerObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
}
else if (const SfxSimpleHint *pSplHint = dynamic_cast<const SfxSimpleHint*>(&rHint))
{
- sal_uLong nId = pSplHint->GetId();
- if (nId == SFX_HINT_DYING)
+ if (pSplHint->GetId() == SFX_HINT_DYING)
{
// If the range is being deleted, listening must be restarted
// after the deletion is complete (done in GetData)
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx
index 2c1f1608cd7f..bc9e495ec173 100644
--- a/sc/source/ui/navipi/navipi.cxx
+++ b/sc/source/ui/navipi/navipi.cxx
@@ -823,7 +823,7 @@ void ScNavigatorDlg::Notify( SfxBroadcaster&, const SfxHint& rHint )
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>( &rHint );
if ( pSimpleHint )
{
- sal_uLong nHintId = pSimpleHint->GetId();
+ const sal_uInt32 nHintId = pSimpleHint->GetId();
if ( nHintId == SC_HINT_DOCNAME_CHANGED )
{
diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx
index 3bf6646b5341..6d2dd3fdb39a 100644
--- a/sc/source/ui/unoobj/cellsuno.cxx
+++ b/sc/source/ui/unoobj/cellsuno.cxx
@@ -1598,7 +1598,7 @@ void ScCellRangesBase::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
+ const sal_uInt32 nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
if ( nId == SFX_HINT_DYING )
{
ForgetCurrentAttrs();
@@ -9418,7 +9418,7 @@ void ScCellFormatsEnumeration::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
+ const sal_uInt32 nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
if ( nId == SFX_HINT_DYING )
{
pDocShell = nullptr; // ungueltig geworden
@@ -9481,8 +9481,7 @@ void ScUniqueCellFormatsObj::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
- if ( nId == SFX_HINT_DYING )
+ if ( static_cast<const SfxSimpleHint&>(rHint).GetId() == SFX_HINT_DYING )
pDocShell = nullptr; // ungueltig geworden
}
}
@@ -9739,8 +9738,7 @@ void ScUniqueCellFormatsEnumeration::Notify( SfxBroadcaster&, const SfxHint& rHi
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
- if ( nId == SFX_HINT_DYING )
+ if ( static_cast<const SfxSimpleHint&>(rHint).GetId() == SFX_HINT_DYING )
pDocShell = nullptr; // ungueltig geworden
}
}
diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx
index deb144f19c3c..6884339c62d8 100644
--- a/sc/source/ui/unoobj/chart2uno.cxx
+++ b/sc/source/ui/unoobj/chart2uno.cxx
@@ -2806,7 +2806,7 @@ void ScChart2DataSequence::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if ( pSimpleHint )
{
- sal_uLong nId = pSimpleHint->GetId();
+ const sal_uInt32 nId = pSimpleHint->GetId();
if ( nId ==SFX_HINT_DYING )
{
m_pDocument = nullptr;
diff --git a/sc/source/ui/unoobj/datauno.cxx b/sc/source/ui/unoobj/datauno.cxx
index ab7486db7d02..70921f106245 100644
--- a/sc/source/ui/unoobj/datauno.cxx
+++ b/sc/source/ui/unoobj/datauno.cxx
@@ -991,13 +991,9 @@ ScFilterDescriptorBase::~ScFilterDescriptorBase()
void ScFilterDescriptorBase::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
- if ( pSimpleHint )
+ if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- sal_uLong nId = pSimpleHint->GetId();
- if ( nId == SFX_HINT_DYING )
- {
- pDocSh = nullptr; // invalid
- }
+ pDocSh = nullptr; // invalid
}
}
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 0ab3f4fa0aad..3a1c0a28c759 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -1088,7 +1088,7 @@ void ScModelObj::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if ( pSimpleHint )
{
- sal_uLong nId = pSimpleHint->GetId();
+ const sal_uInt32 nId = pSimpleHint->GetId();
if ( nId == SFX_HINT_DYING )
{
pDocShell = nullptr; // has become invalid
diff --git a/sc/source/ui/unoobj/editsrc.cxx b/sc/source/ui/unoobj/editsrc.cxx
index 219d74b7b559..d52b7730d522 100644
--- a/sc/source/ui/unoobj/editsrc.cxx
+++ b/sc/source/ui/unoobj/editsrc.cxx
@@ -202,7 +202,7 @@ void ScAnnotationEditSource::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
+ const sal_uInt32 nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
if ( nId == SFX_HINT_DYING )
{
pDocShell = nullptr; // ungueltig geworden
diff --git a/sc/source/ui/unoobj/textuno.cxx b/sc/source/ui/unoobj/textuno.cxx
index 736e96140b3f..3758fe10c51b 100644
--- a/sc/source/ui/unoobj/textuno.cxx
+++ b/sc/source/ui/unoobj/textuno.cxx
@@ -1029,7 +1029,7 @@ void ScCellTextData::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) )
{
- sal_uLong nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
+ const sal_uInt32 nId = static_cast<const SfxSimpleHint&>(rHint).GetId();
if ( nId == SFX_HINT_DYING )
{
pDocShell = nullptr; // invalid now
diff --git a/sc/source/ui/view/prevwsh2.cxx b/sc/source/ui/view/prevwsh2.cxx
index 10edc68cbc07..0b8af5dd7ad1 100644
--- a/sc/source/ui/view/prevwsh2.cxx
+++ b/sc/source/ui/view/prevwsh2.cxx
@@ -32,8 +32,7 @@ void ScPreviewShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
if (dynamic_cast<const SfxSimpleHint*>(&rHint))
{
- sal_uLong nSlot = static_cast<const SfxSimpleHint&>(rHint).GetId();
- switch ( nSlot )
+ switch ( static_cast<const SfxSimpleHint&>(rHint).GetId() )
{
case FID_DATACHANGED:
case SID_SCPRINTOPTIONS:
diff --git a/sc/source/ui/view/tabvwsh5.cxx b/sc/source/ui/view/tabvwsh5.cxx
index 9ccfb503b872..674dc6544e48 100644
--- a/sc/source/ui/view/tabvwsh5.cxx
+++ b/sc/source/ui/view/tabvwsh5.cxx
@@ -44,7 +44,7 @@ void ScTabViewShell::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
if (dynamic_cast<const SfxSimpleHint*>(&rHint)) // ohne Parameter
{
- sal_uLong nSlot = static_cast<const SfxSimpleHint&>(rHint).GetId();
+ const sal_uInt32 nSlot = static_cast<const SfxSimpleHint&>(rHint).GetId();
switch ( nSlot )
{
case FID_DATACHANGED: