From c77072d586bf7aca58e6465ceab3d11a0be0021f Mon Sep 17 00:00:00 2001 From: Yuqian Yang Date: Mon, 15 Dec 2025 21:27:33 +0800 Subject: Clean up mapper codes. --- include/cru/ui/mapper/SizeMapper.h | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'include/cru/ui/mapper/SizeMapper.h') diff --git a/include/cru/ui/mapper/SizeMapper.h b/include/cru/ui/mapper/SizeMapper.h index 4d781ee3..5c6eed2e 100644 --- a/include/cru/ui/mapper/SizeMapper.h +++ b/include/cru/ui/mapper/SizeMapper.h @@ -3,16 +3,7 @@ namespace cru::ui::mapper { class CRU_UI_API SizeMapper : public BasicMapper { - public: - CRU_DEFAULT_CONSTRUCTOR_DESTRUCTOR(SizeMapper) - - public: - bool SupportMapFromString() override { return true; } - bool SupportMapFromXml() override { return true; } - bool XmlElementIsOfThisType(xml::XmlElementNode* node) override; - - protected: - Size DoMapFromString(std::string str) override; - Size DoMapFromXml(xml::XmlElementNode* node) override; + CRU_UI_DECLARE_CAN_MAP_FROM_STRING(Size) + CRU_UI_DECLARE_CAN_MAP_FROM_XML_ELEMENT_TAG(Size, Size) }; } // namespace cru::ui::mapper -- cgit v1.2.3