summaryrefslogtreecommitdiff
path: root/sd/source/ui/view/viewshe2.cxx
diff options
context:
space:
mode:
authorOliver Bolte <obo@openoffice.org>2004-03-17 10:29:22 +0000
committerOliver Bolte <obo@openoffice.org>2004-03-17 10:29:22 +0000
commit627c97cac531a1ac1a8571991dbc0685bcd84382 (patch)
tree4d0e0076c2623e50670fc89c470098259bcf95c1 /sd/source/ui/view/viewshe2.cxx
parente64a61f10f4623156e2d8ef539046c4c4fe49899 (diff)
INTEGRATION: CWS impress4ea1 (1.23.30); FILE MERGED
2004/03/08 15:57:32 cl 1.23.30.2: #i22801# present 'insert ole object' dialog when user double clicks on an ole placeholder that uses an oleserver that is not installed 2004/03/01 16:53:48 cl 1.23.30.1: #i22801# present 'insert ole object' dialog when user double clicks on an ole placeholder where the coresponding application is not installed
Diffstat (limited to 'sd/source/ui/view/viewshe2.cxx')
-rw-r--r--sd/source/ui/view/viewshe2.cxx38
1 files changed, 20 insertions, 18 deletions
diff --git a/sd/source/ui/view/viewshe2.cxx b/sd/source/ui/view/viewshe2.cxx
index 113d6e14afb4..bbe97e1dbc28 100644
--- a/sd/source/ui/view/viewshe2.cxx
+++ b/sd/source/ui/view/viewshe2.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: viewshe2.cxx,v $
*
- * $Revision: 1.23 $
+ * $Revision: 1.24 $
*
- * last change: $Author: obo $ $Date: 2004-01-20 12:56:22 $
+ * last change: $Author: obo $ $Date: 2004-03-17 11:29:22 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -112,6 +112,9 @@
#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
#endif
+#ifndef INCLUDED_SVTOOLS_MODULEOPTIONS_HXX
+#include <svtools/moduleoptions.hxx>
+#endif
#include <sot/clsids.hxx>
@@ -1059,23 +1062,29 @@ BOOL ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb)
if( aName.EqualsAscii( "StarChart" ))
{
- aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SCH_CLASSID ) );
+ if( SvtModuleOptions().IsChart() )
+ aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SCH_CLASSID ) );
}
else if( aName.EqualsAscii( "StarOrg" ))
{
- // z.Z noch Nummer vom StarChart!
- aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SCH_CLASSID ) );
+ if( SvtModuleOptions().IsChart() )
+ aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SCH_CLASSID ) );
}
else if( aName.EqualsAscii( "StarCalc" ))
{
- aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SC_CLASSID ) );
+ if( SvtModuleOptions().IsCalc() )
+ aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SC_CLASSID ) );
}
else if( aName.EqualsAscii( "StarMath" ))
{
- aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SM_CLASSID ) );
+ if( SvtModuleOptions().IsMath() )
+ aNewIPObj = SvInPlaceObject::CreateObject( SvGlobalName( SO3_SM_CLASSID ) );
}
- else
+
+ if( !aNewIPObj.Is() )
{
+ aName = String();
+
// Dialog "OLE-Objekt einfuegen" aufrufen
GetDocSh()->SetWaitCursor( FALSE );
pViewShell->GetViewFrame()->GetDispatcher()->Execute(
@@ -1090,7 +1099,7 @@ BOOL ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb)
}
}
- if ( aNewIPObj.Is() )
+ if( aNewIPObj.Is() )
{
/******************************************************
* OLE-Objekt ist nicht mehr leer
@@ -1134,7 +1143,7 @@ BOOL ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb)
}
}
- if ( aErrCode == 0 )
+ if( aErrCode == 0 )
{
::sd::View* pView = GetView();
@@ -1195,14 +1204,7 @@ BOOL ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb)
ErrorHandler::HandleError(* new StringErrorInfo(aErrCode, String() ) );
}
- BOOL bActivated = FALSE;
-
- if (aErrCode == 0)
- {
- bActivated = TRUE;
- }
-
- return(bActivated);
+ return aErrCode == 0;
}
/*************************************************************************