diff options
author | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-08-29 21:00:18 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-08-29 21:00:18 -0400 |
commit | 63e3fb44178f9e00c0e8d37c957fd55643fa9c4a (patch) | |
tree | ae3bfc406b44a7f48bcd05dad897c186b9a979af /sc/source | |
parent | ac991693db02ec6ede3585ca6ae22f087fe7d48d (diff) |
String to rtl::OUString, and I forgot to commit the new headers.
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/ui/app/scmod.cxx | 18 | ||||
-rw-r--r-- | sc/source/ui/view/gridwin.cxx | 22 |
2 files changed, 20 insertions, 20 deletions
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx index 9b11facc2f6e..7932fca3b0f2 100644 --- a/sc/source/ui/app/scmod.cxx +++ b/sc/source/ui/app/scmod.cxx @@ -658,13 +658,12 @@ void ScModule::ResetDragObject() { mpDragData->pCellTransfer = NULL; mpDragData->pDrawTransfer = NULL; - - mpDragData->aLinkDoc.Erase(); - mpDragData->aLinkTable.Erase(); - mpDragData->aLinkArea.Erase(); mpDragData->pJumpLocalDoc = NULL; - mpDragData->aJumpTarget.Erase(); - mpDragData->aJumpText.Erase(); + mpDragData->aLinkDoc = rtl::OUString(); + mpDragData->aLinkTable = rtl::OUString(); + mpDragData->aLinkArea = rtl::OUString(); + mpDragData->aJumpTarget = rtl::OUString(); + mpDragData->aJumpText = rtl::OUString(); } const ScDragData& ScModule::GetDragData() const @@ -679,16 +678,17 @@ void ScModule::SetDragObject( ScTransferObj* pCellObj, ScDrawTransferObj* pDrawO mpDragData->pDrawTransfer = pDrawObj; } -void ScModule::SetDragLink( const String& rDoc, const String& rTab, const String& rArea ) +void ScModule::SetDragLink( + const rtl::OUString& rDoc, const rtl::OUString& rTab, const rtl::OUString& rArea ) { ResetDragObject(); - mpDragData->aLinkDoc = rDoc; mpDragData->aLinkTable = rTab; mpDragData->aLinkArea = rArea; } -void ScModule::SetDragJump( ScDocument* pLocalDoc, const String& rTarget, const String& rText ) +void ScModule::SetDragJump( + ScDocument* pLocalDoc, const rtl::OUString& rTarget, const rtl::OUString& rText ) { ResetDragObject(); diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx index d87cc2ee2244..305a68eda2aa 100644 --- a/sc/source/ui/view/gridwin.cxx +++ b/sc/source/ui/view/gridwin.cxx @@ -3488,17 +3488,17 @@ sal_Int8 ScGridWindow::AcceptDrop( const AcceptDropEvent& rEvt ) } else { - if ( rData.aLinkDoc.Len() ) + if ( !rData.aLinkDoc.isEmpty() ) { - String aThisName; + rtl::OUString aThisName; ScDocShell* pDocSh = pViewData->GetDocShell(); if (pDocSh && pDocSh->HasName()) aThisName = pDocSh->GetMedium()->GetName(); - if ( rData.aLinkDoc != aThisName ) + if ( !rData.aLinkDoc.equals(aThisName) ) nRet = rEvt.mnAction; } - else if (rData.aJumpTarget.Len()) + else if (!rData.aJumpTarget.isEmpty()) { // internal bookmarks (from Navigator) // local jumps from an unnamed document are possible only within a document @@ -4097,25 +4097,25 @@ sal_Int8 ScGridWindow::ExecuteDrop( const ExecuteDropEvent& rEvt ) Point aPos = rEvt.maPosPixel; - if ( rData.aLinkDoc.Len() ) + if ( !rData.aLinkDoc.isEmpty() ) { // try to insert a link - sal_Bool bOk = sal_True; - String aThisName; + bool bOk = true; + rtl::OUString aThisName; ScDocShell* pDocSh = pViewData->GetDocShell(); if (pDocSh && pDocSh->HasName()) aThisName = pDocSh->GetMedium()->GetName(); - if ( rData.aLinkDoc == aThisName ) // error - no link within a document + if ( rData.aLinkDoc.equals(aThisName) ) // error - no link within a document bOk = false; else { ScViewFunc* pView = pViewData->GetView(); - if ( rData.aLinkTable.Len() ) + if ( !rData.aLinkTable.isEmpty() ) pView->InsertTableLink( rData.aLinkDoc, EMPTY_STRING, EMPTY_STRING, rData.aLinkTable ); - else if ( rData.aLinkArea.Len() ) + else if ( !rData.aLinkArea.isEmpty() ) { SCsCOL nPosX; SCsROW nPosY; @@ -4160,7 +4160,7 @@ sal_Int8 ScGridWindow::ExecuteDrop( const ExecuteDropEvent& rEvt ) SCsROW nPosY; pViewData->GetPosFromPixel( aPos.X(), aPos.Y(), eWhich, nPosX, nPosY ); - if (rData.aJumpTarget.Len()) + if (!rData.aJumpTarget.isEmpty()) { // internal bookmark (from Navigator) // bookmark clipboard formats are in PasteScDataObject |