summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-12-05 18:05:10 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-12-05 18:05:10 +0100
commit5f2e9679b1a676d54c9efc8fd0c2dae25015cfd9 (patch)
treee9cd63a14df9d9eb0ff2f17a24f0efb0812a3798 /sc
parentc50d8bf596f527bb53b86dd04da652ed72f2c549 (diff)
loplugin:cstylecast, involving pointer to incomplete type
Change-Id: Ib256ed35a9ecb59a07ed31edec9bd8abb31a4610
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/table3.cxx5
-rw-r--r--sc/source/core/data/table6.cxx17
2 files changed, 12 insertions, 10 deletions
diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx
index 1a2a5182e620..edeeaeb025d7 100644
--- a/sc/source/core/data/table3.cxx
+++ b/sc/source/core/data/table3.cxx
@@ -59,6 +59,7 @@
#include <fstalgorithm.hxx>
#include <listenercontext.hxx>
#include <sharedformula.hxx>
+#include <stlsheet.hxx>
#include <refhint.hxx>
#include <listenerquery.hxx>
#include <bcaslot.hxx>
@@ -1812,8 +1813,8 @@ bool ScTable::DoSubTotals( ScSubTotalParam& rParam )
//! sortieren?
- ScStyleSheet* pStyle = (ScStyleSheet*) pDocument->GetStyleSheetPool()->Find(
- ScGlobal::GetRscString(STR_STYLENAME_RESULT), SFX_STYLE_FAMILY_PARA );
+ ScStyleSheet* pStyle = static_cast<ScStyleSheet*>(pDocument->GetStyleSheetPool()->Find(
+ ScGlobal::GetRscString(STR_STYLENAME_RESULT), SFX_STYLE_FAMILY_PARA ));
bool bSpaceLeft = true; // Erfolg beim Einfuegen?
diff --git a/sc/source/core/data/table6.cxx b/sc/source/core/data/table6.cxx
index c678680d5f40..697fa11ba7bc 100644
--- a/sc/source/core/data/table6.cxx
+++ b/sc/source/core/data/table6.cxx
@@ -28,6 +28,7 @@
#include "formulacell.hxx"
#include "document.hxx"
#include "stlpool.hxx"
+#include "stlsheet.hxx"
#include "markdata.hxx"
#include "editutil.hxx"
#include "detfunc.hxx"
@@ -520,9 +521,9 @@ bool ScTable::ReplaceAll(
bool ScTable::SearchStyle(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
const ScMarkData& rMark)
{
- const ScStyleSheet* pSearchStyle = (const ScStyleSheet*)
+ const ScStyleSheet* pSearchStyle = static_cast<const ScStyleSheet*>(
pDocument->GetStyleSheetPool()->Find(
- rSearchItem.GetSearchString(), SFX_STYLE_FAMILY_PARA );
+ rSearchItem.GetSearchString(), SFX_STYLE_FAMILY_PARA ));
SCsCOL nCol = rCol;
SCsROW nRow = rRow;
@@ -612,9 +613,9 @@ bool ScTable::ReplaceStyle(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW&
bRet = SearchStyle(rSearchItem, rCol, rRow, rMark);
if (bRet)
{
- const ScStyleSheet* pReplaceStyle = (const ScStyleSheet*)
+ const ScStyleSheet* pReplaceStyle = static_cast<const ScStyleSheet*>(
pDocument->GetStyleSheetPool()->Find(
- rSearchItem.GetReplaceString(), SFX_STYLE_FAMILY_PARA );
+ rSearchItem.GetReplaceString(), SFX_STYLE_FAMILY_PARA ));
if (pReplaceStyle)
ApplyStyle( rCol, rRow, *pReplaceStyle );
@@ -630,9 +631,9 @@ bool ScTable::ReplaceStyle(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW&
bool ScTable::SearchAllStyle(
const SvxSearchItem& rSearchItem, const ScMarkData& rMark, ScRangeList& rMatchedRanges)
{
- const ScStyleSheet* pSearchStyle = (const ScStyleSheet*)
+ const ScStyleSheet* pSearchStyle = static_cast<const ScStyleSheet*>(
pDocument->GetStyleSheetPool()->Find(
- rSearchItem.GetSearchString(), SFX_STYLE_FAMILY_PARA );
+ rSearchItem.GetSearchString(), SFX_STYLE_FAMILY_PARA ));
bool bSelect = rSearchItem.GetSelection();
bool bBack = rSearchItem.GetBackward();
bool bEverFound = false;
@@ -670,9 +671,9 @@ bool ScTable::ReplaceAllStyle(
bool bRet = SearchAllStyle(rSearchItem, rMark, rMatchedRanges);
if (bRet)
{
- const ScStyleSheet* pReplaceStyle = (const ScStyleSheet*)
+ const ScStyleSheet* pReplaceStyle = static_cast<const ScStyleSheet*>(
pDocument->GetStyleSheetPool()->Find(
- rSearchItem.GetReplaceString(), SFX_STYLE_FAMILY_PARA );
+ rSearchItem.GetReplaceString(), SFX_STYLE_FAMILY_PARA ));
if (pReplaceStyle)
{