summaryrefslogtreecommitdiffstats
path: root/dtrans/source/win32/dtobj/DataFmtTransl.cxx
diff options
context:
space:
mode:
authorTino Rachui <tra@openoffice.org>2001-07-26 10:36:42 +0000
committerTino Rachui <tra@openoffice.org>2001-07-26 10:36:42 +0000
commit5ca5cb4fe3319ff035c36b78ae6c3b52b61e980d (patch)
treeb6fdb8a3189fbf075f67009d2d8b3a3adf9e5b7d /dtrans/source/win32/dtobj/DataFmtTransl.cxx
parent#90205# remove TF_SVDATA (diff)
downloadcore-5ca5cb4fe3319ff035c36b78ae6c3b52b61e980d.tar.gz
core-5ca5cb4fe3319ff035c36b78ae6c3b52b61e980d.zip
#87296#now setting lindex to 0 if clipboard format is cfstr_filecontents in formatetcfromclipbformat
Diffstat (limited to 'dtrans/source/win32/dtobj/DataFmtTransl.cxx')
-rw-r--r--dtrans/source/win32/dtobj/DataFmtTransl.cxx19
1 files changed, 16 insertions, 3 deletions
diff --git a/dtrans/source/win32/dtobj/DataFmtTransl.cxx b/dtrans/source/win32/dtobj/DataFmtTransl.cxx
index 72366f2b2e20..610ec8355095 100644
--- a/dtrans/source/win32/dtobj/DataFmtTransl.cxx
+++ b/dtrans/source/win32/dtobj/DataFmtTransl.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: DataFmtTransl.cxx,v $
*
- * $Revision: 1.15 $
+ * $Revision: 1.16 $
*
- * last change: $Author: tra $ $Date: 2001-05-25 11:32:47 $
+ * last change: $Author: tra $ $Date: 2001-07-26 11:36:42 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -107,6 +107,7 @@
#include <windows.h>
#include <olestd.h>
+#include <shlobj.h>
//------------------------------------------------------------------------
// namespace directives
@@ -280,7 +281,7 @@ OUString CDataFormatTranslator::getClipboardFormatName( CLIPFORMAT aClipformat )
CFormatEtc SAL_CALL CDataFormatTranslator::getFormatEtcForClipformat( CLIPFORMAT cf ) const
{
- CFormatEtc fetc( cf, TYMED_NULL, NULL, DVASPECT_CONTENT );;
+ CFormatEtc fetc( cf, TYMED_NULL, NULL, DVASPECT_CONTENT );
switch( cf )
{
@@ -296,6 +297,18 @@ CFormatEtc SAL_CALL CDataFormatTranslator::getFormatEtcForClipformat( CLIPFORMAT
fetc.setTymed( TYMED_HGLOBAL /*| TYMED_ISTREAM*/ );
}
+ /*
+ hack: in order to paste urls copied by Internet Explorer
+ with "copy link" we set the lindex member to 0
+ but if we really want to support CFSTR_FILECONTENT and
+ the accompany format CFSTR_FILEDESCRIPTOR (FileGroupDescriptor)
+ the client of the clipboard service has to provide a id
+ of which FileContents it wants to paste
+ see MSDN: "Handling Shell Data Transfer Scenarios"
+ */
+ if ( cf == RegisterClipboardFormatA( CFSTR_FILECONTENTS ) )
+ fetc.setLindex( 0 );
+
return fetc;
}