22 #include <com/sun/star/beans/XPropertySet.hpp>
23 #include <com/sun/star/beans/PropertyValue.hpp>
24 #include <com/sun/star/embed/XEmbeddedObject.hpp>
28 #include <com/sun/star/uno/Any.hxx>
40 switch( rName.toChar() )
48 (rName ==
"ARCHIVE" || rName ==
"ARCHIVES" ) )
83 if( bApplet && rName ==
"OBJECT" )
117 bool bMayScript,
const OUString& rCodeBase,
118 const OUString& rDocumentBaseURL )
131 uno::Reference < beans::XPropertySet > xSet(
xApplet->getComponent(), uno::UNO_QUERY );
134 xSet->setPropertyValue(
"AppletCode", uno::makeAny( rCode ) );
135 xSet->setPropertyValue(
"AppletName", uno::makeAny( rName ) );
136 xSet->setPropertyValue(
"AppletIsScript", uno::makeAny( bMayScript ) );
137 xSet->setPropertyValue(
"AppletDocBase", uno::makeAny( sDocBase ) );
138 if ( !rCodeBase.isEmpty() )
139 xSet->setPropertyValue(
"AppletCodeBase", uno::makeAny( rCodeBase ) );
141 xSet->setPropertyValue(
"AppletCodeBase", uno::makeAny( sDocBase ) );
144 #if HAVE_FEATURE_JAVA
147 OUString aCode,
aName, aCodeBase;
148 bool bMayScript =
false;
151 for(
size_t i = 0;
i < nArgCount;
i++ )
155 if( rName.equalsIgnoreAsciiCase( OOO_STRING_SVTOOLS_HTML_O_code ) )
157 else if( rName.equalsIgnoreAsciiCase( OOO_STRING_SVTOOLS_HTML_O_codebase ) )
159 else if( rName.equalsIgnoreAsciiCase( OOO_STRING_SVTOOLS_HTML_O_name ) )
161 else if( rName.equalsIgnoreAsciiCase( OOO_STRING_SVTOOLS_HTML_O_mayscript ) )
165 if( aCode.isEmpty() )
167 CreateApplet( aCode, aName, bMayScript, aCodeBase, rBaseURL );
177 uno::Reference < beans::XPropertySet > xSet(
xApplet->getComponent(), uno::UNO_QUERY );
180 uno::Sequence < beans::PropertyValue > aProps;
182 xSet->setPropertyValue(
"AppletCommands", uno::makeAny( aProps ) );
186 #if HAVE_FEATURE_JAVA
187 void SwApplet_Impl::AppendParam(
const OUString& rName,
const OUString& rValue )
#define OOO_STRING_SVTOOLS_HTML_O_src
#define OOO_STRING_SVTOOLS_HTML_O_vspace
css::uno::Reference< css::embed::XEmbeddedObject > CreateEmbeddedObject(const css::uno::Sequence< sal_Int8 > &, OUString &, OUString const *pBaseURL=nullptr)
static SwHtmlOptType GetOptionType(const OUString &rName, bool bApplet)
#define OOO_STRING_SW_HTML_O_Hidden
SvCommandList aCommandList
#define OOO_STRING_SVTOOLS_HTML_O_id
#define OOO_STRING_SVTOOLS_HTML_O_alt
SwApplet_Impl(SfxItemPool &rPool)
#define OOO_STRING_SVTOOLS_HTML_O_height
#define OOO_STRING_SVTOOLS_HTML_O_mayscript
static OUString GetAbsURL(OUString const &rTheBaseURIRef, OUString const &rTheRelURIRef, EncodeMechanism eEncodeMechanism=EncodeMechanism::WasEncoded, DecodeMechanism eDecodeMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8)
void CreateApplet(const OUString &rCode, const OUString &rName, bool bMayScript, const OUString &rCodeBase, const OUString &rBaseURL)
void FillSequence(css::uno::Sequence< css::beans::PropertyValue > &) const
#define OOO_STRING_SVTOOLS_HTML_O_code
#define OOO_STRING_SVTOOLS_HTML_O_hspace
#define OOO_STRING_SVTOOLS_HTML_O_class
const OUString & GetArgument() const
void Append(const OUString &rCommand, const OUString &rArg)
#define OOO_STRING_SVTOOLS_HTML_O_name
#define SO3_APPLET_CLASSID
const OUString & GetCommand() const
OUString GetMainURL(DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
#define OOO_STRING_SVTOOLS_HTML_O_codebase
#define OOO_STRING_SVTOOLS_HTML_O_align
constexpr sal_uInt16 RES_FRMATR_END(131)
#define OOO_STRING_SVTOOLS_HTML_O_style
#define OOO_STRING_SVTOOLS_HTML_O_type
static bool TryRunningState(const css::uno::Reference< css::embed::XEmbeddedObject > &)
constexpr sal_uInt16 RES_FRMATR_BEGIN(RES_PARATR_LIST_END)
#define OOO_STRING_SVTOOLS_HTML_O_width
css::uno::Reference< css::embed::XEmbeddedObject > xApplet
bool removeSegment(sal_Int32 nIndex=LAST_SEGMENT, bool bIgnoreFinalSlash=true)