+ if (tool->GetId() == -1)
+ {
+ y += 6;
+ continue;
+ }
+ tool->m_x = m_xMargin;
+ tool->m_y = y;
+ y += m_defaultHeight + 6;
+
+ // Calculate the maximum height or width (depending on style)
+ // so we know how to size the toolbar in Realize.
+ // We could get the size of the tool instead of the
+ // default bitmap size
+ if (m_maxWidth < (m_defaultWidth + 2*(m_xMargin + 2)))
+ m_maxWidth = (m_defaultWidth + 2*(m_xMargin + 2)) ;
+ }
+ else
+ {
+ if (tool->GetId() == -1)
+ {
+ x += 6;
+ continue;
+ }
+ tool->m_x = x;
+ tool->m_y = m_yMargin;
+ x += m_defaultWidth + 6;
+
+ // Calculate the maximum height or width (depending on style)
+ // so we know how to size the toolbar in Realize.
+ // We could get the size of the tool instead of the
+ // default bitmap size
+ if (m_maxHeight < (m_defaultHeight + 2*(m_yMargin + 2)))
+ m_maxHeight = (m_defaultHeight + 2*(m_yMargin + 2)) ;