Update ooo320-m1
[ooovba.git] / applied_patches / 0346-oox-pptx-import-fix-wipe-transition.diff
blobcf354902581d3a981432cee8ad8a9f1ed1878ba0
1 diff -rup oox-orig-1/inc/oox/ppt/slidetransition.hxx oox/inc/oox/ppt/slidetransition.hxx
2 --- oox-orig-1/inc/oox/ppt/slidetransition.hxx 2009-05-13 14:04:15.000000000 +0200
3 +++ oox/inc/oox/ppt/slidetransition.hxx 2009-05-13 14:35:01.000000000 +0200
4 @@ -59,6 +59,8 @@ namespace oox { namespace ppt {
5 static sal_Int16 ooxToOdpEightDirections( ::sal_Int32 nOoxType );
6 static sal_Int16 ooxToOdpCornerDirections( ::sal_Int32 nOoxType );
7 static sal_Int16 ooxToOdpBorderDirections( ::sal_Int32 nOoxType );
8 + static sal_Int16 ooxToOdpSideDirections( ::sal_Int32 nOoxType );
9 + static sal_Bool ooxToOdpSideDirectionsDirectionNormal( ::sal_Int32 nOoxType );
11 void setOoxTransitionType( ::sal_Int32 OoxType,
12 ::sal_Int32 param1, ::sal_Int32 param2 );
13 diff -rup oox-orig-1/source/ppt/slidetransition.cxx oox/source/ppt/slidetransition.cxx
14 --- oox-orig-1/source/ppt/slidetransition.cxx 2009-05-13 14:04:17.000000000 +0200
15 +++ oox/source/ppt/slidetransition.cxx 2009-05-13 14:38:09.000000000 +0200
16 @@ -178,6 +178,39 @@ namespace oox { namespace ppt {
17 return nOdpDirection;
20 + sal_Int16 SlideTransition::ooxToOdpSideDirections( ::sal_Int32 nOoxType )
21 + {
22 + sal_Int16 nOdpDirection;
23 + switch( nOoxType )
24 + {
25 + case XML_d:
26 + case XML_u:
27 + nOdpDirection = TransitionSubType::TOPTOBOTTOM;
28 + break;
29 + case XML_l:
30 + case XML_r:
31 + nOdpDirection = TransitionSubType::LEFTTORIGHT;
32 + break;
33 + default:
34 + nOdpDirection= 0;
35 + break;
36 + }
37 + return nOdpDirection;
38 + }
40 + sal_Bool SlideTransition::ooxToOdpSideDirectionsDirectionNormal( ::sal_Int32 nOoxType )
41 + {
42 + sal_Bool nOdpDirection = true;
43 + switch( nOoxType )
44 + {
45 + case XML_u:
46 + case XML_l:
47 + nOdpDirection = false;
48 + break;
49 + }
50 + return nOdpDirection;
51 + }
53 sal_Int16 SlideTransition::ooxToOdpCornerDirections( ::sal_Int32 nOoxType )
55 sal_Int16 nOdpDirection;
56 @@ -293,7 +326,8 @@ namespace oox { namespace ppt {
57 break;
58 case NMSP_PPT|XML_wipe:
59 mnTransitionType = TransitionType::BARWIPE;
60 - mnTransitionSubType = ooxToOdpBorderDirections( param1 );
61 + mnTransitionSubType = ooxToOdpSideDirections( param1 );
62 + mbTransitionDirectionNormal = ooxToOdpSideDirectionsDirectionNormal( param1 );
63 break;
64 case NMSP_PPT|XML_split:
65 mnTransitionType = TransitionType::BARNDOORWIPE;