summaryrefslogtreecommitdiff
path: root/framework/source/classes/taskcreator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source/classes/taskcreator.cxx')
-rw-r--r--framework/source/classes/taskcreator.cxx10
1 files changed, 8 insertions, 2 deletions
diff --git a/framework/source/classes/taskcreator.cxx b/framework/source/classes/taskcreator.cxx
index 612ab433e7e3..0bf720b510ac 100644
--- a/framework/source/classes/taskcreator.cxx
+++ b/framework/source/classes/taskcreator.cxx
@@ -57,7 +57,7 @@ TaskCreator::~TaskCreator()
/*-****************************************************************************************************
TODO document me
*//*-*****************************************************************************************************/
-css::uno::Reference< css::frame::XFrame > TaskCreator::createTask( const OUString& sName )
+css::uno::Reference< css::frame::XFrame > TaskCreator::createTask( const OUString& sName, const utl::MediaDescriptor& rDescriptor )
{
css::uno::Reference< css::lang::XSingleServiceFactory > xCreator;
OUString sCreator = IMPLEMENTATIONNAME_FWK_TASKCREATOR;
@@ -86,7 +86,7 @@ css::uno::Reference< css::frame::XFrame > TaskCreator::createTask( const OUStrin
if ( ! xCreator.is())
xCreator = css::frame::TaskCreator::create(m_xContext);
- css::uno::Sequence< css::uno::Any > lArgs(5);
+ css::uno::Sequence< css::uno::Any > lArgs(6);
css::beans::NamedValue aArg;
aArg.Name = ARGUMENT_PARENTFRAME;
@@ -109,6 +109,12 @@ css::uno::Reference< css::frame::XFrame > TaskCreator::createTask( const OUStrin
aArg.Value <<= sName;
lArgs[4] <<= aArg;
+ bool bHidden
+ = rDescriptor.getUnpackedValueOrDefault(utl::MediaDescriptor::PROP_HIDDEN(), false);
+ aArg.Name = "Hidden";
+ aArg.Value <<= bHidden;
+ lArgs[5] <<= aArg;
+
css::uno::Reference< css::frame::XFrame > xTask(xCreator->createInstanceWithArguments(lArgs), css::uno::UNO_QUERY_THROW);
return xTask;
}