Implementation of the service for the base CListItem. You should use it as a base class of your list item service. The most important method you have to override usually is getRequiredSize() which should return full size of the item(not including child items).
You can find more information in comments below. Overrided methods can be found in corresponding base interface.
class CListItemService :public virtual IListItemService
{
public:
CListItemService(CListItem *listitem);
virtual ~CListItemService() = default;
IListItemOwner *getOwner() override;
PointF getRequiredSize() override;
bool setOwner(IListItemOwner *value) override;
bool setParent(IListItem *value) override;
bool setSize(const PointF &value) override;
bool setPosition(const PointF &value) override;
bool setHovered(const bool value) override;
bool setDPI(const Point &value) override; // Do nothing. Return false. Should be implemented by child class
void Release() override;
void UpdateFromStyle() override;
void Render(const Matrix &matrix, const BLOCK *block, const bool last_pass, ITexture **clip) override;
void FreeResources() override;
bool MoveItem(IListItem *item, const int before) override;
bool KeyDown(const KEY key, const bool ctrl, const bool alt, const bool shift) override;
bool KeyUp(const KEY key, const bool ctrl, const bool alt, const bool shift) override;
bool Char(const wchar_t chr, const bool ctrl, const bool alt, const bool shift) override;
bool MouseDown(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift) override;
void MouseDownCancel() override;
bool MouseMove(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift) override;
bool MouseUp(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift) override;
bool MouseDoubleClick(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift) override;
bool MouseVerticalWheel(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift, const int delta) override;
bool MouseHorizontalWheel(const PointF &position, const bool left, const bool middle, const bool right, const bool ctrl, const bool alt, const bool shift, const int delta) override;
bool DropFiles(const PointF &position, const std::vector<String> &filenames) override;
};
Namespace: | nitisa |
Include: | Nitisa/Core/ListItem.h |