You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to show a PopupMenu when a node in long clicked.
treeView.setDefaultNodeLongClickListener { node, value ->// show popup to remove fileval popup =PopupMenu(context!!, node.viewHolder.view)
//Inflating the Popup using xml file
popup.menuInflater
.inflate(R.menu.file_menu, popup.menu)
popup.show()
true
}
In PopupMenu(context!!, node.viewHolder.view) I need to set a view to hook the popup menu, but node.viewHolder.view don't show nothing as result.
What is the proper view of node ?
The text was updated successfully, but these errors were encountered:
So, in setDefaultNodeLongClickListener I got view reference through id:
treeView.setDefaultNodeLongClickListener { node, value ->// show popup to remove fileval popup =PopupMenu(context!!, vFiles.findViewById(node.id))
//Inflating the Popup using xml file
popup.menuInflater
.inflate(R.menu.file_menu, popup.menu)
popup.show()
true
}
I want to show a
PopupMenu
when a node in long clicked.In
PopupMenu(context!!, node.viewHolder.view)
I need to set a view to hook the popup menu, butnode.viewHolder.view
don't show nothing as result.What is the proper view of node ?
The text was updated successfully, but these errors were encountered: