diff options
Diffstat (limited to 'src/ImageViewer.cpp')
-rw-r--r-- | src/ImageViewer.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ImageViewer.cpp b/src/ImageViewer.cpp index ff35d06..fcc3b3b 100644 --- a/src/ImageViewer.cpp +++ b/src/ImageViewer.cpp @@ -339,6 +339,8 @@ namespace QuickMedia { const double first_image_height = get_page_size(0).y; const double last_image_height = get_page_size((int)image_data.size() - 1).y; + // TODO: Limit bottom scroll if page_offset is smaller than window height + const double top_scroll = std::max(0.0, -first_image_height * 0.5 + window_size.y * 0.5); const double bottom_scroll = std::min(window_size.y, window_size.y + last_image_height * 0.5 - window_size.y * 0.5); if(scroll > top_scroll) { |