comparison mde/gui/widget/Ifaces.d @ 140:c94ec5594449

Fixed a bug with changing the minimal size and optimised it slightly.
author Diggory Hardy <diggory.hardy@gmail.com>
date Sun, 08 Feb 2009 15:20:11 +0000
parents 29a524e7c858
children 66c58e5b0062
comparison
equal deleted inserted replaced
139:29a524e7c858 140:c94ec5594449
53 IPopupParentWidget getParentIPPW (); 53 IPopupParentWidget getParentIPPW ();
54 54
55 /** Child widgets should call this on their parent if their minimal size 55 /** Child widgets should call this on their parent if their minimal size
56 * changes, since they cannot properly resize themselves. 56 * changes, since they cannot properly resize themselves.
57 * 57 *
58 * Children may depend on their parent resizing them if necessary to keep 58 * Parents $(I must) increase their child's size if the child is too small.
59 * width valid. To ease adjustments with layouts, widgets $(I may) enlarge 59 * Parents $(I must not) decrease their own size, even if they are not
60 * themselves, but shouldn't shrink themselves. Widgets may also depend on 60 * sizable; they may only decrease their childrens' sizes if it does not
61 * setPosition being called afterwards. 61 * affect their own (i.e. WidgetManager and FloatingAreaWidget).
62 *
63 * Child widgets may depend on setPosition being called afterwards.
62 * 64 *
63 * Params: 65 * Params:
64 * widget = The child widget calling the function 66 * widget = The child widget calling the function
65 * mw = New minimal width 67 * mw = New minimal width
66 * mh = New minimal height */ 68 * mh = New minimal height */
81 ANY_SUBWIDGETS = 2, /// Parents are resizable if any sub-widgets are 83 ANY_SUBWIDGETS = 2, /// Parents are resizable if any sub-widgets are
82 ALWAYS = 1, /// Parents are always resizable 84 ALWAYS = 1, /// Parents are always resizable
83 START_TRUE = 1, /// Flag set by ALWAYS and ALL_SUBWIDGETS 85 START_TRUE = 1, /// Flag set by ALWAYS and ALL_SUBWIDGETS
84 SUBWIDGETS = 2, /// Flag set by ALL_SUBWIDGETS and ANY_SUBWIDGETS 86 SUBWIDGETS = 2, /// Flag set by ALL_SUBWIDGETS and ANY_SUBWIDGETS
85 } 87 }
86 static const SIZABILITY = SIZABILITY_ENUM.ALL_SUBWIDGETS; /// ditto 88 static const SIZABILITY = SIZABILITY_ENUM.ANY_SUBWIDGETS; /// ditto
87 } 89 }
88 90
89 /****************************************************************************** 91 /******************************************************************************
90 * Interface for parents of popups and the widget manager. 92 * Interface for parents of popups and the widget manager.
91 * 93 *