diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-01-18 21:30:43 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-01-20 09:06:51 +0100 |
commit | 42a53497708e8b3b9b2d93bd39ac782fc185ac3e (patch) | |
tree | 288a49e85d66efd0006c5a6b161f893d3f14da6c /sfx2/source/appl | |
parent | 6812daf27117041eb02709291f506136259df264 (diff) |
Some more loplugin:cstylecast: sfx2
Change-Id: I19f3ce00e5e19dd34db2d92cae1b532d3c3eae6a
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r-- | sfx2/source/appl/app.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/appl/appinit.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/appl/appserv.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/appl/appuno.cxx | 44 | ||||
-rw-r--r-- | sfx2/source/appl/impldde.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/appl/lnkbase2.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/appl/shutdowniconunx.cxx | 4 |
7 files changed, 30 insertions, 30 deletions
diff --git a/sfx2/source/appl/app.cxx b/sfx2/source/appl/app.cxx index 5b8ff78ddd8e..7073ef95de39 100644 --- a/sfx2/source/appl/app.cxx +++ b/sfx2/source/appl/app.cxx @@ -494,7 +494,7 @@ IMPL_LINK( SfxApplication, GlobalBasicErrorHdl_Impl, StarBASIC*, pStarBasic ) aMod.loadRelative(&thisModule, SVLIBRARY("basctl"), 0); // get symbol - basicide_handle_basic_error pSymbol = (basicide_handle_basic_error) aMod.getFunctionSymbol("basicide_handle_basic_error"); + basicide_handle_basic_error pSymbol = reinterpret_cast<basicide_handle_basic_error>(aMod.getFunctionSymbol("basicide_handle_basic_error")); aMod.release(); @@ -592,7 +592,7 @@ void SfxApplication::MacroOrganizer( sal_Int16 nTabId ) aMod.loadRelative(&thisModule, SVLIBRARY("basctl"), 0); // get symbol - basicide_macro_organizer pSymbol = (basicide_macro_organizer) aMod.getFunctionSymbol("basicide_macro_organizer"); + basicide_macro_organizer pSymbol = reinterpret_cast<basicide_macro_organizer>(aMod.getFunctionSymbol("basicide_macro_organizer")); SAL_WARN_IF(!pSymbol, "sfx.doc", "SfxApplication::MacroOrganizer, no symbol!"); if (!pSymbol) diff --git a/sfx2/source/appl/appinit.cxx b/sfx2/source/appl/appinit.cxx index 2c64e342fd54..9580a6433044 100644 --- a/sfx2/source/appl/appinit.cxx +++ b/sfx2/source/appl/appinit.cxx @@ -185,7 +185,7 @@ OUString GetSpecialCharsForEdit(vcl::Window* pParent, const vcl::Font& rFont) // get symbol OUString aSymbol( "GetSpecialCharsForEdit" ); - pfunc_getSpecialCharsForEdit = (PFunc_getSpecialCharsForEdit)aMod.getFunctionSymbol(aSymbol); + pfunc_getSpecialCharsForEdit = reinterpret_cast<PFunc_getSpecialCharsForEdit>(aMod.getFunctionSymbol(aSymbol)); DBG_ASSERT( pfunc_getSpecialCharsForEdit, "GetSpecialCharsForEdit() not found!" ); aMod.release(); #else diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index 84de443c619e..9256ea270966 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -853,7 +853,7 @@ OUString ChooseMacro( const Reference< XModel >& rxLimitToDocument, bool bChoose aMod.loadRelative(&thisModule, SVLIBRARY("basctl"), 0); // get symbol - basicide_choose_macro pSymbol = (basicide_choose_macro) aMod.getFunctionSymbol("basicide_choose_macro"); + basicide_choose_macro pSymbol = reinterpret_cast<basicide_choose_macro>(aMod.getFunctionSymbol("basicide_choose_macro")); SAL_WARN_IF(!pSymbol, "sfx.doc", "SfxApplication::MacroOrganizer, no symbol!"); if (!pSymbol) return OUString(); diff --git a/sfx2/source/appl/appuno.cxx b/sfx2/source/appl/appuno.cxx index 01b950d46202..a64ec0369229 100644 --- a/sfx2/source/appl/appuno.cxx +++ b/sfx2/source/appl/appuno.cxx @@ -79,28 +79,28 @@ using namespace ::com::sun::star::io; // needs to be converted to a better data structure SfxFormalArgument aFormalArgs[] = { - { (const SfxType*) &aSfxStringItem_Impl, "SuggestedSaveAsName", SID_DEFAULTFILENAME }, - { (const SfxType*) &aSfxStringItem_Impl, "SuggestedSaveAsDir", SID_DEFAULTFILEPATH }, - { (const SfxType*) &aSfxStringItem_Impl, "VersionAuthor", SID_DOCINFO_AUTHOR }, - { (const SfxType*) &aSfxStringItem_Impl, "VersionComment", SID_DOCINFO_COMMENTS }, - { (const SfxType*) &aSfxBoolItem_Impl, "VersionMajor", SID_DOCINFO_MAJOR }, - { (const SfxType*) &aSfxStringItem_Impl, "FilterOptions", SID_FILE_FILTEROPTIONS }, - { (const SfxType*) &aSfxStringItem_Impl, "FilterName", SID_FILTER_NAME }, -// { (const SfxType*) &aSfxStringItem_Impl, "FileName", SID_FILE_NAME }, - { (const SfxType*) &aSfxStringItem_Impl, "URL", SID_FILE_NAME }, - { (const SfxType*) &aSfxStringItem_Impl, "OpenFlags", SID_OPTIONS }, - { (const SfxType*) &aSfxBoolItem_Impl, "Overwrite", SID_OVERWRITE }, - { (const SfxType*) &aSfxStringItem_Impl, "Password", SID_PASSWORD }, - { (const SfxType*) &aSfxBoolItem_Impl, "PasswordInteraction", SID_PASSWORDINTERACTION }, - { (const SfxType*) &aSfxStringItem_Impl, "Referer", SID_REFERER }, - { (const SfxType*) &aSfxBoolItem_Impl, "SaveTo", SID_SAVETO }, - { (const SfxType*) &aSfxStringItem_Impl, "TemplateName", SID_TEMPLATE_NAME }, - { (const SfxType*) &aSfxStringItem_Impl, "TemplateRegion", SID_TEMPLATE_REGIONNAME }, -// { (const SfxType*) &aSfxStringItem_Impl, "Region", SID_TEMPLATE_REGIONNAME }, -// { (const SfxType*) &aSfxStringItem_Impl, "Name", SID_TEMPLATE_NAME }, - { (const SfxType*) &aSfxBoolItem_Impl, "Unpacked", SID_UNPACK }, - { (const SfxType*) &aSfxInt16Item_Impl, "Version", SID_VERSION }, - { (const SfxType*) &aSfxBoolItem_Impl, "SaveACopy", SID_SAVEACOPYITEM }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "SuggestedSaveAsName", SID_DEFAULTFILENAME }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "SuggestedSaveAsDir", SID_DEFAULTFILEPATH }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "VersionAuthor", SID_DOCINFO_AUTHOR }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "VersionComment", SID_DOCINFO_COMMENTS }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "VersionMajor", SID_DOCINFO_MAJOR }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "FilterOptions", SID_FILE_FILTEROPTIONS }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "FilterName", SID_FILTER_NAME }, +// { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "FileName", SID_FILE_NAME }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "URL", SID_FILE_NAME }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "OpenFlags", SID_OPTIONS }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "Overwrite", SID_OVERWRITE }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "Password", SID_PASSWORD }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "PasswordInteraction", SID_PASSWORDINTERACTION }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "Referer", SID_REFERER }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "SaveTo", SID_SAVETO }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "TemplateName", SID_TEMPLATE_NAME }, + { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "TemplateRegion", SID_TEMPLATE_REGIONNAME }, +// { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "Region", SID_TEMPLATE_REGIONNAME }, +// { reinterpret_cast<SfxType*>(&aSfxStringItem_Impl), "Name", SID_TEMPLATE_NAME }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "Unpacked", SID_UNPACK }, + { reinterpret_cast<SfxType*>(&aSfxInt16Item_Impl), "Version", SID_VERSION }, + { reinterpret_cast<SfxType*>(&aSfxBoolItem_Impl), "SaveACopy", SID_SAVEACOPYITEM }, }; static sal_uInt16 nMediaArgsCount = sizeof(aFormalArgs) / sizeof (SfxFormalArgument); diff --git a/sfx2/source/appl/impldde.cxx b/sfx2/source/appl/impldde.cxx index 526a83932207..6f1cb5196bfb 100644 --- a/sfx2/source/appl/impldde.cxx +++ b/sfx2/source/appl/impldde.cxx @@ -327,7 +327,7 @@ IMPL_LINK( SvDDEObject, ImplGetDDEData, DdeData*, pData ) const sal_Char* p = (sal_Char*)( pData->operator const void*() ); long nLen = FORMAT_STRING == nFmt ? (p ? strlen( p ) : 0) : (long)*pData; - Sequence< sal_Int8 > aSeq( (const sal_Int8*)p, nLen ); + Sequence< sal_Int8 > aSeq( reinterpret_cast<const sal_Int8*>(p), nLen ); if( pGetData ) { *pGetData <<= aSeq; // Copy Data diff --git a/sfx2/source/appl/lnkbase2.cxx b/sfx2/source/appl/lnkbase2.cxx index ab22c6db2efe..9e1e8603d941 100644 --- a/sfx2/source/appl/lnkbase2.cxx +++ b/sfx2/source/appl/lnkbase2.cxx @@ -592,7 +592,7 @@ DdeData* ImplDdeItem::Get( sal_uIntPtr nFormat ) { if( aValue >>= aSeq ) { - aData = DdeData( (const char *)aSeq.getConstArray(), aSeq.getLength(), nFormat ); + aData = DdeData( aSeq.getConstArray(), aSeq.getLength(), nFormat ); bIsValidData = true; return &aData; diff --git a/sfx2/source/appl/shutdowniconunx.cxx b/sfx2/source/appl/shutdowniconunx.cxx index 199674f13909..8c85946d6a6c 100644 --- a/sfx2/source/appl/shutdowniconunx.cxx +++ b/sfx2/source/appl/shutdowniconunx.cxx @@ -155,7 +155,7 @@ static GdkPixbuf * ResIdToPixbuf( sal_uInt16 nResId ) GDK_COLORSPACE_RGB, sal_True, 8, aSize.Width(), aSize.Height(), aSize.Width() * 4, - (GdkPixbufDestroyNotify) g_free, + reinterpret_cast<GdkPixbufDestroyNotify>(g_free), NULL ); } @@ -412,7 +412,7 @@ void plugin_init_sys_tray() if (pFile) { if ((pMonitor = g_file_monitor_file(pFile, G_FILE_MONITOR_NONE, NULL, NULL))) - g_signal_connect(pMonitor, "changed", (GCallback)notify_file_changed, NULL); + g_signal_connect(pMonitor, "changed", reinterpret_cast<GCallback>(notify_file_changed), NULL); g_object_unref(pFile); } #endif |