Java代碼
// 銷毀 protected void onDestroy() { System.out.println("onDestroy"); super.onDestroy(); } // 暫停 protected void onPause() { System.out.println("onPause"); super.onPause(); } // 重新啟動 protected void onRestart() { System.out.println("onRestart"); super.onRestart(); } // Resume protected void onResume() { System.out.println("onResume"); super.onResume(); }
作者“Android開發”