From 4cc8b5678950041b71b525c70be3f13d48a777cc Mon Sep 17 00:00:00 2001 From: Daniel Rentz Date: Fri, 15 Jan 2010 12:00:39 +0100 Subject: dr74: migrate changes to hg --- svx/source/msfilter/msocximex.cxx | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'svx') diff --git a/svx/source/msfilter/msocximex.cxx b/svx/source/msfilter/msocximex.cxx index 7db08e229536..a489d769df59 100644 --- a/svx/source/msfilter/msocximex.cxx +++ b/svx/source/msfilter/msocximex.cxx @@ -2341,8 +2341,8 @@ sal_Bool OCX_ToggleButton::Import(com::sun::star::uno::Reference< if (pValue) { INT16 nTmp=pValue[0]-0x30; - aTmp <<= nTmp; - rPropSet->setPropertyValue( WW8_ASCII2STR("State"), aTmp); + aTmp <<= nTmp == 1; + rPropSet->setPropertyValue( WW8_ASCII2STR("DefaultState"), aTmp); } if (pCaption) @@ -2462,9 +2462,9 @@ sal_Bool OCX_ToggleButton::WriteContents(SvStorageStreamRef &rContents, WriteAlign(rContents,4); nValueLen = 1|SVX_MSOCX_COMPRESSED; - aTmp = rPropSet->getPropertyValue(WW8_ASCII2STR("State")); - sal_Int16 nDefault = sal_Int16(); - aTmp >>= nDefault; + bool bDefault = false; + rPropSet->getPropertyValue(WW8_ASCII2STR("DefaultState")) >>= bDefault; + sal_uInt8 nDefault = static_cast< sal_uInt8 >( bDefault ? '1' : '0' ); *rContents << nValueLen; pBlockFlags[2] |= 0x40; @@ -2477,8 +2477,7 @@ sal_Bool OCX_ToggleButton::WriteContents(SvStorageStreamRef &rContents, *rContents << rSize.Width; *rContents << rSize.Height; - nDefault += 0x30; - *rContents << sal_uInt8(nDefault); + *rContents << nDefault; *rContents << sal_uInt8(0x00); aCaption.WriteCharArray( *rContents ); -- cgit From 919af93078236afd12a0163163c0d67766a0a320 Mon Sep 17 00:00:00 2001 From: David Tardon Date: Thu, 11 Mar 2010 07:34:30 +0100 Subject: dtardon02: #i108507# remove empty files in svx --- svx/source/engine3d/viewpt3d.cxx | 32 -------------------- svx/source/engine3d/volume3d.cxx | 32 -------------------- svx/source/form/typemap.cxx | 65 ---------------------------------------- svx/source/svdraw/svdcrtmt.hxx | 32 -------------------- svx/source/svdraw/svdoimp.cxx | 33 -------------------- svx/source/svdraw/svdscrol.cxx | 33 -------------------- svx/source/svdraw/svdscrol.hxx | 31 ------------------- 7 files changed, 258 deletions(-) delete mode 100644 svx/source/engine3d/viewpt3d.cxx delete mode 100644 svx/source/engine3d/volume3d.cxx delete mode 100644 svx/source/form/typemap.cxx delete mode 100644 svx/source/svdraw/svdcrtmt.hxx delete mode 100644 svx/source/svdraw/svdoimp.cxx delete mode 100644 svx/source/svdraw/svdscrol.cxx delete mode 100644 svx/source/svdraw/svdscrol.hxx (limited to 'svx') diff --git a/svx/source/engine3d/viewpt3d.cxx b/svx/source/engine3d/viewpt3d.cxx deleted file mode 100644 index ef9750781a2e..000000000000 --- a/svx/source/engine3d/viewpt3d.cxx +++ /dev/null @@ -1,32 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_svx.hxx" -#include - -// eof diff --git a/svx/source/engine3d/volume3d.cxx b/svx/source/engine3d/volume3d.cxx deleted file mode 100644 index 04a94b1705f5..000000000000 --- a/svx/source/engine3d/volume3d.cxx +++ /dev/null @@ -1,32 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_svx.hxx" -#include - -// eof diff --git a/svx/source/form/typemap.cxx b/svx/source/form/typemap.cxx deleted file mode 100644 index f465e9d88dad..000000000000 --- a/svx/source/form/typemap.cxx +++ /dev/null @@ -1,65 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_svx.hxx" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef _SVX_CLIPBOARDCTL_HXX_ -#include "clipfmtitem.hxx" -#endif -#include -#include "editeng/fontitem.hxx" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef _SVX_EMPHITEM_HXX -#include -#endif - -#include -#define SFX_TYPEMAP -#include "svxslots.hxx" - diff --git a/svx/source/svdraw/svdcrtmt.hxx b/svx/source/svdraw/svdcrtmt.hxx deleted file mode 100644 index 0cf7642bf110..000000000000 --- a/svx/source/svdraw/svdcrtmt.hxx +++ /dev/null @@ -1,32 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#ifndef _SVDCRTMT_HXX -#define _SVDCRTMT_HXX - -#endif //_SVDCRTMT_HXX - diff --git a/svx/source/svdraw/svdoimp.cxx b/svx/source/svdraw/svdoimp.cxx deleted file mode 100644 index 7b7fa2652017..000000000000 --- a/svx/source/svdraw/svdoimp.cxx +++ /dev/null @@ -1,33 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_svx.hxx" -#include - -/////////////////////////////////////////////////////////////////////////////// -// eof diff --git a/svx/source/svdraw/svdscrol.cxx b/svx/source/svdraw/svdscrol.cxx deleted file mode 100644 index ce1d4e32bf32..000000000000 --- a/svx/source/svdraw/svdscrol.cxx +++ /dev/null @@ -1,33 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_svx.hxx" - -#include "svdscrol.hxx" - -// eof diff --git a/svx/source/svdraw/svdscrol.hxx b/svx/source/svdraw/svdscrol.hxx deleted file mode 100644 index f44cf3d81c65..000000000000 --- a/svx/source/svdraw/svdscrol.hxx +++ /dev/null @@ -1,31 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#ifndef _SVDSCROL_HXX -#define _SVDSCROL_HXX - -#endif //_SVDSCROL_HXX -- cgit From 13f97a0abca273d1ad111e5109a8723628b3df3c Mon Sep 17 00:00:00 2001 From: David Tardon Date: Fri, 12 Mar 2010 07:49:50 +0100 Subject: dtardon02: #i18507# revert errorneously removed file --- svx/source/form/typemap.cxx | 65 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 svx/source/form/typemap.cxx (limited to 'svx') diff --git a/svx/source/form/typemap.cxx b/svx/source/form/typemap.cxx new file mode 100644 index 000000000000..f465e9d88dad --- /dev/null +++ b/svx/source/form/typemap.cxx @@ -0,0 +1,65 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +#include "precompiled_svx.hxx" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#ifndef _SVX_CLIPBOARDCTL_HXX_ +#include "clipfmtitem.hxx" +#endif +#include +#include "editeng/fontitem.hxx" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#ifndef _SVX_EMPHITEM_HXX +#include +#endif + +#include +#define SFX_TYPEMAP +#include "svxslots.hxx" + -- cgit From bbcce61e3561c9f6afb2e320928bf49b7e6fb417 Mon Sep 17 00:00:00 2001 From: David Tardon Date: Fri, 12 Mar 2010 13:16:09 +0100 Subject: dtardon02: #i108503# #i108505# #i108507# #i108508# #i110035# clean up makefiles and #includes --- svx/source/engine3d/makefile.mk | 2 -- svx/source/svdraw/makefile.mk | 2 -- svx/source/svdraw/svdobj.cxx | 1 - svx/source/svdraw/svdotext.cxx | 1 - 4 files changed, 6 deletions(-) (limited to 'svx') diff --git a/svx/source/engine3d/makefile.mk b/svx/source/engine3d/makefile.mk index 6e6e3f97c550..308b130e2b9a 100644 --- a/svx/source/engine3d/makefile.mk +++ b/svx/source/engine3d/makefile.mk @@ -64,8 +64,6 @@ LIB1OBJFILES= \ LIB2TARGET= $(SLB)$/$(TARGET).lib LIB2OBJFILES= \ - $(SLO)$/volume3d.obj \ - $(SLO)$/viewpt3d.obj \ $(SLO)$/float3d.obj SLOFILES = $(LIB1OBJFILES) $(LIB2OBJFILES) diff --git a/svx/source/svdraw/makefile.mk b/svx/source/svdraw/makefile.mk index 0108615b10dd..514c5b6d2cbc 100644 --- a/svx/source/svdraw/makefile.mk +++ b/svx/source/svdraw/makefile.mk @@ -113,8 +113,6 @@ LIB1OBJFILES= \ LIB2TARGET= $(SLB)$/$(TARGET).lib LIB2OBJFILES= \ - $(SLO)$/svdoimp.obj \ - $(SLO)$/svdscrol.obj \ $(SLO)$/ActionDescriptionProvider.obj \ $(SLO)$/impgrfll.obj diff --git a/svx/source/svdraw/svdobj.cxx b/svx/source/svdraw/svdobj.cxx index d44b44210ca0..ceee3f69b229 100644 --- a/svx/source/svdraw/svdobj.cxx +++ b/svx/source/svdraw/svdobj.cxx @@ -47,7 +47,6 @@ #include #include // Fuer Add/Del Ref #include // fuer Dragging (Ortho abfragen) -#include "svdscrol.hxx" #include "svdglob.hxx" // StringCache #include "svdstr.hrc" // Objektname #include // Factory diff --git a/svx/source/svdraw/svdotext.cxx b/svx/source/svdraw/svdotext.cxx index a2b7e8c0490c..6a79359e1a00 100644 --- a/svx/source/svdraw/svdotext.cxx +++ b/svx/source/svdraw/svdotext.cxx @@ -35,7 +35,6 @@ #include // und fuer AnimationHandler (Laufschrift) #include #include -#include "svdscrol.hxx" // fuer Laufschrift #include // OutlinerDefaults #include "svdglob.hxx" // Stringcache #include "svdstr.hrc" // Objektname -- cgit From b3b69ebe0dff114f73f864abef31f7a7384be93d Mon Sep 17 00:00:00 2001 From: David Tardon Date: Sat, 13 Mar 2010 17:55:47 +0100 Subject: dtardon02: #i108507# remove windows-specific bits --- svx/source/engine3d/makefile.mk | 6 ------ 1 file changed, 6 deletions(-) (limited to 'svx') diff --git a/svx/source/engine3d/makefile.mk b/svx/source/engine3d/makefile.mk index 308b130e2b9a..71916df4a83c 100644 --- a/svx/source/engine3d/makefile.mk +++ b/svx/source/engine3d/makefile.mk @@ -68,12 +68,6 @@ LIB2OBJFILES= \ SLOFILES = $(LIB1OBJFILES) $(LIB2OBJFILES) -#disable optimizer for MSCompiler and ICC -.IF "$(COM)"=="ICC" || "$(COM)"=="MSC" -NOOPTFILES=\ - $(SLO)$/viewpt3d.obj -.ENDIF - SRS1NAME=engine3d SRC1FILES=\ string3d.src \ -- cgit From 801ea2a13eaa24b530315f8ff5666c17f911e670 Mon Sep 17 00:00:00 2001 From: Armin Le Grand Date: Wed, 17 Mar 2010 17:42:25 +0100 Subject: impress187 #i109515# avoid styles from other ItemPools --- svx/source/sdr/properties/attributeproperties.cxx | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'svx') diff --git a/svx/source/sdr/properties/attributeproperties.cxx b/svx/source/sdr/properties/attributeproperties.cxx index 15142a86b9cf..5abd9c4b26f1 100644 --- a/svx/source/sdr/properties/attributeproperties.cxx +++ b/svx/source/sdr/properties/attributeproperties.cxx @@ -281,7 +281,19 @@ namespace sdr // set stylesheet (if used) if(pStySheet) { - ImpAddStyleSheet(pStySheet, sal_True); + // #i109515# + SfxItemPool* pStyleSheetPool = &pStySheet->GetPool().GetPool(); + + if(pStyleSheetPool == pDestPool) + { + // just re-set stylesheet + ImpAddStyleSheet(pStySheet, sal_True); + } + else + { + // StyleSheet is NOT from the correct pool; use default + ImpAddStyleSheet(pNewModel->GetDefaultStyleSheet(), sal_True); + } } delete pOldSet; -- cgit From 4f84f920c1256125ab3a1073bcf5037deb3cb6ff Mon Sep 17 00:00:00 2001 From: Frank Schönheit Date: Tue, 19 Jan 2010 09:10:33 +0000 Subject: #i108375#: when searching the control belonging to a control model, ask the SdrUnoObj. This will ensure the control is actually created when it does not yet exist. --- svx/source/form/fmshimp.cxx | 104 +++++++++++++++++++++++++++++--------------- svx/source/inc/fmshimp.hxx | 8 +++- 2 files changed, 74 insertions(+), 38 deletions(-) (limited to 'svx') diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx index 463749b68364..34b13151bd32 100644 --- a/svx/source/form/fmshimp.cxx +++ b/svx/source/form/fmshimp.cxx @@ -1579,22 +1579,25 @@ void FmXFormShell::ExecuteSearch() return; // filter out the forms which do not contain valid controls at all - FmFormArray::reverse_iterator form = m_aSearchForms.rbegin(); - ::std::vector< String >::reverse_iterator contextName = aContextNames.rbegin(); - sal_Int32 i = m_aSearchForms.size(); - for ( ; - form != m_aSearchForms.rend(); - ++form, ++contextName, --i - ) { - FmSearchContext aTestContext; - aTestContext.nContext = static_cast< sal_Int16 >( i-1 ); - sal_uInt32 nValidControls = OnSearchContextRequest( &aTestContext ); - if ( nValidControls == 0 ) + FmFormArray aValidForms; + ::std::vector< String > aValidContexts; + FmFormArray::const_iterator form = m_aSearchForms.begin(); + ::std::vector< String >::const_iterator contextName = aContextNames.begin(); + for ( ; form != m_aSearchForms.end(); ++form, ++contextName ) { - m_aSearchForms.erase( form.base() - 1 ); - aContextNames.erase( contextName.base() - 1 ); + FmSearchContext aTestContext; + aTestContext.nContext = static_cast< sal_Int16 >( form - m_aSearchForms.begin() ); + sal_uInt32 nValidControls = OnSearchContextRequest( &aTestContext ); + if ( nValidControls > 0 ) + { + aValidForms.push_back( *form ); + aValidContexts.push_back( *contextName ); + } } + + m_aSearchForms.swap( aValidForms ); + aContextNames.swap( aValidContexts ); } if (m_aSearchForms.size() == 0) @@ -1606,7 +1609,7 @@ void FmXFormShell::ExecuteSearch() // jetzt brauche ich noch einen 'initial context' sal_Int16 nInitialContext = 0; Reference< XForm> xActiveForm( getActiveForm()); - for (i=0; i<(sal_Int32)m_aSearchForms.size(); ++i) + for ( size_t i=0; i<(sal_Int32)m_aSearchForms.size(); ++i ) { if (m_aSearchForms.at(i) == xActiveForm) { @@ -2373,6 +2376,8 @@ IMPL_LINK(FmXFormShell, OnFoundData, FmFoundRecordInformation*, pfriWhere) FmFormObj* pFormObject = FmFormObj::GetFormObject( pObject ); Reference< XControlModel > xControlModel( pFormObject ? pFormObject->GetUnoControlModel() : Reference< XControlModel >() ); DBG_ASSERT( xControlModel.is(), "FmXFormShell::OnFoundData: invalid control!" ); + if ( !xControlModel.is() ) + return 0; // disable the permanent cursor for the last grid we found a record if (m_xLastGridFound.is() && (m_xLastGridFound != xControlModel)) @@ -2390,7 +2395,7 @@ IMPL_LINK(FmXFormShell, OnFoundData, FmFoundRecordInformation*, pfriWhere) sal_Int32 nGridColumn = m_arrRelativeGridColumn.GetObject(pfriWhere->nFieldPos); if (nGridColumn != -1) { // dummer weise muss ich mir das Control erst wieder besorgen - Reference< XControl> xControl( GetControlFromModel(xControlModel)); + Reference< XControl> xControl( impl_getControl( xControlModel, *pFormObject ) ); Reference< XGrid> xGrid(xControl, UNO_QUERY); DBG_ASSERT(xGrid.is(), "FmXFormShell::OnFoundData : ungueltiges Control !"); // wenn eine der Asserts anschlaegt, habe ich beim Aufbauen von m_arrSearchedControls wohl was falsch gemacht @@ -2402,7 +2407,8 @@ IMPL_LINK(FmXFormShell, OnFoundData, FmFoundRecordInformation*, pfriWhere) xModelSet->setPropertyValue( FM_PROP_CURSORCOLOR, makeAny( sal_Int32( COL_LIGHTRED ) ) ); m_xLastGridFound = xControlModel; - xGrid->setCurrentColumnPosition((sal_Int16)nGridColumn); + if ( xGrid.is() ) + xGrid->setCurrentColumnPosition((sal_Int16)nGridColumn); } // als der Cursor neu positioniert wurde, habe ich (in positioned) meine Formularleisten-Slots invalidiert, aber das greift @@ -2510,7 +2516,7 @@ IMPL_LINK(FmXFormShell, OnSearchContextRequest, FmSearchContext*, pfmscContextIn // ... nach der ControlSource-Eigenschaft fragen SearchableControlIterator iter( xCurrentFormComponent ); - Reference< XControl> xControlBehindModel; + Reference< XControl> xControl; // das Control, das als Model xControlModel hat // (das folgende while kann mehrmals durchlaufen werden, ohne dass das Control sich aendert, dann muss // ich nicht jedesmal neu suchen) @@ -2522,10 +2528,12 @@ IMPL_LINK(FmXFormShell, OnSearchContextRequest, FmSearchContext*, pfmscContextIn if ( sControlSource.getLength() == 0 ) { // das aktuelle Element hat keine ControlSource, also ist es ein GridControl (das ist das einzige, was // der SearchableControlIterator noch zulaesst) - xControlBehindModel = GetControlFromModel(xControlModel); - DBG_ASSERT(xControlBehindModel.is(), "FmXFormShell::OnSearchContextRequest : didn't ::std::find a control with requested model !"); + xControl = impl_getControl( xControlModel, *pFormObject ); + DBG_ASSERT(xControl.is(), "FmXFormShell::OnSearchContextRequest : didn't ::std::find a control with requested model !"); - Reference< XGridPeer> xGridPeer(xControlBehindModel->getPeer(), UNO_QUERY); + Reference< XGridPeer> xGridPeer; + if ( xControl.is() ) + xGridPeer.set( xControl->getPeer(), UNO_QUERY ); do { if (!xGridPeer.is()) @@ -2579,13 +2587,13 @@ IMPL_LINK(FmXFormShell, OnSearchContextRequest, FmSearchContext*, pfmscContextIn if (sControlSource.getLength() && xValidFormFields->hasByName(sControlSource)) { // jetzt brauche ich das Control zum SdrObject - if (!xControlBehindModel.is()) + if (!xControl.is()) { - xControlBehindModel = GetControlFromModel(xControlModel); - DBG_ASSERT(xControlBehindModel.is(), "FmXFormShell::OnSearchContextRequest : didn't ::std::find a control with requested model !"); + xControl = impl_getControl( xControlModel, *pFormObject ); + DBG_ASSERT(xControl.is(), "FmXFormShell::OnSearchContextRequest : didn't ::std::find a control with requested model !"); } - if (IsSearchableControl(xControlBehindModel)) + if (IsSearchableControl(xControl)) { // alle Tests ueberstanden -> in die Liste mit aufnehmen strFieldList += sControlSource.getStr(); strFieldList += ';'; @@ -2601,7 +2609,7 @@ IMPL_LINK(FmXFormShell, OnSearchContextRequest, FmSearchContext*, pfmscContextIn m_arrRelativeGridColumn.Insert(-1, m_arrRelativeGridColumn.Count()); // und fuer die formatierte Suche ... - pfmscContextInfo->arrFields.push_back(Reference< XInterface>(xControlBehindModel, UNO_QUERY)); + pfmscContextInfo->arrFields.push_back(Reference< XInterface>(xControl, UNO_QUERY)); } } } @@ -2975,24 +2983,48 @@ void FmXFormShell::SetDesignMode(sal_Bool bDesign) } //------------------------------------------------------------------------------ -Reference< XControl> FmXFormShell::GetControlFromModel(const Reference< XControlModel>& xModel) +Reference< XControl> FmXFormShell::impl_getControl( const Reference< XControlModel >& i_rxModel, const FmFormObj& i_rKnownFormObj ) { - RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "svx", "Ocke.Janssen@sun.com", "FmXFormShell::GetControlFromModel" ); if ( impl_checkDisposed() ) return NULL; - Reference< XControlContainer> xControlContainer( getControlContainerForView() ); + Reference< XControl > xControl; + try + { + Reference< XControlContainer> xControlContainer( getControlContainerForView(), UNO_SET_THROW ); - Sequence< Reference< XControl> > seqControls( xControlContainer->getControls() ); - Reference< XControl>* pControls = seqControls.getArray(); - // ... die ich dann durchsuchen kann - for (int i=0; i > seqControls( xControlContainer->getControls() ); + const Reference< XControl >* pControls = seqControls.getArray(); + // ... die ich dann durchsuchen kann + for (sal_Int32 i=0; i xCurrentModel( xControl->getModel() ); + if ( xCurrentModel == i_rxModel ) + break; + xControl.clear(); + } + + if ( !xControl.is() ) + { + // fallabck (some controls might not have been created, yet, since they were never visible so far) + Reference< XControl > xContainerControl( xControlContainer, UNO_QUERY_THROW ); + const Window* pContainerWindow = VCLUnoHelper::GetWindow( xContainerControl->getPeer() ); + ENSURE_OR_THROW( pContainerWindow, "unexpected control container implementation" ); + + const SdrView* pSdrView = m_pShell ? m_pShell->GetFormView() : NULL; + ENSURE_OR_THROW( pSdrView, "no current view" ); + + xControl.set( i_rKnownFormObj.GetUnoControl( *pSdrView, *pContainerWindow ), UNO_QUERY_THROW ); + } + } + catch( const Exception& ) { - Reference< XControlModel> xSearchLoopModel( pControls[i]->getModel()); - if ((XControlModel*)xSearchLoopModel.get() == (XControlModel*)xModel.get()) - return pControls[i]; + DBG_UNHANDLED_EXCEPTION(); } - return Reference< XControl>(NULL); + + OSL_ENSURE( xControl.is(), "FmXFormShell::impl_getControl: no control found!" ); + return xControl; } //------------------------------------------------------------------------------ diff --git a/svx/source/inc/fmshimp.hxx b/svx/source/inc/fmshimp.hxx index 3f89adb42626..65a2572cd5af 100644 --- a/svx/source/inc/fmshimp.hxx +++ b/svx/source/inc/fmshimp.hxx @@ -163,6 +163,7 @@ typedef ::utl::ConfigItem FmXFormShell_CFGBASE; struct SdrViewEvent; class FmFormShell; class FmFormView; +class FmFormObj; class SAL_DLLPRIVATE FmXFormShell :public FmXFormShell_BASE ,public FmXFormShell_CFGBASE ,public ::svxform::OStaticDataAccessTools @@ -349,8 +350,11 @@ protected: void startListening(); void stopListening(); - ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl> GetControlFromModel(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel>& xModel); - // liefert das Control, welches das angegebene Model hat + ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl > + impl_getControl( + const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel>& i_rxModel, + const FmFormObj& i_rKnownFormObj + ); // sammelt in strNames die Namen aller Formulare static void impl_collectFormSearchContexts_nothrow( -- cgit From b381391e5d2ce79470b813cd11fdfbdea2ccc7c1 Mon Sep 17 00:00:00 2001 From: Frank Schönheit Date: Wed, 20 Jan 2010 18:45:26 +0000 Subject: reverting the fix for #i108325#, which caused #i108423#. Adding another, less invasive workaround. Still not the final solution, which is covered by issue 108357 --- svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'svx') diff --git a/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx b/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx index 5d00418a5729..531938b4a482 100644 --- a/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx +++ b/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx @@ -237,6 +237,8 @@ namespace sdr { namespace contact { void invalidate() const; + void invalidate() const; + public: inline const Reference< XControl >& getControl() const { return m_xControl; } }; @@ -305,6 +307,15 @@ namespace sdr { namespace contact { pWindow->Invalidate(); } + //-------------------------------------------------------------------- + void ControlHolder::invalidate() const + { + Window* pWindow = VCLUnoHelper::GetWindow( m_xControl->getPeer() ); + OSL_ENSURE( pWindow, "ControlHolder::invalidate: no implementation access!" ); + if ( pWindow ) + pWindow->Invalidate(); + } + //-------------------------------------------------------------------- ::basegfx::B2DVector ControlHolder::getZoom() const { @@ -1686,6 +1697,9 @@ namespace sdr { namespace contact { Reference< XControlModel > xControlModel( rViewContactOfUnoControl.GetSdrUnoObj().GetUnoControlModel() ); const ControlHolder& rControl( m_pVOCImpl->getExistentControl() ); + if ( !bHadControl && rControl.is() && rControl.isVisible() ) + rControl.invalidate(); + if ( !bHadControl && rControl.is() && rControl.isVisible() ) rControl.invalidate(); -- cgit From 63a0eea1522e2c5c9ab0b43e8dd215020b7f11d6 Mon Sep 17 00:00:00 2001 From: Frank Schönheit Date: Wed, 20 Jan 2010 19:31:43 +0000 Subject: #i10000# --- svx/source/form/fmshimp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'svx') diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx index 34b13151bd32..8c752910b15e 100644 --- a/svx/source/form/fmshimp.cxx +++ b/svx/source/form/fmshimp.cxx @@ -1609,7 +1609,7 @@ void FmXFormShell::ExecuteSearch() // jetzt brauche ich noch einen 'initial context' sal_Int16 nInitialContext = 0; Reference< XForm> xActiveForm( getActiveForm()); - for ( size_t i=0; i<(sal_Int32)m_aSearchForms.size(); ++i ) + for ( size_t i=0; i Date: Wed, 31 Mar 2010 15:47:30 +0200 Subject: nativea: #161909# Exchange names and URLs --- svx/source/dialog/docrecovery.src | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'svx') diff --git a/svx/source/dialog/docrecovery.src b/svx/source/dialog/docrecovery.src index 5bcde8bdf071..7c1532b71b55 100644 --- a/svx/source/dialog/docrecovery.src +++ b/svx/source/dialog/docrecovery.src @@ -370,7 +370,7 @@ TabPage RID_SVXPAGE_ERR_REP_WELCOME Pos = MAP_APPFONT( RECOV_COL1, RECOV_ROW2 ); Size = MAP_APPFONT( RECOV_CONTROLWIDTH, (RECOV_ROW7-RECOV_ROW2-RSC_SP_CTRL_Y) ); WordBreak = TRUE; - Text[ en-US ] = "This error report tool gathers information about how %PRODUCTNAME is working and sends it to Sun Microsystems to help improve future versions.\n\nIt's easy - just send the report without any further effort on your part by clicking 'Send' in the next dialog, or you can briefly describe how the error occurred and then click 'Send'. If you want to see the report, click the 'Show Report' button. No data will be sent if you click 'Do Not Send'.\n\nCustomer Privacy\nThe information gathered is limited to data concerning the state of %PRODUCTNAME %PRODUCTVERSION when the error occurred. Other information about passwords or document contents is not collected.\n\nThe information will only be used to improve the quality of %PRODUCTNAME and will not be shared with third parties.\nFor more information on Sun Microsystems' privacy policy, visit\nhttp://www.sun.com/privacy/"; + Text[ en-US ] = "This error report tool gathers information about how %PRODUCTNAME is working and sends it to Oracle to help improve future versions.\n\nIt's easy - just send the report without any further effort on your part by clicking 'Send' in the next dialog, or you can briefly describe how the error occurred and then click 'Send'. If you want to see the report, click the 'Show Report' button. No data will be sent if you click 'Do Not Send'.\n\nCustomer Privacy\nThe information gathered is limited to data concerning the state of %PRODUCTNAME %PRODUCTVERSION when the error occurred. Other information about passwords or document contents is not collected.\n\nThe information will only be used to improve the quality of %PRODUCTNAME and will not be shared with third parties.\nFor more information on Oracle's privacy policy, visit\nwww.oracle.com/html/services-privacy-policy.html"; }; FixedLine FL_RECOV_BOTTOM { @@ -472,7 +472,7 @@ TabPage RID_SVXPAGE_ERR_REP_SEND Pos = MAP_APPFONT( ERRSEND_COL0, ERRSEND_ROW12 ); Size = MAP_APPFONT( ERRSEND_CONTROLWIDTH2, RSC_CD_CHECKBOX_HEIGHT ); Check = FALSE; - Text[ en-US ] = "~I allow Sun Microsystems to contact me regarding this report."; + Text[ en-US ] = "~I allow Oracle to contact me regarding this report."; }; FixedText FT_ERRSEND_EMAILADDR { -- cgit From 6cf9f51705a4c8565858963d3f50c5489e5895a9 Mon Sep 17 00:00:00 2001 From: obo Date: Wed, 14 Apr 2010 16:13:17 +0200 Subject: #i10000# remove dublicate method declaration ControlHolder::invalidate --- svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'svx') diff --git a/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx b/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx index 531938b4a482..0aecac047121 100644 --- a/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx +++ b/svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx @@ -237,8 +237,6 @@ namespace sdr { namespace contact { void invalidate() const; - void invalidate() const; - public: inline const Reference< XControl >& getControl() const { return m_xControl; } }; @@ -307,15 +305,6 @@ namespace sdr { namespace contact { pWindow->Invalidate(); } - //-------------------------------------------------------------------- - void ControlHolder::invalidate() const - { - Window* pWindow = VCLUnoHelper::GetWindow( m_xControl->getPeer() ); - OSL_ENSURE( pWindow, "ControlHolder::invalidate: no implementation access!" ); - if ( pWindow ) - pWindow->Invalidate(); - } - //-------------------------------------------------------------------- ::basegfx::B2DVector ControlHolder::getZoom() const { -- cgit