public void addAction(int id, CharSequence title, MenuItemClickListener listener) { final Action action = new Action(); action.setId(id); action.setTitle(title); action.setListener(listener); actions.add(action); }
public void addAction(int id, int titleResource, MenuItemClickListener listener) { final Action action = new Action(); action.setId(id); action.setTitle(titleResource); action.setListener(listener); actions.add(action); }
private Action getReloadAction() { final Action reload = new Action(); reload.setId(-501); reload.setTitle(R.string.imm__reload); reload.setListener( new MenuItemClickListener() { public void onClick(ImageMenu imageMenu, int menuItemId) { imageLoader.reload(); } }); return reload; }