summaryrefslogtreecommitdiff
path: root/sw/source/ui/misc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-03-31 13:17:08 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-03-31 13:17:08 +0200
commit4a69849e2fb50cbe3632209c28b9d638bbf878a9 (patch)
tree1204e22891cc1b8e566ad5aecf51212fe061442b /sw/source/ui/misc
parenta5d6cd83d7cac1fde630ac1211354242cbe4e085 (diff)
Reduce to static_cast any reinterpret_cast from void pointers
Change-Id: I83594c8b6cb1f317b55fe048111edd23f622e1ed
Diffstat (limited to 'sw/source/ui/misc')
-rw-r--r--sw/source/ui/misc/glossary.cxx12
-rw-r--r--sw/source/ui/misc/srtdlg.cxx2
2 files changed, 7 insertions, 7 deletions
diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx
index 4e398a8f83d4..ffecd29ab37a 100644
--- a/sw/source/ui/misc/glossary.cxx
+++ b/sw/source/ui/misc/glossary.cxx
@@ -257,7 +257,7 @@ IMPL_LINK( SwGlossaryDlg, GrpSelect, SvTreeListBox *, pBox )
{
OUString aName(pBox->GetEntryText(pEntry));
m_pNameED->SetText(aName);
- m_pShortNameEdit->SetText(*reinterpret_cast<OUString*>(pEntry->GetUserData()));
+ m_pShortNameEdit->SetText(*static_cast<OUString*>(pEntry->GetUserData()));
m_pInsertBtn->Enable( !bIsDocReadOnly);
ShowAutoText(::GetCurrGlosGroup(), m_pShortNameEdit->GetText());
}
@@ -325,7 +325,7 @@ SvTreeListEntry* SwGlossaryDlg::DoesBlockExist(const OUString& rBlock,
SvTreeListEntry* pChild = m_pCategoryBox->GetEntry( pEntry, i );
if (rBlock == m_pCategoryBox->GetEntryText(pChild) &&
(rShort.isEmpty() ||
- rShort==*reinterpret_cast<OUString*>(pChild->GetUserData()))
+ rShort==*static_cast<OUString*>(pChild->GetUserData()))
)
{
return pChild;
@@ -479,7 +479,7 @@ IMPL_LINK( SwGlossaryDlg, MenuHdl, Menu *, pMn )
SvTreeListEntry* pNewEntry = m_pCategoryBox->InsertEntry(
pNewNameDlg->GetNewName(), m_pCategoryBox->GetParent(pEntry));
pNewEntry->SetUserData(new OUString(pNewNameDlg->GetNewShort()));
- delete reinterpret_cast<OUString*>(pEntry->GetUserData());
+ delete static_cast<OUString*>(pEntry->GetUserData());
m_pCategoryBox->GetModel()->Remove(pEntry);
m_pCategoryBox->Select(pNewEntry);
m_pCategoryBox->MakeVisible(pNewEntry);
@@ -830,7 +830,7 @@ void SwGlTreeListBox::Clear()
while(pEntry)
{
if(GetParent(pEntry))
- delete reinterpret_cast<OUString*>(pEntry->GetUserData());
+ delete static_cast<OUString*>(pEntry->GetUserData());
else
delete static_cast<GroupUserData*>(pEntry->GetUserData());
pEntry = Next(pEntry);
@@ -877,7 +877,7 @@ void SwGlTreeListBox::RequestHelp( const HelpEvent& rHEvt )
}
}
else
- sMsg = *reinterpret_cast<OUString*>(pEntry->GetUserData());
+ sMsg = *static_cast<OUString*>(pEntry->GetUserData());
Help::ShowQuickHelp( this, aItemRect, sMsg,
QUICKHELP_LEFT|QUICKHELP_VCENTER );
}
@@ -968,7 +968,7 @@ TriState SwGlTreeListBox::NotifyCopyingOrMoving(
pDlg->pGlossaryHdl->SetCurGroup(sSourceGroup);
OUString sTitle(GetEntryText(pEntry));
- OUString sShortName(*reinterpret_cast<OUString*>(pEntry->GetUserData()));
+ OUString sShortName(*static_cast<OUString*>(pEntry->GetUserData()));
GroupUserData* pDestData = static_cast<GroupUserData*>(pDestParent->GetUserData());
OUString sDestName = pDestData->sGroupName
diff --git a/sw/source/ui/misc/srtdlg.cxx b/sw/source/ui/misc/srtdlg.cxx
index dba258bb5d58..3c58114764b1 100644
--- a/sw/source/ui/misc/srtdlg.cxx
+++ b/sw/source/ui/misc/srtdlg.cxx
@@ -73,7 +73,7 @@ static void lcl_ClearLstBoxAndDelUserData( ListBox& rLstBox )
const sal_Int32 nEnd = rLstBox.GetEntryCount();
for( sal_Int32 n = 0; n < nEnd; ++n )
{
- delete reinterpret_cast<OUString *>(rLstBox.GetEntryData( n ));
+ delete static_cast<OUString *>(rLstBox.GetEntryData( n ));
}
rLstBox.Clear();
}