diff options
author | Mathias Bauer <mba@openoffice.org> | 2010-07-19 22:04:23 +0200 |
---|---|---|
committer | Mathias Bauer <mba@openoffice.org> | 2010-07-19 22:04:23 +0200 |
commit | f60b366882b4281061199daf2df24055f94f1ba0 (patch) | |
tree | a6eb10826960d3249c90a15cdf7c196de46af4de /sw/source/ui | |
parent | ec8cfe27fa5d2c7041c0895a0ef8f3a2483b8a3e (diff) |
CWS changehid: remove code dealing with obsolete SID_INSERT_APPLET
Diffstat (limited to 'sw/source/ui')
-rw-r--r-- | sw/source/ui/shells/textsh.cxx | 41 | ||||
-rw-r--r-- | sw/source/ui/wrtsh/wrtsh1.cxx | 10 |
2 files changed, 2 insertions, 49 deletions
diff --git a/sw/source/ui/shells/textsh.cxx b/sw/source/ui/shells/textsh.cxx index 0de14dc3dacbd..2e39e1ebd6d44 100644 --- a/sw/source/ui/shells/textsh.cxx +++ b/sw/source/ui/shells/textsh.cxx @@ -282,7 +282,6 @@ void SwTextShell::ExecInsert(SfxRequest &rReq) break; case SID_INSERT_OBJECT: case SID_INSERT_PLUGIN: - case SID_INSERT_APPLET: { SFX_REQUEST_ARG( rReq, pNameItem, SfxGlobalNameItem, SID_INSERT_OBJECT, sal_False ); SvGlobalName *pName = NULL; @@ -298,8 +297,7 @@ void SwTextShell::ExecInsert(SfxRequest &rReq) SFX_REQUEST_ARG( rReq, pCommandsItem, SfxStringItem, FN_PARAM_3, sal_False ); //TODO/LATER: recording currently not working, need code for Commandlist svt::EmbeddedObjectRef xObj; - if((SID_INSERT_APPLET == nSlot || SID_INSERT_PLUGIN) - && (pClassItem || pClassLocationItem || pCommandsItem)) + if( pClassItem || pClassLocationItem || pCommandsItem ) { String sClass; String sClassLocation; @@ -315,36 +313,6 @@ void SwTextShell::ExecInsert(SfxRequest &rReq) aCommandList.AppendCommands( pCommandsItem->GetValue(), &nTemp ); } - if(SID_INSERT_APPLET == nSlot) - { - SwApplet_Impl aApplImpl( rSh.GetAttrPool(), - RES_FRMATR_BEGIN, RES_FRMATR_END-1 ); - String sBaseURL; - SfxMedium* pMedium = GetView().GetDocShell()->GetMedium(); - if(pMedium) - sBaseURL = pMedium->GetURLObject().GetMainURL(INetURLObject::NO_DECODE); - - aApplImpl.CreateApplet(sClass, aEmptyStr, FALSE, sClassLocation, sBaseURL ); - aApplImpl.FinishApplet(); - xObj.Assign( aApplImpl.GetApplet(), embed::Aspects::MSOLE_CONTENT ); - if( aCommandList.Count() ) - { - uno::Reference < beans::XPropertySet > xSet( xObj->getComponent(), uno::UNO_QUERY ); - if ( xSet.is() ) - { - uno::Sequence < beans::PropertyValue > aSeq; - aCommandList.FillSequence( aSeq ); - try - { - xSet->setPropertyValue( ::rtl::OUString::createFromAscii("AppletCommands"), uno::makeAny( aSeq ) ); - } - catch ( uno::Exception& ) - { - } - } - } - } - else { comphelper::EmbeddedObjectContainer aCnt; ::rtl::OUString sName; @@ -851,13 +819,8 @@ void SwTextShell::StateInsert( SfxItemSet &rSet ) case SID_INSERT_FLOATINGFRAME: case SID_INSERT_OBJECT: case SID_INSERT_PLUGIN: - case SID_INSERT_APPLET: { - if( -#ifndef SOLAR_JAVA - nWhich == SID_INSERT_APPLET || -#endif - eCreateMode == SFX_CREATE_MODE_EMBEDDED || bCrsrInHidden ) + if( eCreateMode == SFX_CREATE_MODE_EMBEDDED || bCrsrInHidden ) { rSet.DisableItem( nWhich ); } diff --git a/sw/source/ui/wrtsh/wrtsh1.cxx b/sw/source/ui/wrtsh/wrtsh1.cxx index efbb5f161cd20..64199404687cd 100644 --- a/sw/source/ui/wrtsh/wrtsh1.cxx +++ b/sw/source/ui/wrtsh/wrtsh1.cxx @@ -443,16 +443,6 @@ void SwWrtShell::InsertObject( const svt::EmbeddedObjectRef& xRef, SvGlobalName pReq->AppendItem(SfxStringItem(FN_PARAM_2, pURL->GetMainURL(INetURLObject::NO_DECODE))); pReq->AppendItem(SfxStringItem(FN_PARAM_3 , aDlg.GetCommands())); } */ - case SID_INSERT_APPLET: - /* - if(pReq) - { - SvAppletObjectRef xApplet ( xIPObj ); - if(xApplet.Is()) - pReq->AppendItem(SfxStringItem(FN_PARAM_1 , xApplet->GetCodeBase())); - pReq->AppendItem(SfxStringItem(FN_PARAM_2 , aDlg.GetClass())); - pReq->AppendItem(SfxStringItem(FN_PARAM_3 , aDlg.GetCommands())); - }*/ case SID_INSERT_FLOATINGFRAME: /* if(pReq && xFloatingFrame.Is()) |