// When using gamepad, we project the reference nav bounding box into window visible area.
// When using gamepad, we project the reference nav bounding box into window visible area.
// This is to allow resuming navigation inside the visible area after doing a large amount of scrolling, since with gamepad every movements are relative
// This is to allow resuming navigation inside the visible area after doing a large amount of scrolling, since with gamepad every movements are relative
// (can't focus a visible object like we can with the mouse).
// (can't focus a visible object like we can with the mouse).
window_rect_rel.Expand(ImVec2(-ImMin(window_rect_rel.GetWidth(),pad),-ImMin(window_rect_rel.GetHeight(),pad)));// Terrible approximation for the intent of starting navigation from first fully visible item
IMGUI_DEBUG_LOG_NAV("[nav] NavMoveRequest: clamp NavRectRel for gamepad move\n");
floatpad_y=ImMin(inner_rect_rel.GetHeight(),window->CalcFontSize()*0.5f);// Terrible approximation for the intent of starting navigation from first fully visible item
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals. Work in progress versions typically starts at XYY99 then bounce up to XYY00, XYY01 etc. when release tagging happens)
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals. Work in progress versions typically starts at XYY99 then bounce up to XYY00, XYY01 etc. when release tagging happens)