UiLiquidItemBase — Implementations of custom liquid items should inherit from this class.
class UiLiquidItemBase : : public SimpleWrappedObjectSernaApi::SimpleWrappedObject { public: enum Type { WIDGET = 0x01, UNDOCKED_TOOL = 0x02, VERTICAL_TOOL = 0x04, HORIZONTAL_TOOL = 0x08 }; // construct/copy/destruct UiLiquidItemBase(SernaApiBase * = 0); ~UiLiquidItemBase(); // public member functions UiItem item() const; SString itemClass() const; SString widgetClass() const; void showContextMenu(int, int) ; void releaseFocus() const; void grabFocus() const; bool doAttach() ; bool doDetach() ; void propertyChanged(const PropertyNode &) ; void escapePressed() ; void widgetFocusChanged(bool) ; QWidget * makeWidget(QWidget *, Type) ; };
UiLiquidItemBase
public member functionsUiItem item() const;
SString itemClass() const;
SString widgetClass() const;
Shows context menu for this liquid item at global pos (x,y)
Releases input focus and passes it back to the editor.
Set the focus to the widget corresponding to this UI item.
may be reimplemented for custom attach
may be reimplemented for custom detach
Called when item property changes.
invoked when escape button is pressed
May be reimplemented in custom item to indicate active focus.
Widget factory - must be implemented in custom item, and should return QWidget instance