I'm using a standard android activity, the "Navigation Drawer Activity", and there's a button in the navigation bar
public boolean onOptionsItemSelected(MenuItem item) {
if (mDrawerToggle.onOptionsItemSelected(item)) {
return true;
}
if (item.getItemId() == R.id.action_example) {
Toast.makeText(getActivity(), "Example action.", Toast.LENGTH_SHORT)
.show();
//getActivity().drawGraph();
return true;
}
And I'd like to call the drawGraphic () method of my main activity just by pressing the
Note that this navigation bar is a fragment