First two episodes are explained in two ways
One is implemented in code, and the other is implemented using XML files.
And then the listener is the same. Directly use the item's ID to trigger the menu directly.
Finally, the second episode directly adds the menu directly inside the action bar.
The third episode explains the use of floating menus
A floating menu can be registered with any view.
And every menu item is monitored.
About the differences (the following is the addition of the context menu)
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/4B/78/wKiom1QuCFqzyhnxAAHMuDxz9Ac982.jpg "title=" Snapshot 30.jpg "alt=" Wkiom1qucfqzyhnxaahmudxz9ac982.jpg "/>
This menu will appear directly when you click on an item in the ListView.
The following method will trigger this method when you click on a project in the ListView.
The following directly triggers the practice of clicking on each small item in the context menu
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/4B/7A/wKioL1QuCZXAm4YtAAMn9L3cOUw726.jpg "title=" Snapshot 32.jpg "alt=" Wkiol1quczxam4ytaamn9l3couw726.jpg "/>
Finally, the context popup menu is written
Look at the code:
Menu operation for Android