~thumper/nux/next-changes

« back to all changes in this revision

Viewing changes to Nux/GridHLayout.cpp

Merge object cleanup branch.

Show diffs side-by-side

added added

removed removed

Lines of Context:
329
329
 
330
330
        if (_force_children_size)
331
331
        {
332
 
          (*it)->SetMinimumSize (_children_size.width, _children_size.height);
 
332
          (*it)->SetMinimumSize(_children_size.width, _children_size.height);
333
333
        }
334
334
 
335
 
        (*it)->SetGeometry (nux::Geometry (X, Y, _children_size.width, _children_size.height));
 
335
        (*it)->SetGeometry(nux::Geometry (X, Y, _children_size.width, _children_size.height));
336
336
 
337
337
        (*it)->ComputeLayout2();
338
338
 
340
340
 
341
341
        it++;
342
342
 
343
 
        if (!_partial_visibility && (X + _children_size.width > base.x + base.width))
 
343
        if ((!_partial_visibility) && (X + _children_size.width > base.x + base.width))
344
344
        {
345
345
          X = base.x + m_h_out_margin;
346
346
          Y += _children_size.height + m_v_in_margin;
347
347
 
348
348
          first_element_of_row = true;
349
 
          if(i < num_elements - 1)
 
349
          if (i < num_elements - 1)
350
350
            ++num_row;
351
351
        }
352
 
        else if (X > base.x + base.width)
 
352
        else if (X >= base.x + base.width)
353
353
        {
354
354
          X = base.x + m_h_out_margin;
355
355
          Y += _children_size.height + m_v_in_margin;
356
356
 
357
357
          first_element_of_row = true;
358
 
          if(i < num_elements - 1)
 
358
          if (i < num_elements - 1)
359
359
            ++num_row;
360
360
        }
361
361
      }