We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
问题 及 方案 见图:
WMMagicScrollView.m中的 - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context ; bug: maximumContentOffsetY 这个数值必须是像素的整数倍, 否则 196 行 设置contentOffset的值并不会精准, 系统会自动调整contentOffset像素对齐, 这时 207 行的判断是错误, 导致otherScrollView无法被滚动 例如: maximumContentOffsetY = 151.72 在3x屏幕时, 设置给scrollView的contentOffset后, 会被系统纠正为contentOffset = 151.666... , 207 行的判断 self.contentOffset.y(151.666...) < maximumContentOffsetY(151.72) 将会一直满足 fix: 方案1: 对齐像素 添加 maximumContentOffsetY = roundf(maximumContentOffsetY / (1/[UIScreen mainScreen].scale)) * (1/[UIScreen mainScreen].scale); 方案2: 也是对齐像素, 直接取整 maximumContentOffsetY = roundf(maximumContentOffsetY); // 1: maximumContentOffsetY = roundf(maximumContentOffsetY / (1/[UIScreen mainScreen].scale)) * (1/[UIScreen mainScreen].scale); // 2: maximumContentOffsetY = roundf(maximumContentOffsetY)
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
问题 及 方案 见图:
The text was updated successfully, but these errors were encountered: