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
private SyncStatusObserver mSyncStatusObserver = new SyncStatusObserver() { | |
@Override | |
public void onStatusChanged(int which) { | |
runOnUiThread(new Runnable() { | |
@Override | |
public void run() { | |
String accountName = AccountUtils.getActiveAccountName(BaseActivity.this); | |
if (TextUtils.isEmpty(accountName)) { | |
onRefreshingStateChanged(false); | |
mManualSyncRequest = false; |
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 LogUtils { | |
private static final String LOG_PREFIX = "myapp_"; | |
private static final int LOG_PREFIX_LENGTH = LOG_PREFIX.length(); | |
private static final int MAX_LOG_TAG_LENGTH = 23; | |
private LogUtils() { | |
} | |
public static String makeLogTag(String str) { | |
if (str.length() > MAX_LOG_TAG_LENGTH - LOG_PREFIX_LENGTH) { |