文件整理

This commit is contained in:
huangzhuanghua
2016-08-31 14:41:41 +08:00
parent d4498fb573
commit efc19441cd
219 changed files with 1738 additions and 1873 deletions

View File

@ -5,7 +5,6 @@ import android.app.Activity;
import android.content.Context;
import android.os.Build;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup.LayoutParams;
@ -37,17 +36,14 @@ import onekeyshare.OnekeyShare;
import onekeyshare.themes.classic.PlatformPage;
public class BaseActivity extends Activity {
private String LOG = this.getClass().getName();
private boolean LOG_ON = true;
private SystemBarTintManager tintManager;
private boolean isPause;
private SystemBarTintManager tintManager;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
AppLog("onCreate");
Utils.log(this.getClass().getSimpleName());
AppController.getInstance().addActivity(this);
EventBus.getDefault().register(this);
@ -65,7 +61,7 @@ public class BaseActivity extends Activity {
setTranslucentStatus(true);
tintManager = new SystemBarTintManager(this);
tintManager.setStatusBarTintEnabled(true);
tintManager.setStatusBarTintResource(R.color.theme_colors);
tintManager.setStatusBarTintResource(R.color.theme);
SystemBarConfig config = tintManager.getConfig();
contentView.setPadding(0, config.getPixelInsetTop(false), 0,
config.getPixelInsetBottom());
@ -120,12 +116,6 @@ public class BaseActivity extends Activity {
AppController.getInstance().removeActivity(this);
}
public void AppLog(String str) {
if (LOG_ON) {
Log.i(LOG, str);
}
}
public void toast(String msg) {
Toast.makeText(this, msg, Toast.LENGTH_SHORT).show();
}
@ -231,35 +221,15 @@ public class BaseActivity extends Activity {
@Override
protected void onPause() {
super.onPause();
AppLog("onPause");
DataUtils.onPause(this);
isPause = true;
}
@Override
protected void onRestart() {
super.onRestart();
AppLog("onRestart");
}
@Override
protected void onResume() {
super.onResume();
AppLog("onResume");
DataUtils.onResume(this);
isPause = false;
}
@Override
protected void onStart() {
super.onStart();
AppLog("onStart");
}
@Override
protected void onStop() {
super.onStop();
AppLog("onStop");
}
}