Skip to content

Commit

Permalink
tweak scroll bar position
Browse files Browse the repository at this point in the history
  • Loading branch information
brindy committed Feb 1, 2024
1 parent 229de25 commit a83f693
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions DuckDuckGo/SwipeTabsCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,6 @@ extension SwipeTabsCoordinator: UICollectionViewDelegate {
print("***", #function, "image preview")
createPreviewFromImage(image)
} else if tab?.link == nil {
// either the tab or link is nil - either way transition to the home screen
// TODO handle favorites
print("***", #function, "new tab home screen preview")
createPreviewFromLogoContainerWithSize(targetFrame.size)
} else {
Expand Down Expand Up @@ -291,11 +289,11 @@ extension SwipeTabsCoordinator {

func addressBarPositionChanged(isTop: Bool) {
if isTop {
collectionView.horizontalScrollIndicatorInsets.bottom = -2
collectionView.horizontalScrollIndicatorInsets.bottom = -1.5
collectionView.hitTestInsets.top = -12
collectionView.hitTestInsets.bottom = 0
} else {
collectionView.horizontalScrollIndicatorInsets.bottom = collectionView.frame.height - 8
collectionView.horizontalScrollIndicatorInsets.bottom = collectionView.frame.height - 7.5
collectionView.hitTestInsets.top = 0
collectionView.hitTestInsets.bottom = -12
}
Expand Down

0 comments on commit a83f693

Please sign in to comment.