mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Change to use Gfx rendering
This commit is contained in:
@ -22,6 +22,7 @@
|
||||
#include "Error.h"
|
||||
#include "Litestep.h"
|
||||
#include "Rainmeter.h"
|
||||
#include "../Common/Gfx/Canvas.h"
|
||||
|
||||
using namespace Gdiplus;
|
||||
|
||||
@ -145,9 +146,11 @@ bool CMeterRotator::Update()
|
||||
** Draws the meter on the double buffer
|
||||
**
|
||||
*/
|
||||
bool CMeterRotator::Draw(Graphics& graphics)
|
||||
bool CMeterRotator::Draw(Gfx::Canvas& canvas)
|
||||
{
|
||||
if (!CMeter::Draw(graphics)) return false;
|
||||
if (!CMeter::Draw(canvas)) return false;
|
||||
|
||||
Gdiplus::Graphics& graphics = canvas.BeginGdiplusContext();
|
||||
|
||||
if (m_Image.IsLoaded())
|
||||
{
|
||||
@ -176,5 +179,7 @@ bool CMeterRotator::Draw(Graphics& graphics)
|
||||
graphics.ResetTransform();
|
||||
}
|
||||
|
||||
canvas.EndGdiplusContext();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user