LibreOffice Module vcl (master)  1
impanmvw.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
20 #ifndef INCLUDED_VCL_SOURCE_GDI_IMPANMVW_HXX
21 #define INCLUDED_VCL_SOURCE_GDI_IMPANMVW_HXX
22 
24 #include <vcl/vclptr.hxx>
25 
26 class Animation;
27 class OutputDevice;
28 class VirtualDevice;
29 struct AnimationBitmap;
30 
31 struct AInfo
32 {
36  void* pViewData;
37  long nExtraData;
38  bool bPause;
39 
40  AInfo();
41 };
42 
43 
45 {
46 private:
47 
48  friend class Animation;
49 
52  long const mnExtraData;
53  Point const maPt;
56  Size const maSz;
65  bool mbIsPaused;
66  bool mbIsMarked;
69 
70 public:
71  ~ImplAnimView();
72 private:
73  ImplAnimView( Animation* pParent, OutputDevice* pOut,
74  const Point& rPt, const Size& rSz, sal_uLong nExtraData,
75  OutputDevice* pFirstFrameOutDev = nullptr );
76 
77  bool matches( OutputDevice* pOut, long nExtraData ) const;
78  void drawToPos( sal_uLong nPos );
79  void draw( sal_uLong nPos, VirtualDevice* pVDev=nullptr );
80  void repaint();
81  AInfo* createAInfo() const;
82 
83  void getPosSize( const AnimationBitmap& rAnm, Point& rPosPix, Size& rSizePix );
84 
85  const Point& getOutPos() const { return maPt; }
86 
87  const Size& getOutSizePix() const { return maSzPix; }
88 
89  void pause( bool bIsPaused ) { mbIsPaused = bIsPaused; }
90  bool isPause() const { return mbIsPaused; }
91 
92  void setMarked( bool bIsMarked ) { mbIsMarked = bIsMarked; }
93  bool isMarked() const { return mbIsMarked; }
94 };
95 
96 #endif
97 
98 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
const Point & getOutPos() const
Definition: impanmvw.hxx:85
long const mnExtraData
Definition: impanmvw.hxx:52
void setMarked(bool bIsMarked)
Definition: impanmvw.hxx:92
void pause(bool bIsPaused)
Definition: impanmvw.hxx:89
bool mbIsMarked
Definition: impanmvw.hxx:66
long nExtraData
Definition: impanmvw.hxx:37
Point aStartOrg
Definition: impanmvw.hxx:33
void getPosSize(const AnimationBitmap &rAnm, Point &rPosPix, Size &rSizePix)
Definition: impanmvw.cxx:114
sal_uIntPtr sal_uLong
bool isPause() const
Definition: impanmvw.hxx:90
Size maDispSz
Definition: impanmvw.hxx:58
void * pViewData
Definition: impanmvw.hxx:36
bool matches(OutputDevice *pOut, long nExtraData) const
Definition: impanmvw.cxx:99
void draw(sal_uLong nPos, VirtualDevice *pVDev=nullptr)
Definition: impanmvw.cxx:183
bool const mbIsMirroredHorizontally
Definition: impanmvw.hxx:67
void repaint()
Definition: impanmvw.cxx:306
VclPtr< OutputDevice > pOutDev
Definition: impanmvw.hxx:35
VclPtr< VirtualDevice > mpRestore
Definition: impanmvw.hxx:62
AInfo * createAInfo() const
Definition: impanmvw.cxx:317
VclPtr< VirtualDevice > mpBackground
Definition: impanmvw.hxx:61
void drawToPos(sal_uLong nPos)
Definition: impanmvw.cxx:151
Size maSzPix
Definition: impanmvw.hxx:57
bool const mbIsMirroredVertically
Definition: impanmvw.hxx:68
const Size & getOutSizePix() const
Definition: impanmvw.hxx:87
Animation *const mpParent
Definition: impanmvw.hxx:50
Some things multiple-inherit from VclAbstractDialog and OutputDevice, so we need to use virtual inher...
Definition: outdev.hxx:304
Disposal meLastDisposal
Definition: impanmvw.hxx:64
ImplAnimView(Animation *pParent, OutputDevice *pOut, const Point &rPt, const Size &rSz, sal_uLong nExtraData, OutputDevice *pFirstFrameOutDev=nullptr)
Definition: impanmvw.cxx:29
Point const maPt
Definition: impanmvw.hxx:53
Size const maSz
Definition: impanmvw.hxx:56
bool bPause
Definition: impanmvw.hxx:38
bool isMarked() const
Definition: impanmvw.hxx:93
Point maDispPt
Definition: impanmvw.hxx:54
vcl::Region maClip
Definition: impanmvw.hxx:60
Point maRestPt
Definition: impanmvw.hxx:55
bool mbIsPaused
Definition: impanmvw.hxx:65
Size maRestSz
Definition: impanmvw.hxx:59
sal_uLong mnActPos
Definition: impanmvw.hxx:63
VclPtr< OutputDevice > mpRenderContext
Definition: impanmvw.hxx:51
Size aStartSize
Definition: impanmvw.hxx:34
Disposal