From 96bd54275ae74eb62a8de57e2e8f15557d4c98f1 Mon Sep 17 00:00:00 2001 From: Thomas Benisch Date: Mon, 4 Feb 2002 14:42:53 +0000 Subject: #97213# Clipboard doesn't work correct in the dialog editor --- basctl/source/dlged/dlged.cxx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'basctl/source/dlged') diff --git a/basctl/source/dlged/dlged.cxx b/basctl/source/dlged/dlged.cxx index 3b588598d27d..6aa5e1b947f7 100644 --- a/basctl/source/dlged/dlged.cxx +++ b/basctl/source/dlged/dlged.cxx @@ -2,9 +2,9 @@ * * $RCSfile: dlged.cxx,v $ * - * $Revision: 1.21 $ + * $Revision: 1.22 $ * - * last change: $Author: tbe $ $Date: 2002-01-22 09:06:16 $ + * last change: $Author: tbe $ $Date: 2002-02-04 15:42:53 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -735,8 +735,12 @@ void DlgEditor::Paste() for( sal_uInt32 n = 0; n < nCtrls; n++ ) { Any aA = xNameAcc->getByName( pNames[n] ); - Reference< ::com::sun::star::awt::XControlModel > xCtrlModel; - aA >>= xCtrlModel; + Reference< ::com::sun::star::awt::XControlModel > xCM; + aA >>= xCM; + + // clone the control model + Reference< util::XCloneable > xClone( xCM, uno::UNO_QUERY ); + Reference< awt::XControlModel > xCtrlModel( xClone->createClone(), uno::UNO_QUERY ); DlgEdObj* pCtrlObj = new DlgEdObj(); pCtrlObj->SetDlgEdForm(pDlgEdForm); // set parent form -- cgit v1.2.3