/* Mirrors Activity#onStop(...) */
 void onStop() {
   if (mCheckout != null) {
     mCheckout.stop();
     AppHeap.getCheckoutInternal().requestDisconnect();
   }
   mPowerSaveDetector.stop();
 }
 /* Mirrors Activity#onDestroy(...) */
 void onDestroy() {
   mCheckout = null;
   if (mInputMethodResetRequest) performInputMethodServiceReset();
   // Watch for the activity to detect possible leaks.
   RefWatcher refWatcher = AppHeap.getRefWatcher();
   refWatcher.watch(this);
 }
 /* Mirrors Activity#onStart(...) */
 void onStart() {
   if (mCheckout != null) {
     AppHeap.getCheckoutInternal().requestConnect();
     mCheckout.start();
   }
   mPowerSaveDetector.start();
 }
 /* Mirrors Activity#onCreate(...) */
 void onCreate(Activity activity, Bundle savedInstanceState) {
   if (mCheckoutRequest) mCheckout = Checkout.forActivity(activity, AppHeap.getCheckout());
   mPowerSaveDetector = PowerSaveDetector.newInstance(activity);
   mActivity = activity;
   mCreated = true;
 }