Skip to content

How to use in java: setMenuItemClickListener? #101

Description

@panovvitalik

How I can implement menu item click on java? Which parameter type I should provide to setMenuItemClickListener method

ContextMenuDialogFragment contextMenuDialogFragment = ContextMenuDialogFragment.newInstance(menuParams);
contextMenuDialogFragment.setMenuItemClickListener(???);

He show me the tint:

Required type: Function2

What is it?

If I try to provide this with implemented: MenuItem.OnMenuItemClickListener interface, I get such error:

Required type:
Function2
Provided:
OnMenuItemClickListener

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions