diff options
Diffstat (limited to 'src/ui/documentwidget.c')
-rw-r--r-- | src/ui/documentwidget.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c index e09844c2..79678f56 100644 --- a/src/ui/documentwidget.c +++ b/src/ui/documentwidget.c | |||
@@ -567,7 +567,7 @@ static int scrollMax_DocumentWidget_(const iDocumentWidget *d) { | |||
567 | int sm = size_GmDocument(d->doc).y - height_Rect(bounds_Widget(constAs_Widget(d))) + | 567 | int sm = size_GmDocument(d->doc).y - height_Rect(bounds_Widget(constAs_Widget(d))) + |
568 | (hasSiteBanner_GmDocument(d->doc) ? 1 : 2) * d->pageMargin * gap_UI; | 568 | (hasSiteBanner_GmDocument(d->doc) ? 1 : 2) * d->pageMargin * gap_UI; |
569 | if (d->phoneToolbar) { | 569 | if (d->phoneToolbar) { |
570 | sm += size_Root(get_Root()).y - | 570 | sm += size_Root(constAs_Widget(d)->root).y - |
571 | top_Rect(boundsWithoutVisualOffset_Widget(d->phoneToolbar)); | 571 | top_Rect(boundsWithoutVisualOffset_Widget(d->phoneToolbar)); |
572 | } | 572 | } |
573 | return sm; | 573 | return sm; |
@@ -1354,7 +1354,7 @@ static void scrollBegan_DocumentWidget_(iAnyObject *any, int offset, uint32_t du | |||
1354 | /* Show and hide toolbar on scroll. */ | 1354 | /* Show and hide toolbar on scroll. */ |
1355 | if (deviceType_App() == phone_AppDeviceType) { | 1355 | if (deviceType_App() == phone_AppDeviceType) { |
1356 | if (prefs_App()->hideToolbarOnScroll && iAbs(offset) > 5) { | 1356 | if (prefs_App()->hideToolbarOnScroll && iAbs(offset) > 5) { |
1357 | showToolbars_Root(get_Root(), offset < 0); | 1357 | showToolbars_Root(as_Widget(d)->root, offset < 0); |
1358 | } | 1358 | } |
1359 | } | 1359 | } |
1360 | updateVisible_DocumentWidget_(d); | 1360 | updateVisible_DocumentWidget_(d); |