+ if (mOperationsServiceBinder != null) {\r
+ doOnResumeAndBound();\r
+ }\r
+ \r
+ //Log.wtf(TAG, "onResume end" );\r
+ }\r
+\r
+ \r
+ @Override\r
+ protected void onPause() {\r
+ //Log.wtf(TAG, "onPause init" );\r
+ if (mOperationsServiceBinder != null) {\r
+ //Log.wtf(TAG, "unregistering to listen for operation callbacks" );\r
+ mOperationsServiceBinder.removeOperationListener(this);\r
+ }\r
+ super.onPause();\r
+ //Log.wtf(TAG, "onPause end" );\r
+ }\r
+ \r
+ @Override\r
+ protected void onDestroy() {\r
+ if (mOperationsServiceConnection != null) {\r
+ unbindService(mOperationsServiceConnection);\r
+ mOperationsServiceBinder = null;\r
+ }\r
+ super.onDestroy();\r