forked from rainmeter/rainmeter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMeterRotator.h
44 lines (34 loc) · 1.13 KB
/
MeterRotator.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/* Copyright (C) 2001 Rainmeter Project Developers
*
* This Source Code Form is subject to the terms of the GNU General Public
* License; either version 2 of the License, or (at your option) any later
* version. If a copy of the GPL was not distributed with this file, You can
* obtain one at <https://www.gnu.org/licenses/gpl-2.0.html>. */
#ifndef __METERROTATOR_H__
#define __METERROTATOR_H__
#include "Meter.h"
#include "GeneralImage.h"
class MeterRotator : public Meter
{
public:
MeterRotator(Skin* skin, const WCHAR* name);
virtual ~MeterRotator();
MeterRotator(const MeterRotator& other) = delete;
MeterRotator& operator=(MeterRotator other) = delete;
virtual UINT GetTypeID() { return TypeID<MeterRotator>(); }
virtual void Initialize();
virtual bool Update();
virtual bool Draw(Gfx::Canvas& canvas);
protected:
virtual void ReadOptions(ConfigParser& parser, const WCHAR* section);
private:
GeneralImage m_Image;
std::wstring m_ImageName;
double m_OffsetX;
double m_OffsetY;
double m_StartAngle;
double m_RotationAngle;
UINT m_ValueRemainder;
double m_Value;
};
#endif