diff options
author | Kurt Zenker <kz@openoffice.org> | 2004-05-19 15:40:25 +0000 |
---|---|---|
committer | Kurt Zenker <kz@openoffice.org> | 2004-05-19 15:40:25 +0000 |
commit | 30cda2c3d6fd5d2770dce09aff31902e61768a76 (patch) | |
tree | 9f14ab1a40fbd4c94c9f23a46328ed94c4b7972a /ucb | |
parent | e4a2ec55258bef3d9b7a1e938cd49f8dd56c3302 (diff) |
INTEGRATION: CWS qwizards1 (1.10.84); FILE MERGED
2004/02/26 15:06:20 abi 1.10.84.1: #115710# changed direct use of sal_Bool to use of !!sal_Bool
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/core/ucbcmds.cxx | 48 |
1 files changed, 44 insertions, 4 deletions
diff --git a/ucb/source/core/ucbcmds.cxx b/ucb/source/core/ucbcmds.cxx index 4b5aeb5f0906..7660ed277417 100644 --- a/ucb/source/core/ucbcmds.cxx +++ b/ucb/source/core/ucbcmds.cxx @@ -2,9 +2,9 @@ * * $RCSfile: ucbcmds.cxx,v $ * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * - * last change: $Author: hr $ $Date: 2004-04-14 13:38:01 $ + * last change: $Author: kz $ $Date: 2004-05-19 16:40:25 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -80,12 +80,18 @@ #ifndef _RTL_USTRING_HXX_ #include <rtl/ustring.hxx> #endif +#ifndef __COM_SUN_STAR_LANG_XINTERFACE_HPP_ +#include <com/sun/star/uno/XInterface.hpp> +#endif #ifndef _COM_SUN_STAR_BEANS_PROPERTYSTATE_HPP_ #include <com/sun/star/beans/PropertyState.hpp> #endif #ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_ #include <com/sun/star/beans/PropertyValue.hpp> #endif +#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_ +#include <com/sun/star/container/XChild.hpp> +#endif #ifndef _COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP_ #include <com/sun/star/beans/XPropertySetInfo.hpp> #endif @@ -759,11 +765,14 @@ static uno::Reference< star::ucb::XContent > createNew( } else { - if ( ( bSourceIsFolder == + // (not a and not b) or (a and b) + // not( a or b) or (a and b) + // + if ( ( !!bSourceIsFolder == !!( nAttribs & star::ucb::ContentInfoAttribute::KIND_FOLDER ) ) && - ( bSourceIsDocument == + ( !!bSourceIsDocument == !!( nAttribs & star::ucb::ContentInfoAttribute::KIND_DOCUMENT ) ) ) @@ -1735,6 +1744,37 @@ static void globalTransfer( { } } + + try { + uno::Reference< star::ucb::XCommandProcessor > xcp( + xTarget, uno::UNO_QUERY ); + + uno::Any aAny; + uno::Reference< star::ucb::XCommandInfo > xci; + if(xcp.is()) + aAny = + xcp->execute( + star::ucb::Command( + rtl::OUString::createFromAscii("getCommandInfo"), + -1, + uno::Any()), + 0, + rContext.xEnv ); + + const rtl::OUString cmdName = + rtl::OUString::createFromAscii("flush"); + if((aAny >>= xci) && xci->hasCommandByName(cmdName)) + xcp->execute( + star::ucb::Command( + cmdName, + -1, + uno::Any()) , + 0, + rContext.xEnv ); + } + catch( star::uno::Exception const & ) + { + } } } /* namescpace ucb_commands */ |