@Override
 protected void onStart() {
   AppEventsLogger logger = uiHelper.getAppEventsLogger();
   super.onStart();
   logger.logEvent("Home");
   mDataLayer = TagManager.getInstance(this).getDataLayer();
   mDataLayer.push(DataLayer.mapOf("event", "screenVisible", "screenName", SCREEN_NAME));
   EasyTracker.getInstance(this).activityStart(this);
 }
  @Override
  public void onPause() {
    super.onPause();
    uiHelper.onPause();
    AppEventsLogger.deactivateApp(this);

    // Call the 'deactivateApp' method to log an app event for use in
    // analytics and advertising
    // reporting. Do so in the onPause methods of the primary Activities
    // that an app may be launched into.
    AppEventsLogger.deactivateApp(this);
  }
  @Override
  protected void onResume() {
    // TODO Auto-generated method stub
    super.onResume();
    AppEventsLogger.activateApp(this);

    uiHelper.onResume();

    // Call the 'activateApp' method to log an app event for use in
    // analytics and advertising reporting. Do so in
    // the onResume methods of the primary Activities that an app may be
    // launched into.
    AppEventsLogger.activateApp(this);

    updateUI();
  }
Exemple #4
0
 @Override
 protected void onResume() {
   super.onResume();
   Varios.clearAllNotifications = false;
   AppEventsLogger.activateApp(this, getString(R.string.facebook_app_id));
   EasyTracker.getInstance(this).activityStart(this);
 }
 @Override
 protected void onResume() {
   super.onResume();
   com.facebook.AppEventsLogger.activateApp(getApplicationContext(), AppConstants.FACEBOOK_APPID);
   Log.d("=============================", "test");
   // Tabbars.getInstance().hideTabs();
   try {
     InputMethodManager inputManager =
         (InputMethodManager) mHomePage.getSystemService(Activity.INPUT_METHOD_SERVICE);
     inputManager.hideSoftInputFromWindow(
         mParentLayout.getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS);
   } catch (Exception e) {
   }
   // isInBackGround = false;
   // getLatLongObj = GetLatLongFromGPS.getinstance(this); // PP
   // if (getLatLongObj != null) { // PP
   // if (getLatLongObj.mbUpdatesStopped == true) {
   // getLatLongObj.startGPS();
   // }
   // }
   // try {
   // Thread.sleep(2000);
   // } catch (InterruptedException e) {
   // e.printStackTrace();
   // }
 }
  @Override
  protected void onResume() {
    super.onResume();

    final String intentAnswerId = getIntent().getExtras().getString(INTENT_ANSWER_EXTRA);
    IntentAnswer.getIntentAnswer(
        intentAnswerId,
        new GetCallback<IntentAnswer>() {

          @Override
          public void done(IntentAnswer intentAnswer, ParseException error) {
            if (error == null) {
              updateView(intentAnswer);
            } else {
              Log.e(TAG, "Cannot load intent", error);
              // Let's update the data and try again
              fetchIntentAnswer(intentAnswerId);
            }
          }
        });

    registerNotificationReceiver();

    ActionLog.log("resumed intent answer activity", intentAnswerId);
    AppEventsLogger.activateApp(this);
  }
  @Override
  protected void onPause() {
    super.onPause();

    // Save read flag
    intentAnswer.saveInBackground();

    if (newMessageListener != null) {
      messagesRef.removeEventListener(newMessageListener);
    }

    if (chatStatusListener != null) {
      friendTypingRef.removeEventListener(chatStatusListener);
    }

    if (onlineStatusListener != null) {
      friendOnlineRef.removeEventListener(onlineStatusListener);
    }

    if (userTypingRef != null) {
      userTypingRef.setValue(false);
    }

    if (receiver != null) {
      unregisterReceiver(receiver);
    }

    ActionLog.log("paused intent answer activity");
    AppEventsLogger.deactivateApp(this);
  }
  @Override
  protected void onResume() {
    super.onResume();

    // Call the 'activateApp' method to log an app event for use in analytics and advertising
    // reporting.  Do so in
    // the onResume methods of the primary Activities that an app may be launched into.
    AppEventsLogger.activateApp(this);
  }
  @Override
  protected void onResume() {

    super.onResume();

    Context context = getApplicationContext();

    com.facebook.AppEventsLogger.activateApp(context, "316673561850081");
  }
  @Override
  void logAppEvents(boolean doneButtonClicked) {
    AppEventsLogger logger = AppEventsLogger.newLogger(this.getActivity(), getSession());
    Bundle parameters = new Bundle();

    // If Done was clicked, we know this completed successfully. If not, we don't know (caller might
    // have
    // dismissed us in response to selection changing, or user might have hit back button). Either
    // way
    // we'll log the number of selections.
    String outcome =
        doneButtonClicked
            ? AnalyticsEvents.PARAMETER_DIALOG_OUTCOME_VALUE_COMPLETED
            : AnalyticsEvents.PARAMETER_DIALOG_OUTCOME_VALUE_UNKNOWN;
    parameters.putString(AnalyticsEvents.PARAMETER_DIALOG_OUTCOME, outcome);
    parameters.putInt("num_places_picked", (getSelection() != null) ? 1 : 0);

    logger.logSdkEvent(AnalyticsEvents.EVENT_PLACE_PICKER_USAGE, null, parameters);
  }
Exemple #11
0
  @Override
  protected void onResume() {
    super.onResume();

    uiHelper = new UiLifecycleHelper(this, callback);
    uiHelper.onResume();

    try {
      /* Only activate FaceBook publish install if the user has the FaceBook app installed */
      if (com.facebook.Settings.getAttributionId(getContentResolver()) != null) {
        com.facebook.AppEventsLogger.activateApp(this);
      }
    } catch (IllegalStateException e) {
      Log.d(TAG, "Facebook Setting Exception again!");
    }

    AndroidAuthSession session = mApi.getSession();

    // The next part must be inserted in the onResume() method of the
    // activity from which session.startAuthentication() was called, so
    // that Dropbox authentication completes properly.
    if (session.authenticationSuccessful()) {
      try {
        // Mandatory call to complete the auth
        session.finishAuthentication();

        // Store it locally in our app for later use
        TokenPair tokens = session.getAccessTokenPair();
        storeKeys(tokens.key, tokens.secret);
        setLoggedIn(true);
      } catch (IllegalStateException e) {
        showToast("Couldn't authenticate with Dropbox:" + e.getLocalizedMessage());
        Log.i(TAG, "Error authenticating", e);
      }
    }
  }
Exemple #12
0
  @Override
  protected void onPause() {
    super.onPause();

    AppEventsLogger.deactivateApp(this);
  }