Created
July 3, 2017 04:04
-
-
Save agusibrahim/b98821df84ee26265c3dbdcd9f91bcf0 to your computer and use it in GitHub Desktop.
Test Post with java Android
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public boolean onOptionsItemSelected(MenuItem item) { | |
switch (item.getItemId()) { | |
case R.id.menu_login: | |
String token=gauth.getAccessToken(); | |
if(token==null) doLogin(); | |
else mPerformEdit.setDefaultText("Has Login, Token: "+token); | |
break; | |
case R.id.menu_settings: | |
if(gauth.getAccessToken()!=null){ | |
doPost(); | |
} | |
break; | |
} | |
return super.onOptionsItemSelected(item); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment