update ooo310-m15
[ooovba.git] / applied_patches / 0880-sd-pptx-crash-fix.diff
blobe5c5c0295d656e30d4dfe7e52bad55135de05828
1 Author: sj
2 Date: Wed May 13 12:59:08 2009
3 New Revision: 271862
5 Log:
6 #i101563# fixed crash when loading pptx document
8 Modified:
9 cws/impress171/sd/source/ui/unoidl/unopback.cxx
11 Modified: cws/impress171/sd/source/ui/unoidl/unopback.cxx
12 ==============================================================================
13 --- sd/source/ui/unoidl/unopback.cxx Wed May 13 12:39:35 2009 (r271861)
14 +++ sd/source/ui/unoidl/unopback.cxx Wed May 13 12:59:08 2009 (r271862)
15 @@ -140,22 +140,56 @@
16 if( pAny )
18 OUString aPropertyName( OUString::createFromAscii(pMap->pName));
19 - if ( pMap->nWID == XATTR_FILLBITMAP )
20 + switch( pMap->nWID )
22 - if ( ( ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XBitmap >*)0) ) ||
23 - ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic >*)0) ) ) &&
24 - ( pMap->nMemberId == MID_BITMAP ) )
25 + case XATTR_FILLFLOATTRANSPARENCE :
26 + case XATTR_FILLGRADIENT :
28 - setPropertyValue( aPropertyName, *pAny );
29 + if ( ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::awt::Gradient*)0) )
30 + && ( pMap->nMemberId == MID_FILLGRADIENT ) )
31 + {
32 + setPropertyValue( aPropertyName, *pAny );
33 + }
34 + else if ( ( pAny->getValueType() == ::getCppuType((const ::rtl::OUString*)0) ) &&
35 + ( pMap->nMemberId == MID_NAME ) )
36 + {
37 + setPropertyValue( aPropertyName, *pAny );
38 + }
40 - else if ( ( pAny->getValueType() == ::getCppuType((const ::rtl::OUString*)0) ) &&
41 - ( ( pMap->nMemberId == MID_NAME ) || ( pMap->nMemberId == MID_GRAFURL ) ) )
42 + break;
43 + case XATTR_FILLHATCH :
45 - setPropertyValue( aPropertyName, *pAny );
46 + if ( ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::drawing::Hatch*)0) )
47 + && ( pMap->nMemberId == MID_FILLHATCH ) )
48 + {
49 + setPropertyValue( aPropertyName, *pAny );
50 + }
51 + else if ( ( pAny->getValueType() == ::getCppuType((const ::rtl::OUString*)0) ) &&
52 + ( pMap->nMemberId == MID_NAME ) )
53 + {
54 + setPropertyValue( aPropertyName, *pAny );
55 + }
57 - }
58 - else
59 - setPropertyValue( aPropertyName, *pAny );
60 + break;
61 + case XATTR_FILLBITMAP :
62 + {
63 + if ( ( ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XBitmap >*)0) ) ||
64 + ( pAny->getValueType() == ::getCppuType((const ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic >*)0) ) ) &&
65 + ( pMap->nMemberId == MID_BITMAP ) )
66 + {
67 + setPropertyValue( aPropertyName, *pAny );
68 + }
69 + else if ( ( pAny->getValueType() == ::getCppuType((const ::rtl::OUString*)0) ) &&
70 + ( ( pMap->nMemberId == MID_NAME ) || ( pMap->nMemberId == MID_GRAFURL ) ) )
71 + {
72 + setPropertyValue( aPropertyName, *pAny );
73 + }
74 + }
75 + break;
77 + default:
78 + setPropertyValue( aPropertyName, *pAny );
79 + }
81 pMap++;
84 ---------------------------------------------------------------------
85 To unsubscribe, e-mail: allsvn-unsubscribe@openoffice.org
86 For additional commands, e-mail: allsvn-help@openoffice.org