Пример #1
0
        public void onServiceConnected(ComponentName className, IBinder service) {
          // We've bound to LocalService, cast the IBinder and get
          // LocalService instance
          if (service == null) {
            return;
          }

          mWeatherService = IWeatherService.Stub.asInterface(service);
          if (mWeatherBindedCallBack != null) {
            mWeatherBindedCallBack.onWeatherServiceBinded(mWeatherService);
          }
        }
Пример #2
0
 public void onServiceDisconnected(ComponentName arg0) {
   mWeatherService = null;
   if (mWeatherBindedCallBack != null) {
     mWeatherBindedCallBack.onWeatherServiceBinded(null);
   }
 }