Branch data Line data Source code
1 : : #ifndef INCLUDED_COM_SUN_STAR_AWT_GRADIENT_HPP
2 : : #define INCLUDED_COM_SUN_STAR_AWT_GRADIENT_HPP
3 : :
4 : : #include "sal/config.h"
5 : :
6 : : #include "com/sun/star/awt/Gradient.hdl"
7 : :
8 : : #include "com/sun/star/util/Color.hpp"
9 : : #include "com/sun/star/awt/GradientStyle.hpp"
10 : : #include "com/sun/star/uno/Type.hxx"
11 : : #include "cppu/unotype.hxx"
12 : : #include "sal/types.h"
13 : : #include "typelib/typeclass.h"
14 : : #include "typelib/typedescription.h"
15 : :
16 : : namespace com { namespace sun { namespace star { namespace awt {
17 : :
18 : 1498 : inline Gradient::Gradient() SAL_THROW(())
19 : : : Style(::com::sun::star::awt::GradientStyle_LINEAR)
20 : : , StartColor(0)
21 : : , EndColor(0)
22 : : , Angle(0)
23 : : , Border(0)
24 : : , XOffset(0)
25 : : , YOffset(0)
26 : : , StartIntensity(0)
27 : : , EndIntensity(0)
28 : 1498 : , StepCount(0)
29 : : {
30 : 1498 : }
31 : :
32 : : inline Gradient::Gradient(const ::com::sun::star::awt::GradientStyle& Style_, const ::sal_Int32& StartColor_, const ::sal_Int32& EndColor_, const ::sal_Int16& Angle_, const ::sal_Int16& Border_, const ::sal_Int16& XOffset_, const ::sal_Int16& YOffset_, const ::sal_Int16& StartIntensity_, const ::sal_Int16& EndIntensity_, const ::sal_Int16& StepCount_) SAL_THROW(())
33 : : : Style(Style_)
34 : : , StartColor(StartColor_)
35 : : , EndColor(EndColor_)
36 : : , Angle(Angle_)
37 : : , Border(Border_)
38 : : , XOffset(XOffset_)
39 : : , YOffset(YOffset_)
40 : : , StartIntensity(StartIntensity_)
41 : : , EndIntensity(EndIntensity_)
42 : : , StepCount(StepCount_)
43 : : {
44 : : }
45 : :
46 : : } } } }
47 : :
48 : : namespace com { namespace sun { namespace star { namespace awt {
49 : :
50 : 1864 : inline ::com::sun::star::uno::Type const & cppu_detail_getUnoType(SAL_UNUSED_PARAMETER ::com::sun::star::awt::Gradient const *) {
51 : : //TODO: On certain platforms with weak memory models, the following code can result in some threads observing that the_type points to garbage
52 : : static ::typelib_TypeDescriptionReference * the_type = 0;
53 [ + + ]: 1864 : if (the_type == 0) {
54 : 76 : ::typelib_static_type_init(&the_type, typelib_TypeClass_STRUCT, "com.sun.star.awt.Gradient");
55 : : }
56 : 1864 : return *reinterpret_cast< ::com::sun::star::uno::Type * >(&the_type);
57 : : }
58 : :
59 : : } } } }
60 : :
61 : 366 : inline ::com::sun::star::uno::Type const & SAL_CALL getCppuType(SAL_UNUSED_PARAMETER ::com::sun::star::awt::Gradient const *) SAL_THROW(()) {
62 : 366 : return ::cppu::UnoType< ::com::sun::star::awt::Gradient >::get();
63 : : }
64 : :
65 : : #endif // INCLUDED_COM_SUN_STAR_AWT_GRADIENT_HPP
|