summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2016-12-09 15:48:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2016-12-11 18:56:16 +0000
commit4ef9ccea6c4aa79cdc57dea52b47775c346696ec (patch)
treead3b4dd30484436c595990bd8994f94477b9492b /sfx2
parent4282ea67c2e90222f141df8213b06dfed09d4c85 (diff)
OSL_TRACE -> SAL in sfx2..svx
Change-Id: I78cf8058a5682baa3d7b00a25feeb2d28fb3e66e Reviewed-on: https://gerrit.libreoffice.org/31799 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/appl/appcfg.cxx13
-rw-r--r--sfx2/source/appl/appserv.cxx12
-rw-r--r--sfx2/source/control/dispatch.cxx18
-rw-r--r--sfx2/source/control/thumbnailview.cxx27
-rw-r--r--sfx2/source/control/thumbnailviewacc.cxx2
-rw-r--r--sfx2/source/dialog/splitwin.cxx26
-rw-r--r--sfx2/source/dialog/templdlg.cxx2
-rw-r--r--sfx2/source/doc/DocumentMetadataAccess.cxx26
-rw-r--r--sfx2/source/doc/Metadatable.cxx38
-rw-r--r--sfx2/source/doc/objmisc.cxx4
-rw-r--r--sfx2/source/sidebar/PanelTitleBar.cxx3
-rw-r--r--sfx2/source/sidebar/SidebarController.cxx2
-rw-r--r--sfx2/source/sidebar/Theme.cxx5
-rw-r--r--sfx2/source/view/frame2.cxx2
-rw-r--r--sfx2/source/view/viewprn.cxx6
15 files changed, 69 insertions, 117 deletions
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index 2bae14867dc3..9f9735c6b495 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -125,14 +125,7 @@ IMPL_LINK(SfxEventAsyncer_Impl, IdleHdl, Idle*, pAsyncIdle, void)
{
SfxObjectShellRef xRef( aHint.GetObjShell() );
pAsyncIdle->Stop();
-#ifdef DBG_UTIL
- if (!xRef.Is())
- {
- OStringBuffer aTmp("SfxEvent: ");
- aTmp.append(OUStringToOString(aHint.GetEventName(), RTL_TEXTENCODING_UTF8));
- OSL_TRACE( "%s", aTmp.getStr() );
- }
-#endif
+ SAL_INFO_IF(!xRef.Is(), "sfx", "SfxEvent: " << aHint.GetEventName());
SfxGetpApp()->Broadcast( aHint );
if ( xRef.Is() )
xRef->Broadcast( aHint );
@@ -860,9 +853,7 @@ void SfxApplication::NotifyEvent( const SfxEventHint& rEventHint, bool bSynchron
#ifdef DBG_UTIL
if (!pDoc)
{
- OStringBuffer aTmp("SfxEvent: ");
- aTmp.append(OUStringToOString(rEventHint.GetEventName(), RTL_TEXTENCODING_UTF8));
- OSL_TRACE( "%s", aTmp.getStr() );
+ SAL_INFO("sfx", "SfxEvent: " << rEventHint.GetEventName());
}
#endif
Broadcast(rEventHint);
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index de9b8af352f0..f880b01180a0 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -374,7 +374,7 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
if this dialog is closed by the user ...
So we ignore this request now and wait for a new user decision.
*/
- OSL_TRACE( "QueryExit => sal_False (DispatchLevel == %u)", Application::GetDispatchLevel() );
+ SAL_INFO("sfx", "QueryExit => sal_False, DispatchLevel == " << Application::GetDispatchLevel() );
return;
}
@@ -1482,7 +1482,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
case SID_MACROORGANIZER:
{
- OSL_TRACE("handling SID_MACROORGANIZER");
+ SAL_INFO("sfx", "handling SID_MACROORGANIZER");
const SfxItemSet* pArgs = rReq.GetArgs();
const SfxPoolItem* pItem;
sal_Int16 nTabId = 0;
@@ -1499,7 +1499,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
case SID_RUNMACRO:
{
SfxAbstractDialogFactory* pFact = SfxAbstractDialogFactory::Create();
- OSL_TRACE("SfxApplication::OfaExec_Impl: case ScriptOrg");
+ SAL_INFO("sfx", "SfxApplication::OfaExec_Impl: case ScriptOrg");
Reference< XFrame > xFrame;
const SfxItemSet* pIntSet = rReq.GetInternalArgs_Impl();
@@ -1552,7 +1552,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
case SID_SCRIPTORGANIZER:
{
SfxAbstractDialogFactory* pFact = SfxAbstractDialogFactory::Create();
- OSL_TRACE("SfxApplication::OfaExec_Impl: case ScriptOrg");
+ SAL_INFO("sfx", "SfxApplication::OfaExec_Impl: case ScriptOrg");
const SfxItemSet* pArgs = rReq.GetArgs();
const SfxPoolItem* pItem;
OUString aLanguage;
@@ -1562,7 +1562,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
}
OUString aLang( aLanguage );
- OSL_TRACE("SfxApplication::OfaExec_Impl: about to create dialog for: %s", OUStringToOString( aLang , RTL_TEXTENCODING_ASCII_US ).pData->buffer);
+ SAL_INFO("sfx", "SfxApplication::OfaExec_Impl: about to create dialog for: " << aLang);
// not sure about the vcl::Window*
VclPtr<VclAbstractDialog> pDlg = pFact->CreateSvxScriptOrgDialog( GetTopWindow(), aLanguage );
if( pDlg )
@@ -1572,7 +1572,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
}
else
{
- OSL_TRACE("no dialog!!!");
+ SAL_WARN("sfx", "no dialog!!!");
}
rReq.Done();
}
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index 96ae44a6f77a..807fcd9e981e 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -476,9 +476,7 @@ SfxDispatcher::SfxDispatcher(SfxViewFrame *pViewFrame)
SfxDispatcher::~SfxDispatcher()
{
#ifdef DBG_UTIL
- OStringBuffer sTemp("Delete Dispatcher ");
- sTemp.append(reinterpret_cast<sal_Int64>(this));
- OSL_TRACE("%s", sTemp.getStr());
+ SAL_WARN("sfx", "Delete Dispatcher " << reinterpret_cast<sal_Int64>(this));
DBG_ASSERT( !xImp->bActive, "deleting active Dispatcher" );
#endif
@@ -563,7 +561,7 @@ void SfxDispatcher::Pop(SfxShell& rShell, SfxDispatcherPopFlags nMode)
xImp->aToDoStack.push_front( SfxToDo_Impl(bPush, bDelete, bUntil, rShell) );
if (xImp->bFlushed)
{
- OSL_TRACE("Unflushed dispatcher!");
+ SAL_WARN("sfx", "Unflushed dispatcher!");
xImp->bFlushed = false;
xImp->bUpdated = false;
@@ -736,9 +734,7 @@ void SfxDispatcher::DoActivate_Impl(bool bMDI)
if ( bMDI )
{
#ifdef DBG_UTIL
- OStringBuffer sTemp("Activate Dispatcher ");
- sTemp.append(reinterpret_cast<sal_Int64>(this));
- OSL_TRACE("%s", sTemp.getStr());
+ SAL_WARN("sfx", "Activate Dispatcher " << reinterpret_cast<sal_Int64>(this));
DBG_ASSERT( !xImp->bActive, "Activation error" );
#endif
xImp->bActive = true;
@@ -753,9 +749,7 @@ void SfxDispatcher::DoActivate_Impl(bool bMDI)
else
{
#ifdef DBG_UTIL
- OStringBuffer sTemp("Non-MDI-Activate Dispatcher");
- sTemp.append(reinterpret_cast<sal_Int64>(this));
- OSL_TRACE("%s", sTemp.getStr());
+ SAL_WARN("sfx", "Non-MDI-Activate Dispatcher " << reinterpret_cast<sal_Int64>(this));
#endif
}
@@ -1507,7 +1501,7 @@ void SfxDispatcher::FlushImpl()
{
SFX_STACK(SfxDispatcher::FlushImpl);
- OSL_TRACE("Flushing dispatcher!");
+ SAL_INFO("sfx", "Flushing dispatcher!");
xImp->aIdle.Stop();
@@ -1572,7 +1566,7 @@ void SfxDispatcher::FlushImpl()
xImp->bFlushing = false;
xImp->bUpdated = false; // not only when bModify, if Doc/Template-Config
xImp->bFlushed = true;
- OSL_TRACE("Successfully flushed dispatcher!");
+ SAL_INFO("sfx", "Successfully flushed dispatcher!");
//fdo#70703 FlushImpl may call back into itself so use aToDoCopyStack to talk
//to outer levels of ourself. If DoActivate_Impl/DoDeactivate_Impl deletes
diff --git a/sfx2/source/control/thumbnailview.cxx b/sfx2/source/control/thumbnailview.cxx
index 9397c2a31d6e..4eabf1227fb3 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -1265,12 +1265,9 @@ BitmapEx ThumbnailView::readThumbnail(const OUString &msURL)
}
catch (const uno::Exception& rException)
{
- OSL_TRACE (
- "caught exception while trying to access Thumbnail/thumbnail.png of %s: %s",
- OUStringToOString(msURL,
- RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(rException.Message,
- RTL_TEXTENCODING_UTF8).getStr());
+ SAL_WARN("sfx",
+ "caught exception while trying to access Thumbnail/thumbnail.png of "
+ << msURL << ": " << rException.Message);
}
try
@@ -1295,22 +1292,16 @@ BitmapEx ThumbnailView::readThumbnail(const OUString &msURL)
}
catch (const uno::Exception& rException)
{
- OSL_TRACE (
- "caught exception while trying to access Thumbnails/thumbnail.png of %s: %s",
- OUStringToOString(msURL,
- RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(rException.Message,
- RTL_TEXTENCODING_UTF8).getStr());
+ SAL_WARN("sfx",
+ "caught exception while trying to access Thumbnails/thumbnail.png of "
+ << msURL << ": " << rException.Message);
}
}
catch (const uno::Exception& rException)
{
- OSL_TRACE (
- "caught exception while trying to access tuhmbnail of %s: %s",
- OUStringToOString(msURL,
- RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(rException.Message,
- RTL_TEXTENCODING_UTF8).getStr());
+ SAL_WARN("sfx",
+ "caught exception while trying to access tuhmbnail of "
+ << msURL << ": " << rException.Message);
}
// Extract the image from the stream.
diff --git a/sfx2/source/control/thumbnailviewacc.cxx b/sfx2/source/control/thumbnailviewacc.cxx
index 12b12d74eeb6..56f4c0f4069e 100644
--- a/sfx2/source/control/thumbnailviewacc.cxx
+++ b/sfx2/source/control/thumbnailviewacc.cxx
@@ -585,7 +585,7 @@ void ThumbnailViewAcc::ThrowIfDisposed()
{
if (rBHelper.bDisposed || rBHelper.bInDispose)
{
- OSL_TRACE ("Calling disposed object. Throwing exception:");
+ SAL_WARN("sfx", "Calling disposed object. Throwing exception:");
throw lang::DisposedException (
OUString("object has been already disposed"),
static_cast<uno::XWeak*>(this));
diff --git a/sfx2/source/dialog/splitwin.cxx b/sfx2/source/dialog/splitwin.cxx
index 95b12bd095f5..2409baade4db 100644
--- a/sfx2/source/dialog/splitwin.cxx
+++ b/sfx2/source/dialog/splitwin.cxx
@@ -722,7 +722,7 @@ void SfxSplitWindow::InsertWindow_Impl( SfxDock_Impl* pDock,
pEmptyWin->bFadeIn = false;
SetPinned_Impl( false );
pEmptyWin->Actualize();
- OSL_TRACE( "SfxSplitWindow::InsertWindow_Impl - registering empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::InsertWindow_Impl - registering empty Splitwindow" );
pWorkWin->RegisterChild_Impl( *GetSplitWindow(), eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
pWorkWin->ArrangeChildren_Impl();
if ( bFadeIn )
@@ -736,11 +736,11 @@ void SfxSplitWindow::InsertWindow_Impl( SfxDock_Impl* pDock,
#ifdef DBG_UTIL
if ( !bPinned || !pEmptyWin->bFadeIn )
{
- OSL_TRACE( "SfxSplitWindow::InsertWindow_Impl - registering empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::InsertWindow_Impl - registering empty Splitwindow" );
}
else
{
- OSL_TRACE( "SfxSplitWindow::InsertWindow_Impl - registering real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::InsertWindow_Impl - registering real Splitwindow" );
}
#endif
pWorkWin->RegisterChild_Impl( *GetSplitWindow(), eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
@@ -804,11 +804,11 @@ void SfxSplitWindow::RemoveWindow( SfxDockingWindow* pDockWin, bool bHide )
#ifdef DBG_UTIL
if ( !bPinned || !pEmptyWin->bFadeIn )
{
- OSL_TRACE( "SfxSplitWindow::RemoveWindow - releasing empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::RemoveWindow - releasing empty Splitwindow" );
}
else
{
- OSL_TRACE( "SfxSplitWindow::RemoveWindow - releasing real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::RemoveWindow - releasing real Splitwindow" );
}
#endif
pWorkWin->ReleaseChild_Impl( *GetSplitWindow() );
@@ -1063,11 +1063,11 @@ void SfxSplitWindow::SetPinned_Impl( bool bOn )
if ( pEmptyWin->bFadeIn )
{
// Unregister replacement windows
- OSL_TRACE( "SfxSplitWindow::SetPinned_Impl - releasing real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetPinned_Impl - releasing real Splitwindow" );
pWorkWin->ReleaseChild_Impl( *this );
Hide();
pEmptyWin->Actualize();
- OSL_TRACE( "SfxSplitWindow::SetPinned_Impl - registering empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetPinned_Impl - registering empty Splitwindow" );
pWorkWin->RegisterChild_Impl( *pEmptyWin, eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
}
@@ -1089,10 +1089,10 @@ void SfxSplitWindow::SetPinned_Impl( bool bOn )
if ( pEmptyWin->bFadeIn )
{
// Unregister replacement windows
- OSL_TRACE( "SfxSplitWindow::SetPinned_Impl - releasing empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetPinned_Impl - releasing empty Splitwindow" );
pWorkWin->ReleaseChild_Impl( *pEmptyWin );
pEmptyWin->Hide();
- OSL_TRACE( "SfxSplitWindow::SetPinned_Impl - registering real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetPinned_Impl - registering real Splitwindow" );
pWorkWin->RegisterChild_Impl( *this, eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
}
}
@@ -1122,10 +1122,10 @@ void SfxSplitWindow::SetFadeIn_Impl( bool bOn )
}
else
{
- OSL_TRACE( "SfxSplitWindow::SetFadeIn_Impl - releasing empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetFadeIn_Impl - releasing empty Splitwindow" );
pWorkWin->ReleaseChild_Impl( *pEmptyWin );
pEmptyWin->Hide();
- OSL_TRACE( "SfxSplitWindow::SetFadeIn_Impl - registering real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetFadeIn_Impl - registering real Splitwindow" );
pWorkWin->RegisterChild_Impl( *this, eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
pWorkWin->ArrangeChildren_Impl();
pWorkWin->ShowChildren_Impl();
@@ -1138,11 +1138,11 @@ void SfxSplitWindow::SetFadeIn_Impl( bool bOn )
if ( !IsFloatingMode() )
{
// The window is not "floating", should be hidden
- OSL_TRACE( "SfxSplitWindow::SetFadeIn_Impl - releasing real Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetFadeIn_Impl - releasing real Splitwindow" );
pWorkWin->ReleaseChild_Impl( *this );
Hide();
pEmptyWin->Actualize();
- OSL_TRACE( "SfxSplitWindow::SetFadeIn_Impl - registering empty Splitwindow" );
+ SAL_INFO("sfx", "SfxSplitWindow::SetFadeIn_Impl - registering empty Splitwindow" );
pWorkWin->RegisterChild_Impl( *pEmptyWin, eAlign, true )->nVisible = SfxChildVisibility::VISIBLE;
pWorkWin->ArrangeChildren_Impl();
pWorkWin->ShowChildren_Impl();
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index d84f7300d5a0..2d8d527b763d 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1750,7 +1750,7 @@ static OUString getModuleIdentifier( const Reference< XModuleManager2 >& i_xModM
}
catch ( css::frame::UnknownModuleException& )
{
- OSL_TRACE( "getModuleIdentifier(): unknown module" );
+ SAL_WARN("sfx", "getModuleIdentifier(): unknown module" );
}
catch ( Exception& )
{
diff --git a/sfx2/source/doc/DocumentMetadataAccess.cxx b/sfx2/source/doc/DocumentMetadataAccess.cxx
index 065ae5aeda0f..1c8f8f8c128a 100644
--- a/sfx2/source/doc/DocumentMetadataAccess.cxx
+++ b/sfx2/source/doc/DocumentMetadataAccess.cxx
@@ -496,7 +496,7 @@ collectFilesFromStorage(uno::Reference<embed::XStorage> const& i_xStorage,
o_rFiles.insert(i_Path + styles);
}
} catch (const uno::Exception &) {
- OSL_TRACE("collectFilesFromStorage: exception?");
+ SAL_WARN("sfx", "collectFilesFromStorage: exception?");
}
}
@@ -543,8 +543,7 @@ readStream(struct DocumentMetadataAccess_Impl & i_rImpl,
utl::MediaDescriptor::PROP_MEDIATYPE() )
>>= mimeType;
if (mimeType.startsWith(s_odfmime)) {
- OSL_TRACE("readStream: "
- "refusing to recurse into embedded document");
+ SAL_WARN("sfx", "readStream: refusing to recurse into embedded document");
return;
}
} catch (const uno::Exception &) { }
@@ -645,8 +644,7 @@ writeStream(struct DocumentMetadataAccess_Impl & i_rImpl,
utl::MediaDescriptor::PROP_MEDIATYPE() )
>>= mimeType;
if (mimeType.startsWith(s_odfmime)) {
- OSL_TRACE("writeStream: "
- "refusing to recurse into embedded document");
+ SAL_WARN("sfx", "writeStream: refusing to recurse into embedded document");
return;
}
} catch (const uno::Exception &) { }
@@ -1104,15 +1102,12 @@ throw (uno::RuntimeException, lang::IllegalArgumentException,
it != parts.end(); ++it) {
const OUString name((*it)->getStringValue());
if (!name.match(baseURI)) {
- OSL_TRACE("loadMetadataFromStorage: graph not in document: %s",
- OUStringToOString(name, RTL_TEXTENCODING_UTF8)
- .getStr());
+ SAL_WARN("sfx", "loadMetadataFromStorage: graph not in document: " << name);
continue;
}
const OUString relName( name.copy(len) );
if (relName == s_manifest) {
- OSL_TRACE("loadMetadataFromStorage: "
- "found ourselves a recursive manifest!");
+ SAL_WARN("sfx", "loadMetadataFromStorage: found ourselves a recursive manifest!");
continue;
}
// remove found items from StgFiles
@@ -1136,8 +1131,7 @@ throw (uno::RuntimeException, lang::IllegalArgumentException,
xStylesFile.get());
}
} else if (isReservedFile(relName)) {
- OSL_TRACE("loadMetadataFromStorage: "
- "reserved file name in manifest");
+ SAL_WARN("sfx", "loadMetadataFromStorage: reserved file name in manifest");
} else {
if (isPartOfType(*m_pImpl, *it, xMetadataFile)) {
MfstMetadataFiles.push_back(relName);
@@ -1197,9 +1191,7 @@ throw (uno::RuntimeException, lang::IllegalArgumentException,
const uno::Reference<rdf::XURI> xName(graphs[i]);
const OUString name(xName->getStringValue());
if (!name.match(baseURI)) {
- OSL_TRACE("storeMetadataToStorage: graph not in document: %s",
- OUStringToOString(name, RTL_TEXTENCODING_UTF8)
- .getStr());
+ SAL_WARN("sfx", "storeMetadataToStorage: graph not in document: " << name);
continue;
}
const OUString relName( name.copy(len) );
@@ -1207,9 +1199,7 @@ throw (uno::RuntimeException, lang::IllegalArgumentException,
continue;
}
if (!isFileNameValid(relName) || isReservedFile(relName)) {
- OSL_TRACE("storeMetadataToStorage: invalid file name: %s",
- OUStringToOString(relName, RTL_TEXTENCODING_UTF8)
- .getStr());
+ SAL_WARN("sfx", "storeMetadataToStorage: invalid file name: " << relName);
continue;
}
try {
diff --git a/sfx2/source/doc/Metadatable.cxx b/sfx2/source/doc/Metadatable.cxx
index 4c678bac2285..cd379584eb3e 100644
--- a/sfx2/source/doc/Metadatable.cxx
+++ b/sfx2/source/doc/Metadatable.cxx
@@ -654,9 +654,7 @@ bool
XmlIdRegistryDocument::TryRegisterMetadatable(Metadatable & i_rObject,
OUString const& i_rStreamName, OUString const& i_rIdref)
{
- OSL_TRACE("TryRegisterMetadatable: %p (%s#%s)\n", &i_rObject,
- OUStringToOString(i_rStreamName, RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(i_rIdref, RTL_TEXTENCODING_UTF8).getStr());
+ SAL_INFO("sfx", "TryRegisterMetadatable: " << &i_rObject << " (" << i_rStreamName << "#" << i_rIdref << ")");
OSL_ENSURE(!dynamic_cast<MetadatableUndo*>(&i_rObject),
"TryRegisterMetadatable called for MetadatableUndo?");
@@ -705,7 +703,7 @@ XmlIdRegistryDocument::TryRegisterMetadatable(Metadatable & i_rObject,
void
XmlIdRegistryDocument::RegisterMetadatableAndCreateID(Metadatable & i_rObject)
{
- OSL_TRACE("RegisterMetadatableAndCreateID: %p", &i_rObject);
+ SAL_INFO("sfx", "RegisterMetadatableAndCreateID: " << &i_rObject);
OSL_ENSURE(!dynamic_cast<MetadatableUndo*>(&i_rObject),
"RegisterMetadatableAndCreateID called for MetadatableUndo?");
@@ -748,7 +746,7 @@ XmlIdRegistryDocument::RegisterMetadatableAndCreateID(Metadatable & i_rObject)
void XmlIdRegistryDocument::UnregisterMetadatable(const Metadatable& i_rObject)
{
- OSL_TRACE("UnregisterMetadatable: %p", &i_rObject);
+ SAL_INFO("sfx", "UnregisterMetadatable: " << &i_rObject);
OUString path;
OUString idref;
@@ -766,7 +764,7 @@ void XmlIdRegistryDocument::UnregisterMetadatable(const Metadatable& i_rObject)
void XmlIdRegistryDocument::RemoveXmlIdForElement(const Metadatable& i_rObject)
{
- OSL_TRACE("RemoveXmlIdForElement: %p", &i_rObject);
+ SAL_INFO("sfx", "RemoveXmlIdForElement: " << &i_rObject);
const XmlIdReverseMap_t::iterator iter(
m_pImpl->m_XmlIdReverseMap.find(&i_rObject) );
@@ -782,8 +780,7 @@ void XmlIdRegistryDocument::RemoveXmlIdForElement(const Metadatable& i_rObject)
void XmlIdRegistryDocument::RegisterCopy(Metadatable const& i_rSource,
Metadatable & i_rCopy, const bool i_bCopyPrecedesSource)
{
- OSL_TRACE("RegisterCopy: %p -> %p (%d)\n",
- &i_rSource, &i_rCopy, i_bCopyPrecedesSource);
+ SAL_INFO("sfx", "RegisterCopy: " << &i_rSource << " -> " << &i_rCopy << " (" << i_bCopyPrecedesSource << ")");
// potential sources: clipboard, undo array, splitNode
// assumption: stream change can only happen via clipboard, and is handled
@@ -825,7 +822,7 @@ void XmlIdRegistryDocument::RegisterCopy(Metadatable const& i_rSource,
std::shared_ptr<MetadatableUndo>
XmlIdRegistryDocument::CreateUndo(Metadatable const& i_rObject)
{
- OSL_TRACE("CreateUndo: %p", &i_rObject);
+ SAL_INFO("sfx", "CreateUndo: " << &i_rObject);
return std::make_shared<MetadatableUndo>(
i_rObject.IsInContent() );
@@ -852,7 +849,7 @@ void
XmlIdRegistryDocument::JoinMetadatables(
Metadatable & i_rMerged, Metadatable const & i_rOther)
{
- OSL_TRACE("JoinMetadatables: %p <- %p", &i_rMerged, &i_rOther);
+ SAL_INFO("sfx", "JoinMetadatables: " << &i_rMerged << " <- " << &i_rOther);
bool mergedOwnsRef;
OUString path;
@@ -1070,9 +1067,7 @@ bool
XmlIdRegistryClipboard::TryRegisterMetadatable(Metadatable & i_rObject,
OUString const& i_rStreamName, OUString const& i_rIdref)
{
- OSL_TRACE("TryRegisterMetadatable: %p (%s#%s)\n", &i_rObject,
- OUStringToOString(i_rStreamName, RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(i_rIdref, RTL_TEXTENCODING_UTF8).getStr());
+ SAL_INFO("sfx", "TryRegisterMetadatable: " << &i_rObject << " (" << i_rStreamName << "#" << i_rIdref <<")");
OSL_ENSURE(!dynamic_cast<MetadatableUndo*>(&i_rObject),
"TryRegisterMetadatable called for MetadatableUndo?");
@@ -1122,7 +1117,7 @@ XmlIdRegistryClipboard::TryRegisterMetadatable(Metadatable & i_rObject,
void
XmlIdRegistryClipboard::RegisterMetadatableAndCreateID(Metadatable & i_rObject)
{
- OSL_TRACE("RegisterMetadatableAndCreateID: %p", &i_rObject);
+ SAL_INFO("sfx", "RegisterMetadatableAndCreateID: " << &i_rObject);
OSL_ENSURE(!dynamic_cast<MetadatableUndo*>(&i_rObject),
"RegisterMetadatableAndCreateID called for MetadatableUndo?");
@@ -1156,7 +1151,7 @@ XmlIdRegistryClipboard::RegisterMetadatableAndCreateID(Metadatable & i_rObject)
void XmlIdRegistryClipboard::UnregisterMetadatable(const Metadatable& i_rObject)
{
- OSL_TRACE("UnregisterMetadatable: %p", &i_rObject);
+ SAL_INFO("sfx", "UnregisterMetadatable: " << &i_rObject);
OUString path;
OUString idref;
@@ -1176,7 +1171,7 @@ void XmlIdRegistryClipboard::UnregisterMetadatable(const Metadatable& i_rObject)
void XmlIdRegistryClipboard::RemoveXmlIdForElement(const Metadatable& i_rObject)
{
- OSL_TRACE("RemoveXmlIdForElement: %p", &i_rObject);
+ SAL_INFO("sfx", "RemoveXmlIdForElement: " << &i_rObject);
ClipboardXmlIdReverseMap_t::iterator iter(
m_pImpl->m_XmlIdReverseMap.find(&i_rObject) );
@@ -1192,7 +1187,7 @@ void XmlIdRegistryClipboard::RemoveXmlIdForElement(const Metadatable& i_rObject)
std::shared_ptr<MetadatableClipboard>
XmlIdRegistryClipboard::CreateClipboard(const bool i_isInContent)
{
- OSL_TRACE("CreateClipboard:");
+ SAL_INFO("sfx", "CreateClipboard:");
return std::make_shared<MetadatableClipboard>(
i_isInContent );
@@ -1203,13 +1198,8 @@ XmlIdRegistryClipboard::RegisterCopyClipboard(Metadatable & i_rCopy,
beans::StringPair const & i_rReference,
const bool i_isLatent)
{
- OSL_TRACE("RegisterCopyClipboard: %p -> "/*"%p"*/"(%s#%s) (%d)\n",
- /*&i_rSource,*/ &i_rCopy,
- OUStringToOString(i_rReference.First,
- RTL_TEXTENCODING_UTF8).getStr(),
- OUStringToOString(i_rReference.Second,
- RTL_TEXTENCODING_UTF8).getStr(),
- i_isLatent);
+ SAL_INFO("sfx", "RegisterCopyClipboard: " << &i_rCopy
+ << " -> (" << i_rReference.First << "#" << i_rReference.Second << ") (" << i_isLatent << ")");
// N.B.: when copying to the clipboard, the selection is always inserted
// into the body, even if the source is a header/footer!
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx
index 4fc3f8212ef2..027e57b54d31 100644
--- a/sfx2/source/doc/objmisc.cxx
+++ b/sfx2/source/doc/objmisc.cxx
@@ -1425,7 +1425,7 @@ namespace
ErrCode SfxObjectShell::CallXScript( const Reference< XInterface >& _rxScriptContext, const OUString& _rScriptURL,
const Sequence< Any >& aParams, Any& aRet, Sequence< sal_Int16 >& aOutParamIndex, Sequence< Any >& aOutParam, bool bRaiseError, const css::uno::Any* pCaller )
{
- OSL_TRACE( "in CallXScript" );
+ SAL_INFO("sfx", "in CallXScript" );
ErrCode nErr = ERRCODE_NONE;
bool bIsDocumentScript = ( _rScriptURL.indexOf( "location=document" ) >= 0 );
@@ -1488,7 +1488,7 @@ ErrCode SfxObjectShell::CallXScript( const Reference< XInterface >& _rxScriptCon
}
}
- OSL_TRACE( "leaving CallXScript" );
+ SAL_INFO("sfx", "leaving CallXScript" );
return nErr;
}
diff --git a/sfx2/source/sidebar/PanelTitleBar.cxx b/sfx2/source/sidebar/PanelTitleBar.cxx
index d13dc740a93f..c52841cc0189 100644
--- a/sfx2/source/sidebar/PanelTitleBar.cxx
+++ b/sfx2/source/sidebar/PanelTitleBar.cxx
@@ -150,8 +150,7 @@ void PanelTitleBar::HandleToolBoxItemClick (const sal_uInt16 nItemIndex)
}
catch(Exception& rException)
{
- OSL_TRACE("caught exception: %s",
- OUStringToOString(rException.Message, RTL_TEXTENCODING_ASCII_US).getStr());
+ SAL_WARN("sfx", "caught exception: " << rException.Message);
}
}
}
diff --git a/sfx2/source/sidebar/SidebarController.cxx b/sfx2/source/sidebar/SidebarController.cxx
index cc11f07c3104..f52a3ff2380a 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -885,7 +885,7 @@ IMPL_LINK(SidebarController, WindowEventHandler, VclWindowEvent&, rEvent, void)
break;
case VclEventId::WindowPaint:
- OSL_TRACE("Paint");
+ SAL_INFO("sfx", "Paint");
break;
default:
diff --git a/sfx2/source/sidebar/Theme.cxx b/sfx2/source/sidebar/Theme.cxx
index 17f7b19eaff4..1b96d23c7879 100644
--- a/sfx2/source/sidebar/Theme.cxx
+++ b/sfx2/source/sidebar/Theme.cxx
@@ -337,10 +337,7 @@ void Theme::UpdateTheme()
}
catch(beans::UnknownPropertyException& rException)
{
- OSL_TRACE("unknown property: %s",
- OUStringToOString(
- rException.Message,
- RTL_TEXTENCODING_ASCII_US).getStr());
+ SAL_WARN("sfx", "unknown property: " << rException.Message);
OSL_ASSERT(false);
}
}
diff --git a/sfx2/source/view/frame2.cxx b/sfx2/source/view/frame2.cxx
index 91e9e6182028..0b6fb83f1e68 100644
--- a/sfx2/source/view/frame2.cxx
+++ b/sfx2/source/view/frame2.cxx
@@ -103,7 +103,7 @@ bool SfxFrameWindow_Impl::EventNotify( NotifyEvent& rNEvt )
{
if ( pView->GetViewShell() && !pView->GetViewShell()->GetUIActiveIPClient_Impl() && !pFrame->IsInPlace() )
{
- OSL_TRACE("SfxFrame: GotFocus");
+ SAL_INFO("sfx", "SfxFrame: GotFocus");
pView->MakeActive_Impl( false );
}
diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx
index b139f55e3e5e..e62577b81975 100644
--- a/sfx2/source/view/viewprn.cxx
+++ b/sfx2/source/view/viewprn.cxx
@@ -226,7 +226,7 @@ int SfxPrinterController::getPageCount() const
}
catch (lang::DisposedException &)
{
- OSL_TRACE("SfxPrinterController: document disposed while printing");
+ SAL_WARN("sfx", "SfxPrinterController: document disposed while printing");
const_cast<SfxPrinterController*>(this)->setJobState(
view::PrintableState_JOB_ABORTED);
}
@@ -251,7 +251,7 @@ Sequence< beans::PropertyValue > SfxPrinterController::getPageParameters( int i_
}
catch (lang::DisposedException &)
{
- OSL_TRACE("SfxPrinterController: document disposed while printing");
+ SAL_WARN("sfx", "SfxPrinterController: document disposed while printing");
const_cast<SfxPrinterController*>(this)->setJobState(
view::PrintableState_JOB_ABORTED);
}
@@ -276,7 +276,7 @@ void SfxPrinterController::printPage( int i_nPage ) const
}
catch (lang::DisposedException &)
{
- OSL_TRACE("SfxPrinterController: document disposed while printing");
+ SAL_WARN("sfx", "SfxPrinterController: document disposed while printing");
const_cast<SfxPrinterController*>(this)->setJobState(
view::PrintableState_JOB_ABORTED);
}