summaryrefslogtreecommitdiff
path: root/dw/oofpositionedmgr.hh
diff options
context:
space:
mode:
authorSebastian Geerken <devnull@localhost>2014-12-22 14:59:02 +0100
committerSebastian Geerken <devnull@localhost>2014-12-22 14:59:02 +0100
commit1162688e7720815b17cc6b85033ec5b63eb6440e (patch)
treed8ca3b1c43b7155c19f9e2470fae469fdf78824f /dw/oofpositionedmgr.hh
parent424a01ce5c2dd3cadd3d7ca60c7b43283c183b02 (diff)
(Absolute) positions: distinguish between container (= parent widget) and reference widget.
Diffstat (limited to 'dw/oofpositionedmgr.hh')
-rw-r--r--dw/oofpositionedmgr.hh19
1 files changed, 13 insertions, 6 deletions
diff --git a/dw/oofpositionedmgr.hh b/dw/oofpositionedmgr.hh
index 04fa1629..713c2739 100644
--- a/dw/oofpositionedmgr.hh
+++ b/dw/oofpositionedmgr.hh
@@ -13,14 +13,17 @@ protected:
class Child: public lout::object::Object
{
public:
- core::Widget *widget;
+ core::Widget *widget, *reference;
OOFAwareWidget *generator;
int x, y;
- inline Child (core::Widget *widget, OOFAwareWidget *generator)
- { this->widget = widget; this->generator = generator; x = y = 0; }
+ inline Child (core::Widget *widget, OOFAwareWidget *generator,
+ core::Widget *reference)
+ { this->widget = widget; this->generator = generator;
+ this->reference = reference; x = y = 0; }
};
+ virtual bool isReference (core::Widget *widget) = 0;
virtual int containerBoxOffsetX () = 0;
virtual int containerBoxOffsetY () = 0;
virtual int containerBoxRestWidth () = 0;
@@ -56,9 +59,13 @@ protected:
int getPosBorder (core::style::Length cssValue, int refLength);
- bool isHPosComplete (core::Widget *child);
- bool isVPosComplete (core::Widget *child);
- bool isPosComplete (core::Widget *child);
+ bool isHPosComplete (Child *child);
+ bool isVPosComplete (Child *child);
+
+ bool isHPosCalculable (Child *child, bool allocated);
+ bool isVPosCalculable (Child *child, bool allocated);
+
+ bool isPosCalculable (Child *child, bool allocated);
void calcPosAndSizeChildOfChild (Child *child, int refWidth, int refHeight,
int *xPtr, int *yPtr, int *widthPtr,