mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-12-14 12:09:36 +00:00
Emscripten port
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
namespace PortabilityLayer
|
||||
{
|
||||
EditboxWidget::EditboxWidget(const WidgetBasicState &state)
|
||||
: WidgetSpec<EditboxWidget>(state)
|
||||
: WidgetSpec<EditboxWidget, WidgetTypes::kEditbox>(state)
|
||||
, m_capacity(255)
|
||||
, m_length(0)
|
||||
, m_chars(nullptr)
|
||||
@@ -351,6 +351,11 @@ namespace PortabilityLayer
|
||||
return WidgetHandleStates::kIgnored;
|
||||
}
|
||||
|
||||
int16_t EditboxWidget::Capture(void *captureContext, const Point &pos, WidgetUpdateCallback_t callback)
|
||||
{
|
||||
return DefaultCapture(captureContext, pos, callback);
|
||||
}
|
||||
|
||||
Rect EditboxWidget::GetExpandedRect() const
|
||||
{
|
||||
return GetRect().Inset(-3, -3);
|
||||
@@ -1394,4 +1399,7 @@ namespace PortabilityLayer
|
||||
{ 0xf5, EditboxWidget::CharacterCategory_AlphaNumeric },
|
||||
{ 0xff, EditboxWidget::CharacterCategory_Punctuation },
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
PL_IMPLEMENT_WIDGET_TYPE(PortabilityLayer::WidgetTypes::kEditbox, PortabilityLayer::EditboxWidget)
|
||||
|
||||
Reference in New Issue
Block a user