There is not really a point in having BasicContainer as most of it's
functions needs an interface in Widget, therefore BasicContainer and
Widgets should be merge.
Merging the two classes have several benefits:
* Every widget will be considered a container internally in Guichan making
it much easier to handle widgets
* Code for drawing and logic can be put in one place, the widget class,
instead of being spread out, as the case is with BasicContainer and Widget,
making it easier to change the way Guichan draws itself or performs logic
* As every widget will be considered a container in Guichan, taking care of
drawing calls and logic calls for children can be handled automatically by
the Widget class (no need for logicChildren or drawChildren calls)
* A lot of dummy code in Widget, such as getWidgetAt, can be replaced by
proper implementations
Another benefit is that making Widget a container follows the composite
design pattern better making Guichan more intuitive for people with design
pattern knowledge.
Original issue reported on code.google.com by olof.nae...@gmail.com on 23 Sep 2008 at 4:33
Original issue reported on code.google.com by
olof.nae...@gmail.com
on 23 Sep 2008 at 4:33