UI: Limit preview scrolling

This prevents the preview from being scrolled on forever.
This commit is contained in:
cg2121 2023-03-08 12:20:10 -06:00 • committed by Jim
commit b82c8ccdcf
3 changed files with 26 additions and 0 deletions

View file

@ -4665,6 +4665,7 @@ void OBSBasic::ResizePreview(uint32_t cx, uint32_t cy)
obs_get_video_info(&ovi);
if (isFixedScaling) {
ui->preview->ClampScrollingOffsets();
previewScale = ui->preview->GetScalingAmount();
GetCenterPosFromFixedScale(
int(cx), int(cy),