コード例 #1
0
 @ServiceThreadOnly
 private void invokeCallback(IHdmiControlCallback callback, int result) {
   assertRunOnServiceThread();
   try {
     callback.onComplete(result);
   } catch (RemoteException e) {
     Slog.e(TAG, "Invoking callback failed:" + e);
   }
 }
コード例 #2
0
 private void finishWithCallback(int returnCode) {
   if (mCallback != null) {
     try {
       mCallback.onComplete(returnCode);
     } catch (RemoteException e) {
       Slog.e(TAG, "Failed to invoke callback.", e);
     }
   }
   finish();
 }