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 class NetworkLogUtility { | |
public static void logFailure(Call call, Throwable throwable){ | |
if(call != null){ | |
if (call.isCanceled()) | |
Timber.e("Request was cancelled"); | |
Request request = call.request(); | |
if(request != null){ | |
HttpUrl httpUrl = request.url(); |
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
// How make the ActionBar title clickable on Android under API 11 (1/2) | |
private static final boolean API_LEVEL_UNDER_11 = android.os.Build.VERSION.SDK_INT < 11; | |
private boolean navigationDrawerEnabled = true; // Useful if your app need navigation drawer | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
if (API_LEVEL_UNDER_11) { | |
getSupportActionBar().setCustomView(R.layout.partial_actionbar); | |
getSupportActionBar().setDisplayShowCustomEnabled(true); |
NewerOlder