FXGL icon indicating copy to clipboard operation
FXGL copied to clipboard

Design and implement default InventoryView

Open AlmasB opened this issue 5 years ago • 1 comments

In the fxgl-trade module we have Inventory API, we now need to provide a default InventoryView with some reasonable settings such as width and height and a default look.

Most of the time, developers will produce their own views using Inventory.

We should consider if the "sort" functionality responsibility of the view or the model. Example: sort by name...

AlmasB avatar Jan 31 '21 21:01 AlmasB

Something like the inventory in Zephyria

The API probably should be:

Inventory inventory = ...
InventoryView view = new InventoryView(inventory);

// view should be a JavaFX Node, so can be added to scene graph.

AlmasB avatar Feb 02 '21 20:02 AlmasB