Fixed rows before columns inconsistency.
This commit is contained in:
@ -18,7 +18,7 @@ bool sandboxSceneInit(sandboxscene_t *game) {
|
||||
|
||||
framedTextMenuInit(&menu, &game->font, &game->texture);
|
||||
|
||||
gridAddBreakpoint(&menu.menu.menu.grid, -1, 3, 1, 0, 0);
|
||||
gridAddBreakpoint(&menu.menu.menu.grid, -1, 2, 3, 0, 0);
|
||||
|
||||
gridchild_t *child = textMenuListAdd(&menu.menu, "First");
|
||||
gridChildAddBreakpoint(child, 0,0, 1,1);
|
||||
@ -26,6 +26,8 @@ bool sandboxSceneInit(sandboxscene_t *game) {
|
||||
gridChildAddBreakpoint(child, 0,1, 1,1);
|
||||
child = textMenuListAdd(&menu.menu, "Third");
|
||||
gridChildAddBreakpoint(child, 0,2, 1,1);
|
||||
child = textMenuListAdd(&menu.menu, "Fourth");
|
||||
gridChildAddBreakpoint(child, 1,0, 1,1);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ void gridInit(grid_t *grid) {
|
||||
|
||||
uint8_t gridAddBreakpoint(
|
||||
grid_t *grid, float width,
|
||||
uint8_t rows, uint8_t columns,
|
||||
uint8_t columns, uint8_t rows,
|
||||
float gutterX, float gutterY
|
||||
) {
|
||||
uint8_t i = grid->breakpointCount++;
|
||||
|
@ -20,15 +20,15 @@ void gridInit(grid_t *grid);
|
||||
*
|
||||
* @param grid Grid to add to.
|
||||
* @param width Screen dimension width of the breakpoint.
|
||||
* @param rows How many rows at this breakpoint.
|
||||
* @param columns How many columns at this breakpoint.
|
||||
* @param rows How many rows at this breakpoint.
|
||||
* @param gutterX Gutter X at this breakpoint.
|
||||
* @param gutterY Gutter Y at this breakpoint.
|
||||
* @return Index of the breakpoint within the grid.
|
||||
*/
|
||||
uint8_t gridAddBreakpoint(
|
||||
grid_t *grid, float width,
|
||||
uint8_t rows, uint8_t columns,
|
||||
uint8_t columns, uint8_t rows,
|
||||
float gutterX, float gutterY
|
||||
);
|
||||
|
||||
|
Reference in New Issue
Block a user