xref: /aoo41x/main/vcl/source/gdi/impanmvw.hxx (revision 0d63794c)
1*0d63794cSAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*0d63794cSAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*0d63794cSAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*0d63794cSAndrew Rist  * distributed with this work for additional information
6*0d63794cSAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*0d63794cSAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*0d63794cSAndrew Rist  * "License"); you may not use this file except in compliance
9*0d63794cSAndrew Rist  * with the License.  You may obtain a copy of the License at
10*0d63794cSAndrew Rist  *
11*0d63794cSAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*0d63794cSAndrew Rist  *
13*0d63794cSAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*0d63794cSAndrew Rist  * software distributed under the License is distributed on an
15*0d63794cSAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*0d63794cSAndrew Rist  * KIND, either express or implied.  See the License for the
17*0d63794cSAndrew Rist  * specific language governing permissions and limitations
18*0d63794cSAndrew Rist  * under the License.
19*0d63794cSAndrew Rist  *
20*0d63794cSAndrew Rist  *************************************************************/
21*0d63794cSAndrew Rist 
22*0d63794cSAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #ifndef _SV_IMPANMVW_HXX
25cdf0e10cSrcweir #define _SV_IMPANMVW_HXX
26cdf0e10cSrcweir 
27cdf0e10cSrcweir #include <vcl/animate.hxx>
28cdf0e10cSrcweir 
29cdf0e10cSrcweir // ----------------
30cdf0e10cSrcweir // - ImplAnimView -
31cdf0e10cSrcweir // ----------------
32cdf0e10cSrcweir 
33cdf0e10cSrcweir class Animation;
34cdf0e10cSrcweir class OutputDevice;
35cdf0e10cSrcweir class VirtualDevice;
36cdf0e10cSrcweir struct AnimationBitmap;
37cdf0e10cSrcweir 
38cdf0e10cSrcweir class ImplAnimView
39cdf0e10cSrcweir {
40cdf0e10cSrcweir private:
41cdf0e10cSrcweir 
42cdf0e10cSrcweir 	Animation*		mpParent;
43cdf0e10cSrcweir 	OutputDevice*	mpOut;
44cdf0e10cSrcweir 	long			mnExtraData;
45cdf0e10cSrcweir 	Point			maPt;
46cdf0e10cSrcweir 	Point			maDispPt;
47cdf0e10cSrcweir 	Point			maRestPt;
48cdf0e10cSrcweir 	Size			maSz;
49cdf0e10cSrcweir 	Size			maSzPix;
50cdf0e10cSrcweir 	Size			maDispSz;
51cdf0e10cSrcweir 	Size			maRestSz;
52cdf0e10cSrcweir 	MapMode			maMap;
53cdf0e10cSrcweir 	Region			maClip;
54cdf0e10cSrcweir 	VirtualDevice*	mpBackground;
55cdf0e10cSrcweir 	VirtualDevice*	mpRestore;
56cdf0e10cSrcweir 	sal_uLong			mnActPos;
57cdf0e10cSrcweir 	Disposal		meLastDisposal;
58cdf0e10cSrcweir 	sal_Bool			mbPause;
59cdf0e10cSrcweir 	sal_Bool			mbFirst;
60cdf0e10cSrcweir 	sal_Bool			mbMarked;
61cdf0e10cSrcweir 	sal_Bool			mbHMirr;
62cdf0e10cSrcweir 	sal_Bool			mbVMirr;
63cdf0e10cSrcweir 
64cdf0e10cSrcweir 	void			ImplGetPosSize( const AnimationBitmap& rAnm, Point& rPosPix, Size& rSizePix );
65cdf0e10cSrcweir 	void			ImplDraw( sal_uLong nPos, VirtualDevice* pVDev );
66cdf0e10cSrcweir 
67cdf0e10cSrcweir public:
68cdf0e10cSrcweir 
69cdf0e10cSrcweir 					ImplAnimView( Animation* pParent, OutputDevice* pOut,
70cdf0e10cSrcweir 								  const Point& rPt, const Size& rSz, sal_uLong nExtraData,
71cdf0e10cSrcweir 								  OutputDevice* pFirstFrameOutDev = NULL );
72cdf0e10cSrcweir 					~ImplAnimView();
73cdf0e10cSrcweir 
74cdf0e10cSrcweir 	sal_Bool			ImplMatches( OutputDevice* pOut, long nExtraData ) const;
75cdf0e10cSrcweir 	void			ImplDrawToPos( sal_uLong nPos );
76cdf0e10cSrcweir 	void			ImplDraw( sal_uLong nPos );
77cdf0e10cSrcweir 	void			ImplRepaint();
78cdf0e10cSrcweir 	AInfo*			ImplCreateAInfo() const;
79cdf0e10cSrcweir 
ImplGetOutPos() const80cdf0e10cSrcweir 	const Point&	ImplGetOutPos() const { return maPt; }
81cdf0e10cSrcweir 
ImplGetOutSize() const82cdf0e10cSrcweir 	const Size&		ImplGetOutSize() const { return maSz; }
ImplGetOutSizePix() const83cdf0e10cSrcweir 	const Size&		ImplGetOutSizePix() const { return maSzPix; }
84cdf0e10cSrcweir 
ImplPause(sal_Bool bPause)85cdf0e10cSrcweir 	void			ImplPause( sal_Bool bPause ) { mbPause = bPause; }
ImplIsPause() const86cdf0e10cSrcweir 	sal_Bool			ImplIsPause() const { return mbPause; }
87cdf0e10cSrcweir 
ImplSetMarked(sal_Bool bMarked)88cdf0e10cSrcweir 	void			ImplSetMarked( sal_Bool bMarked ) { mbMarked = bMarked; }
ImplIsMarked() const89cdf0e10cSrcweir 	sal_Bool			ImplIsMarked() const { return mbMarked; }
90cdf0e10cSrcweir };
91cdf0e10cSrcweir 
92cdf0e10cSrcweir #endif
93