summaryrefslogtreecommitdiff
path: root/new/ui.h
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2015-04-12 19:19:06 -0400
committerPietro Gagliardi <[email protected]>2015-04-12 19:19:06 -0400
commit54ba083fe9665d8213ffbcb4f65913f5d07132e5 (patch)
tree60c4767e7d206a49edb561cc34b8ab3b63790321 /new/ui.h
parent74e4238fe73c40473b219409ad80e819528b947e (diff)
Set up the foundation for the new Windows uiParent.
Diffstat (limited to 'new/ui.h')
-rw-r--r--new/ui.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/new/ui.h b/new/ui.h
index f9a0b26..0a35231 100644
--- a/new/ui.h
+++ b/new/ui.h
@@ -86,12 +86,16 @@ struct uiParent {
#define uiParentHandle(p) ((*((p)->Handle))((p)))
// SetChild sets the uiControl that this uiParent relegates.
- // It calls uiControl.SetParent().
+ // It calls uiControl.SetParent() which should, in turn, call uiParent.Update().
+ // The uiParent should already not have a child and the uiControl should already not have a parent.
+ //
+ // child can be NULL, in which case the uiParent has no children.
+ // This form should be called by uiControl.RemoveParent().
void (*SetChild)(uiParent *p, uiControl *child);
#define uiParentSetChild(p, child) ((*((p)->SetChild))((p), (child)))
// SetMargins sets the margins of the uiParent to the given margins.
- // It then updates the uiParent to make the margins take effect.
+ // It does not call uiParent.Update(); its caller must.
// The units of the margins are backend-defined.
// The initial margins are all 0.
void (*SetMargins)(uiParent *p, intmax_t left, intmax_t top, intmax_t right, intmax_t bottom);