Пример #1
0
  private static void failListener(int requestedAction, String message) {
    switch (requestedAction) {
      case ACTION_LOGIN:
        {
          RefLoginListener.fail("Login failed: " + message);
          break;
        }
      case ACTION_PUBLISH_STATUS:
        {
          RefSocialActionListener.fail("Publish status failed: " + message);
          break;
        }
      case ACTION_PUBLISH_STATUS_DIALOG:
        {
          RefSocialActionListener.fail("Publish status dialog failed: " + message);
          break;
        }
      case ACTION_PUBLISH_STORY:
        {
          RefSocialActionListener.fail("Publish story failed: " + message);
          break;
        }
      case ACTION_PUBLISH_STORY_DIALOG:
        {
          RefSocialActionListener.fail("Publish story dialog failed: " + message);
          break;
        }
      case ACTION_UPLOAD_IMAGE:
        {
          RefSocialActionListener.fail("Upload Image failed: " + message);
          break;
        }
      case ACTION_GET_FEED:
        {
          RefFeedListener.fail("Get feed failed: " + message);
          break;
        }
      case ACTION_GET_CONTACTS:
        {
          RefContactsListener.fail("Get contacts failed: " + message);
          break;
        }
      case ACTION_GET_USER_PROFILE:
        {
          RefUserProfileListener.fail("Get user profile failed: " + message);
          break;
        }
      default:
        {
          SoomlaUtils.LogWarning(TAG, "action unknown fail listener:" + requestedAction);
          break;
        }
    }

    clearListener(requestedAction);
  }
Пример #2
0
  /** {@inheritDoc} */
  @Override
  public void updateStatusDialog(
      String link, SocialCallbacks.SocialActionListener socialActionListener) {
    if (!isInitialized) {
      return;
    }

    SoomlaUtils.LogDebug(TAG, "updateStatusDialog");
    socialActionListener.fail("Dialogs are not available in Twitter");
  }
Пример #3
0
 /**
  * Called when a tweet has finished posting
  *
  * @param status The status which was posted
  */
 @Override
 public void updatedStatus(Status status) {
   SoomlaUtils.LogDebug(TAG, "updateStatus/onComplete");
   RefSocialActionListener.success();
   clearListener(ACTION_PUBLISH_STATUS);
 }