Skip to content

Commit

Permalink
Release 8.3.3 (#95)
Browse files Browse the repository at this point in the history
* Maps marker deselect and UI changes (#84) - Closed #79

Merge map fix into develop

* Test structure now mirrors src structure (#85)

* Dagger 2 and some bug fixes  (#86)

* Added initial dagger modules

* Implemented dagger functionality in all legacy BMController calls, also fixed gym group_ex crash bug and general clean up

* Updated gradle version and dependencies to make bitrise happy

* Limited bounds of autocomplete search on BearTransit map

* fixed library hours not being right justified by using changing width to match parent (#87)

* Limited autocomplete search to Berkeley area for BearTransit map (#94)

* Updated CONTRIBUTING.md

Changed instructions to tell open source contributors to make a PR to develop instead of master

* Limited bounds of autocomplete search on BearTransit map

* Added release notes

* Removed google-services.json from readme

* Fixed bounds for Destination
  • Loading branch information
rustielin authored Oct 21, 2018
1 parent 5654398 commit f6ebec7
Show file tree
Hide file tree
Showing 28 changed files with 362 additions and 262 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ It is recommended you use Android Studio 3.0.0.
* Create a new project in the [Google Cloud Console](https://console.cloud.google.com)
* Under the APIs and Services tab, enable the Google Places API for Android, Google Maps Directions API, Google Maps Android API, and Google Maps Geocoding API
* Under the Credentials tab, create an API key
* Paste your API key into [secret.xml](app/src/main/res/values/secret.xml) and [google-services.json](app/google-services.json)
* Paste your API key into [secret.xml](app/src/main/res/values/secret.xml)
* We've configured this repository so that the application pulls from our sandbox backend, which just returns test data. If you would like access to our production backend API, please [contact us](#contact).

## Contributing [![contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)](https://github.com/asuc-octo/berkeley-mobile-android/issues)
Expand Down
87 changes: 58 additions & 29 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apply plugin: 'io.fabric'

android {
compileSdkVersion 25
buildToolsVersion '26.0.2'
buildToolsVersion '28.0.3'

defaultConfig {
applicationId "com.asuc.asucmobile"
Expand All @@ -18,6 +18,19 @@ android {
dexOptions {
javaMaxHeapSize "4g"
}

packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.md'
exclude 'META-INF/LICENSE-notice.md'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/notice.txt'
exclude 'META-INF/ASL2.0'
}
}

repositories {
Expand All @@ -27,48 +40,64 @@ repositories {


dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'mbanje.kurt:fabbutton:1.2.4@aar'
compile 'com.dmitrymalkovich.android:progress-fab:1.6'
compile 'com.wang.avi:library:2.1.3'
compile 'com.chabbal:slidingdotsplash:1.0.2'
compile 'com.android.support:multidex:1.0.1'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'mbanje.kurt:fabbutton:1.2.4@aar'
implementation 'com.dmitrymalkovich.android:progress-fab:1.6'
implementation 'com.wang.avi:library:2.1.3'
implementation 'com.chabbal:slidingdotsplash:1.0.2'
implementation 'com.android.support:multidex:1.0.1'

compile 'com.google.code.gson:gson:2.8.0'
implementation 'com.google.code.gson:gson:2.8.0'

compile 'com.google.android.gms:play-services:11.8.0'
compile 'com.google.android.gms:play-services-location:11.8.0'
compile 'com.crashlytics.sdk.android:crashlytics:2.9.1'
implementation 'com.google.android.gms:play-services:11.8.0'
implementation 'com.google.android.gms:play-services-location:11.8.0'
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.1'



//compile 'com.getbase:floatingactionbutton:1.10.1'
compile 'com.github.clans:fab:1.6.4'
//implementation 'com.getbase:floatingactionbutton:1.10.1'
implementation 'com.github.clans:fab:1.6.4'

compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'com.android.support:appcompat-v7:25.3.0'
compile 'com.android.support:design:25.3.0'
compile 'com.android.support:support-v4:25.3.0'
compile 'com.android.support:support-v13:25.3.0'
compile 'com.android.support:cardview-v7:25.3.0'
implementation 'com.github.bumptech.glide:glide:3.7.0'
implementation 'com.android.support:appcompat-v7:25.3.0'
implementation 'com.android.support:design:25.3.0'
implementation 'com.android.support:support-v4:25.3.0'
implementation 'com.android.support:support-v13:25.3.0'
implementation 'com.android.support:cardview-v7:25.3.0'

compile 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.squareup.picasso:picasso:2.5.2'

compile 'com.pushwoosh:pushwoosh:4.6.2'
compile 'com.squareup.retrofit2:retrofit:2.1.0'
compile 'com.squareup.retrofit2:converter-gson:2.1.0'
implementation 'com.pushwoosh:pushwoosh:4.6.2'
implementation 'com.squareup.retrofit2:retrofit:2.1.0'
implementation 'com.squareup.retrofit2:converter-gson:2.1.0'

compile 'com.jakewharton:butterknife:8.5.1'
compile 'com.github.bumptech.glide:glide:3.7.0'
implementation 'com.jakewharton:butterknife:8.5.1'
implementation 'com.github.bumptech.glide:glide:3.7.0'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.5.1'

compile 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'

implementation 'noman.weekcalendar:weekcalendar:1.0.6'

// maps
implementation 'com.google.android.gms:play-services-maps:16.0.0'
implementation 'com.google.android.gms:play-services-places:16.0.0'
implementation 'com.google.android.gms:play-services-location:16.0.0'

compile 'noman.weekcalendar:weekcalendar:1.0.6'
// firebase
implementation 'com.google.firebase:firebase-core:16.0.4'
implementation 'com.google.firebase:firebase-firestore:17.1.1'
implementation 'com.google.firebase:firebase-messaging:17.3.3'
implementation 'com.firebase:firebase-jobdispatcher:0.7.0'

compile 'com.google.firebase:firebase-messaging:11.8.0'
compile 'com.firebase:firebase-jobdispatcher:0.7.0'
// dagger 2
implementation 'com.google.dagger:dagger:2.17'
annotationProcessor 'com.google.dagger:dagger-compiler:2.17'

// Required -- JUnit 4 framework
testImplementation 'junit:junit:4.12'
// Optional -- Mockito framework
testImplementation 'org.mockito:mockito-core:1.10.19'

}
apply plugin: 'com.google.gms.google-services'
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
android:label="@string/app_name"
android:theme="@style/AppTheme"
android:largeHeap="true"
android:name="android.support.multidex.MultiDexApplication">
android:name="com.asuc.asucmobile.GlobalApplication">

<meta-data
android:name="com.google.android.geo.API_KEY"
Expand Down
39 changes: 39 additions & 0 deletions app/src/main/java/com/asuc/asucmobile/GlobalApplication.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
package com.asuc.asucmobile;

import android.app.Application;
import android.content.Context;

import com.asuc.asucmobile.dagger.components.DaggerRetrofitComponent;
import com.asuc.asucmobile.dagger.components.RetrofitComponent;
import com.asuc.asucmobile.dagger.modules.AppModule;
import com.asuc.asucmobile.dagger.modules.RetrofitModule;
import com.asuc.asucmobile.utilities.ServerUtils;

/**
* Configuration for the global application
*/
public class GlobalApplication extends Application {

private static Context appContext;
private static RetrofitComponent retrofitComponent;

@Override
public void onCreate() {
super.onCreate();
appContext = getApplicationContext();

retrofitComponent = DaggerRetrofitComponent.builder()
.appModule(new AppModule(this))
.retrofitModule(new RetrofitModule(ServerUtils.getBaseUrl()))
.build();

}

public static RetrofitComponent getRetrofitComponent() {
return retrofitComponent;
}

public static Context getAppContext() {
return appContext;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package com.asuc.asucmobile.dagger.components;

import com.asuc.asucmobile.services.BMService;
import com.asuc.asucmobile.dagger.modules.AppModule;
import com.asuc.asucmobile.dagger.modules.RetrofitModule;
import com.asuc.asucmobile.fragments.FoodFragment;
import com.asuc.asucmobile.fragments.GymFragment;
import com.asuc.asucmobile.fragments.LibraryFragment;
import com.asuc.asucmobile.fragments.ResourceFragment;

import javax.inject.Singleton;

import dagger.Component;

@Singleton
@Component(modules = {RetrofitModule.class, AppModule.class})
public interface RetrofitComponent {

// TODO: try a more generalized injection function

void inject(FoodFragment fragment);

void inject(LibraryFragment fragment);

void inject(GymFragment fragment);

void inject(ResourceFragment fragment);

// testing?

BMService bmapi();

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package com.asuc.asucmobile.dagger.modules;

import android.app.Application;

import javax.inject.Singleton;

import dagger.Module;
import dagger.Provides;

@Module
public class AppModule {
Application mApplication;

public AppModule(Application mApplication) {
this.mApplication = mApplication;
}

@Provides
@Singleton
Application provideApplication() {
return mApplication;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package com.asuc.asucmobile.dagger.modules;

import com.google.firebase.firestore.FirebaseFirestore;

import javax.inject.Singleton;

import dagger.Module;
import dagger.Provides;

@Module
public class RepositoryModule {

// singleton provider for Firestore instance
@Provides
@Singleton
public FirebaseFirestore getFirestore() {
return FirebaseFirestore.getInstance();
}

}
Loading

0 comments on commit f6ebec7

Please sign in to comment.