Longkong.ColorPicker.Controls.ColorSwatchPanel.UpdatePositions C# (CSharp) Method

UpdatePositions() private method

private UpdatePositions ( int &x, int &y, int &swatchColumnNum, int &swatchRowNum ) : void
x int
y int
swatchColumnNum int
swatchRowNum int
return void
        private void UpdatePositions( ref int x, ref int y, ref int swatchColumnNum, ref int swatchRowNum )
        {
            if ( x + 2 * ( SWATCH_WIDTH + PADDING ) > m_swatchOuterRegionWidth ) {

                x = m_startX;
                y += SWATCH_HEIGHT + PADDING;

                swatchColumnNum = 0;
                swatchRowNum++;

            } else {
                x += SWATCH_WIDTH + PADDING;
            }
        }