summaryrefslogtreecommitdiff
path: root/sw/source/ui/wrtsh/wrtsh3.cxx
diff options
context:
space:
mode:
authorOliver Bolte <obo@openoffice.org>2004-08-12 12:15:25 +0000
committerOliver Bolte <obo@openoffice.org>2004-08-12 12:15:25 +0000
commitdc8dc7a67ee7f78b0202876b9c6673172160855e (patch)
tree5e94152bf1c81d4ec7516a67929a178387dc086d /sw/source/ui/wrtsh/wrtsh3.cxx
parent98fbb045dfbe005403fd8aa82e4ec16fa76a6f84 (diff)
INTEGRATION: CWS tune05 (1.6.568); FILE MERGED
2004/07/23 17:08:07 mhu 1.6.568.2: RESYNC: (1.6-1.7); FILE MERGED 2004/07/22 11:15:24 cmc 1.6.568.1: #i30554# unused SwWrtShell::SetURLToButton
Diffstat (limited to 'sw/source/ui/wrtsh/wrtsh3.cxx')
-rw-r--r--sw/source/ui/wrtsh/wrtsh3.cxx57
1 files changed, 2 insertions, 55 deletions
diff --git a/sw/source/ui/wrtsh/wrtsh3.cxx b/sw/source/ui/wrtsh/wrtsh3.cxx
index c57868ed946f..30dd7b2f51d8 100644
--- a/sw/source/ui/wrtsh/wrtsh3.cxx
+++ b/sw/source/ui/wrtsh/wrtsh3.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: wrtsh3.cxx,v $
*
- * $Revision: 1.7 $
+ * $Revision: 1.8 $
*
- * last change: $Author: rt $ $Date: 2004-07-12 15:53:36 $
+ * last change: $Author: obo $ $Date: 2004-08-12 13:15:25 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -274,56 +274,3 @@ sal_Bool SwWrtShell::GetURLFromButton( String& rURL, String& rDescr ) const
return bRet;
}
-
-
- // falls ein util::URL-Button selektiert ist, dessen util::URL returnen, ansonsten
- // einen LeerString
-sal_Bool SwWrtShell::SetURLToButton( const String& rURL, const String& rDescr )
-{
- sal_Bool bRet = sal_False;
- const SdrView *pDView = GetDrawView();
- if( pDView )
- {
- // Ein Fly ist genau dann erreichbar, wenn er selektiert ist.
- const SdrMarkList &rMarkList = pDView->GetMarkedObjectList();
- if (rMarkList.GetMark(0))
- {
- SdrUnoObj* pUnoCtrl = PTR_CAST(SdrUnoObj, rMarkList.GetMark(0)->GetObj());
- if (pUnoCtrl && FmFormInventor == pUnoCtrl->GetObjInventor())
- {
- uno::Reference< awt::XControlModel > xControlModel = pUnoCtrl->GetUnoControlModel();
-
- ASSERT( xControlModel.is(), "UNO-Control ohne Model" );
- if( !xControlModel.is() )
- return bRet;
-
- uno::Reference< beans::XPropertySet > xPropSet(xControlModel, uno::UNO_QUERY);
-
- uno::Any aTmp;
-
- // Darf man eine util::URL an dem Objekt setzen?
- uno::Reference< beans::XPropertySetInfo > xPropInfoSet = xPropSet->getPropertySetInfo();
- beans::Property aProp = xPropInfoSet->getPropertyByName( C2U("TargetURL") );
- if (aProp.Name.getLength())
- {
- // Ja!
- aTmp <<= OUString(rDescr);
- xPropSet->setPropertyValue( C2U("Label"), aTmp );
-
- aTmp <<= OUString(rURL);
- xPropSet->setPropertyValue( C2U("TargetURL"), aTmp );
-
-
- form::FormButtonType eButtonType = form::FormButtonType_URL;
- aTmp.setValue( &eButtonType, ::getCppuType((form::FormButtonType*)0));
- xPropSet->setPropertyValue( C2U("ButtonType"), aTmp );
- }
- }
- }
- }
-
- return bRet;
-}
-
-
-