Android Open Source - GroupGoal Application






From Project

Back to project page GroupGoal.

License

The source code is released under:

GNU General Public License

If you think the Android project GroupGoal listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.cs121.groupgoal;
//ww  w  .  ja  v  a 2s.c  o  m
import android.content.Context;
import android.content.SharedPreferences;

import com.parse.Parse;
import com.parse.ParseObject;

public class Application extends android.app.Application {
  // Debugging switch
  public static final boolean APPDEBUG = false;

  // Debugging tag for the application
  public static final String APPTAG = "GroupGoal";

  // Used to pass location from MainActivity to PostActivity
  public static final String INTENT_EXTRA_LOCATION = "location";

  // Key for saving the search distance preference
  private static final String KEY_SEARCH_DISTANCE = "searchDistance";

  private static final float DEFAULT_SEARCH_DISTANCE = 250.0f;

  private static SharedPreferences preferences;

  private static ConfigHelper configHelper;

  public Application() {
  }

  @Override
  public void onCreate() {
    super.onCreate();

    ParseObject.registerSubclass(GoalPost.class);
    ParseObject.registerSubclass(Comment.class);
    Parse.initialize(this, "taKaWQ9jdSlG2DryqXcpg0Aq8FMobmFjiS6K500d",
        "y0C4d44dKDn6FFJdyigkjAaonrrzbGytUzbU59Bp"); //our personal codes to access the Parse account we created

    preferences = getSharedPreferences("com.cs121.groupgoal", Context.MODE_PRIVATE);

    configHelper = new ConfigHelper();
    configHelper.fetchConfigIfNeeded();
  }

  public static float getSearchDistance() {
    return preferences.getFloat(KEY_SEARCH_DISTANCE, DEFAULT_SEARCH_DISTANCE);
  }

  public static ConfigHelper getConfigHelper() {
    return configHelper;
  }

  public static void setSearchDistance(float value) {
    preferences.edit().putFloat(KEY_SEARCH_DISTANCE, value).commit();
  }

}




Java Source Code List

android.UnusedStub.java
com.cs121.groupgoal.Application.java
com.cs121.groupgoal.CommentActivity.java
com.cs121.groupgoal.Comment.java
com.cs121.groupgoal.ConfigHelper.java
com.cs121.groupgoal.DatePickerDialogFragment.java
com.cs121.groupgoal.DispatchActivity.java
com.cs121.groupgoal.GoalAdapter.java
com.cs121.groupgoal.GoalPost.java
com.cs121.groupgoal.InviteActivity.java
com.cs121.groupgoal.LoginActivity.java
com.cs121.groupgoal.MainActivity.java
com.cs121.groupgoal.MyFriendsActivity.java
com.cs121.groupgoal.NotificationsActivity.java
com.cs121.groupgoal.PostActivity.java
com.cs121.groupgoal.SignUpActivity.java
com.cs121.groupgoal.StartGuideActivity.java
com.cs121.groupgoal.TimePickerDialogFragment.java
com.cs121.groupgoal.UpcomingGoalsActivity.java
com.cs121.groupgoal.UserProfileActivity.java
com.cs121.groupgoal.ViewAttendeesActivity.java
com.cs121.groupgoal.ViewGoal.java
com.cs121.groupgoal.WelcomeActivity.java