コード例 #1
0
 protected void onDestroy() {
   MojiLog.v("WeatherMainActivity", "onDestroy");
   super.onDestroy();
   if (mWeathearTabCallBackImpl != null)
     WeatherTabPublisher.getInstance().unSubscribe(mWeathearTabCallBackImpl);
   mCityWeatherBgSwitcher.removeTimer();
   checkStopBroadcast();
 }
コード例 #2
0
 protected void onCreate(Bundle bundle) {
   super.onCreate(bundle);
   MojiLog.v("WeatherMainActivity", "onCreate");
   initWindow();
   setContentView(0x7f03004f);
   initMain();
   forFirstRun();
   checkTuorialDisplay();
   addUmengAd();
   subscribeWeathertabCallBack();
   mFadeAnim = AnimationUtils.loadAnimation(this, 0x7f040008);
   mFadeAnim.setDuration(300L);
 }
コード例 #3
0
 protected void onResume() {
   super.onResume();
   MojiLog.v("WeatherMainActivity", "onResume");
   if (android.os.Build.VERSION.SDK_INT > 4)
     if (mIsFromCityView) {
       mIsFromCityView = false;
       if (mCurrentCityIdx != Gl.getCurrentCityIndex()) {
         mCurrentCityIdx = Gl.getCurrentCityIndex();
         ((ViewGroup) findViewById(0x7f0d01d7)).startAnimation(mFadeAnim);
       }
     } else {
       ((ViewGroup) findViewById(0x7f0d01d7)).startAnimation(mFadeAnim);
     }
   StatsUtil.updateStatsPv(com.moji.mjweather.util.StatsUtil.StatsPv.PV_WW);
 }
コード例 #4
0
 protected void onStop() {
   MojiLog.v("WeatherMainActivity", "onStop");
   super.onStop();
   Gl.saveCurrentCityIndex(Gl.getCurrentCityIndex());
 }
コード例 #5
0
 protected void onPause() {
   super.onPause();
   MojiLog.v("WeatherMainActivity", "onPause");
   if (isUpdating) cancelUpdateWeather(null, true);
 }