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
3.11.1
是
#FocusImageView public void startFocus(Point point) { RelativeLayout.LayoutParams params = (RelativeLayout.LayoutParams) getLayoutParams(); params.topMargin = point.y - getMeasuredHeight() / 2; params.leftMargin = point.x - getMeasuredWidth() / 2; setLayoutParams(params); setVisibility(View.VISIBLE); setFocusResource(mFocusImg); startAnimation(mAnimation); } 这部分代码存在问题,原因是首次点击,该视图并未绘制完成,getMeasuredHeight()和getMeasuredWidth()是获取不到宽高的,所以会产生偏移
The text was updated successfully, but these errors were encountered:
我自己给他加了个post处理的
Sorry, something went wrong.
补充一个新的解决方案就是 把View设置成invisible 不要设置成gone 因为首次点击没有绘制 所以无法准确定位
No branches or pull requests
Current use version?
当前使用的版本是多少?
Will this problem occur in demo?
Demo能否复现这问题?
Describe the problem or provide an error log?
描述问题或提供错误log?
The text was updated successfully, but these errors were encountered: