Code example for PopupMenu

Methods: getMenugetMenuInflater

	public void inflate(int menuId) {
		// done without using the PopupMenu.inflate() method, which isn't available on Honeycomb. 
		// this method works on both Honeycomb and Ice Cream Sandwich. 
		MenuInflater inflater = menu.getMenuInflater();
		Menu baseMenu = menu.getMenu();
		inflater.inflate(menuId, baseMenu);
	public void show() {;
	static { 
		try { 
		} catch (Exception ex) {
			throw new RuntimeException(ex);
Connect your IDE to all the code out there  Get Codota for Java