public boolean onOptionsItemSelected(MenuItem item) { Intent serverIntent = null; switch (item.getItemId()) { case R.id.directioncontrolmenu: // OpenChange Direction Pad menu //What should I declare view here as? So I could call the context menu. openContextMenu(); return true; } return false; }
public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo) { if (v == findViewById(R.id.directioncontrolmenu)) { menu.add(100,101,1, "Dpad only"); menu.add(100,102,3, "Up and Down Button With Gyroscope"); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)