mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 08:15:30 +03:00
Fix pageCount calculation
This commit is contained in:
parent
b10412ac9b
commit
4c114db666
1 changed files with 1 additions and 1 deletions
|
@ -493,7 +493,7 @@ static void cmsMenuCountPage(displayPort_t *pDisplay)
|
||||||
{
|
{
|
||||||
OSD_Entry *p;
|
OSD_Entry *p;
|
||||||
for (p = currentCtx.menu->entries; p->type != OME_END; p++);
|
for (p = currentCtx.menu->entries; p->type != OME_END; p++);
|
||||||
pageCount = (p - currentCtx.menu->entries) / MAX_MENU_ITEMS(pDisplay) + 1;
|
pageCount = (p - currentCtx.menu->entries - 1) / MAX_MENU_ITEMS(pDisplay) + 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
long cmsMenuChange(displayPort_t *pDisplay, const void *ptr)
|
long cmsMenuChange(displayPort_t *pDisplay, const void *ptr)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue