In today's implementation, notifyLayout() for a control leads to a whole
layout rebuilt. Therefore, this function must be called _only_ if needed.
- Never needed in onResize() since we are already in the process of rebuilding
the whole layout. Calling notifyLayout() means the job is done twice.
- Never needed in onPositionChange() for the same reason as onResize().
- Not needed for a checkbox since already called in setImage() two lines above.
// Notify the window the tooltip has changed
notifyTooltipChange();
- // Refresh
- notifyLayout();
}
// Get the size of the control
const Position *pPos = getPosition();
if( !pPos )
- {
return;
- }
+
int height = pPos->getHeight();
// How many lines can be displayed ?
// Get the size of the control
const Position *pPos = getPosition();
if( !pPos )
- {
return;
- }
+
int height = pPos->getHeight();
// How many lines can be displayed ?
}
makeImage();
- notifyLayout();
}
void CtrlList::onPositionChange()
{
makeImage();
- notifyLayout();
}
// Redraw the control if the position has changed
m_firstPos = it;
makeImage();
- notifyLayout();
}
void CtrlTree::onPositionChange()
{
makeImage();
- notifyLayout();
}
void CtrlTree::handleEvent( EvtGeneric &rEvent )