1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 24 25 #ifndef OOX_PPT_SLIDETRANSITION 26 #define OOX_PPT_SLIDETRANSITION 27 28 #include <rtl/ustring.hxx> 29 30 #include <com/sun/star/animations/XTransitionFilter.hpp> 31 32 namespace oox { class PropertyMap; } 33 34 namespace oox { namespace ppt { 35 36 class SlideTransition 37 { 38 public: 39 SlideTransition(); 40 explicit SlideTransition(const ::rtl::OUString & ); 41 42 void setSlideProperties( PropertyMap& props ); 43 void setTransitionFilterProperties( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTransitionFilter > & xFilter ); 44 45 void setOoxTransitionSpeed( sal_Int32 nToken ); setFadeColor(sal_Int32 nColor)46 void setFadeColor( sal_Int32 nColor ) 47 { mnFadeColor = nColor; } setMode(sal_Bool bMode)48 void setMode( sal_Bool bMode ) 49 { mbMode = bMode; } 50 51 static sal_Int16 ooxToOdpDirection( ::sal_Int32 nOoxType ); 52 static sal_Int16 ooxToOdpEightDirections( ::sal_Int32 nOoxType ); 53 static sal_Int16 ooxToOdpCornerDirections( ::sal_Int32 nOoxType ); 54 static sal_Int16 ooxToOdpBorderDirections( ::sal_Int32 nOoxType ); 55 static sal_Int16 ooxToOdpSideDirections( ::sal_Int32 nOoxType ); 56 static sal_Bool ooxToOdpSideDirectionsDirectionNormal( ::sal_Int32 nOoxType ); 57 58 void setOoxTransitionType( ::sal_Int32 OoxType, 59 ::sal_Int32 param1, ::sal_Int32 param2 ); 60 private: 61 ::sal_Int16 mnTransitionType; 62 ::sal_Int16 mnTransitionSubType; 63 ::sal_Bool mbTransitionDirectionNormal; 64 ::sal_Int16 mnAnimationSpeed; 65 ::sal_Int32 mnFadeColor; 66 ::sal_Bool mbMode; /**< http://api.openoffice.org/docs/common/ref/com/sun/star/animations/XTransitionFilter.html Mode property */ 67 }; 68 69 } } 70 71 #endif 72