Mercurial > projects > mde
comparison mde/gui/widget/Ifaces.d @ 103:42e241e7be3e
ContentList content type; getting content items/lists from Options generically via content.Items, and a new addContent widget function. Several improvements to generic handling of content. New button-with-text widget.
Some tidy-up.
Some name changes, to increase uniformity.
Bug-fix: floating widgets of fixed size could previously be made larger than intended from config dimdata.
author | Diggory Hardy <diggory.hardy@gmail.com> |
---|---|
date | Tue, 25 Nov 2008 18:01:44 +0000 |
parents | 5de5810e3516 |
children | 08651e8a8c51 |
comparison
equal
deleted
inserted
replaced
102:ba035eba07b4 | 103:42e241e7be3e |
---|---|
52 // Loading/saving: | 52 // Loading/saving: |
53 /** Create a widget by ID. | 53 /** Create a widget by ID. |
54 * | 54 * |
55 * Params: | 55 * Params: |
56 * id = Identifier, within data files, of the data for the widget. | 56 * id = Identifier, within data files, of the data for the widget. |
57 * data = Pass this data to the widget, not data looked up via id. | |
57 * content = An IContent may be passed to some widgets on creation. | 58 * content = An IContent may be passed to some widgets on creation. |
58 * | 59 * |
59 * Creates a widget, using the widget data with index id. Widget data is loaded from files, | 60 * Creates a widget, using the widget data with index id. Widget data is loaded from files, |
60 * and per design (multiple gui layouts, called designs, may exist; data is per design). | 61 * and per design (multiple gui layouts, called designs, may exist; data is per design). |
61 */ | 62 * |
63 * The function taking a WidgetData is intended for modifier functions and only exists to | |
64 * avoid circular dependencies between the modifier function's module and createWidget. */ | |
62 IChildWidget makeWidget (widgetID id, IContent content = null); | 65 IChildWidget makeWidget (widgetID id, IContent content = null); |
63 | 66 IChildWidget makeWidget (widgetID id, WidgetData data, IContent content = null); |
64 /// Get dimensional data. | 67 |
68 /** Get dimension data for a widget. */ | |
65 wdims dimData (widgetID id); | 69 wdims dimData (widgetID id); |
66 | 70 |
67 /** Record some changes, for saving. Should only be called from IWidget.saveChanges() to avoid | 71 /** Record some changes, for saving. Should only be called from IWidget.saveChanges() to avoid |
68 * multiple calls for instanced widgets of same id. | 72 * multiple calls for instanced widgets of same id. |
69 * | 73 * |