I'm currently trying to add a click listener to the menu hardware button. Currently I'm just putting my onclick logic into the onCreatePanelMenu-method and return false. But that just feels wrong.
Is there a more clean way?
The code currently looks like that:
@Override
public boolean onCreatePanelMenu(int featureId, Menu menu) {
Toast.makeText(this, "HALLO!", Toast.LENGTH_SHORT).show();
return false;
}