mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-09-23 23:00:42 +00:00
29 lines
626 B
C++
29 lines
626 B
C++
#pragma once
|
|
|
|
#include "PascalStr.h"
|
|
#include "PLWidgets.h"
|
|
|
|
namespace PortabilityLayer
|
|
{
|
|
class ButtonWidget final : public WidgetSpec<ButtonWidget>
|
|
{
|
|
public:
|
|
explicit ButtonWidget(const WidgetBasicState &state);
|
|
|
|
bool Init(const WidgetBasicState &state) override;
|
|
|
|
void DrawControl(DrawSurface *surface) override;
|
|
|
|
WidgetHandleState_t ProcessEvent(const TimeTaggedVOSEvent &evt) override;
|
|
|
|
void OnEnabledChanged() override;
|
|
|
|
int16_t Capture(const Point &pos, WidgetUpdateCallback_t callback) override;
|
|
|
|
private:
|
|
void DrawControlInternal(DrawSurface *surface, bool inverted);
|
|
|
|
PascalStr<255> m_text;
|
|
};
|
|
}
|