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

Incorrect item index with header #72

Closed
khoben opened this issue Jul 7, 2021 · 0 comments · Fixed by #73
Closed

Incorrect item index with header #72

khoben opened this issue Jul 7, 2021 · 0 comments · Fixed by #73

Comments

@khoben
Copy link
Contributor

khoben commented Jul 7, 2021

Please complete the following information:

  • Library Version: v2.1.9
  • Affected Device(s): Xiaomi Mi 9 with Android 10

Describe the Bug:

createPowerMenu(this) {
    setHeaderView(R.layout.power_menu_header)
    ...
}.apply {
   setOnMenuItemClickListener { position, item ->
        position // incremented by one
   }
}

The item index is incremented by one if the headerView is set.

Expected Behavior:

Getting actual item index.

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

Successfully merging a pull request may close this issue.

1 participant