Use GLView.offsetTopAndBottom(int) in ScrollLayoutManager
This commit is contained in:
1 parent
2c8b56c3bb
commit
be9ed688c8
1 file changed
+2
-2
@@ -214,7 +214,7 @@ public class ScrollLayoutManager extends GalleryView.LayoutManager {
|
||||
// Translate pages
|
||||
pages = mPages.iterator();
|
||||
for (int i = 0; i < pageSize; i++) {
|
||||
pages.next().bounds().offset(0, -offset);
|
||||
pages.next().offsetTopAndBottom(-offset);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -375,7 +375,7 @@ public class ScrollLayoutManager extends GalleryView.LayoutManager {
|
||||
mOffset += translate;
|
||||
// Translate pages
|
||||
for (GalleryPageView page : pages) {
|
||||
page.bounds().offset(0, translate);
|
||||
page.offsetTopAndBottom(-translate);
|
||||
}
|
||||
// Break if no previous
|
||||
if (mIndex <= 0) {
|
||||
|
||||
Reference in new issue
Block a user