Configuring UI for your devices
Last updated
Last updated
If you want UI that is displayed when you have a device selected, there are two approaches, using Standard/Data Driven UI, or providing a custom widget. Both can be provided, or neither.
This is our advised flow - you can provide button data in your device's item executor, and a widget will be automatically created, in the standardised style. As you modify the data, the widget will be updated automatically to reflect the changes.
This step is outlined in .
If you don't provide button data for your item executor (if you don't implement the M2_UsesStandardButtonsInterface
and mark it as true), this widget on the bottom left won't be added.
If you want to arrange things in a more bespoke way, you can provide a custom widget, inheriting the J_QuickbarExecutorWidget
class.
You can provide this either in your item's use item details (in the QuickbarWidgetClass
field), or in your item executor's OverrideWidgetClass
.
The Quickbar Executor Widget has the Notify Executor Ready
event, which can be used to get the executor that is controlling the item's behavior, and so listen to it, or notify it of UI interaction events.