Skip to content
New issue

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

LayoutParams.layoutId confusing name. #28

Closed
PatrickDattilio opened this issue Feb 18, 2015 · 3 comments
Closed

LayoutParams.layoutId confusing name. #28

PatrickDattilio opened this issue Feb 18, 2015 · 3 comments
Assignees
Labels
Milestone

Comments

@PatrickDattilio
Copy link

Could we consider renaming layoutId? Perhaps to sectionId, section, or sectionManager? The value refers to the id/position of the section in the SectionLayoutManager.

final LayoutManager.LayoutParams lp = (LayoutManager.LayoutParams) holder.itemView.getLayoutParams();
lp.layoutId = 1;
final LayoutManager.LayoutParams lp = (LayoutManager.LayoutParams) holder.itemView.getLayoutParams();
lp.section = 1;
lp.sectionId = 1;
lp.sectionManager = 1;

I think one of these is easier to understand/read.

@TonicArtos
Copy link
Owner

I also don't like the naming, and I've considered using 'kind' too.

I think 'lp.sectionManager' can work.

To me, the other two don't imply matching a registered id for a SLM, and instead suggest incrementing section numbers for each section.

@PatrickDattilio
Copy link
Author

I agree, sectionManager seems to be the best fit!

@TonicArtos TonicArtos added bug and removed discussion labels Feb 18, 2015
@TonicArtos TonicArtos added this to the 4 milestone Feb 18, 2015
@TonicArtos TonicArtos self-assigned this Feb 18, 2015
@TonicArtos
Copy link
Owner

Agreed, change to sectionManager.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants